From ba53e49845f21836a431a8626cfee2877d1a6dbf Mon Sep 17 00:00:00 2001 From: luoyaoming Date: Tue, 7 May 2024 14:59:55 +0800 Subject: [PATCH] Import Upstream version 9.2.0~ds1 --- .commitlintrc.js | 10 + .eslintrc.js | 23 + .eslintrc.json | 15 - .eslintrc.local.json | 14 + .gitattributes | 2 - .github/CODEOWNERS | 1 - .github/ISSUE_TEMPLATE/bug_8.yml | 63 - .github/ISSUE_TEMPLATE/config.yml | 23 - .github/ISSUE_TEMPLATE/docs-enhancement.yml | 37 - .github/ISSUE_TEMPLATE/docs-problem.yml | 37 - .github/workflows/benchmark-comment.yml | 87 - .github/workflows/benchmark.yml | 52 - .github/workflows/ci-docs.yml | 52 - .github/workflows/ci-libnpmaccess.yml | 76 - .github/workflows/ci-libnpmdiff.yml | 76 - .github/workflows/ci-libnpmexec.yml | 76 - .github/workflows/ci-libnpmfund.yml | 76 - .github/workflows/ci-libnpmhook.yml | 76 - .github/workflows/ci-libnpmorg.yml | 76 - .github/workflows/ci-libnpmpack.yml | 76 - .github/workflows/ci-libnpmpublish.yml | 76 - .github/workflows/ci-libnpmsearch.yml | 76 - .github/workflows/ci-libnpmteam.yml | 76 - .github/workflows/ci-libnpmversion.yml | 76 - .github/workflows/ci-npmcli-arborist.yml | 76 - .github/workflows/ci.yml | 166 - .github/workflows/create-cli-deps-pr.yml | 89 - .gitignore | 30 - .mailmap | 2 + .npmrc | 3 + .release-please-manifest.json | 16 + AUTHORS | 44 +- CHANGELOG.md | 947 +- CODE_OF_CONDUCT.md | 7 + CONTRIBUTING.md | 21 +- DEPENDENCIES.md | 790 + Makefile | 123 - README.md | 16 +- SECURITY.md | 15 +- bin/node-gyp-bin/node-gyp | 2 +- bin/npx | 3 + bin/npx-cli.js | 2 + changelogs/CHANGELOG-1.md | 743 - changelogs/CHANGELOG-2.md | 5344 ---- changelogs/CHANGELOG-3.md | 5245 ---- changelogs/CHANGELOG-4.md | 1566 -- changelogs/CHANGELOG-5.md | 2360 -- changelogs/CHANGELOG-6.md | 2910 --- changelogs/CHANGELOG-7.md | 3644 --- debian/NEWS | 11 - debian/README.Debian | 50 - debian/README.source | 24 - debian/TODO | 2 - debian/changelog | 5 - debian/clean | 35 - debian/control | 155 - debian/copyright | 501 - debian/copyright_hints | 1394 -- debian/docs | 3 - debian/install | 1 - debian/links | 3 - debian/manpages | 3 - debian/nodejs/additional_components | 3 - debian/nodejs/files | 2 - debian/nodejs/links | 10 - debian/nodejs/root_modules | 5 - debian/npm.bash-completion | 1 - debian/npm.lintian-overrides | 6 - debian/npm.maintscript | 3 - debian/npmrc | 5 - debian/patches/2004_remove_shebang.patch | 11 - debian/patches/2011_node-gyp-path.patch | 17 - .../patches/2012_dont_install_man_deps.patch | 16 - ...020_reproducible_documentation_build.patch | 19 - .../patches/dont-check-for-last-version.patch | 95 - debian/patches/fix-test.patch | 64 - debian/patches/fix-tests.patch | 70 - debian/patches/series | 6 - debian/rules | 57 - debian/source/format | 1 - debian/source/lintian-overrides | 30 - debian/tests/control | 8 - debian/tests/install-test | 9 - debian/tests/no-duplication | 10 - debian/tests/pkg-js/SKIP | 1 - debian/tests/test_excluded | 1 - debian/watch | 10 - docs/.eslintrc.js | 17 + docs/.gitignore | 21 + docs/README.md | 5 + docs/bin/build.js | 9 + docs/config.json | 5 - docs/content/commands/npm-adduser.md | 94 - docs/content/commands/npm-bin.md | 49 - docs/content/commands/npm-bugs.md | 62 - docs/content/commands/npm-ci.md | 117 - docs/content/commands/npm-config.md | 173 - docs/content/commands/npm-dedupe.md | 310 - docs/content/commands/npm-docs.md | 122 - docs/content/commands/npm-explain.md | 112 - docs/content/commands/npm-find-dupes.md | 232 - docs/content/commands/npm-fund.md | 155 - docs/content/commands/npm-install-ci-test.md | 69 - docs/content/commands/npm-install-test.md | 297 - docs/content/commands/npm-link.md | 384 - docs/content/commands/npm-logout.md | 83 - docs/content/commands/npm-ls.md | 290 - docs/content/commands/npm-org.md | 121 - docs/content/commands/npm-pack.md | 140 - docs/content/commands/npm-prefix.md | 66 - docs/content/commands/npm-prune.md | 159 - docs/content/commands/npm-publish.md | 250 - docs/content/commands/npm-rebuild.md | 143 - docs/content/commands/npm-repo.md | 105 - docs/content/commands/npm-restart.md | 77 - docs/content/commands/npm-root.md | 56 - docs/content/commands/npm-run-script.md | 253 - docs/content/commands/npm-search.md | 175 - docs/content/commands/npm-set-script.md | 101 - docs/content/commands/npm-stop.md | 80 - docs/content/commands/npm-test.md | 77 - docs/content/commands/npm-uninstall.md | 143 - docs/content/commands/npm-unpublish.md | 152 - docs/content/commands/npm-unstar.md | 82 - docs/content/commands/npm-update.md | 406 - docs/content/commands/npm-version.md | 244 - docs/content/using-npm/config.md | 2051 -- docs/content/using-npm/logging.md | 60 - docs/dockhand.js | 333 - docs/lib/build.js | 137 + docs/lib/check-nav.js | 62 + docs/{ => lib}/content/commands/npm-access.md | 57 +- docs/lib/content/commands/npm-adduser.md | 34 + docs/{ => lib}/content/commands/npm-audit.md | 240 +- docs/lib/content/commands/npm-bugs.md | 31 + docs/{ => lib}/content/commands/npm-cache.md | 29 +- docs/lib/content/commands/npm-ci.md | 76 + .../content/commands/npm-completion.md | 4 +- docs/lib/content/commands/npm-config.md | 106 + docs/lib/content/commands/npm-dedupe.md | 83 + .../content/commands/npm-deprecate.md | 38 +- docs/{ => lib}/content/commands/npm-diff.md | 190 +- .../content/commands/npm-dist-tag.md | 84 +- docs/lib/content/commands/npm-docs.md | 30 + docs/{ => lib}/content/commands/npm-doctor.md | 25 +- docs/{ => lib}/content/commands/npm-edit.md | 20 +- docs/{ => lib}/content/commands/npm-exec.md | 130 +- docs/lib/content/commands/npm-explain.md | 67 + .../{ => lib}/content/commands/npm-explore.md | 20 +- docs/lib/content/commands/npm-find-dupes.md | 26 + docs/lib/content/commands/npm-fund.md | 75 + .../content/commands/npm-help-search.md | 19 +- docs/{ => lib}/content/commands/npm-help.md | 21 +- docs/{ => lib}/content/commands/npm-hook.md | 36 +- docs/{ => lib}/content/commands/npm-init.md | 123 +- .../content/commands/npm-install-ci-test.md | 23 + docs/lib/content/commands/npm-install-test.md | 24 + .../{ => lib}/content/commands/npm-install.md | 288 +- docs/lib/content/commands/npm-link.md | 119 + docs/lib/content/commands/npm-login.md | 43 + docs/lib/content/commands/npm-logout.md | 35 + docs/lib/content/commands/npm-ls.md | 86 + docs/lib/content/commands/npm-org.md | 64 + .../content/commands/npm-outdated.md | 100 +- docs/{ => lib}/content/commands/npm-owner.md | 38 +- docs/lib/content/commands/npm-pack.md | 35 + docs/{ => lib}/content/commands/npm-ping.md | 19 +- docs/{ => lib}/content/commands/npm-pkg.md | 111 +- docs/lib/content/commands/npm-prefix.md | 44 + .../{ => lib}/content/commands/npm-profile.md | 63 +- docs/lib/content/commands/npm-prune.md | 42 + docs/lib/content/commands/npm-publish.md | 101 + docs/lib/content/commands/npm-query.md | 143 + docs/lib/content/commands/npm-rebuild.md | 29 + docs/lib/content/commands/npm-repo.md | 26 + docs/lib/content/commands/npm-restart.md | 46 + docs/lib/content/commands/npm-root.md | 34 + docs/lib/content/commands/npm-run-script.md | 146 + docs/lib/content/commands/npm-search.md | 47 + .../content/commands/npm-shrinkwrap.md | 4 +- docs/{ => lib}/content/commands/npm-star.md | 32 +- docs/{ => lib}/content/commands/npm-stars.md | 20 +- docs/{ => lib}/content/commands/npm-start.md | 35 +- docs/lib/content/commands/npm-stop.md | 49 + docs/{ => lib}/content/commands/npm-team.md | 65 +- docs/lib/content/commands/npm-test.md | 44 + docs/{ => lib}/content/commands/npm-token.md | 58 +- docs/lib/content/commands/npm-uninstall.md | 63 + docs/lib/content/commands/npm-unpublish.md | 50 + docs/lib/content/commands/npm-unstar.md | 41 + docs/lib/content/commands/npm-update.md | 165 + docs/lib/content/commands/npm-version.md | 104 + docs/{ => lib}/content/commands/npm-view.md | 93 +- docs/{ => lib}/content/commands/npm-whoami.md | 19 +- docs/{ => lib}/content/commands/npm.md | 6 +- docs/{ => lib}/content/commands/npx.md | 18 +- .../content/configuring-npm/folders.md | 52 +- .../content/configuring-npm/install.md | 0 .../configuring-npm/npm-shrinkwrap-json.md | 0 .../content/configuring-npm/npmrc.md | 37 + .../content/configuring-npm/package-json.md | 71 +- .../configuring-npm/package-lock-json.md | 0 docs/{ => lib/content}/nav.yml | 18 +- docs/lib/content/using-npm/config.md | 95 + .../content/using-npm/dependency-selectors.md | 207 + .../{ => lib}/content/using-npm/developers.md | 0 docs/lib/content/using-npm/logging.md | 96 + docs/{ => lib}/content/using-npm/orgs.md | 0 docs/lib/content/using-npm/package-spec.md | 106 + docs/{ => lib}/content/using-npm/registry.md | 13 +- docs/{ => lib}/content/using-npm/removal.md | 0 docs/{ => lib}/content/using-npm/scope.md | 20 +- docs/{ => lib}/content/using-npm/scripts.md | 29 +- .../{ => lib}/content/using-npm/workspaces.md | 23 +- docs/lib/index.js | 175 + docs/{ => lib}/template.html | 0 docs/lib/transform-html.js | 157 + docs/package.json | 66 +- docs/test/index.js | 111 + lib/arborist-cmd.js | 17 + lib/auth/legacy.js | 92 - lib/auth/oauth.js | 8 - lib/auth/saml.js | 8 - lib/auth/sso.js | 83 - lib/base-command.js | 62 +- lib/cli.js | 109 +- lib/commands/access.js | 306 +- lib/commands/adduser.js | 63 +- lib/commands/audit.js | 387 +- lib/commands/bin.js | 18 - lib/commands/birthday.js | 11 - lib/commands/bugs.js | 30 +- lib/commands/cache.js | 27 +- lib/commands/ci.js | 63 +- lib/commands/completion.js | 40 +- lib/commands/config.js | 91 +- lib/commands/dedupe.js | 20 +- lib/commands/deprecate.js | 15 +- lib/commands/diff.js | 35 +- lib/commands/dist-tag.js | 26 +- lib/commands/docs.js | 44 +- lib/commands/doctor.js | 279 +- lib/commands/edit.js | 37 +- lib/commands/exec.js | 64 +- lib/commands/explain.js | 7 +- lib/commands/explore.js | 2 +- lib/commands/find-dupes.js | 3 +- lib/commands/fund.js | 6 +- lib/commands/get.js | 1 + lib/commands/help-search.js | 13 +- lib/commands/help.js | 34 +- lib/commands/hook.js | 17 +- lib/commands/init.js | 82 +- lib/commands/install.js | 40 +- lib/commands/link.js | 20 +- lib/commands/login.js | 53 + lib/commands/logout.js | 3 +- lib/commands/ls.js | 75 +- lib/commands/org.js | 140 +- lib/commands/outdated.js | 24 +- lib/commands/owner.js | 296 +- lib/commands/pack.js | 9 +- lib/commands/ping.js | 3 +- lib/commands/pkg.js | 4 +- lib/commands/prefix.js | 1 + lib/commands/profile.js | 16 +- lib/commands/prune.js | 12 +- lib/commands/publish.js | 90 +- lib/commands/query.js | 107 + lib/commands/rebuild.js | 7 +- lib/commands/repo.js | 44 +- lib/commands/restart.js | 2 + lib/commands/root.js | 1 + lib/commands/run-script.js | 12 +- lib/commands/search.js | 48 +- lib/commands/set-script.js | 93 - lib/commands/set.js | 1 + lib/commands/shrinkwrap.js | 3 +- lib/commands/star.js | 33 +- lib/commands/stars.js | 1 + lib/commands/start.js | 2 + lib/commands/stop.js | 2 + lib/commands/team.js | 17 +- lib/commands/test.js | 2 + lib/commands/token.js | 52 +- lib/commands/uninstall.js | 8 +- lib/commands/unpublish.js | 104 +- lib/commands/unstar.js | 10 - lib/commands/update.js | 12 +- lib/commands/version.js | 23 + lib/commands/view.js | 81 +- lib/commands/whoami.js | 4 +- lib/exec/get-workspace-location-msg.js | 25 - lib/lifecycle-cmd.js | 1 + lib/npm.js | 431 +- lib/package-url-cmd.js | 66 + lib/search/package-filter.js | 43 - lib/utils/auth.js | 78 + lib/utils/cmd-list.js | 187 +- lib/utils/completion.sh | 1 + lib/utils/completion/installed-shallow.js | 8 +- lib/utils/config/definition.js | 2 +- lib/utils/config/definitions.js | 322 +- lib/utils/config/describe-all.js | 20 - lib/utils/config/index.js | 60 +- lib/utils/deref-command.js | 31 - lib/utils/did-you-mean.js | 4 +- lib/utils/display.js | 52 +- lib/utils/error-message.js | 19 +- lib/utils/exit-handler.js | 140 +- lib/utils/explain-dep.js | 17 +- lib/utils/explain-eresolve.js | 35 +- lib/utils/file-exists.js | 10 - lib/utils/format-bytes.js | 1 + .../format-search-stream.js} | 72 +- lib/utils/get-identity.js | 49 +- lib/utils/hosted-git-info-from-manifest.js | 14 - lib/utils/is-windows-bash.js | 3 - lib/utils/is-windows-shell.js | 3 - lib/utils/is-windows.js | 7 +- lib/utils/log-file.js | 129 +- lib/utils/npm-usage.js | 60 +- lib/utils/open-url-prompt.js | 70 + lib/utils/open-url.js | 18 +- lib/utils/otplease.js | 62 +- lib/utils/path.js | 4 - lib/utils/queryable.js | 4 +- lib/utils/read-package-name.js | 9 - lib/utils/reify-output.js | 6 +- lib/utils/replace-info.js | 48 +- lib/utils/split-package-names.js | 25 - lib/utils/tar.js | 8 +- lib/utils/timers.js | 67 +- lib/utils/unsupported.js | 39 - lib/utils/update-notifier.js | 94 +- lib/utils/usage.js | 32 - lib/utils/web-auth.js | 20 + lib/utils/with-chown-sync.js | 13 - lib/workspaces/get-workspaces.js | 16 +- lib/workspaces/update-workspaces.js | 40 + make.bat | 3 - mock-registry/.eslintrc.js | 17 + mock-registry/.gitignore | 21 + mock-registry/lib/index.js | 376 + mock-registry/package.json | 55 + mock-registry/test/index.js | 8 + netlify.toml | 4 - node_modules/.gitignore | 712 +- node_modules/@colors/colors/LICENSE | 26 + .../@colors/colors/examples/normal-usage.js | 83 + .../@colors/colors/examples/safe-string.js | 80 + node_modules/@colors/colors/index.d.ts | 136 + node_modules/@colors/colors/lib/colors.js | 211 + .../@colors/colors/lib/custom/trap.js | 46 + .../@colors/colors/lib/custom/zalgo.js | 110 + .../colors/lib/extendStringPrototype.js | 110 + node_modules/@colors/colors/lib/index.js | 13 + .../@colors/colors/lib/maps/america.js | 10 + .../@colors/colors/lib/maps/rainbow.js | 12 + .../@colors/colors/lib/maps/random.js | 11 + node_modules/@colors/colors/lib/maps/zebra.js | 5 + node_modules/@colors/colors/lib/styles.js | 95 + .../@colors/colors/lib/system/has-flag.js | 35 + .../colors/lib/system/supports-colors.js | 151 + node_modules/@colors/colors/package.json | 45 + node_modules/@colors/colors/safe.d.ts | 48 + node_modules/@colors/colors/safe.js | 10 + .../@colors/colors/themes/generic-logging.js | 12 + node_modules/@gar/promisify/index.js | 36 - node_modules/@gar/promisify/package.json | 32 - node_modules/@npmcli/ci-detect/lib/index.js | 51 - node_modules/@npmcli/ci-detect/package.json | 41 - node_modules/@npmcli/config | 1 + node_modules/@npmcli/config/lib/proc-log.js | 4 - node_modules/@npmcli/config/package.json | 51 - .../disparity-colors/{ => lib}/index.js | 6 +- .../@npmcli/disparity-colors/package.json | 42 +- .../fs/lib/common/file-url-to-path/index.js | 17 - .../lib/common/file-url-to-path/polyfill.js | 121 - .../@npmcli/fs/lib/common/get-options.js | 20 - node_modules/@npmcli/fs/lib/common/node.js | 9 - node_modules/@npmcli/fs/lib/common/owner.js | 92 - node_modules/@npmcli/fs/lib/copy-file.js | 22 - node_modules/@npmcli/fs/lib/cp/LICENSE | 15 - node_modules/@npmcli/fs/lib/cp/index.js | 22 - node_modules/@npmcli/fs/lib/cp/polyfill.js | 428 - node_modules/@npmcli/fs/lib/errors.js | 129 - node_modules/@npmcli/fs/lib/fs.js | 8 - node_modules/@npmcli/fs/lib/index.js | 10 - node_modules/@npmcli/fs/lib/mkdir/index.js | 32 - node_modules/@npmcli/fs/lib/mkdir/polyfill.js | 81 - node_modules/@npmcli/fs/lib/mkdtemp.js | 28 - node_modules/@npmcli/fs/lib/rm/index.js | 22 - node_modules/@npmcli/fs/lib/rm/polyfill.js | 239 - node_modules/@npmcli/fs/lib/with-temp-dir.js | 39 - node_modules/@npmcli/fs/lib/write-file.js | 19 - node_modules/@npmcli/fs/package.json | 41 - node_modules/@npmcli/git/lib/clone.js | 32 +- node_modules/@npmcli/git/lib/errors.js | 2 +- node_modules/@npmcli/git/lib/index.js | 2 +- node_modules/@npmcli/git/lib/lines-to-revs.js | 20 +- node_modules/@npmcli/git/lib/make-error.js | 4 +- node_modules/@npmcli/git/lib/opts.js | 4 +- node_modules/@npmcli/git/lib/proc-log.js | 21 - node_modules/@npmcli/git/lib/revs.js | 2 +- node_modules/@npmcli/git/lib/spawn.js | 21 +- node_modules/@npmcli/git/lib/which.js | 4 +- node_modules/@npmcli/git/package.json | 50 +- .../{ => lib}/index.js | 85 +- .../installed-package-contents/package.json | 49 +- .../@npmcli/map-workspaces/lib/index.js | 61 +- .../@npmcli/map-workspaces/package.json | 50 +- .../metavuln-calculator/lib/advisory.js | 142 +- .../@npmcli/metavuln-calculator/lib/hash.js | 4 +- .../@npmcli/metavuln-calculator/lib/index.js | 14 +- .../@npmcli/metavuln-calculator/package.json | 50 +- node_modules/@npmcli/node-gyp/lib/index.js | 6 +- node_modules/@npmcli/node-gyp/package.json | 39 +- .../@npmcli/package-json/lib/index.js | 9 +- .../package-json/lib/update-dependencies.js | 9 +- .../package-json/lib/update-scripts.js | 3 +- .../package-json/lib/update-workspaces.js | 3 +- .../@npmcli/package-json/package.json | 41 +- node_modules/@npmcli/promise-spawn/index.js | 75 - .../@npmcli/promise-spawn/lib/escape.js | 68 + .../@npmcli/promise-spawn/lib/index.js | 195 + .../@npmcli/promise-spawn/package.json | 40 +- .../@npmcli/{fs/LICENSE.md => query/LICENSE} | 0 node_modules/@npmcli/query/lib/index.js | 189 + node_modules/@npmcli/query/package.json | 62 + .../@npmcli/run-script/lib/make-spawn-args.js | 34 +- .../@npmcli/run-script/lib/package-envs.js | 7 +- .../@npmcli/run-script/lib/run-script-pkg.js | 56 +- .../@npmcli/run-script/lib/run-script.js | 5 +- .../@npmcli/run-script/lib/set-path.js | 17 +- .../@npmcli/run-script/lib/signal-manager.js | 7 +- .../run-script/lib/validate-options.js | 24 +- node_modules/@npmcli/run-script/package.json | 58 +- .../{debuglog => abort-controller}/LICENSE | 22 +- node_modules/abort-controller/browser.js | 13 + node_modules/abort-controller/browser.mjs | 11 + .../dist/abort-controller.d.ts | 43 + .../abort-controller/dist/abort-controller.js | 127 + .../dist/abort-controller.js.map | 1 + .../dist/abort-controller.mjs | 118 + .../dist/abort-controller.mjs.map | 1 + .../dist/abort-controller.umd.js | 5 + .../dist/abort-controller.umd.js.map | 1 + node_modules/abort-controller/package.json | 97 + node_modules/abort-controller/polyfill.js | 21 + node_modules/abort-controller/polyfill.mjs | 19 + node_modules/agentkeepalive/History.md | 6 + node_modules/agentkeepalive/index.d.ts | 10 +- node_modules/agentkeepalive/package.json | 2 +- node_modules/ansicolors/LICENSE | 23 - node_modules/ansicolors/ansicolors.js | 65 - node_modules/ansicolors/package.json | 23 - node_modules/ansicolors/test/ansicolors.js | 71 - node_modules/bin-links/lib/check-bin.js | 14 +- node_modules/bin-links/lib/fix-bin.js | 20 +- node_modules/bin-links/lib/get-paths.js | 19 +- node_modules/bin-links/lib/link-gently.js | 26 +- node_modules/bin-links/lib/link-mans.js | 2 +- node_modules/bin-links/lib/shim-bin.js | 9 +- node_modules/bin-links/package.json | 45 +- node_modules/cli-columns/{LICENSE => license} | 0 .../node_modules/ansi-regex/index.d.ts | 37 - .../node_modules/ansi-regex/index.js | 10 - .../node_modules/ansi-regex/license | 9 - .../node_modules/ansi-regex/package.json | 55 - .../is-fullwidth-code-point/index.d.ts | 17 - .../is-fullwidth-code-point/index.js | 50 - .../is-fullwidth-code-point/license | 9 - .../is-fullwidth-code-point/package.json | 42 - .../node_modules/string-width/index.d.ts | 29 - .../node_modules/string-width/index.js | 47 - .../node_modules/string-width/license | 9 - .../node_modules/string-width/package.json | 56 - .../node_modules/strip-ansi/index.d.ts | 17 - .../node_modules/strip-ansi/index.js | 4 - .../node_modules/strip-ansi/license | 9 - .../node_modules/strip-ansi/package.json | 54 - node_modules/cmd-shim/{ => lib}/index.js | 39 +- node_modules/cmd-shim/lib/to-batch-syntax.js | 88 +- node_modules/cmd-shim/package.json | 36 +- node_modules/debuglog/debuglog.js | 22 - node_modules/debuglog/package.json | 21 - node_modules/dezalgo/LICENSE | 15 - node_modules/dezalgo/dezalgo.js | 22 - node_modules/dezalgo/package.json | 42 - node_modules/dezalgo/test/basic.js | 29 - node_modules/env-paths/readme.md | 115 - node_modules/event-target-shim/LICENSE | 22 + .../dist/event-target-shim.js | 871 + .../dist/event-target-shim.js.map | 1 + .../dist/event-target-shim.mjs | 862 + .../dist/event-target-shim.mjs.map | 1 + .../dist/event-target-shim.umd.js | 6 + .../dist/event-target-shim.umd.js.map | 1 + node_modules/event-target-shim/index.d.ts | 399 + node_modules/event-target-shim/package.json | 82 + node_modules/fastest-levenshtein/bench.js | 96 + node_modules/fastest-levenshtein/esm/mod.d.ts | 4 + .../fastest-levenshtein/esm/mod.d.ts.map | 1 + node_modules/fastest-levenshtein/esm/mod.js | 138 + node_modules/fastest-levenshtein/index.d.ts | 2 - node_modules/fastest-levenshtein/index.js | 147 - node_modules/fastest-levenshtein/mod.d.ts | 3 + node_modules/fastest-levenshtein/mod.js | 142 + node_modules/fastest-levenshtein/package.json | 43 +- node_modules/fastest-levenshtein/test.js | 113 +- node_modules/fastest-levenshtein/test.ts | 67 + .../node_modules/minipass}/LICENSE | 2 +- .../node_modules/minipass/index.d.ts | 155 + .../node_modules/minipass/index.js | 649 + .../node_modules/minipass/package.json | 56 + node_modules/ignore-walk/{ => lib}/index.js | 26 +- node_modules/ignore-walk/package.json | 49 +- .../init-package-json/lib/default-input.js | 34 +- .../lib/init-package-json.js | 54 +- node_modules/init-package-json/package.json | 44 +- node_modules/just-diff-apply/index.d.ts | 17 + node_modules/just-diff-apply/index.js | 78 +- node_modules/just-diff-apply/index.mjs | 90 +- node_modules/just-diff-apply/index.tests.ts | 108 + node_modules/just-diff-apply/package.json | 9 +- node_modules/just-diff/index.js | 11 +- node_modules/just-diff/index.mjs | 8 +- node_modules/just-diff/package.json | 8 +- node_modules/make-fetch-happen/lib/agent.js | 11 +- .../make-fetch-happen/lib/cache/entry.js | 138 +- .../make-fetch-happen/lib/cache/index.js | 4 +- node_modules/make-fetch-happen/lib/dns.js | 49 + node_modules/make-fetch-happen/lib/index.js | 7 +- node_modules/make-fetch-happen/lib/options.js | 4 + .../make-fetch-happen/lib/pipeline.js | 41 + node_modules/make-fetch-happen/lib/remote.js | 19 +- .../node_modules/lru-cache/LICENSE | 15 - .../node_modules/lru-cache/index.js | 581 - .../node_modules/lru-cache/package.json | 34 - node_modules/make-fetch-happen/package.json | 52 +- node_modules/mkdirp-infer-owner/LICENSE | 15 - node_modules/mkdirp-infer-owner/index.js | 26 - node_modules/mkdirp-infer-owner/package.json | 36 - node_modules/npm-audit-report/lib/colors.js | 2 +- .../npm-audit-report/lib/exit-code.js | 2 +- node_modules/npm-audit-report/lib/index.js | 12 +- .../npm-audit-report/lib/reporters/detail.js | 22 +- .../npm-audit-report/lib/reporters/install.js | 10 +- node_modules/npm-audit-report/package.json | 35 +- .../npm-install-checks/{ => lib}/index.js | 13 +- node_modules/npm-install-checks/package.json | 35 +- .../npm-normalize-package-bin/LICENSE | 15 - .../npm-normalize-package-bin/index.js | 60 - .../package-lock.json | 3529 --- .../npm-normalize-package-bin/package.json | 21 - .../npm-normalize-package-bin/test/array.js | 37 - .../npm-normalize-package-bin/test/nobin.js | 35 - .../npm-normalize-package-bin/test/object.js | 141 - .../npm-normalize-package-bin/test/string.js | 37 - node_modules/npm-packlist/bin/index.js | 25 - node_modules/npm-packlist/index.js | 481 - node_modules/npm-packlist/lib/index.js | 457 + node_modules/npm-packlist/package.json | 51 +- .../npm-pick-manifest/{ => lib}/index.js | 14 +- node_modules/npm-pick-manifest/package.json | 53 +- node_modules/npm-profile/lib/index.js | 42 +- node_modules/npm-profile/package.json | 39 +- node_modules/npm-registry-fetch/lib/auth.js | 37 +- .../npm-registry-fetch/lib/check-response.js | 32 +- .../npm-registry-fetch/lib/clean-url.js | 26 + .../npm-registry-fetch/lib/default-opts.js | 1 - node_modules/npm-registry-fetch/lib/errors.js | 2 +- node_modules/npm-registry-fetch/lib/index.js | 14 +- .../npm-registry-fetch/lib/silentlog.js | 14 - node_modules/npm-registry-fetch/package.json | 52 +- node_modules/pacote/lib/bin.js | 41 +- node_modules/pacote/lib/dir.js | 35 +- node_modules/pacote/lib/fetcher.js | 203 +- node_modules/pacote/lib/file.js | 41 +- node_modules/pacote/lib/git.js | 111 +- node_modules/pacote/lib/registry.js | 224 +- node_modules/pacote/lib/remote.js | 33 +- node_modules/pacote/lib/util/cache-dir.js | 2 +- .../pacote/lib/util/is-package-bin.js | 7 +- node_modules/pacote/lib/util/npm.js | 3 +- node_modules/pacote/lib/util/proc-log.js | 21 - .../pacote/lib/util/tar-create-options.js | 5 +- .../pacote/lib/util/trailing-slashes.js | 10 + node_modules/pacote/package.json | 73 +- node_modules/parse-conflict-json/package.json | 41 +- node_modules/proc-log/LICENSE | 15 - node_modules/proc-log/index.js | 22 - node_modules/proc-log/package.json | 28 - node_modules/process/LICENSE | 22 + node_modules/process/browser.js | 184 + node_modules/process/index.js | 2 + node_modules/process/package.json | 27 + node_modules/process/test.js | 199 + .../promise-all-reject-late/package-lock.json | 3447 --- node_modules/read-cmd-shim/{ => lib}/index.js | 18 +- node_modules/read-cmd-shim/package.json | 42 +- .../read-package-json-fast/{ => lib}/index.js | 51 +- .../read-package-json-fast/package.json | 43 +- node_modules/readdir-scoped-modules/LICENSE | 15 - .../readdir-scoped-modules/package.json | 34 - .../readdir-scoped-modules/readdir.js | 121 - .../socks-proxy-agent/dist/agent.d.ts | 22 - node_modules/socks-proxy-agent/dist/agent.js | 181 - .../socks-proxy-agent/dist/agent.js.map | 1 - .../socks-proxy-agent/dist/index.d.ts | 46 +- node_modules/socks-proxy-agent/dist/index.js | 199 +- .../socks-proxy-agent/dist/index.js.map | 2 +- node_modules/socks-proxy-agent/package.json | 191 +- .../socks/build/client/socksclient.js | 23 +- .../socks/build/client/socksclient.js.map | 2 +- .../socks/build/common/receivebuffer.js.map | 2 +- node_modules/socks/build/common/util.js | 1 - node_modules/socks/build/common/util.js.map | 2 +- node_modules/socks/build/index.js | 6 +- node_modules/socks/build/index.js.map | 2 +- node_modules/socks/package.json | 53 +- .../socks/typings/client/socksclient.d.ts | 10 +- .../socks/typings/common/constants.d.ts | 2 + node_modules/socks/typings/common/util.d.ts | 2 +- node_modules/stringify-package/LICENSE | 13 - node_modules/stringify-package/index.js | 18 - node_modules/stringify-package/package.json | 38 - node_modules/treeverse/index.js | 4 - node_modules/treeverse/lib/breadth.js | 27 +- node_modules/treeverse/lib/depth-descent.js | 27 +- node_modules/treeverse/lib/depth.js | 16 +- node_modules/treeverse/lib/index.js | 4 + node_modules/treeverse/package.json | 38 +- node_modules/unique-slug/{ => lib}/index.js | 4 +- node_modules/unique-slug/package.json | 38 +- node_modules/unique-slug/test/index.js | 13 - package-lock.json | 20477 ++++++---------- package.json | 230 +- release-please-config.json | 78 + scripts/bundle-and-gitignore-deps.js | 262 +- scripts/changelog.js | 107 - scripts/clean-old.sh | 165 - scripts/config-doc-command.js | 55 - scripts/config-doc.js | 54 - scripts/create-node-pr.js | 284 + scripts/dependency-graph.js | 189 + scripts/docs-build.js | 45 - scripts/git-dirty.js | 20 +- scripts/install.sh | 175 - scripts/maketest | 85 - scripts/npm-cli-repos.txt | 84 + scripts/pr | 167 - scripts/publish-tag.js | 3 - scripts/publish.js | 110 + scripts/release.sh | 43 - scripts/relocate.sh | 26 - scripts/remove-files.js | 11 + scripts/resetdeps.js | 19 + scripts/resetdeps.sh | 8 - scripts/template-oss/_step-deps.yml | 2 + scripts/template-oss/_step-test.yml | 4 + .../template-oss/branch-specific-config.js | 5 + scripts/template-oss/ci-npmcli-docs.yml | 22 + scripts/template-oss/ci-release.yml | 21 + scripts/template-oss/ci.yml | 13 + scripts/template-oss/create-node-pr.yml | 32 + scripts/template-oss/index.js | 3 + scripts/template-oss/root.js | 46 + scripts/update-authors.js | 27 + scripts/update-authors.sh | 9 - scripts/util.js | 204 + smoke-tests/.eslintrc.js | 17 + smoke-tests/.gitignore | 21 + smoke-tests/content/abbrev.json | 449 - smoke-tests/content/abbrev.min.json | 89 - smoke-tests/content/abbrev/-/abbrev-1.0.4.tgz | Bin 2295 -> 0 bytes smoke-tests/content/abbrev/-/abbrev-1.1.1.tgz | Bin 2301 -> 0 bytes .../content/promise-all-reject-late.json | 138 - .../content/promise-all-reject-late.min.json | 44 - .../-/promise-all-reject-late-1.0.1.tgz | Bin 30838 -> 0 bytes smoke-tests/index.js | 351 - smoke-tests/package.json | 54 + smoke-tests/server.js | 282 - .../tap-snapshots/test/index.js.test.cjs | 481 + smoke-tests/test/fixtures/setup.js | 217 + smoke-tests/test/index.js | 335 + smoke-tests/test/workspace-ua.js | 36 + tap-snapshots/smoke-tests/index.js.test.cjs | 784 - .../test/lib/commands/audit.js.test.cjs | 353 + .../test/lib/commands/cache.js.test.cjs | 63 + .../test/lib/commands/ci.js.test.cjs | 13 - .../test/lib/commands/completion.js.test.cjs | 161 +- .../test/lib/commands/config.js.test.cjs | 36 +- .../test/lib/commands/dist-tag.js.test.cjs | 2 +- .../test/lib/commands/doctor.js.test.cjs | 1647 ++ .../test/lib/commands/init.js.test.cjs | 54 +- .../test/lib/commands/link.js.test.cjs | 10 + .../test/lib/commands/ls.js.test.cjs | 79 +- .../test/lib/commands/owner.js.test.cjs | 20 - .../test/lib/commands/pack.js.test.cjs | 30 + .../test/lib/commands/profile.js.test.cjs | 82 +- .../test/lib/commands/publish.js.test.cjs | 458 +- .../test/lib/commands/query.js.test.cjs | 243 + .../test/lib/commands/search.js.test.cjs | 130 +- .../test/lib/commands/shrinkwrap.js.test.cjs | 62 +- .../test/lib/commands/unpublish.js.test.cjs | 14 - .../test/lib/commands/version.js.test.cjs | 78 + .../test/lib/commands/view.js.test.cjs | 441 +- tap-snapshots/test/lib/docs.js.test.cjs | 4278 ++++ .../test/lib/load-all-commands.js.test.cjs | 1127 - .../test/lib/utils/cmd-list.js.test.cjs | 210 - .../lib/utils/config/definitions.js.test.cjs | 1924 -- .../lib/utils/config/describe-all.js.test.cjs | 1914 -- .../test/lib/utils/config/index.js.test.cjs | 136 - .../test/lib/utils/error-message.js.test.cjs | 106 +- .../test/lib/utils/exit-handler.js.test.cjs | 58 +- .../test/lib/utils/explain-dep.js.test.cjs | 22 + .../lib/utils/explain-eresolve.js.test.cjs | 136 +- .../test/lib/utils/log-file.js.test.cjs | 118 +- .../test/lib/utils/npm-usage.js.test.cjs | 1165 - .../lib/utils/open-url-prompt.js.test.cjs | 25 + tap-snapshots/test/lib/utils/tar.js.test.cjs | 46 +- test/bin/windows-shims.js | 2 - test/coverage-map.js | 20 - test/fixtures/clean-snapshot.js | 2 +- test/fixtures/libnpmsearch-stream-result.js | 27 +- test/fixtures/mock-logs.js | 78 +- test/fixtures/mock-npm.js | 154 +- test/fixtures/sandbox.js | 70 +- test/fixtures/tnock.js | 17 + test/fixtures/tspawk.js | 16 + test/index.js | 12 +- test/lib/arborist-cmd.js | 16 +- test/lib/auth/legacy.js | 429 - test/lib/auth/oauth.js | 28 - test/lib/auth/saml.js | 28 - test/lib/auth/sso.js | 264 - test/lib/cli.js | 174 +- test/lib/commands/access.js | 706 +- test/lib/commands/adduser.js | 349 +- test/lib/commands/audit.js | 1780 +- test/lib/commands/bin.js | 76 - test/lib/commands/birthday.js | 15 - test/lib/commands/bugs.js | 2 +- test/lib/commands/cache.js | 559 +- test/lib/commands/ci.js | 443 +- test/lib/commands/completion.js | 21 +- test/lib/commands/config.js | 289 +- test/lib/commands/dedupe.js | 106 +- test/lib/commands/deprecate.js | 188 +- test/lib/commands/diff.js | 34 +- test/lib/commands/dist-tag.js | 12 +- test/lib/commands/docs.js | 13 +- test/lib/commands/doctor.js | 1634 +- test/lib/commands/edit.js | 197 +- test/lib/commands/exec.js | 1338 +- test/lib/commands/explain.js | 9 + test/lib/commands/explore.js | 4 +- test/lib/commands/find-dupes.js | 84 +- test/lib/commands/help-search.js | 4 +- test/lib/commands/help.js | 39 + test/lib/commands/hook.js | 104 +- test/lib/commands/init.js | 83 +- test/lib/commands/install-ci-test.js | 9 + test/lib/commands/install-test.js | 9 + test/lib/commands/install.js | 550 +- test/lib/commands/link.js | 72 +- test/lib/commands/login.js | 143 + test/lib/commands/logout.js | 9 +- test/lib/commands/ls.js | 616 +- test/lib/commands/org.js | 42 +- test/lib/commands/outdated.js | 37 +- test/lib/commands/owner.js | 1175 +- test/lib/commands/pack.js | 32 +- test/lib/commands/ping.js | 161 +- test/lib/commands/profile.js | 6 - test/lib/commands/publish.js | 1490 +- test/lib/commands/query.js | 199 + test/lib/commands/repo.js | 14 +- test/lib/commands/restart.js | 26 +- test/lib/commands/run-script.js | 43 +- test/lib/commands/search.js | 307 +- test/lib/commands/set-script.js | 188 - test/lib/commands/set.js | 4 + test/lib/commands/shrinkwrap.js | 24 +- test/lib/commands/star.js | 165 +- test/lib/commands/stars.js | 3 +- test/lib/commands/start.js | 27 +- test/lib/commands/stop.js | 26 +- test/lib/commands/team.js | 23 +- test/lib/commands/test.js | 26 +- test/lib/commands/token.js | 5 +- test/lib/commands/unpublish.js | 761 +- test/lib/commands/unstar.js | 83 +- test/lib/commands/update.js | 11 +- test/lib/commands/version.js | 119 +- test/lib/commands/view.js | 499 +- test/lib/commands/whoami.js | 92 +- test/lib/docs.js | 98 + test/lib/lifecycle-cmd.js | 3 + test/lib/load-all-commands.js | 10 +- test/lib/load-all.js | 31 - test/lib/npm.js | 517 +- test/lib/utils/cmd-list.js | 4 - test/lib/utils/config/definitions.js | 357 +- test/lib/utils/config/describe-all.js | 6 - test/lib/utils/config/flatten.js | 38 - test/lib/utils/config/index.js | 71 +- test/lib/utils/deref-command.js | 9 - test/lib/utils/display.js | 2 +- test/lib/utils/error-message.js | 35 +- test/lib/utils/exit-handler.js | 246 +- test/lib/utils/explain-dep.js | 17 + test/lib/utils/explain-eresolve.js | 37 +- test/lib/utils/file-exists.js | 30 - test/lib/utils/get-identity.js | 103 - .../utils/hosted-git-info-from-manifest.js | 21 - test/lib/utils/is-windows-bash.js | 30 - test/lib/utils/is-windows-shell.js | 8 - test/lib/utils/is-windows.js | 8 - test/lib/utils/log-file.js | 31 +- test/lib/utils/npm-usage.js | 60 - test/lib/utils/open-url-prompt.js | 184 + test/lib/utils/open-url.js | 13 +- test/lib/utils/otplease.js | 70 +- test/lib/utils/path.js | 12 - test/lib/utils/ping.js | 35 - test/lib/utils/read-package-name.js | 33 - test/lib/utils/reify-output.js | 11 +- test/lib/utils/replace-info.js | 40 +- test/lib/utils/split-package-names.js | 18 - test/lib/utils/tar.js | 41 +- test/lib/utils/timers.js | 42 +- test/lib/utils/unsupported.js | 102 - test/lib/utils/update-notifier.js | 14 +- test/lib/utils/web-auth.js | 32 + test/lib/workspaces/get-workspaces.js | 183 +- workspaces/arborist/.eslintrc.js | 5 +- workspaces/arborist/.eslintrc.local.json | 7 +- workspaces/arborist/.gitignore | 28 +- workspaces/arborist/.npmrc | 3 - workspaces/arborist/CHANGELOG.md | 371 +- workspaces/arborist/README.md | 16 +- workspaces/arborist/SECURITY.md | 3 - workspaces/arborist/bin/actual.js | 36 +- workspaces/arborist/bin/audit.js | 49 +- workspaces/arborist/bin/funding.js | 66 +- workspaces/arborist/bin/ideal.js | 29 +- workspaces/arborist/bin/index.js | 156 +- workspaces/arborist/bin/lib/logging.js | 87 +- workspaces/arborist/bin/lib/options.js | 172 +- workspaces/arborist/bin/lib/print-tree.js | 5 +- workspaces/arborist/bin/lib/timers.js | 32 +- workspaces/arborist/bin/license.js | 78 +- workspaces/arborist/bin/prune.js | 43 +- workspaces/arborist/bin/reify.js | 43 +- workspaces/arborist/bin/shrinkwrap.js | 15 +- workspaces/arborist/bin/virtual.js | 26 +- workspaces/arborist/docs/reify.md | 2 +- workspaces/arborist/lib/add-rm-pkg-deps.js | 139 +- .../arborist/lib/arborist/build-ideal-tree.js | 319 +- workspaces/arborist/lib/arborist/index.js | 11 +- .../arborist/lib/arborist/load-actual.js | 439 +- .../arborist/lib/arborist/load-virtual.js | 10 +- workspaces/arborist/lib/arborist/rebuild.js | 113 +- workspaces/arborist/lib/arborist/reify.js | 232 +- workspaces/arborist/lib/audit-report.js | 90 +- workspaces/arborist/lib/consistent-resolve.js | 28 +- workspaces/arborist/lib/dep-valid.js | 18 +- workspaces/arborist/lib/edge.js | 20 +- workspaces/arborist/lib/from-path.js | 19 +- .../arborist/lib/get-workspace-nodes.js | 5 +- workspaces/arborist/lib/link.js | 23 +- workspaces/arborist/lib/node.js | 40 +- workspaces/arborist/lib/override-resolves.js | 11 + workspaces/arborist/lib/override-set.js | 11 +- workspaces/arborist/lib/place-dep.js | 229 +- workspaces/arborist/lib/query-selector-all.js | 850 + workspaces/arborist/lib/realpath.js | 5 +- workspaces/arborist/lib/retire-path.js | 2 +- workspaces/arborist/lib/shrinkwrap.js | 180 +- workspaces/arborist/lib/signal-handling.js | 8 +- workspaces/arborist/lib/spec-from-lock.js | 6 +- workspaces/arborist/lib/tracker.js | 31 +- workspaces/arborist/lib/version-from-tgz.js | 2 +- workspaces/arborist/lib/vuln.js | 3 + workspaces/arborist/lib/yarn-lock.js | 54 +- workspaces/arborist/package.json | 95 +- workspaces/arborist/scripts/benchmark.js | 26 +- .../arborist/scripts/benchmark/load-actual.js | 12 +- .../arborist/scripts/benchmark/reify.js | 28 +- .../arborist/build-ideal-tree.js.test.cjs | 278 +- .../test/arborist/load-actual.js.test.cjs | 35 +- .../test/arborist/pruner.js.test.cjs | 15 +- .../test/arborist/rebuild.js.test.cjs | 15 +- .../test/arborist/reify.js.test.cjs | 774 +- .../test/audit-report.js.test.cjs | 279 + .../tap-snapshots/test/edge.js.test.cjs | 189 + .../tap-snapshots/test/link.js.test.cjs | 8 + .../tap-snapshots/test/node.js.test.cjs | 498 +- .../tap-snapshots/test/place-dep.js.test.cjs | 10 +- .../tap-snapshots/test/printable.js.test.cjs | 16 +- .../tap-snapshots/test/shrinkwrap.js.test.cjs | 8918 ++----- .../test/spec-from-lock.js.test.cjs | 15 +- .../tap-snapshots/test/yarn-lock.js.test.cjs | 4971 ++-- workspaces/arborist/test/add-rm-pkg-deps.js | 25 +- .../test/arborist/build-ideal-tree.js | 65 +- workspaces/arborist/test/arborist/index.js | 19 +- .../arborist/test/arborist/load-actual.js | 102 +- workspaces/arborist/test/arborist/rebuild.js | 57 +- workspaces/arborist/test/arborist/reify.js | 719 +- .../arborist/test/arborist/validate-path.js | 2 +- workspaces/arborist/test/audit-report.js | 7 +- .../arborist/test/consistent-resolve.js | 16 +- workspaces/arborist/test/dep-valid.js | 72 +- workspaces/arborist/test/diff.js | 3 +- workspaces/arborist/test/edge.js | 316 +- workspaces/arborist/test/fixtures/index.js | 3 +- .../link-dep-lifecycle-scripts/a/package.json | 3 +- .../old-lock-with-link/link-dep/package.json | 4 + .../old-lock-with-link/package-lock.json | 11 + .../fixtures/old-lock-with-link/package.json | 7 + .../registry-mocks/fetch-lock-contents.js | 3 +- .../reify-cases/link-dep-lifecycle-scripts.js | 3 +- .../reify-cases/workspaces-link-bin.js | 5 +- .../test/fixtures/tnock.js | 2 + .../packages/b/create-file.js | 1 + .../workspaces-link-bin/packages/b/file.js | 0 .../packages/b/package.json | 3 + .../test/fixtures/yarn-stuff/yarn.lock | 3 + workspaces/arborist/test/from-path.js | 29 +- workspaces/arborist/test/gather-dep-set.js | 3 +- .../arborist/test/get-workspace-nodes.js | 10 +- workspaces/arborist/test/inventory.js | 6 +- workspaces/arborist/test/link.js | 17 - workspaces/arborist/test/node.js | 147 +- workspaces/arborist/test/override-set.js | 18 +- workspaces/arborist/test/place-dep.js | 13 +- workspaces/arborist/test/printable.js | 4 +- .../arborist/test/query-selector-all.js | 964 + workspaces/arborist/test/shrinkwrap.js | 518 +- workspaces/arborist/test/tracker.js | 43 +- workspaces/arborist/test/yarn-lock.js | 18 +- workspaces/config/.eslintrc.js | 17 + workspaces/config/.gitignore | 21 + workspaces/config/CHANGELOG.md | 145 + .../ci-detect => workspaces/config}/LICENSE | 0 workspaces/config/README.md | 260 + .../config/lib/env-replace.js | 6 +- workspaces/config/lib/errors.js | 22 + .../config/lib/index.js | 276 +- .../config/lib/nerf-dart.js | 0 .../config/lib/parse-field.js | 2 +- .../config/lib/set-envs.js | 0 .../config/lib/type-defs.js | 0 .../config/lib/type-description.js | 0 .../config/lib/umask.js | 0 workspaces/config/map.js | 1 + workspaces/config/package.json | 55 + workspaces/config/scripts/example.js | 43 + .../tap-snapshots/test/index.js.test.cjs | 240 + .../test/type-description.js.test.cjs | 449 + workspaces/config/test/env-replace.js | 13 + workspaces/config/test/fixtures/cafile | 32 + workspaces/config/test/fixtures/defaults.js | 143 + .../config/test/fixtures/definitions.js | 2609 ++ .../config/test/fixtures}/flatten.js | 0 workspaces/config/test/fixtures/shorthands.js | 41 + workspaces/config/test/fixtures/types.js | 151 + workspaces/config/test/index.js | 1295 + workspaces/config/test/nerf-dart.js | 44 + workspaces/config/test/parse-field.js | 36 + workspaces/config/test/set-envs.js | 212 + workspaces/config/test/type-defs.js | 22 + workspaces/config/test/type-description.js | 14 + workspaces/libnpmaccess/.eslintrc.js | 5 +- workspaces/libnpmaccess/.gitignore | 28 +- workspaces/libnpmaccess/.npmrc | 3 - workspaces/libnpmaccess/CHANGELOG.md | 82 +- workspaces/libnpmaccess/README.md | 238 +- workspaces/libnpmaccess/SECURITY.md | 3 - workspaces/libnpmaccess/lib/index.js | 300 +- workspaces/libnpmaccess/package.json | 51 +- workspaces/libnpmaccess/test/index.js | 558 +- workspaces/libnpmdiff/.eslintrc.js | 5 +- workspaces/libnpmdiff/.gitignore | 28 +- workspaces/libnpmdiff/.npmrc | 3 - workspaces/libnpmdiff/CHANGELOG.md | 138 +- workspaces/libnpmdiff/README.md | 4 +- workspaces/libnpmdiff/SECURITY.md | 3 - .../libnpmdiff/lib/should-print-patch.js | 2 +- workspaces/libnpmdiff/lib/tarball.js | 6 +- workspaces/libnpmdiff/package.json | 60 +- workspaces/libnpmdiff/test/index.js | 11 +- workspaces/libnpmdiff/test/tarball.js | 33 +- workspaces/libnpmexec/.editorconfig | 3 - workspaces/libnpmexec/.eslintrc.js | 5 +- workspaces/libnpmexec/.gitignore | 28 +- workspaces/libnpmexec/.npmrc | 3 - workspaces/libnpmexec/CHANGELOG.md | 250 +- workspaces/libnpmexec/CONTRIBUTING.md | 68 - workspaces/libnpmexec/README.md | 4 +- workspaces/libnpmexec/SECURITY.md | 3 - .../libnpmexec/lib/cache-install-dir.js | 20 - workspaces/libnpmexec/lib/file-exists.js | 22 +- workspaces/libnpmexec/lib/index.js | 289 +- workspaces/libnpmexec/lib/manifest-missing.js | 19 - workspaces/libnpmexec/lib/run-script.js | 31 +- workspaces/libnpmexec/package.json | 66 +- .../libnpmexec/test/cache-install-dir.js | 12 - workspaces/libnpmexec/test/fixtures/setup.js | 256 + workspaces/libnpmexec/test/index.js | 745 +- workspaces/libnpmexec/test/local.js | 370 + .../libnpmexec/test/manifest-missing.js | 32 - workspaces/libnpmexec/test/prompt.js | 384 + workspaces/libnpmexec/test/registry.js | 166 + .../content/ruyadorno/create-index.json | 81 - .../content/ruyadorno/create-index.min.json | 26 - .../create-index/-/create-index-1.0.0.tgz | Bin 490 -> 0 bytes .../content/ruyadorno/create-test.json | 81 - .../content/ruyadorno/create-test.min.json | 26 - .../create-test/-/create-test-1.0.0.tgz | Bin 487 -> 0 bytes workspaces/libnpmexec/test/registry/server.js | 280 - workspaces/libnpmexec/test/run-script.js | 82 +- workspaces/libnpmfund/.editorconfig | 3 - workspaces/libnpmfund/.eslintrc.js | 5 +- workspaces/libnpmfund/.gitignore | 28 +- workspaces/libnpmfund/.npmrc | 3 - workspaces/libnpmfund/CHANGELOG.md | 123 +- workspaces/libnpmfund/README.md | 3 +- workspaces/libnpmfund/SECURITY.md | 3 - workspaces/libnpmfund/lib/index.js | 4 +- workspaces/libnpmfund/package.json | 46 +- .../libnpmfund/{test.js => test/index.js} | 4 +- workspaces/libnpmhook/.eslintrc.js | 5 +- workspaces/libnpmhook/.gitignore | 28 +- workspaces/libnpmhook/.npmrc | 3 - workspaces/libnpmhook/CHANGELOG.md | 68 +- workspaces/libnpmhook/README.md | 2 +- workspaces/libnpmhook/SECURITY.md | 3 - workspaces/libnpmhook/lib/index.js | 2 +- workspaces/libnpmhook/package.json | 46 +- workspaces/libnpmorg/.eslintrc.js | 5 +- workspaces/libnpmorg/.gitignore | 28 +- workspaces/libnpmorg/.npmrc | 3 - workspaces/libnpmorg/CHANGELOG.md | 64 +- workspaces/libnpmorg/README.md | 3 +- workspaces/libnpmorg/SECURITY.md | 3 - workspaces/libnpmorg/package.json | 49 +- workspaces/libnpmorg/test/index.js | 62 +- workspaces/libnpmpack/.eslintrc.js | 5 +- workspaces/libnpmpack/.gitignore | 28 +- workspaces/libnpmpack/.npmrc | 3 - workspaces/libnpmpack/CHANGELOG.md | 182 +- workspaces/libnpmpack/README.md | 3 +- workspaces/libnpmpack/SECURITY.md | 3 - workspaces/libnpmpack/lib/index.js | 14 +- workspaces/libnpmpack/package.json | 51 +- workspaces/libnpmpack/test/fixtures/tspawk.js | 13 + workspaces/libnpmpack/test/index.js | 80 +- workspaces/libnpmpublish/.eslintrc.js | 5 +- workspaces/libnpmpublish/.gitignore | 28 +- workspaces/libnpmpublish/.npmrc | 3 - workspaces/libnpmpublish/CHANGELOG.md | 162 +- workspaces/libnpmpublish/README.md | 8 +- workspaces/libnpmpublish/SECURITY.md | 3 - workspaces/libnpmpublish/lib/publish.js | 7 +- workspaces/libnpmpublish/lib/unpublish.js | 21 +- workspaces/libnpmpublish/package.json | 57 +- workspaces/libnpmpublish/test/publish.js | 62 +- workspaces/libnpmpublish/test/unpublish.js | 55 + workspaces/libnpmsearch/.eslintrc.js | 5 +- workspaces/libnpmsearch/.gitignore | 28 +- workspaces/libnpmsearch/.npmrc | 3 - workspaces/libnpmsearch/CHANGELOG.md | 67 +- workspaces/libnpmsearch/README.md | 2 +- workspaces/libnpmsearch/SECURITY.md | 3 - workspaces/libnpmsearch/package.json | 47 +- workspaces/libnpmsearch/test/index.js | 140 +- workspaces/libnpmteam/.eslintrc.js | 5 +- workspaces/libnpmteam/.github/settings.yml | 2 - .../libnpmteam/.github/workflows/ci.yml | 97 - workspaces/libnpmteam/.gitignore | 28 +- workspaces/libnpmteam/.npmrc | 3 - workspaces/libnpmteam/CHANGELOG.md | 64 +- workspaces/libnpmteam/README.md | 3 +- workspaces/libnpmteam/SECURITY.md | 3 - workspaces/libnpmteam/package.json | 47 +- workspaces/libnpmteam/test/index.js | 179 +- workspaces/libnpmversion/.eslintrc.js | 5 +- workspaces/libnpmversion/.gitignore | 28 +- workspaces/libnpmversion/.npmrc | 3 - workspaces/libnpmversion/CHANGELOG.md | 91 + workspaces/libnpmversion/README.md | 5 + workspaces/libnpmversion/SECURITY.md | 3 - workspaces/libnpmversion/lib/enforce-clean.js | 3 +- workspaces/libnpmversion/lib/index.js | 5 +- workspaces/libnpmversion/lib/proc-log.js | 21 - workspaces/libnpmversion/lib/version.js | 13 +- workspaces/libnpmversion/package.json | 47 +- .../tap-snapshots/test/index.js.test.cjs | 14 +- .../libnpmversion/test/enforce-clean.js | 78 +- workspaces/libnpmversion/test/index.js | 1 - workspaces/libnpmversion/test/proc-log.js | 11 - workspaces/libnpmversion/test/version.js | 57 +- 1106 files changed, 69223 insertions(+), 100402 deletions(-) create mode 100644 .commitlintrc.js create mode 100644 .eslintrc.js delete mode 100644 .eslintrc.json create mode 100644 .eslintrc.local.json delete mode 100644 .gitattributes delete mode 100644 .github/CODEOWNERS delete mode 100644 .github/ISSUE_TEMPLATE/bug_8.yml delete mode 100644 .github/ISSUE_TEMPLATE/config.yml delete mode 100644 .github/ISSUE_TEMPLATE/docs-enhancement.yml delete mode 100644 .github/ISSUE_TEMPLATE/docs-problem.yml delete mode 100644 .github/workflows/benchmark-comment.yml delete mode 100644 .github/workflows/benchmark.yml delete mode 100644 .github/workflows/ci-docs.yml delete mode 100644 .github/workflows/ci-libnpmaccess.yml delete mode 100644 .github/workflows/ci-libnpmdiff.yml delete mode 100644 .github/workflows/ci-libnpmexec.yml delete mode 100644 .github/workflows/ci-libnpmfund.yml delete mode 100644 .github/workflows/ci-libnpmhook.yml delete mode 100644 .github/workflows/ci-libnpmorg.yml delete mode 100644 .github/workflows/ci-libnpmpack.yml delete mode 100644 .github/workflows/ci-libnpmpublish.yml delete mode 100644 .github/workflows/ci-libnpmsearch.yml delete mode 100644 .github/workflows/ci-libnpmteam.yml delete mode 100644 .github/workflows/ci-libnpmversion.yml delete mode 100644 .github/workflows/ci-npmcli-arborist.yml delete mode 100644 .github/workflows/ci.yml delete mode 100644 .github/workflows/create-cli-deps-pr.yml delete mode 100644 .gitignore create mode 100644 .release-please-manifest.json create mode 100644 CODE_OF_CONDUCT.md create mode 100644 DEPENDENCIES.md delete mode 100644 Makefile delete mode 100644 changelogs/CHANGELOG-1.md delete mode 100644 changelogs/CHANGELOG-2.md delete mode 100644 changelogs/CHANGELOG-3.md delete mode 100644 changelogs/CHANGELOG-4.md delete mode 100644 changelogs/CHANGELOG-5.md delete mode 100644 changelogs/CHANGELOG-6.md delete mode 100644 changelogs/CHANGELOG-7.md delete mode 100644 debian/NEWS delete mode 100644 debian/README.Debian delete mode 100644 debian/README.source delete mode 100644 debian/TODO delete mode 100644 debian/changelog delete mode 100644 debian/clean delete mode 100644 debian/control delete mode 100644 debian/copyright delete mode 100644 debian/copyright_hints delete mode 100644 debian/docs delete mode 100644 debian/install delete mode 100644 debian/links delete mode 100644 debian/manpages delete mode 100644 debian/nodejs/additional_components delete mode 100644 debian/nodejs/files delete mode 100644 debian/nodejs/links delete mode 100644 debian/nodejs/root_modules delete mode 100644 debian/npm.bash-completion delete mode 100644 debian/npm.lintian-overrides delete mode 100644 debian/npm.maintscript delete mode 100644 debian/npmrc delete mode 100644 debian/patches/2004_remove_shebang.patch delete mode 100644 debian/patches/2011_node-gyp-path.patch delete mode 100644 debian/patches/2012_dont_install_man_deps.patch delete mode 100644 debian/patches/2020_reproducible_documentation_build.patch delete mode 100644 debian/patches/dont-check-for-last-version.patch delete mode 100644 debian/patches/fix-test.patch delete mode 100644 debian/patches/fix-tests.patch delete mode 100644 debian/patches/series delete mode 100755 debian/rules delete mode 100644 debian/source/format delete mode 100644 debian/source/lintian-overrides delete mode 100644 debian/tests/control delete mode 100755 debian/tests/install-test delete mode 100755 debian/tests/no-duplication delete mode 100644 debian/tests/pkg-js/SKIP delete mode 100644 debian/tests/test_excluded delete mode 100644 debian/watch create mode 100644 docs/.eslintrc.js create mode 100644 docs/.gitignore create mode 100644 docs/README.md create mode 100644 docs/bin/build.js delete mode 100644 docs/config.json delete mode 100644 docs/content/commands/npm-adduser.md delete mode 100644 docs/content/commands/npm-bin.md delete mode 100644 docs/content/commands/npm-bugs.md delete mode 100644 docs/content/commands/npm-ci.md delete mode 100644 docs/content/commands/npm-config.md delete mode 100644 docs/content/commands/npm-dedupe.md delete mode 100644 docs/content/commands/npm-docs.md delete mode 100644 docs/content/commands/npm-explain.md delete mode 100644 docs/content/commands/npm-find-dupes.md delete mode 100644 docs/content/commands/npm-fund.md delete mode 100644 docs/content/commands/npm-install-ci-test.md delete mode 100644 docs/content/commands/npm-install-test.md delete mode 100644 docs/content/commands/npm-link.md delete mode 100644 docs/content/commands/npm-logout.md delete mode 100644 docs/content/commands/npm-ls.md delete mode 100644 docs/content/commands/npm-org.md delete mode 100644 docs/content/commands/npm-pack.md delete mode 100644 docs/content/commands/npm-prefix.md delete mode 100644 docs/content/commands/npm-prune.md delete mode 100644 docs/content/commands/npm-publish.md delete mode 100644 docs/content/commands/npm-rebuild.md delete mode 100644 docs/content/commands/npm-repo.md delete mode 100644 docs/content/commands/npm-restart.md delete mode 100644 docs/content/commands/npm-root.md delete mode 100644 docs/content/commands/npm-run-script.md delete mode 100644 docs/content/commands/npm-search.md delete mode 100644 docs/content/commands/npm-set-script.md delete mode 100644 docs/content/commands/npm-stop.md delete mode 100644 docs/content/commands/npm-test.md delete mode 100644 docs/content/commands/npm-uninstall.md delete mode 100644 docs/content/commands/npm-unpublish.md delete mode 100644 docs/content/commands/npm-unstar.md delete mode 100644 docs/content/commands/npm-update.md delete mode 100644 docs/content/commands/npm-version.md delete mode 100644 docs/content/using-npm/config.md delete mode 100644 docs/content/using-npm/logging.md delete mode 100644 docs/dockhand.js create mode 100644 docs/lib/build.js create mode 100644 docs/lib/check-nav.js rename docs/{ => lib}/content/commands/npm-access.md (62%) create mode 100644 docs/lib/content/commands/npm-adduser.md rename docs/{ => lib}/content/commands/npm-audit.md (50%) create mode 100644 docs/lib/content/commands/npm-bugs.md rename docs/{ => lib}/content/commands/npm-cache.md (79%) create mode 100644 docs/lib/content/commands/npm-ci.md rename docs/{ => lib}/content/commands/npm-completion.md (95%) create mode 100644 docs/lib/content/commands/npm-config.md create mode 100644 docs/lib/content/commands/npm-dedupe.md rename docs/{ => lib}/content/commands/npm-deprecate.md (56%) rename docs/{ => lib}/content/commands/npm-diff.md (50%) rename docs/{ => lib}/content/commands/npm-dist-tag.md (53%) create mode 100644 docs/lib/content/commands/npm-docs.md rename docs/{ => lib}/content/commands/npm-doctor.md (90%) rename docs/{ => lib}/content/commands/npm-edit.md (61%) rename docs/{ => lib}/content/commands/npm-exec.md (68%) create mode 100644 docs/lib/content/commands/npm-explain.md rename docs/{ => lib}/content/commands/npm-explore.md (61%) create mode 100644 docs/lib/content/commands/npm-find-dupes.md create mode 100644 docs/lib/content/commands/npm-fund.md rename docs/{ => lib}/content/commands/npm-help-search.md (57%) rename docs/{ => lib}/content/commands/npm-help.md (58%) rename docs/{ => lib}/content/commands/npm-hook.md (65%) rename docs/{ => lib}/content/commands/npm-init.md (53%) create mode 100644 docs/lib/content/commands/npm-install-ci-test.md create mode 100644 docs/lib/content/commands/npm-install-test.md rename docs/{ => lib}/content/commands/npm-install.md (62%) create mode 100644 docs/lib/content/commands/npm-link.md create mode 100644 docs/lib/content/commands/npm-login.md create mode 100644 docs/lib/content/commands/npm-logout.md create mode 100644 docs/lib/content/commands/npm-ls.md create mode 100644 docs/lib/content/commands/npm-org.md rename docs/{ => lib}/content/commands/npm-outdated.md (57%) rename docs/{ => lib}/content/commands/npm-owner.md (54%) create mode 100644 docs/lib/content/commands/npm-pack.md rename docs/{ => lib}/content/commands/npm-ping.md (58%) rename docs/{ => lib}/content/commands/npm-pkg.md (56%) create mode 100644 docs/lib/content/commands/npm-prefix.md rename docs/{ => lib}/content/commands/npm-profile.md (63%) create mode 100644 docs/lib/content/commands/npm-prune.md create mode 100644 docs/lib/content/commands/npm-publish.md create mode 100644 docs/lib/content/commands/npm-query.md create mode 100644 docs/lib/content/commands/npm-rebuild.md create mode 100644 docs/lib/content/commands/npm-repo.md create mode 100644 docs/lib/content/commands/npm-restart.md create mode 100644 docs/lib/content/commands/npm-root.md create mode 100644 docs/lib/content/commands/npm-run-script.md create mode 100644 docs/lib/content/commands/npm-search.md rename docs/{ => lib}/content/commands/npm-shrinkwrap.md (95%) rename docs/{ => lib}/content/commands/npm-star.md (50%) rename docs/{ => lib}/content/commands/npm-stars.md (58%) rename docs/{ => lib}/content/commands/npm-start.md (50%) create mode 100644 docs/lib/content/commands/npm-stop.md rename docs/{ => lib}/content/commands/npm-team.md (64%) create mode 100644 docs/lib/content/commands/npm-test.md rename docs/{ => lib}/content/commands/npm-token.md (68%) create mode 100644 docs/lib/content/commands/npm-uninstall.md create mode 100644 docs/lib/content/commands/npm-unpublish.md create mode 100644 docs/lib/content/commands/npm-unstar.md create mode 100644 docs/lib/content/commands/npm-update.md create mode 100644 docs/lib/content/commands/npm-version.md rename docs/{ => lib}/content/commands/npm-view.md (54%) rename docs/{ => lib}/content/commands/npm-whoami.md (59%) rename docs/{ => lib}/content/commands/npm.md (98%) rename docs/{ => lib}/content/commands/npx.md (91%) rename docs/{ => lib}/content/configuring-npm/folders.md (81%) rename docs/{ => lib}/content/configuring-npm/install.md (100%) rename docs/{ => lib}/content/configuring-npm/npm-shrinkwrap-json.md (100%) rename docs/{ => lib}/content/configuring-npm/npmrc.md (70%) rename docs/{ => lib}/content/configuring-npm/package-json.md (92%) rename docs/{ => lib}/content/configuring-npm/package-lock-json.md (100%) rename docs/{ => lib/content}/nav.yml (94%) create mode 100644 docs/lib/content/using-npm/config.md create mode 100644 docs/lib/content/using-npm/dependency-selectors.md rename docs/{ => lib}/content/using-npm/developers.md (100%) create mode 100644 docs/lib/content/using-npm/logging.md rename docs/{ => lib}/content/using-npm/orgs.md (100%) create mode 100644 docs/lib/content/using-npm/package-spec.md rename docs/{ => lib}/content/using-npm/registry.md (87%) rename docs/{ => lib}/content/using-npm/removal.md (100%) rename docs/{ => lib}/content/using-npm/scope.md (83%) rename docs/{ => lib}/content/using-npm/scripts.md (92%) rename docs/{ => lib}/content/using-npm/workspaces.md (91%) create mode 100644 docs/lib/index.js rename docs/{ => lib}/template.html (100%) create mode 100644 docs/lib/transform-html.js create mode 100644 docs/test/index.js delete mode 100644 lib/auth/legacy.js delete mode 100644 lib/auth/oauth.js delete mode 100644 lib/auth/saml.js delete mode 100644 lib/auth/sso.js delete mode 100644 lib/commands/bin.js delete mode 100644 lib/commands/birthday.js create mode 100644 lib/commands/login.js create mode 100644 lib/commands/query.js delete mode 100644 lib/commands/set-script.js delete mode 100644 lib/exec/get-workspace-location-msg.js create mode 100644 lib/package-url-cmd.js delete mode 100644 lib/search/package-filter.js create mode 100644 lib/utils/auth.js delete mode 100644 lib/utils/config/describe-all.js delete mode 100644 lib/utils/deref-command.js delete mode 100644 lib/utils/file-exists.js rename lib/{search/format-package-stream.js => utils/format-search-stream.js} (67%) delete mode 100644 lib/utils/hosted-git-info-from-manifest.js delete mode 100644 lib/utils/is-windows-bash.js delete mode 100644 lib/utils/is-windows-shell.js create mode 100644 lib/utils/open-url-prompt.js delete mode 100644 lib/utils/path.js delete mode 100644 lib/utils/read-package-name.js delete mode 100644 lib/utils/split-package-names.js delete mode 100644 lib/utils/unsupported.js delete mode 100644 lib/utils/usage.js create mode 100644 lib/utils/web-auth.js delete mode 100644 lib/utils/with-chown-sync.js create mode 100644 lib/workspaces/update-workspaces.js delete mode 100644 make.bat create mode 100644 mock-registry/.eslintrc.js create mode 100644 mock-registry/.gitignore create mode 100644 mock-registry/lib/index.js create mode 100644 mock-registry/package.json create mode 100644 mock-registry/test/index.js delete mode 100644 netlify.toml create mode 100644 node_modules/@colors/colors/LICENSE create mode 100644 node_modules/@colors/colors/examples/normal-usage.js create mode 100644 node_modules/@colors/colors/examples/safe-string.js create mode 100644 node_modules/@colors/colors/index.d.ts create mode 100644 node_modules/@colors/colors/lib/colors.js create mode 100644 node_modules/@colors/colors/lib/custom/trap.js create mode 100644 node_modules/@colors/colors/lib/custom/zalgo.js create mode 100644 node_modules/@colors/colors/lib/extendStringPrototype.js create mode 100644 node_modules/@colors/colors/lib/index.js create mode 100644 node_modules/@colors/colors/lib/maps/america.js create mode 100644 node_modules/@colors/colors/lib/maps/rainbow.js create mode 100644 node_modules/@colors/colors/lib/maps/random.js create mode 100644 node_modules/@colors/colors/lib/maps/zebra.js create mode 100644 node_modules/@colors/colors/lib/styles.js create mode 100644 node_modules/@colors/colors/lib/system/has-flag.js create mode 100644 node_modules/@colors/colors/lib/system/supports-colors.js create mode 100644 node_modules/@colors/colors/package.json create mode 100644 node_modules/@colors/colors/safe.d.ts create mode 100644 node_modules/@colors/colors/safe.js create mode 100644 node_modules/@colors/colors/themes/generic-logging.js delete mode 100644 node_modules/@gar/promisify/index.js delete mode 100644 node_modules/@gar/promisify/package.json delete mode 100644 node_modules/@npmcli/ci-detect/lib/index.js delete mode 100644 node_modules/@npmcli/ci-detect/package.json create mode 120000 node_modules/@npmcli/config delete mode 100644 node_modules/@npmcli/config/lib/proc-log.js delete mode 100644 node_modules/@npmcli/config/package.json rename node_modules/@npmcli/disparity-colors/{ => lib}/index.js (87%) delete mode 100644 node_modules/@npmcli/fs/lib/common/file-url-to-path/index.js delete mode 100644 node_modules/@npmcli/fs/lib/common/file-url-to-path/polyfill.js delete mode 100644 node_modules/@npmcli/fs/lib/common/get-options.js delete mode 100644 node_modules/@npmcli/fs/lib/common/node.js delete mode 100644 node_modules/@npmcli/fs/lib/common/owner.js delete mode 100644 node_modules/@npmcli/fs/lib/copy-file.js delete mode 100644 node_modules/@npmcli/fs/lib/cp/LICENSE delete mode 100644 node_modules/@npmcli/fs/lib/cp/index.js delete mode 100644 node_modules/@npmcli/fs/lib/cp/polyfill.js delete mode 100644 node_modules/@npmcli/fs/lib/errors.js delete mode 100644 node_modules/@npmcli/fs/lib/fs.js delete mode 100644 node_modules/@npmcli/fs/lib/index.js delete mode 100644 node_modules/@npmcli/fs/lib/mkdir/index.js delete mode 100644 node_modules/@npmcli/fs/lib/mkdir/polyfill.js delete mode 100644 node_modules/@npmcli/fs/lib/mkdtemp.js delete mode 100644 node_modules/@npmcli/fs/lib/rm/index.js delete mode 100644 node_modules/@npmcli/fs/lib/rm/polyfill.js delete mode 100644 node_modules/@npmcli/fs/lib/with-temp-dir.js delete mode 100644 node_modules/@npmcli/fs/lib/write-file.js delete mode 100644 node_modules/@npmcli/fs/package.json delete mode 100644 node_modules/@npmcli/git/lib/proc-log.js rename node_modules/@npmcli/installed-package-contents/{ => lib}/index.js (81%) delete mode 100644 node_modules/@npmcli/promise-spawn/index.js create mode 100644 node_modules/@npmcli/promise-spawn/lib/escape.js create mode 100644 node_modules/@npmcli/promise-spawn/lib/index.js rename node_modules/@npmcli/{fs/LICENSE.md => query/LICENSE} (100%) create mode 100644 node_modules/@npmcli/query/lib/index.js create mode 100644 node_modules/@npmcli/query/package.json rename node_modules/{debuglog => abort-controller}/LICENSE (56%) create mode 100644 node_modules/abort-controller/browser.js create mode 100644 node_modules/abort-controller/browser.mjs create mode 100644 node_modules/abort-controller/dist/abort-controller.d.ts create mode 100644 node_modules/abort-controller/dist/abort-controller.js create mode 100644 node_modules/abort-controller/dist/abort-controller.js.map create mode 100644 node_modules/abort-controller/dist/abort-controller.mjs create mode 100644 node_modules/abort-controller/dist/abort-controller.mjs.map create mode 100644 node_modules/abort-controller/dist/abort-controller.umd.js create mode 100644 node_modules/abort-controller/dist/abort-controller.umd.js.map create mode 100644 node_modules/abort-controller/package.json create mode 100644 node_modules/abort-controller/polyfill.js create mode 100644 node_modules/abort-controller/polyfill.mjs delete mode 100644 node_modules/ansicolors/LICENSE delete mode 100644 node_modules/ansicolors/ansicolors.js delete mode 100644 node_modules/ansicolors/package.json delete mode 100644 node_modules/ansicolors/test/ansicolors.js rename node_modules/cli-columns/{LICENSE => license} (100%) delete mode 100644 node_modules/cli-columns/node_modules/ansi-regex/index.d.ts delete mode 100644 node_modules/cli-columns/node_modules/ansi-regex/index.js delete mode 100644 node_modules/cli-columns/node_modules/ansi-regex/license delete mode 100644 node_modules/cli-columns/node_modules/ansi-regex/package.json delete mode 100644 node_modules/cli-columns/node_modules/is-fullwidth-code-point/index.d.ts delete mode 100644 node_modules/cli-columns/node_modules/is-fullwidth-code-point/index.js delete mode 100644 node_modules/cli-columns/node_modules/is-fullwidth-code-point/license delete mode 100644 node_modules/cli-columns/node_modules/is-fullwidth-code-point/package.json delete mode 100644 node_modules/cli-columns/node_modules/string-width/index.d.ts delete mode 100644 node_modules/cli-columns/node_modules/string-width/index.js delete mode 100644 node_modules/cli-columns/node_modules/string-width/license delete mode 100644 node_modules/cli-columns/node_modules/string-width/package.json delete mode 100644 node_modules/cli-columns/node_modules/strip-ansi/index.d.ts delete mode 100644 node_modules/cli-columns/node_modules/strip-ansi/index.js delete mode 100644 node_modules/cli-columns/node_modules/strip-ansi/license delete mode 100644 node_modules/cli-columns/node_modules/strip-ansi/package.json rename node_modules/cmd-shim/{ => lib}/index.js (89%) delete mode 100644 node_modules/debuglog/debuglog.js delete mode 100644 node_modules/debuglog/package.json delete mode 100644 node_modules/dezalgo/LICENSE delete mode 100644 node_modules/dezalgo/dezalgo.js delete mode 100644 node_modules/dezalgo/package.json delete mode 100644 node_modules/dezalgo/test/basic.js delete mode 100644 node_modules/env-paths/readme.md create mode 100644 node_modules/event-target-shim/LICENSE create mode 100644 node_modules/event-target-shim/dist/event-target-shim.js create mode 100644 node_modules/event-target-shim/dist/event-target-shim.js.map create mode 100644 node_modules/event-target-shim/dist/event-target-shim.mjs create mode 100644 node_modules/event-target-shim/dist/event-target-shim.mjs.map create mode 100644 node_modules/event-target-shim/dist/event-target-shim.umd.js create mode 100644 node_modules/event-target-shim/dist/event-target-shim.umd.js.map create mode 100644 node_modules/event-target-shim/index.d.ts create mode 100644 node_modules/event-target-shim/package.json create mode 100644 node_modules/fastest-levenshtein/bench.js create mode 100644 node_modules/fastest-levenshtein/esm/mod.d.ts create mode 100644 node_modules/fastest-levenshtein/esm/mod.d.ts.map create mode 100644 node_modules/fastest-levenshtein/esm/mod.js delete mode 100644 node_modules/fastest-levenshtein/index.d.ts delete mode 100644 node_modules/fastest-levenshtein/index.js create mode 100644 node_modules/fastest-levenshtein/mod.d.ts create mode 100644 node_modules/fastest-levenshtein/mod.js create mode 100644 node_modules/fastest-levenshtein/test.ts rename node_modules/{@npmcli/config => fs-minipass/node_modules/minipass}/LICENSE (90%) create mode 100644 node_modules/fs-minipass/node_modules/minipass/index.d.ts create mode 100644 node_modules/fs-minipass/node_modules/minipass/index.js create mode 100644 node_modules/fs-minipass/node_modules/minipass/package.json rename node_modules/ignore-walk/{ => lib}/index.js (91%) create mode 100644 node_modules/just-diff-apply/index.d.ts create mode 100644 node_modules/just-diff-apply/index.tests.ts create mode 100644 node_modules/make-fetch-happen/lib/dns.js create mode 100644 node_modules/make-fetch-happen/lib/pipeline.js delete mode 100644 node_modules/make-fetch-happen/node_modules/lru-cache/LICENSE delete mode 100644 node_modules/make-fetch-happen/node_modules/lru-cache/index.js delete mode 100644 node_modules/make-fetch-happen/node_modules/lru-cache/package.json delete mode 100644 node_modules/mkdirp-infer-owner/LICENSE delete mode 100644 node_modules/mkdirp-infer-owner/index.js delete mode 100644 node_modules/mkdirp-infer-owner/package.json rename node_modules/npm-install-checks/{ => lib}/index.js (91%) delete mode 100644 node_modules/npm-normalize-package-bin/LICENSE delete mode 100644 node_modules/npm-normalize-package-bin/index.js delete mode 100644 node_modules/npm-normalize-package-bin/package-lock.json delete mode 100644 node_modules/npm-normalize-package-bin/package.json delete mode 100644 node_modules/npm-normalize-package-bin/test/array.js delete mode 100644 node_modules/npm-normalize-package-bin/test/nobin.js delete mode 100644 node_modules/npm-normalize-package-bin/test/object.js delete mode 100644 node_modules/npm-normalize-package-bin/test/string.js delete mode 100755 node_modules/npm-packlist/bin/index.js delete mode 100644 node_modules/npm-packlist/index.js create mode 100644 node_modules/npm-packlist/lib/index.js rename node_modules/npm-pick-manifest/{ => lib}/index.js (96%) create mode 100644 node_modules/npm-registry-fetch/lib/clean-url.js delete mode 100644 node_modules/npm-registry-fetch/lib/silentlog.js delete mode 100644 node_modules/pacote/lib/util/proc-log.js create mode 100644 node_modules/pacote/lib/util/trailing-slashes.js delete mode 100644 node_modules/proc-log/LICENSE delete mode 100644 node_modules/proc-log/index.js delete mode 100644 node_modules/proc-log/package.json create mode 100644 node_modules/process/LICENSE create mode 100644 node_modules/process/browser.js create mode 100644 node_modules/process/index.js create mode 100644 node_modules/process/package.json create mode 100644 node_modules/process/test.js delete mode 100644 node_modules/promise-all-reject-late/package-lock.json rename node_modules/read-cmd-shim/{ => lib}/index.js (87%) rename node_modules/read-package-json-fast/{ => lib}/index.js (83%) delete mode 100644 node_modules/readdir-scoped-modules/LICENSE delete mode 100644 node_modules/readdir-scoped-modules/package.json delete mode 100644 node_modules/readdir-scoped-modules/readdir.js delete mode 100644 node_modules/socks-proxy-agent/dist/agent.d.ts delete mode 100644 node_modules/socks-proxy-agent/dist/agent.js delete mode 100644 node_modules/socks-proxy-agent/dist/agent.js.map delete mode 100644 node_modules/stringify-package/LICENSE delete mode 100644 node_modules/stringify-package/index.js delete mode 100644 node_modules/stringify-package/package.json delete mode 100644 node_modules/treeverse/index.js create mode 100644 node_modules/treeverse/lib/index.js rename node_modules/unique-slug/{ => lib}/index.js (55%) delete mode 100644 node_modules/unique-slug/test/index.js create mode 100644 release-please-config.json delete mode 100644 scripts/changelog.js delete mode 100755 scripts/clean-old.sh delete mode 100644 scripts/config-doc-command.js delete mode 100644 scripts/config-doc.js create mode 100644 scripts/create-node-pr.js create mode 100644 scripts/dependency-graph.js delete mode 100644 scripts/docs-build.js delete mode 100755 scripts/install.sh delete mode 100755 scripts/maketest create mode 100644 scripts/npm-cli-repos.txt delete mode 100755 scripts/pr delete mode 100644 scripts/publish-tag.js create mode 100644 scripts/publish.js delete mode 100644 scripts/release.sh delete mode 100755 scripts/relocate.sh create mode 100644 scripts/remove-files.js create mode 100644 scripts/resetdeps.js delete mode 100755 scripts/resetdeps.sh create mode 100644 scripts/template-oss/_step-deps.yml create mode 100644 scripts/template-oss/_step-test.yml create mode 100644 scripts/template-oss/branch-specific-config.js create mode 100644 scripts/template-oss/ci-npmcli-docs.yml create mode 100644 scripts/template-oss/ci-release.yml create mode 100644 scripts/template-oss/ci.yml create mode 100644 scripts/template-oss/create-node-pr.yml create mode 100644 scripts/template-oss/index.js create mode 100644 scripts/template-oss/root.js create mode 100755 scripts/update-authors.js delete mode 100755 scripts/update-authors.sh create mode 100644 scripts/util.js create mode 100644 smoke-tests/.eslintrc.js create mode 100644 smoke-tests/.gitignore delete mode 100644 smoke-tests/content/abbrev.json delete mode 100644 smoke-tests/content/abbrev.min.json delete mode 100644 smoke-tests/content/abbrev/-/abbrev-1.0.4.tgz delete mode 100644 smoke-tests/content/abbrev/-/abbrev-1.1.1.tgz delete mode 100644 smoke-tests/content/promise-all-reject-late.json delete mode 100644 smoke-tests/content/promise-all-reject-late.min.json delete mode 100644 smoke-tests/content/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz delete mode 100644 smoke-tests/index.js create mode 100644 smoke-tests/package.json delete mode 100644 smoke-tests/server.js create mode 100644 smoke-tests/tap-snapshots/test/index.js.test.cjs create mode 100644 smoke-tests/test/fixtures/setup.js create mode 100644 smoke-tests/test/index.js create mode 100644 smoke-tests/test/workspace-ua.js delete mode 100644 tap-snapshots/smoke-tests/index.js.test.cjs create mode 100644 tap-snapshots/test/lib/commands/audit.js.test.cjs create mode 100644 tap-snapshots/test/lib/commands/cache.js.test.cjs delete mode 100644 tap-snapshots/test/lib/commands/ci.js.test.cjs create mode 100644 tap-snapshots/test/lib/commands/doctor.js.test.cjs delete mode 100644 tap-snapshots/test/lib/commands/owner.js.test.cjs create mode 100644 tap-snapshots/test/lib/commands/query.js.test.cjs delete mode 100644 tap-snapshots/test/lib/commands/unpublish.js.test.cjs create mode 100644 tap-snapshots/test/lib/commands/version.js.test.cjs create mode 100644 tap-snapshots/test/lib/docs.js.test.cjs delete mode 100644 tap-snapshots/test/lib/load-all-commands.js.test.cjs delete mode 100644 tap-snapshots/test/lib/utils/cmd-list.js.test.cjs delete mode 100644 tap-snapshots/test/lib/utils/config/definitions.js.test.cjs delete mode 100644 tap-snapshots/test/lib/utils/config/describe-all.js.test.cjs delete mode 100644 tap-snapshots/test/lib/utils/config/index.js.test.cjs delete mode 100644 tap-snapshots/test/lib/utils/npm-usage.js.test.cjs create mode 100644 tap-snapshots/test/lib/utils/open-url-prompt.js.test.cjs delete mode 100644 test/coverage-map.js create mode 100644 test/fixtures/tnock.js create mode 100644 test/fixtures/tspawk.js delete mode 100644 test/lib/auth/legacy.js delete mode 100644 test/lib/auth/oauth.js delete mode 100644 test/lib/auth/saml.js delete mode 100644 test/lib/auth/sso.js delete mode 100644 test/lib/commands/bin.js delete mode 100644 test/lib/commands/birthday.js create mode 100644 test/lib/commands/login.js create mode 100644 test/lib/commands/query.js delete mode 100644 test/lib/commands/set-script.js create mode 100644 test/lib/docs.js delete mode 100644 test/lib/load-all.js delete mode 100644 test/lib/utils/cmd-list.js delete mode 100644 test/lib/utils/config/describe-all.js delete mode 100644 test/lib/utils/config/flatten.js delete mode 100644 test/lib/utils/deref-command.js delete mode 100644 test/lib/utils/file-exists.js delete mode 100644 test/lib/utils/get-identity.js delete mode 100644 test/lib/utils/hosted-git-info-from-manifest.js delete mode 100644 test/lib/utils/is-windows-bash.js delete mode 100644 test/lib/utils/is-windows-shell.js delete mode 100644 test/lib/utils/is-windows.js delete mode 100644 test/lib/utils/npm-usage.js create mode 100644 test/lib/utils/open-url-prompt.js delete mode 100644 test/lib/utils/path.js delete mode 100644 test/lib/utils/ping.js delete mode 100644 test/lib/utils/read-package-name.js delete mode 100644 test/lib/utils/split-package-names.js delete mode 100644 test/lib/utils/unsupported.js create mode 100644 test/lib/utils/web-auth.js delete mode 100644 workspaces/arborist/.npmrc delete mode 100644 workspaces/arborist/SECURITY.md create mode 100644 workspaces/arborist/lib/override-resolves.js create mode 100644 workspaces/arborist/lib/query-selector-all.js create mode 100644 workspaces/arborist/test/fixtures/old-lock-with-link/link-dep/package.json create mode 100644 workspaces/arborist/test/fixtures/old-lock-with-link/package-lock.json create mode 100644 workspaces/arborist/test/fixtures/old-lock-with-link/package.json rename workspaces/{libnpmaccess => arborist}/test/fixtures/tnock.js (77%) create mode 100644 workspaces/arborist/test/fixtures/workspaces-link-bin/packages/b/create-file.js delete mode 100644 workspaces/arborist/test/fixtures/workspaces-link-bin/packages/b/file.js create mode 100644 workspaces/arborist/test/query-selector-all.js create mode 100644 workspaces/config/.eslintrc.js create mode 100644 workspaces/config/.gitignore create mode 100644 workspaces/config/CHANGELOG.md rename {node_modules/@npmcli/ci-detect => workspaces/config}/LICENSE (100%) create mode 100644 workspaces/config/README.md rename {node_modules/@npmcli => workspaces}/config/lib/env-replace.js (67%) create mode 100644 workspaces/config/lib/errors.js rename {node_modules/@npmcli => workspaces}/config/lib/index.js (79%) rename {node_modules/@npmcli => workspaces}/config/lib/nerf-dart.js (100%) rename {node_modules/@npmcli => workspaces}/config/lib/parse-field.js (98%) rename {node_modules/@npmcli => workspaces}/config/lib/set-envs.js (100%) rename {node_modules/@npmcli => workspaces}/config/lib/type-defs.js (100%) rename {node_modules/@npmcli => workspaces}/config/lib/type-description.js (100%) rename {node_modules/@npmcli => workspaces}/config/lib/umask.js (100%) create mode 100644 workspaces/config/map.js create mode 100644 workspaces/config/package.json create mode 100644 workspaces/config/scripts/example.js create mode 100644 workspaces/config/tap-snapshots/test/index.js.test.cjs create mode 100644 workspaces/config/tap-snapshots/test/type-description.js.test.cjs create mode 100644 workspaces/config/test/env-replace.js create mode 100644 workspaces/config/test/fixtures/cafile create mode 100644 workspaces/config/test/fixtures/defaults.js create mode 100644 workspaces/config/test/fixtures/definitions.js rename {lib/utils/config => workspaces/config/test/fixtures}/flatten.js (100%) create mode 100644 workspaces/config/test/fixtures/shorthands.js create mode 100644 workspaces/config/test/fixtures/types.js create mode 100644 workspaces/config/test/index.js create mode 100644 workspaces/config/test/nerf-dart.js create mode 100644 workspaces/config/test/parse-field.js create mode 100644 workspaces/config/test/set-envs.js create mode 100644 workspaces/config/test/type-defs.js create mode 100644 workspaces/config/test/type-description.js delete mode 100644 workspaces/libnpmaccess/.npmrc delete mode 100644 workspaces/libnpmaccess/SECURITY.md delete mode 100644 workspaces/libnpmdiff/.npmrc delete mode 100644 workspaces/libnpmdiff/SECURITY.md delete mode 100644 workspaces/libnpmexec/.editorconfig delete mode 100644 workspaces/libnpmexec/.npmrc delete mode 100644 workspaces/libnpmexec/CONTRIBUTING.md delete mode 100644 workspaces/libnpmexec/SECURITY.md delete mode 100644 workspaces/libnpmexec/lib/cache-install-dir.js delete mode 100644 workspaces/libnpmexec/lib/manifest-missing.js delete mode 100644 workspaces/libnpmexec/test/cache-install-dir.js create mode 100644 workspaces/libnpmexec/test/fixtures/setup.js create mode 100644 workspaces/libnpmexec/test/local.js delete mode 100644 workspaces/libnpmexec/test/manifest-missing.js create mode 100644 workspaces/libnpmexec/test/prompt.js create mode 100644 workspaces/libnpmexec/test/registry.js delete mode 100644 workspaces/libnpmexec/test/registry/content/ruyadorno/create-index.json delete mode 100644 workspaces/libnpmexec/test/registry/content/ruyadorno/create-index.min.json delete mode 100644 workspaces/libnpmexec/test/registry/content/ruyadorno/create-index/-/create-index-1.0.0.tgz delete mode 100644 workspaces/libnpmexec/test/registry/content/ruyadorno/create-test.json delete mode 100644 workspaces/libnpmexec/test/registry/content/ruyadorno/create-test.min.json delete mode 100644 workspaces/libnpmexec/test/registry/content/ruyadorno/create-test/-/create-test-1.0.0.tgz delete mode 100644 workspaces/libnpmexec/test/registry/server.js delete mode 100644 workspaces/libnpmfund/.editorconfig delete mode 100644 workspaces/libnpmfund/.npmrc delete mode 100644 workspaces/libnpmfund/SECURITY.md rename workspaces/libnpmfund/{test.js => test/index.js} (99%) delete mode 100644 workspaces/libnpmhook/.npmrc delete mode 100644 workspaces/libnpmhook/SECURITY.md delete mode 100644 workspaces/libnpmorg/.npmrc delete mode 100644 workspaces/libnpmorg/SECURITY.md delete mode 100644 workspaces/libnpmpack/.npmrc delete mode 100644 workspaces/libnpmpack/SECURITY.md create mode 100644 workspaces/libnpmpack/test/fixtures/tspawk.js delete mode 100644 workspaces/libnpmpublish/.npmrc delete mode 100644 workspaces/libnpmpublish/SECURITY.md delete mode 100644 workspaces/libnpmsearch/.npmrc delete mode 100644 workspaces/libnpmsearch/SECURITY.md delete mode 100644 workspaces/libnpmteam/.github/settings.yml delete mode 100644 workspaces/libnpmteam/.github/workflows/ci.yml delete mode 100644 workspaces/libnpmteam/.npmrc delete mode 100644 workspaces/libnpmteam/SECURITY.md delete mode 100644 workspaces/libnpmversion/.npmrc create mode 100644 workspaces/libnpmversion/CHANGELOG.md delete mode 100644 workspaces/libnpmversion/SECURITY.md delete mode 100644 workspaces/libnpmversion/lib/proc-log.js delete mode 100644 workspaces/libnpmversion/test/proc-log.js diff --git a/.commitlintrc.js b/.commitlintrc.js new file mode 100644 index 0000000..5b0b1a5 --- /dev/null +++ b/.commitlintrc.js @@ -0,0 +1,10 @@ +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +module.exports = { + extends: ['@commitlint/config-conventional'], + rules: { + 'type-enum': [2, 'always', ['feat', 'fix', 'docs', 'deps', 'chore']], + 'header-max-length': [2, 'always', 80], + 'subject-case': [0, 'always', ['lower-case', 'sentence-case', 'start-case']], + }, +} diff --git a/.eslintrc.js b/.eslintrc.js new file mode 100644 index 0000000..4d943ad --- /dev/null +++ b/.eslintrc.js @@ -0,0 +1,23 @@ +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' + +const { readdirSync: readdir } = require('fs') + +const localConfigs = readdir(__dirname) + .filter((file) => file.startsWith('.eslintrc.local.')) + .map((file) => `./${file}`) + +module.exports = { + root: true, + ignorePatterns: [ + 'docs/**', + 'smoke-tests/**', + 'mock-registry/**', + 'workspaces/**', + ], + extends: [ + '@npmcli', + ...localConfigs, + ], +} diff --git a/.eslintrc.json b/.eslintrc.json deleted file mode 100644 index 2968a2e..0000000 --- a/.eslintrc.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "extends": ["@npmcli"], - "overrides": [{ - "files": "test/**", - "rules": { - "no-extend-native": "off", - "no-global-assign": "off" - } - }, { - "files": ["lib/**"], - "rules": { - "no-console": "warn" - } - }] -} diff --git a/.eslintrc.local.json b/.eslintrc.local.json new file mode 100644 index 0000000..e953021 --- /dev/null +++ b/.eslintrc.local.json @@ -0,0 +1,14 @@ +{ + "rules": { + "no-shadow": "off", + "no-console": "error" + }, + "overrides": [{ + "files": [ + "test/**" + ], + "rules": { + "no-console": "off" + } + }] +} diff --git a/.gitattributes b/.gitattributes deleted file mode 100644 index ef4b94f..0000000 --- a/.gitattributes +++ /dev/null @@ -1,2 +0,0 @@ -/node_modules/** linguist-generated=false -/package-lock.json linguist-generated=false diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS deleted file mode 100644 index ef87431..0000000 --- a/.github/CODEOWNERS +++ /dev/null @@ -1 +0,0 @@ -* @npm/cli-team diff --git a/.github/ISSUE_TEMPLATE/bug_8.yml b/.github/ISSUE_TEMPLATE/bug_8.yml deleted file mode 100644 index f6855c4..0000000 --- a/.github/ISSUE_TEMPLATE/bug_8.yml +++ /dev/null @@ -1,63 +0,0 @@ -name: 🐞 Bug v8 -description: File a bug/issue against v8.x -title: "[BUG] " -labels: [Bug, Needs Triage, Release 8.x] -body: -- type: checkboxes - attributes: - label: Is there an existing issue for this? - description: Please [search here](https://github.com/npm/cli/issues) to see if an issue already exists for your problem. - options: - - label: I have searched the existing issues - required: true -- type: checkboxes - attributes: - label: This issue exists in the latest npm version - description: Please make sure you have installed the latest npm and verified it is still an issue. - options: - - label: I am using the latest npm - required: true -- type: textarea - attributes: - label: Current Behavior - description: A clear & concise description of what you're experiencing. - validations: - required: false -- type: textarea - attributes: - label: Expected Behavior - description: A clear & concise description of what you expected to happen. - validations: - required: false -- type: textarea - attributes: - label: Steps To Reproduce - description: Steps to reproduce the behavior. - value: | - 1. In this environment... - 2. With this config... - 3. Run '...' - 4. See error... - validations: - required: false -- type: textarea - attributes: - label: Environment - description: | - examples: - - **`npm -v`**: **npm**: 7.6.3 - - **`node -v`**: **Node.js**: 13.14.0 - - **OS Name**: Ubuntu 20.04 - - **System Model Name**: Macbook Pro - - **`npm config ls`**: `; "user" config from ...` - value: | - - npm: - - Node.js: - - OS Name: - - System Model Name: - - npm config: - ```ini - ; copy and paste output from `npm config ls` here - ``` - validations: - required: false diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml deleted file mode 100644 index 07e3b97..0000000 --- a/.github/ISSUE_TEMPLATE/config.yml +++ /dev/null @@ -1,23 +0,0 @@ -blank_issues_enabled: true -contact_links: - - name: ❓ Help with issues in older versions of the CLI - url: https://github.community/c/software-development/47 - about: Find/file tickets with the community - - name: ⭐️ Feature Request - url: https://github.com/npm/feedback - about: Add your request or discuss the project w/ the community - - name: 📃 RFC - url: https://github.com/npm/rfcs - about: Create a more formal proposal/idea via our RFC - - name: 🚥 Registry Status - url: https://status.npmjs.org - about: Check the current status of the website/registry - - name: 🗂 Documentation - url: https://docs.npmjs.com - about: Preview our new docs - - name: 📫 Support - url: https://github.community/ - about: For general support questions please open a topic over at github.community - - name: 🚑 Support Policy - url: https://github.com/npm/cli/wiki/Support-Policy - about: Information about what version(s) of the CLI we support diff --git a/.github/ISSUE_TEMPLATE/docs-enhancement.yml b/.github/ISSUE_TEMPLATE/docs-enhancement.yml deleted file mode 100644 index ee8db1e..0000000 --- a/.github/ISSUE_TEMPLATE/docs-enhancement.yml +++ /dev/null @@ -1,37 +0,0 @@ -name: 📄 CLI Docs Enhancement -description: File a potential enhancement for the npm documentation -title: "[DOCS] <title>" -labels: [Documentation, Needs Triage] -body: -- type: checkboxes - attributes: - label: Is there an existing issue for this? - description: Please [search here](https://github.com/npm/cli/issues) to see if an issue already exists for your problem. - options: - - label: I have searched the existing issues - required: true -- type: checkboxes - attributes: - label: This is a CLI Docs Enhancement, not another kind of Docs Enhancement. - description: These issue templates are only for CLI documentation enhancements. If you are looking to submit another kind of documentation enhancement, please submit it to the [documentation](https://github.com/npm/documentation) repo. - options: - - label: This is a CLI Docs Enhancement. - required: true -- type: textarea - attributes: - label: Description of Problem - description: A clear & concise description of the current state of the docs. - validations: - required: true -- type: textarea - attributes: - label: Potential Solution - description: A clear & concise description of the potential enhancement, if there is one. - validations: - required: false -- type: input - attributes: - label: Docs URL - description: Please provide the URL of the page you'd like to see an enhancement to. - validations: - required: false diff --git a/.github/ISSUE_TEMPLATE/docs-problem.yml b/.github/ISSUE_TEMPLATE/docs-problem.yml deleted file mode 100644 index 6d50968..0000000 --- a/.github/ISSUE_TEMPLATE/docs-problem.yml +++ /dev/null @@ -1,37 +0,0 @@ -name: 📄 CLI Docs Problem -description: File a problem with the npm documentation -title: "[DOCS] <title>" -labels: [Documentation, Needs Triage] -body: -- type: checkboxes - attributes: - label: Is there an existing issue for this? - description: Please [search here](https://github.com/npm/cli/issues) to see if an issue already exists for your problem. - options: - - label: I have searched the existing issues - required: true -- type: checkboxes - attributes: - label: This is a CLI Docs Problem, not another kind of Docs Problem. - description: These issue templates are only for CLI documentation problems. If you are looking to submit another kind of documentation problem, please submit it to the [documentation](https://github.com/npm/documentation) repo. - options: - - label: This is a CLI Docs Problem. - required: true -- type: textarea - attributes: - label: Description of Problem - description: A clear & concise description of what is wrong with the docs. - validations: - required: true -- type: textarea - attributes: - label: Potential Solution - description: A clear & concise description of a potential solution or fix to the problem, if there is one. - validations: - required: false -- type: input - attributes: - label: Affected URL - description: Please provide the affected URL. - validations: - required: false diff --git a/.github/workflows/benchmark-comment.yml b/.github/workflows/benchmark-comment.yml deleted file mode 100644 index 285b293..0000000 --- a/.github/workflows/benchmark-comment.yml +++ /dev/null @@ -1,87 +0,0 @@ ---- -name: Benchmark CLI - Comment - -on: - issue_comment: - types: [created, edited] - -jobs: - comment-handler: - name: Trigger Benchmarks - - runs-on: ubuntu-latest - - steps: - - name: Handle Incoming Comment - env: - DISPATCH_REPO: "benchmarks" - DISPATCH_OWNER: "npm" - EVENT_NAME: ${{ github.event_name }} - OWNER: ${{ github.event.repository.owner.login }} - REPO: ${{ github.event.repository.name }} - ISSUE_NUMBER: ${{ github.event.issue.number }} - COMMENT_NODE_ID: ${{ github.event.comment.node_id }} - COMMENT_ACTIONABLE: ${{ startsWith(github.event.comment.body, 'test this please ✅') }} - AUTH_TOKEN: ${{ secrets.NPM_BENCHMARKS_TOKEN }} - run: | - # Comment Handler - - # Creates an exit early condition if there are errors - # Exit early if `jq` is not present - set -e - jq --version - - # Figure out if comment came from pull-request or issue - IS_PR=$(curl -s https://api.github.com/repos/${OWNER}/${REPO}/issues/${ISSUE_NUMBER} | jq -cr '.pull_request.url') - - if [ "${IS_PR}" != "null" ]; then - echo "Comment from pull/${ISSUE_NUMBER}." - - # It is a pull-request; check comment body for correct phrase - if [ "${COMMENT_ACTIONABLE}" == "true" ]; then - # Fetch pull-request information - PR_DATA=$(curl -s "${IS_PR}") - PR_OWNER=$(echo "${PR_DATA}" | jq '.head.repo.owner.login') - PR_REPO=$(echo "${PR_DATA}" | jq '.head.repo.name') - - # dispatch request for benchmarks - echo "Dispatching request..." - curl \ - -s \ - -X POST https://api.github.com/repos/${DISPATCH_OWNER}/${DISPATCH_REPO}/dispatches \ - -H "Accept: application/vnd.github.v3+json" \ - -H "Authorization: token ${AUTH_TOKEN}" \ - -d \ - ' - { - "event_type": "'"${EVENT_NAME} ${PR_OWNER}/${PR_REPO}#${ISSUE_NUMBER}"'", - "client_payload": { - "pr_id": "'"${ISSUE_NUMBER}"'", - "repo": "'"${PR_REPO}"'", - "owner": "'"${PR_OWNER}"'" - } - }' - - # Create reaction on comment to confirm dispatch was sent - curl \ - -s \ - -X POST https://api.github.com/graphql \ - -H "Content-Type: application/json" \ - -H "Authorization: token ${AUTH_TOKEN}" \ - -d \ - ' - { - "query": "mutation($inputData:AddReactionInput!) { addReaction(input:$inputData) { reaction { content } } }", - "variables": { - "inputData": { - "subjectId": "'"${COMMENT_NODE_ID}"'", - "content": "ROCKET" - } - } - }' - else - echo "Comment not actionable." - fi - else - echo "Comment not from pull-request." - fi diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml deleted file mode 100644 index b9da2dd..0000000 --- a/.github/workflows/benchmark.yml +++ /dev/null @@ -1,52 +0,0 @@ ---- -name: Benchmark Suite - -on: - pull_request: - branches: - - "**" - -jobs: - build: - name: Trigger Benchmarks - - runs-on: ubuntu-latest - - steps: - - name: Handle Incoming Pull-Request - env: - DISPATCH_REPO: "benchmarks" - DISPATCH_OWNER: "npm" - EVENT_NAME: ${{ github.event_name }} - REPO: ${{ github.event.repository.name }} - PR_NUMBER: ${{ github.event.pull_request.number }} - PR_OWNER: ${{ github.event.pull_request.head.repo.owner.login }} - AUTH_TOKEN: ${{ secrets.NPM_BENCHMARKS_TOKEN }} - run: | - # Dispatch Handler - - dispatch_request () { - echo "Dispatching request..." - curl \ - -s \ - -X POST https://api.github.com/repos/${DISPATCH_OWNER}/${DISPATCH_REPO}/dispatches \ - -H "Accept: application/vnd.github.v3+json" \ - -H "Authorization: token ${AUTH_TOKEN}" \ - -d \ - ' - { - "event_type": "'"${EVENT_NAME} ${PR_OWNER}/${REPO}#${PR_NUMBER}"'", - "client_payload": { - "pr_id": "'"${PR_NUMBER}"'", - "repo": "'"${REPO}"'", - "owner": "'"${PR_OWNER}"'" - } - }' - } - - if [ "${AUTH_TOKEN}" != "" ]; then - # Dispatch request for benchmarks - dispatch_request - else - echo "NO AUTH - FORK PULL REQUEST" - fi diff --git a/.github/workflows/ci-docs.yml b/.github/workflows/ci-docs.yml deleted file mode 100644 index 67a0752..0000000 --- a/.github/workflows/ci-docs.yml +++ /dev/null @@ -1,52 +0,0 @@ -name: Node CI docs - -on: - pull_request: - paths: - - docs/** - branches: - - '*' - push: - paths: - - docs/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 14.x - uses: actions/setup-node@v2 - with: - node-version: 14.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run lint -w docs - env: - DEPLOY_VERSION: testing - - check_docs: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Use Node.js 14.x - uses: actions/setup-node@v2 - with: - node-version: 14.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - - name: Rebuild the docs - run: make freshdocs - - name: Git should not be dirty - run: node scripts/git-dirty.js diff --git a/.github/workflows/ci-libnpmaccess.yml b/.github/workflows/ci-libnpmaccess.yml deleted file mode 100644 index b25bc61..0000000 --- a/.github/workflows/ci-libnpmaccess.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI libnpmaccess - -on: - pull_request: - paths: - - workspaces/libnpmaccess/** - branches: - - '*' - push: - paths: - - workspaces/libnpmaccess/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/libnpmaccess - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/libnpmaccess --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci-libnpmdiff.yml b/.github/workflows/ci-libnpmdiff.yml deleted file mode 100644 index 5ff0fdc..0000000 --- a/.github/workflows/ci-libnpmdiff.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI libnpmdiff - -on: - pull_request: - paths: - - workspaces/libnpmdiff/** - branches: - - '*' - push: - paths: - - workspaces/libnpmdiff/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/libnpmdiff - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/libnpmdiff --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci-libnpmexec.yml b/.github/workflows/ci-libnpmexec.yml deleted file mode 100644 index 011ae63..0000000 --- a/.github/workflows/ci-libnpmexec.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI libnpmexec - -on: - pull_request: - paths: - - workspaces/libnpmexec/** - branches: - - '*' - push: - paths: - - workspaces/libnpmexec/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/libnpmexec - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/libnpmexec --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci-libnpmfund.yml b/.github/workflows/ci-libnpmfund.yml deleted file mode 100644 index 3ce4de5..0000000 --- a/.github/workflows/ci-libnpmfund.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI libnpmfund - -on: - pull_request: - paths: - - workspaces/libnpmfund/** - branches: - - '*' - push: - paths: - - workspaces/libnpmfund/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/libnpmfund - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/libnpmfund --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci-libnpmhook.yml b/.github/workflows/ci-libnpmhook.yml deleted file mode 100644 index 1cd823a..0000000 --- a/.github/workflows/ci-libnpmhook.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI libnpmhook - -on: - pull_request: - paths: - - workspaces/libnpmhook/** - branches: - - '*' - push: - paths: - - workspaces/libnpmhook/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/libnpmhook - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/libnpmhook --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci-libnpmorg.yml b/.github/workflows/ci-libnpmorg.yml deleted file mode 100644 index e36aded..0000000 --- a/.github/workflows/ci-libnpmorg.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI libnpmorg - -on: - pull_request: - paths: - - workspaces/libnpmorg/** - branches: - - '*' - push: - paths: - - workspaces/libnpmorg/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/libnpmorg - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/libnpmorg --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci-libnpmpack.yml b/.github/workflows/ci-libnpmpack.yml deleted file mode 100644 index b2f1c3e..0000000 --- a/.github/workflows/ci-libnpmpack.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI libnpmpack - -on: - pull_request: - paths: - - workspaces/libnpmpack/** - branches: - - '*' - push: - paths: - - workspaces/libnpmpack/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/libnpmpack - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/libnpmpack --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci-libnpmpublish.yml b/.github/workflows/ci-libnpmpublish.yml deleted file mode 100644 index 3d26cf8..0000000 --- a/.github/workflows/ci-libnpmpublish.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI libnpmpublish - -on: - pull_request: - paths: - - workspaces/libnpmpublish/** - branches: - - '*' - push: - paths: - - workspaces/libnpmpublish/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/libnpmpublish - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/libnpmpublish --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci-libnpmsearch.yml b/.github/workflows/ci-libnpmsearch.yml deleted file mode 100644 index 08c4545..0000000 --- a/.github/workflows/ci-libnpmsearch.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI libnpmsearch - -on: - pull_request: - paths: - - workspaces/libnpmsearch/** - branches: - - '*' - push: - paths: - - workspaces/libnpmsearch/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/libnpmsearch - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/libnpmsearch --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci-libnpmteam.yml b/.github/workflows/ci-libnpmteam.yml deleted file mode 100644 index 18a37df..0000000 --- a/.github/workflows/ci-libnpmteam.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI libnpmteam - -on: - pull_request: - paths: - - workspaces/libnpmteam/** - branches: - - '*' - push: - paths: - - workspaces/libnpmteam/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/libnpmteam - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/libnpmteam --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci-libnpmversion.yml b/.github/workflows/ci-libnpmversion.yml deleted file mode 100644 index 5b4719d..0000000 --- a/.github/workflows/ci-libnpmversion.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI libnpmversion - -on: - pull_request: - paths: - - workspaces/libnpmversion/** - branches: - - '*' - push: - paths: - - workspaces/libnpmversion/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/libnpmversion - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/libnpmversion --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci-npmcli-arborist.yml b/.github/workflows/ci-npmcli-arborist.yml deleted file mode 100644 index d0cfbe0..0000000 --- a/.github/workflows/ci-npmcli-arborist.yml +++ /dev/null @@ -1,76 +0,0 @@ -name: Node Workspace CI @npmcli/arborist - -on: - pull_request: - paths: - - workspaces/arborist/** - branches: - - '*' - push: - paths: - - workspaces/arborist/** - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 16.x - uses: actions/setup-node@v2 - with: - node-version: 16.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest -w workspaces/arborist - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - run: node ./bin/npm-cli.js run -w workspaces/arborist --ignore-scripts test -- -t600 -Rbase -c diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml deleted file mode 100644 index b6b9125..0000000 --- a/.github/workflows/ci.yml +++ /dev/null @@ -1,166 +0,0 @@ -name: Node CI - -on: - pull_request: - branches: - - '*' - push: - branches: - - release-next - - latest - workflow_dispatch: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 14.x - uses: actions/setup-node@v2 - with: - node-version: 14.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Run linting - run: node ./bin/npm-cli.js run posttest - env: - DEPLOY_VERSION: testing - - check_docs: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Use Node.js 14.x - uses: actions/setup-node@v2 - with: - node-version: 14.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - - name: Rebuild the docs - run: make freshdocs - - name: Git should not be dirty - run: node scripts/git-dirty.js - - - licenses: - runs-on: ubuntu-latest - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - name: Use Node.js 14.x - uses: actions/setup-node@v2 - with: - node-version: 14.x - cache: npm - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - name: Validate licenses - run: node ./bin/npm-cli.js run licenses - - smoke-tests: - strategy: - fail-fast: false - matrix: - node-version: [12.x, 14.x, 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the smoke tests - - name: Run Smoke tests - run: node ./bin/npm-cli.js run --ignore-scripts smoke-tests -- --no-check-coverage -t600 -Rbase -c - env: - DEPLOY_VERSION: testing - - test: - strategy: - fail-fast: false - matrix: - node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x] - platform: - - os: ubuntu-latest - shell: bash - - os: macos-latest - shell: bash - - os: windows-latest - shell: bash - - os: windows-latest - shell: powershell - - runs-on: ${{ matrix.platform.os }} - defaults: - run: - shell: ${{ matrix.platform.shell }} - - steps: - # Checkout the npm/cli repo - - uses: actions/checkout@v2 - - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - # Run the installer script - - name: Install dependencies - run: | - node ./bin/npm-cli.js install --ignore-scripts --no-audit - node ./bin/npm-cli.js rebuild - - # Run the tests, but not if we're just gonna do coveralls later anyway - - name: Run Tap tests - if: matrix.platform.os != 'ubuntu-latest' || matrix.node-version != '16.x' - run: node ./bin/npm-cli.js run --ignore-scripts test -- -t600 -Rbase -c - env: - DEPLOY_VERSION: testing - - # Run coverage check - - name: Run coverage report - if: matrix.platform.os == 'ubuntu-latest' && matrix.node-version == '16.x' - # turn off --check-coverage until 100%, so CI failure is relevant - run: node ./bin/npm-cli.js run check-coverage -- -t600 --no-check-coverage -Rbase -c - env: - DEPLOY_VERSION: testing - COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_OPTIONAL_TOKEN }} - - # - name: Run sudo tests on Linux - # if: matrix.os == 'ubuntu-latest' - # run: sudo PATH=$PATH $(which node) . test -- --coverage --timeout 600 diff --git a/.github/workflows/create-cli-deps-pr.yml b/.github/workflows/create-cli-deps-pr.yml deleted file mode 100644 index a59302e..0000000 --- a/.github/workflows/create-cli-deps-pr.yml +++ /dev/null @@ -1,89 +0,0 @@ -name: "Create CLI Deps PR" - -on: - workflow_dispatch: - inputs: - npmVersion: - description: "6.x.x or latest" - required: true - default: 'latest' - - -jobs: - create-pull-request: - runs-on: ubuntu-latest - env: - GITHUB_TOKEN: ${{ secrets.NPM_ROBOT_USER_PAT }} - NPM_VERSION: ${{ github.event.inputs.npmVersion }} - SUPPORT_BRANCH: "v14.x-staging" - steps: - - name: Update gh cli & install jq parser - run: | - sudo apt-get update -y - sudo apt update - sudo apt-get install -y jq - sudo apt install gh - - name: Checkout npm/node - uses: actions/checkout@v2 - with: - fetch-depth: 0 - ref: master - repository: "npm/node" - token: ${{ secrets.NPM_ROBOT_USER_PAT }} - - name: Pull (Fast-Forward) upstream - id: sync - uses: aormsby/Fork-Sync-With-Upstream-action@v2.1 - with: - upstream_repository: nodejs/node - upstream_branch: master - target_branch: master - git_pull_args: --ff-only # optional arg use, defaults to simple 'pull' - github_token: ${{ secrets.NPM_ROBOT_USER_PAT }} # optional, for accessing repos that require authentication - - name: Run dependency updates and create PR - run: | - npm_tag="" - base_branch="" - if [ "$NPM_VERSION" == "latest" ] - then - npm_tag=`npm view npm@latest version` - base_branch="master" - else - npm_tag="$NPM_VERSION" - base_branch="v14.x-staging" - fi - - git config user.name "npm team" - git config user.email "ops+robot@npmjs.com" - git checkout -b "npm-$npm_tag" - - BASE_DIR="$( pwd )"/ - DEPS_DIR="$BASE_DIR"deps/ - - echo "Cloning CLI repo" - gh repo clone npm/cli - - echo "Prepping CLI repo for release" - cd cli - git checkout v"$npm_tag" - make - make release - - - echo "Removing old npm" - cd "$DEPS_DIR" - rm -rf npm/ - - echo "Copying new npm" - tar zxf "$BASE_DIR"cli/release/npm-"$npm_tag".tgz - - echo "Removing CLI workspace" - cd "$BASE_DIR" - rm -rf cli - - git add -A deps/npm - git commit -m "deps: upgrade npm to $npm_tag" - git rebase --whitespace=fix master - git push origin "npm-$npm_tag" - gh_release_body=`gh release view v"$npm_tag" -R npm/cli --json body | jq -r '.body'` - - gh pr create -R "nodejs/node" -B "$base_branch" -H "npm:npm-$npm_tag" --title "deps: upgrade npm to $npm_tag" --body "$gh_release_body" diff --git a/.gitignore b/.gitignore deleted file mode 100644 index cbcf027..0000000 --- a/.gitignore +++ /dev/null @@ -1,30 +0,0 @@ -*.swp -npm-debug.log -/.nyc_output -/test/output.log -/test/*/*/node_modules -/test/packages/npm-test-depends-on-spark/which-spark.log -/test/packages/test-package/random-data.txt -/test/root -/node_modules/.bin -/docs/output/ -/docs/node_modules/ -/man/ -/npmrc -/release/ -/npm-*.tgz -/node_modules/npm-registry-client/test/fixtures -/test/fixtures/config/userconfig-with-gc -/node_modules/npm-registry-couchapp -*.pyc -.jshintrc -.eslintrc -.nyc_output -/test/npm_cache* -/node_modules/.cache -.DS_Store -**/.DS_Store -/coverage -/*.tgz -/.editorconfig -.vscode/ \ No newline at end of file diff --git a/.mailmap b/.mailmap index 725a59d..ca878ba 100644 --- a/.mailmap +++ b/.mailmap @@ -55,6 +55,8 @@ Maximilian Antoni <mail@maxantoni.de> <maximilian.antoni@juliusbaer.com> Michael Hayes <michael@hayes.io> <mhayes@newrelic.com> Misha Kaletsky <misha.kaletsky@gmail.com> Nicolas Morel <marsup@gmail.com> +npm team <ops+robot@npmjs.com> <ops+npm-cli@npmjs.com> +npm CLI robot <npm-cli+bot@github.com> Olivier Melcher <olivier.melcher@gmail.com> Ra'Shaun Stovall <rashaunstovall@gmail.com> Rebecca Turner <me@re-becca.org> <rebecca@npmjs.com> diff --git a/.npmrc b/.npmrc index e69de29..63cd3a3 100644 --- a/.npmrc +++ b/.npmrc @@ -0,0 +1,3 @@ +; This file is automatically added by @npmcli/template-oss. Do not edit. + +package-lock=true diff --git a/.release-please-manifest.json b/.release-please-manifest.json new file mode 100644 index 0000000..354b45e --- /dev/null +++ b/.release-please-manifest.json @@ -0,0 +1,16 @@ +{ + ".": "9.2.0", + "workspaces/arborist": "6.1.5", + "workspaces/libnpmaccess": "7.0.1", + "workspaces/libnpmdiff": "5.0.6", + "workspaces/libnpmexec": "5.0.6", + "workspaces/libnpmfund": "4.0.6", + "workspaces/libnpmhook": "9.0.1", + "workspaces/libnpmorg": "5.0.1", + "workspaces/libnpmpack": "5.0.6", + "workspaces/libnpmpublish": "7.0.6", + "workspaces/libnpmsearch": "6.0.1", + "workspaces/libnpmteam": "5.0.1", + "workspaces/libnpmversion": "4.0.1", + "workspaces/config": "6.1.0" +} diff --git a/AUTHORS b/AUTHORS index 6d50365..af0d5ed 100644 --- a/AUTHORS +++ b/AUTHORS @@ -819,9 +819,51 @@ Tierney Cyren <accounts@bnb.im> Guillaume Grossetie <g.grossetie@gmail.com> linkgoron <Linkgoron@users.noreply.github.com> Quentin Barbe <forty@everteam.org> -dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Delapouite <delapouite@gmail.com> F. Hinkelmann <franziska.hinkelmann@gmail.com> Tierney Cyren <hello@bnb.im> Mohamed Akram <mohd-akram@users.noreply.github.com> Wassim Chegham <1699357+manekinekko@users.noreply.github.com> +David Chin <dlcmhd@me.com> +David Walker <d0sboots@gmail.com> +Boris Verkhovskiy <boris.verk@gmail.com> +JSKitty <jskitty@protonmail.com> +CommanderRoot <CommanderRoot@users.noreply.github.com> +Marco Tizzoni <marco.tizzoni@gmail.com> +You Nguyen <tunt081295@gmail.com> +Omri Bar-Zik <omri@bar-zik.com> +Jihun Lee <zkoong21@gmail.com> +Yonathan Randolph <yonathan@gmail.com> +Julian Møller Ellehauge <jumoel@github.com> +Lucas Werkmeister <mail@lucaswerkmeister.de> +Seth Westphal <westy92@users.noreply.github.com> +Mihai Crisan <61682879+crisanmm@users.noreply.github.com> +Kenichi Kamiya <kachick1@gmail.com> +Chen XI <xichen1427@gmail.com> +Jon Jensen <jenseng@gmail.com> +JC (Jonathan Chen) <jc@dijonkitchen.org> +MapleCCC <littlelittlemaple@gmail.com> +Patryk Ludwikowski <psychoxivi@gmail.com> +Takuya N <takninnovationresearch@gmail.com> +Neel Dani <neeldani@github.com> +Anton Rieder <1301152+aried3r@users.noreply.github.com> +William Marlow <linuxdragon@gmail.com> +KevinBrother <1301239018@qq.com> +Kyle West <kyle-west@users.noreply.github.com> +Nathan Hughes <nathan@endor.ai> +Sandeep Meduru <73886592+sandeepmeduru@users.noreply.github.com> +Kid <44045911+kidonng@users.noreply.github.com> +Hugh Lilly <hughlilly@users.noreply.github.com> +Hafizur046 <hafijurrahman046@gmail.com> +Michael Rienstra <mrienstra@gmail.com> +Juan Heyns <juanheyns@gmail.com> +Michał Kurowski <michalkurowskix@gmail.com> +giovanniPepi <gtpepi@proton.me> +Winter <winter@winter.cafe> +shalvah <diakon.ng@gmail.com> +Albert 理斯特 <shuaizhexu@gmail.com> +Gennadiy Gashev <63790536+gennadiygashev@users.noreply.github.com> +Andrew Dawes <andrewsdawes@gmail.com> +sosoba <slawomir.osoba@coig.pl> +Aron <aron@master.co> +HenryNguyen5 <6404866+HenryNguyen5@users.noreply.github.com> diff --git a/CHANGELOG.md b/CHANGELOG.md index 88cf576..bdb6c04 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,594 +1,435 @@ -## v8.5.1 (2022-02-17) +# Changelog -### Dependencies - -* [`54cda9697`](https://github.com/npm/cli/commit/54cda9697b776fae807966097315c7b836623743) - [#4410](https://github.com/npm/cli/pull/4410) - fix(arborist): do not audit in offline mode - ([@mohd-akram](https://github.com/mohd-akram)) -* [`fb13bdaf1`](https://github.com/npm/cli/commit/fb13bdaf12dde3ef5685a77354e51a9cfa579879) - [#4403](https://github.com/npm/cli/pull/4403) - deps: `@npmcli/ci-detect@2.0.0` -* [`702801002`](https://github.com/npm/cli/commit/702801002e99bf02dd4d6d1e447a5ab332d56c79) - [#4415](https://github.com/npm/cli/pull/4415) - deps: `make-fetch-happen@10.0.3` -* [`88bab3540`](https://github.com/npm/cli/commit/88bab354097023c96c49e78d7ee54159f495bf73) - [#4416](https://github.com/npm/cli/pull/4416) - deps: `gauge@4.0.1` - -### Documentation - -* [`20378c67c`](https://github.com/npm/cli/commit/20378c67cd533db514dd2aec7828c6d119e9d6c7) - [#4423](https://github.com/npm/cli/pull/4423) - docs: update documentation for ping - ([@fhinkel](https://github.com/fhinkel)) -* [`408d2fc15`](https://github.com/npm/cli/commit/408d2fc150185ef66125f7d6bdb1c25edb71bba3) - [#4426](https://github.com/npm/cli/pull/4426) - docs: update workspaces guide for consistency - ([@bnb](https://github.com/bnb)) -* [`9275856eb`](https://github.com/npm/cli/commit/9275856eb75e7c394a3c7617c2b495aba35ee2de) - [#4424](https://github.com/npm/cli/pull/4424) - docs: update usage example for npm pkg - ([@manekinekko](https://github.com/manekinekko)) -* [`20c83fae7`](https://github.com/npm/cli/commit/20c83fae76ff4a051e4f6542a328f1c00cf071bb) - [#4428](https://github.com/npm/cli/pull/4428) - docs: update docs for npm install <folder> - ([@manekinekko](https://github.com/manekinekko)) - -## v8.5.0 (2022-02-10) +## [9.2.0](https://github.com/npm/cli/compare/v9.1.3...v9.2.0) (2022-12-07) ### Features -* [`0cc9d4c51`](https://github.com/npm/cli/commit/0cc9d4c51a337af0edd2e20c6fadb26807e5d09f) - [#4372](https://github.com/npm/cli/pull/4372) - feat(deps): `@npmcli/config@3.0.0 - introduce automatic workspace roots` - ([@nlf](https://github.com/nlf)) +* [`cf57ffa`](https://github.com/npm/cli/commit/cf57ffa90088fcf5b028cc02938baae6228b5a40) [#5888](https://github.com/npm/cli/pull/5888) discrete npm doctor commands (#5888) (@wraithgar) ### Bug Fixes -* [`fb6e2ddf9`](https://github.com/npm/cli/commit/fb6e2ddf942bacf5ae745d16c2d57f3836dce75a) - [#4386](https://github.com/npm/cli/pull/4386) - fix(log): pass in logger to more external modules - ([@wraithgar](https://github.com/wraithgar)) -* [`0e231d4a4`](https://github.com/npm/cli/commit/0e231d4a40526608411aca0a6e7cf27c750f2409) - [#4389](https://github.com/npm/cli/pull/4389) - fix(pack): let libnpmpack take care of file writes - ([@nlf](https://github.com/nlf)) -* [`e2f1f7b04`](https://github.com/npm/cli/commit/e2f1f7b045a3ae9840f431cb4266ba046831247b) - [#4389](https://github.com/npm/cli/pull/4389) - fix(publish): pass dryRun: true to libnpmpack so it doesnt write a tarball - ([@nlf](https://github.com/nlf)) -* [`2937b43d4`](https://github.com/npm/cli/commit/2937b43d4629225d83b6c71833df00743209f5ff) - [#4389](https://github.com/npm/cli/pull/4389) - fix(config): add pack-destination flattener - ([@nlf](https://github.com/nlf)) - -### Documentation - -* [`b836d596f`](https://github.com/npm/cli/commit/b836d596f9d98cd7849882000cad11ad2a0b9a26) - [#4384](https://github.com/npm/cli/pull/4384) - docs: add cross-references between npx and npm exec - ([@Delapouite](https://github.com/Delapouite)) -* [`f3fbeea5a`](https://github.com/npm/cli/commit/f3fbeea5a173902ca7455c6c94a9e677591b0410) - [#4388](https://github.com/npm/cli/pull/4388) - docs: add --save-bundle to --save usage output - ([@wraithgar](https://github.com/wraithgar)) +* [`dfd5d46`](https://github.com/npm/cli/commit/dfd5d461e0ee2163e210cc136d2bb7873dfeb363) [#5932](https://github.com/npm/cli/pull/5932) ignore implicit workspaces for completion (#5932) (@wraithgar) ### Dependencies -* [`8732f393e`](https://github.com/npm/cli/commit/8732f393ee547e2eada4317613599517c1d8ec0a) - deps: `@npmcli/arborist@4.3.1` - * [`2ba09cc0d`](https://github.com/npm/cli/commit/2ba09cc0d7d56a064aa67bbb1881d381e6504888) - [#4371](https://github.com/npm/cli/pull/4371) - fix(arborist): check if a spec is a workspace before fetching a manifest, closes #3637 - ([@nlf](https://github.com/nlf)) - * [`e631faf7b`](https://github.com/npm/cli/commit/e631faf7b5f414c233d723ee11413264532b37de) - [#4387](https://github.com/npm/cli/pull/4387) - fix(arborist): save bundleDependencies to package.json when reifying - ([@wraithgar](https://github.com/wraithgar)) -* [`d3a7c15e1`](https://github.com/npm/cli/commit/d3a7c15e1e3d305a0bf781493406dfb1fdbaca35) - deps: `libnpmpack@3.1.0` - * [`4884821f6`](https://github.com/npm/cli/commit/4884821f637ca1992b494fbdbd94d000e4428a40) - [#4389](https://github.com/npm/cli/pull/4389) - feat(libnpmpack): write tarball file when dryRun === false - ([@nlf](https://github.com/nlf)) -* [`ab926995e`](https://github.com/npm/cli/commit/ab926995e43ccdd048a6e1164b436fea1940f932) - [#4393](https://github.com/npm/cli/pull/4393) - deps: `npm-registry-fetch@12.0.2` -* [`1c0d0699c`](https://github.com/npm/cli/commit/1c0d0699c13e1cb36a69f2ac4acdb78ea205aa3e) - [#4394](https://github.com/npm/cli/pull/4394) - deps: `npmlog@6.0.1` - * changed notice color from blue to cyan for improved readability -* [`3c33a5842`](https://github.com/npm/cli/commit/3c33a584213e4f2230f3b912fad2c2f5786906fb) - [#4400](https://github.com/npm/cli/pull/4400) - deps: `make-fetch-happen@10.0.2` +* [`2f2b146`](https://github.com/npm/cli/commit/2f2b1469565894ec777e6eb77fea7b607b797adb) [#5936](https://github.com/npm/cli/pull/5936) `npm-packlist@7.0.4` (#5936) +* [`372d158`](https://github.com/npm/cli/commit/372d158d2637120600a95abee64355ed1cb6f990) [#5935](https://github.com/npm/cli/pull/5935) `minimatch@5.1.1` (#5935) +* [`0e6c28b`](https://github.com/npm/cli/commit/0e6c28ba093f8c5d35df98afca28e842b247004b) [#5934](https://github.com/npm/cli/pull/5934) `ci-info@3.7.0` (#5934) +* [`0a3fe00`](https://github.com/npm/cli/commit/0a3fe000e2723ae6fdb8b1d3154fd3835057c992) [#5933](https://github.com/npm/cli/pull/5933) `minipass@4.0.0` +* [`6b77340`](https://github.com/npm/cli/commit/6b7734009ecd939fbb3d382cb92eb0cdbec7dcd3) `tar@6.1.13` +* [`cf0a174`](https://github.com/npm/cli/commit/cf0a17407abc577c27420a1c8a4a0c08c7cefce9) `ssri@10.0.1` +* [`3da9a1a`](https://github.com/npm/cli/commit/3da9a1a4ebcf1779035b5f9ae985c087f617efe3) `pacote@15.0.7` +* [`fee9b66`](https://github.com/npm/cli/commit/fee9b6686892a1c7f976c36ddd5d89b70c416817) `npm-registry-fetch@14.0.3` +* [`e940917`](https://github.com/npm/cli/commit/e940917befcdaf44ee7e24d31b540f4de8507734) `cacache@17.0.3` +* [`875bd56`](https://github.com/npm/cli/commit/875bd56c33ca5eef80c2a50a11808445f2a39a2a) `npm-package-arg@10.1.0` +* [`280b7a4`](https://github.com/npm/cli/commit/280b7a445e4a83d70980cf3c436745a1faa50c67) [#5927](https://github.com/npm/cli/pull/5927) `npm-packlist@7.0.3` +* [Workspace](https://github.com/npm/cli/releases/tag/arborist-v6.1.5): `@npmcli/arborist@6.1.5` +* [Workspace](https://github.com/npm/cli/releases/tag/libnpmaccess-v7.0.1): `libnpmaccess@7.0.1` +* [Workspace](https://github.com/npm/cli/releases/tag/libnpmdiff-v5.0.6): `libnpmdiff@5.0.6` +* [Workspace](https://github.com/npm/cli/releases/tag/libnpmexec-v5.0.6): `libnpmexec@5.0.6` +* [Workspace](https://github.com/npm/cli/releases/tag/libnpmfund-v4.0.6): `libnpmfund@4.0.6` +* [Workspace](https://github.com/npm/cli/releases/tag/libnpmhook-v9.0.1): `libnpmhook@9.0.1` +* [Workspace](https://github.com/npm/cli/releases/tag/libnpmorg-v5.0.1): `libnpmorg@5.0.1` +* [Workspace](https://github.com/npm/cli/releases/tag/libnpmpack-v5.0.6): `libnpmpack@5.0.6` +* [Workspace](https://github.com/npm/cli/releases/tag/libnpmpublish-v7.0.6): `libnpmpublish@7.0.6` +* [Workspace](https://github.com/npm/cli/releases/tag/libnpmsearch-v6.0.1): `libnpmsearch@6.0.1` +* [Workspace](https://github.com/npm/cli/releases/tag/libnpmteam-v5.0.1): `libnpmteam@5.0.1` -## v8.4.1 (2022-02-03) +## [9.1.3](https://github.com/npm/cli/compare/v9.1.2...v9.1.3) (2022-11-30) ### Bug Fixes -* [`1b9338554`](https://github.com/npm/cli/commit/1b9338554fc006954fae54c25c33e64e26ae997e) - [#4359](https://github.com/npm/cli/pull/4359) - fix(log): pass in logger to external modules - ([@wraithgar](https://github.com/wraithgar)) -* [`457e0ae61`](https://github.com/npm/cli/commit/457e0ae61bbc55846f5af44afa4066921923490f) - [#4363](https://github.com/npm/cli/pull/4363) - fix(ci): lock file validation - ([@ruyadorno](https://github.com/ruyadorno)) -* [`c0519edc1`](https://github.com/npm/cli/commit/c0519edc16f66370b2153430342247b4ec5cb496) - [#4364](https://github.com/npm/cli/pull/4364) - fix(ci): should not use package-lock config - ([@ruyadorno](https://github.com/ruyadorno)) -* [`ebb428375`](https://github.com/npm/cli/commit/ebb428375cd417c096d5a648df92620dc4215a3d) - [#4365](https://github.com/npm/cli/pull/4365) - fix(outdated): parse aliased modules - ([@ruyadorno](https://github.com/ruyadorno)) +* [`ffbdea2`](https://github.com/npm/cli/commit/ffbdea286a08eeaf40ab83eea5bfe0602dc6bbcd) [#5894](https://github.com/npm/cli/pull/5894) npm pack filename on scoped packages (#5894) (@HenryNguyen5) +* [`c26d708`](https://github.com/npm/cli/commit/c26d708428a96da530092759b5ff6d67c7282348) [#5884](https://github.com/npm/cli/pull/5884) validate username at get-identity (#5884) (@sosoba, @nlf) ### Documentation -* [`0b0a7cc76`](https://github.com/npm/cli/commit/0b0a7cc767947ea738da50caa832d8a922e20ac6) - [#4361](https://github.com/npm/cli/pull/4361) - docs: bundleDependencies can be a boolean. - ([@forty](https://github.com/forty)) +* [`ea948dc`](https://github.com/npm/cli/commit/ea948dceac5cfeef437c97874ab26c3275e75766) [#5881](https://github.com/npm/cli/pull/5881) update description of npm exec (#5881) (@styfle, @wraithgar) +* [`40f2c21`](https://github.com/npm/cli/commit/40f2c213d75a252665311b4f8775d297390aeb70) [#5865](https://github.com/npm/cli/pull/5865) ci-info url (#5865) (@wraithgar) +* [`681a45b`](https://github.com/npm/cli/commit/681a45bb48acd57aa64cb3241ea4915f5a12e029) [#5875](https://github.com/npm/cli/pull/5875) run the comand for directory workspaces (#5875) (@1aron) +* [`681a45b`](https://github.com/npm/cli/commit/681a45bb48acd57aa64cb3241ea4915f5a12e029) [#5875](https://github.com/npm/cli/pull/5875) add workspace directory example (#5875) (@1aron) ### Dependencies -* [`3d41447b9`](https://github.com/npm/cli/commit/3d41447b961a72f1ce541fea252d0cd462399c76) - [#4353](https://github.com/npm/cli/pull/4353) - deps: `wide-align@1.1.5` -* [`dc1a0573a`](https://github.com/npm/cli/commit/dc1a0573ace328d985a741af76d03752b1dbf1ff) - [#4353](https://github.com/npm/cli/pull/4353) - deps: `socks-proxy-agent@6.1.1` -* [`adcefef6b`](https://github.com/npm/cli/commit/adcefef6b953e0804f4a2de3a1912321f44c4a7e) - [#4353](https://github.com/npm/cli/pull/4353) - deps: `spdx-license-ids@3.0.11` -* [`d7e2499e0`](https://github.com/npm/cli/commit/d7e2499e073301a62607266d3ab8f9b63d630fb5) - [#4353](https://github.com/npm/cli/pull/4353) - deps: `debug@4.3.3` -* [`f0f307140`](https://github.com/npm/cli/commit/f0f30714002db979a2707d85c65bb92ae0ff76fe) - [#4353](https://github.com/npm/cli/pull/4353) - deps: `@npmcli/fs@1.1.0` -* [`1cb107d33`](https://github.com/npm/cli/commit/1cb107d33d7e1499d92c3405fa0694142bdee8df) - [#4353](https://github.com/npm/cli/pull/4353) - deps: `is-core-module@2.8.1` -* [`e198ac0d1`](https://github.com/npm/cli/commit/e198ac0d1c1e536db57e84af6e7f40089b4c1bfc) - [#4354](https://github.com/npm/cli/pull/4354) - deps: `cli-table3@0.6.1` -* [`5a84e6515`](https://github.com/npm/cli/commit/5a84e6515a0331be20395ce2a6b1e892ecea20f8) - [#4355](https://github.com/npm/cli/pull/4355) - deps: `graceful-fs@4.2.9` +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.3...arborist-v6.1.4): `@npmcli/arborist@6.1.4` +* [Workspace](https://github.com/npm/cli/compare/libnpmdiff-v5.0.4...libnpmdiff-v5.0.5): `libnpmdiff@5.0.5` +* [Workspace](https://github.com/npm/cli/compare/libnpmexec-v5.0.4...libnpmexec-v5.0.5): `libnpmexec@5.0.5` +* [Workspace](https://github.com/npm/cli/compare/libnpmfund-v4.0.4...libnpmfund-v4.0.5): `libnpmfund@4.0.5` +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.4...libnpmpack-v5.0.5): `libnpmpack@5.0.5` +* [Workspace](https://github.com/npm/cli/compare/libnpmpublish-v7.0.4...libnpmpublish-v7.0.5): `libnpmpublish@7.0.5` -## v8.4.0 (2022-01-27) +## [9.1.2](https://github.com/npm/cli/compare/v9.1.1...v9.1.2) (2022-11-16) + +### Bug Fixes + +* [`d9654cf`](https://github.com/npm/cli/commit/d9654cffd7024ec2d068147868978fc994d696e4) [#5861](https://github.com/npm/cli/pull/5861) remove unwanted package.json entries (#5861) (@wraithgar) + +### Dependencies + +* [`a351685`](https://github.com/npm/cli/commit/a351685c4951b1d9e2ba86bc99e3706688813438) [#5858](https://github.com/npm/cli/pull/5858) move from @npmcli/ci-detect to ci-info (#5858) +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.2...arborist-v6.1.3): `@npmcli/arborist@6.1.3` +* [Workspace](https://github.com/npm/cli/compare/libnpmdiff-v5.0.3...libnpmdiff-v5.0.4): `libnpmdiff@5.0.4` +* [Workspace](https://github.com/npm/cli/compare/libnpmexec-v5.0.3...libnpmexec-v5.0.4): `libnpmexec@5.0.4` +* [Workspace](https://github.com/npm/cli/compare/libnpmfund-v4.0.3...libnpmfund-v4.0.4): `libnpmfund@4.0.4` +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.3...libnpmpack-v5.0.4): `libnpmpack@5.0.4` +* [Workspace](https://github.com/npm/cli/compare/libnpmpublish-v7.0.3...libnpmpublish-v7.0.4): `libnpmpublish@7.0.4` + +## [9.1.1](https://github.com/npm/cli/compare/v9.1.0...v9.1.1) (2022-11-09) + +### Documentation + +* [`1bff064`](https://github.com/npm/cli/commit/1bff0640ccb8414e2d416a5cf9d64e9ff03c6403) [#5819](https://github.com/npm/cli/pull/5819) config: document `npm config fix` (#5819) (@wraithgar) + +### Dependencies + +* [`335c7e4`](https://github.com/npm/cli/commit/335c7e4348f5505fad33b8a78348a02a82b91426) [#5813](https://github.com/npm/cli/pull/5813) `cacache@17.0.2` +* [`878ddfb`](https://github.com/npm/cli/commit/878ddfb5b68c03bdcd7d7da8dae92c4947942801) `@npmcli/fs@3.1.0` +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.1...arborist-v6.1.2): `@npmcli/arborist@6.1.2` +* [Workspace](https://github.com/npm/cli/compare/libnpmdiff-v5.0.2...libnpmdiff-v5.0.3): `libnpmdiff@5.0.3` +* [Workspace](https://github.com/npm/cli/compare/libnpmexec-v5.0.2...libnpmexec-v5.0.3): `libnpmexec@5.0.3` +* [Workspace](https://github.com/npm/cli/compare/libnpmfund-v4.0.2...libnpmfund-v4.0.3): `libnpmfund@4.0.3` +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.2...libnpmpack-v5.0.3): `libnpmpack@5.0.3` +* [Workspace](https://github.com/npm/cli/compare/libnpmpublish-v7.0.2...libnpmpublish-v7.0.3): `libnpmpublish@7.0.3` + +## [9.1.0](https://github.com/npm/cli/compare/v9.0.1...v9.1.0) (2022-11-02) ### Features -* [`fbe48a840`](https://github.com/npm/cli/commit/fbe48a84047e0c5de31bdaa84707f0f8fdcef71d) - [#4307](https://github.com/npm/cli/pull/4307) - feat(arborist): add named updates validation - ([@ruyadorno](https://github.com/ruyadorno)) +* [`706b3d3`](https://github.com/npm/cli/commit/706b3d3f227de43a095263926d2eef2b4e4cf2a9) [#5779](https://github.com/npm/cli/pull/5779) set --no-audit when installing outside of a project (like --global) (@fritzy) ### Bug Fixes -* [`1f853f8bf`](https://github.com/npm/cli/commit/1f853f8bf7cecd1222703dde676a4b664526141d) - [#4306](https://github.com/npm/cli/pull/4306) - fix(arborist): load actual tree on named updates - ([@ruyadorno](https://github.com/ruyadorno)) -* [`90c384ccc`](https://github.com/npm/cli/commit/90c384ccccac32c80c481a04c438cbcbea82539c) - [#4326](https://github.com/npm/cli/pull/4326) - fix(logout): require proper auth.js from npm-registry-fetch - ([@wraithgar](https://github.com/wraithgar)) -* [`fabcf431a`](https://github.com/npm/cli/commit/fabcf431a63ecf93b56ae5d9a05ad4e7ef280c2a) - [#4327](https://github.com/npm/cli/pull/4327) - fix(arborist): correctly load overrides on workspace edges, closes #4205 - ([@nlf](https://github.com/nlf)) -* [`8c3b143ca`](https://github.com/npm/cli/commit/8c3b143ca20d0da56c0ce2764e288a4c203b9f93) - [#4258](https://github.com/npm/cli/pull/4258) - fix(arborist): shrinkwrap throws when trying to read a folder without permissions - ([@Linkgoron](https://github.com/Linkgoron)) -* [`b51b29c56`](https://github.com/npm/cli/commit/b51b29c563fa97aa4fbf38250d1f04e879a8d961) - [#4334](https://github.com/npm/cli/pull/4334) - fix(arborist): update save exact - ([@ruyadorno](https://github.com/ruyadorno)) - -### Dependencies - -* [`8558527c7`](https://github.com/npm/cli/commit/8558527c7158b2c1c353f8ab9c31de2a66ab470e) - [#4333](https://github.com/npm/cli/pull/4333) - deps: `make-fetch-happen@10.0.0` - * compress option and accept/content encoding header edge cases - * strip cookie header on redirect across hostnames -* [`1bfc507f2`](https://github.com/npm/cli/commit/1bfc507f2a5afa02f04d4dea2fc6d151d4fef3ac) - [#4326](https://github.com/npm/cli/pull/4326) - deps: `npm-registry-fetch@12.0.1` -* [`52c9608e7`](https://github.com/npm/cli/commit/52c9608e7bb1cda396b2cef3fc1b48dbaa2b7de3) - [#4326](https://github.com/npm/cli/pull/4326) - deps: `pacote@12.0.3` -* [`2bbeedfeb`](https://github.com/npm/cli/commit/2bbeedfebb3aea082d612deb5e4d9de9e550c529) - [#4326](https://github.com/npm/cli/pull/4326) - deps: `npm-profile@6.0.0` -* [`9652d685b`](https://github.com/npm/cli/commit/9652d685b1e4bd21cec107a611c2e307387623d6) - chore(release): `@npmcli/arborist@4.3.0` - ([@wraithgar](https://github.com/wraithgar)) -* [`0ee4927d2`](https://github.com/npm/cli/commit/0ee4927d2e8206dd24fa7eea5e1c10ea649ecc49) - chore(release): `libnpmaccess@5.0.1` - ([@wraithgar](https://github.com/wraithgar)) -* [`6c0dc1ffb`](https://github.com/npm/cli/commit/6c0dc1ffb70858be1e9ca9afdb6950e39609a367) - chore(release): `libnpmexec@3.0.3` - ([@wraithgar](https://github.com/wraithgar)) -* [`41b8f7b6f`](https://github.com/npm/cli/commit/41b8f7b6ff62f0e738865eb8e98df8650f5467bd) - chore(release): `libnpmorg@3.0.1` - ([@wraithgar](https://github.com/wraithgar)) -* [`433e6aafb`](https://github.com/npm/cli/commit/433e6aafbbf56efcf71e991767a6f00afe4aba7c) - chore(release): `libnpmpublish@5.0.1` - ([@wraithgar](https://github.com/wraithgar)) -* [`6654b6efe`](https://github.com/npm/cli/commit/6654b6efe02666bdb9864f4608e477ba132fd215) - chore(release): `libnpmsearch@4.0.1` - ([@wraithgar](https://github.com/wraithgar)) -* [`3423a9804`](https://github.com/npm/cli/commit/3423a980436492b7f0ee9e002517387a801f4f4a) - chore(release): `libnpmteam@3.0.1` - ([@wraithgar](https://github.com/wraithgar)) -* [`fb03e485d`](https://github.com/npm/cli/commit/fb03e485d9b1f09eb1cbcce00ee8e3e5c012097f) - chore(release): `libnpmhook@7.0.1` - ([@wraithgar](https://github.com/wraithgar)) - -## v8.3.2 (2022-01-20) - -### Bug Fixes - -* [`cfd59b8c8`](https://github.com/npm/cli/commit/cfd59b8c81078f842328b13a23a234150842cd58) - [#4223](https://github.com/npm/cli/pull/4223) - fix: npm update --save - ([@ruyadorno](https://github.com/ruyadorno)) -* [`510f0ecbc`](https://github.com/npm/cli/commit/510f0ecbc9970ed8c8993107cc03cf27b7b996dc) - [#4218](https://github.com/npm/cli/pull/4218) - fix(arborist): ensure indentation is preserved - ([@ljharb](https://github.com/ljharb)) -* [`c99c2151a`](https://github.com/npm/cli/commit/c99c2151a868672c017f64ff0ecb12149a2fb095) - [#4230](https://github.com/npm/cli/pull/4230) - fix(arborist): prioritize valid workspace nodes - ([@nlf](https://github.com/nlf)) -* [`14a3d9500`](https://github.com/npm/cli/commit/14a3d95000f1cba937f3309d198a363ae65cf01f) - [#4265](https://github.com/npm/cli/pull/4265) - fix: resolve workspace paths from cwd when possible - ([@nlf](https://github.com/nlf)) - -### Dependencies - -* [`2ef9f9847`](https://github.com/npm/cli/commit/2ef9f9847c11fe8c0c0494558fe77c15ac4dbc80) - [#4254](https://github.com/npm/cli/pull/4254) - deps: `bin-links@3.0.0 write-file-atomic@4.0.0` - -## v8.3.1 (2022-01-13) - -### Bug Fixes - -* [`2ac540b0c`](https://github.com/npm/cli/commit/2ac540b0ccd016a14676ad891758e8d9e903a12c) - fix(unpublish): Show warning on unpublish command when last version (#4191) - ([@ebsaral](https://github.com/ebsaral)) - -### Dependencies - -* [`da80d579d`](https://github.com/npm/cli/commit/da80d579d1f1db61894c54f7b9b3623394882c16) - [#4211](https://github.com/npm/cli/pull/4211) - deps: `hosted-git-info@4.1.0` - * feat: Support Sourcehut -* [`5a87d190f`](https://github.com/npm/cli/commit/5a87d190f38af9f2f98084d9b476184dbcaf1429) - [#4228](https://github.com/npm/cli/pull/4228) - deps: `@npmcli/config@2.4.0` -* [`1f0d1370f`](https://github.com/npm/cli/commit/1f0d1370ff6bf2ca978ef0d7d32640314c62204e) - chore(release): `@npmcli/arborist@4.2.0` - * [`3cfae3840`](https://github.com/npm/cli/commit/3cfae384011a8b291cc82cc02b56bc114557a9e5) - [#4181](https://github.com/npm/cli/pull/4181) - feat(arborist) add `toJSON`/`toString` methods to get shrinkwrap contents without saving - ([@ljharb](https://github.com/ljharb)) - -### Chores - -* [`d72650457`](https://github.com/npm/cli/commit/d7265045730555c03b3142c004c7438e9577028c) - chore: Bring in all libnpm modules + arborist as workspaces (#4166) - ([@fritzy](https://github.com/fritzy)) - - -## v8.3.0 (2021-12-09) - -### Features - -* [`4b0c29a7c`](https://github.com/npm/cli/commit/4b0c29a7c5860410c7b453bec389c54cb21dbde3) - [#4116](https://github.com/npm/cli/issues/4116) - feat: `@npmcli/arborist@4.1.0` - * introduces overrides - ([@nlf](https://github.com/nlf)) -* [`166d9e144`](https://github.com/npm/cli/commit/166d9e144b38087ee5e7d8aaf6ec7d602cf2957c) - [npm/statusboard#416](https://github.com/npm/statusboard/issues/416) - [#4143](https://github.com/npm/cli/issues/4143) - feat: output configured registry during publish - ([@lukekarrys](https://github.com/lukekarrys)) -* [`71777be17`](https://github.com/npm/cli/commit/71777be17e57179d203cb9162664ecd0c36ca633) - [npm/statusboard#417](https://github.com/npm/statusboard/issues/417) - [#4146](https://github.com/npm/cli/issues/4146) - feat: display `publishConfig` during `config list` - ([@lukekarrys](https://github.com/lukekarrys)) - -### Bug Fixes - -* [`08c663931`](https://github.com/npm/cli/commit/08c663931ec1f56d777ffdb38f94926b9eac13ef) - [#4128](https://github.com/npm/cli/issues/4128) - [#4134](https://github.com/npm/cli/issues/4134) - fix: dont warn on error cleaning individual log files - ([@lukekarrys](https://github.com/lukekarrys)) -* [`e605b128c`](https://github.com/npm/cli/commit/e605b128c87620aae843cdbd8f35cc614da3f8a2) - [#4142](https://github.com/npm/cli/issues/4142) - fix: redact all private keys from config output - ([@lukekarrys](https://github.com/lukekarrys)) +* [`1f5382d`](https://github.com/npm/cli/commit/1f5382dada181cda41f1504974de1e69a6c1ad7f) [#5789](https://github.com/npm/cli/pull/5789) don't set `stdioString` for any spawn/run-script calls (@lukekarrys) +* [`8fd614a`](https://github.com/npm/cli/commit/8fd614af5d6de970a6bbcffc538564d2a809411a) use promiseSpawn.open instead of opener (@nlf) +* [`41843ad`](https://github.com/npm/cli/commit/41843ad8a20bd20aacad2bb37fe473f2e76d5306) use an absolute path to notepad.exe by default, correct docs (@nlf) +* [`0c5834e`](https://github.com/npm/cli/commit/0c5834ed635833ef49fe10cc888025a5debebe21) [#5758](https://github.com/npm/cli/pull/5758) use hosted-git-info to parse registry urls (#5758) (@lukekarrys) ### Documentation -* [`db1885d7f`](https://github.com/npm/cli/commit/db1885d7fec012f018093c76dec5a9c01a0ca2b0) - [#4092](https://github.com/npm/cli/issues/4092) - chore(docs): document overrides - ([@nlf](https://github.com/nlf)) +* [`ce6745c`](https://github.com/npm/cli/commit/ce6745c806d721f5e3c455a65fd44bfe03e9d2ae) [#5763](https://github.com/npm/cli/pull/5763) fixed some typos (#5763) (@AndrewDawes) ### Dependencies -* [`e1da1fa4b`](https://github.com/npm/cli/commit/e1da1fa4ba7d95616928d2192b5b9db09b3120bc) - [#4141](https://github.com/npm/cli/issues/4141) - deps: `@npmcli/arborist@4.1.1`: `parse-conflict-json@2.0.1` - * Fixes object property assignment bug in resolving package-locks with - conflicts -* [`1d8bec566`](https://github.com/npm/cli/commit/1d8bec566cb08ff5ff220f53083323fa8c3fb72e) - [#4144](https://github.com/npm/cli/issues/4144) - [#3884](https://github.com/npm/cli/issues/3884) - deps: `minipass@3.1.6` - * fixes some TAR_ENTRY_INVALID and Z_DATA_ERROR errors +* [`b89c19e`](https://github.com/npm/cli/commit/b89c19e9a7674b0bd9d336c14dee1bf381843648) [#5795](https://github.com/npm/cli/pull/5795) `cli-table3@0.6.3` +* [`6b6dfca`](https://github.com/npm/cli/commit/6b6dfca191cb8f7871f755b926fd5ae223ba697a) `fastest-levenshtein@1.0.16` +* [`9972ed1`](https://github.com/npm/cli/commit/9972ed1423d7a4f7ca03a34f5aa69321b81850fd) `@npmcli/ci-detect@3.0.1` +* [`024e612`](https://github.com/npm/cli/commit/024e612f55fc9906b49065dbabbee8b8261eb4eb) `abbrev@2.0.0` +* [`66f9bcd`](https://github.com/npm/cli/commit/66f9bcd10b8d8cb635593c526727056581c7955d) `nopt@7.0.0` +* [`5730d17`](https://github.com/npm/cli/commit/5730d17198e066077cb3ea6f78753746afc13603) `tar@6.1.12` +* [`2fef570`](https://github.com/npm/cli/commit/2fef570caf00bd92a3a4cf0b2bc4ce56fd8bd594) `node-gyp@9.3.0` +* [`abfb28b`](https://github.com/npm/cli/commit/abfb28b249183b8c033f8e7acc1546150cdac137) `@npmcli/run-script@6.0.0` +* [`205e2fd`](https://github.com/npm/cli/commit/205e2fdde91f4f21d92ccf0bf9e1ab9ab3053167) `pacote@15.0.6` +* [`ac25863`](https://github.com/npm/cli/commit/ac25863a33b75620ac9edf4057bfb9409028636a) remove opener, `@npmcli/promise-spawn@6.0.1`, `@npmcli/run-script@5.1.1`, `@npmcli/git@4.0.3`, `pacote@15.0.5`, `which@3.0.0` +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.0...arborist-v6.1.1): `@npmcli/arborist@6.1.1` +* [Workspace](https://github.com/npm/cli/compare/config-v6.0.1...config-v6.1.0): `@npmcli/config@6.1.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmdiff-v5.0.1...libnpmdiff-v5.0.2): `libnpmdiff@5.0.2` +* [Workspace](https://github.com/npm/cli/compare/libnpmexec-v5.0.1...libnpmexec-v5.0.2): `libnpmexec@5.0.2` +* [Workspace](https://github.com/npm/cli/compare/libnpmfund-v4.0.1...libnpmfund-v4.0.2): `libnpmfund@4.0.2` +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.1...libnpmpack-v5.0.2): `libnpmpack@5.0.2` +* [Workspace](https://github.com/npm/cli/compare/libnpmpublish-v7.0.1...libnpmpublish-v7.0.2): `libnpmpublish@7.0.2` +* [Workspace](https://github.com/npm/cli/compare/libnpmversion-v4.0.0...libnpmversion-v4.0.1): `libnpmversion@4.0.1` -## v8.2.0 (2021-12-02) - -### Features - -* [`6734ba36d`](https://github.com/npm/cli/commit/6734ba36dd6e07a859ab4d6eb4f264d2c0022276) - [#4062](https://github.com/npm/cli/issues/4062) - feat: streaming debug logfile - ([@lukekarrys](https://github.com/lukekarrys)) - -### Bug Fixes - -* [`5f4040aa0`](https://github.com/npm/cli/commit/5f4040aa0e30a3b74caab64958770c682e4d0031) - chore: remove get-project-scope utils - ([@Yucel Okcu](https://github.com/Yucel Okcu)) -* [`c5c6d1603`](https://github.com/npm/cli/commit/c5c6d1603b06df4c10b503047aeed34d6e0c36c2) - [#4060](https://github.com/npm/cli/issues/4060) - fix: add missing scope on flat options - ([@yuqu](https://github.com/yuqu)) -* [`47828b766`](https://github.com/npm/cli/commit/47828b766a4a7b50c1245c8f01b99ffbeffd014f) - chore: update one-time password prompt - ([@Darcy Clarke](https://github.com/Darcy Clarke)) +## [9.0.1](https://github.com/npm/cli/compare/v9.0.0...v9.0.1) (2022-10-26) ### Documentation -* [`fc46a7926`](https://github.com/npm/cli/commit/fc46a792621c89354eddc0e1ee2d4f5c26efe5a5) - [#4072](https://github.com/npm/cli/issues/4072) - docs: fix typo in `save-peer` description - ([@chalkygames123](https://github.com/chalkygames123)) -* [`2fbf1576f`](https://github.com/npm/cli/commit/2fbf1576f5427babab2bdf314b1760adc5f9a575) - [#4081](https://github.com/npm/cli/issues/4081) - docs: Fix typo - ([@idleberg](https://github.com/idleberg)) -* [`a8bc95f11`](https://github.com/npm/cli/commit/a8bc95f11c9d21319581d7b09baf9f864bea21ac) - [#4089](https://github.com/npm/cli/issues/4089) - docs(workspaces): Fix typo - ([@yotamselementor](https://github.com/yotamselementor)) -* [`31b098ee2`](https://github.com/npm/cli/commit/31b098ee26ed17facb132278bb3205e80e2a760d) - [#4113](https://github.com/npm/cli/issues/4113) - docs: add logging docs - ([@darcyclarke](https://github.com/darcyclarke)) -* [`cbae0fb71`](https://github.com/npm/cli/commit/cbae0fb71cea55004f7066c0dfc870137b53ee8b) - [#4114](https://github.com/npm/cli/issues/4114) - docs: update description about where/when debug log is written - ([@lukekarrys](https://github.com/lukekarrys)) +* [`b5fadd0`](https://github.com/npm/cli/commit/b5fadd0cec392f4bf6d60fa1358f96400be94667) [#5742](https://github.com/npm/cli/pull/5742) Better npx link (#5742) (@mrienstra) + +### Dependencies + +* [`de6618e`](https://github.com/npm/cli/commit/de6618e93182ba00b4be516db1efb3c51efa17ba) [#5757](https://github.com/npm/cli/pull/5757) `@npmcli/promise-spawn@5.0.0` (#5757) +* [`5625274`](https://github.com/npm/cli/commit/562527456d3862d871d042fa4ff6e38354e320ea) [#5755](https://github.com/npm/cli/pull/5755) `hosted-git-info@6.1.0` (#5755) +* [`32bdd68`](https://github.com/npm/cli/commit/32bdd686ccf826050075e770ffddf7401efa79c9) [#5754](https://github.com/npm/cli/pull/5754) `npm-packlist@7.0.2` (#5754) +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0...arborist-v6.1.0): `@npmcli/arborist@6.1.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmdiff-v5.0.0...libnpmdiff-v5.0.1): `libnpmdiff@5.0.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmexec-v5.0.0...libnpmexec-v5.0.1): `libnpmexec@5.0.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmfund-v4.0.0...libnpmfund-v4.0.1): `libnpmfund@4.0.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.0...libnpmpack-v5.0.1): `libnpmpack@5.0.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0...libnpmpublish-v7.0.1): `libnpmpublish@7.0.1` + +## [9.0.0](https://github.com/npm/cli/compare/v9.0.0-pre.6...v9.0.0) (2022-10-19) + +### Features + +* [`e3b004c`](https://github.com/npm/cli/commit/e3b004c0d6dfcb153c4734af12afb09897e20932) [#5727](https://github.com/npm/cli/pull/5727) move cli and all workspaces out of prerelease mode (@lukekarrys) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.5...arborist-v6.0.0): `@npmcli/arborist@6.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmaccess-v7.0.0-pre.2...libnpmaccess-v7.0.0): `libnpmaccess@7.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmdiff-v5.0.0-pre.3...libnpmdiff-v5.0.0): `libnpmdiff@5.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.5...libnpmexec-v5.0.0): `libnpmexec@5.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.5...libnpmfund-v4.0.0): `libnpmfund@4.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmhook-v9.0.0-pre.1...libnpmhook-v9.0.0): `libnpmhook@9.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmorg-v5.0.0-pre.1...libnpmorg-v5.0.0): `libnpmorg@5.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.4...libnpmpack-v5.0.0): `libnpmpack@5.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0-pre.4...libnpmpublish-v7.0.0): `libnpmpublish@7.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmsearch-v6.0.0-pre.1...libnpmsearch-v6.0.0): `libnpmsearch@6.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmteam-v5.0.0-pre.1...libnpmteam-v5.0.0): `libnpmteam@5.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmversion-v4.0.0-pre.1...libnpmversion-v4.0.0): `libnpmversion@4.0.0` + +## [9.0.0-pre.6](https://github.com/npm/cli/compare/v9.0.0-pre.5...v9.0.0-pre.6) (2022-10-19) + +### ⚠️ BREAKING CHANGES + +* `npm` now outputs some json errors on stdout. Previously `npm` would output all json formatted errors on stderr, making it difficult to parse as the stderr stream usually has logs already written to it. In the future, `npm` will differentiate between errors and crashes. Errors, such as `E404` and `ERESOLVE`, will be handled and will continue to be output on stdout. In the case of a crash, `npm` will log the error as usual but will not attempt to display it as json, even in `--json` mode. Moving a case from the category of an error to a crash will not be considered a breaking change. For more information see npm/rfcs#482. +* `npm config set` will no longer accept deprecated or invalid config options. +* `timing` and `loglevel` changes + - `timing` has been removed as a value for `--loglevel` + - `--timing` will show timing information regardless of + `--loglevel`, except when `--silent` +* deprecate boolean install flags in favor of `--install-strategy` + * deprecate --global-style, --global now sets --install-strategy=shallow + * deprecate --legacy-bundling, now sets --install-strategy=nested +* npm will no longer attempt to modify ownership of files it creates +* this package no longer attempts to change file ownership automatically +* this package no longer attempts to change file ownership automatically + +### Features + +* [`d3543e9`](https://github.com/npm/cli/commit/d3543e945e721783dcb83385935f282a4bb32cf3) output json formatted errors on stdout (#5716) (@lukekarrys) +* [`be642c6`](https://github.com/npm/cli/commit/be642c6b8e3df40fd43b0110b30d3ecd44086016) refuse to set deprecated/invalid config (#5719) (@wraithgar) +* [`332914b`](https://github.com/npm/cli/commit/332914b48b616099e586893b1df21480b7ddb733) separate configs for `--timing` and `--loglevel` (@lukekarrys) +* [`f653785`](https://github.com/npm/cli/commit/f6537855e1a34b84251993a49e1ee362082ada37) deprecated `key`, `cert` config options and updated registry scoped auth docs (@fritzy) +* [`de2d33f`](https://github.com/npm/cli/commit/de2d33f3ed42e187803bdd31db4f7a12f08f353c) add --install-strategy=hoisted|nested|shallow, deprecate --global-style, --legacy-bundling (#5709) (@fritzy) +* [`58065bc`](https://github.com/npm/cli/commit/58065bc679e6968742b5b15fa2fb82dd9e8ae988) [#5704](https://github.com/npm/cli/pull/5704) do not alter file ownership (@nlf) +* [`475e9b6`](https://github.com/npm/cli/commit/475e9b6c0c978a104dd2ee47bde22b0a031a95f9) [#5703](https://github.com/npm/cli/pull/5703) do not alter file ownership (@nlf) + +### Bug Fixes + +* [`6ffa5b7`](https://github.com/npm/cli/commit/6ffa5b7bbb8fd7cae1a0b955a1f762661ec5e9ed) `npm hook ls` duplicates hook name prefixes (#5295) (@gennadiygashev) +* [`1afe5ba`](https://github.com/npm/cli/commit/1afe5ba9647d1f0f55bf0a4bace543965d05daed) account for new npm-package-arg behavior (@wraithgar) +* [`353b5bb`](https://github.com/npm/cli/commit/353b5bb92c3f7899526536b597252b44aa8a712d) [#5710](https://github.com/npm/cli/pull/5710) remove chownr and mkdirp-infer-owner (@nlf) + +### Documentation + +* [`9e74d3e`](https://github.com/npm/cli/commit/9e74d3e847c4bc0abc630fbe81328e011d6f0187) update supported engines in readme (#5725) (@lukekarrys) + +### Dependencies + +* [`88137a3`](https://github.com/npm/cli/commit/88137a329c8ad418db265dd465768a7cf5ebccb1) `npmlog@7.0.1` +* [`2008ea6`](https://github.com/npm/cli/commit/2008ea6a807acbd97912799adfe97f276202cea6) `npm-package-arg@10.0.0`, `pacote@15.0.2` +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.4...arborist-v6.0.0-pre.5): `@npmcli/arborist@6.0.0-pre.5` +* [Workspace](https://github.com/npm/cli/compare/libnpmaccess-v7.0.0-pre.1...libnpmaccess-v7.0.0-pre.2): `libnpmaccess@7.0.0-pre.2` +* [Workspace](https://github.com/npm/cli/compare/libnpmdiff-v5.0.0-pre.2...libnpmdiff-v5.0.0-pre.3): `libnpmdiff@5.0.0-pre.3` +* [Workspace](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.4...libnpmexec-v5.0.0-pre.5): `libnpmexec@5.0.0-pre.5` +* [Workspace](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.4...libnpmfund-v4.0.0-pre.5): `libnpmfund@4.0.0-pre.5` +* [Workspace](https://github.com/npm/cli/compare/libnpmhook-v9.0.0-pre.0...libnpmhook-v9.0.0-pre.1): `libnpmhook@9.0.0-pre.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmorg-v5.0.0-pre.0...libnpmorg-v5.0.0-pre.1): `libnpmorg@5.0.0-pre.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.3...libnpmpack-v5.0.0-pre.4): `libnpmpack@5.0.0-pre.4` +* [Workspace](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0-pre.3...libnpmpublish-v7.0.0-pre.4): `libnpmpublish@7.0.0-pre.4` +* [Workspace](https://github.com/npm/cli/compare/libnpmsearch-v6.0.0-pre.0...libnpmsearch-v6.0.0-pre.1): `libnpmsearch@6.0.0-pre.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmteam-v5.0.0-pre.0...libnpmteam-v5.0.0-pre.1): `libnpmteam@5.0.0-pre.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmversion-v4.0.0-pre.0...libnpmversion-v4.0.0-pre.1): `libnpmversion@4.0.0-pre.1` + +## [9.0.0-pre.5](https://github.com/npm/cli/compare/v9.0.0-pre.4...v9.0.0-pre.5) (2022-10-13) + +### ⚠️ BREAKING CHANGES + +* the presence of auth related settings that are not scoped to a specific registry found in a config file is no longer supported and will throw errors +* the `node-version` and `npm-version` configs have been removed. +* links generated from git urls will now use `HEAD` instead of `master` as the default ref + +### Features + +* [`a09e19d`](https://github.com/npm/cli/commit/a09e19d88f046e54e8d75343883635a1bd056310) [#5696](https://github.com/npm/cli/pull/5696) introduce the `npm config fix` command (@nlf) +* [`d2963c6`](https://github.com/npm/cli/commit/d2963c67b992b9b3b9dd32f6f41cbbe4bcc580c8) explicitly validate config within the cli (@nlf) +* [`a5fec08`](https://github.com/npm/cli/commit/a5fec08348add7e75fa2498e6a9efe608b20aa8b) rewrite docs generation (@lukekarrys) + +### Bug Fixes + +* [`a35c784`](https://github.com/npm/cli/commit/a35c784f8c25dce05b4173edd6c3f8e7913d7b50) [#5691](https://github.com/npm/cli/pull/5691) config: remove `node-version` and `npm-version` (@wraithgar) + +### Documentation + +* [`a8532eb`](https://github.com/npm/cli/commit/a8532eb39504584cef452152948e015cef8c010a) [#5661](https://github.com/npm/cli/pull/5661) typo missing parentheses (@hbrls) +* [`542efdb`](https://github.com/npm/cli/commit/542efdb0a31f663cd899bc6d2ddad8fa88c20bc8) update `folders` page for modern npm (@shalvah) + +### Dependencies + +* [`cee3fd9`](https://github.com/npm/cli/commit/cee3fd9905c7eb0a5cb26a8c9c08c5db48becd15) `@npmcli/config@5.0.0` +* [`2a740b1`](https://github.com/npm/cli/commit/2a740b14c3789d80825b1345f2e99765fcb90351) [#5692](https://github.com/npm/cli/pull/5692) `hosted-git-info@6.0.0` +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.2...libnpmpack-v5.0.0-pre.3): `libnpmpack@5.0.0-pre.3` +* [Workspace](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0-pre.2...libnpmpublish-v7.0.0-pre.3): `libnpmpublish@7.0.0-pre.3` + +## [9.0.0-pre.4](https://github.com/npm/cli/compare/v9.0.0-pre.3...v9.0.0-pre.4) (2022-10-05) + +### Features + +* [`9609e9e`](https://github.com/npm/cli/commit/9609e9eed87c735f0319ac0af265f4d406cbf800) [#5605](https://github.com/npm/cli/pull/5605) use v3 lockfiles by default (#5605) (@fritzy) + +### Bug Fixes + +* [`e4e8ae2`](https://github.com/npm/cli/commit/e4e8ae20aef9e27e57282e87e8757d5b364abb39) libnpmpack: obey foregroundScripts (@winterqt) +* [`07fabc9`](https://github.com/npm/cli/commit/07fabc93007495f0926f4dd24b4350c07d92887d) [#5633](https://github.com/npm/cli/pull/5633) `npm link` should override `--install-links` (#5633) (@fritzy) +* [`02fcbb6`](https://github.com/npm/cli/commit/02fcbb67e6b7cf78cd6dc996570b0ba58132de22) [#5634](https://github.com/npm/cli/pull/5634) ensure Arborist constructor gets passed around everywhere for pacote (#5634) (@nlf) + +### Documentation + +* [`f37caad`](https://github.com/npm/cli/commit/f37caad9e92c50ae949014f6bee6375d9299fb39) [#5606](https://github.com/npm/cli/pull/5606) accurately describe install-links effect on relative paths (#5606) (@lukekarrys) +* [`97c32ed`](https://github.com/npm/cli/commit/97c32ed24d8fa2edcdbb9448839a1f1c9d8fb86f) [#5637](https://github.com/npm/cli/pull/5637) remove link to cache command (#5637) (@wraithgar) +* [`130bc9f`](https://github.com/npm/cli/commit/130bc9fb31fcff956765493a9e3cec668867c30e) [#5626](https://github.com/npm/cli/pull/5626) Remove circular reference (#5626) (@giovanniPepi) + +### Dependencies + +* [`5344d2c`](https://github.com/npm/cli/commit/5344d2ca9ffd1f6db473fd58b46b50179f899ff5) [#5644](https://github.com/npm/cli/pull/5644) `pacote@14.0.0` +* [`6a43b31`](https://github.com/npm/cli/commit/6a43b31eab8bd392ed684d2f906259ddfe0f26b5) `@npmcli/metavuln-calculator@4.0.0` +* [`501f8ca`](https://github.com/npm/cli/commit/501f8ca47bb042f19cdfca4026970caf7160f7f6) [#5640](https://github.com/npm/cli/pull/5640) `semver@7.3.8` (#5640) +* [`8b072dc`](https://github.com/npm/cli/commit/8b072dc113190ed49b296a5f02650b7d8cbf384a) [#5639](https://github.com/npm/cli/pull/5639) `@npmcli/ci-detect@3.0.0` (#5639) +* [`1ebbb44`](https://github.com/npm/cli/commit/1ebbb4454c09891ca2c9f9a11432c4a10ccf8c32) [#5638](https://github.com/npm/cli/pull/5638) `npm-profile@7.0.0` (#5638) +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.3...arborist-v6.0.0-pre.4): `@npmcli/arborist@6.0.0-pre.4` +* [Workspace](https://github.com/npm/cli/compare/libnpmdiff-v5.0.0-pre.1...libnpmdiff-v5.0.0-pre.2): `libnpmdiff@5.0.0-pre.2` +* [Workspace](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.3...libnpmexec-v5.0.0-pre.4): `libnpmexec@5.0.0-pre.4` +* [Workspace](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.3...libnpmfund-v4.0.0-pre.4): `libnpmfund@4.0.0-pre.4` +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.1...libnpmpack-v5.0.0-pre.2): `libnpmpack@5.0.0-pre.2` +* [Workspace](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0-pre.1...libnpmpublish-v7.0.0-pre.2): `libnpmpublish@7.0.0-pre.2` + +## [9.0.0-pre.3](https://github.com/npm/cli/compare/v9.0.0-pre.2...v9.0.0-pre.3) (2022-09-30) + +### ⚠️ BREAKING CHANGES + +* `npm pack` now follows a strict order of operations when applying ignore rules. If a files array is present in the package.json, then rules in .gitignore and .npmignore files from the root will be ignored. +* `--timing` file changes: + - When run with the `--timing` flag, `npm` now writes timing data to a + file alongside the debug log data, respecting the `logs-dir` option and + falling back to `<CACHE>/_logs/` dir, instead of directly inside the + cache directory. + - The timing file data is no longer newline delimited JSON, and instead + each run will create a uniquely named `<ID>-timing.json` file, with the + `<ID>` portion being the same as the debug log. + - Finally, the data inside the file now has three top level keys, + `metadata`, `timers, and `unfinishedTimers` instead of everything being + a top level key. + +### Features + +* [`3ae796d`](https://github.com/npm/cli/commit/3ae796d937bd36a5b1b9fd6e9e8473b4f2ddc32d) implement new `npm-packlist` behavior (@lukekarrys) +* [`e64d69a`](https://github.com/npm/cli/commit/e64d69aedecc0943425605b3a6dc68aec3ad93aa) [#5581](https://github.com/npm/cli/pull/5581) write eresolve error files to the logs directory (@lukekarrys) +* [`3445da0`](https://github.com/npm/cli/commit/3445da0138f9eed9d73d2b3f5f451fcc1fa2e3fe) timings are now written alongside debug log files (@lukekarrys) + +### Documentation + +* [`f0e7584`](https://github.com/npm/cli/commit/f0e758494698d9dd8a58d07bf71c87608c36869e) [#5601](https://github.com/npm/cli/pull/5601) update docs/logging for new --access default (@wraithgar) + +### Dependencies + +* [`bc21552`](https://github.com/npm/cli/commit/bc2155247d00b7a868c414f4bc86993069b035f9) [#5603](https://github.com/npm/cli/pull/5603) `npm-package-arg@9.1.2` +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.2...arborist-v6.0.0-pre.3): `@npmcli/arborist@6.0.0-pre.3` +* [Workspace](https://github.com/npm/cli/compare/libnpmdiff-v5.0.0-pre.0...libnpmdiff-v5.0.0-pre.1): `libnpmdiff@5.0.0-pre.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.2...libnpmexec-v5.0.0-pre.3): `libnpmexec@5.0.0-pre.3` +* [Workspace](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.2...libnpmfund-v4.0.0-pre.3): `libnpmfund@4.0.0-pre.3` +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.0...libnpmpack-v5.0.0-pre.1): `libnpmpack@5.0.0-pre.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0-pre.0...libnpmpublish-v7.0.0-pre.1): `libnpmpublish@7.0.0-pre.1` + +## [9.0.0-pre.2](https://github.com/npm/cli/compare/v9.0.0-pre.1...v9.0.0-pre.2) (2022-09-23) + +### ⚠️ BREAKING CHANGES + +* the default `auth-type` config value is now `web` +* `login`, `adduser`, and `auth-type` changes + - This removes all `auth-type` configs except `web` and `legacy`. + - `login` and `adduser` are now separate commands that send different data to the registry. + - `auth-type` config values `web` and `legacy` only try + their respective methods, npm no longer tries them all and waits to see + which one doesn't fail. + +### Features + +* [`66ed584`](https://github.com/npm/cli/commit/66ed58454418dd69c4cd8196ad8499e73f7e46e1) [#5551](https://github.com/npm/cli/pull/5551) default auth-type to web (#5551) (@wraithgar) +* [`6ee5b32`](https://github.com/npm/cli/commit/6ee5b320d2eab58c18d50b861b3cfabe7f24124a) query: display `queryContext` in results (@nlf) +* [`314311c`](https://github.com/npm/cli/commit/314311c61b8f341715c168199d52976ee3237077) [#5550](https://github.com/npm/cli/pull/5550) separate login/adduser, remove auth types (#5550) (@wraithgar) + +### Bug Fixes + +* [`0d90a01`](https://github.com/npm/cli/commit/0d90a011fff411c878ba4b44582f14ef7dbdceb1) [#5480](https://github.com/npm/cli/pull/5480) audit: add a condition to allow third-party registries returning E400 (#5480) (@juanheyns, Juan Heyns) + +### Documentation + +* [`2d756cb`](https://github.com/npm/cli/commit/2d756cbb05125dcb769f2ca4c1687e42568d5882) [#5527](https://github.com/npm/cli/pull/5527) add instruction to query objects with npm view (#5527) (@moonith) +* [`8743366`](https://github.com/npm/cli/commit/874336699681ac37857167b2438fac19c059511c) [#5519](https://github.com/npm/cli/pull/5519) add hash to "tag" config link (#5519) (@mrienstra, @lukekarrys) +* [`5645c51`](https://github.com/npm/cli/commit/5645c51410a730c4b9c6831cf81ab22efbe8c0ce) [#5521](https://github.com/npm/cli/pull/5521) link mentions of config parameters (#5521) (@mrienstra) +* [`19762b4`](https://github.com/npm/cli/commit/19762b4ac4b10741ff53ddd315be1fd23d9b1e28) [#5529](https://github.com/npm/cli/pull/5529) modify Misleading doc about bins (@Hafizur046) +* [`19762b4`](https://github.com/npm/cli/commit/19762b4ac4b10741ff53ddd315be1fd23d9b1e28) [#5529](https://github.com/npm/cli/pull/5529) modify misleading doc about package.json:bin (#5529) (@Hafizur046) +* [`8402fd8`](https://github.com/npm/cli/commit/8402fd8780c5e0461850da882dca024f7df1a681) [#5547](https://github.com/npm/cli/pull/5547) add `:outdated` pseudo selector to docs (@nlf) + +### Dependencies + +* [`d030f10`](https://github.com/npm/cli/commit/d030f10fd535433e5a824df1b099f500a71075dd) `@npmcli/query@2.0.0` +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.1...arborist-v6.0.0-pre.2): `@npmcli/arborist@6.0.0-pre.2` +* [Workspace](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.1...libnpmexec-v5.0.0-pre.2): `libnpmexec@5.0.0-pre.2` +* [Workspace](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.1...libnpmfund-v4.0.0-pre.2): `libnpmfund@4.0.0-pre.2` + +## [9.0.0-pre.1](https://github.com/npm/cli/compare/v9.0.0-pre.0...v9.0.0-pre.1) (2022-09-14) + +### ⚠️ BREAKING CHANGES + +* renames most of the `npm access` subcommands +* the api for libnpmaccess is different now + +### Features + +* [`9c32c6c`](https://github.com/npm/cli/commit/9c32c6c8d6fc5bdfd6af685731fe26920d7e5446) rewrite: rewrite `npm access` (@wraithgar) +* [`854521b`](https://github.com/npm/cli/commit/854521baa49ef88ff9586ec2cc5f1fbaee7fa364) rewrite: Rewrite libnpmaccess (@wraithgar) + +### Bug Fixes + +* [`c3d7549`](https://github.com/npm/cli/commit/c3d75499cfd4e3601c6ca31621b2f693af466c4d) add tag to publish log message (@wraithgar) + +### Documentation + +* [`fd0eebe`](https://github.com/npm/cli/commit/fd0eebe4c2b55dd69972aff7de1b4db14ea6799a) update registry docs header (@hughlilly) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.0...arborist-v6.0.0-pre.1): `@npmcli/arborist@6.0.0-pre.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmaccess-v7.0.0-pre.0...libnpmaccess-v7.0.0-pre.1): `libnpmaccess@7.0.0-pre.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.0...libnpmexec-v5.0.0-pre.1): `libnpmexec@5.0.0-pre.1` +* [Workspace](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.0...libnpmfund-v4.0.0-pre.1): `libnpmfund@4.0.0-pre.1` + +## [9.0.0-pre.0](https://github.com/npm/cli/compare/v8.19.1...v9.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` +* this removes the `npm birthday` command +* this removes `npm set-script` +* this changes the default value of `install-links` to true +* this removes the `npm bin` command +* `npm` is now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + * [`49bbb2f`](https://github.com/npm/cli/commit/49bbb2fb9d56e02d94da652befaa3d445283090b) [#5455](https://github.com/npm/cli/pull/5455) feat: remove `npm birthday` (@wraithgar) + * [`926f0ad`](https://github.com/npm/cli/commit/926f0adbd71949c905932a241a245b78c85ef643) [#5456](https://github.com/npm/cli/pull/5456) feat: remove `npm set-script` (@wraithgar) + * [`2a8c2fc`](https://github.com/npm/cli/commit/2a8c2fcd124ce7d4b23a6c26552d097c6501ac74) [#5458](https://github.com/npm/cli/pull/5458) feat: default `install-links` to true (@wraithgar) + * [`2e92800`](https://github.com/npm/cli/commit/2e9280072f9852466fa0944d3a0fdb0c8af156a9) [#5459](https://github.com/npm/cli/pull/5459) feat: remove `npm bin` (@wraithgar) + * [`457d388`](https://github.com/npm/cli/commit/457d388c9a70b4bc6c2421f576c79fb7524ff259) [#5475](https://github.com/npm/cli/pull/5475) feat: update supported node engines in package.json (@wraithgar) + +### Bug Fixes + + * [`41481f8`](https://github.com/npm/cli/commit/41481f8bc1de0fb92a2d6aab3d4a43292d1a1db7) [#5475](https://github.com/npm/cli/pull/5475) fix: attempt more graceful failure in older node versions (@wraithgar) + +### Documentation + + * [`7fc2b6f`](https://github.com/npm/cli/commit/7fc2b6f3cc157c8727da9e480f1f552eae2451e2) [#5468](https://github.com/npm/cli/pull/5468) docs: remove duplicate description for `prepare` script (@kidonng) + * [`285b39f`](https://github.com/npm/cli/commit/285b39f8d6915823fb424cca7161a0b445b86bd3) [#5324](https://github.com/npm/cli/pull/5324) docs: add documentation for expanded :semver selector (@nlf) ### Dependencies -* [`037f2cc8c`](https://github.com/npm/cli/commit/037f2cc8c8ed9d9a092475a5a07f2a3a88915633) - [#4078](https://github.com/npm/cli/issues/4078) - `node-gyp@8.4.1` -* [`0e63df612`](https://github.com/npm/cli/commit/0e63df61283a2f7ace991f72e4577c6f23ffc5df) - [#4102](https://github.com/npm/cli/issues/4102) - `@npmcli/config@2.3.2`: - * fix: always load localPrefix - -## v8.1.4 (2021-11-18) - -### BUG FIXES - -* [`7887fb3d7`](https://github.com/npm/cli/commit/7887fb3d7ba7f05abeb49dd92b76d90422cb38ca) - [#4025](https://github.com/npm/cli/issues/4025) - fix: don't try to open file:/// urls - ([@wraithgar](https://github.com/wraithgar)) -* [`cd6d3a90d`](https://github.com/npm/cli/commit/cd6d3a90d4bbf3793834830b4c77fc8eb0846596) - [#4026](https://github.com/npm/cli/issues/4026) - fix: explicitly allow `npm help` to open file:/// man pages - ([@wraithgar](https://github.com/wraithgar)) -* [`72ca4a4e3`](https://github.com/npm/cli/commit/72ca4a4e39a1d4de03d6423480aa2ee82b021060) - [#4020](https://github.com/npm/cli/issues/4020) - [#4032](https://github.com/npm/cli/issues/4032) - fix: command completion - ([@wraithgar](https://github.com/wraithgar)) -* [`b78949134`](https://github.com/npm/cli/commit/b789491345aa6fbe345aa3c96fe9f415296ec418) - [#4023](https://github.com/npm/cli/issues/4023) - fix(install): command completion with single match - ([@wraithgar](https://github.com/wraithgar)) -* [`44bfa3787`](https://github.com/npm/cli/commit/44bfa378723554195fccf8cf4ca2d895ddbd8f8c) - [#4065](https://github.com/npm/cli/issues/4065) - @npmcli/arborist 4.0.5 - * fix: accurate filtering of workspaces `--no-workspaces` - ([@fritzy](https://github.com/fritzy)) - -### DEPENDENCIES - -* [`225645420`](https://github.com/npm/cli/commit/225645420cf3d13bc0b0d591f7f7bf21a9c24e47) - [#3995](https://github.com/npm/cli/issues/3995) - update to latest eslint and linting rules - ([@wraithgar](https://github.com/wraithgar)) -* [`203fedf5b`](https://github.com/npm/cli/commit/203fedf5b1eba78b76ebacbda88f215caabea6ca) - [#4016](https://github.com/npm/cli/issues/4016) - `eslint@8.0.0`: `@npmcli/eslint-config@2.0.0` - * Update to eslint@8 and and `@npmcli/eslint-config@2.0.0` - * Remove eslint-plugin-node. - Also remove an unused script that was failing linting. We don't use the - update-dist-tags script anymore as part of our release process. - ([@wraithgar](https://github.com/wraithgar)) -* [`7b4aa59b6`](https://github.com/npm/cli/commit/7b4aa59b6630831f25d19c0c15a65acaf3a83327) - `signal-exit@3.0.6`:, `tap@15.1.2` - ([@isaacs](https://github.com/isaacs)) -* [`08015859c`](https://github.com/npm/cli/commit/08015859ca0abe47845d2970212cd344cdfc56e6) - [#4049](https://github.com/npm/cli/issues/4049) - `npmlog@6.0.0` -* [`088c11694`](https://github.com/npm/cli/commit/088c11694a9f575e5c0fe10ab9efb55d14019be7) - [#4045](https://github.com/npm/cli/issues/4045) - `node-gyp@8.4.0`: - * feat: support vs2022 - * feat: build with config.gypi from node headers - -## v8.1.3 (2021-11-04) - -### BUG FIXES - -* [`8ffeb71df`](https://github.com/npm/cli/commit/8ffeb71dfb248b4a76744bd06cd4d6100f17c8ae) - [#3959](https://github.com/npm/cli/issues/3959) - fix: refactor commands - ([@wraithgar](https://github.com/wraithgar)) -* [`e5bfdaca4`](https://github.com/npm/cli/commit/e5bfdaca455e294109ba026f4d8b5cc80d3dfd20) - [#3978](https://github.com/npm/cli/issues/3978) - fix: shrinkwrap setting incorrect lockfileVersion - ([@lukekarrys](https://github.com/lukekarrys)) -* [`32ccd3c27`](https://github.com/npm/cli/commit/32ccd3c2767a14198a1803f04e747ef848f7c938) - [#3988](https://github.com/npm/cli/issues/3988) - fix: remove usage of unnecessary util.promisify - ([@lukekarrys](https://github.com/lukekarrys)) -* [`1e9c31c4e`](https://github.com/npm/cli/commit/1e9c31c4e3929483580a0a554d7515095b5418ca) - [#3994](https://github.com/npm/cli/issues/3994) - fix: npm help on windows - ([@wraithgar](https://github.com/wraithgar)) -* [`22230ef3d`](https://github.com/npm/cli/commit/22230ef3dd590def31c274b3412106b4cfbd212f) - [#3987](https://github.com/npm/cli/issues/3987) - fix: make prefixed usage errors more consistent - ([@lukekarrys](https://github.com/lukekarrys)) - -### DEPENDENCIES - -* [`ac2fabb86`](https://github.com/npm/cli/commit/ac2fabb8604db0dac852913d61c8415ae7464485) - [#3990](https://github.com/npm/cli/issues/3990) - `@npmcli/arborist@4.0.4` - * fix: don't compare spec for local dep vs existing - * fix: stop pruning peerSets when entryEdge is from a workspace -* [`a0d35ff20`](https://github.com/npm/cli/commit/a0d35ff20aed6aab8508123eb540bc9c61fb127d) - [#3996](https://github.com/npm/cli/issues/3996) - `@npmcli/config@2.3.1`: - * fix: dont load project configs in global mode - -## v8.1.2 (2021-10-28) - -### BUG FIXES - -* [`cb9f43551`](https://github.com/npm/cli/commit/cb9f43551f46bf27095cd7bd6c1885a441004cd2) - [#3949](https://github.com/npm/cli/issues/3949) - allow `--lockfile-version` config to be string and coerce to number ([@lukekarrys](https://github.com/lukekarrys)) -* [`070901d7a`](https://github.com/npm/cli/commit/070901d7a6e3110a04ef41d8fcf14ffbfcce1496) - [#3943](https://github.com/npm/cli/issues/3943) - fix(publish): clean args before logging - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`8af94726b`](https://github.com/npm/cli/commit/8af94726b098031c7c0cae7ed50cc4e2e3499181) - [#3953](https://github.com/npm/cli/issues/3953) - `arborist@4.0.3` - * [`38cee94`](https://github.com/npm/arborist/commit/38cee94afa53d578830cc282348a803a8a6eefad) - [#340](https://github.com/npm/arborist/pull/340) - fix: set lockfileVersion from file during reset - * [`d310bd3`](https://github.com/npm/arborist/commit/d310bd3290c3a81e8285ceeb6eda9c9b5aa867d7) - [#339](https://github.com/npm/arborist/pull/339) - fix: always set originalLockfileVersion when doing shrinkwrap reset - -## v8.1.1 (2021-10-21) - -### DEPENDENCIES - -* [`51fb83ce9`](https://github.com/npm/cli/commit/51fb83ce93fdd7e289da7b2aabc95b0518f0aa31) - [#3921](https://github.com/npm/cli/issues/3921) - `@npmcli/arborist@4.0.2`: - * fix: skip peer conflict check if there is a current node -* [`1d07f2187`](https://github.com/npm/cli/commit/1d07f21876994c6d4d69559203cfdac6022536b6) - [#3913](https://github.com/npm/cli/issues/3913) - `node-gyp@8.3.0`: - * feat(gyp): update gyp to v0.10.0 - -## v8.1.0 (2021-10-14) - -### FEATURES - -* [`24273a862`](https://github.com/npm/cli/commit/24273a862e54abfd022df9fc4b8c250bfe77817c) - [#3890](https://github.com/npm/cli/issues/3890) - feat(workspaces): add --include-workspace-root and explicit --no-workspaces - ([@fritzy](https://github.com/fritzy)) -* [`d559d6da8`](https://github.com/npm/cli/commit/d559d6da84c2dae960c6b7c89c6012fb31bcfa37) - [#3880](https://github.com/npm/cli/issues/3880) - feat(config): Add --lockfile-version config option - ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES - -* [`ae4bf013d`](https://github.com/npm/cli/commit/ae4bf013d06d84b8600937a28cc7b4c4034f571c) - [#3883](https://github.com/npm/cli/issues/3883) - `pacote@12.0.2`: - * fix: preserve git+ssh url for non-hosted repos - * deps: update `npm-packlist@3.0.0` - * fix: no longer include ignored bundled link deps -* [`fbc5a3d08`](https://github.com/npm/cli/commit/fbc5a3d08231176b9d8a7b9dd3371fb40ba6abc9) - [#3889](https://github.com/npm/cli/issues/3889) - `@npmcli/ci-detect@1.4.0` -* [`b6bc279e5`](https://github.com/npm/cli/commit/b6bc279e55aa65afff09d9258f9df7168a7dbadb) - `@npmcli/arborist@4.0.1` -* [`0f69d295b`](https://github.com/npm/cli/commit/0f69d295bd5516f496af75ef29e7ae6304fa2ba5) - [#3893](https://github.com/npm/cli/issues/3893) - `@npmcli/map-workspaces@2.0.0` - -### DOCUMENTATION - -* [`f77932ca1`](https://github.com/npm/cli/commit/f77932ca1eafbece16fc249a7470f760d652bd94) - [#3861](https://github.com/npm/cli/issues/3861) - fix(docs): Update Node support in README - ([@gfyoung](https://github.com/gfyoung)) -* [`a190f422a`](https://github.com/npm/cli/commit/a190f422a2587a0e56afa5032175e57e55123ea2) - [#3878](https://github.com/npm/cli/issues/3878) - fix(docs): grammar fix - ([@XhmikosR](https://github.com/XhmikosR)) - -## v8.0.0 (2021-10-07) - -The purpose of this release is to drop support for old node versions and -to remove support for `require('npm')`. There are no other breaking -changes. - -### BREAKING CHANGES - -* Drop support for node 10 and 11 -* Raise support ceiling in node 12 and 14 to LTS (^12.13.0/^14.15.0) -* Drop support to `require('npm')` -* Update subdependencies that also dropped node10 support - -### DEPENDENCIES - -* The following dependencies were updated to drop node10 support and - update to the latest node-gyp - * libnpmversion@2.0.1 - * pacote@12.0.0 - * libnpmpack@3.0.0 - * @npmcli/arborist@3.0.0 - * libnpmfund@2.0.0 - * libnpmexec@3.0.0 - * node-gyp@8.2.0 -* [`8bd85cdae`](https://github.com/npm/cli/commit/8bd85cdae5eead60d5e92d6f1be27e88b480b1cb) - [#3813](https://github.com/npm/cli/issues/3813) - `cli-columns@4.0.0` +* The following workspace dependencies were updated + * dependencies + * @npmcli/arborist bumped from ^5.6.1 to ^6.0.0-pre.0 + * libnpmaccess bumped from ^6.0.4 to ^7.0.0-pre.0 + * libnpmdiff bumped from ^4.0.5 to ^5.0.0-pre.0 + * libnpmexec bumped from ^4.0.12 to ^5.0.0-pre.0 + * libnpmfund bumped from ^3.0.3 to ^4.0.0-pre.0 + * libnpmhook bumped from ^8.0.4 to ^9.0.0-pre.0 + * libnpmorg bumped from ^4.0.4 to ^5.0.0-pre.0 + * libnpmpack bumped from ^4.1.3 to ^5.0.0-pre.0 + * libnpmpublish bumped from ^6.0.5 to ^7.0.0-pre.0 + * libnpmsearch bumped from ^5.0.4 to ^6.0.0-pre.0 + * libnpmteam bumped from ^4.0.4 to ^5.0.0-pre.0 + * libnpmversion bumped from ^3.0.7 to ^4.0.0-pre.0 diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md new file mode 100644 index 0000000..167043c --- /dev/null +++ b/CODE_OF_CONDUCT.md @@ -0,0 +1,7 @@ +<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> + +All interactions in this repo are covered by the [npm Code of +Conduct](https://docs.npmjs.com/policies/conduct) + +The npm cli team may, at its own discretion, moderate, remove, or edit +any interactions such as pull requests, issues, and comments. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 33dff2e..e12e300 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -19,7 +19,7 @@ $ git clone git@github.com:npm/cli.git npm **2. Navigate into project & install development-specific dependencies...** ```bash -$ cd ./npm && npm install +$ cd ./npm && node . install ``` **3. Write some code &/or add some tests...** @@ -30,20 +30,23 @@ $ cd ./npm && npm install **4. Run tests & ensure they pass...** ``` -$ npm run test +$ node . run test ``` **5. Open a [Pull Request](https://github.com/npm/cli/pulls) for your work & become the newest contributor to `npm`! 🎉** +## Pull Request Conventions + +We use [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/). When opening a pull request, please be sure that either the pull request title, or each commit in the pull request, has one of the following prefixes: + + - `feat`: For when introducing a new feature. The result will be a new semver minor version of the package when it is next published. + - `fix`: For bug fixes. The result will be a new semver patch version of the package when it is next published. + - `docs`: For documentation updates. The result will be a new semver patch version of the package when it is next published. + - `chore`: For changes that do not affect the published module. Often these are changes to tests. The result will be *no* change to the version of the package when it is next published (as the commit does not affect the published version). + ## Test Coverage -We use [`tap`](https://node-tap.org/) for testing & expect that every new feature or bug fix comes with corresponding tests that validate the solutions. We strive to have as close to, if not exactly, 100% code coverage. - -**You can find out what the current test coverage percentage is by running...** - -```bash -$ npm run check-coverage -``` +We use [`tap`](https://node-tap.org/) for testing & expect that every new feature or bug fix comes with corresponding tests that validate the solutions. Tap also reports on code coverage and it will fail if that drops below 100%. ## Performance & Benchmarks diff --git a/DEPENDENCIES.md b/DEPENDENCIES.md new file mode 100644 index 0000000..ca8568d --- /dev/null +++ b/DEPENDENCIES.md @@ -0,0 +1,790 @@ +# npm dependencies + +## `github.com/npm/` only +```mermaid +graph LR; + bin-links-->cmd-shim; + bin-links-->npm-normalize-package-bin; + bin-links-->read-cmd-shim; + bin-links-->write-file-atomic; + cacache-->fs-minipass; + cacache-->npmcli-fs["@npmcli/fs"]; + cacache-->ssri; + cacache-->unique-filename; + init-package-json-->npm-package-arg; + init-package-json-->promzard; + init-package-json-->read-package-json; + init-package-json-->read; + init-package-json-->semver; + init-package-json-->validate-npm-package-name; + libnpmaccess-->npm-package-arg; + libnpmaccess-->npm-registry-fetch; + libnpmaccess-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmaccess-->npmcli-mock-registry["@npmcli/mock-registry"]; + libnpmaccess-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmdiff-->npm-package-arg; + libnpmdiff-->npmcli-arborist["@npmcli/arborist"]; + libnpmdiff-->npmcli-disparity-colors["@npmcli/disparity-colors"]; + libnpmdiff-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmdiff-->npmcli-installed-package-contents["@npmcli/installed-package-contents"]; + libnpmdiff-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmdiff-->pacote; + libnpmexec-->bin-links; + libnpmexec-->minify-registry-metadata; + libnpmexec-->npm-package-arg; + libnpmexec-->npmcli-arborist["@npmcli/arborist"]; + libnpmexec-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmexec-->npmcli-mock-registry["@npmcli/mock-registry"]; + libnpmexec-->npmcli-run-script["@npmcli/run-script"]; + libnpmexec-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmexec-->npmlog; + libnpmexec-->pacote; + libnpmexec-->proc-log; + libnpmexec-->read-package-json-fast; + libnpmexec-->read; + libnpmexec-->semver; + libnpmfund-->npmcli-arborist["@npmcli/arborist"]; + libnpmfund-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmfund-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmhook-->npm-registry-fetch; + libnpmhook-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmhook-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmorg-->npm-registry-fetch; + libnpmorg-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmorg-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmpack-->npm-package-arg; + libnpmpack-->npmcli-arborist["@npmcli/arborist"]; + libnpmpack-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmpack-->npmcli-run-script["@npmcli/run-script"]; + libnpmpack-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmpack-->pacote; + libnpmpublish-->libnpmpack; + libnpmpublish-->normalize-package-data; + libnpmpublish-->npm-package-arg; + libnpmpublish-->npm-registry-fetch; + libnpmpublish-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmpublish-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmpublish-->semver; + libnpmpublish-->ssri; + libnpmsearch-->npm-registry-fetch; + libnpmsearch-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmsearch-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmteam-->npm-registry-fetch; + libnpmteam-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmteam-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmversion-->json-parse-even-better-errors; + libnpmversion-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmversion-->npmcli-git["@npmcli/git"]; + libnpmversion-->npmcli-run-script["@npmcli/run-script"]; + libnpmversion-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmversion-->proc-log; + libnpmversion-->semver; + make-fetch-happen-->cacache; + make-fetch-happen-->minipass-fetch; + make-fetch-happen-->ssri; + nopt-->abbrev; + normalize-package-data-->hosted-git-info; + normalize-package-data-->semver; + npm-->abbrev; + npm-->cacache; + npm-->fs-minipass; + npm-->hosted-git-info; + npm-->ini; + npm-->init-package-json; + npm-->json-parse-even-better-errors; + npm-->libnpmaccess; + npm-->libnpmdiff; + npm-->libnpmexec; + npm-->libnpmfund; + npm-->libnpmhook; + npm-->libnpmorg; + npm-->libnpmpack; + npm-->libnpmpublish; + npm-->libnpmsearch; + npm-->libnpmteam; + npm-->libnpmversion; + npm-->make-fetch-happen; + npm-->nopt; + npm-->npm-audit-report; + npm-->npm-install-checks; + npm-->npm-package-arg; + npm-->npm-packlist; + npm-->npm-pick-manifest; + npm-->npm-profile; + npm-->npm-registry-fetch; + npm-->npm-user-validate; + npm-->npmcli-arborist["@npmcli/arborist"]; + npm-->npmcli-config["@npmcli/config"]; + npm-->npmcli-docs["@npmcli/docs"]; + npm-->npmcli-eslint-config["@npmcli/eslint-config"]; + npm-->npmcli-fs["@npmcli/fs"]; + npm-->npmcli-git["@npmcli/git"]; + npm-->npmcli-map-workspaces["@npmcli/map-workspaces"]; + npm-->npmcli-mock-registry["@npmcli/mock-registry"]; + npm-->npmcli-package-json["@npmcli/package-json"]; + npm-->npmcli-promise-spawn["@npmcli/promise-spawn"]; + npm-->npmcli-run-script["@npmcli/run-script"]; + npm-->npmcli-smoke-tests["@npmcli/smoke-tests"]; + npm-->npmcli-template-oss["@npmcli/template-oss"]; + npm-->npmlog; + npm-->pacote; + npm-->parse-conflict-json; + npm-->proc-log; + npm-->read-package-json-fast; + npm-->read-package-json; + npm-->read; + npm-->semver; + npm-->ssri; + npm-->treeverse; + npm-->validate-npm-package-name; + npm-->write-file-atomic; + npm-bundled-->npm-normalize-package-bin; + npm-install-checks-->semver; + npm-package-arg-->hosted-git-info; + npm-package-arg-->proc-log; + npm-package-arg-->semver; + npm-package-arg-->validate-npm-package-name; + npm-packlist-->ignore-walk; + npm-pick-manifest-->npm-install-checks; + npm-pick-manifest-->npm-normalize-package-bin; + npm-pick-manifest-->npm-package-arg; + npm-pick-manifest-->semver; + npm-profile-->npm-registry-fetch; + npm-profile-->proc-log; + npm-registry-fetch-->make-fetch-happen; + npm-registry-fetch-->minipass-fetch; + npm-registry-fetch-->npm-package-arg; + npm-registry-fetch-->proc-log; + npmcli-arborist-->bin-links; + npmcli-arborist-->cacache; + npmcli-arborist-->hosted-git-info; + npmcli-arborist-->json-parse-even-better-errors; + npmcli-arborist-->minify-registry-metadata; + npmcli-arborist-->nopt; + npmcli-arborist-->npm-install-checks; + npmcli-arborist-->npm-package-arg; + npmcli-arborist-->npm-pick-manifest; + npmcli-arborist-->npm-registry-fetch; + npmcli-arborist-->npmcli-eslint-config["@npmcli/eslint-config"]; + npmcli-arborist-->npmcli-fs["@npmcli/fs"]; + npmcli-arborist-->npmcli-installed-package-contents["@npmcli/installed-package-contents"]; + npmcli-arborist-->npmcli-map-workspaces["@npmcli/map-workspaces"]; + npmcli-arborist-->npmcli-metavuln-calculator["@npmcli/metavuln-calculator"]; + npmcli-arborist-->npmcli-name-from-folder["@npmcli/name-from-folder"]; + npmcli-arborist-->npmcli-node-gyp["@npmcli/node-gyp"]; + npmcli-arborist-->npmcli-package-json["@npmcli/package-json"]; + npmcli-arborist-->npmcli-query["@npmcli/query"]; + npmcli-arborist-->npmcli-run-script["@npmcli/run-script"]; + npmcli-arborist-->npmcli-template-oss["@npmcli/template-oss"]; + npmcli-arborist-->npmlog; + npmcli-arborist-->pacote; + npmcli-arborist-->parse-conflict-json; + npmcli-arborist-->proc-log; + npmcli-arborist-->read-package-json-fast; + npmcli-arborist-->semver; + npmcli-arborist-->ssri; + npmcli-arborist-->treeverse; + npmcli-config-->ini; + npmcli-config-->nopt; + npmcli-config-->npmcli-eslint-config["@npmcli/eslint-config"]; + npmcli-config-->npmcli-map-workspaces["@npmcli/map-workspaces"]; + npmcli-config-->npmcli-template-oss["@npmcli/template-oss"]; + npmcli-config-->proc-log; + npmcli-config-->read-package-json-fast; + npmcli-config-->semver; + npmcli-docs-->ignore-walk; + npmcli-docs-->npmcli-eslint-config["@npmcli/eslint-config"]; + npmcli-docs-->npmcli-template-oss["@npmcli/template-oss"]; + npmcli-fs-->semver; + npmcli-git-->npm-pick-manifest; + npmcli-git-->npmcli-promise-spawn["@npmcli/promise-spawn"]; + npmcli-git-->proc-log; + npmcli-git-->semver; + npmcli-installed-package-contents-->npm-bundled; + npmcli-installed-package-contents-->npm-normalize-package-bin; + npmcli-map-workspaces-->npmcli-name-from-folder["@npmcli/name-from-folder"]; + npmcli-map-workspaces-->read-package-json-fast; + npmcli-metavuln-calculator-->cacache; + npmcli-metavuln-calculator-->json-parse-even-better-errors; + npmcli-metavuln-calculator-->pacote; + npmcli-metavuln-calculator-->semver; + npmcli-mock-registry-->npm-package-arg; + npmcli-mock-registry-->npmcli-arborist["@npmcli/arborist"]; + npmcli-mock-registry-->npmcli-eslint-config["@npmcli/eslint-config"]; + npmcli-mock-registry-->npmcli-template-oss["@npmcli/template-oss"]; + npmcli-mock-registry-->pacote; + npmcli-package-json-->json-parse-even-better-errors; + npmcli-run-script-->npmcli-node-gyp["@npmcli/node-gyp"]; + npmcli-run-script-->npmcli-promise-spawn["@npmcli/promise-spawn"]; + npmcli-run-script-->read-package-json-fast; + npmcli-smoke-tests-->npmcli-eslint-config["@npmcli/eslint-config"]; + npmcli-smoke-tests-->npmcli-mock-registry["@npmcli/mock-registry"]; + npmcli-smoke-tests-->npmcli-promise-spawn["@npmcli/promise-spawn"]; + npmcli-smoke-tests-->npmcli-template-oss["@npmcli/template-oss"]; + npmlog-->are-we-there-yet; + npmlog-->gauge; + pacote-->cacache; + pacote-->fs-minipass; + pacote-->npm-package-arg; + pacote-->npm-packlist; + pacote-->npm-pick-manifest; + pacote-->npm-registry-fetch; + pacote-->npmcli-git["@npmcli/git"]; + pacote-->npmcli-installed-package-contents["@npmcli/installed-package-contents"]; + pacote-->npmcli-promise-spawn["@npmcli/promise-spawn"]; + pacote-->npmcli-run-script["@npmcli/run-script"]; + pacote-->proc-log; + pacote-->read-package-json-fast; + pacote-->read-package-json; + pacote-->ssri; + parse-conflict-json-->json-parse-even-better-errors; + promzard-->read; + read-->mute-stream; + read-package-json-->json-parse-even-better-errors; + read-package-json-->normalize-package-data; + read-package-json-->npm-normalize-package-bin; + read-package-json-fast-->json-parse-even-better-errors; + read-package-json-fast-->npm-normalize-package-bin; + unique-filename-->unique-slug; +``` + +## all dependencies +```mermaid +graph LR; + agent-base-->debug; + agentkeepalive-->debug; + agentkeepalive-->depd; + agentkeepalive-->humanize-ms; + aggregate-error-->clean-stack; + aggregate-error-->indent-string; + ansi-styles-->color-convert; + are-we-there-yet-->delegates; + are-we-there-yet-->readable-stream; + bin-links-->cmd-shim; + bin-links-->npm-normalize-package-bin; + bin-links-->read-cmd-shim; + bin-links-->write-file-atomic; + brace-expansion-->balanced-match; + builtins-->semver; + cacache-->chownr; + cacache-->fs-minipass; + cacache-->glob; + cacache-->infer-owner; + cacache-->lru-cache; + cacache-->minipass-collect; + cacache-->minipass-flush; + cacache-->minipass-pipeline; + cacache-->minipass; + cacache-->mkdirp; + cacache-->npmcli-fs["@npmcli/fs"]; + cacache-->npmcli-move-file["@npmcli/move-file"]; + cacache-->p-map; + cacache-->promise-inflight; + cacache-->rimraf; + cacache-->ssri; + cacache-->tar; + cacache-->unique-filename; + chalk-->ansi-styles; + chalk-->supports-color; + cidr-regex-->ip-regex; + cli-columns-->string-width; + cli-columns-->strip-ansi; + cli-table3-->colors-colors["@colors/colors"]; + cli-table3-->string-width; + color-convert-->color-name; + columnify-->strip-ansi; + columnify-->wcwidth; + debug-->ms; + defaults-->clone; + encoding-->iconv-lite; + fs-minipass-->minipass; + gauge-->aproba; + gauge-->color-support; + gauge-->console-control-strings; + gauge-->has-unicode; + gauge-->signal-exit; + gauge-->string-width; + gauge-->strip-ansi; + gauge-->wide-align; + glob-->fs.realpath; + glob-->inflight; + glob-->inherits; + glob-->minimatch; + glob-->once; + glob-->path-is-absolute; + has-->function-bind; + hosted-git-info-->lru-cache; + http-proxy-agent-->agent-base; + http-proxy-agent-->debug; + http-proxy-agent-->tootallnate-once["@tootallnate/once"]; + https-proxy-agent-->agent-base; + https-proxy-agent-->debug; + humanize-ms-->ms; + iconv-lite-->safer-buffer; + ignore-walk-->minimatch; + inflight-->once; + inflight-->wrappy; + init-package-json-->npm-package-arg; + init-package-json-->promzard; + init-package-json-->read-package-json; + init-package-json-->read; + init-package-json-->semver; + init-package-json-->validate-npm-package-license; + init-package-json-->validate-npm-package-name; + is-cidr-->cidr-regex; + is-core-module-->has; + libnpmaccess-->nock; + libnpmaccess-->npm-package-arg; + libnpmaccess-->npm-registry-fetch; + libnpmaccess-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmaccess-->npmcli-mock-registry["@npmcli/mock-registry"]; + libnpmaccess-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmaccess-->tap; + libnpmdiff-->binary-extensions; + libnpmdiff-->diff; + libnpmdiff-->minimatch; + libnpmdiff-->npm-package-arg; + libnpmdiff-->npmcli-arborist["@npmcli/arborist"]; + libnpmdiff-->npmcli-disparity-colors["@npmcli/disparity-colors"]; + libnpmdiff-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmdiff-->npmcli-installed-package-contents["@npmcli/installed-package-contents"]; + libnpmdiff-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmdiff-->pacote; + libnpmdiff-->tap; + libnpmdiff-->tar; + libnpmexec-->bin-links; + libnpmexec-->chalk; + libnpmexec-->ci-info; + libnpmexec-->just-extend; + libnpmexec-->just-safe-set; + libnpmexec-->minify-registry-metadata; + libnpmexec-->mkdirp; + libnpmexec-->npm-package-arg; + libnpmexec-->npmcli-arborist["@npmcli/arborist"]; + libnpmexec-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmexec-->npmcli-mock-registry["@npmcli/mock-registry"]; + libnpmexec-->npmcli-run-script["@npmcli/run-script"]; + libnpmexec-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmexec-->npmlog; + libnpmexec-->pacote; + libnpmexec-->proc-log; + libnpmexec-->read-package-json-fast; + libnpmexec-->read; + libnpmexec-->semver; + libnpmexec-->tap; + libnpmexec-->walk-up-path; + libnpmfund-->npmcli-arborist["@npmcli/arborist"]; + libnpmfund-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmfund-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmfund-->tap; + libnpmhook-->aproba; + libnpmhook-->nock; + libnpmhook-->npm-registry-fetch; + libnpmhook-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmhook-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmhook-->tap; + libnpmorg-->aproba; + libnpmorg-->minipass; + libnpmorg-->nock; + libnpmorg-->npm-registry-fetch; + libnpmorg-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmorg-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmorg-->tap; + libnpmpack-->nock; + libnpmpack-->npm-package-arg; + libnpmpack-->npmcli-arborist["@npmcli/arborist"]; + libnpmpack-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmpack-->npmcli-run-script["@npmcli/run-script"]; + libnpmpack-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmpack-->pacote; + libnpmpack-->spawk; + libnpmpack-->tap; + libnpmpublish-->libnpmpack; + libnpmpublish-->lodash.clonedeep; + libnpmpublish-->nock; + libnpmpublish-->normalize-package-data; + libnpmpublish-->npm-package-arg; + libnpmpublish-->npm-registry-fetch; + libnpmpublish-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmpublish-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmpublish-->semver; + libnpmpublish-->ssri; + libnpmpublish-->tap; + libnpmsearch-->nock; + libnpmsearch-->npm-registry-fetch; + libnpmsearch-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmsearch-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmsearch-->tap; + libnpmteam-->aproba; + libnpmteam-->nock; + libnpmteam-->npm-registry-fetch; + libnpmteam-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmteam-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmteam-->tap; + libnpmversion-->json-parse-even-better-errors; + libnpmversion-->npmcli-eslint-config["@npmcli/eslint-config"]; + libnpmversion-->npmcli-git["@npmcli/git"]; + libnpmversion-->npmcli-run-script["@npmcli/run-script"]; + libnpmversion-->npmcli-template-oss["@npmcli/template-oss"]; + libnpmversion-->proc-log; + libnpmversion-->require-inject; + libnpmversion-->semver; + libnpmversion-->tap; + lru-cache-->yallist; + make-fetch-happen-->agentkeepalive; + make-fetch-happen-->cacache; + make-fetch-happen-->http-cache-semantics; + make-fetch-happen-->http-proxy-agent; + make-fetch-happen-->https-proxy-agent; + make-fetch-happen-->is-lambda; + make-fetch-happen-->lru-cache; + make-fetch-happen-->minipass-collect; + make-fetch-happen-->minipass-fetch; + make-fetch-happen-->minipass-flush; + make-fetch-happen-->minipass-pipeline; + make-fetch-happen-->minipass; + make-fetch-happen-->negotiator; + make-fetch-happen-->promise-retry; + make-fetch-happen-->socks-proxy-agent; + make-fetch-happen-->ssri; + minimatch-->brace-expansion; + minipass-->yallist; + minipass-collect-->minipass; + minipass-fetch-->encoding; + minipass-fetch-->minipass-sized; + minipass-fetch-->minipass; + minipass-fetch-->minizlib; + minipass-flush-->minipass; + minipass-json-stream-->jsonparse; + minipass-json-stream-->minipass; + minipass-pipeline-->minipass; + minipass-sized-->minipass; + minizlib-->minipass; + minizlib-->yallist; + node-gyp-->env-paths; + node-gyp-->glob; + node-gyp-->graceful-fs; + node-gyp-->make-fetch-happen; + node-gyp-->nopt; + node-gyp-->npmlog; + node-gyp-->rimraf; + node-gyp-->semver; + node-gyp-->tar; + node-gyp-->which; + nopt-->abbrev; + normalize-package-data-->hosted-git-info; + normalize-package-data-->is-core-module; + normalize-package-data-->semver; + normalize-package-data-->validate-npm-package-license; + npm-->abbrev; + npm-->archy; + npm-->cacache; + npm-->chalk; + npm-->ci-info; + npm-->cli-columns; + npm-->cli-table3; + npm-->columnify; + npm-->fastest-levenshtein; + npm-->fs-minipass; + npm-->glob; + npm-->graceful-fs; + npm-->hosted-git-info; + npm-->ini; + npm-->init-package-json; + npm-->is-cidr; + npm-->isaacs-string-locale-compare["@isaacs/string-locale-compare"]; + npm-->json-parse-even-better-errors; + npm-->libnpmaccess; + npm-->libnpmdiff; + npm-->libnpmexec; + npm-->libnpmfund; + npm-->libnpmhook; + npm-->libnpmorg; + npm-->libnpmpack; + npm-->libnpmpublish; + npm-->libnpmsearch; + npm-->libnpmteam; + npm-->libnpmversion; + npm-->licensee; + npm-->make-fetch-happen; + npm-->minimatch; + npm-->minipass-pipeline; + npm-->minipass; + npm-->mkdirp; + npm-->ms; + npm-->nock; + npm-->node-gyp; + npm-->nopt; + npm-->npm-audit-report; + npm-->npm-install-checks; + npm-->npm-package-arg; + npm-->npm-packlist; + npm-->npm-pick-manifest; + npm-->npm-profile; + npm-->npm-registry-fetch; + npm-->npm-user-validate; + npm-->npmcli-arborist["@npmcli/arborist"]; + npm-->npmcli-config["@npmcli/config"]; + npm-->npmcli-docs["@npmcli/docs"]; + npm-->npmcli-eslint-config["@npmcli/eslint-config"]; + npm-->npmcli-fs["@npmcli/fs"]; + npm-->npmcli-git["@npmcli/git"]; + npm-->npmcli-map-workspaces["@npmcli/map-workspaces"]; + npm-->npmcli-mock-registry["@npmcli/mock-registry"]; + npm-->npmcli-package-json["@npmcli/package-json"]; + npm-->npmcli-promise-spawn["@npmcli/promise-spawn"]; + npm-->npmcli-run-script["@npmcli/run-script"]; + npm-->npmcli-smoke-tests["@npmcli/smoke-tests"]; + npm-->npmcli-template-oss["@npmcli/template-oss"]; + npm-->npmlog; + npm-->p-map; + npm-->pacote; + npm-->parse-conflict-json; + npm-->proc-log; + npm-->qrcode-terminal; + npm-->read-package-json-fast; + npm-->read-package-json; + npm-->read; + npm-->remark-gfm; + npm-->remark-github; + npm-->remark; + npm-->rimraf; + npm-->semver; + npm-->spawk; + npm-->ssri; + npm-->tap; + npm-->tar; + npm-->text-table; + npm-->tiny-relative-date; + npm-->treeverse; + npm-->validate-npm-package-name; + npm-->which; + npm-->write-file-atomic; + npm-audit-report-->chalk; + npm-bundled-->npm-normalize-package-bin; + npm-install-checks-->semver; + npm-package-arg-->hosted-git-info; + npm-package-arg-->proc-log; + npm-package-arg-->semver; + npm-package-arg-->validate-npm-package-name; + npm-packlist-->ignore-walk; + npm-pick-manifest-->npm-install-checks; + npm-pick-manifest-->npm-normalize-package-bin; + npm-pick-manifest-->npm-package-arg; + npm-pick-manifest-->semver; + npm-profile-->npm-registry-fetch; + npm-profile-->proc-log; + npm-registry-fetch-->make-fetch-happen; + npm-registry-fetch-->minipass-fetch; + npm-registry-fetch-->minipass-json-stream; + npm-registry-fetch-->minipass; + npm-registry-fetch-->minizlib; + npm-registry-fetch-->npm-package-arg; + npm-registry-fetch-->proc-log; + npmcli-arborist-->benchmark; + npmcli-arborist-->bin-links; + npmcli-arborist-->cacache; + npmcli-arborist-->chalk; + npmcli-arborist-->common-ancestor-path; + npmcli-arborist-->hosted-git-info; + npmcli-arborist-->isaacs-string-locale-compare["@isaacs/string-locale-compare"]; + npmcli-arborist-->json-parse-even-better-errors; + npmcli-arborist-->json-stringify-nice; + npmcli-arborist-->minify-registry-metadata; + npmcli-arborist-->minimatch; + npmcli-arborist-->nock; + npmcli-arborist-->nopt; + npmcli-arborist-->npm-install-checks; + npmcli-arborist-->npm-package-arg; + npmcli-arborist-->npm-pick-manifest; + npmcli-arborist-->npm-registry-fetch; + npmcli-arborist-->npmcli-eslint-config["@npmcli/eslint-config"]; + npmcli-arborist-->npmcli-fs["@npmcli/fs"]; + npmcli-arborist-->npmcli-installed-package-contents["@npmcli/installed-package-contents"]; + npmcli-arborist-->npmcli-map-workspaces["@npmcli/map-workspaces"]; + npmcli-arborist-->npmcli-metavuln-calculator["@npmcli/metavuln-calculator"]; + npmcli-arborist-->npmcli-name-from-folder["@npmcli/name-from-folder"]; + npmcli-arborist-->npmcli-node-gyp["@npmcli/node-gyp"]; + npmcli-arborist-->npmcli-package-json["@npmcli/package-json"]; + npmcli-arborist-->npmcli-query["@npmcli/query"]; + npmcli-arborist-->npmcli-run-script["@npmcli/run-script"]; + npmcli-arborist-->npmcli-template-oss["@npmcli/template-oss"]; + npmcli-arborist-->npmlog; + npmcli-arborist-->pacote; + npmcli-arborist-->parse-conflict-json; + npmcli-arborist-->proc-log; + npmcli-arborist-->promise-all-reject-late; + npmcli-arborist-->promise-call-limit; + npmcli-arborist-->read-package-json-fast; + npmcli-arborist-->semver; + npmcli-arborist-->ssri; + npmcli-arborist-->tap; + npmcli-arborist-->tcompare; + npmcli-arborist-->treeverse; + npmcli-arborist-->walk-up-path; + npmcli-config-->ini; + npmcli-config-->nopt; + npmcli-config-->npmcli-eslint-config["@npmcli/eslint-config"]; + npmcli-config-->npmcli-map-workspaces["@npmcli/map-workspaces"]; + npmcli-config-->npmcli-template-oss["@npmcli/template-oss"]; + npmcli-config-->proc-log; + npmcli-config-->read-package-json-fast; + npmcli-config-->semver; + npmcli-config-->tap; + npmcli-config-->walk-up-path; + npmcli-disparity-colors-->ansi-styles; + npmcli-docs-->front-matter; + npmcli-docs-->ignore-walk; + npmcli-docs-->isaacs-string-locale-compare["@isaacs/string-locale-compare"]; + npmcli-docs-->jsdom; + npmcli-docs-->mkdirp; + npmcli-docs-->npmcli-eslint-config["@npmcli/eslint-config"]; + npmcli-docs-->npmcli-template-oss["@npmcli/template-oss"]; + npmcli-docs-->rehype-stringify; + npmcli-docs-->remark-gfm; + npmcli-docs-->remark-man; + npmcli-docs-->remark-parse; + npmcli-docs-->remark-rehype; + npmcli-docs-->tap; + npmcli-docs-->unified; + npmcli-docs-->yaml; + npmcli-fs-->semver; + npmcli-git-->lru-cache; + npmcli-git-->mkdirp; + npmcli-git-->npm-pick-manifest; + npmcli-git-->npmcli-promise-spawn["@npmcli/promise-spawn"]; + npmcli-git-->proc-log; + npmcli-git-->promise-inflight; + npmcli-git-->promise-retry; + npmcli-git-->semver; + npmcli-git-->which; + npmcli-installed-package-contents-->npm-bundled; + npmcli-installed-package-contents-->npm-normalize-package-bin; + npmcli-map-workspaces-->glob; + npmcli-map-workspaces-->minimatch; + npmcli-map-workspaces-->npmcli-name-from-folder["@npmcli/name-from-folder"]; + npmcli-map-workspaces-->read-package-json-fast; + npmcli-metavuln-calculator-->cacache; + npmcli-metavuln-calculator-->json-parse-even-better-errors; + npmcli-metavuln-calculator-->pacote; + npmcli-metavuln-calculator-->semver; + npmcli-mock-registry-->nock; + npmcli-mock-registry-->npm-package-arg; + npmcli-mock-registry-->npmcli-arborist["@npmcli/arborist"]; + npmcli-mock-registry-->npmcli-eslint-config["@npmcli/eslint-config"]; + npmcli-mock-registry-->npmcli-template-oss["@npmcli/template-oss"]; + npmcli-mock-registry-->pacote; + npmcli-mock-registry-->tap; + npmcli-move-file-->mkdirp; + npmcli-move-file-->rimraf; + npmcli-package-json-->json-parse-even-better-errors; + npmcli-promise-spawn-->which; + npmcli-query-->postcss-selector-parser; + npmcli-run-script-->node-gyp; + npmcli-run-script-->npmcli-node-gyp["@npmcli/node-gyp"]; + npmcli-run-script-->npmcli-promise-spawn["@npmcli/promise-spawn"]; + npmcli-run-script-->read-package-json-fast; + npmcli-run-script-->which; + npmcli-smoke-tests-->http-proxy; + npmcli-smoke-tests-->just-extend; + npmcli-smoke-tests-->just-safe-set; + npmcli-smoke-tests-->npmcli-eslint-config["@npmcli/eslint-config"]; + npmcli-smoke-tests-->npmcli-mock-registry["@npmcli/mock-registry"]; + npmcli-smoke-tests-->npmcli-promise-spawn["@npmcli/promise-spawn"]; + npmcli-smoke-tests-->npmcli-template-oss["@npmcli/template-oss"]; + npmcli-smoke-tests-->tap; + npmcli-smoke-tests-->which; + npmlog-->are-we-there-yet; + npmlog-->console-control-strings; + npmlog-->gauge; + npmlog-->set-blocking; + once-->wrappy; + p-map-->aggregate-error; + pacote-->cacache; + pacote-->fs-minipass; + pacote-->minipass; + pacote-->npm-package-arg; + pacote-->npm-packlist; + pacote-->npm-pick-manifest; + pacote-->npm-registry-fetch; + pacote-->npmcli-git["@npmcli/git"]; + pacote-->npmcli-installed-package-contents["@npmcli/installed-package-contents"]; + pacote-->npmcli-promise-spawn["@npmcli/promise-spawn"]; + pacote-->npmcli-run-script["@npmcli/run-script"]; + pacote-->proc-log; + pacote-->promise-retry; + pacote-->read-package-json-fast; + pacote-->read-package-json; + pacote-->ssri; + pacote-->tar; + parse-conflict-json-->json-parse-even-better-errors; + parse-conflict-json-->just-diff-apply; + parse-conflict-json-->just-diff; + postcss-selector-parser-->cssesc; + postcss-selector-parser-->util-deprecate; + promise-retry-->err-code; + promise-retry-->retry; + promzard-->read; + read-->mute-stream; + read-package-json-->glob; + read-package-json-->json-parse-even-better-errors; + read-package-json-->normalize-package-data; + read-package-json-->npm-normalize-package-bin; + read-package-json-fast-->json-parse-even-better-errors; + read-package-json-fast-->npm-normalize-package-bin; + readable-stream-->inherits; + readable-stream-->string_decoder; + readable-stream-->util-deprecate; + rimraf-->glob; + semver-->lru-cache; + socks-->ip; + socks-->smart-buffer; + socks-proxy-agent-->agent-base; + socks-proxy-agent-->debug; + socks-proxy-agent-->socks; + spdx-correct-->spdx-expression-parse; + spdx-correct-->spdx-license-ids; + spdx-expression-parse-->spdx-exceptions; + spdx-expression-parse-->spdx-license-ids; + ssri-->minipass; + string-width-->emoji-regex; + string-width-->is-fullwidth-code-point; + string-width-->strip-ansi; + string_decoder-->safe-buffer; + strip-ansi-->ansi-regex; + supports-color-->has-flag; + tar-->chownr; + tar-->fs-minipass; + tar-->minipass; + tar-->minizlib; + tar-->mkdirp; + tar-->yallist; + unique-filename-->unique-slug; + unique-slug-->imurmurhash; + validate-npm-package-license-->spdx-correct; + validate-npm-package-license-->spdx-expression-parse; + validate-npm-package-name-->builtins; + wcwidth-->defaults; + which-->isexe; + wide-align-->string-width; + write-file-atomic-->imurmurhash; + write-file-atomic-->signal-exit; +``` + +## npm dependency heirarchy + +These are the groups of dependencies in npm that depend on each other. +Each group depends on packages lower down the chain, nothing depends on +packages higher up the chain. + + - npm + - @npmcli/smoke-tests, libnpmaccess, libnpmexec, libnpmpublish + - @npmcli/mock-registry, libnpmdiff, libnpmfund, libnpmpack + - @npmcli/arborist + - @npmcli/metavuln-calculator + - pacote, libnpmhook, libnpmorg, libnpmsearch, libnpmteam, npm-profile + - npm-registry-fetch, libnpmversion + - @npmcli/git, make-fetch-happen, @npmcli/config, init-package-json + - @npmcli/installed-package-contents, @npmcli/map-workspaces, cacache, npm-pick-manifest, @npmcli/run-script, read-package-json, promzard + - @npmcli/docs, @npmcli/fs, npm-bundled, read-package-json-fast, unique-filename, npm-install-checks, npm-package-arg, npm-packlist, normalize-package-data, @npmcli/package-json, bin-links, nopt, npmlog, parse-conflict-json, read + - @npmcli/eslint-config, @npmcli/template-oss, ignore-walk, semver, npm-normalize-package-bin, @npmcli/name-from-folder, json-parse-even-better-errors, fs-minipass, ssri, unique-slug, @npmcli/promise-spawn, hosted-git-info, proc-log, validate-npm-package-name, @npmcli/node-gyp, minipass-fetch, @npmcli/query, cmd-shim, read-cmd-shim, write-file-atomic, abbrev, are-we-there-yet, gauge, treeverse, minify-registry-metadata, ini, @npmcli/disparity-colors, mute-stream, npm-audit-report, npm-user-validate diff --git a/Makefile b/Makefile deleted file mode 100644 index 09a12af..0000000 --- a/Makefile +++ /dev/null @@ -1,123 +0,0 @@ -# vim: set softtabstop=2 shiftwidth=2: -SHELL = bash - -PUBLISHTAG = $(shell node scripts/publish-tag.js) -BRANCH = $(shell git rev-parse --abbrev-ref HEAD) - -markdowns = $(shell find docs -name '*.md' | grep -v 'index') - -# these docs have the @VERSION@ tag in them, so they have to be rebuilt -# whenever the package.json is touched, in case the version changed. -version_mandocs = $(shell grep -rl '@VERSION@' docs/content \ - |sed 's|.md|.1|g' \ - |sed 's|docs/content/commands/|man/man1/|g' ) - -cli_mandocs = $(shell find docs/content/commands -name '*.md' \ - |sed 's|.md|.1|g' \ - |sed 's|docs/content/commands/|man/man1/|g' ) - -files_mandocs = $(shell find docs/content/configuring-npm -name '*.md' \ - |sed 's|.md|.5|g' \ - |sed 's|docs/content/configuring-npm/|man/man5/|g' ) \ - -misc_mandocs = $(shell find docs/content/using-npm -name '*.md' \ - |sed 's|.md|.7|g' \ - |sed 's|docs/content/using-npm/|man/man7/|g' ) \ - -mandocs = $(cli_mandocs) $(files_mandocs) $(misc_mandocs) - -all: docs - -docs: mandocs htmldocs - -# don't regenerate the snapshot if we're generating -# snapshots, since presumably we just did that. -mandocs: $(mandocs) - @ ! [ $${npm_lifecycle_event} = "snap" ] && \ - ! [ $${npm_lifecycle_event} = "postsnap" ] && \ - TAP_SNAPSHOT=1 node test/lib/utils/config/definitions.js || true - -$(version_mandocs): package.json - -htmldocs: dev-deps - node bin/npm-cli.js rebuild - node bin/npm-cli.js run -w docs build - -clean: docs-clean gitclean - -docsclean: docs-clean - -docs-clean: - rm -rf man - -## build-time dependencies for the documentation -dev-deps: - node bin/npm-cli.js install --no-audit --ignore-scripts - -## targets for man files, these are encouraged to be only built by running `make docs` or `make mandocs` -man/man1/%.1: docs/content/commands/%.md scripts/docs-build.js - @[ -d man/man1 ] || mkdir -p man/man1 - node scripts/docs-build.js $< $@ - -man/man5/npm-json.5: man/man5/package.json.5 - cp $< $@ - -man/man5/npm-global.5: man/man5/folders.5 - cp $< $@ - -man/man5/%.5: docs/content/configuring-npm/%.md scripts/docs-build.js - @[ -d man/man5 ] || mkdir -p man/man5 - node scripts/docs-build.js $< $@ - -man/man7/%.7: docs/content/using-npm/%.md scripts/docs-build.js - @[ -d man/man7 ] || mkdir -p man/man7 - node scripts/docs-build.js $< $@ - -# Any time the config definitions description changes, automatically -# update the documentation to account for it -docs/content/using-npm/config.md: scripts/config-doc.js lib/utils/config/*.js - node scripts/config-doc.js - -docs/content/commands/npm-%.md: lib/%.js scripts/config-doc-command.js lib/utils/config/*.js - node scripts/config-doc-command.js $@ $< - -freshdocs: - touch lib/utils/config/definitions.js - touch scripts/config-doc-command.js - touch scripts/config-doc.js - make docs - -test: dev-deps - node bin/npm-cli.js test - -smoke-tests: dev-deps - node bin/npm-cli.js run smoke-tests -- --no-check-coverage - -ls-ok: - node . ls --production >/dev/null - -gitclean: - git clean -fd - -uninstall: - node bin/npm-cli.js rm -g -f npm - -link: uninstall - node bin/npm-cli.js link -f --ignore-scripts - -prune: - node bin/npm-cli.js run resetdeps - node bin/npm-cli.js prune --production --no-save --no-audit - @[[ "$(shell git status -s)" != "" ]] && echo "ERR: found unpruned files" && exit 1 || echo "git status is clean" - - -publish: gitclean ls-ok link test smoke-tests docs prune - @git push origin :v$(shell node bin/npm-cli.js --no-timing -v) 2>&1 || true - git push origin $(BRANCH) &&\ - git push origin --tags &&\ - node bin/npm-cli.js publish --tag=$(PUBLISHTAG) - -release: gitclean ls-ok docs prune - @bash scripts/release.sh - -.PHONY: all latest install dev link docs clean uninstall test man docs-clean docsclean release ls-ok dev-deps prune freshdocs diff --git a/README.md b/README.md index 46846fa..b88882f 100644 --- a/README.md +++ b/README.md @@ -1,14 +1,17 @@ -[![GitHub Workflow Status (branch)](https://img.shields.io/github/workflow/status/npm/cli/Node%20CI/latest)](https://github.com/npm/cli/actions?query=workflow%3A%22Node+CI%22+branch%3Alatest) [![Coveralls github branch](https://img.shields.io/coveralls/github/npm/cli/latest)](https://coveralls.io/github/npm/cli?branch=latest) - # npm - a JavaScript package manager +[![npm version](https://img.shields.io/npm/v/npm.svg)](https://npm.im/npm) +[![license](https://img.shields.io/npm/l/npm.svg)](https://npm.im/npm) +[![CI - cli](https://github.com/npm/cli/actions/workflows/ci.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci.yml) +[![Benchmark Suite](https://github.com/npm/cli/actions/workflows/benchmark.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/benchmark.yml) + ### Requirements One of the following versions of [Node.js](https://nodejs.org/en/download/) must be installed to run **`npm`**: -* `12.x.x` >= `12.13.0` -* `14.x.x` >= `14.15.0` -* `16.0.0` or higher +* `14.x.x` >= `14.17.0` +* `16.x.x` >= `16.13.0` +* `18.0.0` or higher ### Installation @@ -34,6 +37,7 @@ If you're looking to manage multiple versions of **`node`** &/or **`npm`**, cons * [**`nodenv`**](https://github.com/nodenv/nodenv) * [**`asdf-nodejs`**](https://github.com/asdf-vm/asdf-nodejs) * [**`nvm-windows`**](https://github.com/coreybutler/nvm-windows) +* [**`fnm`**](https://github.com/Schniz/fnm) ### Usage @@ -46,7 +50,7 @@ npm <command> * [**Documentation**](https://docs.npmjs.com/) - Official docs & how-tos for all things **npm** * Note: you can also search docs locally with `npm help-search <query>` * [**Bug Tracker**](https://github.com/npm/cli/issues) - Search or submit bugs against the CLI -* [**Roadmap**](https://github.com/npm/roadmap) - Track & follow along with our public roadmap +* [**Roadmap**](https://github.com/orgs/github/projects/4247/views/1?filterQuery=npm) - Track & follow along with our public roadmap * [**Feedback**](https://github.com/npm/feedback) - Contribute ideas & discussion around the npm registry, website & CLI * [**RFCs**](https://github.com/npm/rfcs) - Contribute ideas & specifications for the API/design of the npm CLI * [**Service Status**](https://status.npmjs.org/) - Monitor the current status & see incident reports for the website & registry diff --git a/SECURITY.md b/SECURITY.md index 41b76c2..4e7c26c 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -1 +1,14 @@ -Please send vulnerability reports through [hackerone](https://hackerone.com/github). +<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> + +GitHub takes the security of our software products and services seriously, including the open source code repositories managed through our GitHub organizations, such as [GitHub](https://github.com/GitHub). + +If you believe you have found a security vulnerability in this GitHub-owned open source repository, you can report it to us in one of two ways. + +If the vulnerability you have found is *not* [in scope for the GitHub Bug Bounty Program](https://bounty.github.com/#scope) or if you do not wish to be considered for a bounty reward, please report the issue to us directly using [private vulnerability reporting](https://docs.github.com/en/code-security/security-advisories/guidance-on-reporting-and-writing/privately-reporting-a-security-vulnerability). + +If the vulnerability you have found is [in scope for the GitHub Bug Bounty Program](https://bounty.github.com/#scope) and you would like for your finding to be considered for a bounty reward, please submit the vulnerability to us through [HackerOne](https://hackerone.com/github) in order to be eligible to receive a bounty award. + +**Please do not report security vulnerabilities through public GitHub issues, discussions, or pull requests.** + +Thanks for helping make GitHub safe for everyone. + diff --git a/bin/node-gyp-bin/node-gyp b/bin/node-gyp-bin/node-gyp index ae7cff3..70efb6f 100755 --- a/bin/node-gyp-bin/node-gyp +++ b/bin/node-gyp-bin/node-gyp @@ -1,6 +1,6 @@ #!/usr/bin/env sh if [ "x$npm_config_node_gyp" = "x" ]; then - /usr/bin/node-gyp "$@" + node "`dirname "$0"`/../../node_modules/node-gyp/bin/node-gyp.js" "$@" else "$npm_config_node_gyp" "$@" fi diff --git a/bin/npx b/bin/npx index 4b58a10..a34e345 100755 --- a/bin/npx +++ b/bin/npx @@ -12,6 +12,9 @@ case `uname` in esac NODE_EXE="$basedir/node.exe" +if ! [ -x "$NODE_EXE" ]; then + NODE_EXE="$basedir/node" +fi if ! [ -x "$NODE_EXE" ]; then NODE_EXE=node fi diff --git a/bin/npx-cli.js b/bin/npx-cli.js index cb05e1c..75090ae 100755 --- a/bin/npx-cli.js +++ b/bin/npx-cli.js @@ -98,6 +98,7 @@ for (i = 3; i < process.argv.length; i++) { } if (removed.has(key)) { + // eslint-disable-next-line no-console console.error(`npx: the --${key} argument has been removed.`) sawRemovedFlags = true process.argv.splice(i, 1) @@ -122,6 +123,7 @@ for (i = 3; i < process.argv.length; i++) { } if (sawRemovedFlags) { + // eslint-disable-next-line no-console console.error('See `npm help exec` for more information') } diff --git a/changelogs/CHANGELOG-1.md b/changelogs/CHANGELOG-1.md deleted file mode 100644 index ea409c3..0000000 --- a/changelogs/CHANGELOG-1.md +++ /dev/null @@ -1,743 +0,0 @@ -### v1.4.29 (2015-10-29): - -#### THINGS ARE HAPPENING IN LTS LAND - -In a special one-off release as part of the [strategy to get a version of npm -into Node LTS that works with the current -registry](https://github.com/nodejs/LTS/issues/37), modify npm to print out -this deprecation banner literally every time npm is invoked to do anything: - -``` -npm WARN deprecated This version of npm lacks support for important features, -npm WARN deprecated such as scoped packages, offered by the primary npm -npm WARN deprecated registry. Consider upgrading to at least npm@2, if not the -npm WARN deprecated latest stable version. To upgrade to npm@2, run: -npm WARN deprecated -npm WARN deprecated npm -g install npm@latest-2 -npm WARN deprecated -npm WARN deprecated To upgrade to the latest stable version, run: -npm WARN deprecated -npm WARN deprecated npm -g install npm@latest -npm WARN deprecated -npm WARN deprecated (Depending on how Node.js was installed on your system, you -npm WARN deprecated may need to prefix the preceding commands with `sudo`, or if -npm WARN deprecated on Windows, run them from an Administrator prompt.) -npm WARN deprecated -npm WARN deprecated If you're running the version of npm bundled with -npm WARN deprecated Node.js 0.10 LTS, be aware that the next version of 0.10 LTS -npm WARN deprecated will be bundled with a version of npm@2, which has some small -npm WARN deprecated backwards-incompatible changes made to `npm run-script` and -npm WARN deprecated semver behavior. -``` - -The message basically tells the tale: Node 0.10 will finally be getting -`npm@2`, so those of you who haven't upgraded your build systems to deal with -its (relatively small) breaking changes should do so now. - -Also, this version doesn't even pretend that it can deal with scoped packages, -which, given the confusing behavior of older versions of `npm@1.4`, where it -would sometimes try to install packages from GitHub, is a distinct improvement. - -There is no good reason for you as an end user to upgrade to this version of -npm yourself. - -* [`709e9b4`](https://github.com/npm/npm/commit/709e9b44f5df9817a1c4babfbf26a2329bd265fb) - Print 20-line deprecation banner on all command invocations. - ([@othiym23](https://github.com/othiym23)) -* [`0c29d09`](https://github.com/npm/npm/commit/0c29d0906608e8e174bd30a7a245e19795326051) - Crash out immediately with an exhortation to upgrade on attempts to use - scoped packages. ([@othiym23](https://github.com/othiym23)) - -### v1.5.0-alpha-4 (2014-07-18): - -* fall back to `_auth` config as default auth when using default registry - ([@isaacs](https://github.com/isaacs)) -* support for 'init.version' for those who don't want to deal with semver 0.0.x - oddities ([@rvagg](https://github.com/rvagg)) -* [`be06213`](https://github.com/npm/npm/commit/be06213415f2d51a50d2c792b4cd0d3412a9a7b1) - remove residual support for `win` log level - ([@aterris](https://github.com/aterris)) - -### v1.5.0-alpha-3 (2014-07-17): - -* [`a3a85dd`](https://github.com/npm/npm/commit/a3a85dd004c9245a71ad2f0213bd1a9a90d64cd6) - `--save` scoped packages correctly ([@othiym23](https://github.com/othiym23)) -* [`18a3385`](https://github.com/npm/npm/commit/18a3385bcf8bfb8312239216afbffb7eec759150) - `npm-registry-client@3.0.2` ([@othiym23](https://github.com/othiym23)) -* [`375988b`](https://github.com/npm/npm/commit/375988b9bf5aa5170f06a790d624d31b1eb32c6d) - invalid package names are an early error for optional deps - ([@othiym23](https://github.com/othiym23)) -* consistently use `node-package-arg` instead of arbitrary package spec - splitting ([@othiym23](https://github.com/othiym23)) - -### v1.5.0-alpha-2 (2014-07-01): - -* [`54cf625`](https://github.com/npm/npm/commit/54cf62534e3331e3f454e609e44f0b944e819283) - fix handling for 301s in `npm-registry-client@3.0.1` - ([@Raynos](https://github.com/Raynos)) -* [`e410861`](https://github.com/npm/npm/commit/e410861c69a3799c1874614cb5b87af8124ff98d) - don't crash if no username set on `whoami` - ([@isaacs](https://github.com/isaacs)) -* [`0353dde`](https://github.com/npm/npm/commit/0353ddeaca8171aa7dbdd8102b7e2eb581a86406) - respect `--json` for output ([@isaacs](https://github.com/isaacs)) -* [`b3d112a`](https://github.com/npm/npm/commit/b3d112ae190b984cc1779b9e6de92218f22380c6) - outdated: Don't show headings if there's nothing to output - ([@isaacs](https://github.com/isaacs)) -* [`bb4b90c`](https://github.com/npm/npm/commit/bb4b90c80dbf906a1cb26d85bc0625dc2758acc3) - outdated: Default to `latest` rather than `*` for unspecified deps - ([@isaacs](https://github.com/isaacs)) - -### v1.5.0-alpha-1 (2014-07-01): - -* [`eef4884`](https://github.com/npm/npm/commit/eef4884d6487ee029813e60a5f9c54e67925d9fa) - use the correct piece of the spec for GitHub shortcuts - ([@othiym23](https://github.com/othiym23)) - -### v1.5.0-alpha-0 (2014-07-01): - -* [`7f55057`](https://github.com/npm/npm/commit/7f55057807cfdd9ceaf6331968e666424f48116c) - install scoped packages ([#5239](https://github.com/npm/npm/issues/5239)) - ([@othiym23](https://github.com/othiym23)) -* [`0df7e16`](https://github.com/npm/npm/commit/0df7e16c0232d8f4d036ebf4ec3563215517caac) - publish scoped packages ([#5239](https://github.com/npm/npm/issues/5239)) - ([@othiym23](https://github.com/othiym23)) -* [`0689ba2`](https://github.com/npm/npm/commit/0689ba249b92b4c6279a26804c96af6f92b3a501) - support (and save) --scope=@s config - ([@othiym23](https://github.com/othiym23)) -* [`f34878f`](https://github.com/npm/npm/commit/f34878fc4cee29901e4daf7bace94be01e25cad7) - scope credentials to registry ([@othiym23](https://github.com/othiym23)) -* [`0ac7ca2`](https://github.com/npm/npm/commit/0ac7ca233f7a69751fe4386af6c4daa3ee9fc0da) - capture and store bearer tokens when sent by registry - ([@othiym23](https://github.com/othiym23)) -* [`63c3277`](https://github.com/npm/npm/commit/63c3277f089b2c4417e922826bdc313ac854cad6) - only delete files that are created by npm - ([@othiym23](https://github.com/othiym23)) -* [`4f54043`](https://github.com/npm/npm/commit/4f540437091d1cbca3915cd20c2da83c2a88bb8e) - `npm-package-arg@2.0.0` ([@othiym23](https://github.com/othiym23)) -* [`9e1460e`](https://github.com/npm/npm/commit/9e1460e6ac9433019758481ec031358f4af4cd44) - `read-package-json@1.2.3` ([@othiym23](https://github.com/othiym23)) -* [`719d8ad`](https://github.com/npm/npm/commit/719d8adb9082401f905ff4207ede494661f8a554) - `fs-vacuum@1.2.1` ([@othiym23](https://github.com/othiym23)) -* [`9ef8fe4`](https://github.com/npm/npm/commit/9ef8fe4d6ead3acb3e88c712000e2d3a9480ebec) - `async-some@1.0.0` ([@othiym23](https://github.com/othiym23)) -* [`a964f65`](https://github.com/npm/npm/commit/a964f65ab662107b62a4ca58535ce817e8cca331) - `npmconf@2.0.1` ([@othiym23](https://github.com/othiym23)) -* [`113765b`](https://github.com/npm/npm/commit/113765bfb7d3801917c1d9f124b8b3d942bec89a) - `npm-registry-client@3.0.0` ([@othiym23](https://github.com/othiym23)) - -### v1.4.28 (2014-09-12): - -* [`f4540b6`](https://github.com/npm/npm/commit/f4540b6537a87e653d7495a9ddcf72949fdd4d14) - [#6043](https://github.com/npm/npm/issues/6043) defer rollbacks until just - before the CLI exits ([@isaacs](https://github.com/isaacs)) -* [`1eabfd5`](https://github.com/npm/npm/commit/1eabfd5c03f33c2bd28823714ff02059eeee3899) - [#6043](https://github.com/npm/npm/issues/6043) `slide@1.1.6`: wait until all - callbacks have finished before proceeding - ([@othiym23](https://github.com/othiym23)) - -### v1.4.27 (2014-09-04): - -* [`4cf3c8f`](https://github.com/npm/npm/commit/4cf3c8fd78c9e2693a5f899f50c28f4823c88e2e) - [#6007](https://github.com/npm/npm/issues/6007) request@2.42.0: properly set - headers on proxy requests ([@isaacs](https://github.com/isaacs)) -* [`403cb52`](https://github.com/npm/npm/commit/403cb526be1472bb7545fa8e62d4976382cdbbe5) - [#6055](https://github.com/npm/npm/issues/6055) npmconf@1.1.8: restore - case-insensitivity of environmental config - ([@iarna](https://github.com/iarna)) - -### v1.4.26 (2014-08-28): - -* [`eceea95`](https://github.com/npm/npm/commit/eceea95c804fa15b18e91c52c0beb08d42a3e77d) - `github-url-from-git@1.4.0`: add support for git+https and git+ssh - ([@stefanbuck](https://github.com/stefanbuck)) -* [`e561758`](https://github.com/npm/npm/commit/e5617587e7d7ab686192391ce55357dbc7fed0a3) - `columnify@1.2.1` ([@othiym23](https://github.com/othiym23)) -* [`0c4fab3`](https://github.com/npm/npm/commit/0c4fab372ee76eab01dda83b6749429a8564902e) - `cmd-shim@2.0.0`: upgrade to graceful-fs 3 - ([@ForbesLindesay](https://github.com/ForbesLindesay)) -* [`2d69e4d`](https://github.com/npm/npm/commit/2d69e4d95777671958b5e08d3b2f5844109d73e4) - `github-url-from-username-repo@1.0.0`: accept slashes in branch names - ([@robertkowalski](https://github.com/robertkowalski)) -* [`81f9b2b`](https://github.com/npm/npm/commit/81f9b2bac9d34c223ea093281ba3c495f23f10d1) - ensure lifecycle spawn errors caught properly - ([@isaacs](https://github.com/isaacs)) -* [`bfaab8c`](https://github.com/npm/npm/commit/bfaab8c6e0942382a96b250634ded22454c36b5a) - `npm-registry-client@2.0.7`: properly encode % in passwords - ([@isaacs](https://github.com/isaacs)) -* [`91cfb58`](https://github.com/npm/npm/commit/91cfb58dda851377ec604782263519f01fd96ad8) - doc: Fix 'npm help index' ([@isaacs](https://github.com/isaacs)) - -### v1.4.25 (2014-08-21): - -* [`64c0ec2`](https://github.com/npm/npm/commit/64c0ec241ef5d83761ca8de54acb3c41b079956e) - `npm-registry-client@2.0.6`: Print the notification header returned by the - registry, and make sure status codes are printed without gratuitous quotes - around them. - ([@othiym23](https://github.com/othiym23)) -* [`a8ed12b`](https://github.com/npm/npm/commit/a8ed12b) `tar@1.0.1`: - Add test for removing an extract target immediately after unpacking. - ([@isaacs](https://github.com/isaacs)) -* [`70fd11d`](https://github.com/npm/npm/commit/70fd11d) - `lockfile@1.0.0`: Fix incorrect interaction between `wait`, `stale`, - and `retries` options. Part 2 of race condition leading to `ENOENT` - errors. - ([@isaacs](https://github.com/isaacs)) -* [`0072c4d`](https://github.com/npm/npm/commit/0072c4d) - `fstream@1.0.2`: Fix a double-finish call which can result in excess - FS operations after the `close` event. Part 2 of race condition - leading to `ENOENT` errors. - ([@isaacs](https://github.com/isaacs)) - -### v1.4.24 (2014-08-14): - -* [`9344bd9`](https://github.com/npm/npm/commit/9344bd9b2929b5c399a0e0e0b34d45bce7bc24bb) - doc: add new changelog ([@othiym23](https://github.com/othiym23)) -* [`4be76fd`](https://github.com/npm/npm/commit/4be76fd65e895883c337a99f275ccc8c801adda3) - doc: update version doc to include `pre-*` increment args - ([@isaacs](https://github.com/isaacs)) -* [`e4f2620`](https://github.com/npm/npm/commit/e4f262036080a282ad60e236a9aeebd39fde9fe4) - build: add `make tag` to tag current release as `latest` - ([@isaacs](https://github.com/isaacs)) -* [`ec2596a`](https://github.com/npm/npm/commit/ec2596a7cb626772780b25b0a94a7e547a812bd5) - build: publish with `--tag=v1.4-next` ([@isaacs](https://github.com/isaacs)) -* [`9ee55f8`](https://github.com/npm/npm/commit/9ee55f892b8b473032a43c59912c5684fd1b39e6) - build: add script to output `v1.4-next` publish tag - ([@isaacs](https://github.com/isaacs)) -* [`aecb56f`](https://github.com/npm/npm/commit/aecb56f95a84687ea46920a0b98aaa587fee1568) - build: remove outdated `docpublish` make target - ([@isaacs](https://github.com/isaacs)) -* [`b57a9b7`](https://github.com/npm/npm/commit/b57a9b7ccd13e6b38831ed63595c8ea5763da247) - build: remove unpublish step from `make publish` - ([@isaacs](https://github.com/isaacs)) -* [`2c6acb9`](https://github.com/npm/npm/commit/2c6acb96c71c16106965d5cd829b67195dd673c7) - install: rename `.gitignore` when unpacking foreign tarballs - ([@isaacs](https://github.com/isaacs)) -* [`22f3681`](https://github.com/npm/npm/commit/22f3681923e993a47fc1769ba735bfa3dd138082) - cache: detect non-gzipped tar files more reliably - ([@isaacs](https://github.com/isaacs)) - -### v1.4.23 (2014-07-31): - -* [`8dd11d1`](https://github.com/npm/npm/commit/8dd11d1) update several - dependencies to avoid using `semver`s starting with 0. - -### v1.4.22 (2014-07-31): - -* [`d9a9e84`](https://github.com/npm/npm/commit/d9a9e84) `read-package-json@1.2.4` - ([@isaacs](https://github.com/isaacs)) -* [`86f0340`](https://github.com/npm/npm/commit/86f0340) - `github-url-from-git@1.2.0` ([@isaacs](https://github.com/isaacs)) -* [`a94136a`](https://github.com/npm/npm/commit/a94136a) `fstream@0.1.29` - ([@isaacs](https://github.com/isaacs)) -* [`bb82d18`](https://github.com/npm/npm/commit/bb82d18) `glob@4.0.5` - ([@isaacs](https://github.com/isaacs)) -* [`5b6bcf4`](https://github.com/npm/npm/commit/5b6bcf4) `cmd-shim@1.1.2` - ([@isaacs](https://github.com/isaacs)) -* [`c2aa8b3`](https://github.com/npm/npm/commit/c2aa8b3) license: Cleaned up - legalese with actual lawyer ([@isaacs](https://github.com/isaacs)) -* [`63fe0ee`](https://github.com/npm/npm/commit/63fe0ee) `init-package-json@1.0.0` - ([@isaacs](https://github.com/isaacs)) - -### v1.4.21 (2014-07-14): - -* [`88f51aa`](https://github.com/npm/npm/commit/88f51aa27eb9a958d1fa7ec50fee5cfdedd05110) - fix handling for 301s in `npm-registry-client@2.0.3` - ([@Raynos](https://github.com/Raynos)) - -### v1.4.20 (2014-07-02): - -* [`0353dde`](https://github.com/npm/npm/commit/0353ddeaca8171aa7dbdd8102b7e2eb581a86406) - respect `--json` for output ([@isaacs](https://github.com/isaacs)) -* [`b3d112a`](https://github.com/npm/npm/commit/b3d112ae190b984cc1779b9e6de92218f22380c6) - outdated: Don't show headings if there's nothing to output - ([@isaacs](https://github.com/isaacs)) -* [`bb4b90c`](https://github.com/npm/npm/commit/bb4b90c80dbf906a1cb26d85bc0625dc2758acc3) - outdated: Default to `latest` rather than `*` for unspecified deps - ([@isaacs](https://github.com/isaacs)) - -### v1.4.19 (2014-07-01): - -* [`f687433`](https://github.com/npm/npm/commit/f687433) relative URLS for - working non-root registry URLS ([@othiym23](https://github.com/othiym23)) -* [`bea190c`](https://github.com/npm/npm/commit/bea190c) - [#5591](https://github.com/npm/npm/issues/5591) bump nopt and npmconf - ([@isaacs](https://github.com/isaacs)) - -### v1.4.18 (2014-06-29): - -* Bump glob dependency from 4.0.2 to 4.0.3. It now uses graceful-fs when - available, increasing resilience to [various filesystem - errors](https://github.com/isaacs/node-graceful-fs#improvements-over-fs-module). - ([@isaacs](https://github.com/isaacs)) - -### v1.4.17 (2014-06-27): - -* replace escape codes with ansicolors - ([@othiym23](https://github.com/othiym23)) -* Allow to build all the docs OOTB. ([@GeJ](https://github.com/GeJ)) -* Use core.longpaths on win32 git - fixes - [#5525](https://github.com/npm/npm/issues/5525) ([@bmeck](https://github.com/bmeck)) -* `npmconf@1.1.2` ([@isaacs](https://github.com/isaacs)) -* Consolidate color sniffing in config/log loading process - ([@isaacs](https://github.com/isaacs)) -* add verbose log when project config file is ignored - ([@isaacs](https://github.com/isaacs)) -* npmconf: Float patch to remove 'scope' from config defs - ([@isaacs](https://github.com/isaacs)) -* doc: npm-explore can't handle a version - ([@robertkowalski](https://github.com/robertkowalski)) -* Add user-friendly errors for ENOSPC and EROFS. - ([@voodootikigod](https://github.com/voodootikigod)) -* bump tar and fstream deps ([@isaacs](https://github.com/isaacs)) -* Run the npm-registry-couchapp tests along with npm tests - ([@isaacs](https://github.com/isaacs)) - -### v1.2.8000 (2014-06-17): - -* Same as v1.4.16, but with the spinner disabled, and a version number that - starts with v1.2. - -### v1.4.16 (2014-06-17): - -* `npm-registry-client@2.0.2` ([@isaacs](https://github.com/isaacs)) -* `fstream@0.1.27` ([@isaacs](https://github.com/isaacs)) -* `sha@1.2.4` ([@isaacs](https://github.com/isaacs)) -* `rimraf@2.2.8` ([@isaacs](https://github.com/isaacs)) -* `npmlog@1.0.1` ([@isaacs](https://github.com/isaacs)) -* `npm-registry-client@2.0.1` ([@isaacs](https://github.com/isaacs)) -* removed redundant dependency ([@othiym23](https://github.com/othiym23)) -* `npmconf@1.0.5` ([@isaacs](https://github.com/isaacs)) -* Properly handle errors that can occur in the config-loading process - ([@isaacs](https://github.com/isaacs)) - -### v1.4.15 (2014-06-10): - -* cache: atomic de-race-ified package.json writing - ([@isaacs](https://github.com/isaacs)) -* `fstream@0.1.26` ([@isaacs](https://github.com/isaacs)) -* `graceful-fs@3.0.2` ([@isaacs](https://github.com/isaacs)) -* `osenv@0.1.0` ([@isaacs](https://github.com/isaacs)) -* Only spin the spinner when we're fetching stuff - ([@isaacs](https://github.com/isaacs)) -* Update `osenv@0.1.0` which removes ~/tmp as possible tmp-folder - ([@robertkowalski](https://github.com/robertkowalski)) -* `ini@1.2.1` ([@isaacs](https://github.com/isaacs)) -* `graceful-fs@3` ([@isaacs](https://github.com/isaacs)) -* Update glob and things depending on glob - ([@isaacs](https://github.com/isaacs)) -* github-url-from-username-repo and read-package-json updates - ([@isaacs](https://github.com/isaacs)) -* `editor@0.1.0` ([@isaacs](https://github.com/isaacs)) -* `columnify@1.1.0` ([@isaacs](https://github.com/isaacs)) -* bump ansi and associated deps ([@isaacs](https://github.com/isaacs)) - -### v1.4.14 (2014-06-05): - -* char-spinner: update to not bork windows - ([@isaacs](https://github.com/isaacs)) - -### v1.4.13 (2014-05-23): - -* Fix `npm install` on a tarball. - ([`ed3abf1`](https://github.com/npm/npm/commit/ed3abf1aa10000f0f687330e976d78d1955557f6), - [#5330](https://github.com/npm/npm/issues/5330), - [@othiym23](https://github.com/othiym23)) -* Fix an issue with the spinner on Node 0.8. - ([`9f00306`](https://github.com/npm/npm/commit/9f003067909440390198c0b8f92560d84da37762), - [@isaacs](https://github.com/isaacs)) -* Re-add `npm.commands.cache.clean` and `npm.commands.cache.read` APIs, and - document `npm.commands.cache.*` as npm-cache(3). - ([`e06799e`](https://github.com/npm/npm/commit/e06799e77e60c1fc51869619083a25e074d368b3), - [@isaacs](https://github.com/isaacs)) - -### v1.4.12 (2014-05-23): - -* remove normalize-package-data from top level, de-^-ify inflight dep - ([@isaacs](https://github.com/isaacs)) -* Always sort saved bundleDependencies ([@isaacs](https://github.com/isaacs)) -* add inflight to bundledDependencies - ([@othiym23](https://github.com/othiym23)) - -### v1.4.11 (2014-05-22): - -* fix `npm ls` labeling issue -* `node-gyp@0.13.1` -* default repository to https:// instead of git:// -* addLocalTarball: Remove extraneous unpack - ([@isaacs](https://github.com/isaacs)) -* Massive cache folder refactor ([@othiym23](https://github.com/othiym23) and - [@isaacs](https://github.com/isaacs)) -* Busy Spinner, no http noise ([@isaacs](https://github.com/isaacs)) -* Per-project .npmrc file support ([@isaacs](https://github.com/isaacs)) -* `npmconf@1.0.0`, Refactor config/uid/prefix loading process - ([@isaacs](https://github.com/isaacs)) -* Allow once-disallowed characters in passwords - ([@isaacs](https://github.com/isaacs)) -* Send npm version as 'version' header ([@isaacs](https://github.com/isaacs)) -* fix cygwin encoding issue (Karsten Tinnefeld) -* Allow non-github repositories with `npm repo` - ([@evanlucas](https://github.com/evanlucas)) -* Allow peer deps to be satisfied by grandparent -* Stop optional deps moving into deps on `update --save` - ([@timoxley](https://github.com/timoxley)) -* Ensure only matching deps update with `update --save*` - ([@timoxley](https://github.com/timoxley)) -* Add support for `prerelease`, `preminor`, `prepatch` to `npm version` - -### v1.4.10 (2014-05-05): - -* Don't set referer if already set -* fetch: Send referer and npm-session headers -* `run-script`: Support `--parseable` and `--json` -* list runnable scripts ([@evanlucas](https://github.com/evanlucas)) -* Use marked instead of ronn for html docs - -### v1.4.9 (2014-05-01): - -* Send referer header (with any potentially private stuff redacted) -* Fix critical typo bug in previous npm release - -### v1.4.8 (2014-05-01): - -* Check SHA before using files from cache -* adduser: allow change of the saved password -* Make `npm install` respect `config.unicode` -* Fix lifecycle to pass `Infinity` for config env value -* Don't return 0 exit code on invalid command -* cache: Handle 404s and other HTTP errors as errors -* Resolve ~ in path configs to env.HOME -* Include npm version in default user-agent conf -* npm init: Use ISC as default license, use save-prefix for deps -* Many test and doc fixes - -### v1.4.7 (2014-04-15): - -* Add `--save-prefix` option that can be used to override the default of `^` - when using `npm install --save` and its counterparts. - ([`64eefdf`](https://github.com/npm/npm/commit/64eefdfe26bb27db8dc90e3ab5d27a5ef18a4470), - [@thlorenz](https://github.com/thlorenz)) -* Allow `--silent` to silence the echoing of commands that occurs with `npm - run`. - ([`c95cf08`](https://github.com/npm/npm/commit/c95cf086e5b97dbb48ff95a72517b203a8f29eab), - [@Raynos](https://github.com/Raynos)) -* Some speed improvements to the cache, which should improve install times. - ([`cb94310`](https://github.com/npm/npm/commit/cb94310a6adb18cb7b881eacb8d67171eda8b744), - [`3b0870f`](https://github.com/npm/npm/commit/3b0870fb2f40358b3051abdab6be4319d196b99d), - [`120f5a9`](https://github.com/npm/npm/commit/120f5a93437bbbea9249801574a2f33e44e81c33), - [@isaacs](https://github.com/isaacs)) -* Improve ability to retry registry requests when a subset of the registry - servers are down. - ([`4a5257d`](https://github.com/npm/npm/commit/4a5257de3870ac3dafa39667379f19f6dcd6093e), - https://github.com/npm/npm-registry-client/commit/7686d02cb0b844626d6a401e58c0755ef3bc8432, - [@isaacs](https://github.com/isaacs)) -* Fix marking of peer dependencies as extraneous. - ([`779b164`](https://github.com/npm/npm/commit/779b1649764607b062c031c7e5c972151b4a1754), - https://github.com/npm/read-installed/commit/6680ba6ef235b1ca3273a00b70869798ad662ddc, - [@isaacs](https://github.com/isaacs)) -* Fix npm crashing when doing `npm shrinkwrap` in the presence of a - `package.json` with no dependencies. - ([`a9d9fa5`](https://github.com/npm/npm/commit/a9d9fa5ad3b8c925a589422b7be28d2735f320b0), - [@kislyuk](https://github.com/kislyuk)) -* Fix error when using `npm view` on packages that have no versions or have - been unpublished. - ([`94df2f5`](https://github.com/npm/npm/commit/94df2f56d684b35d1df043660180fc321b743dc8), - [@juliangruber](https://github.com/juliangruber); - [`2241a09`](https://github.com/npm/npm/commit/2241a09c843669c70633c399ce698cec3add40b3), - [@isaacs](https://github.com/isaacs)) - -### v1.4.6 (2014-03-19): - -* Fix extraneous package detection to work in more cases. - ([`f671286`](https://github.com/npm/npm/commit/f671286), npm/read-installed#20, - [@LaurentVB](https://github.com/LaurentVB)) - -### v1.4.5 (2014-03-18): - -* Sort dependencies in `package.json` when doing `npm install --save` and all - its variants. - ([`6fd6ff7`](https://github.com/npm/npm/commit/6fd6ff7e536ea6acd33037b1878d4eca1f931985), - [@domenic](https://github.com/domenic)) -* Add `--save-exact` option, usable alongside `--save` and its variants, which - will write the exact version number into `package.json` instead of the - appropriate semver-compatibility range. - ([`17f07df`](https://github.com/npm/npm/commit/17f07df8ad8e594304c2445bf7489cb53346f2c5), - [@timoxley](https://github.com/timoxley)) -* Accept gzipped content from the registry to speed up downloads and save - bandwidth. - ([`a3762de`](https://github.com/npm/npm/commit/a3762de843b842be8fa0ab57cdcd6b164f145942), - npm/npm-registry-client#40, [@fengmk2](https://github.com/fengmk2)) -* Fix `npm ls`'s `--depth` and `--log` options. - ([`1d29b17`](https://github.com/npm/npm/commit/1d29b17f5193d52a5c4faa412a95313dcf41ed91), - npm/read-installed#13, [@zertosh](https://github.com/zertosh)) -* Fix "Adding a cache directory to the cache will make the world implode" in - certain cases. - ([`9a4b2c4`](https://github.com/npm/npm/commit/9a4b2c4667c2b1e0054e3d5611ab86acb1760834), - domenic/path-is-inside#1, [@pmarques](https://github.com/pmarques)) -* Fix readmes not being uploaded in certain rare cases. - ([`527b72c`](https://github.com/npm/npm/commit/527b72cca6c55762b51e592c48a9f28cc7e2ff8b), - [@isaacs](https://github.com/isaacs)) - -### v1.4.4 (2014-02-20): - -* Add `npm t` as an alias for `npm test` (which is itself an alias for `npm run - test`, or even `npm run-script test`). We like making running your tests - easy. ([`14e650b`](https://github.com/npm/npm/commit/14e650bce0bfebba10094c961ac104a61417a5de), [@isaacs](https://github.com/isaacs)) - -### v1.4.3 (2014-02-16): - -* Add back `npm prune --production`, which was removed in 1.3.24. - ([`acc4d02`](https://github.com/npm/npm/commit/acc4d023c57d07704b20a0955e4bf10ee91bdc83), - [@davglass](https://github.com/davglass)) -* Default `npm install --save` and its counterparts to use the `^` version - specifier, instead of `~`. - ([`0a3151c`](https://github.com/npm/npm/commit/0a3151c9cbeb50c1c65895685c2eabdc7e2608dc), - [@mikolalysenko](https://github.com/mikolalysenko)) -* Make `npm shrinkwrap` output dependencies in a sorted order, so that diffs - between shrinkwrap files should be saner now. - ([`059b2bf`](https://github.com/npm/npm/commit/059b2bfd06ae775205a37257dca80142596a0113), - [@Raynos](https://github.com/Raynos)) -* Fix `npm dedupe` not correctly respecting dependency constraints. - ([`86028e9`](https://github.com/npm/npm/commit/86028e9fd8524d5e520ce01ba2ebab5a030103fc), - [@rafeca](https://github.com/rafeca)) -* Fix `npm ls` giving spurious warnings when you used `"latest"` as a version - specifier. - (https://github.com/npm/read-installed/commit/d2956400e0386931c926e0f30c334840e0938f14, - [@bajtos](https://github.com/bajtos)) -* Fixed a bug where using `npm link` on packages without a `name` value could - cause npm to delete itself. - ([`401a642`](https://github.com/npm/npm/commit/401a64286aa6665a94d1d2f13604f7014c5fce87), - [@isaacs](https://github.com/isaacs)) -* Fixed `npm install ./pkg@1.2.3` to actually install the directory at - `pkg@1.2.3`; before it would try to find version `1.2.3` of the package - `./pkg` in the npm registry. - ([`46d8768`](https://github.com/npm/npm/commit/46d876821d1dd94c050d5ebc86444bed12c56739), - [@rlidwka](https://github.com/rlidwka); see also - [`f851b79`](https://github.com/npm/npm/commit/f851b79a71d9a5f5125aa85877c94faaf91bea5f)) -* Fix `npm outdated` to respect the `color` configuration option. - ([`d4f6f3f`](https://github.com/npm/npm/commit/d4f6f3ff83bd14fb60d3ac6392cb8eb6b1c55ce1), - [@timoxley](https://github.com/timoxley)) -* Fix `npm outdated --parseable`. - ([`9575a23`](https://github.com/npm/npm/commit/9575a23f955ce3e75b509c89504ef0bd707c8cf6), - [@yhpark](https://github.com/yhpark)) -* Fix a lockfile-related errors when using certain Git URLs. - ([`164b97e`](https://github.com/npm/npm/commit/164b97e6089f64e686db7a9a24016f245effc37f), - [@nigelzor](https://github.com/nigelzor)) - -### v1.4.2 (2014-02-13): - -* Fixed an issue related to mid-publish GET requests made against the registry. - (https://github.com/npm/npm-registry-client/commit/acbec48372bc1816c67c9e7cbf814cf50437ff93, - [@isaacs](https://github.com/isaacs)) - -### v1.4.1 (2014-02-13): - -* Fix `npm shrinkwrap` forgetting to shrinkwrap dependencies that were also - development dependencies. - ([`9c575c5`](https://github.com/npm/npm/commit/9c575c56efa9b0c8b0d4a17cb9c1de3833004bcd), - [@diwu1989](https://github.com/diwu1989)) -* Fixed publishing of pre-existing packages with uppercase characters in their - name. - (https://github.com/npm/npm-registry-client/commit/9345d3b6c3d8510dd5c4418f27ee1fce59acebad, - [@isaacs](https://github.com/isaacs)) - -### v1.4.0 (2014-02-12): - -* Remove `npm publish --force`. See - https://github.com/npm/npmjs.org/issues/148. - ([@isaacs](https://github.com/isaacs), - npm/npm-registry-client@2c8dba990de6a59af6545b75cc00a6dc12777c2a) -* Other changes to the registry client related to saved configs and couch - logins. ([@isaacs](https://github.com/isaacs); - npm/npm-registry-client@25e2b019a1588155e5f87d035c27e79963b75951, - npm/npm-registry-client@9e41e9101b68036e0f078398785f618575f3cdde, - npm/npm-registry-client@2c8dba990de6a59af6545b75cc00a6dc12777c2a) -* Show an error to the user when doing `npm update` and the `package.json` - specifies a version that does not exist. - ([@evanlucas](https://github.com/evanlucas), - [`027a33a`](https://github.com/npm/npm/commit/027a33a5c594124cc1d82ddec5aee2c18bc8dc32)) -* Fix some issues with cache ownership in certain installation configurations. - ([@outcoldman](https://github.com/outcoldman), - [`a132690`](https://github.com/npm/npm/commit/a132690a2876cda5dcd1e4ca751f21dfcb11cb9e)) -* Fix issues where GitHub shorthand dependencies `user/repo` were not always - treated the same as full Git URLs. - ([@robertkowalski](https://github.com/robertkowalski), - https://github.com/meryn/normalize-package-data/commit/005d0b637aec1895117fcb4e3b49185eebf9e240) - -### v1.3.26 (2014-02-02): - -* Fixes and updates to publishing code - ([`735427a`](https://github.com/npm/npm/commit/735427a69ba4fe92aafa2d88f202aaa42920a9e2) - and - [`c0ac832`](https://github.com/npm/npm/commit/c0ac83224d49aa62e55577f8f27d53bbfd640dc5), - [@isaacs](https://github.com/isaacs)) -* Fix `npm bugs` with no arguments. - ([`b99d465`](https://github.com/npm/npm/commit/b99d465221ac03bca30976cbf4d62ca80ab34091), - [@Hoops](https://github.com/Hoops)) - -### v1.3.25 (2014-01-25): - -* Remove gubblebum blocky font from documentation headers. - ([`6940c9a`](https://github.com/npm/npm/commit/6940c9a100160056dc6be8f54a7ad7fa8ceda7e2), - [@isaacs](https://github.com/isaacs)) - -### v1.3.24 (2014-01-19): - -* Make the search output prettier, with nice truncated columns, and a `--long` - option to create wrapping columns. - ([`20439b2`](https://github.com/npm/npm/commit/20439b2) and - [`3a6942d`](https://github.com/npm/npm/commit/3a6942d), - [@timoxley](https://github.com/timoxley)) -* Support multiple packagenames in `npm docs`. - ([`823010b`](https://github.com/npm/npm/commit/823010b), - [@timoxley](https://github.com/timoxley)) -* Fix the `npm adduser` bug regarding "Error: default value must be string or - number" again. ([`b9b4248`](https://github.com/npm/npm/commit/b9b4248), - [@isaacs](https://github.com/isaacs)) -* Fix `scripts` entries containing whitespaces on Windows. - ([`80282ed`](https://github.com/npm/npm/commit/80282ed), - [@robertkowalski](https://github.com/robertkowalski)) -* Fix `npm update` for Git URLs that have credentials in them - ([`93fc364`](https://github.com/npm/npm/commit/93fc364), - [@danielsantiago](https://github.com/danielsantiago)) -* Fix `npm install` overwriting `npm link`-ed dependencies when they are tagged - Git dependencies. ([`af9bbd9`](https://github.com/npm/npm/commit/af9bbd9), - [@evanlucas](https://github.com/evanlucas)) -* Remove `npm prune --production` since it buggily removed some dependencies - that were necessary for production; see - [#4509](https://github.com/npm/npm/issues/4509). Hopefully it can make its - triumphant return, one day. - ([`1101b6a`](https://github.com/npm/npm/commit/1101b6a), - [@isaacs](https://github.com/isaacs)) - -Dependency updates: -* [`909cccf`](https://github.com/npm/npm/commit/909cccf) `read-package-json@1.1.6` -* [`a3891b6`](https://github.com/npm/npm/commit/a3891b6) `rimraf@2.2.6` -* [`ac6efbc`](https://github.com/npm/npm/commit/ac6efbc) `sha@1.2.3` -* [`dd30038`](https://github.com/npm/npm/commit/dd30038) `node-gyp@0.12.2` -* [`c8c3ebe`](https://github.com/npm/npm/commit/c8c3ebe) `npm-registry-client@0.3.3` -* [`4315286`](https://github.com/npm/npm/commit/4315286) `npmconf@0.1.12` - -### v1.3.23 (2014-01-03): - -* Properly handle installations that contained a certain class of circular - dependencies. - ([`5dc93e8`](https://github.com/npm/npm/commit/5dc93e8c82604c45b6067b1acf1c768e0bfce754), - [@substack](https://github.com/substack)) - -### v1.3.22 (2013-12-25): - -* Fix a critical bug in `npm adduser` that would manifest in the error message - "Error: default value must be string or number." - ([`fba4bd2`](https://github.com/npm/npm/commit/fba4bd24bc2ab00ccfeda2043aa53af7d75ef7ce), - [@isaacs](https://github.com/isaacs)) -* Allow `npm bugs` in the current directory to open the current package's bugs - URL. - ([`d04cf64`](https://github.com/npm/npm/commit/d04cf6483932c693452f3f778c2fa90f6153a4af), - [@evanlucas](https://github.com/evanlucas)) -* Several fixes to various error messages to include more useful or updated - information. - ([`1e6f2a7`](https://github.com/npm/npm/commit/1e6f2a72ca058335f9f5e7ca22d01e1a8bb0f9f7), - [`ff46366`](https://github.com/npm/npm/commit/ff46366bd40ff0ef33c7bac8400bc912c56201d1), - [`8b4bb48`](https://github.com/npm/npm/commit/8b4bb4815d80a3612186dc5549d698e7b988eb03); - [@rlidwka](https://github.com/rlidwka), - [@evanlucas](https://github.com/evanlucas)) - -### v1.3.21 (2013-12-17): - -* Fix a critical bug that prevented publishing due to incorrect hash - calculation. - ([`4ca4a2c`](https://github.com/npm/npm-registry-client/commit/4ca4a2c6333144299428be6b572e2691aa59852e), - [@dominictarr](https://github.com/dominictarr)) - -### v1.3.20 (2013-12-17): - -* Fixes a critical bug in v1.3.19. Thankfully, due to that bug, no one could - install npm v1.3.19 :) - -### v1.3.19 (2013-12-16): - -* Adds atomic PUTs for publishing packages, which should result in far fewer - requests and less room for replication errors on the server-side. - -### v1.3.18 (2013-12-16): - -* Added an `--ignore-scripts` option, which will prevent `package.json` scripts - from being run. Most notably, this will work on `npm install`, so e.g. `npm - install --ignore-scripts` will not run preinstall and prepublish scripts. - ([`d7e67bf`](https://github.com/npm/npm/commit/d7e67bf0d94b085652ec1c87d595afa6f650a8f6), - [@sqs](https://github.com/sqs)) -* Fixed a bug introduced in 1.3.16 that would manifest with certain cache - configurations, by causing spurious errors saying "Adding a cache directory - to the cache will make the world implode." - ([`966373f`](https://github.com/npm/npm/commit/966373fad8d741637f9744882bde9f6e94000865), - [@domenic](https://github.com/domenic)) -* Re-fixed the multiple download of URL dependencies, whose fix was reverted in - 1.3.17. - ([`a362c3f`](https://github.com/npm/npm/commit/a362c3f1919987419ed8a37c8defa19d2e6697b0), - [@spmason](https://github.com/spmason)) - -### v1.3.17 (2013-12-11): - -* This release reverts - [`644c2ff`](https://github.com/npm/npm/commit/644c2ff3e3d9c93764f7045762477f48864d64a7), - which avoided re-downloading URL and shinkwrap dependencies when doing `npm - install`. You can see the in-depth reasoning in - [`d8c907e`](https://github.com/npm/npm/commit/d8c907edc2019b75cff0f53467e34e0ffd7e5fba); - the problem was, that the patch changed the behavior of `npm install -f` to - reinstall all dependencies. -* A new version of the no-re-downloading fix has been submitted as - [#4303](https://github.com/npm/npm/issues/4303) and will hopefully be - included in the next release. - -### v1.3.16 (2013-12-11): - -* Git URL dependencies are now updated on `npm install`, fixing a two-year old - bug - ([`5829ecf`](https://github.com/npm/npm/commit/5829ecf032b392d2133bd351f53d3c644961396b), - [@robertkowalski](https://github.com/robertkowalski)). Additional progress on - reducing the resulting Git-related I/O is tracked as - [#4191](https://github.com/npm/npm/issues/4191), but for now, this will be a - big improvement. -* Added a `--json` mode to `npm outdated` to give a parseable output. - ([`0b6c9b7`](https://github.com/npm/npm/commit/0b6c9b7c8c5579f4d7d37a0c24d9b7a12ccbe5fe), - [@yyx990803](https://github.com/yyx990803)) -* Made `npm outdated` much prettier and more useful. It now outputs a - color-coded and easy-to-read table. - ([`fd3017f`](https://github.com/npm/npm/commit/fd3017fc3e9d42acf6394a5285122edb4dc16106), - [@quimcalpe](https://github.com/quimcalpe)) -* Added the `--depth` option to `npm outdated`, so that e.g. you can do `npm - outdated --depth=0` to show only top-level outdated dependencies. - ([`1d184ef`](https://github.com/npm/npm/commit/1d184ef3f4b4bc309d38e9128732e3e6fb46d49c), - [@yyx990803](https://github.com/yyx990803)) -* Added a `--no-git-tag-version` option to `npm version`, for doing the usual - job of `npm version` minus the Git tagging. This could be useful if you need - to increase the version in other related files before actually adding the - tag. - ([`59ca984`](https://github.com/npm/npm/commit/59ca9841ba4f4b2f11b8e72533f385c77ae9f8bd), - [@evanlucas](https://github.com/evanlucas)) -* Made `npm repo` and `npm docs` work without any arguments, adding them to the - list of npm commands that work on the package in the current directory when - invoked without arguments. - ([`bf9048e`](https://github.com/npm/npm/commit/bf9048e2fa16d43fbc4b328d162b0a194ca484e8), - [@robertkowalski](https://github.com/robertkowalski); - [`07600d0`](https://github.com/npm/npm/commit/07600d006c652507cb04ac0dae9780e35073dd67), - [@wilmoore](https://github.com/wilmoore)). There are a few other commands we - still want to implement this for; see - [#4204](https://github.com/npm/npm/issues/4204). -* Pass through the `GIT_SSL_NO_VERIFY` environment variable to Git, if it is - set; we currently do this with a few other environment variables, but we - missed that one. - ([`c625de9`](https://github.com/npm/npm/commit/c625de91770df24c189c77d2e4bc821f2265efa8), - [@arikon](https://github.com/arikon)) -* Fixed `npm dedupe` on Windows due to incorrect path separators being used - ([`7677de4`](https://github.com/npm/npm/commit/7677de4583100bc39407093ecc6bc13715bf8161), - [@mcolyer](https://github.com/mcolyer)). -* Fixed the `npm help` command when multiple words were searched for; it - previously gave a `ReferenceError`. - ([`6a28dd1`](https://github.com/npm/npm/commit/6a28dd147c6957a93db12b1081c6e0da44fe5e3c), - [@dereckson](https://github.com/dereckson)) -* Stopped re-downloading URL and shrinkwrap dependencies, as demonstrated in - [#3463](https://github.com/npm/npm/issues/3463) - ([`644c2ff`](https://github.com/isaacs/npm/commit/644c2ff3e3d9c93764f7045762477f48864d64a7), - [@spmason](https://github.com/spmason)). You can use the `--force` option to - force re-download and installation of all dependencies. diff --git a/changelogs/CHANGELOG-2.md b/changelogs/CHANGELOG-2.md deleted file mode 100644 index c4d2b77..0000000 --- a/changelogs/CHANGELOG-2.md +++ /dev/null @@ -1,5344 +0,0 @@ -### v2.15.12 (2017-03-24): - -This version brings the latest `node-gyp` to a soon to be released Node.js -4.x. The `node-gyp` update is particularly important to Windows folks due to -its addition of Visual Studio 2017 support. - -* [`cdd60e733`](https://github.com/npm/npm/commit/cdd60e733905a9994e1d6d832996bfdd12abeaee) - `node-gyp@3.6.0`: - Improvements to how Python is located. New `--devdir` flag. - Support for VS2017. - Chakracore support on ARM. - Remove path-array dependency, reducing size significantly. - ([@bnoordhuis](https://github.com/bnoordhuis)) - ([@mhart](https://github.com/mhart)) - ([@refack](https://github.com/refack)) - ([@kunalspathak](https://github.com/kunalspathak)) - -### v2.15.11 (2016-09-08): - -On we go with our monthly release cadence! This week is pretty much all -dependency updates and some documentation changes, as can be expected by now. - -Note that `npm@4` will almost certainly be released next month! It's not final -what we'll end up doing as far as LTS support goes, but the current thinking is -that, considering how small and resource-constrained our team is, support for -`npm@2` will be reduced to essentially maintenance, so we can better focus on -`npm@3` as the new LTS version (which will go into `node@6`), and `npm@4` as our -next main development version. - -#### DOCUMENTATION UPDATES - -* [`8f71038`](https://github.com/npm/npm/commit/8f71038310501ad5bc7445b2fa2ff0eaa377919a) - [#13892](https://github.com/npm/npm/pull/13892) - Update `LICENSE` file to match license on `master`. - ([@rvagg](https://github.com/rvagg)) -* [`e81b4f1`](https://github.com/npm/npm/commit/e81b4f1d18a4d79b7af8342747f2ed7dc3e84f0a) - [#12438](https://github.com/npm/npm/issues/12438) - Remind folks to use `#!/usr/bin/env node` in their `bin` scripts to make files - executable directly. - ([@mxstbr](https://github.com/mxstbr)) -* [`f89789f`](https://github.com/npm/npm/commit/f89789f43d65bfc74f64f15a99356841377e1af3) - [#13655](https://github.com/npm/npm/pull/13655) - Document line comment syntax for `.npmrc`. - ([@mdjasper](https://github.com/mdjasper)) -* [`5cd3abc`](https://github.com/npm/npm/commit/5cd3abc3511515e09b4a1b781c0520e84c267c5b) - [#13493](https://github.com/npm/npm/pull/13493) - Document that the user config file can itself be configured either through the - `$NPM_CONFIG_USERCONFIG` environment variable, or `--userconfig` command line - flag. - ([@jasonkarns](https://github.com/jasonkarns)) -* [`dd71ca0`](https://github.com/npm/npm/commit/dd71ca0efc2094b824ccc9e23af0fc915499f2e6) - [#13911](https://github.com/npm/npm/pull/13911) - Minor documentation reword and cleanup. - ([@othiym23](https://github.com/othiym23)) -* [`f7a320c`](https://github.com/npm/npm/commit/f7a320c816947d578a050c97e0fb9878954be0e8) - [#13682](https://github.com/npm/npm/pull/13682) - Minor grammar fix in documentation for `npm scripts`. - ([@Ajedi32](https://github.com/Ajedi32)) -* [`e5cb5e8`](https://github.com/npm/npm/commit/e5cb5e8fcf4642836fedf3f3421c994a8e27e19b) - [#13717](https://github.com/npm/npm/pull/13717) - Document that `npm link` will link the files specified in the `bin` field of - `package.json` to `{prefix}/bin/{name}`. - ([@legodude17](https://github.com/legodude17)) - -#### DEPENDENCY UPDATES -* [`8bef026`](https://github.com/npm/npm/commit/8bef026603b6da888edf0d41308d9e532abfcd54) - `graceful-fs@4.1.6` - ([@francescoinfante](https://github.com/francescoinfante)) -* [`9f73f4a`](https://github.com/npm/npm/commit/9f73f4aab5f56b256c5cf9e461e81abfa2844945) - `glob@7.0.6` - ([@isaacs](https://github.com/isaacs)) -* [`5391b7e`](https://github.com/npm/npm/commit/5391b7e8cd4401fbadbf54e810fdc965a3662a21) - `which@1.2.1` - ([@isaacs](https://github.com/isaacs)) -* [`43bfec8`](https://github.com/npm/npm/commit/43bfec8376dd8ded7d56a8dabd6139919544760e) - `retry@0.10.0` - ([@tim-kos](https://github.com/tim-kos)) -* [`39305f1`](https://github.com/npm/npm/commit/39305f1c76f74bf9789c769ef72a94ea9a81d119) - `readable-stream@2.1.5` - ([@calvinmetcalf](https://github.com/calvinmetcalf)) -* [`a5512fa`](https://github.com/npm/npm/commit/a5512fafd72e23755e77e28f1122b008bc12a733) - `once@1.4.0` - ([@zkochan](https://github.com/zkochan)) -* [`06a208b`](https://github.com/npm/npm/commit/06a208b178c1de3d0da58bc35a854d200fea8ef0) - `npm-registry-client@7.2.1`: - * [npm/npm-registry-client#142](https://github.com/npm/npm-registry-client/pull/142) Fix `EventEmitter` warning spam from error handlers on socket. ([@addaleax](https://github.com/addaleax)) - * [npm/npm-registry-client#131](https://github.com/npm/npm-registry-client/pull/131) Adds support for streaming request bodies. ([@aredridel](https://github.com/aredridel)) - * Fixes [#13656](https://github.com/npm/npm/issues/13656). - * Dependency updates. - * Documentation improvements. - ([@othiym23](https://github.com/othiym23)) -* [`4f759be`](https://github.com/npm/npm/commit/4f759be1fb5e23180b970350e58f40a513daa680) - `inherits@2.0.3` - ([@isaacs](https://github.com/isaacs)) -* [`4258b76`](https://github.com/npm/npm/commit/4258b764e2565f6294ae1e34a5653895290b62e3) - `tap@7.1.1` - ([@isaacs](https://github.com/isaacs)) - -### v2.15.10 (2016-08-11): - -Hi all, today's our first release coming out of the new monthly release -cadence. See below for details. We're all recovered from conferences now and -raring to go! For LTS we see some bug fixes, documentation improvements and -a host of dependency updates. - -The most dramatic bug fix is probably the inclusion of scoped modules in -bundled dependencies. Prior to this release and -[v3.10.7](https://github.com/npm/npm/releases/v3.10.7), npm had ignored -scoped modules found in `bundleDependencies` entirely. - -#### NEW RELEASE CADENCE - -Releasing npm has been, for the most part, a very prominent part of our -weekly process process. As part of our efforts to find the most effective -ways to allocate our team's resources, we decided last month that we would -try and slow our releases down to a monthly cadence, and see if we found -ourselves with as much extra time and attention as we expected to have. -Process experiments are useful for finding more effective ways to do our -work, and we're at least going to keep doing this for a whole quarter, and -then measure how well it worked out. It's entirely likely that we'll switch -back to a more frequent cadence, specially if we find that the value that -weekly cadence was providing the community is not worth sacrificing for a -bit of extra time. Does this affect you significantly? Let us know! - -#### WINDOWS CORNER CASES - -* [`405c404`](https://github.com/npm/npm/commit/405c4048c69c14d66e6179aba0c8a35e504e8041) - [#13023](https://github.com/npm/npm/pull/13023) - Fixed a Windows issue with the cache where callbacks could be called more than once. - ([@zkat](https://github.com/zkat)) - -* [`bf348dc`](https://github.com/npm/npm/commit/bf348dcfb944dc4b9f71b779bf172f86a2e1f474) - [#13023](https://github.com/npm/npm/pull/13023) - Fixed a Windows corner case with correct-mkdir where if SUDO_UID or - SUDO_GID were set then we would try to chown things even though that can't - work on Windows. - ([@zkat](https://github.com/zkat)) - -#### RACES IN THE CACHE - -* [`68f29f1`](https://github.com/npm/npm/commit/68f29f18f65c7a7e1c58eb6933af41d786971379) - [#12669](https://github.com/npm/npm/issues/12669) - Ignore ENOENT errors on chownr while adding packages to cache. This change - works around problems with race conditions and local packages. - ([@julianduque](https://github.com/julianduque)) - -#### BETTER GIT ENVIRONMENT WHITELISTING - -* [`5e96566`](https://github.com/npm/npm/commit/5e96566088f0d88c1ed10c5a9cbb7c0cd4aa2aee) - [#13358](https://github.com/npm/npm/pull/13358) - Add GIT_EXEC_PATH to Git environment whitelist. - ([@mhart](https://github.com/mhart)) - -#### DOCUMENTATION - -* [`363e381`](https://github.com/npm/npm/commit/363e381a4076ead89707a00cc4a447b1d59df3bc) - [#13319](https://github.com/npm/npm/pull/13319) - As Node.js 0.8 is no longer supported, remove mention of it from the README. - ([@watilde](https://github.com/watilde)) -* [`e8fafa8`](https://github.com/npm/npm/commit/e8fafa887c60eb8842c76c4b3dffe85eb49fa434) - [#10167](https://github.com/npm/npm/pull/10167) - Clarify in scope documentation that npm@2 is required for scoped packages. - ([@danpaz](https://github.com/danpaz)) - -#### DEPENDENCIES - -* [`66ef279`](https://github.com/npm/npm/commit/66ef279b7c3b3e4f9454474dddd057cc1f21873b) - [npm/fstream-npm#22](https://github.com/npm/fstream-npm/pull/22) - `fstream@1.1.1`: - Always include NOTICE files now. Fix inclusion of scoped modules as bundled dependencies. - ([@kemitchell](https://github.com/kemitchell)) - ([@forivall](https://github.com/forivall)) -* [`fe8385b`](https://github.com/npm/npm/commit/fe8385bd655502feb175eed175a6a06cafb2247a) - `glob@7.0.5`: - Update minimatch dep for security fix. See the minimatch update below for details. - ([@isaacs](https://github.com/isaacs)) -* [`51d49d2`](https://github.com/npm/npm/commit/51d49d2f79b4c69264de73a492ed54f87188d554) - [isaacs/node-graceful-fs#71](https://github.com/isaacs/node-graceful-fs/pull/71) - `graceful-fs@4.1.5`: - `graceful-fs` had a [bug fix](https://github.com/isaacs/node-graceful-fs/pull/71) which - fixes a problem ([nodejs/node#7846](https://github.com/nodejs/node/pull/7846)) exposed - by recent changes to Node.js. - ([@thefourtheye](https://github.com/thefourtheye)) -* [`5c8f39d`](https://github.com/npm/npm/commit/5c8f39d152c43e96b9006ffe865646a36a433a8a) - `minimatch@3.0.3`: - Handle extremely long and terrible patterns more gracefully. - There were some magic numbers that assumed that every extglob pattern starts - and ends with a specific number of characters in the regular expression. - Since !(||) patterns are a little bit more complicated, this led to creating - an invalid regular expression and throwing. - ([@isaacs](https://github.com/isaacs)) -* [`d681e16`](https://github.com/npm/npm/commit/d681e16a475a49d6196af9a5cedaaf88712f3a9f) - [npm/npm-user-validate#9](https://github.com/npm/npm-user-validate/pull/9) - `npm-user-validate@0.1.5`: - Use correct, lower username length limit. - ([@aredridel](https://github.com/aredridel)) -* [`f918994`](https://github.com/npm/npm/commit/f918994bd05ca965766cd573606ac35fb3032d6e) - `request@2.74.0`: - Update `request` dependency `tough-cookie` to `2.3.0` to - to address [https://nodesecurity.io/advisories/130](https://nodesecurity.io/advisories/130). - Versions 0.9.7 through 2.2.2 contain a vulnerable regular expression that, - under certain conditions involving long strings of semicolons in the - "Set-Cookie" header, causes the event loop to block for excessive amounts of - time. - ([@stash-sfdc](https://github.com/stash-sfdc)) -* [`5540cc4`](https://github.com/npm/npm/commit/5540cc4d6bde65071fb6fc2cb074e8598bd1276f) - [isaacs/rimraf#111](https://github.com/isaacs/rimraf/issues/111) - `rimraf@2.5.4`: Clarify assertions: cb is required, options are not. - ([@isaacs](https://github.com/isaacs)) -* [`6357928`](https://github.com/npm/npm/commit/6357928673be85f520dae2104fea58c35742bd65) - `spdx-license-ids@1.2.2`: - New licenses synced from spdx.org. - ([@shinnn](https://github.com/shinnn)) - -### v2.15.9 (2016-06-30): - -What's this? An LTS release? Yes, that is indeed so. Small, as usual, and as -LTSs should be, really, but a release nonetheless! - -The star of the show is an updated `node-gyp` with some goodies. The rest is -just docs and some CI stuff. - -Happy hacking! - -#### DEPENDENCY UPDATE! - -* [`f9a07cc`](https://github.com/npm/npm/commit/f9a07cc873f1915827d8df97d0c43204d1eb128c) - [#13200](https://github.com/npm/npm/pull/13200) - [`node-gyp@3.4.0`](https://github.com/nodejs/node-gyp/blob/master/CHANGELOG.md): - AIX, Visual Studio 2015, and logging improvements. Oh my~! - ([@rvagg](https://github.com/rvagg)) - -#### CI TWEAKS - -* [`bee83b8`](https://github.com/npm/npm/commit/bee83b8500c31aba65451dfcb082f9b5d1d5ce34) - Globally install `rimraf` on CI to make the LTS self-install work better. - ([@othiym23](https://github.com/othiym23)) -* [`6b8c0ab`](https://github.com/npm/npm/commit/6b8c0ab6fcbf8a37e8693acb8bbac22293b10893) - This new Travis configuration only runs coverage checks against Node.js LTS, - which speeds up all the other test runs. By, like, a lot. Also, the entire - file has been extensively commented, so the next time we need to mess with it, - we'll be able to better remember why all the weird bits are there. - ([@othiym23](https://github.com/othiym23)) - -#### DOCUMENTATION FIXES - -* [`2c7a5be`](https://github.com/npm/npm/commit/2c7a5be080276e3fdca3375ab0f8f5edffff753e) - [#13156](https://github.com/npm/npm/pull/13156) - Fix old reference to `doc/install` in a source comment. - ([@sheerun](https://github.com/sheerun)) -* [`e1cf78c`](https://github.com/npm/npm/commit/e1cf78c5b77f95383bd4a7fc6eeb8adbbe68e12e) - [#13189](https://github.com/npm/npm/pull/13189) - [#13113](https://github.com/npm/npm/issues/13113) - [#13189](https://github.com/npm/npm/pull/13189) - Fixes a link to `npm-tag(3)` that was breaking to instead point to - `npm-dist-tag(1)`, as reported by [@SimenB](https://github.com/SimenB) - ([@macdonst](https://github.com/macdonst)) - -### v2.15.8 (2016-06-17): - -There's a very important bug fix and a long-awaited (and significant!) -deprecation in this hotfix release. [Hold on.](http://butt.holdings/) - -#### *WHOA* - -When Node.js 6.0.0 was released, the CLI team noticed an alarming upsurge in -bugs related to important files (like `README.md`) not being included in -published packages. The new bugs looked much like -[#5082](https://github.com/npm/npm/issues/5082), which had been around in one -form or another since April, 2014. #5082 used to be a very rare (and obnoxious) -bug that the CLI team hadn't had much luck reproducing, and we'd basically -marked it down as a race condition that arose on machines using slow and / or -rotating-media-based hard drives. - -Under 6.0.0, the behavior was reliable enough to be nearly deterministic, and -made it very difficult for publishers using `.npmignore` files in combination -with `"files"` stanzas in `package.json` to get their packages onto the -registry without one or more files missing from the packed tarball. The entire -saga is contained within [the issue](https://github.com/npm/npm/issues/5082), -but the summary is that an improvement to the performance of -[`fs.realpath()`](https://nodejs.org/api/fs.html#fs_fs_realpath_path_options_callback) -made it much more likely that the packing code would lose the race. - -Fixing this has proven to be very difficult, in part because the code used by -npm to produce package tarballs is more complicated than, strictly speaking, it -needs to be. [**@evanlucas**](https://github.com/evanlucas) contributed [a -patch](https://github.com/npm/fstream/pull/50) that passed the tests in a -[special test suite](https://github.com/othiym23/eliminate-5082) that I -([**@othiym23**](https://github.com/othiym23)) created (with help from -[**@addaleax**](https://github.com/addaleax)), but only _after_ we'd released -the fixed version of that package did we learn that it actually made the -problem _worse_ in other situations in npm proper. Eventually, -[**@rvagg**](https://github.com/rvagg) put together a more durable fix that -appears to completely address the errant behavior under Node.js 6.0.0. That's -the patch included in this release. Everybody should chip in for redback -insurance for Rod and his family; he's done the community a huge favor. - -Does this mean the long (2+ year) saga of #5082 is now over? At this point, I'm -going to quote from my latest summary on the issue: - -> The CLI team (mostly me, with input from the rest of the team) has decided that -> the overall complexity of the interaction between `fstream`, `fstream-ignore`, -> `fstream-npm`, and `node-tar` has grown more convoluted than the team is -> comfortable (maybe even capable of) supporting. -> -> - While I believe that @rvagg's (very targeted) fix addresses _this_ issue, I -> would be shocked if there aren't other race conditions in npm's packing -> logic. I've already identified a couple other places in the code that are -> most likely race conditions, even if they're harder to trigger than the -> current one. -> - The way that dependency bundling is integrated leads to a situation in -> which a bunch of logic is duplicated between `fstream-npm` and -> `lib/utils/tar.js` in npm itself, and the way `fstream`'s extension -> mechanism works makes this difficult to clean up. This caused a nasty -> regression ([#13088](https://github.com/npm/fstream/pull/50), see below) as -> of ~`npm@3.8.7` where the dependencies of `bundledDependencies` were no -> longer being included in the built package tarballs. -> - The interaction between `.npmignore`, `.gitignore`, and `files` is hopelessly -> complicated, scattered in many places throughout the code. We've been -> discussing [making the ignores and includes logic clearer and more -> predictable](https://github.com/npm/npm/wiki/Files-and-Ignores), and the -> current code fights our efforts to clean that up. -> -> So, our intention is still to replace `fstream`, `fstream-ignore`, and -> `fstream-npm` with something much simpler and purpose-built. There's no real -> reason to have a stream abstraction here when a simple recursive-descent -> filesystem visitor and a synchronous function that can answer whether a given -> path should be included in the packed tarball would do the job adequately. -> -> What's not yet clear is whether we'll need to replace `node-tar` in the -> process. `node-tar` is a very robust implementation of tar (it handles, like, -> everything), and it also includes some very important tweaks to prevent several -> classes of security exploits involving maliciously crafted packages. However, -> its packing API involves passing in an `fstream` instance, so we'd either need -> to produce something that follows enough of `fstream`'s contract for `node-tar` -> to keep working, or swap `node-tar` out for something like `tar-stream` (and -> then ensuring that our use of `tar-stream` is secure, which could involve -> security patches for either npm or `tar-stream`). - -The testing and review of `fstream@1.0.10` that the team has done leads us to -believe that this bug is fixed, but I'm feeling more than a little paranoid -about fstream now, so it's important that people keep a close eye on their -publishes for a while and let us know immediately if they notice any -irregularities. - -* [`2c49265`](https://github.com/npm/npm/commit/2c49265c6746d29ae0cd5f3532d28c5950f9847e) - [#5082](https://github.com/npm/npm/issues/5082) `fstream@1.0.10`: Ensure that - entries are collected after a paused stream resumes. - ([@rvagg](https://github.com/rvagg)) -* [`92e4344`](https://github.com/npm/npm/commit/92e43444d9204f749f83512aeab5d5e0a2d085a7) - [#5082](https://github.com/npm/npm/issues/5082) Remove the warning introduced - in `npm@3.10.0`, because it should no longer be necessary. - ([@othiym23](https://github.com/othiym23)) - -#### GOODBYE, FAITHFUL FRIEND - -At NodeConf Adventure 2016 (RIP in peace, Mikeal Rogers's NodeConf!), the CLI -team had an opportunity to talk to representatives from some of the larger -companies that we knew were still using Node.js 0.8 in production. After asking -them whether they were still using 0.8, we got back blank stares and questions -like, "0.8? You mean, from four years ago?" After establishing that being able -to run npm in their legacy environments was no longer necessary, the CLI team -made the decision to drop support for 0.8. (Faithful observers of our [team -meetings](https://github.com/npm/npm/issues?utf8=%E2%9C%93&q=is%3Aissue+npm+cli+team+meeting+) -will have known this was the plan for NodeConf since the beginning of 2016.) - -In practice, this means only what's in the commit below: we've removed 0.8 from -our continuous integration test matrix below, and will no longer be habitually -testing changes under Node 0.8. We may also give ourselves permission to use -`setImmediate()` in test code. However, since the project still supports -Node.js 0.10 and 0.12, it's unlikely that patches that rely on ES 2015 -functionality will land anytime soon. - -Looking forward, the team's current plan is to drop support for Node.js 0.10 -when its LTS maintenance window expires in October, 2016, and 0.12 when its -maintenance / LTS window ends at the end of 2016. We will also drop support for -Node.js 5.x when Node.js 6 becomes LTS and Node.js 7 is released, also in the -October-December 2016 timeframe. - -(Confused about Node.js's LTS policy? [Don't -be!](https://github.com/nodejs/LTS) If you look at [this -diagram](https://github.com/nodejs/LTS/blob/ce364a94b0e0619eba570cd57be396573e1ef889/schedule.png), -it should make all of the preceding clear.) - -If, in practice, this doesn't work with distribution packagers or other -community stakeholders responsible for packaging and distributing Node.js and -npm, please reach out to us. Aligning the npm CLI's LTS policy with Node's -helps everybody minimize the amount of work they need to do, and since all of -our teams are small and very busy, this is somewhere between a necessity and -non-negotiable. - -* [`4a1ecc0`](https://github.com/npm/npm/commit/4a1ecc068fb2660bd9bc3e2e2372aa0176d2193b) - Remove 0.8 from the Node.js testing matrix, and reorder to match real-world - priority, with comments. ([@othiym23](https://github.com/othiym23)) - -### v2.15.7 (2016-06-16): - -It pains me greatly that we haven't been able to fix -[#5082](https://github.com/npm/npm/issues/5082) yet, but warning you away from -potentially publishing incomplete packages takes priority over feeling cheesy -about landing a warning to help keep y'all out of trouble, so here you go -(_please read this next bit_ (_please clap_)): - -#### DANGER: PUBLISHING ON NODE 6.0.0 - -Publishing and packing are buggy under Node versions greater than 6.0.0. -Please use Node.js LTS (4.4.x) to publish packages. See -[#5082](https://github.com/npm/npm/issues/5082) for details and current -status. - -* [`dff00ce`](https://github.com/npm/npm/commit/dff00cedd56b9c04370f840299a7e657a7a835c6) - [#13077](https://github.com/npm/npm/pull/13077) - Warn when using Node 6+. - ([@othiym23](https://github.com/othiym23)) - -#### PACKAGING CHANGES - -* [`1877171`](https://github.com/npm/npm/commit/1877171648e20595a82de34073b643f7e01a339f) - [#12873](https://github.com/npm/npm/issues/12873) - Ignore `.nyc_output`. This will help avoid an accidental publish or commit filled with - code coverage data. - ([@TheAlphaNerd](https://github.com/TheAlphaNerd)) - -#### DOCUMENTATION CHANGES - -* [`470ae86`](https://github.com/npm/npm/commit/470ae86e052ae2f29ebec15b7547230b6240042e) - [#12983](https://github.com/npm/npm/pull/12983) - Describe how to run the lifecycle scripts of dependencies. How you do - this changed with `npm` v2. - ([@Tapppi](https://github.com/Tapppi)) -* [`9cedf37`](https://github.com/npm/npm/commit/9cedf37e5a3e26d0ffd6351af8cac974e3e011c2) - [#12776](https://github.com/npm/npm/pull/12776) - Remove mention of `<pkg>` arg for `run-script`. - ([@fibo](https://github.com/fibo)) -* [`55b8424`](https://github.com/npm/npm/commit/55b8424d7229f2021cac55f0b03de72403e7c0ff) - [#12840](https://github.com/npm/npm/pull/12840) - Remove sexualized language from comment. - ([@geek](https://github.com/geek)) -* [`d6bf0c3`](https://github.com/npm/npm/commit/d6bf0c393788a6398bf80b41c57956f2dbcf3b39) - [#12802](https://github.com/npm/npm/pull/12802) - Small grammar fix in `doc/cli/npm.md`. - ([@andresilveira](https://github.com/andresilveira)) - -#### DEPENDENCY UPDATES - -* [`2c2c568`](https://github.com/npm/npm/commit/2c2c56857ff801d5fe1b6d3157870cd16e65891b) - `readable-stream@2.1.4`: Brought up to date with Node 6.1.0's streams implementation. - ([@calvinmetcalf](https://github.com/calvinmetcalf)) -* [`d682e64`](https://github.com/npm/npm/commit/d682e6445845b0a2584935d5e2942409c43f6916) - [npm/npm-user-validate#8](https://github.com/npm/npm-user-validate/pull/8) - `npm-user-validate@0.1.4`: Add a maximum length limit for usernames based on - the (arbitrary) limit imposed by the primary npm registry. - ([@aredridel](https://github.com/aredridel)) -* [`448b65b`](https://github.com/npm/npm/commit/448b65b48cda3b782b714057fb4b8311cc1fa36a) - `which@1.2.10`: Remove unused dependency `is-absolute`, bug fixes. - ([@isaacs](https://github.com/isaacs)) -* [`7d15434`](https://github.com/npm/npm/commit/7d15434f0b0af8e70b119835b21968217224664f) - `require-inject@1.4.0`: Add `requireInject.withEmptyCache` and - `requireInject.installGlobally.andClearCache` to support loading modules to be - injected with an empty cache. - ([@iarna](https://github.com/iarna)) -* [`31845c0`](https://github.com/npm/npm/commit/31845c081bc6f3f8a2f3d83a3c792dccffbaa2a8) - `init-package-json@1.9.4`: - Replace use of reserved identifier `package` in, uh, the package. - ([@adius](https://github.com/adius)) -* [`d73ef3e`](https://github.com/npm/npm/commit/d73ef3e6b18d4905de668c5115bc6042905a02d9) - `glob@7.0.4`: Use userland `fs.realpath` implementation to get glob working under Node 6. - ([@isaacs](https://github.com/isaacs)) -* [`b47da85`](https://github.com/npm/npm/commit/b47da85cf83b946f2c8d29ab612c92028f31f6b0) - `inflight@1.0.5`: Correct link to package repository, add `"files"` stanza. - ([@iarna](https://github.com/iarna), [@jamestalmage](https://github.com/jamestalmage)) -* [`04815e4`](https://github.com/npm/npm/commit/04815e436035de785279fd000cdbc821cc1f3447) - [npm/npmlog#32](https://github.com/npm/npmlog/pull/32) - `npmlog@2.0.4`: Add `"files"` stanza to `package.json`. - ([@jamestalmage](https://github.com/jamestalmage)) -* [`9e29ad2`](https://github.com/npm/npm/commit/9e29ad227300bb970e7bcd21029944d4733e40db) - `wrappy@1.0.2`: Add `"files"` stanza to `package.json`. - ([@jamestalmage](https://github.com/jamestalmage)) -* [`44af4d4`](https://github.com/npm/npm/commit/44af4d475ac65bdce6d088173273ce4a4f74a49e) - `abbrev@1.0.9` ([@jorrit](https://github.com/jorrit)) -* [`6c977c0`](https://github.com/npm/npm/commit/6c977c0031d074479a26c7bec6ec83fd6c6526b2) - `npm-registry-client@7.1.2`: Add support for newer versions of `npmlog`. - ([@iarna](https://github.com/iarna)) - -### v2.15.6 (2016-05-12): - -I have a couple of doc fixes and a shrinkwrap fix for you all this week. - -#### PEER DEPENDENCIES AND SHRINKWRAPS - -* [`55c998a`](https://github.com/npm/npm/commit/55c998a098a306b90a84beef163a8890f9a616b1) - [#5135](https://github.com/npm/npm/issues/5135) - Fix a bug where peerDependencies & shrinkwraps didn't play nice together. (Where - the peerDependency resolver would end up installing its dep when it wasn't needed.) - ([@majgis](https://github.com/majgis)) - -#### NPM AND `node-gyp` DOCS IMPROVEMENTS - -* [`1826908`](https://github.com/npm/npm/commit/1826908b991510d8fbc71a0d0f2c01ff24fd83c2) - [#12636](https://github.com/npm/npm/pull/12636) - Improve `npm-scripts` documentation regarding when `node-gyp` is used. - ([@reconbot](https://github.com/reconbot)) -* [`f9ff7f3`](https://github.com/npm/npm/commit/f9ff7f36cc2c2c3fbb4f6eef91491b589d049d5f) - [#12586](https://github.com/npm/npm/pull/12586) - Correct `package.json` documentation as to when `node-gyp rebuild` called. - This now matches https://docs.npmjs.com/misc/scripts#default-values - ([@reconbot](https://github.com/reconbot)) - -### v2.15.5 (2016-05-05): - -This is a minor LTS release, bringing dependencies up to date and updating -our CI matrix to match what we support. - -Some of the dependency updates come out of our getting the development -branch's tests passing on Windows and so bring in fixes for a few Windows -related corner cases. - -#### CI UPDATES - -* [`bb6f0e5`](https://github.com/npm/npm/commit/bb6f0e5c95d4ad186768b1c962dd4c399f90ddb1) - [#12487](https://github.com/npm/npm/pull/12487) - Remove iojs from CI, add Node.js 6, prioritize 4 over 5. - ([@othiym23](https://github.com/othiym23)) - -#### DEPENDENCY UPDATES - -* [`f2f8753`](https://github.com/npm/npm/commit/f2f8753c4aef2a604a4bdca2677711c940234b8f) - `which@1.2.8`: - Properly handle relative path executables. - ([@isaacs](https://github.com/isaacs)) -* [`e287ca9`](https://github.com/npm/npm/commit/e287ca99c37680d8e4cfacf4cfebe2da98884865) - `read-package-json@2.0.4`: - Fix Windows issue with ENOTDIR detection. - ([@zkat](https://github.com/zkat)) -* [`1a0ce6c`](https://github.com/npm/npm/commit/1a0ce6cff4c347bad035dc89bba2ceed9dacbf73) - `realize-package-specifier@3.0.3`: - Use npa with windows fix. - Fix relative path resolution when the local file might also be a tag. - ([@zkat](https://github.com/zkat)) - ([@iarna](https://github.com/iarna)) -* [`a475c9a`](https://github.com/npm/npm/commit/a475c9a4e4b36d00080b11f379657ce68185adc6) - `lru-cache@4.0.1`: - Use Symbol if available. - ([@isaacs](https://github.com/isaacs)) -* [`7141e08`](https://github.com/npm/npm/commit/7141e08816c620b1889d7537c30dc5b254de4d1f) - `sorted-object@2.0.0` - ([@iamstarkov](https://github.com/iamstarkov)) -* [`27c6190`](https://github.com/npm/npm/commit/27c6190216cc8a5a280f0efbabb3444581968d40) - `request@2.72.0` - ([@simov](https://github.com/simov)) -* [`ab90daf`](https://github.com/npm/npm/commit/ab90daf70ba51b51f722fb4cd74ac5267621c4b4) - `readable-stream@2.1.2` - ([@calvinmetcalf](https://github.com/calvinmetcalf)) -* [`b1715f8`](https://github.com/npm/npm/commit/b1715f805426403273225bcfa91d1a52d7b56eb8) - `graceful-fs@4.1.4` - ([@isaacs](https://github.com/isaacs)) -* [`ca97de6`](https://github.com/npm/npm/commit/ca97de6c18059ef420235f4706898ad8758904e6) - `block-stream@0.0.9` - ([@isaacs](https://github.com/isaacs)) - -### v2.15.4 (2016-04-21): - -Gosh, it's been a peaceful couple of weeks! - -Overall, the CLI team has been focused on the project to [get the test suite -passing on Windows](https://github.com/npm/npm/pull/11444). Our efforts should -be paying off soon -- there's only a couple of tests left! - -It's very unlikely those particular changes will make their way into our current -`npm@2` LTS release, I think, but it will help `npm@3` a lot, as well as -whatever version makes it into [`node@6`, which will eventually be the next -Node.js LTS](https://github.com/nodejs/node/pull/6155). - -As far as this week goes, we've got a couple of dep updates and doc fixes. -Always happy to see community contributions flying in. 💚 - -#### DEP UPDATE MAGIC - -* [`b178c4a`](https://github.com/npm/npm/commit/b178c4ac9ce91c0a0794526a38b553c759132d18) - `spdx-license-ids@1.2.1`: - Minor project-related tweaks -- no license changes. - ([@shinnn](https://github.com/shinnn)) -* [`1adf179`](https://github.com/npm/npm/commit/1adf179948ab8cb97dfb2f46a61e9f37d944c42a) - `normalize-git-url@3.0.2`: - Fixes `file://` URLs on Windows. Turns out stuff like `file://C:\hello` is - actually fairly weird for a URL (it's not actually a valid URL, but we're just - gonna pretend.😉) - ([@zkat](https://github.com/zkat)) -* [`9cfd56c`](https://github.com/npm/npm/commit/9cfd56cdadc040c0b2fa7654cdb5e7d22dbef7cb) - `fs-vacuum@1.2.9`: - This one goes out to our fans at Big Blue: There was an AIX-specific issue - where `fs.rmDir` was failing with `EEXIST` instead of `ENOTEMPTY` with - non-empty directories. - ([@richardlau](https://github.com/richardlau)) - -#### HOORAY DOC CONTRIBUTIONS - -No seriously, we love these. Keep 'em comin'! - -* [`2afe8bf`](https://github.com/npm/npm/commit/2afe8bf415a159baa181a8102f72c96e1d189bc9) - [#12415](https://github.com/npm/npm/pull/12415) - Clarify that the `--cert` and `--key` options are actual certs and keys, not - paths to files containing them. - ([@rvedotrc](https://github.com/rvedotrc)) -* [`3522560`](https://github.com/npm/npm/commit/3522560b0a4bb6c9717a34f9728f156fd9760cad) - [#12107](https://github.com/npm/npm/pull/12107) - Document `npm login` as an alias to `npm adduser`. People are still surprised - by this so often. - ([@gnerkus](https://github.com/gnerkus)) - -### v2.15.3 (2016-03-31): - -Hiiiiiii!~👋 - -We're really happy to be getting more and more community contributions! Keep it -up! We really appreciate folks trying to help us, and we'll do our best to help -point you in the right direction. Even things like documentation are a huge -help. And remember -- you get socks for it, too!🎁 - -This week is as quiet as usual, aside from fixing a regression to `npm -deprecate` you might want to pay attention to! Other than that, just docs and -deps, as any good LTS release train should be. 🙆 - -#### FIXME - -* [`6e0b66e`](https://github.com/npm/npm/commit/6e0b66e282aa27d1b5371e2babaa859924121730) - [#11884](https://github.com/npm/npm/pull/11884) - Include `node_modules` in the list of files and directories that npm won't - include in packages ordinarily. (Modules listed in `bundledDependencies` and - things that those modules rely on, ARE included of course.) - ([@Jameskmonger](https://github.com/Jameskmonger)) -* [`9896290`](https://github.com/npm/npm/commit/98962909b160364030705575202ad133971033c1) - [#12079](https://github.com/npm/npm/pull/12079) - Back in `npm@2.13.1` we included [a patch that made it so `npm install pkg` - was basically `npm install pkg@latest` instead of - `pkg@*`](https://github.com/npm/npm/pull/9170) This is probably what most - users expected, but it also ended up [breaking `npm - deprecate`](https://github.com/npm/npm/pull/9170) when no version was provided - for a package. In that case, we were using `*` to mean "deprecate all - versions" and relying on the `pkg` -> `pkg@*` conversion. This patch fixes - `npm deprecate pkg` to work as it used to by special casing that particular - command's behavior. - ([@polm](https://github.com/polm)) -* [`6c1628f`](https://github.com/npm/npm/commit/6c1628f62b657db6c116be13849d00933a3388cd) - [#12146](https://github.com/npm/npm/pull/12146) - Adds `make doc-clean` to `prepublish` script, to clear out previously built - docs before publishing a new npm version. - ([@watilde](https://github.com/watilde)) -* [`6d3017e`](https://github.com/npm/npm/commit/6d3017e6eed8a771b395d10130ac1f498e2d3211) - [#12146](https://github.com/npm/npm/pull/12146) - Adds `doc-clean` phony target to `make publish`. - ([@watilde](https://github.com/watilde)) - -#### DOCS - -* [`d43921c`](https://github.com/npm/npm/commit/d43921c546617cdb94bbee444d7d67ef55f38dc5) - [#12147](https://github.com/npm/npm/pull/12147) - Document that the current behavior of `engines` is just to warn if the node - platform is incompatible. - ([@reconbot](https://github.com/reconbot)) -* [`3cfe99e`](https://github.com/npm/npm/commit/3cfe99e3a757c5d8cbb1c2789410e9802563abac) - [#12093](https://github.com/npm/npm/pull/12093) - Update `bugs` url in `package.json` to use the `https` URL for Github. - ([@watilde](https://github.com/watilde)) -* [`ecf865f`](https://github.com/npm/npm/commit/ecf865f4eed1419c75442e0d52bc34ba1647de15) - [#12075](https://github.com/npm/npm/pull/12075) - Add the `--ignore-scripts` flag to the `npm install` docs. - ([@paulirish](https://github.com/paulirish)) -* [`f0e6db3`](https://github.com/npm/npm/commit/f0e6db32827d88680ef2320e60c0863754a4fbc5) - [#12063](https://github.com/npm/npm/pull/12063) - Various minor fixes to the html docs homepage. - ([@watilde](https://github.com/watilde)) - -#### DEPS - -* [`e2660de`](https://github.com/npm/npm/commit/e2660de1c08ed68a1c6fc4ee75d10376595979be) - `npmlog@2.0.3` - ([@iarna](https://github.com/iarna)) - -### v2.15.2 (2016-03-24): - -It's always nice to see new contributors. 💚 - -This week sees another small release, but we're still chugging along on our -[Windows efforts](https://github.com/npm/npm/pull/11444). - -There's also some small process changes to our LTS process relatively recently -that you might wanna know about! 💁 - -For one, the `2.x` branch was removed in favor of just `lts`. If you're making -PRs exclusively against npm's LTS, please use that name from now on. `2.x` was -deleted. - -Also, [@othiym23](https://github.com/othiym23) put some time into [writing down -our LTS process and policy](https://github.com/npm/npm/wiki/LTS). Check it out -and ping us if you have questions or comments about it! - -In general, we're trying to make sure all our policy and such for our -contributors is written down, and we hope it makes it easier in general for -y'all. Forrest is also working on a shiny new Contributor's Guide right now, but -we'll link to that in the (near?) future, when it's ready to roll out. - -#### TESTS - -* [`1d0e468`](https://github.com/npm/npm/commit/1d0e468c06c7b8e2b95b7fe874a3399a16d9db74) - [#11931](https://github.com/npm/npm/pull/11931) - Removes a bunch of old, disabled tests that have just been sitting around, - doing nothing. - ([@othiym23](https://github.com/othiym23)) -* [`7ae8aa1`](https://github.com/npm/npm/commit/7ae8aa1d9dc47761024f6756114205db3fb2c80b) - [#11987](https://github.com/npm/npm/pull/11987) - There was a failure in the `outdated-symlink` test caused by using the default - registry instead of the mock registry tests. - ([@yodeyer](https://github.com/yodeyer)) - -#### DOCS - -* [`b2649fb`](https://github.com/npm/npm/commit/b2649fb360f239aadef1ab51a580cbf4fdf29722) - [#12006](https://github.com/npm/npm/pull/12006) - Access was Team and Team was Access, but someone from the community rolled - around and corrected it for us. Thanks a bunch! - ([@yaelz](https://github.com/yaelz)) - -### v2.15.1 (2016-03-17): - -#### SECURITY ADVISORY: BEARER TOKEN DISCLOSURE - -This release includes [the fix for a -vulnerability](https://github.com/npm/npm/commit/fea8cc92cee02c720b58f95f14d315507ccad401) -that could cause the unintentional leakage of bearer tokens. - -Here are details on this vulnerability and how it affects you. - -##### DETAILS - -Since 2014, npm’s registry has used HTTP bearer tokens to authenticate requests -from the npm’s command-line interface. A design flaw meant that the CLI was -sending these bearer tokens with _every_ request made by logged-in users, -regardless of the destination of their request. (The bearers only should have -been included for requests made against a registry or registries used for the -current install.) - -An attacker could exploit this flaw by setting up an HTTP server that could -collect authentication information, then use this authentication information to -impersonate the users whose tokens they collected. This impersonation would -allow them to do anything the compromised users could do, including publishing -new versions of packages. - -With the fixes we’ve released, the CLI will only send bearer tokens with -requests made against a registry. - -##### THINK YOU'RE AT RISK? REGENERATE YOUR TOKENS - -If you believe that your bearer token may have been leaked, [invalidate your -current npm bearer tokens](https://www.npmjs.com/settings/tokens) and rerun -`npm login` to generate new tokens. Keep in mind that this may cause continuous -integration builds in services like Travis to break, in which case you’ll need -to update the tokens in your CI server’s configuration. - -##### WILL THIS BREAK MY CURRENT SETUP? - -Maybe. - -npm’s CLI team believes that the fix won’t break any existing registry setups. -Due to the large number of registry software suites out in the wild, though, -it’s possible our change will be breaking in some cases. - -If so, please [file an issue](https://github.com/npm/npm/issues/new) describing -the software you’re using and how it broke. Our team will work with you to -mitigate the breakage. - -##### CREDIT & THANKS - -Thanks to Mitar, Will White & the team at Mapbox, Max Motovilov, and James -Taylor for reporting this vulnerability to npm. - -### BACK TO YOUR REGULARLY SCHEDULED PROGRAMMING - -Aside from that, it's another one of those releases again! Docs and tests, it -turns out, have a pretty easy time getting into LTS releases, and boring is -exactly how LTS should be. 💁 - -#### DOCS - -* [`981c89c`](https://github.com/npm/npm/commit/981c89c8e398ca22ab6bf466123b25728ef6f543) - [#11820](https://github.com/npm/npm/pull/11820) - The basic explanation for how `npm link` works was a bit confusing, and - somewhat incorrect. It should be clearer now. - ([@rhgb](https://github.com/rhgb)) -* [`35b2b45`](https://github.com/npm/npm/commit/35b2b45f181dcbfb297f53b577dc1f26efcf3aba) - [#11787](https://github.com/npm/npm/pull/11787) - The `verison` alias for `npm version` no longer shows up in the command list - when you do `npm -h`. - ([@doug-wade](https://github.com/doug-wade)) -* [`1c9d00f`](https://github.com/npm/npm/commit/1c9d00f788298a81a8a7293d7dcf430f01bdd7fd) - [#11786](https://github.com/npm/npm/pull/11786) - Add a comment to the `npm-scope.md` docs about `npm@>=2` being required in - order to use scoped packaged. - ([@doug-wade](https://github.com/doug-wade)) -* [`7d64fb1`](https://github.com/npm/npm/commit/7d64fb1452d360aa736f31c85d6776ce570b2365) - [#11762](https://github.com/npm/npm/pull/11762) - Roll back patch that previously advised people to use `--depth Infinity` - instead of `--depth 9999`. Just keep using `--depth 9999`. - ([@GriffinSchneider](https://github.com/GriffinSchneider)) - -#### TESTS - -* [`98a9ee4`](https://github.com/npm/npm/commit/98a9ee4773f83994b8eb63c0ff75a9283408ba1a) - [#11912](https://github.com/npm/npm/pull/11912) - Did you know npm can install itself? `npm install -g npm` is the way to - upgrade! Turns out that one of the tests that verified this functionality got - rewritten as part of our recent push for better tests, and in the process - omitted a detail about *how* the test ran. We're testing that corner case - again, now, by moving the install folder to `/tmp`, where the original legacy - test ran. - ([@iarna](https://github.com/iarna)) - -### v2.15.0 (2016-03-10): - -#### WHY IS THIS SEMVER-MINOR I THOUGHT THIS WAS LTS - -A brief note about LTS this week! - -npm, as you may know if you're using this `2.x` branch, has an LTS process for -releases. We also try and play nice with [Node.js' own LTS release -process](https://github.com/nodejs/LTS#lts-plan). That means we generally try to -avoid things like minor version bumps on our `2.x` branch (which is also tagged -`lts` in the `dist-tag`s). - -That said, we had a minor-bump update recently for `npm@3.8.0` which added a -`maxsockets` option to allow users to configure the number of concurrent sockets -that npm would keep open at a time -- a setting that has the potential to help a -bunch for people with fussy routers or internet connections that aren't very -happy with Node.js applications' usual concurrency storm. This change was done -to `npm-registry-client`, which we don't have a parallel LTS-tracking branch -for. - -After talking it over, we ended up deciding that this was a reasonable enough -addition to LTS, even though it's *technically* a `semver-minor` bump, taking -into account both its potential for bugfixing (specially on `2.x`!) and the -general hassle it would be to maintain another branch for `npm-registry-client`. - - -* [`6dd61e7`](https://github.com/npm/npm/commit/6dd61e781c145480dc255a3e6a748729868443fd) - Expose `maxsockets` config setting from new `npm-registry-client`. - ([@misterbyrne](https://github.com/misterbyrne)) -* [`8a021c3`](https://github.com/npm/npm/commit/8a021c35184e665bd1f3f70ae2f478af812ab614) - `npm-registry-client@7.1.0`: - Adds support for configuring the max number of concurrent sockets, defaulting - to `50`. - ([@iarna](https://github.com/iarna)) - -#### DOC PATCH IS HERE TOO - -* [`0ae9f74`](https://github.com/npm/npm/commit/0ae9f740001a1bdf5920bc464cf9e284d5d139f0) - [#11748](https://github.com/npm/npm/pull/11748) - Add command aliases as a separate section in documentation for npm - subcommands. - ([@watilde](https://github.com/watilde)) - -#### DEP UPDATES - -* [`bfc3888`](https://github.com/npm/npm/commit/bfc38887f832f701c16b7ee410c4e0220a90399f) - `strip-ansi@3.0.1` - ([@jbnicolai](https://github.com/jbnicolai)) -* [`d5f4d51`](https://github.com/npm/npm/commit/d5f4d51a1b7ea78d7431c7ed4fed30200b2622f8) - `node-gyp@3.3.1`: Fixes Android generator - ([@bnoordhuis](https://github.com/bnoordhuis)) -* [`4119df8`](https://github.com/npm/npm/commit/4119df8aecd2ae57b0492ad8c9a480d900833008) - `glob@7.0.3`: Some path-related fixes for Windows. - ([@isaacs](https://github.com/isaacs)) - -### v2.14.22 (2016-03-03): - -This week is all documentation improvements. In case you hadn't noticed, we -*love* doc patches. We love them so much, we give socks away if you submit -documentation PRs! - -These folks are all getting socks if they ask for them. The socks are -super-sweet. Do you have yours yet? 👣 - -* [`3f3c7d0`](https://github.com/npm/npm/commit/3f3c7d080f052a5db91ff6091f8b1b13f26b53d6) - [#11441](https://github.com/npm/npm/pull/11441) - Add a link to the [Contribution - Guidelines](https://github.com/npm/npm/wiki/Contributing-Guidelines) to the - main npm docs. - ([@watilde](https://github.com/watilde)) -* [`9f87bb1`](https://github.com/npm/npm/commit/9f87bb1934acb33b678c17b7827165b17c071a82) - [#11441](https://github.com/npm/npm/pull/11441) - Remove Google Group email from npm docs about contributing. - ([@watilde](https://github.com/watilde)) -* [`93eaab3`](https://github.com/npm/npm/commit/93eaab3ee5ad16c7d90d1a4b38a95403fcf3f0f6) - [#11474](https://github.com/npm/npm/pull/11474) - Fix an invalid JSON error overlooked in - [#11196](https://github.com/npm/npm/pull/11196). - ([@robludwig](https://github.com/robludwig)) -* [`a407ca2`](https://github.com/npm/npm/commit/a407ca2bcf6a05117e55cf2ab69376e09094995e) - [#11483](https://github.com/npm/npm/pull/11483) - Add more details and an example to the documentation for bundledDependencies. - ([@gnerkus](https://github.com/gnerkus)) -* [`2c851a2`](https://github.com/npm/npm/commit/2c851a231afd874baa77c42ea5ba539c454ac79c) - [#11490](https://github.com/npm/npm/pull/11490) - Document the `--registry` flag for `npm search`. - ([@plumlee](https://github.com/plumlee)) - -### v2.14.21 (2016-02-25): - -Good news, everyone! There's a new LTS release with a few shinies here and there! - -#### USE THIS ONE INSTEAD - -We had some cases where the versions of npm and node used in some scripting situations were different than the ideal, or what folks actually expected. These should be particularly helpful to our Windows friends! <3 - -* [`02813c5`](https://github.com/npm/npm/commit/02813c55782a9def23f7f1e614edc38c6c88aed3) [#9253](https://github.com/npm/npm/issues/9253) Fix a bug where, when running lifecycle scripts, if the Node.js binary you ran `npm` with wasn't in your `PATH`, `npm` wouldn't use it to run your scripts. ([@segrey](https://github.com/segrey) and [@narqo](https://github.com/narqo)) -* [`a985dd5`](https://github.com/npm/npm/commit/a985dd50e06ee51ba5544577f977c7440c227ba2) [#11526](https://github.com/npm/npm/pull/11526) Prefer locally installed npm in Git Bash -- previous behavior was to use the global one. This was done previously for other shells, but not for Git Bash. ([@destroyerofbuilds](https://github.com/destroyerofbuilds)) - -#### SOCKS FOR THE SOCK GOD - -* [`f961092`](https://github.com/npm/npm/commit/f9610920079d8b88ae464b30007a92c594bd85a8) - [#11636.](https://github.com/npm/npm/issues/11636.) - Document the `--save-bundle` option for `npm install`. - ([@datyayu](https://github.com/datyayu)) -* [`7c908b6`](https://github.com/npm/npm/commit/7c908b618f7123f0a3b860c71eb779e33df35964) - [#11644](https://github.com/npm/npm/pull/11644) - Add documentation for the `test` directory for packages. - ([@lewiscowper](https://github.com/lewiscowper)) - -#### INTERNAL TEST IMPROVEMENTS - -The npm CLI team's time recently has been sunk into npm's many years of tech debt. Specifically, we've been working on improving the test suite. This isn't user visible, but in future should mean a more stable, easier to contribute to npm. Ordinarily we don't report these kinds of changes in the change log, but I thought I might share this week as this chunk is bigger than usual. - -These patches were previously released for `npm@3`, and then ported back to `npm@2` LTS. - -* [`437c537`](https://github.com/npm/npm/commit/437c537e2be5923c6d2c2753154564ba13db8fd9) [#11613](https://github.com/npm/npm/pull/11613) Fix up one of the tests after rebasing the legacy test rewrite to `npm@2`. ([@zkat](https://github.com/zkat)) -* [`55abd0c`](https://github.com/npm/npm/commit/55abd0cc20e87a144d33ce2d459f65e7506da576) [#11613](https://github.com/npm/npm/pull/11613) Test that the `package.json` `files` section and `.npmignore` do what they're supposed to. ([@zkat](https://github.com/zkat)) -* [`a2b99b6`](https://github.com/npm/npm/commit/a2b99b6273ada14b2121ebc0acb7933e630edd9d) [#11613](https://github.com/npm/npm/pull/11613) Test that npm's distribution binary is complete and can be installed and used. ([@iarna](https://github.com/iarna)) -* [`8a8c36c`](https://github.com/npm/npm/commit/8a8c36ce51166006022e5c5d4f8655bbc458d651) [#11613](https://github.com/npm/npm/pull/11613) Test that environment variables are properly passed into scripts. - ([@iarna](https://github.com/zkat)) -* [`a95b550`](https://github.com/npm/npm/commit/a95b5507616bd51e83d7eab5f2337b1aff6480b1) [#11613](https://github.com/npm/npm/pull/11613) Test that we don't leak auth info into the environment. ([@iarna](https://github.com/iarna)) -* [`a1c1c52`](https://github.com/npm/npm/commit/a1c1c52efeab24f6dba154d054f85d9efc833486) [#11613](https://github.com/npm/npm/pull/11613) Remove all the relatively cryptic legacy tests and creates new tap tests that check the same functionality. The *legacy* tests were tests that were originally a shell script that was ported to javascript early in `npm`'s history. ([@iarna](https:\\github.com/iarna) and [@zkat](https://github.com/zkat)) -* [`9d89581`](https://github.com/npm/npm/commit/9d895811d3ee70c2e672f3d8fa06574495b5b488) [#11613](https://github.com/npm/npm/pull/11613) `tacks@1.0.9`: Add a package that provides a tool to generate fixtures from folders and, relatedly, a module that an create and tear down filesystem fixtures easily. ([@iarna](https://github.com/iarna)) - -### v2.14.20 (2016-02-18): - -Hope y'all are having a nice week! As usual, it's a fairly limited release. The -most notable thing is some dependency updates that might help the Node.js CI -setup for Windows run a little better, even if we have some work to do on that -path length things, still. - -#### WHITTLING AWAY AT PATH LENGTHS - -So for all of you who don't know -- Node.js does, in fact, support long Windows -paths. Unfortunately, depending on the tool and the Windows version, a lot of -external tooling does not. This means, for example, that some (all?) versions of -Windows Explorer *can literally never delete npm from their system entirely -because of deeply-nested npm dependencies*. Which is pretty gnarly. - -Incidentally, if you run into that in particularly, you can use -[rimraf](npm.im/rimraf) to remove such files 💁. - -The latest victim of this issue was the Node.js CI setup for testing on Windows, -which uses some tooling or another that croaks on the usual path length limit -for that OS: 255 characters. - -This issue, of course, is largely not a problem as of `npm@3`, with its flat -trees, but it still occasionally and viciously bites LTS. - -We've taken another baby step towards alleviating this in this release by -updating a couple of dependencies that were preventing `npmlog` from deduping, -and then doing a dedupe on that and `gauge`. Hopefully it helps. - -* [`4199551`](https://github.com/npm/npm/commit/41995517e617674710748ab6d262670c96124393) - [#11528](https://github.com/npm/npm/pull/11528) - `npm-install-checks@1.0.7`: Just updates the version of npmlog so we can - dedupe it better. - ([@zkat](https://github.com/zkat)) -* [`14d72c7`](https://github.com/npm/npm/commit/14d72c756b89e2d167eb52c1849263dbddcb9f35) - [#11552](https://github.com/npm/npm/pull/11552) - [#11528](https://github.com/npm/npm/pull/11528) - `node-gyp@3.3.0`: AIX support, new `gyp`, update `npmlog` (for the dedupe), - adds `--cafile` command line option, and allows configuration of Node.js and - io.js mirrors. - ([@rvagg](https://github.com/rvagg)) -* [`0453cb9`](https://github.com/npm/npm/commit/0453cb94b33520eb723b7072cd2654b1d0142533) - [#11528](https://github.com/npm/npm/pull/11528) - Do a `dedupe` on `gauge` to flatten our dependencies a bit more. - ([@zkat](https://github.com/zkat)) - -#### OTHER DEP STUFF - -* [`686c0b3`](https://github.com/npm/npm/commit/686c0b37ec3a7b65f9b3849e1099805e5221c408) - `rimraf@2.5.2`: Just updates to glob@7. - ([@isaacs](https://github.com/isaacs)) - -#### @wyze, DOCUMENTATION HERO OF THE PEOPLE, GETS THEIR OWN HEADER - -* [`7232948`](https://github.com/npm/npm/commit/72329484c775376cb40d5b348f453eaaf2f0b821) - [#11416](https://github.com/npm/npm/pull/11416) - Logout docs were using a section copy-pasted from the adduser docs. - ([@wyze](https://github.com/wyze)) -* [`922b33a`](https://github.com/npm/npm/commit/922b33aba4362e1e90f42e9348f061a1cc73eafb) - [#11414](https://github.com/npm/npm/pull/11414) - Add colon for consistency. - ([@wyze](https://github.com/wyze)) - -### v2.14.19 (2016-02-11): - -Really tiny micro-release this week! The main thing to note is a dependency -update that means we no longer have `graceful-fs@3` in our dependency tree. This -has some implications for being able to run on future Node.js releases, so -better to get this out the door. 😁 - -#### DEPS - -* [`a556e0f`](https://github.com/npm/npm/commit/a556e0f9dcb5d7b44224ba9c16c9d0dc6c8d2532) - `cmd-shim@2.0.2`: Final straggler using `graceful-fs@<4`. - ([@ForbesLindesay](https://github.com/ForbesLindesay)) - -#### DOCS - -* [`69a2d59`](https://github.com/npm/npm/commit/69a2d599bf0cba674ee268483e9bd5c14333b89f) - [#11391](https://github.com/npm/npm/pull/11391) - Fixed versions of `shrinkwrap.json` in examples in documentation for `npm - shrinkwrap`, which did not quite match up. - ([@xcatliu](https://github.com/xcatliu)) - -### v2.14.18 (2016-02-04): - -Clearly our docs are perfect after all those wonderful PRs, 'cause this week's -gonna be all about dependency updates. Note: There is a small security-related -fix included here! - -#### SECURITY-RELATED DEPENDENCY UPDATE - -* [`5c095ef`](https://github.com/npm/npm/commit/5c095eff8dc006980d4d083f2007e4dacff23be3) - [#11341](https://github.com/npm/npm/pull/11341) - `request@2.69.0`: Includes security-related dependency updates involving - `hawk` and `is-my-json-valid` - ([@remy](https://github.com/remy) and [@simov](https://github.com/simov)) - -#### OTHER DEPENDENCY UPDATES - -* [`f9c2668`](https://github.com/npm/npm/commit/f9c2668ca3e6e2602d91250ce61280e5e12d0a00) - `which@1.2.4` - ([@isaacs](https://github.com/isaacs)) -* [`2907c43`](https://github.com/npm/npm/commit/2907c43ad4ef87e5f730c2576f680d6837fcbad0) - `spdx-license-ids@1.2.0` - ([@shinnn](https://github.com/shinnn)) -* [`7734069`](https://github.com/npm/npm/commit/773406960bf7f4a87b2ecb6ebf593c62d0e9f95d) - `rimraf@2.5.1` - ([@isaacs](https://github.com/isaacs)) -* [`f4b39a7`](https://github.com/npm/npm/commit/f4b39a7dd5e1335d92aa22c46d99abb33f271b8b) - `retry@0.9.0` - ([@tim-kos](https://github.com/tim-kos)) -* [`ded1e7a`](https://github.com/npm/npm/commit/ded1e7a1c9c7bec29bb7c30a8f85546670e75b56) - Nest `retry@0.8.0` inside `npm-registry-client` to prevent invalid - dependency issue until the latter gets a dependency update. - ([@zkat](https://github.com/zkat)) -* [`ab9f867`](https://github.com/npm/npm/commit/ab9f8679f9687f91ad03adaab6211a897aeebbae) - `read-package-json@2.0.3` - ([@iarna](https://github.com/iarna)) -* [`b638c41`](https://github.com/npm/npm/commit/b638c41607bb936b9eaaceba2aeeda1d34e3a9b2) - `npmlog@2.0.2` - ([@iarna](https://github.com/iarna)) -* [`49f34af`](https://github.com/npm/npm/commit/49f34af463a674359269025d8438feb6a7c69960) - `init-package-json@1.9.3` - ([@iarna](https://github.com/iarna)) -* [`2305dab`](https://github.com/npm/npm/commit/2305dab4e7bff09bb7686cec653cf1e663dbf15d) - `graceful-fs@4.1.3`: Fixed `.close()` not being patched. - ([@isaacs](https://github.com/isaacs)) -* [`18496d9`](https://github.com/npm/npm/commit/18496d9a0fff94e3652655998e8333056aa52b15) - `fs-write-stream-atomic@1.0.8` - ([@iarna](https://github.com/iarna)) -* [`6637bc7`](https://github.com/npm/npm/commit/6637bc7a0e194d82554cd7c91e1794018fef5943) - `config-chain@1.1.10` - ([@dominictarr](https://github.com/dominictarr)) -* [`4222bad`](https://github.com/npm/npm/commit/4222badffed9e9edacea6a8a96a99a164d376158) - `columnify@1.5.4` - ([@timoxley](https://github.com/timoxley)) -* [`df9016f`](https://github.com/npm/npm/commit/df9016f327a2a9ce492ebc75b882b03069438e13) - `ansi@0.3.1`: Added a license file. - ([@TooTallNate](https://github.com/TooTallNate)) - -### v2.14.17 (2016-01-28): - -Another week, another small LTS release! - -#### BETTER ERROR REPORTING YAY - -So as it turns out, when stuff goes wrong, it's actually nice to give people a -better clue rather than just say "oh well 😏". - -* [`5b8ccb9`](https://github.com/npm/npm/commit/5b8ccb91cf11b4edb463609cd4ed1dee84ed4db0) - [#11289](https://github.com/npm/npm/pull/11289) - There is an obscure feature that lets you monkey-patch npm when it starts up. - If the module being required with this feature failed, it would previous just - make npm error out– this reduces that to a warning. - ([@evanlucas](https://github.com/evanlucas)) -* [`556e42a`](https://github.com/npm/npm/commit/556e42ac6bab078722ddc1dc6cce4428d001133b) - [#11300](https://github.com/npm/npm/pull/11300) - Report symlinked packages as 'linked' in the output for `npm outdated`. - ([@halhenke](https://github.com/halhenke)) -* [`3842317`](https://github.com/npm/npm/commit/3842317583e0ea2eca78e39aa03f5bc06ba21de7) - [#11290](https://github.com/npm/npm/pull/11290) - Suppress warnings about pre-release node versions. This should get node's CI - passing on non-Windows platforms without needing to modify the node version to - get rid of the pre-release suffix. - ([@iarna](https://github.com/iarna)) - -#### EVERYONE WANTS THOSE NPM SOCKS, GEEZE - -Did you know that you can get npm socks for contributing to our docs? I bet -these people do, and now so do you! - -* [`dcde451`](https://github.com/npm/npm/commit/dcde451cb85a6ca08acc6ef45782c652f1d8fc89) - [#11232](https://github.com/npm/npm/pull/11232) - Update automatically included/excluded packages in `package.json`. - ([@jscissr](https://github.com/jscissr)) -* [`e3f8d5b`](https://github.com/npm/npm/commit/e3f8d5be5ac5ec1d72db42f7abf50cc4a8c5935c) - [#11273](https://github.com/npm/npm/pull/11273) - Add an example for `npm view <pkg> versions`. - ([@vedatmahir](https://github.com/vedatmahir)) -* [`6a06ef2`](https://github.com/npm/npm/commit/6a06ef2252748089f0013de951f2d06160b90306) - [#11272](https://github.com/npm/npm/pull/11272) - Fix a typo in `npm-update.md`. - ([@jonathanp](https://github.com/jonathanp)) -* [`2515ff1`](https://github.com/npm/npm/commit/2515ff1de28f0b261fb25c79a66bd762a65961c4) - [#11215](https://github.com/npm/npm/pull/11215) - Correct small thinko in docs for SPDX expressions. - ([@kemitchell](https://github.com/kemitchell)) -* [`70f897b`](https://github.com/npm/npm/commit/70f897b03da9a5d5d4fd34614e9ee40e6f9e9653) - [#11196](https://github.com/npm/npm/pull/11196) - Make JSON snippets valid JSON in `npm update` docs. - ([@s100](https://github.com/s100)) - -### v2.14.16 (2016-01-21): - -Good to see you all again! It's been a while since we had an LTS release, and -the team continues to work hard to both get the issue tracker under control, and -get our test suite to be awesome and reliable. - -This is also the first LTS release of this year. - -We're gonna have an interesting time -- most of our focus this year will be -around stability and maintainability of the CLI, so you might actually end up -seeing a number of updates even over here, just for the sake of making sure -we're stable, that bugs get fixed, and tests have proper coverage. - -What better way to start this effort, then, than getting Travis tests green, fix -a few things here and there, and tweak a bunch of documentation? 😁 - -#### FIX ALL THE BUGS AND TWEAK ALL THE THINGS - -* [`24b13fb`](https://github.com/npm/npm/commit/24b13fbc57d34db1d5b0a37bcca122c00deba978) - [#11158](https://github.com/npm/npm/pull/11158) - Fix custom node-gyp env var quoting on Windows. - ([@orangemocha](https://github.com/orangemocha)) -* [`e2503f2`](https://github.com/npm/npm/commit/e2503f2be40157b05a9c500ec3b5d16090ffee50) - [#11142](https://github.com/npm/npm/pull/11142) - Fix race condition with `correctMkdir` in the cache directory. - ([@Jimbly](https://github.com/Jimbly)) - -* [`5c0e4c4`](https://github.com/npm/npm/commit/5c0e4c45a29d774ab729e86044377d4e5e424252) - [#10940](https://github.com/npm/npm/pull/10940) - Ignore failures replacing `package.json`. writeFileAtomic is not atomic in - Windows, it fails if the file is being accessed concurrently. - ([@orangemocha](https://github.com/orangemocha)) -* [`2c44d8d`](https://github.com/npm/npm/commit/2c44d8dc8c267d5e054d0175ce2f4750f0986463) - [#10903](https://github.com/npm/npm/pull/10903) - Add tests for `npm adduser --scope`. - ([@ekmartin](https://github.com/ekmartin)) -* [`4cb25d0`](https://github.com/npm/npm/commit/4cb25d0fed5c7792dfd1aec891380ecc1f8a5761) - [#10903](https://github.com/npm/npm/pull/10903) - Add a message informing users when they have been successfully logged in. - ([@ekmartin](https://github.com/ekmartin)) -* [`fe3ec6d`](https://github.com/npm/npm/commit/fe3ec6d6658262054c0c19c55373c21e84ab9f17) - [#10628](https://github.com/npm/npm/pull/10628) - Tell users how to open an issue with a package that has errored. - ([@trodrigues](https://github.com/trodrigues)) - -#### DOCS DOCS DOCS - -We got a TON of lovely documentation patches, too! Thanks all for submitting! - -* [`22482a1`](https://github.com/npm/npm/commit/22482a1f22079d72c3f8ca55c2f0c153bdd024c0) - [#11188](https://github.com/npm/npm/pull/11188) - Briefly explain what's included when you publish. - ([@beaugunderson](https://github.com/beaugunderson)) -* [`fa47724`](https://github.com/npm/npm/commit/fa4772438df0c66a19309dd1c1a3ce43cbee5461) - [#11150](https://github.com/npm/npm/pull/11150) - Advise use of `--depth Infinity` instead of `--depth 9999` in `npm update`. - ([@halhenke](https://github.com/halhenke)) -* [`248ddfe`](https://github.com/npm/npm/commit/248ddfe8f7ddd3318e14bf61de41cab4a638c8a3) - [#11130](https://github.com/npm/npm/pull/11130) - Nuke "using npm programmatically" section from README. The programmatic npm - API is unsupported, and is not guaranteed not to break in non-major versions. - Removing this section so newcomers aren't encouraged to discover or use it. - ([@ljharb](https://github.com/ljharb)) -* [`ae9c452`](https://github.com/npm/npm/commit/ae9c4521222d60ab4a69c19fee5e361c62f41fae) - [#11128](https://github.com/npm/npm/pull/11128) - Add link to local paths section indocs for `package.json`. - ([@orangejulius](https://github.com/orangejulius)) -* [`663a8c6`](https://github.com/npm/npm/commit/663a8c6b4b1647f9b86c15ef32e30023edc8c060) - [#11044](https://github.com/npm/npm/pull/11044) - Update default value documentation for the color option in npm's config. - ([@scottaddie](https://github.com/scottaddie)) -* [`5c1dda0`](https://github.com/npm/npm/commit/5c1dda0d3a18b2954872dba33fbc696ff0700ffe) - [#11037](https://github.com/npm/npm/pull/11037) - Correct the name property max length constraint verbiage. - ([@scottaddie](https://github.com/scottaddie)) -* [`8288365`](https://github.com/npm/npm/commit/8288365d08e97fa3a5b0d31703c015a8be49e07f) - [#10990](https://github.com/npm/npm/pull/10990) - Update folder docs to reflect that process.installPrefix was removed as of - 0.8.x. - ([@jeffmcmahan](https://github.com/jeffmcmahan)) -* [`61d63fa`](https://github.com/npm/npm/commit/61d63fa22c4f09742180c2de460a4ffb6c32738e) - [#10790](https://github.com/npm/npm/pull/10790) - Clarify that `npm install foo` is the same as `npm install foo@latest` now. - ([@cvrebert](https://github.com/cvrebert)) -* [`442c920`](https://github.com/npm/npm/commit/442c9207f375354c91d36df8711ba2d33e1c97f3) - [#10789](https://github.com/npm/npm/pull/10789) - Link over to `npm-dist-tag(1)` in `npm install` docs when they talk about the - `pkg@<tag>` syntax. - ([@cvrebert](https://github.com/cvrebert)) -* [`dca7a5e`](https://github.com/npm/npm/commit/dca7a5e2be3bfa306a870a123707d35c732406c0) - [#10788](https://github.com/npm/npm/pull/10788) - Link to tag docs in docs for `npm publish --tag`. - ([@cvrebert](https://github.com/cvrebert)) -* [`a72904e`](https://github.com/npm/npm/commit/a72904e8d4ab1d43ae8150fbe3f6468b0cbb1efd) - [#10787](https://github.com/npm/npm/pull/10787) - Explain why the `latest` tag matters. - ([@cvrebert](https://github.com/cvrebert)) -* [`9d0697a`](https://github.com/npm/npm/commit/9d0697a534046df7efda32170014041bbc1f4e7d) - [#10785](https://github.com/npm/npm/pull/10785) - Replace some quite marks in `npm dist-tag` docs for the sake of consistency. - ([@cvrebert](https://github.com/cvrebert)) - -#### I REALLY LIKE GREEN. CAN YOU TELL? - -So Travis is all green now on `npm@2`, thanks to the removal of nock and a few -other test suite tweaks. This is a fantastic step towards making sure we can all -have confidence in our test suite! 🎉 - -* [`64995be`](https://github.com/npm/npm/commit/64995be6d874356b15c136f9867302d805dfe1e9) [`75ab216`](https://github.com/npm/npm/commit/75ab2164cf79e28ac7f7ebe714f3c5aee99c6626) [`a9f6fe9`](https://github.com/npm/npm/commit/a9f6fe9dc558f17c4a7b9eb83329ac080f7df4b7) [`649c193`](https://github.com/npm/npm/commit/649c193adadf714c2819837f9372a29d724a5ec0) [`94cb05e`](https://github.com/npm/npm/commit/94cb05eaa9e5ad6675cf15c4ac0a44fbdde05900) [`6541690`](https://github.com/npm/npm/commit/65416907008061ac5a5f66b1630a57776803b526) [`255be6f`](https://github.com/npm/npm/commit/255be6f5bca9e3d216f3a5cbdf6714c6c9fcf132) [`9e84fa4`](https://github.com/npm/npm/commit/9e84fa43c49d04cf86ca1678e2a61412f5559cb9) [`8a587b0`](https://github.com/npm/npm/commit/8a587b0c1696ae7302891fa6355fc3e8670e00d3) [`bf812a5`](https://github.com/npm/npm/commit/bf812a54e497a573493346399798aa0b9373ac24) - [#10903](https://github.com/npm/npm/pull/10903) - Get rid of nock from tests, and get Travis green. - ([@zkat](https://github.com/zkat) and [@iarna](https://github.com/iarna)) -* [`70a5310`](https://github.com/npm/npm/commit/70a5310712c6666e753ca8f3bfff4a780ec6292d) - `npm-registry-couchapp@2.6.12`: - Better 0.8 compatibility, and ability to run in travis docker stuff. This - means the test suite should run a lot faster, too! - ([@iarna](https://github.com/iarna)) -* [`28fae39`](https://github.com/npm/npm/commit/28fae399212eda5554e6c0ffd8c9591144ab7b9d) - Get rid of sudo, for Travis! - ([@zkat](https://github.com/zkat)) - -### v2.14.15 (2015-12-10): - -Did you know that Bob Ross reached the rank of master sergeant in the US Air -Force before becoming perhaps the most soothing painter of all time? - -#### TWO HAPPY LITTLE BUG FIXES - -* [`f482664`](https://github.com/npm/npm/commit/f4826645dc6b5c0f05c5f9187efb28c1a293554f) - [#10505](https://github.com/npm/npm/issues/10505) `npm ls --json --depth=0` - now respects the depth parameter, when it is zero and when it is not zero. - ([@MarkReeder](https://github.com/MarkReeder)) -* [`529fa1f`](https://github.com/npm/npm/commit/529fa1ff2c6432a773af99a1c5209c0865f7a19c) - [#9099](https://github.com/npm/npm/issues/9099) I had always thought you - could run `npm version` from subdirectories in your project, which is great, - because now you can. I guess I was just ahead of my time. - ([@ekmartin](https://github.com/ekmartin)) - -#### NOW PAINT IN SOME NICE DOCS CHANGES - -* [`1fc7f2b`](https://github.com/npm/npm/commit/1fc7f2b523ea760e08adb9b861b28e3ba450e565) - [#10546](https://github.com/npm/npm/issues/10546) Goodbye, FAQ! You were - cheeky and fun until you weren't! Don't worry: npm still loves everyone, - especially you! ([@ashleygwilliams](https://github.com/ashleygwilliams)) -* [`7fe6950`](https://github.com/npm/npm/commit/7fe6950b44d241bb4d90857a44d89d750af1e2b3) - [#10570](https://github.com/npm/npm/issues/10570) Update documentation URLs - to be HTTPS everywhere sensible. No HTTP shall be spared! - ([@rsp](https://github.com/rsp)) -* [`96ebb90`](https://github.com/npm/npm/commit/96ebb902439e4f6f37f8beffb589769146fecf24) - [#10650](https://github.com/npm/npm/issues/10650) Correctly note that there - are two lifecycle scripts run by an install phase in an example, instead of - three. ([@eymengunay](https://github.com/eymengunay)) -* [`5196893`](https://github.com/npm/npm/commit/5196893a7496f68a514b83641ff6b72f14d664dd) - [#10687](https://github.com/npm/npm/issues/10687) `npm outdated`'s output can - be a little puzzling sometimes. I've attempted to make it clearer, with some - examples, of what's going on with "wanted" and "latest" in more cases. - ([@othiym23](https://github.com/othiym23)) -* [`8e6712d`](https://github.com/npm/npm/commit/8e6712d4ee128858cab36c77723e35bddbb977ba) - [#10700](https://github.com/npm/npm/issues/10700) Hey, do you remember when - `search.npmjs.org` was a thing? I think I do? The last time I used it was in - like 2012, and it's gone now, so remove it from the docs. - ([@gagern](https://github.com/gagern)) -* [`27d2612`](https://github.com/npm/npm/commit/27d2612b3f5aa88b12c943d04e162ce4c3a350ae) - `semver@5.1.0`: Include BNF for SemVer expression grammar (which is also now - included in `npm help semver`). ([@isaacs](https://github.com/isaacs)) - -#### LAND YOUR DEPENDENCY UPGRADES IN PAIRS SO EVERYONE HAS A FRIEND - -* [`fc6c3c5`](https://github.com/npm/npm/commit/fc6c3c53a31e9e11c2616fcd378202e5b80bf286) - `request@2.67.0` ([@simov](https://github.com/simov)) -* [`07013fd`](https://github.com/npm/npm/commit/07013fd0fd55a2eb31fb9334631ee5d0dd5c41bb) - [isaacs/rimraf#89](https://github.com/isaacs/rimraf/pull/89) `rimraf@2.4.4` - ([@zerok](https://github.com/zerok)) -* [`bc149be`](https://github.com/npm/npm/commit/bc149bef871f0f00639509898cece531af3aa8b3) - [isaacs/once#7](https://github.com/isaacs/once/pull/7) `once@1.3.3` - ([@floatdrop](https://github.com/floatdrop)) -* [`ac598d3`](https://github.com/npm/npm/commit/ac598d36e1ad207bc0d8a7eadfd84b26146aec1f) - `lru-cache@3.2.0` ([@isaacs](https://github.com/isaacs)) -* [`1b915ce`](https://github.com/npm/npm/commit/1b915ce1e0787ccb6d8aa235d002d66565f2175d) - `npm-registry-client@7.0.9` ([@othiym23](https://github.com/othiym23)) -* [`df7dd78`](https://github.com/npm/npm/commit/df7dd78b8fe3cc58202996fa6c994fc55419bfa5) - `tap@2.3.1` ([@isaacs](https://github.com/isaacs)) - -### v2.14.14 (2015-12-03): - -#### FIX URL IN LICENSE - -The license incorrectly identified the registry URL as `registry.npmjs.com` and -this has been corrected to `registry.npmjs.org`. - -* [`6051a69`](https://github.com/npm/npm/commit/6051a69b1adc80f5f200077067e831643f655bd4) - [#10685](https://github.com/npm/npm/pull/10685) - Fix npm public registry URL in notices. - ([@kemitchell](https://github.com/kemitchell)) - -#### NO MORE MD5 - -We updated modules that had been using MD5 for non-security purposes. While -this is perfectly safe, if you compile Node in FIPS-compliance mode it will -explode if you try to use MD5. We've replaced MD5 with Murmur, which conveys -our intent better and is faster to boot. - -* [`30b5994`](https://github.com/npm/npm/commit/30b599496a9762482e1cef945a378e3a534fd366) - [#10629](https://github.com/npm/npm/issues/10629) - `write-file-atomic@1.1.4` - ([@othiym23](https://github.com/othiym23)) -* [`68c63ff`](https://github.com/npm/npm/commit/68c63ff1279d3d5ea7b2c970ab5562a8e0536f27) - [#10629](https://github.com/npm/npm/issues/10629) - `fs-write-stream-atomic@1.0.5` - ([@othiym23](https://github.com/othiym23)) - -#### DEPENDENCY UPDATES - -* [`e48e5a9`](https://github.com/npm/npm/commit/e48e5a90b4dcf76124b7e9ea3b295c1383e7f0c8) - [nodejs/node-gyp#831](https://github.com/nodejs/node-gyp/pull/831) - `node-gyp@3.2.1`: Improved \*BSD support. - ([@bnoordhuis](https://github.com/bnoordhuis)) - -### v2.14.13 (2015-11-25): - -#### THE npm CLI !== THE npm REGISTRY !== npm, INC. - -npm-the-CLI is licensed under the terms of the [Artistic License -2.0](https://github.com/npm/npm/blob/8d79c1a39dae908f27eaa37ff6b23515d505ef29/LICENSE), -which is a liberal open-source license that allows you to take this code and do -pretty much whatever you like with it (that is, of course, not legal language, -and if you're doing anything with npm that leaves you in doubt about your legal -rights, please seek the review of qualified counsel, which is to say, not -members of the CLI team, none of whom have passed the bar, to my knowledge). At -the same time the primary registry the CLI uses when looking up and downloading -packages is a commercial service run by npm, Inc., and it has its own [Terms of -Use](https://www.npmjs.com/policies/terms). - -Aside from clarifying the terms of use (and trying to make sure they're more -widely known), the only recent changes to npm's licenses have been making the -split between the CLI and registry clearer. You are still free to do whatever -you like with the CLI's source, and you are free to view, download, and publish -packages to and from `registry.npmjs.org`, but now the existing terms under -which you can do so are more clearly documented. Aside from the two commits -below, see also [the release notes for -`npm@2.14.11`](https://github.com/npm/npm/releases/tag/v2.14.11), which is where -the split between the CLI's code and the terms of use for the registry was -first made more clear. - -* [`1f3e936`](https://github.com/npm/npm/commit/1f3e936aab6840667948ef281e0c3621df365131) - [#10532](https://github.com/npm/npm/issues/10532) Clarify that - `registry.npmjs.org` is the default, but that you're free to use the npm CLI - with whatever registry you wish. ([@kemitchell](https://github.com/kemitchell)) -* [`6733539`](https://github.com/npm/npm/commit/6733539eeb9b32a5f2d1a6aa797987e2252fa760) - [#10532](https://github.com/npm/npm/issues/10532) Having semi-duplicate - release information in `README.md` was confusing and potentially inaccurate, - so remove it. ([@kemitchell](https://github.com/kemitchell)) - -#### EASE UP ON WINDOWS BASH USERS - -It turns out that a fair number of us use bash on Windows (through MINGW or -bundled with Git, plz – Cygwin is still a bridge too far, for both npm and -Node.js). [@jakub-g](https://github.com/jakub-g) did us all a favor and relaxed -the check for npm completion to support MINGW bash. Thanks, Jakub! - -* [`460cc09`](https://github.com/npm/npm/commit/460cc0950fd6a005c4e5c4f85af807814209b2bb) - [#10156](https://github.com/npm/npm/issues/10156) completion: enable on - Windows in git bash ([@jakub-g](https://github.com/jakub-g)) - -#### MAKE NODE-GYP A LITTLE BLUER - -* [`333e118`](https://github.com/npm/npm/commit/333e1181082842c21edc62f0ce515928424dff1f) - `node-gyp@3.2.0`: Support AIX, use `which` to find Python, updated to a newer - version of `gyp`, and more! ([@bnoordhuis](https://github.com/bnoordhuis)) - -#### WE LIKE SPDX AND ALL BUT IT'S NOT ACTUALLY A DIRECT DEP, SORRY - -* [`1f4b4bb`](https://github.com/npm/npm/commit/1f4b4bbdf8758281beecb7eaf75d05a6c4a77c15) - Removed `spdx` as a direct npm dependency, since we don't actually need it at - that level, and updated subdeps for `validate-npm-package-license` - ([@othiym23](https://github.com/othiym23)) - -#### A BOUNTEOUS THANKSGIVING CORNUCOPIA OF DOC TWEAKS - -These are great! Keep them coming! Sorry for letting them pile up so deep, -everybody. Also, a belated Thanksgiving to our Canadian friends, and a happy -Thanksgiving to all our friends in the USA. - -* [`6101f44`](https://github.com/npm/npm/commit/6101f44737645d9379c3396fae81bbc4d94e1f7e) - [#10250](https://github.com/npm/npm/issues/10250) Correct order of `org:team` - in `npm team` documentation. ([@louislarry](https://github.com/louislarry)) -* [`e8769f9`](https://github.com/npm/npm/commit/e8769f9807b91582c15ef130733e2e72b6c7bda4) - [#10371](https://github.com/npm/npm/issues/10371) Remove broken / duplicate - link to tag. ([@WickyNilliams](https://github.com/WickyNilliams)) -* [`1ae2dbe`](https://github.com/npm/npm/commit/1ae2dbe759feb80d8634569221ec6ee2c6d1d1ff) - [#10419](https://github.com/npm/npm/issues/10419) Remove references to - nonexistent `npm-rm(1)` documentation. ([@KenanY](https://github.com/KenanY)) -* [`777a271`](https://github.com/npm/npm/commit/777a271830a42d4ee62540a89f764a6e7d62de19) - [#10474](https://github.com/npm/npm/issues/10474) Clarify that install finds - dependencies in `package.json`. ([@sleekweasel](https://github.com/sleekweasel)) -* [`dcf4b5c`](https://github.com/npm/npm/commit/dcf4b5cbece1b0ef55ab7665d9acacc0b6b7cd6e) - [#10497](https://github.com/npm/npm/issues/10497) Clarify what a package is - slightly. ([@aredridel](https://github.com/aredridel)) -* [`447b3d6`](https://github.com/npm/npm/commit/447b3d669b2b6c483b8203754ac0a002c67bf015) - [#10539](https://github.com/npm/npm/issues/10539) Remove an extra, spuriously - capitalized letter. ([@alexlukin-softgrad](https://github.com/alexlukin-softgrad)) - -### v2.14.12 (2015-11-19): - -#### TEEN ORCS AT THE GATES - -This week heralds the general release of the primary npm registry's [new -support for private packages for -organizations](http://blog.npmjs.org/post/133542170540/private-packages-for-organizations). -For many potential users, it's the missing piece needed to make it easy for you -to move your organization's private work onto npm. And now it's here! The -functionality to support it has been in place in the CLI for a while now, -thanks to [@zkat](https://github.com/zkat)'s hard work. - -During our final testing before the release, our ace support team member -[@snopeks](https://github.com/snopeks) noticed that there had been some drift -between the CLI team's implementation and what npm was actually preparing to -ship. In the interests of everyone having a smooth experience with this -_extremely useful_ new feature, we quickly made a few changes to square up the -CLI and the web site experiences. - -* [`0e8b15e`](https://github.com/npm/npm/commit/0e8b15e9fbc89e31bd00e573b648846beddfb835) - [#9327](https://github.com/npm/npm/issues/9327) `npm access` no longer has - problems when run in a directory that doesn't contain a `package.json`. - ([@othiym23](https://github.com/othiym23)) -* [`c4e939c`](https://github.com/npm/npm/commit/c4e939c1d493601d25dcb88e6ffcca73076fd3fd) - [npm/npm-registry-client#126](https://github.com/npm/npm-registry-client/issues/126) - `npm-registry-client@7.0.8`: Allow the CLI to grant, revoke, and list - permissions on unscoped (public) packages on the primary registry. - ([@othiym23](https://github.com/othiym23)) - -#### A BRIEF NOTE ON NPM'S BACKWARDS COMPATIBILITY - -We don't often have much to say about the changes we make to our internal -testing and tooling, but I'm going to take this opportunity to reiterate that -npm tries hard to maintain compatibility with a wide variety of Node versions. -As this change shows, we want to ensure that npm works the same across: - -* Node.js 0.8 -* Node.js 0.10 -* Node.js 0.12 -* the latest io.js release -* Node.js 4 LTS -* Node.js 5 - -Contributors who send us pull requests often notice that it's very rare that -our tests pass across all of those versions (ironically, almost entirely due to -the packages we use for testing instead of any issues within npm itself). We're -currently beginning an effort, lasting the rest of 2015, to clean up our test -suite, and not only get it passing on all of the above versions of Node.js, but -working solidly on Windows as well. This is a compounding form of technical -debt that we're finally paying down, and our hope is that cleaning up the tests -will produce a more robust CLI that's a lot easier to write patches for. - -* [`d743620`](https://github.com/npm/npm/commit/d743620a0005213a65d25de771661b4d48a09717) - [#10233](https://github.com/npm/npm/issues/10233) Update Node.js versions - that Travis uses to test npm. ([@iarna](https://github.com/iarna)) - -#### TYPOS IN THE LICENSE, OH MY - -* [`58ac241`](https://github.com/npm/npm/commit/58ac241f556b2c202a8ee33321965e2540361ca7) - [#10478](https://github.com/npm/npm/issues/10478) Correct two typos in npm's - LICENSE. ([@jorrit](https://github.com/jorrit)) - -### v2.14.11 (2015-11-12): - -#### ASK FOR NOTHING, GET LATEST - -When you run `npm install foo`, you probably expect that you'll get the -`latest` version of `foo`, whatever that is. And good news! That's what this -change makes it do. - -We _think_ this is what everyone wants, but if this causes problems for you, we -want to know! If it proves problematic for people we will consider reverting it -(preferably before this becomes `npm@latest`). - -Previously, when you ran `npm install foo` we would act as if you typed `npm -install foo@*`. Now, like any range-type specifier, in addition to matching the -range, it would also have to be `<=` the value of the `latest` dist-tag. -Further, it would exclude prerelease versions from the list of versions -considered for a match. - -This worked as expected most of the time, unless your `latest` was a prerelease -version, in which case that version wouldn't be used, to everyone's surprise. - -* [`6f0a646`](https://github.com/npm/npm/commit/6f0a646cd865b24fe3ff25365bf5421780e63e01) - [#10189](https://github.com/npm/npm/issues/10189) `npm-package-arg@4.1.0`: - Change the default version from `*` to `latest`. - ([@zkat](https://github.com/zkat)) - -#### LICENSE CLARIFICATION - -* [`54a9046`](https://github.com/npm/npm/commit/54a90461f068ea89baa5d70248cdf1581897936d) - [#10326](https://github.com/npm/npm/issues/10326) Clarify what-all is covered - by npm's license and point to the registry's terms of use. - ([@kemitchell](https://github.com/kemitchell)) - -#### CLOSER TO GREEN TRAVIS - -* [`28efd3d`](https://github.com/npm/npm/commit/28efd3d7dfb2fa3755076ae706ea4d38c6ee6900) - [#10232](https://github.com/npm/npm/issues/10232) `nock@1.9.0`: Downgrade - nock to a version that doesn't depend on streams2 in core so that more of our - tests can pass in 0.8. ([@iarna](https://github.com/iarna)) - -#### A BUG FIX - -* [`eacac8f`](https://github.com/npm/npm/commit/eacac8f05014d15217c3d8264d0b00a72eafe2d2) - [#9965](https://github.com/npm/npm/issues/9965) Fix a corrupt `package.json` - file introduced by a merge conflict in - [`022691a`](https://github.com/npm/npm/commit/022691a). - ([@waynebloss](https://github.com/waynebloss)) - -#### A DEPENDENCY UPGRADE - -* [`ea7d8e0`](https://github.com/npm/npm/commit/ea7d8e00a67a3d5877ed72c9728909c848468a9b) - [npm/nopt#51](https://github.com/npm/nopt/pull/51) `nopt@3.0.6`: Allow - types checked to be validated by passed-in name in addition to the JS name of - the type / class. ([@wbecker](https://github.com/wbecker)) - -### v2.14.10 (2015-11-05): - -There's nothing in here that that isn't in the `npm@3.4.0` release notes, but -all of the commit shasums have been adjusted to be correct. Enjoy! - -#### BUG FIXES VIA DEPENDENCY UPDATES - -* [`204c558`](https://github.com/npm/npm/commit/204c558c06637a753c0b41d0cf19f564a1ac3715) - [#8640](https://github.com/npm/npm/issues/8640) - [npm/normalize-package-data#69](https://github.com/npm/normalize-package-data/pull/69) - `normalize-package-data@2.3.5`: Fix a bug where if you didn't specify the - name of a scoped module's binary, it would install it such that it was - impossible to call it. ([@iarna](https://github.com/iarna)) -* [`bbdf4ee`](https://github.com/npm/npm/commit/bbdf4ee0a3cd12be6a2ace255b67d573a72f1f8f) - [npm/fstream-npm#14](https://github.com/npm/fstream-npm/pull/14) - `fstream-npm@1.0.7`: Only filter `config.gypi` when it's in the build - directory. ([@mscdex](https://github.com/mscdex)) -* [`d82ff81`](https://github.com/npm/npm/commit/d82ff81403e906931fac701775723626dcb443b3) - [npm/fstream-npm#15](https://github.com/npm/fstream-npm/pull/15) - `fstream-npm@1.0.6`: Stop including directories that happened to have names - matching whitelisted npm files in npm module tarballs. The most common cause - was that if you had a README directory then everything in it would be - included if wanted it or not. ([@taion](https://github.com/taion)) - -#### DOCUMENTATION FIXES - -* [`16361d1`](https://github.com/npm/npm/commit/16361d122f2ff6d1a4729c66153b7c24c698fd19) - [#10036](https://github.com/npm/npm/pull/10036) Fix typo / over-abbreviation. - ([@ifdattic](https://github.com/ifdattic)) -* [`d1343dd`](https://github.com/npm/npm/commit/d1343dda42f113dc322f95687f5a8c7d71a97c35) - [#10176](https://github.com/npm/npm/pull/10176) Fix broken link, scopes => - scope. ([@ashleygwilliams](https://github.com/ashleygwilliams)) -* [`110663d`](https://github.com/npm/npm/commit/110663d000a3908a4853393d9abae481700cf4dc) - [#9460](https://github.com/npm/npm/issue/9460) Specifying the default command - run by "npm start" and the fact that you can pass it arguments. - ([@JuanCaicedo](https://github.com/JuanCaicedo)) - -#### DEPENDENCY UPDATES FOR THEIR OWN SAKE - -* [`7476d2d`](https://github.com/npm/npm/commit/7476d2d31552a41671c425aa7fcc2844e0381008) - [npm/npmlog#19](https://github.com/npm/npmlog/pull/19) - `npmlog@2.0.0`: Make it possible to emit log messages with `error` as the - prefix. - ([@bengl](https://github.com/bengl)) -* [`6ca7888`](https://github.com/npm/npm/commit/6ca7888862cfe8bf802dc7c66632c102acd94cf5) - `read-package-json@2.0.2`: Minor cleanups. - ([@KenanY](https://github.com/KenanY)) - -### v2.14.9 (2015-10-29): - -There's still life in `npm@2`, but for now, enjoy these dependency upgrades! -Also, [@othiym23](https://github.com/othiym23) says hi! _waves_ -[@zkat](https://github.com/zkat) has her hands full, and -[@iarna](https://github.com/iarna)'s handling `npm@3`, so I'm dealing with -`npm@2` and the totally nonexistent weird bridge `npm@1.4` LTS release that may -or may not be happening this week. - -#### CAN'T STOP WON'T STOP UPDATING THOSE DEPENDENCIES - -* [`f52f0cb`](https://github.com/npm/npm/commit/f52f0cb51526314197e9d67619feebbd82a397b7) - [#10150](https://github.com/npm/npm/issues/10150) `chmodr@1.0.2`: Use - `fs.lstat()` to check if an entry is a directory, making `chmodr()` work - properly with NFS mounts on Windows. ([@sheerun](https://github.com/sheerun)) -* [`f7011d7`](https://github.com/npm/npm/commit/f7011d7b3b1d9148a6cd8f7b8359d6fe3269a912) - [#10150](https://github.com/npm/npm/issues/10150) `which@1.2.0`: Additional - command-line parameters, which is nice but not used by npm. - ([@isaacs](https://github.com/isaacs)) -* [`ebcc0d8`](https://github.com/npm/npm/commit/ebcc0d8629388da0b849bbbad590382cd7268f51) - [#10150](https://github.com/npm/npm/issues/10150) `minimatch@3.0.0`: Don't - package browser version. ([@isaacs](https://github.com/isaacs)) -* [`8c98dce`](https://github.com/npm/npm/commit/8c98dce5ffe242bafbe92b849e73e8de1803e256) - [#10150](https://github.com/npm/npm/issues/10150) `fstream-ignore@1.0.3`: - Upgrade to use `minimatch@3` (for deduping purposes). - ([@othiym23](https://github.com/othiym23)) -* [`db9ef33`](https://github.com/npm/npm/commit/db9ef337c253ecf21c921055bf8742e10d1cb3bb) - [#10150](https://github.com/npm/npm/issues/10150) `request@2.65.0`: - Dependency upgrades and a few bug fixes, mostly related to cookie handling. - ([@simov](https://github.com/simov)) - -#### DEVDEPENDENCIES TOO, I GUESS, IT'S COOL - -* [`dfbf621`](https://github.com/npm/npm/commit/dfbf621afa09c46991249b4f9a995d1823ea7ede) - [#10150](https://github.com/npm/npm/issues/10150) `tap@2.2.0`: Better - handling of test order handling (including some test fixes for npm). - ([@isaacs](https://github.com/isaacs)) -* [`cf5ad5a`](https://github.com/npm/npm/commit/cf5ad5a8c88bfd72e30ef8a8d1d3c5508e0b3c23) - [#10150](https://github.com/npm/npm/issues/10150) `nock@2.16.0`: More - expectations, documentation, and bug fixes. - ([@pgte](https://github.com/pgte)) - -### v2.14.8 (2015-10-08): - -#### SLOWLY RECOVERING FROM FEELINGS - -OS&F is definitely my favorite convention I've gone to. Y'all should check it -out next year! Rebecca and Kat are back, although Forrest is out at -[&yet conf](http://andyetconf.com/). - -This week sees another tiny LTS release with non-code-related patches -- just -CI/release things. - -Meanwhile, have you heard? `npm@3` is much faster now! Go upgrade with `npm -install -g npm@latest` and give it a whirl if you haven't already! - -#### IF YOU CHANGE CASING ON A FILE, YOU ARE NOT MY FRIEND - -Seriously. I love me some case-sensitive filesystems, but a lot of us have to -deal with `git` and its funky support for case normalizing systems. Have mercy -and just don't bother if all you're changing is casing, please? Otherwise, I -have to do this little dance to prevent horrible conflicts. - -* [`c3a7b61`](https://github.com/npm/npm/commit/c3a7b619786650a45653c8b55b8741fc7bb5cfda) - [#9804](https://github.com/npm/npm/pulls/9804) Remove the readme file with - weird casing. - ([@zkat](https://github.com/zkat)) -* [`f3f619e`](https://github.com/npm/npm/commit/f3f619e06e4be1378dbf286f897b50e9c69c9557) - [#9804](https://github.com/npm/npm/pulls/9804) Add the readme file back in, - with desired casing. - ([@zkat](https://github.com/zkat)) - -#### IDK. OUR CI DOESN'T EVEN FULLY WORK YET BUT SURE - -Either way, it's nice to make sure we're running stuff on the latest Node. `4.2` -is getting released very soon, though (this week?), and that'll be the first -official LTS release! - -* [`bd0b9ab`](https://github.com/npm/npm/commit/bd0b9ab6e60a31448794bbd88f94672572c3cb55) - [#9827](https://github.com/npm/npm/pulls/9827) Add node `4.0` and `4.1` to - TravisCI - ([@JaKXz](https://github.com/JaKXz)) - -### v2.14.7 (2015-10-01): - -#### MORE RELEASE STAGGERING?! - -Hi all, and greetings from [Open Source & Feelings](http://osfeels.com)! - -So we're switching gears a little with how we handle our weekly releases: from -now on, we're going to stagger release weeks between dependency bumps and -regular patches. So, this week, aside from a doc change, we'll be doing only -version bumps. Expect actual patches next week! - -#### TOTALLY FOLLOWING THE RULES ALREADY - -So I snuck this in, because it's our own [@snopeks](https://github.com/snopeks)' -first contribution to the main `npm` repo. She's been helping with building -support documents for Orgs, and contributed her general intro guide to the new -feature so you can read it with `npm help orgs` right in your terminal! - -* [`8324ea0`](https://github.com/npm/npm/commit/8324ea023ace4e08b6b8959ad199e2457af9f9cf) - [#9761](https://github.com/npm/npm/pull/9761) Added general user guide for - Orgs. - ([@snopeks](https://github.com/snopeks)) - -#### JUST. ONE. MORE. - -* [`9a502ca`](https://github.com/npm/npm/commit/9a502ca96e2d43ec75a8f684c9ca33af7e910f0a) - Use unique package name in tests to work around weird test-state-based - failures. - ([@iarna](https://github.com/iarna)) - -#### OKAY ACTUALLY THE THING I WAS SUPPOSED TO DO - -Anyway -- here's your version bump! :) - -* [`4aeb94c`](https://github.com/npm/npm/commit/4aeb94c9f0df3f41802cf2e0397a998f3b527c25) - `request@2.64.0`: No longer defaulting to `application/json` for `json` - requests. Also some minor doc and packaging patches. - ([@simov](https://github.com/simov)) - `minimatch@3.0.0`: No longer packaging browser modules. - ([@isaacs](https://github.com/isaacs)) -* [`a18b213`](https://github.com/npm/npm/commit/a18b213e6945a8f5faf882927829ac95f844e2aa) - `glob@5.0.15`: Upgraded `minimatch` dependency. - ([@isaacs](https://github.com/isaacs)) -* [`9eb64d4`](https://github.com/npm/npm/commit/9eb64e44509519ca9d788502edb2eba4cea5c86b) - `nock@2.13.0` - ([@pgte](https://github.com/pgte)) - -### v2.14.6 (2015-09-24): - -#### `¯\_(ツ)_/¯` - -Since `2.x` is LTS now, you can expect a slowdown in overall release sizes. On -top of that, we had our all-company-npm-internal-conf thing on Monday and -Tuesday so there wasn't really time to do much at all. - -Still, we're bringing you a couple of tiny little changes this week! - -* [`7b7da13`](https://github.com/npm/npm/commit/7b7da13c6cdf5eae53c20d5c69afc4c16e6f715d) - [#9471](https://github.com/npm/npm/pull/9471) When the port for a tarball is - different than the registry it's in, but the hostname is the same, the - protocol is now allowed to change, too. - ([@fastest963](https://github.com/fastest963)) -* [`6643ada`](https://github.com/npm/npm/commit/6643adaf9f37f08893e3ad28b797c55a36b2a152) - `request@2.63.0`: Use `application/json` as the default content type when - making `json` requests. - ([@simov](https://github.com/simov)) - -### v2.14.5 (2015-09-17): - -#### NPM IS DEAD. LONG LIVE NPM - -That's right folks. As of this week, `npm@next` is `npm@3`, which means it'll be -`npm@latest` next week! There's some really great shiny new things over there, -and you should really take a look. - -Many kudos to [@iarna](https://github.com/iarna) for her hard work on `npm@3`! - -Don't worry, we'll keep `2.x` around for a while (as LTS), but you won't see -many, if any, new features on this end. From now on, we're going to use -`latest-2` and `next-2` as the dist tags for the `npm@2` branch. - -#### OKAY THAT'S FINE CAN I DEPRECATE THINGS NOW? - -Yes! Specially if you're using scoped packages. Apparently, deprecating them -never worked, but that should be better now. :) - -* [`eca7b24`](https://github.com/npm/npm/commit/eca7b24de9a0090da02a93a69726f5e70ab80543) - [#9558](https://github.com/npm/npm/issues/9558) Add tests for npm deprecate. - ([@zkat](https://github.com/zkat)) -* [`648fe16`](https://github.com/npm/npm/commit/648fe16157ef0db22395ae056d1dd4b4c1605bf4) - [#9558](https://github.com/npm/npm/issues/9558) `npm-registry-client@7.0.7`: - Fixes `npm deprecate` so you can actually deprecate scoped modules now (it - never worked). - ([@zkat](https://github.com/zkat)) - -#### WTF IS `node-waf` - -idk. Some old thing. We don't talk about it anymore. - -* [`cf1b39f`](https://github.com/npm/npm/commit/cf1b39fc95a9ffad7fba4c2fee705c53b19d1d16) - [#9584](https://github.com/npm/npm/issues/9584) Fix ancient references to - `node-waf` in the docs to refer to the `node-gyp` version of things. - ([@KenanY](https://github.com/KenanY)) - -#### THE `graceful-fs` AND `node-gyp` SAGA CONTINUES - -Last week had some sweeping `graceful-fs` upgrades, and this takes care of one -of the stragglers, as well as bumping `node-gyp`. `node@4` users might be -excited about this, or even `node@<4` users who previously had to cherry-pick a -bunch of patches to get the latest npm working. - -* [`e07354f`](https://github.com/npm/npm/commit/e07354f3ff3a6be568fe950f1f825897f72912d8) - `sha@2.0.1`: Upgraded graceful-fs! - ([@ForbesLindesay](https://github.com/ForbesLindesay)) -* [`83cb6ee`](https://github.com/npm/npm/commit/83cb6ee4045b85e565e9678ca1878877e1dc75bd) - `node-gyp@3.0.3` - ([@rvagg](https://github.com/rvagg)) - -#### DEPS! DEPS! MORE DEPS! OK STOP DEPS - -* [`0d60888`](https://github.com/npm/npm/commit/0d608889615a1cb63f5f852337e955053f201aeb) - `normalize-package-data@2.3.4`: Use an external package to check for built-in - node modules. - ([@sindresorhus](https://github.com/sindresorhus)) -* [`79b4dac`](https://github.com/npm/npm/commit/79b4dac11f1c2d8ad5489fc3104734e1c10d4793) - `retry@0.8.0` - ([@tim-kos](https://github.com/tim-kos)) -* [`c164941`](https://github.com/npm/npm/commit/c164941d3c792904d5b126a4fd36eefbe0699f52) - `request@2.62.0`: node 4 added to build targets. Option initialization issues - fixed. - ([@simov](https://github.com/simov)) -* [`0fd878a`](https://github.com/npm/npm/commit/0fd878a44d5ae303325808d1f00df4dce7549d50) - `lru-cache@2.7.0`: Cache serialization support and fixes a cache length bug. - ([@isaacs](https://github.com/isaacs)) -* [`6a7a114`](https://github.com/npm/npm/commit/6a7a114a45b4699995d6e09164fdfd0fa1274591) - `nock@2.12.0` - ([@pgte](https://github.com/pgte)) -* [`6b25e6d`](https://github.com/npm/npm/commit/6b25e6d2235c11f4444104db4545cb42a0267666) - `semver@5.0.3`: Removed uglify-js dead code. - ([@isaacs](https://github.com/isaacs)) - -### v2.14.4 (2015-09-10): - -#### THE GREAT NODEv4 SAGA - -So [Node 4 is out now](https://nodejs.org/en/blog/release/v4.0.0/) and that's -going to involve a number of things over in npm land. Most importantly, it's the -last major release that will include the `2.x` branch of npm. That also means -that `2.x` is going to go into LTS mode in the coming weeks -- once `npm@3` -becomes our official `latest` release. You can most likely expect Node 5 to -include `npm@3` by default, whenever that happens. We'll go into more detail -about LTS at that point, as well, so keep your eyes peeled for announcements! - -#### NODE IS DEAD. LONG LIVE NODE! - -Node 4 being released means that a few things that used to be floating patches -are finally making it right into npm proper. This week, we've got two such -updates, both to dependencies: - -* [`505d9e4`](https://github.com/npm/npm/commit/505d9e40c13b8b0bb3f70ee9886f7b73ba569407) - `node-gyp@3.0.1`: Support for node nightlies and compilation for both node and - io.js without extra patching - ([@rvagg](https://github.com/rvagg)) - -[@thefourtheye](https://github.com/thefourtheye) was kind enough to submit a -*bunch* of PRs to npm's dependencies updating them to `graceful-fs@4.1.2`, which -mainly makes it so we're no longer monkey-patching `fs`. The following are all -updates related to this: - -* [`10cb189`](https://github.com/npm/npm/commit/10cb189c773fef804214018d57509cc7a943184b) - `write-file-atomic@1.1.3` - ([@thefourtheye](https://github.com/thefourtheye)) -* [`edfb80b`](https://github.com/npm/npm/commit/edfb80b39f8cfce9a993f139eb98248001198e09) - `tar@2.2.1` - ([@thefourtheye](https://github.com/thefourtheye)) -* [`aa6e1ee`](https://github.com/npm/npm/commit/aa6e1eede7d71fa69d7256afdfbaa3406bc39a5b) - `read-package-json@2.0.1` - ([@thefourtheye](https://github.com/thefourtheye)) -* [`18971a3`](https://github.com/npm/npm/commit/18971a361635ed3958ecd39b63930ae1e56f8612) - `read-installed@4.0.3` - ([@thefourtheye](https://github.com/thefourtheye)) -* [`a4cba71`](https://github.com/npm/npm/commit/a4cba71bd2532236fda7385bf55e8790cafd4f0a) - `fstream@1.0.8` - ([@thefourtheye](https://github.com/thefourtheye)) -* [`70a38e2`](https://github.com/npm/npm/commit/70a38e29418951ac61ab6cf269d188074fe8ac3a) - `fs-write-stream-atomic@1.0.4` - ([@thefourtheye](https://github.com/thefourtheye)) -* [`9cbd20f`](https://github.com/npm/npm/commit/9cbd20f691e37960e4ba12d401abd1069657cb47) - `fs-vacuum@1.2.7` - ([@thefourtheye](https://github.com/thefourtheye)) - -#### OTHER PATCHES - -* [`c4dd521`](https://github.com/npm/npm/commit/c4dd5213b2f3283ea0392845e5f78cac4573529e) - [#9506](https://github.com/npm/npm/issues/9506) Make `npm link` work on - Windows when using node pre-release/RC releases. - ([@jon-hall](https://github.com/jon-hall)) -* [`b6bc29c`](https://github.com/npm/npm/commit/b6bc29c1401b3d6b570c09cbef1866bdb0436b59) - [#9544](https://github.com/npm/npm/issues/9549) `process.binding` is being - deprecated, so our only direct usage has been removed. - ([@ChALkeR](https://github.com/ChALkeR)) - -#### MORE DEPENDENCIES! - -* [`d940594`](https://github.com/npm/npm/commit/d940594e479a7f012b6dd6952e8ef985ba2a6216) - `tap@1.4.1` - ([@isaacs](https://github.com/isaacs)) -* [`ee38486`](https://github.com/npm/npm/commit/ee3848669331fd98879a3175789d963543f67ce3) - `which@1.1.2`: Added tests for Windows-related dead code that was previously - helping a silent failure happen. Travis stuff, too. - ([@isaacs](https://github.com/isaacs)) - -#### DOC UPDATES - -* [`475daf5`](https://github.com/npm/npm/commit/475daf54ad07777938d1d7ee1a3e576961e84510) - [#9492](https://github.com/npm/npm/issues/9492) Clarify how `.npmignore` and - `.gitignore` are found and used by npm. - ([@addaleax](https://github.com/addaleax)) -* [`b2c391d`](https://github.com/npm/npm/commit/b2c391d7833249626a6d7650363a83bcc778717a) - `nopt@3.0.4`: Minor clarifications to docs about how array and errors work. - ([@zkat](https://github.com/zkat)) - -### v2.14.3 (2015-09-03): - -#### TEAMS AND ORGS STILL BETA. CLI CODE STILL SOLID. - -Our closed beta for Teens and Orcs is happening! The web team is hard at work -making sure everything looks pretty and usable and such. Once we fix things -stemming from that beta, you can expect the feature to be available publicly. -Some time after that, it'll even be available for free for FOSS orgs. It'll Be -Done When It's Done™. - -#### OH GOOD, I CAN ACTUALLY UPSTREAM NOW - -Looks like last week's release foiled our own test suite when trying to upstream -it to Node! Just a friendly reminder that no, `.npmrc` is no longer included -then you pack/release a package! [@othiym23](https://github.com/othiym23) and -[@isaacs](https://github.com/isaacs) managed to suss the really strange test -failures resulting from that, and we've patched it in this release. - -* [`01a3428`](https://github.com/npm/npm/commit/01a3428534b754dca89a56fd1e49f55cb22f6f25) - [#9476](https://github.com/npm/npm/issues/9476) test: Recreate missing - `.npmrc` files when missing so downstream packagers can run tests on packed - npm. - ([@othiym23](https://github.com/othiym23)) - -#### TALKING ABOUT THE CHANGELOG IN THE CHANGELOG IS LIKE, POMO OR SOMETHING - -* [`c1e7a83`](https://github.com/npm/npm/commit/c1e7a83c0ae7aadf01aecc57cf8a0ae2009d4da8) - [#9431](https://github.com/npm/npm/issues/9431) CHANGELOG: clarify - windows-related nature of patch - ([@saper](https://github.com/saper)) - -#### devDependencies UPDATED - -No actual dep updates this week, but we're bumping a couple of devDeps: - -* [`8454835`](https://github.com/npm/npm/commit/84548351bfd63e3e305d195abbcad24c6b7c3e8e) - `tap@1.4.0`: Add `t.contains()` as alias to `t.match()` - ([@isaacs](https://github.com/isaacs)) -* [`13d2216`](https://github.com/npm/npm/commit/13d22161bcdeb6e1ed095d5ba2f77e6abfffa5eb) - `deep-equal@1.0.1`: Make `null == undefined` in non-strict mode - ([@isaacs](https://github.com/isaacs)) - -### v2.14.2 (2015-08-27): - -#### GETTING THAT PESKY `preferGlobal` WARNING RIGHT - -So apparently the `preferGlobal` option hasn't quite been warning correctly for -some time. But now it should be all better! tl;dr: if you try and install a -dependency with `preferGlobal: true`, and it's _not already_ in your -`package.json`, you'll get a warning that the author would really rather you -install it with `--global`. This should prevent Windows PowerShell from thinking -npm has failed just because of a benign warning. - -* [`bbb25f3`](https://github.com/npm/npm/commit/bbb25f30d582f8979168c79233a9f8f840974f90) - [#8841](https://github.com/npm/npm/issues/8841) - [#9409](https://github.com/npm/npm/issues/9409) The `preferGlobal` - warning shouldn't happen if the dependency being installed is listed in - `devDependencies`. ([@saper](https://github.com/saper)) -* [`222fcec`](https://github.com/npm/npm/commit/222fcec85ccd30d35899e5037079fb14625af4e2) - [#9409](https://github.com/npm/npm/issues/9409) `preferGlobal` now prints a - warning when there are no dependencies for the current package. - ([@zkat](https://github.com/zkat)) -* [`5cfed6d`](https://github.com/npm/npm/commit/5cfed6d7a1a5f2731688cfc8293b5e43a6355393) - [#9409](https://github.com/npm/npm/issues/9409) Verify that - `preferGlobal` is warning as expected (when a `preferGlobal` dependency is - installed, but isn't listed in either `dependencies` or `devDependencies`). - ([@zkat](https://github.com/zkat)) - -#### BUMP +1 - -* [`eeafce2`](https://github.com/npm/npm/commit/eeafce2d06883c0f51bf403415b6bc5f2647eba3) - `validate-npm-package-license@3.0.1`: Include additional metadata in parsed license object, - useful for license checkers. ([@kemitchell](https://github.com/kemitchell)) -* [`1502a28`](https://github.com/npm/npm/commit/1502a285f84aa548806b3eafc8889e6288e810f3) - `normalise-package-data@2.3.2`: Updated to use `validate-npm-package-license@3.0.1`. - ([@othiym23](https://github.com/othiym23)) -* [`cbde823`](https://github.com/npm/npm/commit/cbde8233436bf0ea62a4740869b4990322c20659) - `init-package-json@1.9.1`: Add a `silent` option to suppress output on writing the - generated `package.json`. Also, updated to use `validate-npm-package-license@3.0.1`. - ([@zkat](https://github.com/zkat)) -* [`08fda46`](https://github.com/npm/npm/commit/08fda465452b4d77f1ced8050ee3a35a77fc30a5) - `tar@2.2.0`: Minor improvements. ([@othiym23](https://github.com/othiym23)) -* [`dc2f20b`](https://github.com/npm/npm/commit/dc2f20b53fff77203139c863b48da0e959df2ac9) - `rimraf@2.4.3`: `EPERM` now triggers a delay / retry loop (since Windows throws - this when things still hold a handle). ([@isaacs](https://github.com/isaacs)) -* [`e8acb27`](https://github.com/npm/npm/commit/e8acb273aa67ee0394d0431650e1b2a7d09c8554) - `read@1.0.7`: Fix licensing ambiguity. ([@isaacs](https://github.com/isaacs)) - -#### OTHER STUFF THAT'S RELEVANT - -* [`73a1ee0`](https://github.com/npm/npm/commit/73a1ee0be90fa1928521b63f28bef83b8ffab61d) - [#9386](https://github.com/npm/npm/issues/9386) Include additional unignorable files in - documentation. - ([@mjhasbach](https://github.com/mjhasbach)) -* [`0313e40`](https://github.com/npm/npm/commit/0313e40ee0f757fce8861be590ad668c23d7be53) - [#9396](https://github.com/npm/npm/issues/9396) Improve the `EISDIR` error - message returned by npm's error-handling code to give users a better hint of - what's most likely going on. Usually, error reports with this error code are - about people trying to install things without a `package.json`. - ([@KenanY](https://github.com/KenanY)) -* [`2677457`](https://github.com/npm/npm/commit/26774579c739c5951351e58263cf4d6ea3d66ec8) - [#9360](https://github.com/npm/npm/issues/9360) Make it easier to run - only _some_ of npm tests with lifecycle scripts via `npm tap test/tap/testname.js`. - ([@iarna](https://github.com/iarna)) - -### v2.14.1 (2015-08-20): - -#### SECURITY FIX - -There are patches for two information leaks of moderate severity in `npm@2.14.1`: - -1. In some cases, npm was leaking sensitive credential information into the - child environment when running package and lifecycle scripts. This could - lead to packages being published with files (most notably `config.gypi`, a - file created by `node-gyp` that is a cache of environmental information - regenerated on every run) containing the bearer tokens used to authenticate - users to the registry. Users with affected packages have been notified (and - the affected tokens invalidated), and now npm has been modified to not - upload files that could contain this information, as well as scrubbing the - sensitive information out of the environment passed to child scripts. -2. Per-package `.npmrc` files are used by some maintainers as a way to scope - those packages to a specific registry and its credentials. This is a - reasonable use case, but by default `.npmrc` was packed into packages, - leaking those credentials. npm will no longer include `.npmrc` when packing - tarballs. - -If you maintain packages and believe you may be affected by either -of the above scenarios (especially if you've received a security -notification from npm recently), please upgrade to `npm@2.14.1` as -soon as possible. If you believe you may have inadvertently leaked -your credentials, upgrade to `npm@2.14.1` on the affected machine, -and run `npm logout` and then `npm login`. Your access tokens will be -invalidated, which will eliminate any risk posed by tokens inadvertently -included in published packages. We apologize for the inconvenience this -causes, as well as the oversight that led to the existence of this issue -in the first place. - -Huge thanks to [@ChALkeR](https://github.com/ChALkeR) for bringing these -issues to our attention, and for helping us identify affected packages -and maintainers. Thanks also to the Node.js security working group for -their coördination with the team in our response to this issue. We -appreciate everybody's patience and understanding tremendously. - -* [`b9474a8`](https://github.com/npm/npm/commit/b9474a843ca55b7c5fac6da33989e8eb39aff8b1) - `fstream-npm@1.0.5`: Stop publishing build cruft (`config.gypi`) and per-project - `.npmrc` files to keep local configuration out of published packages. - ([@othiym23](https://github.com/othiym23)) -* [`13c286d`](https://github.com/npm/npm/commit/13c286dbdc3fa8fec4cb79fc4d1ee505c8a41b2e) - [#9348](https://github.com/npm/npm/issues/9348) Filter "private" - (underscore-prefixed, even when scoped to a registry) configuration values - out of child environments. ([@othiym23](https://github.com/othiym23)) - -#### BETTER WINDOWS INTEGRATION, ONE STEP AT A TIME - -* [`e40e71f`](https://github.com/npm/npm/commit/e40e71f2f838a8a42392f44e3eeec04e323ab743) - [#6412](https://github.com/npm/npm/issues/6412) Improve the search strategy - used by the npm shims for Windows to prioritize your own local npm installs. - npm has really needed this tweak for a long time, so hammer on it and let us - know if you run into issues, but with luck it will Just Work. - ([@joaocgreis](https://github.com/joaocgreis)) -* [`204ebbb`](https://github.com/npm/npm/commit/204ebbb3e0cab696a429a878ceeb4a7e78ec2b94) - [#8751](https://github.com/npm/npm/issues/8751) - [#7333](https://github.com/npm/npm/issues/7333) Keep [autorun - scripts](https://technet.microsoft.com/en-us/sysinternals/bb963902.aspx) from - interfering with npm package and lifecycle script execution on Windows by - adding `/d` and `/s` when invoking `cmd.exe`. - ([@saper](https://github.com/saper)) - -#### IT SEEMED LIKE AN IDEA AT THE TIME - -* [`286f3d9`](https://github.com/npm/npm/commit/286f3d97103812f0fd84b70352addbe899e258f9) - [#9201](https://github.com/npm/npm/pull/9201) For a while npm was building - HTML partials for use on [`docs.npmjs.com`](https://docs.npmjs.com), but we - weren't actually using them. Stop building them, which makes running the full - test suite and installation process around a third faster. - ([@isaacs](https://github.com/isaacs)) - -#### A SINGLE LONELY DEPENDENCY UPGRADE - -* [`b343b95`](https://github.com/npm/npm/commit/b343b956ef777e321e4251ddc96ec6d80827d9e2) - `request@2.61.0`: Bug fixes and keep-alive tweaks. - ([@simov](https://github.com/simov)) - -### v2.14.0 (2015-08-13): - -#### IT'S HERE! KINDA! - -This release adds support for teens and orcs (err, teams and organizations) to -the npm CLI! Note that the web site and registry-side features of this are -still not ready for public consumption. - -A beta should be starting in the next couple of weeks, and the features -themselves will become public once all that's done. Keep an eye out for more -news! - -All of these changes were done under [`#9011`](https://github.com/npm/npm/pull/9011): - -* [`6424170`](https://github.com/npm/npm/commit/6424170fc17c666a6efc090370ec691e0cab1792) - Added new `npm team` command and subcommands. - ([@zkat](https://github.com/zkat)) -* [`52220d1`](https://github.com/npm/npm/commit/52220d146d474ec29b683bd99c06f75cbd46a9f4) - Added documentation for new `npm team` command. - ([@zkat](https://github.com/zkat)) -* [`4e66830`](https://github.com/npm/npm/commit/4e668304850d02df8eb27a779fda76fe5de645e7) - Updated `npm access` to support teams and organizations. - ([@zkat](https://github.com/zkat)) -* [`ea3eb87`](https://github.com/npm/npm/commit/ea3eb8733d9fa09ce34106b1b19fb1a8f95844a5) - Gussied up docs for `npm access` with new commands. - ([@zkat](https://github.com/zkat)) -* [`6e0b431`](https://github.com/npm/npm/commit/6e0b431c1de5e329c86e57d097aa88ebfedea864) - Fix up `npm whoami` to make the underlying API usable elsewhere. - ([@zkat](https://github.com/zkat)) -* [`f29c931`](https://github.com/npm/npm/commit/f29c931012ce5ccd69c29d83548f27e443bf7e62) - `npm-registry-client@7.0.1`: Upgrade `npm-registry-client` API to support - `team` and `access` calls against the registry. - ([@zkat](https://github.com/zkat)) - -#### A FEW EXTRA VERSION BUMPS - -* [`c977e12`](https://github.com/npm/npm/commit/c977e12cbfa50c2f52fc807f5cc19ba1cc1b39bf) - `init-package-json@1.8.0`: Checks for some `npm@3` metadata. - ([@iarna](https://github.com/iarna)) -* [`5c8c9e5`](https://github.com/npm/npm/commit/5c8c9e5ae177ba7d0d298cfa42f3fc7f0271e4ec) - `columnify@1.5.2`: Updated some dependencies. - ([@timoxley](https://github.com/timoxley)) -* [`5d56742`](https://github.com/npm/npm/commit/5d567425768b75aeab402c817a53d8b2bc60d8de) - `chownr@1.0.1`: Tests, docs, and minor style nits. - ([@isaacs](https://github.com/isaacs)) - -#### ALSO A DOC FIX - -* [`846fcc7`](https://github.com/npm/npm/commit/846fcc79b86984b109a97366b0422f995a45f8bf) - [`#9200`](https://github.com/npm/npm/pull/9200) Remove single quotes - around semver range, thus making it valid semver. - ([@KenanY](https://github.com/KenanY)) - -### v2.13.5 (2015-08-07): - -This is another quiet week for the `npm@2` release. -[@zkat](https://github.com/zkat) has been working hard on polishing the CLI -bits of the registry's new feature to support direct management of teams and -organizations, and [@iarna](https://github.com/iarna) continues to work through -the list of issues blocking the general release of `npm@3`, which is looking -more and more solid all the time. - -[@othiym23](https://github.com/othiym23) and [@zkat](https://github.com/zkat) -have also been at this week's Node.js / io.js [collaborator -summit](https://github.com/nodejs/summit/tree/master), both as facilitators and -participants. This is a valuable opportunity to get some face time with other -contributors and to work through a bunch of important discussions, but it does -leave us feeling kind of sleepy. Running meetings is hard! - -What does that leave for this release? A few of the more tricky bug fixes that -have been sitting around for a little while now, and a couple dependency -upgrades. Nothing too fancy, but most of these were contributed by developers -like _you_, which we think is swell. Thanks! - -#### BUG FIXES - -* [`d7271b8`](https://github.com/npm/npm/commit/d7271b8226712479cdd339bf85faf7e394923e0d) - [#4530](https://github.com/npm/npm/issues/4530) The bash completion script - for npm no longer alters global completion behavior around word breaks. - ([@whitty](https://github.com/whitty)) -* [`c9ce294`](https://github.com/npm/npm/commit/c9ce29415a0a8fc610690b6e9d91b64d6e36cfcc) - [#7198](https://github.com/npm/npm/issues/7198) When setting up dependencies - to be shared via `npm link <package>`, only run the lifecycle scripts during - the original link, not when running `npm link <package>` or `npm install - --link` against them. ([@murgatroid99](https://github.com/murgatroid99)) -* [`422da66`](https://github.com/npm/npm/commit/422da664bd3ce71313da447f170507faf5aac46a) - [#9108](https://github.com/npm/npm/issues/9108) Clear up minor confusion - around wording in `bundledDependencies` section of `package.json` docs. - ([@derekpeterson](https://github.com/derekpeterson)) -* [`6b42d99`](https://github.com/npm/npm/commit/6b42d99460885e715772d3487b1c548d2bc8a738) - [#9146](https://github.com/npm/npm/issues/9146) Include scripts that run for - `preversion`, `version`, and `postversion` in the section for lifecycle - scripts rather than the generic `npm run-script` output. - ([@othiym23](https://github.com/othiym23)) - -#### NOPE, NOT DONE WITH DEPENDENCY UPDATES - -* [`91a48bb`](https://github.com/npm/npm/commit/91a48bb5ef5a990781c86f8b69b8a32cf4fac2d9) - `chmodr@1.0.1`: Ignore symbolic links when recursively changing mode, just - like the Unix command. ([@isaacs](https://github.com/isaacs)) -* [`4bbc86e`](https://github.com/npm/npm/commit/4bbc86e3825e2eee9a8758ba26bdea0cb6a2581e) - `nock@2.10.0` ([@pgte](https://github.com/pgte)) - -### v2.13.4 (2015-07-30): - -#### JULY ENDS ON A FAIRLY QUIET NOTE - -Hey everyone! I hope you've had a great week. We're having a fairly small -release this week while we wrap up Teams and Orgs (or, as we've taken to calling -it internally, _Teens and Orcs_). - -In other exciting news, a bunch of us are gonna be at the [Node.js Collaborator -Summit](https://github.com/nodejs/summit/issues/1), and you can also find us at -[wafflejs](https://wafflejs.com/) on Wednesday. Hopefully we'll be seeing some -of you there. :) - -#### THE PATCH!!! - -So here it is. The patch. Hope it helps. (Thanks, -[@ktarplee](https://github.com/ktarplee)!) - -* [`2e58c48`](https://github.com/npm/npm/commit/2e58c4819e3cafe4ae23ab7f4a520fe09258cfd7) - [#9033](https://github.com/npm/npm/pull/9033) `npm version` now works on git - submodules - ([@ktarplee](https://github.com/ktarplee)) - -#### OH AND THERE'S A DEV DEPENDENCIES UPDATE - -Hooray. - -* [`d204683`](https://github.com/npm/npm/commit/d2046839d471322e61e3ceb0f00e78e5c481f967) - `nock@2.9.1` - ([@pgte](https://github.com/pgte)) - -### v2.13.3 (2015-07-23): - -#### I'M SAVING THE GOOD JOKES FOR MORE INTERESTING RELEASES - -It's pretty hard to outdo last week's release buuuuut~ I promise I'll have a -treat when we release our shiny new **Teams and Organizations** feature! :D -(Coming Soon™). It'll be a real *gem*. - -That means it's a pretty low-key release this week. We got some nice -documentation tweaks, a few bugfixes, and other such things, though! - -Oh, and a _bunch of version bumps_. Thanks, `semver`! - -#### IT'S THE LITTLE THINGS THAT MATTER - -* [`2fac6ae`](https://github.com/npm/npm/commit/2fac6aeffefba2934c3db395b525d931599c34d8) - [#9012](https://github.com/npm/npm/issues/9012) A convenience for releases -- - using the globally-installed npm before now was causing minor annoyances, so - we just use the exact same npm we're releasing to build the new release. - ([@zkat](https://github.com/zkat)) - -#### WHAT DOES THIS BUTTON DO? - -There's a couple of doc updates! The last one might be interesting. - -* [`4cd3205`](https://github.com/npm/npm/commit/4cd32050c0f89b7f1ae486354fa2c35eea302ba5) - [#9002](https://github.com/npm/npm/issues/9002) Updated docs to list the - various files that npm automatically includes and excludes, regardless of - settings. - ([@SimenB](https://github.com/SimenB)) -* [`cf09e75`](https://github.com/npm/npm/commit/cf09e754931739af32647d667b671e72a4c79081) - [#9022](https://github.com/npm/npm/issues/9022) Document the `"access"` field - in `"publishConfig"`. Did you know you don't need to use `--access=public` - when publishing scoped packages?! Just put it in your `package.json`! - Go refresh yourself on scopes packages by [checking our docs](https://docs.npmjs.com/getting-started/scoped-packages) on them. - ([@boennemann](https://github.com/boennemann)) -* [`bfd73da`](https://github.com/npm/npm/commit/bfd73da33349cc2afb8278953b2ae16ea95023de) - [#9013](https://github.com/npm/npm/issues/9013) fixed typo in changelog - ([@radarhere](https://github.com/radarhere)) - -#### THE SEMVER MAJOR VERSION APOCALYPSE IS UPON US - -Basically, `semver` is up to `@5`, and that meant we needed to go in an update a -bunch of our dependencies manually. `node-gyp` is still pending update, since -it's not ours, though! - -* [`9232e58`](https://github.com/npm/npm/commit/9232e58d54c032c23716ef976023d36a42bfdcc9) - [#8972](https://github.com/npm/npm/issues/8972) `init-package-json@1.7.1` - ([@othiym23](https://github.com/othiym23)) -* [`ba44f6b`](https://github.com/npm/npm/commit/ba44f6b4201a4faee025341b123e372d8f45b6d9) - [#8972](https://github.com/npm/npm/issues/8972) `normalize-package-data@2.3.1` - ([@othiym23](https://github.com/othiym23)) -* [`3901d3c`](https://github.com/npm/npm/commit/3901d3cf191880bb4420b1d6b8aedbcd8fc26cdf) - [#8972](https://github.com/npm/npm/issues/8972) `npm-install-checks@1.0.6` - ([@othiym23](https://github.com/othiym23)) -* [`ffcc7dd`](https://github.com/npm/npm/commit/ffcc7dd12f8bb94ff0f64c465c57e460b3f24a24) - [#8972](https://github.com/npm/npm/issues/8972) `npm-package-arg@4.0.2` - ([@othiym23](https://github.com/othiym23)) -* [`7128f9e`](https://github.com/npm/npm/commit/7128f9ec10c0c8482087511b716dbddb54249626) - [#8972](https://github.com/npm/npm/issues/8972) `npm-registry-client@6.5.1` - ([@othiym23](https://github.com/othiym23)) -* [`af28911`](https://github.com/npm/npm/commit/af28911ecd54a844f848c6ae41887097d6aa2f3b) - [#8972](https://github.com/npm/npm/issues/8972) `read-installed@4.0.2` - ([@othiym23](https://github.com/othiym23)) -* [`3cc817a`](https://github.com/npm/npm/commit/3cc817a0f34f698b580ff6ff02308700efc54f7c) - [#8972](https://github.com/npm/npm/issues/8972) node-gyp needs its own version - of semver - ([@othiym23](https://github.com/othiym23)) -* [`f98eccc`](https://github.com/npm/npm/commit/f98eccc6e3a6699ca0aa9ecbad93a3b995583871) - [#8972](https://github.com/npm/npm/issues/8972) `semver@5.0.1`: Stop including - browser builds. - ([@isaacs](https://github.com/isaacs)) - -#### \*BUMP\* - -And some other version bumps for good measure. - -* [`254ecfb`](https://github.com/npm/npm/commit/254ecfb04f026c2fd16427db01a53600c1892c8b) - [#8990](https://github.com/npm/npm/issues/8990) `marked-man@0.1.5`: Fixes an - issue with documentation rendering where backticks in 2nd-level headers would - break rendering (?!?!) - ([@steveklabnik](https://github.com/steveklabnik)) -* [`79efd79`](https://github.com/npm/npm/commit/79efd79ac216da8cee8636fb2ed926b0196a4eb6) - `minimatch@2.0.10`: A pattern like `'*.!(x).!(y)'` should not match a name - like `'a.xyz.yab'`. - ([@isaacs](https://github.com/isaacs)) -* [`39c7dc9`](https://github.com/npm/npm/commit/39c7dc9a4e17cd35a5ed882ba671821c9a900f9e) - `request@2.60.0`: A few bug fixes and doc updates. - ([@simov](https://github.com/simov)) -* [`72d3c3a`](https://github.com/npm/npm/commit/72d3c3a9e1e461608aa21b14c01a650333330da9) - `rimraf@2.4.2`: Minor doc and dep updates - ([@isaacs](https://github.com/isaacs)) -* [`7513035`](https://github.com/npm/npm/commit/75130356a06f5f4fbec3786aac9f9f0b36dfe010) - `nock@2.9.1` - ([@pgte](https://github.com/pgte)) -* [`3d9aa82`](https://github.com/npm/npm/commit/3d9aa82260f0643a32c13d0c1ed16f644b6fd4ab) - Fixes this thing where Kat decided to save `nock` as a regular dependency ;) - ([@othiym23](https://github.com/othiym23)) - -### v2.13.2 (2015-07-16): - -#### HOLD ON TO YOUR TENTACLES... IT'S NPM RELEASE TIME! - -Kat: Hooray! Full team again, and we've got a pretty small patch release this -week, about everyone's favorite recurring issue: git URLs! - -Rebecca: No Way! Again? - -Kat: The ride never ends! In the meantime, there's some fun, exciting work in -the background to get orgs and teams out the door. Keep an eye out for news. :) - -Rebecca: And make sure to keep an eye out for patches for the super-fresh -`npm@3`! - -#### LET'S GIT INKY - -Rebecca: So what's this about another git URL issue? - -Kat: Welp, I apparently broke backwards-compatibility on what are actually -invalid `git+https` URLs! So I'm making it work, but we're gonna deprecate URLs -that look like `git+https://user@host:path/is/here`. - -Rebecca: What should we use instead?! - -Kat: Just do me a solid and use `git+ssh://user@host:path/here` or -`git+https://user@host/absolute/https/path` instead! - -* [`769f06e`](https://github.com/npm/npm/commit/769f06e5455d7a9fc738379de2e05868df0dab6f) - Updated tests for `getResolved` so the URLs are run through - `normalize-git-url`. - ([@zkat](https://github.com/zkat)) -* [`edbae68`](https://github.com/npm/npm/commit/edbae685bf48971e878ced373d6825fc1891ee47) - [#8881](https://github.com/npm/npm/issues/8881) Added tests to verify that `git+https:` URLs are handled compatibly. - ([@zkat](https://github.com/zkat)) - -#### NEWS FLASH! DOCUMENTATION IMPROVEMENTS! - -* [`bad4e014`](https://github.com/npm/npm/commit/bad4e0143cc95754a682f1da543b2b4e196e924b) - [#8924](https://github.com/npm/npm/pull/8924) Make sure documented default - values in `lib/cache.js` properly correspond to current code. - ([@watilde](https://github.com/watilde)) -* [`e7a11fd`](https://github.com/npm/npm/commit/e7a11fdf70e333cdfe3dac94a1a30907adb76d59) - [#8036](https://github.com/npm/npm/issues/8036) Clarify the documentation for - `.npmrc` to clarify that it's not read at the project level when doing global - installs. - ([@espadrine](https://github.com/espadrine)) - -#### STAY FRESH~ - -Kat: That's it for npm core changes! - -Rebecca: Great! Let's look at the fresh new dependencies, then! - -Kat: See you all next week! - -Both: Stay Freeesh~ - -(some cat form of Forrest can be seen snoring in the corner) - -* [`bfa1f45`](https://github.com/npm/npm/bfa1f45ee760d05039557d2245b7e3df9fda8def) - `normalize-git-url@3.0.1`: Fixes url normalization such that `git+https:` - accepts scp syntax, but get converted into absolute-path `https:` URLs. Also - fixes scp syntax so you can have absolute paths after the `:` - (`git@myhost.org:/some/absolute/place.git`) - ([@zkat](https://github.com/zkat)) -* [`6f757d2`](https://github.com/npm/npm/6f757d22b53f91da0bebec6b5d16c1f4dbe130b4) - `glob@5.0.15`: Better handling of ENOTSUP - ([@isaacs](https://github.com/isaacs)) -* [`0920819`](https://github.com/npm/npm/09208197fb8b0c6d5dbf6bd7f59970cf366de989) - `node-gyp@2.0.2`: Fixes an issue with long paths on Win32 - ([@TooTallNate](https://github.com/TooTallNate)) - -### v2.13.1 (2015-07-09): - -#### KAUAI WAS NICE. I MISS IT. - -But Forrest's still kinda on vacation, and not just mentally, because he's -hanging out with the fine meatbags at CascadiaFest. Enjoy this small bug -release. - -#### MAKE OURSELVES HAPPY - -* [`40981f2`](https://github.com/npm/npm/commit/40981f2e0c9c12bb003ccf188169afd1d201f5af) - [#8862](https://github.com/npm/npm/issues/8862) Make the lifecycle's safety - check work with scoped packages. ([@tcort](https://github.com/tcort)) -* [`5125856`](https://github.com/npm/npm/commit/512585622481dbbda9a0306932468d59efaff658) - [#8855](https://github.com/npm/npm/issues/8855) Make dependency versions of - `"*"` match `"latest"` when all versions are prerelease. - ([@iarna](https://github.com/iarna)) -* [`22fdc1d`](https://github.com/npm/npm/commit/22fdc1d52602ba7098af978c75fca8f7d1060141) - Visually emphasize the correct way to write lifecycle scripts. - ([@josh-egan](https://github.com/josh-egan)) - -#### MAKE TRAVIS HAPPY - -* [`413c3ac`](https://github.com/npm/npm/commit/413c3ac2ab2437f3011c6ca0d1630109ec14e604) - Use npm's `2.x` branch for testing its `2.x` branch. - ([@iarna](https://github.com/iarna)) -* [`7602f64`](https://github.com/npm/npm/commit/7602f64826f7a465d9f3a20bd87a376d992607e6) - Don't prompt for GnuPG passphrase in version lifecycle tests. - ([@othiym23](https://github.com/othiym23)) - -#### MAKE `npm outdated` HAPPY - -* [`d338668`](https://github.com/npm/npm/commit/d338668601d1ebe5247a26237106e80ea8cd7f48) - [#8796](https://github.com/npm/npm/issues/8796) `fstream-npm@1.0.4`: When packing the - package tarball, npm no longer crashes for packages with certain combinations of - `.npmignore` entries, `.gitignore` entries, and lifecycle scripts. - ([@iarna](https://github.com/iarna)) -* [`dbe7c9c`](https://github.com/npm/npm/commit/dbe7c9c74734be870d16dd61b9e7f746123011f6) - `nock@2.7.0`: Add matching based on query strings. - ([@othiym23](https://github.com/othiym23)) - -There are new versions of `strip-ansi` and `ansi-regex`, but npm only uses them -indirectly, so we pushed them down into their dependencies where they can get -updated at their own pace. - -* [`06b6ca5`](https://github.com/npm/npm/commit/06b6ca5b5333025f10c8d901628859bd4678e027) - undeduplicate `ansi-regex` ([@othiym23](https://github.com/othiym23)) -* [`b168e33`](https://github.com/npm/npm/commit/b168e33ad46faf47020a45f72ba8cec8c644bdb9) - undeduplicate `strip-ansi` ([@othiym23](https://github.com/othiym23)) - -### v2.13.0 (2015-07-02): - -#### FORREST IS OUT! LET'S SNEAK IN ALL THE THINGS! - -Well, not _everything_. Just a couple of goodies, like the new `npm ping` -command, and the ability to add files to the commits created by `npm version` -with the new version hooks. There's also a couple of bugfixes in `npm` itself -and some of its dependencies. Here we go! - -#### YES HELLO THIS IS NPM REGISTRY SORRY NO DOG HERE - -Yes, that's right! We now have a dedicated `npm ping` command. It's super simple -and super easy. You ping. We tell you whether you pinged right by saying hello -right back. This should help out folks dealing with things like proxy issues or -other registry-access debugging issues. Give it a shot! - -This addresses [#5750](https://github.com/npm/npm/issues/5750), and will help -with the `npm doctor` stuff described in -[#6756](https://github.com/npm/npm/issues/6756). - -* [`f1f7a85`](https://github.com/npm/npm/commit/f1f7a85) - Add ping command to CLI - ([@michaelnisi](https://github.com/michaelnisi)) -* [`8cec629`](https://github.com/npm/npm/commit/8cec629) - Add ping command to npm-registry-client - ([@michaelnisi](https://github.com/michaelnisi)) -* [`0c0c92d`](https://github.com/npm/npm/0c0c92d) - Fixed ping command issues (added docs, tests, fixed minor bugs, etc) - ([@zkat](https://github.com/zkat)) - -#### I'VE WANTED THIS FOR `version` SINCE LIKE LITERALLY FOREVER AND A DAY - -Seriously! This patch lets you add files to the `version` commit before it's -made, So you can add additional metadata files, more automated changes to -`package.json`, or even generate `CHANGELOG.md` automatically pre-commit if -you're into that sort of thing. I'm so happy this is there I can't even. Do you -have other fun usecases for this? Tell -[npmbot (@npmjs)](http://twitter.com/npmjs) about it! - -* [`582f170`](https://github.com/npm/npm/commit/582f170) - [#8620](https://github.com/npm/npm/issues/8620) version: Allow scripts to add - files to the commit. - ([@jamestalmage](https://github.com/jamestalmage)) - -#### ALL YOUR FILE DESCRIPTORS ARE BELONG TO US - -We've had problems in the past with things like `EMFILE` errors popping up when -trying to install packages with a bunch of dependencies. Isaac patched up -[`graceful-fs`](https://github.com/isaacs/node-graceful-fs) to handle this case -better, so we should be seeing fewer of those. - -* [`022691a`](https://github.com/npm/npm/commit/022691a) - `graceful-fs@4.1.2`: Updated so we can monkey patch globally. - ([@isaacs](https://github.com/isaacs)) -* [`c9fb0fd`](https://github.com/npm/npm/commit/c9fb0fd) - Globally monkey-patch graceful-fs. This should fix some errors when installing - packages with lots of dependencies. - ([@isaacs](https://github.com/isaacs)) - -#### READ THE FINE DOCS. THEY'VE IMPROVED - -* [`5587d0d`](https://github.com/npm/npm/commit/5587d0d) - Nice clarification for `directories.bin` - ([@ujane](https://github.com/ujane)) -* [`20673c7`](https://github.com/npm/npm/commit/20673c7) - Hey, Windows folks! Check out - [`nvm-windows`](https://github.com/coreybutler/nvm-windows) - ([@ArtskydJ](https://github.com/ArtskydJ)) - -#### MORE NUMBERS! MORE VALUE! - -* [`5afa2d5`](https://github.com/npm/npm/commit/5afa2d5) - `validate-npm-package-name@2.2.2`: Documented package name rules in README - ([@zeusdeux](https://github.com/zeusdeux)) -* [`021f4d9`](https://github.com/npm/npm/commit/021f4d9) - `rimraf@2.4.1`: [#74](https://github.com/isaacs/rimraf/issues/74) Use async - function for bin (to better handle Window's `EBUSY`) - ([@isaacs](https://github.com/isaacs)) -* [`5223432`](https://github.com/npm/npm/commit/5223432) - `osenv@0.1.3`: Use `os.homedir()` polyfill for more reliable output. io.js - added the function and the polyfill does a better job than the prior solution. - ([@sindresorhus](https://github.com/sindresorhus)) -* [`8ebbc90`](https://github.com/npm/npm/commit/8ebbc90) - `npm-cache-filename@1.0.2`: Make sure different git references get different - cache folders. This should prevent `foo/bar#v1.0` and `foo/bar#master` from - sharing the same cache folder. - ([@tomekwi](https://github.com/tomekwi)) -* [`367b854`](https://github.com/npm/npm/commit/367b854) - `lru-cache@2.6.5`: Minor test/typo changes - ([@isaacs](https://github.com/isaacs)) -* [`9fcae61`](https://github.com/npm/npm/commit/9fcae61) - `glob@5.0.13`: Tiny doc change + stop firing 'match' events for ignored items. - ([@isaacs](https://github.com/isaacs)) - -#### OH AND ONE MORE THING - -* [`7827249`](https://github.com/npm/npm/commit/7827249) - `PeerDependencies` errors now include the package version. - ([@NickHeiner](https://github.com/NickHeiner)) - -### v2.12.1 (2015-06-25): - -#### HEY WHERE DID EVERYBODY GO - -I keep [hearing some commotion](https://github.com/npm/npm/releases/tag/v3.0.0). -Is there something going on? Like, a party or something? Anyway, here's a small -release with at least two significant bug fixes, at least one of which some of -you have been waiting for for quite a while. - -#### REMEMBER WHEN I SAID "REMEMBER WHEN I SAID THAT THING ABOUT PERMISSIONS?"? - -`npm@2.12.0` has a change that introduces a fix for a permissions problem -whereby the `_locks` directory in the cache directory can up being owned by -root. The fix in 2.12.0 takes care of that problem, but introduces a new -problem for Windows users where npm tries to call `process.getuid()`, which -doesn't exist on Windows. It was easy enough to fix (but more or less -impossible to test, thanks to all the external dependencies involved with -permissions and platforms and whatnot), but as a result, Windows users might -want to skip `npm@2.12.0` and go straight to `npm@2.12.1`. Sorry about that! - -* [`7e5da23`](https://github.com/npm/npm/commit/7e5da238ee869201fdb9027c27b79b0f76b440a8) - When using the new, "fixed" cache directory creator, be extra-careful to not - call `process.getuid()` on platforms that lack it. - ([@othiym23](https://github.com/othiym23)) - -#### WHEW! ALL DONE FIXING GIT FOREVER! - -New npm CLI team hero [@zkat](https://github.com/zkat) has finally (FINALLY) -fixed the regression somebody (hi!) introduced a couple months ago whereby git -URLs of the format `git+ssh://user@githost.com:org/repo.git` suddenly stopped -working, and also started being saved (and cached) incorrectly. I am 100% sure -there are absolutely no more bugs in the git caching code at all ever. Mm hm. -Yep. Pretty sure. Maybe. Hmm... I hope. - -*Sighs audibly.* - -[Let us know](http://github.com/npm/npm/issues/new) if we broke something else -with this fix. - -* [`94ca4a7`](https://github.com/npm/npm/commit/94ca4a711619ba8e40ce3d20bc42b13cdb7611b7) - [#8031](https://github.com/npm/npm/issues/8031) Even though - `git+ssh://user@githost.com:org/repo.git` isn't a URL, treat it like one for - the purposes of npm. ([@zkat](https://github.com/zkat)) -* [`e7f56e5`](https://github.com/npm/npm/commit/e7f56e5a97fcf1c52d5c5bee71303b0126129815) - [#8031](https://github.com/npm/npm/issues/8031) `normalize-git-url@2.0.0`: - Handle git URLs (and URL-like remote refs) in a manner consistent with npm's - docs. ([@zkat](https://github.com/zkat)) - -#### YEP, THERE ARE STILL DEPENDENCY UPGRADES - -* [`679bf47`](https://github.com/npm/npm/commit/679bf4745ac2cfbb01c9ce273e189807fd04fa33) - [#40](http://github.com/npm/read-installed/issues/40) `read-installed@4.0.1`: - Handle prerelease versions in top-level dependencies not in `package.json` - without marking those packages as invalid. - ([@benjamn](https://github.com/benjamn)) -* [`3a67410`](https://github.com/npm/npm/commit/3a6741068c9119174c920496778aeee870ebdac0) - `tap@1.3.1` ([@isaacs](https://github.com/isaacs)) -* [`151904a`](https://github.com/npm/npm/commit/151904af39dc24567f8c98529a2a64a4dbcc960a) - `nopt@3.0.3` ([@isaacs](https://github.com/isaacs)) - -### v2.12.0 (2015-06-18): - -#### REMEMBER WHEN I SAID THAT THING ABOUT PERMISSIONS? - -About [a million people](https://github.com/npm/npm/issues?utf8=%E2%9C%93&q=is%3Aissue+EACCES+_locks) -have filed issues related to having a tough time using npm after they've run -npm once or twice with sudo. "Don't worry about it!" I said. "We've fixed all -those permissions problems ages ago! Use this one weird trick and you'll never -have to deal with this again!" - -Well, uh, if you run npm with root the first time you run npm on a machine, it -turns out that the directory npm uses to store lockfiles ends up being owned by -the wrong user (almost always root), and that can, well, it can cause problems -sometimes. By which I mean every time you run npm without being root it'll barf -with `EACCES` errors. Whoops! - -This is an obnoxious regression, and to prevent it from recurring, we've made -it so that the cache, cached git remotes, and the lockfile directories are all -created and maintained using the same utilty module, which not only creates the -relevant paths with the correct permissions, but will fix the permissions on -those directories (if it can) when it notices that they're broken. An `npm -install` run as root ought to be sufficient to fix things up (and if that -doesn't work, first tell us about it, and then run `sudo chown -R $(whoami) -$HOME/.npm`) - -Also, I apologize for inadvertently gaslighting any of you by claiming this bug -wasn't actually a bug. I do think we've got this permanently dealt with now, -but I'll be paying extra-close attention to permissions issues related to the -cache for a while. - -* [`85d1a53`](https://github.com/npm/npm/commit/85d1a53d7b5e0fc04823187e522ae3711ede61fa) - Set permissions on lock directory to the owner of the process. - ([@othiym23](https://github.com/othiym23)) - -#### I WENT TO NODECONF AND ALL I GOT WAS THIS LOUSY SPDX T-SHIRT - -That's not literally true. We spent very little time discussing SPDX, -[@kemitchell](https://github.com/kemitchell) is a champ, and I had a lot of fun -playing drum & bass to a mostly empty Boogie Barn and only ended up with one -moderately severe cold for my pains. Another winner of a NodeConf! (I would -probably wear a SPDX T-shirt if somebody gave me one, though.) - -A bunch of us did have a spirited discussion of the basics of open-source -intellectual property, and the convergence of me, -[@kemitchell](https://github.com/kemitchell), and -[@jandrieu](https://github.com/jandrieu) in one place allowed us to hammmer out -a small but significant issue that had been bedeviling early adopters of the -new SPDX expression syntax in `package.json` license fields: how to deal with -packages that are left without a license on purpose. - -Refer to [the docs](https://github.com/npm/npm/blob/16a3dd545b10f8a2464e2037506ce39124739b41/doc/files/package.json.md#license) -for the specifics, but the short version is that instead of using -`LicenseRef-LICENSE` for proprietary licenses, you can now use either -`UNLICENSED` if you want to make it clear that you don't _want_ your software -to be licensed (and want npm to stop warning you about this), or `SEE LICENSE -IN <filename>` if there's a license with custom text you want to use. At some -point in the near term, we'll be updating npm to verify that the mentioned -file actually exists, but for now you're all on the honor system. - -* [`4827fc7`](https://github.com/npm/npm/commit/4827fc784117c17f35dd9b51b21d1eff6094f661) - [#8557](https://github.com/npm/npm/issues/8557) - `normalize-package-data@2.2.1`: Allow `UNLICENSED` and `SEE LICENSE IN - <filename>` in "license" field of `package.json`. - ([@kemitchell](https://github.com/kemitchell)) -* [`16a3dd5`](https://github.com/npm/npm/commit/16a3dd545b10f8a2464e2037506ce39124739b41) - [#8557](https://github.com/npm/npm/issues/8557) Document the new accepted - values for the "license" field. - ([@kemitchell](https://github.com/kemitchell)) -* [`8155311`](https://github.com/npm/npm/commit/81553119350deaf199e79e38e35b52a5c8ad206c) - [#8557](https://github.com/npm/npm/issues/8557) `init-package-json@1.7.0`: - Support new "license" field values at init time. - ([@kemitchell](https://github.com/kemitchell)) - -#### SMALLISH BUG FIXES - -* [`9d8cac9`](https://github.com/npm/npm/commit/9d8cac94a258db648a2b1069b1c8c6529c79d013) - [#8548](https://github.com/npm/npm/issues/8548) Remove extraneous newline - from `npm view` output, making it easier to use in shell scripts. - ([@eush77](https://github.com/eush77)) -* [`765fd4b`](https://github.com/npm/npm/commit/765fd4bfca8ea3e2a4a399765b17eec40a3d893d) - [#8521](https://github.com/npm/npm/issues/8521) When checking for outdated - packages, or updating packages, raise an error when the registry is - unreachable instead of silently "succeeding". - ([@ryantemple](https://github.com/ryantemple)) - -#### SMALLERISH DOCUMENTATION TWEAKS - -* [`5018335`](https://github.com/npm/npm/commit/5018335ce1754a9f771954ecbc1a93acde9b8c0a) - [#8365](https://github.com/npm/npm/issues/8365) Add details about which git - environment variables are whitelisted by npm. - ([@nmalaguti](https://github.com/nmalaguti)) -* [`bed9edd`](https://github.com/npm/npm/commit/bed9edddfdcc6d22a80feab33b53e4ef9172ec72) - [#8554](https://github.com/npm/npm/issues/8554) Fix typo in version docs. - ([@rainyday](https://github.com/rainyday)) - -#### WELL, I GUESS THERE ARE MORE DEPENDENCY UPGRADES - -* [`7ce2f06`](https://github.com/npm/npm/commit/7ce2f06f6f34d469b1d2e248084d4f3fef10c05e) - `request@2.58.0`: Refactor tunneling logic, and use `extend` instead of - abusing `util._extend`. ([@simov](https://github.com/simov)) -* [`e6c6195`](https://github.com/npm/npm/commit/e6c61954aad42e20eec49745615c7640b2026a6c) - `nock@2.6.0`: Refined interception behavior. - ([@pgte](https://github.com/pgte)) -* [`9583cc3`](https://github.com/npm/npm/commit/9583cc3cb192c2fced006927cfba7cd37b588605) - `fstream-npm@1.0.3`: Ensure that `main` entry in `package.json` is always - included in the bundled package tarball. - ([@coderhaoxin](https://github.com/coderhaoxin)) -* [`df89493`](https://github.com/npm/npm/commit/df894930f2716adac28740b29b2e863170919990) - `fstream@1.0.7` ([@isaacs](https://github.com/isaacs)) -* [`9744049`](https://github.com/npm/npm/commit/974404934758124aa8ae5b54f7d5257c3bd6b588) - `dezalgo@1.0.3`: `dezalgo` should be usable in the browser, and can be now - that `asap` has been upgraded to be browserifiable. - ([@mvayngrib](https://github.com/mvayngrib)) - -### v2.11.3 (2015-06-11): - -This was a very quiet week. This release was done by -[@iarna](https://github.com/iarna), while the rest of the team hangs out at -NodeConf Adventure! - -#### TESTS IN 0.8 FAIL LESS - -* [`5b3b3c2`](https://github.com/npm/npm/commit/5b3b3c2) - [#8491](//github.com/npm/npm/pull/8491) - Updates a test to use only 0.8 compatible features - ([@watilde](https://github.com/watilde)) - -#### THE TREADMILL OF UPDATES NEVER CEASES - -* [`9f439da`](https://github.com/npm/npm/commit/9f439da) - `spdx@0.4.1`: License range updates - ([@kemitchell](https://github.com/kemitchell)) -* [`2dd055b`](https://github.com/npm/npm/commit/2dd055b) - `normalize-package-data@2.2.1`: Fixes a crashing bug when the package.json - `scripts` property is not an object. - ([@iarna](https://github.com/iarna)) -* [`e02e85d`](https://github.com/npm/npm/commit/e02e85d) - `osenv@0.1.2`: Switches to using the `os-tmpdir` module instead of - `os.tmpdir()` for greater consistency in behavior between node versions. - ([@iarna](https://github.com/iarna)) -* [`a6f0265`](https://github.com/npm/npm/commit/a6f0265) - `ini@1.3.4` ([@isaacs](https://github.com/isaacs)) -* [`7395977`](https://github.com/npm/npm/commit/7395977) - `rimraf@2.4.0` ([@isaacs](https://github.com/isaacs)) - -### v2.11.2 (2015-06-04): - -Another small release this week, brought to you by the latest addition to the -CLI team, [@zkat](https://github.com/zkat) (Hi, all!) - -Mostly small documentation tweaks and version updates. Oh! And `npm outdated` -is actually sorted now. Rejoice! - -It's gonna be a while before we get another palindromic version number. Enjoy it -while it lasts. :3 - -#### QUALITY OF LIFE HAS NEVER BEEN BETTER - -* [`31aada4`](https://github.com/npm/npm/commit/31aada4ccc369c0903ff7f233f464955d12c6fe2) - [#8401](https://github.com/npm/npm/issues/8401) `npm outdated` output is just - that much nicer to consume now, due to sorting by name. - ([@watilde](https://github.com/watilde)) -* [`458a919`](https://github.com/npm/npm/commit/458a91925d8b20c5e672ba71a86745aad654abaf) - [#8469](https://github.com/npm/npm/pull/8469) Explicitly set `cwd` for - `preversion`, `version`, and `postversion` scripts. This makes the scripts - findable relative to the root dir. - ([@alexkwolfe](https://github.com/alexkwolfe)) -* [`55d6d71`](https://github.com/npm/npm/commit/55d6d71562e979e745c9db88861cc39f99b9f3ec) - Ensure package name and version are included in display during `npm version` - lifecycle execution. Gets rid of those little `undefined`s in the console. - ([@othiym23](https://github.com/othiym23)) - -#### WORDS HAVE NEVER BEEN QUITE THIS READABLE - -* [`3901e49`](https://github.com/npm/npm/commit/3901e4974c800e7f9fba4a5b2ff88da1126d5ef8) - [#8462](https://github.com/npm/npm/pull/8462) English apparently requires - correspondence between indefinite articles and attached nouns. - ([@Enet4](https://github.com/Enet4)) -* [`5a744e4`](https://github.com/npm/npm/commit/5a744e4b143ef7b2f50c80a1d96fdae4204d452b) - [#8421](https://github.com/npm/npm/pull/8421) The effect of `npm prune`'s - `--production` flag and how to use it have been documented a bit better. - ([@foiseworth](https://github.com/foiseworth)) -* [`eada625`](https://github.com/npm/npm/commit/eada625993485f0a2c5324b06f02bfa0a95ce4bc) - We've updated our `.mailmap` and `AUTHORS` files to make sure credit is given - where credit is due. ([@othiym23](https://github.com/othiym23)) - -#### VERSION NUMBERS HAVE NEVER BEEN BIGGER - -* [`c929fd1`](https://github.com/npm/npm/commit/c929fd1d0604b5878ed05706447e078d3e41f5b3) - `readable-stream@1.1.13`: Manually deduped `v1.1.13` (streams3) to make - deduping more reliable on `npm@<3`. ([@othiym23](https://github.com/othiym23)) -* [`a9b4b78`](https://github.com/npm/npm/commit/a9b4b78dcc85571fd1cdd737903f7f37a5e6a755) - `request@2.57.0`: Replace dependency on IncomingMessage's `.client` with - `.socket` as the former was deprecated in io.js 2.2.0. - ([@othiym23](https://github.com/othiym23)) -* [`4b5e557`](https://github.com/npm/npm/commit/4b5e557a23cdefd521ad154111e3d4dcc81f1cdb) - `abbrev@1.0.7`: Better testing, with coverage. - ([@othiym23](https://github.com/othiym23)) -* [`561affe`](https://github.com/npm/npm/commit/561affee21df9bbea5a47298f2452f533be8f359) - `semver@4.3.6`: .npmignore added for less cruft, and better testing, with coverage. - ([@othiym23](https://github.com/othiym23)) -* [`60aef3c`](https://github.com/npm/npm/commit/60aef3cf5d84d757752db3eb8ede2cb385469e7b) - `graceful-fs@3.0.8`: io.js fixes. - ([@zkat](https://github.com/zkat)) -* [`f8bd453`](https://github.com/npm/npm/commit/f8bd453b1a1c46ba7666cb166595e8a011eae443) - `config-chain@1.1.9`: Added MIT license to package.json - ([@zkat](https://github.com/zkat)) - -### v2.11.1 (2015-05-28): - -This release brought to you from poolside at the Omni Amelia Island Resort and -JSConf 2015, which is why it's so tiny. - -#### CONFERENCE WIFI CAN'T STOP THESE BUG FIXES - -* [`cf109a6`](https://github.com/npm/npm/commit/cf109a682f38a059a994da953d5c1b4aaece5e2f) - [#8381](https://github.com/npm/npm/issues/8381) Documented a subtle gotcha - with `.npmrc`, which is that it needs to have its permissions set such that - only the owner can read or write the file. - ([@colakong](https://github.com/colakong)) -* [`180da67`](https://github.com/npm/npm/commit/180da67c9fa53103d625e2f031626c2453c7ebcd) - [#8365](https://github.com/npm/npm/issues/8365) Git 2.3 adds support for - `GIT_SSH_COMMAND`, which allows you to pass an explicit git command (with, - for example, a specific identity passed in on the command line). - ([@nmalaguti](https://github.com/nmalaguti)) - -#### MY (VIRGIN) PINA COLADA IS GETTING LOW, BETTER UPGRADE THESE DEPENDENCIES - -* [`b72de41`](https://github.com/npm/npm/commit/b72de41c5cc9f0c46d3fa8f062c75bd273641474) - `node-gyp@2.0.0`: Use a newer version of `gyp`, and generally improve support - for Visual Studios and Windows. - ([@TooTallNate](https://github.com/TooTallNate)) -* [`8edbe21`](https://github.com/npm/npm/commit/8edbe210af41e8f248f5bb92c72de92f54fda3b1) - `node-gyp@2.0.1`: Don't crash when Python's version doesn't parse as valid - semver. ([@TooTallNate](https://github.com/TooTallNate)) -* [`ba0e0a8`](https://github.com/npm/npm/commit/ba0e0a845a4f29717aba566b416a27d1a22f5d08) - `glob@5.0.10`: Add coverage to tests. ([@isaacs](https://github.com/isaacs)) -* [`7333701`](https://github.com/npm/npm/commit/7333701b5d4f01673f37d64992c63c4e15864d6d) - `request@2.56.0`: Bug fixes and dependency upgrades. - ([@simov](https://github.com/simov)) - -### v2.11.0 (2015-05-21): - -For the first time in a very long time, we've added new events to the life -cycle used by `npm run-script`. Since running `npm version (major|minor|patch)` -is typically the last thing many developers do before publishing their updated -packages, it makes sense to add life cycle hooks to run tests or otherwise -preflight the package before doing a full publish. Thanks, as always, to the -indefatigable [@watilde](https://github.com/watilde) for yet another great -usability improvement for npm! - -#### FEATURELETS - -* [`b07f7c7`](https://github.com/npm/npm/commit/b07f7c7c1e5021730b3c320f1b3a46e70f8a21ff) - [#7906](https://github.com/npm/npm/issues/7906) - Add new [`scripts`](https://github.com/npm/npm/blob/master/doc/misc/npm-scripts.md) to - allow you to run scripts before and after - the [`npm version`](https://github.com/npm/npm/blob/master/doc/cli/npm-version.md) - command has run. This makes it easy to, for instance, require that your - test suite passes before bumping the version by just adding `"preversion": - "npm test"` to the scripts section of your `package.json`. - ([@watilde](https://github.com/watilde)) -* [`8a46136`](https://github.com/npm/npm/commit/8a46136f42e416cbadb533bcf89d73d681ed421d) - [#8185](https://github.com/npm/npm/issues/8185) - When we get a "not found" error from the registry, we'll now check to see - if the package name you specified is invalid and if so, give you a better - error message. ([@thefourtheye](https://github.com/thefourtheye)) - -#### BUG FIXES - -* [`9bcf573`](https://github.com/npm/npm/commit/9bcf5730bd0316f210dafea898afe9103849cea9) - [#8324](https://github.com/npm/npm/pull/8324) On Windows, when you've configured a - custom `node-gyp`, run it with node itself instead of using the default open action (which - is almost never what you want). ([@bangbang93](https://github.com/bangbang93)) -* [`1da9b04`](https://github.com/npm/npm/commit/1da9b0411d3416c7fca17d08cbbcfca7ae86e92d) - [#7195](https://github.com/npm/npm/issues/7195) - [#7260](https://github.com/npm/npm/issues/7260) `npm-registry-client@6.4.0`: - (Re-)allow publication of existing mixed-case packages (part 1). - ([@smikes](https://github.com/smikes)) -* [`e926783`](https://github.com/npm/npm/commit/e9267830ab261c751f12723e84d2458ae9238646) - [#7195](https://github.com/npm/npm/issues/7195) - [#7260](https://github.com/npm/npm/issues/7260) - `normalize-package-data@2.2.0`: (Re-)allow publication of existing mixed-case - packages (part 2). ([@smikes](https://github.com/smikes)) - -#### DOCUMENTATION IMPROVEMENTS - -* [`f62ee05`](https://github.com/npm/npm/commit/f62ee05333b141539a8e851c620dd2e82ff06860) - [#8314](https://github.com/npm/npm/issues/8314) Update the README to warn - folks away from using the CLI's internal API. For the love of glob, just use a - child process to run the CLI! ([@claycarpenter](https://github.com/claycarpenter)) -* [`1093921`](https://github.com/npm/npm/commit/1093921c04db41ab46db24a170a634a4b2acd8d9) - [#8279](https://github.com/npm/npm/pull/8279) - Update the documentation to note that, yes, you can publish scoped packages to the - public registry now! ([@mantoni](https://github.com/mantoni)) -* [`f87cde5`](https://github.com/npm/npm/commit/f87cde5234a760d3e515ffdaacaed6f5b71dbf44) - [#8292](https://github.com/npm/npm/pull/8292) - Fix typo in an example and grammar in the description in - the [shrinkwrap documentation](https://github.com/npm/npm/blob/master/doc/cli/npm-shrinkwrap.md). - ([@vshih](https://github.com/vshih)) -* [`d3526ce`](https://github.com/npm/npm/commit/d3526ceb09a0c29fdb7d4124536ae09057d033e7) - Improve the formatting in - the [shrinkwrap documentation](https://github.com/npm/npm/blob/master/doc/cli/npm-shrinkwrap.md). - ([@othiym23](https://github.com/othiym23)) -* [`19fe6d2`](https://github.com/npm/npm/commit/19fe6d20883e28956ff916fe4dae42d73ee6195b) - [#8311](https://github.com/npm/npm/pull/8311) - Update [README.md](https://github.com/npm/npm#readme) to use syntax highlighting in - its code samples and bits of shell scripts. ([@SimenB](https://github.com/SimenB)) - -#### DEPENDENCY UPDATES! ALWAYS AND FOREVER! - -* [`fc52160`](https://github.com/npm/npm/commit/fc52160d0223226fffe4166f42fdfd3b899b3c1e) - [#4700](https://github.com/npm/npm/issues/4700) [#5044](https://github.com/npm/npm/issues/5044) - `init-package-json@1.6.0`: Make entering an invalid version while running `npm init` give - you an immediate error and prompt you to correct it. ([@watilde](https://github.com/watilde)) -* [`738853e`](https://github.com/npm/npm/commit/738853eb1f55636476a2a410c2c04732eec9d51e) - [#7763](https://github.com/npm/npm/issues/7763) `fs-write-stream-atomic@1.0.3`: Fix a bug - where errors would not propagate, making error messages unhelpful. - ([@iarna](https://github.com/iarna)) -* [`6d74a2d`](https://github.com/npm/npm/commit/6d74a2d2ac7f92750cf6a2cfafae1af23b569098) - `npm-package-arg@4.0.1`: Fix tests on windows ([@Bacra](https://github.com)) and with - more recent `hosted-git-info`. ([@iarna](https://github.com/iarna)) -* [`50f7178`](https://github.com/npm/npm/commit/50f717852fbf713ef6cbc4e0a9ab42657decbbbd) - `hosted-git-info@2.1.4`: Correct spelling in its documentation. - ([@iarna](https://github.com/iarna)) -* [`d7956ca`](https://github.com/npm/npm/commit/d7956ca17c057d5383ff0d3fc5cf6ac2940b034d) - `glob@5.0.7`: Fix a bug where unusual error conditions could make - further use of the module fail. ([@isaacs](https://github.com/isaacs)) -* [`44f7d74`](https://github.com/npm/npm/commit/44f7d74c5d3181d37da7ea7949c86b344153f8d9) - `tap@1.1.0`: Update to the most recent tap to get a whole host of bug - fixes and integration with [coveralls](https://coveralls.io/). - ([@isaacs](https://github.com/isaacs)) -* [`c21e8a8`](https://github.com/npm/npm/commit/c21e8a8d94bcf0ad79dc583ddc53f8366d4813b3) - `nock@2.2.0` ([@othiym23](https://github.com/othiym23)) - -#### LICENSE FILES FOR THE LICENSE GOD - -* Add missing ISC license file to package ([@kasicka](https://github.com/kasicka)): - * [`aa9908c`](https://github.com/npm/npm/commit/aa9908c20017729673b9d410b77f9a16b7aae8a4) `realize-package-specifier@3.0.1` - * [`23a3b1a`](https://github.com/npm/npm/commit/23a3b1a726b9176c70ce0ccf3cd9d25c54429bdf) `fs-vacuum@1.2.6` - * [`8e04bba`](https://github.com/npm/npm/commit/8e04bba830d4353d84751d21803cd127c96153a7) `dezalgo@1.0.2` - * [`50f7178`](https://github.com/npm/npm/commit/50f717852fbf713ef6cbc4e0a9ab42657decbbbd) `hosted-git-info@2.1.4` - * [`6a54917`](https://github.com/npm/npm/commit/6a54917fbd4df995495a95d4b548defd44b77c93) `write-file-atomic@1.1.2` - * [`971f92c`](https://github.com/npm/npm/commit/971f92c4a4e5514217d1e4db45d1ccf71a60ff19) `async-some@1.0.2` - * [`67b50b7`](https://github.com/npm/npm/commit/67b50b7667a42bb3340a660eb2e617e1a554d2d4) `normalize-git-url@1.0.1` - -#### SPDX LICENSE UPDATES - -* Switch license to - [BSD-2-Clause](http://spdx.org/licenses/BSD-2-Clause.html#licenseText) from - plain "BSD" ([@isaacs](https://github.com/isaacs)): - * [`efdb733`](https://github.com/npm/npm/commit/efdb73332eeedcad4c609796929070b62abb37ab) `npm-user-validate@0.1.2` - * [`e926783`](https://github.com/npm/npm/commit/e9267830ab261c751f12723e84d2458ae9238646) `normalize-package-data@2.2.0` -* Switch license to [ISC](http://spdx.org/licenses/ISC.html#licenseText) from - [BSD](http://spdx.org/licenses/BSD-2-Clause.html#licenseText) - ([@isaacs](https://github.com/isaacs)): - * [`c300956`](https://github.com/npm/npm/commit/c3009565a964f0ead4ac4ab234b1a458e2365f17) `block-stream@0.0.8` - * [`1de1253`](https://github.com/npm/npm/commit/1de125355765fecd31e682ed0ff9d2edbeac0bb0) `lockfile@1.0.1` - * [`0d5698a`](https://github.com/npm/npm/commit/0d5698ab132e376c7aec93ae357c274932116220) `osenv@0.1.1` - * [`2e84921`](https://github.com/npm/npm/commit/2e84921474e1ffb18de9fce4616e73171fa8046d) `abbrev@1.0.6` - * [`872fac9`](https://github.com/npm/npm/commit/872fac9d10c11607e4d0348c08a683b84e64d30b) `chmodr@0.1.1` - * [`01eb7f6`](https://github.com/npm/npm/commit/01eb7f60acba584346ad8aae846657899f3b6887) `chownr@0.0.2` - * [`294336f`](https://github.com/npm/npm/commit/294336f0f31c7b9fe31a50075ed750db6db134d1) `read@1.0.6` - * [`ebdf6a1`](https://github.com/npm/npm/commit/ebdf6a14d17962cdb7128402c53b452f91d44ca7) `graceful-fs@3.0.7` -* Switch license to [ISC](http://spdx.org/licenses/ISC.html#licenseText) from - [MIT](http://spdx.org/licenses/MIT.html#licenseText) - ([@isaacs](https://github.com/isaacs)): - * [`e5d237f`](https://github.com/npm/npm/commit/e5d237fc0f436dd2a89437ebf8a9632a2e35ccbe) `nopt@3.0.2` - * [`79fef14`](https://github.com/npm/npm/commit/79fef1421b78f044980f0d1bf0e97039b6992710) `rimraf@2.3.4` - * [`22527da`](https://github.com/npm/npm/commit/22527da4816e7c2746cdc0317c5fb4a85152d554) `minimatch@2.0.8` - * [`882ac87`](https://github.com/npm/npm/commit/882ac87a6c4123ca985d7ad4394ea5085e5b0ef5) `lru-cache@2.6.4` - * [`9d9d015`](https://github.com/npm/npm/commit/9d9d015a2e972f68664dda54fbb204db28b21ede) `npmlog@1.2.1` - -### v2.10.1 (2015-05-14): - -#### BUG FIXES & DOCUMENTATION TWEAKS - -* [`dc77520`](https://github.com/npm/npm/commit/dc7752013ffce13a3d3f13e518a0052c22fc1158) - When getting back a 404 from a request to a private registry that uses a - registry path that extends past the root - (`http://registry.enterprise.co/path/to/registry`), display the name of the - nonexistent package, rather than the first element in the registry API path. - Sorry, Artifactory users! ([@hayes](https://github.com/hayes)) -* [`f70dea9`](https://github.com/npm/npm/commit/f70dea9b4766f6eaa55012c3e8087e9cb04fd4ce) - Make clearer that `--registry` can be used on a per-publish basis to push a - package to a non-default registry. ([@mischkl](https://github.com/mischkl)) -* [`a3e26f5`](https://github.com/npm/npm/commit/a3e26f5b4465991a941a325468ab7725670d2a94) - Did you know that GitHub shortcuts can have commit-ishes included - (`org/repo#branch`)? They can! ([@iarna](https://github.com/iarna)) -* [`0e2c091`](https://github.com/npm/npm/commit/0e2c091a539b61fdc60423b6bbaaf30c24e4b1b8) - Some errors from `readPackage` were being swallowed, potentially leading to - invalid package trees on disk. ([@smikes](https://github.com/smikes)) - -#### DEPENDENCY UPDATES! STILL! MORE! AGAIN! - -* [`0b901ad`](https://github.com/npm/npm/commit/0b901ad0811d84dda6ca0755a9adc8d47825edd0) - `lru-cache@2.6.3`: Removed some cruft from the published package. - ([@isaacs](https://github.com/isaacs)) -* [`d713e0b`](https://github.com/npm/npm/commit/d713e0b14930c563e3fdb6ac6323bae2a8924652) - `mkdirp@0.5.1`: Made compliant with `standard`, dropped support for Node 0.6, - added (Travis) support for Node 0.12 and io.js. - ([@isaacs](https://github.com/isaacs)) -* [`a2d6578`](https://github.com/npm/npm/commit/a2d6578b6554c5c9d48fe2006751759f4da57520) - `glob@1.0.3`: Updated to use `tap@1`. ([@isaacs](https://github.com/isaacs)) -* [`64cd1a5`](https://github.com/npm/npm/commit/64cd1a570aaa5f24ccba190948ec9456297c97f5) - `fstream@ 1.0.6`: Made compliant with [`standard`](http://npm.im/standard) - (done by [@othiym23](https://github.com/othiym23), and then debugged and - fixed by [@iarna](https://github.com/iarna)), and license changed to ISC. - ([@othiym23](https://github.com/othiym23) / - [@iarna](https://github.com/iarna)) -* [`b527a7c`](https://github.com/npm/npm/commit/b527a7c2ba3c4002f443dd2c536ff4ff41a38b86) - `which@1.1.1`: Callers can pass in their own `PATH` instead of relying on - `process.env`. ([@isaacs](https://github.com/isaacs)) - -### v2.10.0 (2015-05-8): - -#### THE IMPLICATIONS ARE MORE PROFOUND THAN THEY APPEAR - -If you've done much development in The Enterprise®™, you know that keeping -track of software licenses is far more important than one might expect / hope / -fear. Tracking licenses is a hassle, and while many (if not most) of us have -(reluctantly) gotten around to setting a license to use by default with all our -new projects (even if it's just WTFPL), that's about as far as most of us think -about it. In big enterprise shops, ensuring that projects don't inadvertently -use software with unacceptably encumbered licenses is serious business, and -developers spend a surprising (and appalling) amount of time ensuring that -licensing is covered by writing automated checkers and other license auditing -tools. - -The Linux Foundation has been working on a machine-parseable syntax for license -expressions in the form of [SPDX](https://spdx.org/), an appropriately -enterprisey acronym. IP attorney and JavaScript culture hero [Kyle -Mitchell](http://kemitchell.com/) has put a considerable amount of effort into -bringing SPDX to JavaScript and Node. He's written -[`spdx.js`](https://github.com/kemitchell/spdx.js), a JavaScript SPDX -expression parser, and has integrated it into npm in a few different ways. - -For you as a user of npm, this means: - -* npm now has proper support for dual licensing in `package.json`, due to - SPDX's compound expression syntax. Run `npm help package.json` for details. -* npm will warn you if the `package.json` for your project is either missing a - `"license"` field, or if the value of that field isn't a valid SPDX - expression (pro tip: `"BSD"` becomes `"BSD-2-Clause"` in SPDX (unless you - really want one of its variants); `"MIT"` and `"ISC"` are fine as-is; the - [full list](https://github.com/shinnn/spdx-license-ids/blob/master/spdx-license-ids.json) - is its own package). -* `npm init` now demands that you use a valid SPDX expression when using it - interactively (pro tip: I mostly use `npm init -y`, having previously run - `npm config set init.license=MIT` / `npm config set init.author.email=foo` / - `npm config set init.author.name=me`). -* The documentation for `package.json` has been updated to tell you how to use - the `"license"` field properly with SPDX. - -In general, this shouldn't be a big deal for anybody other than people trying -to run their own automated license validators, but in the long run, if -everybody switches to this format, many people's lives will be made much -simpler. I think this is an important improvement for npm and am very thankful -to Kyle for taking the lead on this. Also, even if you think all of this is -completely stupid, just [choose a license](http://en.wikipedia.org/wiki/License-free_software) -anyway. Future you will thank past you someday, unless you are -[djb](http://cr.yp.to/), in which case you are djb, and more power to you. - -* [`8669f7d`](https://github.com/npm/npm/commit/8669f7d88c472ccdd60e140106ac43cca636a648) - [#8179](https://github.com/npm/npm/issues/8179) Document how to use SPDX in - `license` stanzas in `package.json`, including how to migrate from old busted - license declaration arrays to fancy new compound-license clauses. - ([@kemitchell](https://github.com/kemitchell)) -* [`98ad98c`](https://github.com/npm/npm/commit/98ad98cb11f3d3ba29a488ef1ab050b066d9c7f6) - [#8197](https://github.com/npm/npm/issues/8197) `init-package-json@1.5.0` - Ensure that packages bootstrapped with `npm init` use an SPDX-compliant - license expression. ([@kemitchell](https://github.com/kemitchell)) -* [`2ad3905`](https://github.com/npm/npm/commit/2ad3905e9139b0be2b22accf707b814469de813e) - [#8197](https://github.com/npm/npm/issues/8197) - `normalize-package-data@2.1.0`: Warn when a package is missing a license - declaration, or using a license expression that isn't valid SPDX. - ([@kemitchell](https://github.com/kemitchell)) -* [`127bb73`](https://github.com/npm/npm/commit/127bb73ccccc59a1267851c702d8ebd3f3a97e81) - [#8197](https://github.com/npm/npm/issues/8197) `tar@2.1.1`: Switch from - `BSD` to `ISC` for license, where the latter is valid SPDX. - ([@othiym23](https://github.com/othiym23)) -* [`e9a933a`](https://github.com/npm/npm/commit/e9a933a9148180d9d799f99f4154f5110ff2cace) - [#8197](https://github.com/npm/npm/issues/8197) `once@1.3.2`: Switch from - `BSD` to `ISC` for license, where the latter is valid SPDX. - ([@othiym23](https://github.com/othiym23)) -* [`412401f`](https://github.com/npm/npm/commit/412401fb6a19b18f3e02d97a24d4dafed650c186) - [#8197](https://github.com/npm/npm/issues/8197) `semver@4.3.4`: Switch from - `BSD` to `ISC` for license, where the latter is valid SPDX. - ([@othiym23](https://github.com/othiym23)) - -As a corollary to the previous changes, I've put some work into making `npm -install` spew out fewer pointless warnings about missing values in transitive -dependencies. From now on, npm will only warn you about missing READMEs, -license fields, and the like for top-level projects (including packages you -directly install into your application, but we may relax that eventually). - -Practically _nobody_ liked having those warnings displayed for child -dependencies, for the simple reason that there was very little that anybody -could _do_ about those warnings, unless they happened to be the maintainers of -those dependencies themselves. Since many, many projects don't have -SPDX-compliant licenses, the number of warnings reached a level where they ran -the risk of turning into a block of visual noise that developers (read: me, and -probably you) would ignore forever. - -So I fixed it. If you still want to see the messages about child dependencies, -they're still there, but have been pushed down a logging level to `info`. You -can display them by running `npm install -d` or `npm install --loglevel=info`. - -* [`eb18245`](https://github.com/npm/npm/commit/eb18245f55fb4cd62a36867744bcd1b7be0a33e2) - Only warn on normalization errors for top-level dependencies. Transitive - dependency validation warnings are logged at `info` level. - ([@othiym23](https://github.com/othiym23)) - -#### BUG FIXES - -* [`e40e809`](https://github.com/npm/npm/commit/e40e8095d2bc9fa4eb8f01aa22067e0068fa8a54) - `tap@1.0.1`: TAP: The Next Generation. Fix up many tests to they work - properly with the new major version of `node-tap`. Look at all the colors! - ([@isaacs](https://github.com/isaacs)) -* [`f9314e9`](https://github.com/npm/npm/commit/f9314e97d26532c0ef2b03e98f3ed300b7cd5026) - `nock@1.9.0`: Minor tweaks and bug fixes. ([@pgte](https://github.com/pgte)) -* [`45c2b1a`](https://github.com/npm/npm/commit/45c2b1aaa051733fa352074994ae6e569fd51e8b) - [#8187](https://github.com/npm/npm/issues/8187) `npm ls` wasn't properly - recognizing dependencies installed from GitHub repositories as git - dependencies, and so wasn't displaying them as such. - ([@zornme](https://github.com/zornme)) -* [`1ab57c3`](https://github.com/npm/npm/commit/1ab57c38116c0403965c92bf60121f0f251433e4) - In some cases, `npm help` was using something that looked like a regular - expression where a glob pattern should be used, and vice versa. - ([@isaacs](https://github.com/isaacs)) - -### v2.9.1 (2015-04-30): - -#### WOW! MORE GIT FIXES! YOU LOVE THOSE! - -The first item below is actually a pretty big deal, as it fixes (with a -one-word change and a much, much longer test case (thanks again, -[@iarna](https://github.com/iarna))) a regression that's been around for months -now. If you're depending on multiple branches of a single git dependency in a -single project, you probably want to check out `npm@2.9.1` and verify that -things (again?) work correctly in your project. - -* [`178a6ad`](https://github.com/npm/npm/commit/178a6ad540215820d16217465a5f220d8c95a313) - [#7202](https://github.com/npm/npm/issues/7202) When caching git - dependencies, do so by the whole URL, including the branch name, so that if a - single application depends on multiple branches from the same repository (in - practice, multiple version tags), every install is of the correct version, - instead of reusing whichever branch the caching process happened to check out - first. ([@iarna](https://github.com/iarna)) -* [`63b79cc`](https://github.com/npm/npm/commit/63b79ccde092a9cb3b1f34abe43e1d2ba69c0dbf) - [#8084](https://github.com/npm/npm/issues/8084) Ensure that Bitbucket, - GitHub, and Gitlab dependencies are installed the same way as non-hosted git - dependencies, fixing `npm install --link`. - ([@laiso](https://github.com/laiso)) - -#### DOCUMENTATION FIXES AND TWEAKS - -These changes may seem simple and small (except Lin's fix to the package name -restrictions, which was more an egregious oversight on our part), but cleaner -documentation makes npm significantly more pleasant to use. I really appreciate -all the typo fixes, clarifications, and formatting tweaks people send us, and -am delighted that we get so many of these pull requests. Thanks, everybody! - -* [`ca478dc`](https://github.com/npm/npm/commit/ca478dcaa29b8f07cd6fe515a3c4518166819291) - [#8137](https://github.com/npm/npm/issues/8137) Somehow, we had failed to - clearly document the full restrictions on package names. - [@linclark](https://github.com/linclark) has now fixed that, although we will - take with us to our graves the reasons why the maximum package name length is 214 - characters (well, OK, it was that that was the longest name in the registry - when we decided to put a cap on the name length). - ([@linclark](https://github.com/linclark)) -* [`b574076`](https://github.com/npm/npm/commit/b5740767c320c1eff3576a8d63952534a0fbb936) - [#8079](https://github.com/npm/npm/issues/8079) Make the `npm shrinkwrap` - documentation use code formatting for examples consistently. It would be - great to do this for more commands HINT HINT. - ([@RichardLitt](https://github.com/RichardLitt)) -* [`1ff636e`](https://github.com/npm/npm/commit/1ff636e2db3852a53e38c866fed7eafdacd307fc) - [#8105](https://github.com/npm/npm/issues/8105) Document that the global - `npmrc` goes in `$PREFIX/etc/npmrc`, instead of `$PREFIX/npmrc`. - ([@anttti](https://github.com/anttti)) -* [`c3f2f7c`](https://github.com/npm/npm/commit/c3f2f7c299342e1c1eccc55a976a63c607f51621) - [#8127](https://github.com/npm/npm/issues/8127) Document how to use `npm run - build` directly (hint: it's different from `npm build`!). - ([@mikemaccana](https://github.com/mikemaccana)) -* [`873e467`](https://github.com/npm/npm/commit/873e46757e1986761b15353f94580a071adcb383) - [#8069](https://github.com/npm/npm/issues/8069) Take the old, dead npm - mailing list address out of `package.json`. It seems that people don't have - much trouble figuring out how to report errors to npm. - ([@robertkowalski](https://github.com/robertkowalski)) - -#### ENROBUSTIFICATIONMENT - -* [`5abfc9c`](https://github.com/npm/npm/commit/5abfc9c9017da714e47a3aece750836b4f9af6a9) - [#7973](https://github.com/npm/npm/issues/7973) `npm run-script` completion - will only suggest run scripts, instead of including dependencies. If for some - reason you still wanted it to suggest dependencies, let us know. - ([@mantoni](https://github.com/mantoni)) -* [`4b564f0`](https://github.com/npm/npm/commit/4b564f0ce979dc74c09604f4d46fd25a2ee63804) - [#8081](https://github.com/npm/npm/issues/8081) Use `osenv` to parse the - environment's `PATH` in a platform-neutral way. - ([@watilde](https://github.com/watilde)) -* [`a4b6238`](https://github.com/npm/npm/commit/a4b62387b41848818973eeed056fd5c6570274f3) - [#8094](https://github.com/npm/npm/issues/8094) When we refactored the - configuration code to split out checking for IPv4 local addresses, we - inadvertently completely broke it by failing to return the values. In - addition, just the call to `os.getInterfaces()` could throw on systems where - querying the network configuration requires elevated privileges (e.g. Amazon - Lambda). Add the return, and trap errors so they don't cause npm to explode. - Thanks to [@mhart](https://github.com/mhart) for bringing this to our - attention! ([@othiym23](https://github.com/othiym23)) - -#### DEPENDENCY UPDATES WAIT FOR NO SOPHONT - -* [`000cd8b`](https://github.com/npm/npm/commit/000cd8b52104942ac3404f0ad0651d82f573da37) - `rimraf@2.3.3`: More informative assertions on argument validation failure. - ([@isaacs](https://github.com/isaacs)) -* [`530a2e3`](https://github.com/npm/npm/commit/530a2e369128270f3e098f0e9be061533003b0eb) - `lru-cache@2.6.2`: Revert to old key access-time behavior, as it was correct - all along. ([@isaacs](https://github.com/isaacs)) -* [`d88958c`](https://github.com/npm/npm/commit/d88958ca02ce81b027b9919aec539d0145875a59) - `minimatch@2.0.7`: Feature detection and test improvements. - ([@isaacs](https://github.com/isaacs)) -* [`3fa39e4`](https://github.com/npm/npm/commit/3fa39e4d492609d5d045033896dcd99f7b875329) - `nock@1.7.1` ([@pgte](https://github.com/pgte)) - -### v2.9.0 (2015-04-23): - -This week was kind of a breather to concentrate on fixing up the tests on the -`multi-stage` branch, and not mess with git issues for a little while. -Unfortunately, There are now enough severe git issues that we'll probably have -to spend another couple weeks tackling them. In the meantime, enjoy these two -small features. They're just enough to qualify for a semver-minor bump: - -#### NANOFEATURES - -* [`2799322`](https://github.com/npm/npm/commit/279932298ce5b589c5eea9439ac40b88b99c6a4a) - [#7426](https://github.com/npm/npm/issues/7426) Include local modules in `npm - outdated` and `npm update`. ([@ArnaudRinquin](https://github.com/ArnaudRinquin)) -* [`2114862`](https://github.com/npm/npm/commit/21148620fa03a582f4ec436bb16bd472664f2737) - [#8014](https://github.com/npm/npm/issues/8014) The prefix used before the - version on version tags is now configurable via `tag-version-prefix`. Be - careful with this one and read the docs before using it. - ([@kkragenbrink](https://github.com/kkragenbrink)) - -#### OTHER MINOR TWEAKS - -* [`18ce0ec`](https://github.com/npm/npm/commit/18ce0ecd2d94ad3af01e997f1396515892dd363c) - [#3032](https://github.com/npm/npm/issues/3032) `npm unpublish` will now use - the registry set in `package.json`, just like `npm publish`. This only - applies, for now, when unpublishing the entire package, as unpublishing a - single version requires the name be included on the command line and - therefore doesn't read from `package.json`. ([@watilde](https://github.com/watilde)) -* [`9ad2100`](https://github.com/npm/npm/commit/9ad210042242e51d52b2a8b633d8e59248f5faa4) - [#8008](https://github.com/npm/npm/issues/8008) Once again, when considering - what to install on `npm install`, include `devDependencies`. - ([@smikes](https://github.com/smikes)) -* [`5466260`](https://github.com/npm/npm/commit/546626059909dca1906454e820ca4e315c1795bd) - [#8003](https://github.com/npm/npm/issues/8003) Clarify the documentation - around scopes to make it easier to understand how they support private - packages. ([@smikes](https://github.com/smikes)) - -#### DEPENDENCIES WILL NOT STOP UNTIL YOU ARE VERY SLEEPY - -* [`faf65a7`](https://github.com/npm/npm/commit/faf65a7bbb2fad13216f64ed8f1243bafe743f97) - `init-package-json@1.4.2`: If there are multiple validation errors and - warnings, ensure they all get displayed (includes a rad new way of testing - `init-package-json` contributed by - [@michaelnisi](https://github.com/michaelnisi)). - ([@MisumiRize](https://github.com/MisumiRize)) -* [`7f10f38`](https://github.com/npm/npm/commit/7f10f38d29a8423d7cde8103fa7b64ac728da1e0) - `editor@1.0.0`: `1.0.0` is literally more than `0.1.0` (no change aside from - version number). ([@substack](https://github.com/substack)) -* [`4979af3`](https://github.com/npm/npm/commit/4979af3fcae5a3962383b7fdad3162381e62eefe) - [#6805](https://github.com/npm/npm/issues/6805) `npm-registry-client@6.3.3`: - Decode scoped package names sent by the registry so they look nicer. - ([@mmalecki](https://github.com/mmalecki)) - -### v2.8.4 (2015-04-16): - -This is the fourth release of npm this week, so it's mostly just landing a few -small outstanding PRs on dependencies and some tiny documentation tweaks. -`npm@2.8.3` is where the real action is. - -* [`ee2bd77`](https://github.com/npm/npm/commit/ee2bd77f3c64d38735d1d31028224a5c40422a9b) - [#7983](https://github.com/npm/npm/issues/7983) `tar@2.1.0`: Better error - reporting in corrupted tar files, and add support for the `fromBase` flag - (rescued from the dustbin of history by - [@deanmarano](https://github.com/deanmarano)). - ([@othiym23](https://github.com/othiym23)) -* [`d8eee6c`](https://github.com/npm/npm/commit/d8eee6cf9d2ff7aca68dfaed2de76824a3e0d9af) - `init-package-json@1.4.1`: Add support for a default author, and only add - scope to a package name once. ([@othiym23](https://github.com/othiym23)) -* [`4fc5d98`](https://github.com/npm/npm/commit/4fc5d98b785f601c60d4dc0a2c8674f0cccf6262) - `lru-cache@2.6.1`: Small tweaks to cache value aging and entry counting that - are irrelevant to npm. ([@isaacs](https://github.com/isaacs)) -* [`1fe5840`](https://github.com/npm/npm/commit/1fe584089f5bef133de5518aa26eaf6064be2bf7) - [#7946](https://github.com/npm/npm/issues/7946) Make `npm init` text - friendlier. ([@sandfox](https://github.com/sandfox)) - -### v2.8.3 (2015-04-15): - -#### TWO SMALL GIT TWEAKS - -This is the last of a set of releases intended to ensure npm's git support is -robust enough that we can stop working on it for a while. These fixes are -small, but prevent a common crasher and clear up one of the more confusing -error messages coming out of npm when working with repositories hosted on git. - -* [`387f889`](https://github.com/npm/npm/commit/387f889c0e8fb617d9cc9a42ed0a3ec49424ab5d) - [#7961](https://github.com/npm/npm/issues/7961) Ensure that hosted git SSH - URLs always have a valid protocol when stored in `resolved` fields in - `npm-shrinkwrap.json`. ([@othiym23](https://github.com/othiym23)) -* [`394c2f5`](https://github.com/npm/npm/commit/394c2f5a1227232c0baf42fbba1402aafe0d6ffb) - Switch the order in which hosted Git providers are checked to `git:`, - `git+https:`, then `git+ssh:` (from `git:`, `git+ssh:`, then `git+https:`) in - an effort to go from most to least likely to succeed, to make for less - confusing error message. ([@othiym23](https://github.com/othiym23)) - -### v2.8.2 (2015-04-14): - -#### PEACE IN OUR TIME - -npm has been having an issue with CouchDB's web server since the release -of io.js and Node.js 0.12.0 that has consumed a huge amount of my time -to little visible effect. Sam Mikes picked up the thread from me, and -after a [_lot_ of effort](https://github.com/npm/npm/issues/7699#issuecomment-93091111) -figured out that ultimately there are probably a couple problems with -the new HTTP Agent keep-alive handling in new versions of Node. In -addition, `npm-registry-client` was gratuitously sending a body along -with a GET request which was triggering the bugs. Sam removed about 10 bytes from -one file in `npm-registry-client`, and this problem, which has been bugging us for months, -completely went away. - -In conclusion, Sam Mikes is great, and anybody using a private registry -hosted on CouchDB should thank him for his hard work. Also, thanks to -the community at large for pitching in on this bug, which has been -around for months now. - -* [`431c3bf`](https://github.com/npm/npm/commit/431c3bf6cdec50f9f0c735f478cb2f3f337d3313) - [#7699](https://github.com/npm/npm/issues/7699) `npm-registry-client@6.3.2`: - Don't send body with HTTP GET requests when logging in. - ([@smikes](https://github.com/smikes)) - -### v2.8.1 (2015-04-12): - -#### CORRECTION: NPM'S GIT INTEGRATION IS DOING OKAY - -A [helpful bug report](https://github.com/npm/npm/issues/7872#issuecomment-91809553) -led to another round of changes to -[`hosted-git-info`](https://github.com/npm/hosted-git-info/commit/827163c74531b69985d1ede7abced4861e7b0cd4), -some additional test-writing, and a bunch of hands-on testing against actual -private repositories. While the complexity of npm's git dependency handling is -nearly fractal (because npm is very complex, and git is even more complex), -it's feeling way more solid than it has for a while. We think this is a -substantial improvement over what we had before, so give `npm@2.8.1` a shot if -you have particularly complex git use cases and -[let us know](https://github.com/npm/npm/issues/new) how it goes. - -(NOTE: These changes mostly affect cloning and saving references to packages -hosted in git repositories, and don't address some known issues with things -like lifecycle scripts not being run on npm dependencies. Work continues on -other issues that affect parity between git and npm registry packages.) - -* [`66377c6`](https://github.com/npm/npm/commit/66377c6ece2cf4d53d9a618b7d9824e1452bc293) - [#7872](https://github.com/npm/npm/issues/7872) `hosted-git-info@2.1.2`: Pass - through credentials embedded in SSH and HTTPs git URLs. - ([@othiym23](https://github.com/othiym23)) -* [`15efe12`](https://github.com/npm/npm/commit/15efe124753257728a0ddc64074fa5a4b9c2eb30) - [#7872](https://github.com/npm/npm/issues/7872) Use the new version of - `hosted-git-info` to pass along credentials embedded in git URLs. Test it. - Test it a lot. ([@othiym23](https://github.com/othiym23)) - -#### SCOPED DEPENDENCIES AND PEER DEPENDENCIES: NOT QUITE REESE'S - -Big thanks to [@ewie](https://github.com/ewie) for identifying an issue with -how npm was handling `peerDependencies` that were implicitly installed from the -`package.json` files of scoped dependencies. This -[will be a moot point](https://github.com/npm/npm/issues/6565#issuecomment-74971689) -with the release of `npm@3`, but until then, it's important that -`peerDependency` auto-installation work as expected. - -* [`b027319`](https://github.com/npm/npm/commit/b0273190c71eba14395ddfdd1d9f7ba625297523) - [#7920](https://github.com/npm/npm/issues/7920) Scoped packages with - `peerDependencies` were installing the `peerDependencies` into the wrong - directory. ([@ewie](https://github.com/ewie)) -* [`649e31a`](https://github.com/npm/npm/commit/649e31ae4fd02568bae5dc6b4ea783431ce3d63e) - [#7920](https://github.com/npm/npm/issues/7920) Test `peerDependency` - installs involving scoped packages using `npm-package-arg` instead of simple - path tests, for consistency. ([@othiym23](https://github.com/othiym23)) - -#### MAKING IT EASIER TO WRITE NPM TESTS, VERSION 0.0.1 - -[@iarna](https://github.com/iarna) and I -([@othiym23](https://github.com/othiym23)) have been discussing a -[candidate plan](https://github.com/npm/npm/wiki/rewriting-npm's-tests:-a-plan-maybe) -for improving npm's test suite, with the goal of making it easier for new -contributors to get involved with npm by reducing the learning curve -necessary to be able to write good tests for proposed changes. This is the -first substantial piece of that effort. Here's what the commit message for -[`ed7e249`](https://github.com/npm/npm/commit/ed7e249d50444312cd266942ce3b89e1ca049bdf) -had to say about this work: - -> It's too difficult for npm contributors to figure out what the conventional -> style is for tests. Part of the problem is that the documentation in -> CONTRIBUTING.md is inadequate, but another important factor is that the tests -> themselves are written in a variety of styles. One of the most notable -> examples of this is the fact that many tests use fixture directories to store -> precooked test scenarios and package.json files. -> -> This had some negative consequences: -> -> * tests weren't idempotent -> * subtle dependencies between tests existed -> * new tests get written in this deprecated style because it's not -> obvious that the style is out of favor -> * it's hard to figure out why a lot of those directories existed, -> because they served a variety of purposes, so it was difficult to -> tell when it was safe to remove them -> -> All in all, the fixture directories were a major source of technical debt, and -> cleaning them up, while time-consuming, makes the whole test suite much more -> approachable, and makes it more likely that new tests written by outside -> contributors will follow a conventional style. To support that, all of the -> tests touched by this changed were cleaned up to pass the `standard` style -> checker. - -And here's a little extra context from a comment I left on [#7929](https://github.com/npm/npm/issues/7929): - -> One of the other things that encouraged me was looking at this -> [presentation on technical debt](http://www.slideshare.net/nnja/pycon-2015-technical-debt-the-monster-in-your-closet) -> from Pycon 2015, especially slide 53, which I interpreted in terms of -> difficulty getting new contributors to submit patches to an OSS project like -> npm. npm has a long ways to go, but I feel good about this change. - -* [`ed7e249`](https://github.com/npm/npm/commit/ed7e249d50444312cd266942ce3b89e1ca049bdf) - [#7929](https://github.com/npm/npm/issues/7929) Eliminate fixture directories - from `test/tap`, leaving each test self-contained. - ([@othiym23](https://github.com/othiym23)) -* [`4928d30`](https://github.com/npm/npm/commit/4928d30140821c63e03fffed73f8d88ebdc43710) - [#7929](https://github.com/npm/npm/issues/7929) Move fixture files from - `test/tap/*` to `test/fixtures`. ([@othiym23](https://github.com/othiym23)) -* [`e925deb`](https://github.com/npm/npm/commit/e925debca91092a814c1a00933babc3a8cf975be) - [#7929](https://github.com/npm/npm/issues/7929) Tweak the run scripts to stop - slaughtering the CPU on doc rebuild. - ([@othiym23](https://github.com/othiym23)) -* [`65bf7cf`](https://github.com/npm/npm/commit/65bf7cffaf91c426b676c47529eee796f8b8b75c) - [#7923](https://github.com/npm/npm/issues/7923) Use an alias of scripts and - run-scripts in `npm run test-all` ([@watilde](https://github.com/watilde)) -* [`756a3fb`](https://github.com/npm/npm/commit/756a3fbb852a2469afe706635ed88d22c37743e5) - [#7923](https://github.com/npm/npm/issues/7923) Sync timeout time of `npm - run-script test-all` to be the same as `test` and `tap` scripts. - ([@watilde](https://github.com/watilde)) -* [`8299b5f`](https://github.com/npm/npm/commit/8299b5fb6373354a7fbaab6f333863758812ae90) - Set a timeout for tap tests for `npm run-script test-all`. - ([@othiym23](https://github.com/othiym23)) - -#### THE EVER-BEATING DRUM OF DEPENDENCY UPDATES - -* [`d90d0b9`](https://github.com/npm/npm/commit/d90d0b992acbf62fd5d68debf9d1dbd6cfa20804) - [#7924](https://github.com/npm/npm/issues/7924) Remove `child-process-close`, - as it was included for Node 0.6 compatibility, and npm no longer supports - 0.6. ([@robertkowalski](https://github.com/robertkowalski)) -* [`16427c1`](https://github.com/npm/npm/commit/16427c1f3ea3d71ee753c62eb4c2663c7b32b84f) - `lru-cache@2.5.2`: More accurate updating of expiry times when `maxAge` is - set. ([@isaacs](https://github.com/isaacs)) -* [`03cce83`](https://github.com/npm/npm/commit/03cce83b64344a9e0fe036dce214f4d68cfcc9e7) - `nock@1.6.0`: Mocked network error handling. - ([@pgte](https://github.com/pgte)) -* [`f93b1f0`](https://github.com/npm/npm/commit/f93b1f0b7eb5d1b8a7967e837bbd756db1091d00) - `glob@5.0.5`: Use `path-is-absolute` polyfill, allowing newer Node.js and - io.js versions to use `path.isAbsolute()`. - ([@sindresorhus](https://github.com/sindresorhus)) -* [`a70d694`](https://github.com/npm/npm/commit/a70d69495a6e96997e64855d9e749d943ee6d64f) - `request@2.55.0`: Bug fixes and simplification. - ([@simov](https://github.com/simov)) -* [`2aecc6f`](https://github.com/npm/npm/commit/2aecc6f4083526feeb14615b4e5484edc66175b5) - `columnify@1.5.1`: Switch to using babel from 6to5. - ([@timoxley](https://github.com/timoxley)) - -### v2.8.0 (2015-04-09): - -#### WE WILL NEVER BE DONE FIXING NPM'S GIT SUPPORT - -If you look at [the last release's release -notes](https://github.com/npm/npm/blob/master/CHANGELOG.md#git-mean-git-tuff-git-all-the-way-away-from-my-stuff), -you will note that they confidently assert that it's perfectly OK to force all -GitHub URLs through the same `git:` -> `git+ssh:` fallback flow for cloning. It -turns out that many users depend on `git+https:` URLs in their build -environments because they use GitHub auth tokens instead of SSH keys. Also, in -some cases you just want to be able to explicitly say how a given dependency -should be cloned from GitHub. - -Because of the way we resolved the inconsistency in GitHub shorthand handling -[before](https://github.com/npm/npm/blob/master/CHANGELOG.md#bug-fixes-1), this -turned out to be difficult to work around. So instead of hacking around it, we -completely redid how git is handled within npm and its attendant packages. -Again. This time, we changed things so that `normalize-package-data` and -`read-package-json` leave more of the git logic to npm itself, which makes -handling shorthand syntax consistently much easier, and also allows users to -resume using explicit, fully-qualified git URLs without npm messing with them. - -Here's a summary of what's changed: - -* Instead of converting the GitHub shorthand syntax to a `git+ssh:`, `git:`, or - `git+https:` URL and saving that, save the shorthand itself to - `package.json`. -* If presented with shortcuts, try cloning via the git protocol, SSH, and HTTPS - (in that order). -* No longer prompt for credentials -- it didn't work right with the spinner, - and wasn't guaranteed to work anyway. We may experiment with doing this a - better way in the future. Users can override this by setting `GIT_ASKPASS` in - their environment if they want to experiment with interactive cloning, but - should also set `--no-spin` on the npm command line (or run `npm config set - spin=false`). -* **EXPERIMENTAL FEATURE**: Add support for `github:`, `gist:`, `bitbucket:`, - and `gitlab:` shorthand prefixes. GitHub shortcuts will continue to be - normalized to `org/repo` instead of being saved as `github:org/repo`, but - `gitlab:`, `gist:`, and `bitbucket:` prefixes will be used on the command - line and from `package.json`. BE CAREFUL WITH THIS. `package.json` files - published with the new shorthand syntax can _only_ be read by `npm@2.8.0` and - later, and this feature is mostly meant for playing around with it. If you - want to save git dependencies in a form that older versions of npm can read, - use `--save-exact`, which will save the git URL and resolved commit hash of - the head of the branch in a manner similar to the way that `--save-exact` - pins versions for registry dependencies. This is documented (so check `npm - help install` for details), but we're not going to make a lot of noise about - it until it has a chance to bake in a little more. - -It is [@othiym23](https://github.com/othiym23)'s sincere hope that this will -resolve all of the inconsistencies users were seeing with GitHub and git-hosted -packages, but given the level of change here, that may just be a fond wish. -Extra testing of this change is requested. - -* [`6b0f588`](https://github.com/npm/npm/commit/6b0f58877f37df9904490ffbaaad33862bd36dce) - [#7867](https://github.com/npm/npm/issues/7867) Use git shorthand and git - URLs as presented by user. Support new `hosted-git-info` shortcut syntax. - Save shorthand in `package.json`. Try cloning via `git:`, `git+ssh:`, and - `git+https:`, in that order, when supported by the underlying hosting - provider. ([@othiym23](https://github.com/othiym23)) -* [`75d4267`](https://github.com/npm/npm/commit/75d426787869d54ca7400408f562f971b34649ef) - [#7867](https://github.com/npm/npm/issues/7867) Document new GitHub, GitHub - gist, Bitbucket, and GitLab shorthand syntax. - ([@othiym23](https://github.com/othiym23)) -* [`7d92c75`](https://github.com/npm/npm/commit/7d92c7592998d90ec883fa989ca74f04ec1b93de) - [#7867](https://github.com/npm/npm/issues/7867) When `--save-exact` is used - with git shorthand or URLs, save the fully-resolved URL, with branch name - resolved to the exact hash for the commit checked out. - ([@othiym23](https://github.com/othiym23)) -* [`9220e59`](https://github.com/npm/npm/commit/9220e59f8def8c82c6d331a39ba29ad4c44e3a9b) - [#7867](https://github.com/npm/npm/issues/7867) Ensure that non-prefixed and - non-normalized GitHub shortcuts are saved to `package.json`. - ([@othiym23](https://github.com/othiym23)) -* [`dd398e9`](https://github.com/npm/npm/commit/dd398e98a8eba27eeba84378200da3d078fdf980) - [#7867](https://github.com/npm/npm/issues/7867) `hosted-git-info@2.1.1`: - Ensure that `gist:` shorthand survives being round-tripped through - `package.json`. ([@othiym23](https://github.com/othiym23)) -* [`33d1420`](https://github.com/npm/npm/commit/33d1420bf2f629332fceb2ac7e174e63ac48f96a) - [#7867](https://github.com/npm/npm/issues/7867) `hosted-git-info@2.1.0`: Add - support for auth embedded directly in git URLs. - ([@othiym23](https://github.com/othiym23)) -* [`23a1d5a`](https://github.com/npm/npm/commit/23a1d5a540e8db27f5cd0245de7c3694e2bddad1) - [#7867](https://github.com/npm/npm/issues/7867) `hosted-git-info@2.0.2`: Make - it possible to determine in which form a hosted git URL was passed. - ([@iarna](https://github.com/iarna)) -* [`eaf75ac`](https://github.com/npm/npm/commit/eaf75acb718611ad5cfb360084ec86938d9c66c5) - [#7867](https://github.com/npm/npm/issues/7867) - `normalize-package-data@2.0.0`: Normalize GitHub specifiers so they pass - through shortcut syntax and preserve explicit URLs. - ([@iarna](https://github.com/iarna)) -* [`95e0535`](https://github.com/npm/npm/commit/95e0535e365e0aca49c634dd2061a0369b0475f1) - [#7867](https://github.com/npm/npm/issues/7867) `npm-package-arg@4.0.0`: Add - git URL and shortcut to hosted git spec and use `hosted-git-info@2.0.2`. - ([@iarna](https://github.com/iarna)) -* [`a808926`](https://github.com/npm/npm/commit/a8089268d5f3d57f42dbaba02ff6437da5121191) - [#7867](https://github.com/npm/npm/issues/7867) - `realize-package-specifier@3.0.0`: Use `npm-package-arg@4.0.0` and test - shortcut specifier behavior. ([@iarna](https://github.com/iarna)) -* [`6dd1e03`](https://github.com/npm/npm/commit/6dd1e039bddf8cf5383343f91d84bc5d78acd083) - [#7867](https://github.com/npm/npm/issues/7867) `init-package-json@1.4.0`: - Allow dependency on `read-package-json@2.0.0`. - ([@iarna](https://github.com/iarna)) -* [`63254bb`](https://github.com/npm/npm/commit/63254bb6358f66752aca6aa1a275271b3ae03f7c) - [#7867](https://github.com/npm/npm/issues/7867) `read-installed@4.0.0`: Use - `read-package-json@2.0.0`. ([@iarna](https://github.com/iarna)) -* [`254b887`](https://github.com/npm/npm/commit/254b8871f5a173bb464cc5b0ace460c7878b8097) - [#7867](https://github.com/npm/npm/issues/7867) `read-package-json@2.0.0`: - Use `normalize-package-data@2.0.0`. ([@iarna](https://github.com/iarna)) -* [`0b9f8be`](https://github.com/npm/npm/commit/0b9f8be62fe5252abe54d49e36a696f4816c2eca) - [#7867](https://github.com/npm/npm/issues/7867) `npm-registry-client@6.3.0`: - Mark compatibility with `normalize-package-data@2.0.0` and - `npm-package-arg@4.0.0`. ([@iarna](https://github.com/iarna)) -* [`f40ecaa`](https://github.com/npm/npm/commit/f40ecaad68f77abc50eb6f5b224e31dec3d250fc) - [#7867](https://github.com/npm/npm/issues/7867) Extract a common method to - use when cloning git repos for testing. - ([@othiym23](https://github.com/othiym23)) - -#### TEST FIXES FOR NODE 0.8 - -npm continues to [get closer](https://github.com/npm/npm/issues/7842) to being -completely green on Travis for Node 0.8. - -* [`26d36e9`](https://github.com/npm/npm/commit/26d36e9cf0eca69fe1863d2ea536c28555b9e8de) - [#7842](https://github.com/npm/npm/issues/7842) When spawning child - processes, map exit code 127 to ENOENT so Node 0.8 handles child process - failures the same as later versions. - ([@SonicHedgehog](https://github.com/SonicHedgehog)) -* [`54cd895`](https://github.com/npm/npm/commit/54cd8956ea783f96749e46597d8c2cb9397c5d5f) - [#7842](https://github.com/npm/npm/issues/7842) Node 0.8 requires -e with -p - when evaluating snippets; fix test. - ([@SonicHedgehog](https://github.com/SonicHedgehog)) - -#### SMALL FIX AND DOC TWEAK - -* [`20e9003`](https://github.com/npm/npm/commit/20e90031b847e9f7c7168f3dad8b1e526f9a2586) - `tar@2.0.1`: Fix regression where relative symbolic links within an - extraction root that pointed within an extraction root would get normalized - to absolute symbolic links. ([@isaacs](https://github.com/isaacs)) -* [`2ef8898`](https://github.com/npm/npm/commit/2ef88989c41bee1578570bb2172c90ede129dbd1) - [#7879](https://github.com/npm/npm/issues/7879) Better document that `npm - publish --tag=foo` will not set `latest` to that version. - ([@linclark](https://github.com/linclark)) - -### v2.7.6 (2015-04-02): - -#### GIT MEAN, GIT TUFF, GIT ALL THE WAY AWAY FROM MY STUFF - -Part of the reason that we're reluctant to take patches to how npm deals with -git dependencies is that every time we touch the git support, something breaks. -The last few releases are a case in point. `npm@2.7.4` completely broke -installing private modules from GitHub, and `npm@2.7.5` fixed them at the cost -of logging a misleading error message that caused many people to believe that -their dependencies hadn't been successfully installed when they actually had -been. - -This all started from a desire to ensure that GitHub shortcut syntax is being -handled correctly. The correct behavior is for npm to try to clone all -dependencies on GitHub (whether they're specified with the GitHub -`organization/repository` shortcut syntax or not) via the plain `git:` protocol -first, and to fall back to using `git+ssh:` if `git:` doesn't work. Previously, -sometimes npm would use `git:` and `git+ssh:` in some cases (most notably when -using GitHub shortcut syntax on the command line), and use `git+https:` in -others (when the GitHub shortcut syntax was present in `package.json`). This -led to subtle and hard-to-understand inconsistencies, and we're glad that as of -`npm@2.7.6`, we've finally gotten things to where they were before we started, -only slightly more consistent overall. - -We are now going to go back to our policy of being extremely reluctant to touch -the code that handles Git dependencies. - -* [`b747593`](https://github.com/npm/npm/commit/b7475936f473f029e6a027ba1b16277523747d0b) - [#7630](https://github.com/npm/npm/issues/7630) Don't automatically log all - git failures as errors. `maybeGithub` needs to be able to fail without - logging to support its fallback logic. - ([@othiym23](https://github.com/othiym23)) -* [`cd67a0d`](https://github.com/npm/npm/commit/cd67a0db07891d20871822696c26692c8a84866a) - [#7829](https://github.com/npm/npm/issues/7829) When fetching a git remote - URL, handle failures gracefully (without assuming standard output exists). - ([@othiym23](https://github.com/othiym23)) -* [`637c7d1`](https://github.com/npm/npm/commit/637c7d1411fe07f409cf91f2e65fd70685cb253c) - [#7829](https://github.com/npm/npm/issues/7829) When fetching a git remote - URL, handle failures gracefully (without assuming standard _error_ exists). - ([@othiym23](https://github.com/othiym23)) - -#### OTHER SIGNIFICANT FIXES - -* [`78005eb`](https://github.com/npm/npm/commit/78005ebb6f4103c20f077669c3929b7ea46a4c0d) - [#7743](https://github.com/npm/npm/issues/7743) Always quote arguments passed - to `npm run-script`. This allows build systems and the like to safely escape - glob patterns passed as arguments to `run-scripts` with `npm run-script - <script> -- <arguments>`. This is a tricky change to test, and may be - reverted or moved to `npm@3` if it turns out it breaks things for users. - ([@mantoni](https://github.com/mantoni)) -* [`da015ee`](https://github.com/npm/npm/commit/da015eee45f6daf384598151d06a9b57ffce136e) - [#7074](https://github.com/npm/npm/issues/7074) `read-package-json@1.3.3`: - `read-package-json` no longer caches `package.json` files, which trades a - very small performance loss for the elimination of a large class of really - annoying race conditions. See [#7074](https://github.com/npm/npm/issues/7074) - for the grisly details. ([@othiym23](https://github.com/othiym23)) -* [`dd20f57`](https://github.com/npm/npm/commit/dd20f5755291b9433f0d298ee0eead22cda6db36) - `init-package-json@1.3.2`: Only add the `@` to scoped package names if it's - not already there when reading from the filesystem - ([@watilde](https://github.com/watilde)), and support inline validation of - package names ([@michaelnisi](https://github.com/michaelnisi)). - -#### SMALL FIXES AND DEPENDENCY UPGRADES - -* [`1f380f6`](https://github.com/npm/npm/commit/1f380f66c1e944b8ffbf096fa94d09e931626e12) - [#7820](https://github.com/npm/npm/issues/7820) `are-we-there-yet@1.0.4`: Use - `readable-stream` instead of built-in `stream` module to better support - Node.js 0.8.x. ([@SonicHedgehog](https://github.com/SonicHedgehog)) -* [`d380188`](https://github.com/npm/npm/commit/d380188e161be31f5a4f53947de6bc28df4732d8) - `semver@4.3.3`: Don't throw on `semver.parse(null)`, and parse numeric - version strings more robustly. ([@isaacs](https://github.com/isaacs)) -* [`01d9964`](https://github.com/npm/npm/commit/01d99649265f921e1c61cf406613e7042bcea008) - `nock@1.4.0`: This change may need to be rolled back, or rolled forward, - because [nock depends on - `setImmediate`](https://github.com/npm/npm/issues/7842), which causes tests - to fail when run with Node.js 0.8. ([@othiym23](https://github.com/othiym23)) -* [`91f5cb1`](https://github.com/npm/npm/commit/91f5cb1fb91520fbe25a4da5b80848ed540b9ad3) - [#7791](https://github.com/npm/npm/issues/7791) Fix brackets in npmconf so - that `loaded` is set correctly. - ([@charmander](https://github.com/charmander)) -* [`1349e27`](https://github.com/npm/npm/commit/1349e27c936a8b0fc9f6440a6d6404ef3b19c587) - [#7818](https://github.com/npm/npm/issues/7818) Update `README.md` to point - out that the install script now lives on https://www.npmjs.com. - ([@weisjohn](https://github.com/weisjohn)) - -### v2.7.5 (2015-03-26): - -#### SECURITY FIXES - -* [`300834e`](https://github.com/npm/npm/commit/300834e91a4e2a95fb7fb59c309e7c3fc91d2312) - `tar@2.0.0`: Normalize symbolic links that point to targets outside the - extraction root. This prevents packages containing symbolic links from - overwriting targets outside the expected paths for a package. Thanks to [Tim - Cuthbertson](http://gfxmonk.net/) and the team at [Lift - Security](https://liftsecurity.io/) for working with the npm team to identify - this issue. ([@othiym23](https://github.com/othiym23)) -* [`0dc6875`](https://github.com/npm/npm/commit/0dc68757cffd5397c280bc71365d106523a5a052) - `semver@4.3.2`: Package versions can be no more than 256 characters long. - This prevents a situation in which parsing the version number can use - exponentially more time and memory to parse, leading to a potential denial of - service. Thanks to Adam Baldwin at Lift Security for bringing this to our - attention. ([@isaacs](https://github.com/isaacs)) - -#### BUG FIXES - -* [`5811468`](https://github.com/npm/npm/commit/5811468e104ccb6b26b8715dff390d68daa10066) - [#7713](https://github.com/npm/npm/issues/7713) Add a test for `npm link` and - `npm link <package>`. ([@watilde](https://github.com/watilde)) -* [`3cf3b0c`](https://github.com/npm/npm/commit/3cf3b0c8fddb6b66f969969feebea85fabd0360b) - [#7713](https://github.com/npm/npm/issues/7713) Only use absolute symbolic - links when `npm link`ing. ([@hokaccha](https://github.com/hokaccha)) -* [`f35aa93`](https://github.com/npm/npm/commit/f35aa933e136228a89e3fcfdebe8c7cc4f1e7c00) - [#7443](https://github.com/npm/npm/issues/7443) Keep relative URLs when - hitting search endpoint. ([@othiym23](https://github.com/othiym23)) -* [`eab6184`](https://github.com/npm/npm/commit/eab618425c51e3aa4416da28dcd8ca4ba63aec41) - [#7766](https://github.com/npm/npm/issues/7766) One last tweak to ensure that - GitHub shortcuts work with private repositories. - ([@iarna](https://github.com/iarna)) -* [`5d7f704`](https://github.com/npm/npm/commit/5d7f704823f5f92ddd7ff3e7dd2b8bcc66c73005) - [#7656](https://github.com/npm/npm/issues/7656) Don't try to load a deleted - CA file, allowing the `cafile` config to be changed. - ([@KenanY](https://github.com/KenanY)) -* [`a840a13`](https://github.com/npm/npm/commit/a840a13bbf0330157536381ea8e58d0bd93b4c05) - [#7746](https://github.com/npm/npm/issues/7746) Only fix up URL paths when - there are paths to fix up. ([@othiym23](https://github.com/othiym23)) - -#### DEPENDENCY UPDATES - -* [`94df809`](https://github.com/npm/npm/commit/94df8095985bf5ba9d8db99dc445d05dac136aaf) - `request@2.54.0`: Fixes for Node.js 0.12 and io.js. - ([@simov](https://github.com/simov)) -* [`98a13ea`](https://github.com/npm/npm/commit/98a13eafdf098b53069ad15297008fcab9c61653) - `opener@1.4.1`: Deal with `start` on Windows more conventionally. - ([@domenic](https://github.com/domenic)) -* [`c2417c7`](https://github.com/npm/npm/commit/c2417c7702459a446f07d43ca3c4e99bde7fe9d6) - `require-inject@1.2.0`: Add installGlobally to bypass cleanups. - ([@iarna](https://github.com/iarna)) - -#### DOCUMENTATION FIXES - -* [`f87c728`](https://github.com/npm/npm/commit/f87c728f8732c9e977c0dc2060c0610649e79155) - [#7696](https://github.com/npm/npm/issues/7696) Months and minutes were - swapped in doc-build.sh ([@MeddahJ](https://github.com/MeddahJ)) -* [`4e216b2`](https://github.com/npm/npm/commit/4e216b29b30463f06afe6e3c645e205da5f50922) - [#7752](https://github.com/npm/npm/issues/7752) Update string examples to be - properly quoted. ([@snuggs](https://github.com/snuggs)) -* [`402f52a`](https://github.com/npm/npm/commit/402f52ab201efa348feb87cad753fc4b91e8a3fb) - [#7635](https://github.com/npm/npm/issues/7635) Clarify Windows installation - instructions. ([@msikma](https://github.com/msikma)) -* [`c910399`](https://github.com/npm/npm/commit/c910399ecfd8db49fe4496dd26887765a8aed20f) - small typo fix to `CHANGELOG.md` ([@e-jigsaw](https://github.com/e-jigsaw)) - -### v2.7.4 (2015-03-20): - -#### BUG FIXES - -* [`fe1bc38`](https://github.com/npm/npm/commit/fe1bc387a14475e373557de669e03d9d006d3173) - [#7672](https://github.com/npm/npm/issues/7672) `npm-registry-client@3.1.2`: - Fix client-side certificate handling by correcting property name. - ([@atamon](https://github.com/atamon)) -* [`3ce3cc2`](https://github.com/npm/npm/commit/3ce3cc242fc345bca6820185a4f5a013c5bc1944) - [#7635](https://github.com/npm/npm/issues/7635) `fstream-npm@1.0.2`: Raise a - more descriptive error when `bundledDependencies` isn't an array. - ([@KenanY](https://github.com/KenanY)) -* [`3a12723`](https://github.com/npm/npm/commit/3a127235076a1f00bc8befba56c024c6d0e7f477) - [#7661](https://github.com/npm/npm/issues/7661) Allow setting `--registry` on - the command line to trump the mapped registry for `--scope`. - ([@othiym23](https://github.com/othiym23)) -* [`89ce829`](https://github.com/npm/npm/commit/89ce829a00b526d0518f5cd855c323bffe182af0) - [#7630](https://github.com/npm/npm/issues/7630) `hosted-git-info@1.5.3`: Part - 3 of ensuring that GitHub shorthand is handled consistently. - ([@othiym23](https://github.com/othiym23)) -* [`63313eb`](https://github.com/npm/npm/commit/63313eb0c37891c355546fd1093010c8a0c3cd81) - [#7630](https://github.com/npm/npm/issues/7630) - `realize-package-specifier@2.2.0`: Part 2 of ensuring that GitHub shorthand - is handled consistently. ([@othiym23](https://github.com/othiym23)) -* [`3ed41bf`](https://github.com/npm/npm/commit/3ed41bf64a1bb752bb3155c74dd6ffbbd28c89c9) - [#7630](https://github.com/npm/npm/issues/7630) `npm-package-arg@3.1.1`: Part - 1 of ensuring that GitHub shorthand is handled consistently. - ([@othiym23](https://github.com/othiym23)) - -#### DEPENDENCY UPDATES - -* [`6a498c6`](https://github.com/npm/npm/commit/6a498c6aaa00611a0a1ea405255900c327103f8b) - `npm-registry-couchapp@2.6.7`: Ensure that npm continues to work with new - registry architecture. ([@bcoe](https://github.com/bcoe)) -* [`bd72c47`](https://github.com/npm/npm/commit/bd72c47ce8c58e287d496902c11845c8fea420d6) - `glob@5.0.3`: Updated to latest version. - ([@isaacs](https://github.com/isaacs)) -* [`4bfbaa2`](https://github.com/npm/npm/commit/4bfbaa2d8b9dc7067d999de8f55676db3a4f4196) - `npmlog@1.2.0`: Getting up to date with latest version (but not using any of - the new features). ([@othiym23](https://github.com/othiym23)) - -#### A NEW REGRESSION TEST - -* [`3703b0b`](https://github.com/npm/npm/commit/3703b0b87c127a64649bdbfc3bc697ebccc4aa24) - Add regression test for `npm version` to ensure `message` property in config - continues to be honored. ([@dannyfritz](https://github.com/dannyfritz)) - -### v2.7.3 (2015-03-16): - -#### HAHA WHOOPS LIL SHINKWRAP ISSUE THERE LOL - -* [`1549106`](https://github.com/npm/npm/commit/1549106f518000633915686f5f1ccc6afcf77f8f) - [#7641](https://github.com/npm/npm/issues/7641) Due to 448efd0, running `npm - shrinkwrap --dev` caused production dependencies to no longer be included in - `npm-shrinkwrap.json`. Whoopsie! ([@othiym23](https://github.com/othiym23)) - -### v2.7.2 (2015-03-12): - -#### NPM GASTROENTEROLOGY - -* [`fb0ac26`](https://github.com/npm/npm/commit/fb0ac26eecdd76f6eaa4a96a865b7c6f52ce5aa5) - [#7579](https://github.com/npm/npm/issues/7579) Only block removing files and - links when we're sure npm isn't responsible for them. This change is hard to - summarize, because if things are working correctly you should never see it, - but if you want more context, just [go read the commit - message](https://github.com/npm/npm/commit/fb0ac26eecdd76f6eaa4a96a865b7c6f52ce5aa5), - which lays it all out. ([@othiym23](https://github.com/othiym23)) -* [`051c473`](https://github.com/npm/npm/commit/051c4738486a826300f205b71590781ce7744f01) - [#7552](https://github.com/npm/npm/issues/7552) `bundledDependencies` are now - properly included in the installation context. This is another fantastically - hard-to-summarize bug, and once again, I encourage you to [read the commit - message](https://github.com/npm/npm/commit/051c4738486a826300f205b71590781ce7744f01) - if you're curious about the details. The snappy takeaway is that this - unbreaks many use cases for `ember-cli`. ([@othiym23](https://github.com/othiym23)) - -#### LESS DRAMATIC CHANGES - -* [`fcd9247`](https://github.com/npm/npm/commit/fcd92476f3a9092f6f8c83a19a24fe63b206edcd) - [#7597](https://github.com/npm/npm/issues/7597) Awk varies pretty - dramatically from platform to platform, so use Perl to generate the AUTHORS - list instead. ([@KenanY](https://github.com/KenanY)) -* [`721b17a`](https://github.com/npm/npm/commit/721b17a31690bec074eb8763d823d6de63406005) - [#7598](https://github.com/npm/npm/issues/7598) `npm install --save` really - isn't experimental anymore. ([@RichardLitt](https://github.com/RichardLitt)) - -#### DEPENDENCY REFRESH - -* [`a91f2c7`](https://github.com/npm/npm/commit/a91f2c7c9a5183d9cde7aae040ebd9ccdf104be7) - [#7559](https://github.com/npm/npm/issues/7559) `node-gyp@1.0.3` Switch - `node-gyp` to use `stdio` instead of `customFds` so it stops printing a - deprecation warning every time you build a native dependency. - ([@jeffbski](https://github.com/jeffbski)) -* [`0c85db7`](https://github.com/npm/npm/commit/0c85db7f0dde41762411e40a029153e6a65ef483) - `rimraf@2.3.2`: Globbing now deals with paths containing valid glob - metacharacters better. ([@isaacs](https://github.com/isaacs)) -* [`d14588e`](https://github.com/npm/npm/commit/d14588ed09b032c4c770e34b4c0f2436f5fccf6e) - `minimatch@2.0.4`: Bug fixes. ([@isaacs](https://github.com/isaacs)) -* [`aa9952e`](https://github.com/npm/npm/commit/aa9952e8270a6c1b7f97e579875dd6e3aa22abfd) - `graceful-fs@3.0.6`: Bug fixes. ([@isaacs](https://github.com/isaacs)) - -### v2.7.1 (2015-03-05): - -#### GITSANITY - -* [`6823807`](https://github.com/npm/npm/commit/6823807bba6c00228a724e1205ae90d67df0adad) - [#7121](https://github.com/npm/npm/issues/7121) `npm install --save` for Git - dependencies saves the URL passed in, instead of the temporary directory used - to clone the remote repo. Fixes using Git dependencies when shrinkwrapping. - In the process, rewrote the Git dependency caching code. Again. No more - single-letter variable names, and a much clearer workflow. - ([@othiym23](https://github.com/othiym23)) -* [`c8258f3`](https://github.com/npm/npm/commit/c8258f31365b045e5fcf15b865a363abbc3be616) - [#7486](https://github.com/npm/npm/issues/7486) When installing Git remotes, - the caching code was passing in the function `gitEnv` instead of the results - of invoking it. ([@functino](https://github.com/functino)) -* [`c618eed`](https://github.com/npm/npm/commit/c618eeda3e321fd454d77c476b53a0330f2344cc) - [#2556](https://github.com/npm/npm/issues/2556) Make it possible to install - Git dependencies when using `--link` by not linking just the Git - dependencies. ([@smikes](https://github.com/smikes)) - -#### WHY DID THIS TAKE SO LONG. - -* [`abdd040`](https://github.com/npm/npm/commit/abdd040da90932535472f593d5433a67ee074801) - `read-package-json@1.3.2`: Provide more helpful error messages when JSON - parse errors are encountered by using a more forgiving JSON parser than - JSON.parse. ([@smikes](https://github.com/smikes)) - -#### BUGS & TWEAKS - -* [`c56cfcd`](https://github.com/npm/npm/commit/c56cfcd79cd8ab4ccd06d2c03d7e04030d576683) - [#7525](https://github.com/npm/npm/issues/7525) `npm dedupe` handles scoped - packages. ([@KidkArolis](https://github.com/KidkArolis)) -* [`1b8ba74`](https://github.com/npm/npm/commit/1b8ba7426393cbae2c76ad2c35953782d4401871) - [#7531](https://github.com/npm/npm/issues/7531) `npm stars` and `npm whoami` - will no longer send the registry the error text saying you need to log in as - your username. ([@othiym23](https://github.com/othiym23)) -* [`6de1e91`](https://github.com/npm/npm/commit/6de1e91116a5105dfa75126532b9083d8672e034) - [#6441](https://github.com/npm/npm/issues/6441) Prevent needless reinstalls - by only updating packages when the current version isn't the same as the - version returned as `wanted` by `npm outdated`. - ([@othiym23](https://github.com/othiym23)) -* [`2abc3ee`](https://github.com/npm/npm/commit/2abc3ee08f0cabc4e7bfd7b973c0b59dc44715ff) - Add `npm upgrade` as an alias for `npm update`. - ([@othiym23](https://github.com/othiym23)) -* [`bcd4722`](https://github.com/npm/npm/commit/bcd47224e18884191a5d0057c2b2fff83ac8206e) - [#7508](https://github.com/npm/npm/issues/7508) FreeBSD uses `EAI_FAIL` - instead of `ENOTFOUND`. ([@othiym23](https://github.com/othiym23)) -* [`21c1ac4`](https://github.com/npm/npm/commit/21c1ac41280f0716a208cde14025a2ad5ef61fed) - [#7507](https://github.com/npm/npm/issues/7507) Update support URL in generic - error handler to `https:` from `http:`. - ([@watilde](https://github.com/watilde)) -* [`b6bd99a`](https://github.com/npm/npm/commit/b6bd99a73f575545fbbaef95c12237c47dd32561) - [#7492](https://github.com/npm/npm/issues/7492) On install, the - `package.json` `engineStrict` deprecation only warns for the current package. - ([@othiym23](https://github.com/othiym23)) -* [`4ef1412`](https://github.com/npm/npm/commit/4ef1412d0061239da2b1c4460ed6db37cc9ded27) - [#7075](https://github.com/npm/npm/issues/7075) If you try to tag a release - as a valid semver range, `npm publish` and `npm tag` will error early instead - of proceeding. ([@smikes](https://github.com/smikes)) -* [`ad53d0f`](https://github.com/npm/npm/commit/ad53d0f666125d9f50d661b54901c6e5bab4d603) - Use `rimraf` in npm build script because Windows doesn't know what rm is. - ([@othiym23](https://github.com/othiym23)) -* [`8885c4d`](https://github.com/npm/npm/commit/8885c4dfb618f2838930b5c5149abea300a762d6) - `rimraf@2.3.1`: Better Windows support. - ([@isaacs](https://github.com/isaacs)) -* [`8885c4d`](https://github.com/npm/npm/commit/8885c4dfb618f2838930b5c5149abea300a762d6) - `glob@4.4.2`: Handle bad symlinks properly. - ([@isaacs](https://github.com/isaacs)) - -###E TYPSO & CLARFIICATIONS - -dId yuo know that submiting fxies for doc tpyos is an exclelent way to get -strated contriburting to a new open-saurce porject? - -* [`42c605c`](https://github.com/npm/npm/commit/42c605c7b401f603c32ea70427e1a7666adeafd9) - Fix typo in `CHANGELOG.md` ([@adrianblynch](https://github.com/adrianblynch)) -* [`c9bd58d`](https://github.com/npm/npm/commit/c9bd58dd637b9c41441023584a13e3818d5db336) - Add note about `node_modules/.bin` being added to the path in `npm - run-script`. ([@quarterto](https://github.com/quarterto)) -* [`903bdd1`](https://github.com/npm/npm/commit/903bdd105b205d6e45d3a2ab83eea8e4071e9aeb) - Matt Ranney confused the world when he renamed `node-redis` to `redis`. "The - world" includes npm's documentation. - ([@RichardLitt](https://github.com/RichardLitt)) -* [`dea9bb2`](https://github.com/npm/npm/commit/dea9bb2319183fe54bf4d173d8533d46d2c6611c) - Fix typo in contributor link. ([@watilde](https://github.com/watilde)) -* [`1226ca9`](https://github.com/npm/npm/commit/1226ca98d4d7650cc3ba16bf7ac62e44820f3bfa) - Properly close code block in npm-install.md. - ([@olizilla](https://github.com/olizilla)) - -### v2.7.0 (2015-02-26): - -#### SOMETIMES SEMVER MEANS "SUBJECTIVE-EMPATHETIC VERSIONING" - -For a very long time (maybe forever?), the documentation for `npm run-script` -has said that `npm restart` will only call `npm stop` and `npm start` when -there is no command defined as `npm restart` in `package.json`. The problem -with this documentation is that `npm run-script` was apparently never wired up -to actually work this way. - -Until now. - -If the patch below were landed on its own, free of context, it would be a -breaking change. But, since the "new" behavior is how the documentation claims -this feature has always worked, I'm classifying it as a patch-level bug fix. I -apologize in advance if this breaks anybody's deployment scripts, and if it -turns out to be a significant regression in practice, we can revert this change -and move it to `npm@3`, which is allowed to make breaking changes due to being -a new major version of semver. - -* [`2f6a1df`](https://github.com/npm/npm/commit/2f6a1df3e1e3e0a3bc4abb69e40f59a64204e7aa) - [#1999](https://github.com/npm/npm/issues/1999) Only run `stop` and `start` - scripts (plus their pre- and post- scripts) when there's no `restart` script - defined. This makes it easier to support graceful restarts of services - managed by npm. ([@watilde](https://github.com/watilde) / - [@scien](https://github.com/scien)) - -#### A SMALL FEATURE WITH BIG IMPLICATIONS - -* [`145af65`](https://github.com/npm/npm/commit/145af6587f45de135cc876be2027ed818ed4ca6a) - [#4887](https://github.com/npm/npm/issues/4887) Replace calls to the - `node-gyp` script bundled with npm by passing the - `--node-gyp=/path/to/node-gyp` option to npm. Swap in `pangyp` or a version - of `node-gyp` modified to work better with io.js without having to touch - npm's code! ([@ackalker](https://github.com/ackalker)) - -#### [@WATILDE'S](https://github.com/watilde) NPM USABILITY CORNER - -Following `npm@2.6.1`'s unexpected fix of many of the issues with `npm update --g` simply by making `--depth=0` the default for `npm outdated`, friend of npm -[@watilde](https://github.com/watilde) has made several modest changes to npm's -behavior that together justify bumping npm's minor version, as well as making -npm significantly more pleasant to use: - -* [`448efd0`](https://github.com/npm/npm/commit/448efd0eaa6f97af0889bf47efc543a1ea2f8d7e) - [#2853](https://github.com/npm/npm/issues/2853) Add support for `--dev` and - `--prod` to `npm ls`, so that you can list only the trees of production or - development dependencies, as desired. - ([@watilde](https://github.com/watilde)) -* [`a0a8777`](https://github.com/npm/npm/commit/a0a87777af8bee180e4e9321699f050c29ed5ac4) - [#7463](https://github.com/npm/npm/issues/7463) Split the list printed by - `npm run-script` into lifecycle scripts and scripts directly invoked via `npm - run-script`. ([@watilde](https://github.com/watilde)) -* [`a5edc17`](https://github.com/npm/npm/commit/a5edc17d5ef1435b468a445156a4a109df80f92b) - [#6749](https://github.com/npm/npm/issues/6749) `init-package-json@1.3.1`: - Support for passing scopes to `npm init` so packages are initialized as part - of that scope / organization / team. ([@watilde](https://github.com/watilde)) - -#### SMALLER FEATURES AND FIXES - -It turns out that quite a few pull requests had piled up on npm's issue -tracker, and they included some nice small features and fixes: - -* [`f33e8b8`](https://github.com/npm/npm/commit/f33e8b8ff2de094071c5976be95e35110cf2ab1a) - [#7354](https://github.com/npm/npm/issues/7354) Add `--if-present` flag to - allow e.g. CI systems to call (semi-) standard build tasks defined in - `package.json`, but don't raise an error if no such script is defined. - ([@jussi-kalliokoski](https://github.com/jussi-kalliokoski)) -* [`7bf85cc`](https://github.com/npm/npm/commit/7bf85cc372ab5698593b01e139c383fa62c92516) - [#4005](https://github.com/npm/npm/issues/4005) - [#6248](https://github.com/npm/npm/issues/6248) Globally unlink a package - when `npm rm` / `npm unlink` is called with no arguments. - ([@isaacs](https://github.com/isaacs)) -* [`a2e04bd`](https://github.com/npm/npm/commit/a2e04bd921feab8f9e40a27e180ca9308eb709d7) - [#7294](https://github.com/npm/npm/issues/7294) Ensure that when depending on - `git+<proto>` URLs, npm doesn't keep tacking additional `git+` prefixes onto - the front. ([@twhid](https://github.com/twhid)) -* [`0f87f5e`](https://github.com/npm/npm/commit/0f87f5ed28960d962f34977953561d22983da4f9) - [#6422](https://github.com/npm/npm/issues/6422) When depending on GitHub - private repositories, make sure we construct the Git URLS correctly. - ([@othiym23](https://github.com/othiym23)) -* [`50f461d`](https://github.com/npm/npm/commit/50f461d248c4d22e881a9535dccc1d57d994dbc7) - [#4595](https://github.com/npm/npm/issues/4595) Support finding compressed - manpages. It's still up to the system to figure out how to display them, - though. ([@pshevtsov](https://github.com/pshevtsov)) -* [`44da664`](https://github.com/npm/npm/commit/44da66456b530c049ff50953f78368460df87461) - [#7465](https://github.com/npm/npm/issues/7465) When calling git, log the - **full** command, with all arguments, on error. - ([@thriqon](https://github.com/thriqon)) -* [`9748d5c`](https://github.com/npm/npm/commit/9748d5cd195d0269b32caf45129a93d29359a796) - Add parent to error on `ETARGET` error. - ([@davglass](https://github.com/davglass)) -* [`37038d7`](https://github.com/npm/npm/commit/37038d7db47a986001f77ac17b3e164000fc8ff3) - [#4663](https://github.com/npm/npm/issues/4663) Remove hackaround for Linux - tests, as it's evidently no longer necessary. - ([@mmalecki](https://github.com/mmalecki)) -* [`d7b7853`](https://github.com/npm/npm/commit/d7b785393dffce93bb70317fbc039a6428ca37c5) - [#2612](https://github.com/npm/npm/issues/2612) Add support for path - completion on `npm install`, which narrows completion to only directories - containing `package.json` files. ([@deestan](https://github.com/deestan)) -* [`628fcdb`](https://github.com/npm/npm/commit/628fcdb0be4e14c0312085a50dc2ae01dc713fa6) - Remove all command completion calls to `-/short`, because it's been removed - from the primary registry for quite some time, and is generally a poor idea - on any registry with more than a few hundred packages. - ([@othiym23](https://github.com/othiym23)) -* [`3f6061d`](https://github.com/npm/npm/commit/3f6061d75650441ee690472d1fa9c8dd7a7b1b28) - [#6659](https://github.com/npm/npm/issues/6659) Instead of removing zsh - completion global, make it a local instead. - ([@othiym23](https://github.com/othiym23)) - -#### DOCUMENTATION TWEAKS - -* [`5bc70e6`](https://github.com/npm/npm/commit/5bc70e6cfb3598da433806c6f447fc94c8e1d35d) - [#7417](https://github.com/npm/npm/issues/7417) Provide concrete examples of - how the new `npm update` defaults work in practice, tied to actual test - cases. Everyone interested in using `npm update -g` now that it's been fixed - should read these documents, as should anyone interested in writing - documentation for npm. ([@smikes](https://github.com/smikes)) -* [`8ac6f21`](https://github.com/npm/npm/commit/8ac6f2123a6af13dc9447fad96ec9cb583c45a71) - [#6543](https://github.com/npm/npm/issues/6543) Clarify `npm-scripts` - warnings to de-emphasize dangers of using `install` scripts. - ([@zeke](https://github.com/zeke)) -* [`ebe3b37`](https://github.com/npm/npm/commit/ebe3b37098efdada41dcc4c52a291e29296ea242) - [#6711](https://github.com/npm/npm/issues/6711) Note that git tagging of - versions can be disabled via `--no-git-tag-verson`. - ([@smikes](https://github.com/smikes)) -* [`2ef5771`](https://github.com/npm/npm/commit/2ef5771632006e6cee8cf17f836c0f98ab494bd1) - [#6711](https://github.com/npm/npm/issues/6711) Document `git-tag-version` - configuration option. ([@KenanY](https://github.com/KenanY)) -* [`95e59b2`](https://github.com/npm/npm/commit/95e59b287c9517780318e145371a859e8ebb2d20) - Document that `NODE_ENV=production` behaves analogously to `--production` on - `npm install`. ([@stefaneg](https://github.com/stefaneg)) -* [`687117a`](https://github.com/npm/npm/commit/687117a5bcd6a838cd1532ea7020ec6fcf0c33c0) - [#7463](https://github.com/npm/npm/issues/7463) Document the new script - grouping behavior in the man page for `npm run-script`. - ([@othiym23](https://github.com/othiym23)) -* [`536b2b6`](https://github.com/npm/npm/commit/536b2b6f55c349247b3e79b5d11b4c033ef5a3df) - Rescue one of the the disabled tests and make it work properly. - ([@smikes](https://github.com/smikes)) - -#### DEPENDENCY UPDATES - -* [`89fc6a4`](https://github.com/npm/npm/commit/89fc6a4e7ff8c524675fcc14493ca0a1e3a76d38) - `which@1.0.9`: Test for being run as root, as well as the current user. - ([@isaacs](https://github.com/isaacs)) -* [`5d0612f`](https://github.com/npm/npm/commit/5d0612f31e226cba32a05351c47b055c0ab6c557) - `glob@4.4.1`: Better error message to explain why calling sync glob with a - callback results in an error. ([@isaacs](https://github.com/isaacs)) -* [`64b07f6`](https://github.com/npm/npm/commit/64b07f6caf6cb07e4102f1e4e5f2ff2b944e452e) - `tap@0.7.1`: More accurate counts of pending & skipped tests. - ([@rmg](https://github.com/rmg)) -* [`8fda451`](https://github.com/npm/npm/commit/8fda45195dae1d6f792be556abe87f7763fab09b) - `semver@4.3.1`: Make official the fact that `node-semver` has moved from - [@isaacs](https://github.com/isaacs)'s organization to - [@npm](https://github.com/npm)'s. ([@isaacs](https://github.com/isaacs)) - -### v2.6.1 (2015-02-19): - -* [`8b98f0e`](https://github.com/npm/npm/commit/8b98f0e709d77a8616c944aebd48ab726f726f76) - [#4471](https://github.com/npm/npm/issues/4471) `npm outdated` (and only `npm - outdated`) now defaults to `--depth=0`. See the [docs for - `--depth`](https://github.com/npm/npm/blob/82f484672adb1a3caf526a8a48832789495bb43d/doc/misc/npm-config.md#depth) - for the mildly confusing details. ([@smikes](https://github.com/smikes)) -* [`aa79194`](https://github.com/npm/npm/commit/aa791942a9f3c8af6a650edec72a675deb7a7c6e) - [#6565](https://github.com/npm/npm/issues/6565) Tweak `peerDependency` - deprecation warning to include which peer dependency on which package is - going to need to change. ([@othiym23](https://github.com/othiym23)) -* [`5fa067f`](https://github.com/npm/npm/commit/5fa067fd47682ac3cdb12a2b009d8ca59b05f992) - [#7171](https://github.com/npm/npm/issues/7171) Tweak `engineStrict` - deprecation warning to include which `package.json` is using it. - ([@othiym23](https://github.com/othiym23)) -* [`0fe0caa`](https://github.com/npm/npm/commit/0fe0caa7eddb7acdacbe5ee81ceabaca27175c78) - `glob@4.4.0`: Glob patterns can now ignore matches. - ([@isaacs](https://github.com/isaacs)) - -### v2.6.0 (2015-02-12): - -#### A LONG-AWAITED GUEST - -* [`38c4825`](https://github.com/npm/npm/commit/38c48254d3d217b4babf5027cb39492be4052fc2) - [#5068](https://github.com/npm/npm/issues/5068) Add new logout command, and - make it do something useful on both bearer-based and basic-based authed - clients. ([@othiym23](https://github.com/othiym23)) -* [`4bf0f5d`](https://github.com/npm/npm/commit/4bf0f5d56c33649124b486e016ba4a620c105c1c) - `npm-registry-client@6.1.1`: Support new `logout` endpoint to invalidate - token for sessions. ([@othiym23](https://github.com/othiym23)) - -#### DEPRECATIONS - -* [`c8e08e6`](https://github.com/npm/npm/commit/c8e08e6d91f4016c80f572aac5a2080df0f78098) - [#6565](https://github.com/npm/npm/issues/6565) Warn that `peerDependency` - behavior is changing and add a note to the docs. - ([@othiym23](https://github.com/othiym23)) -* [`7c81a5f`](https://github.com/npm/npm/commit/7c81a5f5f058941f635a92f22641ea68e79b60db) - [#7171](https://github.com/npm/npm/issues/7171) Warn that `engineStrict` in - `package.json` will be going away in the next major version of npm (coming - soon!) ([@othiym23](https://github.com/othiym23)) - -#### BUG FIXES & TWEAKS - -* [`add5890`](https://github.com/npm/npm/commit/add5890ce447dabf120b907a85f715df1e065f44) - [#4668](https://github.com/npm/npm/issues/4668) `read-package-json@1.3.1`: - Warn when a `bin` symbolic link is a dangling reference. - ([@nicks](https://github.com/nicks)) -* [`4b42071`](https://github.com/npm/npm/commit/4b420714dfb84338d85def78c30bd665e32d72c1) - `semver@4.3.0`: Add functions to extract parts of the version triple, fix a - typo. ([@isaacs](https://github.com/isaacs)) -* [`a9aff38`](https://github.com/npm/npm/commit/a9aff38719918486fc381d67ad3371c475632ff7) - Use full path for man pages as the symbolic link source, instead of just the - file name. ([@bengl](https://github.com/bengl)) -* [`6fd0fbd`](https://github.com/npm/npm/commit/6fd0fbd8a0347fd47cb7ee0064e0902a2f8a087c) - [#7233](https://github.com/npm/npm/issues/7233) Ensure `globalconfig` path - exists before trying to edit it. ([@ljharb](https://github.com/ljharb)) -* [`a0a2620`](https://github.com/npm/npm/commit/a0a262047647d9e2690cebe5a89e6a0dd33202bb) - `ini@1.3.3`: Allow embedded, quoted equals signs in ini field names. - ([@isaacs](https://github.com/isaacs)) - -Also typos and other documentation issues were addressed by -[@rutsky](https://github.com/rutsky), [@imurchie](https://github.com/imurchie), -[@marcin-wosinek](https://github.com/marcin-wosinek), -[@marr](https://github.com/marr), [@amZotti](https://github.com/amZotti), and -[@karlhorky](https://github.com/karlhorky). Thank you, everyone! - -### v2.5.1 (2015-02-06): - -This release doesn't look like much, but considerable effort went into ensuring -that npm's tests will pass on io.js 1.1.0 and Node 0.11.16 / 0.12.0 on both OS -X and Linux. - -**NOTE:** there are no actual changes to npm's code in `npm@2.5.1`. Only test -code (and the upgrade of `request` to the latest version) has changed. - -#### `npm-registry-mock@1.0.0`: - -* [`0e8d473`](https://github.com/npm/npm/commit/0e8d4736a1cbdda41ae8eba8a02c7ff7ce80c2ff) - [#7281](https://github.com/npm/npm/issues/7281) `npm-registry-mock@1.0.0`: - Clean up API, set `connection: close`. - ([@robertkowalski](https://github.com/robertkowalski)) -* [`4707bba`](https://github.com/npm/npm/commit/4707bba7d44dfab85cc45c2ecafa9c1601ba2e9a) - Further update tests to work with `npm-registry-mock@1.0.0`. - ([@othiym23](https://github.com/othiym23)) -* [`41a0f89`](https://github.com/npm/npm/commit/41a0f8959d4e02af9661588afa7d2b4543cc21b6) - Got rid of completely gratuitous global config manipulation in tests. - ([@othiym23](https://github.com/othiym23)) - -#### MINOR DEPENDENCY TWEAK - -* [`a4c7af9`](https://github.com/npm/npm/commit/a4c7af9c692f250c0fd017397ed9514fc263b752) - `request@2.53.0`: Tweaks to tunneling proxy behavior. - ([@nylen](https://github.com/nylen)) - -### v2.5.0 (2015-01-29): - -#### SMALL FEATURE I HAVE ALREADY USED TO MAINTAIN NPM ITSELF - -* [`9d61e96`](https://github.com/npm/npm/commit/9d61e96fb1f48687a85c211e4e0cd44c7f95a38e) - `npm outdated --long` now includes a column showing the type of dependency. - ([@watilde](https://github.com/watilde)) - -#### BUG FIXES & TWEAKS - -* [`fec4c96`](https://github.com/npm/npm/commit/fec4c967ee235030bf31393e8605e9e2811f4a39) - Allow `--no-proxy` to override `HTTP_PROXY` setting in environment. - ([@othiym23](https://github.com/othiym23)) -* [`589acb9`](https://github.com/npm/npm/commit/589acb9714f395c2ad0d98cb0ac4236f1842d2cc) - Only set `access` when publshing when it's explicitly set. - ([@othiym23](https://github.com/othiym23)) -* [`1027087`](https://github.com/npm/npm/commit/102708704c8c4f0ea99775d38f8d1efecf584940) - Add script and `Makefile` stanza to update AUTHORS. - ([@KenanY](https://github.com/KenanY)) -* [`eeff04d`](https://github.com/npm/npm/commit/eeff04da7979a0181becd36b8777d607e7aa1787) - Add `NPMOPTS` to top-level install in `Makefile` to override `userconfig`. - ([@aredridel](https://github.com/aredridel)) -* [`0d17328`](https://github.com/npm/npm/commit/0d173287336650606d4c91818bb7bcfb0c5d57a1) - `fstream@1.0.4`: Run chown only when necessary. - ([@silkentrance](https://github.com/silkentrance)) -* [`9aa4622`](https://github.com/npm/npm/commit/9aa46226ee63b9e183fd49fc72d9bdb0fae9605e) - `columnify@1.4.1`: ES6ified! ([@timoxley](https://github.com/timoxley)) -* [`51b2fd1`](https://github.com/npm/npm/commit/51b2fd1974e38b825ac5ca4a852ab3c4142624cc) - Update default version in `docs/npm-config.md`. - ([@lucthev](https://github.com/lucthev)) - -#### `npm-registry-client@6.0.7`: - -* [`f9313a0`](https://github.com/npm/npm/commit/f9313a066c9889a0ee898d8a35676e40b8101e7f) - [#7226](https://github.com/npm/npm/issues/7226) Ensure that all request - settings are copied onto the agent. - ([@othiym23](https://github.com/othiym23)) -* [`e186f6e`](https://github.com/npm/npm/commit/e186f6e7cfeb4db9c94d7375638f0b2f0d472947) - Only set `access` on publish when it differs from the norm. - ([@othiym23](https://github.com/othiym23)) -* [`f9313a0`](https://github.com/npm/npm/commit/f9313a066c9889a0ee898d8a35676e40b8101e7f) - Allow overriding request's environment-based proxy handling. - ([@othiym23](https://github.com/othiym23)) -* [`f9313a0`](https://github.com/npm/npm/commit/f9313a066c9889a0ee898d8a35676e40b8101e7f) - Properly handle retry failures on fetch. - ([@othiym23](https://github.com/othiym23)) - -### v2.4.1 (2015-01-23): - -![bridge that doesn't meet in the middle](http://www.static-18.themodernnomad.com/wp-content/uploads/2011/08/bridge-fail.jpg) - -Let's accentuate the positive: the `dist-tag` endpoints for `npm dist-tag -{add,rm,ls}` are now live on the public npm registry. - -* [`f70272b`](https://github.com/npm/npm/commit/f70272bed7d77032d1e21553371dd5662fef32f2) - `npm-registry-client@6.0.3`: Properly escape JSON tag version strings and - filter `_etag` from CouchDB docs. ([@othiym23](https://github.com/othiym23)) - -### v2.4.0 (2015-01-22): - -#### REGISTRY 2: ACCESS AND DIST-TAGS - -NOTE: This week's registry-2 commands are leading the implementation on -registry.npmjs.org a little bit, so some of the following may not work for -another week or so. Also note that `npm access` has documentation and -subcommands that are not yet finished, because they depend on incompletely -specified registry API endpoints. Things are coming together very quickly, -though, so expect the missing pieces to be filled in the coming weeks. - -* [`c963eb2`](https://github.com/npm/npm/commit/c963eb295cf766921b1680f4a71fd0ed3e1bcad8) - [#7181](https://github.com/npm/npm/issues/7181) NEW `npm access public` and - `npm access restricted`: Toggle visibility of scoped packages. - ([@othiym23](https://github.com/othiym23)) -* [`dc51810`](https://github.com/npm/npm/commit/dc51810e08c0f104259146c9c035d255de4f7d1d) - [#6243](https://github.com/npm/npm/issues/6243) / - [#6854](https://github.com/npm/npm/issues/6854) NEW `npm dist-tags`: Directly - manage `dist-tags` on packages. Most notably, `dist-tags` can now be deleted. - ([@othiym23](https://github.com/othiym23)) -* [`4c7c132`](https://github.com/npm/npm/commit/4c7c132a6b8305dca2974943226c39c0cdc64ff9) - [#7181](https://github.com/npm/npm/issues/7181) / - [#6854](https://github.com/npm/npm/issues/6854) `npm-registry-client@6.0.1`: - Add new `access` and `dist-tags` endpoints - ([@othiym23](https://github.com/othiym23)) - -#### NOT EXACTLY SELF-DEPRECATING - -* [`10d5c77`](https://github.com/npm/npm/commit/10d5c77653487f15759ac7de262a97e9c655240c) - [#6274](https://github.com/npm/npm/issues/6274) Deprecate `npm tag` in favor - of `npm dist-tag`. ([@othiym23](https://github.com/othiym23)) - -#### BUG FIX AND TINY FEATURE - -* [`29a6ef3`](https://github.com/npm/npm/commit/29a6ef38ef86ac318c5d9ea4bee28ce614672fa6) - [#6850](https://github.com/npm/npm/issues/6850) Be smarter about determining - base of file deletion when unbuilding. ([@phated](https://github.com/phated)) -* [`4ad01ea`](https://github.com/npm/npm/commit/4ad01ea2930a7a1cf88be121cc5ce9eba40c6807) - `init-package-json@1.2.0`: Support `--save-exact` in `npm init`. - ([@gustavnikolaj](https://github.com/gustavnikolaj)) - -### v2.3.0 (2015-01-15): - -#### REGISTRY 2: OH MY STARS! WHO AM I? - -* [`e662a60`](https://github.com/npm/npm/commit/e662a60e2f9a542effd8e72279d4622fe514415e) - The new `whoami` endpoint might not return a value. - ([@othiym23](https://github.com/othiym23)) -* [`c2cccd4`](https://github.com/npm/npm/commit/c2cccd4bbc65885239ed646eb510155f7b8af13d) - `npm-registry-client@5.0.0`: Includes the following fine changes - ([@othiym23](https://github.com/othiym23)): - * [`ba6b73e`](https://github.com/npm/npm-registry-client/commit/ba6b73e351027246c228622014e4441412409bad) - [#92](https://github.com/npm/npm-registry-client/issues/92) BREAKING CHANGE: - Move `/whoami` endpoint out of the package namespace (to `/-/whoami`). - ([@othiym23](https://github.com/othiym23)) - * [`3b174b7`](https://github.com/npm/npm-registry-client/commit/3b174b75c0c9ea77e298e6bb664fb499824ecc7c) - [#93](https://github.com/npm/npm-registry-client/issues/93) Registries based - on token-based auth can now offer starring. - ([@bcoe](https://github.com/bcoe)) - * [`4701a29`](https://github.com/npm/npm-registry-client/commit/4701a29bcda41bc14aa91f361dd0d576e24677d7) - Fix HTTP[S] connection keep-alive on Node 0.11 / io.js 1.0. - ([@fengmk2](https://github.com/fengmk2)) - -#### BETTER REGISTRY METADATA CACHING - -* [`98e1e10`](https://github.com/npm/npm/commit/98e1e1080df1f2cab16ed68035603950ea3d2d48) - [#6791](https://github.com/npm/npm/issues/6791) Add caching based on - Last-Modified / If-Modified-Since headers. Includes this - `npm-registry-client@5.0.0` change ([@lxe](https://github.com/lxe)): - * [`07bc335`](https://github.com/npm/npm-registry-client/commit/07bc33502b93554cd7539bfcce37d6e2d5404cd0) - [#86](https://github.com/npm/npm-registry-client/issues/86) Add Last-Modified - / If-Modified-Since cache header handling. ([@lxe](https://github.com/lxe)) - -#### HOW MUCH IS THAT WINDOWS IN THE DOGGY? - -* [`706d49a`](https://github.com/npm/npm/commit/706d49ab45521360fce1a68779b8de899015d8c2) - [#7107](https://github.com/npm/npm/issues/7107) `getCacheStat` passes a stub - stat on Windows. ([@rmg](https://github.com/rmg)) -* [`5fce278`](https://github.com/npm/npm/commit/5fce278a688a1cb79183e012bde40b089c2e97a4) - [#5267](https://github.com/npm/npm/issues/5267) Use `%COMSPEC%` when set on - Windows. ([@edmorley](https://github.com/edmorley)) -* [`cc2e099`](https://github.com/npm/npm/commit/cc2e09912ce2f91567c485422e4e797c4deb9842) - [#7083](https://github.com/npm/npm/issues/7083) Ensure Git cache prefix - exists before repo clone on Windows. - ([@othiym23](https://github.com/othiym23)) - -#### THRILLING BUG FIXES - -* [`c6fb430`](https://github.com/npm/npm/commit/c6fb430e55672b3caf87d25cbd2aeeebc449e2f2) - [#4197](https://github.com/npm/npm/issues/4197) Report `umask` as a 0-padded - octal literal. ([@smikes](https://github.com/smikes)) -* [`209713e`](https://github.com/npm/npm/commit/209713ebd4b77da11ce27d90c3346f78d760ba52) - [#4197](https://github.com/npm/npm/issues/4197) `umask@1.1.0`: Properly - handle `umask`s (i.e. not decimal numbers). - ([@smikes](https://github.com/smikes)) -* [`9eac0a1`](https://github.com/npm/npm/commit/9eac0a14488c5979ebde4c17881c8cd74f395069) - Make the example for bin links non-destructive. - ([@KevinSheedy](https://github.com/KevinSheedy)) -* [`6338bcf`](https://github.com/npm/npm/commit/6338bcfcd9cd1b0cc48b051dae764dc436ab5332) - `glob@4.3.5`: " -> ', for some reason. ([@isaacs](https://github.com/isaacs)) - -### v2.2.0 (2015-01-08): - -* [`88c531d`](https://github.com/npm/npm/commit/88c531d1c0b3aced8f2a09632db01b5635e7226a) - [#7056](https://github.com/npm/npm/issues/7056) version doesn't need a - package.json. ([@othiym23](https://github.com/othiym23)) -* [`2656c19`](https://github.com/npm/npm/commit/2656c19f6b915c3173acc3b6f184cc321563da5f) - [#7095](https://github.com/npm/npm/issues/7095) Link to npm website instead - of registry. ([@konklone](https://github.com/konklone)) -* [`c76b801`](https://github.com/npm/npm/commit/c76b8013bf1758587565822626171b76cb465c9e) - [#7067](https://github.com/npm/npm/issues/7067) Obfuscate secrets, including - nerfed URLs. ([@smikes](https://github.com/smikes)) -* [`17f66ce`](https://github.com/npm/npm/commit/17f66ceb1bd421084e4ae82a6b66634a6e272929) - [#6849](https://github.com/npm/npm/issues/6849) Explain the tag workflow more - clearly. ([@smikes](https://github.com/smikes)) -* [`e309df6`](https://github.com/npm/npm/commit/e309df642de33d10d6dffadaa8a5d214a924d0dc) - [#7096](https://github.com/npm/npm/issues/7096) Really, `npm update -g` is - almost always a terrible idea. ([@smikes](https://github.com/smikes)) -* [`acf287d`](https://github.com/npm/npm/commit/acf287d2547c8a0a8871652c164019261b666d55) - [#6999](https://github.com/npm/npm/issues/6999) `npm run-script env`: add a - new default script that will print out environment values. - ([@gcb](https://github.com/gcb)) -* [`560c009`](https://github.com/npm/npm/commit/560c00945d4dec926cd29193e336f137c7f3f951) - [#6745](https://github.com/npm/npm/issues/6745) Document `npm update --dev`. - ([@smikes](https://github.com/smikes)) -* [`226a677`](https://github.com/npm/npm/commit/226a6776a1a9e28570485623b8adc2ec4b041335) - [#7046](https://github.com/npm/npm/issues/7046) We have never been the Node - package manager. ([@linclark](https://github.com/linclark)) -* [`38eef22`](https://github.com/npm/npm/commit/38eef2248f03bb8ab04cae1833e2a228fb887f3c) - `npm-install-checks@1.0.5`: Compatibility with npmlog@^1. - ([@iarna](https://github.com/iarna)) - -### v2.1.18 (2015-01-01): - -* [`bf8640b`](https://github.com/npm/npm/commit/bf8640b0395b5dff71260a0cede7efc699a7bcf5) - [#7044](https://github.com/npm/npm/issues/7044) Document `.npmignore` syntax. - ([@zeke](https://github.com/zeke)) - -### v2.1.17 (2014-12-25): - -merry npm xmas - -Working with [@phated](https://github.com/phated), I discovered that npm still -had some lingering race conditions around how it handles Git dependencies. The -following changes were intended to remedy to these issues. Thanks to -[@phated](https://github.com/phated) for all his help getting to the bottom of -these. - -* [`bdf1c84`](https://github.com/npm/npm/commit/bdf1c8483f5c4ad79b712db12d73276e15883923) - [#7006](https://github.com/npm/npm/issues/7006) Only `chown` template and - top-level Git cache directories. ([@othiym23](https://github.com/othiym23)) -* [`581a72d`](https://github.com/npm/npm/commit/581a72da18f35ec87edef6255adf4ef4714a478c) - [#7006](https://github.com/npm/npm/issues/7006) Map Git remote inflighting to - clone paths rather than Git URLs. ([@othiym23](https://github.com/othiym23)) -* [`1c48d08`](https://github.com/npm/npm/commit/1c48d08dea31a11ac11a285cac598a482481cade) - [#7009](https://github.com/npm/npm/issues/7009) `normalize-git-url@1.0.0`: - Normalize Git URLs while caching. ([@othiym23](https://github.com/othiym23)) -* [`5423cf0`](https://github.com/npm/npm/commit/5423cf0be8ff2b76bfff7c8e780e5f261235a86a) - [#7009](https://github.com/npm/npm/issues/7009) Pack tarballs to their final - locations atomically. ([@othiym23](https://github.com/othiym23)) -* [`7f6557f`](https://github.com/npm/npm/commit/7f6557ff317469ee4a87c542ff9a991e74ce9f38) - [#7009](https://github.com/npm/npm/issues/7009) Inflight local directory - packing, just to be safe. ([@othiym23](https://github.com/othiym23)) - -Other changes: - -* [`1c491e6`](https://github.com/npm/npm/commit/1c491e65d70af013e8d5ac008d6d9762d6d91793) - [#6991](https://github.com/npm/npm/issues/6991) `npm version`: fix regression - in dirty-checking behavior ([@rlidwka](https://github.com/rlidwka)) -* [`55ceb2b`](https://github.com/npm/npm/commit/55ceb2b08ff8a0f56b94cc972ca15d7862e8733c) - [#1991](https://github.com/npm/npm/issues/1991) modify docs to reflect actual - `npm restart` behavior ([@smikes](https://github.com/smikes)) -* [`fb8e31b`](https://github.com/npm/npm/commit/fb8e31b95476a50bda35a665a99eec8a5d25a4db) - [#6982](https://github.com/npm/npm/issues/6982) when doing registry - operations, ensure registry URL always ends with `/` - ([@othiym23](https://github.com/othiym23)) -* [`5bcba65`](https://github.com/npm/npm/commit/5bcba65bed2678ffe80fb596f72abe9871d131c8) - pull whitelisted Git environment variables out into a named constant - ([@othiym23](https://github.com/othiym23)) -* [`be04bbd`](https://github.com/npm/npm/commit/be04bbdc52ebfc820cd939df2f7d79fe87067747) - [#7000](https://github.com/npm/npm/issues/7000) No longer install badly-named - manpage files, and log an error when trying to uninstall them. - ([@othiym23](https://github.com/othiym23)) -* [`6b7c5ec`](https://github.com/npm/npm/commit/6b7c5eca6b65e1247d0e51f6400cf2637ac880ce) - [#7011](https://github.com/npm/npm/issues/7011) Send auth for tarball fetches - for packages in `npm-shrinkwrap.json` from private registries. - ([@othiym23](https://github.com/othiym23)) -* [`9b9de06`](https://github.com/npm/npm/commit/9b9de06a99893b40aa23f0335726dec6df7979db) - `glob@4.3.2`: Better handling of trailing slashes. - ([@isaacs](https://github.com/isaacs)) -* [`030f3c7`](https://github.com/npm/npm/commit/030f3c7450b8ce124a19073bfbae0948a0a1a02c) - `semver@4.2.0`: Diffing between version strings. - ([@isaacs](https://github.com/isaacs)) - -### v2.1.16 (2014-12-22): - -* [`a4e4e33`](https://github.com/npm/npm/commit/a4e4e33edb35c68813f04bf42bdf933a6f727bcd) - [#6987](https://github.com/npm/npm/issues/6987) `read-installed@3.1.5`: fixed - a regression where a new / empty package would cause read-installed to throw. - ([@othiym23](https://github.com/othiym23) / - [@pgilad](https://github.com/pgilad)) - -### v2.1.15 (2014-12-18): - -* [`e5a2dee`](https://github.com/npm/npm/commit/e5a2dee47c74f26c56fee5998545b97497e830c8) - [#6951](https://github.com/npm/npm/issues/6951) `fs-vacuum@1.2.5`: Use - `path-is-inside` for better Windows normalization. - ([@othiym23](https://github.com/othiym23)) -* [`ac6167c`](https://github.com/npm/npm/commit/ac6167c2b9432939c57296f7ddd11ad5f8f918b2) - [#6955](https://github.com/npm/npm/issues/6955) Call `path.normalize` in - `lib/utils/gently-rm.js` for better Windows normalization. - ([@ben-page](https://github.com/ben-page)) -* [`c625d71`](https://github.com/npm/npm/commit/c625d714795e3b5badd847945e2401adfad5a196) - [#6964](https://github.com/npm/npm/issues/6964) Clarify CA configuration - docs. ([@jeffjo](https://github.com/jeffjo)) -* [`58b8cb5`](https://github.com/npm/npm/commit/58b8cb5cdf26a854358b7c2ab636572dba9bac16) - [#6950](https://github.com/npm/npm/issues/6950) Fix documentation typos. - ([@martinvd](https://github.com/martinvd)) -* [`7c1299d`](https://github.com/npm/npm/commit/7c1299d00538ea998684a1903a4091eafc63b7f1) - [#6909](https://github.com/npm/npm/issues/6909) Remove confusing mention of - rubygems `~>` semver operator. ([@mjtko](https://github.com/mjtko)) -* [`7dfdcc6`](https://github.com/npm/npm/commit/7dfdcc6debd8ef1fc52a2b508997d15887aad824) - [#6909](https://github.com/npm/npm/issues/6909) `semver@4.1.1`: Synchronize - documentation with PR [#6909](https://github.com/npm/npm/issues/6909) - ([@othiym23](https://github.com/othiym23)) -* [`adfddf3`](https://github.com/npm/npm/commit/adfddf3b682e0ae08e4b59d87c1b380dd651c572) - [#6925](https://github.com/npm/npm/issues/6925) Correct typo in - `doc/api/npm-ls.md` ([@oddurs](https://github.com/oddurs)) -* [`f5c534b`](https://github.com/npm/npm/commit/f5c534b711ab173129baf366c4f08d68f6117333) - [#6920](https://github.com/npm/npm/issues/6920) Remove recommendation to run - as root from `README.md`. - ([@robertkowalski](https://github.com/robertkowalski)) -* [`3ef4459`](https://github.com/npm/npm/commit/3ef445922cd39f25b992d91bd22c4d367882ea22) - [#6920](https://github.com/npm/npm/issues/6920) `npm-@googlegroups.com` has - gone the way of all things. That means it's gone. - ([@robertkowalski](https://github.com/robertkowalski)) - -### v2.1.14 (2014-12-13): - -* [`cf7aeae`](https://github.com/npm/npm/commit/cf7aeae3c3a24e48d3de4006fa082f0c6040922a) - [#6923](https://github.com/npm/npm/issues/6923) Overaggressive link update - for new website broke node-gyp. ([@othiym23](https://github.com/othiym23)) - -### v2.1.13 (2014-12-11): - -* [`cbb890e`](https://github.com/npm/npm/commit/cbb890eeacc0501ba1b8c6955f1c829c8af9f486) - [#6897](https://github.com/npm/npm/issues/6897) npm is a nice package manager - that runs server-side JavaScript. ([@othiym23](https://github.com/othiym23)) -* [`d9043c3`](https://github.com/npm/npm/commit/d9043c3b8d7450c3cb9ca795028c0e1c05377820) - [#6893](https://github.com/npm/npm/issues/6893) Remove erroneous docs about - preupdate / update / postupdate lifecycle scripts, which have never existed. - ([@devTristan](https://github.com/devTristan)) -* [`c5df4d0`](https://github.com/npm/npm/commit/c5df4d0d683cd3506808d1cd1acebff02a8b82db) - [#6884](https://github.com/npm/npm/issues/6884) Update npmjs.org to npmjs.com - in docs. ([@linclark](https://github.com/linclark)) -* [`cb6ff8d`](https://github.com/npm/npm/commit/cb6ff8dace1b439851701d4784d2d719c22ca7a7) - [#6879](https://github.com/npm/npm/issues/6879) npm version: Update - shrinkwrap post-check. ([@othiym23](https://github.com/othiym23)) -* [`2a340bd`](https://github.com/npm/npm/commit/2a340bdd548c6449468281e1444a032812bff677) - [#6868](https://github.com/npm/npm/issues/6868) Use magic numbers instead of - regexps to distinguish tarballs from other things. - ([@daxxog](https://github.com/daxxog)) -* [`f1c8bdb`](https://github.com/npm/npm/commit/f1c8bdb3f6b753d0600597e12346bdc3a34cb9c1) - [#6861](https://github.com/npm/npm/issues/6861) `npm-registry-client@4.0.5`: - Distinguish between error properties that are part of the response and error - strings that should be returned to the user. - ([@disrvptor](https://github.com/disrvptor)) -* [`d3a1b63`](https://github.com/npm/npm/commit/d3a1b6397fddef04b5198ca89d36d720aeb05eb6) - [#6762](https://github.com/npm/npm/issues/6762) Make `npm outdated` ignore - private packages. ([@KenanY](https://github.com/KenanY)) -* [`16d8542`](https://github.com/npm/npm/commit/16d854283ca5bcdb0cb2812fc5745d841652b952) - install.sh: Drop support for node < 0.8, remove engines bits. - ([@isaacs](https://github.com/isaacs)) -* [`b9c6046`](https://github.com/npm/npm/commit/b9c60466d5b713b1dc2947da14a5dfe42352e029) - `init-package-json@1.1.3`: ([@terinstock](https://github.com/terinstock)) - noticed that `init.license` configuration doesn't stick. Make sure that - dashed defaults don't trump dotted parameters. - ([@othiym23](https://github.com/othiym23)) -* [`b6d6acf`](https://github.com/npm/npm/commit/b6d6acfc02c8887f78067931babab8f7c5180fed) - `which@1.0.8`: No longer use graceful-fs for some reason. - ([@isaacs](https://github.com/isaacs)) -* [`d39f673`](https://github.com/npm/npm/commit/d39f673caf08a90fb2bb001d79c98062d2cd05f4) - `request@2.51.0`: Incorporate bug fixes. ([@nylen](https://github.com/nylen)) -* [`c7ad727`](https://github.com/npm/npm/commit/c7ad7279cc879930ec58ccc62fa642e621ecb65c) - `columnify@1.3.2`: Incorporate bug fixes. - ([@timoxley](https://github.com/timoxley)) - -### v2.1.12 (2014-12-04): - -* [`e5b1e44`](https://github.com/npm/npm/commit/e5b1e448bb4a9d6eae4ba0f67b1d3c2cea8ed383) - add alias verison=version ([@isaacs](https://github.com/isaacs)) -* [`5eed7bd`](https://github.com/npm/npm/commit/5eed7bddbd7bb92a44c4193c93e8529500c558e6) - `request@2.49.0` ([@nylen](https://github.com/nylen)) -* [`e72f81d`](https://github.com/npm/npm/commit/e72f81d8412540ae7d1e0edcc37c11bcb8169051) - `glob@4.3.1` / `minimatch@2.0.1` ([@isaacs](https://github.com/isaacs)) -* [`b8dcc36`](https://github.com/npm/npm/commit/b8dcc3637b5b71933b97162b7aff1b1a622c13e2) - `graceful-fs@3.0.5` ([@isaacs](https://github.com/isaacs)) - -### v2.1.11 (2014-11-27): - -* [`4861d28`](https://github.com/npm/npm/commit/4861d28ad0ebd959fe6bc15b9c9a50fcabe57f55) - `which@1.0.7`: License update. ([@isaacs](https://github.com/isaacs)) -* [`30a2ea8`](https://github.com/npm/npm/commit/30a2ea80c891d384b31a1cf28665bba4271915bd) - `ini@1.3.2`: License update. ([@isaacs](https://github.com/isaacs)) -* [`6a4ea05`](https://github.com/npm/npm/commit/6a4ea054f6ddf52fc58842ba2046564b04c5c0e2) - `fstream@1.0.3`: Propagate error events to downstream streams. - ([@gfxmonk](https://github.com/gfxmonk)) -* [`a558695`](https://github.com/npm/npm/commit/a5586954f1c18df7c96137e0a79f41a69e7a884e) - `tar@1.0.3`: Don't extract broken files, propagate `drain` event. - ([@gfxmonk](https://github.com/gfxmonk)) -* [`989624e`](https://github.com/npm/npm/commit/989624e8321f87734c1b1272fc2f646e7af1f81c) - [#6767](https://github.com/npm/npm/issues/6767) Actually pass parameters when - adding git repo to cache under Windows. - ([@othiym23](https://github.com/othiym23)) -* [`657af73`](https://github.com/npm/npm/commit/657af7308f7d6cd2f81389fcf0d762252acaf1ce) - [#6774](https://github.com/npm/npm/issues/6774) When verifying paths on - unbuild, resolve both source and target as symlinks. - ([@hokaccha](https://github.com/hokaccha)) -* [`fd19c40`](https://github.com/npm/npm/commit/fd19c4046414494f9647a6991c00f8406a939929) - [#6713](https://github.com/npm/npm/issues/6713) - `realize-package-specifier@1.3.0`: Make it so that `npm install foo@1` work - when a file named `1` exists. ([@iarna](https://github.com/iarna)) -* [`c8ac37a`](https://github.com/npm/npm/commit/c8ac37a470491b2ed28514536e2e198494638c79) - `npm-registry-client@4.0.4`: Fix regression in failed fetch retries. - ([@othiym23](https://github.com/othiym23)) - -### v2.1.10 (2014-11-20): - -* [`756f3d4`](https://github.com/npm/npm/commit/756f3d40fe18bc02bc93afe17016dfcc266c4b6b) - [#6735](https://github.com/npm/npm/issues/6735) Log "already built" messages - at info, not error. ([@smikes](https://github.com/smikes)) -* [`1b7330d`](https://github.com/npm/npm/commit/1b7330dafba3bbba171f74f1e58b261cb1b9301e) - [#6729](https://github.com/npm/npm/issues/6729) `npm-registry-client@4.0.3`: - GitHub won't redirect you through an HTML page to a compressed tarball if you - don't tell it you accept JSON responses. - ([@KenanY](https://github.com/KenanY)) -* [`d9c7857`](https://github.com/npm/npm/commit/d9c7857be02dacd274e55bf6d430d90d91509d53) - [#6506](https://github.com/npm/npm/issues/6506) - `readdir-scoped-modules@1.0.1`: Use `graceful-fs` so the whole dependency - tree gets read, even in case of `EMFILE`. - ([@sakana](https://github.com/sakana)) -* [`3a085be`](https://github.com/npm/npm/commit/3a085be158ace8f1e4395e69f8c102d3dea00c5f) - Grammar fix in docs. ([@icylace](https://github.com/icylace)) -* [`3f8e2ff`](https://github.com/npm/npm/commit/3f8e2ff8342d327d6f1375437ecf4bd945dc360f) - Did you know that npm has a Code of Conduct? Add a link to it to - CONTRIBUTING.md. ([@isaacs](https://github.com/isaacs)) -* [`319ccf6`](https://github.com/npm/npm/commit/319ccf633289e06e57a80d74c39706899348674c) - `glob@4.2.1`: Performance tuning. ([@isaacs](https://github.com/isaacs)) -* [`835f046`](https://github.com/npm/npm/commit/835f046e7568c33e81a0b48c84cff965024d8b8a) - `readable-stream@1.0.33`: Bug fixes. ([@rvagg](https://github.com/rvagg)) -* [`a34c38d`](https://github.com/npm/npm/commit/a34c38d0732fb246d11f2a776d2ad0d8db654338) - `request@2.48.0`: Bug fixes. ([@nylen](https://github.com/nylen)) - -### v2.1.9 (2014-11-13): - -* [`eed9f61`](https://github.com/npm/npm/commit/eed9f6101963364acffc59d7194fc1655180e80c) - [#6542](https://github.com/npm/npm/issues/6542) `npm owner add / remove` now - works properly with scoped packages - ([@othiym23](https://github.com/othiym23)) -* [`cd25973`](https://github.com/npm/npm/commit/cd25973825aa5315b7ebf26227bd32bd6be5533f) - [#6548](https://github.com/npm/npm/issues/6548) using sudo won't leave the - cache's git directories with bad permissions - ([@othiym23](https://github.com/othiym23)) -* [`56930ab`](https://github.com/npm/npm/commit/56930abcae6a6ea41f1b75e23765c61259cef2dd) - fixed irregular `npm cache ls` output (yes, that's a thing) - ([@othiym23](https://github.com/othiym23)) -* [`740f483`](https://github.com/npm/npm/commit/740f483db6ec872b453065842da080a646c3600a) - legacy tests no longer poison user's own cache - ([@othiym23](https://github.com/othiym23)) -* [`ce37f14`](https://github.com/npm/npm/commit/ce37f142a487023747a9086335618638ebca4372) - [#6169](https://github.com/npm/npm/issues/6169) add terse output similar to - `npm publish / unpublish` for `npm owner add / remove` - ([@KenanY](https://github.com/KenanY)) -* [`bf2b8a6`](https://github.com/npm/npm/commit/bf2b8a66d7188900bf1e957c052b893948b67e0e) - [#6680](https://github.com/npm/npm/issues/6680) pass auth credentials to - registry when downloading search index - ([@terinjokes](https://github.com/terinjokes)) -* [`00ecb61`](https://github.com/npm/npm/commit/00ecb6101422984696929f602e14da186f9f669c) - [#6400](https://github.com/npm/npm/issues/6400) `.npmignore` is respected for - git repos on cache / pack / publish - ([@othiym23](https://github.com/othiym23)) -* [`d1b3a9e`](https://github.com/npm/npm/commit/d1b3a9ec5e2b6d52765ba5da5afb08dba41c49c1) - [#6311](https://github.com/npm/npm/issues/6311) `npm ls -l --depth=0` no - longer prints phantom duplicate children - ([@othiym23](https://github.com/othiym23)) -* [`07c5f34`](https://github.com/npm/npm/commit/07c5f34e45c9b18c348ed53b5763b1c5d4325740) - [#6690](https://github.com/npm/npm/issues/6690) `uid-number@0.0.6`: clarify - confusing names in error-handling code ([@isaacs](https://github.com/isaacs)) -* [`1ac9be9`](https://github.com/npm/npm/commit/1ac9be9f3bab816211d72d13cb05b5587878a586) - [#6684](https://github.com/npm/npm/issues/6684) `npm init`: don't report - write if canceled ([@smikes](https://github.com/smikes)) -* [`7bb207d`](https://github.com/npm/npm/commit/7bb207d1d6592a9cffc986871e4b671575363c2f) - [#5754](https://github.com/npm/npm/issues/5754) never remove app directories - on failed install ([@othiym23](https://github.com/othiym23)) -* [`705ce60`](https://github.com/npm/npm/commit/705ce601e7b9c5428353e02ebb30cb76c1991fdd) - [#5754](https://github.com/npm/npm/issues/5754) `fs-vacuum@1.2.2`: don't - throw when another fs task writes to a directory being vacuumed - ([@othiym23](https://github.com/othiym23)) -* [`1b650f4`](https://github.com/npm/npm/commit/1b650f4f217c413a2ffb96e1701beb5aa67a0de2) - [#6255](https://github.com/npm/npm/issues/6255) ensure that order credentials - are used from `.npmrc` doesn't regress - ([@othiym23](https://github.com/othiym23)) -* [`9bb2c34`](https://github.com/npm/npm/commit/9bb2c3435cedef40b45d3e9bd7a8edfb8cbe7209) - [#6644](https://github.com/npm/npm/issues/6644) `warn` rather than `info` on - fetch failure ([@othiym23](https://github.com/othiym23)) -* [`e34a7b6`](https://github.com/npm/npm/commit/e34a7b6b7371b1893a062f627ae8e168546d7264) - [#6524](https://github.com/npm/npm/issues/6524) `npm-registry-client@4.0.2`: - proxy via `request` more transparently - ([@othiym23](https://github.com/othiym23)) -* [`40afd6a`](https://github.com/npm/npm/commit/40afd6aaf34c11a10e80ec87b115fb2bb907e3bd) - [#6524](https://github.com/npm/npm/issues/6524) push proxy settings into - `request` ([@tauren](https://github.com/tauren)) - -### v2.1.8 (2014-11-06): - -* [`063d843`](https://github.com/npm/npm/commit/063d843965f9f0bfa5732d7c2d6f5aa37a8260a2) - npm version now updates version in npm-shrinkwrap.json - ([@faiq](https://github.com/faiq)) -* [`3f53cd7`](https://github.com/npm/npm/commit/3f53cd795f8a600e904a97f215ba5b5a9989d9dd) - [#6559](https://github.com/npm/npm/issues/6559) save local dependencies in - npm-shrinkwrap.json ([@Torsph](https://github.com/Torsph)) -* [`e249262`](https://github.com/npm/npm/commit/e24926268b2d2220910bc81cce6d3b2e08d94eb1) - npm-faq.md: mention scoped pkgs in namespace Q - ([@smikes](https://github.com/smikes)) -* [`6b06ec4`](https://github.com/npm/npm/commit/6b06ec4ef5da490bdca1512fa7f12490245c192b) - [#6642](https://github.com/npm/npm/issues/6642) `init-package-json@1.1.2`: - Handle both `init-author-name` and `init.author.name`. - ([@othiym23](https://github.com/othiym23)) -* [`9cb334c`](https://github.com/npm/npm/commit/9cb334c8a895a55461aac18791babae779309a0e) - [#6409](https://github.com/npm/npm/issues/6409) document commit-ish with - GitHub URLs ([@smikes](https://github.com/smikes)) -* [`0aefae9`](https://github.com/npm/npm/commit/0aefae9bc2598a4b7a3ee7bb2306b42e3e12bb28) - [#2959](https://github.com/npm/npm/issues/2959) npm run no longer fails - silently ([@flipside](https://github.com/flipside)) -* [`e007a2c`](https://github.com/npm/npm/commit/e007a2c1e4fac1759fa61ac6e78c6b83b2417d11) - [#3908](https://github.com/npm/npm/issues/3908) include command in spawn - errors ([@smikes](https://github.com/smikes)) - -### v2.1.7 (2014-10-30): - -* [`6750b05`](https://github.com/npm/npm/commit/6750b05dcba20d8990a672957ec56c48f97e241a) - [#6398](https://github.com/npm/npm/issues/6398) `npm-registry-client@4.0.0`: - consistent API, handle relative registry paths, use auth more consistently - ([@othiym23](https://github.com/othiym23)) -* [`7719cfd`](https://github.com/npm/npm/commit/7719cfdd8b204dfeccc41289707ea58b4d608905) - [#6560](https://github.com/npm/npm/issues/6560) use new npm-registry-client - API ([@othiym23](https://github.com/othiym23)) -* [`ed61971`](https://github.com/npm/npm/commit/ed619714c93718b6c1922b8c286f4b6cd2b97c80) - move caching of search metadata from `npm-registry-client` to npm itself - ([@othiym23](https://github.com/othiym23)) -* [`3457041`](https://github.com/npm/npm/commit/34570414cd528debeb22943873440594d7f47abf) - handle caching of metadata independently from `npm-registry-client` - ([@othiym23](https://github.com/othiym23)) -* [`20a331c`](https://github.com/npm/npm/commit/20a331ced6a52faac6ec242e3ffdf28bcd447c40) - [#6538](https://github.com/npm/npm/issues/6538) map registry URLs to - credentials more safely ([@indexzero](https://github.com/indexzero)) -* [`4072e97`](https://github.com/npm/npm/commit/4072e97856bf1e7affb38333d080c172767eea27) - [#6589](https://github.com/npm/npm/issues/6589) `npm-registry-client@4.0.1`: - allow publishing of packages with names identical to built-in Node modules - ([@feross](https://github.com/feross)) -* [`254f0e4`](https://github.com/npm/npm/commit/254f0e4adaf2c56e9df25c7343c43b0b0804a3b5) - `tar@1.0.2`: better error-handling ([@runk](https://github.com/runk)) -* [`73ee2aa`](https://github.com/npm/npm/commit/73ee2aa4f1a47e43fe7cf4317a5446875f7521fa) - `request@2.47.0` ([@mikeal](https://github.com/mikeal)) - -### v2.1.6 (2014-10-23): - -* [`681b398`](https://github.com/npm/npm/commit/681b3987a18e7aba0aaf78c91a23c7cc0ab82ce8) - [#6523](https://github.com/npm/npm/issues/6523) fix default `logelevel` doc - ([@KenanY](https://github.com/KenanY)) -* [`80b368f`](https://github.com/npm/npm/commit/80b368ffd786d4d008734b56c4a6fe12d2cb2926) - [#6528](https://github.com/npm/npm/issues/6528) `npm version` should work in - a git directory without git ([@terinjokes](https://github.com/terinjokes)) -* [`5f5f9e4`](https://github.com/npm/npm/commit/5f5f9e4ddf544c2da6adf3f8c885238b0e745076) - [#6483](https://github.com/npm/npm/issues/6483) `init-package-json@1.1.1`: - Properly pick up default values from environment variables. - ([@othiym23](https://github.com/othiym23)) -* [`a114870`](https://github.com/npm/npm/commit/a1148702f53f82d49606b2e4dac7581261fff442) - perl 5.18.x doesn't like -pi without filenames - ([@othiym23](https://github.com/othiym23)) -* [`de5ba00`](https://github.com/npm/npm/commit/de5ba007a48db876eb5bfb6156435f3512d58977) - `request@2.46.0`: Tests and cleanup. - ([@othiym23](https://github.com/othiym23)) -* [`76933f1`](https://github.com/npm/npm/commit/76933f169f17b5273b32e924a7b392d5729931a7) - `fstream-npm@1.0.1`: Always include `LICENSE[.*]`, `LICENCE[.*]`, - `CHANGES[.*]`, `CHANGELOG[.*]`, and `HISTORY[.*]`. - ([@jonathanong](https://github.com/jonathanong)) - -### v2.1.5 (2014-10-16): - -* [`6a14b23`](https://github.com/npm/npm/commit/6a14b232a0e34158bd95bb25c607167be995c204) - [#6397](https://github.com/npm/npm/issues/6397) Defactor npmconf back into - npm. ([@othiym23](https://github.com/othiym23)) -* [`4000e33`](https://github.com/npm/npm/commit/4000e3333a76ca4844681efa8737cfac24b7c2c8) - [#6323](https://github.com/npm/npm/issues/6323) Install `peerDependencies` - from top. ([@othiym23](https://github.com/othiym23)) -* [`5d119ae`](https://github.com/npm/npm/commit/5d119ae246f27353b14ff063559d1ba8c616bb89) - [#6498](https://github.com/npm/npm/issues/6498) Better error messages on - malformed `.npmrc` properties. ([@nicks](https://github.com/nicks)) -* [`ae18efb`](https://github.com/npm/npm/commit/ae18efb65fed427b1ef18e4862885bf60b87b92e) - [#6093](https://github.com/npm/npm/issues/6093) Replace instances of 'hash' - with 'object' in documentation. ([@zeke](https://github.com/zeke)) -* [`53108b2`](https://github.com/npm/npm/commit/53108b276fec5f97a38250933a2768d58b6928da) - [#1558](https://github.com/npm/npm/issues/1558) Clarify how local paths - should be used. ([@KenanY](https://github.com/KenanY)) -* [`344fa1a`](https://github.com/npm/npm/commit/344fa1a219ac8867022df3dc58a47636dde8a242) - [#6488](https://github.com/npm/npm/issues/6488) Work around bug in marked. - ([@othiym23](https://github.com/othiym23)) - -OUTDATED DEPENDENCY CLEANUP JAMBOREE - -* [`60c2942`](https://github.com/npm/npm/commit/60c2942e13655d9ecdf6e0f1f97f10cb71a75255) - `realize-package-specifier@1.2.0`: Handle names and rawSpecs more - consistently. ([@iarna](https://github.com/iarna)) -* [`1b5c95f`](https://github.com/npm/npm/commit/1b5c95fbda77b87342bd48c5ecac5b1fd571ccfe) - `sha@1.3.0`: Change line endings? - ([@ForbesLindesay](https://github.com/ForbesLindesay)) -* [`d7dee3f`](https://github.com/npm/npm/commit/d7dee3f3f7d9e7c2061a4ecb4dd93e3e4bfe4f2e) - `request@2.45.0`: Dependency updates, better proxy support, better compressed - response handling, lots of 'use strict'. - ([@mikeal](https://github.com/mikeal)) -* [`3d75180`](https://github.com/npm/npm/commit/3d75180c2cc79fa3adfa0e4cb783a27192189a65) - `opener@1.4.0`: Added gratuitous return. - ([@Domenic](https://github.com/Domenic)) -* [`8e2703f`](https://github.com/npm/npm/commit/8e2703f78d280d1edeb749e257dda1f288bad6e3) - `retry@0.6.1` / `npm-registry-client@3.2.4`: Change of ownership. - ([@tim-kos](https://github.com/tim-kos)) -* [`c87b00f`](https://github.com/npm/npm/commit/c87b00f82f92434ee77831915012c77a6c244c39) - `once@1.3.1`: Wrap once with wrappy. ([@isaacs](https://github.com/isaacs)) -* [`01ec790`](https://github.com/npm/npm/commit/01ec790fd47def56eda6abb3b8d809093e8f493f) - `npm-user-validate@0.1.1`: Correct repository URL. - ([@robertkowalski](https://github.com/robertkowalski)) -* [`389e52c`](https://github.com/npm/npm/commit/389e52c2d94c818ca8935ccdcf392994fec564a2) - `glob@4.0.6`: Now absolutely requires `graceful-fs`. - ([@isaacs](https://github.com/isaacs)) -* [`e15ab15`](https://github.com/npm/npm/commit/e15ab15a27a8f14cf0d9dc6f11dee452080378a0) - `ini@1.3.0`: Tighten up whitespace handling. - ([@isaacs](https://github.com/isaacs)) -* [`7610f3e`](https://github.com/npm/npm/commit/7610f3e62e699292ece081bfd33084d436e3246d) - `archy@1.0.0` ([@substack](https://github.com/substack)) -* [`9c13149`](https://github.com/npm/npm/commit/9c1314985e513e20ffa3ea0ca333ba2ab78299c9) - `semver@4.1.0`: Add support for prerelease identifiers. - ([@bromanko](https://github.com/bromanko)) -* [`f096c25`](https://github.com/npm/npm/commit/f096c250441b031d758f03afbe8d2321f94c7703) - `graceful-fs@3.0.4`: Add a bunch of additional tests, skip the unfortunate - complications of `graceful-fs@3.0.3`. ([@isaacs](https://github.com/isaacs)) - -### v2.1.4 (2014-10-09): - -* [`3aeb440`](https://github.com/npm/npm/commit/3aeb4401444fad83cc7a8d11bf2507658afa5248) - [#6442](https://github.com/npm/npm/issues/6442) proxying git needs `GIT_SSL_CAINFO` - ([@wmertens](https://github.com/wmertens)) -* [`a8da8d6`](https://github.com/npm/npm/commit/a8da8d6e0cd56d97728c0b76b51604ee06ef6264) - [#6413](https://github.com/npm/npm/issues/6413) write builtin config on any - global npm install ([@isaacs](https://github.com/isaacs)) -* [`9e4d632`](https://github.com/npm/npm/commit/9e4d632c0142ba55df07d624667738b8727336fc) - [#6343](https://github.com/npm/npm/issues/6343) don't pass run arguments to - pre & post scripts ([@TheLudd](https://github.com/TheLudd)) -* [`d831b1f`](https://github.com/npm/npm/commit/d831b1f7ca1a9921ea5b394e39b7130ecbc6d7b4) - [#6399](https://github.com/npm/npm/issues/6399) race condition: inflight - installs, prevent `peerDependency` problems - ([@othiym23](https://github.com/othiym23)) -* [`82b775d`](https://github.com/npm/npm/commit/82b775d6ff34c4beb6c70b2344d491a9f2026577) - [#6384](https://github.com/npm/npm/issues/6384) race condition: inflight - caching by URL rather than semver range - ([@othiym23](https://github.com/othiym23)) -* [`7bee042`](https://github.com/npm/npm/commit/7bee0429066fedcc9e6e962c043eb740b3792809) - `inflight@1.0.4`: callback can take arbitrary number of parameters - ([@othiym23](https://github.com/othiym23)) -* [`3bff494`](https://github.com/npm/npm/commit/3bff494f4abf17d6d7e0e4a3a76cf7421ecec35a) - [#5195](https://github.com/npm/npm/issues/5195) fixed regex color regression - for `npm search` ([@chrismeyersfsu](https://github.com/chrismeyersfsu)) -* [`33ba2d5`](https://github.com/npm/npm/commit/33ba2d585160a0a2a322cb76c4cd989acadcc984) - [#6387](https://github.com/npm/npm/issues/6387) allow `npm view global` if - package is specified ([@evanlucas](https://github.com/evanlucas)) -* [`99c4cfc`](https://github.com/npm/npm/commit/99c4cfceed413396d952cf05f4e3c710f9682c23) - [#6388](https://github.com/npm/npm/issues/6388) npm-publish → - npm-developers(7) ([@kennydude](https://github.com/kennydude)) - -TEST CLEANUP EXTRAVAGANZA: - -* [`8d6bfcb`](https://github.com/npm/npm/commit/8d6bfcb88408f5885a2a67409854c43e5c3a23f6) - tap tests run with no system-wide side effects - ([@chrismeyersfsu](https://github.com/chrismeyersfsu)) -* [`7a1472f`](https://github.com/npm/npm/commit/7a1472fbdbe99956ad19f629e7eb1cc07ba026ef) - added npm cache cleanup script - ([@chrismeyersfsu](https://github.com/chrismeyersfsu)) -* [`0ce6a37`](https://github.com/npm/npm/commit/0ce6a3752fa9119298df15671254db6bc1d8e64c) - stripped out dead test code (othiym23) -* replace spawn with common.npm (@chrismeyersfsu): - * [`0dcd614`](https://github.com/npm/npm/commit/0dcd61446335eaf541bf5f2d5186ec1419f86a42) - test/tap/cache-shasum-fork.js - * [`97f861c`](https://github.com/npm/npm/commit/97f861c967606a7e51e3d5047cf805d9d1adea5a) - test/tap/false_name.js - * [`d01b3de`](https://github.com/npm/npm/commit/d01b3de6ce03f25bbf3db97bfcd3cc85830d6801) - test/tap/git-cache-locking.js - * [`7b63016`](https://github.com/npm/npm/commit/7b63016778124c6728d6bd89a045c841ae3900b6) - test/tap/pack-scoped.js - * [`c877553`](https://github.com/npm/npm/commit/c877553265c39673e03f0a97972f692af81a595d) - test/tap/scripts-whitespace-windows.js - * [`df98525`](https://github.com/npm/npm/commit/df98525331e964131299d457173c697cfb3d95b9) - test/tap/prepublish.js - * [`99c4cfc`](https://github.com/npm/npm/commit/99c4cfceed413396d952cf05f4e3c710f9682c23) - test/tap/prune.js - -### v2.1.3 (2014-10-02): - -BREAKING CHANGE FOR THE SQRT(i) PEOPLE ACTUALLY USING `npm submodule`: - -* [`1e64473`](https://github.com/npm/npm/commit/1e6447360207f45ad6188e5780fdf4517de6e23d) - `rm -rf npm submodule` command, which has been broken since the Carter - Administration ([@isaacs](https://github.com/isaacs)) - -BREAKING CHANGE IF YOU ARE FOR SOME REASON STILL USING NODE 0.6 AND YOU SHOULD -NOT BE DOING THAT CAN YOU NOT: - -* [`3e431f9`](https://github.com/npm/npm/commit/3e431f9d6884acb4cde8bcb8a0b122a76b33ee1d) - [joyent/node#8492](https://github.com/joyent/node/issues/8492) bye bye - customFds, hello stdio ([@othiym23](https://github.com/othiym23)) - -Other changes: - -* [`ea607a8`](https://github.com/npm/npm/commit/ea607a8a20e891ad38eed11b5ce2c3c0a65484b9) - [#6372](https://github.com/npm/npm/issues/6372) noisily error (without - aborting) on multi-{install,build} ([@othiym23](https://github.com/othiym23)) -* [`3ee2799`](https://github.com/npm/npm/commit/3ee2799b629fd079d2db21d7e8f25fa7fa1660d0) - [#6372](https://github.com/npm/npm/issues/6372) only make cache creation - requests in flight ([@othiym23](https://github.com/othiym23)) -* [`1a90ec2`](https://github.com/npm/npm/commit/1a90ec2f2cfbefc8becc6ef0c480e5edacc8a4cb) - [#6372](https://github.com/npm/npm/issues/6372) wait to put Git URLs in - flight until normalized ([@othiym23](https://github.com/othiym23)) -* [`664795b`](https://github.com/npm/npm/commit/664795bb7d8da7142417b3f4ef5986db3a394071) - [#6372](https://github.com/npm/npm/issues/6372) log what is and isn't in - flight ([@othiym23](https://github.com/othiym23)) -* [`00ef580`](https://github.com/npm/npm/commit/00ef58025a1f52dfabf2c4dc3898621d16a6e062) - `inflight@1.0.3`: fix largely theoretical race condition, because we really - really hate race conditions ([@isaacs](https://github.com/isaacs)) -* [`1cde465`](https://github.com/npm/npm/commit/1cde4658d897ae0f93ff1d65b258e1571b391182) - [#6363](https://github.com/npm/npm/issues/6363) - `realize-package-specifier@1.1.0`: handle local dependencies better - ([@iarna](https://github.com/iarna)) -* [`86f084c`](https://github.com/npm/npm/commit/86f084c6c6d7935cd85d72d9d94b8784c914d51e) - `realize-package-specifier@1.0.2`: dependency realization! in its own module! - ([@iarna](https://github.com/iarna)) -* [`553d830`](https://github.com/npm/npm/commit/553d830334552b83606b6bebefd821c9ea71e964) - `npm-package-arg@2.1.3`: simplified semver, better tests - ([@iarna](https://github.com/iarna)) -* [`bec9b61`](https://github.com/npm/npm/commit/bec9b61a316c19f5240657594f0905a92a474352) - `readable-stream@1.0.32`: for some reason - ([@rvagg](https://github.com/rvagg)) -* [`ff08ec5`](https://github.com/npm/npm/commit/ff08ec5f6d717bdbd559de0b2ede769306a9a763) - `dezalgo@1.0.1`: use wrappy for instrumentability - ([@isaacs](https://github.com/isaacs)) - -### v2.1.2 (2014-09-29): - -* [`a1aa20e`](https://github.com/npm/npm/commit/a1aa20e44bb8285c6be1e7fa63b9da920e3a70ed) - [#6282](https://github.com/npm/npm/issues/6282) - `normalize-package-data@1.0.3`: don't prune bundledDependencies - ([@isaacs](https://github.com/isaacs)) -* [`a1f5fe1`](https://github.com/npm/npm/commit/a1f5fe1005043ce20a06e8b17a3e201aa3215357) - move locks back into cache, now path-aware - ([@othiym23](https://github.com/othiym23)) -* [`a432c4b`](https://github.com/npm/npm/commit/a432c4b48c881294d6d79b5f41c2e1c16ad15a8a) - convert lib/utils/tar.js to use atomic streams - ([@othiym23](https://github.com/othiym23)) -* [`b8c3c74`](https://github.com/npm/npm/commit/b8c3c74a3c963564233204161cc263e0912c930b) - `fs-write-stream-atomic@1.0.2`: Now works with streams1 fs.WriteStreams. - ([@isaacs](https://github.com/isaacs)) -* [`c7ab76f`](https://github.com/npm/npm/commit/c7ab76f44cce5f42add5e3ba879bd10e7e00c3e6) - logging cleanup ([@othiym23](https://github.com/othiym23)) -* [`4b2d95d`](https://github.com/npm/npm/commit/4b2d95d0641435b09d047ae5cb2226f292bf38f0) - [#6329](https://github.com/npm/npm/issues/6329) efficiently validate tmp - tarballs safely ([@othiym23](https://github.com/othiym23)) - -### v2.1.1 (2014-09-26): - -* [`563225d`](https://github.com/npm/npm/commit/563225d813ea4c12f46d4f7821ac7f76ba8ee2d6) - [#6318](https://github.com/npm/npm/issues/6318) clean up locking; prefix - lockfile with "." ([@othiym23](https://github.com/othiym23)) -* [`c7f30e4`](https://github.com/npm/npm/commit/c7f30e4550fea882d31fcd4a55b681cd30713c44) - [#6318](https://github.com/npm/npm/issues/6318) remove locking code around - tarball packing and unpacking ([@othiym23](https://github.com/othiym23)) - -### v2.1.0 (2014-09-25): - -NEW FEATURE: - -* [`3635601`](https://github.com/npm/npm/commit/36356011b6f2e6a5a81490e85a0a44eb27199dd7) - [#5520](https://github.com/npm/npm/issues/5520) Add `'npm view .'`. - ([@evanlucas](https://github.com/evanlucas)) - -Other changes: - -* [`f24b552`](https://github.com/npm/npm/commit/f24b552b596d0627549cdd7c2d68fcf9006ea50a) - [#6294](https://github.com/npm/npm/issues/6294) Lock cache → lock cache - target. ([@othiym23](https://github.com/othiym23)) -* [`ad54450`](https://github.com/npm/npm/commit/ad54450104f94c82c501138b4eee488ce3a4555e) - [#6296](https://github.com/npm/npm/issues/6296) Ensure that npm-debug.log - file is created when rollbacks are done. - ([@isaacs](https://github.com/isaacs)) -* [`6810071`](https://github.com/npm/npm/commit/681007155a40ac9d165293bd6ec5d8a1423ccfca) - docs: Default loglevel "http" → "warn". - ([@othiym23](https://github.com/othiym23)) -* [`35ac89a`](https://github.com/npm/npm/commit/35ac89a940f23db875e882ce2888208395130336) - Skip installation of installed scoped packages. - ([@timoxley](https://github.com/timoxley)) -* [`e468527`](https://github.com/npm/npm/commit/e468527256ec599892b9b88d61205e061d1ab735) - Ensure cleanup executes for scripts-whitespace-windows test. - ([@timoxley](https://github.com/timoxley)) -* [`ef9101b`](https://github.com/npm/npm/commit/ef9101b7f346797749415086956a0394528a12c4) - Ensure cleanup executes for packed-scope test. - ([@timoxley](https://github.com/timoxley)) -* [`69b4d18`](https://github.com/npm/npm/commit/69b4d18cdbc2ae04c9afaffbd273b436a394f398) - `fs-write-stream-atomic@1.0.1`: Fix a race condition in our race-condition - fixer. ([@isaacs](https://github.com/isaacs)) -* [`26b17ff`](https://github.com/npm/npm/commit/26b17ff2e3b21ee26c6fdbecc8273520cff45718) - [#6272](https://github.com/npm/npm/issues/6272) `npmconf` decides what the - default prefix is. ([@othiym23](https://github.com/othiym23)) -* [`846faca`](https://github.com/npm/npm/commit/846facacc6427dafcf5756dcd36d9036539938de) - Fix development dependency is preferred over dependency. - ([@andersjanmyr](https://github.com/andersjanmyr)) -* [`9d1a9db`](https://github.com/npm/npm/commit/9d1a9db3af5adc48a7158a5a053eeb89ee41a0e7) - [#3265](https://github.com/npm/npm/issues/3265) Re-apply a71615a. Fixes - [#3265](https://github.com/npm/npm/issues/3265) again, with a test! - ([@glasser](https://github.com/glasser)) -* [`1d41db0`](https://github.com/npm/npm/commit/1d41db0b2744a7bd50971c35cc060ea0600fb4bf) - `marked-man@0.1.4`: Fixes formatting of synopsis blocks in man docs. - ([@kapouer](https://github.com/kapouer)) -* [`a623da0`](https://github.com/npm/npm/commit/a623da01bea1b2d3f3a18b9117cfd2d8e3cbdd77) - [#5867](https://github.com/npm/npm/issues/5867) Specify dummy git template - dir when cloning to prevent copying hooks. - ([@boneskull](https://github.com/boneskull)) - -### v2.0.2 (2014-09-19): - -* [`42c872b`](https://github.com/npm/npm/commit/42c872b32cadc0e555638fc78eab3a38a04401d8) - [#5920](https://github.com/npm/npm/issues/5920) - `fs-write-stream-atomic@1.0.0` ([@isaacs](https://github.com/isaacs)) -* [`6784767`](https://github.com/npm/npm/commit/6784767fe15e28b44c81a1d4bb1738c642a65d78) - [#5920](https://github.com/npm/npm/issues/5920) make all write streams atomic - ([@isaacs](https://github.com/isaacs)) -* [`f6fac00`](https://github.com/npm/npm/commit/f6fac000dd98ebdd5ea1d5921175735d463d328b) - [#5920](https://github.com/npm/npm/issues/5920) barf on 0-length cached - tarballs ([@isaacs](https://github.com/isaacs)) -* [`3b37592`](https://github.com/npm/npm/commit/3b37592a92ea98336505189ae8ca29248b0589f4) - `write-file-atomic@1.1.0`: use graceful-fs - ([@iarna](https://github.com/iarna)) - -### v2.0.1 (2014-09-18): - -* [`74c5ab0`](https://github.com/npm/npm/commit/74c5ab0a676793c6dc19a3fd5fe149f85fecb261) - [#6201](https://github.com/npm/npm/issues/6201) `npmconf@2.1.0`: scope - always-auth to registry URI ([@othiym23](https://github.com/othiym23)) -* [`774b127`](https://github.com/npm/npm/commit/774b127da1dd6fefe2f1299e73505d9146f00294) - [#6201](https://github.com/npm/npm/issues/6201) `npm-registry-client@3.2.2`: - use scoped always-auth settings ([@othiym23](https://github.com/othiym23)) -* [`f2d2190`](https://github.com/npm/npm/commit/f2d2190aa365d22378d03afab0da13f95614a583) - [#6201](https://github.com/npm/npm/issues/6201) support saving - `--always-auth` when logging in ([@othiym23](https://github.com/othiym23)) -* [`17c941a`](https://github.com/npm/npm/commit/17c941a2d583210fe97ed47e2968d94ce9f774ba) - [#6163](https://github.com/npm/npm/issues/6163) use `write-file-atomic` - instead of `fs.writeFile()` ([@fiws](https://github.com/fiws)) -* [`fb5724f`](https://github.com/npm/npm/commit/fb5724fd98e1509c939693568df83d11417ea337) - [#5925](https://github.com/npm/npm/issues/5925) `npm init -f`: allow `npm - init` to run without prompting - ([@michaelnisi](https://github.com/michaelnisi)) -* [`b706d63`](https://github.com/npm/npm/commit/b706d637d5965dbf8f7ce07dc5c4bc80887f30d8) - [#3059](https://github.com/npm/npm/issues/3059) disable prepublish when - running `npm install --production` - ([@jussi-kalliokoski](https://github.com/jussi-kalliokoski)) -* [`119f068`](https://github.com/npm/npm/commit/119f068eae2a36fa8b9c9ca557c70377792243a4) - attach the node version used when publishing a package to its registry - metadata ([@othiym23](https://github.com/othiym23)) -* [`8fe0081`](https://github.com/npm/npm/commit/8fe008181665519c2ac201ee432a3ece9798c31f) - seriously, don't use `npm -g update npm` - ([@thomblake](https://github.com/thomblake)) -* [`ea5b3d4`](https://github.com/npm/npm/commit/ea5b3d446b86dcabb0dbc6dba374d3039342ecb3) - `request@2.44.0` ([@othiym23](https://github.com/othiym23)) - -### v2.0.0 (2014-09-12): - -BREAKING CHANGES: - -* [`4378a17`](https://github.com/npm/npm/commit/4378a17db340404a725ffe2eb75c9936f1612670) - `semver@4.0.0`: prerelease versions no longer show up in ranges; `^0.x.y` - behaves the way it did in `semver@2` rather than `semver@3`; docs have been - reorganized for comprehensibility ([@isaacs](https://github.com/isaacs)) -* [`c6ddb64`](https://github.com/npm/npm/commit/c6ddb6462fe32bf3a27b2c4a62a032a92e982429) - npm now assumes that node is newer than 0.6 - ([@isaacs](https://github.com/isaacs)) - -Other changes: - -* [`ea515c3`](https://github.com/npm/npm/commit/ea515c3b858bf493a7b87fa4cdc2110a0d9cef7f) - [#6043](https://github.com/npm/npm/issues/6043) `slide@1.1.6`: wait until all - callbacks have finished before proceeding - ([@othiym23](https://github.com/othiym23)) -* [`0b0a59d`](https://github.com/npm/npm/commit/0b0a59d504f20f424294b1590ace73a7464f0378) - [#6043](https://github.com/npm/npm/issues/6043) defer rollbacks until just - before the CLI exits ([@isaacs](https://github.com/isaacs)) -* [`a11c88b`](https://github.com/npm/npm/commit/a11c88bdb1488b87d8dcac69df9a55a7a91184b6) - [#6175](https://github.com/npm/npm/issues/6175) pack scoped packages - correctly ([@othiym23](https://github.com/othiym23)) -* [`e4e48e0`](https://github.com/npm/npm/commit/e4e48e037d4e95fdb6acec80b04c5c6eaee59970) - [#6121](https://github.com/npm/npm/issues/6121) `read-installed@3.1.2`: don't - mark linked dev dependencies as extraneous - ([@isaacs](https://github.com/isaacs)) -* [`d673e41`](https://github.com/npm/npm/commit/d673e4185d43362c2b2a91acbca8c057e7303c7b) - `cmd-shim@2.0.1`: depend on `graceful-fs` directly - ([@ForbesLindesay](https://github.com/ForbesLindesay)) -* [`9d54d45`](https://github.com/npm/npm/commit/9d54d45e602d595bdab7eae09b9fa1dc46370147) - `npm-registry-couchapp@2.5.3`: make tests more reliable on Travis - ([@iarna](https://github.com/iarna)) -* [`673d738`](https://github.com/npm/npm/commit/673d738c6142c3d043dcee0b7aa02c9831a2e0ca) - ensure permissions are set correctly in cache when running as root - ([@isaacs](https://github.com/isaacs)) -* [`6e6a5fb`](https://github.com/npm/npm/commit/6e6a5fb74af10fd345411df4e121e554e2e3f33e) - prepare for upgrade to `node-semver@4.0.0` - ([@isaacs](https://github.com/isaacs)) -* [`ab8dd87`](https://github.com/npm/npm/commit/ab8dd87b943262f5996744e8d4cc30cc9358b7d7) - swap out `ronn` for `marked-man@0.1.3` ([@isaacs](https://github.com/isaacs)) -* [`803da54`](https://github.com/npm/npm/commit/803da5404d5a0b7c9defa3fe7fa0f2d16a2b19d3) - `npm-registry-client@3.2.0`: prepare for `node-semver@4.0.0` and include more - error information ([@isaacs](https://github.com/isaacs)) -* [`4af0e71`](https://github.com/npm/npm/commit/4af0e7134f5757c3d456d83e8349224a4ba12660) - make default error display less scary ([@isaacs](https://github.com/isaacs)) -* [`4fd9e79`](https://github.com/npm/npm/commit/4fd9e7901a15abff7a3dd478d99ce239b9580bca) - `npm-registry-client@3.2.1`: handle errors returned by the registry much, - much better ([@othiym23](https://github.com/othiym23)) -* [`ca791e2`](https://github.com/npm/npm/commit/ca791e27e97e51c1dd491bff6622ac90b54c3e23) - restore a long (always?) missing pass for deduping - ([@othiym23](https://github.com/othiym23)) -* [`ca0ef0e`](https://github.com/npm/npm/commit/ca0ef0e99bbdeccf28d550d0296baa4cb5e7ece2) - correctly interpret relative paths for local dependencies - ([@othiym23](https://github.com/othiym23)) -* [`5eb8db2`](https://github.com/npm/npm/commit/5eb8db2c370eeb4cd34f6e8dc6a935e4ea325621) - `npm-package-arg@2.1.2`: support git+file:// URLs for local bare repos - ([@othiym23](https://github.com/othiym23)) -* [`860a185`](https://github.com/npm/npm/commit/860a185c43646aca84cb93d1c05e2266045c316b) - tweak docs to no longer advocate checking in `node_modules` - ([@hunterloftis](https://github.com/hunterloftis)) -* [`80e9033`](https://github.com/npm/npm/commit/80e9033c40e373775e35c674faa6c1948661782b) - add links to nodejs.org downloads to docs - ([@meetar](https://github.com/meetar)) - -### v2.0.0-beta.3 (2014-09-04): - -* [`fa79413`](https://github.com/npm/npm/commit/fa794138bec8edb7b88639db25ee9c010d2f4c2b) - [#6119](https://github.com/npm/npm/issues/6119) fall back to registry installs - if package.json is missing in a local directory ([@iarna](https://github.com/iarna)) -* [`16073e2`](https://github.com/npm/npm/commit/16073e2d8ae035961c4c189b602d4aacc6d6b387) - `npm-package-arg@2.1.0`: support file URIs as local specs - ([@othiym23](https://github.com/othiym23)) -* [`9164acb`](https://github.com/npm/npm/commit/9164acbdee28956fa816ce5e473c559395ae4ec2) - `github-url-from-username-repo@1.0.2`: don't match strings that are already - URIs ([@othiym23](https://github.com/othiym23)) -* [`4067d6b`](https://github.com/npm/npm/commit/4067d6bf303a69be13f3af4b19cf4fee1b0d3e12) - [#5629](https://github.com/npm/npm/issues/5629) support saving of local packages - in `package.json` ([@dylang](https://github.com/dylang)) -* [`1b2ffdf`](https://github.com/npm/npm/commit/1b2ffdf359a8c897a78f91fc5a5d535c97aaec97) - [#6097](https://github.com/npm/npm/issues/6097) document scoped packages - ([@seldo](https://github.com/seldo)) -* [`0a67d53`](https://github.com/npm/npm/commit/0a67d536067c4808a594d81288d34c0f7e97e105) - [#6007](https://github.com/npm/npm/issues/6007) `request@2.42.0`: properly - set headers on proxy requests ([@isaacs](https://github.com/isaacs)) -* [`9bac6b8`](https://github.com/npm/npm/commit/9bac6b860b674d24251bb7b8ba412fdb26cbc836) - `npmconf@2.0.8`: disallow semver ranges in tag configuration - ([@isaacs](https://github.com/isaacs)) -* [`d2d4d7c`](https://github.com/npm/npm/commit/d2d4d7cd3c32f91a87ffa11fe464d524029011c3) - [#6082](https://github.com/npm/npm/issues/6082) don't allow tagging with a - semver range as the tag name ([@isaacs](https://github.com/isaacs)) - -### v2.0.0-beta.2 (2014-08-29): - -SPECIAL LABOR DAY WEEKEND RELEASE PARTY WOOO - -* [`ed207e8`](https://github.com/npm/npm/commit/ed207e88019de3150037048df6267024566e1093) - `npm-registry-client@3.1.7`: Clean up auth logic and improve logging around - auth decisions. Also error on trying to change a user document without - writing to it. ([@othiym23](https://github.com/othiym23)) -* [`66c7423`](https://github.com/npm/npm/commit/66c7423b7fb07a326b83c83727879410d43c439f) - `npmconf@2.0.7`: support -C as an alias for --prefix - ([@isaacs](https://github.com/isaacs)) -* [`0dc6a07`](https://github.com/npm/npm/commit/0dc6a07c778071c94c2251429c7d107e88a45095) - [#6059](https://github.com/npm/npm/issues/6059) run commands in prefix, not - cwd ([@isaacs](https://github.com/isaacs)) -* [`65d2179`](https://github.com/npm/npm/commit/65d2179af96737eb9038eaa24a293a62184aaa13) - `github-url-from-username-repo@1.0.1`: part 3 handle slashes in branch names - ([@robertkowalski](https://github.com/robertkowalski)) -* [`e8d75d0`](https://github.com/npm/npm/commit/e8d75d0d9f148ce2b3e8f7671fa281945bac363d) - [#6057](https://github.com/npm/npm/issues/6057) `read-installed@3.1.1`: - properly handle extraneous dev dependencies of required dependencies - ([@othiym23](https://github.com/othiym23)) -* [`0602f70`](https://github.com/npm/npm/commit/0602f708f070d524ad41573afd4c57171cab21ad) - [#6064](https://github.com/npm/npm/issues/6064) ls: do not show deps of - extraneous deps ([@isaacs](https://github.com/isaacs)) - -### v2.0.0-beta.1 (2014-08-28): - -* [`78a1fc1`](https://github.com/npm/npm/commit/78a1fc12307a0cbdbc944775ed831b876ee65855) - `github-url-from-git@1.4.0`: add support for git+https and git+ssh - ([@stefanbuck](https://github.com/stefanbuck)) -* [`bf247ed`](https://github.com/npm/npm/commit/bf247edf5429c6b3ec4d4cb798fa0eb0a9c19fc1) - `columnify@1.2.1` ([@othiym23](https://github.com/othiym23)) -* [`4bbe682`](https://github.com/npm/npm/commit/4bbe682a6d4eabcd23f892932308c9f228bf4de3) - `cmd-shim@2.0.0`: upgrade to graceful-fs 3 - ([@ForbesLindesay](https://github.com/ForbesLindesay)) -* [`ae1d590`](https://github.com/npm/npm/commit/ae1d590bdfc2476a4ed446e760fea88686e3ae05) - `npm-package-arg@2.0.4`: accept slashes in branch names - ([@thealphanerd](https://github.com/thealphanerd)) -* [`b2f51ae`](https://github.com/npm/npm/commit/b2f51aecadf585711e145b6516f99e7c05f53614) - `semver@3.0.1`: semver.clean() is cleaner - ([@isaacs](https://github.com/isaacs)) -* [`1d041a8`](https://github.com/npm/npm/commit/1d041a8a5ebd5bf6cecafab2072d4ec07823adab) - `github-url-from-username-repo@1.0.0`: accept slashes in branch names - ([@robertkowalski](https://github.com/robertkowalski)) -* [`02c85d5`](https://github.com/npm/npm/commit/02c85d592c4058e5d9eafb0be36b6743ae631998) - `async-some@1.0.1` ([@othiym23](https://github.com/othiym23)) -* [`5af493e`](https://github.com/npm/npm/commit/5af493efa8a463cd1acc4a9a394699e2c0793b9c) - ensure lifecycle spawn errors caught properly - ([@isaacs](https://github.com/isaacs)) -* [`60fe012`](https://github.com/npm/npm/commit/60fe012fac9570d6c72554cdf34a6fa95bf0f0a6) - `npmconf@2.0.6`: init.version defaults to 1.0.0 - ([@isaacs](https://github.com/isaacs)) -* [`b4c717b`](https://github.com/npm/npm/commit/b4c717bbf58fb6a0d64ad229036c79a184297ee2) - `npm-registry-client@3.1.4`: properly encode % in passwords - ([@isaacs](https://github.com/isaacs)) -* [`7b55f44`](https://github.com/npm/npm/commit/7b55f44420252baeb3f30da437d22956315c31c9) - doc: Fix 'npm help index' ([@isaacs](https://github.com/isaacs)) - -### v2.0.0-beta.0 (2014-08-21): - -* [`685f8be`](https://github.com/npm/npm/commit/685f8be1f2770cc75fd0e519a8d7aac72735a270) - `npm-registry-client@3.1.3`: Print the notification header returned by the - registry, and make sure status codes are printed without gratuitous quotes - around them. ([@isaacs](https://github.com/isaacs) / - [@othiym23](https://github.com/othiym23)) -* [`a8cb676`](https://github.com/npm/npm/commit/a8cb676aef0561eaf04487d2719672b097392c85) - [#5900](https://github.com/npm/npm/issues/5900) remove `npm` from its own - `engines` field in `package.json`. None of us remember why it was there. - ([@timoxley](https://github.com/timoxley)) -* [`6c47201`](https://github.com/npm/npm/commit/6c47201a7d071e8bf091b36933daf4199cc98e80) - [#5752](https://github.com/npm/npm/issues/5752), - [#6013](https://github.com/npm/npm/issues/6013) save git URLs correctly in - `_resolved` fields ([@isaacs](https://github.com/isaacs)) -* [`e4e1223`](https://github.com/npm/npm/commit/e4e1223a91c37688ba3378e1fc9d5ae045654d00) - [#5936](https://github.com/npm/npm/issues/5936) document the use of tags in - `package.json` ([@KenanY](https://github.com/KenanY)) -* [`c92b8d4`](https://github.com/npm/npm/commit/c92b8d4db7bde2a501da5b7d612684de1d629a42) - [#6004](https://github.com/npm/npm/issues/6004) manually installed scoped - packages are tracked correctly ([@dead](https://github.com/dead)-horse) -* [`21ca0aa`](https://github.com/npm/npm/commit/21ca0aaacbcfe2b89b0a439d914da0cae62de550) - [#5945](https://github.com/npm/npm/issues/5945) link scoped packages - correctly ([@dead](https://github.com/dead)-horse) -* [`16bead7`](https://github.com/npm/npm/commit/16bead7f2c82aec35b83ff0ec04df051ba456764) - [#5958](https://github.com/npm/npm/issues/5958) ensure that file streams work - in all versions of node ([@dead](https://github.com/dead)-horse) -* [`dbf0cab`](https://github.com/npm/npm/commit/dbf0cab29d0db43ac95e4b5a1fbdea1e0af75f10) - you can now pass quoted args to `npm run-script` - ([@bcoe](https://github.com/bcoe)) -* [`0583874`](https://github.com/npm/npm/commit/05838743f01ccb8d2432b3858d66847002fb62df) - `tar@1.0.1`: Add test for removing an extract target immediately after - unpacking. - ([@isaacs](https://github.com/isaacs)) -* [`cdf3b04`](https://github.com/npm/npm/commit/cdf3b0428bc0b0183fb41dcde9e34e8f42c5e3a7) - `lockfile@1.0.0`: Fix incorrect interaction between `wait`, `stale`, and - `retries` options. Part 2 of race condition leading to `ENOENT` - ([@isaacs](https://github.com/isaacs)) - errors. -* [`22d72a8`](https://github.com/npm/npm/commit/22d72a87a9e1a9ab56d9585397f63551887d9125) - `fstream@1.0.2`: Fix a double-finish call which can result in excess FS - operations after the `close` event. Part 1 of race condition leading to - `ENOENT` errors. - ([@isaacs](https://github.com/isaacs)) - -### v2.0.0-alpha.7 (2014-08-14): - -* [`f23f1d8`](https://github.com/npm/npm/commit/f23f1d8e8f86ec1b7ab8dad68250bccaa67d61b1) - doc: update version doc to include `pre-*` increment args - ([@isaacs](https://github.com/isaacs)) -* [`b6bb746`](https://github.com/npm/npm/commit/b6bb7461824d4dc1c0936f46bd7929b5cd597986) - build: add 'make tag' to tag current release as latest - ([@isaacs](https://github.com/isaacs)) -* [`27c4bb6`](https://github.com/npm/npm/commit/27c4bb606e46e5eaf604b19fe8477bc6567f8b2e) - build: publish with `--tag=v1.4-next` ([@isaacs](https://github.com/isaacs)) -* [`cff66c3`](https://github.com/npm/npm/commit/cff66c3bf2850880058ebe2a26655dafd002495e) - build: add script to output `v1.4-next` publish tag - ([@isaacs](https://github.com/isaacs)) -* [`22abec8`](https://github.com/npm/npm/commit/22abec8833474879ac49b9604c103bc845dad779) - build: remove outdated `docpublish` make target - ([@isaacs](https://github.com/isaacs)) -* [`1be4de5`](https://github.com/npm/npm/commit/1be4de51c3976db8564f72b00d50384c921f0917) - build: remove `unpublish` step from `make publish` - ([@isaacs](https://github.com/isaacs)) -* [`e429e20`](https://github.com/npm/npm/commit/e429e2011f4d78e398f2461bca3e5a9a146fbd0c) - doc: add new changelog ([@othiym23](https://github.com/othiym23)) -* [`9243d20`](https://github.com/npm/npm/commit/9243d207896ea307082256604c10817f7c318d68) - lifecycle: test lifecycle path modification - ([@isaacs](https://github.com/isaacs)) -* [`021770b`](https://github.com/npm/npm/commit/021770b9cb07451509f0a44afff6c106311d8cf6) - lifecycle: BREAKING CHANGE do not add the directory containing node executable - ([@chulkilee](https://github.com/chulkilee)) -* [`1d5c41d`](https://github.com/npm/npm/commit/1d5c41dd0d757bce8b87f10c4135f04ece55aeb9) - install: rename .gitignore when unpacking foreign tarballs - ([@isaacs](https://github.com/isaacs)) -* [`9aac267`](https://github.com/npm/npm/commit/9aac2670a73423544d92b27cc301990a16a9563b) - cache: detect non-gzipped tar files more reliably - ([@isaacs](https://github.com/isaacs)) -* [`3f24755`](https://github.com/npm/npm/commit/3f24755c8fce3c7ab11ed1dc632cc40d7ef42f62) - `readdir-scoped-modules@1.0.0` ([@isaacs](https://github.com/isaacs)) -* [`151cd2f`](https://github.com/npm/npm/commit/151cd2ff87b8ac2fc9ea366bc9b7f766dc5b9684) - `read-installed@3.1.0` ([@isaacs](https://github.com/isaacs)) -* [`f5a9434`](https://github.com/npm/npm/commit/f5a94343a8ebe4a8cd987320b55137aef53fb3fd) - test: fix Travis timeouts ([@dylang](https://github.com/dylang)) -* [`126cafc`](https://github.com/npm/npm/commit/126cafcc6706814c88af3042f2ffff408747bff4) - `npm-registry-couchapp@2.5.0` ([@othiym23](https://github.com/othiym23)) - -### v2.0.0-alpha.6 (2014-08-07): - -BREAKING CHANGE: - -* [`ea547e2`](https://github.com/npm/npm/commit/ea547e2) Bump semver to - version 3: `^0.x.y` is now functionally the same as `=0.x.y`. - ([@isaacs](https://github.com/isaacs)) - -Other changes: - -* [`d987707`](https://github.com/npm/npm/commit/d987707) move fetch into - npm-registry-client ([@othiym23](https://github.com/othiym23)) -* [`9b318e2`](https://github.com/npm/npm/commit/9b318e2) `read-installed@3.0.0` - ([@isaacs](https://github.com/isaacs)) -* [`9d73de7`](https://github.com/npm/npm/commit/9d73de7) remove unnecessary - mkdirps ([@isaacs](https://github.com/isaacs)) -* [`33ccd13`](https://github.com/npm/npm/commit/33ccd13) Don't squash execute - perms in `_git-remotes/` dir ([@adammeadows](https://github.com/adammeadows)) -* [`48fd233`](https://github.com/npm/npm/commit/48fd233) `npm-package-arg@2.0.1` - ([@isaacs](https://github.com/isaacs)) - -### v2.0.0-alpha-5 (2014-07-22): - -This release bumps up to 2.0 because of this breaking change, which could -potentially affect how your package's scripts are run: - -* [`df4b0e7`](https://github.com/npm/npm/commit/df4b0e7fc1abd9a54f98db75ec9e4d03d37d125b) - [#5518](https://github.com/npm/npm/issues/5518) BREAKING CHANGE: support - passing arguments to `run` scripts ([@bcoe](https://github.com/bcoe)) - -Other changes: - -* [`cd422c9`](https://github.com/npm/npm/commit/cd422c9de510766797c65720d70f085000f50543) - [#5748](https://github.com/npm/npm/issues/5748) link binaries for scoped - packages ([@othiym23](https://github.com/othiym23)) -* [`4c3c778`](https://github.com/npm/npm/commit/4c3c77839920e830991e0c229c3c6a855c914d67) - [#5758](https://github.com/npm/npm/issues/5758) `npm link` includes scope - when linking scoped package ([@fengmk2](https://github.com/fengmk2)) -* [`f9f58dd`](https://github.com/npm/npm/commit/f9f58dd0f5b715d4efa6619f13901916d8f99c47) - [#5707](https://github.com/npm/npm/issues/5707) document generic pre- / - post-commands ([@sudodoki](https://github.com/sudodoki)) -* [`ac7a480`](https://github.com/npm/npm/commit/ac7a4801d80361b41dce4a18f22bcdf75e396000) - [#5406](https://github.com/npm/npm/issues/5406) `npm cache` displays usage - when called without arguments - ([@michaelnisi](https://github.com/michaelnisi)) -* [`f4554e9`](https://github.com/npm/npm/commit/f4554e99d34f77a8a02884493748f7d49a9a9d8b) - Test fixes for Windows ([@isaacs](https://github.com/isaacs)) -* update dependencies ([@othiym23](https://github.com/othiym23)) diff --git a/changelogs/CHANGELOG-3.md b/changelogs/CHANGELOG-3.md deleted file mode 100644 index fc55a69..0000000 --- a/changelogs/CHANGELOG-3.md +++ /dev/null @@ -1,5245 +0,0 @@ -### v3.10.10 (2016-11-04) - -See the discussion on [#14042](https://github.com/npm/npm/issues/14042) for -more context on this release, which is intended to address a serious regression -in shrinkwrap behavior in the version of the CLI currently bundled with Node.js -6 LTS "Boron". You should never install this version directly; instead update -to `npm@4`, which has everything in this release and more. - -#### REGRESSION FIX - -* [`9aebe98`](https://github.com/npm/npm/commit/9aebe982114ea2107f46baa1dcb11713b4aaad04) - [#14117](https://github.com/npm/npm/pull/14117) - Fixes a bug where installing a shrinkwrapped package would fail if the - platform failed to install an optional dependency included in the shrinkwrap. - ([@watilde](https://github.com/watilde)) - -#### UPDATE SUPPORT MATRIX - -With the advent of the second official Node.js LTS release, Node 6.x -'Boron', the Node.js project has now officially dropped versions 0.10 -and 0.12 out of the maintenance phase of LTS. (Also, Node 5 was never -part of LTS, and will see no further support now that Node 7 has been -released.) As a small team with limited resources, the npm CLI team is -following suit and dropping those versions of Node from its CI test -matrix. - -* [`c82ecfd`](https://github.com/npm/npm/commit/c82ecfdbe0b5f318a175714a8753efe4dfd3e4b3) - [#14503](https://github.com/npm/npm/pull/14503) - Node 6 is LTS; 5.x, 0.10, and 0.12 are unsupported. - ([@othiym23](https://github.com/othiym23)) - -### v3.10.9 (2016-10-06) - -Hi everyone! This is the last of our monthly releases. We're going to give -an every-two-weeks schedule a try starting with our next release. We'll -reevaluate in a quarter, but we suspect that will be what we'll stick with. -You might be wondering _why_ we've been fiddling with the release cadence? Well, -we've been trying to tune it to to minimize the overhead for our little team. - -This is ALSO the ULTIMATE release of `npm` version 3. That's right, in -just two weeks' time (October 20th for you fans of calendar time), our dear -`npm` will be hitting the big 4.0. - -**DON'T PANIC** - -This is gonna be a much, MUCH smaller major version than 3.x was. Maybe even -smaller than 2.x was. I can't tell you everything that'll be in there just -yet, but at the very least it's going to have what's in our -[4.x milestone](https://github.com/npm/npm/pulls?q=is%3Aopen+is%3Apr+milestone%3A4.x), -PLUS, the first steps in -[making `prepublish` work](https://github.com/npm/npm/issues/10074) the way -people expect it to. - -**NOW ABOUT THIS RELEASE** - -This release sees a whole slew of bug fixes. Notably a bunch of lifecycle -fixes and a really important shrinkwrap fix. - -#### LIFECYCLE FIXES - -* [`d388f90`](https://github.com/npm/npm/commit/d388f90732981633b3cdb4fc7fb0fababd4e64ab) - [#13942](https://github.com/npm/npm/pull/13942) - Fix current working directory while running shrinkwrap lifecycle scripts. - Previously if you ran a shrinkwrap from another lifecycle script AND - `node_modules` existed (and if you're running `npm shrinkwrap` it probably - should) then `npm` would run the shrinkwrap lifecycle from the - `node_modules` folder instead of the package folder. - ([@evocateur](https://github.com/evocateur)) - ([@iarna](https://github.com/iarna)) -* [`c3b6cdf`](https://github.com/npm/npm/commit/c3b6cdfedcdb4d9e7712be5245d9b274828d88d1) - [#13964](https://github.com/npm/npm/pull/13964) - Fix bug where the `uninstall` lifecycles weren't being run when you - reinstalled/updated an existing module. - ([@iarna](https://github.com/iarna)) -* [`72bb89c`](https://github.com/npm/npm/commit/72bb89c1aa9811a18cbd766f3da73da76eb920c6) - [#13344](https://github.com/npm/npm/pull/13344) - When running lifecycles use `TMPDIR` if it's writable and fall back to the - current working directory if not. Previously we just assumed `TMPDIR` - wouldn't be writable (as we might have been running as `nobody` and - `nobody` on some systems can't write to `TMPDIR`). - ([@aaronjensen](https://github.com/aaronjensen)) - -#### SHRINKWRAP GIT & TAGGED DEPENDENCY FIX - -* [`3b5eee0`](https://github.com/npm/npm/commit/3b5eee0d31737d1c2518ed95dcc7aaaaa93c253c) - [#13941](https://github.com/npm/npm/pull/13941) - Fix git and tagged dependency matching with shrinkwraps. Previously git - and tag (ie `foo@latest`) dependencies installed from a shrinkwrap would - always be flagged as invalid. - ([@iarna](https://github.com/iarna)) - -#### BUG FIXES - -* [`bf3bd1e`](https://github.com/npm/npm/commit/bf3bd1e4347ee2c5de08d23558c4444749178c8b) - [#14143](https://github.com/npm/npm/pull/14143) - Fix bug in `npm version` where `npm-shrinkwrap.json` wouldn't be updated - if you ran `npm version` from outside of your project root. - ([@lholmquist](https://github.com/lholmquist)) -* [`1089878`](https://github.com/npm/npm/commit/1089878f58977559414c8a9addfc69a9c68905b0) - [#13613](https://github.com/npm/npm/pull/13613) - Log 'skipping action' as 'verbose' instead of 'warn'. This removes a lot of - clutter when there are links in your `node_modules`. The long term plan is - to entirely blind `npm` to what's inside links, which will make this code - go away entirely. - ([@timoxley](https://github.com/timoxley)) -* [`952f1e1`](https://github.com/npm/npm/commit/952f1e109a070ab4066179f6104ba9394300e342) - [#13999](https://github.com/npm/npm/pull/13999) - Fix a bug where setting `bin` to `null` in your `package.json` would result - in `npm` crashing. - ([@IonicaBizau](https://github.com/IonicaBizau)) -* [`fcf8b11`](https://github.com/npm/npm/commit/fcf8b11fb7fcf8902f6a887c3d5f0aef2897dde0) - [#14032](https://github.com/npm/npm/pull/14032) - When using `npm view`, if you specified a version that didn't exist it - would previously print `undefined` (even if you asked for JSON output). It - now prints nothing in this situation. This brings `npm@3`'s behavior in - line with `npm@2`. - ([@roblg](https://github.com/roblg)) -* [`93c689f`](https://github.com/npm/npm/commit/93c689ff44c6042a2dcde7fe0d74d2264237d666) - [#14032](https://github.com/npm/npm/pull/14032) - When using `npm view --json` with a version range that matches multiple - versions we now return a list of all of the metadata for all of those - versions. Previously we picked one and only returned that. This brings - `npm@3`'s behavior in line with `npm@2`. - ([@roblg](https://github.com/roblg)) -* [`2411728`](https://github.com/npm/npm/commit/24117289e09c373b845150c45e4793d98fe7cf4b) - [#14045](https://github.com/npm/npm/pull/14045) - Fix a Windows-only bug in the `git` tests. The tests had rather particular - ideas about what arguments would be passed to `git` and on Windows they - got this wrong. - ([@watilde](https://github.com/watilde)) - -#### DOCUMENTATION & MISC - -* [`30772cc`](https://github.com/npm/npm/commit/30772cc5f80923bf21c003fbe53e5fed9d3a5d97) - [#13904](https://github.com/npm/npm/pull/13904) - Update `package.json` example to include GitHub branches. - ([@stevokk](https://github.com/stevokk)) -* [`f66876f`](https://github.com/npm/npm/commit/f66876f75c204fb78028cf2ff7979f80355bd06c) - [#14010](https://github.com/npm/npm/pull/14010) - Update the GitHub issue template to reflect Apple's change in name of its - desktop operating system. - ([@AlexChesters](https://github.com/AlexChesters)) - -#### DEPENDENCY UPDATES - -* [`b3f9bf1`](https://github.com/npm/npm/commit/b3f9bf1ada3f93e6775f5c232350030db6635d0c) - [#13918](https://github.com/npm/npm/issues/13918) - `graceful-fs@4.1.9`: - Fix the _uid must be an unsigned int_ bug that's been around forever but that - `npm` started tickling in v3.10.8. - ([@addaleax](https://github.com/addaleax)) - Also fixes wrapper to `fs.readdir` to actually pass through (rather than - drop) optional arguments. - ([@isaacs](https://github.com/isaacs)) -* [`9402ead`](https://github.com/npm/npm/commit/9402ead67e3be9b431ade637fbfac86204ee96fe) - [isaacs/node-glob#293](https://github.com/isaacs/node-glob/pull/293) - `glob@7.1.0`: - Add `absolute` option for `match` event. - ([@phated](https://github.com/phated)) -* [`58b83db`](https://github.com/npm/npm/commit/58b83db327dd87bf7cb5a7d503303537718f2f30) - `asap@2.0.5` - ([@kriskowal](https://github.com/kriskowal)) -* [`5707e6e`](https://github.com/npm/npm/commit/5707e6e55b220439c3f83e77daf4c70d72eb46f0) - `sorted-object@2.0.1` - ([@domenic](https://github.com/domenic)) -* [`9d20910`](https://github.com/npm/npm/commit/9d209107ce49a7424c50459284280cd2e6e215d1) - `request@2.75.0` - ([@simov](https://github.com/simov)) -* [`dea4848`](https://github.com/npm/npm/commit/dea48487a9d03492edc68670d05776d32d9ee8cf) - `path-is-inside@1.0.2` - ([@domenic](https://github.com/domenic)) -* [`b3f3db5`](https://github.com/npm/npm/commit/b3f3db52e864d607b6d9b18920e2f58acc4b1616) - `opener@1.4.2` - ([@dominic](https://github.com/dominic)) -* [`6bb5f95`](https://github.com/npm/npm/commit/6bb5f953888bbaaeeb624d623c2a9746d1c243a0) - `lockfile@1.0.2` - ([@isaacs](https://github.com/isaacs)) -* [`13f7c0a`](https://github.com/npm/npm/commit/13f7c0a73212284b53a2d96882fc298afbf9609c) - `config-chain@1.1.11` - ([@dominictarr](https://github.com/dominictarr)) - -### v3.10.8 (2016-09-08) - -Monthly releases are so big! Just look at all this stuff! - -Our quarter of monthly releases is almost over. The next one, in October, might -very well be our last one as we move to trying something different and learning -lessons from our little experiment. - -You may also want to keep an eye our for `npm@4` next month, since we're -planning on finally releasing it then and including a (small) number of breaking -changes we've been meaning to do for a long time. Don't worry, though: `npm@3` -will still be around for a bit and will keep getting better and better, and is -most likely going to be the version that `node@6` uses once it goes to LTS. - -As some of us have mentioned before, npm is likely to start doing more regular -semver-major bumps, while keeping those bumps significantly smaller than the -huge effort that was `npm@3` -- we're not very likely to do a world-shaking -thing like that for a while, if ever. - -All that said, let's move on to the patches included in v3.10.8! - -#### SHRINKWRAP LEVEL UP - -The most notable part of this release is a series of commits meant to make `npm -shrinkwrap` more consistent. By itself, shrinkwrap seems like a fairly -straightforward thing to implement, but things get complicated when it starts -interacting with `devDependencies`, `optionalDependencies`, and -`bundledDependencies`. These commits address some corner cases related to these. - -* [`a7eca32`](https://github.com/npm/npm/commit/a7eca3246fbbcbb05434cb6677f65d14c945d74f) - [#10073](https://github.com/npm/npm/pull/10073) - Record if a dependency is only used as a devDependency and exclude it from the - shrinkwrap file. - ([@bengl](https://github.com/bengl)) -* [`1eabcd1`](https://github.com/npm/npm/commit/1eabcd16bf2590364ca20831096350073539bf3a) - [#10073](https://github.com/npm/npm/pull/10073) - Record if a dependency is optional to shrinkwrap. - ([@bengl](https://github.com/bengl)) -* [`03efc89`](https://github.com/npm/npm/commit/03efc89522c99ee0fa37d8f4a99bc3b44255ef98) - [#13692](https://github.com/npm/npm/pull/13692/) - We were doing a weird thing where we used a `package.json` field `installable` - to check to see if we'd checked for platform compatibility, and if not did - so. But this was the only place that was ever done so there was no reason to - implement it in such an obfuscated manner. - Instead it now just directly checks and then records that its done so on the - node object with `knownInstallable`. This is useful to know because modules - expanded via shrinkwrap don't go through this– `inflateShrinkwrap` does not - currently have any rollback semantics and so checking this sort of thing there - is unhelpful. - ([@iarna](https://github.com/iarna)) -* [`ff87938`](https://github.com/npm/npm/commit/ff879382fda21dac7216a5f666287b3a7e74a947) - [#11735](https://github.com/npm/npm/issues/11735) - Running `npm install --save-dev` will now update shrinkwrap file, but only - if there already are devDependencies in it. - ([@szimek](https://github.com/szimek)) -* [`c00ca3a`](https://github.com/npm/npm/commit/c00ca3aef836709eeaeade91c5305bc2fbda2e8a) - [#13394](https://github.com/npm/npm/issues/13394) - Check installability of modules from shrinkwrap, since modules that came into - the tree vie shrinkwrap won't already have this information recorded in - advance. - ([@iarna](https://github.com/iarna)) - -#### INSTALLER ERROR REPORTING LEVEL UP - -As part of the shrinkwrap push, there were also a lot of error-reporting -improvements. Some to add more detail to error objects, others to fix bugs and -inconsistencies. - -* [`2cdd713`](https://github.com/npm/npm/commit/2cdd7132abddcc7f826a355c14348ce9a5897ffe) - Consistently set code on `ETARGET` when fetching package metadata if no - compatible version is found. - ([@iarna](https://github.com/iarna)) -* [`cabcd17`](https://github.com/npm/npm/commit/cabcd173f2923cb5b77e7be0e42eea2339a24727) - [#13692](https://github.com/npm/npm/pull/13692/) - Include installer warning details at the `verbose` log level. - ([@iarna](https://github.com/iarna)) -* [`95a4044`](https://github.com/npm/npm/commit/95a4044cbae93d19d0da0f3cd04ea8fa620295d9) - [`dbb14c2`](https://github.com/npm/npm/commit/dbb14c241d982596f1cdaee251658f5716989fd2) - [`9994383`](https://github.com/npm/npm/commit/9994383959798f80749093301ec43a8403566bb6) - [`7417000`](https://github.com/npm/npm/commit/74170003db0c53def9b798cb6fe3fe7fc3e06482) - [`f45f85d`](https://github.com/npm/npm/commit/f45f85dac800372d63dfa8653afccbf5bcae7295) - [`e79cc1b`](https://github.com/npm/npm/commit/e79cc1b11440f0d122c4744d5eff98def9553f4a) - [`146ee39`](https://github.com/npm/npm/commit/146ee394b1f7a33cf409a30b835a85d939acb438) - [#13692](https://github.com/npm/npm/pull/13692/) - Improve various bits of error reporting, adding more error information and - some related refactoring. - ([@iarna](https://github.com/iarna)) - -#### MISCELLANEOUS BUGS LEVEL UP - -* [`116b6c6`](https://github.com/npm/npm/commit/116b6c60a174ea0cc49e4d62717e4e26175b6534) - [#13456](https://github.com/npm/npm/issues/13456) - In lifecycle scripts, any `node_modules/.bin` existing in the hierarchy - should be turned into an entry in the PATH environment variable. - However, prior to this commit, it was splitting based on the string - `node_modules`, rather than restricting it to only path portions like - `/node_modules/` or `\node_modules\`. So, a path containing an entry - like `my_node_modules` would be improperly split. - ([@isaacs](https://github.com/isaacs)) -* [`0a28dd0`](https://github.com/npm/npm/commit/0a28dd0104e5b4a8cc0cb038bd213e6a50827fe8) - [npm/fstream-npm#23](https://github.com/npm/fstream-npm/pull/23) - `fstream-npm@1.2.0`: - Always ignore `*.orig` files, which are generated by git when using `git - mergetool`, by default. - ([@zkat](https://github.com/zkat)) -* [`a3a2fb9`](https://github.com/npm/npm/commit/a3a2fb97adc87c2aa9b2b8957861b30efafc7ad0) - [#13708](https://github.com/npm/npm/pull/13708) - Always ignore `*.orig` files, which are generated by git when using `git - mergetool`, by default. - ([@boneskull](https://github.com/boneskull)) - -#### TOOLING LEVEL UP - -* [`e1d7e6c`](https://github.com/npm/npm/commit/e1d7e6ce551cbc42026cdcadcb37ea515059c972) - Add helper for generating test skeletons. - ([@iarna](https://github.com/iarna)) -* [`4400b35`](https://github.com/npm/npm/commit/4400b356bca9175935edad1469c608c909bc01bf) - Fix fixture creation and cleanup in `maketest`. - ([@iarna](https://github.com/iarna)) - -#### DOCUMENTATION LEVEL UP - -* [`8eb9460`](https://github.com/npm/npm/commit/8eb94601fe895b97cbcf8c6134e6b371c5371a1e) - [#13717](https://github.com/npm/npm/pull/13717) - Document that `npm link` will link the files specified in the `bin` field of - `package.json` to `{prefix}/bin/{name}`. - ([@legodude17](https://github.com/legodude17)) -* [`a66e5e9`](https://github.com/npm/npm/commit/a66e5e9c388878fe03fb29014c3b95d28bedd3c1) - [#13682](https://github.com/npm/npm/pull/13682) - Minor grammar fix in documentation for `npm scripts`. - ([@Ajedi32](https://github.com/Ajedi32)) -* [`74b8043`](https://github.com/npm/npm/commit/74b80437ffdfcf8172f6ed4f39bfb021608dd9dd) - [#13655](https://github.com/npm/npm/pull/13655) - Document line comment syntax for `.npmrc`. - ([@mdjasper](https://github.com/mdjasper)) -* [`b352a84`](https://github.com/npm/npm/commit/b352a84c2c7ad15e9c669af75f65cdaa964f86c0) - [#12438](https://github.com/npm/npm/issues/12438) - Remind folks to use `#!/usr/bin/env node` in their `bin` scripts to make files - executable directly. - ([@mxstbr](https://github.com/mxstbr)) -* [`b82fd83`](https://github.com/npm/npm/commit/b82fd838edbfff5d2833a62f6d8ae8ea2df5a1f2) - [#13493](https://github.com/npm/npm/pull/13493) - Document that the user config file can itself be configured either through the - `$NPM_CONFIG_USERCONFIG` environment variable, or `--userconfig` command line - flag. - ([@jasonkarns](https://github.com/jasonkarns)) -* [`8a02699`](https://github.com/npm/npm/commit/8a026992a03d90e563a97c70e90926862120693b) - [#13911](https://github.com/npm/npm/pull/13911) - Minor documentation reword and cleanup. - ([@othiym23](https://github.com/othiym23)) - -#### DEPENDENCY LEVEL UP - -* [`2818fb0`](https://github.com/npm/npm/commit/2818fb0f6081d68a91f0905945ad102f26c6cf85) - `glob@7.0.6` - ([@isaacs](https://github.com/isaacs)) -* [`d88ec81`](https://github.com/npm/npm/commit/d88ec81ad33eb2268fcd517d35346a561bc59aff) - `graceful-fs@4.1.6` - ([@francescoinfante](https://github.com/francescoinfante)) -* [`4727f86`](https://github.com/npm/npm/commit/4727f8646daca7b3e3c1c95860e02acf583b9dae) - `lodash.clonedeep@4.5.0` - ([@jdalton](https://github.com/jdalton)) -* [`c347678`](https://github.com/npm/npm/commit/c3476780ef4483425e4ae1d095a5884b46b8db86) - `lodash.union@4.6.0` - ([@jdalton](https://github.com/jdalton)) -* [`530bd4d`](https://github.com/npm/npm/commit/530bd4d2ae6f704f624e4f7bf64f911f37e2b7f8) - `lodash.uniq@4.5.0` - ([@jdalton](https://github.com/jdalton)) -* [`483d56a`](https://github.com/npm/npm/commit/483d56ae8137eca0c0f7acd5d1c88ca6d5118a6a) - `lodash.without@4.4.0` - ([@jdalton](https://github.com/jdalton)) -* [`6c934df`](https://github.com/npm/npm/commit/6c934df6e74bacd0ed40767b319936837a43b586) - `inherits@2.0.3` - ([@isaacs](https://github.com/isaacs)) -* [`a65ed7c`](https://github.com/npm/npm/commit/a65ed7cbd3c950383a14461a4b2c87b67ef773b9) - `npm-registry-client@7.2.1`: - * [npm/npm-registry-client#142](https://github.com/npm/npm-registry-client/pull/142) Fix `EventEmitter` warning spam from error handlers on socket. ([@addaleax](https://github.com/addaleax)) - * [npm/npm-registry-client#131](https://github.com/npm/npm-registry-client/pull/131) Adds support for streaming request bodies. ([@aredridel](https://github.com/aredridel)) - * Fixes [#13656](https://github.com/npm/npm/issues/13656). - * Dependency updates. - * Documentation improvements. - ([@othiym23](https://github.com/othiym23)) -* [`2b88d62`](https://github.com/npm/npm/commit/2b88d62e6a730716b27052c0911c094d01830a60) - [npm/npmlog#34](https://github.com/npm/npmlog/pull/34) - `npmlog@4.0.0`: - Allows creating log levels that are empty strings or 0 - ([@rwaldron](https://github.com/rwaldron)) -* [`242babb`](https://github.com/npm/npm/commit/242babbd02274ee2d212ae143992c20f47ef0066) - `once@1.4.0` - ([@zkochan](https://github.com/zkochan)) -* [`6d8ba2b`](https://github.com/npm/npm/commit/6d8ba2b4918e2295211130af68ee8a67099139e0) - `readable-stream@2.1.5` - ([@calvinmetcalf](https://github.com/calvinmetcalf)) -* [`855c099`](https://github.com/npm/npm/commit/855c099482a8d93b7f0646bd7bcf8a31f81868e0) - `retry@0.10.0` - ([@tim-kos](https://github.com/tim-kos)) -* [`80540c5`](https://github.com/npm/npm/commit/80540c52b252615ae8a6271b3df870eabfea935e) - `semver@5.3.0`: - * Add `minSatisfying` - * Add `prerelease(v)` - ([@isaacs](https://github.com/isaacs)) -* [`8aaac52`](https://github.com/npm/npm/commit/8aaac52ffae8e689fae265712913b1e2a36b1aa6) - `which@1.2.1` - ([@isaacs](https://github.com/isaacs)) -* [`85108a2`](https://github.com/npm/npm/commit/85108a29108ab0a57997572dc14f87eb706890ba) - `write-file-atomic@1.2.0`: - Preserve chmod and chown from the overwritten file - ([@iarna](https://github.com/iarna)) -* [`291a377`](https://github.com/npm/npm/commit/291a377f32f5073102a8ede61a27e6a9b37154c2) - Update npm documentation to reflect documentation for `semver@5.3.0`. - ([@zkat](https://github.com/zkat)) - -### v3.10.7 (2016-08-11) - -Hi all, today's our first release coming out of the new monthly release -cadence. See below for details. We're all recovered from conferences now -and raring to go! We've got some pretty keen bug fixes and a bunch of -documentation and dependency updates. It's hard to narrow it down to just a -few, but of note are scoped packages in bundled dependencies, the -`preinstall` lifecycle fix, the shrinkwrap and Git dependencies fix and the -fix to a crasher involving cycles in development dependencies. - -#### NEW RELEASE CADENCE - -Releasing npm has been, for the most part, a very prominent part of our -weekly process process. As part of our efforts to find the most effective -ways to allocate our team's resources, we decided last month that we would -try and slow our releases down to a monthly cadence, and see if we found -ourselves with as much extra time and attention as we expected to have. -Process experiments are useful for finding more effective ways to do our -work, and we're at least going to keep doing this for a whole quarter, and -then measure how well it worked out. It's entirely likely that we'll switch -back to a more frequent cadence, specially if we find that the value that -weekly cadence was providing the community is not worth sacrificing for a -bit of extra time. Does this affect you significantly? Let us know! - -#### SCOPED PACKAGES IN BUNDLED DEPENDENCIES - -Prior to this release and -[v2.15.10](https://github.com/npm/npm/releases/v2.15.10), npm had ignored -scoped modules found in `bundleDependencies`. - -* [`29cf56d`](https://github.com/npm/npm/commit/29cf56dbae8e3dd16c24876f998051623842116a) - [#8614](https://github.com/npm/npm/issues/8614) - Include scoped packages in bundled dependencies. - ([@forivall](https://github.com/forivall)) - -#### `preinstall` LIFECYCLE IN CURRENT PROJECT - -* [`b7f13bc`](https://github.com/npm/npm/commit/b7f13bc80b89b025be0c53d81b90ec8f2cebfab7) - [#13259](https://github.com/npm/npm/pull/13259) - Run top level preinstall before installing dependencies - ([@palmerj3](https://github.com/palmerj3)) - -#### BETTER SHRINKWRAP WITH GIT DEPENDENCIES - -* [`0f7e319`](https://github.com/npm/npm/commit/0f7e3197bcec7a328b603efdffd3681bbc40f585) - [#12718](https://github.com/npm/npm/issues/12718.) - Update outdated git dependencies found in shrinkwraps. Previously, if the - module version was the same then no update would be completed even if the - committish had changed. - ([@kossnocorp](https://github.com/kossnocorp)) - - -#### CYCLES IN DEVELOPMENT DEPENDENCIES NO LONGER CRASH - -* [`1691de6`](https://github.com/npm/npm/commit/1691de668d34cd92ab3de08bf3a06085388f2f07) - [#13327](https://github.com/npm/npm/issues/13327) - Fix bug where cycles found in development dependencies could result in - infinite recursion that resulted in crashes. - ([@iarna](https://github.com/iarna)) - -#### IMPROVE "NOT UPDATING LINKED MODULE" WARNINGS - -* [`1619871`](https://github.com/npm/npm/commit/1619871ac0cc8839dc9962c78e736095976c1eb4) - [#12893](https://github.com/npm/npm/pull/12893) - Only warn about symlink update if version number differs - The update-linked action outputs a warning that it needs to update the - linked package, but can't, There is no need for the package to be updated if - it is already at the correct version. This change does a check before - logging the warning. - ([@DaveEmmerson](https://github.com/DaveEmmerson)) - -#### MORE BUG FIXES - -* [`8f8d1b3`](https://github.com/npm/npm/commit/8f8d1b33a78c79aff9de73df362abaa7f05751d2) - [#11398](https://github.com/npm/npm/issues/11398) - Fix bug where `package.json` files that contained a `type` property could - cause crashes. `type` is not a `package.json` property that npm makes use - of and having it should be (and now is) harmless. - ([@zkat](https://github.com/zkat)) -* [`e7fa6c6`](https://github.com/npm/npm/commit/e7fa6c6a2c1de2a214479daa8c6901eebb350381) - [#13353](https://github.com/npm/npm/issues/13353) - Add GIT_EXEC_PATH to Git environment whitelist. - ([@mhart](https://github.com/mhart)) -* [`c23af21`](https://github.com/npm/npm/commit/c23af21d4cedd7fedcb4168672044db76ad054a8) - [#13626](https://github.com/npm/npm/pull/13626) - Use HTTPS issues URL in the error message for type validation errors. - ([@watilde](https://github.com/watilde)) - -#### INCLUDE `npm login` IN COMMAND SUMMARY - -* [`ab0c4b1`](https://github.com/npm/npm/commit/ab0c4b137b05762e75e0913038b606f087b58aa0) - [#13581](https://github.com/npm/npm/issues/13581) - The `login` command has long been an alias for `adduser`. - At the same time, there is an expectation not just of that - particular word being something to look for, but of there being - clear symmetry with `logout`. - So it was a bit confusing when `login` didn't show up in - `npm help` on a technicality. This seems like an acceptable - exception to the rule that says "no aliases in `npm help`". - ([@zkat](https://github.com/zkat)) - -#### DOCUMENTATION - -* [`e2d7e78`](https://github.com/npm/npm/commit/e2d7e7820a7875ed96e0382dc1e91b8df4e83746) - [#13319](https://github.com/npm/npm/pull/13319) - As Node.js 0.8 is no longer supported, remove mention of it from the README. - ([@watilde](https://github.com/watilde)) -* [`c565d89`](https://github.com/npm/npm/commit/c565d893a38efb6006e841450503329c9e58f100) - [#13349](https://github.com/npm/npm/pull/13349) - Updated the scripts documentation to explain the different between `version` and `preversion`. - ([@christophehurpeau](https://github.com/christophehurpeau)) -* [`fa8f87f`](https://github.com/npm/npm/commit/fa8f87f1ec92e543dd975156c4b184eb3e0b80cb) - [#10167](https://github.com/npm/npm/pull/10167) - Clarify in scope documentation that npm@2 is required for scoped packages. - ([@danpaz](https://github.com/danpaz)) - -#### DEPENDENCIES - -* [`124427e`](https://github.com/npm/npm/commit/124427eabbfd200aa145114e389e19692559ff1e) - [#8614](https://github.com/npm/npm/issues/8614) - `fstream-npm@1.1.1`: - Fixes bug with inclusion of scoped bundled dependencies. - ([@forivall](https://github.com/forivall)) -* [`7e0cdff`](https://github.com/npm/npm/commit/7e0cdff04714709f6dc056b19422d3f937502f1c) - [#13497](https://github.com/npm/npm/pull/13497) - `graceful-fs@4.1.5`: - `graceful-fs` had a [bug fix](https://github.com/isaacs/node-graceful-fs/pull/71) which - fixes a problem ([nodejs/node#7846](https://github.com/nodejs/node/pull/7846)) exposed - by recent changes to Node.js. - ([@thefourtheye](https://github.com/thefourtheye)) -* [`9b88cb8`](https://github.com/npm/npm/commit/9b88cb89f138443f324094685f4de073f33ecef0) - [#9984](https://github.com/npm/npm/issues/9984) - `request@2.74.0`: - Update request library to at least 2.73 to fix a bug where `npm install` would crash with - _Cannot read property 'emit' of null._ - - Update `request` dependency `tough-cookie` to `2.3.0` to - to address [https://nodesecurity.io/advisories/130](https://nodesecurity.io/advisories/130). - Versions 0.9.7 through 2.2.2 contain a vulnerable regular expression that, - under certain conditions involving long strings of semicolons in the - "Set-Cookie" header, causes the event loop to block for excessive amounts of - time. - ([@zarenner](https://github.com/zarenner)) - ([@stash-sfdc](https://github.com/stash-sfdc)) -* [`bf78ce5`](https://github.com/npm/npm/commit/bf78ce5ef5d2d6e95177193cca5362dd27bff968) - [#13387](https://github.com/npm/npm/issues/13387) - `minimatch@3.0.3`: - Handle extremely long and terrible patterns more gracefully. - There were some magic numbers that assumed that every extglob pattern starts - and ends with a specific number of characters in the regular expression. - Since !(||) patterns are a little bit more complicated, this led to creating - an invalid regular expression and throwing. - ([@isaacs](https://github.com/isaacs)) -* [`803e538`](https://github.com/npm/npm/commit/803e538efaae4b56a764029742adcf6761e8398b) - [isaacs/rimraf#111](https://github.com/isaacs/rimraf/issues/111) - `rimraf@2.5.4`: Clarify assertions: cb is required, options are not. - ([@isaacs](https://github.com/isaacs)) -* [`a9f84ef`](https://github.com/npm/npm/commit/a9f84ef61b4c719b646bf9cda00577ef16e3a113) - `lodash.without@4.2.0` - ([@jdalton](https://github.com/jdalton)) -* [`f59ff1c`](https://github.com/npm/npm/commit/f59ff1c2701f1bfd21bfdb97b4571823b614f694) - `lodash.uniq@4.4.0` - ([@jdalton](https://github.com/jdalton)) -* [`8cc027e`](https://github.com/npm/npm/commit/8cc027e5e81623260a49b31fe406ce483258b203) - `lodash.union@4.5.0` - ([@jdalton](https://github.com/jdalton)) -* [`0a6c1e4`](https://github.com/npm/npm/commit/0a6c1e4302a153fb055f495043ed33afd8324193) - `lodash.without@4.3.0` - ([@jdalton](https://github.com/jdalton)) -* [`4ab0181`](https://github.com/npm/npm/commit/4ab0181fca2eda18888b865ef691b83d30fb0c33) - `lodash.clonedeep@4.4.1` - ([@jdalton](https://github.com/jdalton)) - -### v3.10.6 (2016-07-07) - -This week we have a bunch of bug fixes for ya! A shrinkwrap regression -introduced in 3.10.0, better lifecycle `PATH` behavior, improvements when -working with registries other than `registry.npmjs.org` and a fix for -hopefully the last _don't print a progress bar over my interactive thingy_ -bug. - -#### SHRINKWRAP AND DEV DEPENDENCIES - -The rewrite in 3.10.0 triggered a bug where dependencies of devDependencies -would be included in your shrinkwrap even if you didn't request -devDependencies. - -* [`2484529`](https://github.com/npm/npm/commit/2484529ab56a42e5d6f13c48006f39a596d9e327) - [#13308](https://github.com/npm/npm/pull/13308) - Fix bug where deps of devDependencies would be incorrectly included in - shrinkwraps. - ([@iarna](https://github.com/iarna)) - -#### BETTER PATH LIFECYCLE BEHAVIOR - -We've been around the details on this one a few times in recent months and -hopefully this will bring is to where we want to be. - -* [`81051a9`](https://github.com/npm/npm/commit/81051a90eee66a843f76eb8cccedbb1d0a5c1f47) - [#12968](https://github.com/npm/npm/pull/12968) - When running lifecycle scripts, only prepend directory containing the node - binary to PATH if not already in PATH. - ([@segrey](https://github.com/segrey)) - -#### BETTER INTERACTIONS WITH THIRD PARTY REGISTRIES - -* [`071193c`](https://github.com/npm/npm/commit/071193c8e193767dd1656cb27556cb3751d77a3b) - [#10869](https://github.com/npm/npm/pull/10869) - If the registry returns a list of versions some of which are invalid, skip - those when picking a version to install. This can't happen with - registry.npmjs.org as it will normalize versions published with it, but it - can happen with other registries. - ([@gregersrygg](https://github.com/gregersrygg)) - -#### ONE LAST TOO-MUCH-PROGRESS CORNER - -* [`1244cc1`](https://github.com/npm/npm/commit/1244cc16dc5a0536acf26816a1deeb8e221d67eb) - [#13305](https://github.com/npm/npm/pull/13305) - Disable progress bar in `npm edit` and `npm config edit`. - ([@watilde](https://github.com/watilde)) - -#### HTML DOCS IMPROVEMENTS - -* [`58da923`](https://github.com/npm/npm/commit/58da9234ae72a5474b997f890a1155ee9785e6f1) - [#13225](https://github.com/npm/npm/issues/13225) - Fix HTML character set declaration in generated HTML documentation. - ([@KenanY](https://github.com/KenanY)) -* [`d1f0bf4`](https://github.com/npm/npm/commit/d1f0bf4303566f8690502034f82bbb449850958d) - [#13250](https://github.com/npm/npm/pull/13250) - Optimize png images using zopflipng. - ([@PeterDaveHello](https://github.com/PeterDaveHello)) - -#### DEPENDENCY UPDATES (THAT MATTER) - -* [`c7567e5`](https://github.com/npm/npm/commit/c7567e58618b63f97884afa104d2f560c9272dd5) - [npm/npm-user-validate#9](https://github.com/npm/npm-user-validate/pull/9) - `npm-user-validate@0.1.5`: - Lower the username length limits to 214 from 576 to match `registry.npmjs.org`'s limits. - ([@aredridel](https://github.com/aredridel)) -* [`22802c9`](https://github.com/npm/npm/commit/22802c9db3cf990c905e8f61304db9b5571d7964) - [#isaacs/rimraf](https://github.com/npm/npm/issues/isaacs/rimraf) - `rimraf@2.5.3`: - Fixes EPERM errors when running `lstat` on read-only directories. - ([@isaacs](https://github.com/isaacs)) -* [`ce6406f`](https://github.com/npm/npm/commit/ce6406f4b6c4dffbb5cd8a3c049f6663a5665522) - `glob@7.0.5`: - Forces the use of `minimatch` to 3.0.2, which improved handling of long and - complicated patterns. - ([@isaacs](https://github.com/isaacs)) - - -### v3.10.5 (2016-07-05) - -This is a fix to this week's testing release to correct the update of -`node-gyp` which somehow got mangled. - -* [`ca97ce2`](https://github.com/npm/npm/commit/ca97ce2e8d8ba44c445b39ffa40daf397d5601b3) - [#13256](https://github.com/npm/npm/issues/13256) - Fresh reinstall of `node-gyp@3.4.0`. - ([@zkat](https://github.com/zkat)) - -### v3.10.4 (2016-06-30) - -Hey y'all! This release includes a bunch of fixes we've been working on as we -continue on our `big-bug` push. There's still [a lot of it left to -do](https://github.com/npm/npm/labels/big-bug), but once this is done, things -should just generally be more stable, installs should be more reliable and -correct, and we'll be able to move on to more future work. We'll keep doing our -best! 🙌 - -#### RACES AS WACKY AS [REDLINE](https://en.wikipedia.org/wiki/Redline_\(2009_film\)) - -Races are notoriously hard to squash, and tend to be some of the more common -recurring bugs we see on the CLI. [@julianduque](https://github.com/julianduque) -did some pretty awesome [sleuthing -work](https://github.com/npm/npm/issues/12669) to track down a cache race and -helpfully submitted a patch. There were some related races in the same area that -also got fixed at around the same time, mostly affecting Windows users. - -* [`2a37c97`](https://github.com/npm/npm/commit/2a37c97121483db2b6f817fe85c2a5a77b76080e) - [#12669](https://github.com/npm/npm/issues/12669) - [#13023](https://github.com/npm/npm/pull/13023) - The CLI is pretty aggressive about correcting permissions across the cache - whenever it writes to it. This aggressiveness caused a couple of races where - temporary cache files would get picked up by `fs.readdir`, and removed before - `chownr` was called on them, causing `ENOENT` errors. While the solution might - seem a bit hamfisted, it's actually perfectly safe and appropriate in this - case to just ignore those resulting `ENOENT` errors. - ([@julianduque](https://github.com/julianduque)) -* [`ea018b9`](https://github.com/npm/npm/commit/ea018b9e3856d1798d199ae3ebce4ed07eea511b) - [#13023](https://github.com/npm/npm/pull/13023) - If a user were to have SUDO_UID and SUDO_GID, they'd be able to get into a - pretty weird state. This fixes that corner case. - ([@zkat](https://github.com/zkat)) -* [`703ca3a`](https://github.com/npm/npm/commit/703ca3abbf4f1cb4dff08be32acd2142d5493482) - [#13023](https://github.com/npm/npm/pull/13023) - A missing `return` was causing `chownr` to be called on Windows, even though - that's literally pointless, and causing crashes in the process, instead of - short-circuiting. This was entirely dependent on which callback happened to be - called first, and in some cases, the failing one would win the race. This - should prevent this from happening in the future. - ([@zkat](https://github.com/zkat)) -* [`69267f4`](https://github.com/npm/npm/commit/69267f4fbd1467ce576f173909ced361f8fe2a9d) - [#13023](https://github.com/npm/npm/pull/13023) - Added tests to verify `correct-mkdir` race patch. - ([@zkat](https://github.com/zkat)) -* [`e5f50ea`](https://github.com/npm/npm/commit/e5f50ea9f84fe8cac6978d18f7efdf43834928e7) - [#13023](https://github.com/npm/npm/pull/13023) - Added tests to verify `addLocal` race patch. - ([@zkat](https://github.com/zkat)) - -#### SHRINKWRAP IS COMPLICATED BUT IT'S BETTER NOW - -[@iarna](https://github.com/iarna) did some heroic hacking to refactor a bunch -of `shrinkwrap`-related bits and fixed some resolution and pathing issues that -were biting users. The code around that stuff got more readable/maintainable in -the process, too! - -* [`346bba1`](https://github.com/npm/npm/commit/346bba1e1fee9cc814b07c56f598a73be5c21686) - [#13214](https://github.com/npm/npm/pull/13214) - Resolve local dependencies in `npm-shrinkwrap.json` relative to the top of the - tree. - ([@iarna](https://github.com/iarna)) -* [`4a67fdb`](https://github.com/npm/npm/commit/4a67fdbd0f160deb6644a9c4c5b587357db04d2d) - [#13213](https://github.com/npm/npm/pull/13213) - If you run `npm install modulename` it should, if a `npm-shrinkwrap.json` is - present, use the version found there. If not, it'll use the version found in - your `package.json`, and failing *that*, use `latest`. - This fixes a case where the first check was being bypassed because version - resolution was being done prior to loading the shrinkwrap, and so checks to - match the shrinkwrap version couldn't succeed. - ([@iarna](https://github.com/iarna)) -* [`afa2133`](https://github.com/npm/npm/commit/afa2133a5d8ac4f6f44cdc6083d89ad7f946f5bb) - [#13214](https://github.com/npm/npm/pull/13214) - Refactor shrinkwrap specifier lookup into shared function. - ([@iarna](https://github.com/iarna)) -* [`2820b56`](https://github.com/npm/npm/commit/2820b56a43e1cc1e12079a4c886f6c14fe8c4f10) - [#13214](https://github.com/npm/npm/pull/13214) - Refactor operations in `inflate-shrinkwrap.js` into separate functions for - added clarity. - ([@iarna](https://github.com/iarna)) -* [`ee5bfb3`](https://github.com/npm/npm/commit/ee5bfb3e56ee7ae582bec9f741f32b224c279947) - Fix Windows path issue in a shrinkwrap test. - ([@zkat](https://github.com/zkat)) - -#### OTHER BUGFIXES - -* [`a11a7b2`](https://github.com/npm/npm/commit/a11a7b2e7df9478ac9101b06eead4a74c41a648d) - [#13212](https://github.com/npm/npm/pull/13212) - Resolve local paths passed in through the command line relative to current - directory, instead of relative to the `package.json`. - ([@iarna](https://github.com/iarna)) - -#### DEPENDENCY UPDATES - -* [`900a5b7`](https://github.com/npm/npm/commit/900a5b7f18b277786397faac05853c030263feb8) - [#13199](https://github.com/npm/npm/pull/13199) - [`node-gyp@3.4.0`](https://github.com/nodejs/node-gyp/blob/master/CHANGELOG.md): - AIX, Visual Studio 2015, and logging improvements. Oh my~! - ([@rvagg](https://github.com/rvagg)) - -#### DOCUMENTATION FIXES - -* [`c6942a7`](https://github.com/npm/npm/commit/c6942a7d6acb2b8c73206353bbec03380a056af4) - [#13134](https://github.com/npm/npm/pull/13134) - Fixed a few typos in `CHANGELOG.md`. - ([@watilde](https://github.com/watilde)) -* [`e63d913`](https://github.com/npm/npm/commit/e63d913127731ece56dcd69c7c0182af21be58f8) - [#13156](https://github.com/npm/npm/pull/13156) - Fix old reference to `doc/install` in a source comment. - ([@sheerun](https://github.com/sheerun)) -* [`099d23c`](https://github.com/npm/npm/commit/099d23cc8f38b524dc19a25857b2ebeca13c49d6) - [#13113](https://github.com/npm/npm/issues/13113) - [#13189](https://github.com/npm/npm/pull/13189) - Fixes a link to `npm-tag(3)` that was breaking to instead point to - `npm-dist-tag(1)`, as reported by [@SimenB](https://github.com/SimenB) - ([@macdonst](https://github.com/macdonst)) - -### v3.10.3 (2016-06-23) - -Given that we had not one, but two updates to our RC this past week, it -should come as no surprise that this week's full release is a bit -lighter. We have some documentation patches and a couple of bug fixes via -dependency updates. - -If you haven't yet checked out last week's release, -[v3.10.0](https://github.com/npm/npm/releases/tag/v3.10.0) -and the two follow up releases -[v3.10.1](https://github.com/npm/npm/releases/tag/v3.10.1) -and -[v3.10.2](https://github.com/npm/npm/releases/tag/v3.10.2), -you really should do so. They're the most important releases we've had in -quite a while, fixing a bunch of critical bugs (including an issue -impacting publishing with Node.js 6.x) and of course, bringing in the new -and improved progress bar. - -#### BUM SYMLINKS BURN NO MORE - -There's been a bug lurking where broken symlinks in your `node_modules` -folder could cause all manner of mischief, from crashes to empty `npm ls` -results. The intrepid [@watilde](https://github.com/watilde) tracked this -down for us. - -This addresses the root cause of the outdated crasher we protected -against earlier this week in -[#13115](https://github.com/npm/npm/issues/13115). - -This also fixes [#9564](https://github.com/npm/npm/issues/9564), the -problem where a bad symlink in your global modules would result in an -empty result when you ran `npm ls -g`. - -This ALSO likely fixes numerous "Missing argument #1" errors. (But surely -not all of them as that's actually just a generic arity and -type-validation failure.) - -* [`ca92ac4`](https://github.com/npm/npm/commit/ca92ac455b841a708dd89262ff88d503b125d717) - [npm/read-package-tree#6](https://github.com/npm/read-package-tree/pull/6) - `read-package-tree@5.1.5`: - Make bad symlinks be non-fatal errors when reading the tree off disk. - ([@watilde](https://github.com/watilde)) - -#### BETTER UNICODE DETECTION - -* [`6c3f7f0`](https://github.com/npm/npm/commit/6c3f7f043f09fc2aa19ffd3f956787635fa6f4d0) - `has-unicode@2.0.1`: - Fix unicode detection on a number of Linux distributions. - ([@Darkhogg](https://github.com/Darkhogg)) ([@gagern](https://github.com/gagern)) - - -#### DOCUMENTATION FIXES - -* [`b9243ee`](https://github.com/npm/npm/commit/b9243ee60a3d60505c2502dc8633811b42c8aaea) - [#13127](https://github.com/npm/npm/pull/13127) - Remove extra backtick from `npm ls` documentation. - ([@shvaikalesh](https://github.com/shvaikalesh)) -* [`e05c0c2`](https://github.com/npm/npm/commit/e05c0c243cc702f9c392c001f668a90b57eaeb0e) - [iarna/has-unicode#3](https://github.com/iarna/has-unicode/pull/3) - [iarna/has-unicode#4](https://github.com/iarna/has-unicode/pull/4) - [#13084](https://github.com/npm/npm/pull/13084) - Correct changelog entry for shrinkwrap lifecycle order. - ([@SimenB](https://github.com/SimenB)) -* [`823994f`](https://github.com/npm/npm/commit/823994f100a0e59e1dd109e312811f971968ec75) - [#13080](https://github.com/npm/npm/pull/13080) - Describe using `npm pack` to see a dry run of publication results in - the `npm publish` documentation. - ([@laughinghan](https://github.com/laughinghan)) - -#### DEPENDENCY UPDATES - -* [`e44d2db`](https://github.com/npm/npm/commit/e44d2db1ad0d860ca08e99c81135bd399fb733b1) - `aproba@1.0.4`: Documentation updates and minor refactoring. - ([@iarna](https://github.com/iarna)) - -### v3.10.2 (2016-06-17): - -This is a quick hotfix release with two small bug fixes. First, there was -an issue where the new progress bar would overwrite interactive prompts, -that is, those found in `npm login` and `npm init`. Second, if the -directory you were running `npm outdated` on was a bad link or otherwise had -unrecoverable errors then npm would crash instead of printing the error. - -* [`fbefb86`](https://github.com/npm/npm/commit/fbefb8675b26320b295f481b4872ce99f0180807) - [`7779e9f`](https://github.com/npm/npm/commit/7779e9fb9430f6547532c67f2471864d62bbd5bc) - [#13105](https://github.com/npm/npm/issues/13105) - Disable progress bar in `adduser` and `init`. -* [`6a33b2c`](https://github.com/npm/npm/commit/6a33b2c13f637a41e25cd0339925bc430b50358a) - [#13115](https://github.com/npm/npm/issues/13115) - Ensure that errors reading the package tree for `outdated` does not result - in crashes. - ([@iarna](https://github.com/iarna)) - -### v3.10.1 (2016-06-17): - -There are two very important bug fixes and one long-awaited (and significant!) -deprecation in this hotfix release. [Hold on.](http://butt.holdings/) - -#### *WHOA* - -When Node.js 6.0.0 was released, the CLI team noticed an alarming upsurge in -bugs related to important files (like `README.md`) not being included in -published packages. The new bugs looked much like -[#5082](https://github.com/npm/npm/issues/5082), which had been around in one -form or another since April, 2014. #5082 used to be a very rare (and obnoxious) -bug that the CLI team hadn't had much luck reproducing, and we'd basically -marked it down as a race condition that arose on machines using slow and / or -rotating-media-based hard drives. - -Under 6.0.0, the behavior was reliable enough to be nearly deterministic, and -made it very difficult for publishers using `.npmignore` files in combination -with `"files"` stanzas in `package.json` to get their packages onto the -registry without one or more files missing from the packed tarball. The entire -saga is contained within [the issue](https://github.com/npm/npm/issues/5082), -but the summary is that an improvement to the performance of -[`fs.realpath()`](https://nodejs.org/api/fs.html#fs_fs_realpath_path_options_callback) -made it much more likely that the packing code would lose the race. - -Fixing this has proven to be very difficult, in part because the code used by -npm to produce package tarballs is more complicated than, strictly speaking, it -needs to be. [**@evanlucas**](https://github.com/evanlucas) contributed [a -patch](https://github.com/npm/fstream/pull/50) that passed the tests in a -[special test suite](https://github.com/othiym23/eliminate-5082) that I -([**@othiym23**](https://github.com/othiym23)) created (with help from -[**@addaleax**](https://github.com/addaleax)), but only _after_ we'd released -the fixed version of that package did we learn that it actually made the -problem _worse_ in other situations in npm proper. Eventually, -[**@rvagg**](https://github.com/rvagg) put together a more durable fix that -appears to completely address the errant behavior under Node.js 6.0.0. That's -the patch included in this release. Everybody should chip in for redback -insurance for Rod and his family; he's done the community a huge favor. - -Does this mean the long (2+ year) saga of #5082 is now over? At this point, I'm -going to quote from my latest summary on the issue: - -> The CLI team (mostly me, with input from the rest of the team) has decided that -> the overall complexity of the interaction between `fstream`, `fstream-ignore`, -> `fstream-npm`, and `node-tar` has grown more convoluted than the team is -> comfortable (maybe even capable of) supporting. -> -> - While I believe that @rvagg's (very targeted) fix addresses _this_ issue, I -> would be shocked if there aren't other race conditions in npm's packing -> logic. I've already identified a couple other places in the code that are -> most likely race conditions, even if they're harder to trigger than the -> current one. -> - The way that dependency bundling is integrated leads to a situation in -> which a bunch of logic is duplicated between `fstream-npm` and -> `lib/utils/tar.js` in npm itself, and the way `fstream`'s extension -> mechanism works makes this difficult to clean up. This caused a nasty -> regression ([#13088](https://github.com/npm/fstream/pull/50), see below) as -> of ~`npm@3.8.7` where the dependencies of `bundledDependencies` were no -> longer being included in the built package tarballs. -> - The interaction between `.npmignore`, `.gitignore`, and `files` is hopelessly -> complicated, scattered in many places throughout the code. We've been -> discussing [making the ignores and includes logic clearer and more -> predictable](https://github.com/npm/npm/wiki/Files-and-Ignores), and the -> current code fights our efforts to clean that up. -> -> So, our intention is still to replace `fstream`, `fstream-ignore`, and -> `fstream-npm` with something much simpler and purpose-built. There's no real -> reason to have a stream abstraction here when a simple recursive-descent -> filesystem visitor and a synchronous function that can answer whether a given -> path should be included in the packed tarball would do the job adequately. -> -> What's not yet clear is whether we'll need to replace `node-tar` in the -> process. `node-tar` is a very robust implementation of tar (it handles, like, -> everything), and it also includes some very important tweaks to prevent several -> classes of security exploits involving maliciously crafted packages. However, -> its packing API involves passing in an `fstream` instance, so we'd either need -> to produce something that follows enough of `fstream`'s contract for `node-tar` -> to keep working, or swap `node-tar` out for something like `tar-stream` (and -> then ensuring that our use of `tar-stream` is secure, which could involve -> security patches for either npm or `tar-stream`). - -The testing and review of `fstream@1.0.10` that the team has done leads us to -believe that this bug is fixed, but I'm feeling more than a little paranoid -about fstream now, so it's important that people keep a close eye on their -publishes for a while and let us know immediately if they notice any -irregularities. - -* [`8802f6c`](https://github.com/npm/npm/commit/8802f6c152ea35cb9e5269c077c3a2f9df411afc) - [#5082](https://github.com/npm/npm/issues/5082) `fstream@1.0.10`: Ensure that - entries are collected after a paused stream resumes. - ([@rvagg](https://github.com/rvagg)) -* [`c189723`](https://github.com/npm/npm/commit/c189723110497a17dac3b0596f2916deeed93ee7) - [#5082](https://github.com/npm/npm/issues/5082) Remove the warning introduced - in `npm@3.10.0`, because it should no longer be necessary. - ([@othiym23](https://github.com/othiym23)) - -#### *ERK* - -Because the interaction between `fstream`, `fstream-ignore`, `fsream-npm`, and -`node-tar` is so complex, it's proven difficult to add support for npm features -like `bundledDependencies` without duplicating some logic within npm's code -base. While [fixing a completely unrelated -bug](https://github.com/npm/npm/issues/9642), we "cleaned up" some of this -seemingly duplicated code, and in the process removed the code that ensured -that the dependencies of `bundledDependencies` are themselves bundled. We've -brought that code back into the code base (without reopening #9642), and added -a test to ensure that this regression can't recur. - -* [`1b6ceca`](https://github.com/npm/npm/commit/1b6ceca32fc81ca7cc7ac2eb7d11f687e6f87f26) - [#13088](https://github.com/npm/npm/issues/13088) Partially restore npm's own - version of the `fstream-npm` function `applyIgnores` to ensure that the - dependencies of `bundledDependencies` are included in published packages. - ([@iarna](https://github.com/iarna)) - -#### GOODBYE, FAITHFUL FRIEND - -At NodeConf Adventure 2016 (RIP in peace, Mikeal Rogers's NodeConf!), the CLI -team had an opportunity to talk to representatives from some of the larger -companies that we knew were still using Node.js 0.8 in production. After asking -them whether they were still using 0.8, we got back blank stares and questions -like, "0.8? You mean, from four years ago?" After establishing that being able -to run npm in their legacy environments was no longer necessary, the CLI team -made the decision to drop support for 0.8. (Faithful observers of our [team -meetings](https://github.com/npm/npm/issues?utf8=%E2%9C%93&q=is%3Aissue+npm+cli+team+meeting+) -will have known this was the plan for NodeConf since the beginning of 2016.) - -In practice, this means only what's in the commit below: we've removed 0.8 from -our continuous integration test matrix below, and will no longer be habitually -testing changes under Node 0.8. We may also give ourselves permission to use -`setImmediate()` in test code. However, since the project still supports -Node.js 0.10 and 0.12, it's unlikely that patches that rely on ES 2015 -functionality will land anytime soon. - -Looking forward, the team's current plan is to drop support for Node.js 0.10 -when its LTS maintenance window expires in October, 2016, and 0.12 when its -maintenance / LTS window ends at the end of 2016. We will also drop support for -Node.js 5.x when Node.js 6 becomes LTS and Node.js 7 is released, also in the -October-December 2016 timeframe. - -(Confused about Node.js's LTS policy? [Don't -be!](https://github.com/nodejs/LTS) If you look at [this -diagram](https://github.com/nodejs/LTS/blob/ce364a94b0e0619eba570cd57be396573e1ef889/schedule.png), -it should make all of the preceding clear.) - -If, in practice, this doesn't work with distribution packagers or other -community stakeholders responsible for packaging and distributing Node.js and -npm, please reach out to us. Aligning the npm CLI's LTS policy with Node's -helps everybody minimize the amount of work they need to do, and since all of -our teams are small and very busy, this is somewhere between a necessity and -non-negotiable. - -* [`d6afd5f`](https://github.com/npm/npm/commit/d6afd5ffb1b19e5d94aeee666afcb8adaced58db) - Remove 0.8 from the Node.js testing matrix, and reorder to match real-world - priority, with comments. ([@othiym23](https://github.com/othiym23)) - -### v3.10.0 (2016-06-16): - -Do we have a release for you! We have our first new lifecycle since -`version`, a new progress bar and a bunch of bug fixes. -[I'm](https://github.com/iarna) really excited about this release, let me -tell you!! - -#### DANGER: PUBLISHING ON NODE 6.0.0 - -Publishing and packing are buggy under Node versions greater than 6.0.0. -Please use Node.js LTS (4.4.x) to publish packages. See -[#5082](https://github.com/npm/npm/issues/5082) for details and current -status. - -* [`4e52cef`](https://github.com/npm/npm/commit/4e52cef3d4170c8abab98149666ec599f8363233) - [#13077](https://github.com/npm/npm/pull/13077) - Warn when using Node 6+. - ([@othiym23](https://github.com/othiym23)) - -#### NEW LIFECYCLE SCRIPT: `shrinkwrap` - -* [`e8c80f2`](https://github.com/npm/npm/commit/e8c80f20bfd5d1618e85dbab41660d6f3e5ce405) - [#10744](https://github.com/npm/npm/issues/10744) - You can now add `preshrinkwrap`, `shrinkwrap` and `postshrinkwrap` to your `package.json` - scripts section. They are run when you run `npm shrinkwrap` or `npm install --save` with - an `npm-shrinkwrap.json` present in your module directory. - - `preshrinkwrap` and `shrinkwrap` is run prior to generating the new `npm-shrinkwrap.json` - and `postshrinkwrap` is run after. - ([@SimenB](https://github.com/SimenB)) - -#### NEW PROGRESS BAR - -![Install with new progress bar](http://shared.by.re-becca.org/misc-images/new-gauge-color.gif) - -We have a new progress bar and a bunch of related improvements! - -##### BLOCKING BLOCKING - -**!!WARNING!!** As a part of this change we now explicitly set -`process.stdout` and `process.stderr` to be _blocking_ if they are ttys, -using [set-blocking](https://www.npmjs.com/package/set-blocking). This is -necessary to ensure that we can fully erase the progress bar before we start -writing other things out to the console. - -Prior to Node.js 6.0.0, they were already blocking on Windows, and MacOS. -Meanwhile, on Linux they were always non-blocking but had large (64kb) -buffers, which largely made this a non-issue there. Starting with Node.js -6.0.0 they became non-blocking on MacOS and that caused some unexpected -issues (see [nodejs/node#6456](https://github.com/nodejs/node/issues/6456)). - -If you are a Linux user, it's plausible that this might have a performance -impact if your terminal can't keep up with output rate. If you experience -this, we want to know! Please [file an -issue](https://github.com/npm/npm/issues/new) at our issue tracker. - -##### BETTER LAYOUT - -Let's start by talking about what goes into the new progress bar: - -``` -⸨░░░░░░░░░░⠂⠂⠂⠂⠂⠂⠂⠂⸩ ⠹ loadExtraneous: verb afterAdd /Users/rebecca/.npm/null/0.0.0/package/package.json written - ↑‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾ ↑ ‾‾‾‾‾‾‾‾‾↑‾‾‾‾ ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾↑‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾ - percent complete spinner current thing we're doing most recent log line -``` - -The _spinner_ is intended as an activity indicator–it moves whenever -npm sends something to its logs. It also spins at a constant speed while -waiting on the network. - -The _current thing we're doing_ relates to how we track how much work has -been done. It's the name of the unit of work we most recently started or -completed some of. Sometimes these names are more obvious than others and -that's something we'll look at improving over time. - -And finally, the _most recent log line_ is exactly that, it's the most -recent line that you would have seen if you were running with -`--loglevel=silly` or were watching the `npm-debug.log`. These are written -to be useful to the npm developers above all else, so they may sometimes be -a little cryptic. - -* [`6789978`](https://github.com/npm/npm/commit/6789978ab0713f67928177a9109fed43953ccbda) - [#13075](https://github.com/npm/npm/pull/13075) - `npmlog@3.1.2`: Update to the latest npmlog, which includes the new and - improved progress bar layout. - ([@iarna](https://github.com/iarna)) - -##### MORE PERFORMANT - -The underlying code for the progress bar was rewritten, in part with -performance in mind. Previously whenever you updated the progress bar it -would check an internal variable for how long it had been since the last -update and if it had been long enough, it would print out what you gave it. -With the new progress bar we do updates at a fixed interval (with -`setInterval`) and "updating" the progress bar just updates some variables -that will be used when the next tick of the progress bar happens. Currently -progress bar updates happen every 50ms, although that's open to tuning. - -##### WIDE(R) COMPATIBILITY - -I spent a lot of time working our Unicode support. There were a few issues -that plagued us: - -Previously one of the characters we used was _ambiguous width_ which means -that it was possible to configure your terminal to display it as _full -width_. If you did this, the output would be broken because we assumed it -was a _half width_ character. We no longer use any of these characters. - -Previously, we defaulted to using Unicode on Windows. This isn't a safe -assumption, however, as folks in non-US locales often use other code pages -for their terminals. Windows doesn't provide* any facility available to -Node.js for determining the current code page, so we no longer try to use -Unicode on Windows. - -_\* The facilities it does provide are a command line tool and a windows -system call. The former isn't satisfactory for speed reasons and the latter -can't be accessed from a JS-only Node.js program._ - -##### FOR THE FUTURE: THEMES - -The new version of the progress bar library supports plugable themes. Adding -support to npm shouldn't be too difficult. The built in themes are: - -* `ASCII` – The fallback theme which is always available. -* `colorASCII` – Inverts the color of the completed portion of the progress - bar. The default on Windows and usually on Linux. (Color support is - determined by looking at the `TERM` environment variable.) -* `brailleSpinner` – A braille based spinner and other unicode enhancements. MacOS only. -* `colorBrailleSpinner` – The default on MacOS, a combination of the above two. - -##### LESS GARBLED OUTPUT - -As a part of landing this I've also taken the opportunity to more -systematically disable the progress bar prior to printing to `stdout` or -running external commands (in particular: git). This should ensure that the -progress bar doesn't get left on screen after something else prints -something. We also are now much more zealous about erasing the progress bar -on exit, so if you `Ctrl-C` out of an install we'll still cleanup the -progress bar. - -* [`63f153c`](https://github.com/npm/npm/commit/63f153c743f9354376bfb9dad42bd028a320fd1f) - [#13075](https://github.com/npm/npm/pull/13075) - Consistently make sure that the progress bar is hidden before we try to - write to stdout. - ([@iarna](https://github.com/iarna)) -* [`8da79fa`](https://github.com/npm/npm/commit/8da79fa60de4972dca406887623d4e430d1609a1) - [#13075](https://github.com/npm/npm/pull/13075) - Be more methodical about disabling progress bars before running external - commands. - ([@iarna](https://github.com/iarna)) - -#### REPLACE `process.nextTick` WITH `asap` ASAP - -* [`5873b56`](https://github.com/npm/npm/commit/5873b56cb315437dfe97e747811c0b9c297bfd38) - [`254ad7e`](https://github.com/npm/npm/commit/254ad7e38f978b81046d242297fe8b122bfb5852) - [#12754](https://github.com/npm/npm/issues/12754) - Use `asap` in preference over `process.nextTick` to avoid recursion warnings. - Under the hood `asap` uses `setImmediate` when available and falls back to - `process.nextTick` when it's not. Versions of node that don't support - `setImmediate` have a version of `process.nextTick` that actually behaves - like the current `setImmediate`. - ([@lxe](https://github.com/lxe)) - -#### FIXES AND REFACTORING - -Sometimes the installer would get it into its head that it could move or -remove things that it really shouldn't have. While the reproducers for this were -often a bit complicated (the core reproducer involved five symlinks(!)), it turns -out this is an easy scenario to end up in if your project has a bunch of small -modules and you're linking them while developing them. - -Fixing this ended up involving doing an important and overdue rewrite of how -the installer keeps track of (and interrogates) the relationships between -modules. This likely fixes other related bugs, and in the coming weeks -we'll verify and close them as we find them. There are a whole slew of -commits related to this rewrite, and if you'd like to learn more check -out the PR where I describe what I did in detail: [#12775](https://github.com/npm/npm/pull/12775) - -* [`8f3e111`](https://github.com/npm/npm/commit/8f3e111fdd2ce7824864f77b04e5206bdaf961a1) - [`c0b0ed1`](https://github.com/npm/npm/commit/c0b0ed1e9945c01b2e68bf22af3fe4005aa4bcd4) - [#10800](https://github.com/npm/npm/issues/10800) - Remove install pruning stage–this was obsoleted by making the installer keep - itself up to date as it goes along. This is NOT related to `npm prune`. - ([@iarna](https://github.com/iarna)) - -#### MAKE OUTDATED MORE WIDELY LEGIBLE - -* [`21c60e9`](https://github.com/npm/npm/commit/21c60e9bb56d47da17b79681f2142b3dcf4c804b) - [#12843](https://github.com/npm/npm/pull/12843) - In `npm outdated, stop coloring the _Location_ and _Package Type_ columns. - Previously they were colored dark gray, which was hard to read for some - users. - ([@tribou](https://github.com/tribou)) - -#### DOCUMENTATION UPDATE - -* [`eb0a72e`](https://github.com/npm/npm/commit/eb0a72eb95862c1d0d41a259d138ab601d538793) - [#12983](https://github.com/npm/npm/pull/12983) - Describe how to run the lifecycle scripts of dependencies. How you do - this changed with `npm` v2. - ([@Tapppi](https://github.com/Tapppi)) - -### DEPENDENCY UPDATES - -* [`da743dc`](https://github.com/npm/npm/commit/da743dc2153fed8baca3dada611b188f53ab5931) - `which@1.2.10`: - Fix bug where unnecessary special case path handling for Windows could - produce unexpected results on Unix systems. - ([@isaacs](https://github.com/isaacs)) -* [`4533bd5`](https://github.com/npm/npm/commit/4533bd501d54aeedfec3884f4fd54e8c2edd6020) - `npm-user-validate@0.1.4`: - Validate the length of usernames. - ([@aredridel](https://github.com/aredridel)) -* [`4a18922`](https://github.com/npm/npm/commit/4a18922e56f9dc902fbb4daa8f5fafa4a1b89376) - `glob@7.0.4`: - Fixes issues with Node 6 and "long or excessively symlink-looping paths". - ([@isaacs](https://github.com/isaacs)) -* [`257fe11`](https://github.com/npm/npm/commit/257fe11052987e5cfec2abdf52392dd95a6c6ef3) - `npm-package-arg@4.2.0`: - Add `escapedName` to the result. It is suitable for passing through to a - registry without further processing. - ([@nexdrew](https://github.com/nexdrew)) -* [`dda3ca7`](https://github.com/npm/npm/commit/dda3ca70f74879106589ef29e167c8b91ef5aa4c) - `wrappy@1.0.2` - ([@zkat](https://github.com/zkat)) -* [`25f1db5`](https://github.com/npm/npm/commit/25f1db504d0fd8c97211835f0027027fe95e0ef3) - `readable-stream@2.1.4` - ([@calvinmetcalf](https://github.com/calvinmetcalf)) -* [`9d64fe6`](https://github.com/npm/npm/commit/9d64fe676ebc6949c687ffb85bd93eca3137fc0d) - `abbrev@1.0.9` - ([@isaacs](https://github.com/isaacs)) - -### v3.9.6 (2016-06-02): - -#### SMALL OUTPUT TWEAK - -* [`0bdc9d1`](https://github.com/npm/npm/commit/0bdc9d13b73df07e63a58470ea001fda490e5869) - [#12879](https://github.com/npm/npm/pull/12879) - The usage output for npm commands was somehow under the impression that - the singular form of `aliases` is `aliase`. This has been corrected to show - `alias` instead. - ([@intelliot](https://github.com/intelliot)) - -#### DOC UPDATES - -* [`f771b49`](https://github.com/npm/npm/commit/f771b49f5d65bbef540c231fbfcca71cacdce4db) - [#12933](https://github.com/npm/npm/pull/12933) - Add `config.gypi` to list of files that are always ignored in the - `package.json` manpage. - ([@Jokero](https://github.com/Jokero)) - -#### DEPENDENCY UPDATES - -* [`61c1d9c`](https://github.com/npm/npm/commit/61c1d9cd4b2296bd41d55a5c58e35ca5f028b9bc) - [#12926](https://github.com/npm/npm/pull/12926) - Removed unused dependency `lodash.isarray`. - ([@mmalecki](https://github.com/mmalecki)) -* [`168ed28`](https://github.com/npm/npm/commit/168ed2834b2c6db8bb39f81baadc0bf275807328) - [#12926](https://github.com/npm/npm/pull/12926) - Removed unused dependency `lodash.keys`. - ([@mmalecki](https://github.com/mmalecki)) - -### v3.9.5 (2016-05-27): - -Just a quick point release. We had an issue where I (Kat) included the -`.nyc_output/` directory in `npm@3.9.3` and `npm@3.9.4`. The issue got reported -right after that second release -([`#12873`](https://github.com/npm/npm/issues/12873)), and now there's this -small point release that's there to fix the issue sooner. - -* [`f96aea0`](https://github.com/npm/npm/commit/f96aea085be981cdb59bd09f16da40717426f981) - [#12878](https://github.com/npm/npm/pull/12878) - Ignore `.nyc_output` to avoid an accidental publish or commit filled with - code coverage data. - ([@TheAlphaNerd](https://github.com/TheAlphaNerd)) - -### v3.9.4 (2016-05-26): - -Hey all! It's that time again! - -This week continues our current `big-bug` squashing push, although there's none -that are ready to release quite yet -- we're working on it! - -It's also worth noting that we're entering the main part of conference season, -so you can probably expect a bit of a dev slowdown as a lot of us wombats attend -or speak at the various conferences. Remember [npm.camp](npm.camp) is happening -in 2 months and the lineup is looking pretty great! Tickets are still on sale. -Come hang out with us! WOO FUN! 🎉😸 - -#### BUGFIX - -* [`cac0038`](https://github.com/npm/npm/commit/cac0038868b18295f9f299e762e20034f32a3e11) - [#12845](https://github.com/npm/npm/pull/12845) - Progress bar during tarball packing now prints `pack:packagename` instead of - `pack:[object Object]`. - ([@iarna](https://github.com/iarna)) - -#### DOC UPDATES - -* [`0b81622`](https://github.com/npm/npm/commit/0b816225c743c9203db5d92fb4dd3a9293833298) - [#12840](https://github.com/npm/npm/pull/12840) - Remove sexualized language from comment in code. - ([@geek](https://github.com/geek)) -* [`d6dff24`](https://github.com/npm/npm/commit/d6dff2481cb587c392f22afb893ac3136371a64c) - [#12802](https://github.com/npm/npm/pull/12802) - Small grammar fix in `cli/npm.md`. - ([@andresilveira](https://github.com/andresilveira)) -* [`cb38e0f`](https://github.com/npm/npm/commit/cb38e0fff82a6c1c110026b95b07a8c32e27ec01) - [#12782](https://github.com/npm/npm/pull/12782) - Documents that `NOTICE` files started getting included after - [npm/fstream-npm#17](https://github.com/npm/fstream-npm/pull/17). - ([@SimenB](https://github.com/SimenB)) -* [`70a3ae4`](https://github.com/npm/npm/commit/70a3ae4d4ec76b3ec51f00bf5261f1147829f9fe) - [#12776](https://github.com/npm/npm/pull/12776) - `npm run-script` used to have a `<pkg>` argument that allowed you to target - specific packages' scripts. This was removed as one of the breaking changes - for `npm@2`. - This patch removes a mention of that argument, which really doesn't exist - anymore. - ([@fibo](https://github.com/fibo)) - -#### DEP UPDATES - -* [`4a4470d`](https://github.com/npm/npm/commit/4a4470ddd1d9b0b62cb94f3bff5ab6b8e6db527a) - `aproba@1.0.3` - ([@iarna](https://github.com/iarna)) - -#### TEST IMPROVEMENTS - -So it turns out, `t.comment` in `tap` is actually pretty nice! -There's also a couple other test improvements by Rebecca landing here. - -* [`9fd04dd`](https://github.com/npm/npm/commit/9fd04dd6be493465d7ac5f14dd9328e66069c1bf) - [#12851](https://github.com/npm/npm/pull/12851) - Rewrite `shrinkwrap-prod-dependency-also` test to use `common.npm` - ([@iarna](https://github.com/iarna)) -* [`3bc4a8e`](https://github.com/npm/npm/commit/3bc4a8ee58cb0e0adc84b4f135330f2b1e20d992) - [#12851](https://github.com/npm/npm/pull/12851) - Clean up `rm-linked` test. - ([@iarna](https://github.com/iarna)) -* [`bf7f7f2`](https://github.com/npm/npm/commit/bf7f7f273a794f7573bbbc84b1c216fdcd9e0ef9) - [#12851](https://github.com/npm/npm/pull/12851) - Clean up `outdated-symlink` test. - ([@iarna](https://github.com/iarna)) -* [`ca0baa4`](https://github.com/npm/npm/commit/ca0baa4dac85b1df4e26ef0c73d39314ca6858ca) - [#12851](https://github.com/npm/npm/pull/12851) - Improve diagnostics for `shrinkwrap-scoped-auth` test. - ([@iarna](https://github.com/iarna)) -* [`fbec9fd`](https://github.com/npm/npm/commit/fbec9fd5bb0abce589120d14c1f2b03b58cecce1) - [#12851](https://github.com/npm/npm/pull/12851) - Rewrite `shrinkwrap-dev-dependency` test to use `common.npm`. - ([@iarna](https://github.com/iarna)) - -### v3.9.3 (2016-05-19): - -This week continues our `big-bug` squashing adventure! Things are churning along -nicely, and we've gotten a lot of fantastic contributions from the community. -Please keep it up! - -A quick note on last week's release: We had a small `npm shrinkwrap`-related -crasher in `npm@3.9.1`, so once this release goes out, `v3.9.2` is going to be -`npm@latest`. Please update if you ended up in with that previous version! - -Remember we have a weekly team meeting, and you can [suggest agenda items in the -GitHub issue](https://github.com/npm/npm/issues/12761). Keep an eye out for the -`#npmweekly` tag on Twitter, too, and join the conversation! We'll do our best -to address questions y'all send us. ✌ - -#### FIXES - -* [`42d71be`](https://github.com/npm/npm/commit/42d71be2cec674dd9e860ad414f53184f667620d) - [#12685](https://github.com/npm/npm/pull/12685) - When using `npm ls <pkg>` without a semver specifier, `npm ls` would skip - any packages in your tree that matched by name, but had a prerelease version - in their `package.json`. This patch fixes it so `npm ls` does a simple name - match unless you use the `npm ls <pkg>@<version>` format. - ([@zkat](https://github.com/zkat)) -* [`c698ae6`](https://github.com/npm/npm/commit/c698ae666afc92fbc0fcba3c082cfa9b34a4420d) - [#12685](https://github.com/npm/npm/pull/12685) - Added some tests for more basic `npm ls` functionality. - ([@zkat](https://github.com/zkat)) - -### NOTABLE DEPENDENCY UPDATES - -* [`3a6fe23`](https://github.com/npm/npm/commit/3a6fe2373c45e80a1f28aaf176d552f6f97cf131) - [npm/fstream-npm#17](https://github.com/npm/fstream-npm/pull/17) - `fstream-npm@1.1.0`: - `fstream-npm` always includes NOTICE files now. - ([@kemitchell](https://github.com/kemitchell)) -* [`df04e05`](https://github.com/npm/npm/commit/df04e05af1f257a1903372e1baf334c0969fbdbd) - [#10013](https://github.com/npm/npm/issues/10013) - `read-package-tree@5.1.4`: - Fixes an issue where `npm install` would fail if your `node_modules` was - symlinked. - ([@iarna](https://github.com/iarna)) -* [`584676f`](https://github.com/npm/npm/commit/584676f85eaebcb9d6c4d70d2ad320be8a8d6a74) - [npm/init-package-json#62](https://github.com/npm/init-package-json/pull/62) - `init-package-json@1.9.4`: - Stop using `package` for a variable, which defeats some bundlers and linters. - ([@adius](https://github.com/adius)) -* [`935a7e3`](https://github.com/npm/npm/commit/935a7e359535e13924934811b77924cbad82619a) - `readable-stream@2.1.3`: - Node 6 build and buffer-related updates. - ([@calvinmetcalf](https://github.com/calvinmetcalf)) - -#### OTHER DEPENDENCY UPDATES - -* [`4c4609e`](https://github.com/npm/npm/commit/4c4609ea49e77303f9d72af6757620e6b3a9a6a9) - `inflight@1.0.5` - ([@zkat](https://github.com/zkat)) -* [`7a3030d`](https://github.com/npm/npm/commit/7a3030d3d44ea2136425f72950ba22e6efd441d9) - `hosted-git-info@2.1.5` - ([@zkat](https://github.com/zkat)) -* [`5ed4b58`](https://github.com/npm/npm/commit/5ed4b58409eeb134bca1c96252682fd7600d9906) - `which@1.2.9` - ([@isaacs](https://github.com/isaacs)) - -### v3.9.2 (2016-05-17) - -This is a quick patch release. The previous release, 3.9.1, introduced a -bug where npm would crash given a combination of specific package tree on -disk and a shrinkwrap. - -* [`cde367f`](https://github.com/npm/npm/commit/cde367fbb6eebc5db68a44b12a5c7bea158d70db) - [#12724](https://github.com/npm/npm/issues/12724) - Fix crasher when inflating shrinkwraps with packages on disk that were - installed by older npm versions. - ([@iarna](https://github.com/iarna)) - -### v3.9.1 (2016-05-12) - -HI all! We have bug fixes to a couple of the hairy corners of `npm`, in the -form of shrinkwraps and bundled dependencies. Plus some documentation improvements -and our lodash deps bot a bump. - -This is our first week really focused on getting the -[big bugs](https://github.com/npm/npm/issues?q=is%3Aopen+is%3Aissue+label:big-bug) -list down. Our work from this week will be landing next week, and I can't -wait to tell you about that! (It's about symlinks!) - -#### SHRINKWRAP FIX - -* [`b894413`](https://github.com/npm/npm/commit/b8944139a935680c4a267468bb2d3c3082b5609f) - [#12372](https://github.com/npm/npm/issues/12372) - Changing a nested dependency in an `npm-shrinkwrap.json` and then running `npm install` - would not get up the updated package. This corrects that. - ([@misterbyrne](https://github.com/misterbyrne)) - -#### BUNDLED DEPENDENCIES FIX - -* [`d0c6d19`](https://github.com/npm/npm/commit/d0c6d194471be8ce3e7b41b744b24f63dd1a3f6f) - [#12476](https://github.com/npm/npm/pull/12476) - Protects against a crasher when a bundled dep is missing a package.json. - ([@dflupu](https://github.com/dflupu)) - -#### DOCS IMPROVEMENTS - -* [`6699aa5`](https://github.com/npm/npm/commit/6699aa53c0a729cfc921ac1d8107c320e5a5ac95) - [#12585](https://github.com/npm/npm/pull/12585) - Document that engineStrict is quite gone. Not "deprecated" so much as "extirpated". - ([@othiym23](https://github.com/othiym23)) -* [`7a41a84`](https://github.com/npm/npm/commit/7a41a84b655be3204d2e80848278a510e42c80e7) - [#12636](https://github.com/npm/npm/pull/12636) - Improve `npm-scripts` documentation regarding when `node-gyp` is used. - ([@reconbot](https://github.com/reconbot)) -* [`4c4b4ba`](https://github.com/npm/npm/commit/4c4b4badf09b9b50cdca85314429a0111bb35cb1) - [#12586](https://github.com/npm/npm/pull/12586) - Correct `package.json` documentation as to when `node-gyp rebuild` called. - This now matches https://docs.npmjs.com/misc/scripts#default-values - ([@reconbot](https://github.com/reconbot)) - -#### DEPENDENCY UPDATES - -* [`cfa797f`](https://github.com/npm/npm/commit/cfa797fedd34696d45b61e3ae0398407afece880) - `lodash._baseuniq@4.6.0` - ([@jdalton](https://github.com/jdalton)) -* [`ab6f180`](https://github.com/npm/npm/commit/ab6f1801971b513f9294b4b8902034ab402af02d) - `lodash.keys@4.0.7` - ([@jdalton](https://github.com/jdalton)) -* [`4b8d8b6`](https://github.com/npm/npm/commit/4b8d8b63e760a8aa03e8bffa974495dfafbfcb06) - `lodash.union@4.4.0` - ([@jdalton](https://github.com/jdalton)) -* [`46099d3`](https://github.com/npm/npm/commit/46099d34542760098e5d13c7468a405a724ca407) - `lodash.uniq@4.3.0` - ([@jdalton](https://github.com/jdalton)) -* [`fff89c6`](https://github.com/npm/npm/commit/fff89c6826c86e9e789adcc9c398385539306042) - `lodash.without@4.2.0` - ([@jdalton](https://github.com/jdalton)) - -### v3.9.0 (2016-05-05) - -Wow! This is a big release week! We've completed the fixes that let the -test suite pass on Windows, plus more general bug fixes we found while -fixing things on Windows. Plus a warning to help folks work around a common -footgun. PLUS an improvement to how npm works with long cache timeouts. - -#### INFINITE CACHE A LITTLE BETTER - -* [`111ae3e`](https://github.com/npm/npm/commit/111ae3ec366ece7ebcf5988f5bc2a7cd70737dfe) - [#8581](https://github.com/npm/npm/issues/8581) - When a package is fetched from the cache which cannot satisfy the version - requirements, an attempt to fetch it from the network is made. This is - helpful for folks using high values for `--cache-min` who are willing to - accept possibly not-the-most-recent modules in return for less network - traffic. - ([@Zirak](https://github.com/Zirak)) - -#### WARNING: FOOTGUN - -* [`60b9a05`](https://github.com/npm/npm/commit/60b9a051aa46b8892fe63b3681839a6fd6642bfd) - [#12475](https://github.com/npm/npm/pull/12475) - Options can only start with ASCII dashes. Ordinarily this isn't a problem - but many web documentation tools "helpfully" convert `--` into an emdash - (–), or `-` into an endash (–). If you copy and paste from this documentation - your commands won't work the way you expect. This adds a warning that tries - to be a little more descriptive about why your command is failing. - ([@iarna](https://github.com/iarna)) - -#### WINDOWS CI - -We have [Windows CI](https://ci.appveyor.com/project/npm/npm) setup now! We still have to -tweak it a little bit around paths to the git binaries, but it's otherwise ready! - -* [`bb5d6cb`](https://github.com/npm/npm/commit/bb5d6cbf46b2609243d3b384caadd196e665a797) - [#11444](https://github.com/npm/npm/pull/11444) - Add AppVeyor to CI matrix. - ([@othiym23](https://github.com/othiym23)) - -#### COVERAGE DATA - -Not only do our tests produce coverage reports after they run now, we also -automatically [update Coveralls](https://coveralls.io/github/npm/npm) with -results from [Travis CI](travis-ci.org/npm/npm) runs. - -* [`044cbab`](https://github.com/npm/npm/commit/044cbab0d49adeeb0d9310c64fee6c9759cc7428) - [#11444](https://github.com/npm/npm/pull/11444) - Enable coverage reporting for every test run. - ([@othiym23](https://github.com/othiym23)) - -#### EVERYONE BUGS - -* [`37c6a51`](https://github.com/npm/npm/commit/37c6a51c71b0feec8f639b3199a8a9172e58deec) - [#12150](https://github.com/npm/npm/pull/12150) - Ensure that 'npm cache ls' outputs real filenames. Previously it would - sometimes double up the package name in the path it printed. - ([@isaacs](https://github.com/isaacs)) -* [`d3ce0b2`](https://github.com/npm/npm/commit/d3ce0b253eb519375071aee29db4ee129dbcdf5c) - [#11444](https://github.com/npm/npm/pull/11444) - Fix unbuilding bins for scoped modules. - ([@iarna](https://github.com/iarna)) -* [`e928a30`](https://github.com/npm/npm/commit/e928a30947477a09245f54e9381f46b97bee32d5) - [#11444](https://github.com/npm/npm/pull/11444) - Make handling of local modules (eg `npm install /path/to/my/module`) more - consistent when saved to a `package.json`. There were bugs previously where - it wouldn't consistently resolve relative paths in the same way. - ([@iarna](https://github.com/iarna)) -* [`b820ed4`](https://github.com/npm/npm/commit/b820ed4fc04e21577fa66f7c9482b5ab002e7985) - [#11444](https://github.com/npm/npm/pull/11444) - Under certain circumstances the paths produced for linking, either - relative or absolute, would end up basing off the wrong virtual cwd. - This resulted in failures for `npm link` in this situations. - ([@iarna](https://github.com/iarna)) - -#### WINDOWS BUGS - -* [`7380425`](https://github.com/npm/npm/commit/7380425d810fb8bfc69405a9cbbdec19978a7bee) - [#11444](https://github.com/npm/npm/pull/11444) - Scoped module names were not being correctly inferred from the path on Windows. - ([@zkat](https://github.com/zkat)) -* [`91fc24f`](https://github.com/npm/npm/commit/91fc24f2763c2e0591093099ffc866c735f27fde) - [#11444](https://github.com/npm/npm/pull/11444) - Explore with a command to run didn't work properly in Windows– it would pop open a new - cmd window and leave it there. - ([@iarna](https://github.com/iarna)) - -#### WINDOWS REFACTORING - -* [`f07e643`](https://github.com/npm/npm/commit/f07e6430d4ca02f811138f6140a8bad927607a1f) - [#11444](https://github.com/npm/npm/pull/11444) - Move exec path escaping out to its own function. This turns out to be - tricky to get right because how you escape commands to run on Windows via - cmd is different then how you escape them at other times. Specifically, - you HAVE to quote each directory segment that has a quote in it, that is: - `C:\"Program Files"\MyApp\MyApp.exe` By contrast, if that were an argument - to a command being run, you CAN'T DO quote it that way, instead you have - to wrap the entire path in quotes, like so: `"C:\Program - Files\MyApp\MyApp.exe"`. - ([@iarna](https://github.com/iarna)) -* [`2e01d29`](https://github.com/npm/npm/commit/2e01d299f8244134b1aa040cab1b59c72c9df4da) - [#11444](https://github.com/npm/npm/pull/11444) - Create a single function for detecting if we're running on Windows (and - using a Windows shell like cmd) and use this instead of doing it one-off - all over the place. - ([@iarna](https://github.com/iarna)) - -#### FIX WINDOWS TESTS - -As I said before, our tests are passing on Windows! 🎉 - -* [`ef0dd74`](https://github.com/npm/npm/commit/ef0dd74583be25c72343ed07d1127e4d0cc02df9) - [#11444](https://github.com/npm/npm/pull/11444) - The fruits of many weeks of labor, fix our tests to pass on Windows. - ([@zkat](https://github.com/zkat)) - ([@iarna](https://github.com/iarna)) - -#### DEPENDENCY UPDATES - -* [`8fccda8`](https://github.com/npm/npm/commit/8fccda8587209659c469ab55c608b0e2d7533530) - [#11444](https://github.com/npm/npm/pull/11444) - `normalize-git-url@3.0.2`: - Fix file URLs on Windows. - ([@zkat](https://github.com/zkat)) -* [`f53a154`](https://github.com/npm/npm/commit/f53a154df8e0696623e6a71f33e0a7c11a7555aa) - `readable-stream@2.1.2`: - When readable-stream is disabled, reuse result of `require('stream')` - instead of calling it every time. - ([@calvinmetcalf](https://github.com/calvinmetcalf)) -* [`02841cf`](https://github.com/npm/npm/commit/02841cfb81d6ba86f691ab43d9bbdac29aec27e7) - [#11444](https://github.com/npm/npm/pull/11444) - `realize-package-specifier@3.0.2`: - Resolve local package paths relative to package root, not cwd. - ([@zkat](https://github.com/zkat)) - ([@iarna](https://github.com/iarna)) -* [`247c1c5`](https://github.com/npm/npm/commit/247c1c5ae08c882c9232ca605731039168bae6ed) - [#11444](https://github.com/npm/npm/pull/11444) - `npm-package-arg@4.1.1`: - Fix Windows file URIs with leading slashes. - ([@zkat](https://github.com/zkat)) -* [`365c72b`](https://github.com/npm/npm/commit/365c72bc3ecd9e45f9649725dd635d5625219d8c) - `which@1.2.8` - ([@isaacs](https://github.com/isaacs)) -* [`e568caa`](https://github.com/npm/npm/commit/e568caabb8390a924ce1cfa51fc914ee6c1637a2) - `graceful-fs@4.1.4` - ([@isaacs](https://github.com/isaacs)) -* [`304b974`](https://github.com/npm/npm/commit/304b97434959a58f84383bcccc0357c51a4eb39a) - [#11444](https://github.com/npm/npm/pull/11444) - `standard@6.0.8` - ([@feross](https://github.com/feross)) - -### v3.8.9 (2016-04-28) - -Our biggest news this week is that we got the -[Windows test suite passing](https://github.com/npm/npm/pull/11444)! -It'll take a little longer to get it passing in our -[Windows CI](https://ci.appveyor.com/project/npm/npm/) but that's coming -soon too. - -That means we'll be shifting gears away from tests to fixing -[Big Bugs™](https://github.com/npm/npm/issues?q=is%3Aopen+is%3Aissue+label%3Abig-bug) again. -Join us at our [team meeting](https://github.com/npm/npm/issues/12517) next -Tuesday to learn more about that. - -#### BUG FIXES AND REFACTORING - -* [`60da618`](https://github.com/npm/npm/commit/60da61862885fa904afba7d121860b4282a5b0df) - [#12347](https://github.com/npm/npm/issues/12347) - Fix a bug that could result in shrinkwraps missing the `resolved` field, which is - necessary in producing a fully reproducible build. - ([@sminnee](https://github.com/sminnee)) -* [`8597ba4`](https://github.com/npm/npm/commit/8597ba432e91245a1000953b612eb01308178bad) - [#12009](https://github.com/npm/npm/issues/12009) - Fix a bug in `npm view <packagename> versions` that resulted in bad output if you - didn't also pass in `--json`. - ([@watilde](https://github.com/watilde)) -* [`20125f1`](https://github.com/npm/npm/commit/20125f19b96fd05af63f8c0bd243ffb25780279a) - [`a53feac`](https://github.com/npm/npm/commit/a53feac2647f7dc4245f1700dfbdd1aba8745672) - [`6cfbae4`](https://github.com/npm/npm/commit/6cfbae403abc3cf690565b09569f71cdd41a8372) - [#12485](https://github.com/npm/npm/pull/12485) - Refactor how the help summaries for commands are produced, such that we only have - one list of command aliases. - ([@watilde](https://github.com/watilde)) -* [`2ae210c`](https://github.com/npm/npm/commit/2ae210c76ab6fd15fcf15dc1808b01ca0b94fc9e) - `read-package-json@2.0.4`: - Fix a crash we discovered while fixing up the Windows test suite where if - you had a file in your `node_modules` it would cause a crash on Windows - (but not MacOS/Linux). - - This makes the error code you get on Windows match that from MacOS/Linux - if you try to read a `package.json` from a path that includes a file, not - a folder. - ([@zkat](https://github.com/zkat)) - -### v3.8.8 (2016-04-21) - -Hi all! Long time no see! We've been heads-down working through getting -[our test suite passing on Windows](https://github.com/npm/npm/pull/11444). -Did you know that we have -[Windows CI](https://ci.appveyor.com/project/npm/npm) now running over at -Appveyor? In the meantime, we've got a bunch of dependency updates, some -nice documentation improvements and error messages when your `package.json` -contains invalid JSON. (Yeah, I thought we did that last one before too!) - -#### BAD JSON IS BAD - -* [`769e620`](https://github.com/npm/npm/commit/769e6200722d8060b6769e47354032c51cfa85a1) - [#12406](https://github.com/npm/npm/pull/12406) - Failing to parse the top level `package.json` should be an error. - ([@watilde](https://github.com/watilde)) - -#### DOCUMENTATION - -* [`7d64301`](https://github.com/npm/npm/commit/7d643018af5051c920cc73f17bfe32b7ff86e108) - [#12415](https://github.com/npm/npm/pull/12415) - Clarify that when configuring client-side certificates for authenticating - to non-npm registries that `cert` and `key` are not filesystem paths and should - actually include the certificate and key data. - ([@rvedotrc](https://github.com/rvedotrc)) -* [`f8539b8`](https://github.com/npm/npm/commit/f8539b8c986e81771ccc8ced7e716718423d3187) - [#12324](https://github.com/npm/npm/pull/12324) - Describe how `npm run` sets `NODE` and `PATH` in more detail. - Note that `npm run` changes `PATH` to include the current node - interpreter’s directory. - ([@addaleax](https://github.com/addaleax)) -* [`2b57606`](https://github.com/npm/npm/commit/2b57606852a2c2a03e4c4b7dcda85b807619c2cf) - [#11461](https://github.com/npm/npm/pull/11461) - Clarify the documentation for the package.json homepage field. - ([@stevemao](https://github.com/stevemao)) - -#### TESTS - -* [`b5a0fbb`](https://github.com/npm/npm/commit/b5a0fbb9e1a2c4fb003dd748264571aa6e3c9e70) - [#12329](https://github.com/npm/npm/pull/12329) - Fix progress config testing to ignore local user configs. - Previously, _any_ local setting would cause the tests to fail as - they were trying to test what the default values for the progress - bar would be in different environments and any explicit setting - overrides those defaults. - ([@iarna](https://github.com/iarna)) -* [`3d195bc`](https://github.com/npm/npm/commit/3d195bc0a72b40df02a5c56e4f3be44152e8222b) - The lifecycle-signal test could crash on v0.8 due to its use of `Number.parseInt`, which - isn't available in that version of node. Fortunately `global.parseInt` _is_, so - we just use that instead. - ([@iarna](https://github.com/iarna)) - -#### DEPENDENCY UPDATES - -* [`05a28e3`](https://github.com/npm/npm/commit/05a28e38586082ac4bbf26ee6f863cc8d07054d6) - `npm-package-arg@4.1.1`: - Under some circumstances `file://` URLs on Windows were not handled correctly. - - Also, stop converting local module/tarballs into full paths in this - module. We do already do that in `realize-package-specifier`, which is - more appropriate as it knows what package we're installing relative to. - ([@zkat](https://github.com/zkat)) -* [`ada2e93`](https://github.com/npm/npm/commit/ada2e93e8b276000150a9aa93fff69ec366e03d6) - `realize-package-specifier@3.0.3`: - Require the new `npm-package-arg`, plus fix a case where specifiers that were - maybe a tag, maybe a local filename were resolved differently than those that were - definitely a local filename. - ([@zkat](https://github.com/zkat)) ([@iarna](https://github.com/iarna)) -* [`adc515b`](https://github.com/npm/npm/commit/adc515b22775871386cd62390079fb4bf8e1714a) - `fs-vacuum@1.2.9`: - A fix for AIX where a non-empty directory can cause `fs.rmDir` to fail with `EEXIST` instead of `ENOTEMPTY` - and three new tests - ([@richardlau](https://github.com/richardlau)) - - Code cleanup, CI & dependency updates. - ([@othiym23](https://github.com/othiym23)) -* [`ef53a46`](https://github.com/npm/npm/commit/ef53a46906ce872a4541b605dd42a563cc26e614) - `tap@5.7.1` - ([@isaacs](https://github.com/isaacs)) -* [`df1f2e4`](https://github.com/npm/npm/commit/df1f2e4838b4d7ea2ea2321a95ae868c0ec0a520) - `request@2.72.0`: - Fix crashes when response headers indicate gzipped content but the body is - empty. - Add support for the deflate content encoding. - ([@simov](https://github.com/simov)) -* [`776c599`](https://github.com/npm/npm/commit/776c599b204632aca9d29fd92ea5c4f099fdea9f) - `readable-stream@2.1.0`: - Adds READABLE_STREAM env var that, if set to `disable`, will make - `readable-stream` use the local native node streams instead. - ([@calvinmetcalf](https://github.com/calvinmetcalf)) -* [`10d6d55`](https://github.com/npm/npm/commit/10d6d5547354fcf50e930c7932ba4d63c0b6009c) - `normalize-git-url@3.0.2`: - Add support `git+file://` type URLs. - ([@zkat](https://github.com/zkat)) -* [`75017ae`](https://github.com/npm/npm/commit/75017aeecec69a1efd546df908aa5befc4467f36) - `lodash.union@4.3.0` - ([@jdalton](https://github.com/jdalton)) - -### v3.8.7 (2016-04-07) - -#### IMPROVED DIAGNOSTICS - -* [`38cf79f`](https://github.com/npm/npm/commit/38cf79ffa564ef5cb6677b476e06d0e45351592a) - [#12083](https://github.com/npm/npm/pull/12083) - If you `ignore-scripts` to disable lifecycles, this makes npm report when it skips running - a script. - ([@bfred-it](https://github.com/bfred-it)) - -#### IMPROVE AUTO-INCLUDES - -* [`c615182`](https://github.com/npm/npm/commit/c615182c8b47e418338eb1317b99bb66987cda54) - [#11995](https://github.com/npm/npm/pull/11995) - There were bugs where modules whose names matched the special files that npm always - includes would be included, for example, the `history` package was always included. - - With `npm@3` such extraneously bundled modules would not be ordinarily - used, as things in `node_modules` in packages are ignored entirely if the - package isn't marked as bundling modules. - - Because of this `npm@3` behavior, the `files-and-ignores` test failed to catch this as - it was testing _install output_ not what got packed. That has also been fixed. - ([@glenjamin](https://github.com/glenjamin)) - -#### DOCUMENTATION UPDATES - -* [`823d9df`](https://github.com/npm/npm/commit/823d9dfa91d7086a26620f007aee4e3cd77b6153) - [#12107](https://github.com/npm/npm/pull/12107) - In the command summary for `adduser` mention that `login` is an alias. - ([@gnerkus](https://github.com/gnerkus)) -* [`7aaf47e`](https://github.com/npm/npm/commit/7aaf47e124c45dde72c961638b770ee535fb2776) - [#12244](https://github.com/npm/npm/pull/12244) - Update the README to suggest npm@3 for Windows users. Also add a reference to - [Microsoft's npm upgrade tool](https://github.com/felixrieseberg/npm-windows-upgrade). - ([@felixrieseberg](https://github.com/felixrieseberg)) - -#### DEPENDENCY UPDATES - -* [`486bbc0`](https://github.com/npm/npm/commit/486bbc0e1b101f847e890e6f1925dc8cb253cf3e) - `request@2.70.0` - ([@simov](https://github.com/simov)) -* [`b1aff34`](https://github.com/npm/npm/commit/b1aff346fc41f13e3306b437e1831942aacf2f54) - `lodash.keys@4.0.6` - ([@jdalton](https://github.com/jdalton)) - -### v3.8.6 (2016-03-31) - -Heeeeeey y'all. - -Kat here! Rebecca's been schmoozing with folks at [Microsoft -Build](https://build.microsoft.com/), so I'm doing the `npm@3` release this -week. - -Speaking of Build, it looks like Microsoft is doing some bash thing. This might -be really good news for our Windows users once it rolls around. We're keeping an -eye out and feeling hopeful. 🙆 - -As far as the release goes: We're really happy to be getting more and more -community contributions! Keep it up! We really appreciate folks trying to help -us, and we'll do our best to help point you in the right direction. Even things -like documentation are a huge help. And remember -- you get socks for it, too! - -#### FIXES - -* [`f8fb4d8`](https://github.com/npm/npm/commit/f8fb4d83923810eb78d075bd200a9376c64c3e3a) - [#12079](https://github.com/npm/npm/pull/12079) - Back in `npm@3.2.2` we included [a patch that made it so `npm install pkg` was - basically `npm install pkg@latest` instead of - `pkg@*`](https://github.com/npm/npm/pull/9170) - This is probably what most users expected, but it also ended up [breaking `npm - deprecate`](https://github.com/npm/npm/pull/9170) when no version was provided - for a package. In that case, we were using `*` to mean "deprecate all - versions" and relying on the `pkg` -> `pkg@*` conversion. - This patch fixes `npm deprecate pkg` to work as it used to by special casing - that particular command's behavior. - ([@polm](https://github.com/polm)) -* [`458f773`](https://github.com/npm/npm/commit/458f7734f3376aba0b6ff16d34a25892f7717e40) - [#12146](https://github.com/npm/npm/pull/12146) - Adds `make doc-clean` to `prepublish` script, to clear out previously built - docs before publishing a new npm version - ([@watilde](https://github.com/watilde)) -* [`f0d1521`](https://github.com/npm/npm/commit/f0d1521038e956b2197673f36c464684293ce99d) - [#12146](https://github.com/npm/npm/pull/12146) - Adds `doc-clean` phony target to `make publish`. - ([@watilde](https://github.com/watilde)) - -#### DOC UPDATES - -* [`ea92ffc`](https://github.com/npm/npm/commit/ea92ffc9dd2a063896353fc52c104e85ec061360) - [#12147](https://github.com/npm/npm/pull/12147) - Document that the current behavior of `engines` is just to warn if the node - platform is incompatible. - ([@reconbot](https://github.com/reconbot)) -* [`cd1ba44`](https://github.com/npm/npm/commit/cd1ba4423b3ca889c741141b95b0d9472b9f71ea) - [#12143](https://github.com/npm/npm/pull/12143) - Remove `npm faq` command, since the [FAQ was - removed](https://github.com/npm/npm/pull/10547). - ([@watilde](https://github.com/watilde)) -* [`50a12cb`](https://github.com/npm/npm/commit/50a12cb1f5f158af78d6962ad20ff0a98bc18f18) - [#12143](https://github.com/npm/npm/pull/12143) - Remove references to the FAQ from the docs, since [it was - removed](https://github.com/npm/npm/pull/10547). - ([@watilde](https://github.com/watilde)) -* [`60051c2`](https://github.com/npm/npm/commit/60051c25e2ab80c667137dfcd04b242eea25980e) - [#12093](https://github.com/npm/npm/pull/12093) - Update `bugs` url in `package.json` to use the `https` URL for Github. - ([@watilde](https://github.com/watilde)) -* [`af30c37`](https://github.com/npm/npm/commit/af30c374ef22ed1a1c71b14fced7c4b8350e4e82) - [#12075](https://github.com/npm/npm/pull/12075) - Add the `--ignore-scripts` flag to the `npm install` docs. - ([@paulirish](https://github.com/paulirish)) -* [`632b214`](https://github.com/npm/npm/commit/632b214b2f2450e844410792e5947e46844612ff) - [#12063](https://github.com/npm/npm/pull/12063) - Various minor fixes to the html docs homepage. - ([@watilde](https://github.com/watilde)) - -#### DEP BUMPS - -* [`3da0171`](https://github.com/npm/npm/commit/3da01716a0e41d6b5adee2b4fc70fcaf08c0eb24) - `lodash.without@4.1.2` - ([@jdalton](https://github.com/jdalton)) -* [`69ccf6d`](https://github.com/npm/npm/commit/69ccf6dd4caf95cd0628054307487cae1885acd0) - `lodash.uniq@4.2.1` - ([@jdalton](https://github.com/jdalton)) -* [`b50c41a`](https://github.com/npm/npm/commit/b50c41a9930dc5353a23c5ae2ff87bb99e11d482) - `lodash.union@4.2.1` - ([@jdalton](https://github.com/jdalton)) -* [`59c1ad7`](https://github.com/npm/npm/commit/59c1ad7b6f243d07618ed5703bd11d787732fc57) - `lodash.clonedeep@4.3.2` - ([@jdalton](https://github.com/jdalton)) -* [`2b4f797`](https://github.com/npm/npm/commit/2b4f797dba8e7a1376c8335b7223e82d02cd8243) - `lodash._baseuniq@4.5.1` - ([@jdalton](https://github.com/jdalton)) - -### v3.8.5 (2016-03-24) - -Like my esteemed colleague [@zkat](https://github.com/zkat) said in this -week's [LTS release notes](https://github.com/npm/npm/releases/tag/v2.15.2), -this week is another small release but we are continuing to work on our -[Windows efforts](https://github.com/npm/npm/pull/11444). - -You may also be interested in reading the [LTS process and -policy](https://github.com/npm/npm/wiki/LTS) that -[@othiym23](https://github.com/othiym23) put together recently. If you have any -feedback, we would love to hear. - -#### DOCTOR IT HURTS WHEN LINK TO MY LINK - -Well then, don't do that. - -* [`0d4a0b1`](https://github.com/npm/npm/commit/0d4a0b1) - [#11442](https://github.com/npm/npm/pull/11442) - Fail if the user asks us to make a link from a module back on to itself. - ([@antialias](https://github.com/antialias)) - -#### ERR MODULE LIST TOO LONG - -* [`b271ed2`](https://github.com/npm/npm/commit/b271ed2) - [#11983](https://github.com/npm/npm/issues/11983) - Exit early if no arguments were provided to search instead of trying to display all the modules, - running out of memory, and then crashing. - ([@SimenB](https://github.com/SimenB)) - -#### ELIMINATE UNUSED MODULE - -* [`b8c7cd7`](https://github.com/npm/npm/commit/b8c7cd7) - [#12000](https://github.com/npm/npm/pull/12000) - Stop depending on [`async-some`](https://npmjs.com/package/async-some) as it's no - longer used in npm. - ([@watilde](https://github.com/watilde)) - -#### DOCUMENTATION IMPROVEMENTS - -* [`fdd6b28`](https://github.com/npm/npm/commit/fdd6b28) - [#11884](https://github.com/npm/npm/pull/11884) - Include `node_modules` in the list of files and directories that npm won't - include in packages ordinarily. (Modules listed in `bundledDependencies` and things - that those modules rely on, ARE included of course.) - ([@Jameskmonger](https://github.com/Jameskmonger)) -* [`aac15eb`](https://github.com/npm/npm/commit/aac15eb) - [#12006](https://github.com/npm/npm/pull/12006) - Fix typo in npm-orgs documentation, where teams docs went to access docs and vice versa. - ([@yaelz](https://github.com/yaelz)) - -#### FEWER NETWORK TESTS - -* [`3e41360`](https://github.com/npm/npm/commit/3e41360) - [#11987](https://github.com/npm/npm/pull/11987) - Fix test that was inappropriately hitting the network - ([@yodeyer](https://github.com/yodeyer)) - -### v3.8.4 (2016-03-24) - -Was erroneously released with just a changelog typo correction and was -otherwise the same as 3.8.3. - -### v3.8.3 (2016-03-17): - -#### SECURITY ADVISORY: BEARER TOKEN DISCLOSURE - -This release includes [the fix for a -vulnerability](https://github.com/npm/npm/commit/f67ecad59e99a03e5aad8e93cd1a086ae087cb29) -that could cause the unintentional leakage of bearer tokens. - -Here are details on this vulnerability and how it affects you. - -##### DETAILS - -Since 2014, npm’s registry has used HTTP bearer tokens to authenticate requests -from the npm’s command-line interface. A design flaw meant that the CLI was -sending these bearer tokens with _every_ request made by logged-in users, -regardless of the destination of their request. (The bearers only should have -been included for requests made against a registry or registries used for the -current install.) - -An attacker could exploit this flaw by setting up an HTTP server that could -collect authentication information, then use this authentication information to -impersonate the users whose tokens they collected. This impersonation would -allow them to do anything the compromised users could do, including publishing -new versions of packages. - -With the fixes we’ve released, the CLI will only send bearer tokens with -requests made against a registry. - -##### THINK YOU'RE AT RISK? REGENERATE YOUR TOKENS - -If you believe that your bearer token may have been leaked, [invalidate your -current npm bearer tokens](https://www.npmjs.com/settings/tokens) and rerun -`npm login` to generate new tokens. Keep in mind that this may cause continuous -integration builds in services like Travis to break, in which case you’ll need -to update the tokens in your CI server’s configuration. - -##### WILL THIS BREAK MY CURRENT SETUP? - -Maybe. - -npm’s CLI team believes that the fix won’t break any existing registry setups. -Due to the large number of registry software suites out in the wild, though, -it’s possible our change will be breaking in some cases. - -If so, please [file an issue](https://github.com/npm/npm/issues/new) describing -the software you’re using and how it broke. Our team will work with you to -mitigate the breakage. - -##### CREDIT & THANKS - -Thanks to Mitar, Will White & the team at Mapbox, Max Motovilov, and James -Taylor for reporting this vulnerability to npm. - -#### PERFORMANCE IMPROVEMENTS - -The updated [`are-we-there-yet`](https://npmjs.com/package/are-we-there-yet) -changes how it tracks how complete things are to be much more efficient. -The summary is that `are-we-there-yet` was refactored to remove an expensive -tree walk. - -The result for you should be faster installs when working with very large trees. - -Previously `are-we-there-yet` computed this when you asked by passing the request down -its tree of progress indicators, totaling up the results. In doing so, it had to walk the -entire tree of progress indicators. - -By contrast, `are-we-there-yet` now updates a running total when a change -is made, bubbling that up the tree from whatever branch made progress. This -bubbling was already going on so there was nearly no cost associated with taking advantage of it. - -* [`32f2bd0`](https://github.com/npm/npm/commit/32f2bd0e26116db253e619d67c4feae1de3ad2c2) - `npmlog@2.0.3`: - Bring in substantial performance improvements from `are-we-there-yet`. - ([@iarna](https://github.com/iarna)) - -#### DUCT TAPE FOR BUGS - -* [`473d324`](https://github.com/npm/npm/commit/473d3244a8ddfd6b260d0aa0d395b119d595bf97) - [#11947](https://github.com/npm/npm/pull/11947) - Guard against bugs that could cause the installer to crash with errors like: - - ``` - TypeError: Cannot read property 'target' of null - ``` - - This doesn't fix the bugs, but it does at least make the installer less - likely to explode. - ([@thefourtheye](https://github.com/thefourtheye)) - -#### DOC FIXES - -* [`ffa428a`](https://github.com/npm/npm/commit/ffa428a4eee482aa620819bc8df994a76fad7b0c) - [#11880](https://github.com/npm/npm/pull/11880) - Fix typo in `npm install` documentation. - ([@watilde](https://github.com/watilde)) - -#### DEPENDENCY UPDATES - -* [`7537fe1`](https://github.com/npm/npm/commit/7537fe1748c27e6f1144b279b256cd3376d5c41c) - `sorted-object@2.0.0`: - Create objects with `{}` instead of `Object.create(null)` to make the results - strictly equal to what, say, parsed JSON would provide. - ([@domenic](https://github.com/domenic)) -* [`8defb0f`](https://github.com/npm/npm/commit/8defb0f7b3ebdbe15c9ef5036052c10eda7e3161) - `readable-stream@2.0.6`: - Fix sync write issue on 0.10. - ([@calvinmetcalf](https://github.com/calvinmetcalf)) - -#### TEST FIXES FOR THE SELF TESTS - -* [`c3edeab`](https://github.com/npm/npm/commit/c3edeabece4400308264e7cf4bc4448bd2729f55) - [#11912](https://github.com/npm/npm/pull/11912) - Change the self installation test to do its work in `/tmp`. - Previously this was installing into a temp subdir in `test/tap`, which - wouldn't catch the case where a module was installed in the local - `node_modules` folder but not in dependencies, as node would look up - the tree and use the copy from the version of npm being tested. - ([@iarna](https://github.com/iarna)) - -### v3.8.2 (2016-03-10): - -#### HAVING TROUBLE INSTALLING C MODULES ON ANDROID? - -This release includes an updated `node-gyp` with fixes for Android. - -* [`634ecba`](https://github.com/npm/npm/commit/634ecba320fb5a3287e8b7debfd8b931827b9e19) - `node-gyp@3.3.1`: - Fix bug in builds for Android. - ([@bnoordhuis](https://github.com/bnoordhuis)) - -#### NPM LOGOUT CLEANS UP BETTER - -* [`460ed21`](https://github.com/npm/npm/commit/460ed217876ac78d21477c288f1c06563fb770b4) - [#10529](https://github.com/npm/npm/issues/10529) - If you ran `npm logout` with a scope, while we did invalidate your auth - token, we weren't removing the auth token from your config file. This patch causes - the auth token to be removed. - ([@wyze](https://github.com/wyze)) - -#### HELP MORE HELPFUL - -* [`d1d0233`](https://github.com/npm/npm/commit/d1d02335d297da2734b538de44d8967bdcd354cf) - [#11003](https://github.com/npm/npm/issues/11003) - Update help to only show command names and their shortcuts. Previously - some typo corrections were shown, along with various alternate - spellings. - ([@watilde](https://github.com/watilde)) -* [`47928cd`](https://github.com/npm/npm/commit/47928cd6264e1d6d0ef67435b71c66d01bea664a) - [#11003](https://github.com/npm/npm/issues/11003) - Remove "version" typo from the help listing. - ([@doug-wade](https://github.com/doug-wade)) - -#### MORE COMPLETE CONFIG LISTINGS - -* [`cf5fd40`](https://github.com/npm/npm/commit/cf5fd401494d96325d74a8bb8c326aa0045a714c) - [#11472](https://github.com/npm/npm/issues/11472) - Make `npm config list` include the per-project `.npmrc` in the output. - ([@mjomble](https://github.com/mjomble)) - -#### DEPTH LIMITED PARSEABLE DEP LISTINGS - -* [`611070f`](https://github.com/npm/npm/commit/611070f0f7a1e185c75cadae46179194084b398f) - [#11495](https://github.com/npm/npm/issues/11495) - Made `npm ls --parseable` honor the `--depth=#` option. - ([@zacdoe](https://github.com/zacdoe)) - -#### PROGRESS FOR THE (NON) UNICODE REVOLUTION - -* [`ff90382`](https://github.com/npm/npm/commit/ff9038227a1976b5e936442716d9877f43c6c9b4) - [#11781](https://github.com/npm/npm/issues/11781) - Make the progress bars honor the unicode option. - ([@watilde](https://github.com/watilde)) - -#### `npm view --json`, NOW ACTUALLY JSON - -* [`24ab70a`](https://github.com/npm/npm/commit/24ab70a4ccfeaa005b80252da313bb589510668e) - [#11808](https://github.com/npm/npm/issues/11808) - Make `npm view` produce valid JSON when requested with `--json`. - Previously `npm view` produced some sort of weird hybrid output, with multiple - JSON docs. - ([@doug-wade](https://github.com/doug-wade)) - -#### DOCUMENTATION CHANGES - -* [`6fb0499`](https://github.com/npm/npm/commit/6fb0499bea868fdc637656d210c94f051481ecd4) - [#11726](https://github.com/npm/npm/issues/11726) - Previously we patched the `npm update` docs to suggest using `--depth - Infinity` instead of `--depth 9999`, but that was a mistake. We forgot - that `npm outdated` (on which `npm update` is built) has a special - case where it treats `Infinity` as `0`. This reverts that patch. - ([@GriffinSchneider](https://github.com/GriffinSchneider)) -* [`f0bf684`](https://github.com/npm/npm/commit/f0bf684a87ea5eea03432a17f38678fed4960d43) - [#11748](https://github.com/npm/npm/pull/11748) - Document all of the various aliases for commands in the documentation - for those commands. - ([@watilde](https://github.com/watilde)) -* [`fe04443`](https://github.com/npm/npm/commit/fe04443d8988e2e41bd4047078e06a26d05d380d) - [#10968](https://github.com/npm/npm/issues/10968) - The `npm-scope` document notes that scopes have been available on the - public registry for a while. This adds that you'll need `npm@2` or later - to use them. - ([@doug-wade](https://github.com/doug-wade)) -* [`3db37a5`](https://github.com/npm/npm/commit/3db37a52b2b2e3193ef250ad2cf96dfd2def2777) - [#11820](https://github.com/npm/npm/pull/11820) - The command `npm link` should be linking package from local folder to - global, and `npm link package-name` should be from global to local. The - description in the documentation was reversed and this fixes that. - ([@rhgb](https://github.com/rhgb)) - -#### GLOB FOR THE GLOB THRONE - -* [`be55882`](https://github.com/npm/npm/commit/be55882dc4ee5ce0777b4badc9141dab5bf5be4d) - `glob@7.0.3`: - Fix a race condition and some windows edge cases. - ([@isaacs](https://github.com/isaacs)) - -### v3.8.1 (2016-03-03): - -This week the install summary got better, killing your npm process now -also kills the scripts it was running and a rarely used search flag got -documented. - -Our improvements on the test suite on Windows are beginning to pick up -steam, you can follow along by -[watching the PR](https://github.com/npm/npm/pull/11444). - -#### BETTER INSTALL SUMMARIES - -* [`e40d457`](https://github.com/npm/npm/commit/e40d4572cc98db06757df5b8bb6b7dbd0546d3d7) - [#11699](https://github.com/npm/npm/issues/11699) - Ensure that flags like `--production` passed to install don't result in - the summary at the end being incorrectly filtered. That summary is - produced by the same code as `npm ls` and therefore responds to flags - the same way it does. This is undesirable when it's an install summary, - however, as we don't want it to filter anything. - - This fixes an issue where `npm install --production <module>` would - result in npm exiting with an error code. The `--production` flag would - make `npm ls` filter out `<module>` as it wasn't saved to the - `package.json` and thus wasn't a production dependency. The install - report is limited to show just the modules installed, so with that - filtered out nothing is available. With nothing available `npm ls` - would set `npm` to exit with an error code. - ([@ixalon](https://github.com/ixalon)) -* [`99337b4`](https://github.com/npm/npm/commit/99337b469163a4b211b9c6ff1aa9712ae0d601d2) - [#11600](https://github.com/npm/npm/pull/11600) - Make the report of installed modules really only show those modules - that were installed. Previously it selected which modules from your - tree to display based on `name@version` which worked great when your - tree was deduped but would list things it hadn't touched when there - were duplicates. - ([@iarna](https://github.com/iarna)) - -#### SCRIPTS BETTER FOLLOW THE LEADER - -* [`5454347`](https://github.com/npm/npm/commit/545434766eb3681d3f40b745f9f3187ed63f310a) - [#10868](https://github.com/npm/npm/pull/10868) - When running a lifecycle script, say through `npm start`, killing npm - wouldn't forward that on to the children. It does now. - ([@daniel-pedersen](https://github.com/daniel-pedersen)) - -#### SEARCHING SPECIFIC REGISTRIES - -* [`6020447`](https://github.com/npm/npm/commit/60204479f76458a9864aa530cda2b3333f95c2b0) - [#11490](https://github.com/npm/npm/pull/11490) - Add docs for using the `--registry` flag with search. - ([@plumlee](https://github.com/plumlee)) - -#### LODASH UPDATES - -* [`bb14204`](https://github.com/npm/npm/commit/bb14204183dad620a6650452a26cdc64111f8136) - `lodash.without@4.1.1` - ([@jdalton](https://github.com/jdalton)) -* [`0089059`](https://github.com/npm/npm/commit/0089059c562aee9ad0398e55d2c12c68a6150e79) - `lodash.keys@4.0.5` - ([@jdalton](https://github.com/jdalton)) -* [`6ee1de4`](https://github.com/npm/npm/commit/6ee1de4474d9683a1f7023067d440780eeb10311) - `lodash.clonedeep@4.3.1` - ([@jdalton](https://github.com/jdalton)) - -### v3.8.0 (2016-02-25): - -This week brings a quality of life improvement for some Windows users, and -an important knob to be tuned for folks experiencing network problems. - -#### LIMIT CONCURRENT REQUESTS - -We've long known that `npm`'s tendency to try to request all your -dependencies simultaneously upset some network hardware (particular, -consumer grade routers & proxies of all sorts). One of the reasons that we're -planning to write our own npm specific version of `request` is to be able to -more easily control this sort of thing. - -But fortunately, you don't have to wait for that. -[@misterbyrne](https://github.com/misterbyrne) took a look at our existing -code and realized it could be added painlessly TODAY. The new default -maximum is `50`, instead of `Infinity`. If you're having network issues you -can try setting that value down to something lower (if you do, please let us -know... the default is subject to tuning). - -* [`910f9ac`](https://github.com/npm/npm/commit/910f9accf398466b8497952bee9f566ab50ade8c) - [`f7be667`](https://github.com/npm/npm/commit/f7be667548a132ec190ac9d60a31885a7b4fe2b3) - Add a new config option, `maxsockets` and `npm-registry-client@7.1.0` to - take advantage of it. - ([@misterbyrne](https://github.com/misterbyrne)) - -#### WINDOWS GIT BASH - -We think it's pretty keen too, we were making it really hard to actually -upgrade if you were using it. NO MORE! - -* [`d60351c`](https://github.com/npm/npm/commit/d60351ccae87d71a5f5eac73e3085c6290b52a69) - [#11524](https://github.com/npm/npm/issues/11524) - Prefer locally installed npm in Git Bash -- previous behavior was to use - the global one. This was done previously for other shells, but not for Git - Bash. - ([@destroyerofbuilds](https://github.com/destroyerofbuilds)) - -#### DOCUMENTATION IMPROVEMENTS - -* [`b63de3c`](https://github.com/npm/npm/commit/b63de3c97c4c27078944249a4d5bbe1c502c23bc) - [#11636](https://github.com/npm/npm/issues/11636) - Document `--save-bundle` option in main install page. - ([@datyayu](https://github.com/datyayu)) -* [`3d26453`](https://github.com/npm/npm/commit/3d264532d6d9df60420e985334aebb53c668d32b) - [#11644](https://github.com/npm/npm/pull/11644) - Add `directories.test` to the `package.json` documentation. - ([@lewiscowper](https://github.com/lewiscowper)) -* [`b64d124`](https://github.com/npm/npm/commit/b64d12432fdad344199b678d700306340d3607eb) - [#11441](https://github.com/npm/npm/pull/11441) - Add a link in documentation to the contribution guidelines. - ([@watilde](https://github.com/watilde)) -* [`82fc548`](https://github.com/npm/npm/commit/82fc548b0e2abbdc4f7968c20b118c30cca79a24) - [#11441](https://github.com/npm/npm/pull/11441/commits) - Remove mentions of the long defunct Google group. - ([@watilde](https://github.com/watilde)) -* [`c6ad091`](https://github.com/npm/npm/commit/c6ad09131af2e2766d6034257a8fcaa294184121) - [#11474](https://github.com/npm/npm/pull/11474) - Correct invalid JSON in npm-update docs. - ([@robludwig](https://github.com/robludwig)) -* [`4906c90`](https://github.com/npm/npm/commit/4906c90ed2668adf59ebee759c7ebb811aa46e57) - Expand on the documentation for `bundlededDependencies`, explaining what they are - and when you might want to use them. - ([@gnerkus](https://github.com/gnerkus)) - -#### DEPENDENCY UPDATES - -* [`93cdc25`](https://github.com/npm/npm/commit/93cdc25432b71cbc9c25c54ae316770e18f4b01e) - `strip-ansi@3.0.1`: - Non-user visible tests & maintainer doc updates. - ([@jbnicolai](https://github.com/jbnicolai)) -* [`3b2ccef`](https://github.com/npm/npm/commit/3b2ccef30dc2038b99ba93cd1404a1d01dac8790) - `lodash.keys@4.0.4` - ([@jdalton](https://github.com/jdalton)) -* [`30e9eb9`](https://github.com/npm/npm/commit/30e9eb97397a8f85081d328ea9aa54c2a7852613) - `lodash._baseuniq@4.5.0` - ([@jdalton](https://github.com/jdalton)) - - -### v3.7.5 (2016-02-22): - -A quick fixup release because when I updated glob, I missed the subdep copies of itself -that it installed deeper in the tree. =/ - -This only effected people trying to update to `3.7.4` from `npm@2` or `npm@1`. Updates from -`npm@3` worked fine (as it fixes up the missing subdeps during installation). - -#### OH MY GLOB - -* [`63fa704`](https://github.com/npm/npm/commit/63fa7044569127e6e29510dc499a865189806076) - [#11633](https://github.com/npm/npm/issues/11633) - When updating the top level `npm` to `glob@7`, the subdeps that - still depended on `glob@6` got new versions installed but they - weren't added to the commit. This adds them back in. - ([@iarna](https://github.com/iarna)) - -### v3.7.4 (2016-02-18): - -I'm ([@iarna](https://github.com/iarna)) back from vacation in the frozen -wastes of Maine! This release sees a couple of bug fixes, some -documentation updates, a bunch of dependency updates and improvements to our -test suite. - -#### FIXES FOR `update`, FIXES FOR `ls` - -* [`53cdb96`](https://github.com/npm/npm/commit/53cdb96634fc329378b4ea4e767ba9987986a76e) - [#11362](https://github.com/npm/npm/issues/11362) - Make `npm update` stop trying to update linked packages. - ([@rhendric](https://github.com/rhendric)) -* [`8d90d25`](https://github.com/npm/npm/commit/8d90d25b3da086843ce43911329c9572bd109078) - [#11559](https://github.com/npm/npm/issues/11559) - Only list runtime dependencies when doing `npm ls --production`. - ([@yibn2008](https://github.com/yibn2008)) - -#### @wyze, DOCUMENTATION HERO OF THE PEOPLE, GETS THEIR OWN HEADER - -* [`b78b301`](https://github.com/npm/npm/commit/b78b30171038ab737eff0b070281277e35af25b4) - [#11416](https://github.com/npm/npm/pull/11416) - Logout docs were using a section copy-pasted from the adduser docs. - ([@wyze](https://github.com/wyze)) -* [`649e28f`](https://github.com/npm/npm/commit/649e28f50aa323e75202eeedb824434535a0a4a0) - [#11414](https://github.com/npm/npm/pull/11414) - Add colon for consistency. - ([@wyze](https://github.com/wyze)) - -#### WHITTLING AWAY AT PATH LENGTHS - -So for all of you who don't know -- Node.js does, in fact, support long Windows -paths. Unfortunately, depending on the tool and the Windows version, a lot of -external tooling does not. This means, for example, that some (all?) versions of -Windows Explorer *can literally never delete npm from their system entirely -because of deeply-nested npm dependencies*. Which is pretty gnarly. - -Incidentally, if you run into that in particularly, you can use -[rimraf](npm.im/rimraf) to remove such files 💁. - -The latest victim of this issue was the Node.js CI setup for testing on Windows, -which uses some tooling or another that croaks on the usual path length limit -for that OS: 255 characters. - -This isn't ordinarily an issue with `npm@3` as it produces mostly flat -trees, but you may be surprised to learn that `npm`'s own distribution isn't -flat, due to needing to be compatible with `npm@1.2`, which ships with -`node@0.8`! - -We've taken another baby step towards alleviating this in this release by -updating a couple of dependencies that were preventing `npmlog` from deduping, -and then doing a dedupe on that and `gauge`. Hopefully it helps. - -* [`f3c32bc`](https://github.com/npm/npm/commit/f3c32bc3127301741d2fa3a26be6f5f127a35908) - [#11528](https://github.com/npm/npm/pull/11528) - `node-gyp@3.3.0`: - Update to a more recent version that uses a version of npmlog compatible - with npm itself. Also adds: AIX support, new `gyp`, `--cafile` command - line option, and allows configuration of Node.js and io.js mirrors. - ([@rvagg](https://github.com/rvagg)) - -#### INTERNAL TEST IMPROVEMENTS - -The `npm` core team's time recently has been sunk into `npm`'s many years of -tech debt. Specifically, we've been working on improving the test suite. -This isn't user visible, but in future should mean a more stable, easier to -contribute to `npm`. Ordinarily we don't report these kinds of changes in -the change log, but I thought I might share this week as this chunk is -bigger than usual. - -* [`07f020a`](https://github.com/npm/npm/commit/07f020a09e94ae393c67526985444e128ef6f83c) - [#11292](https://github.com/npm/npm/pull/11292) - `tacks@1.0.9`: - Add a package that provides a tool to generate fixtures from folders and, relatedly, - a module that an create and tear down filesystem fixtures easily. - ([@iarna](https://github.com/iarna)) -* [`0837346`](https://github.com/npm/npm/commit/083734631f9b11b17c08bca8ba8cb736a7b1e3fb) - [#11292](https://github.com/npm/npm/pull/11292) - Remove all the relatively cryptic legacy tests and creates new tap tests - that check the same functionality. The *legacy* tests were tests that - were originally a shell script that was ported to javascript early in - `npm`'s history. - ([@iarna](https://github.com/iarna)) - ([@zkat](https://github.com/zkat)) -* [`5a701e7`](https://github.com/npm/npm/commit/5a701e71a0130787fb98450f9de92117b4ef88e1) - [#11292](https://github.com/npm/npm/pull/11292) - Test that we don't leak auth info into the environment. - ([@zkat](https://github.com/zkat)) -* [`502d7d0`](https://github.com/npm/npm/commit/502d7d0628f08b09d8d13538ebccc63de8b3edf5) - [#11292](https://github.com/npm/npm/pull/11292) - Test that env vars properly passed into scripts. - ([@zkat](https://github.com/zkat)) -* [`420f267`](https://github.com/npm/npm/commit/420f2672ee8c909f18bee10b1fc7d4ad91cf328b) - [#11292](https://github.com/npm/npm/pull/11292) - Test that npm's distribution binary is complete and can be installed and used. - ([@iarna](https://github.com/iarna)) -* [`b7e99be`](https://github.com/npm/npm/commit/b7e99be1b1086f2d6098c653c1e20791269c9177) - [#11292](https://github.com/npm/npm/pull/11292) - Test that the `package.json` `files` section and `.npmignore` do what - they're supposed to. - ([@zkat](https://github.com/zkat)) - -#### DEPENDENCY UPDATES - -* [`4611098`](https://github.com/npm/npm/commit/4611098fd8c65d61a0645deb05bf38c81300ffca) - `rimraf@2.5.2`: - Use `glob@7.0.0`. - ([@isaacs](https://github.com/isaacs)) -* [`41b2772`](https://github.com/npm/npm/commit/41b2772cb83627f3b5b926cf81e150e7148cb124) - `glob@7.0.0`: - Raise error if `options.cwd` is specified, and not a directory. - ([@isaacs](https://github.com/isaacs)) -* [`c14e74a`](https://github.com/npm/npm/commit/c14e74ab5d17c764f3aa37123a9632fa965f8760) - `gauge@1.2.7`: Update to newer lodash versions, for a smaller tree. - ([@iarna](https://github.com/iarna)) -* [`d629363`](https://github.com/npm/npm/commit/d6293630ddc25bfa26d19b6be4fd2685976d7358) - `lodash.without@4.1.0` - ([@jdalton](https://github.com/jdalton)) -* [`3ea4c80`](https://github.com/npm/npm/commit/3ea4c8049ca8df9f64426b1db8a29b9579950134) - `lodash.uniq@4.2.0` - ([@jdalton](https://github.com/jdalton)) -* [`8ddcc8d`](https://github.com/npm/npm/commit/8ddcc8deb554660a3f7f474fae9758c967d94552) - `lodash.union@4.2.0` - ([@jdalton](https://github.com/jdalton)) -* [`2b656a6`](https://github.com/npm/npm/commit/2b656a672d351f32ee2af24dcee528356dcd64f4) - `lodash.keys@4.0.3` - ([@jdalton](https://github.com/jdalton)) -* [`ac171f8`](https://github.com/npm/npm/commit/ac171f8f0318a7dd3c515f3b83502dfa9e87adb8) - `lodash.isarguments@3.0.7` - ([@jdalton](https://github.com/jdalton)) -* [`bcccd90`](https://github.com/npm/npm/commit/bcccd9057b75d800c799ab15f00924f700415d3e) - `lodash.clonedeep@4.3.0` - ([@jdalton](https://github.com/jdalton)) -* [`8165bca`](https://github.com/npm/npm/commit/8165bca537d86305a3d08f080f86223a26615aa8) - `lodash._baseuniq@4.4.0` - ([@jdalton](https://github.com/jdalton)) - -### v3.7.3 (2016-02-11): - -Hey all! We've got a pretty small release this week -- just documentation -updates and a couple of dependencies. This release also includes a particular -dependency upgrade that makes it so we're exclusively using the latest version -of `graceful-fs`, which'll make it so things keep working with future Node.js -releases. - -A certain internal Node.js API was deprecated and slated for future removal from -Node Core. This API was critical for versions of `graceful-fs@<4`, before a -different approach was used to achieve similar ends. By upgrading this library, -and making sure all our dependencies are also updated, we've ensured npm will -continue to work once the API is finally removed. Older versions of npm, on the -other hand, will simply not work on future versions of Node.js. - -#### DEPENDENCY UPGRADES - -* [`29536f4`](https://github.com/npm/npm/commit/29536f42da6c06091c9acbc8952f72daa8a9412c) - `cmd-shim@2.0.2`: - Final straggler using `graceful-fs@<4`. - ([@ForbesLindesay](https://github.com/ForbesLindesay)) -* [`5f59e74`](https://github.com/npm/npm/commit/5f59e748ef4c066756bb204a452cecd0543c7a2f) - `lodash.uniq@4.1.0` - ([@jdalton](https://github.com/jdalton)) -* [`987cabe`](https://github.com/npm/npm/commit/987cabe8a18abcb5a685685958bf74c7258a979c) - `lodash.union@4.1.0` - ([@jdalton](https://github.com/jdalton)) -* [`5c641f0`](https://github.com/npm/npm/commit/5c641f05fdc153c6bb06a89c46fe2a345ce413db) - `lodash.clonedeep@4.1.0` - ([@jdalton](https://github.com/jdalton)) - -#### EVERYONE GETTING SOCKS LIKE IT'S OPRAH'S SHOW - -* [`9ea5658`](https://github.com/npm/npm/commit/9ea56582ca4d0991dbed44f992c88f08a643cb4b) - [#11410](https://github.com/npm/npm/pull/11410) - Fixed a small spelling error in `npm-config.md`. - ([@pra85](https://github.com/pra85)) -* [`2a11e56`](https://github.com/npm/npm/commit/2a11e562a14bce18b6ddca6c20d17f97b6a8ec2f) - [#11403](https://github.com/npm/npm/pull/11403) - Removes `--depth Infinity` warning from documentation -- this operation should - actually be totally safe as of `npm@3`. (The warning remains for `npm@2`.) - ([@Aourin](https://github.com/Aourin)) -* [`42a4727`](https://github.com/npm/npm/commit/42a4727bfb1e21c890b8e2babda55e06ac2bda29) - [#11391](https://github.com/npm/npm/pull/11391) - Fixed versions of `shrinkwrap.json` in examples in documentation for `npm - shrinkwrap`, which did not quite match up. - ([@xcatliu](https://github.com/xcatliu)) - -### v3.7.2 (2016-02-04): - -This week, the CLI team has been busy working on rewriting tests to support -getting coverage reports going and running all of our tests on Windows. -Meanwhile, we've got a bunch of dependency updates and one or two other -things. - -#### TESTS WENT INTO HIDING - -Last week we took a patch from [@substack](https://github.com/substack) to -stop the installer from reordering arrays in an installed module's -`package.json`... but somehow I dropped the test when I was rebasing. - -* [`21b9271`](https://github.com/npm/npm/commit/21b927182514a0ff6d9f34480bfc39f72e3e9f8c) - [#10063](https://github.com/npm/npm/issues/10063) - Restore test that verifies that we don't re-order arrays in a module's - `package.json` on install. - ([@substack](https://github.com/substack)) - -#### DOCUMENTATION FIXES - -* [`c67521d`](https://github.com/npm/npm/commit/c67521dc6c1e41d39d02c74105e41442851d23bb) - [#11348](https://github.com/npm/npm/pull/11348) - Improve the documentation around which files are ALWAYS included in published packages - and which are ALWAYS excluded. - ([@jscissr](https://github.com/jscissr)) -* [`7ef6793`](https://github.com/npm/npm/commit/7ef6793cd191cc8d88340f7e1ce9c9e3d6f0b2f4) - [#11348](https://github.com/npm/npm/pull/11348) - The release date on the 3.7.0 changelog entry was wrong. I honestly don't - know how I keep doing this. =D - ([@rafek](https://github.com/rafek)) - -#### DEPENDENCY UPDATES - -* [`8a3c80c`](https://github.com/npm/npm/commit/8a3c80c4fd3d82fe937f30bc7cbd3dee51a8a893) - `graceful-fs@4.1.3`: - Fix a bug where close wasn't getting made graceful. - ([@isaacs](https://github.com/isaacs)) - -`lodash` saw updates across most of its modules this week with browser -campatibility fixes that don't really impact us. - -* [`2df342b`](https://github.com/npm/npm/commit/2df342bf30efa99b98016acc8a5dc03e00b58b9c) - `lodash.without@4.0.2` - ([@jdalton](https://github.com/jdalton)) -* [`86aa91d`](https://github.com/npm/npm/commit/86aa91dce60f6b6a92bb3ba2bf6e6be1f6afc750) - `lodash.uniq@4.0.2` - ([@jdalton](https://github.com/jdalton)) -* [`0a94bf6`](https://github.com/npm/npm/commit/0a94bf6af0ebd38d080f92257e0cd9bae40b31ff) - `lodash.union@4.0.2` - ([@jdalton](https://github.com/jdalton)) -* [`b4c9582`](https://github.com/npm/npm/commit/b4c9582b4ef5991f3d155e0c6142ed1c631860af) - `lodash.isarguments@3.0.6` - ([@jdalton](https://github.com/jdalton)) -* [`efe766c`](https://github.com/npm/npm/commit/efe766c63c0948a4ae4c0d12f2b834629ab86e92) - `lodash.keys@4.0.2`: Minor code cleanup and the above. - ([@jdalton](https://github.com/jdalton)) -* [`36abb24`](https://github.com/npm/npm/commit/36abb24ef31017adbf325e7f833d5d4b0f03f5d4) - `lodash.clonedeep@4.0.4`: - Add support for cloning prototype objects and the above. - ([@jdalton](https://github.com/jdalton)) - -### v3.7.1 (2016-02-01): - -Super quick Monday patch on last week's release. - -If you ever wondered why we release things to the `npm@next` tag for a week -before promoting them to `npm@latest`, this is it! - -#### RELEASE TRAIN VINDICATED (again) - -* [`adcaf04`](adcaf047811dcc475ab1984fc93fe34540fc03d7) - [#11349](https://github.com/npm/npm/issues/11349) - Revert last weeks change to use JSON clone instead of `lodash.cloneDeep`. - ([@iarna](https://github.com/iarna)) - -### v3.7.0 (2016-01-29): - -Hi all! This week brings us some important performance improvements, -support for git submodules(!) and a bunch of bug fixes. - -#### PERFORMANCE - -`gauge`, the module responsible for drawing `npm`'s progress bars, had an -embarrassing bug in its debounce implementation that resulted in it, on many -systems, actually being _slower_ than if it hadn't been debouncing. This was -due to it destroying and then creating a timer object any time it got an -update while waiting on its minimum update period to elapse. This only was -a measurable slowdown when sending thousands of updates a second, but -unfortunately parts of `npm`'s logging do exactly that. This has been patched -to eliminate that churn, and our testing shows the progress bar as being -eliminated as a source of slow down. - -Meanwhile, `are-we-there-yet` is the module that tracks just how complete -our big asynchronous install process is. [@STRML](https://github.com/STRML) -spent some time auditing its source and made a few smaller performance -improvements to it. Most impactful was eliminating a bizarre bit of code -that was both binding to AND closing over the current object. I don't have -any explanation for how that crept in. =D - -* [`c680fa9`](https://github.com/npm/npm/commit/c680fa9f8135759eb5512f4b86e47fa265733f79) - `npmlog@2.0.2`: New `are-we-there-yet` with performance patches from - [@STRML](https://github.com/STRML). New `gauge` with timer churn - performance patch. - ([@iarna](https://github.com/iarna)) - -We were also using `lodash`'s `cloneDeep` on `package.json` data which is -definitely overkill, seeing as `package.json` data has all the restrictions -of being `json`. The fix for this is just swapping that out for something -that does a pair of `JSON.stringify`/`JSON.parse`, which is distinctly more -speedy. - -* [`1d1ea7e`](https://github.com/npm/npm/commit/1d1ea7eeb958034878eb6573149aeecc686888d3) - [#11306](https://github.com/npm/npm/pull/11306) - Use JSON clone instead of `lodash.cloneDeep`. - ([@STRML](https://github.com/STRML)) - -#### NEW FEATURE: GIT SUBMODULE SUPPORT - -Long, long requested– the referenced issue is from 2011– we're finally -getting rudimentary git submodule support. - -* [`39dea9c`](https://github.com/npm/npm/commit/39dea9ca4216c6ea628f5ca47d2b34a4b251a1ed) - [#1876](https://github.com/npm/npm/issues/1876) - Add support for git submodules in git remotes. This is a fairly simple - approach, which does not leverage the git caching mechanism to cache - submodules. It also doesn't provide a means to disable automatic - initialization, e.g. via a setting in the `.gitmodules` file. - ([@gagern](https://github.com/gagern)) - -#### ROBUSTNESS - -* [`5dec02a`](https://github.com/npm/npm/commit/5dec02a3d0e82202c021e27aff9d006283fdc25a) - [#10347](https://github.com/npm/npm/issues/10347) - There is an obscure feature that lets you monkey-patch npm when it starts - up. If the module being required with this feature failed, it would - previously just make `npm` error out– this reduces that to a warning. - ([@evanlucas](https://github.com/evanlucas)) - -#### BUG FIXES - -* [`9ab8b8d`](https://github.com/npm/npm/commit/9ab8b8d047792612ae7f9a6079745d51d5283a53) - [#10820](https://github.com/npm/npm/issues/10820) - Fix a bug with `npm ls` where if you asked for ONLY production dependencies in output - it would exclude dependencies that were BOTH production AND development dependencies. - ([@davidvgalbraith](https://github.com/davidvgalbraith)) -* [`6803fed`](https://github.com/npm/npm/commit/6803fedadb8f9b36cd85f7338ecf75d1d183c833) - [#8982](https://github.com/npm/npm/issues/8982) - Fix a bug where, under some circumstances, if you had a path that - contained the name of a package being installed somewhere in it, `npm` - would incorrectly refuse to run lifecycle scripts. - ([@elvanja](https://github.com/elvanja)) -* [`3eae40b`](https://github.com/npm/npm/commit/3eae40b7a681aa067dfe4fea8c9a76da5b508b48) - [#9253](https://github.com/npm/npm/issues/9253) - Fix a bug where, when running lifecycle scripts, if the Node.js binary you ran - `npm` with wasn't in your `PATH`, `npm` wouldn't use it to run your scripts. - ([@segrey](https://github.com/segrey)) -* [`61daa6a`](https://github.com/npm/npm/commit/61daa6ae8cbc041d3a0d8a6f8f268b47dd8176eb) - [#11014](https://github.com/npm/npm/issues/11014) - Fix a bug where running `rimraf node_modules/<package>` followed by `npm - rm --save <package>` would fail. `npm` now correctly removes the module - from your `package.json` even though it doesn't exist on disk. - ([@davidvgalbraith](https://github.com/davidvgalbraith)) -* [`a605586`](https://github.com/npm/npm/commit/a605586df134ee97c95f89c4b4bd6bc73f7aa439) - [#9679](https://github.com/npm/npm/issues/9679) - Fix a bug where `npm install --save git+https://…` would save a `https://` - url to your `package.json` which was a problem because `npm` wouldn't then - know that it was a git repo. - ([@gagern](https://github.com/gagern)) -* [`bbdc700`](https://github.com/npm/npm/commit/bbdc70024467c365cc4e06b8410947c04b6f145b) - [#10063](https://github.com/npm/npm/issues/10063) - Fix a bug where `npm` would change the order of array properties in the - `package.json` files of dependencies. `npm` adds a bunch of stuff to - `package.json` files in your `node_modules` folder for debugging and - bookkeeping purposes. As a part of this process it sorts the object to - reduce file churn when it does updates. This fixes a bug where the arrays - in the object were also getting sorted. This wasn't a problem for - properties that `npm` itself maintains, but _is_ a problem for properties - used by other packages. - ([@substack](https://github.com/substack)) - -#### DOCS IMPROVEMENTS - -* [`2609a29`](https://github.com/npm/npm/commit/2609a2950704f577ac888668e81ba514568fab44) - [#11273](https://github.com/npm/npm/pull/11273) - Include an example of viewing package version history in the `npm view` documentation. - ([@vedatmahir](https://github.com/vedatmahir)) -* [`719ea9c`](https://github.com/npm/npm/commit/719ea9c45a5c3233f3afde043b89824aad2df0a7) - [#11272](https://github.com/npm/npm/pull/11272) - Fix typographical issue in `npm update` documentation. - ([@jonathanp](https://github.com/jonathanp)) -* [`cb9df5a`](https://github.com/npm/npm/commit/cb9df5a37091e06071d8704b629e7ebaa41c37fe) - [#11215](https://github.com/npm/npm/pull/11215) - Do not call `SEE LICENSE IN <filename>` an _SPDX expression_, as it's not. - ([@kemitchell](https://github.com/kemitchell)) -* [`f427934`](https://github.com/npm/npm/commit/f4279346c368da4bca09385f773e8eed1d389e5e) - [#11196](https://github.com/npm/npm/pull/11196) - Correct the `package.json` examples in the `npm update` documentation to actually be - valid JSON and not just JavaScript object literals. - ([@s100](https://github.com/s100)) - -#### DEPENDENCY UPDATES - -* [`a7b2407`](https://github.com/npm/npm/commit/a7b24074cb59a1ab17c0d8eff1498047e6a123e5) - `retry@0.9.0`: New features and interface agnostic refactoring. - ([@tim-kos](https://github.com/tim-kos)) -* [`220fc77`](https://github.com/npm/npm/commit/220fc7702ae3e5d601dfefd3e95c14e9b32327de) - `request@2.69.0`: - A bunch of small bug fixes and module updates. - ([@simov](https://github.com/simov)) -* [`9e5c84f`](https://github.com/npm/npm/commit/9e5c84f1903748897e54f8ff099729ff744eab0f) - `which@1.2.4`: - Update `isexe` and fix bug in `pathExt`, in which files without extensions - would sometimes be preferred to files with extensions on Windows, even though - those without extensions aren't executable. - `pathExt` is a list of extensions that are considered executable (exe, cmd, - bat, com on Windows). - ([@isaacs](https://github.com/isaacs)) -* [`375b9c4`](https://github.com/npm/npm/commit/375b9c42fe0c6de47ac2f92527354b2ea79b7968) - `rimraf@2.5.1`: Minor doc formatting fixes. - ([@isaacs](https://github.com/isaacs)) -* [`ef1971e`](https://github.com/npm/npm/commit/ef1971e6270c2bc72e6392b51a8b84f52708f7e7) - `lodash.clonedeep@4.0.2`: - Misc minor code cleanup. No functional changes. - ([@jdalton](https://github.com/jdalton)) - -### v3.6.0 (2016-01-20): - -Hi all! This is a bigger release, in part 'cause we didn't have one last -week. The most important thing you need to know is that when `npm@3.6.0` replaces -`npm@3.5.4` as `next`, `npm@3.5.4` WILL NOT be moved on to `latest`. This is due to -a packaging error that tickles bugs in some earlier releases and makes upgrades to it -from those versions break the install. - -#### NEW FEATURES‼ - -* [`ff504d4`](https://github.com/npm/npm/commit/ff504d449ea1fa996cbb02c8078964643c51e5f6) - [#8752](https://github.com/npm/npm/issues/8752) - In `npm outdated`, report symlinked packages as having a wanted & latest - version of `linked`. - ([@halhenke](https://github.com/halhenke)) -* [`f44d8c9`](https://github.com/npm/npm/commit/f44d8c9a3940f7041f8136f8754a54b13f1f9d60) - [#10775](https://github.com/npm/npm/issues/10775) - Add a success message to `adduser` / `login`. - ([@ekmartin](https://github.com/ekmartin)) -* [`3109303`](https://github.com/npm/npm/commit/310930395c9bf1577cf085b9742210bfc71bb019) - [#10043](https://github.com/npm/npm/pull/10043) - Warn if you try to use `npm run x` if you don't have a `node_modules` folder, since - whatever you're trying to do _probably_ won't work. - ([@timkrins](https://github.com/timkrins)) - -* [`9ed2849`](https://github.com/npm/npm/commit/9ed2849cd7e8cc97111dca42a940905284afe55d) - [`e9f1ad8`](https://github.com/npm/npm/commit/e9f1ad88ce58ecd111811e11afa52ac19fc8696e) - [`f10d300`](https://github.com/npm/npm/commit/f10d300e5effa7a5756c8d461eef284c283a41d1) - [`8b593d8`](https://github.com/npm/npm/commit/8b593d8d187d6ac85d2a59cbe647afb5516c1b94) - [#10717](https://github.com/npm/npm/pull/10717) - `npm version` can now take a `from-git` argument, which instructs `npm` to read the - version from git and update your `package.json` to what it finds. This is in contrast - to its normal use where `npm` _tells_ git about your new version. - ([@ekmartin](https://github.com/ekmartin)) - -#### 3.5.4 WAS NOT SO GREAT - -The `npm@3.5.4` package was missing some dependencies. Specifically, `glob` -and `has-unicode` had major release updates which meant that subdeps that -relied on older major versions couldn't use the npm supplied versions any -more, and so they needed their own copies. - -This went undetected because the actions necessary to run the tests (which -check for this sort of thing) resolved the missing modules. - -Further, it didn't have symptoms when upgrading from _most_ versions of npm. -Unfortunately, some versions had bugs that were tickled by this and resulted -in broken upgrades, most notably, `npm@3.3.12`, the version that's been in -Node.js 5. - -* [`1d3325c`](https://github.com/npm/npm/commit/1d3325c040621a4792db80fb232f4994b9d5c5f2) - [`02611c6`](https://github.com/npm/npm/commit/02611c673a4d2bbe8fcef8d48407768da31c90d2) - [`39d5fea`](https://github.com/npm/npm/commit/39d5feadefdde38d75a18f23343bc6ec37153638) - [`7d0e830`](https://github.com/npm/npm/commit/7d0e830f26c73b9d9277b29949227ba9cca27fd9) - [#11129](https://github.com/npm/npm/pull/11129) - Update the underlying dependencies to allow use for the new versions of - `glob` and `has-unicode`. - ([@iarna](https://github.com/iarna)) - -#### WHEN MISSING PATHS ARE OK - -* [`bb638fa`](https://github.com/npm/npm/commit/bb638fa4f48d24d2c9935861d5d751c5621eea49) - [#11212](https://github.com/npm/npm/pull/11212) - When trying to determine if a file was controlled by npm before going to - remove it, we check to see if it is inside any of a list of paths that npm - considers to be under its control. Not all of those paths always exist - (and that's ok!) Previously we were calling it a failure to match if ANY - of them didn't exist. We now only do so if NONE of them exist. If some - do, then we do our usual checks on them. - - This showed up as an error where you would see something like: - ``` - npm warn gentlyRm not removing /path/to/thing as it wasn't installed by /path/to/other/thing - ``` - But it totally was installed by it. - ([@iarna](https://github.com/iarna)) - -#### BETTER NODE PRE-RELEASE SUPPORT - -Historically, if you used a pre-release version of Node.js, you would get -dozens and dozens of warnings when EVERY engine check failed across all of -your modules, because `>= 0.10.0` doesn't match prereleases. - -You might find this stream of redundant warnings undesirable. I do. - -We've moved this into a SINGLE warning you'll get about using a pre-release -version of Node.js and now suppress those other warnings. - -* [`6952f79`](https://github.com/npm/npm/commit/6952f7981e451a2d599a4f513573af208bdfe103) - [#11212](https://github.com/npm/npm/pull/11212) - Engine check warnings are now issued along with any other warnings about - your tree, instead of emitting in the middle of your install (and then - disappearing behind the giant tree of stuff installed). - ([@iarna](https://github.com/iarna)) -* [`ee2ebe9`](https://github.com/npm/npm/commit/ee2ebe96fb3d105787835b72085bbd2eee66a629) - [#11212](https://github.com/npm/npm/pull/11212) - Suppress engine verification warnings about pre-release versions of Node.js. - ([@iarna](https://github.com/iarna)) -* [`135b7e0`](https://github.com/npm/npm/commit/135b7e078311e8b4e2c8e2b662eed9ba6c2e2537) - [#11212](https://github.com/npm/npm/pull/11212) - Explicitly warn, in only one place, if you are using a pre-release version - of Node.js. - ([@iarna](https://github.com/iarna)) - -#### BUG FIXES - -* [`ea331c8`](https://github.com/npm/npm/commit/ea331c82157c65f7643cd4b49fd24031c84bf601) - [#10938](https://github.com/npm/npm/issues/10938) - When removing a package, sometimes the `node_modules/.bin` wouldn't be - cleaned up entirely. This would result in package folders that contained - only a `node_modules/.bin` directory. In turn, this would result in `npm - ls` and other tools complaining about these broken directories. - To fix this, the `unbuild` step now explicitly deletes the - `node_modules/.bin` folder as its final step. - ([@chrisirhc](https://github.com/chrisirhc)) -* [`00720db`](https://github.com/npm/npm/commit/00720db2c326cf8f968c662444a4575ae8c3020a) - [#11158](https://github.com/npm/npm/pull/11158) - On Windows, the `node-gyp` wrapper would fail if your path to `node-gyp` - contained spaces. This fixes that problem by quoting use of that path. - ([@orangemocha](https://github.com/orangemocha)) -* [`69ac933`](https://github.com/npm/npm/commit/69ac9333506752bf2e5af70b3b3e03c6181de3e7) - [#11142](https://github.com/npm/npm/pull/11142) - Fix a race condition when making directories in the cache, which could - lead to `ENOENT` failures. - ([@Jimbly](https://github.com/Jimbly)) -* [`e982858`](https://github.com/npm/npm/commit/e982858d9bed65cede9cbb12df9216a4bb9e6fc9) - [#9696](https://github.com/npm/npm/issues/9696) - When replacing the `package.json` in the cache you sometimes see `EPERM` errors on - Windows that you wouldn't on Unix-like operating systems. This ignores those errors - and allows Windows to continue. Longer term, we'll be adding something to retry - these errors, but ultimately fail if there really is an ongoing permissions issue. - ([@orangemocha](https://github.com/orangemocha)) - -#### DOC CHANGES - -* [`3666081`](https://github.com/npm/npm/commit/3666081abd02184ba97a7cdb6ae238085d640b4b) - [#11188](https://github.com/npm/npm/pull/11188) - Add brief description to publish documentation of what's included in - published tarballs. - ([@beaugunderson](https://github.com/beaugunderson)) -* [`b463e34`](https://github.com/npm/npm/commit/b463e3424b296cfc4bd384fc8bfe0e2329649164) - [#11150](https://github.com/npm/npm/pull/11150) - In npm update docs, advise use of `--depth Infinity` instead of `--depth - 9999`. - ([@halhenke](https://github.com/halhenke)) -* [`382e71a`](https://github.com/npm/npm/commit/382e71a7ee5d1ca3dba55c1e753d529eb8ae6895) - [#11128](https://github.com/npm/npm/pull/11128) - In the `package.json` docs, make the reference to the "Local Paths" section - a link to it as well. - ([@orangejulius](https://github.com/orangejulius)) -* [`5277e7f`](https://github.com/npm/npm/commit/5277e7f236e8cb40d7f4a1054506f2d3d159716e) - [#11090](https://github.com/npm/npm/pull/11090) - Fix the 3.5.4 release date in CHANGELOG.md. - ([@ashleygwilliams](https://github.com/ashleygwilliams)) -* [`e6d238a`](https://github.com/npm/npm/commit/e6d238a3d90beeb0af23fa75a9b5e50671d6e4c5) - [#11130](https://github.com/npm/npm/pull/11130) - Eliminate the "using npm programmatically" section from the README. The - documentation for this was removed a while ago and is unsupported. - ([@ljharb](https://github.com/ljharb)) - -#### DEPENDENCY UPDATES - -* [`b0dde5c`](https://github.com/npm/npm/commit/b0dde5c3407b58d78969d3da01af2629fcba1c73) - `config-chain@1.1.10`: Update tests for most recent version of `ini`. - ([@dominictarr](https://github.com/dominictarr)) -* [`c62f414`](https://github.com/npm/npm/commit/c62f414534971761a48ce3cbc3e25214fb09e494) - `glob@6.0.4`: Eliminated use of `util._extend`. - ([@isaacs](https://github.com/isaacs)) -* [`98a6779`](https://github.com/npm/npm/commit/98a67797978ed7ce534e16b705d3a2a9ca0e6cc1) - `lodash.clonedeep@4.0.1`: Bug fixes, including the non-linear performance - that was biting npm a while back. - ([@jdalton](https://github.com/jdalton)) -* [`0e8c4ce`](https://github.com/npm/npm/commit/0e8c4cebddaefbf5eca0abaad512db266c6722c9) - `lodash.without@4.0.1` - ([@jdalton](https://github.com/jdalton)) -* [`1fd19f5`](https://github.com/npm/npm/commit/1fd19f57a3551d7d30a6b8a9ce967ef50e0ff0ba) - `lodash.uniq@4.0.1` - ([@jdalton](https://github.com/jdalton)) -* [`b7486c5`](https://github.com/npm/npm/commit/b7486c550f3391f733d1e1907652be95fddf4368) - `lodash.union@4.0.1` - ([@jdalton](https://github.com/jdalton)) -* [`54bb591`](https://github.com/npm/npm/commit/54bb5911e18f8fb86eb94159f34b13f0c0aa2e30) - `lodash.keys@4.0.0` - ([@jdalton](https://github.com/jdalton)) -* [`26f7a7a`](https://github.com/npm/npm/commit/26f7a7aaae0575a85deba2241ee69b433dd1ba98) - `lodash.isarray@4.0.0` - ([@jdalton](https://github.com/jdalton)) -* [`ed38bd3`](https://github.com/npm/npm/commit/ed38bd3baf544dfc0630fd321d279f137700bd4d) - `lodash.isarguments@3.0.5` - ([@jdalton](https://github.com/jdalton)) - -### v3.5.4 (2016-01-07): - -I hope you all had fantastic winter holidays, if it's winter where you are -and if there are holidays‼ We went a few weeks without releases because -staff was taking time away from work here and there. A new year has come -and we're back now, and refreshed and ready to dig in! - -This week brings us a bunch of documentation improvements and some module -updates. The core team's focus continues to be on improving tests, -particularly with Windows, so there's not too much to call out here. - -#### DOCUMENTATION IMPROVEMENTS - -* [`6b0031e`](https://github.com/npm/npm/commit/6b0031e28c0b10fb2622fdadde41f5cd294348e8) - [#11044](https://github.com/npm/npm/pull/11044) - Correct documentation regarding the defaults for the `color` config option. - ([@scottaddie](https://github.com/scottaddie)) -* [`c6ce69e`](https://github.com/npm/npm/commit/c6ce69eaed7f17b5f1876ac13ecfae3d14a72f24) - [#10990](https://github.com/npm/npm/pull/10990) - Drop mentions in documentation of `process.installPrefix`, as it hasn't - been a thing since Node.js 0.6 and we don't support that. - ([@jeffmcmahan](https://github.com/jeffmcmahan)) -* [`dee92d1`](https://github.com/npm/npm/commit/dee92d1f78608a10becf57aae86d5d495f2272bd) - [#11037](https://github.com/npm/npm/pull/11037) - Clarify the documentation on the max length of the `name` property in - `package.json` files. - ([@scottaddie](https://github.com/scottaddie)) -* [`4b9d7bb`](https://github.com/npm/npm/commit/4b9d7bb1a4fc3f1edcf563379abfd2273af10881) - [#10787](https://github.com/npm/npm/pull/10787) - Make the formatting in the documentation for `npm dist-tag` more - consistent with other docs. - ([@cvrebert](https://github.com/cvrebert)) -* [`7f77a80`](https://github.com/npm/npm/commit/7f77a80d561ee4b2b8c0aba1226fe89dfe339bcd) - [#10787](https://github.com/npm/npm/pull/10787) - Add documentation to the `npm dist-tag` docs that explains in greater - detail how `latest` is different than other tags. Further, improve the - documentation with better examples. Add a discussion of common practice - for using dist tags to manage alpha's and beta's. - ([@cvrebert](https://github.com/cvrebert)) -* [`6db58dd`](https://github.com/npm/npm/commit/6db58dd0d7719c4675a239d43164edc066842b14) - [`2ee6371`](https://github.com/npm/npm/commit/2ee6371911bd3a4d566c5d7bc8734facc60cb27c) - [#10788](https://github.com/npm/npm/pull/10788) - [#10789](https://github.com/npm/npm/pull/10789) - Improve documentation cross referencing. - ([@cvrebert](https://github.com/cvrebert)) -* [`7ba629a`](https://github.com/npm/npm/commit/7ba629a2ad3eaf736529e053b533cabe3a0d7123) - [#10790](https://github.com/npm/npm/pull/10790) - Document more clearly that `npm install foo` means `npm install - foo@latest`. - ([@cvrebert](https://github.com/cvrebert)) - -#### A FEW MODULE UPDATES - -* [`fc2e8d5`](https://github.com/npm/npm/commit/fc2e8d58a91728cb06936eea686efaa4fdec3f06) - `glob@6.0.3`: Remove deprecated features and fix a bunch of bugs. - ([@isaacs](https://github.com/isaacs)) -* [`5b820c4`](https://github.com/npm/npm/commit/5b820c4e17c907fa8c23771c0cd8e74dd5fdaa51) - `has-unicode@2.0.0`: Change the default on Windows to be false, as - international Windows installs often install to non-unicode codepages and - there's no way to detect this short of a system call or a call to a - command line program. - ([@iarna](https://github.com/iarna)) -* [`238fe84`](https://github.com/npm/npm/commit/238fe84ac61297f1d71701d80368afaa40463305) - `which@1.2.1`: Fixed bugs with uid/gid checks and with quoted Windows PATH - parts. - ([@isaacs](https://github.com/isaacs)) -* [`5e510e1`](https://github.com/npm/npm/commit/5e510e13d022a22d58742b126482d3b38a14cc83) - `rimraf@2.5.0`: Add ability to disable glob support / pass in options. - ([@isaacs](https://github.com/isaacs)) -* [`7558215`](https://github.com/npm/npm/commit/755821569466b7be0883f4b0573eeb83c24109eb) - `readable-stream@2.0.5`: Minor performance improvements. - ([@calvinmetcalf](https://github.com/calvinmetcalf)) -* [`64e8499`](https://github.com/npm/npm/commit/64e84992c812a73d590be443c09a6977d0ae9040) - `fs-write-stream-atomic@1.0.8`: Rewrite to use modern streams even on 0.8 - plus a bunch of tests. - ([@iarna](https://github.com/iarna)) -* [`74d92a0`](https://github.com/npm/npm/commit/74d92a08d72ce3603244de4bb3e3706d2b928cef) - `columnify@1.5.4`: Some bug fixes around large inputs. - ([@timoxley](https://github.com/timoxley)) - -#### FIX NPM'S TESTS ON 0.8 - -This doesn't impact you as a user of npm, and ordinarily that means we -wouldn't call it out here, but if you've ever wanted to contribute, having -that green travis badge makes it a lot easier to do so with confidence! - -* [`b14cdbb`](https://github.com/npm/npm/commit/b14cdbb6002b04bfbefaff70cc45810c20d5a366) - [#10872](https://github.com/npm/npm/pull/10872) - Rewrite tests using nock to use other alternatives. - ([@zkat](https://github.com/zkat)) -* [`59ed01a`](https://github.com/npm/npm/commit/59ed01a8ea7960b1467aed52164fc36a03c77770) - [#10872](https://github.com/npm/npm/pull/10872) - Work around Node.js 0.8 http back-pressure bug. - - 0.8 http streams have a bug, where if they're paused with data in their - buffers when the socket closes, they call `end` before emptying those - buffers, which results in the entire pipeline ending and thus the point - that applied backpressure never being able to trigger a `resume`. - - We work around this by piping into a pass through stream that has - unlimited buffering. The pass through stream is from readable-stream and - is thus a current streams3 implementation that is free of these bugs even - on 0.8. - ([@iarna](https://github.com/iarna)) - -### v3.5.3 (2015-12-10): - -Did you know that Bob Ross reached the rank of master sergeant in the US Air -Force before becoming perhaps the most soothing painter of all time? - -#### TWO HAPPY LITTLE BUG FIXES - -* [`71c9590`](https://github.com/npm/npm/commit/71c9590be61b6a7b7fa8b6dc19baa588cda26a27) - [#10505](https://github.com/npm/npm/issues/10505) `npm ls --json --depth=0` - now respects the depth parameter, when it is zero and when it is not zero. - ([@MarkReeder](https://github.com/MarkReeder)) -* [`954fa67`](https://github.com/npm/npm/commit/954fa67f1ca3739992abd244e217a0aaf8465660) - [#9099](https://github.com/npm/npm/issues/9099) I had always thought you - could run `npm version` from subdirectories in your project, which is great, - because now you can. I guess I was just ahead of my time. - ([@ekmartin](https://github.com/ekmartin)) - -#### NOW PAINT IN SOME NICE DOCS CHANGES - -* [`b88c37c`](https://github.com/npm/npm/commit/b88c37c1cced40e9e41402cc54a5efc3c33cd13e) - [#10546](https://github.com/npm/npm/issues/10546) Goodbye, FAQ! You were - cheeky and fun until you weren't! Don't worry: npm still loves everyone, - especially you! ([@ashleygwilliams](https://github.com/ashleygwilliams)) -* [`2d3afe9`](https://github.com/npm/npm/commit/2d3afe9644ba69681a36721e79c45d27def71939) - [#10570](https://github.com/npm/npm/issues/10570) Update documentation URLs - to be HTTPS everywhere sensible. No HTTP shall be spared! - ([@rsp](https://github.com/rsp)) -* [`6abd0e0`](https://github.com/npm/npm/commit/6abd0e0626d0f642ce0dae0e128ced80433f15a1) - [#10650](https://github.com/npm/npm/issues/10650) Correctly note that there - are two lifecycle scripts run by an install phase in an example, instead of - three. ([@eymengunay](https://github.com/eymengunay)) -* [`a5e8df5`](https://github.com/npm/npm/commit/a5e8df53b8d6d75398cb6a55a44dcf374b0f1661) - [#10687](https://github.com/npm/npm/issues/10687) `npm outdated`'s output can - be a little puzzling sometimes. I've attempted to make it clearer, with some - examples, of what's going on with "wanted" and "latest" in more cases. - ([@othiym23](https://github.com/othiym23)) -* [`8f52833`](https://github.com/npm/npm/commit/8f52833f5d15c4f94467234607d40e75198af1aa) - [#10700](https://github.com/npm/npm/issues/10700) Hey, do you remember when - `search.npmjs.org` was a thing? I think I do? The last time I used it was in - like 2012, and it's gone now, so remove it from the docs. - ([@gagern](https://github.com/gagern)) -* [`b6a53b8`](https://github.com/npm/npm/commit/b6a53b889c948053dcbf6d7aab9ad1cd4226dc32) - [npm/docs#477](https://github.com/npm/docs/issues/477) Continue to airbrush - the CLI API docs out of history. ([@verpixelt](https://github.com/verpixelt)) -* [`b835b72`](https://github.com/npm/npm/commit/b835b72d1dd23b0a17321a85d8d395322d18005d) - `semver@5.1.0`: Include BNF for SemVer expression grammar (which is also now - included in `npm help semver`). ([@isaacs](https://github.com/isaacs)) - -#### LAND YOUR DEPENDENCY UPGRADES IN PAIRS SO EVERYONE HAS A FRIEND - -* [`95e99fa`](https://github.com/npm/npm/commit/95e99faadcdc85a16210dd79c0e7d83add1b9f3e) - `request@2.67.0` ([@simov](https://github.com/simov)) -* [`b49199a`](https://github.com/npm/npm/commit/b49199ac96dfb1afe5719286621a318576dd69ae) - [isaacs/rimraf#89](https://github.com/isaacs/rimraf/pull/89) `rimraf@2.4.4` - ([@zerok](https://github.com/zerok)) -* [`6632418`](https://github.com/npm/npm/commit/66324189a734a1665e1b78a06ba44089d9c3a11c) - [npm/nopt#51](https://github.com/npm/nopt/pull/51) `nopt@3.0.6` - ([@wbecker](https://github.com/wbecker)) -* [`f0a3b3e`](https://github.com/npm/npm/commit/f0a3b3e0dbbdaf11ec55dccd59cc21bfa05f9240) - [isaacs/once#7](https://github.com/isaacs/once/pull/7) `once@1.3.3` - ([@floatdrop](https://github.com/floatdrop)) - -### v3.5.2 (2015-12-03): - -Weeeelcome to another npm release! The short version is that we fixed -some `ENOENT` and some modules that resulted in modules going missing. We -also eliminated the use of MD5 in our code base to help folks using -Node.js in FIPS mode. And we fixed a bad URL in our license file. - -#### FIX URL IN LICENSE - -The license incorrectly identified the registry URL as -`registry.npmjs.com` and this has been corrected to `registry.npmjs.org`. - -* [`cb6d81b`](https://github.com/npm/npm/commit/cb6d81bd611f68c6126a90127a9dfe5604d46c8c) - [#10685](https://github.com/npm/npm/pull/10685) - Fix npm public registry URL in notices. - ([@kemitchell](https://github.com/kemitchell)) - -#### ENOENT? MORE LIKE ENOMOREBUGS - -The headliner this week was uncovered by the fixes to bundled dependency -handling over the past few releases. What had been a frustratingly -intermittent and hard to reproduce bug became something that happened -every time in Travis. This fixes another whole bunch of errors where you -would, while running an install have it crash with an `ENOENT` on -`rename`, or the install would finish but some modules would be -mysteriously missing and you'd have to install a second time. - -What's going on was a bit involved, so bear with me: - -`npm@3` generates a list of actions to take against the tree on disk. -With the exception of lifecycle scripts, it expects these all to be able -to act independently without interfering with each other. - -This means, for instance, that one should be able to upgrade `b` in -`a→b→c` without having npm reinstall `c`. - -That works fine by the way. - -But it also means that the move action should be able to move `b` in -`a→b→c@1.0.1` to `a→d→b→c@1.0.2` without moving or removing `c@1.0.1` and -while leaving `c@1.0.2` in place if it was already installed. - -That is, the `move` action moves an individual node, replacing itself -with an empty spot if it had children. This is not, as it might first -appear, something where you move an entire branch to another location on -the tree. - -When moving `b` we already took care to leave `c@1.0.1` in place so that -other moves (or removes) could handle it, but we were stomping on the -destination and so `c@1.0.2` was being removed. - -* [`f4385d8`](https://github.com/npm/npm/commit/f4385d8e7678349e75c80fae8a1f8f366f197937) - [#10655](https://github.com/npm/npm/pull/10655) - Preserve destination `node_modules` when moving. - ([@iarna](https://github.com/iarna)) - -There was also a bug with `remove` where it was pruning the entire tree -at the remove point, prior to running moves and adds. - -This was fine most of the time, but if we were moving one of the deps out -from inside it, kaboom. - -* [`19c626d`](https://github.com/npm/npm/commit/19c626d69888f0cdc6e960254b3fdf523ec4b52c) - [#10655](https://github.com/npm/npm/pull/10655) - Get rid of the remove commit phase– we could have it prune _just_ the - module being removed, but that isn't gaining us anything. - ([@iarna](https://github.com/iarna)) - -After all that, we shouldn't be upgrading the `add` of a bundled package -to a `move`. Moves save us from having to extract the package, but with a -bundled dependency it's included in another package already so that -doesn't gain us anything. - -* [`641a93b`](https://github.com/npm/npm/commit/641a93bd66a6aa4edf2d6167344b50d1a2afb593) - [#10655](https://github.com/npm/npm/pull/10655) - Don't convert adds to moves with bundled deps. - ([@iarna](https://github.com/iarna)) - -While I was in there, I also took some time to improve diagnostics to -make this sort of thing easier to track down in the future: - -* [`a04ec04`](https://github.com/npm/npm/commit/a04ec04804e562b511cd31afe89c8ba94aa37ff2) - [#10655](https://github.com/npm/ npm/pull/10655) - Wrap rename so errors have stack traces. - ([@iarna](https://github.com/iarna)) -* [`8ea142f`](https://github.com/npm/npm/commit/8ea142f896a2764290ca5472442b27b047ab7a1a) - [#10655](https://github.com/npm/npm/pull/10655) - Add silly logging so function is debuggable - ([@iarna](https://github.com/iarna)) - -#### NO MORE MD5 - -We updated modules that had been using MD5 for non-security purposes. -While this is perfectly safe, if you compile Node in FIPS-compliance mode -it will explode if you try to use MD5. We've replaced MD5 with Murmur, -which conveys our intent better and is faster to boot. - -* [`f068b26`](https://github.com/npm/npm/commit/f068b2661a8d0269c184867e003cd08cb6c56cf2) - [#10629](https://github.com/npm/npm/issues/10629) - `unique-filename@1.1.0` - ([@iarna](https://github.com/iarna)) -* [`dba1b24`](https://github.com/npm/npm/commit/dba1b2402aaa2beceec798d3bd22d00650e01069) - [#10629](https://github.com/npm/npm/issues/10629) - `write-file-atomic@1.1.4` - ([@othiym23](https://github.com/othiym23)) -* [`8347a30`](https://github.com/npm/npm/commit/8347a308ef0d2cf0f58f96bba3635af642ec611f) - [#10629](https://github.com/npm/npm/issues/10629) - `fs-write-stream-atomic@1.0.5` - ([@othiym23](https://github.com/othiym23)) - -#### DEPENDENCY UPDATES - -* [`9e2a2bb`](https://github.com/npm/npm/commit/9e2a2bb5bc71a0ab3b3637e8eec212aa22d5c99f) - [nodejs/node-gyp#831](https://github.com/nodejs/node-gyp/pull/831) - `node-gyp@3.2.1`: - Improved \*BSD support. - ([@bnoordhuis](https://github.com/bnoordhuis)) - -### v3.5.1 (2015-11-25): - -#### THE npm CLI !== THE npm REGISTRY !== npm, INC. - -npm-the-CLI is licensed under the terms of the [Artistic License -2.0](https://github.com/npm/npm/blob/8d79c1a39dae908f27eaa37ff6b23515d505ef29/LICENSE), -which is a liberal open-source license that allows you to take this code and do -pretty much whatever you like with it (that is, of course, not legal language, -and if you're doing anything with npm that leaves you in doubt about your legal -rights, please seek the review of qualified counsel, which is to say, not -members of the CLI team, none of whom have passed the bar, to my knowledge). At -the same time the primary registry the CLI uses when looking up and downloading -packages is a commercial service run by npm, Inc., and it has its own [Terms of -Use](https://www.npmjs.com/policies/terms). - -Aside from clarifying the terms of use (and trying to make sure they're more -widely known), the only recent changes to npm's licenses have been making the -split between the CLI and registry clearer. You are still free to do whatever -you like with the CLI's source, and you are free to view, download, and publish -packages to and from `registry.npmjs.org`, but now the existing terms under -which you can do so are more clearly documented. Aside from the two commits -below, see also [the release notes for -`npm@3.4.1`](https://github.com/npm/npm/releases/tag/v3.4.1), which is where -the split between the CLI's code and the terms of use for the registry was -first made more clear. - -* [`35a5dd5`](https://github.com/npm/npm/commit/35a5dd5abbfeec4f98a2b4534ec4ef5d16760581) - [#10532](https://github.com/npm/npm/issues/10532) Clarify that - `registry.npmjs.org` is the default, but that you're free to use the npm CLI - with whatever registry you wish. ([@kemitchell](https://github.com/kemitchell)) -* [`fa6b013`](https://github.com/npm/npm/commit/fa6b0136a0e4a19d8979b2013622e5ff3f0446f8) - [#10532](https://github.com/npm/npm/issues/10532) Having semi-duplicate - release information in `README.md` was confusing and potentially inaccurate, - so remove it. ([@kemitchell](https://github.com/kemitchell)) - -#### EASE UP ON WINDOWS BASH USERS - -It turns out that a fair number of us use bash on Windows (through MINGW or -bundled with Git, plz – Cygwin is still a bridge too far, for both npm and -Node.js). [@jakub-g](https://github.com/jakub-g) did us all a favor and relaxed -the check for npm completion to support MINGW bash. Thanks, Jakub! - -* [`09498e4`](https://github.com/npm/npm/commit/09498e45c5c9e683f092ab1372670f81db4762b6) - [#10156](https://github.com/npm/npm/issues/10156) completion: enable on - Windows in git bash ([@jakub-g](https://github.com/jakub-g)) - -#### THE ONGOING SAGA OF BUNDLED DEPENDENCIES - -`npm@3.5.0` fixed up a serious issue with how `npm@3.4.1` (and potentially -`npm@3.4.0` and `npm@3.3.12`) handled the case in which dependencies bundled -into a package tarball are handled improperly when one or more of their own -dependencies are older than what's latest on the registry. Unfortunately, in -fixing that (quite severe) regression (see [`npm@3.5.0`'s release notes' for -details](https://github.com/npm/npm/releases/tag/v3.5.0)), we introduced a new -(small, and fortunately cosmetic) issue where npm superfluously warns you about -bundled dependencies being stale. We have now fixed that, and hope that we -haven't introduced any _other_ regressions in the process. :D - -* [`20824a7`](https://github.com/npm/npm/commit/20824a75bf7639fb0951a588e3c017a370ae6ec2) - [#10501](https://github.com/npm/npm/issues/10501) Only warn about replacing - bundled dependencies when actually doing so. ([@iarna](https://github.com/iarna)) - -#### MAKE NODE-GYP A LITTLE BLUER - -* [`1d14d88`](https://github.com/npm/npm/commit/1d14d882c3b5af0a7fee46e8e0e343d07e4c38cb) - `node-gyp@3.2.0`: Support AIX, use `which` to find Python, updated to a newer - version of `gyp`, and more! ([@bnoordhuis](https://github.com/bnoordhuis)) - -#### A BOUNTEOUS THANKSGIVING CORNUCOPIA OF DOC TWEAKS - -These are great! Keep them coming! Sorry for letting them pile up so deep, -everybody. Also, a belated Thanksgiving to our Canadian friends, and a happy -Thanksgiving to all our friends in the USA. - -* [`4659f1c`](https://github.com/npm/npm/commit/4659f1c5ad617c46a5e89b48abf0b1c4e6f04307) - [#10244](https://github.com/npm/npm/issues/10244) In `npm@3`, `npm dedupe` - doesn't take any arguments, so update documentation to reflect that. - ([@bengotow](https://github.com/bengotow)) -* [`625a7ee`](https://github.com/npm/npm/commit/625a7ee6b4391e90cb28a95f20a73fd794e1eebe) - [#10250](https://github.com/npm/npm/issues/10250) Correct order of `org:team` - in `npm team` documentation. ([@louislarry](https://github.com/louislarry)) -* [`bea7f87`](https://github.com/npm/npm/commit/bea7f87399d784e3a6d3393afcca658a61a40d77) - [#10371](https://github.com/npm/npm/issues/10371) Remove broken / duplicate - link to tag. ([@WickyNilliams](https://github.com/WickyNilliams)) -* [`0a25e29`](https://github.com/npm/npm/commit/0a25e2956e9ddd4065d6bd929559321afc512fde) - [#10419](https://github.com/npm/npm/issues/10419) Remove references to - nonexistent `npm-rm(1)` documentation. ([@KenanY](https://github.com/KenanY)) -* [`19b94e1`](https://github.com/npm/npm/commit/19b94e1e6781fe2f98ada0a3f49a1bda25e3e32d) - [#10474](https://github.com/npm/npm/issues/10474) Clarify that install finds - dependencies in `package.json`. ([@sleekweasel](https://github.com/sleekweasel)) -* [`b25efc8`](https://github.com/npm/npm/commit/b25efc88067c843ffdda86ea0f50f95d136a638e) - [#9948](https://github.com/npm/npm/issues/9948) Encourage users to file an - issue, rather than emailing authors. ([@trodrigues](https://github.com/trodrigues)) -* [`24f4ced`](https://github.com/npm/npm/commit/24f4cedc83b10061f26362bf2f005ab935e0cbfe) - [#10497](https://github.com/npm/npm/issues/10497) Clarify what a package is - slightly. ([@aredridel](https://github.com/aredridel)) -* [`e8168d4`](https://github.com/npm/npm/commit/e8168d40caae00b2914ea09dbe4bd1b09ba3dcd5) - [#10539](https://github.com/npm/npm/issues/10539) Remove an extra, spuriously - capitalized letter. ([@alexlukin-softgrad](https://github.com/alexlukin-softgrad)) - -### v3.5.0 (2015-11-19): - -#### TEEN ORCS AT THE GATES - -This week heralds the general release of the primary npm registry's [new -support for private packages for -organizations](http://blog.npmjs.org/post/133542170540/private-packages-for-organizations). -For many potential users, it's the missing piece needed to make it easy for you -to move your organization's private work onto npm. And now it's here! The -functionality to support it has been in place in the CLI for a while now, -thanks to [@zkat](https://github.com/zkat)'s hard work. - -During our final testing before the release, our ace support team member -[@snopeks](https://github.com/snopeks) noticed that there had been some drift -between the CLI team's implementation and what npm was actually preparing to -ship. In the interests of everyone having a smooth experience with this -_extremely useful_ new feature, we quickly made a few changes to square up the -CLI and the web site experiences. - -* [`d7fb92d`](https://github.com/npm/npm/commit/d7fb92d1c53ba5196ad6dd2101a06792a4c0412b) - [#9327](https://github.com/npm/npm/issues/9327) `npm access` no longer has - problems when run in a directory that doesn't contain a `package.json`. - ([@othiym23](https://github.com/othiym23)) -* [`17df3b5`](https://github.com/npm/npm/commit/17df3b5d5dffb2e9c223b9cfa2d5fd78c39492a4) - [npm/npm-registry-client#126](https://github.com/npm/npm-registry-client/issues/126) - `npm-registry-client@7.0.8`: Allow the CLI to grant, revoke, and list - permissions on unscoped (public) packages on the primary registry. - ([@othiym23](https://github.com/othiym23)) - -#### NON-OPTIONAL INSTALLS, DEFINITELY NON-OPTIONAL - -* [`180263b`](https://github.com/npm/npm/commit/180263b) - [#10465](https://github.com/npm/npm/pull/10465) - When a non-optional dep fails, we check to see if it's only required by - ONLY optional dependencies. If it is, we make it fail all the deps in - that chain (and roll them back). If it isn't then we give an error. - - We do this by walking up through all of our ancestors until we either hit an - optional dependency or the top of the tree. If we hit the top, we know to - give the error. - - If you installed a module by hand but didn't `--save` it, your module - won't have the top of the tree as an anscestor and so this code was - failing to abort the install with an error - - This updates the logic so that hitting the top OR a module that was - requested by the user will trigger the error message. - ([@iarna](https://github.com/iarna)) - -* [`b726a0e`](https://github.com/npm/npm/commit/b726a0e) - [#9204](https://github.com/npm/npm/issues/9204) - Ideally we would like warnings about your install to come AFTER the - output from your compile steps or the giant tree of installed modules. - - To that end, we've moved warnings about failed optional deps to the show - after your install completes. - ([@iarna](https://github.com/iarna)) - -#### OVERRIDING BUNDLING - -* [`aed71fb`](https://github.com/npm/npm/commit/aed71fb) - [#10482](https://github.com/npm/npm/issues/10482) - We've been in our bundled modules code a lot lately, and our last go at - this introduced a new bug, where if you had a module `a` that bundled - a module `b`, which in turn required `c`, and the version of `c` that - got bundled wasn't compatible with `b`'s `package.json`, we would then - install a compatible version of `c`, but also erase `b` at the same time. - - This fixes that. It also reworks our bundled module support to be much - closer to being in line with how we handle non-bundled modules and we're - hopeful this will reduce any future errors around them. The new structure - is hopefully much easier to reason about anyway. - ([@iarna](https://github.com/iarna)) - -#### A BRIEF NOTE ON NPM'S BACKWARDS COMPATIBILITY - -We don't often have much to say about the changes we make to our internal -testing and tooling, but I'm going to take this opportunity to reiterate that -npm tries hard to maintain compatibility with a wide variety of Node versions. -As this change shows, we want to ensure that npm works the same across: - -* Node.js 0.8 -* Node.js 0.10 -* Node.js 0.12 -* the latest io.js release -* Node.js 4 LTS -* Node.js 5 - -Contributors who send us pull requests often notice that it's very rare that -our tests pass across all of those versions (ironically, almost entirely due to -the packages we use for testing instead of any issues within npm itself). We're -currently beginning an effort, lasting the rest of 2015, to clean up our test -suite, and not only get it passing on all of the above versions of Node.js, but -working solidly on Windows as well. This is a compounding form of technical -debt that we're finally paying down, and our hope is that cleaning up the tests -will produce a more robust CLI that's a lot easier to write patches for. - -* [`791ec6b`](https://github.com/npm/npm/commit/791ec6b1bac0d1df59f5ebb4ccd16a29a5dc73f0) - [#10233](https://github.com/npm/npm/issues/10233) Update Node.js versions - that Travis uses to test npm. ([@iarna](https://github.com/iarna)) - -#### 0.8 + npm <1.4 COMPATIBLE? SURE WHY NOT - -Hey, you found the feature we added! - -* [`231c58a`](https://github.com/npm/npm/commit/231c58a) - [#10337](https://github.com/npm/npm/pull/10337) - Add two new flags, first `--legacy-bundling` which installs your - dependencies such that if you bundle those dependencies, npm versions - prior to `1.4` can still install them. This eliminates all automatic - deduping. - - Second, `--global-style` which will install modules in your `node_modules` - folder with the same layout as global modules. Only your direct - dependencies will show in `node_modules` and everything they depend on - will be flattened in their `node_modules` folders. This obviously will - eliminate some deduping. - ([@iarna](https://github.com/iarna)) - -#### TYPOS IN THE LICENSE, OH MY - -* [`8d79c1a`](https://github.com/npm/npm/commit/8d79c1a39dae908f27eaa37ff6b23515d505ef29) - [#10478](https://github.com/npm/npm/issues/10478) Correct two typos in npm's - LICENSE. ([@jorrit](https://github.com/jorrit)) - -### v3.4.1 (2015-11-12): - -#### ASK FOR NOTHING, GET LATEST - -When you run `npm install foo`, you probably expect that you'll get the -`latest` version of `foo`, whatever that is. And good news! That's what -this change makes it do. - -We _think_ this is what everyone wants, but if this causes problems for -you, we want to know! If it proves problematic for people we will consider -reverting it (preferably before this becomes `npm@latest`). - -Previously, when you ran `npm install foo` we would act as if you typed -`npm install foo@*`. Now, like any range-type specifier, in addition to -matching the range, it would also have to be `<=` the value of the -`latest` dist-tag. Further, it would exclude prerelease versions from the -list of versions considered for a match. - -This worked as expected most of the time, unless your `latest` was a -prerelease version, in which case that version wouldn't be used, to -everyone's surprise. Worse, if all your versions were prerelease versions -it would just refuse to install anything. (We fixed that in -[`npm@3.2.2`](https://github.com/npm/npm/releases/tag/v3.2.2) with -[`e4a38080`](https://github.com/npm/npm/commit/e4a38080).) - -* [`1e834c2`](https://github.com/npm/npm/commit/1e834c2) - [#10189](https://github.com/npm/npm/issues/10189) - `npm-package-arg@4.1.0` Change the default version from `*` to `latest`. - ([@zkat](https://github.com/zkat)) - -#### BUGS - -* [`bec4a84`](https://github.com/npm/npm/commit/bec4a84) - [#10338](https://github.com/npm/npm/pull/10338) - Failed installs could result in more rollback (removal of just installed - packages) than we intended. This bug was first introduced by - [`83975520`](https://github.com/npm/npm/commit/83975520). - ([@iarna](https://github.com/iarna)) -* [`06c732f`](https://github.com/npm/npm/commit/06c732f) - [#10338](https://github.com/npm/npm/pull/10338) - Updating a module could result in the module stealing some of its - dependencies from the top level, potentially breaking other modules or - resulting in many redundant installations. This bug was first introduced - by [`971fd47a`](https://github.com/npm/npm/commit/971fd47a). - ([@iarna](https://github.com/iarna)) -* [`5653366`](https://github.com/npm/npm/commit/5653366) - [#9980](https://github.com/npm/npm/issues/9980) - npm, when removing a module, would refuse to remove the symlinked - binaries if the module itself was symlinked as well. npm goes to some - effort to ensure that it doesn't remove things that aren't is, and this - code was being too conservative. This code has been rewritten to be - easier to follow and to be unit-testable. - ([@iarna](https://github.com/iarna)) - -#### LICENSE CLARIFICATION - -* [`80acf20`](https://github.com/npm/npm/commit/80acf20) - [#10326](https://github.com/npm/npm/pull/10326) - Update npm's licensing to more completely cover all of the various - things that are npm. - ([@kemitchell](https://github.com/kemitchell)) - -#### CLOSER TO GREEN TRAVIS - -* [`fc12da9`](https://github.com/npm/npm/commit/fc12da9) - [#10232](https://github.com/npm/npm/pull/10232) - `nock@1.9.0` - Downgrade nock to a version that doesn't depend on streams2 in core so - that more of our tests can pass in 0.8. - ([@iarna](https://github.com/iarna)) - -### v3.4.0 (2015-11-05): - -#### A NEW FEATURE - -This was a group effort, with [@isaacs](https://github.com/isaacs) -dropping the implementation in back in August. Then, a few days ago, -[@ashleygwilliams](https://github.com/ashleygwilliams) wrote up docs and -just today [@othiym23](https://github.com/othiym23) wrote a test. - -It's a handy shortcut to update a dependency and then make sure tests -still pass. - -This new command: - -``` -npm install-test x -``` - -is the equivalent of running: - -``` -npm install x && npm test -``` - -* [`1ac3e08`](https://github.com/npm/npm/commit/1ac3e08) - [`bcb04f6`](https://github.com/npm/npm/commit/bcb04f6) - [`b6c17dd`](https://github.com/npm/npm/commit/b6c17dd) - [#9443](https://github.com/npm/npm/pull/9443) - Add `npm install-test` command, alias `npm it`. - ([@isaacs](https://github.com/isaacs), - [@ashleygwilliams](https://github.com/ashleygwilliams), - [@othiym23](https://github.com/othiym23)) - -#### BUG FIXES VIA DEPENDENCY UPDATES - -* [`31c0080`](https://github.com/npm/npm/commit/31c0080) - [#8640](https://github.com/npm/npm/issues/8640) - [npm/normalize-package-data#69](https://github.com/npm/normalize-package-data/pull/69) - `normalize-package-data@2.3.5`: - Fix a bug where if you didn't specify the name of a scoped module's - binary, it would install it such that it was impossible to call it. - ([@iarna](https://github.com/iarna)) -* [`02b37bc`](https://github.com/npm/npm/commit/02b37bc) - [npm/fstream-npm#14](https://github.com/npm/fstream-npm/pull/14) - `fstream-npm@1.0.7`: - Only filter `config.gypi` when it's in the build directory. - ([@mscdex](https://github.com/mscdex)) -* [`accb9d2`](https://github.com/npm/npm/commit/accb9d2) - [npm/fstream-npm#15](https://github.com/npm/fstream-npm/pull/15) - `fstream-npm@1.0.6`: - Stop including directories that happened to have names matching whitelisted - npm files in npm module tarballs. The most common cause was that if you had - a README directory then everything in it would be included if wanted it - or not. - ([@taion](https://github.com/taion)) - -#### DOCUMENTATION FIXES - -* [`7cf6366`](https://github.com/npm/npm/commit/7cf6366) - [#10036](https://github.com/npm/npm/pull/10036) - Fix typo / over-abbreviation. - ([@ifdattic](https://github.com/ifdattic)) -* [`d0ad8f4`](https://github.com/npm/npm/commit/d0ad8f4) - [#10176](https://github.com/npm/npm/pull/10176) - Fix broken link, scopes => scope. - ([@ashleygwilliams](https://github.com/ashleygwilliams)) -* [`d623783`](https://github.com/npm/npm/commit/d623783) - [#9460](https://github.com/npm/npm/issue/9460) - Specifying the default command run by "npm start" and the - fact that you can pass it arguments. - ([@JuanCaicedo](https://github.com/JuanCaicedo)) - -#### DEPENDENCY UPDATES FOR THEIR OWN SAKE - -* [`0a4c29e`](https://github.com/npm/npm/commit/0a4c29e) - [npm/npmlog#19](https://github.com/npm/npmlog/pull/19) - `npmlog@2.0.0`: Make it possible to emit log messages with `error` as the - prefix. - ([@bengl](https://github.com/bengl)) -* [`9463ce9`](https://github.com/npm/npm/commit/9463ce9) - `read-package-json@2.0.2`: - Minor cleanups. - ([@KenanY](https://github.com/KenanY)) - -### v3.3.12 (2015-11-02): - -Hi, a little hot-fix release for a bug introduced in 3.3.11. The ENOENT fix -last week ([`f0e2088`](https://github.com/npm/npm/commit/f0e2088)) broke -upgrades of modules that have bundled dependencies (like `npm`, augh!) - -* [`aedf7cf`](https://github.com/npm/npm/commit/aedf7cf) - [#10192](//github.com/npm/npm/pull/10192) - If a bundled module is going to be replacing a module that's currently on - disk (for instance, when you upgrade a module that includes bundled - dependencies) we want to select the version from the bundle in preference - over the one that was there previously. - ([@iarna](https://github.com/iarna)) - -### v3.3.11 (2015-10-29): - -This is a dependency update week, so that means no PRs from our lovely -users. Look for those next week. As it happens, the dependencies updated -were just devdeps, so nothing for you all to worry about. - -But the bug fixes, oh geez, I tracked down some really long standing stuff -this week!! The headliner is those intermittent `ENOENT` errors that no one -could reproduce consistently? I think they're nailed! But also pretty -important, the bug where `hapi` would install w/ a dep missing? Squashed! - -#### EEEEEEENOENT - -* [`f0e2088`](https://github.com/npm/npm/commit/f0e2088) - [#10026](https://github.com/npm/npm/issues/10026) - Eliminate some, if not many, of the `ENOENT` errors `npm@3` has seen over - the past few months. This was happening when npm would, in its own mind, - correct a bundled dependency, due to a `package.json` specifying an - incompatible version. Then, when npm extracted the bundled version, what - was on disk didn't match its mind and… well, when it tried to act on what - was in its mind, we got an `ENOENT` because it didn't actually exist on - disk. - ([@iarna](https://github.com/iarna)) - -#### PARTIAL SHRINKWRAPS, NO LONGER A BAD DAY - -* [`712fd9c`](https://github.com/npm/npm/commit/712fd9c) - [#10153](https://github.com/npm/npm/pull/10153) - Imagine that you have a module, let's call it `fun-time`, and it depends - on two dependencies, `need-fun@1` and `need-time`. Further, `need-time` - requires `need-fun@2`. So after install the logical tree will look like - this: - - ``` - fun-time - ├── need-fun@1 - └── need-time - └── need-fun@2 - ``` - - Now, the `fun-time` author also distributes a shrinkwrap, but it only includes - the `need-fun@1` in it. - - Resolving dependencies would look something like this: - - 1. Require `need-fun@1`: Use version from shrinkwrap (ignoring version) - 2. Require `need-time`: User version in package.json - 1. Require `need-fun@2`: Use version from shrinkwrap, which oh hey, is - already installed at the top level, so no further action is needed. - - Which results in this tree: - - ``` - fun-time - ├── need-fun@1 - └── need-time - ``` - - We're ignoring the version check on things specified in the shrinkwrap - so that you can override the version that will be installed. This is - because you may want to use a different version than is specified - by your dependencies' dependencies' `package.json` files. - - To fix this, we now only allow overrides of a dependency version when - that dependency is a child (in the tree) of the thing that requires it. - This means that when we're looking for `need-fun@2` we'll see `need-fun@1` - and reject it because, although it's from a shrinkwrap, it's parent is - `fun-time` and the package doing the requiring is `need-time`. - - ([@iarna](https://github.com/iarna)) - -#### STRING `package.bin` AND NON-NPMJS REGISTRIES - -* [`3de1463`](https://github.com/npm/npm/commit/3de1463) - [#9187](https://github.com/npm/npm/issues/9187) - If you were using a module with the `bin` field in your `package.json` set - to a string on a non-npmjs registry then npm would crash, due to the our - expectation that the `bin` field would be an object. We now pass all - `package.json` data through a routine that normalizes the format, - including the `bin` field. (This is the same routine that your - `package.json` is passed through when read off of disk or sent to the - registry for publication.) Doing this also ensures that older modules on - npm's own registry will be treated exactly the same as new ones. (In the - past we weren't always super careful about scrubbing `package.json` data - on publish. And even when we were, those rules have subtly changed over - time.) - ([@iarna](https://github.com/iarna)) - -### v3.3.10 (2015-10-22): - -Hey you all! Welcome to a busy bug fix and PR week. We've got changes -to how `npm install` replaces dependencies during updates, improvements -to shrinkwrap behavior, and all sorts of doc updates. - -In other news, `npm@3` landed in node master in preparation for `node@5` -with [`41923c0`](https://github.com/nodejs/node/commit/41923c0). - -#### UPDATED DEPS NOW MAKE MORE SENSE - -* [`971fd47`](https://github.com/npm/npm/commit/971fd47) - [#9929](https://github.com/npm/npm/pull/9929) - Make the tree more consistent by doing updates in place. This means - that trees after a dependency version update will more often look - the same as after a fresh install. - ([@iarna](https://github.com/iarna)) - -#### SHRINKWRAP + DEV DEPS NOW RESPECTED - -* [`eb28a8c`](https://github.com/npm/npm/commit/eb28a8c) - [#9647](https://github.com/npm/npm/issues/9647) - If a shrinkwrap already has dev deps, don't throw them away when - someone later runs `npm install --save`. - ([@iarna](https://github.com/iarna)) - -#### FANTASTIC DOCUMENTATION UPDATES - -* [`291162c`](https://github.com/npm/npm/commit/291162c) - [#10021](https://github.com/npm/npm/pull/10021) - Improve wording in the FAQ to be more empathetic and less jokey. - ([@TaMe3971](https://github.com/TaMe3971)) -* [`9a28c54`](https://github.com/npm/npm/commit/9a28c54) - [#10020](https://github.com/npm/npm/pull/10020) - Document the command to see the list of config defaults in the section - on config defaults. - ([@lady3bean](https://github.com/lady3bean)) -* [`8770b0a`](https://github.com/npm/npm/commit/8770b0a) - [#7600](https://github.com/npm/npm/issues/7600) - Add shortcuts to all command documentation. - ([@RichardLitt](https://github.com/RichardLitt)) -* [`e9b7d0d`](https://github.com/npm/npm/commit/e9b7d0d) - [#9950](https://github.com/npm/npm/pull/9950) - On errors that can be caused by outdated node & npm, suggest updating - as a part of the error message. - ([@ForbesLindesay](https://github.com/ForbesLindesay)) - -#### NEW STANDARD HAS ALWAYS BEEN STANDARD - -* [`40c1b0f`](https://github.com/npm/npm/commit/40c1b0f) - [#9954](https://github.com/npm/npm/pull/9954) - Update to `standard@5` and reformat the source to work with it. - ([@cbas](https://github.com/cbas)) - -### v3.3.9 (2015-10-15): - -This week sees a few small changes ready to land: - -#### TRAVIS NODE 0.8 BUILDS REJOICE - -* [`25a234b`](https://github.com/npm/npm/commit/25a234b) - [#9668](https://github.com/npm/npm/issues/9668) - Install `npm@3`'s bundled dependencies with `npm@2`, so that the ancient npm - that ships with node 0.8 can install `npm@3` directly. - ([@othiym23](https://github.com/othiym23)) - -#### SMALL ERROR MESSAGE IMPROVEMENT - -* [`a332f61`](https://github.com/npm/npm/commit/a332f61) - [#9927](https://github.com/npm/npm/pull/9927) - Update error messages where we report a list of versions that you could - have installed to show this as a comma separated list instead of as JSON. - ([@iarna](https://github.com/iarna)) - -#### DEPENDENCY UPDATES - -* [`4cd74b0`](https://github.com/npm/npm/commit/4cd74b0) - `nock@2.15.0` - ([@pgte](https://github.com/pgte)) -* [`9360976`](https://github.com/npm/npm/commit/9360976) - `tap@2.1.1` - ([@isaacs](https://github.com/isaacs)) -* [`1ead0a4`](https://github.com/npm/npm/commit/1ead0a4) - `which@1.2.0` - ([@isaacs](https://github.com/isaacs)) -* [`759f88a`](https://github.com/npm/npm/commit/759f88a) - `has-unicode@1.0.1` - ([@iarna](https://github.com/iarna)) - -### v3.3.8 (2015-10-12): - -This is a small update release, we're reverting -[`22a3af0`](https://github.com/npm/npm/commit/22a3af0) from last week's -release, as it is resulting in crashes. We'll revisit this PR during this -week. - -* [`ddde1d5`](https://github.com/npm/npm/commit/ddde1d5) - Revert "lifecycle: Swap out custom logic with add-to-path module" - ([@iarna](https://github.com/iarna)) - -### v3.3.7 (2015-10-08): - -So, as Kat mentioned in last week's 2.x release, we're now swapping weeks -between accepting PRs and doing dependency updates, in an effort to keep -release management work from taking over our lives. This week is a PR week, -so we've got a bunch of goodies for you. - -Relatedly, this week means 3.3.6 is now `latest` and it is WAY faster than -previous 3.x releases. Give it or this a look! - -#### OPTIONAL DEPS, MORE OPTIONAL - -* [`2289234`](https://github.com/npm/npm/commit/2289234) - [#9643](https://github.com/npm/npm/issues/9643) - [#9664](https://github.com/npm/npm/issues/9664) - `npm@3` was triggering `npm@2`'s build mechanics when it was linking bin files - into the tree. This was originally intended to trigger rebuilds of - bundled modules, but `npm@3`'s flat module structure confused it. This - caused two seemingly unrelated issues. First, failing optional - dependencies could under some circumstances (if they were built during - this phase) trigger a full build failure. And second, rebuilds were being - triggered of already installed modules, again, in some circumstances. - Both of these are fixed by disabling the `npm@2` mechanics and adding a - special rebuild phase for the initial installation of bundled modules. - ([@iarna](https://github.com/iarna)) - -#### BAD NAME, NO CRASH - -* [`b78fec9`](https://github.com/npm/npm/commit/b78fec9) - [#9766](https://github.com/npm/npm/issues/9766) - Refactor all attempts to read the module name or package name to go via a - single function, with appropriate guards unusual circumstances where they - aren't where we expect them. This ultimately will ensure we don't see any - more recurrences of the `localeCompare` error and related crashers. - ([@iarna](https://github.com/iarna)) - -#### MISCELLANEOUS BUG FIXES - -* [`22a3af0`](https://github.com/npm/npm/commit/22a3af0) - [#9553](https://github.com/npm/npm/pull/9553) - Factor the lifecycle code to manage paths out into its own module and use that. - ([@kentcdodds](https://github.com/kentcdodds)) -* [`6a29fe3`](https://github.com/npm/npm/commit/6a29fe3) - [#9677](https://github.com/npm/npm/pull/9677) - Start testing our stuff in node 4 on travis - ([@fscherwi](https://github.com/fscherwi)) -* [`508c6a4`](https://github.com/npm/npm/commit/508c6a4) - [#9669](https://github.com/npm/npm/issues/9669) - Make `recalculateMetadata` more resilient to unexpectedly bogus dependency specifiers. - ([@tmct](https://github.com/tmct)) -* [`3c44763`](https://github.com/npm/npm/commit/3c44763) - [#9643](https://github.com/npm/npm/issues/9463) - Update `install --only` to ignore the `NODE_ENV` var and _just_ use the only - value, if specified. - ([@watilde](https://github.com/watilde)) -* [`87336c3`](https://github.com/npm/npm/commit/87336c3) - [#9879](https://github.com/npm/npm/pull/9879) - `npm@3`'s shrinkwrap was refusing to shrinkwrap if an optional dependency - was missing– patch it to allow this. - ([@mantoni](https://github.com/mantoni)) - -#### DOCUMENTATION UPDATES - -* [`82659fd`](https://github.com/npm/npm/commit/82659fd) - [#9208](https://github.com/npm/npm/issues/9208) - Correct the npm style guide around quote usage - ([@aaroncrows](https://github.com/aaroncrows)) -* [`a69c83a`](https://github.com/npm/npm/commit/a69c83a) - [#9645](https://github.com/npm/npm/pull/9645) - Fix spelling error in README - ([@dkoleary88](https://github.com/dkoleary88)) -* [`f2cf054`](https://github.com/npm/npm/commit/f2cf054) - [#9714](https://github.com/npm/npm/pull/9714) - Fix typos in our documentation - ([@reggi](https://github.com/reggi)) -* [`7224bef`](https://github.com/npm/npm/commit/7224bef) - [#9759](https://github.com/npm/npm/pull/9759) - Fix typo in npm-team docs - ([@zkat](https://github.com/zkat)) -* [`7e6e007`](https://github.com/npm/npm/commit/7e6e007) - [#9820](https://github.com/npm/npm/pull/9820) - Correct documentation as to `binding.gyp` - ([@KenanY](https://github.com/KenanY)) - -### v3.3.6 (2015-09-30): - -I have the most exciting news for you this week. YOU HAVE NO IDEA. Well, -ok, maybe you do if you follow my twitter. - -Performance just got 5 bazillion times better (under some circumstances, -ymmv, etc). So– my test scenario is our very own website. In `npm@2`, on my -macbook running `npm ls` takes about 5 seconds. Personally it's more than -I'd like, but it's entire workable. In `npm@3` it has been taking _50_ seconds, -which is appalling. But after doing some work on Monday isolating the performance -issues I've been able to reduce `npm@3`'s run time back down to 5 seconds. - -Other scenarios were even worse, there was one that until now in `npm@3` that -took almost 6 minutes, and has been reduced to 14 seconds. - -* [`7bc0d4c`](https://github.com/npm/npm/commit/7bc0d4c) - [`cf42217`](https://github.com/npm/npm/commit/cf42217) - [#8826](https://github.com/npm/npm/issues/8826) - Stop using deepclone on super big datastructures. Avoid cloning - all-together even when that means mutating things, when possible. - Otherwise use a custom written tree-copying function that understands - the underlying datastructure well enough to only copy what we absolutely - need to. - ([@iarna](https://github.com/iarna)) - -In other news, look for us this Friday and Saturday at the amazing -[Open Source and Feelings](https://osfeels.com) conference, where something like a -third of the company will be attending. - -#### And finally a dependency update - -* [`a6a4437`](https://github.com/npm/npm/commit/a6a4437) - `glob@5.0.15` - ([@isaacs](https://github.com/isaacs)) - -#### And some subdep updates - -* [`cc5e6a0`](https://github.com/npm/npm/commit/cc5e6a0) - `hoek@2.16.3` - ([@nlf](https://github.com/nlf)) -* [`912a516`](https://github.com/npm/npm/commit/912a516) - `boom@2.9.0` - ([@arb](https://github.com/arb)) -* [`63944e9`](https://github.com/npm/npm/commit/63944e9) - `bluebird@2.10.1` - ([@petkaantonov](https://github.com/petkaantonov)) -* [`ef16003`](https://github.com/npm/npm/commit/ef16003) - `mime-types@2.1.7` & `mime-db@1.19.0` - ([@dougwilson](https://github.com/dougwilson)) -* [`2b8c0dd`](https://github.com/npm/npm/commit/2b8c0dd) - `request@2.64.0` - ([@simov](https://github.com/simov)) -* [`8139124`](https://github.com/npm/npm/commit/8139124) - `brace-expansion@1.1.1` - ([@juliangruber](https://github.com/juliangruber)) - -### v3.3.5 (2015-09-24): - -Some of you all may not be aware, but npm is ALSO a company. I tell you this -'cause npm-the-company had an all-staff get together this week, flying in -our remote folks from around the world. That was great, but it also -basically eliminated normal work on Monday and Tuesday. - -Still, we've got a couple of really important bug fixes this week. Plus a -lil bit from the [now LTS 2.x branch](https://github.com/npm/npm/releases/tag/v2.14.6). - -#### ATTENTION WINDOWS USERS - -If you previously updated to npm 3 and you try to update again, you may get -an error messaging telling you that npm won't install npm into itself. Until you -are at 3.3.5 or greater, you can get around this with `npm install -f -g npm`. - -* [`bef06f5`](https://github.com/npm/npm/commit/bef06f5) - [#9741](https://github.com/npm/npm/pull/9741) Uh... so... er... it - seems that since `npm@3.2.0` on Windows with a default configuration, it's - been impossible to update npm. Well, that's not actually true, there's a - work around (see above), but it shouldn't be complaining in the first - place. - ([@iarna](https://github.com/iarna)) - -#### STACK OVERFLOWS ON PUBLISH - -* [`330b496`](https://github.com/npm/npm/commit/330b496) - [#9667](https://github.com/npm/npm/pull/9667) - We were keeping track of metadata about your project while packing the - tree in a way that resulted in this data being written to packed tar files - headers. When this metadata included cycles, it resulted in the the tar - file entering an infinite recursive loop and eventually crashing with a - stack overflow. - - I've patched this by keeping track of your metadata by closing over the - variables in question instead, and I've further restricted gathering and - tracking the metadata to times when it's actually needed. (Which is only - if you need bundled modules.) - ([@iarna](https://github.com/iarna)) - -#### LESS CRASHY ERROR MESSAGES ON BAD PACKAGES - -* [`829921f`](https://github.com/npm/npm/commit/829921f) - [#9741](https://github.com/npm/npm/pull/9741) - Packages with invalid names or versions were crashing the installer. These - are now captured and warned as was originally intended. - ([@iarna](https://github.com/iarna)) - -#### ONE DEPENDENCY UPDATE - -* [`963295c`](https://github.com/npm/npm/commit/963295c) - `npm-install-checks@2.0.1` - ([@iarna](https://github.com/iarna)) - -#### AND ONE SUBDEPENDENCY - -* [`448737d`](https://github.com/npm/npm/commit/448737d) - `request@2.63.0` - ([@simov](https://github.com/simov)) - -### v3.3.4 (2015-09-17): - -This is a relatively quiet release, bringing a few bug fixes and -some module updates, plus via the -[2.14.5 release](https://github.com/npm/npm/releases/tag/v2.14.5) -some forward compatibility fixes with versions of Node that -aren't yet released. - -#### NO BETA NOTICE THIS TIME!! - -But, EXCITING NEWS FRIENDS, this week marks the exit of `npm@3` -from beta. This means that the week of this release, -[v3.3.3](https://github.com/npm/npm/releases/tag/v3.3.3) will -become `latest` and this version (v3.3.4) will become `next`!! - -#### CRUFT FOR THE CRUFT GODS - -What I call "cruft", by which I mean, files sitting around in -your `node_modules` folder, will no longer produce warnings in -`npm ls` nor during `npm install`. This brings `npm@3`'s behavior -in line with `npm@2`. - -* [`a127801`](https://github.com/npm/npm/commit/a127801) - [#9285](https://github.com/npm/npm/pull/9586) - Stop warning about cruft in module directories. - ([@iarna](https://github.com/iarna)) - -#### BETTER ERROR MESSAGE - -* [`95ee92c`](https://github.com/npm/npm/commit/95ee92c) - [#9433](https://github.com/npm/npm/issues/9433) - Give better error messages for invalid URLs in the dependency - list. - ([@jamietre](https://github.com/jamietre)) - -#### MODULE UPDATES - -* [`ebb92ca`](https://github.com/npm/npm/commit/ebb92ca) - `retry@0.8.0` ([@tim-kos](https://github.com/tim-kos)) -* [`55f1285`](https://github.com/npm/npm/commit/55f1285) - `normalize-package-data@2.3.4` ([@zkat](https://github.com/zkat)) -* [`6d4ebff`](https://github.com/npm/npm/commit/6d4ebff) - `sha@2.0.1` ([@ForbesLindesay](https://github.com/ForbesLindesay)) -* [`09a9c7a`](https://github.com/npm/npm/commit/09a9c7a) - `semver@5.0.3` ([@isaacs](https://github.com/isaacs)) -* [`745000f`](https://github.com/npm/npm/commit/745000f) - `node-gyp@3.0.3` ([@rvagg](https://github.com/rvagg)) - -#### SUB DEP MODULE UPDATES - -* [`578ca25`](https://github.com/npm/npm/commit/578ca25) - `request@2.62.0` ([@simov](https://github.com/simov)) -* [`1d8996e`](https://github.com/npm/npm/commit/1d8996e) - `jju@1.2.1` ([@rlidwka](https://github.com/rlidwka)) -* [`6da1ba4`](https://github.com/npm/npm/commit/6da1ba4) - `hoek@2.16.2` ([@nlf](https://github.com/nlf)) - -### v3.3.3 (2015-09-10): - -This short week brought us brings us a few small bug fixes, a -doc change and a whole lotta dependency updates. - -Plus, as usual, this includes a forward port of everything in -[`npm@2.14.4`](https://github.com/npm/npm/releases/tag/v2.14.4). - -#### BETA BUT NOT FOREVER - -**_THIS IS BETA SOFTWARE_**. `npm@3` will remain in beta until -we're confident that it's stable and have assessed the effect of -the breaking changes on the community. During that time we will -still be doing `npm@2` releases, with `npm@2` tagged as `latest` -and `next`. We'll _also_ be publishing new releases of `npm@3` -as `npm@v3.x-next` and `npm@v3.x-latest` alongside those -versions until we're ready to switch everyone over to `npm@3`. -We need your help to find and fix its remaining bugs. It's a -significant rewrite, so we are _sure_ there still significant -bugs remaining. So do us a solid and deploy it in non-critical -CI environments and for day-to-day use, but maybe don't use it -for production maintenance or frontline continuous deployment -just yet. - -#### REMOVE INSTALLED BINARIES ON WINDOWS - -So waaaay back at the start of August, I fixed a bug with -[#9198](https://github.com/npm/npm/pull/9198). That fix made it -so that if you had two modules installed that both installed the -same binary (eg `gulp` & `gulp-cli`), that removing one wouldn't -remove the binary if it was owned by the other. - -It did this by doing some hocus-pocus that, turns out, was -Unix-specific, so on Windows it just threw up its hands and -stopped removing installed binaries at all. Not great. - -So today we're fixing that– it let us maintain the same safety -that we added in #9198, but ALSO works with Windows. - -* [`25fbaed`](https://github.com/npm/npm/commit/25fbaed) - [#9394](https://github.com/npm/npm/issues/9394) - Treat cmd-shims the same way we treat symlinks - ([@iarna](https://github.com/iarna)) - -#### API DOCUMENTATION HAS BEEN SACRIFICED THE API GOD - -The documentation of the internal APIs of npm is going away, -because it would lead people into thinking they should integrate -with npm by using it. Please don't do that! In the future, we'd -like to give you a suite of stand alone modules that provide -better, more stand alone APIs for your applications to build on. -But for now, call the npm binary with `process.exec` or -`process.spawn` instead. - -* [`2fb60bf`](https://github.com/npm/npm/commit/2fb60bf) - Remove misleading API documentation - ([@othiym23](https://github.com/othiym23)) - -#### ALLOW `npm link` ON WINDOWS W/ PRERELEASE VERSIONS OF NODE - -We never meant to have this be a restriction in the first place -and it was only just discovered with the recent node 4.0.0 -release candidate. - -* [`6665e54`](https://github.com/npm/npm/commit/6665e54) - [#9505](https://github.com/npm/npm/pull/9505) - Allow npm link to run on Windows with prerelease versions of - node - ([@jon-hall](https://github.com/jon-hall)) - -#### graceful-fs update - -We're updating all of npm's deps to use the most recent -`graceful-fs`. This turns out to be important for future not yet -released versions of node, because older versions monkey-patch -`fs` in ways that will break in the future. Plus it ALSO makes -use of `process.binding` which is an internal API that npm -definitely shouldn't have been using. We're not done yet, but -this is the bulk of them. - -* [`e7bc98e`](https://github.com/npm/npm/commit/e7bc98e) - `write-file-atomic@1.1.3` - ([@iarna](https://github.com/iarna)) -* [`7417600`](https://github.com/npm/npm/commit/7417600) - `tar@2.2.1` - ([@zkat](https://github.com/zkat)) -* [`e4e9d40`](https://github.com/npm/npm/commit/e4e9d40) - `read-package-json@2.0.1` - ([@zkat](https://github.com/zkat)) -* [`481611d`](https://github.com/npm/npm/commit/481611d) - `read-installed@4.0.3` - ([@zkat](https://github.com/zkat)) -* [`0dabbda`](https://github.com/npm/npm/commit/0dabbda) - `npm-registry-client@7.0.4` - ([@zkat](https://github.com/zkat)) -* [`c075a91`](https://github.com/npm/npm/commit/c075a91) - `fstream@1.0.8` - ([@zkat](https://github.com/zkat)) -* [`2e4341a`](https://github.com/npm/npm/commit/2e4341a) - `fs-write-stream-atomic@1.0.4` - ([@zkat](https://github.com/zkat)) -* [`18ad16e`](https://github.com/npm/npm/commit/18ad16e) - `fs-vacuum@1.2.7` - ([@zkat](https://github.com/zkat)) - -#### DEPENDENCY UPDATES - -* [`9d6666b`](https://github.com/npm/npm/commit/9d6666b) - `node-gyp@3.0.1` - ([@rvagg](https://github.com/rvagg)) -* [`349c4df`](https://github.com/npm/npm/commit/349c4df) - `retry@0.7.0` - ([@tim-kos](https://github.com/tim-kos)) -* [`f507551`](https://github.com/npm/npm/commit/f507551) - `which@1.1.2` - ([@isaacs](https://github.com/isaacs)) -* [`e5b6743`](https://github.com/npm/npm/commit/e5b6743) - `nopt@3.0.4` - ([@zkat](https://github.com/zkat)) - -#### THE DEPENDENCIES OF OUR DEPENDENCIES ARE OUR DEPENDENCIES UPDATES - -* [`316382d`](https://github.com/npm/npm/commit/316382d) - `mime-types@2.1.6` & `mime-db@1.18.0` -* [`64b741e`](https://github.com/npm/npm/commit/64b741e) - `spdx-correct@1.0.1` -* [`fff62ac`](https://github.com/npm/npm/commit/fff62ac) - `process-nextick-args@1.0.3` -* [`9d6488c`](https://github.com/npm/npm/commit/9d6488c) - `cryptiles@2.0.5` -* [`1912012`](https://github.com/npm/npm/commit/1912012) - `bluebird@2.10.0` -* [`4d09402`](https://github.com/npm/npm/commit/4d09402) - `readdir-scoped-modules@1.0.2` - -### v3.3.2 (2015-09-04): - -#### PLEASE HOLD FOR THE NEXT AVAILABLE MAINTAINER - -This is a tiny little maintenance release, both to update dependencies and to -keep `npm@3` up to date with changes made to `npm@2`. -[@othiym23](https://github.com/othiym23) is putting out this release (again) as -his esteemed colleague [@iarna](https://github.com/iarna) finishes relocating -herself, her family, and her sizable anime collection all the way across North -America. It contains [all the goodies in -`npm@2.14.3`](https://github.com/npm/npm/releases/tag/v2.14.3) and one other -dependency update. - -#### BETA WARNINGS FOR FUN AND PROFIT - -**_THIS IS BETA SOFTWARE_**. `npm@3` will remain in beta until we're -confident that it's stable and have assessed the effect of the breaking -changes on the community. During that time we will still be doing `npm@2` -releases, with `npm@2` tagged as `latest` and `next`. We'll _also_ be -publishing new releases of `npm@3` as `npm@v3.x-next` and `npm@v3.x-latest` -alongside those versions until we're ready to switch everyone over to -`npm@3`. We need your help to find and fix its remaining bugs. It's a -significant rewrite, so we are _sure_ there still significant bugs -remaining. So do us a solid and deploy it in non-critical CI environments -and for day-to-day use, but maybe don't use it for production maintenance or -frontline continuous deployment just yet. - -That said, it's getting there! It will be leaving beta very soon! - -#### ONE OTHER DEPENDENCY UPDATE - -* [`bb5de34`](https://github.com/npm/npm/commit/bb5de3493531228df0bd3f0742d5493c826be6dd) - `is-my-json-valid@2.12.2`: Upgrade to a new, modernized version of - `json-pointer`. ([@mafintosh](https://github.com/mafintosh)) - -### v3.3.1 (2015-08-27): - -Hi all, this `npm@3` update brings you another round of bug fixes. The -headliner here is that `npm update` works again. We're running down the -clock on blocker 3.x issues! Shortly after that hits zero we'll be -promoting 3.x to latest!! - -And of course, we have changes that were brought forward from 2.x. Check out -the release notes for -[2.14.1](https://github.com/npm/npm/releases/tag/v2.14.1) and -[2.14.2](https://github.com/npm/npm/releases/tag/v2.14.2). - -#### BETA WARNINGS FOR FUN AND PROFIT - -**_THIS IS BETA SOFTWARE_**. `npm@3` will remain in beta until we're -confident that it's stable and have assessed the effect of the breaking -changes on the community. During that time we will still be doing `npm@2` -releases, with `npm@2` tagged as `latest` and `next`. We'll _also_ be -publishing new releases of `npm@3` as `npm@v3.x-next` and `npm@v3.x-latest` -alongside those versions until we're ready to switch everyone over to -`npm@3`. We need your help to find and fix its remaining bugs. It's a -significant rewrite, so we are _sure_ there still significant bugs -remaining. So do us a solid and deploy it in non-critical CI environments -and for day-to-day use, but maybe don't use it for production maintenance or -frontline continuous deployment just yet. - -#### NPM UPDATE, NOW AGAIN YOUR FRIEND - -* [`f130a00`](https://github.com/npm/npm/commit/f130a00) - [#9095](https://github.com/npm/npm/issues/9095) - `npm update` once again works! Previously, after selecting packages - to update, it would then pick the wrong location to run the install - from. ([@iarna](https://github.com/iarna)) - -#### MORE VERBOSING FOR YOUR VERBOSE LIFECYCLES - -* [`d088b7d`](https://github.com/npm/npm/commit/d088b7d) - [#9227](https://github.com/npm/npm/pull/9227) - Add some additional logging at the verbose and silly levels - when running lifecycle scripts. Hopefully this will make - debugging issues with them a bit easier! - ([@saper](https://github.com/saper)) - -#### AND SOME OTHER BUG FIXES… - -* [`f4a5784`](https://github.com/npm/npm/commit/f4a5784) - [#9308](https://github.com/npm/npm/issues/9308) - Make fetching metadata for local modules faster! This ALSO means - that doing things like running `npm repo` won't build your - module and maybe run `prepublish`. - ([@iarna](https://github.com/iarna)) - -* [`4468c92`](https://github.com/npm/npm/commit/4468c92) - [#9205](https://github.com/npm/npm/issues/9205) - Fix a bug where local modules would sometimes not resolve relative - links using the correct base path. - ([@iarna](https://github.com/iarna)) - -* [`d395a6b`](https://github.com/npm/npm/commit/d395a6b) - [#8995](https://github.com/npm/npm/issues/8995) - Certain combinations of packages could result in different install orders for their - initial installation than for reinstalls run on the same folder. - ([@iarna](https://github.com/iarna)) - -* [`d119ea6`](https://github.com/npm/npm/commit/d119ea6) - [#9113](https://github.com/npm/npm/issues/9113) - Make extraneous packages _always_ up in `npm ls`. Previously, if an - extraneous package had a dependency that depended back on the original - package this would result in the package not showing up in `ls`. - ([@iarna](https://github.com/iarna)) - -* [`02420dc`](https://github.com/npm/npm/commit/02420dc) - [#9113](https://github.com/npm/npm/issues/9113) - Stop warning about missing top level package.json files. Errors in said - files will still be reported. - ([@iarna](https://github.com/iarna)) - -#### SOME DEP UPDATES - -* [`1ed1364`](https://github.com/npm/npm/commit/1ed1364) `rimraf@2.4.3` - ([@isaacs](https://github.com/isaacs)) Added EPERM to delay/retry loop -* [`e7b8315`](https://github.com/npm/npm/commit/e7b8315) `read@1.0.7` - Smaller distribution package, better metadata - ([@isaacs](https://github.com/isaacs)) - -#### SOME DEPS OF DEPS UPDATES - -* [`b273bcc`](https://github.com/npm/npm/commit/b273bcc) `mime-types@2.1.5` -* [`df6e225`](https://github.com/npm/npm/commit/df6e225) `mime-db@1.17.0` -* [`785f2ad`](https://github.com/npm/npm/commit/785f2ad) `is-my-json-valid@2.12.1` -* [`88170dd`](https://github.com/npm/npm/commit/88170dd) `form-data@1.0.0-rc3` -* [`af5357b`](https://github.com/npm/npm/commit/af5357b) `request@2.61.0` -* [`337f96a`](https://github.com/npm/npm/commit/337f96a) `chalk@1.1.1` -* [`3dfd74d`](https://github.com/npm/npm/commit/3dfd74d) `async@1.4.2` - -### v3.3.0 (2015-08-13): - -This is a pretty EXCITING week. But I may be a little excitable– or -possibly sleep deprived, it's sometimes hard to tell them apart. =D So -[Kat](https://github.com/zkat) really went the extra mile this week and got -the client side support for teams and orgs out in this week's 2.x release. -You can't use that just yet, 'cause we have to turn on some server side -stuff too, but this way it'll be there for you all the moment we do! Check -out the details over in the [2.14.0 release -notes](https://github.com/npm/npm/releases/tag/v2.14.0)! - -But we over here in 3.x ALSO got a new feature this week, check out the new -`--only` and `--also` flags for better control over when dev and production -dependencies are used by various npm commands. - -That, and some important bug fixes round out this week. Enjoy everyone! - -#### NEVER SHALL NOT BETA THE BETA - -**_THIS IS BETA SOFTWARE_**. EXCITING NEW BETA WARNING!!! Ok, I fibbed, -EXACTLY THE SAME BETA WARNINGS: `npm@3` will remain in beta until we're -confident that it's stable and have assessed the effect of the breaking -changes on the community. During that time we will still be doing `npm@2` -releases, with `npm@2` tagged as `latest` and `next`. We'll _also_ be -publishing new releases of `npm@3` as `npm@v3.x-next` and `npm@v3.x-latest` -alongside those versions until we're ready to switch everyone over to -`npm@3`. We need your help to find and fix its remaining bugs. It's a -significant rewrite, so we are _sure_ there still significant bugs -remaining. So do us a solid and deploy it in non-critical CI environments -and for day-to-day use, but maybe don't use it for production maintenance or -frontline continuous deployment just yet. - -#### ONLY ALSO DEV - -Hey we've got a SUPER cool new feature for you all, thanks to the fantastic -work of [@davglass](https://github.com/davglass) and -[@bengl](https://github.com/bengl) we have `--only=prod`, -`--only=dev`, `--also=prod` and `--also=dev` options. These apply in -various ways to: `npm install`, `npm ls`, `npm outdated` and `npm update`. - -So for instance: - -``` -npm install --only=dev -``` - -Only installs dev dependencies. By contrast: - -``` -npm install --only=prod -``` - -Will only install prod dependencies and is very similar to `--production` -but differs in that it doesn't set the environment variables that -`--production` does. - -The related new flag, `--also` is most useful with things like: - -``` -npm shrinkwrap --also=dev -``` - -As shrinkwraps don't include dev deps by default. This replaces passing in -`--dev` in that scenario. - -And that leads into the fact that this deprecates `--dev` as its semantics -across commands were inconsistent and confusing. - -* [`3ab1eea`](https://github.com/npm/npm/commit/3ab1eea) - [#9024](https://github.com/npm/npm/pull/9024) - Add support for `--only`, `--also` and deprecate `--dev` - ([@bengl](https://github.com/bengl)) - -#### DON'T TOUCH! THAT'S NOT YOUR BIN - -* [`b31812e`](https://github.com/npm/npm/commit/b31812e) - [#8996](https://github.com/npm/npm/pull/8996) - When removing a module that has bin files, if one that we're going to - remove is a symlink to a DIFFERENT module, leave it alone. This only happens - when you have two modules that try to provide the same bin. - ([@iarna](https://github.com/iarna)) - -#### THERE'S AN END IN SIGHT - -* [`d2178a9`](https://github.com/npm/npm/commit/d2178a9) - [#9223](https://github.com/npm/npm/pull/9223) - Close a bunch of infinite loops that could show up with symlink cycles in your dependencies. - ([@iarna](https://github.com/iarna)) - -#### OOPS DIDN'T MEAN TO FIX THAT - -Well, not _just_ yet. This was scheduled for next week, but it snuck into -2.x this week. - -* [`139dd92`](https://github.com/npm/npm/commit/139dd92) - [#8716](https://github.com/npm/npm/pull/8716) - `npm init` will now only pick up the modules you install, not everything - else that got flattened with them. - ([@iarna](https://github.com/iarna)) - -### v3.2.2 (2015-08-08): - -Lot's of lovely bug fixes for `npm@3`. I'm also suuuuper excited that I -think we have a handle on stack explosions that effect a small portion of -our users. We also have some tantalizing clues as to where some low hanging -fruit may be for performance issues. - -And of course, in addition to the `npm@3` specific bug fixes, there are some -great one's coming in from `npm@2`! [@othiym23](https://github.com/othiym23) -put together that release this week– check out its -[release notes](https://github.com/npm/npm/releases/tag/v2.13.4) for the deets. - -#### AS ALWAYS STILL BETA - -**_THIS IS BETA SOFTWARE_**. Just like the airline safety announcements, -we're not taking this plane off till we finish telling you: `npm@3` will -remain in beta until we're confident that it's stable and have assessed the -effect of the breaking changes on the community. During that time we will -still be doing `npm@2` releases, with `npm@2` tagged as `latest` and `next`. -We'll _also_ be publishing new releases of `npm@3` as `npm@v3.x-next` and -`npm@v3.x-latest` alongside those versions until we're ready to switch -everyone over to `npm@3`. We need your help to find and fix its remaining -bugs. It's a significant rewrite, so we are _sure_ there still significant -bugs remaining. So do us a solid and deploy it in non-critical CI -environments and for day-to-day use, but maybe don't use it for production -maintenance or frontline continuous deployment just yet. - -#### BUG FIXES - -* [`a8c8a13`](https://github.com/npm/npm/commit/a8c8a13) - [#9050](https://github.com/npm/npm/issues/9050) - Resolve peer deps relative to the parent of the requirer - ([@iarna](http://github.com/iarna)) -* [`05f0226`](https://github.com/npm/npm/commit/05f0226) - [#9077](https://github.com/npm/npm/issues/9077) - Fix crash when saving `git+ssh` urls - ([@iarna](http://github.com/iarna)) -* [`e4a3808`](https://github.com/npm/npm/commit/e4a3808) - [#8951](https://github.com/npm/npm/issues/8951) - Extend our patch to allow `*` to match something when a package only has - prerelease versions to everything and not just the cache. - ([@iarna](http://github.com/iarna)) -* [`d135abf`](https://github.com/npm/npm/commit/d135abf) - [#8871](https://github.com/npm/npm/issues/8871) - Don't warn about a missing `package.json` or missing fields in the global - install directory. - ([@iarna](http://github.com/iarna)) - -#### DEP VERSION BUMPS - -* [`990ee4f`](https://github.com/npm/npm/commit/990ee4f) - `path-is-inside@1.0.1` ([@domenic](https://github.com/domenic)) -* [`1f71ec0`](https://github.com/npm/npm/commit/1f71ec0) - `lodash.clonedeep@3.0.2` ([@jdalton](https://github.com/jdalton)) -* [`a091354`](https://github.com/npm/npm/commit/a091354) - `marked@0.3.5` ([@chjj](https://github.com/chjj)) -* [`fc51f28`](https://github.com/npm/npm/commit/fc51f28) - `tap@1.3.2` ([@isaacs](https://github.com/isaacs)) -* [`3569ec0`](https://github.com/npm/npm/commit/3569ec0) - `nock@2.10.0` ([@pgte](https://github.com/pgte)) -* [`ad5f6fd`](https://github.com/npm/npm/commit/ad5f6fd) - `npm-registry-mock@1.0.1` ([@isaacs](https://github.com/isaacs)) - -### v3.2.1 (2015-07-31): - -#### AN EXTRA QUIET RELEASE - -A bunch of stuff got deferred for various reasons, which just means more -branches to land next week! - -Don't forget to check out [Kat's 2.x release](https://github.com/npm/npm/releases/tag/v2.13.4) for other quiet goodies. - -#### AS ALWAYS STILL BETA - -**_THIS IS BETA SOFTWARE_**. Yes, we're still reminding you of this. No, -you can't be excused. `npm@3` will remain in beta until we're confident -that it's stable and have assessed the effect of the breaking changes on the -community. During that time we will still be doing `npm@2` releases, with -`npm@2` tagged as `latest` and `next`. We'll _also_ be publishing new -releases of `npm@3` as `npm@v3.x-next` and `npm@v3.x-latest` alongside those -versions until we're ready to switch everyone over to `npm@3`. We need your -help to find and fix its remaining bugs. It's a significant rewrite, so we -are _sure_ there still significant bugs remaining. So do us a solid and -deploy it in non-critical CI environments and for day-to-day use, but maybe -don't use it for production maintenance or frontline continuous deployment -just yet. - - -#### MAKING OUR TESTS TEST THE THING THEY TEST - -* [`6e53c3d`](https://github.com/npm/npm/commit/6e53c3d) - [#8985](https://github.com/npm/npm/pull/8985) - Many thanks to @bengl for noticing that one of our tests wasn't testing - what it claimed it was testing! ([@bengl](https://github.com/bengl)) - -#### MY PACKAGE.JSON WAS ALREADY IN THE RIGHT ORDER - -* [`eb2c7aa`](https://github.com/npm/npm/commit/d00d0f) - [#9068](https://github.com/npm/npm/pull/9079) - Stop sorting keys in the `package.json` that we haven't edited. Many - thanks to [@Qix-](https://github.com/Qix-) for bringing this up and - providing a first pass at a patch for this. - ([@iarna](https://github.com/iarna)) - -#### DEV DEP UPDATE - -* [`555f60c`](https://github.com/npm/npm/commit/555f60c) `marked@0.3.4` - -### v3.2.0 (2015-07-24): - -#### MORE CONFIG, BETTER WINDOWS AND A BUG FIX - -This is a smallish release with a new config option and some bug fixes. And -lots of module updates. - -#### BETA BETAS ON - -**_THIS IS BETA SOFTWARE_**. Yes, we're still reminding you of this. No, -you can't be excused. `npm@3` will remain in beta until we're confident -that it's stable and have assessed the effect of the breaking changes on the -community. During that time we will still be doing `npm@2` releases, with -`npm@2` tagged as `latest` and `next`. We'll _also_ be publishing new -releases of `npm@3` as `npm@v3.x-next` and `npm@v3.x-latest` alongside those -versions until we're ready to switch everyone over to `npm@3`. We need your -help to find and fix its remaining bugs. It's a significant rewrite, so we -are _sure_ there still significant bugs remaining. So do us a solid and -deploy it in non-critical CI environments and for day-to-day use, but maybe -don't use it for production maintenance or frontline continuous deployment -just yet. - - -#### NEW CONFIGS, LESS PROGRESS - -* [`423d8f7`](https://github.com/npm/npm/commit/423d8f7) - [#8704](https://github.com/npm/npm/issues/8704) - Add the ability to disable the new progress bar with `--no-progress` - ([@iarna](https://github.com/iarna)) - -#### AND BUG FIXES - -* [`b3ee452`](https://github.com/npm/npm/commit/b3ee452) - [#9038](https://github.com/npm/npm/pull/9038) - We previously disabled the use of the new `fs.access` API on Windows, but - the bug we were seeing is fixed in `io.js@1.5.0` so we now use `fs.access` - if you're using that version or greater. - ([@iarna](https://github.com/iarna)) - -* [`b181fa3`](https://github.com/npm/npm/commit/b181fa3) - [#8921](https://github.com/npm/npm/issues/8921) - [#8637](https://github.com/npm/npm/issues/8637) - Rejigger how we validate modules for install. This allow is to fix - a problem where arch/os checking wasn't being done at all. - It also made it easy to add back in a check that declines to - install a module in itself unless you force it. - ([@iarna](https://github.com/iarna)) - -#### AND A WHOLE BUNCH OF SUBDEP VERSIONS - -These are all development dependencies and semver-compatible subdep -upgrades, so they should not have visible impact on users. - -* [`6b3f6d9`](https://github.com/npm/npm/commit/6b3f6d9) `standard@4.3.3` -* [`f4e22e5`](https://github.com/npm/npm/commit/f4e22e5) `readable-stream@2.0.2` (inside concat-stream) -* [`f130bfc`](https://github.com/npm/npm/commit/f130bfc) `minimatch@2.0.10` (inside node-gyp's copy of glob) -* [`36c6a0d`](https://github.com/npm/npm/commit/36c6a0d) `caseless@0.11.0` -* [`80df59c`](https://github.com/npm/npm/commit/80df59c) `chalk@1.1.0` -* [`ea935d9`](https://github.com/npm/npm/commit/ea935d9) `bluebird@2.9.34` -* [`3588a0c`](https://github.com/npm/npm/commit/3588a0c) `extend@3.0.0` -* [`c6a8450`](https://github.com/npm/npm/commit/c6a8450) `form-data@1.0.0-rc2` -* [`a04925b`](https://github.com/npm/npm/commit/a04925b) `har-validator@1.8.0` -* [`ee7c095`](https://github.com/npm/npm/commit/ee7c095) `has-ansi@2.0.0` -* [`944fc34`](https://github.com/npm/npm/commit/944fc34) `hawk@3.1.0` -* [`783dc7b`](https://github.com/npm/npm/commit/783dc7b) `lodash._basecallback@3.3.1` -* [`acef0fe`](https://github.com/npm/npm/commit/acef0fe) `lodash._baseclone@3.3.0` -* [`dfe959a`](https://github.com/npm/npm/commit/dfe959a) `lodash._basedifference@3.0.3` -* [`a03bc76`](https://github.com/npm/npm/commit/a03bc76) `lodash._baseflatten@3.1.4` -* [`8a07d50`](https://github.com/npm/npm/commit/8a07d50) `lodash._basetostring@3.0.1` -* [`7785e3f`](https://github.com/npm/npm/commit/7785e3f) `lodash._baseuniq@3.0.3` -* [`826fb35`](https://github.com/npm/npm/commit/826fb35) `lodash._createcache@3.1.2` -* [`76030b3`](https://github.com/npm/npm/commit/76030b3) `lodash._createpadding@3.6.1` -* [`1a49ec6`](https://github.com/npm/npm/commit/1a49ec6) `lodash._getnative@3.9.1` -* [`eebe47f`](https://github.com/npm/npm/commit/eebe47f) `lodash.isarguments@3.0.4` -* [`09994d4`](https://github.com/npm/npm/commit/09994d4) `lodash.isarray@3.0.4` -* [`b6f8dbf`](https://github.com/npm/npm/commit/b6f8dbf) `lodash.keys@3.1.2` -* [`c67dd6b`](https://github.com/npm/npm/commit/c67dd6b) `lodash.pad@3.1.1` -* [`4add042`](https://github.com/npm/npm/commit/4add042) `lodash.repeat@3.0.1` -* [`e04993c`](https://github.com/npm/npm/commit/e04993c) `lru-cache@2.6.5` -* [`2ed7da4`](https://github.com/npm/npm/commit/2ed7da4) `mime-db@1.15.0` -* [`ae08244`](https://github.com/npm/npm/commit/ae08244) `mime-types@2.1.3` -* [`e71410e`](https://github.com/npm/npm/commit/e71410e) `os-homedir@1.0.1` -* [`67c13e0`](https://github.com/npm/npm/commit/67c13e0) `process-nextick-args@1.0.2` -* [`12ee041`](https://github.com/npm/npm/commit/12ee041) `qs@4.0.0` -* [`15564a6`](https://github.com/npm/npm/commit/15564a6) `spdx-license-ids@1.0.2` -* [`8733bff`](https://github.com/npm/npm/commit/8733bff) `supports-color@2.0.0` -* [`230943c`](https://github.com/npm/npm/commit/230943c) `tunnel-agent@0.4.1` -* [`26a4653`](https://github.com/npm/npm/commit/26a4653) `ansi-styles@2.1.0` -* [`3d27081`](https://github.com/npm/npm/commit/3d27081) `bl@1.0.0` -* [`9efa110`](https://github.com/npm/npm/commit/9efa110) `async@1.4.0` - -#### MERGED FORWARD - -* As usual, we've ported all the `npm@2` goodies in this week's - [v2.13.3](https://github.com/npm/npm/releases/tag/v2.13.3) - release. - -### v3.1.3 (2015-07-17): - -Rebecca: So Kat, I hear this week's other release uses a dialog between us to -explain what changed? - -Kat: Well, you could say that… - -Rebecca: I would! This week I fixed more `npm@3` bugs! - -Kat: That sounds familiar. - -Rebecca: Eheheheh, well, before we look at those, a word from our sponsor… - -#### BETA IS AS BETA DOES - -**_THIS IS BETA SOFTWARE_**. Yes, we're still reminding you of this. No, -you can't be excused. `npm@3` will remain in beta until we're confident -that it's stable and have assessed the effect of the breaking changes on the -community. During that time we will still be doing `npm@2` releases, with -`npm@2` tagged as `latest` and `next`. We'll _also_ be publishing new -releases of `npm@3` as `npm@v3.x-next` and `npm@v3.x-latest` alongside those -versions until we're ready to switch everyone over to `npm@3`. We need your -help to find and fix its remaining bugs. It's a significant rewrite, so we -are _sure_ there still significant bugs remaining. So do us a solid and -deploy it in non-critical CI environments and for day-to-day use, but maybe -don't use it for production maintenance or frontline continuous deployment -just yet. - -Rebecca: Ok, enough of the dialoguing, that's Kat's schtick. But do remember -kids, betas hide in dark hallways waiting to break your stuff, stuff like… - -#### SO MANY LINKS YOU COULD MAKE A CHAIN - -* [`6d69ec9`](https://github.com/npm/npm/6d69ec9) - [#8967](https://github.com/npm/npm/issues/8967) - Removing a module linked into your globals would result in having - all of its subdeps removed. Since the npm release process does - exactly this, it burned me -every- -single- -week-. =D - While we're here, we also removed extraneous warns that used to - spill out when you'd remove a symlink. - ([@iarna](https://github.com/iarna)) - -* [`fdb360f`](https://github.com/npm/npm/fdb360f) - [#8874](https://github.com/npm/npm/issues/8874) - Linking scoped modules was failing outright, but this fixes that - and updates our tests so we don't do it again. - ([@iarna](https://github.com/iarna)) - -#### WE'LL TRY NOT TO CRACK YOUR WINDOWS - -* [`9fafb18`](https://github.com/npm/npm/9fafb18) - [#8701](https://github.com/npm/npm/issues/8701) - `npm@3` introduced permissions checks that run before it actually tries to - do something. This saves you from having an install fail half way - through. We did this using the shiny new `fs.access` function available - in `node 0.12` and `io.js`, with fallback options for older nodes. Unfortunately - the way we implemented the fallback caused racey problems for Windows systems. - This fixes that by ensuring we only ever run any one check on a directory once. - BUT it turns out there are bugs in `fs.access` on Windows. So this ALSO just disables - the use of `fs.access` on Windows entirely until that settles out. - ([@iarna](https://github.com/iarna)) - -#### ZOOM ZOOM, DEP UPDATES - -* [`5656baa`](https://github.com/npm/npm/5656baa) - `gauge@1.2.2`: Better handle terminal resizes while printing the progress bar - ([@iarna](https://github.com/iarna)) - -#### MERGED FORWARD - -* Check out Kat's [super-fresh release notes for v2.13.2](https://github.com/npm/npm/releases/tag/v2.13.2) - and see all the changes we ported from `npm@2`. - -### v3.1.2 - -#### SO VERY BETA RELEASE - -So, `v3.1.1` managed to actually break installing local modules. And then -immediately after I drove to an island for the weekend. 😁 So let's get -this fixed outside the usual release train! - -Fortunately it didn't break installing _global_ modules and so you could -swap it out for another version at least. - -#### DISCLAIMER MEANS WHAT IT SAYS - -**_THIS IS BETA SOFTWARE_**. Yes, we're still reminding you of this. No, -you can't be excused. `npm@3` will remain in beta until we're confident -that it's stable and have assessed the effect of the breaking changes on the -community. During that time we will still be doing `npm@2` releases, with -`npm@2` tagged as `latest` and `next`. We'll _also_ be publishing new -releases of `npm@3` as `npm@v3.x-next` and `npm@v3.x-latest` alongside those -versions until we're ready to switch everyone over to `npm@3`. We need your -help to find and fix its remaining bugs. It's a significant rewrite, so we -are _sure_ there still significant bugs remaining. So do us a solid and -deploy it in non-critical CI environments and for day-to-day use, but maybe -don't use it for production maintenance or frontline continuous deployment -just yet. - -#### THIS IS IT, THE REASON - -* [`f5e19df`](https://github.com/npm/npm/commit/f5e19df) - [#8893](https://github.com/npm/npm/issues/8893) - Fix crash when installing local modules introduced by the fix for - [#8608](https://github.com/npm/npm/issues/8608) - ([@iarna](https://github.com/iarna) - -### v3.1.1 - -#### RED EYE RELEASE - -Rebecca's up too late writing tests, so you can have `npm@3` bug fixes! Lots -of great new issues from you all! ❤️️ Keep it up! - -#### YUP STILL BETA, PLEASE PAY ATTENTION - -**_THIS IS BETA SOFTWARE_**. Yes, we're still reminding you of this. No, -you can't be excused. `npm@3` will remain in beta until we're confident -that it's stable and have assessed the effect of the breaking changes on the -community. During that time we will still be doing `npm@2` releases, with -`npm@2` tagged as `latest` and `next`. We'll _also_ be publishing new -releases of `npm@3` as `npm@v3.x-next` and `npm@v3.x-latest` alongside those -versions until we're ready to switch everyone over to `npm@3`. We need your -help to find and fix its remaining bugs. It's a significant rewrite, so we -are _sure_ there still significant bugs remaining. So do us a solid and -deploy it in non-critical CI environments and for day-to-day use, but maybe -don't use it for production maintenance or frontline continuous deployment -just yet. - -#### BOOGS - -* [`9badfd6`](https://github.com/npm/npm/commit/9babfd63f19f2d80b2d2624e0963b0bdb0d76ef4) - [#8608](https://github.com/npm/npm/issues/8608) - Make global installs and uninstalls MUCH faster by only reading the directories of - modules referred to by arguments. - ([@iarna](https://github.com/iarna) -* [`075a5f0`](https://github.com/npm/npm/commit/075a5f046ab6837f489b08d44cb601e9fdb369b7) - [#8660](https://github.com/npm/npm/issues/8660) - Failed optional deps would still result in the optional deps own - dependencies being installed. We now find them and fail them out of the - tree. - ([@iarna](https://github.com/iarna) -* [`c9fbbb5`](https://github.com/npm/npm/commit/c9fbbb540083396ea58fd179d81131d959d8e049) - [#8863](https://github.com/npm/npm/issues/8863) - The "no compatible version found" error message was including only the - version requested, not the name of the package we wanted. Ooops! - ([@iarna](https://github.com/iarna) -* [`32e6bbd`](https://github.com/npm/npm/commit/32e6bbd21744dcbe8c0720ab53f60caa7f2a0588) - [#8806](https://github.com/npm/npm/issues/8806) - The "uninstall" lifecycle was being run after all of a module's dependencies has been - removed. This reverses that order-- this means "uninstall" lifecycles can make use - of the package's dependencies. - ([@iarna](https://github.com/iarna) - -#### MERGED FORWARD - -* Check out the [v2.13.1 release notes](https://github.com/npm/npm/releases/tag/v2.13.1) - and see all the changes we ported from `npm@2`. - -### v3.1.0 (2015-07-02): - -This has been a brief week of bug fixes, plus some fun stuff merged forward -from this weeks 2.x release. See the -[2.13.0 release notes](https://github.com/npm/npm/releases/tag/v2.13.0) -for details on that. - -You all have been AWESOME with -[all](https://github.com/npm/npm/milestones/3.x) -[the](https://github.com/npm/npm/milestones/3.2.0) -`npm@3` bug reports! Thank you and keep up the great work! - -#### NEW PLACE, SAME CODE - -Remember how last week we said `npm@3` would go to `3.0-next` and latest -tags? Yeaaah, no, please use `npm@v3.x-next` and `npm@v3.x-latest` going forward. - -I dunno why we said "suuure, we'll never do a feature release till we're out -of beta" when we're still forward porting `npm@2.x` features. `¯\_(ツ)_/¯` - -If you do accidentally use the old tag names, I'll be maintaining them -for a few releases, but they won't be around forever. - -#### YUP STILL BETA, PLEASE PAY ATTENTION - -**_THIS IS BETA SOFTWARE_**. `npm@3` will remain in beta until we're -confident that it's stable and have assessed the effect of the breaking -changes on the community. During that time we will still be doing `npm@2` -releases, with `npm@2` tagged as `latest` and `next`. We'll _also_ be -publishing new releases of `npm@3` as `npm@v3.x-next` and `npm@v3.x-latest` -alongside those versions until we're ready to switch everyone over to -`npm@3`. We need your help to find and fix its remaining bugs. It's a -significant rewrite, so we are _sure_ there still significant bugs -remaining. So do us a solid and deploy it in non-critical CI environments -and for day-to-day use, but maybe don't use it for production maintenance -or frontline continuous deployment just yet. - -#### BUGS ON THE WINDOWS - - * [`0030ade`](https://github.com/npm/npm/commit/0030ade) - [#8685](https://github.com/npm/npm/issues/8685) - Windows would hang when trying to clone git repos - ([@euprogramador](https://github.com/npm/npm/pull/8777)) - * [`b259bcc`](https://github.com/npm/npm/commit/b259bcc) - [#8786](https://github.com/npm/npm/pull/8786) - Windows permissions checks would cause installations to fail under some - circumstances. We're disabling the checks entirely for this release. - I'm hoping to check back with this next week to get a Windows friendly - fix in. - ([@iarna](https://github.com/iarna)) - -#### SO MANY BUGS SQUASHED, JUST CALL US RAID - - * [`0848698`](https://github.com/npm/npm/commit/0848698) - [#8686](https://github.com/npm/npm/pull/8686) - Stop leaving progress bar cruft on the screen during publication - ([@ajcrites](https://github.com/ajcrites)) - * [`57c3cea`](https://github.com/npm/npm/commit/57c3cea) - [#8695](https://github.com/npm/npm/pull/8695) - Remote packages with shrinkwraps made npm cause node + iojs to explode - and catch fire. NO MORE. - ([@iarna](https://github.com/iarna)) - * [`2875ba3`](https://github.com/npm/npm/commit/2875ba3) - [#8723](https://github.com/npm/npm/pull/8723) - I uh, told you that engineStrict checking had gone away last week. - TURNS OUT I LIED. So this is making that actually be true. - ([@iarna](https://github.com/iarna)) - * [`28064e5`](https://github.com/npm/npm/commit/28064e5) - [#3358](https://github.com/npm/npm/issues/3358) - Consistently allow Unicode BOMs at the start of package.json files. - Previously this was allowed some of time, like when you were installing - modules, but not others, like running npm version or installing w/ - `--save`. - ([@iarna](https://github.com/iarna)) - * [`3cb6ad2`](https://github.com/npm/npm/commit/3cb6ad2) - [#8736](https://github.com/npm/npm/issues/8766) - `npm@3` wasn't running the "install" lifecycle in your current (toplevel) - module. This broke modules that relied on C compilation. BOO. - ([@iarna](https://github.com/iarna)) - * [`68da583`](https://github.com/npm/npm/commit/68da583) - [#8766](https://github.com/npm/npm/issues/8766) - To my great shame, `npm link package` wasn't working AT ALL if you - didn't have `package` already installed. - ([@iarna](https://github.com/iarna)) - * [`edd7448`](https://github.com/npm/npm/commit/edd7448) - `read-package-tree@5.0.0`: This update makes read-package-tree not explode - when there's bad data in your node_modules folder. `npm@2` silently - ignores this sort of thing. - ([@iarna](https://github.com/iarna)) - * [`0bb08c8`](https://github.com/npm/npm/commit/0bb08c8) - [#8778](https://github.com/npm/npm/pull/8778) - RELATEDLY, we now show any errors from your node_modules folder after - your installation completes as warnings. We're also reporting these in - `npm ls` now. - ([@iarna](https://github.com/iarna)) - * [`6c248ff`](https://github.com/npm/npm/commit/6c248ff) - [#8779](https://github.com/npm/npm/pull/8779) - Hey, you know how we used to complain if your `package.json` was - missing stuff? Well guess what, we are again. I know, I know, you can - thank me later. - ([@iarna](https://github.com/iarna)) - * [`d6f7c98`](https://github.com/npm/npm/commit/d6f7c98) - So, when we were rolling back after errors we had untested code that - tried to undo moves. Being untested it turns out it was very broken. - I've removed it until we have time to do this right. - ([@iarna](https://github.com/iarna)) - -#### NEW VERSION - -Just the one. Others came in via the 2.x release. Do check out its -changelog, immediately following this message. - - * [`4e602c5`](https://github.com/npm/npm/commit/4e602c5) `lodash@3.2.2` - -### v3.0.0 (2015-06-25): - -Wow, it's finally here! This has been a long time coming. We are all -delighted and proud to be getting this out into the world, and are looking -forward to working with the npm user community to get it production-ready -as quickly as possible. - -`npm@3` constitutes a nearly complete rewrite of npm's installer to be -easier to maintain, and to bring a bunch of valuable new features and -design improvements to you all. - -[@othiym23](https://github.com/othiym23) and -[@isaacs](https://github.com/isaacs) have been -[talking about the changes](http://blog.npmjs.org/post/91303926460/npm-cli-roadmap-a-periodic-update) -in this release for well over a year, and it's been the primary focus of -[@iarna](https://github.com/iarna) since she joined the team. - -Given that this is a near-total rewrite, all changes listed here are -[@iarna](https://github.com/iarna)'s work unless otherwise specified. - -#### NO, REALLY, READ THIS PARAGRAPH. IT'S THE IMPORTANT ONE. - -**_THIS IS BETA SOFTWARE_**. `npm@3` will remain in beta until we're -confident that it's stable and have assessed the effect of the breaking -changes on the community. During that time we will still be doing `npm@2` -releases, with `npm@2` tagged as `latest` and `next`. We'll _also_ be -publishing new releases of `npm@3` as `npm@3.0-next` and `npm@3.0-latest` -alongside those versions until we're ready to switch everyone over to -`npm@3`. We need your help to find and fix its remaining bugs. It's a -significant rewrite, so we are _sure_ there still significant bugs -remaining. So do us a solid and deploy it in non-critical CI environments -and for day-to-day use, but maybe don't use it for production maintenance -or frontline continuous deployment just yet. - -#### BREAKING CHANGES - -##### `peerDependencies` - -`grunt`, `gulp`, and `broccoli` plugin maintainers take note! You will be -affected by this change! - -* [#6930](https://github.com/npm/npm/issues/6930) - ([#6565](https://github.com/npm/npm/issues/6565)) - `peerDependencies` no longer cause _anything_ to be implicitly installed. - Instead, npm will now warn if a packages `peerDependencies` are missing, - but it's up to the consumer of the module (i.e. you) to ensure the peers - get installed / are included in `package.json` as direct `dependencies` - or `devDependencies` of your package. -* [#3803](https://github.com/npm/npm/issues/3803) - npm also no longer checks `peerDependencies` until after it has fully - resolved the tree. - -This shifts the responsibility for fulfilling peer dependencies from library -/ framework / plugin maintainers to application authors, and is intended to -get users out of the dependency hell caused by conflicting `peerDependency` -constraints. npm's job is to keep you _out_ of dependency hell, not put you -in it. - -##### `engineStrict` - -* [#6931](https://github.com/npm/npm/issues/6931) The rarely-used - `package.json` option `engineStrict` has been deprecated for several - months, producing warnings when it was used. Starting with `npm@3`, the - value of the field is ignored, and engine violations will only produce - warnings. If you, as a user, want strict `engines` field enforcement, - just run `npm config set engine-strict true`. - -As with the peer dependencies change, this is about shifting control from -module authors to application authors. It turns out `engineStrict` was very -difficult to understand even harder to use correctly, and more often than -not just made modules using it difficult to deploy. - -##### `npm view` - -* [`77f1aec`](https://github.com/npm/npm/commit/77f1aec) With `npm view` (aka - `npm info`), always return arrays for versions, maintainers, etc. Previously - npm would return a plain value if there was only one, and multiple values if - there were more. ([@KenanY](https://github.com/KenanY)) - -#### KNOWN BUGS - -Again, this is a _**BETA RELEASE**_, so not everything is working just yet. -Here are the issues that we already know about. If you run into something -that isn't on this list, -[let us know](https://github.com/npm/npm/issues/new)! - -* [#8575](https://github.com/npm/npm/issues/8575) - Circular deps will never be removed by the prune-on-uninstall code. -* [#8588](https://github.com/npm/npm/issues/8588) - Local deps where the dep name and the name in the package.json differ - don't result in an error. -* [#8637](https://github.com/npm/npm/issues/8637) - Modules can install themselves as direct dependencies. `npm@2` declined to - do this. -* [#8660](https://github.com/npm/npm/issues/8660) - Dependencies of failed optional dependencies aren't rolled back when the - optional dependency is, and then are reported as extraneous thereafter. - -#### NEW FEATURES - -##### The multi-stage installer! - -* [#5919](https://github.com/npm/npm/issues/5919) - Previously the installer had a set of steps it executed for each package - and it would immediately start executing them as soon as it decided to - act on a package. - - But now it executes each of those steps at the same time for all - packages, waiting for all of one stage to complete before moving on. This - eliminates many race conditions and makes the code easier to reason - about. - -This fixes, for instance: - -* [#6926](https://github.com/npm/npm/issues/6926) - ([#5001](https://github.com/npm/npm/issues/5001), - [#6170](https://github.com/npm/npm/issues/6170)) - `install` and `postinstall` lifecycle scripts now only execute `after` - all the module with the script's dependencies are installed. - -##### Install: it looks different! - -You'll now get a tree much like the one produced by `npm ls` that -highlights in orange the packages that were installed. Similarly, any -removed packages will have their names prefixed by a `-`. - -Also, `npm outdated` used to include the name of the module in the -`Location` field: - -``` -Package Current Wanted Latest Location -deep-equal MISSING 1.0.0 1.0.0 deep-equal -glob 4.5.3 4.5.3 5.0.10 rimraf > glob -``` - -Now it shows the module that required it as the final point in the -`Location` field: - -``` -Package Current Wanted Latest Location -deep-equal MISSING 1.0.0 1.0.0 npm -glob 4.5.3 4.5.3 5.0.10 npm > rimraf -``` - -Previously the `Location` field was telling you where the module was on -disk. Now it tells you what requires the module. When more than one thing -requires the module you'll see it listed once for each thing requiring it. - -##### Install: it works different! - -* [#6928](https://github.com/npm/npm/issues/6928) - ([#2931](https://github.com/npm/npm/issues/2931) - [#2950](https://github.com/npm/npm/issues/2950)) - `npm install` when you have an `npm-shrinkwrap.json` will ensure you have - the modules specified in it are installed in exactly the shape specified - no matter what you had when you started. -* [#6913](https://github.com/npm/npm/issues/6913) - ([#1341](https://github.com/npm/npm/issues/1341) - [#3124](https://github.com/npm/npm/issues/3124) - [#4956](https://github.com/npm/npm/issues/4956) - [#6349](https://github.com/npm/npm/issues/6349) - [#5465](https://github.com/npm/npm/issues/5465)) - `npm install` when some of your dependencies are missing sub-dependencies - will result in those sub-dependencies being installed. That is, `npm - install` now knows how to fix broken installs, most of the time. -* [#5465](https://github.com/npm/npm/issues/5465) - If you directly `npm install` a module that's already a subdep of - something else and your new version is incompatible, it will now install - the previous version nested in the things that need it. -* [`a2b50cf`](https://github.com/npm/npm/commit/a2b50cf) - [#5693](https://github.com/npm/npm/issues/5693) - When installing a new module, if it's mentioned in your - `npm-shrinkwrap.json` or your `package.json` use the version specifier - from there if you didn't specify one yourself. - -##### Flat, flat, flat! - -Your dependencies will now be installed *maximally flat*. Insofar as is -possible, all of your dependencies, and their dependencies, and THEIR -dependencies will be installed in your project's `node_modules` folder with no -nesting. You'll only see modules nested underneath one another when two (or -more) modules have conflicting dependencies. - -* [#3697](https://github.com/npm/npm/issues/3697) - This will hopefully eliminate most cases where Windows users ended up - with paths that were too long for Explorer and other standard tools to - deal with. -* [#6912](https://github.com/npm/npm/issues/6912) - ([#4761](https://github.com/npm/npm/issues/4761) - [#4037](https://github.com/npm/npm/issues/4037)) - This also means that your installs will be deduped from the start. -* [#5827](https://github.com/npm/npm/issues/5827) - This deduping even extends to git deps. -* [#6936](https://github.com/npm/npm/issues/6936) - ([#5698](https://github.com/npm/npm/issues/5698)) - Various commands are dedupe aware now. - -This has some implications for the behavior of other commands: - -* `npm uninstall` removes any dependencies of the module that you specified - that aren't required by any other module. Previously, it would only - remove those that happened to be installed under it, resulting in left - over cruft if you'd ever deduped. -* `npm ls` now shows you your dependency tree organized around what - requires what, rather than where those modules are on disk. -* [#6937](https://github.com/npm/npm/issues/6937) - `npm dedupe` now flattens the tree in addition to deduping. - -And bundling of dependencies when packing or publishing changes too: - -* [#2442](https://github.com/npm/npm/issues/2442) - bundledDependencies no longer requires that you specify deduped sub deps. - npm can now see that a dependency is required by something bundled and - automatically include it. To put that another way, bundledDependencies - should ONLY include things that you included in dependencies, - optionalDependencies or devDependencies. -* [#5437](https://github.com/npm/npm/issues/5437) - When bundling a dependency that's both a `devDependency` and the child of - a regular `dependency`, npm bundles the child dependency. - -As a demonstration of our confidence in our own work, npm's own -dependencies are now flattened, deduped, and bundled in the `npm@3` style. -This means that `npm@3` can't be packed or published by `npm@2`, which is -something to be aware of if you're hacking on npm. - -##### Shrinkwraps: they are a-changin'! - -First of all, they should be idempotent now -([#5779](https://github.com/npm/npm/issues/5779)). No more differences -because the first time you install (without `npm-shrinkwrap.json`) and the -second time (with `npm-shrinkwrap.json`). - -* [#6781](https://github.com/npm/npm/issues/6781) - Second, if you save your changes to `package.json` and you have - `npm-shrinkwrap.json`, then it will be updated as well. This applies to - all of the commands that update your tree: - * `npm install --save` - * `npm update --save` - * `npm dedupe --save` ([#6410](https://github.com/npm/npm/issues/6410)) - * `npm uninstall --save` -* [#4944](https://github.com/npm/npm/issues/4944) - ([#5161](https://github.com/npm/npm/issues/5161) - [#5448](https://github.com/npm/npm/issues/5448)) - Third, because `node_modules` folders are now deduped and flat, - shrinkwrap has to also be smart enough to handle this. - -And finally, enjoy this shrinkwrap bug fix: - -* [#3675](https://github.com/npm/npm/issues/3675) - When shrinkwrapping a dependency that's both a `devDependency` and the - child of a regular `dependency`, npm now correctly includes the child. - -##### The Age of Progress (Bars)! - -* [#6911](https://github.com/npm/npm/issues/6911) - ([#1257](https://github.com/npm/npm/issues/1257) - [#5340](https://github.com/npm/npm/issues/5340) - [#6420](https://github.com/npm/npm/issues/6420)) - The spinner is gone (yay? boo? will you miss it?), and in its place npm - has _progress bars_, so you actually have some sense of how long installs - will take. It's provided in Unicode and non-Unicode variants, and Unicode - support is automatically detected from your environment. - -#### TINY JEWELS - -The bottom is where we usually hide the less interesting bits of each -release, but each of these are small but incredibly useful bits of this -release, and very much worth checking out: - -* [`9ebe312`](https://github.com/npm/npm/commit/9ebe312) - Build system maintainers, rejoice: npm does a better job of cleaning up - after itself in your temporary folder. -* [#6942](https://github.com/npm/npm/issues/6942) - Check for permissions issues prior to actually trying to install - anything. -* Emit warnings at the end of the installation when possible, so that - they'll be on your screen when npm stops. -* [#3505](https://github.com/npm/npm/issues/3505) - `npm --dry-run`: You can now ask that npm only report what it _would have - done_ with the new `--dry-run` flag. This can be passed to any of the - commands that change your `node_modules` folder: `install`, `uninstall`, - `update` and `dedupe`. -* [`81b46fb`](https://github.com/npm/npm/commit/81b46fb) - npm now knows the correct URLs for `npm bugs` and `npm repo` for - repositories hosted on Bitbucket and GitLab, just like it does for GitHub - (and GitHub support now extends to projects hosted as gists as well as - traditional repositories). -* [`5be4008a`](https://github.com/npm/npm/commit/5be4008a09730cfa3891d9f145e4ec7f2accd144) - npm has been cleaned up to pass the [`standard`](http://npm.im/standard) - style checker. Forrest and Rebecca both feel this makes it easier to read - and understand the code, and should also make it easier for new - contributors to put merge-ready patches. - ([@othiym23](https://github.com/othiym23)) - -#### ZARRO BOOGS - -* [`6401643`](https://github.com/npm/npm/commit/6401643) - Make sure the global install directory exists before installing to it. - ([@thefourtheye](https://github.com/thefourtheye)) -* [#6158](https://github.com/npm/npm/issues/6158) - When we remove modules we do so inside-out running unbuild for each one. -* [`960a765`](https://github.com/npm/npm/commit/960a765) - The short usage information for each subcommand has been brought in sync - with the documentation. ([@smikes](https://github.com/smikes)) diff --git a/changelogs/CHANGELOG-4.md b/changelogs/CHANGELOG-4.md deleted file mode 100644 index 2c971bb..0000000 --- a/changelogs/CHANGELOG-4.md +++ /dev/null @@ -1,1566 +0,0 @@ -## v4.6.1 (2017-04-21) - -A little release to tide you over while we hammer out the last bits for npm@5. - -### FEATURES - -* [`d13c9b2f2`](https://github.com/npm/npm/commit/d13c9b2f24b6380427f359b6e430b149ac8aaa79) - `init-package-json@1.10.0`: - The `name:` prompt is now `package name:` to make this less ambiguous for new users. - - The default package name is now a valid package name. For example: If your package directory - has mixed case, the default package name will be all lower case. -* [`f08c66323`](https://github.com/npm/npm/commit/f08c663231099f7036eb82b92770806a3a79cdf1) - [#16213](https://github.com/npm/npm/pull/16213) - Add `--allow-same-version` option to `npm version` so that you can use `npm version` to run - your version lifecycles and tag your git repo without actually changing the version number in - your `package.json`. - ([@lucastheisen](https://github.com/lucastheisen)) -* [`f5e8becd0`](https://github.com/npm/npm/commit/f5e8becd05e0426379eb0c999abdbc8e87a7f6f2) - Timing has been added throughout the install implementation. You can see it by running - a command with `--loglevel=timing`. You can also run commands with `--timing` which will write - an `npm-debug.log` even on success and add an entry to `_timing.json` in your cache with - the timing information from that run. - ([@iarna](https://github.com/iarna)) - -### BUG FIXES - -* [`9c860f2ed`](https://github.com/npm/npm/commit/9c860f2ed3bdea1417ed059b019371cd253db2ad) - [#16021](https://github.com/npm/npm/pull/16021) - Fix a crash in `npm doctor` when used with a registry that does not support - the `ping` API endpoint. - ([@watilde](https://github.com/watilde)) -* [`65b9943e9`](https://github.com/npm/npm/commit/65b9943e9424c67547b0029f02b0258e35ba7d26) - [#16364](https://github.com/npm/npm/pull/16364) - Shorten the ELIFECYCLE error message. The shorter error message should make it much - easier to discern the actual cause of the error. - ([@j-f1](https://github.com/j-f1)) -* [`a87a4a835`](https://github.com/npm/npm/commit/a87a4a8359693518ee41dfeb13c5a8929136772a) - `npmlog@4.0.2`: - Fix flashing of the progress bar when your terminal is very narrow. - ([@iarna](https://github.com/iarna)) -* [`41c10974f`](https://github.com/npm/npm/commit/41c10974fe95a2e520e33e37725570c75f6126ea) - `write-file-atomic@1.3.2`: - Wait for `fsync` to complete before considering our file written to disk. - This will improve certain sorts of Windows diagnostic problems. -* [`2afa9240c`](https://github.com/npm/npm/commit/2afa9240ce5b391671ed5416464f2882d18a94bc) - [#16336](https://github.com/npm/npm/pull/16336) - Don't ham-it-up when expecting JSON. - ([@bdukes](https://github.com/bdukes)) - -### DOCUMENTATION FIXES - -* [`566f3eebe`](https://github.com/npm/npm/commit/566f3eebe741f935b7c1e004bebf19b8625a1413) - [#16296](https://github.com/npm/npm/pull/16296) - Use a single convention when referring to the `<command>` you're running. - ([@desfero](https://github.com/desfero)) -* [`ccbb94934`](https://github.com/npm/npm/commit/ccbb94934d4f677f680c3e2284df3d0ae0e65758) - [#16267](https://github.com/npm/npm/pull/16267) - Fix a missing space in the example package.json. - ([@famousgarkin](https://github.com/famousgarkin)) - -### DEPENDENCY UPDATES - -* [`ebde4ea33`](https://github.com/npm/npm/commit/ebde4ea3363dfc154c53bd537189503863c9b3a4) - `hosted-git-info@2.4.2` -* [`c46ad71bb`](https://github.com/npm/npm/commit/c46ad71bbe27aaa9ee10e107d8bcd665d98544d7) - `init-package-json@1.9.6` -* [`d856d570d`](https://github.com/npm/npm/commit/d856d570d2df602767c039cf03439d647bba2e3d) - `npm-registry-client@8.1.1` -* [`4a2e14436`](https://github.com/npm/npm/commit/4a2e1443613a199665e7adbda034d5b9d10391a2) - `readable-stream@2.2.9` -* [`f0399138e`](https://github.com/npm/npm/commit/f0399138e6d6f1cd7f807d523787a3b129996301) - `normalize-package-data@2.3.8` - -### v4.5.0 (2017-03-24) - -Welcome a wrinkle on npm's registry API! - -Codename: Corgi - -![corgi-meme](https://cloud.githubusercontent.com/assets/757502/24126107/64c14268-0d89-11e7-871b-d457e6d0082b.jpg) - -This release has some bug fixes, but it's mostly about bringing support for -MUCH smaller package metadata. How much smaller? Well, for npm itself it -reduces 416K of gzip compressed JSON to 24K. - -As a user, all you have to do is update to get to use the new API. If -you're interested in the details we've [documented the -changes](https://github.com/npm/registry/blob/master/docs/responses/package-metadata.md) -in detail. - -#### CORGUMENTS - -Package metadata: now smaller. This means a smaller cache and less to download. - -* [`86dad0d74`](https://github.com/npm/npm/commit/86dad0d747f288eab467d49c9635644d3d44d6f0) - Add support for filtered package metadata. - ([@iarna](https://github.com/iarna)) -* [`41789cffa`](https://github.com/npm/npm/commit/41789cffac9845603f4bdf3f5b03f412144a0e9f) - `npm-registry-client@8.1.0` - ([@iarna](https://github.com/iarna)) - -#### NO SHRINKWRAP, NO PROBLEM - -Previously we needed to extract every package's tarball to look for an -`npm-shrinkwrap.json` before we could begin working through what its -dependencies were. This was one of the things stopping npm's network -accesses from happening more concurrently. The new filtered package -metadata provides a new key, `_hasShrinkwrap`. When that's set to `false` -then we know we don't have to look for one. - -* [`4f5060eb3`](https://github.com/npm/npm/commit/4f5060eb31b9091013e1d6a34050973613a294a3) - [#15969](https://github.com/npm/npm/pull/15969) - Add support for skipping `npm-shrinkwrap.json` extraction when the - registry can affirm that one doesn't exist. - ([@iarna](https://github.com/iarna)) - -#### INTERRUPTING SCRIPTS - -* [`878aceb25`](https://github.com/npm/npm/commit/878aceb25e6d6052dac15da74639ce274c8e62c5) - [#16129](https://github.com/npm/npm/pull/16129) - Better handle Ctrl-C while running scripts. `npm` will now no longer exit - until the script it is running has exited. If you press Ctrl-C a second - time it kill the script rather than just forwarding the Ctrl-C. - ([@jaridmargolin](https://github.com/jaridmargolin)) - -#### DEPENDENCY UPDATES: - -* [`def75eebf`](https://github.com/npm/npm/commit/def75eebf1ad437bf4fd3f5e103cc2d963bd2a73) - `hosted-git-info@2.4.1`: - Preserve case of the user name part of shortcut specifiers, previously they were lowercased. - ([@iarna](https://github.com/iarna)) -* [`eb3789fd1`](https://github.com/npm/npm/commit/eb3789fd18cfb063de9e6f80c3049e314993d235) - `node-gyp@3.6.0`: Add support for VS2017 and Chakracore improvements. - ([@refack](https://github.com/refack)) - ([@kunalspathak](https://github.com/kunalspathak)) -* [`245e25315`](https://github.com/npm/npm/commit/245e25315524b95c0a71c980223a27719392ba75) - `readable-stream@2.2.6` ([@mcollina](https://github.com/mcollina)) -* [`30357ebc5`](https://github.com/npm/npm/commit/30357ebc5691d7c9e9cdc6e0fe7dc6253220c9c2) - `which@1.2.14` ([@isaacs](https://github.com/isaacs)) - -### v4.4.4 (2017-03-16) - -😩😤😅 Okay! We have another `next` -release for ya today. So, yes! With v4.4.3 we fixed the bug that made -bundled scoped modules uninstallable. But somehow I overlooked the fact -that we: A) were using these and B) that made upgrading to v4.4.3 impossible. 😭 - -So I've renamed those two scoped modules to no longer use scopes and we now -have a shiny new test to ensure that scoped modules don't creep into our -transitive deps and make it impossible to upgrade to `npm`. - -(None of our woes applies to most of you all because most of you all don't -use bundled dependencies. `npm` does because we want the published artifact to be -installable without having to already have `npm`.) - -* [`2a7409fcb`](https://github.com/npm/npm/commit/2a7409fcba6a8fab716c80f56987b255983e048e) - [#16066](https://github.com/npm/npm/pull/16066) - Ensure we aren't using any scoped modules - Because `npm`s prior 4.4.3 can't install dependencies that have bundled scoped - modules. This didn't show up sooner because they ALSO had a bug that caused - bundled scoped modules to not be included in the bundle. - ([@iarna](https://github.com/iarna)) -* [`eb4c70796`](https://github.com/npm/npm/commit/eb4c70796c38f24ee9357f5d4a0116db582cc7a9) - [#16066](https://github.com/npm/npm/pull/16066) - Switch to move-concurrently to remove scoped dependency - ([@iarna](https://github.com/iarna)) - -### v4.4.3 (2017-03-15) - -This is a small patch release, mostly because the published tarball for -v4.4.2 was missing a couple of modules, due to a bug involving scoped -modules, bundled dependencies and legacy tree layouts. - -There are a couple of other things here that happened to be ready to go. So -without further ado… - -#### BUG FIXES - -* [`3d80f8f70`](https://github.com/npm/npm/commit/3d80f8f70679ad2b8ce7227d20e8dbce257a47b9) - [npm/fs-vacuum#6](https://github.com/npm/fs-vacuum/pull/6) - `fs-vacuum@1.2.1`: Make sure we never, ever remove home directories. Previously if your - home directory was entirely empty then we might `rmdir` it. - ([@helio-frota](https://github.com/helio-frota)) -* [`1af85ca9f`](https://github.com/npm/npm/commit/1af85ca9f4d625f948e85961372de7df3f3774e2) - [#16040](https://github.com/npm/npm/pull/16040) - Fix bug where bundled transitive dependencies that happened to be - installed under bundled scoped dependencies wouldn't be included in the - tarball when building a package. - ([@iarna](https://github.com/iarna)) -* [`13c7fdc2e`](https://github.com/npm/npm/commit/13c7fdc2e87456a87b1c9385a3daeae228ed7c95) - [#16040](https://github.com/npm/npm/pull/16040) - Fix a bug where bundled scoped dependencies couldn't be extracted. - ([@iarna](https://github.com/iarna)) -* [`d6cde98c2`](https://github.com/npm/npm/commit/d6cde98c2513fe160eab41e31c3198dfde993207) - [#16040](https://github.com/npm/npm/pull/16040) - Stop printing `ENOENT` errors more than once. - ([@iarna](https://github.com/iarna)) -* [`722fbf0f6`](https://github.com/npm/npm/commit/722fbf0f6cf4413cdc24b610bbd60a7dbaf2adfe) - [#16040](https://github.com/npm/npm/pull/16040) - Rewrite the `extract` action for greater clarity. - Specifically, this involves moving things around structurally to do the same - thing [`d0c6d194`](https://github.com/npm/npm/commit/d0c6d194) did, but in a more comprehensive manner. - This also fixes a long standing bug where errors from the move step would be - eaten during this phase and as a result we would get mysterious crashes in - the finalize phase when finalize tried to act on them. - ([@iarna](https://github.com/iarna)) -* [`6754dabb6`](https://github.com/npm/npm/commit/6754dabb6bd3301504efb3b62f36d3fe70958c19) - [#16040](https://github.com/npm/npm/pull/16040) - Flatten out `@npmcorp/move`'s deps for backwards compatibility reasons. Versions prior to this - one will fail to install any package that bundles a scoped dependency. This was responsible - for `ENOENT` errors during the `finalize` phase. - ([@iarna](https://github.com/iarna)) - -#### DOC UPDATES - -* [`fba51c582`](https://github.com/npm/npm/commit/fba51c582d1d08dd4aa6eb27f9044dddba91bb18) - [#15960](https://github.com/npm/npm/pull/15960) - Update troubleshooting and contribution guide links. - ([@watilde](https://github.com/watilde)) - - -### v4.4.2 (2017-03-09): - -This week, the focus on the release was mainly going through [all of npm's deps -that we manage -ourselves](https://github.com/npm/npm/wiki/npm-maintained-dependencies), and -making sure all their PRs and versions were up to date. That means there's a few -fixes here and there. Nothing too big codewise, though. - -The most exciting part of this release is probably our [shiny new -Contributing](https://github.com/npm/npm/blob/latest/CONTRIBUTING.md) and -[Troubleshooting](https://github.com/npm/npm/blob/latest/TROUBLESHOOTING.md) -docs! [@snopeks](https://github.com/snopeks) did some ✨fantastic✨ work hashing it -out, and we're really hoping this is a nice big step towards making contributing -to npm easier. The troubleshooting doc will also hopefully solve common issues -for people! Do you think something is missing from it? File a PR and we'll add -it! The current document is just a baseline for further editing and additions. - -Also there's maybe a bit of an easter egg in this release. 'Cause those are fun and I'm a huge nerd. 😉 - -#### DOCUMENTATION AHOY - -* [`07e997a`](https://github.com/npm/npm/commit/07e997a7ecedba7b29ad76ffb2ce990d5c0200fc) - [#15756](https://github.com/npm/npm/pull/15756) - Overhaul `CONTRIBUTING.md` and add new `TROUBLESHOOTING.md` files. 🙌🏼 - ([@snopeks](https://github.com/snopeks)) -* [`2f3e4b6`](https://github.com/npm/npm/commit/2f3e4b645cdc268889cf95ba24b2aae572d722ad) - [#15833](https://github.com/npm/npm/pull/15833) - Mention the [24-hour unpublish - policy](http://blog.npmjs.org/post/141905368000/changes-to-npms-unpublish-policy) - on the main registry. - ([@carols10cents](https://github.com/carols10cents)) - -#### NOT REALLY FEATURES, NOT REALLY BUGFIXES. MORE LIKE TWEAKS? 🤔 - -* [`84be534`](https://github.com/npm/npm/commit/84be534aedb78c65cd8012427fc04871ceeccf90) - [#15888](https://github.com/npm/npm/pull/15888) - Stop flattening `ls`-tree output. From now on, deduped deps will be marked as - such in the place where they would've been before getting hoisted by the - installer. - ([@iarna](https://github.com/iarna)) -* [`e9a5dca`](https://github.com/npm/npm/commit/e9a5dca369ead646ab5922326cede1406c62bd3b) - [#15967](https://github.com/npm/npm/pull/15967) - Limit metadata fetches to 10 concurrent requests. - ([@iarna](https://github.com/iarna)) -* [`46aa9bc`](https://github.com/npm/npm/commit/46aa9bcae088740df86234fc199f7aef53b116df) - [#15967](https://github.com/npm/npm/pull/15967) - Limit concurrent installer actions to 10. - ([@iarna](https://github.com/iarna)) - -#### BUGFIXES - -* [`c3b994b`](https://github.com/npm/npm/commit/c3b994b71565eb4f943cce890bb887d810e6e2d4) - [#15901](https://github.com/npm/npm/pull/15901) - Use EXDEV aware move instead of rename. This will allow moving across devices - and moving when filesystems don't support renaming directories full of files. It might make folks using Docker a bit happier. - ([@iarna](https://github.com/iarna)) -* [`0de1a9c`](https://github.com/npm/npm/commit/0de1a9c1db90e6705c65c068df1fe82899e60d68) - [#15735](https://github.com/npm/npm/pull/15735) - Autocomplete support for npm scripts with `:` colons in the name. - ([@beyondcompute](https://github.com/beyondcompute)) -* [`84b0b92`](https://github.com/npm/npm/commit/84b0b92e7f78ec4add42e8161c555325c99b7f98) - [#15874](https://github.com/npm/npm/pull/15874) - Stop using [undocumented](https://github.com/nodejs/node/pull/11355) - `res.writeHeader` alias for `res.writeHead`. - ([@ChALkeR](https://github.com/ChALkeR)) -* [`895ffe4`](https://github.com/npm/npm/commit/895ffe4f3eecd674796395f91c30eda88aca6b36) - [#15824](https://github.com/npm/npm/pull/15824) - Fix empty versions column in `npm search` output. - ([@bcoe](https://github.com/bcoe)) -* [`38c8d7a`](https://github.com/npm/npm/commit/38c8d7adc1f43ab357d1e729ae7cd5d801a26e68) - `init-package-json@1.9.5`: [npm/init-package-json#61](https://github.com/npm/init-package-json/pull/61) Exclude existing `devDependencies` from being added to `dependencies`. Fixes [#12260](https://github.com/npm/npm/issues/12260). - ([@addaleax](https://github.com/addaleax)) - -### v4.4.1 (2017-03-06): - -This is a quick little patch release to forgo the update notification -checker if you're on an unsupported (but not otherwise broken) version of -Node.js. Right now that means 0.10 or 0.12. - -* [`56ac249`](https://github.com/npm/npm/commit/56ac249ef8ede1021f1bc62a0e4fe1e9ba556af2) - [#15864](https://github.com/npm/npm/pull/15864) - Only use `update-notifier` on supported versions. - ([@legodude17](https://github.com/legodude17)) - -### v4.4.0 (2017-02-23): - -Aaaah, [@iarna](https://github.com/iarna) here, it's been a little while -since I did one of these! This is a nice little release, we've got an -update notifier, vastly less verbose error messages, new warnings on package -metadata that will probably give you a bad day, and a sprinkling of bug -fixes. - -#### UPDATE NOTIFICATIONS - -We now have a little nudge to update your `npm`, courtesy of -[update-notifier](https://www.npmjs.com/package/update-notifier). - -* [`148ee66`](https://github.com/npm/npm/commit/148ee663740aa05877c64f16cdf18eba33fbc371) - [#15774](https://github.com/npm/npm/pull/15774) - `npm` will now check at start up to see if a newer version is available. - It will check once a day. If you want to disable this, set `optOut` to `true` in - `~/.config/configstore/update-notifier-npm.json`. - ([@ceejbot](https://github.com/ceejbot)) - -#### LESS VERBOSE ERROR MESSAGES - -`npm` has, for a long time, had very verbose error messages. There was a -lot of info in there, including the cause of the error you were seeing but -without a lot of experience reading them pulling that out was time consuming -and difficult. - -With this change the output is cut down substantially, centering the error -message. So, for example if you try to `npm run sdlkfj` then the entire -error you'll get will be: - -``` -npm ERR! missing script: sldkfj - -npm ERR! A complete log of this run can be found in: -npm ERR! /Users/rebecca/.npm/_logs/2017-02-24T00_41_36_988Z-debug.log -``` - -The CLI team has discussed cutting this down even further and stripping the -`npm ERR!` prefix off those lines too. We'd appreciate your feedback on -this! - -* [`e544124`](https://github.com/npm/npm/commit/e544124592583654f2970ec332003cfd00d04f2b) - [#15716](https://github.com/npm/npm/pull/15716) - Make error output less verbose. - ([@iarna](https://github.com/iarna)) -* [`166bda9`](https://github.com/npm/npm/commit/166bda97410d0518b42ed361020ade1887e684af) - [#15716](https://github.com/npm/npm/pull/15716) - Stop encouraging users to visit the issue tracker unless we know for - certain that it's an npm bug. - ([@iarna](https://github.com/iarna)) - -#### OTHER NEW FEATURES - -* [`53412eb`](https://github.com/npm/npm/commit/53412eb22c1c75d768e30f96d69ed620dfedabde) - [#15772](https://github.com/npm/npm/pull/15772) - We now warn if you have a module listed in both dependencies and - devDependencies. - ([@TedYav](https://github.com/TedYav)) -* [`426b180`](https://github.com/npm/npm/commit/426b1805904a13bdc5c0dd504105ba037270cbee) - [#15757](https://github.com/npm/npm/pull/15757) - Default reporting metrics to default registry. Previously it defaulted to using - `https://registry.npmjs.org`, now it will default to the result of - `npm config get registry`. For most folks this won't actually change anything, but it - means that folks who use a private registry will have metrics routed there by default. - This has the potential to be interesting because it means that in the - future private registry products ([npme](https://npme.npmjs.com/docs/)!) - will be able to report on these metrics. - ([@iarna](https://github.com/iarna)) - -#### BUG FIXES - -* [`8ea0de9`](https://github.com/npm/npm/commit/8ea0de98563648ba0db032acd4d23d27c4a50a66) - [#15716](https://github.com/npm/npm/pull/15716) - Write logs for `cb() never called` errors. -* [`c4e83dc`](https://github.com/npm/npm/commit/c4e83dca830b24305e3cb3201a42452d56d2d864) - Make it so that errors while reading the existing node_modules tree can't - result in installer crashes. - ([@iarna](https://github.com/iarna)) -* [`2690dc2`](https://github.com/npm/npm/commit/2690dc2684a975109ef44953c2cf0746dbe343bb) - Update `npm doctor` to not treat broken symlinks in your global modules as - a permission failure. This is particularly important if you link modules and your text - editor uses the convention of creating symlinks from `.#filename.js` to a - machine name and pid to lock files (eg emacs and compatible things). - ([@iarna](https://github.com/iarna)) -* [`f4c3f48`](https://github.com/npm/npm/commit/f4c3f489aa5787cf0d60e8436be2190e4b0d0ff7) - [#15777](https://github.com/npm/npm/pull/15777) - Not exactly a bug, but change a parameterless `.apply` to `.call`. - ([@notarseniy](https://github.com/notarseniy)) - -#### DEPENDENCY UPDATES - -* [`549dcff`](https://github.com/npm/npm/commit/549dcff58c7aaa1e7ba71abaa14008fdf2697297) - `rimraf@2.6.0`: - Retry EBUSY, ENOTEMPTY and EPERM on non-Windows platforms too. - More reliable `rimraf.sync` on Windows. - ([@isaacs](https://github.com/isaacs)) -* [`052dfb6`](https://github.com/npm/npm/commit/052dfb623da508f2b5f681da0258125552a18a4a) - `validate-npm-package-name@3.0.0`: - Remove ableist language in README. - Stop allowing ~'!()* in package names. - ([@tomdale](https://github.com/tomdale)) - ([@chrisdickinson](https://github.com/chrisdickinson)) -* [`6663ea6`](https://github.com/npm/npm/commit/6663ea6ac0f0ecec5a3f04a3c01a71499632f4dc) - `abbrev@1.1.0` ([@isaacs](https://github.com/isaacs)) -* [`be6de9a`](https://github.com/npm/npm/commit/be6de9aab9e20b6eac70884e8626161eebf8721a) - `opener@1.4.3` ([@dominic](https://github.com/dominic)) -* [`900a5e3`](https://github.com/npm/npm/commit/900a5e3e3411ec221306455f99b24b9ce35757c0) - `readable-stream@2.2.3` ([@RangerMauve](https://github.com/RangerMauve)) ([@mcollina](https://github.com/mcollina)) -* [`c972a8b`](https://github.com/npm/npm/commit/c972a8b0f20a61a79c45b6642f870bea8c55c7e4) - `tacks@1.2.6` - ([@iarna](https://github.com/iarna)) -* [`85a36ef`](https://github.com/npm/npm/commit/85a36efdac0c24501876875cb9ad40292024e0b0) - [`7ac9265`](https://github.com/npm/npm/commit/7ac9265c56b4d9eeaca6fcfb29513f301713e7bb) - `tap@10.2.0` - ([@isaacs](https://github.com/saacs)) - -### v4.3.0 (2017-02-09): - -Yay! Release time! It's a rainy day, and we have another smallish release for -y'all. These things are not necessarily related. Or are they 🌧🤔 - -As far as news go, you may have noticed that the CLI team dropped support for -`node@0.12` when that version went out of maintenance. Still, we've avoided -explicitly breaking it and `node@0.10` so far -- but not much longer. - -Sometime soon, the CLI team plans on switching over to language features only -available as of `node@4 LTS`, and will likely start dropping old versions of node -as they go out of maintenance. The new features are exciting! We're really -looking forward to using them in the core CLI (and its dependencies) as we keep up -with our current feature work. - -And speaking of features, this release is a minor bump due to a small change in -how `npm login` works for the sake of supporting OAuth-based login for npm -Enterprise users. But we won't leave the rest of y'all out -- we're working on a -larger version of this feature. Soon enough, you'll be able to log in to npm -with, say, GitHub -- and use some shiny features that come from the integration. -Or turn on 2FA and other such security features. Keep your eyes peeled for new -on this in the next few releases and our weekly newsletter! - -#### NEW AUTH TYPES - -There's a new command line option: `--auth-type`, which can be used to log in to -a supporting registry with OAuth2 or SAML. The current implementation is mainly -meant to support npmE customers, so if you're one of those: ask us about using -it! If not, just hold off cause we'll have a much more complete version of this -feature out soon. - -* [`ac8595e`](https://github.com/npm/npm/commit/ac8595e3c9b615ff95abc3301fac1262c434792c) [`bcf2dd8`](https://github.com/npm/npm/commit/bcf2dd8a165843255c06515fa044c6e4d3b71ca4) [`9298d20`](https://github.com/npm/npm/commit/9298d20af58b92572515bfa9cf7377bd4221dc7d) [`66b61bc`](https://github.com/npm/npm/commit/66b61bc42e81ee8a1ee00fc63517f62284140688) [`dc85de7`](https://github.com/npm/npm/commit/dc85de7df6bb61f7788611813ee82ae695a18f1f) - [#13389](https://github.com/npm/npm/pull/13389) - Implement single-sign-on support with `--auth-type` option. - ([@zkat](https://github.com/zkat)) - -#### FASTER STARTUP. SOMETIMES! - -`request` is pretty heavy. And it loads a bunch of things. It's actually a -pretty big chunk of npm's load time. This small patch by Rebecca will make it so -npm only loads that module when we're actually intending to make network -requests. Those of you who use npm commands that run offline might see a small -speedup in startup time. - -* [`ac73568`](https://github.com/npm/npm/commit/ac735682e666e8724549d56146821f3b8b018e25) - [#15631](https://github.com/npm/npm/pull/15631) - Lazy load `caching-registry-client`. - ([@iarna](https://github.com/iarna)) - -#### DOCUMENTATION - -* [`4ad9247`](https://github.com/npm/npm/commit/4ad9247aa82f7553c9667ee93c74ec7399d6ceec) - [#15630](https://github.com/npm/npm/pull/15630) - Fix formatting/rendering for root npm README. - ([@ungoldman](https://github.com/ungoldman)) - -#### DEPENDENCY UPDATES - -* [`8cc1112`](https://github.com/npm/npm/commit/8cc1112958638ff88ac2c24c4a065acacb93d64b) - [npm/hosted-git-info#21](https://github.com/npm/hosted-git-info/pull/21) - `hosted-git-info@2.2.0`: - Add support for `.tarball()` URLs. - ([@zkat](https://github.com/zkat)) -* [`6eacc1b`](https://github.com/npm/npm/commit/6eacc1bc1925fe3cc79fc97bdc3194d944fce55e) - `npm-registry-mock@1.1.0` - ([@addaleax](https://github.com/addaleax)) -* [`a9b6d77`](https://github.com/npm/npm/commit/a9b6d775e61cf090df0e13514c624f99bf31d1e7) - `aproba@1.1.1` - ([@iarna](https://github.com/iarna)) - -### v4.2.0 (2017-01-26): - -Hi all! I'm Kat, and I'm currently sitting in a train traveling at ~300km/h -through Spain. So clearly, this release should have *something* to do with -speed. And it does! Heck, with this release, you could say we're really -_blazing_, even. 🌲🔥😏 - -#### IMPROVED CLI SEARCH~ - -You might recall if you've been keeping up that one of the reasons for a -semver-major bump to `npm@4` was an improved CLI search (read: no longer blowing -up Node). The work done for that new search system, while still relying on a -full metadata download and local search, was also meant to act as groundwork for -then-ongoing work on a brand-new, smarter search system for npm. Shortly after -`npm@4` came out, the bulk of the server-side work was done, and with this -release, the npm CLI has integrated use of the new endpoint for high-quality, -fast-turnaround searches. - -No, seriously, it's *fast*. And *relevant*: - -[![GOTTA GO FAST! This is a gif of the new npm search returning results in around a second for `npm search web framework`.](https://cloud.githubusercontent.com/assets/17535/21954136/f007e8be-d9fd-11e6-9231-f899c12790e0.gif)](https://github.com/npm/npm/pull/15481) - -Give it a shot! And remember to check out the new website version of the search, -too, which uses the same backend as the CLI now. 🎉 - -Incidentally, the backend is a public service, so you can write your own search -tools, be they web-based, CLI, or GUI-based. You can read up on the [full -documentation for the search -endpoint](https://github.com/npm/registry/blob/master/docs/REGISTRY-API.md#get-v1search), -and let us know about the cool things you come up with! - -* [`ce3ca51`](https://github.com/npm/npm/commit/ce3ca51ca2d60e15e901c8bf6256338e53e1eca2) - [#15481](https://github.com/npm/npm/pull/15481) - Add an internal `gunzip-maybe` utility for optional gunzipping. - ([@zkat](https://github.com/zkat)) -* [`e322932`](https://github.com/npm/npm/commit/e3229324d507fda10ea9e94fd4de8a4ae5025c75) [`a53055e`](https://github.com/npm/npm/commit/a53055e423f1fe168f05047aa0dfec6d963cb211) [`a1f4365`](https://github.com/npm/npm/commit/a1f436570730c6e4a173ca92d1967a87c29b7f2d) [`c56618c`](https://github.com/npm/npm/commit/c56618c62854ea61f6f716dffe7bcac80b5f4144) - [#15481](https://github.com/npm/npm/pull/15481) - Add support for using the new npm search endpoint for fast, quality search - results. Includes a fallback to "classic" search. - ([@zkat](https://github.com/zkat)) - -#### WHERE DID THE DEBUG LOGS GO - -This is another pretty significant change: Usually, when the npm process -crashed, you would get an `npm-debug.log` in your current working directory. -This debug log would get cleared out as soon as you ran npm again. This was a -bit annoying because 1) you would get a random file in your `git status` that -you might accidentally commit, and 2) if you hit a hard-to-reproduce bug and -instinctually tried again, you would no longer have access to the repro -`npm-debug.log`. - -So now, any time a crash happens, we'll save your debug logs to your cache -folder, under `_logs` (`~/.npm` on *nix, by default -- use `npm config get -cache` to see what your current value is). The cache will now hold a -(configurable) number of `npm-debug.log` files, which you can access in the -future. Hopefully this will help clean stuff up and reduce frustration from -missed repros! In the future, this will also be used by `npm report` to make it -super easy to put up issues about crashes you run into with npm. 💃🕺🏿👯‍♂️ - -* [`04fca22`](https://github.com/npm/npm/commit/04fca223a0f704b69340c5f81b26907238fad878) - [#11439](https://github.com/npm/npm/pull/11439) - Put debug logs in `$(npm get cache)/_logs` and store multiple log files. - ([@KenanY](https://github.com/KenanY)) - ([@othiym23](https://github.com/othiym23)) - ([@isaacs](https://github.com/isaacs)) - ([@iarna](https://github.com/iarna)) - -#### DOCS - -* [`ae8e71c`](https://github.com/npm/npm/commit/ae8e71c2b7d64d782af287a21e146d7cea6e5273) - [#15402](https://github.com/npm/npm/pull/15402) - Add missing backtick in one of the `npm doctor` messages. - ([@watilde](https://github.com/watilde), [@charlotteis](https://github.com/charlotteis)) -* [`821fee6`](https://github.com/npm/npm/commit/821fee6d0b12a324e035c397ae73904db97d07d2) - [#15480](https://github.com/npm/npm/pull/15480) - Clarify that unscoped packages can depend on scoped packages and vice-versa. - ([@chocolateboy](https://github.com/chocolateboy)) -* [`2ee45a8`](https://github.com/npm/npm/commit/2ee45a884137ae0706b7c741c671fef2cb3bac96) - [#15515](https://github.com/npm/npm/pull/15515) - Update minimum supported Node version number in the README to `node@>=4`. - ([@watilde](https://github.com/watilde)) -* [`af06aa9`](https://github.com/npm/npm/commit/af06aa9a357578a8fd58c575f3dbe55bc65fc376) - [#15520](https://github.com/npm/npm/pull/15520) - Add section to `npm-scope` docs to explain that scope owners will own scoped - packages with that scope. That is, user `@alice` is not allowed to publish to - `@bob/my-package` unless explicitly made an owner by user (or org) `@bob`. - ([@hzoo](https://github.com/hzoo)) -* [`bc892e6`](https://github.com/npm/npm/commit/bc892e6d07a4c6646480703641a4d71129c38b6d) - [#15539](https://github.com/npm/npm/pull/15539) - Replace `http` with `https` and fix typos in some docs. - ([@watilde](https://github.com/watilde)) -* [`1dfe875`](https://github.com/npm/npm/commit/1dfe875b9ac61a0ab9f61a2eab02bacf6cce583c) - [#15545](https://github.com/npm/npm/pull/15545) - Update Node.js download link to point to the right place. - ([@watilde](https://github.com/watilde)) - -#### DEPENDENCIES - - * [`b824bfb`](https://github.com/npm/npm/commit/b824bfbeb2d89c92762e9170b026af98b5a3668a) - `ansi-regex@2.1.1` - * [`81ea3e8`](https://github.com/npm/npm/commit/81ea3e8e4ea34cd9c2b418512dcb508abcee1380) - `mississippi@1.3.0` - -#### MISC - -* [`98df212`](https://github.com/npm/npm/commit/98df212a91fd6ff4a02b9cd247f4166f93d3977a) - [#15492](https://github.com/npm/npm/pull/15492) - Update the "master" node version used for AppVeyor to `node@7`. - ([@watilde](https://github.com/watilde)) -* [`d75fc03`](https://github.com/npm/npm/commit/d75fc03eda5364f12ac266fa4f66e31c2e44e864) - [#15413](https://github.com/npm/npm/pull/15413) - `npm run-script` now exits with the child process' exit code on exit. - ([@kapals](https://github.com/kapals)) - -### v4.1.2 (2017-01-12) - -We have a twee little release this week as we come back from the holidays. - -#### 0.12 IS UNSUPPORTED NOW (really) - -After [jumping the gun a -little](https://github.com/npm/npm/releases/tag/v4.0.2), we can now -officially remove 0.12 from our supported versions list. The Node.js -project has now officially ended even maintenance support for 0.12 and thus, -so will we. To reiterate from the last time we did this: - -What this means: - -* Your contributions will no longer block on the tests passing on 0.12. -* We will no longer block dependency upgrades on working with 0.12. -* Bugs filed on the npm CLI that are due to incompatibilities with 0.12 - (and older versions) will be closed with a strong urging to upgrade to a - supported version of Node. -* On the flip side, we'll continue to (happily!) accept patches that - address regressions seen when running the CLI with Node.js 0.12. - -What this doesn't mean: - -* The CLI is going to start depending on ES2015+ features. npm continues - to work, in almost all cases, all the way back to Node.js 0.8, and our - long history of backwards compatibility is a source of pride for the - team. -* We aren't concerned about the problems of users who, for whatever - reason, can't update to newer versions of npm. As mentioned above, we're - happy to take community patches intended to address regressions. - -We're not super interested in taking sides on what version of Node.js -you "should" be running. We're a workflow tool, and we understand that -you all have a diverse set of operational environments you need to be -able to support. At the same time, we _are_ a small team, and we need -to put some limits on what we support. Tracking what's supported by our -runtime's own team seems most practical, so that's what we're doing. - -* [`c7bbba8`](https://github.com/npm/npm/commit/c7bbba8744b62448103a1510c65d9751288abb5d) - Remove 0.12 from our supported versions list. - ([@iarna](https://github.com/iarna)) - -#### WRITING TO SYMLINKED `package.json` (AND OTHER FILES) - -If your `package.json`, `npm-shrinkwrap.json` or `.npmrc` were a symlink and -you used an `npm` command that modified one of these (eg `npm config set` or -`npm install --save`) then previously we would have removed your symlink and -replaced it with an ordinary file. While making these files symlinks is pretty -uncommon, this was still surprising behavior. With this fix we now overwrite -the _destination_ of the symlink and preserve the symlink itself. - -* [`a583983`](https://github.com/npm/npm/commit/a5839833d3de7072be06884b91902c093aff1aed) - [write-file-atomic/#5](https://github.com/npm/write-file-atomic/issues/5) - [#10223](https://github.com/npm/npm/10223) - `write-file-atomic@1.3.1`: - When the target is a symlink, write-file-atomic now overwrites the - _destination_ of the symlink, instead of replacing the symlink itself. This - makes it's behavior match `fs.writeFile`. - - Fixed a bug where it would ALWAYS fs.stat to look up default mode and chown - values even if you'd passed them in. (It still used the values you passed - in, but did a needless stat.) - ([@iarna](https://github.com/iarna)) - -#### DEPENDENCY UPDATES - -* [`521f230`](https://github.com/npm/npm/commit/521f230dd57261e64ac9613b3db62f5312971dca) - `node-gyp@3.5.0`: - Improvements to how Python is located. New `--devdir` flag. - ([@bnoordhuis](https://github.com/bnoordhuis)) - ([@mhart](https://github.com/mhart)) -* [`ccd83e8`](https://github.com/npm/npm/commit/ccd83e8a70d35fb0904f8a9adb2ff7ac8a6b2706) - `JSONStream@1.3.0`: - Add new emitPath option. - ([@nathanwills](https://github.com/nathanwills)) - -#### TEST IMPROVEMENTS - -* [`d76e084`](https://github.com/npm/npm/commit/d76e08463fd65705217624b861a1443811692f34) - Disable metric reporting for test suite even if the user has it enabled. - ([@iarna](https://github.com/iarna)) - -### v4.1.1 (2016-12-16) - -This fixes a bug in the metrics reporting where, if you had enabled it then -installs would create a metrics reporting process, that would create a -metrics reporting process, that would… well, you get the idea. The only -way to actually kill these processes is to turn off your networking, then -on MacOS/Linux kill them with `kill -9`. Alternatively you can just reboot. - -Anyway, this is a quick release to fix that bug: - -* [`51c393f`](https://github.com/npm/npm/commit/51c393feff5f4908c8a9fb02baef505b1f2259be) - [#15237](https://github.com/npm/npm/pull/15237) - Don't launch a metrics sender process if we're running from a metrics - sender process. - ([@iarna](https://github.com/iarna)) - -### v4.1.0 (2016-12-15) - -I'm really excited about `npm@4.1.0`. I know, I know, I'm kinda overexcited -in my changelogs, but this one is GREAT. We've got a WHOLE NEW subcommand, I -mean, when was the last time you saw that? YEARS! And we have the beginnings -of usage metrics reporting. Then there's a fix for a really subtle bug that -resulted in `shasum` errors. And then we also have a few more bug fixes and -other improvements. - -#### ANONYMOUS METRIC REPORTING - -We're adding the ability for you all to help us track the quality of your -experiences using `npm`. Metrics will be sent if you run: - -``` -npm config set send-metrics true -``` - -Then `npm` will report to `registry.npmjs.org` the number of successful and -failed installations you've had. The data contains no identifying -information and npm will not attempt to correlate things like IP address -with the metrics being submitted. - -Currently we only track number of successful and failed installations. In -the future we would like to find additional metrics to help us better -quantify the quality of the `npm` experience. - -* [`190a658`](https://github.com/npm/npm/commit/190a658c4222f6aa904cbc640fc394a5c875e4db) - [#15084](https://github.com/npm/npm/pull/15084) - Add facility for recording and reporting success metrics. - ([@iarna](https://github.com/iarna)) -* [`87afc8b`](https://github.com/npm/npm/commit/87afc8b466f553fb49746c932c259173de48d0a4) - [npm/npm-registry-client#147](https://github.com/npm/npm-registry-client/pull/148) - `npm-registry-client@7.4.5`: - Add support for sending anonymous CLI metrics. - ([@iarna](https://github.com/iarna), - [@sisidovski](https://github.com/sisidovski)) - -### NPM DOCTOR - -<pre> -<u>Check</u> <u>Value</u> <u>Recommendation</u> -npm ping ok -npm -v v4.0.5 -node -v v4.6.1 Use node v6.9.2 -npm config get registry https://registry.npmjs.org/ -which git /Users/rebecca/bin/git -Perms check on cached files ok -Perms check on global node_modules ok -Perms check on local node_modules ok -Checksum cached files ok -</pre> - -It's a rare day that we add a new command to `npm`, so I'm excited to -present to you `npm doctor`. It checks for a number of common problems and -provides some recommended solutions. It was put together through the hard -work of [@watilde](https://github.com/watilde). - -* [`2359505`](https://github.com/npm/npm/commit/23595055669f76c9fe8f5f1cf4a705c2e794f0dc) - [`0209ee5`](https://github.com/npm/npm/commit/0209ee50448441695fbf9699019d34178b69ba73) - [#14582](https://github.com/npm/npm/pull/14582) - Add new `npm doctor` to give your project environment a health check. - ([@watilde](https://github.com/watilde)) - -#### FIX MAJOR SOURCE OF SHASUM ERRORS - -If you've been getting intermittent shasum errors then you'll be pleased to -know that we've tracked down at least one source of them, if not THE source -of them. - -* [`87afc8b`](https://github.com/npm/npm/commit/87afc8b466f553fb49746c932c259173de48d0a4) - [#14626](https://github.com/npm/npm/issues/14626) - [npm/npm-registry-client#148](https://github.com/npm/npm-registry-client/pull/148) - `npm-registry-client@7.4.5`: - Fix a bug where an `ECONNRESET` while fetching a package file would result - in a partial download that would be reported as a "shasum mismatch". It - now throws away the partial download and retries it. - ([@iarna](https://github.com/iarna)) - -#### FILE URLS AND NODE.JS 7 - -When `npm` was formatting `file` URLs we took advantage of `url.format` to -construct them. Node.js 7 changed the behavior in such a way that our use of -`url.format` stopped producing URLs that we could make use of. - -The reasons for this have to do with the `file` URL specification and how -invalid (according to the specification) URLs are handled. How this changed -is most easily explained with a table: - -<table> -<tr><th></th><th>URL</th><th>Node.js <= 6</th><th><tt>npm</tt>'s understanding</th><th>Node.js 7</th><th><tt>npm</tt>'s understanding</th></tr> -<tr><td>VALID</td><td><tt>file:///abc/def</tt></td><td><tt>file:///abc/def</tt></td><td><tt>/abc/def</tt></td><td><tt>file:///abc/def</tt></td><td><tt>/abc/def</tt></td></tr> -<tr><td>invalid</td><td><tt>file:/abc/def</tt></td><td><tt>file:/abc/def</tt></td><td><tt>/abc/def</tt></td><td><tt>file:///abc/def</tt></td><td><tt>/abc/def</tt></td></tr> -<tr><td>invalid</td><td><tt>file:abc/def</tt></td><td><tt>file:abc/def</tt></td><td><tt>$CWD/abc/def</tt></td><td><tt>file://abc/def</tt></td><td><tt>/def</tt> on the <tt>abc</tt> host</td></tr> -<tr><td>invalid</td><td><tt>file:../abc/def</tt></td><td><tt>file:../abc/def</tt></td><td><tt>$CWD/../abc/def</tt></td><td><tt>file://../abc/def</tt></td><td><tt>/abc/def</tt> on the <tt>..</tt> host</td></tr> -</table> - -So the result was that passing a `file` URL that npm had received that used -through Node.js 7's `url.format` changed its meaning as far as `npm` was -concerned. As those kinds of URLs are, per the specification, invalid, how -they should be handled is undefined and so the change in Node.js wasn't a -bug per se. - -Our solution is to stop using `url.format` when constructing this kind of -URL. - -* [`173935b`](https://github.com/npm/npm/commit/173935b4298e09c4fdcb8f3a44b06134d5aff181) - [#15114](https://github.com/npm/npm/issues/15114) - Stop using `url.format` for relative local dep paths. - ([@zkat](https://github.com/zkat)) - -#### EXTRANEOUS LIFECYCLE SCRIPT EXECUTION WHEN REMOVING - -* [`afb1dfd`](https://github.com/npm/npm/commit/afb1dfd944e57add25a05770c0d52d983dc4e96c) - [#15090](https://github.com/npm/npm/pull/15090) - Skip top level lifecycles when uninstalling. - ([@iarna](https://github.com/iarna)) - -#### REFACTORING AND INTERNALS - -* [`c9b279a`](https://github.com/npm/npm/commit/c9b279aca0fcb8d0e483e534c7f9a7250e2a9392) - [#15205](https://github.com/npm/npm/pull/15205) - [#15196](https://github.com/npm/npm/pull/15196) - Only have one function that determines which version of a package to use - given a specifier and a list of versions. - ([@iarna](https://github.com/iarna), - [@zkat](https://github.com/zkat)) - -* [`981ce63`](https://github.com/npm/npm/commit/981ce6395e7892dde2591b44e484e191f8625431) - [#15090](https://github.com/npm/npm/pull/15090) - Rewrite prune to use modern npm plumbing. - ([@iarna](https://github.com/iarna)) - -* [`bc4b739`](https://github.com/npm/npm/commit/bc4b73911f58a11b4a2d28b49e24b4dd7365f95b) - [#15089](https://github.com/npm/npm/pull/15089) - Rename functions and variables in the module that computes what changes to - make to your installation. - ([@iarna](https://github.com/iarna)) - -* [`2449f74`](https://github.com/npm/npm/commit/2449f74a202b3efdb1b2f5a83356a78ea9ecbe35) - [#15089](https://github.com/npm/npm/pull/15089) - When computing changes to make to your installation, use a function to add - new actions to take instead of just pushing on a list. - ([@iarna](https://github.com/iarna)) - -#### IMPROVED LOGGING - -* [`335933a`](https://github.com/npm/npm/commit/335933a05396258eead139d27eea3f7668ccdfab) - [#15089](https://github.com/npm/npm/pull/15089) - Log when we remove obsolete dependencies in the tree. - ([@iarna](https://github.com/iarna)) - -#### DOCUMENTATION - -* [`33ca4e6`](https://github.com/npm/npm/commit/33ca4e6db3c1878cbc40d5e862ab49bb0e82cfb2) - [#15157](https://github.com/npm/npm/pull/15157) - Update `npm cache` docs to use more consistent language - ([@JonahMoses](https://github.com/JonahMoses)) - -#### DEPENDENCY UPDATES - -* [`c2d22fa`](https://github.com/npm/npm/commit/c2d22faf916e8260136a1cc95913ca474421c0d3) - [#15215](https://github.com/npm/npm/pull/15215) - `nopt@4.0.1`: - The breaking change is a small tweak to how empty string values are - handled. See the brand-new - [CHANGELOG.md for nopt](https://github.com/npm/nopt/blob/v4.0.1/CHANGELOG.md) for further - details about what's changed in this release! - ([@adius](https://github.com/adius), - [@samjonester](https://github.com/samjonester), - [@elidoran](https://github.com/elidoran), - [@helio](https://github.com/helio), - [@silkentrance](https://github.com/silkentrance), - [@othiym23](https://github.com/othiym23)) -* [`54d949b`](https://github.com/npm/npm/commit/54d949b05adefffeb7b5b10229c5fe0ccb929ac3) - [npm/lockfile#24](https://github.com/npm/lockfile/pull/24) - `lockfile@1.0.3`: - Handled case where callback was not passed in by the user. - ([@ORESoftware](https://github.com/ORESoftware)) -* [`54acc03`](https://github.com/npm/npm/commit/54acc0389b39850c0725d0868cb5e61317b57503) - `npmlog@4.0.2`: - Documentation update. - ([@helio-frota](https://github.com/helio-frota)) -* [`57f4bc1`](https://github.com/npm/npm/commit/57f4bc1150322294c1ea0a287ad0a8e457c151e6) - `osenv@0.1.4`: - Test changes. - ([@isaacs](https://github.com/isaacs)) -* [`bea1a2d`](https://github.com/npm/npm/commit/bea1a2d0db566560e13ecc1d5f42e55811269c88) - `retry@0.10.1`: - No changes. - ([@tim-kos](https://github.com/tim-kos)) -* [`6749e39`](https://github.com/npm/npm/commit/6749e395f868109afd97f79d36507e6567dd48fb) - [kapouer/marked-man#9](https://github.com/kapouer/marked-man/pull/9) - `marked-man@0.2.0`: - Add table support. - ([@gholk](https://github.com/gholk)) - -### v4.0.5 (2016-12-01) - -It's that time of year! December is upon us, which means y'all are just going to -be doing a lot less, in general, for the next month or so. The "Xmas Chasm", as -we like to call it, has already begun. So for those of you reading it from the -other side: Hi! Welcome back! - -This week's release is a relatively small one, involving just a few bugfixes and -dependency upgrades. The CLI team has been busy recently with scoping out -`npm@5`, and starting to do initial spec work for in-scope stuff. - -#### BUGFIXES - -On to the actual changes! - -* [`9776d8f`](https://github.com/npm/npm/commit/9776d8f70a0ea8d921cbbcab7a54e52c15fc455f) - [#15081](https://github.com/npm/npm/pull/15081) - `bundledDependencies` are intended to be left untouched by the installer, as - much as possible -- if they're bundled, we assume that you want to be - particular about the contents of your bundle. - - The installer used to have a corner case where existing dependencies that had - bundledDependencies would get clobbered by as the installer moved stuff - around, even though the installer already avoided moving deps that were - themselves bundled. This is now fixed, along with the connected crasher, and - your bundledDeps should be left even more intact than before! - ([@iarna](https://github.com/iarna)) -* [`fc61c08`](https://github.com/npm/npm/commit/fc61c082122104031ccfb2a888432c9f809a0e8b) - [#15082](https://github.com/npm/npm/pull/15082) - Initialize nodes from bundled dependencies. This should address - [#14427](https://github.com/npm/npm/issues/14427) and related issues, but it's - turned out to be a tremendously difficult issue to reproduce in a test. We - decided to include it even pending tests, because we found the root cause of - the errors. - ([@iarna](https://github.com/iarna)) -* [`d8471a2`](https://github.com/npm/npm/commit/d8471a294ef848fc893f60e17d6ec6695b975d16) - [#12811](https://github.com/npm/npm/pull/12811) - Consider `devDependencies` when deciding whether to hoist a package. This - should resolve a variety of missing dependency issues some folks were seeing - when `devDependencies` happened to also be dependencies of your - `dependencies`. This often manifested as modules going missing, or only being - installed, after `npm install` was called twice. - ([@schmod](https://github.com/schmod)) - -#### DEPENDENCY UPDATES - -* [`5978703`](https://github.com/npm/npm/commit/5978703da8669adae464789b1b15ee71d7f8d55d) - `graceful-fs@4.1.11`: - `EPERM` errors are Windows are now handled more gracefully. Windows users that - tended to see these errors due to, say, an antivirus-induced race condition, - should see them much more rarely, if at all. - ([@zkatr](https://github.com/zkat)) -* [`85b0174`](https://github.com/npm/npm/commit/85b0174ba9842e8e89f3c33d009e4b4a9e877c7d) - `request@2.79.0` - ([@zkat](https://github.com/zkat)) -* [`9664d36`](https://github.com/npm/npm/commit/9664d36653503247737630440bc2ff657de965c3) - `tap@8.0.1` - ([@zkat](https://github.com/zkat)) - -#### MISCELLANEOUS - -* [`f0f7b0f`](https://github.com/npm/npm/commit/f0f7b0fd025daa2b69994130345e6e8fdaaa0304) - [#15083](https://github.com/npm/npm/pull/15083) - Removed dead code. - ([@iarna](https://github.com/iarna)) * [`bc32afe`](https://github.com/npm/npm/commit/bc32afe4d12e3760fb5a26466dc9c26a5a2981d5) [`c8a22fe`](https://github.com/npm/npm/commit/c8a22fe5320550e09c978abe560b62ce732686f4) [`db2666d`](https://github.com/npm/npm/commit/db2666d8c078fc69d0c02c6a3de9b31be1e995e9) - [#15085](https://github.com/npm/npm/pull/15085) - Change some network tests so they can run offline. - ([@iarna](https://github.com/iarna)) -* [`744a39b`](https://github.com/npm/npm/commit/744a39b836821b388ad8c848bd898c1d006689a9) - [#15085](https://github.com/npm/npm/pull/15085) - Make Node.js tests compatible with Windows. - ([@iarna](https://github.com/iarna)) - -### v4.0.3 (2016-11-17) - -Hey you all, we've got a couple of bug fixes for you, a slew of -documentation improvements and some improvements to our CI environment. I -know we just got v4 out the door, but the CLI team is already busy planning -v5. We'll have more for you in early December. - -#### BUG FIXES - -* [`45d40d9`](https://github.com/npm/npm/commit/45d40d96d2cd145f1e36702d6ade8cd033f7f332) - [`ba2adc2`](https://github.com/npm/npm/commit/ba2adc2e822d5e75021c12f13e3f74ea2edbde32) - [`1dc8908`](https://github.com/npm/npm/commit/1dc890807bd78a1794063688af31287ed25a2f06) - [`2ba19ee`](https://github.com/npm/npm/commit/2ba19ee643d612d103cdd8f288d313b00d05ee87) - [#14403](https://github.com/npm/npm/pull/14403) - Fix a bug where a scoped module could produce crashes when incorrectly - computing the paths related to their location. This patch reorganizes how path information - is passed in to eliminate the possibility of this sort of bug. - ([@iarna](https://github.com/iarna)) - ([@NatalieWolfe](https://github.com/NatalieWolfe)) -* [`1011ec6`](https://github.com/npm/npm/commit/1011ec61230288c827a1c256735c55cf03d6228f) - [npm/npmlog#46](https://github.com/npm/npmlog/pull/46) - `npmlog@4.0.1`: Fix a bug where the progress bar would still display even if - you passed in `--no-progress`. - ([@iarna](https://github.com/iarna)) - -#### DOCUMENTATION UPDATES - -* [`c3ac177`](https://github.com/npm/npm/commit/c3ac177236124c80524c5f252ba8f6670f05dcd8) - [#14406](https://github.com/npm/npm/pull/14406) - Sync up the dispute policy included with the CLI with the [current official text](https://www.npmjs.com/policies/disputes). - ([@mike-engel](https://github.com/mike-engel)) -* [`9c663b2`](https://github.com/npm/npm/commit/9c663b2dd8552f892dc0205330bbc73a484ecd81) - [#14627](https://github.com/npm/npm/pull/14627) - Update build status branch in README. - ([@cameronroe](https://github.com/cameronroe)) -* [`8a8a0a3`](https://github.com/npm/npm/commit/8a8a0a3d490fc767def208f925cdff57e16e565b) - [#14609](https://github.com/npm/npm/pull/14609) - Update examples URLs of GitHub repos where those repos have moved to new URLs. - ([@dougwilson](https://github.com/dougwilson)) -* [`7a6425b`](https://github.com/npm/npm/commit/7a6425bcd4decde5d4b0af8b507e98723a07c680) - [#14472](https://github.com/npm/npm/pull/14472) - Document `sign-git-tag` in - [npm-version(1)](https://github.com/npm/npm/blob/release-next/doc/cli/npm-version.md)'s - configuration section. - ([@strugee](https://github.com/strugee)) -* [`f3087cc`](https://github.com/npm/npm/commit/f3087cc58c903d9a70275be805ebaf0eadbcbe1b) - [#14546](https://github.com/npm/npm/pull/14546) - Add a note about the dangers of configuring npm via uppercase env vars. - ([@tuhoojabotti](https://github.com/tuhoojabotti)) -* [`50e51b0`](https://github.com/npm/npm/commit/50e51b04a143959048cf9e1e4c8fe15094f480b0) - [#14559](https://github.com/npm/npm/pull/14559) - Remove documentation that incorrectly stated that we check `.npmrc` permissions. - ([@iarna](https://github.com/iarna)) - -##### OH UH, HELLO AGAIN NODE.JS 0.12 - -* [`6f0c353`](https://github.com/npm/npm/commit/6f0c353e4e89b0378a4c88c829ccf9a1c5ae829d) - [`f78bde6`](https://github.com/npm/npm/commit/f78bde6983bdca63d5fcb9c220c87e8f75ffb70e) - [#14591](https://github.com/npm/npm/pull/14591) - Reintroduce Node.js 0.12 to our support matrix. We jumped the gun when - removing it. We won't drop support for it till the Node.js project does - so at the end of December 2016. - ([@othiym23](https://github.com/othiym23)) - -#### TEST/CI UPDATES - -* [`aa73d1c`](https://github.com/npm/npm/commit/aa73d1c1cc22608f95382a35b33da252addff38e) - [`c914e80`](https://github.com/npm/npm/commit/c914e80f5abcb16c572fe756c89cf0bcef4ff991) -* [`58fe064`](https://github.com/npm/npm/commit/58fe064dcc80bc08c677647832f2adb4a56b538a) - [#14602](https://github.com/npm/npm/pull/14602) - When running tests with coverage, use nyc's cache. This provides an 8x speedup! - ([@bcoe](https://github.com/bcoe)) -* [`ba091ce`](https://github.com/npm/npm/commit/ba091ce843af5d694f4540e825b095435b3558d8) - [#14435](https://github.com/npm/npm/pull/14435) - Remove an unused zero byte `package.json` found in the test fixtures. - ([@baderbuddy](https://github.com/baderbuddy)) - -#### DEPENDENCY UPDATES - -* [`442e01e`](https://github.com/npm/npm/commit/442e01e42d8a439809f6726032e3b73ac0d2b2f8) - `readable-stream@2.2.2`: - Bring in latest changes from Node.js 7.x. - ([@calvinmetcalf](https://github.com/calvinmetcalf)) -* [`bfc4a1c`](https://github.com/npm/npm/commit/bfc4a1c0c17ef0a00dfaa09beba3389598a46535) - `which@1.2.12`: - Remove unused require. - ([@isaacs](https://github.com/isaacs)) - -#### DEV DEPENDENCY UPDATES - -* [`7075b05`](https://github.com/npm/npm/commit/7075b054d8d2452bb53bee9b170498a48a0dc4e9) - `marked-man@0.1.6` - ([@kapouer](https://github.com/kapouer)) -* [`3e13fea`](https://github.com/npm/npm/commit/3e13fea907ee1141506a6de7d26cbc91c28fdb80) - `tap@8.0.0` - ([@isaacs](https://github.com/isaacs)) - -### v4.0.2 (2016-11-03) - -Hola, amigxs. I know it's been a long time since I rapped at ya, but I -been spending a lotta time quietly reflecting on all the things going on -in my life. I was, like, [in Japan for a while](https://gist.github.com/othiym23/c98bd4ef5d9fb3f496835bd481ef40ae), -and before that my swell colleagues [@zkat](https://github.com/zkat) and -[@iarna](https://github.com/iarna) have been very capably managing the release -process for quite a while. But I returned from Japan somewhat refreshed, very -jetlagged, and filled with a burning urge to get `npm@4` as stable as possible -before we push it out to the user community at large, so I decided to do this -release myself. (Also, huge thanks to Kat and Rebecca for putting out `npm@4` -so capably while I was on vacation! So cool to return to a major release having -gone so well without my involvement!) - -That said... - -#### NEVER TRUST AN X.0.0 RELEASE - -Even though 4.0.1 came out hard on the heels of 4.0.0 with a couple -critical fixes, we've found a couple other major issues that we want to -see fixed before making `npm@4` into `npm@latest`. Some of these are -arguably breaking changes on their own, so now is the time to get them -out if we're going to do so before `npm@5`, and all of them are pretty -significant blockers for a substantial number of users, so now is the -best time to fix them. - -##### PREPUBLISHONLY WHOOPS - -The code running the `publish*` lifecycle events was very confusingly written. -In fact, we didn't really figure out what it was doing until we added the new -`prepublishOnly` event and it was running people's scripts from the wrong -directory. We made it simpler. See the [commit -message](https://github.com/npm/npm/commit/8b32d67aa277fd7e62edbed886387a855f58387f) -for details. - -Because the change is no longer running publish events when publishing prebuilt -artifacts, it's technically a breaking / semver-major change. In the off chance -that the new behavior breaks any of y'all's workflows, let us know, and we can -roll some or all of this change back until `npm@5` (or forever, if that works -better for you). - -* [`8b32d67`](https://github.com/npm/npm/commit/8b32d67aa277fd7e62edbed886387a855f58387f) - [#14502](https://github.com/npm/npm/pull/14502) - Simplify lifecycle invocation and fix `prepublishOnly`. - ([@othiym23](https://github.com/othiym23)) - -##### G'BYE NODE.JS 0.10, 0.12, and 5.X; HI THERE, NODE 7 - -With the advent of the second official Node.js LTS release, Node 6.x -'Boron', the Node.js project has now officially dropped versions 0.10 -and 0.12 out of the maintenance phase of LTS. (Also, Node 5 was never -part of LTS, and will see no further support now that Node 7 has been -released.) As a small team with limited resources, the npm CLI team is -following suit and dropping those versions of Node from its CI test -matrix. - -What this means: - -* Your contributions will no longer block on the tests passing on 0.10 and 0.12. -* We will no longer block dependency upgrades on working with 0.10 and 0.12. -* Bugs filed on the npm CLI that are due to incompatibilities with 0.10 - or 0.12 (and older versions) will be closed with a strong urging to - upgrade to a supported version of Node. -* On the flip side, we'll continue to (happily!) accept patches that - address regressions seen when running the CLI with Node.js 0.10 and - 0.12. - -What this doesn't mean: - -* The CLI is going to start depending on ES2015+ features. npm continues - to work, in almost all cases, all the way back to Node.js 0.8, and our - long history of backwards compatibility is a source of pride for the - team. -* We aren't concerned about the problems of users who, for whatever - reason, can't update to newer versions of npm. As mentioned above, we're - happy to take community patches intended to address regressions. - -We're not super interested in taking sides on what version of Node.js -you "should" be running. We're a workflow tool, and we understand that -you all have a diverse set of operational environments you need to be -able to support. At the same time, we _are_ a small team, and we need -to put some limits on what we support. Tracking what's supported by our -runtime's own team seems most practical, so that's what we're doing. - -* [`ab630c9`](https://github.com/npm/npm/commit/ab630c9a7a1b40cdd4f1244be976c25ab1525907) - [#14503](https://github.com/npm/npm/pull/14503) - Node 6 is LTS; 5.x, 0.10, and 0.12 are unsupported. - ([@othiym23](https://github.com/othiym23)) -* [`731ae52`](https://github.com/npm/npm/commit/731ae526fb6e9951c43d82a26ccd357b63cc56c2) - [#14503](https://github.com/npm/npm/pull/14503) - Update supported version expression. - ([@othiym23](https://github.com/othiym23)) - -##### DISENTANGLING SCOPE - -The new `Npm-Scope` header was previously reusing the `scope` -configuration option to pass the current scope back to your current -registry (which, as [described -previously](https://github.com/npm/npm/blob/release-next/CHANGELOG.md#send-extra-headers-to-registry), is meant to set up some upcoming -registry features). It turns out that had some [seriously weird -consequences](https://github.com/npm/npm/issues/14412) in the case where -you were already configuring `scope` in your own environment. The CLI -now uses separate configuration for this. - -* [`39358f7`](https://github.com/npm/npm/commit/39358f732ded4aa46d86d593393a0d6bca5dc12a) - [#14477](https://github.com/npm/npm/pull/14477) - Differentiate registry scope from project scope in configuration. - ([@zkat](https://github.com/zkat)) - -#### SMALLER CHANGES - -* [`7f41295`](https://github.com/npm/npm/commit/7f41295775f28b958a926f9cb371cb37b05771dd) - [#14519](https://github.com/npm/npm/pull/14519) - Document that as of `npm@4.0.1`, `npm shrinkwrap` now includes `devDependencies` unless - instructed otherwise. - ([@iarna](https://github.com/iarna)) -* [`bdc2f9e`](https://github.com/npm/npm/commit/bdc2f9e255ddf1a47fd13ec8749d17ed41638b2c) - [#14501](https://github.com/npm/npm/pull/14501) - The `ENOSELF` error message is tricky to word. It's also an error that - normally bites new users. Clean it up in an effort to make it easier - to understand what's going on. - ([@snopeks](https://github.com/snopeks), [@zkat](https://github.com/zkat)) - -#### DEPENDENCY UPGRADES - -* [`a52d0f0`](https://github.com/npm/npm/commit/a52d0f0c9cf2de5caef77e12eabd7dca9e89b49c) - `glob@7.1.1`: - - Handle files without associated perms on Windows. - - Fix failing case with `absolute` option. - ([@isaacs](https://github.com/isaacs), [@phated](https://github.com/phated)) -* [`afda66d`](https://github.com/npm/npm/commit/afda66d9afcdcbae1d148f589287583c4182d124) - [isaacs/node-graceful-fs#97](https://github.com/isaacs/node-graceful-fs/pull/97) - `graceful-fs@4.1.10`: Better backoff for EPERM on Windows. - ([@sam-github](https://github.com/sam-github)) -* [`e0023c0`](https://github.com/npm/npm/commit/e0023c089ded9161fbcbe544f12b07e12e3e5729) - [npm/inflight#3](https://github.com/npm/inflight/pull/3) - `inflight@1.0.6`: Clean up even if / when a callback throws. - ([@phated](https://github.com/phated)) -* [`1d91594`](https://github.com/npm/npm/commit/1d9159440364d2fe21e8bc15e08e284aaa118347) - `request@2.78.0` - ([@othiym23](https://github.com/othiym23)) - -### v4.0.1 (2016-10-24) - -Ayyyy~ 🌊 - -So thanks to folks who were running on `npm@next`, we managed to find a few -issues of notes in that preview version, and we're rolling out a small patch -change to fix them. Most notably, anyone who was using a symlinked `node` binary -(for example, if they installed Node.js through `homebrew`), was getting a very -loud warning every time they ran scripts. Y'all should get warnings in a more -useful way, now that we're resolving those path symlinks. - -Another fairly big change that we decided to slap into this version, since -`npm@4.0.0` is never going to be `latest`, is to make it so `devDependencies` -are included in `npm-shrinkwrap.json` by default -- if you do not want this, use -`--production` with `npm shrinkwrap`. - -#### BIG FIXES/CHANGES - -* [`eff46dd`](https://github.com/npm/npm/commit/eff46dd498ed007bfa77ab7782040a3a828b852d) - [#14374](https://github.com/npm/npm/pull/14374) - Fully resolve the path for `node` executables in both `$PATH` and - `process.execPath` to avoid issues with symlinked `node`. - ([@addaleax](https://github.com/addaleax)) -* [`964f2d3`](https://github.com/npm/npm/commit/964f2d3a0675584267e6ece95b0115a53c6ca6a9) - [#14375](https://github.com/npm/npm/pull/14375) - Make including `devDependencies` in `npm-shrinkwrap.json` the default. This - should help make the transition to `npm@5` smoother in the future. - ([@iarna](https://github.com/iarna)) - -#### BUGFIXES - -* [`a5b0a8d`](https://github.com/npm/npm/commit/a5b0a8db561916086fc7dbd6eb2836c952a42a7e) - [#14400](https://github.com/npm/npm/pull/14400) - Recently, we've had some consistent timeout failures while running the test - suite under Travis. This tweak to tests should take care of those issues and - Travis should go back to being reliably green. - ([@iarna](https://github.com/iarna)) - -#### DOC PATCHES - -* [`c5907b2`](https://github.com/npm/npm/commit/c5907b2fc1a82ec919afe3b370ecd34d8895c7a2) - [#14251](https://github.com/npm/npm/pull/14251) - Update links to Node.js downloads. They previously pointed to 404 pages.😬 - ([@ArtskydJ](https://github.com/ArtskydJ)) -* [`0c122f2`](https://github.com/npm/npm/commit/0c122f24ff1d4d400975edda2b7262aaaf6f7d69) - [#14380](https://github.com/npm/npm/pull/14380) - Add note and clarification on when `prepare` script is run. Make it more - consistent with surrounding descriptions. - ([@SimenB](https://github.com/SimenB)) -* [`51a62ab`](https://github.com/npm/npm/commit/51a62abd88324ba3dad18e18ca5e741f1d60883c) - [#14359](https://github.com/npm/npm/pull/14359) - Fixes typo in `npm@4` changelog. - ([@kimroen](https://github.com/kimroen)) - -### v4.0.0 (2016-10-20) - -Welcome to `npm@4`, friends! - -This is our first semver major release since the release of `npm@3` just over a -year ago. Back then, `@3` turned out to be a bit of a ground-shaking release, -with a brand-new installer with significant structural changes to how npm set up -your tree. This is the end of an era, in a way. `npm@4` also marks the release -when we move *both* `npm@2` and `npm@3` into maintenance: We will no longer be -updating those release branches with anything except critical bugfixes and -security patches. - -While its predecessor had some pretty serious impaact, `npm@4` is expected to -have a much smaller effect on your day-to-day use of npm. Over the past year, -we've collected a handful of breaking changes that we wanted to get in which are -only breaking under a strict semver interpretation (which we follow). Some of -these are simple usability improvements, while others fix crashes and serious -issues that required a major release to include. - -We hope this release sees you well, and you can look forward to an accelerated -release pace now that the CLI team is done focusing on sustaining work -- our -Windows fixing and big bugs pushes -- and we can start focusing again on -usability, features, and performance. Keep an eye out for `npm@5` in Q1 2017, -too: We're planning a major overhaul of `shrinkwrap` as well as various speed -and usability fixes for that release. It's gonna be a fun ride. I promise. 😘 - -#### BRIEF OVERVIEW OF **BREAKING** CHANGES - -The following breaking changes are included in this release: - -* `npm search` rewritten to stream results, and no longer supports sorting. -* `npm scripts` no longer prepend the path of the node executable used to run - npm before running scripts. A `--scripts-prepend-node-path` option has been - added to configure this behavior. -* `npat` has been removed. -* `prepublish` has been deprecated, replaced by `prepare`. A `prepublishOnly` - script has been temporarily added, which will *only* run on `npm publish`. -* `npm outdated` exits with exit code `1` if it finds any outdated packages. -* `npm tag` has been removed after a deprecation cycle. Use `npm dist-tag`. -* Partial shrinkwraps are no longer supported. `npm-shrinkwrap.json` is - considered a complete installation manifest except for `devDependencies`. -* npm's default git branch is no longer `master`. We'll be using `latest` from - now on. - -#### SEARCH REWRITE (**BREAKING**) - -Let's face it -- `npm search` simply doesn't work anymore. Apart from the fact -that it grew slower over the years, it's reached a point where we can no longer -fit the entire registry metadata in memory, and anyone who tries to use the -command now sees a really awful memory overflow crash from node. - -It's still going to be some time before the CLI, registry, and web team are able -to overhaul `npm search` altogether, but until then, we've rewritten the -previous `npm search` implementation to *stream* results on the fly, from both -the search endpoint and a local cache. In absolute terms, you won't see a -performance increase and this patch *does* come at the cost of sorting -capabilities, but what it does do is start outputting results as it finds them. -This should make the experience much better, overall, and we believe this is an -acceptable band-aid until we have that search endpoint in place. - -Incidentally, if you want a really nice search experience, we recommend checking -out [npms.io](http://npms.io), which includes a handy-dandy -[`npms-cli`](https://npm.im/npms-cli) for command-line usage -- it's an npm -search site that returns high-quality results quickly and is operated by members -of the npm community. - -* [`cfd43b4`](https://github.com/npm/npm/commit/cfd43b49aed36d0e8ea6c35b07ed8b303b69be61) [`2b8057b`](https://github.com/npm/npm/commit/2b8057be2e1b51e97b1f8f38d7f58edf3ce2c145) - [#13746](https://github.com/npm/npm/pull/13746) - Stream search process end-to-end. - ([@zkat](https://github.com/zkat) and [@aredridel](https://github.com/aredridel)) -* [`50f4ec8`](https://github.com/npm/npm/commit/50f4ec8e8ce642aa6a58cb046b2b770ccf0029db) [`70b4bc2`](https://github.com/npm/npm/commit/70b4bc22ec8e81cd33b9448f5b45afd1a50d50ba) [`8fb470f`](https://github.com/npm/npm/commit/8fb470fe755c4ad3295cb75d7b4266f8e67f8d38) [`ac3a6e0`](https://github.com/npm/npm/commit/ac3a6e0eba61fb40099b1370c74ad1598777def4) [`bad54dd`](https://github.com/npm/npm/commit/bad54dd9f1119fe900a8d065f8537c6f1968b589) [`87d504e`](https://github.com/npm/npm/commit/87d504e0a61bccf09f5e975007d018de3a1c5f50) - [#13746](https://github.com/npm/npm/pull/13746) - Updated search-related tests. - ([@zkat](https://github.com/zkat)) -* [`3596de8`](https://github.com/npm/npm/commit/3596de88598c69eb5bae108703c8e74ca198b20c) - [#13746](https://github.com/npm/npm/pull/13746) - `JSONStream@1.2.1` - ([@zkat](https://github.com/zkat)) -* [`4b09209`](https://github.com/npm/npm/commit/4b09209bb605f547243065032a8b37772669745f) - [#13746](https://github.com/npm/npm/pull/13746) - `mississippi@1.2.0` - ([@zkat](https://github.com/zkat)) -* [`b650b39`](https://github.com/npm/npm/commit/b650b39d42654abb9eed1c7cd463b1c595ca2ef9) - [#13746](https://github.com/npm/npm/pull/13746) - `sorted-union-stream@2.1.3` - ([@zkat](https://github.com/zkat)) - -#### SCRIPT NODE PATH (**BREAKING**) - -Thanks to some great work by [@addaleax](https://github.com/addaleax), we've -addressed a fairly tricky issue involving the node process used by `npm -scripts`. - -Previously, npm would prefix the path of the node executable to the script's -`PATH`. This had the benefit of making sure that the node process would be the -same for both npm and `scripts` unless you had something like -[`node-bin`](https://npm.im/node-bin) in your `node_modules`. And it turns out -lots of people relied on this behavior being this way! - -It turns out that this had some unintended consequences: it broke systems like -[`nyc`](https://npm.im/nyc), but also completely broke/defeated things like -[`rvm`](https://rvm.io/) and -[`virtualenv`](https://virtualenv.pypa.io/en/stable/) by often causing things -that relied on them to fall back to the global system versions of ruby and -python. - -In the face of two perfectly valid, and used alternatives, we decided that the -second case was much more surprising for users, and that we should err on the -side of doing what those users expect. Anna put some hard work in and managed to -put together a patch that changes npm's behavior such that we no longer prepend -the node executable's path *by default*, and adds a new option, -`--scripts-prepend-node-path`, to allow users who rely on this behavior to have -it add the node path for them. - -This patch also makes it so this feature is discoverable by people who might run -into the first case above, by warning if the node executable is either missing -or shadowed by another one in `PATH`. This warning can also be disabled with the -`--scripts-prepend-node-path` option as needed. - -* [`3fb1eb3`](https://github.com/npm/npm/commit/3fb1eb3e00b5daf37f14e437d2818e9b65a43392) [`6a7d375`](https://github.com/npm/npm/commit/6a7d375d779ba5416fd5df154c6da673dd745d9d) [`378ae08`](https://github.com/npm/npm/commit/378ae08851882d6d2bc9b631b16b8c875d0b9704) - [#13409](https://github.com/npm/npm/pull/13409) - Add a `--scripts-prepend-node-path` option to configure whether npm prepends - the current node executable's path to `PATH`. - ([@addaleax](https://github.com/addaleax)) -* [`70b352c`](https://github.com/npm/npm/commit/70b352c6db41533b9a4bfaa9d91f7a2a1178f74e) - [#13409](https://github.com/npm/npm/pull/13409) - Change the default behaviour of npm to never prepending the current node - executable’s directory to `PATH` but printing a warning in the cases in which - it previously did. - ([@addaleax](https://github.com/addaleax)) - -#### REMOVE `npat` (**BREAKING**) - -Let's be real here -- almost no one knows this feature ever existed, and it's a -vestigial feature of the days when the ideal for npm was to distribute full -packages that could be directly developed on, even from the registry. - -It turns out the npm community decided to go a different way: primarily -publishing packages in a production-ready format, with no tests, build tools, -etc. And so, we say goodbye to `npat`. - -* [`e16c14a`](https://github.com/npm/npm/commit/e16c14afb6f52cb8b7adf60b2b26427f76773f2e) - [#14329](https://github.com/npm/npm/pull/14329) - Remove the npat feature. - ([@iarna](https://github.com/iarna)) - -#### NEW `prepare` SCRIPT. `prepublish` DEPRECATED (**BREAKING**) - -If there's anything that really seemed to confuse users, it's that the -`prepublish` script ran when invoking `npm install` without any arguments. - -Turns out many, many people really expected that it would only run on `npm -publish`, even if it actually did what most people expected: prepare the package -for publishing on the registry. - -And so, we've added a `prepare` command that runs in the exact same cases where -`prepublish` ran, and we've begun a deprecation cycle for `prepublish` itself -**only when run by `npm install`**, which will now include a warning any time -you use it that way. - -We've also added a `prepublishOnly` script which will execute **only** when `npm -publish` is invoked. Eventually, `prepublish` will stop executing on `npm -install`, and `prepublishOnly` will be removed, leaving `prepare` and -`prepublish` as two distinct lifecycles. - -* [`9b4a227`](https://github.com/npm/npm/commit/9b4a2278cee0a410a107c8ea4d11614731e0a943) [`bc32078`](https://github.com/npm/npm/commit/bc32078fa798acef0e036414cb448645f135b570) - [#14290](https://github.com/npm/npm/pull/14290) - Add `prepare` and `prepublishOnly` lifecycle events. - ([@othiym23](https://github.com/othiym23)) -* [`52fdefd`](https://github.com/npm/npm/commit/52fdefddb48f0c39c6e8eb4c118eb306c9436117) - [#14290](https://github.com/npm/npm/pull/14290) - Warn when running `prepublish` on `npm pack`. - ([@othiym23](https://github.com/othiym23)) -* [`4c2a948`](https://github.com/npm/npm/commit/4c2a9481b564cae3df3f4643766db4b987018a7b) [`a55bd65`](https://github.com/npm/npm/commit/a55bd651284552b93f7d972a2e944f65c1aa6c35) - [#14290](https://github.com/npm/npm/pull/14290) - Added `prepublish` warnings to `npm install`. - ([@zkat](https://github.com/zkat)) -* [`c27412b`](https://github.com/npm/npm/commit/c27412bb9fc7b09f7707c7d9ad23128959ae1abc) - [#14290](https://github.com/npm/npm/pull/14290) - Replace `prepublish` with `prepare` in `npm help package.json` documentation. - ([@zkat](https://github.com/zkat)) - -#### NO MORE PARTIAL SHRINKWRAPS (**BREAKING**) - -That's right. No more partial shrinkwraps. That means that if you have an -`npm-shrinkwrap.json` in your project, npm will no longer install anything that -isn't explicitly listed there, unless it's a `devDependency`. This will open -doors to some nice optimizations and make use of `npm shrinkwrap` just generally -smoother by removing some awful corner cases. We will also skip `devDependency` -installation from `package.json` if you added `devDependencies` to your -shrinkwrap by using `npm shrinkwrap --dev`. - -* [`b7dfae8`](https://github.com/npm/npm/commit/b7dfae8fd4dc0456605f7a921d20a829afd50864) - [#14327](https://github.com/npm/npm/pull/14327) - Use `readShrinkwrap` to read top level shrinkwrap. There's no reason for npm - to be doing its own bespoke heirloom-grade artisanal thing here. - ([@iarna](https://github.com/iarna)) -* [`0ae1f4b`](https://github.com/npm/npm/commit/0ae1f4b9d83af2d093974beb33f26d77fcc95bb9) [`4a54997`](https://github.com/npm/npm/commit/4a549970dc818d78b6de97728af08a1edb5ae7f0) [`f22a1ae`](https://github.com/npm/npm/commit/f22a1ae54b5d47f1a056a6e70868013ebaf66b79) [`3f61189`](https://github.com/npm/npm/commit/3f61189cb3843fee9f54288fefa95ade9cace066) - [#14327](https://github.com/npm/npm/pull/14327) - Treat shrinkwrap as canonical. That is, don't try to fill in for partial - shrinkwraps. Partial shrinkwraps should produce partial installs. If your - shrinkwrap contains NO `devDependencies` then we'll still try to install them - from your `package.json` instead of assuming you NEVER want `devDependencies`. - ([@iarna](https://github.com/iarna)) - -#### `npm tag` REMOVED (**BREAKING**) - -* [`94255da`](https://github.com/npm/npm/commit/94255da8ffc2d9ed6a0434001a643c1ad82fa483) - [#14328](https://github.com/npm/npm/pull/14328) - Remove deprecated tag command. Folks must use the `dist-tag` command from now - on. - ([@iarna](https://github.com/iarna)) - -#### NON-ZERO EXIT CODE ON OUTDATED DEPENDENCIES (**BREAKING**) - -* [`40a04d8`](https://github.com/npm/npm/commit/40a04d888d10a5952d5ca4080f2f5d2339d2038a) [`e2fa18d`](https://github.com/npm/npm/commit/e2fa18d9f7904eb048db7280b40787cb2cdf87b3) [`3ee3948`](https://github.com/npm/npm/commit/3ee39488b74c7d35fbb5c14295e33b5a77578104) [`3fa25d0`](https://github.com/npm/npm/commit/3fa25d02a8ff07c42c595f84ae4821bc9ee908df) - [#14013](https://github.com/npm/npm/pull/14013) - Do `exit 1` if any outdated dependencies are found by `npm outdated`. - ([@watilde](https://github.com/watilde)) -* [`c81838a`](https://github.com/npm/npm/commit/c81838ae96b253f4b1ac66af619317a3a9da418e) - [#14013](https://github.com/npm/npm/pull/14013) - Log non-zero exit codes at `verbose` level -- this isn't something command - line tools tend to do. It's generally the shell's job to display, if at all. - ([@zkat](https://github.com/zkat)) - -#### SEND EXTRA HEADERS TO REGISTRY - -For the purposes of supporting shiny new registry features, we've started -sending `Npm-Scope` and `Npm-In-CI` headers in outgoing requests. - -* [`846f61c`](https://github.com/npm/npm/commit/846f61c1dd4a033f77aa736ab01c27ae6724fe1c) - [npm/npm-registry-client#145](https://github.com/npm/npm-registry-client/pull/145) - [npm/npm-registry-client#147](https://github.com/npm/npm-registry-client/pull/147) - `npm-registry-client@7.3.0`: - * Allow npm to add headers to outgoing requests. - * Add `Npm-In-CI` header that reports whether we're running in CI. - ([@iarna](https://github.com/iarna)) -* [`6b6bb08`](https://github.com/npm/npm/commit/6b6bb08af661221224a81df8adb0b72019ca3e11) - [#14129](https://github.com/npm/npm/pull/14129) - Send `Npm-Scope` header along with requests to registry. `Npm-Scope` is set to - the `@scope` of the current top level project. This will allow registries to - implement user/scope-aware features and services. - ([@iarna](https://github.com/iarna)) -* [`506de80`](https://github.com/npm/npm/commit/506de80dc0a0576ec2aab0ed8dc3eef3c1dabc23) - [#14129](https://github.com/npm/npm/pull/14129) - Add test to ensure `Npm-In-CI` header is being sent when CI is set in env. - ([@iarna](https://github.com/iarna)) - -#### BUGFIXES - -* [`bc84012`](https://github.com/npm/npm/commit/bc84012c2c615024b08868acbd8df53a7ca8d146) - [#14117](https://github.com/npm/npm/pull/14117) - Fixes a bug where installing a shrinkwrapped package would fail if the - platform failed to install an optional dependency included in the shrinkwrap. - ([@watilde](https://github.com/watilde)) -* [`a40b32d`](https://github.com/npm/npm/commit/a40b32dc7fe18f007a672219a12d6fecef800f9d) - [#13519](https://github.com/npm/npm/pull/13519) - If a package has malformed metadata, `node.requiredBy` is sometimes missing. - Stop crashing when that happens. - ([@creationix](https://github.com/creationix)) - -#### OTHER PATCHES - -* [`643dae2`](https://github.com/npm/npm/commit/643dae2197c56f1c725ecc6539786bf82962d0fe) - [#14244](https://github.com/npm/npm/pull/14244) - Remove some ancient aliases that we'd rather not have around. - ([@zkat](https://github.com/zkat)) -* [`bdeac3e`](https://github.com/npm/npm/commit/bdeac3e0fb226e4777d4be5cd3c3bec8231c8044) - [#14230](https://github.com/npm/npm/pull/14230) - Detect unsupported Node.js versions and warn about it. Also error on really - old versions where we know we can't work. - ([@iarna](https://github.com/iarna)) - -#### DOC UPDATES - -* [`9ca18ad`](https://github.com/npm/npm/commit/9ca18ada7cc1c10b2d32bbb59d5a99dd1c743109) - [#13746](https://github.com/npm/npm/pull/13746) - Updated docs for `npm search` options. - ([@zkat](https://github.com/zkat)) -* [`e02a47f`](https://github.com/npm/npm/commit/e02a47f9698ff082488dc2b1738afabb0912793e) - Move the `npm@3` changelog into the archived changelogs directory. - ([@zkat](https://github.com/zkat)) -* [`c12bbf8`](https://github.com/npm/npm/commit/c12bbf8c5a5dff24a191b66ac638f552bfb76601) - [#14290](https://github.com/npm/npm/pull/14290) - Document prepublish-on-install deprecation. - ([@othiym23](https://github.com/othiym23)) -* [`c246a75`](https://github.com/npm/npm/commit/c246a75ac8697f4ca11d316b7e7db5f24af7972b) - [#14129](https://github.com/npm/npm/pull/14129) - Document headers added by npm to outgoing registry requests. - ([@iarna](https://github.com/iarna)) - -#### DEPENDENCIES - -* [`cb20c73`](https://github.com/npm/npm/commit/cb20c7373a32daaccba2c1ad32d0b7e1fc01a681) - [#13953](https://github.com/npm/npm/pull/13953) - `signal-exit@3.0.1` - ([@benjamincoe](https://github.com/benjamincoe)) diff --git a/changelogs/CHANGELOG-5.md b/changelogs/CHANGELOG-5.md deleted file mode 100644 index ea8331b..0000000 --- a/changelogs/CHANGELOG-5.md +++ /dev/null @@ -1,2360 +0,0 @@ -## v5.10.0 (2018-05-10): - -### AUDIT SHOULDN'T WAIT FOREVER - -This will likely be reduced further with the goal that the audit process -shouldn't noticibly slow down your builds regardless of your network -situation. - -* [`3dcc240db`](https://github.com/npm/npm/commit/3dcc240dba5258532990534f1bd8a25d1698b0bf) - Timeout audit requests eventually. - ([@iarna](https://github.com/iarna)) - - -## v5.10.0-next.1 (2018-05-07): - -### EXTENDED `npm init` SCAFFOLDING - -Thanks to the wonderful efforts of [@jdalton](https://github.com/jdalton) of -lodash fame, `npm init` can now be used to invoke custom scaffolding tools! - -You can now do things like `npm init react-app` or `npm init esm` to scaffold an -npm package by running `create-react-app` and `create-esm`, respectively. This -also adds an `npm create` alias, to correspond to Yarn's `yarn create` feature, -which inspired this. - -* [`adc009ed4`](https://github.com/npm/npm/commit/adc009ed4114ed1e692f8ef15123af6040615cee) - [`f363edd04`](https://github.com/npm/npm/commit/f363edd04f474fa64e4d97228c0b2a7858f21e7c) - [`f03b45fb2`](https://github.com/npm/npm/commit/f03b45fb217df066c3cb7715f9c0469d84e5aa8e) - [`13adcbb52`](https://github.com/npm/npm/commit/13adcbb527fb8214e5f2233706c6b72ce072f3fa) - [#20303](https://github.com/npm/npm/pull/20303) - [#20372](https://github.com/npm/npm/pull/20372) - Add an `npm init` feature that calls out to `npx` when invoked with positional - arguments. ([@jdalton](https://github.com/jdalton)) - -### DEPENDENCY AUDITING - -This version of npm adds a new command, `npm audit`, which will run a security -audit of your project's dependency tree and notify you about any actions you may -need to take. - -The registry-side services required for this command to work will be available -on the main npm registry in the coming weeks. Until then, you won't get much out -of trying to use this on the CLI. - -As part of this change, the npm CLI now sends scrubbed and cryptographically -anonymized metadata about your dependency tree to your configured registry, to -allow notifying you about the existence of critical security flaws. For details -about how the CLI protects your privacy when it shares this metadata, see `npm -help audit`, or [read the docs for `npm audit` -online](https://github.com/npm/npm/blob/release-next/doc/cli/npm-audit.md). You -can disable this altogether by doing `npm config set audit false`, but will no -longer benefit from the service. - -* [`c81dfb91b`](https://github.com/npm/npm/commit/c81dfb91bc031f1f979fc200bb66718a7e8e1551) - `npm-registry-fetch@1.1.1` - ([@iarna](https://github.com/iarna)) -* [`b096f44a9`](https://github.com/npm/npm/commit/b096f44a96d185c45305b9b6a5f26d3ccbbf759d) - `npm-audit-report@1.0.9` - ([@iarna](https://github.com/iarna)) -* [`43b20b204`](https://github.com/npm/npm/commit/43b20b204ff9a86319350988d6774397b7da4593) - [#20389](https://github.com/npm/npm/pull/20389) - Add new `npm audit` command. - ([@iarna](https://github.com/iarna)) -* [`49ddb3f56`](https://github.com/npm/npm/commit/49ddb3f5669e90785217a639f936f4e38390eea2) - [#20389](https://github.com/npm/npm/pull/20389) - Temporarily suppress git metadata till there's an opt-in. - ([@iarna](https://github.com/iarna)) -* [`5f1129c4b`](https://github.com/npm/npm/commit/5f1129c4b072172c72cf9cff501885e2c11998ea) - [#20389](https://github.com/npm/npm/pull/20389) - Document the new command. - ([@iarna](https://github.com/iarna)) -* [`9a07b379d`](https://github.com/npm/npm/commit/9a07b379d24d089687867ca34df6e1e6189c72f1) - [#20389](https://github.com/npm/npm/pull/20389) - Default audit to off when running the npm test suite itself. - ([@iarna](https://github.com/iarna)) -* [`a6e2f1284`](https://github.com/npm/npm/commit/a6e2f12849b84709d89b3dc4f096e8c6f7db7ebb) - Make sure we hide stream errors on background audit submissions. Previously some classes - of error could end up being displayed (harmlessly) during installs. - ([@iarna](https://github.com/iarna)) -* [`aadbf3f46`](https://github.com/npm/npm/commit/aadbf3f4695e75b236ee502cbe41e51aec318dc3) - Include session and scope in requests (as we do in other requests to the registry). - ([@iarna](https://github.com/iarna)) -* [`7d43ddf63`](https://github.com/npm/npm/commit/7d43ddf6366d3bfc18ea9ccef8c7b8e43d3b79f5) - Exit with non-zero status when vulnerabilities are found. So you can have `npm audit` as a test or prepublish step! - ([@iarna](https://github.com/iarna)) -* [`bc3fc55fa`](https://github.com/npm/npm/commit/bc3fc55fae648da8efaf1be5b86078f0f736282e) - Verify lockfile integrity before running. You'd get an error either way, but this way it's - faster and can give you more concrete instructions on how to fix it. - ([@iarna](https://github.com/iarna)) -* [`2ac8edd42`](https://github.com/npm/npm/commit/2ac8edd4248f2393b35896f0300b530e7666bb0e) - Refuse to run in global mode. Audits require a lockfile and globals don't have one. Yet. - ([@iarna](https://github.com/iarna)) - -### CTRL-C OUT DURING PACKAGE EXTRACTION AS MUCH AS YOU WANT! - -* [`663d8b5e5`](https://github.com/npm/npm/commit/663d8b5e5427c2243149d2dd6968faa117e9db3f) - [npm/lockfile#29](https://github.com/npm/lockfile/pull/29) - `lockfile@1.0.4`: - Switches to `signal-exit` to detect abnormal exits and remove locks. - ([@Redsandro](https://github.com/Redsandro)) - -### SHRONKWRAPS AND LACKFILES - -If a published modules had legacy `npm-shrinkwrap.json` we were saving -ordinary registry dependencies (`name@version`) to your `package-lock.json` -as `https://` URLs instead of versions. - -* [`36f998411`](https://github.com/npm/npm/commit/36f9984113e39d7b190010a2d0694ee025924dcb) - When saving the lock-file compute how the dependency is being required instead of using - `_resolved` in the `package.json`. This fixes the bug that was converting - registry dependencies into `https://` dependencies. - ([@iarna](https://github.com/iarna)) -* [`113e1a3af`](https://github.com/npm/npm/commit/113e1a3af2f487c753b8871d51924682283c89fc) - When encountering a `https://` URL in our lockfiles that point at our default registry, extract - the version and use them as registry dependencies. This lets us heal - `package-lock.json` files produced by 6.0.0 - ([@iarna](https://github.com/iarna)) - -### MORE `package-lock.json` FORMAT CHANGES?! - -* [`074502916`](https://github.com/npm/npm/commit/0745029168dfdfee0d1823137550e6ebccf741a5) - [#20384](https://github.com/npm/npm/pull/20384) - Add `from` field back into package-lock for git dependencies. This will give - npm the information it needs to figure out whether git deps are valid, - specially when running with legacy install metadata or in - `--package-lock-only` mode when there's no `node_modules`. This should help - remove a significant amount of git-related churn on the lock-file. - ([@zkat](https://github.com/zkat)) - -### DOCUMENTATION IMPROVEMENTS - -* [`e0235ebb6`](https://github.com/npm/npm/commit/e0235ebb6e560f0114b8babedb6949385ab9bd57) - [#20384](https://github.com/npm/npm/pull/20384) - Update the lock-file spec doc to mention that we now generate the from field for `git`-type dependencies. - ([@watilde](https://github.com/watilde)) -* [`35de04676`](https://github.com/npm/npm/commit/35de04676a567ef11e1dd031d566231021d8aff2) - [#20408](https://github.com/npm/npm/pull/20408) - Describe what the colors in outdated mean. - ([@teameh](https://github.com/teameh)) - -### BUGFIXES - -* [`1b535cb9d`](https://github.com/npm/npm/commit/1b535cb9d4a556840aeab2682cc8973495c9919a) - [#20358](https://github.com/npm/npm/pull/20358) - `npm install-test` (aka `npm it`) will no longer generate `package-lock.json` - when running with `--no-package-lock` or `package-lock=false`. - ([@raymondfeng](https://github.com/raymondfeng)) -* [`268f7ac50`](https://github.com/npm/npm/commit/268f7ac508cda352d61df63a2ae7148c54bdff7c) - [`5f84ebdb6`](https://github.com/npm/npm/commit/5f84ebdb66e35486d1dec1ca29e9ba0e4c5b6d5f) - [`c12e61431`](https://github.com/npm/npm/commit/c12e61431ecf4f77e56dc8aa55c41d5d7eeaacad) - [#20390](https://github.com/npm/npm/pull/20390) - Fix a scenario where a git dependency had a comittish associated with it - that was not a complete commitid. `npm` would never consider that entry - in the `package.json` as matching the entry in the `package-lock.json` and - this resulted in inappropriate pruning or reinstallation of git - dependencies. This has been addressed in two ways, first, the addition of the - `from` field as described in [#20384](https://github.com/npm/npm/pull/20384) means - we can exactly match the `package.json`. Second, when that's missing (when working with - older `package-lock.json` files), we assume that the match is ok. (If - it's not, we'll fix it up when a real installation is done.) - ([@iarna](https://github.com/iarna)) - -### DOCS - -* [`7b13bf5e3`](https://github.com/npm/npm/commit/7b13bf5e373e2ae2466ecaa3fd6dcba67a97f462) - [#20331](https://github.com/npm/npm/pull/20331) - Fix broken link to 'private-modules' page. The redirect went away when the new - npm website went up, but the new URL is better anyway. - ([@vipranarayan14](https://github.com/vipranarayan14)) -* [`1c4ffddce`](https://github.com/npm/npm/commit/1c4ffddce05c25ef51e254dfc6a9a97e03c711ce) - [#20279](https://github.com/npm/npm/pull/20279) - Document the `--if-present` option for `npm run-script`. - ([@aleclarson](https://github.com/aleclarson)) - -### DEPENDENCY UPDATES - -* [`815d91ce0`](https://github.com/npm/npm/commit/815d91ce0e8044775e884c1dab93052da57f6650) - `libnpx@10.2.0` - ([@zkat](https://github.com/zkat)) -* [`02715f19f`](https://github.com/npm/npm/commit/02715f19fbcdecec8990b92fc60b1a022c59613b) - `update-notifier@2.5.0` - ([@alexccl](https://github.com/alexccl)) -* [`08c4ddd9e`](https://github.com/npm/npm/commit/08c4ddd9eb560aa6408a1bb1c1d2d9aa6ba46ba0) - `tar@4.4.2` - ([@isaacs](https://github.com/isaacs)) -* [`53718cb12`](https://github.com/npm/npm/commit/53718cb126956851850839b4d7d3041d4e9a80d0) - `tap@11.1.4` - ([@isaacs](https://github.com/isaacs)) -* [`0a20cf546`](https://github.com/npm/npm/commit/0a20cf546a246ac12b5fe2b6235ffb8649336ec4) - `safe-buffer@5.1.2` - ([@feross](https://github.com/feross)) -* [`e8c8e844c`](https://github.com/npm/npm/commit/e8c8e844c194351fe2d65cf3af79ef318bbc8bec) - `retry@0.12.0` - ([@tim-kos](https://github.com/tim-kos)) -* [`76c7f21bd`](https://github.com/npm/npm/commit/76c7f21bd04407d529edc4a76deaa85a2d6b6e6f) - `read-package-tree@5.2.1` - ([@zkat](https://github.com/zkat)) -* [`c8b0aa07b`](https://github.com/npm/npm/commit/c8b0aa07b34a0b0f8bc85154da75d9fb458eb504) - `query-string@6.1.0` - ([@sindresorhus](https://github.com/sindresorhus)) -* [`abfd366b4`](https://github.com/npm/npm/commit/abfd366b4709325f954f2b1ee5bd475330aab828) - `npm-package-arg@6.1.0` - ([@zkat](https://github.com/zkat)) -* [`bd29baf83`](https://github.com/npm/npm/commit/bd29baf834c3e16a9b3d7b60cdb4f462889800bf) - `lock-verify@2.0.2` - ([@iarna](https://github.com/iarna)) - -## v5.10.0-next.0 (2018-04-12): - -### NEW FEATURES - -* [`32ec2f54b`](https://github.com/npm/npm/commit/32ec2f54b2ad7370f2fd17e6e2fbbb2487c81266) - [#20257](https://github.com/npm/npm/pull/20257) - Add shasum and integrity to the new `npm view` output. - ([@zkat](https://github.com/zkat)) -* [`a22153be2`](https://github.com/npm/npm/commit/a22153be239dfd99d87a1a1c7d2c3700db0bebf3) - [#20126](https://github.com/npm/npm/pull/20126) - Add `npm cit` command that's equivalent of `npm ci && npm t` that's equivalent of `npm it`. - ([@SimenB](https://github.com/SimenB)) - -### BUG FIXES - -* [`089aeaf44`](https://github.com/npm/npm/commit/089aeaf4479f286b1ce62716c6442382ff0f2150) - Fix a bug where OTPs passed in via the commandline would have leading - zeros deleted resulted in authentication failures. - ([@iarna](https://github.com/iarna)) -* [`6eaa860ea`](https://github.com/npm/npm/commit/6eaa860ead3222a6dbd6d370b4271e7bf242b30b) - Eliminate direct use of `new Buffer` in `npm`. While the use of it in `npm` was safe, there - are two other reasons for this change: - - 1. Node 10 emits warnings about its use. - 2. Users who require npm as a library (which they definitely should not do) - can call the functions that call `new Buffer` in unsafe ways, if they try - really hard. - - ([@iarna](https://github.com/iarna)) - -* [`85900a294`](https://github.com/npm/npm/commit/85900a2944fed14bc8f59c48856fb797faaafedc) - Starting with 5.8.0 the `requires` section of the lock-file saved version ranges instead of - specific versions. Due to a bug, further actions on the same lock-file would result in the - range being switched back to a version. This corrects that, keeping ranges when they appear. - ([@iarna](https://github.com/iarna)) -* [`0dffa9c2a`](https://github.com/npm/npm/commit/0dffa9c2ae20b669f65c8e596dafd63e52248250) - [`609d6f6e1`](https://github.com/npm/npm/commit/609d6f6e1b39330b64ca4677a531819f2143a283) - [`08f81aa94`](https://github.com/npm/npm/commit/08f81aa94171987a8e1b71a87034e7b028bb9fc7) - [`f8b76e076`](https://github.com/npm/npm/commit/f8b76e0764b606e2c129cbaa66e48ac6a3ebdf8a) - [`6d609822d`](https://github.com/npm/npm/commit/6d609822d00da7ab8bd05c24ec4925094ecaef53) - [`59d080a22`](https://github.com/npm/npm/commit/59d080a22f7314a8e4df6e4f85c84777c1e4be42) - Restore the ability to bundle dependencies that are uninstallable from the - registry. This also eliminates needless registry lookups for bundled - dependencies. - - Fixed a bug where attempting to install a dependency that is bundled - inside another module without reinstalling that module would result in - ENOENT errors. - ([@iarna](https://github.com/iarna)) -* [`db846c2d5`](https://github.com/npm/npm/commit/db846c2d57399f277829036f9d96cd767088097e) - [#20029](https://github.com/npm/npm/pull/20029) - Allow packages with non-registry specifiers to follow the fast path that - the we use with the lock-file for registry specifiers. This will improve install time - especially when operating only on the package-lock (`--package-lock-only`). - - ([@zkat](https://github.com/zkat)) - - Fix the a bug where `npm i --only=prod` could remove development - dependencies from lock-file. - ([@iarna](https://github.com/iarna)) -* [`3e12d2407`](https://github.com/npm/npm/commit/3e12d2407446661d3dd226b03a2b6055b7932140) - [#20122](https://github.com/npm/npm/pull/20122) - Improve the update-notifier messaging (borrowing ideas from pnpm) and - eliminate false positives. - ([@zkat](https://github.com/zkat)) -* [`f18be9b39`](https://github.com/npm/npm/commit/f18be9b39888d05c7f98946c53214f40914f6284) - [#20154](https://github.com/npm/npm/pull/20154) - Let version succeed when `package-lock.json` is gitignored. - ([@nwoltman](https://github.com/nwoltman)) -* [`ced29253d`](https://github.com/npm/npm/commit/ced29253df6c6d67e4bf47ca83e042db4fb19034) - [#20212](https://github.com/npm/npm/pull/20212) - Ensure that we only create an `etc` directory if we are actually going to write files to it. - ([@buddydvd](https://github.com/buddydvd)) -* [`8e21b19a8`](https://github.com/npm/npm/commit/8e21b19a8c5e7d71cb51f3cc6a8bfaf7749ac2c5) - [#20140](https://github.com/npm/npm/pull/20140) - Note in documentation that `package-lock.json` version gets touched by `npm version`. - ([@srl295](https://github.com/srl295)) -* [`5d17c87d8`](https://github.com/npm/npm/commit/5d17c87d8d27caeac71f291fbd62628f2765fda2) - [#20032](https://github.com/npm/npm/pull/20032) - Fix bug where unauthenticated errors would get reported as both 404s and - 401s, i.e. `npm ERR! 404 Registry returned 401`. In these cases the error - message will now be much more informative. - ([@iarna](https://github.com/iarna)) -* [`05ff6c9b1`](https://github.com/npm/npm/commit/05ff6c9b14cb095988b768830e51789d6b6b8e6e) - [#20082](https://github.com/npm/npm/pull/20082) - Allow optional @ prefix on scope with `npm team` commands for parity with other commands. - ([@bcoe](https://github.com/bcoe)) -* [`6bef53891`](https://github.com/npm/npm/commit/6bef538919825b8cd2e738333bdd7b6ca2e2e0e3) - [#19580](https://github.com/npm/npm/pull/19580) - Improve messaging when two-factor authentication is required while publishing. - ([@jdeniau](https://github.com/jdeniau)) -* [`155dab2bd`](https://github.com/npm/npm/commit/155dab2bd7b06724eca190abadd89c9f03f85446) - Fix a bug where optional status of a dependency was not being saved to - the package-lock on the initial install. - ([@iarna](https://github.com/iarna)) -* [`8d6a4cafc`](https://github.com/npm/npm/commit/8d6a4cafc2e6963d9ec7c828e1af6f2abc12e7f3) - [`a0937e9af`](https://github.com/npm/npm/commit/a0937e9afe126dce7a746c1a6270b1ac69f2a9b3) - Ensure that `--no-optional` does not remove optional dependencies from the lock-file. - ([@iarna](https://github.com/iarna)) - -### DEPENDENCY UPDATES - -* [`8baa37551`](https://github.com/npm/npm/commit/8baa37551945bc329a6faf793ec5e3e2feff489b) - [zkat/cipm#46](https://github.com/zkat/cipm/pull/46) - `libcipm@1.6.2`: - Detect binding.gyp for default install lifecycle. Let's `npm ci` work on projects that - have their own C code. - ([@caleblloyd](https://github.com/caleblloyd)) -* [`323f74242`](https://github.com/npm/npm/commit/323f74242066c989f7faf94fb848ff8f3b677619) - [zkat/json-parse-better-errors#1](https://github.com/zkat/json-parse-better-errors/pull/1) - `json-parse-better-errors@1.0.2` - ([@Hoishin](https://github.com/Hoishin)) -* [`d0cf1f11e`](https://github.com/npm/npm/commit/d0cf1f11e5947446f74881a3d15d6a504baea619) - `readable-stream@2.3.6` - ([@mcollina](https://github.com/mcollina)) -* [`9e9fdba5e`](https://github.com/npm/npm/commit/9e9fdba5e7b7f3a1dd73530dadb96d9e3445c48d) - `update-notifier@2.4.0` - ([@sindersorhus](https://github.com/sindersorhus)) -* [`57fa33870`](https://github.com/npm/npm/commit/57fa338706ab122ab7e13d2206016289c5bdacf3) - `marked@0.3.1` - ([@joshbruce](https://github.com/joshbruce)) -* [`d2b20d34b`](https://github.com/npm/npm/commit/d2b20d34b60f35eecf0d51cd1f05de79b0e15096) - [#20276](https://github.com/npm/npm/pull/20276) - `node-gyp@3.6.2` -* [`2b5700679`](https://github.com/npm/npm/commit/2b5700679fce9ee0c24c4509618709a4a35a3d27) - [zkat/npx#172](https://github.com/zkat/npx/pull/172) - `libnpx@10.1.1` - ([@jdalton](https://github.com/jdalton)) - -## v5.9.0 (2018-03-23): - -Coming to you this week are a fancy new package view, pack/publish previews -and a handful of bug fixes! Let's get right in! - -### NEW PACKAGE VIEW - -There's a new `npm view` in town. You might it as `npm info` or `npm show`. -The new output gives you a nicely summarized view that for most packages -fits on one screen. If you ask it for `--json` you'll still get the same -results, so your scripts should still work fine. - -* [`143cdbf13`](https://github.com/npm/npm/commit/143cdbf1327f7d92ccae405bc05d95d28939a837) - [#19910](https://github.com/npm/npm/pull/19910) - Add humanized default view. - ([@zkat](https://github.com/zkat)) -* [`ca84be91c`](https://github.com/npm/npm/commit/ca84be91c434fb7fa472ee4c0b7341414acf52b5) - [#19910](https://github.com/npm/npm/pull/19910) - `tiny-relative-date@1.3.0` - ([@zkat](https://github.com/zkat)) -* [`9a5807c4f`](https://github.com/npm/npm/commit/9a5807c4f813c49b854170b6111c099b3054faa2) - [#19910](https://github.com/npm/npm/pull/19910) - `cli-columns@3.1.2` - ([@zkat](https://github.com/zkat)) -* [`23b4a4fac`](https://github.com/npm/npm/commit/23b4a4fac0fbfe8e03e2f65d9f674f163643d15d) - [#19910](https://github.com/npm/npm/pull/19910) - `byte-size@4.0.2` - -### PACK AND PUBLISH PREVIEWS - -The `npm pack` and `npm publish` commands print out a summary of the files -included in the package. They also both now take the `--dry-run` flag, so -you can double check your `.npmignore` settings before doing a publish. - -* [`116e9d827`](https://github.com/npm/npm/commit/116e9d8271d04536522a7f02de1dde6f91ca5e6e) - [#19908](https://github.com/npm/npm/pull/19908) - Add package previews to pack and publish. Also add --dry-run and --json - flags. - ([@zkat](https://github.com/zkat)) - -### MERGE CONFLICT, SMERGE CONFLICT - -If you resolve a `package-lock.json` merge conflict with `npm install` we -now suggest you setup a merge driver to handle these automatically for you. -If you're reading this and you'd like to set it up now, run: - -```console -npx npm-merge-driver install -g -``` - -* [`5ebe99719`](https://github.com/npm/npm/commit/5ebe99719d11fedeeec7a55f1b389dcf556f32f3) - [#20071](https://github.com/npm/npm/pull/20071) - suggest installing the merge driver - ([@zkat](https://github.com/zkat)) - -### MISC BITS - -* [`a05e27b71`](https://github.com/npm/npm/commit/a05e27b7104f9a79f5941e7458c4658872e5e0cd) - Going forward, record requested ranges not versions in the package-lock. - ([@iarna](https://github.com/iarna)) -* [`f721eec59`](https://github.com/npm/npm/commit/f721eec599df4bdf046d248e0f50822d436654b4) - Add 10 to Node.js supported version list. It's not out yet, but soon my pretties... - ([@iarna](https://github.com/iarna)) - -### DEPENDENCY UPDATES - -* [`40aabb94e`](https://github.com/npm/npm/commit/40aabb94e3f24a9feabb9c490403e10ec9dc254f) - `libcipm@1.6.1`: - Fix bugs on docker and with some `prepare` scripts and `npm ci`. - Fix a bug where script hooks wouldn't be called with `npm ci`. - Fix a bug where `npm ci` and `--prefix` weren't compatible. - ([@isaacseymour](https://github.com/isaacseymour)) - ([@umarov](https://github.com/umarov)) - ([@mikeshirov](https://github.com/mikeshirov)) - ([@billjanitsch](https://github.com/billjanitsch)) -* [`a85372e67`](https://github.com/npm/npm/commit/a85372e671eab46e62caa46631baa30900e32114) - `tar@4.4.1`: - Switch to safe-buffer and Buffer.from. - ([@isaacs](https://github.com/isaacs)) - ([@ChALkeR](https://github.com/ChALkeR)) -* [`588eabd23`](https://github.com/npm/npm/commit/588eabd23fa04420269b9326cab26d974d9c151f) - `lru-cache@4.1.2`: -* [`07f27ee89`](https://github.com/npm/npm/commit/07f27ee898f3c3199e75427017f2b6a189b1a85b) - `qrcode-terminal@0.12.0`: -* [`01e4e29bc`](https://github.com/npm/npm/commit/01e4e29bc879bdaa0e92f0b58e3725a41377d21c) - `request@2.85.0` -* [`344ba8819`](https://github.com/npm/npm/commit/344ba8819f485c72e1c7ac3e656d7e9210ccf607) - `worker-farm@1.6.0` -* [`dc6df1bc4`](https://github.com/npm/npm/commit/dc6df1bc4677164b9ba638e87c1185b857744720) - `validate-npm-package-license@3.0.3` -* [`97a976696`](https://github.com/npm/npm/commit/97a9766962ab5125af3b2a1f7b4ef550a2e3599b) - `ssri@5.3.0` -* [`9b629d0c6`](https://github.com/npm/npm/commit/9b629d0c69599635ee066cb71fcc1b0155317f19) - `query-string@5.1.1` - -## v5.8.0 (2018-03-08): - -Hey again, everyone! While last release was focused largely around PRs from the -CLI team, this release is mostly pulling in community PRs in npm itself and its -dependencies! We've got a good chunk of wonderful contributions for y'all, and -even new features and performance improvements! 🎉 - -We're hoping to continue our biweekly (as in every-other-week biweekly) release -schedule from now on, so you should be seeing more steady npm releases from here -on out. And that's good, 'cause we've got a _ton_ of new stuff on our roadmap -for this year. Keep an eye out for exciting news. 👀 - -### FEATURES - -* [`2f513fe1c`](https://github.com/npm/npm/commit/2f513fe1ce6db055b04a63fe4360212a83f77b34) - [#19904](https://github.com/npm/npm/pull/19904) - Make a best-attempt at preserving line ending style when saving - `package.json`/`package-lock.json`/`npm-shrinkwrap.json`. This goes - hand-in-hand with a previous patch to preserve detected indentation style. - ([@tuananh](https://github.com/tuananh)) -* [`d3cfd41a2`](https://github.com/npm/npm/commit/d3cfd41a28253db5a18260f68642513cbbc93e3b) - `pacote@7.6.1` ([@zkat](https://github.com/zkat)) - * Enable `file:`-based `resolved` URIs in `package-lock.json`. - * Retry git-based operations on certain types of failure. -* [`ecfbb16dc`](https://github.com/npm/npm/commit/ecfbb16dc705f28aa61b3223bdbf9e47230a0fa4) - [#19929](https://github.com/npm/npm/pull/19929) - Add support for the [`NO_COLOR` standard](http://no-color.org). This gives a - cross-application, consistent way of disabling ANSI color code output. Note - that npm already supported this through `--no-color` or - `npm_config_color='false'` configurations, so this is just another way to do - it. - ([@chneukirchen](https://github.com/chneukirchen)) -* [`fc8761daf`](https://github.com/npm/npm/commit/fc8761daf1e8749481457973890fa516eb96a195) - [#19629](https://github.com/npm/npm/pull/19629) - Give more detailed, contextual information when npm fails to parse - `package-lock.json` and `npm-shrinkwrap.json`, instead of saying `JSON parse - error` and leaving you out in the cold. - ([@JoshuaKGoldberg](https://github.com/JoshuaKGoldberg)) -* [`1d368e1e6`](https://github.com/npm/npm/commit/1d368e1e63229f236b9dbabf628989fa3aa98bdb) - [#19157](https://github.com/npm/npm/pull/19157) - Add `--no-proxy` config option. Previously, you needed to use the `NO_PROXY` - environment variable to use this feature -- now it's an actual npm option. - ([@Saturate](https://github.com/Saturate)) -* [`f0e998daa`](https://github.com/npm/npm/commit/f0e998daa049810d5f928615132250021e46451d) - [#18426](https://github.com/npm/npm/pull/18426) - Do environment variable replacement in config files even for config keys or - fragments of keys. - ([@misak113](https://github.com/misak113)) -* [`9847c82a8`](https://github.com/npm/npm/commit/9847c82a8528cfdf5968e9bb00abd8ed47903b5c) - [#18384](https://github.com/npm/npm/pull/18384) - Better error messaging and suggestions when users get `EPERM`/`EACCES` errors. - ([@chrisjpatty](https://github.com/chrisjpatty)) -* [`b9d0c0c01`](https://github.com/npm/npm/commit/b9d0c0c0173542a8d741a9a17b9fb34fbaf5068e) - [#19448](https://github.com/npm/npm/pull/19448) - Holiday celebrations now include all JavaScripters, not just Node developers. - ([@isaacs](https://github.com/isaacs)) - -### NPM CI - -I hope y'all have been having fun with `npm ci` so far! Since this is the first -release since that went out, we've had a few fixes and improvements now that -folks have actually gotten their hands on it! Benchmarks have been super -promising so far, and I've gotten messages from a lot of you saying you've sped -up your CI work by **2-5x** in some cases! Have a good example? Tell us on -Twitter! - -`npm ci` is, right now, [the fastest -installer](http://blog.npmjs.org/post/171556855892/introducing-npm-ci-for-faster-more-reliable) -you can use in CI situations, so go check it out if you haven't already! We'll -continue doing performance improvements on it, and a lot of those will help make -`npm install` fast as well. 🏎😎 - -* [`0d7f203d9`](https://github.com/npm/npm/commit/0d7f203d9e86cc6c8d69107689ea60fc7cbab424) - `libcipm@1.6.0` - ([@zkat](https://github.com/zkat)) - -This `libcipm` release includes a number of improvements: - -* **PERFORMANCE** Reduce calls to `read-package-json` and separate JSON update phase from man/bin linking phase. `npm ci` should be noticeably faster. -* **FEATURE** Progress bar now fills up as packages are installed, instead of sitting there doing nothing. -* **BUGFIX** Add support for `--only` and `--also` options. -* **BUFGIX** Linking binaries and running scripts in parallel was causing packages to sometimes clobber each other when hoisted, as well as potentially running too many run-scripts in parallel. This is now a serial operation, and it turns out to have had relatively little actual performance impact. -* **BUGFIX** Stop adding `_from` to directory deps (aka `file:packages/my-dep`). - -### BUGFIXES - -* [`58d2aa58d`](https://github.com/npm/npm/commit/58d2aa58d5f9c4db49f57a5f33952b3106778669) - [#20027](https://github.com/npm/npm/pull/20027) - Use a specific mtime when packing tarballs instead of the beginning of epoch - time. This should allow `npm pack` to generate tarballs with identical hashes - for identical contents, while fixing issues with some `zip` implementations - that do not support pre-1980 timestamps. - ([@isaacs](https://github.com/isaacs)) -* [`4f319de1d`](https://github.com/npm/npm/commit/4f319de1d6e8aca5fb68f78023425233da4f07f6) - Don't fall back to couch adduser if we didn't try couch login. - ([@iarna](https://github.com/iarna)) -* [`c8230c9bb`](https://github.com/npm/npm/commit/c8230c9bbd596156a4a8cfe62f2370f81d22bd9f) - [#19608](https://github.com/npm/npm/pull/19608) - Fix issue where using the npm-bundled `npx` on Windows was invoking `npx - prefix` (and downloading that package). - ([@laggingreflex](https://github.com/laggingreflex)) -* [`d70c01970`](https://github.com/npm/npm/commit/d70c01970311f4e84b35eef8559c114136a9ebc7) - [#18953](https://github.com/npm/npm/pull/18953) - Avoid using code that depends on `node@>=4` in the `unsupported` check, so npm - can report the issue normally instead of syntax-crashing. - ([@deployable](https://github.com/deployable)) - -### DOCUMENTATION - -* [`4477ca2d9`](https://github.com/npm/npm/commit/4477ca2d993088ac40ef5cf39d1f9c68be3d6252) - `marked@0.3.17`: Fixes issue preventing correct rendering of backticked - strings. man pages should be rendering correctly now instead of having empty - spaces wherever backticks were used. - ([@joshbruce](https://github.com/joshbruce)) -* [`71076ebda`](https://github.com/npm/npm/commit/71076ebdaddd04f2bf330fe668f15750bcff00ea) - [#19950](https://github.com/npm/npm/pull/19950) - Add a note to install --production. - ([@kyranet](https://github.com/kyranet)) -* [`3a33400b8`](https://github.com/npm/npm/commit/3a33400b89a8dd00fa9a49fcb57a8add36f79fa6) - [#19957](https://github.com/npm/npm/pull/19957) - nudge around some details in ci docs - ([@zkat](https://github.com/zkat)) -* [`06038246a`](https://github.com/npm/npm/commit/06038246a3fa58d6f42bb4ab897aa534ff6ed282) - [#19893](https://github.com/npm/npm/pull/19893) - Add a common open reason to the issue template. - ([@MrStonedOne](https://github.com/MrStonedOne)) -* [`7376dd8af`](https://github.com/npm/npm/commit/7376dd8afb654929adade126b4925461aa52da12) - [#19870](https://github.com/npm/npm/pull/19870) - Fix typo in `npm-config.md` - ([@joebowbeer](https://github.com/joebowbeer)) -* [`5390ed4fa`](https://github.com/npm/npm/commit/5390ed4fa2b480f7c58fff6ee670120149ec2d45) - [#19858](https://github.com/npm/npm/pull/19858) - Fix documented default value for config save option. It was still documented - as `false`, even though `npm@5.0.0` set it to `true` by default. - ([@nalinbhardwaj](https://github.com/nalinbhardwaj)) -* [`dc36d850a`](https://github.com/npm/npm/commit/dc36d850a1d763f71a98c99db05ca875dab124ed) - [#19552](https://github.com/npm/npm/pull/19552) - Rework `npm update` docs now that `--save` is on by default. - ([@selbekk](https://github.com/selbekk)) -* [`5ec5dffc8`](https://github.com/npm/npm/commit/5ec5dffc80527d9330388ff82926dd890f4945af) - [#19726](https://github.com/npm/npm/pull/19726) - Clarify that `name` and `version` fields are optional if your package is not - supposed to be installable as a dependency. - ([@ngarnier](https://github.com/ngarnier)) -* [`046500994`](https://github.com/npm/npm/commit/0465009942d6423f878c1359e91972fa5990f996) - [#19676](https://github.com/npm/npm/pull/19676) - Fix documented cache location on Windows. - ([@VladRassokhin](https://github.com/VladRassokhin)) -* [`ffa84cd0f`](https://github.com/npm/npm/commit/ffa84cd0f43c07858506764b4151ba6af11ea120) - [#19475](https://github.com/npm/npm/pull/19475) - Added example for `homepage` field from `package.json`. - ([@cg-cnu](https://github.com/cg-cnu)) -* [`de72d9a18`](https://github.com/npm/npm/commit/de72d9a18ae650ebaee0fdd6694fc89b1cbe8e95) - [#19307](https://github.com/npm/npm/pull/19307) - Document the `requires` field in `npm help package-lock.json`. - ([@jcrben](https://github.com/jcrben)) -* [`35c4abded`](https://github.com/npm/npm/commit/35c4abdedfa622f27e8ee47aa6e293f435323623) - [#18976](https://github.com/npm/npm/pull/18976) - Typo fix in coding style documentation. - ([@rinfan](https://github.com/rinfan)) -* [`0616fd22a`](https://github.com/npm/npm/commit/0616fd22a4e4f2b2998bb70d86d269756aab64be) - [#19216](https://github.com/npm/npm/pull/19216) - Add `edit` section to description in `npm-team.md`. - ([@WispProxy](https://github.com/WispProxy)) -* [`c2bbaaa58`](https://github.com/npm/npm/commit/c2bbaaa582d024cc48b410757efbb81d95837d43) - [#19194](https://github.com/npm/npm/pull/19194) - Tiny style fix in `npm.md`. - ([@WispProxy](https://github.com/WispProxy)) -* [`dcdfdcbb0`](https://github.com/npm/npm/commit/dcdfdcbb0035ef3290bd0912f562e26f6fc4ea94) - [#19192](https://github.com/npm/npm/pull/19192) - Document `--development` flag in `npm-ls.md`. - ([@WispProxy](https://github.com/WispProxy)) -* [`d7ff07135`](https://github.com/npm/npm/commit/d7ff07135a685dd89c15e29d6a28fca33cf448b0) - [#18514](https://github.com/npm/npm/pull/18514) - Make it so `javascript` -> `JavaScript`. This is important. - ([@masonpawsey](https://github.com/masonpawsey)) -* [`7a8705113`](https://github.com/npm/npm/commit/7a870511327d31e8921d6afa845ec8065c60064b) - [#18407](https://github.com/npm/npm/pull/18407) - Clarify the mechanics of the `file` field in `package.json` a bit. - ([@bmacnaughton](https://github.com/bmacnaughton)) -* [`b2a1cf084`](https://github.com/npm/npm/commit/b2a1cf0844ceaeb51ed04f3ae81678527ec9ae68) - [#18382](https://github.com/npm/npm/pull/18382) - Document the [`browser` - field](https://github.com/defunctzombie/package-browser-field-spec) in - `package.json`. - ([@mxstbr](https://github.com/mxstbr)) - -### MISC - -* [`b8a48a959`](https://github.com/npm/npm/commit/b8a48a9595b379cfc2a2c576f61062120ea0caf7) - [#19907](https://github.com/npm/npm/pull/19907) - Consolidate code for stringifying `package.json` and package locks. Also adds - tests have been added to test that `package[-lock].json` files are written to - disk with their original line endings. - ([@nwoltman](https://github.com/nwoltman)) -* [`b4f707d9f`](https://github.com/npm/npm/commit/b4f707d9f543f0995ed5811827a892fc8b2192b5) - [#19879](https://github.com/npm/npm/pull/19879) - Remove unused devDependency `nock` from `.gitignore`. - ([@watilde](https://github.com/watilde)) -* [`8150dd5f7`](https://github.com/npm/npm/commit/8150dd5f72520eb143f75e44787a5775bd8b8ebc) - [#16540](https://github.com/npm/npm/pull/16540) - Stop doing an `uninstall` when using `make clean`. - ([@metux](https://github.com/metux)) - -### OTHER DEPENDENCY BUMPS - -* [`ab237a2a5`](https://github.com/npm/npm/commit/ab237a2a5dcf70ee490e2f0322dfedb1560251d4) - `init-package-json@1.10.3` - ([@zkat](https://github.com/zkat)) -* [`f6d668941`](https://github.com/npm/npm/commit/f6d6689414f00a67a1f34afc6791bdc7d7be4d9b) - `npm-lifecycle@2.0.1` - ([@zkat](https://github.com/zkat)) -* [`882bfbdfa`](https://github.com/npm/npm/commit/882bfbdfaa3eb09b35875e648545cb6967f72562) - `npm-registry-client@8.5.1` - ([@zkat](https://github.com/zkat)) -* [`6ae38055b`](https://github.com/npm/npm/commit/6ae38055ba69db5785ee6c394372de0333763822) - `read-package-json@2.0.1`: Support git packed refs `--all` mode. - ([@zkat](https://github.com/zkat)) -* [`89db703ae`](https://github.com/npm/npm/commit/89db703ae4e25b9fb6c9d7c5119520107a23a752) - `readable-stream@2.3.5` - ([@mcollina](https://github.com/mcollina)) -* [`634dfa5f4`](https://github.com/npm/npm/commit/634dfa5f476b7954b136105a8f9489f5631085a3) - `worker-farm@1.5.4` - ([@rvagg](https://github.com/rvagg)) -* [`92ad34439`](https://github.com/npm/npm/commit/92ad344399f7a23e308d0f3f02547656a47ae6c5) - `hosted-git-info@2.6.0` - ([@zkat](https://github.com/zkat)) -* [`75279c488`](https://github.com/npm/npm/commit/75279c4884d02bd7d451b66616e320eb8cb03bcb) - `tar@4.4.0` - ([@isaacs](https://github.com/isaacs)) -* [`228aba276`](https://github.com/npm/npm/commit/228aba276b19c987cd5989f9bb9ffbe25edb4030) - `write-file-atomic@2.3.0` - ([@iarna](https://github.com/iarna)) -* [`006e9d272`](https://github.com/npm/npm/commit/006e9d272914fc3ba016f110b1411dd20f8a937d) - `libnpx@10.0.1` - ([@zkat](https://github.com/zkat)) -* [`9985561e6`](https://github.com/npm/npm/commit/9985561e666473deeb352c1d4252adf17c2fa01d) - `mississippi@3.0.0` - ([@bcomnes](https://github.com/bcomnes)) -* [`1dc6b3b52`](https://github.com/npm/npm/commit/1dc6b3b525967bc8526aa4765e987136cb570e8e) - `tap@11.1.2` - ([@isaacs](https://github.com/isaacs)) - -## v5.7.1 (2018-02-22): - -This release reverts a patch that could cause some ownership changes on system -files when running from some directories when also using `sudo`. 😲 - -Thankfully, it only affected users running `npm@next`, which is part of our -staggered release system, which we use to prevent issues like this from going -out into the wider world before we can catch them. Users on `latest` would have -never seen this! - -The original patch was added to increase consistency and reliability of methods -npm uses to avoid writing files as `root` in places it shouldn't, but the change -was applied in places that should have used regular `mkdirp`. This release -reverts that patch. - -* [`74e149da6`](https://github.com/npm/npm/commit/74e149da6efe6ed89477faa81fef08eee7999ad0) - [`#19883`](https://github.com/npm/npm/issue/19883) - Revert "*: Switch from mkdirp to correctMkdir to preserve perms and owners" - This reverts commit [`94227e15`](https://github.com/npm/npm/commit/94227e15eeced836b3d7b3d2b5e5cc41d4959cff). - ([@zkat](https://github.com/zkat)) - -## v5.7.0 (2018-02-20): - -Hey y'all, it's been a while. Expect our release rate to increase back to -normal here, as we've got a lot in the pipeline. Right now we've got a -bunch of things from folks at npm. In the next release we'll be focusing on -user contributions and there are a lot of them queued up! - -This release brings a bunch of exciting new features and bug fixes. - -### PACKAGE-LOCK GIT MERGE CONFLICT RESOLUTION - -Allow `npm install` to fix `package-lock.json` and `npm-shrinkwrap.json` -files that have merge conflicts in them without your having to edit them. -It works in conjunction with -[`npm-merge-driver`](https://www.npmjs.com/package/npm-merge-driver) to -entirely eliminate package-lock merge conflicts. - -* [`e27674c22`](https://github.com/npm/npm/commit/e27674c221dc17473f23bffa50123e49a021ae34) - Automatically resolve merge conflicts in lock-files. - ([@zkat](https://github.com/zkat)) - -### NPM CI - -The new `npm ci` command installs from your lock-file ONLY. If your -`package.json` and your lock-file are out of sync then it will report an error. - -It works by throwing away your `node_modules` and recreating it from scratch. - -Beyond guaranteeing you that you'll only get what is in your lock-file it's -also much faster (2x-10x!) than `npm install` when you don't start with a -`node_modules`. - -As you may take from the name, we expect it to be a big boon to continuous -integration environments. We also expect that folks who do production -deploys from git tags will see major gains. - -* [`5e4de9c99`](https://github.com/npm/npm/commit/5e4de9c99c934e25ef7b9c788244cc3c993da559) - Add new `npm ci` installer. - ([@zkat](https://github.com/zkat)) - -### OTHER NEW FEATURES - -* [`4d418c21b`](https://github.com/npm/npm/commit/4d418c21b051f23a3b6fb085449fdf4bf4f826f5) - [#19817](https://github.com/npm/npm/pull/19817) - Include contributor count in installation summary. - ([@kemitchell](https://github.com/kemitchell)) -* [`17079c2a8`](https://github.com/npm/npm/commit/17079c2a880d3a6f8a67c8f17eedc7eb51b8f0f8) - Require password to change email through `npm profile`. - ([@iarna](https://github.com/iarna)) -* [`e7c5d226a`](https://github.com/npm/npm/commit/e7c5d226ac0ad3da0e38f16721c710909d0a9847) - [`4f5327c05`](https://github.com/npm/npm/commit/4f5327c0556764aa1bbc9b58b1a8c8a84136c56a) - [#19780](https://github.com/npm/npm/pull/19780) - Add support for web-based logins. This is not yet available on the registry, however. - ([@isaacs](https://github.com/isaacs)) - -### BIG FIXES TO PRUNING - -* [`827951590`](https://github.com/npm/npm/commit/8279515903cfa3026cf7096189485cdf29f74a8f) - Handle running `npm install package-name` with a `node_modules` containing - packages without sufficient metadata to verify their origin. The only way - to get install packages like this is to use a non-`npm` package manager. - Previously `npm` removed any packages that it couldn't verify. Now it - will leave them untouched as long as you're not asking for a full install. - On a full install they will be reinstalled (but the same versions will be - maintained). - - This will fix problems for folks who are using a third party package - manager to install packages that have `postinstall` scripts that run - `npm install`. - ([@iarna](https://github.com/iarna)) -* [`3b305ee71`](https://github.com/npm/npm/commit/3b305ee71e2bf852ff3037366a1774b8c5fcc0a5) - Only auto-prune on installs that will create a lock-file. This restores - `npm@4` compatible behavior when the lock-file is disabled. When using a - lock-file `npm` will continue to remove anything in your `node_modules` - that's not in your lock-file. ([@iarna](https://github.com/iarna)) -* [`cec5be542`](https://github.com/npm/npm/commit/cec5be5427f7f5106a905de8630e1243e9b36ef4) - Fix bug where `npm prune --production` would remove dev deps from the lock - file. It will now only remove them from `node_modules` not from your lock - file. - ([@iarna](https://github.com/iarna)) -* [`857dab03f`](https://github.com/npm/npm/commit/857dab03f2d58586b45d41d3e5af0fb2d4e824d0) - Fix bug where git dependencies would be removed or reinstalled when - installing other dependencies. - ([@iarna](https://github.com/iarna)) - -### BUG FIXES TO TOKENS AND PROFILES - -* [`a66e0cd03`](https://github.com/npm/npm/commit/a66e0cd0314893b745e6b9f6ca1708019b1d7aa3) - For CIDR filtered tokens, allow comma separated CIDR ranges, as documented. Previously - you could only pass in multiple cidr ranges with multiple `--cidr` command line options. - ([@iarna](https://github.com/iarna)) -* [`d259ab014`](https://github.com/npm/npm/commit/d259ab014748634a89cad5b20eb7a40f3223c0d5) - Fix token revocation when an OTP is required. Previously you had to pass - it in via `--otp`. Now it will prompt you for an OTP like other - `npm token` commands. - ([@iarna](https://github.com/iarna)) -* [`f8b1f6aec`](https://github.com/npm/npm/commit/f8b1f6aecadd3b9953c2b8b05d15f3a9cff67cfd) - Update token and profile commands to support legacy (username/password) authentication. - (The npm registry uses tokens, not username/password pairs, to authenticate commands.) - ([@iarna](https://github.com/iarna)) - -### OTHER BUG FIXES - -* [`6954dfc19`](https://github.com/npm/npm/commit/6954dfc192f88ac263f1fcc66cf820a21f4379f1) - Fix a bug where packages would get pushed deeper into the tree when upgrading without - an existing copy on disk. Having packages deeper in the tree ordinarily is harmless but - is not when peerDependencies are in play. - ([@iarna](https://github.com/iarna)) -* [`1ca916a1e`](https://github.com/npm/npm/commit/1ca916a1e9cf94691d1ff2e5e9d0204cfaba39e1) - Fix bug where when switching from a linked module to a non-linked module, the dependencies - of the module wouldn't be installed on the first run of `npm install`. - ([@iarna](https://github.com/iarna)) -* [`8c120ebb2`](https://github.com/npm/npm/commit/8c120ebb28e87bc6fe08a3fad1bb87b50026a33a) - Fix integrity matching to eliminate spurious EINTEGRITY errors. - ([@zkat](https://github.com/zkat)) -* [`94227e15e`](https://github.com/npm/npm/commit/94227e15eeced836b3d7b3d2b5e5cc41d4959cff) - More consistently make directories using perm and ownership preserving features. - ([@iarna](https://github.com/iarna)) - -### DEPENDENCY UPDATES - -* [`364b23c7f`](https://github.com/npm/npm/commit/364b23c7f8a231c0df3866d6a8bde4d3f37bbc00) - [`f2049f9e7`](https://github.com/npm/npm/commit/f2049f9e7992e6edcfce8619b59746789367150f) - `cacache@10.0.4` - ([@zkat](https://github.com/zkat)) -* [`d183d7675`](https://github.com/npm/npm/commit/d183d76757e8a29d63a999d7fb4edcc1486c25c1) - `find-npm-prefix@1.0.2`: - ([@iarna](https://github.com/iarna)) -* [`ffd6ea62c`](https://github.com/npm/npm/commit/ffd6ea62ce583baff38cf4901cf599639bc193c8) - `fs-minipass@1.2.5` -* [`ee63b8a31`](https://github.com/npm/npm/commit/ee63b8a311ac53b0cf2efa79babe61a2c4083ef6) - `ini@1.3.5` - ([@isaacs](https://github.com/isaacs)) -* [`6f73f5509`](https://github.com/npm/npm/commit/6f73f5509e9e8d606526565c7ceb71c62642466e) - `JSONStream@1.3.2` - ([@dominictarr](https://github.com/dominictarr)) -* [`26cd64869`](https://github.com/npm/npm/commit/26cd648697c1324979289e381fe837f9837f3874) - [`9bc6230cf`](https://github.com/npm/npm/commit/9bc6230cf34a09b7e4358145ff0ac3c69c23c3f6) - `libcipm@1.3.3` - ([@zkat](https://github.com/zkat)) -* [`21a39be42`](https://github.com/npm/npm/commit/21a39be4241a60a898d11a5967f3fc9868ef70c9) - `marked@0.3.1`:5 - ([@joshbruce](https://github.com/joshbruce)) -* [`dabdf57b2`](https://github.com/npm/npm/commit/dabdf57b2d60d665728894b4c1397b35aa9d41c0) - `mississippi@2.0.0` -* [`2594c5867`](https://github.com/npm/npm/commit/2594c586723023edb1db172779afb2cbf8b30c08) - `npm-registry-couchapp@2.7.1` - ([@iarna](https://github.com/iarna)) -* [`8abb3f230`](https://github.com/npm/npm/commit/8abb3f230f119fe054353e70cb26248fc05db0b9) - `osenv@0.1.5` - ([@isaacs](https://github.com/isaacs)) -* [`11a0b00bd`](https://github.com/npm/npm/commit/11a0b00bd3c18625075dcdf4a5cb6500b33c6265) - `pacote@7.3.3` - ([@zkat](https://github.com/zkat)) -* [`9b6bdb2c7`](https://github.com/npm/npm/commit/9b6bdb2c77e49f6d473e70de4cd83c58d7147965) - `query-string@5.1.0` - ([@sindresorhus](https://github.com/sindresorhus)) -* [`d6d17d6b5`](https://github.com/npm/npm/commit/d6d17d6b532cf4c3461b1cf2e0404f7c62c47ec4) - `readable-stream@2.3.4` - ([@mcollina](https://github.com/mcollina)) -* [`51370aad5`](https://github.com/npm/npm/commit/51370aad561b368ccc95c1c935c67c8cd2844d40) - `semver@5.5.0` - ([@isaacs](https://github.com/isaacs)) -* [`0db14bac7`](https://github.com/npm/npm/commit/0db14bac762dd59c3fe17c20ee96d2426257cdd5) - [`81da938ab`](https://github.com/npm/npm/commit/81da938ab6efb881123cdcb44f7f84551924c988) - [`9999e83f8`](https://github.com/npm/npm/commit/9999e83f87c957113a12a6bf014a2099d720d716) - `ssri@5.2.4` - ([@zkat](https://github.com/zkat)) -* [`f526992ab`](https://github.com/npm/npm/commit/f526992ab6f7322a0b3a8d460dc48a2aa4a59a33) - `tap@11.1.1` - ([@isaacs](https://github.com/isaacs)) -* [`be096b409`](https://github.com/npm/npm/commit/be096b4090e2a33ae057912d28fadc5a53bd3391) - [`dc3059522`](https://github.com/npm/npm/commit/dc3059522758470adc225f0651be72c274bd29ef) - `tar@4.3.3` -* [`6b552daac`](https://github.com/npm/npm/commit/6b552daac952f413ed0e2df762024ad219a8dc0a) - `uuid@3.2.1` - ([@broofa](https://github.com/broofa)) -* [`8c9011b72`](https://github.com/npm/npm/commit/8c9011b724ad96060e7e82d9470e9cc3bb64e9c6) - `worker-farm@1.5.2` - ([@rvagg](https://github.com/rvagg)) - - -## v5.6.0 (2017-11-27): - -### Features! - -You may have noticed this is a semver-minor bump. Wondering why? This is why! - -* [`bc263c3fd`](https://github.com/npm/npm/commit/bc263c3fde6ff4b04deee132d0a9d89379e28c27) - [#19054](https://github.com/npm/npm/pull/19054) - **Fully cross-platform `package-lock.json`**. Installing a failing optional - dependency on one platform no longer removes it from the dependency tree, - meaning that `package-lock.json` should now be generated consistently across - platforms! 🎉 - ([@iarna](https://github.com/iarna)) -* [`f94fcbc50`](https://github.com/npm/npm/commit/f94fcbc50d8aec7350164df898d1e12a1e3da77f) - [#19160](https://github.com/npm/npm/pull/19160) - Add `--package-lock-only` config option. This makes it so you can generate a - target `package-lock.json` without performing a full install of - `node_modules`. - ([@alopezsanchez](https://github.com/alopezsanchez)) -* [`66d18280c`](https://github.com/npm/npm/commit/66d18280ca320f880f4377cf80a8052491bbccbe) - [#19104](https://github.com/npm/npm/pull/19104) - Add new `--node-options` config to pass through a custom `NODE_OPTIONS` for - lifecycle scripts. - ([@bmeck](https://github.com/bmeck)) -* [`114d518c7`](https://github.com/npm/npm/commit/114d518c75732c42acbef3acab36ba1d0fd724e2) - Ignore mtime when packing tarballs: This means that doing `npm pack` on the - same repository should yield two tarballs with the same checksum. This will - also help prevent cache bloat when using git dependencies. In the future, this - will allow npm to explicitly cache git dependencies. - ([@isaacs](https://github.com/isaacs)) - -### Node 9 - -Previously, it turns out npm broke on the latest Node, `node@9`. We went ahead -and fixed it up so y'all should be able to use the latest npm again! - -* [`4ca695819`](https://github.com/npm/npm/commit/4ca6958196ae41cef179473e3f7dbed9df9a32f1) - `minizlib@1.0.4`: `Fix node@9` incompatibility. - ([@isaacs](https://github.com/isaacs)) -* [`c851bb503`](https://github.com/npm/npm/commit/c851bb503a756b7cd48d12ef0e12f39e6f30c577) - `tar@4.0.2`: Fix `node@9` incompatibility. - ([@isaacs](https://github.com/isaacs)) -* [`6caf23096`](https://github.com/npm/npm/commit/6caf2309613d14ce77923ad3d1275cb89c6cf223) - Remove "unsupported" warning for Node 9 now that things are fixed. - ([@iarna](https://github.com/iarna)) -* [`1930b0f8c`](https://github.com/npm/npm/commit/1930b0f8c44373301edc9fb6ccdf7efcb350fa42) - Update test matrix with `node@8` LTS and `node@9`. - ([@iarna](https://github.com/iarna)) - -### Bug Fixes - -* [`b70321733`](https://github.com/npm/npm/commit/b7032173361665a12c9e4200bdc3f0eb4dee682f) - [#18881](https://github.com/npm/npm/pull/18881) - When dealing with a `node_modules` that was created with older versions of npm - (and thus older versions of npa) we need to gracefully handle older spec - entries. Failing to do so results in us treating those packages as if they - were http remote deps, which results in invalid lock files with `version` set - to tarball URLs. This should now be fixed. - ([@iarna](https://github.com/iarna)) -* [`2f9c5dd00`](https://github.com/npm/npm/commit/2f9c5dd0046a53ece3482e92a412413f5aed6955) - [#18880](https://github.com/npm/npm/pull/18880) - Stop overwriting version in package data on disk. This is another safeguard - against the version overwriting that's plagued some folks upgrading from older - package-locks. - ([@iarna](https://github.com/iarna)) - ([@joshclow](https://github.com/joshclow)) -* [`a93e0a51d`](https://github.com/npm/npm/commit/a93e0a51d3dafc31c809ca28cd7dfa71b2836f86) - [#18846](https://github.com/npm/npm/pull/18846) - Correctly save transitive dependencies when using `npm update` in - `package-lock.json`. - ([@iarna](https://github.com/iarna)) -* [`fdde7b649`](https://github.com/npm/npm/commit/fdde7b649987b2acd9a37ef203f1e263fdf6fece) - [#18825](https://github.com/npm/npm/pull/18825) - Fix typo and concatenation in error handling. - ([@alulsh](https://github.com/alulsh)) -* [`be67de7b9`](https://github.com/npm/npm/commit/be67de7b90790cef0a9f63f91c2f1a00942205ee) - [#18711](https://github.com/npm/npm/pull/18711) - Upgrade to bearer tokens from legacy auth when enabling 2FA. - ([@iarna](https://github.com/iarna)) -* [`bfdf0fd39`](https://github.com/npm/npm/commit/bfdf0fd39646b03db8e543e2bec7092da7880596) - [#19033](https://github.com/npm/npm/pull/19033) - Fix issue where files with `@` signs in their names would not get included - when packing tarballs. - ([@zkat](https://github.com/zkat)) -* [`b65b89bde`](https://github.com/npm/npm/commit/b65b89bdeaa65516f3e13afdb6e9aeb22d8508f4) - [#19048](https://github.com/npm/npm/pull/19048) - Fix problem where `npm login` was ignoring various networking-related options, - such as custom certs. - ([@wejendorp](https://github.com/wejendorp)) -* [`8c194b86e`](https://github.com/npm/npm/commit/8c194b86ec9617e2bcc31f30ee4772469a0bb440) - `npm-packlist@1.1.10`: Include `node_modules/` directories not in the root. - ([@isaacs](https://github.com/isaacs)) -* [`d7ef6a20b`](https://github.com/npm/npm/commit/d7ef6a20b44e968cb92babab1beb51f99110781d) - `libnpx@9.7.1`: Fix some *nix binary path escaping issues. - ([@zkat](https://github.com/zkat)) -* [`981828466`](https://github.com/npm/npm/commit/981828466a5936c70abcccea319b227c443e812b) - `cacache@10.0.1`: Fix fallback to `copy-concurrently` when file move fails. - This might fix permissions and such issues on platforms that were getting - weird filesystem errors during install. - ([@karolba](https://github.com/karolba)) -* [`a0be6bafb`](https://github.com/npm/npm/commit/a0be6bafb6dd7acb3e7b717c27c8575a2215bfff) - `pacote@7.0.2`: Includes a bunch of fixes, specially for issues around git - dependencies. Shasum-related errors should be way less common now, too. - ([@zkat](https://github.com/zkat)) -* [`b80d650de`](https://github.com/npm/npm/commit/b80d650def417645d2525863e9f17af57a917b42) - [#19163](https://github.com/npm/npm/pull/19163) - Fix a number of git and tarball specs and checksum errors. - ([@zkat](https://github.com/zkat)) -* [`cac225025`](https://github.com/npm/npm/commit/cac225025fa06cd055286e75541138cd95f52def) - [#19054](https://github.com/npm/npm/pull/19054) - Don't count failed optionals when summarizing installed packages. - ([@iarna](https://github.com/iarna)) - -### UX - -* [`b1ec2885c`](https://github.com/npm/npm/commit/b1ec2885c43f8038c4e05b83253041992fdfe382) - [#18326](https://github.com/npm/npm/pull/18326) - Stop truncating output of `npm view`. This means, for example, that you no - longer need to use `--json` when a package has a lot of versions, to see the - whole list. - ([@SimenB](https://github.com/SimenB)) -* [`55a124e0a`](https://github.com/npm/npm/commit/55a124e0aa6097cb46f1484f666444b2a445ba57) - [#18884](https://github.com/npm/npm/pull/18884) - Profile UX improvements: better messaging on unexpected responses, and stop - claiming we set passwords to null when resetting them. - ([@iarna](https://github.com/iarna)) -* [`635481c61`](https://github.com/npm/npm/commit/635481c6143bbe10a6f89747795bf4b83f75a7e9) - [#18844](https://github.com/npm/npm/pull/18844) - Improve error messaging for OTP/2FA. - ([@iarna](https://github.com/iarna)) -* [`52b142ed5`](https://github.com/npm/npm/commit/52b142ed5e0f13f23c99209932e8de3f7649fd47) - [#19054](https://github.com/npm/npm/pull/19054) - Stop running the same rollback multiple times. This should address issues - where Windows users saw strange failures when `fsevents` failed to install. - ([@iarna](https://github.com/iarna)) -* [`798428b0b`](https://github.com/npm/npm/commit/798428b0b7b6cfd6ce98041c45fc0a36396e170c) - [#19172](https://github.com/npm/npm/pull/19172) - `bin-links@1.1.0`: Log the fact line endings are being changed upon install. - ([@marcosscriven](https://github.com/marcosscriven)) - -### Refactors - -Usually, we don't include internal refactor stuff in our release notes, but it's -worth calling out some of them because they're part of a larger effort the CLI -team and associates are undertaking to modularize npm itself so other package -managers and associated tools can reuse all that code! - -* [`9d22c96b7`](https://github.com/npm/npm/commit/9d22c96b7160729c8126a38dcf554611b9e3ba87) - [#18500](https://github.com/npm/npm/pull/18500) - Extract bin-links and gentle-fs to a separate library. This will allow - external tools to do bin linking and certain fs operations in an - npm-compatible way! - ([@mikesherov](https://github.com/mikesherov)) -* [`015a7803b`](https://github.com/npm/npm/commit/015a7803b7b63bc8543882196d987b92b461932d) - [#18883](https://github.com/npm/npm/pull/18883) - Capture logging from log events on the process global. This allows npm to use - npmlog to report logging from external libraries like `npm-profile`. - ([@iarna](https://github.com/iarna)) -* [`c930e98ad`](https://github.com/npm/npm/commit/c930e98adc03cef357ae5716269a04d74744a852) - `npm-lifecycle@2.0.0`: Use our own `node-gyp`. This means npm no longer needs - to pull some maneuvers to make sure `node-gyp` is in the right place, and that - external packages using `npm-lifecycle` will get working native builds without - having to do their own `node-gyp` maneuvers. - ([@zkochan](https://github.com/zkochan)) -* [`876f0c8f3`](https://github.com/npm/npm/commit/876f0c8f341f8915e338b409f4b8616bb5263500) [`829893d61`](https://github.com/npm/npm/commit/829893d617bf81bba0d1ce4ea303f76ea37a2b2d) - [#19099](https://github.com/npm/npm/pull/19099) - `find-npm-prefix@1.0.1`: npm's prefix-finding logic is now a standalone - module. That is, the logic that figures out where the root of your project is - if you've `cd`'d into a subdirectory. Did you know you can run `npm install` - from these subdirectories, and it'll only affect the root? It works like git! - ([@iarna](https://github.com/iarna)) - -### Docs - -* [`7ae12b21c`](https://github.com/npm/npm/commit/7ae12b21cc841f76417d3bb13b74f177319d4deb) - [#18823](https://github.com/npm/npm/pull/18823) - Fix spelling of the word authenticator. Because English is hard. - ([@tmcw](https://github.com/tmcw)) -* [`5dfc3ab7b`](https://github.com/npm/npm/commit/5dfc3ab7bc2cb0fa7d9a8c00aa95fecdd14d7ae1) - [#18742](https://github.com/npm/npm/pull/18742) - Explicitly state 'github:foo/bar' as a valid shorthand for hosted git specs. - ([@felicio](https://github.com/felicio)) -* [`a9dc098a6`](https://github.com/npm/npm/commit/a9dc098a6eb7a87895f52a101ac0d41492da698e) - [#18679](https://github.com/npm/npm/pull/18679) - Add some documentation about the `script-shell` config. - ([@gszabo](https://github.com/gszabo)) -* [`24d7734d1`](https://github.com/npm/npm/commit/24d7734d1a1e906c83c53b6d1853af8dc758a998) - [#18571](https://github.com/npm/npm/pull/18571) - Change `verboten` to `forbidden`. - ([@devmount](https://github.com/devmount)) -* [`a8a45668f`](https://github.com/npm/npm/commit/a8a45668fb9b8eb84234fe89234bdcdf644ead58) - [#18568](https://github.com/npm/npm/pull/18568) - Improve wording for the docs for the "engines" section of package.json files. - ([@apitman](https://github.com/apitman)) -* [`dbc7e5b60`](https://github.com/npm/npm/commit/dbc7e5b602870330a8cdaf63bd303cd9050f792f) - [#19118](https://github.com/npm/npm/pull/19118) - Use valid JSON in example for bundledDependencies. - ([@charmander](https://github.com/charmander)) -* [`779339485`](https://github.com/npm/npm/commit/779339485bab5137d0fdc68d1ed6fa987aa8965a) - [#19162](https://github.com/npm/npm/pull/19162) - Remove trailing white space from `npm access` docs. - ([@WispProxy](https://github.com/WispProxy)) - -### Dependency Bumps - -* [`0e7cac941`](https://github.com/npm/npm/commit/0e7cac9413ff1104cf242cc3006f42aa1c2ab63f) - `bluebird@3.5.1` - ([@petkaantonov](https://github.com/petkaantonov)) -* [`c4d5887d9`](https://github.com/npm/npm/commit/c4d5887d978849ddbe2673630de657f141ae5bcf) - `update-notifier@2.3.0` - ([@sindresorhus](https://github.com/sindresorhus)) -* [`eb19a9691`](https://github.com/npm/npm/commit/eb19a9691cf76fbc9c5b66aa7aadb5d905af467a) - `npm-package-arg@6.0.0` - ([@zkat](https://github.com/zkat)) -* [`91d5dca96`](https://github.com/npm/npm/commit/91d5dca96772bc5c45511ddcbeeb2685c7ea68e8) - `npm-profile@2.0.5` - ([@iarna](https://github.com/iarna)) -* [`8de66c46e`](https://github.com/npm/npm/commit/8de66c46e57e4b449c9540c8ecafbc4fd58faff5) - `ssri@5.0.0` - ([@zkat](https://github.com/zkat)) -* [`cfbc3ea69`](https://github.com/npm/npm/commit/cfbc3ea69a8c62dc8e8543193c3ac472631dcef9) - `worker-farm@1.5.1` - ([@rvagg](https://github.com/rvagg)) -* [`60c228160`](https://github.com/npm/npm/commit/60c228160f22d41c2b36745166c9e8c2d84fee58) - `query-string@5.0.1` - ([@sindresorhus](https://github.com/sindresorhus)) -* [`72cad8c66`](https://github.com/npm/npm/commit/72cad8c664efd8eb1bec9a418bccd6c6ca9290de) - `copy-concurrently@1.0.5` - ([@iarna](https://github.com/iarna)) - -## v5.5.1 (2017-10-04): - -A very quick, record time, patch release, of a bug fix to a (sigh) last minute bug fix. - -* [`e628e058b`](https://github.com/npm/npm/commit/e628e058b) - Fix login to properly recognize OTP request and store bearer tokens. - ([@iarna](https://github.com/iarna)) - -## v5.5.0 (2017-10-04): - -Hey y'all, this is a big new feature release! We've got some security -related goodies plus a some quality-of-life improvements for anyone who uses -the public registry (so, virtually everyone). - -The changes largely came together in one piece, so I'm just gonna leave the commit line here: - -* [`f6ebf5e8b`](https://github.com/npm/npm/commit/f6ebf5e8bd6a212c7661e248c62c423f2b54d978) - [`f97ad6a38`](https://github.com/npm/npm/commit/f97ad6a38412581d059108ea29be470acb4fa510) - [`f644018e6`](https://github.com/npm/npm/commit/f644018e6ef1ff7523c6ec60ae55a24e87a9d9ae) - [`8af91528c`](https://github.com/npm/npm/commit/8af91528ce6277cd3a8c7ca8c8102671baf10d2f) - [`346a34260`](https://github.com/npm/npm/commit/346a34260b5fba7de62717135f3e083cc4820853) - Two factor authentication, profile editing and token management. - ([@iarna](https://github.com/iarna)) - -### TWO FACTOR AUTHENTICATION - -You can now enable two-factor authentication for your npm account. You can -even do it from the CLI. In fact, you have to, for the time being: - -``` -npm profile enable-tfa -``` - -With the default two-factor authentication mode you'll be prompted to enter -a one-time password when logging in, when publishing and when modifying access rights to -your modules. - -### TOKEN MANAGEMENT - -You can now create, list and delete authentication tokens from the comfort -of the command line. Authentication tokens created this way can have NEW -restrictions placed on them. For instance, you can create a `read-only` -token to give to your CI. It will be able to download your private modules -but it won't be able to publish or modify modules. You can also create -tokens that can only be used from certain network addresses. This way you -can lock down access to your corporate VPN or other trusted machines. - -Deleting tokens isn't new, you could [do it via the -website](https://www.npmjs.com/settings/tokens) but now you can do it via -the CLI as well. - -### CHANGE YOUR PASSWORD, SET YOUR EMAIL - -You can finally change your password from the CLI with `npm profile set -password`! You can also update your email address with `npm profile set -email <address>`. If you change your email address we'll send you a new -verification email so you verify that its yours. - -### AND EVERYTHING ELSE ON YOUR PROFILE - -You can also update all of the other attributes of your profile that -previously you could only update via the website: `fullname`, `homepage`, -`freenode`, `twitter` and `github`. - -### AVAILABLE STAND ALONE - -All of these features were implemented in a stand alone library, so if you -have use for them in your own project you can find them in -[npm-profile](https://www.npmjs.com/package/npm-profile) on the registry. -There's also a little mini-cli written just for it at -[npm-profile-cli](https://www.npmjs.com/package/npm-profile-cli). You might -also be interested in the [API -documentation](https://github.com/npm/registry/tree/master/docs) for these -new features: [user profile editing](https://github.com/npm/registry/blob/master/docs/user/profile.md) and -[authentication](https://github.com/npm/registry/blob/master/docs/user/authentication.md). - -### BUG FIXES - -* [`5ee55dc71`](https://github.com/npm/npm/commit/5ee55dc71b8b74b8418c3d5ec17483a07b3b6777) - install.sh: Drop support for upgrading from npm@1 as npm@5 can't run on - any Node.js version that ships npm@1. This fixes an issue some folks were seeing when trying - to upgrade using `curl | http://npmjs.com/install.sh`. - ([@iarna](https://github.com/iarna)) -* [`5cad1699a`](https://github.com/npm/npm/commit/5cad1699a7a0fc85ac7f77a95087a9647f75e344) - `npm-lifecycle@1.0.3` Fix a bug where when more than one lifecycle script - got queued to run, npm would crash. - ([@zkat](https://github.com/zkat)) -* [`cd256cbb2`](https://github.com/npm/npm/commit/cd256cbb2f97fcbcb82237e94b66eac80e493626) - `npm-packlist@1.1.9` Fix a bug where test directories would always be - excluded from published modules. - ([@isaacs](https://github.com/isaacs)) -* [`2a11f0215`](https://github.com/npm/npm/commit/2a11f021561acb1eb1ad4ad45ad955793b1eb4af) - Fix formatting of unsupported version warning - ([@iarna](https://github.com/iarna)) - -### DEPENDENCY UPDATES - -* [`6d2a285a5`](https://github.com/npm/npm/commit/6d2a285a58655f10834f64d38449eb1f3c8b6c47) - `npm-registry-client@8.5.0` -* [`69e64e27b`](https://github.com/npm/npm/commit/69e64e27bf58efd0b76b3cf6e8182c77f8cc452f) - `request@2.83.0` -* [`34e0f4209`](https://github.com/npm/npm/commit/34e0f42090f6153eb5462f742e402813e4da56c8) - `abbrev@1.1.1` -* [`10d31739d`](https://github.com/npm/npm/commit/10d31739d39765f1f0249f688bd934ffad92f872) - `aproba@1.2.0` -* [`2b02e86c0`](https://github.com/npm/npm/commit/2b02e86c06cf2a5fe7146404f5bfd27f190ee4f4) - `meant@1.0.1` -* [`b81fff808`](https://github.com/npm/npm/commit/b81fff808ee269361d3dcf38c1b6019f1708ae02) - `rimraf@2.6.2`: - Fixes a long standing bug in rimraf's attempts to work around Windows limitations - where it owns a file and can change its perms but can't remove it without - first changing its perms. This _may_ be an improvement for Windows users of npm under - some circumstances. - ([@isaacs](https://github.com/isaacs)) - -## v5.4.2 (2017-09-14): - -This is a small bug fix release wrapping up most of the issues introduced with 5.4.0. - -### Bugs - -* [`0b28ac72d`](https://github.com/npm/npm/commit/0b28ac72d29132e9b761717aba20506854465865) - [#18458](https://github.com/npm/npm/pull/18458) - Fix a bug on Windows where rolling back of failed optional dependencies would fail. - ([@marcins](https://github.com/marcins)) -* [`3a1b29991`](https://github.com/npm/npm/commit/3a1b299913ce94fdf25ed3ae5c88fe6699b04e24) - `write-file-atomic@2.1.0` Revert update of `write-file-atomic`. There were changes made to it - that were resulting in EACCES errors for many users. - ([@iarna](https://github.com/iarna)) -* [`cd8687e12`](https://github.com/npm/npm/commit/cd8687e1257f59a253436d69e8d79a29c85d00c8) - Fix a bug where if npm decided it needed to move a module during an upgrade it would strip - out much of the `package.json`. This would result in broken trees after package updates. -* [`5bd0244ee`](https://github.com/npm/npm/commit/5bd0244eec347ce435e88ff12148c35da7c69efe) - [#18385](https://github.com/npm/npm/pull/18385) - Fix `npm outdated` when run on non-registry dependencies. - ([@joshclow](https://github.com/joshclow)) - ([@iarna](https://github.com/iarna)) - -### Ux - -* [`339f17b1e`](https://github.com/npm/npm/commit/339f17b1e6816eccff7df97875db33917eccdd13) - Report unsupported node versions with greater granularity. - ([@iarna](https://github.com/iarna)) - -### Docs - -* [`b2ab6f43b`](https://github.com/npm/npm/commit/b2ab6f43b8ae645134238acd8dd3083e5ba8846e) - [#18397](https://github.com/npm/npm/pull/18397) - Document that the default loglevel with `npm@5` is `notice`. - ([@KenanY](https://github.com/KenanY)) -* [`e5aedcd82`](https://github.com/npm/npm/commit/e5aedcd82af81fa9e222f9210f6f890c72a18dd3) - [#18372](https://github.com/npm/npm/pull/18372) - In npm-config documentation, note that env vars use \_ in place of -. - ([@jakubholynet](https://github.com/jakubholynet)) - -## v5.4.1 (2017-09-06): - -This is a very small bug fix release to fix a problem where permissions on -installed binaries were being set incorrectly. - -* [`767ff6eee`](https://github.com/npm/npm/commit/767ff6eee7fa3a0f42ad677dedc0ec1f0dc15e7c) - [zkat/pacote#117](https://github.com/zkat/pacote/pull/117) - [#18324](https://github.com/npm/npm/issues/18324) - `pacote@6.0.2` - ([@zkat](https://github.com/zkat)) - -## v5.4.0 (2017-08-22): - -Here's another ~~small~~ big release, with a ~~handful~~ bunch of fixes and -a couple of ~~small~~ new features! This release has been incubating rather -longer than usual and it's grown quite a bit in that time. I'm also excited -to say that it has contributions from **27** different folks, which is a new -record for us. Our previous record was 5.1.0 at 21. Before that the record -had been held by 1.3.16 since _December of 2013_. - -![chart of contributor counts by version, showing an increasing rate over time and spikes mid in the 1.x series and later at 5.x](https://pbs.twimg.com/media/DH38rbZUwAAf9hS.jpg) - -If you can't get enough of the bleeding edge, I encourage you to check out -our canary release of npm. Get it with `npm install -g npmc`. It's going to -be seeing some exciting stuff in the next couple of weeks, starting with a -rewritten `npm dedupe`, but moving on to… well, you'll just have to wait and -find out. - -### PERFORMANCE - -* [`d080379f6`](https://github.com/npm/npm/commit/d080379f620c716afa2c1d2e2ffc0a1ac3459194) - `pacote@6.0.1` Updates extract to use tar@4, which is much faster than the - older tar@2. It reduces install times by as much as 10%. - ([@zkat](https://github.com/zkat)) -* [`4cd6a1774`](https://github.com/npm/npm/commit/4cd6a1774f774506323cae5685c9ca9a10deab63) - [`0195c0a8c`](https://github.com/npm/npm/commit/0195c0a8cdf816834c2f737372194ddc576c451d) - [#16804](https://github.com/npm/npm/pull/16804) - `tar@4.0.1` Update publish to use tar@4. tar@4 brings many advantages - over tar@2: It's faster, better tested and easier to work with. It also - produces exactly the same byte-for-byte output when producing tarballs - from the same set of files. This will have some nice carry on effects for - things like caching builds from git. And finally, last but certainly not - least, upgrading to it also let's us finally eliminate `fstream`—if - you know what that is you'll know why we're so relieved. - ([@isaacs](https://github.com/isaacs)) - -### FEATURES - -* [`1ac470dd2`](https://github.com/npm/npm/commit/1ac470dd283cc7758dc37721dd6331d5b316dc99) - [#10382](https://github.com/npm/npm/pull/10382) - If you make a typo when writing a command now, npm will print a brief "did you - mean..." message with some possible alternatives to what you meant. - ([@watilde](https://github.com/watilde)) -* [`20c46228d`](https://github.com/npm/npm/commit/20c46228d8f9243910f8c343f4830d52455d754e) - [#12356](https://github.com/npm/npm/pull/12356) - When running lifecycle scripts, `INIT_CWD` will now contain the original - working directory that npm was executed from. Remember that you can use `npm - run-script` even if you're not inside your package root directory! - ([@MichaelQQ](https://github.com/MichaelQQ)) -* [`be91e1726`](https://github.com/npm/npm/commit/be91e1726e9c21c4532723e4f413b73a93dd53d1) - [`4e7c41f4a`](https://github.com/npm/npm/commit/4e7c41f4a29744a9976cc22c77eee9d44172f21e) - `libnpx@9.6.0`: Fixes a number of issues on Windows and adds support for - several more languages: Korean, Norwegian (bokmål and nynorsk), Ukrainian, - Serbian, Bahasa Indonesia, Polish, Dutch and Arabic. - ([@zkat](https://github.com/zkat)) -* [`2dec601c6`](https://github.com/npm/npm/commit/2dec601c6d5a576751d50efbcf76eaef4deff31e) - [#17142](https://github.com/npm/npm/pull/17142) - Add the new `commit-hooks` option to `npm version` so that you can disable commit - hooks when committing the version bump. - ([@faazshift](https://github.com/faazshift)) -* [`bde151902`](https://github.com/npm/npm/commit/bde15190230b5c62dbd98095311eab71f6b52321) - [#14461](https://github.com/npm/npm/pull/14461) - Make output from `npm ping` clear as to its success or failure. - ([@legodude17](https://github.com/legodude17)) - -### BUGFIXES - -* [`b6d5549d2`](https://github.com/npm/npm/commit/b6d5549d2c2d38dd0e4319c56b69ad137f0d50cd) - [#17844](https://github.com/npm/npm/pull/17844) - Make package-lock.json sorting locale-agnostic. Previously, sorting would vary - by locale, due to using `localeCompare` for key sorting. This'll give you - a little package-lock.json churn as it reshuffles things, sorry! - ([@LotharSee](https://github.com/LotharSee)) -* [`44b98b9dd`](https://github.com/npm/npm/commit/44b98b9ddcfcccf68967fdf106fca52bf0c3da4b) - [#17919](https://github.com/npm/npm/pull/17919) - Fix a crash where `npm prune --production` would fail while removing `.bin`. - ([@fasterthanlime](https://github.com/fasterthanlime)) -* [`c3d1d3ba8`](https://github.com/npm/npm/commit/c3d1d3ba82aa41dfb2bd135e6cdc59f8d33cd9fb) - [#17816](https://github.com/npm/npm/pull/17816) - Fail more smoothly when attempting to install an invalid package name. - ([@SamuelMarks](https://github.com/SamuelMarks)) -* [`55ac2fca8`](https://github.com/npm/npm/commit/55ac2fca81bf08338302dc7dc2070494e71add5c) - [#12784](https://github.com/npm/npm/pull/12784) - Guard against stack overflows when marking packages as failed. - ([@vtravieso](https://github.com/vtravieso)) -* [`597cc0e4b`](https://github.com/npm/npm/commit/597cc0e4b5e6ee719014e3171d4e966df42a275c) - [#15087](https://github.com/npm/npm/pull/15087) - Stop outputting progressbars or using color on dumb terminals. - ([@iarna](https://github.com/iarna)) -* [`7a7710ba7`](https://github.com/npm/npm/commit/7a7710ba72e6f82414653c2e7e91fea9a1aba7e2) - [#15088](https://github.com/npm/npm/pull/15088) - Don't exclude modules that are both dev & prod when using `npm ls --production`. - ([@iarna](https://github.com/iarna)) -* [`867df2b02`](https://github.com/npm/npm/commit/867df2b0214689822b87b51578e347f353be97e8) - [#18164](https://github.com/npm/npm/pull/18164) - Only do multiple procs on OSX for now. We've seen a handful of issues - relating to this in Docker and in on Windows with antivirus. - ([@zkat](https://github.com/zkat)) -* [`23540af7b`](https://github.com/npm/npm/commit/23540af7b0ec5f12bbdc1558745c8c4f0861042b) - [#18117](https://github.com/npm/npm/pull/18117) - Some package managers would write spaces to the \_from field in package.json's in the - form of `name @spec`. This was causing npm to fail to interpret them. We now handle that - correctly and doubly make sure we don't do that ourselves. - ([@IgorNadj](https://github.com/IgorNadj)) -* [`0ef320cb4`](https://github.com/npm/npm/commit/0ef320cb40222693b7367b97c60ddffabc2d58c5) - [#16634](https://github.com/npm/npm/pull/16634) - Convert any bin script with a shbang a the start to Unix line-endings. (These sorts of scripts - are not compatible with Windows line-endings even on Windows.) - ([@ScottFreeCode](https://github.com/ScottFreeCode)) -* [`71191ca22`](https://github.com/npm/npm/commit/71191ca2227694355c49dfb187104f68df5126bd) - [#16476](https://github.com/npm/npm/pull/16476) - `npm-lifecycle@1.0.2` Running an install with `--ignore-scripts` was resulting in the - the package object being mutated to have the lifecycle scripts removed from it and that - in turn was being written out to disk, causing further problems. This fixes that: - No more mutation, no more unexpected changes. - ([@addaleax](https://github.com/addaleax)) -* [`459fa9d51`](https://github.com/npm/npm/commit/459fa9d51600904ee75ed6267b159367a1209793) - [npm/read-package-json#74](https://github.com/npm/read-package-json/pull/74) - [#17802](https://github.com/npm/npm/pull/17802) - `read-package-json@2.0.1` Use unix-style slashes for generated bin - entries, which lets them be cross platform even when produced on Windows. - ([@iarna](https://github.com/iarna)) -* [`5ec72ab5b`](https://github.com/npm/npm/commit/5ec72ab5b27c5c83cee9ff568cf75a9479d4b83a) - [#18229](https://github.com/npm/npm/pull/18229) - Make install.sh find nodejs on debian. - ([@cebe](https://github.com/cebe)) - -### DOCUMENTATION - -* [`b019680db`](https://github.com/npm/npm/commit/b019680db78ae0a6dff2289dbfe9f61fccbbe824) - [#10846](https://github.com/npm/npm/pull/10846) - Remind users that they have to install missing `peerDependencies` manually. - ([@ryanflorence](https://github.com/ryanflorence)) -* [`3aee5986a`](https://github.com/npm/npm/commit/3aee5986a65add2f815b24541b9f4b69d7fb445f) - [#17898](https://github.com/npm/npm/pull/17898) - Minor punctuation fixes to the README. - ([@AndersDJohnson](https://github.com/AndersDJohnson)) -* [`e0d0a7e1d`](https://github.com/npm/npm/commit/e0d0a7e1dda2c43822b17eb71f4d51900575cc61) - [#17832](https://github.com/npm/npm/pull/17832) - Fix grammar, format, and spelling in documentation for `run-script`. - ([@simonua](https://github.com/simonua)) -* [`3fd6a5f2f`](https://github.com/npm/npm/commit/3fd6a5f2f8802a9768dba2ec32c593b5db5a878d) - [#17897](https://github.com/npm/npm/pull/17897) - Add more info about using `files` with `npm pack`/`npm publish`. - ([@davidjgoss](https://github.com/davidjgoss)) -* [`f00cdc6eb`](https://github.com/npm/npm/commit/f00cdc6eb90a0735bc3c516720de0b1428c79c31) - [#17785](https://github.com/npm/npm/pull/17785) - Add a note about filenames for certificates on Windows, which use a different - extension and file type. - ([@lgp1985](https://github.com/lgp1985)) -* [`0cea6f974`](https://github.com/npm/npm/commit/0cea6f9741243b1937abfa300c2a111d9ed79143) - [#18022](https://github.com/npm/npm/pull/18022) - Clarify usage for the `files` field in `package.json`. - ([@xcambar](https://github.com/xcambar)) -* [`a0fdd1571`](https://github.com/npm/npm/commit/a0fdd15710971234cbc57086cd1a4dc037a39471) - [#15234](https://github.com/npm/npm/pull/15234) - Clarify the behavior of the `files` array in the package-json docs. - ([@jbcpollak](https://github.com/jbcpollak)) -* [`cecd6aa5d`](https://github.com/npm/npm/commit/cecd6aa5d4dd04af765b26b749c1cd032f7eb913) - [#18137](https://github.com/npm/npm/pull/18137) - Clarify interaction between npmignore and files in package.json. - ([@supertong](https://github.com/supertong)) -* [`6b8972039`](https://github.com/npm/npm/commit/6b89720396767961001e727fc985671ce88b901b) - [#18044](https://github.com/npm/npm/pull/18044) - Corrected the typo in package-locks docs. - ([@vikramnr](https://github.com/vikramnr)) -* [`6e012924f`](https://github.com/npm/npm/commit/6e012924f99c475bc3637c86ab6a113875405fc7) - [#17667](https://github.com/npm/npm/pull/17667) - Fix description of package.json in npm-scripts docs. - ([@tripu](https://github.com/tripu)) - -### POSSIBLY INTERESTING DEPENDENCY UPDATES - -* [`48d84171a`](https://github.com/npm/npm/commit/48d84171a302fde2510b3f31e4a004c5a4d39c73) - [`f60b05d63`](https://github.com/npm/npm/commit/f60b05d6307a7c46160ce98d6f3ccba89411c4ba) - `semver@5.4.1` Perf improvements. - ([@zkat](https://github.com/zkat)) -* [`f4650b5d4`](https://github.com/npm/npm/commit/f4650b5d4b2be2c04c229cc53aa930e260af9b4e) - `write-file-atomic@2.3.0`: - Serialize writes to the same file so that results are deterministic. - Cleanup tempfiles when process is interrupted or killed. - ([@ferm10n](https://github.com/ferm10n)) - ([@iarna](https://github.com/iarna)) - -### CHORES - -* [`96d78df98`](https://github.com/npm/npm/commit/96d78df9843187bc53be2c93913e8567003ccb73) - [`80e2f4960`](https://github.com/npm/npm/commit/80e2f4960691bc5dbd8320002e4d9143784b9ce9) - [`4f49f687b`](https://github.com/npm/npm/commit/4f49f687bbd54b6a0e406936ae35593d8e971e1e) - [`07d2296b1`](https://github.com/npm/npm/commit/07d2296b10e3d8d6f079eba3a61f0258501d7161) - [`a267ab430`](https://github.com/npm/npm/commit/a267ab4309883012a9d55934533c5915e9842277) - [#18176](https://github.com/npm/npm/pull/18176) - [#18025](https://github.com/npm/npm/pull/18025) - Move the lifecycle code out of npm into a separate library, - [`npm-lifecycle`](https://github.com/npm/lifecycle). Shh, I didn't tell you this, but this - portends to some pretty cool stuff to come very soon now. - ([@mikesherov](https://github.com/mikesherov)) -* [`0933c7eaf`](https://github.com/npm/npm/commit/0933c7eaf9cfcdf56471fe4e71c403e2016973da) - [#18025](https://github.com/npm/npm/pull/18025) - Force Travis to use Precise instead of Trusty. We have issues with our - couchdb setup and Trusty. =/ - ([@mikesherov](https://github.com/mikesherov)) -* [`afb086230`](https://github.com/npm/npm/commit/afb086230223f3c4fcddee4e958d18fce5db0ff9) - [#18138](https://github.com/npm/npm/pull/18138) - Fix typos in files-and-ignores test. - ([@supertong](https://github.com/supertong)) -* [`3e6d11cde`](https://github.com/npm/npm/commit/3e6d11cde096b4ee7b07e7569b37186aa2115b1a) - [#18175](https://github.com/npm/npm/pull/18175) - Update dependencies to eliminate transitive dependencies with the WTFPL license, which - some more serious corporate lawyery types aren't super comfortable with. - ([@zkat](https://github.com/zkat)) -* [`ee4c9bd8a`](https://github.com/npm/npm/commit/ee4c9bd8ae574a0d6b24725ba6c7b718d8aaad8d) - [#16474](https://github.com/npm/npm/pull/16474) - The tests in `test/tap/lifecycle-signal.js`, as well as the features - they are testing, are partially broken. This moves them from - being skipped in CI to being disabled only for certain platforms. - In particular, because `npm` spawns its lifecycle scripts in a - shell, signals are not necessarily forwarded by the shell and - won’t cause scripts to exit; also, shells may report the signal - they receive using their exit status, rather than terminating - themselves with a signal. - ([@addaleax](https://github.com/addaleax)) -* [`9462e5d9c`](https://github.com/npm/npm/commit/9462e5d9cfbaa50218de6d0a630d6552e72ad0a8) - [#16547](https://github.com/npm/npm/pull/16547) - Remove unused file: bin/read-package-json.js - ([@metux](https://github.com/metux)) -* [`0756d687d`](https://github.com/npm/npm/commit/0756d687d4ccfcd4a7fd83db0065eceb9261befb) - [#16550](https://github.com/npm/npm/pull/16550) - The build tools for the documentation need to be built/installed - before the documents, even with parallel builds. - Make has a simple mechanism which was made exactly for that: - target dependencies. - ([@metux](https://github.com/metux)) - -## v5.3.0 (2017-07-12): - -As mentioned before, we're continuing to do relatively rapid, smaller releases -as we keep working on stomping out `npm@5` issues! We've made a lot of progress -since 5.0 already, and this release is no exception. - -### FEATURES - -* [`1e3a46944`](https://github.com/npm/npm/commit/1e3a469448b5db8376e6f64022c4c0c78cdb1686) - [#17616](https://github.com/npm/npm/pull/17616) - Add `--link` filter option to `npm ls`. - ([@richardsimko](https://github.com/richardsimko)) -* [`33df0aaa`](https://github.com/npm/npm/commit/33df0aaaa7271dac982b86f2701d10152c4177c8) - `libnpx@9.2.0`: - * 4 new languages - Czech, Italian, Turkish, and Chinese (Traditional)! This means npx is available in 14 different languages! - * New --node-arg option lets you pass CLI arguments directly to node when the target binary is found to be a Node.js script. - ([@zkat](https://github.com/zkat)) - -### BUGFIXES - -* [`33df0aaa`](https://github.com/npm/npm/commit/33df0aaaa7271dac982b86f2701d10152c4177c8) - `libnpx@9.2.0`: - * npx should now work on (most) Windows installs. A couple of issues remain. - * Prevent auto-fallback from going into an infinite loop when npx disappears. - * `npx npx npx npx npx npx npx npx` works again. - * `update-notifier` will no longer run for the npx bundled with npm. - * `npx <cmd>` in a subdirectory of your project should be able to find your `node_modules/.bin` now. Oops - ([@zkat](https://github.com/zkat)) -* [`8e979bf80`](https://github.com/npm/npm/commit/8e979bf80fb93233f19db003f08443e26cfc5e64) - Revert change where npm stopped flattening modules that required peerDeps. - This caused problems because folks were using peer deps to indicate that the - target of the peer dep needed to be able to require the dependency and had - been relying on the fact that peer deps didn't change the shape of the tree - (as of npm@3). - The fix that will actually work for people is for a peer dep to insist on - never being installed deeper than the the thing it relies on. At the moment - this is tricky because the thing the peer dep relies on may not yet have - been added to the tree, so we don't know where it is. - ([@iarna](https://github.com/iarna)) -* [`7f28a77f3`](https://github.com/npm/npm/commit/7f28a77f33ef501065f22e8d5e8cffee3195dccd) - [#17733](https://github.com/npm/npm/pull/17733) - Split remove and unbuild actions into two to get uninstall lifecycles and the - removal of transitive symlinks during uninstallation to run in the right - order. - ([@iarna](https://github.com/iarna)) -* [`637f2548f`](https://github.com/npm/npm/commit/637f2548facae011eebf5e5c38bfe56a6c2db9fa) - [#17748](https://github.com/npm/npm/pull/17748) - When rolling back use symlink project-relative path, fixing some issues with - `fs-vacuum` getting confused while removing symlinked things. - ([@iarna](https://github.com/iarna)) -* [`f153b5b22`](https://github.com/npm/npm/commit/f153b5b22f647d4d403f5b8cecd2ce63ac75b07c) - [#17706](https://github.com/npm/npm/pull/17706) - Use semver to compare node versions in npm doctor instead of plain `>` - comparison. - ([@leo-shopify](https://github.com/leo-shopify)) -* [`542f7561`](https://github.com/npm/npm/commit/542f7561d173eca40eb8d838a16a0ed582fef989) - [#17742](https://github.com/npm/npm/pull/17742) - Fix issue where `npm version` would sometimes not commit package-locks. - ([@markpeterfejes](https://github.com/markpeterfejes)) -* [`51a9e63d`](https://github.com/npm/npm/commit/51a9e63d31cb5ac52259dcf1c364004286072426) - [#17777](https://github.com/npm/npm/pull/17777) - Fix bug exposed by other bugfixes where the wrong package would be removed. - ([@iarna](https://github.com/iarna)) - -### DOCUMENTATION - -Have we mentioned we really like documentation patches? Keep sending them in! -Small patches are just fine, and they're a great way to get started contributing -to npm! - -* [`fb42d55a9`](https://github.com/npm/npm/commit/fb42d55a9a97afa5ab7db38b3b99088cf68684ea) - [#17728](https://github.com/npm/npm/pull/17728) - Document semver git urls in package.json docs. - ([@sankethkatta](https://github.com/sankethkatta)) -* [`f398c700f`](https://github.com/npm/npm/commit/f398c700fb0f2f3665ebf45995a910ad16cd8d05) - [#17684](https://github.com/npm/npm/pull/17684) - Tweak heading hierarchy in package.json docs. - ([@sonicdoe](https://github.com/sonicdoe)) -* [`d5ad65e50`](https://github.com/npm/npm/commit/d5ad65e50a573cdf9df4155225e869cd6c88ca5e) - [#17691](https://github.com/npm/npm/pull/17691) - Explicitly document `--no-save` flag for uninstall. - ([@timneedham](https://github.com/timneedham)) - -## v5.2.0 (2017-07-05): - -It's only been a couple of days but we've got some bug fixes we wanted to -get out to you all. We also believe that -[`npx`](https://medium.com/@maybekatz/introducing-npx-an-npm-package-runner-55f7d4bd282b) is ready to be bundled -with npm, which we're really excited about! - -### npx!!! - -npx is a tool intended to help round out the experience of using packages -from the npm registry — the same way npm makes it super easy to install and -manage dependencies hosted on the registry, npx is meant to make it easy to -use CLI tools and other executables hosted on the registry. It greatly -simplifies a number of things that, until now, required a bit of ceremony to -do with plain npm. - -![](https://cdn-images-1.medium.com/max/1600/1*OlIRsvVO5aK7ja9HmwXz_Q.gif) - -[@zkat](https://github.com/zkat) has a [great introduction post to npx](https://medium.com/@maybekatz/introducing-npx-an-npm-package-runner-55f7d4bd282b) -that I highly recommend you give a read - -* [`fb040bee0`](https://github.com/npm/npm/commit/fb040bee0710759c60e45bf8fa2a3b8ddcf4212a) - [#17685](https://github.com/npm/npm/pull/17685) - Bundle npx with npm itself. - ([@zkat](https://github.com/zkat)) - -### BUG FIXES - -* [`9fe905c39`](https://github.com/npm/npm/commit/9fe905c399d07a3c00c7b22035ddb6b7762731e6) - [#17652](https://github.com/npm/npm/pull/17652) - Fix max callstack exceeded loops with trees with circular links. - ([@iarna](https://github.com/iarna)) -* [`c0a289b1b`](https://github.com/npm/npm/commit/c0a289b1ba6b99652c43a955b23acbf1de0b56ae) - [#17606](https://github.com/npm/npm/pull/17606) - Make sure that when write package.json and package-lock.json we always use unix path separators. - ([@Standard8](https://github.com/Standard8)) -* [`1658b79ca`](https://github.com/npm/npm/commit/1658b79cad89ccece5ae5ce3c2f691d44b933116) - [#17654](https://github.com/npm/npm/pull/17654) - Make `npm outdated` show results for globals again. Previously it never thought they were out of date. - ([@iarna](https://github.com/iarna)) -* [`06c154fd6`](https://github.com/npm/npm/commit/06c154fd653d18725d2e760ba825d43cdd807420) - [#17678](https://github.com/npm/npm/pull/17678) - Stop flattening modules that have peer dependencies. We're making this - change to support scenarios where the module requiring a peer dependency - is flattened but the peer dependency itself is not, due to conflicts. In - those cases the module requiring the peer dep can't be flattened past the - location its peer dep was placed in. This initial fix is naive, never - flattening peer deps, and we can look into doing something more - sophisticated later on. - ([@iarna](https://github.com/iarna)) -* [`88aafee8b`](https://github.com/npm/npm/commit/88aafee8b5b232b7eeb5690279a098d056575791) - [#17677](https://github.com/npm/npm/pull/17677) - There was an issue where updating a flattened dependency would sometimes - unflatten it. This only happened when the dependency had dependencies - that in turn required the original dependency. - ([@iarna](https://github.com/iarna)) -* [`b58ec8eab`](https://github.com/npm/npm/commit/b58ec8eab3b4141e7f1b8b42d8cc24f716a804d8) - [#17626](https://github.com/npm/npm/pull/17626) - Integrators who were building their own copies of npm ran into issues because - `make install` and https://npmjs.com/install.sh weren't aware that - `npm install` creates links now when given a directory to work on. This does not impact folks - installing npm with `npm install -g npm`. - ([@iarna](https://github.com/iarna)) - -### DOC FIXES - -* [`10bef735e`](https://github.com/npm/npm/commit/10bef735e825acc8278827d34df415dfcd8c67d4) - [#17645](https://github.com/npm/npm/pull/17645) - Fix some github issue links in the 5.1.0 changelog - ([@schmod](https://github.com/schmod)) -* [`85fa9dcb2`](https://github.com/npm/npm/commit/85fa9dcb2f0b4f51b515358e0184ec82a5845227) - [#17634](https://github.com/npm/npm/pull/17634) - Fix typo in package-lock docs. - ([@sonicdoe](https://github.com/sonicdoe)) -* [`688699bef`](https://github.com/npm/npm/commit/688699befc2d147288c69a9405fb8354ecaebe36) - [#17628](https://github.com/npm/npm/pull/17628) - Recommend that folks looking for support join us on https://package.community/ or message - [@npm_support](https://twitter.com/npm_support) on Twitter. - ([@strugee](https://github.com/strugee)) - - -## v5.1.0 (2017-07-05): - -Hey y'all~ - -We've got some goodies for you here, including `npm@5`'s first semver-minor -release! This version includes a huge number of fixes, particularly for some of -the critical bugs users were running into after upgrading npm. You should -overall see a much more stable experience, and we're going to continue hacking -on fixes for the time being. Semver-major releases, specially for tools like -npm, are bound to cause some instability, and getting `npm@5` stable is the CLI -team's top priority for now! - -Not that bugfixes are the only things that landed, either: between improvements -that fell out of the bugfixes, and some really cool work by community members -like [@mikesherov](https://github.com/mikesherov), `npm@5.1.0` is **_twice as -fast_** as `npm@5.0.0` in some benchmarks. We're not stopping there, either: you -can expect a steady stream of speed improvements over the course of the year. -It's not _top_ priority, but we'll keep doing what we can to make sure npm saves -its users as much time as possible. - -Hang on to your seats. At **100 commits**, this release is a bit of a doozy. 😎 - -### FEATURES - -Semver-minor releases, of course, mean that there's a new feature somewhere, -right? Here's what's bumping that number for us this time: - -* [`a09c1a69d`](https://github.com/npm/npm/commit/a09c1a69df05b753464cc1272cdccc6af0f4da5a) - [#16687](https://github.com/npm/npm/pull/16687) - Allow customizing the shell used to execute `run-script`s. - ([@mmkal](https://github.com/mmkal)) -* [`4f45ba222`](https://github.com/npm/npm/commit/4f45ba222e2ac6dbe6d696cb7a8e678bbda7c839) [`a48958598`](https://github.com/npm/npm/commit/a489585985540deed4edc03418636c9e97aa9e40) [`901bef0e1`](https://github.com/npm/npm/commit/901bef0e1ea806fc08d8d58744a9f813b6c020ab) - [#17508](https://github.com/npm/npm/pull/17508) - Add a new `requires` field to `package-lock.json` with information about the - _logical_ dependency tree. This includes references to the specific version - each package is intended to see, and can be used for many things, such as - [converting `package-lock.json` to other lockfile - formats](https://twitter.com/maybekatz/status/880578566907248640), various - optimizations, and verifying correctness of a package tree. - ([@iarna](https://github.com/iarna)) -* [`47e8fc8eb`](https://github.com/npm/npm/commit/47e8fc8eb9b5faccef9e03ab991cf37458c16249) - [#17508](https://github.com/npm/npm/pull/17508) - Make `npm ls` take package locks (and shrinkwraps) into account. This means - `npm ls` can now be used to see [which dependencies are - missing](https://twitter.com/maybekatz/status/880446509547794437), so long as - a package lock has been previously generated with it in. - ([@iarna](https://github.com/iarna)) -* [`f0075e7ca`](https://github.com/npm/npm/commit/f0075e7caa3e151424a254d7809ae4489ed8df90) - [#17508](https://github.com/npm/npm/pull/17508) - Take `package.json` changes into account when running installs -- if you - remove or add a dependency to `package.json` manually, npm will now pick that - up and update your tree and package lock accordingly. - ([@iarna](https://github.com/iarna)) -* [`83a5455aa`](https://github.com/npm/npm/commit/83a5455aac3c5cc2511ab504923b652b13bd66a0) - [#17205](https://github.com/npm/npm/pull/17205) - Add `npm udpate` as an alias for `npm update`, for symmetry with - `install`/`isntall`. - ([@gdassori](https://github.com/gdassori)) -* [`57225d394`](https://github.com/npm/npm/commit/57225d394b6174eb0be48393d8e18da0991f67b6) - [#17120](https://github.com/npm/npm/pull/17120) - npm will no longer warn about `preferGlobal`, and the option is now - deprecated. - ([@zkat](https://github.com/zkat)) -* [`82df7bb16`](https://github.com/npm/npm/commit/82df7bb16fc29c47a024db4a8c393e55f883744b) - [#17351](https://github.com/npm/npm/pull/17351) - As some of you may already know `npm build` doesn't do what a lot of people - expect: It's mainly an npm plumbing command, and is part of the more familiar - `npm rebuild` command. That said, a lot of users assume that this is the way - to run an npm `run-script` named `build`, which is an incredibly common script - name to use. To clarify things for users, and encourage them to use `npm run - build` instead, npm will now warn if `npm build` is run without any arguments. - ([@lennym](https://github.com/lennym)) - -### PERFORMANCE - -* [`59f86ef90`](https://github.com/npm/npm/commit/59f86ef90a58d8dc925c9613f1c96e68bee5ec7b) [`43be9d222`](https://github.com/npm/npm/commit/43be9d2222b23ebb0a427ed91824ae217e6d077a) [`e906cdd98`](https://github.com/npm/npm/commit/e906cdd980b4722e66618ce295c682b9a8ffaf8f) - [#16633](https://github.com/npm/npm/pull/16633) - npm now parallelizes tarball extraction across multiple child process workers. - This can significantly speed up installations, specially when installing from - cache, and will improve with number of processors. - ([@zkat](https://github.com/zkat)) -* [`e0849878d`](https://github.com/npm/npm/commit/e0849878dd248de8988c2ef3fc941054625712ca) - [#17441](https://github.com/npm/npm/pull/17441) - Avoid building environment for empty lifecycle scripts. This change alone - accounted for as much as a 15% speed boost for npm installations by outright - skipping entire steps of the installer when not needed. - ([@mikesherov](https://github.com/mikesherov)) -* [`265c2544c`](https://github.com/npm/npm/commit/265c2544c8ded10854909243482e6437ed03c261) - [npm/hosted-git-info#24](https://github.com/npm/hosted-git-info/pull/24) - `hosted-git-info@2.5.0`: Add caching to `fromURL`, which gets called many, - many times by the installer. This improved installation performance by around - 10% on realistic application repositories. - ([@mikesherov](https://github.com/mikesherov)) -* [`901d26cb`](https://github.com/npm/npm/commit/901d26cb656e7e773d9a38ef4eac9263b95e07c8) - [npm/read-package-json#20](https://github.com/npm/read-package-json/pull/70) - `read-package-json@2.0.9`: Speed up installs by as much as 20% by - reintroducing a previously-removed cache and making it actually be correct - this time around. - ([@mikesherov](https://github.com/mikesherov)) -* [`44e37045d`](https://github.com/npm/npm/commit/44e37045d77bc40adf339b423d42bf5e9b4d4d91) - Eliminate `Bluebird.promisifyAll` from our codebase. - ([@iarna](https://github.com/iarna)) -* [`3b4681b53`](https://github.com/npm/npm/commit/3b4681b53db7757985223932072875d099694677) - [#17508](https://github.com/npm/npm/pull/17508) - Stop calling `addBundle` on locked deps, speeding up the - `package-lock.json`-based fast path. - ([@iarna](https://github.com/iarna)) - -### BUGFIXES - -* [#17508](https://github.com/npm/npm/pull/17508) - This is a big PR that fixes a variety of issues when installing from package - locks. If you were previously having issues with missing dependencies or - unwanted removals, this might have fixed it: - * It introduces a new `package-lock.json` field, called `requires`, which tracks which modules a given module requires. - * It fixes [#16839](https://github.com/npm/npm/issues/16839) which was caused by not having this information available, particularly when git dependencies were involved. - * It fixes [#16866](https://github.com/npm/npm/issues/16866), allowing the `package.json` to trump the `package-lock.json`. - * `npm ls` now loads the shrinkwrap, which opens the door to showing a full tree of dependencies even when nothing is yet installed. (It doesn't do that yet though.) - ([@iarna](https://github.com/iarna)) -* [`656544c31`](https://github.com/npm/npm/commit/656544c31cdef3cef64fc10c24f03a8ae2685e35) [`d21ab57c3`](https://github.com/npm/npm/commit/d21ab57c3ef4f01d41fb6c2103debe884a17dc22) - [#16637](https://github.com/npm/npm/pull/16637) - Fix some cases where `npm prune` was leaving some dependencies unpruned if - to-be-pruned dependencies depended on them. - ([@exogen](https://github.com/exogen)) -* [`394436b09`](https://github.com/npm/npm/commit/394436b098dcca2d252061f95c4eeb92c4a7027c) - [#17552](https://github.com/npm/npm/pull/17552) - Make `refresh-package-json` re-verify the package platform. This fixes an - issue most notably experienced by Windows users using `create-react-app` where - `fsevents` would not short-circuit and cause a crash during its - otherwise-skipped native build phase. - ([@zkat](https://github.com/zkat)) -* [`9e5a94354`](https://github.com/npm/npm/commit/9e5a943547b29c8d022192afd9398b3a136a7e5a) - [#17590](https://github.com/npm/npm/pull/17590) - Fix an issue where `npm@5` would crash when trying to remove packages - installed with `npm@<5`. - ([@iarna](https://github.com/iarna)) -* [`c3b586aaf`](https://github.com/npm/npm/commit/c3b586aafa9eabac572eb6e2b8a7266536dbc65b) - [#17141](https://github.com/npm/npm/issues/17141) - Don't update the package.json when modifying packages that don't go there. - This was previously causing `package.json` to get a `"false": {}` field added. - ([@iarna](https://github.com/iarna)) -* [`d04a23de2`](https://github.com/npm/npm/commit/d04a23de21dd9991b32029d839b71e10e07b400d) [`4a5b360d5`](https://github.com/npm/npm/commit/4a5b360d561f565703024085da0927ccafe8793e) [`d9e53db48`](https://github.com/npm/npm/commit/d9e53db48ca227b21bb67df48c9b3580cb390e9e) - `pacote@2.7.38`: - * [zkat/pacote#102](https://github.com/zkat/pacote/pull/102) Fix issue with tar extraction and special characters. - * Enable loose semver parsing in some missing corner cases. - ([@colinrotherham](https://github.com/colinrotherham), [@zkat](https://github.com/zkat), [@mcibique](https://github.com/mcibique)) -* [`e2f815f87`](https://github.com/npm/npm/commit/e2f815f87676b7c50b896e939cee15a01aa976e4) - [#17104](https://github.com/npm/npm/pull/17104) - Write an empty str and wait for flush to exit to reduce issues with npm - exiting before all output is complete when it's a child process. - ([@zkat](https://github.com/zkat)) -* [`835fcec60`](https://github.com/npm/npm/commit/835fcec601204971083aa3a281c3a9da6061a7c2) - [#17060](https://github.com/npm/npm/pull/17060) - Make git repos with prepare scripts always install with both dev and prod - flags. - ([@intellix](https://github.com/intellix)) -* [`f1dc8a175`](https://github.com/npm/npm/commit/f1dc8a175eed56f1ed23bd5773e5e10beaf6cb31) - [#16879](https://github.com/npm/npm/pull/16879) - Fix support for `always-auth` and `_auth`. They are now both available in both - unscoped and registry-scoped configurations. - ([@jozemlakar](https://github.com/jozemlakar)) -* [`ddd8a1ca2`](https://github.com/npm/npm/commit/ddd8a1ca2fa3377199af74ede9d0c1a406d19793) - Serialize package specs to prevent `[object Object]` showing up in logs during - extraction. - ([@zkat](https://github.com/zkat)) -* [`99ef3b52c`](https://github.com/npm/npm/commit/99ef3b52caa7507e87a4257e622f8964b1c1f5f3) - [#17505](https://github.com/npm/npm/pull/17505) - Stop trying to commit updated `npm-shrinkwrap.json` and `package-lock.json` if - they're `.gitignore`d. - ([@zkat](https://github.com/zkat)) -* [`58be2ec59`](https://github.com/npm/npm/commit/58be2ec596dfb0353ad2570e6750e408339f1478) - Make sure uid and gid are getting correctly set even when they're `0`. This - should fix some Docker-related issues with bad permissions/broken ownership. - ([@rgrove](https://github.com/rgrove)) - ([@zkat](https://github.com/zkat)) -* [`9d1e3b6fa`](https://github.com/npm/npm/commit/9d1e3b6fa01bb563d76018ee153259d9507658cf) - [#17506](https://github.com/npm/npm/pull/17506) - Skip writing package.json and locks if on-disk version is identical to the new - one. - ([@zkat](https://github.com/zkat)) -* [`3fc6477a8`](https://github.com/npm/npm/commit/3fc6477a89773786e6c43ef43a23e5cdc662ff8e) - [#17592](https://github.com/npm/npm/pull/17592) - Fix an issue where `npm install -g .` on a package with no `name` field would - cause the entire global `node_modules` directory to be replaced with a symlink - to `$CWD`. lol. - ([@iarna](https://github.com/iarna)) -* [`06ba0a14a`](https://github.com/npm/npm/commit/06ba0a14a6c1c8cdcc8c062b68c8c63041b0cec0) - [#17591](https://github.com/npm/npm/pull/17591) - Fix spurious removal reporting: if you tried to remove something that didn't - actually exist, npm would tell you it removed 1 package even though there was - nothing to do. - ([@iarna](https://github.com/iarna)) -* [`20ff05f8`](https://github.com/npm/npm/commit/20ff05f8fe0ad8c36e1323d30b63b4d2ff7e11ef) - [#17629](https://github.com/npm/npm/pull/17629) - When removing a link, keep dependencies installed inside of it instead of - removing them, if the link is outside the scope of the current project. This - fixes an issue where removing globally-linked packages would remove all their - dependencies in the source directory, as well as some ergonomic issues when - using links in other situations. - ([@iarna](https://github.com/iarna)) - -### DOCS - -* [`fd5fab595`](https://github.com/npm/npm/commit/fd5fab5955a20a9bb8c0e77092ada1435f73a8d2) - [#16441](https://github.com/npm/npm/pull/16441) - Add spec for `npm-shrinkwrap.json` and `package-lock.json` from RFC. - ([@iarna](https://github.com/iarna)) -* [`9589c1ccb`](https://github.com/npm/npm/commit/9589c1ccb3f794abaaa48c2a647ada311dd881ef) - [#17451](https://github.com/npm/npm/pull/17451) - Fix typo in changelog. - ([@watilde](https://github.com/watilde)) -* [`f8e76d856`](https://github.com/npm/npm/commit/f8e76d8566ae1965e57d348df74edad0643b66a6) - [#17370](https://github.com/npm/npm/pull/17370) - Correct the default prefix config path for Windows operating systems in the - documentation for npm folders. - ([@kierendixon](https://github.com/kierendixon)) -* [`d0f3b5a12`](https://github.com/npm/npm/commit/d0f3b5a127718b0347c6622a2b9c28341c530d36) - [#17369](https://github.com/npm/npm/pull/17369) - Fix `npm-config` reference to `userconfig` & `globalconfig` environment - variables. - ([@racztiborzoltan](https://github.com/racztiborzoltan)) -* [`87629880a`](https://github.com/npm/npm/commit/87629880a71baec352c1b5345bc29268d6212467) - [#17336](https://github.com/npm/npm/pull/17336) - Remove note in docs about `prepublish` being entirely removed. - ([@Hirse](https://github.com/Hirse)) -* [`a1058afd9`](https://github.com/npm/npm/commit/a1058afd9a7a569bd0ac65b86eadd4fe077a7221) - [#17169](https://github.com/npm/npm/pull/17169) - Document `--no-package-lock` flag. - ([@leggsimon](https://github.com/leggsimon)) -* [`32fc6e41a`](https://github.com/npm/npm/commit/32fc6e41a2ce4dbcd5ce1e5f291e2e2efc779d48) - [#17250](https://github.com/npm/npm/pull/17250) - Fix a typo in the shrinkwrap docs. - ([@Zarel](https://github.com/Zarel)) -* [`f19bd3c8c`](https://github.com/npm/npm/commit/f19bd3c8cbd37c8a99487d6b5035282580ac3e9d) - [#17249](https://github.com/npm/npm/pull/17249) - Fix a package-lock.json cross-reference link. - ([@not-an-aardvark](https://github.com/not-an-aardvark)) -* [`153245edc`](https://github.com/npm/npm/commit/153245edc4845db670ada5e95ef384561706a751) - [#17075](https://github.com/npm/npm/pull/17075/files) - Fix a typo in `npm-config` docs. - ([@KennethKinLum](https://github.com/KennethKinLum)) -* [`c9b534a14`](https://github.com/npm/npm/commit/c9b534a148818d1a97787c0dfdba5f64ce3618a6) - [#17074](https://github.com/npm/npm/pull/17074) - Clarify config documentation with multiple boolean flags. - ([@KennethKinLum](https://github.com/KennethKinLum)) -* [`e111b0a40`](https://github.com/npm/npm/commit/e111b0a40c4bc6691d7b8d67ddce5419e67bfd27) - [#16768](https://github.com/npm/npm/pull/16768) - Document the `-l` option to `npm config list`. - ([@happylynx](https://github.com/happylynx)) -* [`5a803ebad`](https://github.com/npm/npm/commit/5a803ebadd61229bca3d64fb3ef1981729b2548e) - [#16548](https://github.com/npm/npm/pull/16548) - Fix permissions for documentation files. Some of them had `+x` set. (???) - ([@metux](https://github.com/metux)) -* [`d57d4f48c`](https://github.com/npm/npm/commit/d57d4f48c6cd00fdf1e694eb49e9358071d8e105) - [#17319](https://github.com/npm/npm/pull/17319) - Document that the `--silent` option for `npm run-script` can be used to - suppress `npm ERR!` output on errors. - ([@styfle](https://github.com/styfle)) - -### MISC - -Not all contributions need to be visible features, docs, or bugfixes! It's super -helpful when community members go over our code and help clean it up, too! - -* [`9e5b76140`](https://github.com/npm/npm/commit/9e5b76140ffdb7dcd12aa402793644213fb8c5d7) - [#17411](https://github.com/npm/npm/pull/17411) - Convert all callback-style `move` usage to use Promises. - ([@vramana](https://github.com/vramana)) -* [`0711c08f7`](https://github.com/npm/npm/commit/0711c08f779ac641ec42ecc96f604c8861008b28) - [#17394](https://github.com/npm/npm/pull/17394) - Remove unused argument in `deepSortObject`. - ([@vramana](https://github.com/vramana)) -* [`7d650048c`](https://github.com/npm/npm/commit/7d650048c8ed5faa0486492f1eeb698e7383e32f) - [#17563](https://github.com/npm/npm/pull/17563) - Refactor some code to use `Object.assign`. - ([@vramana](https://github.com/vramana)) -* [`993f673f0`](https://github.com/npm/npm/commit/993f673f056aea5f602ea04b1e697b027c267a2d) - [#17600](https://github.com/npm/npm/pull/17600) - Remove an old comment. - ([@vramana](https://github.com/vramana)) - -## v5.0.4 (2017-06-13): - -Hey y'all. This is another minor patch release with a variety of little fixes -we've been accumulating~ - -* [`f0a37ace9`](https://github.com/npm/npm/commit/f0a37ace9ab7879cab20f2b0fcd7840bfc305feb) - Fix `npm doctor` when hitting registries without `ping`. - ([@zkat](https://github.com/zkat)) -* [`64f0105e8`](https://github.com/npm/npm/commit/64f0105e81352b42b72900d83b437b90afc6d9ce) - Fix invalid format error when setting cache-related headers. - ([@zkat](https://github.com/zkat)) -* [`d2969c80e`](https://github.com/npm/npm/commit/d2969c80e4178faebf0f7c4cab6eb610dd953cc6) - Fix spurious `EINTEGRITY` issue. - ([@zkat](https://github.com/zkat)) -* [`800cb2b4e`](https://github.com/npm/npm/commit/800cb2b4e2d0bd00b5c9082a896f2110e907eb0b) - [#17076](https://github.com/npm/npm/pull/17076) - Use legacy `from` field to improve upgrade experience from legacy shrinkwraps - and installs. - ([@zkat](https://github.com/zkat)) -* [`4100d47ea`](https://github.com/npm/npm/commit/4100d47ea58b4966c02604f71350b5316108df6a) - [#17007](https://github.com/npm/npm/pull/17007) - Restore loose semver parsing to match older npm behavior when running into - invalid semver ranges in dependencies. - ([@zkat](https://github.com/zkat)) -* [`35316cce2`](https://github.com/npm/npm/commit/35316cce2ca2d8eb94161ec7fe7e8f7bec7b3aa7) - [#17005](https://github.com/npm/npm/pull/17005) - Emulate npm@4's behavior of simply marking the peerDep as invalid, instead of - crashing. - ([@zkat](https://github.com/zkat)) -* [`e7e8ee5c5`](https://github.com/npm/npm/commit/e7e8ee5c57c7238655677e118a8809b652019f53) - [#16937](https://github.com/npm/npm/pull/16937) - Workaround for separate bug where `requested` was somehow null. - ([@forivall](https://github.com/forivall)) -* [`2d9629bb2`](https://github.com/npm/npm/commit/2d9629bb2043cff47eaad2654a64d2cef5725356) - Better logging output for git errors. - ([@zkat](https://github.com/zkat)) -* [`2235aea73`](https://github.com/npm/npm/commit/2235aea73569fb9711a06fa6344ef31247177dcd) - More scp-url fixes: parsing only worked correctly when a committish was - present. - ([@zkat](https://github.com/zkat)) -* [`80c33cf5e`](https://github.com/npm/npm/commit/80c33cf5e6ef207450949764de41ea96538c636e) - Standardize package permissions on tarball extraction, instead of using perms - from the tarball. This matches previous npm behavior and fixes a number of - incompatibilities in the wild. - ([@zkat](https://github.com/zkat)) -* [`2b1e40efb`](https://github.com/npm/npm/commit/2b1e40efba0b3d1004259efa4275cf42144e3ce3) - Limit shallow cloning to hosts which are known to support it. - ([@zkat](https://github.com/zkat)) - -## v5.0.3 (2017-06-05) - -Happy Monday, y'all! We've got another npm release for you with the fruits of -our ongoing bugsquashing efforts. You can expect at least one more this week, -but probably more -- and as we announced last week, we'll be merging fixes more -rapidly into the `npmc` canary so you can get everything as soon as possible! - -Hope y'all are enjoying npm5 in the meantime, and don't hesitate to file issues -for anything you find! The goal is to get this release rock-solid as soon as we -can. 💚 - -* [`6e12a5cc0`](https://github.com/npm/npm/commit/6e12a5cc022cb5a157a37df7283b6d7b3d49bdab) - Bump several dependencies to get improvements and bugfixes: - * `cacache`: content files (the tarballs) are now read-only. - * `pacote`: fix failing clones with bad heads, send extra TLS-related opts to proxy, enable global auth configurations and `_auth`-based auth. - * `ssri`: stop crashing with `can't call method find of undefined` when running into a weird `opts.integrity`/`opts.algorithms` conflict during verification. - ([@zkat](https://github.com/zkat)) -* [`89cc8e3e1`](https://github.com/npm/npm/commit/89cc8e3e12dad67fd9844accf4d41deb4c180c5c) - [#16917](https://github.com/npm/npm/pull/16917) - Send `ca`, `cert` and `key` config through to network layer. - ([@colinrotherham](https://github.com/colinrotherham)) -* [`6a9b51c67`](https://github.com/npm/npm/commit/6a9b51c67ba3df0372991631992748329b84f2e7) - [#16929](https://github.com/npm/npm/pull/16929) - Send `npm-session` header value with registry requests again. - ([@zarenner](https://github.com/zarenner)) -* [`662a15ab7`](https://github.com/npm/npm/commit/662a15ab7e790e87f5e5a35252f05d5a4a0724a1) - Fix `npm doctor` so it stop complaining about read-only content files in the - cache. - ([@zkat](https://github.com/zkat)) -* [`191d10a66`](https://github.com/npm/npm/commit/191d10a6616d72e26d89fd00f5a4f6158bfbc526) - [#16918](https://github.com/npm/npm/pull/16918) - Clarify prepublish deprecation message. - ([@Hirse](https://github.com/Hirse)) - -## v5.0.2 (2017-06-02) - -Here's another patch release, soon after the other! - -This particular release includes a slew of fixes to npm's git support, which was -causing some issues for a chunk of people, specially those who were using -self-hosted/Enterprise repos. All of those should be back in working condition -now. - -There's another shiny thing you might wanna know about: npm has a Canary release -now! The `npm5` experiment we did during our beta proved to be incredibly -successful: users were able to have a tight feedback loop between reports and -getting the bugfixes they needed, and the CLI team was able to roll out -experimental patches and have the community try them out right away. So we want -to keep doing that. - -From now on, you'll be able to install the 'npm canary' with `npm i -g npmc`. -This release will be a separate binary (`npmc`. Because canary. Get it?), which -will update independently of the main CLI. Most of the time, this will track -`release-next` or something close to it. We might occasionally toss experimental -branches in there to see if our more adventurous users run into anything -interesting with it. For example, the current canary (`npmc@5.0.1-canary.6`) -includes an [experimental multiproc -branch](https://github.com/npm/npm/pull/16633) that parallelizes tarball -extraction across multiple processes. - -If you find any issues while running the canary version, please report them and -let us know it came from `npmc`! It would be tremendously helpful, and finding -things early is a huge reason to have it there. Happy hacking! - -### A NOTE ABOUT THE ISSUE TRACKER - -Just a heads up: We're preparing to do a massive cleanup of the issue tracker. -It's been a long time since it was something we could really keep up with, and -we didn't have a process for dealing with it that could actually be sustainable. - -We're still sussing the details out, and we'll talk about it more when we're -about to do it, but the plan is essentially to close old, abandoned issues and -start over. We will also [add some automation](https://github.com/probot) around -issue management so that things that we can't keep up with don't just stay -around forever. - -Stay tuned! - -### GIT YOLO - -* [`1f26e9567`](https://github.com/npm/npm/commit/1f26e9567a6d14088704e121ebe787c38b6849a4) - `pacote@2.7.27`: Fixes installing committishes that look like semver, even - though they're not using the required `#semver:` syntax. - ([@zkat](https://github.com/zkat)) -* [`85ea1e0b9`](https://github.com/npm/npm/commit/85ea1e0b9478551265d03d545e7dc750b9edf547) - `npm-package-arg@5.1.1`: This includes the npa git-parsing patch to make it so - non-hosted SCP-style identifiers are correctly handled. Previously, npa would - mangle them (even though hosted-git-info is doing the right thing for them). - ([@zkat](https://github.com/zkat)) - -### COOL NEW OUTPUT - -The new summary output has been really well received! One downside that reared -its head as more people used it, though, is that it doesn't really tell you -anything about the toplevel versions it installed. So, if you did `npm i -g -foo`, it would just say "added 1 package". This patch by -[@rmg](https://github.com/rmg) keeps things concise while still telling you -what you got! So now, you'll see something like this: - -``` -$ npm i -g foo bar -+ foo@1.2.3 -+ bar@3.2.1 -added 234 packages in .005ms -``` - -* [`362f9fd5b`](https://github.com/npm/npm/commit/362f9fd5bec65301082416b4292b8fe3eb7f824a) - [#16899](https://github.com/npm/npm/pull/16899) - For every package that is given as an argument to install, print the name and - version that was actually installed. - ([@rmg](https://github.com/rmg)) - -### OTHER BUGFIXES - -* [`a47593a98`](https://github.com/npm/npm/commit/a47593a98a402143081d7077d2ac677d13083010) - [#16835](https://github.com/npm/npm/pull/16835) - Fix a crash while installing with `--no-shrinkwrap`. - ([@jacknagel](https://github.com/jacknagel)) - -### DOC UPDATES - -* [`89e0cb816`](https://github.com/npm/npm/commit/89e0cb8165dd9c3c7ac74d531617f367099608f4) - [#16818](https://github.com/npm/npm/pull/16818) - Fixes a spelling error in the docs. Because the CLI team has trouble spelling - "package", I guess. - ([@ankon](https://github.com/ankon)) -* [`c01fbc46e`](https://github.com/npm/npm/commit/c01fbc46e151bcfb359fd68dd7faa392789b4f55) - [#16895](https://github.com/npm/npm/pull/16895) - Remove `--save` from `npm init` instructions, since it's now the default. - ([@jhwohlgemuth](https://github.com/jhwohlgemuth)) -* [`80c42d218`](https://github.com/npm/npm/commit/80c42d2181dd4d1b79fcee4e9233df268dfb30b7) - Guard against cycles when inflating bundles, as symlinks are bundles now. - ([@iarna](https://github.com/iarna)) -* [`7fe7f8665`](https://github.com/npm/npm/commit/7fe7f86658798db6667df89afc75588c0e43bc94) - [#16674](https://github.com/npm/npm/issues/16674) - Write the builtin config for `npmc`, not just `npm`. This is hardcoded for npm - self-installations and is needed for Canary to work right. - ([@zkat](https://github.com/zkat)) - -### DEP UPDATES - -* [`63df4fcdd`](https://github.com/npm/npm/commit/63df4fcddc7445efb50cc7d8e09cdd45146d3e39) - [#16894](https://github.com/npm/npm/pull/16894) - [`node-gyp@3.6.2`](https://github.com/nodejs/node-gyp/blob/master/CHANGELOG.md#v362-2017-06-01): - Fixes an issue parsing SDK versions on Windows, among other things. - ([@refack](https://github.com/refack)) -* [`5bb15c3c4`](https://github.com/npm/npm/commit/5bb15c3c4f0d7d77c73fd6dafa38ac36549b6e00) - `read-package-tree@5.1.6`: Fixes some racyness while reading the tree. - ([@iarna](https://github.com/iarna)) -* [`a6f7a52e7`](https://github.com/npm/npm/commit/a6f7a52e7) - `aproba@1.1.2`: Remove nested function declaration for speed up - ([@mikesherov](https://github.com/mikesherov)) - -## v5.0.1 (2017-05-31): - -Hey y'all! Hope you're enjoying the new npm! - -As you all know, fresh software that's gone through major overhauls tends to -miss a lot of spots the old one used to handle well enough, and `npm@5` is no -exception. The CLI team will be doing faster release cycles that go directly to -the `latest` tag for a couple of weeks while 5 stabilizes a bit and we're -confident the common low-hanging fruit people are running into are all taken -care of. - -With that said: this is our first patch release! The biggest focus is fixing up -a number of git-related issues that folks ran into right out the door. It also -fixes other things, like some proxy/auth-related issues, and even has a neat -speed boost! (You can expect more speed bumps in the coming releases as pending -work starts landing, too!) - -Thanks everyone who's been reporting issues and submitting patches! - -### BUGFIXES - -* [`e61e68dac`](https://github.com/npm/npm/commit/e61e68dac4fa51c0540a064204a75b19f8052e58) - [#16762](https://github.com/npm/npm/pull/16762) - Make `npm publish` obey the `--tag` flag again. - ([@zkat](https://github.com/zkat)) -* [`923fd58d3`](https://github.com/npm/npm/commit/923fd58d312f40f8c17b232ad1dfc8e2ff622dbd) - [#16749](https://github.com/npm/npm/pull/16749) - Speed up installations by nearly 20% by... removing one line of code. (hah) - ([@mikesherov](https://github.com/mikesherov)) -* [`9aac984cb`](https://github.com/npm/npm/commit/9aac984cbbfef22182ee42b51a193c0b47146ad6) - Guard against a particular failure mode for a bug still being hunted down. - ([@iarna](https://github.com/iarna)) -* [`80ab521f1`](https://github.com/npm/npm/commit/80ab521f18d34df109de0c5dc9eb1cde5ff6d7e8) - Pull in dependency updates for various core deps: - * New `pacote` fixes several git-related bugs. - * `ssri` update fixes crash on early node@4 versions. - * `make-fetch-happen` update fixes proxy authentication issue. - * `npm-user-validate` adds regex for blocking usernames with illegal chars. - ([@zkat](https://github.com/zkat)) -* [`7e5ce87b8`](https://github.com/npm/npm/commit/7e5ce87b84880c7433ee4c07d2dd6ce8806df436) - `pacote@2.7.26`: - Fixes various other git issues related to commit hashes. - ([@zkat](https://github.com/zkat)) -* [`acbe85bfc`](https://github.com/npm/npm/commit/acbe85bfc1a68d19ca339a3fb71da0cffbf58926) - [#16791](https://github.com/npm/npm/pull/16791) - `npm view` was calling `cb` prematurely and giving partial output when called - in a child process. - ([@zkat](https://github.com/zkat)) -* [`ebafe48af`](https://github.com/npm/npm/commit/ebafe48af91f702ccefc8c619d52fed3b8dfd3c7) - [#16750](https://github.com/npm/npm/pull/16750) - Hamilpatch the Musical: Talk less, complete more. - ([@aredridel](https://github.com/aredridel)) - -### DOCUMENTATION - -* [`dc2823a6c`](https://github.com/npm/npm/commit/dc2823a6c5fc098041e61515c643570819d059d2) - [#16799](https://github.com/npm/npm/pull/16799) - Document that `package-lock.json` is never allowed in tarballs. - ([@sonicdoe](https://github.com/sonicdoe)) -* [`f3cb84b44`](https://github.com/npm/npm/commit/f3cb84b446c51d628ee0033cdf13752c15b31a29) - [#16771](https://github.com/npm/npm/pull/16771) - Fix `npm -l` usage information for the `test` command. - ([@grawlinson](https://github.com/grawlinson)) - -### OTHER CHANGES - -* [`661262309`](https://github.com/npm/npm/commit/66126230912ab5ab35287b40a9908e036fa73994) - [#16756](https://github.com/npm/npm/pull/16756) - remove unused argument - ([@Aladdin-ADD](https://github.com/Aladdin-ADD)) -* [`c3e0b4287`](https://github.com/npm/npm/commit/c3e0b4287ea69735cc367aa7bb7e7aa9a6d9804b) - [#16296](https://github.com/npm/npm/pull/16296) - preserve same name convention for command - ([@desfero](https://github.com/desfero)) -* [`9f814831d`](https://github.com/npm/npm/commit/9f814831d330dde7702973186aea06caaa77ff31) - [#16757](https://github.com/npm/npm/pull/16757) - remove unused argument - ([@Aladdin-ADD](https://github.com/Aladdin-ADD)) -* [`3cb843239`](https://github.com/npm/npm/commit/3cb8432397b3666d88c31131dbb4599016a983ff) - minor linter fix - ([@zkat](https://github.com/zkat)) - -## v5.0.0 (2017-05-25) - -Wowowowowow npm@5! - -This release marks months of hard work for the young, scrappy, and hungry CLI -team, and includes some changes we've been hoping to do for literally years. -npm@5 takes npm a pretty big step forward, significantly improving its -performance in almost all common situations, fixing a bunch of old errors due to -the architecture, and just generally making it more robust and fault-tolerant. -It comes with changes to make life easier for people doing monorepos, for users -who want consistency/security guarantees, and brings semver support to git -dependencies. See below for all the deets! - -### Breaking Changes - -* Existing npm caches will no longer be used: you will have to redownload any cached packages. There is no tool or intention to reuse old caches. ([#15666](https://github.com/npm/npm/pull/15666)) - -* `npm install ./packages/subdir` will now create a symlink instead of a regular installation. `file://path/to/tarball.tgz` will not change -- only directories are symlinked. ([#15900](https://github.com/npm/npm/pull/15900)) - -* npm will now scold you if you capitalize its name. seriously it will fight you. - -* [npm will `--save` by default now](https://twitter.com/maybekatz/status/859229741676625920). Additionally, `package-lock.json` will be automatically created unless an `npm-shrinkwrap.json` exists. ([#15666](https://github.com/npm/npm/pull/15666)) - -* Git dependencies support semver through `user/repo#semver:^1.2.3` ([#15308](https://github.com/npm/npm/pull/15308)) ([#15666](https://github.com/npm/npm/pull/15666)) ([@sankethkatta](https://github.com/sankethkatta)) - -* Git dependencies with `prepare` scripts will have their `devDependencies` installed, and `npm install` run in their directory before being packed. - -* `npm cache` commands have been rewritten and don't really work anything like they did before. ([#15666](https://github.com/npm/npm/pull/15666)) - -* `--cache-min` and `--cache-max` have been deprecated. ([#15666](https://github.com/npm/npm/pull/15666)) - -* Running npm while offline will no longer insist on retrying network requests. npm will now immediately fall back to cache if possible, or fail. ([#15666](https://github.com/npm/npm/pull/15666)) - -* package locks no longer exclude `optionalDependencies` that failed to build. This means package-lock.json and npm-shrinkwrap.json should now be cross-platform. ([#15900](https://github.com/npm/npm/pull/15900)) - -* If you generated your package lock against registry A, and you switch to registry B, npm will now try to [install the packages from registry B, instead of A](https://twitter.com/maybekatz/status/862834964932435969). If you want to use different registries for different packages, use scope-specific registries (`npm config set @myscope:registry=https://myownregist.ry/packages/`). Different registries for different unscoped packages are not supported anymore. - -* Shrinkwrap and package-lock no longer warn and exit without saving the lockfile. - -* Local tarballs can now only be installed if they have a file extensions `.tar`, `.tar.gz`, or `.tgz`. - -* A new loglevel, `notice`, has been added and set as default. - -* One binary to rule them all: `./cli.js` has been removed in favor of `./bin/npm-cli.js`. In case you were doing something with `./cli.js` itself. ([#12096](https://github.com/npm/npm/pull/12096)) ([@watilde](https://github.com/watilde)) - -* Stub file removed ([#16204](https://github.com/npm/npm/pull/16204)) ([@watilde](https://github.com/watilde)) - -* The "extremely legacy" `_token` couchToken has been removed. ([#12986](https://github.com/npm/npm/pull/12986)) - -### Feature Summary - -#### Installer changes - -* A new, standardised lockfile feature meant for cross-package-manager compatibility (`package-lock.json`), and a new format and semantics for shrinkwrap. ([#16441](https://github.com/npm/npm/pull/16441)) - -* `--save` is no longer necessary. All installs will be saved by default. You can prevent saving with `--no-save`. Installing optional and dev deps is unchanged: use `-D/--save-dev` and `-O/--save-optional` if you want them saved into those fields instead. Note that since npm@3, npm will automatically update npm-shrinkwrap.json when you save: this will also be true for `package-lock.json`. ([#15666](https://github.com/npm/npm/pull/15666)) - -* Installing a package directory now ends up creating a symlink and does the Right Thing™ as far as saving to and installing from the package lock goes. If you have a monorepo, this might make things much easier to work with, and probably a lot faster too. 😁 ([#15900](https://github.com/npm/npm/pull/15900)) - -* Project-level (toplevel) `preinstall` scripts now run before anything else, and can modify `node_modules` before the CLI reads it. - -* Two new scripts have been added, `prepack` and `postpack`, which will run on both `npm pack` and `npm publish`, but NOT on `npm install` (without arguments). Combined with the fact that `prepublishOnly` is run before the tarball is generated, this should round out the general story as far as putzing around with your code before publication. - -* Git dependencies with `prepare` scripts will now [have their devDependencies installed, and their prepare script executed](https://twitter.com/maybekatz/status/860363896443371520) as if under `npm pack`. - -* Git dependencies now support semver-based matching: `npm install git://github.com/npm/npm#semver:^5` (#15308, #15666) - -* `node-gyp` now supports `node-gyp.cmd` on Windows ([#14568](https://github.com/npm/npm/pull/14568)) - -* npm no longer blasts your screen with the whole installed tree. Instead, you'll see a summary report of the install that is much kinder on your shell real-estate. Specially for large projects. ([#15914](https://github.com/npm/npm/pull/15914)): -``` -$ npm install -npm added 125, removed 32, updated 148 and moved 5 packages in 5.032s. -$ -``` - -* `--parseable` and `--json` now work more consistently across various commands, particularly `install` and `ls`. - -* Indentation is now [detected and preserved](https://twitter.com/maybekatz/status/860690502932340737) for `package.json`, `package-lock.json`, and `npm-shrinkwrap.json`. If the package lock is missing, it will default to `package.json`'s current indentation. - -#### Publishing - -* New [publishes will now include *both* `sha512`](https://twitter.com/maybekatz/status/863201943082065920) and `sha1` checksums. Versions of npm from 5 onwards will use the strongest algorithm available to verify downloads. [npm/npm-registry-client#157](https://github.com/npm/npm-registry-client/pull/157) - -#### Cache Rewrite! - -We've been talking about rewriting the cache for a loooong time. So here it is. -Lots of exciting stuff ahead. The rewrite will also enable some exciting future -features, but we'll talk about those when they're actually in the works. #15666 -is the main PR for all these changes. Additional PRs/commits are linked inline. - -* Package metadata, package download, and caching infrastructure replaced. - -* It's a bit faster. [Hopefully it will be noticeable](https://twitter.com/maybekatz/status/865393382260056064). 🤔 - -* With the shrinkwrap and package-lock changes, tarballs will be looked up in the cache by content address (and verified with it). - -* Corrupted cache entries will [automatically be removed and re-fetched](https://twitter.com/maybekatz/status/854933138182557696) on integrity check failure. - -* npm CLI now supports tarball hashes with any hash function supported by Node.js. That is, it will [use `sha512` for tarballs from registries that send a `sha512` checksum as the tarball hash](https://twitter.com/maybekatz/status/858137093624573953). Publishing with `sha512` is added by [npm/npm-registry-client#157](https://github.com/npm/npm-registry-client/pull/157) and may be backfilled by the registry for older entries. - -* Remote tarball requests are now cached. This means that even if you're missing the `integrity` field in your shrinkwrap or package-lock, npm will be able to install from the cache. - -* Downloads for large packages are streamed in and out of disk. npm is now able to install packages of """any""" size without running out of memory. Support for publishing them is pending (due to registry limitations). - -* [Automatic fallback-to-offline mode](https://twitter.com/maybekatz/status/854176565587984384). npm will seamlessly use your cache if you are offline, or if you lose access to a particular registry (for example, if you can no longer access a private npm repo, or if your git host is unavailable). - -* A new `--prefer-offline` option will make npm skip any conditional requests (304 checks) for stale cache data, and *only* hit the network if something is missing from the cache. - -* A new `--prefer-online` option that will force npm to revalidate cached data (with 304 checks), ignoring any staleness checks, and refreshing the cache with revalidated, fresh data. - -* A new `--offline` option will force npm to use the cache or exit. It will error with an `ENOTCACHED` code if anything it tries to install isn't already in the cache. - -* A new `npm cache verify` command that will garbage collect your cache, reducing disk usage for things you don't need (-handwave-), and will do full integrity verification on both the index and the content. This is also hooked into `npm doctor` as part of its larger suite of checking tools. - -* The new cache is *very* fault tolerant and supports concurrent access. - * Multiple npm processes will not corrupt a shared cache. - * Corrupted data will not be installed. Data is checked on both insertion and extraction, and treated as if it were missing if found to be corrupted. I will literally bake you a cookie if you manage to corrupt the cache in such a way that you end up with the wrong data in your installation (installer bugs notwithstanding). - * `npm cache clear` is no longer useful for anything except clearing up disk space. - -* Package metadata is cached separately per registry and package type: you can't have package name conflicts between locally-installed packages, private repo packages, and public repo packages. Identical tarball data will still be shared/deduplicated as long as their hashes match. - -* HTTP cache-related headers and features are "fully" (lol) supported for both metadata and tarball requests -- if you have your own registry, you can define your own cache settings the CLI will obey! - -* `prepublishOnly` now runs *before* the tarball to publish is created, after `prepare` has run. diff --git a/changelogs/CHANGELOG-6.md b/changelogs/CHANGELOG-6.md deleted file mode 100644 index 0f07a68..0000000 --- a/changelogs/CHANGELOG-6.md +++ /dev/null @@ -1,2910 +0,0 @@ -## 6.14.8 (2020-08-17) - -### BUG FIXES -* [`9262e8c88`](https://github.com/npm/cli/commit/9262e8c88f2f828206423928b8e21eea67f4801a) - [#1575](https://github.com/npm/cli/pull/1575) - npm install --dev deprecation message - ([@sandratatarevicova](https://github.com/sandratatarevicova)) -* [`765cfe0bc`](https://github.com/npm/cli/commit/765cfe0bc05a10b72026291ff0ca7c9ca5cb3f57) - [#1658](https://github.com/npm/cli/issues/1658) - remove unused broken require - ([@aduh95](https://github.com/aduh95)) -* [`4e28de79a`](https://github.com/npm/cli/commit/4e28de79a3a0aacc7603010a592beb448ceb6f5f) - [#1663](https://github.com/npm/cli/pull/1663) - Do not send user secret in the referer header - ([@assapir](https://github.com/assapir)) - -### DOCUMENTATION -* [`8abdf30c9`](https://github.com/npm/cli/commit/8abdf30c95ec90331456f3f2ed78e2703939bb74) - [#1572](https://github.com/npm/cli/pull/1572) - docs: add missing metadata in semver page - ([@tripu](https://github.com/tripu)) -* [`8cedcca46`](https://github.com/npm/cli/commit/8cedcca464ced5aab58be83dd5049c3df13384de) - [#1614](https://github.com/npm/cli/pull/1614) - Node-gyp supports both Python and legacy Python - ([@cclauss](https://github.com/cclauss)) - -### DEPENDENCIES -* [`a303b75fd`](https://github.com/npm/cli/commit/a303b75fd7c4b2644da02ad2ad46d80dfceec3c5) - `update-notifier@2.5.0` -* [`c48600832`](https://github.com/npm/cli/commit/c48600832aff4cc349f59997e08dc4bbde15bd49) - `npm-registry-fetch@4.0.7` -* [`a6e9fc4df`](https://github.com/npm/cli/commit/a6e9fc4df7092ba3eb5394193638b33c24855c36) - `meant@1.0.2`: - -## 6.14.7 (2020-07-21) - -### BUG FIXES -* [`de5108836`](https://github.com/npm/cli/commit/de5108836189bddf28d4d3542f9bd5869cc5c2e9) [#784](https://github.com/npm/cli/pull/784) npm explore spawn shell correctly ([@jasisk](https://github.com/jasisk)) -* [`36e6c01d3`](https://github.com/npm/cli/commit/36e6c01d334c4db75018bc6a4a0bef726fd41ce4) git tag handling regression on shrinkwrap ([@claudiahdz](https://github.com/claudiahdz)) -* [`1961c9369`](https://github.com/npm/cli/commit/1961c9369c92bf8fe530cecba9834ca3c7f5567c) [#288](https://github.com/npm/cli/pull/288) Fix package id in shrinkwrap lifecycle step output ([@bz2](https://github.com/bz2)) -* [`87888892a`](https://github.com/npm/cli/commit/87888892a1282cc3edae968c3ae4ec279189271c) [#1009](https://github.com/npm/cli/pull/1009) gracefully handle error during npm install ([@danielleadams](https://github.com/danielleadams)) -* [`6fe2bdc25`](https://github.com/npm/cli/commit/6fe2bdc25e7961956e5c0067fa4db54ff1bd0dbd) [#1547](https://github.com/npm/cli/pull/1547) npm ls --parseable --long output ([@ruyadorno](https://github.com/ruyadorno)) - -### DEPENDENCIES -* [`2d78481c7`](https://github.com/npm/cli/commit/2d78481c7ec178e628ce23df940f73a05d5c6367) update mkdirp on tacks ([@claudiahdz](https://github.com/claudiahdz)) -* [`4e129d105`](https://github.com/npm/cli/commit/4e129d105eba3b12d474caa6e5ca216a98deb75a) uninstall npm-registry-couchapp ([@claudiahdz](https://github.com/claudiahdz)) -* [`8e1869e27`](https://github.com/npm/cli/commit/8e1869e278d1dd37ddefd6b4e961d1bb17fc9d09) update marked dev dep ([@claudiahdz](https://github.com/claudiahdz)) -* [`6a6151f37`](https://github.com/npm/cli/commit/6a6151f377063c6aca852c859c01910edd235ec6) `libnpx@10.2.4` ([@claudiahdz](https://github.com/claudiahdz)) -* [`dc21422eb`](https://github.com/npm/cli/commit/dc21422eb1ca1a4a19f160fad0e924566e08c496) `bin-links@1.1.8` ([@claudiahdz](https://github.com/claudiahdz)) -* [`d341f88ce`](https://github.com/npm/cli/commit/d341f88ce6feb3df1dcb37f34910fcc6c1db85f2) `gentle-fs@2.3.1` ([@claudiahdz](https://github.com/claudiahdz)) -* [`3e168d49b`](https://github.com/npm/cli/commit/3e168d49b41574809cae2ad013776a00d3f20ff4) `libcipm@4.0.8` ([@claudiahdz](https://github.com/claudiahdz)) -* [`6ae942a51`](https://github.com/npm/cli/commit/6ae942a510520b7dff11b5b78eebeff1706e38af) `npm-audit-report@1.3.3` ([@claudiahdz](https://github.com/claudiahdz)) -* [`6a35e3dee`](https://github.com/npm/cli/commit/6a35e3deec275bf2ae76603acd424a0640458047) `npm-lifecycle@3.1.5` ([@claudiahdz](https://github.com/claudiahdz)) - -## 6.14.6 (2020-07-07) - -### BUG FIXES -* [`a9857b8f6`](https://github.com/npm/cli/commit/a9857b8f6869451ff058789c4631fadfde5bbcbc) chore: remove auth info from logs ([@claudiahdz](https://github.com/claudiahdz)) -* [`b7ad77598`](https://github.com/npm/cli/commit/b7ad77598112908d60195d0fbc472b3c84275fd5) [#1416](https://github.com/npm/cli/pull/1416) fix: wrong `npm doctor` command result ([@vanishcode](https://github.com/vanishcode)) - -### DEPENDENCIES -* [`94eca6377`](https://github.com/npm/cli/commit/94eca637756376b949edfb697e179a1fdcc231ee) `npm-registry-fetch@4.0.5` ([@claudiahdz](https://github.com/claudiahdz)) -* [`c49b6ae28`](https://github.com/npm/cli/commit/c49b6ae28791ff7184288be16654f97168aa9705) [#1418](https://github.com/npm/cli/pull/1418) `spdx-license-ids@3.0.5` ([@kemitchell](https://github.com/kemitchell)) - -### DOCUMENTATION -* [`2e052984b`](https://github.com/npm/cli/commit/2e052984b08c09115ed75387fb2c961631d85d77) - [#1459](https://github.com/npm/cli/pull/1459) - chore(docs): fixed links to cli commands ([@claudiahdz](https://github.com/claudiahdz)) -* [`0ca3509ca`](https://github.com/npm/cli/commit/0ca3509ca940865392daeeabb39192f7d5af9f5e) - [#1283](https://github.com/npm/cli/pull/1283) Update npm-link.md ([@peterfich](https://github.com/peterfich)) -* [`3dd429e9a`](https://github.com/npm/cli/commit/3dd429e9aad760ce2ff9e522b34ebfebd85b460c) - [#1377](https://github.com/npm/cli/pull/1377) - Add note about dropped `*` filenames ([@maxwellgerber](https://github.com/maxwellgerber)) -* [`9a2e2e797`](https://github.com/npm/cli/commit/9a2e2e797e5c91e7f4f261583a1906e2c440cc2f) - [#1429](https://github.com/npm/cli/pull/1429) Fix typo ([@seanpoulter](https://github.com/seanpoulter)) - -## 6.14.5 (2020-05-01) - -### BUG FIXES - -* [`33ec41f18`](https://github.com/npm/cli/commit/33ec41f18f557146607cb14a7a38c707fce6d42c) [#758](https://github.com/npm/cli/pull/758) fix: relativize file links when inflating shrinkwrap ([@jsnajdr](https://github.com/jsnajdr)) -* [`94ed456df`](https://github.com/npm/cli/commit/94ed456dfb0b122fd4192429024f034d06c3c454) [#1162](https://github.com/npm/cli/pull/1162) fix: npm init help output ([@mum-never-proud](https://github.com/mum-never-proud)) - -### DEPENDENCIES - -* [`5587ac01f`](https://github.com/npm/cli/commit/5587ac01ffd0d2ea830a6bbb67bb34a611ffc409) `npm-registry-fetch@4.0.4` - * [`fc5d94c39`](https://github.com/npm/npm-registry-fetch/commit/fc5d94c39ca218d78df77249ab3a6bf1d9ed9db1) fix: removed default timeout -* [`07a4d8884`](https://github.com/npm/cli/commit/07a4d8884448359bac485a49c05fd2d23d06834b) `graceful-fs@4.2.4` -* [`8228d1f2e`](https://github.com/npm/cli/commit/8228d1f2e427ad9adee617266108acd1ee39b4a5) `mkdirp@0.5.5` -* [`e6d208317`](https://github.com/npm/cli/commit/e6d20831740a84aea766da2a2913cf82a4d56ada) `nopt@4.0.3` - -## 6.14.4 (2020-03-24) - -### DEPENDENCIES - -* Bump `minimist@1.2.5` transitive dep to resolve security issue - * [`9c554fd8c`](https://github.com/npm/cli/commit/9c554fd8cd1e9aeb8eb122ccfa3c78d12af4097a) `update-notifier@2.5.0` - * bump `deep-extend@1.2.5` - * bump `deep-extend@0.6.0` - * bump `is-ci@1.2.1` - * bump `is-retry-allowed@1.2.0` - * bump `rc@1.2.8` - * bump `registry-auth-token@3.4.0` - * bump `widest-line@2.0.1` -* [`136832dca`](https://github.com/npm/cli/commit/136832dcae13cb5518b1fe17bd63ea9b2a195f92) `mkdirp@0.5.4` -* [`8bf99b2b5`](https://github.com/npm/cli/commit/8bf99b2b58c14d45dc6739fce77de051ebc8ffb7) [#1053](https://github.com/npm/cli/pull/1053) deps: updates term-size to use signed binary - * [`d2f08a1bdb`](https://github.com/nodejs/node/commit/d2f08a1bdb78655c4a3fc49825986c148d14117e) ([@rvagg](https://github.com/rvagg)) - -## 6.14.3 (2020-03-19) - -### DOCUMENTATION - -* [`4ad221487`](https://github.com/npm/cli/commit4ad2214873cddfd4a0eff1bd188516b08fae9f9e) [#1020](https://github.com/npm/cli/pull/1020) docs(teams): updated team docs to reflect MFA workflow ([@blkdm0n](https://github.com/blkdm0n)) -* [`4a31a4ba2`](https://github.com/npm/cli/commit/4a31a4ba2db0a5db2d1d0890ee934ba1babb73a6) [#1034](https://github.com/npm/cli/pull/1034) docs: cleanup ([@ruyadorno](https://github.com/ruyadorno)) -* [`0eac801cd`](https://github.com/npm/cli/commit/0eac801cdef344e9fbda6270145e062211255b0e) [#1013](https://github.com/npm/cli/pull/1013) docs: fix links to cli commands ([@alenros](https://github.com/alenros)) -* [`7d8e5b99c`](https://github.com/npm/cli/commit/7d8e5b99c4ef8c394cffa7fc845f54a25ff37e3a) [#755](https://github.com/npm/cli/pull/755) docs: correction to `npm update -g` behaviour ([@johnkennedy9147](https://github.com/johnkennedy9147)) - -### DEPENDENCIES - -* [`e11167646`](https://github.com/npm/cli/commit/e111676467f090f73802b97e8da7ece481b18f99) `mkdirp@0.5.3` - * [`c5b97d17d`](https://github.com/isaacs/node-mkdirp/commit/c5b97d17d45a22bcf4c815645cbb989dab57ddd8) fix: bump `minimist` dep to resolve security issue ([@isaacs](https://github.com/isaacs)) -* [`c50d679c6`](https://github.com/npm/cli/commit/c50d679c68b39dd03ad127d34f540ddcb1b1e804) `rimraf@2.7.1` -* [`a2de99ff9`](https://github.com/npm/cli/commit/a2de99ff9e02425a3ccc25280f390178be755a36) `npm-registry-mock@1.3.1` -* [`217debeb9`](https://github.com/npm/cli/commit/217debeb9812e037a6686cbf6ec67a0cd47fa68a) `npm-registry-couchapp@2.7.4` - -## 6.14.2 (2020-03-03) - -### DOCUMENTATION -* [`f9248c0be`](https://github.com/npm/cli/commit/f9248c0be63fba37a30098dc9215c752474380e3) [#730](https://github.com/npm/cli/pull/730) chore(docs): update unpublish docs & policy reference ([@nomadtechie](https://github.com/nomadtechie), [@mikemimik](https://github.com/mikemimik)) - -### DEPENDENCIES - -* [`909cc3918`](https://github.com/npm/cli/commit/909cc39180a352f206898481add5772206c8b65f) `hosted-git-info@2.8.8` ([@darcyclarke](https://github.com/darcyclarke)) - * [`5038b1891`](https://github.com/npm/hosted-git-info/commit/5038b1891a61ca3cd7453acbf85d7011fe0086bb) fix: regression in old node versions w/ respect to url.URL implmentation -* [`9204ffa58`](https://github.com/npm/cli/commit/9204ffa584c140c5e22b1ee37f6df2c98f5dc70b) `npm-profile@4.0.4` ([@isaacs](https://github.com/isaacs)) - * [`6bcf0860a`](https://github.com/npm/npm-profile/commit/6bcf0860a3841865099d0115dbcbde8b78109bd9) fix: treat non-http/https login urls as invalid -* [`0365d39bd`](https://github.com/npm/cli/commit/0365d39bdc74960a18caac674f51d0e2a98b31e6) `glob@7.1.6` ([@isaacs](https://github.com/isaacs)) -* [`dab030536`](https://github.com/nodejs/node-gyp/commit/dab030536b6a70ecae37debc74c581db9e5280fd) `node-gyp@5.1.0` ([@rvagg](https://github.com/rvagg)) - -## 6.14.1 (2020-02-26) - -* [`303e5c11e`](https://github.com/npm/cli/commit/303e5c11e7db34cf014107aecd2e81c821bfde8d) - `hosted-git-info@2.8.7` - Fixes a regression where scp-style git urls are passed to the WhatWG URL - parser, which does not handle them properly. - ([@isaacs](https://github.com/isaacs)) - -## 6.14.0 (2020-02-25) - -### FEATURES -* [`30f170877`](https://github.com/npm/cli/commit/30f170877954acd036cb234a581e4eb155049b82) [#731](https://github.com/npm/cli/pull/731) add support for multiple funding sources ([@ljharb](https://github.com/ljharb) & [@ruyadorno](hhttps://github.com/ruyadorno/)) - -### BUG FIXES -* [`55916b130`](https://github.com/npm/cli/commit/55916b130ef52984584678f2cc17c15c1f031cb5) [#508](https://github.com/npm/cli/pull/508) fix: check `npm.config` before accessing its members ([@kaiyoma](https://github.com/kaiyoma)) -* [`7d0cd65b2`](https://github.com/npm/cli/commit/7d0cd65b23c0986b631b9b54d87bbe74902cc023) [#733](https://github.com/npm/cli/pull/733) fix: access grant with unscoped packages ([@netanelgilad](https://github.com/netanelgilad)) -* [`28c3d40d6`](https://github.com/npm/cli/commit/28c3d40d65eef63f9d6ccb60b99ac57f5057a46e), [`0769c5b20`](https://github.com/npm/cli/commit/30f170877954acd036cb234a581e4eb155049b82) [#945](https://github.com/npm/cli/pull/945), [#697](https://github.com/npm/cli/pull/697) fix: allow new major versions of node to be automatically considered "supported" ([@isaacs](https://github.com/isaacs), [@ljharb](https://github.com/ljharb)) - -### DEPENDENCIES -* [`6f39e93`](https://github.com/npm/hosted-git-info/commit/6f39e93bae9162663af6f15a9d10bce675dd5de3) `hosted-git-info@2.8.6` ([@darcyclarke](https://github.com/darcyclarke)) - * fix: passwords & usernames are escaped properly in git deps ([@stevenhilder](https://github.com/stevenhilder)) -* [`f14b594ee`](https://github.com/npm/cli/commit/f14b594ee9dbfc98ed0b65c65d904782db4f31ad) `chownr@1.1.4` ([@isaacs](https://github.com/isaacs)) -* [`77044150b`](https://github.com/npm/cli/commit/77044150b763d67d997f9ff108219132ea922678) `npm-packlist@1.4.8` ([@isaacs](https://github.com/isaacs)) -* [`1d112461a`](https://github.com/npm/cli/commit/1d112461ad8dc99e5ff7fabb5177e8c2f89a9755) `npm-registry-fetch@4.0.3` ([@isaacs](https://github.com/isaacs)) - * [`ba8b4fe`](https://github.com/npm/npm-registry-fetch/commit/ba8b4fe60eb6cdf9b39012560aec596eda8ce924) fix: always bypass cache when ?write=true -* [`a47fed760`](https://github.com/npm/cli/commit/a47fed7603a6ed31dcc314c0c573805f05a96830) `readable-stream@3.6.0` - * [`3bbf2d6`](https://github.com/nodejs/readable-stream/commit/3bbf2d6feb45b03f4e46a2ae8251601ad2262121) fix: babel's "loose mode" class transform enbrittles BufferList ([@ljharb](https://github.com/ljharb)) - -### DOCUMENTATION -* [`284c1c055`](https://github.com/npm/cli/commit/284c1c055a28c4b334496101799acefe3c54ceb3), [`fbb5f0e50`](https://github.com/npm/cli/commit/fbb5f0e50e54425119fa3f03c5de93e4cb6bfda7) [#729](https://github.com/npm/cli/pull/729) update lifecycle hooks docs - ([@seanhealy](https://github.com/seanhealy), [@mikemimik](https://github.com/mikemimik)) -* [`1c272832d`](https://github.com/npm/cli/commit/1c272832d048300e409882313305c416dc6f21a2) [#787](https://github.com/npm/cli/pull/787) fix: trademarks typo ([@dnicolson](https://github.com/dnicolson)) -* [`f6ff41776`](https://github.com/npm/cli/commit/f6ff417767d52418cc8c9e7b9731ede2c3916d2e) [#936](https://github.com/npm/cli/pull/936) fix: postinstall example ([@ajaymathur](https://github.com/ajaymathur)) -* [`373224b16`](https://github.com/npm/cli/commit/373224b16e019b7b63d8f0b4c5d4adb7e5cb80dd) [#939](https://github.com/npm/cli/pull/939) fix: bad links in publish docs ([@vit100](https://github.com/vit100)) - -### MISCELLANEOUS -* [`85c79636d`](https://github.com/npm/cli/commit/85c79636df31bac586c0e380c4852ee155a7723c) [#736](https://github.com/npm/cli/pull/736) add script to update dist-tags ([@mikemimik](https://github.com/mikemimik)) - -## 6.13.7 (2020-01-28) - -### BUG FIXES -* [`7dbb91438`](https://github.com/npm/cli/commit/7dbb914382ecd2074fffb7eba81d93262e2d23c6) - [#655](https://github.com/npm/cli/pull/655) - Update CI detection cases - ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES -* [`0fb1296c7`](https://github.com/npm/cli/commit/0fb1296c7d6d4bb9e78c96978c433cd65e55c0ea) - `libnpx@10.2.2` - ([@mikemimik](https://github.com/mikemimik)) -* [`c9b69d569`](https://github.com/npm/cli/commit/c9b69d569fec7944375a746e9c08a6fa9bec96ff) - `node-gyp@5.0.7` - ([@mikemimik](https://github.com/mikemimik)) -* [`e8dbaf452`](https://github.com/npm/cli/commit/e8dbaf452a1f6c5350bb0c37059b89a7448e7986) - `bin-links@1.1.7` - ([@mikemimik](https://github.com/mikemimik)) - * [#613](https://github.com/npm/cli/issues/613) Fixes bin entry for package - -## 6.13.6 (2020-01-09) - -### DEPENDENCIES - -* [`6dba897a1`](https://github.com/npm/cli/commit/6dba897a1e2d56388fb6df0c814b0bb85af366b4) - `pacote@9.5.12`: - * [`d2f4176`](https://github.com/npm/pacote/commit/d2f4176b6af393d7e29de27e9b638dbcbab9a0c7) - fix(git): Do not drop uid/gid when executing in root-owned directory - ([@isaacs](https://github.com/isaacs)) - -## 6.13.5 (2020-01-09) - -### BUG FIXES - -* [`fd0a802ec`](https://github.com/npm/cli/commit/fd0a802ec468ec7b98d6c15934c355fef0e7ff60) [#550](https://github.com/npm/cli/pull/550) Fix cache location for `npm ci` ([@zhenyavinogradov](https://github.com/zhenyavinogradov)) -* [`4b30f3cca`](https://github.com/npm/cli/commit/4b30f3ccaebf50d6ab3bad130ff94827c017cc16) [#648](https://github.com/npm/cli/pull/648) fix(version): using 'allow-same-version', git commit --allow-empty and git tag -f ([@rhengles](https://github.com/rhengles)) - -### TESTING - -* [`e16f68d30`](https://github.com/npm/cli/commit/e16f68d30d59ce1ddde9fe62f7681b2c07fce84d) test(ci): add failing cache config test ([@ruyadorno](https://github.com/ruyadorno)) -* [`3f009fbf2`](https://github.com/npm/cli/commit/3f009fbf2c42f68c5127efecc6e22db105a74fe0) [#659](https://github.com/npm/cli/pull/659) test: fix bin-overwriting test on Windows ([@isaacs](https://github.com/isaacs)) -* [`43ae0791f`](https://github.com/npm/cli/commit/43ae0791f74f68e02850201a64a6af693657b241) [#601](https://github.com/npm/cli/pull/601) ci: Allow builds to run even if one fails ([@XhmikosR](https://github.com/XhmikosR)) -* [`4a669bee4`](https://github.com/npm/cli/commit/4a669bee4ac54c70adc6979d45cd0605b6dc33fd) [#603](https://github.com/npm/cli/pull/603) Remove the unused appveyor.yml ([@XhmikosR](https://github.com/XhmikosR)) -* [`9295046ac`](https://github.com/npm/cli/commit/9295046ac92bbe82f4d84e1ec90cc81d3b80bfc7) [#600](https://github.com/npm/cli/pull/600) ci: switch to `actions/checkout@v2` ([@XhmikosR](https://github.com/XhmikosR)) - -### DOCUMENTATION - -* [`f2d770ac7`](https://github.com/npm/cli/commit/f2d770ac768ea84867772b90a3c9acbdd0c1cb6a) [#569](https://github.com/npm/cli/pull/569) fix netlify publish path config ([@claudiahdz](https://github.com/claudiahdz)) -* [`462cf0983`](https://github.com/npm/cli/commit/462cf0983dbc18a3d93f77212ca69f878060b2ec) [#627](https://github.com/npm/cli/pull/627) update gatsby dependencies ([@felixonmars](https://github.com/felixonmars)) -* [`6fb5dbb72`](https://github.com/npm/cli/commit/6fb5dbb7213c4c050c9a47a7d5131447b8b7dcc8) - [#532](https://github.com/npm/cli/pull/532) docs: clarify usage of global prefix ([@jgehrcke](https://github.com/jgehrcke)) - -## 6.13.4 (2019-12-11) - -## BUGFIXES - -* [`320ac9aee`](https://github.com/npm/cli/commit/320ac9aeeafd11bb693c53b31148b8d10c4165e8) - [npm/bin-links#12](https://github.com/npm/bin-links/pull/12) - [npm/gentle-fs#7](https://github.com/npm/gentle-fs/pull/7) - Do not remove global bin/man links inappropriately - ([@isaacs](https://github.com/isaacs)) - -## DEPENDENCIES - -* [`52fd21061`](https://github.com/npm/cli/commit/52fd21061ff8b1a73429294620ffe5ebaaa60d3e) - `gentle-fs@2.3.0` - ([@isaacs](https://github.com/isaacs)) -* [`d06f5c0b0`](https://github.com/npm/cli/commit/d06f5c0b0611c43b6e70ded92af24fa5d83a0f48) - `bin-links@1.1.6` - ([@isaacs](https://github.com/isaacs)) - -## 6.13.3 (2019-12-09) - -### DEPENDENCIES - -* [`19ce061a2`](https://github.com/npm/cli/commit/19ce061a2ee165d8de862c8f0f733c222846b9e1) - `bin-links@1.1.5` Properly normalize, sanitize, and verify `bin` entries - in `package.json`. -* [`59c836aae`](https://github.com/npm/cli/commit/59c836aae8d0104a767e80c540b963c91774012a) - `npm-packlist@1.4.7` -* [`fb4ecd7d2`](https://github.com/npm/cli/commit/fb4ecd7d2810b0b4897daaf081a5e2f3f483b310) - `pacote@9.5.11` - * [`5f33040`](https://github.com/npm/pacote/commit/5f3304028b6985fd380fc77c4840ff12a4898301) - [#476](https://github.com/npm/cli/issues/476) - [npm/pacote#22](https://github.com/npm/pacote/issues/22) - [npm/pacote#14](https://github.com/npm/pacote/issues/14) fix: Do not - drop perms in git when not root ([isaacs](https://github.com/isaacs), - [@darcyclarke](https://github.com/darcyclarke)) - * [`6f229f7`](https://github.com/npm/pacote/6f229f78d9911b4734f0a19c6afdc5454034c759) - sanitize and normalize package bin field - ([isaacs](https://github.com/isaacs)) -* [`1743cb339`](https://github.com/npm/cli/commit/1743cb339767e86431dcd565c7bdb0aed67b293d) - `read-package-json@2.1.1` - - -## 6.13.2 (2019-12-03) - -### BUG FIXES - -* [`4429645b3`](https://github.com/npm/cli/commit/4429645b3538e1cda54d8d1b7ecb3da7a88fdd3c) - [#546](https://github.com/npm/cli/pull/546) - fix docs target typo - ([@richardlau](https://github.com/richardlau)) -* [`867642942`](https://github.com/npm/cli/commit/867642942bec69bb9ab71cff1914fb6a9fe67de8) - [#142](https://github.com/npm/cli/pull/142) - fix(packageRelativePath): fix 'where' for file deps - ([@larsgw](https://github.com/larsgw)) -* [`d480f2c17`](https://github.com/npm/cli/commit/d480f2c176e6976b3cca3565e4c108b599b0379b) - [#527](https://github.com/npm/cli/pull/527) - Revert "windows: Add preliminary WSL support for npm and npx" - ([@craigloewen-msft](https://github.com/craigloewen-msft)) -* [`e4b97962e`](https://github.com/npm/cli/commit/e4b97962e5fce0d49beb541ce5a0f96aee0525de) - [#504](https://github.com/npm/cli/pull/504) - remove unnecessary package.json read when reading shrinkwrap - ([@Lighting-Jack](https://github.com/Lighting-Jack)) -* [`1c65d26ac`](https://github.com/npm/cli/commit/1c65d26ac9f10ac0037094c207d216fbf0e969bf) - [#501](https://github.com/npm/cli/pull/501) - fix(fund): open url for string shorthand - ([@ruyadorno](https://github.com/ruyadorno)) -* [`ae7afe565`](https://github.com/npm/cli/commit/ae7afe56504dbffabf9f73d55b6dac1e3e9fed4a) - [#263](https://github.com/npm/cli/pull/263) - Don't log error message if git tagging is disabled - ([@woppa684](https://github.com/woppa684)) -* [`4c1b16f6a`](https://github.com/npm/cli/commit/4c1b16f6aecaf78956b9335734cfde2ac076ee11) - [#182](https://github.com/npm/cli/pull/182) - Warn the user that it is uninstalling npm-install - ([@Hoidberg](https://github.com/Hoidberg)) - -## 6.13.1 (2019-11-18) - -### BUG FIXES - -* [`938d6124d`](https://github.com/npm/cli/commit/938d6124d6d15d96b5a69d0ae32ef59fceb8ceab) - [#472](https://github.com/npm/cli/pull/472) - fix(fund): support funding string shorthand - ([@ruyadorno](https://github.com/ruyadorno)) -* [`b49c5535b`](https://github.com/npm/cli/commit/b49c5535b7c41729a8d167b035924c3c66b36de0) - [#471](https://github.com/npm/cli/pull/471) - should not publish tap-snapshot folder - ([@ruyadorno](https://github.com/ruyadorno)) -* [`3471d5200`](https://github.com/npm/cli/commit/3471d5200217bfa612b1a262e36c9c043a52eb09) - [#253](https://github.com/npm/cli/pull/253) - Add preliminary WSL support for npm and npx - ([@infinnie](https://github.com/infinnie)) -* [`3ef295f23`](https://github.com/npm/cli/commit/3ef295f23ee1b2300abf13ec19e935c47a455179) - [#486](https://github.com/npm/cli/pull/486) - print quick audit report for human output - ([@isaacs](https://github.com/isaacs)) - -### TESTING - -* [`dbbf977ac`](https://github.com/npm/cli/commit/dbbf977acd1e74bcdec859c562ea4a2bc0536442) - [#278](https://github.com/npm/cli/pull/278) - added workflow to trigger and run benchmarks - ([@mikemimik](https://github.com/mikemimik)) -* [`b4f5e3825`](https://github.com/npm/cli/commit/b4f5e3825535256aaada09c5e8f104570a3d96a4) - [#457](https://github.com/npm/cli/pull/457) - feat(docs): adding tests and updating docs to reflect changes in registry teams API. - ([@nomadtechie](https://github.com/nomadtechie)) -* [`454c7dd60`](https://github.com/npm/cli/commit/454c7dd60c78371bf606f11a17ed0299025bc37c) - [#456](https://github.com/npm/cli/pull/456) - fix git configs for git 2.23 and above - ([@isaacs](https://github.com/isaacs)) - -### DOCUMENTATION - -* [`b8c1576a4`](https://github.com/npm/cli/commit/b8c1576a448566397c721655b95fc90bf202b35a) [`30b013ae8`](https://github.com/npm/cli/commit/30b013ae8eacd04b1b8a41ce2ed0dd50c8ebae25) [`26c1b2ef6`](https://github.com/npm/cli/commit/26c1b2ef6be1595d28d935d35faa8ec72daae544) [`9f943a765`](https://github.com/npm/cli/commit/9f943a765faf6ebb8a442e862b808dbb630e018d) [`c0346b158`](https://github.com/npm/cli/commit/c0346b158fc25ab6ca9954d4dd78d9e62f573a41) [`8e09d5ad6`](https://github.com/npm/cli/commit/8e09d5ad67d4f142241193cecbce61c659389be3) [`4a2f551ee`](https://github.com/npm/cli/commit/4a2f551eeb3285f6f200534da33644789715a41a) [`87d67258c`](https://github.com/npm/cli/commit/87d67258c213d9ea9a49ce1804294a718f08ff13) [`5c3b32722`](https://github.com/npm/cli/commit/5c3b3272234764c8b4d2d798b69af077b5a529c7) [`b150eaeff`](https://github.com/npm/cli/commit/b150eaeff428180bfa03be53fd741d5625897758) [`7555a743c`](https://github.com/npm/cli/commit/7555a743ce4c3146d6245dd63f91503c7f439a6c) [`b89423e2f`](https://github.com/npm/cli/commit/b89423e2f6a09b290b15254e7ff7e8033b434d83) - [#463](https://github.com/npm/cli/pull/463) - [#285](https://github.com/npm/cli/pull/285) - [#268](https://github.com/npm/cli/pull/268) - [#232](https://github.com/npm/cli/pull/232) - [#485](https://github.com/npm/cli/pull/485) - [#453](https://github.com/npm/cli/pull/453) - docs cleanup: typos, styling and content - ([@claudiahdz](https://github.com/claudiahdz)) - ([@XhmikosR](https://github.com/XhmikosR)) - ([@mugli](https://github.com/mugli)) - ([@brettz9](https://github.com/brettz9)) - ([@mkotsollaris](https://github.com/mkotsollaris)) - -### DEPENDENCIES - -* [`661d86cd2`](https://github.com/npm/cli/commit/661d86cd229b14ddf687b7f25a66941a79d233e7) - `make-fetch-happen@5.0.2` - ([@claudiahdz](https://github.com/claudiahdz)) - -## 6.13.0 (2019-11-05) - -### NEW FEATURES - -* [`4414b06d9`](https://github.com/npm/cli/commit/4414b06d944c56bee05ccfb85260055a767ee334) - [#273](https://github.com/npm/cli/pull/273) - add fund command - ([@ruyadorno](https://github.com/ruyadorno)) - -### DOCUMENTATION - -* [`ae4c74d04`](https://github.com/npm/cli/commit/ae4c74d04f820a0255a92bdfe77ecf97af134fae) - [#274](https://github.com/npm/cli/pull/274) - migrate existing docs to gatsby - ([@claudiahdz](https://github.com/claudiahdz)) -* [`4ff1bb180`](https://github.com/npm/cli/commit/4ff1bb180b1db8c72e51b3d57bd4e268b738e049) - [#277](https://github.com/npm/cli/pull/277) - updated documentation copy - ([@oletizi](https://github.com/oletizi)) - -### BUG FIXES - -* [`e4455409f`](https://github.com/npm/cli/commit/e4455409fe6fe9c198b250b488129171f0b4624a) - [#281](https://github.com/npm/cli/pull/281) - delete ps1 files on package removal - ([@NoDocCat](https://github.com/NoDocCat)) -* [`cd14d4701`](https://github.com/npm/cli/commit/cd14d47014e8c96ffd6a18791e8752028b19d637) - [#279](https://github.com/npm/cli/pull/279) - update supported node list to remove v6.0, v6.1, v9.0 - v9.2 - ([@ljharb](https://github.com/ljharb)) - -### DEPENDENCIES - -* [`a37296b20`](https://github.com/npm/cli/commit/a37296b20ca3e19c2bbfa78fedcfe695e03fda69) - `pacote@9.5.9` -* [`d3cb3abe8`](https://github.com/npm/cli/commit/d3cb3abe8cee54bd2624acdcf8043932ef0d660a) - `read-cmd-shim@1.0.5` - -### TESTING - -* [`688cd97be`](https://github.com/npm/cli/commit/688cd97be94ca949719424ff69ff515a68c5caba) - [#272](https://github.com/npm/cli/pull/272) - use github actions for CI - ([@JasonEtco](https://github.com/JasonEtco)) -* [`9a2d8af84`](https://github.com/npm/cli/commit/9a2d8af84f7328f13d8f578cf4b150b9d5f09517) - [#240](https://github.com/npm/cli/pull/240) - Clean up some flakiness and inconsistency - ([@isaacs](https://github.com/isaacs)) - -## 6.12.1 (2019-10-29) - -### BUG FIXES - -* [`6508e833d`](https://github.com/npm/cli/commit/6508e833df35a3caeb2b496f120ce67feff306b6) - [#269](https://github.com/npm/cli/pull/269) - add node v13 as a supported version - ([@ljharb](https://github.com/ljharb)) -* [`b6588a8f7`](https://github.com/npm/cli/commit/b6588a8f74fb8b1ad103060b73c4fd5174b1d1f6) - [#265](https://github.com/npm/cli/pull/265) - Fix regression in lockfile repair for sub-deps - ([@feelepxyz](https://github.com/feelepxyz)) -* [`d5dfe57a1`](https://github.com/npm/cli/commit/d5dfe57a1d810fe7fd64edefc976633ee3a4da53) - [#266](https://github.com/npm/cli/pull/266) - resolve circular dependency in pack.js - ([@addaleax](https://github.com/addaleax)) - -### DEPENDENCIES - -* [`73678bb59`](https://github.com/npm/cli/commit/73678bb590a8633c3bdbf72e08f1279f9e17fd28) - `chownr@1.1.3` -* [`4b76926e2`](https://github.com/npm/cli/commit/4b76926e2058ef30ab1d5e2541bb96d847653417) - `graceful-fs@4.2.3` -* [`c691f36a9`](https://github.com/npm/cli/commit/c691f36a9c108b6267859fe61e4a38228b190c17) - `libcipm@4.0.7` -* [`5e1a14975`](https://github.com/npm/cli/commit/5e1a14975311bfdc43df8e1eb317ae5690ee580c) - `npm-packlist@1.4.6` -* [`c194482d6`](https://github.com/npm/cli/commit/c194482d65ee81a5a0a6281c7a9f984462286c56) - `npm-registry-fetch@4.0.2` -* [`bc6a8e0ec`](https://github.com/npm/cli/commit/bc6a8e0ec966281e49b1dc66f9c641ea661ab7a6) - `tar@4.4.1` -* [`4dcca3cbb`](https://github.com/npm/cli/commit/4dcca3cbb161da1f261095d9cdd26e1fbb536a8d) - `uuid@3.3.3` - -## 6.12.0 (2019-10-08): - -Now `npm ci` runs prepare scripts for git dependencies, and respects the -`--no-optional` argument. Warnings for `engine` mismatches are printed -again. Various other fixes and cleanups. - -### BUG FIXES - -* [`890b245dc`](https://github.com/npm/cli/commit/890b245dc1f609590d8ab993fac7cf5a37ed46a5) - [#252](https://github.com/npm/cli/pull/252) ci: add dirPacker to options - ([@claudiahdz](https://github.com/claudiahdz)) -* [`f3299acd0`](https://github.com/npm/cli/commit/f3299acd0b4249500e940776aca77cc6c0977263) - [#257](https://github.com/npm/cli/pull/257) - [npm.community#4792](https://npm.community/t/engines-and-engines-strict-ignored/4792) - warn message on engine mismatch - ([@ruyadorno](https://github.com/ruyadorno)) -* [`bbc92fb8f`](https://github.com/npm/cli/commit/bbc92fb8f3478ff67071ebaff551f01c1ea42ced) - [#259](https://github.com/npm/cli/pull/259) - [npm.community#10288](https://npm.community/t/npm-token-err-figgypudding-options-cannot-be-modified-use-concat-instead/10288) - Fix figgyPudding error in `npm token` - ([@benblank](https://github.com/benblank)) -* [`70f54dcb5`](https://github.com/npm/cli/commit/70f54dcb5693b301c6b357922b7e8d16b57d8b00) - [#241](https://github.com/npm/cli/pull/241) doctor: Make OK more - consistent ([@gemal](https://github.com/gemal)) - -### FEATURES - -* [`ed993a29c`](https://github.com/npm/cli/commit/ed993a29ccf923425317c433844d55dbea2f23ee) - [#249](https://github.com/npm/cli/pull/249) Add CI environment variables - to user-agent ([@isaacs](https://github.com/isaacs)) -* [`f6b0459a4`](https://github.com/npm/cli/commit/f6b0459a466a2c663dbd549cdc331e7732552dca) - [#248](https://github.com/npm/cli/pull/248) Add option to save - package-lock without formatting Adds a new config - `--format-package-lock`, which defaults to true. - ([@bl00mber](https://github.com/bl00mber)) - -### DEPENDENCIES - -* [`0ca063c5d`](https://github.com/npm/cli/commit/0ca063c5dc961c4aa17373f4b33fb54c51c8c8d6) - `npm-lifecycle@3.1.4`: - - fix: filter functions and undefined out of makeEnv - ([@isaacs](https://github.com/isaacs)) -* [`5df6b0ea2`](https://github.com/npm/cli/commit/5df6b0ea2e3106ba65bba649cc8d7f02f4738236) - `libcipm@4.0.4`: - - fix: pack git directories properly - ([@claudiahdz](https://github.com/claudiahdz)) - - respect no-optional argument - ([@cruzdanilo](https://github.com/cruzdanilo)) -* [`7e04f728c`](https://github.com/npm/cli/commit/7e04f728cc4cd4853a8fc99e2df0a12988897589) - `tar@4.4.12` -* [`5c380e5a3`](https://github.com/npm/cli/commit/5c380e5a33d760bb66a4285b032ae5f50af27199) - `stringify-package@1.0.1` ([@isaacs](https://github.com/isaacs)) -* [`62f2ca692`](https://github.com/npm/cli/commit/62f2ca692ac0c0467ef4cf74f91777a5175258c4) - `node-gyp@5.0.5` ([@isaacs](https://github.com/isaacs)) -* [`0ff0ea47a`](https://github.com/npm/cli/commit/0ff0ea47a8840dd7d952bde7f7983a5016cda8ea) - `npm-install-checks@3.0.2` ([@isaacs](https://github.com/isaacs)) -* [`f46edae94`](https://github.com/npm/cli/commit/f46edae9450b707650a0efab09aa1e9295a18070) - `hosted-git-info@2.8.5` ([@isaacs](https://github.com/isaacs)) - -### TESTING - -* [`44a2b036b`](https://github.com/npm/cli/commit/44a2b036b34324ec85943908264b2e36de5a9435) - [#262](https://github.com/npm/cli/pull/262) fix root-ownership race - conditions in meta-test ([@isaacs](https://github.com/isaacs)) - -## 6.11.3 (2019-09-03): - -Fix npm ci regressions and npm outdated depth. - -### BUG FIXES - -* [`235ed1d28`](https://github.com/npm/cli/commit/235ed1d2838ef302bb995e183980209d16c51b9b) - [#239](https://github.com/npm/cli/pull/239) - Don't override user specified depth in outdated - Restores ability to update packages using `--depth` as suggested by `npm audit`. - ([@G-Rath](https://github.com/G-Rath)) -* [`1fafb5151`](https://github.com/npm/cli/commit/1fafb51513466cd793866b576dfea9a8963a3335) - [#242](https://github.com/npm/cli/pull/242) - [npm.community#9586](https://npm.community/t/6-11-1-some-dependencies-are-no-longer-being-installed/9586/4) - Revert "install: do not descend into directory deps' child modules" - ([@isaacs](https://github.com/isaacs)) -* [`cebf542e6`](https://github.com/npm/cli/commit/cebf542e61dcabdd2bd3b876272bf8eebf7d01cc) - [#243](https://github.com/npm/cli/pull/243) - [npm.community#9720](https://npm.community/t/6-11-2-npm-ci-installs-package-with-wrong-permissions/9720) - ci: pass appropriate configs for file/dir modes - ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES - -* [`e5fbb7ed1`](https://github.com/npm/cli/commit/e5fbb7ed1fc7ef5c6ca4790e2d0dc441e0ac1596) - `read-cmd-shim@1.0.4` - ([@claudiahdz](https://github.com/claudiahdz)) -* [`23ce65616`](https://github.com/npm/cli/commit/23ce65616c550647c586f7babc3c2f60115af2aa) - `npm-pick-manifest@3.0.2` - ([@claudiahdz](https://github.com/claudiahdz)) - -## 6.11.2 (2019-08-22): - -Fix a recent Windows regression, and two long-standing Windows bugs. Also, -get CI running on Windows, so these things are less likely in the future. - -### DEPENDENCIES - -* [`9778a1b87`](https://github.com/npm/cli/commit/9778a1b878aaa817af6e99385e7683c2a389570d) - `cmd-shim@3.0.3`: Fix regression where shims fail to preserve exit code - ([@isaacs](https://github.com/isaacs)) -* [`bf93e91d8`](https://github.com/npm/cli/commit/bf93e91d879c816a055d5913e6e4210d7299f299) - `npm-package-arg@6.1.1`: Properly handle git+file: urls on Windows when a - drive letter is included. ([@isaacs](https://github.com/isaacs)) - -### BUGFIXES - -* [`6cc4cc66f`](https://github.com/npm/cli/commit/6cc4cc66f1fb050dc4113e35cab59197fd48e04a) - escape args properly on Windows Bash Despite being bash, Node.js running - on windows git mingw bash still executes child processes using cmd.exe. - As a result, arguments in this environment need to be escaped in the - style of cmd.exe, not bash. ([@isaacs](https://github.com/isaacs)) - -### TESTS - -* [`291aba7b8`](https://github.com/npm/cli/commit/291aba7b821e247b96240b1ec037310ead69a594) - make tests pass on Windows ([@isaacs](https://github.com/isaacs)) -* [`fea3a023a`](https://github.com/npm/cli/commit/fea3a023a80863f32a5f97f5132401b1a16161b8) - travis: run tests on Windows as well - ([@isaacs](https://github.com/isaacs)) - -## 6.11.1 (2019-08-20): - -Fix a regression for windows command shim syntax. - -* [`37db29647`](https://github.com/npm/cli/commit/37db2964710c80003604b7e3c1527d17be7ed3d0) - `cmd-shim@3.0.2` ([@isaacs](https://github.com/isaacs)) - -## v6.11.0 (2019-08-20): - -A few meaty bugfixes, and introducing `peerDependenciesMeta`. - -### FEATURES - -* [`a12341088`](https://github.com/npm/cli/commit/a12341088820c0e7ef6c1c0db3c657f0c2b3943e) - [#224](https://github.com/npm/cli/pull/224) Implements - peerDependenciesMeta ([@arcanis](https://github.com/arcanis)) -* [`2f3b79bba`](https://github.com/npm/cli/commit/2f3b79bbad820fd4a398aa494b19f79b7fd520a1) - [#234](https://github.com/npm/cli/pull/234) add new forbidden 403 error - code ([@claudiahdz](https://github.com/claudiahdz)) - -### BUGFIXES - -* [`24acc9fc8`](https://github.com/npm/cli/commit/24acc9fc89d99d87cc66206c6c6f7cdc82fbf763) - and - [`45772af0d`](https://github.com/npm/cli/commit/45772af0ddca54b658cb2ba2182eec26d0a4729d) - [#217](https://github.com/npm/cli/pull/217) - [npm.community#8863](https://npm.community/t/installing-the-same-module-under-multiple-relative-paths-fails-on-linux/8863) - [npm.community#9327](https://npm.community/t/reinstall-breaks-after-npm-update-to-6-10-2/9327,) - do not descend into directory deps' child modules, fix shrinkwrap files - that inappropriately list child nodes of symlink packages - ([@isaacs](https://github.com/isaacs) and - [@salomvary](https://github.com/salomvary)) -* [`50cfe113d`](https://github.com/npm/cli/commit/50cfe113da5fcc59c1d99b0dcf1050ace45803c7) - [#229](https://github.com/npm/cli/pull/229) fixed typo in semver doc - ([@gall0ws](https://github.com/gall0ws)) -* [`e8fb2a1bd`](https://github.com/npm/cli/commit/e8fb2a1bd9785e0092e9926f4fd65ad431e38452) - [#231](https://github.com/npm/cli/pull/231) Fix spelling mistakes in - CHANGELOG-3.md ([@XhmikosR](https://github.com/XhmikosR)) -* [`769d2e057`](https://github.com/npm/cli/commit/769d2e057daf5a2cbfe0ce86f02550e59825a691) - [npm/uid-number#7](https://github.com/npm/uid-number/issues/7) Better - error on invalid `--user`/`--group` configs. This addresses the issue - when people fail to install binary packages on Docker and other - environments where there is no 'nobody' user. - ([@isaacs](https://github.com/isaacs)) -* [`8b43c9624`](https://github.com/npm/cli/commit/8b43c962498c8e2707527e4fca442d7a4fa51595) - [nodejs/node#28987](https://github.com/nodejs/node/issues/28987) - [npm.community#6032](https://npm.community/t/npm-ci-doesnt-respect-npmrc-variables/6032) - [npm.community#6658](https://npm.community/t/npm-ci-doesnt-fill-anymore-the-process-env-npm-config-cache-variable-on-post-install-scripts/6658) - [npm.community#6069](https://npm.community/t/npm-ci-does-not-compile-native-dependencies-according-to-npmrc-configuration/6069) - [npm.community#9323](https://npm.community/t/npm-6-9-x-not-passing-environment-to-node-gyp-regression-from-6-4-x/9323/2) - Fix the regression where random config values in a .npmrc file are not - passed to lifecycle scripts, breaking build processes which rely on them. - ([@isaacs](https://github.com/isaacs)) -* [`8b85eaa47`](https://github.com/npm/cli/commit/8b85eaa47da3abaacc90fe23162a68cc6e1f0404) - save files with inferred ownership rather than relying on `SUDO_UID` and - `SUDO_GID`. ([@isaacs](https://github.com/isaacs)) -* [`b7f6e5f02`](https://github.com/npm/cli/commit/b7f6e5f0285515087b4614d81db17206524c0fdb) - Infer ownership of shrinkwrap files - ([@isaacs](https://github.com/isaacs)) -* [`54b095d77`](https://github.com/npm/cli/commit/54b095d77b3b131622b3cf4cb5c689aa2dd10b6b) - [#235](https://github.com/npm/cli/pull/235) Add spec to dist-tag remove - function ([@theberbie](https://github.com/theberbie)) - -### DEPENDENCIES - -* [`dc8f9e52f`](https://github.com/npm/cli/commit/dc8f9e52f0bb107c0a6b20cc0c97cbc3b056c1b3) - `pacote@9.5.7`: Infer the ownership of all unpacked files in - `node_modules`, so that we never have user-owned files in root-owned - folders, or root-owned files in user-owned folders. - ([@isaacs](https://github.com/isaacs)) -* [`bb33940c3`](https://github.com/npm/cli/commit/bb33940c32aad61704084e61ebd1bd8e7cacccc8) - `cmd-shim@3.0.0`: - * [`9c93ac3`](https://github.com/npm/cmd-shim/commit/9c93ac39e95b0d6ae852e842e4c5dba5e19687c2) - [#2](https://github.com/npm/cmd-shim/pull/2) - [npm#3380](https://github.com/npm/npm/issues/3380) Handle environment - variables properly ([@basbossink](https://github.com/basbossink)) - * [`2d277f8`](https://github.com/npm/cmd-shim/commit/2d277f8e84d45401747b0b9470058f168b974ad5) - [#25](https://github.com/npm/cmd-shim/pull/25) - [#36](https://github.com/npm/cmd-shim/pull/36) - [#35](https://github.com/npm/cmd-shim/pull/35) Fix 'no shebang' case by - always providing `$basedir` in shell script - ([@igorklopov](https://github.com/igorklopov)) - * [`adaf20b`](https://github.com/npm/cmd-shim/commit/adaf20b7fa2c09c2111a2506c6a3e53ed0831f88) - [#26](https://github.com/npm/cmd-shim/pull/26) Fix `$*` causing an - error when arguments contain parentheses - ([@satazor](https://github.com/satazor)) - * [`49f0c13`](https://github.com/npm/cmd-shim/commit/49f0c1318fd384e0031c3fd43801f0e22e1e555f) - [#30](https://github.com/npm/cmd-shim/pull/30) Fix paths for MSYS/MINGW - bash ([@dscho](https://github.com/dscho)) - * [`51a8af3`](https://github.com/npm/cmd-shim/commit/51a8af30990cb072cb30d67fc1b564b14746bba9) - [#34](https://github.com/npm/cmd-shim/pull/34) Add proper support for - PowerShell ([@ExE-Boss](https://github.com/ExE-Boss)) - * [`4c37e04`](https://github.com/npm/cmd-shim/commit/4c37e048dee672237e8962fdffca28e20e9f976d) - [#10](https://github.com/npm/cmd-shim/issues/10) Work around quoted - batch file names ([@isaacs](https://github.com/isaacs)) -* [`a4e279544`](https://github.com/npm/cli/commit/a4e279544f7983e0adff1e475e3760f1ea85825a) - `npm-lifecycle@3.1.3` ([@isaacs](https://github.com/isaacs)): - * fail properly if `uid-number` raises an error -* [`7086a1809`](https://github.com/npm/cli/commit/7086a1809bbfda9be81344b3949c7d3ac687ffc4) - `libcipm@4.0.3` ([@isaacs](https://github.com/isaacs)) -* [`8845141f9`](https://github.com/npm/cli/commit/8845141f9d7827dae572c8cf26f2c775db905bd3) - `read-package-json@2.1.0` ([@isaacs](https://github.com/isaacs)) -* [`51c028215`](https://github.com/npm/cli/commit/51c02821575d80035ebe853492d110db11a7d1b9) - `bin-links@1.1.3` ([@isaacs](https://github.com/isaacs)) -* [`534a5548c`](https://github.com/npm/cli/commit/534a5548c9ebd59f0dd90e9ccca148ed8946efa6) - `read-cmd-shim@1.0.3` ([@isaacs](https://github.com/isaacs)) -* [`3038f2fd5`](https://github.com/npm/cli/commit/3038f2fd5b1d7dd886ee72798241d8943690f508) - `gentle-fs@2.2.1` ([@isaacs](https://github.com/isaacs)) -* [`a609a1648`](https://github.com/npm/cli/commit/a609a16489f76791697d270b499fd4949ab1f8c3) - `graceful-fs@4.2.2` ([@isaacs](https://github.com/isaacs)) -* [`f0346f754`](https://github.com/npm/cli/commit/f0346f75490619a81b310bfc18646ae5ae2e0ea4) - `cacache@12.0.3` ([@isaacs](https://github.com/isaacs)) -* [`ca9c615c8`](https://github.com/npm/cli/commit/ca9c615c8cff5c7db125735eb09f84d912d18694) - `npm-pick-manifest@3.0.0` ([@isaacs](https://github.com/isaacs)) -* [`b417affbf`](https://github.com/npm/cli/commit/b417affbf7133dc7687fd809e4956a43eae3438a) - `pacote@9.5.8` ([@isaacs](https://github.com/isaacs)) - -### TESTS - -* [`b6df0913c`](https://github.com/npm/cli/commit/b6df0913ca73246f1fa6cfa0e81e34ba5f2b6204) - [#228](https://github.com/npm/cli/pull/228) Proper handing of - /usr/bin/node lifecycle-path test - ([@olivr70](https://github.com/olivr70)) -* [`aaf98e88c`](https://github.com/npm/cli/commit/aaf98e88c78fd6c850d0a3d3ee2f61c02f63bc8c) - `npm-registry-mock@1.3.0` ([@isaacs](https://github.com/isaacs)) - -## v6.10.3 (2019-08-06): - -### BUGFIXES - -* [`27cccfbda`](https://github.com/npm/cli/commit/27cccfbdac8526cc807b07f416355949b1372a9b) - [#223](https://github.com/npm/cli/pull/223) vulns → vulnerabilities in - npm audit output ([@sapegin](https://github.com/sapegin)) -* [`d5e865eb7`](https://github.com/npm/cli/commit/d5e865eb79329665a927cc2767b4395c03045dbb) - [#222](https://github.com/npm/cli/pull/222) - [#226](https://github.com/npm/cli/pull/226) install, doctor: don't crash - if registry unset ([@dmitrydvorkin](https://github.com/dmitrydvorkin), - [@isaacs](https://github.com/isaacs)) -* [`5b3890226`](https://github.com/npm/cli/commit/5b389022652abeb0e1c278a152550eb95bc6c452) - [#227](https://github.com/npm/cli/pull/227) - [npm.community#9167](https://npm.community/t/npm-err-cb-never-called-permission-denied/9167/5) - Handle unhandledRejections, tell user what to do when encountering an - `EACCES` error in the cache. ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES - -* [`77516df6e`](https://github.com/npm/cli/commit/77516df6eac94a6d7acb5e9ca06feaa0868d779b) - `licensee@7.0.3` ([@isaacs](https://github.com/isaacs)) -* [`ceb993590`](https://github.com/npm/cli/commit/ceb993590e4e376a9a78264ce7bb4327fbbb37fe) - `query-string@6.8.2` ([@isaacs](https://github.com/isaacs)) -* [`4050b9189`](https://github.com/npm/cli/commit/4050b91898c60e9b22998cf82b70b9b822de592a) - `hosted-git-info@2.8.2` - * [#46](https://github.com/npm/hosted-git-info/issues/46) - [#43](https://github.com/npm/hosted-git-info/issues/43) - [#47](https://github.com/npm/hosted-git-info/pull/47) - [#44](https://github.com/npm/hosted-git-info/pull/44) Add support for - GitLab subgroups ([@mterrel](https://github.com/mterrel), - [@isaacs](https://github.com/isaacs), - [@ybiquitous](https://github.com/ybiquitous)) - * [`3b1d629`](https://github.com/npm/hosted-git-info/commit/3b1d629) - [#48](https://github.com/npm/hosted-git-info/issues/48) fix http - protocol using sshurl by default - ([@fengmk2](https://github.com/fengmk2)) - * [`5d4a8d7`](https://github.com/npm/hosted-git-info/commit/5d4a8d7) - ignore noCommittish on tarball url generation - ([@isaacs](https://github.com/isaacs)) - * [`1692435`](https://github.com/npm/hosted-git-info/commit/1692435) - use gist tarball url that works for anonymous gists - ([@isaacs](https://github.com/isaacs)) - * [`d5cf830`](https://github.com/npm/hosted-git-info/commit/d5cf8309be7af884032616c63ea302ce49dd321c) - Do not allow invalid gist urls ([@isaacs](https://github.com/isaacs)) - * [`e518222`](https://github.com/npm/hosted-git-info/commit/e5182224351183ce619dd5ef00019ae700ed37b7) - Use LRU cache to prevent unbounded memory consumption - ([@iarna](https://github.com/iarna)) - -## v6.10.2 (2019-07-23): - -tl;dr - Fixes several issues with the cache when npm is run as `sudo` on -Unix systems. - -### TESTING - -* [`2a78b96f8`](https://github.com/npm/cli/commit/2a78b96f830bbd834720ccc9eacccc54915ae6f7) - check test cache for root-owned files - ([@isaacs](https://github.com/isaacs)) -* [`108646ebc`](https://github.com/npm/cli/commit/108646ebc12f3eeebaa0a45884c45991a45e57e4) - run sudo tests on Travis-CI ([@isaacs](https://github.com/isaacs)) -* [`cf984e946`](https://github.com/npm/cli/commit/cf984e946f453cbea2fcc7a59608de3f24ab74c3) - set --no-esm tap flag ([@isaacs](https://github.com/isaacs)) -* [`8e0a3100d`](https://github.com/npm/cli/commit/8e0a3100dffb3965bb3dc4240e82980dfadf2f3c) - add script to run tests and leave fixtures for inspection and debugging - ([@isaacs](https://github.com/isaacs)) - -### BUGFIXES - -* [`25f4f73f6`](https://github.com/npm/cli/commit/25f4f73f6dc9744757787c82351120cd1baee5f8) - add a util for writing arbitrary files to cache This prevents metrics - timing and debug logs from becoming root-owned. - ([@isaacs](https://github.com/isaacs)) -* [`2c61ce65d`](https://github.com/npm/cli/commit/2c61ce65d6b67100fdf3fcb9729055b669cb1a1d) - infer cache owner from parent dir in `correct-mkdir` util - ([@isaacs](https://github.com/isaacs)) -* [`235e5d6df`](https://github.com/npm/cli/commit/235e5d6df6f427585ec58425f1f3339d08f39d8a) - ensure correct owner on cached all-packages metadata - ([@isaacs](https://github.com/isaacs)) -* [`e2d377bb6`](https://github.com/npm/cli/commit/e2d377bb6419d8a3c1d80a73dba46062b4dad336) - [npm.community#8540](https://npm.community/t/npm-audit-fails-with-child-requires-fails-because-requires-must-be-an-object/8540) - audit: report server error on failure - ([@isaacs](https://github.com/isaacs)) -* [`52576a39e`](https://github.com/npm/cli/commit/52576a39ed75d94c46bb2c482fd38d2c6ea61c56) - [#216](https://github.com/npm/cli/pull/216) - [npm.community#5385](https://npm.community/t/6-8-0-npm-ci-fails-with-local-dependency/5385) - [npm.community#6076](https://npm.community/t/npm-ci-fail-to-local-packages/6076) - Fix `npm ci` with `file:` dependencies. Partially reverts - [#40](https://github.com/npm/cli/pull/40)/[#86](https://github.com/npm/cli/pull/86), - recording dependencies of linked deps in order for `npm ci` to work. - ([@jfirebaugh](https://github.com/jfirebaugh)) - -### DEPENDENCIES - -* [`0fefdee13`](https://github.com/npm/cli/commit/0fefdee130fd7d0dbb240fb9ecb50a793fbf3d29) - `cacache@12.0.2` ([@isaacs](https://github.com/isaacs)) - * infer uid/gid instead of accepting as options, preventing the - overwhelming majority of cases where root-owned files end up in the - cache folder. - ([ac84d14](https://github.com/npm/cacache/commit/ac84d14)) - ([@isaacs](https://github.com/isaacs)) - ([#1](https://github.com/npm/cacache/pull/1)) - * **i18n:** add another error message - ([676cb32](https://github.com/npm/cacache/commit/676cb32)) - ([@zkat](https://github.com/zkat)) -* [`e1d87a392`](https://github.com/npm/cli/commit/e1d87a392371a070b0788ab7bfc62be18b21e9ad) - `pacote@9.5.4` ([@isaacs](https://github.com/isaacs)) - * git: ensure stream failures are reported - ([7f07b5d](https://github.com/npm/pacote/commit/7f07b5d)) - [#1](https://github.com/npm/pacote/issues/1) - ([@lddubeau](https://github.com/lddubeau)) -* [`3f035bf09`](https://github.com/npm/cli/commit/3f035bf098e2feea76574cec18b04812659aa16d) - `infer-owner@1.0.4` ([@isaacs](https://github.com/isaacs)) -* [`ba3283112`](https://github.com/npm/cli/commit/ba32831126591d2f6f48e31a4a2329b533b1ff19) - `npm-registry-fetch@4.0.0` ([@isaacs](https://github.com/isaacs)) -* [`ee90c334d`](https://github.com/npm/cli/commit/ee90c334d271383d0325af42f20f80f34cb61f07) - `libnpm@3.0.1` ([@isaacs](https://github.com/isaacs)) -* [`1e480c384`](https://github.com/npm/cli/commit/1e480c38416982ae28b5cdd48c698ca59d3c0395) - `libnpmaccess@3.0.2` ([@isaacs](https://github.com/isaacs)) -* [`7662ee850`](https://github.com/npm/cli/commit/7662ee850220c71ecaec639adbc7715286f0d28b) - `libnpmhook@5.0.3` ([@isaacs](https://github.com/isaacs)) -* [`1357fadc6`](https://github.com/npm/cli/commit/1357fadc613d0bfeb40f9a8f3ecace2face2fe2c) - `libnpmorg@1.0.1` ([@isaacs](https://github.com/isaacs)) -* [`a621b5cb6`](https://github.com/npm/cli/commit/a621b5cb6c881f95a11af86a8051754a67ae017c) - `libnpmsearch@2.0.2` ([@isaacs](https://github.com/isaacs)) -* [`560cd31dd`](https://github.com/npm/cli/commit/560cd31dd51b6aa2e396ccdd7289fab0a50b5608) - `libnpmteam@1.0.2` ([@isaacs](https://github.com/isaacs)) -* [`de7ae0867`](https://github.com/npm/cli/commit/de7ae0867d4c0180edc283457ce0b4e8e5eee554) - `npm-profile@4.0.2` ([@isaacs](https://github.com/isaacs)) -* [`e95da463c`](https://github.com/npm/cli/commit/e95da463cb7a325457ef411a569d7ef4bf76901d) - `libnpm@3.0.1` ([@isaacs](https://github.com/isaacs)) -* [`554b641d4`](https://github.com/npm/cli/commit/554b641d49d135ae8d137e83aa288897c32dacc6) - `npm-registry-fetch@4.0.0` ([@isaacs](https://github.com/isaacs)) -* [`06772f34a`](https://github.com/npm/cli/commit/06772f34ab851440dcd78574736936c674a84aed) - `node-gyp@5.0.3` ([@isaacs](https://github.com/isaacs)) -* [`85358db80`](https://github.com/npm/cli/commit/85358db80d6ccb5f7bc9a0b4d558ac6dd2468394) - `npm-lifecycle@3.1.2` ([@isaacs](https://github.com/isaacs)) - * [`051cf20`](https://github.com/npm/npm-lifecycle/commit/051cf20072a01839c17920d2e841756251c4f924) - [#26](https://github.com/npm/npm-lifecycle/pull/26) fix switches for - alternative shells on Windows - ([@gucong3000](https://github.com/gucong3000)) - * [`3aaf954`](https://github.com/npm/npm-lifecycle/commit/3aaf95435965e8f7acfd955582cf85237afd2c9b) - [#25](https://github.com/npm/npm-lifecycle/pull/25) set only one PATH - env variable for child process on Windows - ([@zkochan](https://github.com/zkochan)) - * [`ea18ed2`](https://github.com/npm/npm-lifecycle/commit/ea18ed2b754ca7f11998cad70d88e9004c5bef4a) - [#36](https://github.com/npm/npm-lifecycle/pull/36) - [#11](https://github.com/npm/npm-lifecycle/issue/11) - [#18](https://github.com/npm/npm-lifecycle/issue/18) remove - procInterrupt listener on SIGINT in procError - ([@mattshin](https://github.com/mattshin)) - * [`5523951`](https://github.com/npm/npm-lifecycle/commit/55239519c57b82521605622e6c71640a31ed4586) - [#29](https://github.com/npm/npm-lifecycle/issue/29) - [#30](https://github.com/npm/npm-lifecycle/pull/30) Use platform - specific path casing if present - ([@mattezell](https://github.com/mattezell)) - -## v6.10.1 (2019-07-11): - -### BUGFIXES - -* [`3cbd57712`](https://github.com/npm/cli/commit/3cbd577120a9da6e51bb8b13534d1bf71ea5712c) - fix(git): strip GIT environs when running git - ([@isaacs](https://github.com/isaacs)) -* [`a81a8c4c4`](https://github.com/npm/cli/commit/a81a8c4c466f510215a51cef1bb08544d11844fe) - [#206](https://github.com/npm/cli/pull/206) improve isOnly(Dev,Optional) - ([@larsgw](https://github.com/larsgw)) -* [`172f9aca6`](https://github.com/npm/cli/commit/172f9aca67a66ee303c17f90a994cd52fc66552a) - [#179](https://github.com/npm/cli/pull/179) fix-xmas-underline - ([@raywu0123](https://github.com/raywu0123)) -* [`f52673fc7`](https://github.com/npm/cli/commit/f52673fc7284e58af8c04533e82b76bf7add72cf) - [#212](https://github.com/npm/cli/pull/212) build: use `/usr/bin/env` to - load bash ([@rsmarples](https://github.com/rsmarples)) - -### DEPENDENCIES - -* [`ef4445ad3`](https://github.com/npm/cli/commit/ef4445ad34a53b5639499c8e3c9752f62ee6f37c) - [#208](https://github.com/npm/cli/pull/208) `node-gyp@5.0.2` - ([@irega](https://github.com/irega)) -* [`c0d611356`](https://github.com/npm/cli/commit/c0d611356f7b23077e97574b01c8886e544db425) - `npm-lifecycle@3.0.0` ([@isaacs](https://github.com/isaacs)) -* [`7716ba972`](https://github.com/npm/cli/commit/7716ba9720270d5b780755a5bb1ce79702067f1f) - `libcipm@4.0.0` ([@isaacs](https://github.com/isaacs)) -* [`42d22e837`](https://github.com/npm/cli/commit/42d22e8374c7d303d94e405d7385d94dd2558814) - `libnpm@3.0.0` ([@isaacs](https://github.com/isaacs)) -* [`a2ea7f9ff`](https://github.com/npm/cli/commit/a2ea7f9ff64ae743d05fdbf7d46fb9afafa8aa6f) - `semver@5.7.0` ([@isaacs](https://github.com/isaacs)) -* [`429226a5e`](https://github.com/npm/cli/commit/429226a5e992cd907d4f19bd738037007cf78c1f) - `lru-cache@5.1.1` ([@isaacs](https://github.com/isaacs)) -* [`175670ea6`](https://github.com/npm/cli/commit/175670ea65cca03f8b2e957df3dd4b8b0efd0e1f) - `npm-registry-fetch@3.9.1`: ([@isaacs](https://github.com/isaacs)) -* [`0d0517f7f`](https://github.com/npm/cli/commit/0d0517f7f8c902b5064ac18fb4015b31750ad2b2) - `call-limit@1.1.1` ([@isaacs](https://github.com/isaacs)) -* [`741400429`](https://github.com/npm/cli/commit/74140042917ea241062a812ceb65c5423c2bafa9) - `glob@7.1.4` ([@isaacs](https://github.com/isaacs)) -* [`bddd60e30`](https://github.com/npm/cli/commit/bddd60e302283a4a70d35f8f742e42bd13f4dabf) - `inherits@2.0.4` ([@isaacs](https://github.com/isaacs)) -* [`4acf03fd1`](https://github.com/npm/cli/commit/4acf03fd140ed3ddb2dcf3fdc9756bc3f5a8bcbb) - `libnpmsearch@2.0.1` ([@isaacs](https://github.com/isaacs)) -* [`c2bd17291`](https://github.com/npm/cli/commit/c2bd17291a86bea7ced2fbd07d66d013bd7a7560) - `marked@0.6.3` ([@isaacs](https://github.com/isaacs)) -* [`7f0221bb1`](https://github.com/npm/cli/commit/7f0221bb1bb41ffc933c785940e227feae38c80c) - `marked-man@0.6.0` ([@isaacs](https://github.com/isaacs)) -* [`f458fe7dd`](https://github.com/npm/cli/commit/f458fe7dd3bebddf603aaae183a424ea8aaa018f) - `npm-lifecycle@2.1.1` ([@isaacs](https://github.com/isaacs)) -* [`009752978`](https://github.com/npm/cli/commit/0097529780269c28444f1efa0d7c131d47a933eb) - `node-gyp@4.0.0` ([@isaacs](https://github.com/isaacs)) -* [`0fa2bb438`](https://github.com/npm/cli/commit/0fa2bb4386379d6e9d8c95db08662ec0529964f9) - `query-string@6.8.1` ([@isaacs](https://github.com/isaacs)) -* [`b86450929`](https://github.com/npm/cli/commit/b86450929796950a1fe4b1f9b02b1634c812f3bb) - `tar-stream@2.1.0` ([@isaacs](https://github.com/isaacs)) -* [`25db00fe9`](https://github.com/npm/cli/commit/25db00fe953453198adb9e1bd71d1bc2a9f04aaa) - `worker-farm@1.7.0` ([@isaacs](https://github.com/isaacs)) -* [`8dfbe8610`](https://github.com/npm/cli/commit/8dfbe861085dfa8fa56bb504b4a00fba04c34f9d) - `readable-stream@3.4.0` ([@isaacs](https://github.com/isaacs)) -* [`f6164d5dd`](https://github.com/npm/cli/commit/f6164d5ddd072eabdf2237f1694a31efd746eb1d) - [isaacs/chownr#21](https://github.com/isaacs/chownr/pull/21) - [isaacs/chownr#20](https://github.com/isaacs/chownr/issues/20) - [npm.community#7901](https://npm.community/t/7901/) - [npm.community#8203](https://npm.community/t/8203) `chownr@1.1.2` This - fixes an EISDIR error from cacache on Darwin in Node versions prior to - 10.6. ([@isaacs](https://github.com/isaacs)) - -## v6.10.0 (2019-07-03): - -### FEATURES - -* [`87fef4e35`](https://github.com/npm/cli/commit/87fef4e35) - [#176](https://github.com/npm/cli/pull/176) fix: Always return JSON for - outdated --json ([@sreeramjayan](https://github.com/sreeramjayan)) -* [`f101d44fc`](https://github.com/npm/cli/commit/f101d44fc) - [#203](https://github.com/npm/cli/pull/203) fix(unpublish): add space - after hyphen ([@ffflorian](https://github.com/ffflorian)) -* [`a4475de4c`](https://github.com/npm/cli/commit/a4475de4c) - [#202](https://github.com/npm/cli/pull/202) enable production flag for - npm audit ([@CalebCourier](https://github.com/CalebCourier)) -* [`d192904d0`](https://github.com/npm/cli/commit/d192904d0) - [#178](https://github.com/npm/cli/pull/178) fix: Return a value for - `view` when in silent mode - ([@stayradiated](https://github.com/stayradiated)) -* [`39d473adf`](https://github.com/npm/cli/commit/39d473adf) - [#185](https://github.com/npm/cli/pull/185) Allow git to follow global - tagsign config ([@junderw](https://github.com/junderw)) - -### BUGFIXES - -* [`d9238af0b`](https://github.com/npm/cli/commit/d9238af0b) - [#201](https://github.com/npm/cli/pull/163) - [npm/npm#17858](https://github.com/npm/npm/issues/17858) - [npm/npm#18042](https://github.com/npm/npm/issues/18042) - [npm.community#644](https://npm.community/t/644) do not crash when - removing nameless packages - ([@SteveVanOpstal](https://github.com/SteveVanOpstal) and - [@isaacs](https://github.com/isaacs)) -* [`4bec4f111`](https://github.com/npm/cli/commit/4bec4f111) - [#200](https://github.com/npm/cli/pull/200) Check for `node` (as well as - `node.exe`) in npm's local dir on Windows - ([@rgoulais](https://github.com/rgoulais)) -* [`ce93dab2d`](https://github.com/npm/cli/commit/ce93dab2db423ef23b3e08a0612dafbeb2d25789) - [#180](https://github.com/npm/cli/pull/180) - [npm.community#6187](https://npm.community/t/6187) Fix handling of - `remote` deps in `npm outdated` ([@larsgw](https://github.com/larsgw)) - -### TESTING - -* [`a823f3084`](https://github.com/npm/cli/commit/a823f3084) travis: Update - to include new v12 LTS ([@isaacs](https://github.com/isaacs)) -* [`33e2d1dac`](https://github.com/npm/cli/commit/33e2d1dac) fix flaky - debug-logs test ([@isaacs](https://github.com/isaacs)) -* [`e9411c6cd`](https://github.com/npm/cli/commit/e9411c6cd) Don't time out - waiting for gpg user input ([@isaacs](https://github.com/isaacs)) -* [`d2d301704`](https://github.com/npm/cli/commit/d2d301704) - [#195](https://github.com/npm/cli/pull/195) Add the arm64 check for - legacy-platform-all.js test case. - ([@ossdev07](https://github.com/ossdev07)) -* [`a4dc34243`](https://github.com/npm/cli/commit/a4dc34243) parallel tests - ([@isaacs](https://github.com/isaacs)) - -### DOCUMENTATION - -* [`f5857e263`](https://github.com/npm/cli/commit/f5857e263) - [#192](https://github.com/npm/cli/pull/192) Clarify usage of - bundledDependencies - ([@john-osullivan](https://github.com/john-osullivan)) -* [`747fdaf66`](https://github.com/npm/cli/commit/747fdaf66) - [#159](https://github.com/npm/cli/pull/159) doc: add --audit-level param - ([@ngraef](https://github.com/ngraef)) - -### DEPENDENCIES - -* [`e36b3c320`](https://github.com/npm/cli/commit/e36b3c320) - graceful-fs@4.2.0 ([@isaacs](https://github.com/isaacs)) -* [`6bb935c09`](https://github.com/npm/cli/commit/6bb935c09) - read-package-tree@5.3.1 ([@isaacs](https://github.com/isaacs)) - * [`e9cd536`](https://github.com/npm/read-package-tree/commit/e9cd536) - Use custom caching `realpath` implementation, dramatically reducing - `lstat` calls when reading the package tree - ([@isaacs](https://github.com/isaacs)) -* [`39538b460`](https://github.com/npm/cli/commit/39538b460) - write-file-atomic@2.4.3 ([@isaacs](https://github.com/isaacs)) - * [`f8b1552`](https://github.com/npm/write-file-atomic/commit/f8b1552) - [#38](https://github.com/npm/write-file-atomic/pull/38) Ignore errors - raised by `fs.closeSync` ([@lukeapage](https://github.com/lukeapage)) -* [`042193069`](https://github.com/npm/cli/commit/042193069) pacote@9.5.1 - ([@isaacs](https://github.com/isaacs)) - * [`8bbd051`](https://github.com/npm/pacote/commit/8bbd051) - [#172](https://github.com/zkat/pacote/pull/172) limit git retry - times, avoid unlimited retries ([小秦](https://github.com/xqin)) - * [`92f5e4c`](https://github.com/npm/pacote/commit/92f5e4c) - [#170](https://github.com/zkat/pacote/pull/170) fix(errors): Fix - "TypeError: err.code.match is not a function" error - ([@jviotti](https://github.com/jviotti)) -* [`8bd8e909f`](https://github.com/npm/cli/commit/8bd8e909f) cacache@11.3.3 - ([@isaacs](https://github.com/isaacs)) - * [`47de8f5`](https://github.com/npm/cacache/commit/47de8f5) - [#146](https://github.com/zkat/cacache/pull/146) - [npm.community#2395](https://npm.community/t/2395) fix(config): Add - ssri config 'error' option ([@larsgw](https://github.com/larsgw)) - * [`5156561`](https://github.com/npm/cacache/commit/5156561) - fix(write): avoid a `cb never called` situation - ([@zkat](https://github.com/zkat)) - * [`90f40f0`](https://github.com/npm/cacache/commit/90f40f0) - [#166](https://github.com/zkat/cacache/pull/166) - [#165](https://github.com/zkat/cacache/issues/165) docs: Fix docs for - `path` property in get.info - ([@hdgarrood](https://github.com/hdgarrood)) -* [`bf61c45c6`](https://github.com/npm/cli/commit/bf61c45c6) bluebird@3.5.5 - ([@isaacs](https://github.com/isaacs)) -* [`f75d46a9d`](https://github.com/npm/cli/commit/f75d46a9d) tar@4.4.10 - ([@isaacs](https://github.com/isaacs)) - * [`c80341a`](https://github.com/npm/node-tar/commit/c80341a) - [#215](https://github.com/npm/node-tar/pull/215) Fix - encoding/decoding of base-256 numbers - ([@justfalter](https://github.com/justfalter)) - * [`77522f0`](https://github.com/npm/node-tar/commit/77522f0) - [#204](https://github.com/npm/node-tar/issues/204) - [#214](https://github.com/npm/node-tar/issues/214) Use `stat` instead - of `lstat` when checking CWD ([@stkb](https://github.com/stkb)) -* [`ec6236210`](https://github.com/npm/cli/commit/ec6236210) - npm-packlist@1.4.4 ([@isaacs](https://github.com/isaacs)) - * [`63d1e3e`](https://github.com/npm/npm-packlist/commit/63d1e3e) - [#30](https://github.com/npm/npm-packlist/issues/30) Sort package - tarball entries by file type for compression benefits - ([@isaacs](https://github.com/isaacs)) - * [`7fcd045`](https://github.com/npm/npm-packlist/commit/7fcd045) - Ignore `.DS_Store` files as well as folders - ([@isaacs](https://github.com/isaacs)) - * [`68b7c96`](https://github.com/npm/npm-packlist/commit/68b7c96) Never - include .git folders in package root. (Note: this prevents the issue - that broke the v6.9.1 release.) - ([@isaacs](https://github.com/isaacs)) -* [`57bef61bc`](https://github.com/npm/cli/commit/57bef61bc) update fstream - in node-gyp ([@isaacs](https://github.com/isaacs)) - * Addresses [security advisory - #886](https://www.npmjs.com/advisories/886) -* [`acbbf7eee`](https://github.com/npm/cli/commit/acbbf7eee) - [#183](https://github.com/npm/cli/pull/183) licensee@7.0.2 - ([@kemitchell](https://github.com/kemitchell)) -* [`011ae67f0`](https://github.com/npm/cli/commit/011ae67f0) - readable-stream@3.3.0 ([@isaacs](https://github.com/isaacs)) -* [`f5e884909`](https://github.com/npm/cli/commit/f5e884909) - npm-registry-mock@1.2.1 ([@isaacs](https://github.com/isaacs)) -* [`b57d07e35`](https://github.com/npm/cli/commit/b57d07e35) - npm-registry-couchapp@2.7.2 ([@isaacs](https://github.com/isaacs)) - -## v6.9.2 (2019-06-27): - -This release is identical to v6.9.1, but we had to publish a new version -due to [a .git directory in the release](https://npm.community/t/8454). - -## v6.9.1 (2019-06-26): - -### BUGFIXES - -* [`6b1a9da0e`](https://github.com/npm/cli/commit/6b1a9da0e0f5c295cdaf4dea4b73bd221d778611) - [#165](https://github.com/npm/cli/pull/165) - Update `knownBroken` version. - ([@ljharb](https://github.com/ljharb)) -* [`d07547154`](https://github.com/npm/cli/commit/d07547154eb8a88aa4fde8a37e128e1e3272adc1) - [npm.community#5929](https://npm.community/t/npm-outdated-throw-an-error-cannot-read-property-length-of-undefined/5929) - Fix `outdated` rendering for global dependencies. - ([@zkat](https://github.com/zkat)) -* [`e4a1f1745`](https://github.com/npm/cli/commit/e4a1f174514a57580fd5e0fa33eee0f42bba77fc) - [npm.community#6259](https://npm.community/t/npm-token-create-doesnt-work-in-6-6-0-6-9-0/6259) - Fix OTP for token create and remove. - ([@zkat](https://github.com/zkat)) - -### DEPENDENCIES - -* [`a163a9c35`](https://github.com/npm/cli/commit/a163a9c35f6f341de343562368056258bba5d7dc) - `sha@3.0.0` - ([@aeschright](https://github.com/aeschright)) -* [`47b08b3b9`](https://github.com/npm/cli/commit/47b08b3b9860438b416efb438e975a628ec2eed5) - `query-string@6.4.0` - ([@aeschright](https://github.com/aeschright)) -* [`d6a956cff`](https://github.com/npm/cli/commit/d6a956cff6357e6de431848e578c391768685a64) - `readable-stream@3.2.0` - ([@aeschright](https://github.com/aeschright)) -* [`10b8bed2b`](https://github.com/npm/cli/commit/10b8bed2bb0afac5451164e87f25924cc1ac6f2e) - `tacks@1.3.0` - ([@aeschright](https://github.com/aeschright)) -* [`e7483704d`](https://github.com/npm/cli/commit/e7483704dda1acffc8c6b8c165c14c8a7512f3c8) - `tap@12.6.0` - ([@aeschright](https://github.com/aeschright)) -* [`3242fe698`](https://github.com/npm/cli/commit/3242fe698ead46a9cda94e1a4d489cd84a85d7e3) - `tar-stream@2.0.1` - ([@aeschright](https://github.com/aeschright)) - -## v6.9.0 (2019-02-20): - -### FEATURES - -* [`2ba3a0f67`](https://github.com/npm/cli/commit/2ba3a0f6721f6d5a16775aebce6012965634fc7c) - [#90](https://github.com/npm/cli/pull/90) - Time traveling installs using the `--before` flag. - ([@zkat](https://github.com/zkat)) -* [`b7b54f2d1`](https://github.com/npm/cli/commit/b7b54f2d18e2d8d65ec67c850b21ae9f01c60e7e) - [#3](https://github.com/npm/cli/pull/3) - Add support for package aliases. This allows packages to be installed under a - different directory than the package name listed in `package.json`, and adds a - new dependency type to allow this to be done for registry dependencies. - ([@zkat](https://github.com/zkat)) -* [`684bccf06`](https://github.com/npm/cli/commit/684bccf061dfc97bb759121bc0ad635e01c65868) - [#146](https://github.com/npm/cli/pull/146) - Always save `package-lock.json` when using `--package-lock-only`. - ([@aeschright](https://github.com/aeschright)) -* [`b8b8afd40`](https://github.com/npm/cli/commit/b8b8afd4048b4ba1181e00ba2ac49ced43936ce0) - [#139](https://github.com/npm/cli/pull/139) - Make empty-string run-scripts run successfully as a no-op. - ([@vlasy](https://github.com/vlasy)) -* [`8047b19b1`](https://github.com/npm/cli/commit/8047b19b1b994fd4b4e7b5c91d7cc4e0384bd5e4) - [npm.community#3784](https://npm.community/t/3784) - Match git semver ranges when flattening the tree. - ([@larsgw](https://github.com/larsgw)) -* [`e135c2bb3`](https://github.com/npm/cli/commit/e135c2bb360dcf00ecee34a95985afec21ba3655) - [npm.community#1725](https://npm.community/t/1725?u=larsgw) - Re-enable updating local packages. - ([@larsgw](https://github.com/larsgw)) - -### BUGFIXES - -* [`cf09fbaed`](https://github.com/npm/cli/commit/cf09fbaed489d908e9b551382cc5f61bdabe99a9) - [#153](https://github.com/npm/cli/pull/153) - Set modified to undefined in `npm view` when `time` is not available. This - fixes a bug where `npm view` would crash on certain third-party registries. - ([@simonua](https://github.com/simonua)) -* [`774fc26ee`](https://github.com/npm/cli/commit/774fc26eeb01345c11bd8c97e2c4f328d419d9b5) - [#154](https://github.com/npm/cli/pull/154) - Print out tar version in `install.sh` only when the flag is supported not all - the tar implementations support --version flag. This allows the install script - to work in OpenBSD, for example. - ([@agudulin](https://github.com/agudulin)) -* [`863baff11`](https://github.com/npm/cli/commit/863baff11d8c870f1a0d9619bb5133c67d71e407) - [#158](https://github.com/npm/cli/pull/158) - Fix typo in error message for `npm stars`. - ([@phihag](https://github.com/phihag)) -* [`a805a95ad`](https://github.com/npm/cli/commit/a805a95ad8832ef5008671f4bd4c11b83e32e0f2) - [npm.community#4227](https://npm.community/t/4227) - Strip version info from pkg on E404. This improves the error messaging format. - ([@larsgw](https://github.com/larsgw)) - -### DOCS - -* [`5d7633833`](https://github.com/npm/cli/commit/5d76338338621fd0b3d4f7914a51726d27569ee1) - [#160](https://github.com/npm/cli/pull/160) - Add `npm add` as alias to npm install in docs. - ([@ahasall](https://github.com/ahasall)) -* [`489c2211c`](https://github.com/npm/cli/commit/489c2211c96a01d65df50fd57346c785bcc3efe6) - [#162](https://github.com/npm/cli/pull/162) - Fix link to RFC #10 in the changelog. - ([@mansona](https://github.com/mansona)) -* [`433020ead`](https://github.com/npm/cli/commit/433020ead5251b562bc3b0f5f55341a5b8cc9023) - [#135](https://github.com/npm/cli/pull/135) - Describe exit codes in npm-audit docs. - ([@emilis-tm](https://github.com/emilis-tm)) - -### DEPENDENCIES - -* [`ee6b6746b`](https://github.com/npm/cli/commit/ee6b6746b04f145dfe489af2d26667ac32ba0cef) - [zkat/make-fetch-happen#29](https://github.com/zkat/make-fetch-happen/issues/29) - `agent-base@4.2.1` - ([@TooTallNate](https://github.com/TooTallNate)) -* [`2ce23baf5`](https://github.com/npm/cli/commit/2ce23baf53b1ce7d11b8efb80c598ddaf9cef9e7) - `lock-verify@2.1.0`: - Adds support for package aliases - ([@zkat](https://github.com/zkat)) -* [`baaedbc6e`](https://github.com/npm/cli/commit/baaedbc6e2fc370d73b35e7721794719115507cc) - `pacote@9.5.0`: - Adds opts.before support - ([@zkat](https://github.com/zkat)) -* [`57e771a03`](https://github.com/npm/cli/commit/57e771a032165d1e31e71d0ff7530442139c21a6) - [#164](https://github.com/npm/cli/pull/164) - `licensee@6.1.0` - ([@kemitchell](https://github.com/kemitchell)) -* [`2b78288d4`](https://github.com/npm/cli/commit/2b78288d4accd10c1b7cc6c36bc28045f5634d91) - add core to default inclusion tests in pack - ([@Kat Marchán](https://github.com/Kat Marchán)) -* [`9b8b6513f`](https://github.com/npm/cli/commit/9b8b6513fbce92764b32a067322984985ff683fe) - [npm.community#5382](https://npm.community/t/npm-pack-leaving-out-files-6-8-0-only/5382) - `npm-packlist@1.4.1`: Fixes bug where `core/` directories were being suddenly excluded. - ([@zkat](https://github.com/zkat)) - -## v6.8.0 (2019-02-07): - -This release includes an implementation of [RFC #10](https://github.com/npm/rfcs/blob/latest/implemented/0010-monorepo-subdirectory-declaration.md), documenting an optional field that can be used to specify -the directory path for a package within a monorepo. - -### NEW FEATURES - -* [`3663cdef2`](https://github.com/npm/cli/commit/3663cdef205fa9ba2c2830e5ef7ceeb31c30298c) - [#140](https://github.com/npm/cli/pull/140) - Update package.json docs to include repository.directory details. - ([@greysteil](https://github.com/greysteil)) - -### BUGFIXES - -* [`550bf703a`](https://github.com/npm/cli/commit/550bf703ae3e31ba6a300658ae95b6937f67b68f) - Add @types to ignore list to fix git clean -fd. - ([@zkat](https://github.com/zkat)) -* [`cdb059293`](https://github.com/npm/cli/commit/cdb0592939d6256c80f7ec5a2b6251131a512a2a) - [#144](https://github.com/npm/cli/pull/144) - Fix common.npm callback arguments. - ([@larsgw](https://github.com/larsgw)) -* [`25573e9b9`](https://github.com/npm/cli/commit/25573e9b9d5d26261c68d453f06db5b3b1cd6789) - [npm.community#4770](https://npm.community/t/https://npm.community/t/4770) - Show installed but unmet peer deps. - ([@larsgw](https://github.com/larsgw)) -* [`ce2c4bd1a`](https://github.com/npm/cli/commit/ce2c4bd1a2ce7ac1727a4ca9a350b743a2e27b2a) - [#149](https://github.com/npm/cli/pull/149) - Use figgy-config to make sure extra opts are there. - ([@zkat](https://github.com/zkat)) -* [`3c22d1a35`](https://github.com/npm/cli/commit/3c22d1a35878f73c0af8ea5968b962a85a1a9b84) - [npm.community#5101](https://npm.community/t/npm-6-6-0-breaks-access-to-ls-collaborators/5101) - Fix `ls-collaborators` access error for non-scoped case. - ([@zkat](https://github.com/zkat)) -* [`d5137091d`](https://github.com/npm/cli/commit/d5137091dd695a2980f7ade85fdc56b2421ff677) - [npm.community#754](https://npm.community/t/npm-install-for-package-with-local-dependency-fails/754) - Fix issue with sub-folder local references. - ([@iarna](https://github.com/iarna)) - ([@jhecking](https://github.com/jhecking)) - -### DEPENDENCY BUMPS - -* [`d72141080`](https://github.com/npm/cli/commit/d72141080ec8fcf35bcc5650245efbe649de053e) - `npm-registry-couchapp@2.7.1` - ([@zkat](https://github.com/zkat)) -* [`671cad1b1`](https://github.com/npm/cli/commit/671cad1b18239d540da246d6f78de45d9f784396) - `npm-registry-fetch@3.9.0`: - Make sure publishing with legacy username:password `_auth` works again. - ([@zkat](https://github.com/zkat)) -* [`95ca1aef4`](https://github.com/npm/cli/commit/95ca1aef4077c8e68d9f4dce37f6ba49b591c4ca) - `pacote@9.4.1` - ([@aeschright](https://github.com/aeschright)) -* [`322fef403`](https://github.com/npm/cli/commit/322fef40376e71cd100159dc914e7ca89faae327) - `normalize-package-data@2.5.0` - ([@aeschright](https://github.com/aeschright)) -* [`32d34c0da`](https://github.com/npm/cli/commit/32d34c0da4f393a74697297667eb9226155ecc6b) - `npm-packlist@1.3.0` - ([@aeschright](https://github.com/aeschright)) -* [`338571cf0`](https://github.com/npm/cli/commit/338571cf0bd3a1e2ea800464d57581932ff0fb11) - `read-package-tree@5.2.2` - ([@zkat](https://github.com/zkat)) - -### MISC - -* [`89b23a5f7`](https://github.com/npm/cli/commit/89b23a5f7b0ccdcdda1d7d4d3eafb6903156d186) - [#120](https://github.com/npm/cli/pull/120) - Use `const` in lib/fetch-package-metadata.md. - ([@watilde](https://github.com/watilde)) -* [`4970d553c`](https://github.com/npm/cli/commit/4970d553c0ea66128931d118469fd31c87cc7986) - [#126](https://github.com/npm/cli/pull/126) - Replace ronn with marked-man in `.npmignore`. - ([@watilde](https://github.com/watilde)) -* [`d9b6090dc`](https://github.com/npm/cli/commit/d9b6090dc26cd0fded18b4f80248cff3e51bb185) - [#138](https://github.com/npm/cli/pull/138) - Reduce work to test if executable ends with a 'g'. - ([@elidoran](https://github.com/elidoran)) - ([@larsgw](https://github.com/larsgw)) - -## v6.7.0 (2019-01-23): - -Hey y'all! This is a quick hotfix release that includes some important fixes to -`npm@6.6.0` related to the large rewrite/refactor. We're tagging it as a feature -release because the changes involve some minor new features, and semver is -semver, but there's nothing major here. - -### NEW FEATURES - -* [`50463f58b`](https://github.com/npm/cli/commit/50463f58b4b70180a85d6d8c10fcf50d8970ef5e) - Improve usage errors to `npm org` commands and add optional filtering to `npm - org ls` subcommand. - ([@zkat](https://github.com/zkat)) - -### BUGFIXES - -* [`4027070b0`](https://github.com/npm/cli/commit/4027070b03be3bdae2515f2291de89b91f901df9) - Fix default usage printout for `npm org` so you actually see how it's supposed - to be used. - ([@zkat](https://github.com/zkat)) -* [`cfea6ea5b`](https://github.com/npm/cli/commit/cfea6ea5b67ec5e4ec57e3a9cb8c82d018cb5476) - fix default usage message for npm hook - ([@zkat](https://github.com/zkat)) - -### DOCS - -* [`e959e1421`](https://github.com/npm/cli/commit/e959e14217d751ddb295565fd75cc81de1ee0d5b) - Add manpage for `npm org` command. - ([@zkat](https://github.com/zkat)) - -### DEPENDENCY BUMPS - -* [`8543fc357`](https://github.com/npm/cli/commit/8543fc3576f64e91f7946d4c56a5ffb045b55156) - `pacote@9.4.0`: Fall back to "fullfat" packuments on ETARGET errors. This will - make it so that, when a package is published but the corgi follower hasn't - caught up, users can still install a freshly-published package. - ([@zkat](https://github.com/zkat)) -* [`75475043b`](https://github.com/npm/cli/commit/75475043b03a254b2e7db2c04c3f0baea31d8dc5) - [npm.community#4752](https://npm.community/t/npm-6-6-0-broke-authentication-with-npm-registry-couchapp/4752) - `libnpmpublish@1.1.1`: Fixes auth error for username/password legacy authentication. - ([@sreeramjayan](https://github.com/sreeramjayan)) -* [`0af8c00ac`](https://github.com/npm/cli/commit/0af8c00acb01849362ffca25b567cc62447c7175) - [npm.community#4746](https://npm.community/t/npm-6-6-0-release-breaking-docker-npm-ci-commands/4746) - `libcipm@3.0.3`: Fixes issue with "cannot run in wd" errors for run-scripts. - ([@zkat](https://github.com/zkat)) -* [`5a7962e46`](https://github.com/npm/cli/commit/5a7962e46f582c6bd91784b0ddc941ed45e9f802) - `write-file-atomic@2.4.2`: - Fixes issues with leaking `signal-exit` instances and file descriptors. - ([@iarna](https://github.com/iarna)) - -## v6.6.0 (2019-01-17): - -### REFACTORING OUT npm-REGISTRY-CLIENT - -Today is an auspicious day! This release marks the end of a massive internal -refactor to npm that means we finally got rid of the legacy -[`npm-registry-client`](https://npm.im/npm-registry-client) in favor of the -shiny, new, `window.fetch`-like -[`npm-registry-fetch`](https://npm.im/npm-registry-fetch). - -Now, the installer had already done most of this work with the release of -`npm@5`, but it turns out _every other command_ still used the legacy client. -This release updates all of those commands to use the new client, and while -we're at it, adds a few extra goodies: - -* All OTP-requiring commands will now **prompt**. `--otp` is no longer required for `dist-tag`, `access`, et al. -* We're starting to integrate a new config system which will eventually get extracted into a standalone package. -* We now use [`libnpm`](https://npm.im/libnpm) for the API functionality of a lot of our commands! That means you can install a library if you want to write your own tooling around them. -* There's now an `npm org` command for managing users in your org. -* [`pacote`](https://npm.im/pacote) now consumes npm-style configurations, instead of its own naming for various config vars. This will make it easier to load npm configs using `libnpm.config` and hand them directly to `pacote`. - -There's too many commits to list all of them here, so check out the PR if you're -curious about details: - -* [`c5af34c05`](https://github.com/npm/cli/commit/c5af34c05fd569aecd11f18d6d0ddeac3970b253) - [npm-registry-client@REMOVED](https://www.youtube.com/watch\?v\=kPIdRJlzERo) - ([@zkat](https://github.com/zkat)) -* [`4cca9cb90`](https://github.com/npm/cli/commit/4cca9cb9042c0eeb743377e8f1ae1c07733df43f) - [`ad67461dc`](https://github.com/npm/cli/commit/ad67461dc3a73d5ae6569fdbee44c67e1daf86e7) - [`77625f9e2`](https://github.com/npm/cli/commit/77625f9e20d4285b7726b3bf3ebc10cb21c638f0) - [`6e922aefb`](https://github.com/npm/cli/commit/6e922aefbb4634bbd77ed3b143e0765d63afc7f9) - [`584613ea8`](https://github.com/npm/cli/commit/584613ea8ff94b927db4957e5647504b30ca2b1f) - [`64de4ebf0`](https://github.com/npm/cli/commit/64de4ebf019b217179039124c6621e74651e4d27) - [`6cd87d1a9`](https://github.com/npm/cli/commit/6cd87d1a9bb90e795f9891ea4db384435f4a8930) - [`2786834c0`](https://github.com/npm/cli/commit/2786834c0257b8bb1bbb115f1ce7060abaab2e17) - [`514558e09`](https://github.com/npm/cli/commit/514558e094460fd0284a759c13965b685133b3fe) - [`dec07ebe3`](https://github.com/npm/cli/commit/dec07ebe3312245f6421c6e523660be4973ae8c2) - [`084741913`](https://github.com/npm/cli/commit/084741913c4fdb396e589abf3440b4be3aa0b67e) - [`45aff0e02`](https://github.com/npm/cli/commit/45aff0e02251785a85e56eafacf9efaeac6f92ae) - [`846ddcc44`](https://github.com/npm/cli/commit/846ddcc44538f2d9a51ac79405010dfe97fdcdeb) - [`8971ba1b9`](https://github.com/npm/cli/commit/8971ba1b953d4f05ff5094f1822b91526282edd8) - [`99156e081`](https://github.com/npm/cli/commit/99156e081a07516d6c970685bc3d858f89dc4f9c) - [`ab2155306`](https://github.com/npm/cli/commit/ab215530674d7f6123c9572d0ad4ca9e9b5fb184) - [`b37a66542`](https://github.com/npm/cli/commit/b37a66542ca2879069b2acd338b1904de71b7f40) - [`d2af0777a`](https://github.com/npm/cli/commit/d2af0777ac179ff5009dbbf0354a4a84f151b60f) - [`e0b4c6880`](https://github.com/npm/cli/commit/e0b4c6880504fa2e8491c2fbd098efcb2e496849) - [`ff72350b4`](https://github.com/npm/cli/commit/ff72350b4c56d65e4a92671d86a33080bf3c2ea5) - [`6ed943303`](https://github.com/npm/cli/commit/6ed943303ce7a267ddb26aa25caa035f832895dd) - [`90a069e7d`](https://github.com/npm/cli/commit/90a069e7d4646682211f4cabe289c306ee1d5397) - [`b24ed5fdc`](https://github.com/npm/cli/commit/b24ed5fdc3a4395628465ae5273bad54eea274c8) - [`ec9fcc14f`](https://github.com/npm/cli/commit/ec9fcc14f4e0e2f3967e2fd6ad8b8433076393cb) - [`8a56fa39e`](https://github.com/npm/cli/commit/8a56fa39e61136da45565447fe201a57f04ad4cd) - [`41d19e18f`](https://github.com/npm/cli/commit/41d19e18f769c6f0acfdffbdb01d12bf332908ce) - [`125ff9551`](https://github.com/npm/cli/commit/125ff9551595dda9dab2edaef10f4c73ae8e1433) - [`1c3b226ff`](https://github.com/npm/cli/commit/1c3b226ff37159c426e855e83c8f6c361603901d) - [`3c0a7b06b`](https://github.com/npm/cli/commit/3c0a7b06b6473fe068fc8ae8466c07a177975b87) - [`08fcb3f0f`](https://github.com/npm/cli/commit/08fcb3f0f26e025702b35253ed70a527ab69977f) - [`c8135d97a`](https://github.com/npm/cli/commit/c8135d97a424b38363dc4530c45e4583471e9849) - [`ae936f22c`](https://github.com/npm/cli/commit/ae936f22ce80614287f2769e9aaa9a155f03cc15) - [#2](https://github.com/npm/cli/pull/2) - Move rest of commands to `npm-registry-fetch` and use [`figgy-pudding`](https://npm.im/figgy-pudding) for configs. - ([@zkat](https://github.com/zkat)) - -### NEW FEATURES - -* [`02c837e01`](https://github.com/npm/cli/commit/02c837e01a71a26f37cbd5a09be89df8a9ce01da) - [#106](https://github.com/npm/cli/pull/106) - Make `npm dist-tags` the same as `npm dist-tag ls`. - ([@isaacs](https://github.com/isaacs)) -* [`1065a7809`](https://github.com/npm/cli/commit/1065a7809161fd4dc23e96b642019fc842fdacf2) - [#65](https://github.com/npm/cli/pull/65) - Add support for `IBM i`. - ([@dmabupt](https://github.com/dmabupt)) -* [`a22e6f5fc`](https://github.com/npm/cli/commit/a22e6f5fc3e91350d3c64dcc88eabbe0efbca759) - [#131](https://github.com/npm/cli/pull/131) - Update profile to support new npm-profile API. - ([@zkat](https://github.com/zkat)) - -### BUGFIXES - -* [`890a74458`](https://github.com/npm/cli/commit/890a74458dd4a55e2d85f3eba9dbf125affa4206) - [npm.community#3278](https://npm.community/t/3278) - Fix support for passing git binary path config with `--git`. - ([@larsgw](https://github.com/larsgw)) -* [`90e55a143`](https://github.com/npm/cli/commit/90e55a143ed1de8678d65c17bc3c2b103a15ddac) - [npm.community#2713](https://npm.community/t/npx-envinfo-preset-jest-fails-on-windows-with-a-stack-trace/2713) - Check for `npm.config`'s existence in `error-handler.js` to prevent weird - errors when failures happen before config object is loaded. - ([@BeniCheni](https://github.com/BeniCheni)) -* [`134207174`](https://github.com/npm/cli/commit/134207174652e1eb6d7b0f44fd9858a0b6a0cd6c) - [npm.community#2569](https://npm.community/t/2569) - Fix checking for optional dependencies. - ([@larsgw](https://github.com/larsgw)) -* [`7a2f6b05d`](https://github.com/npm/cli/commit/7a2f6b05d27f3bcf47a48230db62e86afa41c9d3) - [npm.community#4172](https://npm.community/t/4172) - Remove tink experiments. - ([@larsgw](https://github.com/larsgw)) -* [`c5b6056b6`](https://github.com/npm/cli/commit/c5b6056b6b35eefb81ae5fb00a5c7681c5318c22) - [#123](https://github.com/npm/cli/pull/123) - Handle git branch references correctly. - ([@johanneswuerbach](https://github.com/johanneswuerbach)) -* [`f58b43ef2`](https://github.com/npm/cli/commit/f58b43ef2c5e3dea2094340a0cf264b2d11a5da4) - [npm.community#3983](https://npm.community/t/npm-audit-error-messaging-update-for-401s/3983) - Report any errors above 400 as potentially not supporting audit. - ([@zkat](https://github.com/zkat)) -* [`a5c9e6f35`](https://github.com/npm/cli/commit/a5c9e6f35a591a6e2d4b6ace5c01bc03f2b75fdc) - [#124](https://github.com/npm/cli/pull/124) - Set default homepage to an empty string. - ([@anchnk](https://github.com/anchnk)) -* [`5d076351d`](https://github.com/npm/cli/commit/5d076351d7ec1d3585942a9289548166a7fbbd4c) - [npm.community#4054](https://npm.community/t/4054) - Fix npm-prefix description. - ([@larsgw](https://github.com/larsgw)) - -### DOCS - -* [`31a7274b7`](https://github.com/npm/cli/commit/31a7274b70de18b24e7bee51daa22cc7cbb6141c) - [#71](https://github.com/npm/cli/pull/71) - Fix typo in npm-token documentation. - ([@GeorgeTaveras1231](https://github.com/GeorgeTaveras1231)) -* [`2401b7592`](https://github.com/npm/cli/commit/2401b7592c6ee114e6db7077ebf8c072b7bfe427) - Correct docs for fake-registry interface. - ([@iarna](https://github.com/iarna)) - -### DEPENDENCIES - -* [`9cefcdc1d`](https://github.com/npm/cli/commit/9cefcdc1d2289b56f9164d14d7e499e115cfeaee) - `npm-registry-fetch@3.8.0` - ([@zkat](https://github.com/zkat)) -* [`1c769c9b3`](https://github.com/npm/cli/commit/1c769c9b3e431d324c1a5b6dd10e1fddb5cb88c7) - `pacote@9.1.0` - ([@zkat](https://github.com/zkat)) -* [`f3bc5539b`](https://github.com/npm/cli/commit/f3bc5539b30446500abcc3873781b2c717f8e22c) - `figgy-pudding@3.5.1` - ([@zkat](https://github.com/zkat)) -* [`bf7199d3c`](https://github.com/npm/cli/commit/bf7199d3cbf50545da1ebd30d28f0a6ed5444a00) - `npm-profile@4.0.1` - ([@zkat](https://github.com/zkat)) -* [`118c50496`](https://github.com/npm/cli/commit/118c50496c01231cab3821ae623be6df89cb0a32) - `semver@5.5.1` - ([@isaacs](https://github.com/isaacs)) -* [`eab4df925`](https://github.com/npm/cli/commit/eab4df9250e9169c694b3f6c287d2932bf5e08fb) - `libcipm@3.0.2` - ([@zkat](https://github.com/zkat)) -* [`b86e51573`](https://github.com/npm/cli/commit/b86e515734faf433dc6c457c36c1de52795aa870) - `libnpm@1.4.0` - ([@zkat](https://github.com/zkat)) -* [`56fffbff2`](https://github.com/npm/cli/commit/56fffbff27fe2fae8bef27d946755789ef0d89bd) - `get-stream@4.1.0` - ([@zkat](https://github.com/zkat)) -* [`df972e948`](https://github.com/npm/cli/commit/df972e94868050b5aa42ac18b527fd929e1de9e4) - npm-profile@REMOVED - ([@zkat](https://github.com/zkat)) -* [`32c73bf0e`](https://github.com/npm/cli/commit/32c73bf0e3f0441d0c7c940292235d4b93aa87e2) - `libnpm@2.0.1` - ([@zkat](https://github.com/zkat)) -* [`569491b80`](https://github.com/npm/cli/commit/569491b8042f939dc13986b6adb2a0a260f95b63) - `licensee@5.0.0` - ([@zkat](https://github.com/zkat)) -* [`a3ba0ccf1`](https://github.com/npm/cli/commit/a3ba0ccf1fa86aec56b1ad49883abf28c1f56b3c) - move rimraf to prod deps - ([@zkat](https://github.com/zkat)) -* [`f63a0d6cf`](https://github.com/npm/cli/commit/f63a0d6cf0b7db3dcc80e72e1383c3df723c8119) - `spdx-license-ids@3.0.3`: - Ref: https://github.com/npm/cli/pull/121 - ([@zkat](https://github.com/zkat)) -* [`f350e714f`](https://github.com/npm/cli/commit/f350e714f66a77f71a7ebe17daeea2ea98179a1a) - `aproba@2.0.0` - ([@aeschright](https://github.com/aeschright)) -* [`a67e4d8b2`](https://github.com/npm/cli/commit/a67e4d8b214e58ede037c3854961acb33fd889da) - `byte-size@5.0.1` - ([@aeschright](https://github.com/aeschright)) -* [`8bea4efa3`](https://github.com/npm/cli/commit/8bea4efa34857c4e547904b3630dd442def241de) - `cacache@11.3.2` - ([@aeschright](https://github.com/aeschright)) -* [`9d4776836`](https://github.com/npm/cli/commit/9d4776836a4eaa4b19701b4e4f00cd64578bf078) - `chownr@1.1.1` - ([@aeschright](https://github.com/aeschright)) -* [`70da139e9`](https://github.com/npm/cli/commit/70da139e97ed1660c216e2d9b3f9cfb986bfd4a4) - `ci-info@2.0.0` - ([@aeschright](https://github.com/aeschright)) -* [`bcdeddcc3`](https://github.com/npm/cli/commit/bcdeddcc3d4dc242f42404223dafe4afdc753b32) - `cli-table3@0.5.1` - ([@aeschright](https://github.com/aeschright)) -* [`63aab82c7`](https://github.com/npm/cli/commit/63aab82c7bfca4f16987cf4156ddebf8d150747c) - `is-cidr@3.0.0` - ([@aeschright](https://github.com/aeschright)) -* [`d522bd90c`](https://github.com/npm/cli/commit/d522bd90c3b0cb08518f249ae5b90bd609fff165) - `JSONStream@1.3.5` - ([@aeschright](https://github.com/aeschright)) -* [`2a59bfc79`](https://github.com/npm/cli/commit/2a59bfc7989bd5575d8cbba912977c6d1ba92567) - `libnpmhook@5.0.2` - ([@aeschright](https://github.com/aeschright)) -* [`66d60e394`](https://github.com/npm/cli/commit/66d60e394e5a96330f90e230505758f19a3643ac) - `marked@0.6.0` - ([@aeschright](https://github.com/aeschright)) -* [`8213def9a`](https://github.com/npm/cli/commit/8213def9aa9b6e702887e4f2ed7654943e1e4154) - `npm-packlist@1.2.0` - ([@aeschright](https://github.com/aeschright)) -* [`e4ffc6a2b`](https://github.com/npm/cli/commit/e4ffc6a2bfb8d0b7047cb6692030484760fc8c91) - `unique-filename@1.1.1` - ([@aeschright](https://github.com/aeschright)) -* [`09a5c2fab`](https://github.com/npm/cli/commit/09a5c2fabe0d1c00ec8c99f328f6d28a3495eb0b) - `semver@5.6.0` - ([@aeschright](https://github.com/aeschright)) -* [`740e79e17`](https://github.com/npm/cli/commit/740e79e17a78247f73349525043c9388ce94459a) - `rimraf@2.6.3` - ([@aeschright](https://github.com/aeschright)) -* [`455476c8d`](https://github.com/npm/cli/commit/455476c8d148ca83a4e030e96e93dcf1c7f0ff5f) - `require-inject@1.4.4` - ([@aeschright](https://github.com/aeschright)) -* [`3f40251c5`](https://github.com/npm/cli/commit/3f40251c5868feaacbcdbcb1360877ce76998f5e) - `npm-pick-manifest@2.2.3` - ([@aeschright](https://github.com/aeschright)) -* [`4ffa8a8e9`](https://github.com/npm/cli/commit/4ffa8a8e9e80e5562898dd76fe5a49f5694f38c8) - `query-string@6.2.0` - ([@aeschright](https://github.com/aeschright)) -* [`a0a0ca9ec`](https://github.com/npm/cli/commit/a0a0ca9ec2a962183d420fa751f4139969760f18) - `pacote@9.3.0` - ([@aeschright](https://github.com/aeschright)) -* [`5777ea8ad`](https://github.com/npm/cli/commit/5777ea8ad2058be3166a6dad2d31d2d393c9f778) - `readable-stream@3.1.1` - ([@aeschright](https://github.com/aeschright)) -* [`887e94386`](https://github.com/npm/cli/commit/887e94386f42cb59a5628e7762b3662d084b23c8) - `lru-cache@4.1.5` - ([@aeschright](https://github.com/aeschright)) -* [`41f15524c`](https://github.com/npm/cli/commit/41f15524c58c59d206c4b1d25ae9e0f22745213b) - Updating semver docs. - ([@aeschright](https://github.com/aeschright)) -* [`fb3bbb72d`](https://github.com/npm/cli/commit/fb3bbb72d448ac37a465b31233b21381917422f3) - `npm-audit-report@1.3.2`: - ([@melkikh](https://github.com/melkikh)) - -### TESTING - -* [`f1edffba9`](https://github.com/npm/cli/commit/f1edffba90ebd96cf88675d2e18ebc48954ba50e) - Modernize maketest script. - ([@iarna](https://github.com/iarna)) -* [`ae263473d`](https://github.com/npm/cli/commit/ae263473d92a896b482830d4019a04b5dbd1e9d7) - maketest: Use promise based example common.npm call. - ([@iarna](https://github.com/iarna)) -* [`d9970da5e`](https://github.com/npm/cli/commit/d9970da5ee97a354eab01cbf16f9101693a15d2d) - maketest: Use newEnv for env production. - ([@iarna](https://github.com/iarna)) - -### MISCELLANEOUS - -* [`c665f35aa`](https://github.com/npm/cli/commit/c665f35aacdb8afdbe35f3dd7ccb62f55ff6b896) - [#119](https://github.com/npm/cli/pull/119) - Replace var with const/let in lib/repo.js. - ([@watilde](https://github.com/watilde)) -* [`46639ba9f`](https://github.com/npm/cli/commit/46639ba9f04ea729502f1af28b02eb67fb6dcb66) - Update package-lock.json for https tarball URLs - ([@aeschright](https://github.com/aeschright)) - -## v6.5.0 (2018-11-28): - -### NEW FEATURES - -* [`fc1a8d185`](https://github.com/npm/cli/commit/fc1a8d185fc678cdf3784d9df9eef9094e0b2dec) - Backronym `npm ci` to `npm clean-install`. - ([@zkat](https://github.com/zkat)) -* [`4be51a9cc`](https://github.com/npm/cli/commit/4be51a9cc65635bb26fa4ce62233f26e0104bc20) - [#81](https://github.com/npm/cli/pull/81) - Adds 'Homepage' to outdated --long output. - ([@jbottigliero](https://github.com/jbottigliero)) - -### BUGFIXES - -* [`89652cb9b`](https://github.com/npm/cli/commit/89652cb9b810f929f5586fc90cc6794d076603fb) - [npm.community#1661](https://npm.community/t/1661) - Fix sign-git-commit options. They were previously totally wrong. - ([@zkat](https://github.com/zkat)) -* [`414f2d1a1`](https://github.com/npm/cli/commit/414f2d1a1bdffc02ed31ebb48a43216f284c21d4) - [npm.community#1742](https://npm.community/t/npm-audit-making-non-rfc-compliant-requests-to-server-resulting-in-400-bad-request-pr-with-fix/1742) - Set lowercase headers for npm audit requests. - ([@maartenba](https://github.com/maartenba)) -* [`a34246baf`](https://github.com/npm/cli/commit/a34246bafe73218dc9e3090df9ee800451db2c7d) - [#75](https://github.com/npm/cli/pull/75) - Fix `npm edit` handling of scoped packages. - ([@larsgw](https://github.com/larsgw)) -* [`d3e8a7c72`](https://github.com/npm/cli/commit/d3e8a7c7240dd25379a5bcad324a367c58733c73) - [npm.community#2303](https://npm.community/t/npm-ci-logs-success-to-stderr/2303) - Make summary output for `npm ci` go to `stdout`, not `stderr`. - ([@alopezsanchez](https://github.com/alopezsanchez)) -* [`71d8fb4a9`](https://github.com/npm/cli/commit/71d8fb4a94d65e1855f6d0c5f2ad2b7c3202e3c4) - [npm.community#1377](https://npm.community/t/unhelpful-error-message-when-publishing-without-logging-in-error-eperm-operation-not-permitted-unlink/1377/3) - Close the file descriptor during publish if exiting upload via an error. This - will prevent strange error messages when the upload fails and make sure - cleanup happens correctly. - ([@macdja38](https://github.com/macdja38)) - -### DOCS UPDATES - -* [`b1a8729c8`](https://github.com/npm/cli/commit/b1a8729c80175243fbbeecd164e9ddd378a09a50) - [#60](https://github.com/npm/cli/pull/60) - Mention --otp flag when prompting for OTP. - ([@bakkot](https://github.com/bakkot)) -* [`bcae4ea81`](https://github.com/npm/cli/commit/bcae4ea8173e489a76cc226bbd30dd9eabe21ec6) - [#64](https://github.com/npm/cli/pull/64) - Clarify that git dependencies use the default branch, not just `master`. - ([@zckrs](https://github.com/zckrs)) -* [`15da82690`](https://github.com/npm/cli/commit/15da8269032bf509ade3252978e934f2a61d4499) - [#72](https://github.com/npm/cli/pull/72) - `bash_completion.d` dir is sometimes found in `/etc` not `/usr/local`. - ([@RobertKielty](https://github.com/RobertKielty)) -* [`8a6ecc793`](https://github.com/npm/cli/commit/8a6ecc7936dae2f51638397ff5a1d35cccda5495) - [#74](https://github.com/npm/cli/pull/74) - Update OTP documentation for `dist-tag add` to clarify `--otp` is needed right - now. - ([@scotttrinh](https://github.com/scotttrinh)) -* [`dcc03ec85`](https://github.com/npm/cli/commit/dcc03ec858bddd7aa2173b5a86b55c1c2385a2a3) - [#82](https://github.com/npm/cli/pull/82) - Note that `prepare` runs when installing git dependencies. - ([@seishun](https://github.com/seishun)) -* [`a91a470b7`](https://github.com/npm/cli/commit/a91a470b71e08ccf6a75d4fb8c9937789fa8d067) - [#83](https://github.com/npm/cli/pull/83) - Specify that --dry-run isn't available in older versions of npm publish. - ([@kjin](https://github.com/kjin)) -* [`1b2fabcce`](https://github.com/npm/cli/commit/1b2fabccede37242233755961434c52536224de5) - [#96](https://github.com/npm/cli/pull/96) - Fix inline code tag issue in docs. - ([@midare](https://github.com/midare)) -* [`6cc70cc19`](https://github.com/npm/cli/commit/6cc70cc1977e58a3e1ea48e660ffc6b46b390e59) - [#68](https://github.com/npm/cli/pull/68) - Add semver link and a note on empty string format to `deprecate` doc. - ([@neverett](https://github.com/neverett)) -* [`61dbbb7c3`](https://github.com/npm/cli/commit/61dbbb7c3474834031bce88c423850047e8131dc) - Fix semver docs after version update. - ([@zkat](https://github.com/zkat)) -* [`4acd45a3d`](https://github.com/npm/cli/commit/4acd45a3d0ce92f9999446226fe7dfb89a90ba2e) - [#78](https://github.com/npm/cli/pull/78) - Correct spelling across various docs. - ([@hugovk](https://github.com/hugovk)) - -### DEPENDENCIES - -* [`4f761283e`](https://github.com/npm/cli/commit/4f761283e8896d0ceb5934779005646463a030e8) - `figgy-pudding@3.5.1` - ([@zkat](https://github.com/zkat)) -* [`3706db0bc`](https://github.com/npm/cli/commit/3706db0bcbc306d167bb902362e7f6962f2fe1a1) - [npm.community#1764](https://npm.community/t/crash-invalid-config-key-requested-error/1764) - `ssri@6.0.1` - ([@zkat](https://github.com/zkat)) -* [`83c2b117d`](https://github.com/npm/cli/commit/83c2b117d0b760d0ea8d667e5e4bdfa6a7a7a8f6) - `bluebird@3.5.2` - ([@petkaantonov](https://github.com/petkaantonov)) -* [`2702f46bd`](https://github.com/npm/cli/commit/2702f46bd7284fb303ca2119d23c52536811d705) - `ci-info@1.5.1` - ([@watson](https://github.com/watson)) -* [`4db6c3898`](https://github.com/npm/cli/commit/4db6c3898b07100e3a324e4aae50c2fab4b93a04) - `config-chain@1.1.1`:2 - ([@dawsbot](https://github.com/dawbot)) -* [`70bee4f69`](https://github.com/npm/cli/commit/70bee4f69bb4ce4e18c48582fe2b48d8b4aba566) - `glob@7.1.3` - ([@isaacs](https://github.com/isaacs)) -* [`e469fd6be`](https://github.com/npm/cli/commit/e469fd6be95333dcaa7cf377ca3620994ca8d0de) - `opener@1.5.1`: - Fix browser opening under Windows Subsystem for Linux (WSL). - ([@thijsputman](https://github.com/thijsputman)) -* [`03840dced`](https://github.com/npm/cli/commit/03840dced865abdca6e6449ea030962e5b19db0c) - `semver@5.5.1` - ([@iarna](https://github.com/iarna)) -* [`161dc0b41`](https://github.com/npm/cli/commit/161dc0b4177e76306a0e3b8660b3b496cc3db83b) - `bluebird@3.5.3` - ([@petkaantonov](https://github.com/petkaantonov)) -* [`bb6f94395`](https://github.com/npm/cli/commit/bb6f94395491576ec42996ff6665df225f6b4377) - `graceful-fs@4.1.1`:5 - ([@isaacs](https://github.com/isaacs)) -* [`43b1f4c91`](https://github.com/npm/cli/commit/43b1f4c91fa1d7b3ebb6aa2d960085e5f3ac7607) - `tar@4.4.8` - ([@isaacs](https://github.com/isaacs)) -* [`ab62afcc4`](https://github.com/npm/cli/commit/ab62afcc472de82c479bf91f560a0bbd6a233c80) - `npm-packlist@1.1.1`:2 - ([@isaacs](https://github.com/isaacs)) -* [`027f06be3`](https://github.com/npm/cli/commit/027f06be35bb09f390e46fcd2b8182539939d1f7) - `ci-info@1.6.0` - ([@watson](https://github.com/watson)) - -### MISCELLANEOUS - -* [`27217dae8`](https://github.com/npm/cli/commit/27217dae8adbc577ee9cb323b7cfe9c6b2493aca) - [#70](https://github.com/npm/cli/pull/70) - Automatically audit dependency licenses for npm itself. - ([@kemitchell](https://github.com/kemitchell)) - -## v6.4.1 (2018-08-22): - -### BUGFIXES - -* [`4bd40f543`](https://github.com/npm/cli/commit/4bd40f543dc89f0721020e7d0bb3497300d74818) - [#42](https://github.com/npm/cli/pull/42) - Prevent blowing up on malformed responses from the `npm audit` endpoint, such - as with third-party registries. - ([@framp](https://github.com/framp)) -* [`0e576f0aa`](https://github.com/npm/cli/commit/0e576f0aa6ea02653d948c10f29102a2d4a31944) - [#46](https://github.com/npm/cli/pull/46) - Fix `NO_PROXY` support by renaming npm-side config to `--noproxy`. The - environment variable should still work. - ([@SneakyFish5](https://github.com/SneakyFish5)) -* [`d8e811d6a`](https://github.com/npm/cli/commit/d8e811d6adf3d87474982cb831c11316ac725605) - [#33](https://github.com/npm/cli/pull/33) - Disable `update-notifier` checks when a CI environment is detected. - ([@Sibiraj-S](https://github.com/Sibiraj-S)) -* [`1bc5b8cea`](https://github.com/npm/cli/commit/1bc5b8ceabc86bfe4777732f25ffef0f3de81bd1) - [#47](https://github.com/npm/cli/pull/47) - Fix issue where `postpack` scripts would break if `pack` was used with - `--dry-run`. - ([@larsgw](https://github.com/larsgw)) - -### DEPENDENCY BUMPS - -* [`4c57316d5`](https://github.com/npm/cli/commit/4c57316d5633e940105fa545b52d8fbfd2eb9f75) - `figgy-pudding@3.4.1` - ([@zkat](https://github.com/zkat)) -* [`85f4d7905`](https://github.com/npm/cli/commit/85f4d79059865d5267f3516b6cdbc746012202c6) - `cacache@11.2.0` - ([@zkat](https://github.com/zkat)) -* [`d20ac242a`](https://github.com/npm/cli/commit/d20ac242aeb44aa3581c65c052802a02d5eb22f3) - `npm-packlist@1.1.11`: - No real changes in npm-packlist, but npm-bundled included a - circular dependency fix, as well as adding a proper LICENSE file. - ([@isaacs](https://github.com/isaacs)) -* [`e8d5f4418`](https://github.com/npm/cli/commit/e8d5f441821553a31fc8cd751670663699d2c8ce) - [npm.community#632](https://npm.community/t/using-npm-ci-does-not-run-prepare-script-for-git-modules/632) - `libcipm@2.0.2`: - Fixes issue where `npm ci` wasn't running the `prepare` lifecycle script when - installing git dependencies - ([@edahlseng](https://github.com/edahlseng)) -* [`a5e6f78e9`](https://github.com/npm/cli/commit/a5e6f78e916873f7d18639ebdb8abd20479615a9) - `JSONStream@1.3.4`: - Fixes memory leak problem when streaming large files (like legacy npm search). - ([@daern91](https://github.com/daern91)) -* [`3b940331d`](https://github.com/npm/cli/commit/3b940331dcccfa67f92366adb7ffd9ecf7673a9a) - [npm.community#1042](https://npm.community/t/3-path-variables-are-assigned-to-child-process-launched-by-npm/1042) - `npm-lifecycle@2.1.0`: - Fixes issue for Windows user where multiple `Path`/`PATH` variables were being - added to the environment and breaking things in all sorts of fun and - interesting ways. - ([@JimiC](https://github.com/JimiC)) -* [`d612d2ce8`](https://github.com/npm/cli/commit/d612d2ce8fab72026f344f125539ecbf3746af9a) - `npm-registry-client@8.6.0` - ([@iarna](https://github.com/iarna)) -* [`1f6ba1cb1`](https://github.com/npm/cli/commit/1f6ba1cb174590c1f5d2b00e2ca238dfa39d507a) - `opener@1.5.0` - ([@domenic](https://github.com/domenic)) -* [`37b8f405f`](https://github.com/npm/cli/commit/37b8f405f35c861b7beeed56f71ad20b0bf87889) - `request@2.88.0` - ([@mikeal](https://github.com/mikeal)) -* [`bb91a2a14`](https://github.com/npm/cli/commit/bb91a2a14562e77769057f1b6d06384be6d6bf7f) - `tacks@1.2.7` - ([@iarna](https://github.com/iarna)) -* [`30bc9900a`](https://github.com/npm/cli/commit/30bc9900ae79c80bf0bdee0ae6372da6f668124c) - `ci-info@1.4.0`: - Adds support for two more CI services - ([@watson](https://github.com/watson)) -* [`1d2fa4ddd`](https://github.com/npm/cli/commit/1d2fa4dddcab8facfee92096cc24b299387f3182) - `marked@0.5.0` - ([@joshbruce](https://github.com/joshbruce)) - -### DOCUMENTATION - -* [`08ecde292`](https://github.com/npm/cli/commit/08ecde2928f8c89a2fdaa800ae845103750b9327) - [#54](https://github.com/npm/cli/pull/54) - Mention registry terms of use in manpage and registry docs and update language - in README for it. - ([@kemitchell](https://github.com/kemitchell)) -* [`de956405d`](https://github.com/npm/cli/commit/de956405d8b72354f98579d00c6dd30ac3b9bddf) - [#41](https://github.com/npm/cli/pull/41) - Add documentation for `--dry-run` in `install` and `pack` docs. - ([@reconbot](https://github.com/reconbot)) -* [`95031b90c`](https://github.com/npm/cli/commit/95031b90ce0b0c4dcd5e4eafc86e3e5bfd59fb3e) - [#48](https://github.com/npm/cli/pull/48) - Update republish time and lightly reorganize republish info. - ([@neverett](https://github.com/neverett)) -* [`767699b68`](https://github.com/npm/cli/commit/767699b6829b8b899d5479445e99b0ffc43ff92d) - [#53](https://github.com/npm/cli/pull/53) - Correct `npm@6.4.0` release date in changelog. - ([@charmander](https://github.com/charmander)) -* [`3fea3166e`](https://github.com/npm/cli/commit/3fea3166eb4f43f574fcfd9ee71a171feea2bc29) - [#55](https://github.com/npm/cli/pull/55) - Align command descriptions in help text. - ([@erik](https://github.com/erik)) - -## v6.4.0 (2018-08-09): - -### NEW FEATURES - -* [`6e9f04b0b`](https://github.com/npm/cli/commit/6e9f04b0baed007169d4e0c341f097cf133debf7) - [npm/cli#8](https://github.com/npm/cli/pull/8) - Search for authentication token defined by environment variables by preventing - the translation layer from env variable to npm option from breaking - `:_authToken`. - ([@mkhl](https://github.com/mkhl)) -* [`84bfd23e7`](https://github.com/npm/cli/commit/84bfd23e7d6434d30595594723a6e1976e84b022) - [npm/cli#35](https://github.com/npm/cli/pull/35) - Stop filtering out non-IPv4 addresses from `local-addrs`, making npm actually - use IPv6 addresses when it must. - ([@valentin2105](https://github.com/valentin2105)) -* [`792c8c709`](https://github.com/npm/cli/commit/792c8c709dc7a445687aa0c8cba5c50bc4ed83fd) - [npm/cli#31](https://github.com/npm/cli/pull/31) - configurable audit level for non-zero exit - `npm audit` currently exits with exit code 1 if any vulnerabilities are found of any level. - Add a flag of `--audit-level` to `npm audit` to allow it to pass if only vulnerabilities below a certain level are found. - Example: `npm audit --audit-level=high` will exit with 0 if only low or moderate level vulns are detected. - ([@lennym](https://github.com/lennym)) - -### BUGFIXES - -* [`d81146181`](https://github.com/npm/cli/commit/d8114618137bb5b9a52a86711bb8dc18bfc8e60c) - [npm/cli#32](https://github.com/npm/cli/pull/32) - Don't check for updates to npm when we are updating npm itself. - ([@olore](https://github.com/olore)) - -### DEPENDENCY UPDATES - -A very special dependency update event! Since the [release of -`node-gyp@3.8.0`](https://github.com/nodejs/node-gyp/pull/1521), an awkward -version conflict that was preventing `request` from begin flattened was -resolved. This means two things: - -1. We've cut down the npm tarball size by another 200kb, to 4.6MB -2. `npm audit` now shows no vulnerabilities for npm itself! - -Thanks, [@rvagg](https://github.com/rvagg)! - -* [`866d776c2`](https://github.com/npm/cli/commit/866d776c27f80a71309389aaab42825b2a0916f6) - `request@2.87.0` - ([@simov](https://github.com/simov)) -* [`f861c2b57`](https://github.com/npm/cli/commit/f861c2b579a9d4feae1653222afcefdd4f0e978f) - `node-gyp@3.8.0` - ([@rvagg](https://github.com/rvagg)) -* [`32e6947c6`](https://github.com/npm/cli/commit/32e6947c60db865257a0ebc2f7e754fedf7a6fc9) - [npm/cli#39](https://github.com/npm/cli/pull/39) - `colors@1.1.2`: - REVERT REVERT, newer versions of this library are broken and print ansi - codes even when disabled. - ([@iarna](https://github.com/iarna)) -* [`beb96b92c`](https://github.com/npm/cli/commit/beb96b92caf061611e3faafc7ca10e77084ec335) - `libcipm@2.0.1` - ([@zkat](https://github.com/zkat)) -* [`348fc91ad`](https://github.com/npm/cli/commit/348fc91ad223ff91cd7bcf233018ea1d979a2af1) - `validate-npm-package-license@3.0.4`: Fixes errors with empty or string-only - license fields. - ([@Gudahtt](https://github.com/Gudahtt)) -* [`e57d34575`](https://github.com/npm/cli/commit/e57d3457547ef464828fc6f82ae4750f3e511550) - `iferr@1.0.2` - ([@shesek](https://github.com/shesek)) -* [`46f1c6ad4`](https://github.com/npm/cli/commit/46f1c6ad4b2fd5b0d7ec879b76b76a70a3a2595c) - `tar@4.4.6` - ([@isaacs](https://github.com/isaacs)) -* [`50df1bf69`](https://github.com/npm/cli/commit/50df1bf691e205b9f13e0fff0d51a68772c40561) - `hosted-git-info@2.7.1` - ([@iarna](https://github.com/iarna)) - ([@Erveon](https://github.com/Erveon)) - ([@huochunpeng](https://github.com/huochunpeng)) - -### DOCUMENTATION - -* [`af98e76ed`](https://github.com/npm/cli/commit/af98e76ed96af780b544962aa575585b3fa17b9a) - [npm/cli#34](https://github.com/npm/cli/pull/34) - Remove `npm publish` from list of commands not affected by `--dry-run`. - ([@joebowbeer](https://github.com/joebowbeer)) -* [`e2b0f0921`](https://github.com/npm/cli/commit/e2b0f092193c08c00f12a6168ad2bd9d6e16f8ce) - [npm/cli#36](https://github.com/npm/cli/pull/36) - Tweak formatting in repository field examples. - ([@noahbenham](https://github.com/noahbenham)) -* [`e2346e770`](https://github.com/npm/cli/commit/e2346e7702acccefe6d711168c2b0e0e272e194a) - [npm/cli#14](https://github.com/npm/cli/pull/14) - Used `process.env` examples to make accessing certain `npm run-scripts` - environment variables more clear. - ([@mwarger](https://github.com/mwarger)) - -## v6.3.0 (2018-08-01): - -This is basically the same as the prerelease, but two dependencies have been -bumped due to bugs that had been around for a while. - -* [`0a22be42e`](https://github.com/npm/cli/commit/0a22be42eb0d40cd0bd87e68c9e28fc9d72c0e19) - `figgy-pudding@3.2.0` - ([@zkat](https://github.com/zkat)) -* [`0096f6997`](https://github.com/npm/cli/commit/0096f69978d2f40b170b28096f269b0b0008a692) - `cacache@11.1.0` - ([@zkat](https://github.com/zkat)) - -## v6.3.0-next.0 (2018-07-25): - -### NEW FEATURES - -* [`ad0dd226f`](https://github.com/npm/cli/commit/ad0dd226fb97a33dcf41787ae7ff282803fb66f2) - [npm/cli#26](https://github.com/npm/cli/pull/26) - `npm version` now supports a `--preid` option to specify the preid for - prereleases. For example, `npm version premajor --preid rc` will tag a version - like `2.0.0-rc.0`. - ([@dwilches](https://github.com/dwilches)) - -### MESSAGING IMPROVEMENTS - -* [`c1dad1e99`](https://github.com/npm/cli/commit/c1dad1e994827f2eab7a13c0f6454f4e4c22ebc2) - [npm/cli#6](https://github.com/npm/cli/pull/6) - Make `npm audit fix` message provide better instructions for vulnerabilities - that require manual review. - ([@bradsk88](https://github.com/bradsk88)) -* [`15c1130fe`](https://github.com/npm/cli/commit/15c1130fe81961706667d845aad7a5a1f70369f3) - Fix missing colon next to tarball url in new `npm view` output. - ([@zkat](https://github.com/zkat)) -* [`21cf0ab68`](https://github.com/npm/cli/commit/21cf0ab68cf528d5244ae664133ef400bdcfbdb6) - [npm/cli#24](https://github.com/npm/cli/pull/24) - Use the default OTP explanation everywhere except when the context is - "OTP-aware" (like when setting double-authentication). This improves the - overall CLI messaging when prompting for an OTP code. - ([@jdeniau](https://github.com/jdeniau)) - -### MISC - -* [`a9ac8712d`](https://github.com/npm/cli/commit/a9ac8712dfafcb31a4e3deca24ddb92ff75e942d) - [npm/cli#21](https://github.com/npm/cli/pull/21) - Use the extracted `stringify-package` package. - ([@dpogue](https://github.com/dpogue)) -* [`9db15408c`](https://github.com/npm/cli/commit/9db15408c60be788667cafc787116555507dc433) - [npm/cli#27](https://github.com/npm/cli/pull/27) - `wrappy` was previously added to dependencies in order to flatten it, but we - no longer do legacy-style for npm itself, so it has been removed from - `package.json`. - ([@rickschubert](https://github.com/rickschubert)) - -### DOCUMENTATION - -* [`3242baf08`](https://github.com/npm/cli/commit/3242baf0880d1cdc0e20b546d3c1da952e474444) - [npm/cli#13](https://github.com/npm/cli/pull/13) - Update more dead links in README.md. - ([@u32i64](https://github.com/u32i64)) -* [`06580877b`](https://github.com/npm/cli/commit/06580877b6023643ec780c19d84fbe120fe5425c) - [npm/cli#19](https://github.com/npm/cli/pull/19) - Update links in docs' `index.html` to refer to new bug/PR URLs. - ([@watilde](https://github.com/watilde)) -* [`ca03013c2`](https://github.com/npm/cli/commit/ca03013c23ff38e12902e9569a61265c2d613738) - [npm/cli#15](https://github.com/npm/cli/pull/15) - Fix some typos in file-specifiers docs. - ([@Mstrodl](https://github.com/Mstrodl)) -* [`4f39f79bc`](https://github.com/npm/cli/commit/4f39f79bcacef11bf2f98d09730bc94d0379789b) - [npm/cli#16](https://github.com/npm/cli/pull/16) - Fix some typos in file-specifiers and package-lock docs. - ([@watilde](https://github.com/watilde)) -* [`35e51f79d`](https://github.com/npm/cli/commit/35e51f79d1a285964aad44f550811aa9f9a72cd8) - [npm/cli#18](https://github.com/npm/cli/pull/18) - Update build status badge url in README. - ([@watilde](https://github.com/watilde)) -* [`a67db5607`](https://github.com/npm/cli/commit/a67db5607ba2052b4ea44f66657f98b758fb4786) - [npm/cli#17](https://github.com/npm/cli/pull/17/) - Replace TROUBLESHOOTING.md with [posts in - npm.community](https://npm.community/c/support/troubleshooting). - ([@watilde](https://github.com/watilde)) -* [`e115f9de6`](https://github.com/npm/cli/commit/e115f9de65bf53711266152fc715a5012f7d3462) - [npm/cli#7](https://github.com/npm/cli/pull/7) - Use https URLs in documentation when appropriate. Happy [Not Secure Day](https://arstechnica.com/gadgets/2018/07/todays-the-day-that-chrome-brands-plain-old-http-as-not-secure/)! - ([@XhmikosR](https://github.com/XhmikosR)) - -## v6.2.0 (2018-07-13): - -In case you missed it, [we -moved!](https://blog.npmjs.org/post/175587538995/announcing-npmcommunity). We -look forward to seeing future PRs landing in -[npm/cli](https://github.com/npm/cli) in the future, and we'll be chatting with -you all in [npm.community](https://npm.community). Go check it out! - -This final release of `npm@6.2.0` includes a couple of features that weren't -quite ready on time but that we'd still like to include. Enjoy! - -### FEATURES - -* [`244b18380`](https://github.com/npm/npm/commit/244b18380ee55950b13c293722771130dbad70de) - [#20554](https://github.com/npm/npm/pull/20554) - Add support for tab-separated output for `npm audit` data with the - `--parseable` flag. - ([@luislobo](https://github.com/luislobo)) -* [`7984206e2`](https://github.com/npm/npm/commit/7984206e2f41b8d8361229cde88d68f0c96ed0b8) - [#12697](https://github.com/npm/npm/pull/12697) - Add new `sign-git-commit` config to control whether the git commit itself gets - signed, or just the tag (which is the default). - ([@tribou](https://github.com/tribou)) - -### FIXES - -* [`4c32413a5`](https://github.com/npm/npm/commit/4c32413a5b42e18a34afb078cf00eed60f08e4ff) - [#19418](https://github.com/npm/npm/pull/19418) - Do not use `SET` to fetch the env in git-bash or Cygwin. - ([@gucong3000](https://github.com/gucong3000)) - -### DEPENDENCY BUMPS - -* [`d9b2712a6`](https://github.com/npm/npm/commit/d9b2712a670e5e78334e83f89a5ed49616f1f3d3) - `request@2.81.0`: Downgraded to allow better deduplication. This does - introduce a bunch of `hoek`-related audit reports, but they don't affect npm - itself so we consider it safe. We'll upgrade `request` again once `node-gyp` - unpins it. - ([@simov](https://github.com/simov)) -* [`2ac48f863`](https://github.com/npm/npm/commit/2ac48f863f90166b2bbf2021ed4cc04343d2503c) - `node-gyp@3.7.0` - ([@MylesBorins](https://github.com/MylesBorins)) -* [`8dc6d7640`](https://github.com/npm/npm/commit/8dc6d76408f83ba35bda77a2ac1bdbde01937349) - `cli-table3@0.5.0`: `cli-table2` is unmaintained and required `lodash`. With - this dependency bump, we've removed `lodash` from our tree, which cut back - tarball size by another 300kb. - ([@Turbo87](https://github.com/Turbo87)) -* [`90c759fee`](https://github.com/npm/npm/commit/90c759fee6055cf61cf6709432a5e6eae6278096) - `npm-audit-report@1.3.1` - ([@zkat](https://github.com/zkat)) -* [`4231a0a1e`](https://github.com/npm/npm/commit/4231a0a1eb2be13931c3b71eba38c0709644302c) - Add `cli-table3` to bundleDeps. - ([@iarna](https://github.com/iarna)) -* [`322d9c2f1`](https://github.com/npm/npm/commit/322d9c2f107fd82a4cbe2f9d7774cea5fbf41b8d) - Make `standard` happy. - ([@iarna](https://github.com/iarna)) - -### DOCS - -* [`5724983ea`](https://github.com/npm/npm/commit/5724983ea8f153fb122f9c0ccab6094a26dfc631) - [#21165](https://github.com/npm/npm/pull/21165) - Fix some markdown formatting in npm-disputes.md. - ([@hchiam](https://github.com/hchiam)) -* [`738178315`](https://github.com/npm/npm/commit/738178315fe48e463028657ea7ae541c3d63d171) - [#20920](https://github.com/npm/npm/pull/20920) - Explicitly state that republishing an unpublished package requires a 72h - waiting period. - ([@gmattie](https://github.com/gmattie)) -* [`f0a372b07`](https://github.com/npm/npm/commit/f0a372b074cc43ee0e1be28dbbcef0d556b3b36c) - Replace references to the old repo or issue tracker. We're at npm/cli now! - ([@zkat](https://github.com/zkat)) - -## v6.2.0-next.1 (2018-07-05): - -This is a quick patch to the release to fix an issue that was preventing users -from installing `npm@next`. - -* [`ecdcbd745`](https://github.com/npm/npm/commit/ecdcbd745ae1edd9bdd102dc3845a7bc76e1c5fb) - [#21129](https://github.com/npm/npm/pull/21129) - Remove postinstall script that depended on source files, thus preventing - `npm@next` from being installable from the registry. - ([@zkat](https://github.com/zkat)) - -## v6.2.0-next.0 (2018-06-28): - -### NEW FEATURES - -* [`ce0793358`](https://github.com/npm/npm/commit/ce07933588ec2da1cc1980f93bdaa485d6028ae2) - [#20750](https://github.com/npm/npm/pull/20750) - You can now disable the update notifier entirely by using - `--no-update-notifier` or setting it in your config with `npm config set - update-notifier false`. - ([@travi](https://github.com/travi)) -* [`d2ad776f6`](https://github.com/npm/npm/commit/d2ad776f6dcd92ae3937465736dcbca171131343) - [#20879](https://github.com/npm/npm/pull/20879) - When `npm run-script <script>` fails due to a typo or missing script, npm will - now do a "did you mean?..." for scripts that do exist. - ([@watilde](https://github.com/watilde)) - -### BUGFIXES - -* [`8f033d72d`](https://github.com/npm/npm/commit/8f033d72da3e84a9dbbabe3a768693817af99912) - [#20948](https://github.com/npm/npm/pull/20948) - Fix the regular expression matching in `xcode_emulation` in `node-gyp` to also - handle version numbers with multiple-digit major versions which would - otherwise break under use of XCode 10. - ([@Trott](https://github.com/Trott)) -* [`c8ba7573a`](https://github.com/npm/npm/commit/c8ba7573a4ea95789f674ce038762d6a77a8b047) - Stop trying to hoist/dedupe bundles dependencies. - ([@iarna](https://github.com/iarna)) -* [`cd698f068`](https://github.com/npm/npm/commit/cd698f06840b7c9407ac802efa96d16464722a7d) - [#20762](https://github.com/npm/npm/pull/20762) - Add synopsis to brief help for `npm audit` and suppress trailing newline. - ([@wyardley](https://github.com/wyardley)) -* [`6808ee3bd`](https://github.com/npm/npm/commit/6808ee3bd59560b1334a18aa6c6e0120094b03c0) - [#20881](https://github.com/npm/npm/pull/20881) - Exclude /.github directory from npm tarball. - ([@styfle](https://github.com/styfle)) -* [`177cbb476`](https://github.com/npm/npm/commit/177cbb4762c1402bfcbf0636c4bc4905fd684fc1) - [#21105](https://github.com/npm/npm/pull/21105) - Add suggestion to use a temporary cache instead of `npm cache clear --force`. - ([@karanjthakkar](https://github.com/karanjthakkar)) - -### DOCS - -* [`7ba3fca00`](https://github.com/npm/npm/commit/7ba3fca00554b884eb47f2ed661693faf2630b27) - [#20855](https://github.com/npm/npm/pull/20855) - Direct people to npm.community instead of the GitHub issue tracker on error. - ([@zkat](https://github.com/zkat)) -* [`88efbf6b0`](https://github.com/npm/npm/commit/88efbf6b0b403c5107556ff9e1bb7787a410d14d) - [#20859](https://github.com/npm/npm/pull/20859) - Fix typo in registry docs. - ([@strugee](https://github.com/strugee)) -* [`61bf827ae`](https://github.com/npm/npm/commit/61bf827aea6f98bba08a54e60137d4df637788f9) - [#20947](https://github.com/npm/npm/pull/20947) - Fixed a small grammar error in the README. - ([@bitsol](https://github.com/bitsol)) -* [`f5230c90a`](https://github.com/npm/npm/commit/f5230c90afef40f445bf148cbb16d6129a2dcc19) - [#21018](https://github.com/npm/npm/pull/21018) - Small typo fix in CONTRIBUTING.md. - ([@reggi](https://github.com/reggi)) -* [`833efe4b2`](https://github.com/npm/npm/commit/833efe4b2abcef58806f823d77ab8bb8f4f781c6) - [#20986](https://github.com/npm/npm/pull/20986) - Document current structure/expectations around package tarballs. - ([@Maximaximum](https://github.com/Maximaximum)) -* [`9fc0dc4f5`](https://github.com/npm/npm/commit/9fc0dc4f58d728bac6a8db7143d04863d7b653db) - [#21019](https://github.com/npm/npm/pull/21019) - Clarify behavior of `npm link ../path` shorthand. - ([@davidgilbertson](https://github.com/davidgilbertson)) -* [`3924c72d0`](https://github.com/npm/npm/commit/3924c72d06b9216ac2b6a9d951fd565a1d5eda89) - [#21064](https://github.com/npm/npm/pull/21064) - Add missing "if" - ([@roblourens](https://github.com/roblourens)) - -### DEPENDENCY SHUFFLE! - -We did some reshuffling and moving around of npm's own dependencies. This -significantly reduces the total bundle size of the npm pack, from 8MB to 4.8MB -for the distributed tarball! We also moved around what we actually commit to the -repo as far as devDeps go. - -* [`0483f5c5d`](https://github.com/npm/npm/commit/0483f5c5deaf18c968a128657923103e49f4e67a) - Flatten and dedupe our dependencies! - ([@iarna](https://github.com/iarna)) -* [`ef9fa1ceb`](https://github.com/npm/npm/commit/ef9fa1ceb5f9d175fd453138b1a26d45a5071dfd) - Remove unused direct dependency `ansi-regex`. - ([@iarna](https://github.com/iarna)) -* [`0d14b0bc5`](https://github.com/npm/npm/commit/0d14b0bc59812f4e33798194e11ffacbea3c0493) - Reshuffle ansi-regex for better deduping. - ([@iarna](https://github.com/iarna)) -* [`68a101859`](https://github.com/npm/npm/commit/68a101859b2b6f78b2e7c3a936492acdb15f7c4a) - Reshuffle strip-ansi for better deduping. - ([@iarna](https://github.com/iarna)) -* [`0d5251f97`](https://github.com/npm/npm/commit/0d5251f97dc8b8b143064869e530d465c757ffbb) - Reshuffle is-fullwidth-code-point for better deduping. - ([@iarna](https://github.com/iarna)) -* [`2d0886632`](https://github.com/npm/npm/commit/2d08866327013522fc5fbe61ed872b8f30e92775) - Add fake-registry, npm-registry-mock replacement. - ([@iarna](https://github.com/iarna)) - -### DEPENDENCIES - -* [`8cff8eea7`](https://github.com/npm/npm/commit/8cff8eea75dc34c9c1897a7a6f65d7232bb0c64c) - `tar@4.4.3` - ([@zkat](https://github.com/zkat)) -* [`bfc4f873b`](https://github.com/npm/npm/commit/bfc4f873bd056b7e3aee389eda4ecd8a2e175923) - `pacote@8.1.6` - ([@zkat](https://github.com/zkat)) -* [`532096163`](https://github.com/npm/npm/commit/53209616329119be8fcc29db86a43cc8cf73454d) - `libcipm@2.0.0` - ([@zkat](https://github.com/zkat)) -* [`4a512771b`](https://github.com/npm/npm/commit/4a512771b67aa06505a0df002a9027c16a238c71) - `request@2.87.0` - ([@iarna](https://github.com/iarna)) -* [`b7cc48dee`](https://github.com/npm/npm/commit/b7cc48deee45da1feab49aa1dd4d92e33c9bcac8) - `which@1.3.1` - ([@iarna](https://github.com/iarna)) -* [`bae657c28`](https://github.com/npm/npm/commit/bae657c280f6ea8e677509a9576e1b47c65c5441) - `tar@4.4.4` - ([@iarna](https://github.com/iarna)) -* [`3d46e5c4e`](https://github.com/npm/npm/commit/3d46e5c4e3c5fecd9bf05a7425a16f2e8ad5c833) - `JSONStream@1.3.3` - ([@iarna](https://github.com/iarna)) -* [`d0a905daf`](https://github.com/npm/npm/commit/d0a905dafc7e3fcd304e8053acbe3da40ba22554) - `is-cidr@2.0.6` - ([@iarna](https://github.com/iarna)) -* [`4fc1f815f`](https://github.com/npm/npm/commit/4fc1f815fec5a7f6f057cf305e01d4126331d1f2) - `marked@0.4.0` - ([@iarna](https://github.com/iarna)) -* [`f72202944`](https://github.com/npm/npm/commit/f722029441a088d03df94bdfdeeec51cfd318659) - `tap@12.0.1` - ([@iarna](https://github.com/iarna)) -* [`bdce96eb3`](https://github.com/npm/npm/commit/bdce96eb3c30fcff873aa3f1190e8ae4928d690b) - `npm-profile@3.0.2` - ([@iarna](https://github.com/iarna)) -* [`fe4240e85`](https://github.com/npm/npm/commit/fe4240e852144770bf76d7b1952056ca5baa63cf) - `uuid@3.3.2` - ([@zkat](https://github.com/zkat)) - -## v6.1.0 (2018-05-17): - -### FIX WRITE AFTER END ERROR - -First introduced in 5.8.0, this finally puts to bed errors where you would -occasionally see `Error: write after end at MiniPass.write`. - -* [`171f3182f`](https://github.com/npm/npm/commit/171f3182f32686f2f94ea7d4b08035427e0b826e) - [node-tar#180](https://github.com/npm/node-tar/issues/180) - [npm.community#35](https://npm.community/t/write-after-end-when-installing-packages-with-5-8-and-later/35) - `pacote@8.1.5`: Fix write-after-end errors. - ([@zkat](https://github.com/zkat)) - -### DETECT CHANGES IN GIT SPECIFIERS - -* [`0e1726c03`](https://github.com/npm/npm/commit/0e1726c0350a02d5a60f5fddb1e69c247538625e) - We can now determine if the commitid of a git dependency in the lockfile is derived - from the specifier in the package.json and if it isn't we now trigger an update for it. - ([@iarna](https://github.com/iarna)) - -### OTHER BUGS - -* [`442d2484f`](https://github.com/npm/npm/commit/442d2484f686e3a371b07f8473a17708f84d9603) - [`2f0c88351`](https://github.com/npm/npm/commit/2f0c883519f17c94411dd1d9877c5666f260c12f) - [`631d30a34`](https://github.com/npm/npm/commit/631d30a340f5805aed6e83f47a577ca4125599b2) - When requesting the update of a direct dependency that was also a - transitive dependency to a version incompatible with the transitive - requirement and you had a lock-file but did not have a `node_modules` - folder then npm would fail to provide a new copy of the transitive - dependency, resulting in an invalid lock-file that could not self heal. - ([@iarna](https://github.com/iarna)) -* [`be5dd0f49`](https://github.com/npm/npm/commit/be5dd0f496ec1485b1ea3094c479dfc17bd50d82) - [#20715](https://github.com/npm/npm/pull/20715) - Cleanup output of `npm ci` summary report. - ([@legodude17](https://github.com/legodude17)) -* [`98ffe4adb`](https://github.com/npm/npm/commit/98ffe4adb55a6f4459271856de2e27e95ee63375) - Node.js now has a test that scans for things that look like conflict - markers in source code. This was triggering false positives on a fixture in a test - of npm's ability to heal lockfiles with conflicts in them. - ([@iarna](https://github.com/iarna)) - -### DEPENDENCY UPDATES - -* [`3f2e306b8`](https://github.com/npm/npm/commit/3f2e306b884a027df03f64524beb8658ce1772cb) - Using `npm audit fix`, replace some transitive dependencies with security - issues with versions that don't have any. - ([@iarna](https://github.com/iarna)) -* [`1d07134e0`](https://github.com/npm/npm/commit/1d07134e0b157f7484a20ce6987ff57951842954) - `tar@4.4.1`: - Dropping to 4.4.1 from 4.4.2 due to https://github.com/npm/node-tar/issues/183 - ([@zkat](https://github.com/zkat)) - - -## v6.1.0-next.0 (2018-05-17): - -Look at that! A feature bump! `npm@6` was super-exciting not just because it -used a bigger number than ever before, but also because it included a super -shiny new command: `npm audit`. Well, we've kept working on it since then and -have some really nice improvements for it. You can expect more of them, and the -occasional fix, in the next few releases as more users start playing with it and -we get more feedback about what y'all would like to see from something like -this. - -I, for one, have started running it (and the new subcommand...) in all my -projects, and it's one of those things that I don't know how I ever functioned --without- it! This will make a world of difference to so many people as far as -making the npm ecosystem a higher-quality, safer commons for all of us. - -This is also a good time to remind y'all that we have a new [RFCs -repository](https://github.com/npm/rfcs), along with a new process for them. -This repo is open to anyone's RFCs, and has already received some great ideas -about where we can take the CLI (and, to a certain extent, the registry). It's a -great place to get feedback, and completely replaces feature requests in the -main repo, so we won't be accepting feature requests there at all anymore. Check -it out if you have something you'd like to suggest, or if you want to keep track -of what the future might look like! - -### NEW FEATURE: `npm audit fix` - -This is the biggie with this release! `npm audit fix` does exactly what it says -on the tin. It takes all the actionable reports from your `npm audit` and runs -the installs automatically for you, so you don't have to try to do all that -mechanical work yourself! - -Note that by default, `npm audit fix` will stick to semver-compatible changes, -so you should be able to safely run it on most projects and carry on with your -day without having to track down what breaking changes were included. If you -want your (toplevel) dependencies to accept semver-major bumps as well, you can -use `npm audit fix --force` and it'll toss those in, as well. Since it's running -the npm installer under the hood, it also supports `--production` and -`--only=dev` flags, as well as things like `--dry-run`, `--json`, and -`--package-lock-only`, if you want more control over what it does. - -Give it a whirl and tell us what you think! See `npm help audit` for full docs! - -* [`3800a660d`](https://github.com/npm/npm/commit/3800a660d99ca45c0175061dbe087520db2f54b7) - Add `npm audit fix` subcommand to automatically fix detected vulnerabilities. - ([@zkat](https://github.com/zkat)) - -### OTHER NEW `audit` FEATURES - -* [`1854b1c7f`](https://github.com/npm/npm/commit/1854b1c7f09afceb49627e539a086d8a3565601c) - [#20568](https://github.com/npm/npm/pull/20568) - Add support for `npm audit --json` to print the report in JSON format. - ([@finnp](https://github.com/finnp)) -* [`85b86169d`](https://github.com/npm/npm/commit/85b86169d9d0423f50893d2ed0c7274183255abe) - [#20570](https://github.com/npm/npm/pull/20570) - Include number of audited packages in `npm install` summary output. - ([@zkat](https://github.com/zkat)) -* [`957cbe275`](https://github.com/npm/npm/commit/957cbe27542d30c33e58e7e6f2f04eeb64baf5cd) - `npm-audit-report@1.2.1`: - Overhaul audit install and detail output format. The new format is terser and - fits more closely into the visual style of the CLI, while still providing you - with the important bits of information you need. They also include a bit more - detail on the footer about what actions you can take! - ([@zkat](https://github.com/zkat)) - -### NEW FEATURE: GIT DEPS AND `npm init <pkg>`! - -Another exciting change that came with `npm@6` was the new `npm init` command -that allows for community-authored generators. That means you can, for example, -do `npm init react-app` and it'll one-off download, install, and run -[`create-react-app`](https://npm.im/create-react-app) for you, without requiring -or keeping around any global installs. That is, it basically just calls out to -[`npx`](https://npm.im/npx). - -The first version of this command only really supported registry dependencies, -but now, [@jdalton](https://github.com/jdalton) went ahead and extended this -feature so you can use hosted git dependencies, and their shorthands. - -So go ahead and do `npm init facebook/create-react-app` and it'll grab the -package from the github repo now! Or you can use it with a private github -repository to maintain your organizational scaffolding tools or whatnot. ✨ - -* [`483e01180`](https://github.com/npm/npm/commit/483e011803af82e63085ef41b7acce5b22aa791c) - [#20403](https://github.com/npm/npm/pull/20403) - Add support for hosted git packages to `npm init <name>`. - ([@jdalton](https://github.com/jdalton)) - -### BUGFIXES - -* [`a41c0393c`](https://github.com/npm/npm/commit/a41c0393cba710761a15612c6c85c9ef2396e65f) - [#20538](https://github.com/npm/npm/pull/20538) - Make the new `npm view` work when the license field is an object instead of a - string. - ([@zkat](https://github.com/zkat)) -* [`eb7522073`](https://github.com/npm/npm/commit/eb75220739302126c94583cc65a5ff12b441e3c6) - [#20582](https://github.com/npm/npm/pull/20582) - Add support for environments (like Docker) where the expected binary for - opening external URLs is not available. - ([@bcoe](https://github.com/bcoe)) -* [`212266529`](https://github.com/npm/npm/commit/212266529ae72056bf0876e2cff4b8ba01d09d0f) - [#20536](https://github.com/npm/npm/pull/20536) - Fix a spurious colon in the new update notifier message and add support for - the npm canary. - ([@zkat](https://github.com/zkat)) -* [`5ee1384d0`](https://github.com/npm/npm/commit/5ee1384d02c3f11949d7a26ec6322488476babe6) - [#20597](https://github.com/npm/npm/pull/20597) - Infer a version range when a `package.json` has a dist-tag instead of a - version range in one of its dependency specs. Previously, this would cause - dependencies to be flagged as invalid. - ([@zkat](https://github.com/zkat)) -* [`4fa68ae41`](https://github.com/npm/npm/commit/4fa68ae41324293e59584ca6cf0ac24b3e0825bb) - [#20585](https://github.com/npm/npm/pull/20585) - Make sure scoped bundled deps are shown in the new publish preview, too. - ([@zkat](https://github.com/zkat)) -* [`1f3ee6b7e`](https://github.com/npm/npm/commit/1f3ee6b7e1b36b52bdedeb9241296d4e66561d48) - `cacache@11.0.2`: - Stop dropping `size` from metadata on `npm cache verify`. - ([@jfmartinez](https://github.com/jfmartinez)) -* [`91ef93691`](https://github.com/npm/npm/commit/91ef93691a9d6ce7c016fefdf7da97854ca2b2ca) - [#20513](https://github.com/npm/npm/pull/20513) - Fix nested command aliases. - ([@mmermerkaya](https://github.com/mmermerkaya)) -* [`18b2b3cf7`](https://github.com/npm/npm/commit/18b2b3cf71a438648ced1bd13faecfb50c71e979) - `npm-lifecycle@2.0.3`: - Make sure different versions of the `Path` env var on Windows all get - `node_modules/.bin` prepended when running lifecycle scripts. - ([@laggingreflex](https://github.com/laggingreflex)) - -### DOCUMENTATION - -* [`a91d87072`](https://github.com/npm/npm/commit/a91d87072f292564e58dcab508b5a8c6702b9aae) - [#20550](https://github.com/npm/npm/pull/20550) - Update required node versions in README. - ([@legodude17](https://github.com/legodude17)) -* [`bf3cfa7b8`](https://github.com/npm/npm/commit/bf3cfa7b8b351714c4ec621e1a5867c8450c6fff) - Pull in changelogs from the last `npm@5` release. - ([@iarna](https://github.com/iarna)) -* [`b2f14b14c`](https://github.com/npm/npm/commit/b2f14b14ca25203c2317ac2c47366acb50d46e69) - [#20629](https://github.com/npm/npm/pull/20629) - Make tone in `publishConfig` docs more neutral. - ([@jeremyckahn](https://github.com/jeremyckahn)) - -### DEPENDENCY BUMPS - -* [`5fca4eae8`](https://github.com/npm/npm/commit/5fca4eae8a62a7049b1ae06aa0bbffdc6e0ad6cc) - `byte-size@4.0.3` - ([@75lb](https://github.com/75lb)) -* [`d9ef3fba7`](https://github.com/npm/npm/commit/d9ef3fba79f87c470889a6921a91f7cdcafa32b9) - `lru-cache@4.1.3` - ([@isaacs](https://github.com/isaacs)) -* [`f1baf011a`](https://github.com/npm/npm/commit/f1baf011a0d164f8dc8aa6cd31e89225e3872e3b) - `request@2.86.0` - ([@simonv](https://github.com/simonv)) -* [`005fa5420`](https://github.com/npm/npm/commit/005fa542072f09a83f77a9d62c5e53b8f6309371) - `require-inject@1.4.3` - ([@iarna](https://github.com/iarna)) -* [`1becdf09a`](https://github.com/npm/npm/commit/1becdf09a2f19716726c88e9a2342e1e056cfc71) - `tap@11.1.5` - ([@isaacs](https://github.com/isaacs)) - -## v6.0.1 (2018-05-09): - -### AUDIT SHOULDN'T WAIT FOREVER - -This will likely be reduced further with the goal that the audit process -shouldn't noticibly slow down your builds regardless of your network -situation. - -* [`3dcc240db`](https://github.com/npm/npm/commit/3dcc240dba5258532990534f1bd8a25d1698b0bf) - Timeout audit requests eventually. - ([@iarna](https://github.com/iarna)) - -### Looking forward - -We're still a way from having node@11, so now's a good time to ensure we -don't warn about being used with it. - -* [`ed1aebf55`](https://github.com/npm/npm/commit/ed1aebf55) - Allow node@11, when it comes. - ([@iarna](https://github.com/iarna)) - -## v6.0.1-next.0 (2018-05-03): - -### CTRL-C OUT DURING PACKAGE EXTRACTION AS MUCH AS YOU WANT! - -* [`b267bbbb9`](https://github.com/npm/npm/commit/b267bbbb9ddd551e3dbd162cc2597be041b9382c) - [npm/lockfile#29](https://github.com/npm/lockfile/pull/29) - `lockfile@1.0.4`: - Switches to `signal-exit` to detect abnormal exits and remove locks. - ([@Redsandro](https://github.com/Redsandro)) - -### SHRONKWRAPS AND LACKFILES - -If a published modules had legacy `npm-shrinkwrap.json` we were saving -ordinary registry dependencies (`name@version`) to your `package-lock.json` -as `https://` URLs instead of versions. - -* [`89102c0d9`](https://github.com/npm/npm/commit/89102c0d995c3d707ff2b56995a97a1610f8b532) - When saving the lock-file compute how the dependency is being required instead of using - `_resolved` in the `package.json`. This fixes the bug that was converting - registry dependencies into `https://` dependencies. - ([@iarna](https://github.com/iarna)) -* [`676f1239a`](https://github.com/npm/npm/commit/676f1239ab337ff967741895dbe3a6b6349467b6) - When encountering a `https://` URL in our lockfiles that point at our default registry, extract - the version and use them as registry dependencies. This lets us heal - `package-lock.json` files produced by 6.0.0 - ([@iarna](https://github.com/iarna)) - -### AUDIT AUDIT EVERYWHERE - -You can't use it _quite_ yet, but we do have a few last moment patches to `npm audit` to make -it even better when it is turned on! - -* [`b2e4f48f5`](https://github.com/npm/npm/commit/b2e4f48f5c07b8ebc94a46ce01a810dd5d6cd20c) - Make sure we hide stream errors on background audit submissions. Previously some classes - of error could end up being displayed (harmlessly) during installs. - ([@iarna](https://github.com/iarna)) -* [`1fe0c7fea`](https://github.com/npm/npm/commit/1fe0c7fea226e592c96b8ab22fd9435e200420e9) - Include session and scope in requests (as we do in other requests to the registry). - ([@iarna](https://github.com/iarna)) -* [`d04656461`](https://github.com/npm/npm/commit/d046564614639c37e7984fff127c79a8ddcc0c92) - Exit with non-zero status when vulnerabilities are found. So you can have `npm audit` as a test or prepublish step! - ([@iarna](https://github.com/iarna)) -* [`fcdbcbacc`](https://github.com/npm/npm/commit/fcdbcbacc16d96a8696dde4b6d7c1cba77828337) - Verify lockfile integrity before running. You'd get an error either way, but this way it's - faster and can give you more concrete instructions on how to fix it. - ([@iarna](https://github.com/iarna)) -* [`2ac8edd42`](https://github.com/npm/npm/commit/2ac8edd4248f2393b35896f0300b530e7666bb0e) - Refuse to run in global mode. Audits require a lockfile and globals don't have one. Yet. - ([@iarna](https://github.com/iarna)) - -### DOCUMENTATION IMPROVEMENTS - -* [`b7fca1084`](https://github.com/npm/npm/commit/b7fca1084b0be6f8b87ec0807c6daf91dbc3060a) - [#20407](https://github.com/npm/npm/pull/20407) - Update the lock-file spec doc to mention that we now generate the from field for `git`-type dependencies. - ([@watilde](https://github.com/watilde)) -* [`7a6555e61`](https://github.com/npm/npm/commit/7a6555e618e4b8459609b7847a9e17de2d4fa36e) - [#20408](https://github.com/npm/npm/pull/20408) - Describe what the colors in outdated mean. - ([@teameh](https://github.com/teameh)) - -### DEPENDENCY UPDATES - -* [`5e56b3209`](https://github.com/npm/npm/commit/5e56b3209c4719e3c4d7f0d9346dfca3881a5d34) - `npm-audit-report@1.0.8` - ([@evilpacket](https://github.com/evilpacket)) -* [`58a0b31b4`](https://github.com/npm/npm/commit/58a0b31b43245692b4de0f1e798fcaf71f8b7c31) - `lock-verify@2.0.2` - ([@iarna](https://github.com/iarna)) -* [`e7a8c364f`](https://github.com/npm/npm/commit/e7a8c364f3146ffb94357d8dd7f643e5563e2f2b) - [zkat/pacote#148](https://github.com/zkat/pacote/pull/148) - `pacote@8.1.1` - ([@redonkulus](https://github.com/redonkulus)) -* [`46c0090a5`](https://github.com/npm/npm/commit/46c0090a517526dfec9b1b6483ff640227f0cd10) - `tar@4.4.2` - ([@isaacs](https://github.com/isaacs)) -* [`8a16db3e3`](https://github.com/npm/npm/commit/8a16db3e39715301fd085a8f4c80ae836f0ec714) - `update-notifier@2.5.0` - ([@alexccl](https://github.com/alexccl)) -* [`696375903`](https://github.com/npm/npm/commit/6963759032fe955c1404d362e14f458d633c9444) - `safe-buffer@5.1.2` - ([@feross](https://github.com/feross)) -* [`c949eb26a`](https://github.com/npm/npm/commit/c949eb26ab6c0f307e75a546f342bb2ec0403dcf) - `query-string@6.1.0` - ([@sindresorhus](https://github.com/sindresorhus)) - -## v6.0.0 (2018-04-20): - -Hey y'all! Here's another `npm@6` release -- with `node@10` around the corner, -this might well be the last prerelease before we tag `6.0.0`! There's two major -features included with this release, along with a few miscellaneous fixes and -changes. - -### EXTENDED `npm init` SCAFFOLDING - -Thanks to the wonderful efforts of [@jdalton](https://github.com/jdalton) of -lodash fame, `npm init` can now be used to invoke custom scaffolding tools! - -You can now do things like `npm init react-app` or `npm init esm` to scaffold an -npm package by running `create-react-app` and `create-esm`, respectively. This -also adds an `npm create` alias, to correspond to Yarn's `yarn create` feature, -which inspired this. - -* [`008a83642`](https://github.com/npm/npm/commit/008a83642e04360e461f56da74b5557d5248a726) [`ed81d1426`](https://github.com/npm/npm/commit/ed81d1426776bcac47492cabef43f65e1d4ab536) [`833046e45`](https://github.com/npm/npm/commit/833046e45fe25f75daffd55caf25599a9f98c148) - [#20303](https://github.com/npm/npm/pull/20303) - Add an `npm init` feature that calls out to `npx` when invoked with positional - arguments. ([@jdalton](https://github.com/jdalton)) - -### DEPENDENCY AUDITING - -This version of npm adds a new command, `npm audit`, which will run a security -audit of your project's dependency tree and notify you about any actions you may -need to take. - -The registry-side services required for this command to work will be available -on the main npm registry in the coming weeks. Until then, you won't get much out -of trying to use this on the CLI. - -As part of this change, the npm CLI now sends scrubbed and cryptographically -anonymized metadata about your dependency tree to your configured registry, to -allow notifying you about the existence of critical security flaws. For details -about how the CLI protects your privacy when it shares this metadata, see `npm -help audit`, or [read the docs for `npm audit` -online](https://github.com/npm/npm/blob/release-next/doc/cli/npm-audit.md). You -can disable this altogether by doing `npm config set audit false`, but will no -longer benefit from the service. - -* [`f4bc648ea`](https://github.com/npm/npm/commit/f4bc648ea7b19d63cc9878c9da2cb1312f6ce152) - [#20389](https://github.com/npm/npm/pull/20389) - `npm-registry-fetch@1.1.0` - ([@iarna](https://github.com/iarna)) -* [`594d16987`](https://github.com/npm/npm/commit/594d16987465014d573c51a49bba6886cc19f8e8) - [#20389](https://github.com/npm/npm/pull/20389) - `npm-audit-report@1.0.5` - ([@iarna](https://github.com/iarna)) -* [`8c77dde74`](https://github.com/npm/npm/commit/8c77dde74a9d8f9007667cd1732c3329e0d52617) [`1d8ac2492`](https://github.com/npm/npm/commit/1d8ac2492196c4752b2e41b23d5ddc92780aaa24) [`552ff6d64`](https://github.com/npm/npm/commit/552ff6d64a5e3bcecb33b2a861c49a3396adad6d) [`09c734803`](https://github.com/npm/npm/commit/09c73480329e75e44fb8e55ca522f798be68d448) - [#20389](https://github.com/npm/npm/pull/20389) - Add new `npm audit` command. - ([@iarna](https://github.com/iarna)) -* [`be393a290`](https://github.com/npm/npm/commit/be393a290a5207dc75d3d70a32973afb3322306c) - [#20389](https://github.com/npm/npm/pull/20389) - Temporarily suppress git metadata till there's an opt-in. - ([@iarna](https://github.com/iarna)) -* [`8e713344f`](https://github.com/npm/npm/commit/8e713344f6e0828ddfb7733df20d75e95a5382d8) - [#20389](https://github.com/npm/npm/pull/20389) - Document the new command. - ([@iarna](https://github.com/iarna)) -* - [#20389](https://github.com/npm/npm/pull/20389) - Default audit to off when running the npm test suite itself. - ([@iarna](https://github.com/iarna)) - -### MORE `package-lock.json` FORMAT CHANGES?! - -* [`820f74ae2`](https://github.com/npm/npm/commit/820f74ae22b7feb875232d46901cc34e9ba995d6) - [#20384](https://github.com/npm/npm/pull/20384) - Add `from` field back into package-lock for git dependencies. This will give - npm the information it needs to figure out whether git deps are valid, - specially when running with legacy install metadata or in - `--package-lock-only` mode when there's no `node_modules`. This should help - remove a significant amount of git-related churn on the lock-file. - ([@zkat](https://github.com/zkat)) - -### BUGFIXES - -* [`9d5d0a18a`](https://github.com/npm/npm/commit/9d5d0a18a5458655275056156b5aa001140ae4d7) - [#20358](https://github.com/npm/npm/pull/20358) - `npm install-test` (aka `npm it`) will no longer generate `package-lock.json` - when running with `--no-package-lock` or `package-lock=false`. - ([@raymondfeng](https://github.com/raymondfeng)) -* [`e4ed976e2`](https://github.com/npm/npm/commit/e4ed976e20b7d1114c920a9dc9faf351f89a31c9) - [`2facb35fb`](https://github.com/npm/npm/commit/2facb35fbfbbc415e693d350b67413a66ff96204) - [`9c1eb945b`](https://github.com/npm/npm/commit/9c1eb945be566e24cbbbf186b0437bdec4be53fc) - [#20390](https://github.com/npm/npm/pull/20390) - Fix a scenario where a git dependency had a comittish associated with it - that was not a complete commitid. `npm` would never consider that entry - in the `package.json` as matching the entry in the `package-lock.json` and - this resulted in inappropriate pruning or reinstallation of git - dependencies. This has been addressed in two ways, first, the addition of the - `from` field as described in [#20384](https://github.com/npm/npm/pull/20384) means - we can exactly match the `package.json`. Second, when that's missing (when working with - older `package-lock.json` files), we assume that the match is ok. (If - it's not, we'll fix it up when a real installation is done.) - ([@iarna](https://github.com/iarna)) - - -### DEPENDENCIES - -* [`1c1f89b73`](https://github.com/npm/npm/commit/1c1f89b7319b2eef6adee2530c4619ac1c0d83cf) - `libnpx@10.2.0` - ([@zkat](https://github.com/zkat)) -* [`242d8a647`](https://github.com/npm/npm/commit/242d8a6478b725778c00be8ba3dc85f367006a61) - `pacote@8.1.0` - ([@zkat](https://github.com/zkat)) - -### DOCS - -* [`a1c77d614`](https://github.com/npm/npm/commit/a1c77d614adb4fe6769631b646b817fd490d239c) - [#20331](https://github.com/npm/npm/pull/20331) - Fix broken link to 'private-modules' page. The redirect went away when the new - npm website went up, but the new URL is better anyway. - ([@vipranarayan14](https://github.com/vipranarayan14)) -* [`ad7a5962d`](https://github.com/npm/npm/commit/ad7a5962d758efcbcfbd9fda9a3d8b38ddbf89a1) - [#20279](https://github.com/npm/npm/pull/20279) - Document the `--if-present` option for `npm run-script`. - ([@aleclarson](https://github.com/aleclarson)) - -## v6.0.0-next.1 (2018-04-12): - -### NEW FEATURES - -* [`a9e722118`](https://github.com/npm/npm/commit/a9e7221181dc88e14820d0677acccf0648ac3c5a) - [#20256](https://github.com/npm/npm/pull/20256) - Add support for managing npm webhooks. This brings over functionality - previously provided by the [`wombat`](https://www.npmjs.com/package/wombat) CLI. - ([@zkat](https://github.com/zkat)) -* [`8a1a64203`](https://github.com/npm/npm/commit/8a1a64203cca3f30999ea9e160eb63662478dcee) - [#20126](https://github.com/npm/npm/pull/20126) - Add `npm cit` command that's equivalent of `npm ci && npm t` that's equivalent of `npm it`. - ([@SimenB](https://github.com/SimenB)) -* [`fe867aaf1`](https://github.com/npm/npm/commit/fe867aaf19e924322fe58ed0cf0a570297a96559) - [`49d18b4d8`](https://github.com/npm/npm/commit/49d18b4d87d8050024f8c5d7a0f61fc2514917b1) - [`ff6b31f77`](https://github.com/npm/npm/commit/ff6b31f775f532bb8748e8ef85911ffb35a8c646) - [`78eab3cda`](https://github.com/npm/npm/commit/78eab3cdab6876728798f876d569badfc74ce68f) - The `requires` field in your lock-file will be upgraded to use ranges from - versions on your first use of npm. - ([@iarna](https://github.com/iarna)) -* [`cf4d7b4de`](https://github.com/npm/npm/commit/cf4d7b4de6fa241a656e58f662af0f8d7cd57d21) - [#20257](https://github.com/npm/npm/pull/20257) - Add shasum and integrity to the new `npm view` output. - ([@zkat](https://github.com/zkat)) - -### BUG FIXES - -* [`685764308`](https://github.com/npm/npm/commit/685764308e05ff0ddb9943b22ca77b3a56d5c026) - Fix a bug where OTPs passed in via the commandline would have leading - zeros deleted resulted in authentication failures. - ([@iarna](https://github.com/iarna)) -* [`8f3faa323`](https://github.com/npm/npm/commit/8f3faa3234b2d2fcd2cb05712a80c3e4133c8f45) - [`6800f76ff`](https://github.com/npm/npm/commit/6800f76ffcd674742ba8944f11f6b0aa55f4b612) - [`ec90c06c7`](https://github.com/npm/npm/commit/ec90c06c78134eb2618612ac72288054825ea941) - [`825b5d2c6`](https://github.com/npm/npm/commit/825b5d2c60e620da5459d9dc13d4f911294a7ec2) - [`4785f13fb`](https://github.com/npm/npm/commit/4785f13fb69f33a8c624ecc8a2be5c5d0d7c94fc) - [`bd16485f5`](https://github.com/npm/npm/commit/bd16485f5b3087625e13773f7251d66547d6807d) - Restore the ability to bundle dependencies that are uninstallable from the - registry. This also eliminates needless registry lookups for bundled - dependencies. - - Fixed a bug where attempting to install a dependency that is bundled - inside another module without reinstalling that module would result in - ENOENT errors. - ([@iarna](https://github.com/iarna)) -* [`429498a8c`](https://github.com/npm/npm/commit/429498a8c8d4414bf242be6a3f3a08f9a2adcdf9) - [#20029](https://github.com/npm/npm/pull/20029) - Allow packages with non-registry specifiers to follow the fast path that - the we use with the lock-file for registry specifiers. This will improve install time - especially when operating only on the package-lock (`--package-lock-only`). - ([@zkat](https://github.com/zkat)) - - Fix the a bug where `npm i --only=prod` could remove development - dependencies from lock-file. - ([@iarna](https://github.com/iarna)) -* [`834b46ff4`](https://github.com/npm/npm/commit/834b46ff48ade4ab4e557566c10e83199d8778c6) - [#20122](https://github.com/npm/npm/pull/20122) - Improve the update-notifier messaging (borrowing ideas from pnpm) and - eliminate false positives. - ([@zkat](https://github.com/zkat)) -* [`f9de7ef3a`](https://github.com/npm/npm/commit/f9de7ef3a1089ceb2610cd27bbd4b4bc2979c4de) - [#20154](https://github.com/npm/npm/pull/20154) - Let version succeed when `package-lock.json` is gitignored. - ([@nwoltman](https://github.com/nwoltman)) -* [`f8ec52073`](https://github.com/npm/npm/commit/f8ec520732bda687bc58d9da0873dadb2d65ca96) - [#20212](https://github.com/npm/npm/pull/20212) - Ensure that we only create an `etc` directory if we are actually going to write files to it. - ([@buddydvd](https://github.com/buddydvd)) -* [`ab489b753`](https://github.com/npm/npm/commit/ab489b75362348f412c002cf795a31dea6420ef0) - [#20140](https://github.com/npm/npm/pull/20140) - Note in documentation that `package-lock.json` version gets touched by `npm version`. - ([@srl295](https://github.com/srl295)) -* [`857c2138d`](https://github.com/npm/npm/commit/857c2138dae768ea9798782baa916b1840ab13e8) - [#20032](https://github.com/npm/npm/pull/20032) - Fix bug where unauthenticated errors would get reported as both 404s and - 401s, i.e. `npm ERR! 404 Registry returned 401`. In these cases the error - message will now be much more informative. - ([@iarna](https://github.com/iarna)) -* [`d2d290bca`](https://github.com/npm/npm/commit/d2d290bcaa85e44a4b08cc40cb4791dd4f81dfc4) - [#20082](https://github.com/npm/npm/pull/20082) - Allow optional @ prefix on scope with `npm team` commands for parity with other commands. - ([@bcoe](https://github.com/bcoe)) -* [`b5babf0a9`](https://github.com/npm/npm/commit/b5babf0a9aa1e47fad8a07cc83245bd510842047) - [#19580](https://github.com/npm/npm/pull/19580) - Improve messaging when two-factor authentication is required while publishing. - ([@jdeniau](https://github.com/jdeniau)) -* [`471ee1c5b`](https://github.com/npm/npm/commit/471ee1c5b58631fe2e936e32480f3f5ed6438536) - [`0da38b7b4`](https://github.com/npm/npm/commit/0da38b7b4aff0464c60ad12e0253fd389efd5086) - Fix a bug where optional status of a dependency was not being saved to - the package-lock on the initial install. - ([@iarna](https://github.com/iarna)) -* [`b3f98d8ba`](https://github.com/npm/npm/commit/b3f98d8ba242a7238f0f9a90ceea840b7b7070af) - [`9dea95e31`](https://github.com/npm/npm/commit/9dea95e319169647bea967e732ae4c8212608f53) - Ensure that `--no-optional` does not remove optional dependencies from the lock-file. - ([@iarna](https://github.com/iarna)) - -### MISCELLANEOUS - -* [`ec6b12099`](https://github.com/npm/npm/commit/ec6b120995c9c1d17ff84bf0217ba5741365af2d) - Exclude all tests from the published version of npm itself. - ([@iarna](https://github.com/iarna)) - -### DEPENDENCY UPDATES - -* [`73dc97455`](https://github.com/npm/npm/commit/73dc974555217207fb384e39d049da19be2f79ba) - [zkat/cipm#46](https://github.com/zkat/cipm/pull/46) - `libcipm@1.6.2`: - Detect binding.gyp for default install lifecycle. Let's `npm ci` work on projects that - have their own C code. - ([@caleblloyd](https://github.com/caleblloyd)) -* [`77c3f7a00`](https://github.com/npm/npm/commit/77c3f7a0091f689661f61182cd361465e2d695d5) - `iferr@1.0.0` -* [`dce733e37`](https://github.com/npm/npm/commit/dce733e37687c21cb1a658f06197c609ac39c793) - [zkat/json-parse-better-errors#1](https://github.com/zkat/json-parse-better-errors/pull/1) - `json-parse-better-errors@1.0.2` - ([@Hoishin](https://github.com/Hoishin)) -* [`c52765ff3`](https://github.com/npm/npm/commit/c52765ff32d195842133baf146d647760eb8d0cd) - `readable-stream@2.3.6` - ([@mcollina](https://github.com/mcollina)) -* [`e160adf9f`](https://github.com/npm/npm/commit/e160adf9fce09f226f66e0892cc3fa45f254b5e8) - `update-notifier@2.4.0` - ([@sindersorhus](https://github.com/sindersorhus)) -* [`9a9d7809e`](https://github.com/npm/npm/commit/9a9d7809e30d1add21b760804be4a829e3c7e39e) - `marked@0.3.1` - ([@joshbruce](https://github.com/joshbruce)) -* [`f2fbd8577`](https://github.com/npm/npm/commit/f2fbd857797cf5c12a68a6fb0ff0609d373198b3) - [#20256](https://github.com/npm/npm/pull/20256) - `figgy-pudding@2.0.1` - ([@zkat](https://github.com/zkat)) -* [`44972d53d`](https://github.com/npm/npm/commit/44972d53df2e0f0cc22d527ac88045066205dbbf) - [#20256](https://github.com/npm/npm/pull/20256) - `libnpmhook@3.0.0` - ([@zkat](https://github.com/zkat)) -* [`cfe562c58`](https://github.com/npm/npm/commit/cfe562c5803db08a8d88957828a2cd1cc51a8dd5) - [#20276](https://github.com/npm/npm/pull/20276) - `node-gyp@3.6.2` -* [`3c0bbcb8e`](https://github.com/npm/npm/commit/3c0bbcb8e5440a3b90fabcce85d7a1d31e2ecbe7) - [zkat/npx#172](https://github.com/zkat/npx/pull/172) - `libnpx@10.1.1` - ([@jdalton](https://github.com/jdalton)) -* [`0573d91e5`](https://github.com/npm/npm/commit/0573d91e57c068635a3ad4187b9792afd7b5e22f) - [zkat/cacache#128](https://github.com/zkat/cacache/pull/128) - `cacache@11.0.1` - ([@zkat](https://github.com/zkat)) -* [`396afa99f`](https://github.com/npm/npm/commit/396afa99f61561424866d5c8dd7aedd6f91d611a) - `figgy-pudding@3.1.0` - ([@zkat](https://github.com/zkat)) -* [`e7f869c36`](https://github.com/npm/npm/commit/e7f869c36ec1dacb630e5ab749eb3bb466193f01) - `pacote@8.0.0` - ([@zkat](https://github.com/zkat)) -* [`77dac72df`](https://github.com/npm/npm/commit/77dac72dfdb6add66ec859a949b1d2d788a379b7) - `ssri@6.0.0` - ([@zkat](https://github.com/zkat)) -* [`0b802f2a0`](https://github.com/npm/npm/commit/0b802f2a0bfa15c6af8074ebf9347f07bccdbcc7) - `retry@0.12.0` - ([@iarna](https://github.com/iarna)) -* [`4781b64bc`](https://github.com/npm/npm/commit/4781b64bcc47d4e7fb7025fd6517cde044f6b5e1) - `libnpmhook@4.0.1` - ([@zkat](https://github.com/zkat)) -* [`7bdbaeea6`](https://github.com/npm/npm/commit/7bdbaeea61853280f00c8443a3b2d6e6b893ada9) - `npm-package-arg@6.1.0` - ([@zkat](https://github.com/zkat)) -* [`5f2bf4222`](https://github.com/npm/npm/commit/5f2bf4222004117eb38c44ace961bd15a779fd66) - `read-package-tree@5.2.1` - ([@zkat](https://github.com/zkat)) - -## v6.0.0-0 (2018-03-23): - -Sometimes major releases are a big splash, sometimes they're something -smaller. This is the latter kind. That said, we expect to keep this in -release candidate status until Node 10 ships at the end of April. There -will likely be a few more features for the 6.0.0 release line between now -and then. We do expect to have a bigger one later this year though, so keep -an eye out for `npm@7`! - -### *BREAKING* AVOID DEPRECATED - -When selecting versions to install, we now avoid deprecated versions if -possible. For example: - -``` -Module: example -Versions: -1.0.0 -1.1.0 -1.1.2 -1.1.3 (deprecated) -1.2.0 (latest) -``` - -If you ask `npm` to install `example@~1.1.0`, `npm` will now give you `1.1.2`. - -By contrast, if you installed `example@~1.1.3` then you'd get `1.1.3`, as -it's the only version that can match the range. - -* [`78bebc0ce`](https://github.com/npm/npm/commit/78bebc0cedc4ce75c974c47b61791e6ca1ccfd7e) - [#20151](https://github.com/npm/npm/pull/20151) - Skip deprecated versions when possible. - ([@zkat](https://github.com/zkat)) - -### *BREAKING* UPDATE AND OUTDATED - -When `npm install` is finding a version to install, it first checks to see -if the specifier you requested matches the `latest` tag. If it doesn't, -then it looks for the highest version that does. This means you can do -release candidates on tags other than `latest` and users won't see them -unless they ask for them. Promoting them is as easy as setting the `latest` -tag to point at them. - -Historically `npm update` and `npm outdated` worked differently. They just -looked for the most recent thing that matched the semver range, disregarding -the `latest` tag. We're changing it to match `npm install`'s behavior. - -* [`3aaa6ef42`](https://github.com/npm/npm/commit/3aaa6ef427b7a34ebc49cd656e188b5befc22bae) - Make update and outdated respect latest interaction with semver as install does. - ([@iarna](https://github.com/iarna)) -* [`e5fbbd2c9`](https://github.com/npm/npm/commit/e5fbbd2c999ab9c7ec15b30d8b4eb596d614c715) - `npm-pick-manifest@2.1.0` - ([@iarna](https://github.com/iarna)) - -### PLUS ONE SMALLER PATCH - -Technically this is a bug fix, but the change in behavior is enough of an -edge case that I held off on bringing it in until a major version. - -When we extract a binary and it starts with a shebang (or "hash bang"), that -is, something like: - -``` -#!/usr/bin/env node -``` - -If the file has Windows line endings we strip them off of the first line. -The reason for this is that shebangs are only used in Unix-like environments -and the files with them can't be run if the shebang has a Windows line ending. - -Previously we converted ALL line endings from Windows to Unix. With this -patch we only convert the line with the shebang. (Node.js works just fine -with either set of line endings.) - -* [`814658371`](https://github.com/npm/npm/commit/814658371bc7b820b23bc138e2b90499d5dda7b1) - [`7265198eb`](https://github.com/npm/npm/commit/7265198ebb32d35937f4ff484b0167870725b054) - `bin-links@1.1.2`: - Only rewrite the CR after a shebang (if any) when fixing up CR/LFs. - ([@iarna](https://github.com/iarna)) - -### *BREAKING* SUPPORTED NODE VERSIONS - -Per our supported Node.js policy, we're dropping support for both Node 4 and -Node 7, which are no longer supported by the Node.js project. - -* [`077cbe917`](https://github.com/npm/npm/commit/077cbe917930ed9a0c066e10934d540e1edb6245) - Drop support for Node 4 and Node 7. - ([@iarna](https://github.com/iarna)) - -### DEPENDENCIES - -* [`478fbe2d0`](https://github.com/npm/npm/commit/478fbe2d0bce1534b1867e0b80310863cfacc01a) - `iferr@1.0.0` -* [`b18d88178`](https://github.com/npm/npm/commit/b18d88178a4cf333afd896245a7850f2f5fb740b) - `query-string@6.0.0` -* [`e02fa7497`](https://github.com/npm/npm/commit/e02fa7497f89623dc155debd0143aa54994ace74) - `is-cidr@2.0.5` -* [`c8f8564be`](https://github.com/npm/npm/commit/c8f8564be6f644e202fccd9e3de01d64f346d870) - [`311e55512`](https://github.com/npm/npm/commit/311e5551243d67bf9f0d168322378061339ecff8) - `standard@11.0.1` diff --git a/changelogs/CHANGELOG-7.md b/changelogs/CHANGELOG-7.md deleted file mode 100644 index 0c00a90..0000000 --- a/changelogs/CHANGELOG-7.md +++ /dev/null @@ -1,3644 +0,0 @@ -## v7.24.2 (2021-10-04) - -### BUG FIXES - -* [`56d6cfdc0`](https://github.com/npm/cli/commit/56d6cfdc0745fe919645389b94efb36760eb4179) - [#3804](https://github.com/npm/cli/issues/3804) - encode url before opening - ([@isaacs](https://github.com/isaacs)) -* [`075fe5056`](https://github.com/npm/cli/commit/075fe50565ae5c66df727cdd7df9dd5ed8cd4015) - [#3799](https://github.com/npm/cli/issues/3799) - restore exit code on "npm outdated" - ([@gfyoung](https://github.com/gfyoung)) -* [`dbb90f799`](https://github.com/npm/cli/commit/dbb90f7997900b8ae6026dddaa718efe9a1db2f4) - [#3809](https://github.com/npm/cli/issues/3809) - use Intl.Collator for string sorting when available - ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES - -* [`69ab10bbf`](https://github.com/npm/cli/commit/69ab10bbf83d42a5d3b5d3f43e5e5b861f3dfed0) - `is-core-module@2.7.0` -* [`e94ddeaca`](https://github.com/npm/cli/commit/e94ddeaca1e75ecc8f54ebcb3df222965e3635d1) - `@npmcli/arborist@2.9.0`: - * fix: avoid infinite loops in peer dep replacements - * fix: use Intl.Collator for string sorting when available - * feat(vuln): expose isDirect - -### DOCUMENTATION - -* [`f425950a6`](https://github.com/npm/cli/commit/f425950a6ca671b2df20703f70b59022c2858d4d) - [#3805](https://github.com/npm/cli/issues/3805) - remove npm Enterprise from documentation - ([@ethomson](https://github.com/ethomson)) -* [`bb0b2da6c`](https://github.com/npm/cli/commit/bb0b2da6c0275dd8c9eda894452ce45b2e8c4c51) - [#3699](https://github.com/npm/cli/issues/3699) - fix(docs): add note about workspace script order - ([@behnammodi](https://github.com/behnammodi)) - -## v7.24.1 (2021-09-23) - -### DEPENDENCIES - -* [`1be8d41e6`](https://github.com/npm/cli/commit/1be8d41e6f23f7a3d8411a31099ab546fbcb5bfa) - `socks-proxy-agent@6.1.0`: - * feat: allow passing tls connection options -* [`eafd55eae`](https://github.com/npm/cli/commit/eafd55eae219a6c15d2857d06b673a67d7f7d060) - `glob@7.2.0` - -### DOCS - -* [`dae5ce305`](https://github.com/npm/cli/commit/dae5ce3055ded57eab8aa3425004c60224a6fe67) - [#3784](https://github.com/npm/cli/issues/3784) - docs: document special meaning of registry.npmjs.com - ([@everett1992](https://github.com/everett1992)) - -## v7.24.0 (2021-09-16) - -### FEATURES - -* [`c7787b3fb`](https://github.com/npm/cli/commit/c7787b3fb7630aab84aae83ebf9a7117c7173b6b) - [`1fbbe1e04`](https://github.com/npm/cli/commit/1fbbe1e04be5d79c7b49910324e64c19ed599eeb) - bundled npm-install-checks ([@wraithgar](https://github.com/wraithgar)) - -### BUG FIXES - -* [`0320bd77e`](https://github.com/npm/cli/commit/0320bd77e2a38f48a88e377df4b122fd21043a83) - [#3739](https://github.com/npm/cli/issues/3739) - fix(view): Show the correct publish date for versions selected by range ([@andersk](https://github.com/andersk)) -* [`e4a521857`](https://github.com/npm/cli/commit/e4a5218573583149af795982a39fa64a4116cdab) - [#3748](https://github.com/npm/cli/issues/3748) - fix(install.sh): don't remove old npm first - ([@wraithgar](https://github.com/wraithgar)) -* [`b4aac345b`](https://github.com/npm/cli/commit/b4aac345b0a7cdec4d713c5be4daea37330b2b26) - [#3754](https://github.com/npm/cli/issues/3754) - fix(config): user-agent properly shows ci - ([@wraithgar](https://github.com/wraithgar)) -* [`b807cd62e`](https://github.com/npm/cli/commit/b807cd62eabe337e3243415c9870ea36d9289e12) - [#3738](https://github.com/npm/cli/issues/3738) - fix(search): return valid json for no results - ([@AyushRawal](https://github.com/AyushRawal)) -* [`2def17a3b`](https://github.com/npm/cli/commit/2def17a3b625b92b40c6185ff4b47e8ed006492c) - [#3760](https://github.com/npm/cli/issues/3760) - fix(install): use configured registry when checking manifest - ([@yacoman89](https://github.com/yacoman89)) -* [`ca792acdd`](https://github.com/npm/cli/commit/ca792acdd4ba683d8415c88188ec6739033fb4fd) - [#3761](https://github.com/npm/cli/issues/3761) - fix(logs): clean args for failed commands - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`59743972c`](https://github.com/npm/cli/commit/59743972c2ae1d2dd601aaa6c59974c686b1cb29) - [#3747](https://github.com/npm/cli/issues/3747) - fix(did-you-mean): succeed if cwd is not a package - ([@wraithgar](https://github.com/wraithgar)) -* [`ac8e4ad18`](https://github.com/npm/cli/commit/ac8e4ad18a6b726dd2c3abcb0f605701cca0ae2c) - `init-package-json@2.0.5`: - * fix: bin script path -* [`371655a6b`](https://github.com/npm/cli/commit/371655a6b0e6664fec67f16cb247cc9f174a5197) - `minipass@3.1.5`: - * fix: re-emit 'error' event if missed and new listener added - * fix: do not blow up if process is missing - -### DOCUMENTATION - -* [`4d93b484a`](https://github.com/npm/cli/commit/4d93b484abb50e3704fb436db572b93fb36c7ac3) - [#3759](https://github.com/npm/cli/issues/3759) - fix(docs): use correct hyperlink to package-json - ([@nategreen](https://github.com/nategreen)) - -## v7.23.0 (2021-09-09) - -### FEATURES - -* [`6c12500ae`](https://github.com/npm/cli/commit/6c12500ae14a6f8b78e3ab091ee6cc8e2ea9fd23) - [#3731](https://github.com/npm/cli/issues/3731) - feat(install): very strict global npm engines - ([@wraithgar](https://github.com/wraithgar)) - -### BUG FIXES - -* [`1ad093824`](https://github.com/npm/cli/commit/1ad0938243110d983284e8763da41a57b561563d) - [#3732](https://github.com/npm/cli/issues/3732) - fix(error-message): clean urls from 404 error - ([@wraithgar](https://github.com/wraithgar)) - -### DOCUMENTATION - -* [`64f7d1a55`](https://github.com/npm/cli/commit/64f7d1a55db99b1aaf8fb59557b3dedcdcd954a0) - [#3727](https://github.com/npm/cli/issues/3727) - docs(contributing): add note on changes to tooling - ([@darcyclarke](https://github.com/darcyclarke)) -* [`eda9162f2`](https://github.com/npm/cli/commit/eda9162f2db19b512d3af6b0d43201d54045c13a) - [#3715](https://github.com/npm/cli/issues/3715) - Add --if-present flag documentation to workspaces - ([@Matsuuu](https://github.com/Matsuuu)) - -## v7.22.0 (2021-09-02) - -### BUG FIXES -* [`6f431fe23`](https://github.com/npm/cli/commit/6f431fe2325f77b4370f95848359a36fe7a011d1) - [#3690](https://github.com/npm/cli/issues/3690) - Fix one “see also” link - ([@tripu](https://github.com/tripu)) - -### DEPENDENCIES -* [`033e948c9`](https://github.com/npm/cli/commit/033e948c95b3455812e03a860ad1bd96a635e7eb) - `read-package-json@4.1.1`: - * feat: add types lookup - * fix(man): don't lose relative man path -* [`1fa549db0`](https://github.com/npm/cli/commit/1fa549db0955b55fd680a658809a6d97be306b06) - `@npmcli/config@2.3.0`: - * feat: export npm_config_local_prefix and npm_config_global_prefix to the environment -* [`e91578d10`](https://github.com/npm/cli/commit/e91578d10b1d5d930fec32e7070d975af4892140) - `minpass-fetch@1.4.1`: - * Made rejectUnauthorized depend on NODE_TLS_REJECT_UNAUTHORIZED -* [`6125db545`](https://github.com/npm/cli/commit/6125db545315da0217fe7b05062fd0a504c9a45b) - `are-we-there-yet@1.1.6` -* [`0dcda73b0`](https://github.com/npm/cli/commit/0dcda73b022083338c4cb755390a275757b9627b) - `string_decoder@1.3.0` -* [`4b913417c`](https://github.com/npm/cli/commit/4b913417c4e30980505a02eec50810f895dd52d7) - `npmlog@5.0.1` -* [`876c755eb`](https://github.com/npm/cli/commit/876c755eb0dfc215123682f798b5fca415f7c7d9) - `@npmcli/arborist@2.8.3`: - * fix: do not fail adding unresolvable optional dep - -## v7.21.1 (2021-08-26) - -### BUG FIXES - -* [`4e52217cb`](https://github.com/npm/cli/commit/4e52217cb25a697b0f6b0131bcb8c87e0dbcda53) - [#3684](https://github.com/npm/cli/issues/3684) - fix(config): respect --global, --package-lock-only - ([@nlf](https://github.com/nlf)) - -### DEPENDENCIES - -* [`e3878536f`](https://github.com/npm/cli/commit/e3878536f3612d9ddc3002c126cfa9a91021c7db) - `make-fetch-happen@9.1.0`: - * fix: use the same strictSSL default as tls.connect -* [`145f70cc1`](https://github.com/npm/cli/commit/145f70cc1b78dee4ffa53f557fa72d0948696839) - `read-package-json@4.0.1`: - * fix: Add gitHead in subdirectories too - * fix(man): don't resolve paths to man files -* [`3f4d37143`](https://github.com/npm/cli/commit/3f4d371432a1fc8280e73d8467acd0eed0bbef26) - `tar@6.1.11`: - * fix: perf regression on hot string munging path -* [`e63a942c6`](https://github.com/npm/cli/commit/e63a942c685233fa546788981ed9c144220d50e1) - `cacache@15.3.0`: - * feat: introduce @npmcli/fs for tmp dir methods - -### DOCUMENTATION - -* [`957fa6040`](https://github.com/npm/cli/commit/957fa604035992285572f63c38545eea86bbb1ff) - [#3681](https://github.com/npm/cli/issues/3681) - clarify uninstall lifecycle script - ([@fritzy](https://github.com/fritzy)) - -## v7.21.0 (2021-08-19) - -### FEATURES - -* [`ff34d6cd6`](https://github.com/npm/cli/commit/ff34d6cd6f2077962cba1ef9c893a958ac7174f8) - [#3592](https://github.com/npm/cli/issues/3592) - feat(cache): initial implementation of ls and rm - ([@fritzy](https://github.com/fritzy)) - -### BUG FIXES - -* [`32e88c943`](https://github.com/npm/cli/commit/32e88c94387bda6b25f66019793efcda8f01ef6e) - [#3640](https://github.com/npm/cli/issues/3640) - fix(did-you-mean): switch levenshtein libraries - ([@wraithgar](https://github.com/wraithgar)) -* [`487731cd5`](https://github.com/npm/cli/commit/487731cd56a22272c6ff72ef2fa7822368bf63e3) - [#3658](https://github.com/npm/cli/issues/3658) - fix(logging): sanitize logged argv - ([@wraithgar](https://github.com/wraithgar)) -* [`68a19bb02`](https://github.com/npm/cli/commit/68a19bb02aa0d7a566c8e2245f1e524b915faf09) - [#3661](https://github.com/npm/cli/issues/3661) - fix(error-message): look for er.path not er.file - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`df57f0d53`](https://github.com/npm/cli/commit/df57f0d532d406b3b1409454ea5f2255fcd08248) - `@npmcli/run-script@1.8.6` -* [`8183976cf`](https://github.com/npm/cli/commit/8183976cfa53bab6e9116ec5de97b04225c5d09b) - `normalize-package-data@3.0.3`: - * fix: account for "licence" as spelling variant -* [`f07772401`](https://github.com/npm/cli/commit/f07772401c3712d5f9b0dfeef88e1943229cfa79) - `init-package-json@2.0.4` -* [`991a3bd39`](https://github.com/npm/cli/commit/991a3bd39f0abf8614373f267419c7b8f6e279ac) - `read-package-json@4.0.0` -* [`e9e5ee560`](https://github.com/npm/cli/commit/e9e5ee560e2baf694843df852d027fb9f2dbcb06) - `@npmcli/arborist@2.8.2`: - * fix: treat top-level global packages as "top" nodes - * fix: load global symlinks implicitly as file: deps - * fix(reify): debug crash when extracting into symlink - * fix: node_modules must be a directory - * fix: make Node.children() a case-insensitive Map - * fix(reify): verify existing deps in nm are dirs -* [`b6f40b5f8`](https://github.com/npm/cli/commit/b6f40b5f85094387f2fa8d42b6a624644b8ddcf1) - `tar@6.1.10`: - * fix: prune dirCache properly for unicode, windows - * fix: reserve paths properly for unicode, windows - * fix: prevent path escape using drive-relative paths - * fix: drop dirCache for symlink on all platforms -* [`218cacadc`](https://github.com/npm/cli/commit/218cacadcf35879ce178813c699258e7ffe91fe9) - `is-core-module@2.6.0` -* [`7ac621cd1`](https://github.com/npm/cli/commit/7ac621cd14f2ffbf5c15c3258f537fdfddc21ac6) - `smart-buffer@4.2.0` -* [`94f92de13`](https://github.com/npm/cli/commit/94f92de138432c900b195b71949f4933e872f26a) - `make-fetch-happen@9.0.5` -* [`71cdfd898`](https://github.com/npm/cli/commit/71cdfd8983cd0c61f39bdf91f87d40aad3b081c2) - `spdx-license-ids@3.0.10`: - * update license list to v3.14 - -### DOCUMENTATION - -* [`ff6626ab6`](https://github.com/npm/cli/commit/ff6626ab6ca9b4e189a3bc56a762104927dbeedb) - [#3630](https://github.com/npm/cli/issues/3630) - fix(docs): update npm-publish access flag info - ([@austincho](https://github.com/austincho)) - -## v7.20.6 (2021-08-12) - -### DEPENDENCIES - -* [`5bebf280f`](https://github.com/npm/cli/commit/5bebf280f228e818524f6989caab1cfba1ffaf90) - `tar@6.1.8` - * fix: reserve paths case-insensitively -* [`5d89de44d`](https://github.com/npm/cli/commit/5d89de44daa636dc151eaefcafabb357540d35ce) - `tar@6.1.7`: - * fix: normalize paths on Windows systems -* [`a1bdbea97`](https://github.com/npm/cli/commit/a1bdbea974ebfc6694b4c8ad5da86215c2924dde) - [#3569](https://github.com/npm/cli/issues/3569) - * remove byte-size - ([@wraithgar](https://github.com/wraithgar)) -* [`61782fa85`](https://github.com/npm/cli/commit/61782fa858c278455ce144f975c6b0e3ea2d9944) - `@npmcli/map-workspaces@1.0.4`: - * fix: better error message for duplicate workspace names -* [`b88f770fa`](https://github.com/npm/cli/commit/b88f770faa2651ca0833e1c9eb361e9e07e0bbc3) - `@npmcli/arborist@2.8.1`: - * [#3632] Fix "cannot read property path of null" error in 'npm dedupe' - * fix(shrinkwrap): always set name on the root node - -### DOCUMENTATION - -* [`001f2c1b7`](https://github.com/npm/cli/commit/001f2c1b7e9474049a45709f0e80ee3c474a4ba9) - [#3621](https://github.com/npm/cli/issues/3621) - fix(docs): do not include certain files - ([@AkiJoey](https://github.com/AkiJoey)) -* [`d1812f1a6`](https://github.com/npm/cli/commit/d1812f1a627d6a4d4cb6d07d7735d2d2cc2cf264) - [#3630](https://github.com/npm/cli/issues/3630) - fix(docs): update npm-publish access flag info - ([@austincho](https://github.com/austincho)) -* [`d5a099c7b`](https://github.com/npm/cli/commit/d5a099c7bf62977a5a5d8242c61f323a88e27c73) - [#3615](https://github.com/npm/cli/issues/3615) - fix(readme): add nvm-windows to installers links - ([@Yash-Singh1](https://github.com/Yash-Singh1)) - -## v7.20.5 (2021-08-05) - -### DEPENDENCIES - -* [`44377738e`](https://github.com/npm/cli/commit/44377738ef6b53607a7b17162aec984d5dcf7c58) - `graceful-fs@4.2.8` - * fix: start retrying immediately, stop after 60 seconds - - -## v7.20.4 (2021-08-05) - -### BUG FIXES - -* [`6a8086e25`](https://github.com/npm/cli/commit/6a8086e258aa209b877e182db4b75f11de5b291d) - [#3463](https://github.com/npm/cli/issues/3463) - fix(tests): move more tests to use real npm - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`15fae4941`](https://github.com/npm/cli/commit/15fae4941475f4398e47d9cc4eb6a73683e15aac) - `tar@6.1.6`: - * fix: properly handle top-level files when using strip - * Avoid an unlikely but theoretically possible redos - * WriteEntry backpressure - * fix(unpack): always resume parsing after an entry error - * fix(unpack): fix hang on large file on open() fail - * fix: properly prefix hard links -* [`745326de0`](https://github.com/npm/cli/commit/745326de0fae9f27f1deaf7729777aae48ac29fc) - `libnpmexec@2.0.1`: - * Clear progress bar which overlays confirm prompt -* [`e82bcd4e8`](https://github.com/npm/cli/commit/e82bcd4e8355d083f8f3eedb6251a5f3053d6dfd) - `graceful-fs@4.2.7`: - * fix: start retrying immediately, stop after 10 attempts - -## v7.20.3 (2021-07-29) - -### BUG FIXES - -* [`66dc5f94d`](https://github.com/npm/cli/commit/66dc5f94dfb5bc99c715e075cde1ab9c1ec84a83) - [#3588](https://github.com/npm/cli/issues/3588) - update eresolve explanations for new arborist data provided -* [`99575acab`](https://github.com/npm/cli/commit/99575acab5c93c03c59cb918c7916647b2c0be51) - [#3591](https://github.com/npm/cli/issues/3591) - fix(node_modules): remove duplicated file - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`97cb5ec31`](https://github.com/npm/cli/commit/97cb5ec312e151527ba2aab77ed0307917e1d845) - `@npmcli/arborist@2.8.0`: - * Refactor ideal tree building to handle more complicated - peerDependencies use cases. - * Do not modify ideal tree while checking if a peerSet can be placed. -* [`7db1a0a26`](https://github.com/npm/cli/commit/7db1a0a264cf67d2a2a3cdc71bbf09b36dc45075) - chore(deps): `mime-types@1.49.0` `mime-db@1.49.0` - -## v7.20.2 (2021-07-27) - -### DEPENDENCIES - -* [`f5aab1f88`](https://github.com/npm/cli/commit/f5aab1f8878b4e9a6f4d47dddc449e18a190e201) - `tar@6.1.1` - * fix: strip absolute paths more comprehensively -* [`ce8fb0f69`](https://github.com/npm/cli/commit/ce8fb0f69ae1b3fdd8834cf073d3d30c2bfc7bc6) - `tar@6.1.2` - * fix: Remove paths from dirCache when no longer dirs -* [`ced85087a`](https://github.com/npm/cli/commit/ced85087ac5fce5984ae28af910357a9a94434d7) - `gauge@3.0.1` - * add missing dependency to package.json - -## v7.20.1 (2021-07-22) - -### BUG FIXES - -* [`009ad1e68`](https://github.com/npm/cli/commit/009ad1e683aa061d7e5c78b9362b0bd1b14ee643) - [#3561](https://github.com/npm/cli/issues/3561) - fix(exit-handler): always warn if not called - ([@wraithgar](https://github.com/wraithgar)) -* [`eb67054c8`](https://github.com/npm/cli/commit/eb67054c8303348b25f9717c8f82c8d8d494a242) - [#3563](https://github.com/npm/cli/issues/3563) - fix(config): consolidate use of npm.color - ([@wraithgar](https://github.com/wraithgar)) - -### DOCUMENTATION - -* [`a014f3d28`](https://github.com/npm/cli/commit/a014f3d284e49cd085cfd060a71a161b93bca9d1) - [#3562](https://github.com/npm/cli/issues/3562) - fix(docs): typo in `npm cmd` docs - ([@wraithgar](https://github.com/wraithgar)) -* [`1fe1c9b74`](https://github.com/npm/cli/commit/1fe1c9b74ea3c3d5bb5b3696b954422b9b55dd91) - [#3523](https://github.com/npm/cli/issues/3523) - fix(docs): updated policy urls - ([@DemiraDimitrova](https://github.com/DemiraDimitrova)) - -### DEPENDENCIES - -* [`d7f29e8c9`](https://github.com/npm/cli/commit/d7f29e8c94ae77661390f82ae72efc1bd6fcfbc3) - `read-package-json-fast@2.0.3`: - - feat: load directories.bin as a bin object -* [`b1fefa73d`](https://github.com/npm/cli/commit/b1fefa73db2f8d9c55b4447ffc1cdbaf8e9bb298) - `npmlog@5.0.0` - * Drop support for node 6 and 8 -* [`b6e09971a`](https://github.com/npm/cli/commit/b6e09971a8f9a3c92188838b69be0a0dda27f0bb) - remove ignored files from node_modules - ([@Ruy Adorno](https://github.com/Ruy Adorno)) -* [`cf737c505`](https://github.com/npm/cli/commit/cf737c505e76a473850c5244b17f3469efbc3c02) - `debug@4.3.2` - -## v7.20.0 (2021-07-15) - -### FEATURES - -* [`f17aca5cd`](https://github.com/npm/cli/commit/f17aca5cdf355aaa7e1f517d1b3bb4213f4df092) - [#3487](https://github.com/npm/cli/issues/3487) - feat: add `npm pkg` command - ([@ruyadorno](https://github.com/ruyadorno)) -* [`98905ae37`](https://github.com/npm/cli/commit/98905ae3759165cd6d6f6306f31acc6a2baa4cde) - [#3471](https://github.com/npm/cli/issues/3471) - feat(config): introduce `location` parameter - ([@nlf](https://github.com/nlf)) - -### BUG FIXES - -* [`4755b0728`](https://github.com/npm/cli/commit/4755b072877f547585cb0e2562261b2c87e2ff0b) - [#3498](https://github.com/npm/cli/issues/3498) - friendlier errors for `ERR_SOCKET_TIMEOUT` - ([@nlf](https://github.com/nlf)) -* [`3ecf19cdc`](https://github.com/npm/cli/commit/3ecf19cdc35684ccb15280b2c34d27496aa1c634) - [#3508](https://github.com/npm/cli/issues/3508) - fix(config): fix noproxy - ([@wraithgar](https://github.com/wraithgar)) -* [`c3bd10e46`](https://github.com/npm/cli/commit/c3bd10e461976a073e6a898c46f8bde28b17668f) - [#3499](https://github.com/npm/cli/issues/3499) - fix(update-notifier): don't force black background - ([@wraithgar](https://github.com/wraithgar)) -* [`89483e888`](https://github.com/npm/cli/commit/89483e888acc56386b9ebc4d70a4676e4a5a5cb1) - [#3497](https://github.com/npm/cli/issues/3497) - fix(usage): better audit/boolean flag usage output - ([@wraithgar](https://github.com/wraithgar)) -* [`feeb8e42a`](https://github.com/npm/cli/commit/feeb8e42a7b0510023175dc86269edb544d97601) - [#3495](https://github.com/npm/cli/issues/3495) - fix(publish): obey --ignore-scripts flag - ([@wraithgar](https://github.com/wraithgar)) -* [`103c8c3ef`](https://github.com/npm/cli/commit/103c8c3ef3ba7ff0483557f32eebc4c6298285e3) - [#3479](https://github.com/npm/cli/issues/3479) - chore(exit): log any un-ended timings - ([@wraithgar](https://github.com/wraithgar)) -* [`efc4313c2`](https://github.com/npm/cli/commit/efc4313c2062ffad22aa24e5198d575a7eb5f20e) - [#3482](https://github.com/npm/cli/issues/3482) - chore(refactor): refactor exit handler and tests - ([@wraithgar](https://github.com/wraithgar)) -* [`d8eb49b70`](https://github.com/npm/cli/commit/d8eb49b705acb50b6bed971bfcce4db6e18e73dd) - [#3540](https://github.com/npm/cli/issues/3540) - fix(bundle-and-ignore): case sensitivity cleanup - ([@wraithgar](https://github.com/wraithgar)) - -### DOCUMENTATION - -* [`339145f64`](https://github.com/npm/cli/commit/339145f64f82d540dbc72ef97b54ae20c34315dd) - [#3491](https://github.com/npm/cli/issues/3491) - fix(docs): clarify what install type gets `.bin` - ([@wraithgar](https://github.com/wraithgar)) -* [`74c99755e`](https://github.com/npm/cli/commit/74c99755e522f9cfc0d602841568d5e1f835fcaf) - [#3494](https://github.com/npm/cli/issues/3494) - fix(docs): add npm update example - ([@wraithgar](https://github.com/wraithgar)) -* [`801a52330`](https://github.com/npm/cli/commit/801a52330636008fecadc812916c76fb945ce1f6) - [#3542](https://github.com/npm/cli/issues/3542) - fix(docs): correct Node.js JavaScript stylings - ([@relrelb](https://github.com/relrelb)) -* [`791416713`](https://github.com/npm/cli/commit/791416713d64c072d73bffbab2daf7b8eb3c4868) - [#3546](https://github.com/npm/cli/issues/3546) - fix(docs): how to see background script output - ([@cinderblock](https://github.com/cinderblock)) - -### DEPENDENCIES - -* [`691816f3d`](https://github.com/npm/cli/commit/691816f3de2a679152644a60f3e2c5962df6a81d) - `@npmcli/arborist@2.7.1` - * fixes running prepare scripts for workspaces on reify - * ensure pacote always compares correct integrity values -* [`b9597e944`](https://github.com/npm/cli/commit/b9597e944377e74907607ee280ec1e8c31dd3156) - `make-fetch-happen@9.0.4` - * fix: retry socket timeout failures - * fix: clean up invalid indexes and content after cacache read errors -* [`f573e7c56`](https://github.com/npm/cli/commit/f573e7c56e8505fd6dcc3e5f5b5be401d0a45b58) - `minipass-fetch@1.3.4` - * fix: correctly handle error events that happen after response events -* [`2d5797ea0`](https://github.com/npm/cli/commit/2d5797ea01e17b1559d792613446e1435e588a35) - `pacote@11.3.5` - * fix: show more actionable messages for git pathspec errors - * fix: include all dep types when building for prepare - * fix: do not set mtime when unpacking - -## v7.19.1 (2021-07-01) - -### BUG FIXES - -* [`013f0262d`](https://github.com/npm/cli/commit/013f0262db3e16605820f6117749fd3ebc70f6d1) - [#3469](https://github.com/npm/cli/issues/3469) - fix(exitHandler): write code to logfile - ([@wraithgar](https://github.com/wraithgar)) -* [`0dd0341ac`](https://github.com/npm/cli/commit/0dd0341ac9a65a2df8fc262ad9a56b7351f99d66) - [#3474](https://github.com/npm/cli/issues/3474) - fix(ping): make "npm ping" echo a right time - ([@aluneed](https://github.com/aluneed)) -* [`d2e298f3c`](https://github.com/npm/cli/commit/d2e298f3cbab278071480f94ff7d916d42cbf43b) - [#3484](https://github.com/npm/cli/issues/3484) - fix(deprecate): add undeprecate support - ([@wraithgar](https://github.com/wraithgar)) - - ### DOCUMENTATION - -* [`9dd32d08e`](https://github.com/npm/cli/commit/9dd32d08e09c21c9a4517161abfc7eed6518faf2) - [#3485](https://github.com/npm/cli/issues/3485) - fix(docs): remove npm package config override - ([@wraithgar](https://github.com/wraithgar)) -* [`a4e095618`](https://github.com/npm/cli/commit/a4e095618cda72244a18aaff9d6660b9082a2b84) - [#3486](https://github.com/npm/cli/issues/3486) - fix(docs): remove .hooks scripts - ([@wraithgar](https://github.com/wraithgar)) - -### TESTING - -* [`5f8ccccef`](https://github.com/npm/cli/commit/5f8ccccef9fc19229320df8cbcae9fcea8d31388) - [#3483](https://github.com/npm/cli/issues/3483) - chore(tests): clean snapshot for lib/view.js tests - ([@wraithgar](https://github.com/wraithgar)) - -## v7.19.0 (2021-06-24) - -### FEATURES - -* [`23ce3af19`](https://github.com/npm/cli/commit/23ce3af199c8a14ef16c63fc638a1ac21fd9a9b0) - [#3460](https://github.com/npm/cli/issues/3460) - feat(ls): report *why* something is invalid - ([@isaacs](https://github.com/isaacs)) - -### BUG FIXES - -* [`53f81af31`](https://github.com/npm/cli/commit/53f81af319f298a0fdd8f143184c3e89770f24ea) - [#3450](https://github.com/npm/cli/issues/3450) - fix(docs): Improve phrasing of workspace example - ([@lumaxis](https://github.com/lumaxis)) -* [`78da60ffe`](https://github.com/npm/cli/commit/78da60ffefcfd457a4432ce1492ee7b53d854450) - [#3454](https://github.com/npm/cli/issues/3454) - chore(linting): add bin and clean up lib/ls.js -* [`54eae3063`](https://github.com/npm/cli/commit/54eae3063eeb197225ee930525a1316e34ecf34c) - [#3416](https://github.com/npm/cli/issues/3416) - chore(errorHandler): rename to exit handler - ([@wraithgar](https://github.com/wraithgar)) -* [`d0f50b156`](https://github.com/npm/cli/commit/d0f50b156725e5b414050d9e9a59d5fad8a39a3d) - [#3451](https://github.com/npm/cli/issues/3451) - chore(refactor): async npm.load - ([@wraithgar](https://github.com/wraithgar)) -* [`87f67d9ef`](https://github.com/npm/cli/commit/87f67d9efaf6f897cf0d74e738c2625a21044109) - [#3458](https://github.com/npm/cli/issues/3458) - chore(tests): expose real mock npm object - ([@wraithgar](https://github.com/wraithgar)) -* [`f3dce0917`](https://github.com/npm/cli/commit/f3dce0917088dc37795af39e7f6b5089beff984c) - [#3459](https://github.com/npm/cli/issues/3459) - chore(config): snapshot config descriptions - ([@wraithgar](https://github.com/wraithgar)) -* [`6254b6f72`](https://github.com/npm/cli/commit/6254b6f726a301908f73b36ccfa52cd4fd6619e5) - [#3234](https://github.com/npm/cli/issues/3234) - [#3455](https://github.com/npm/cli/issues/3455) - @npmcli/package-json refactor - ([@ruyadorno](https://github.com/ruyadorno)) - -### DEPENDENCIES - -* [`fe4138381`](https://github.com/npm/cli/commit/fe4138381fd2e8c919bb9f794e20033ff049f783) - `@npmcli/arborist@2.6.4`: - * bin: allow turning off timer display with --timers=false - * fix: do not try to inflate a fresh lockfile - * fix(diff): walk target children if root is a link - * chore: @npmcli/package-json refactor - -## v7.18.1 (2021-06-17) - -## BUG FIXES - -* [`fce30e423`](https://github.com/npm/cli/commit/fce30e423745a2b81530176d2f08ca84896eef4c) - [#3435](https://github.com/npm/cli/issues/3435) - fix(docs): rebuild config docs - ([@wraithgar](https://github.com/wraithgar)) - -## v7.18.0 (2021-06-17) - -## FEATURES - -* [`ae285b391`](https://github.com/npm/cli/commit/ae285b39191f3a0c4edfb045a334057bef4567b5) - [#3408](https://github.com/npm/cli/issues/3408) - feat(ls): support `--package-lock-only` flag - ([@G-Rath](https://github.com/G-Rath)) -* [`c984fb59c`](https://github.com/npm/cli/commit/c984fb59c5af087b91acd927cbbacad7c6a46576) - [#3420](https://github.com/npm/cli/issues/3420) - feat(pack): add pack-destination config - ([@wraithgar](https://github.com/wraithgar)) - -## BUG FIXES - -* [`40829ec40`](https://github.com/npm/cli/commit/40829ec40c33a6d23f18715e60e3395bdcb0467e) - [#2554](https://github.com/npm/cli/issues/2554) - [#3399](https://github.com/npm/cli/issues/3399) - fix(link): do not prune packages - ([@ruyadorno](https://github.com/ruyadorno)) -* [`102d4e6fb`](https://github.com/npm/cli/commit/102d4e6fb3c3b02148dbeee977a7d1e6372340d5) - [#3417](https://github.com/npm/cli/issues/3417) - fix(workspaces): explicitly error in global mode - ([@wraithgar](https://github.com/wraithgar)) -* [`993df3041`](https://github.com/npm/cli/commit/993df3041f5bdaa496c3c8d80f00d16b9cf0a1e6) - [#3423](https://github.com/npm/cli/issues/3423) - fix(docs): ls command usage instructions - ([@gurdiga](https://github.com/gurdiga)) -* [`dcc13662c`](https://github.com/npm/cli/commit/dcc13662c1d3e22eaf392647a9cddbb5b0710d24) - [#3418](https://github.com/npm/cli/issues/3418) - fix(config): update link definition - ([@wraithgar](https://github.com/wraithgar)) -* [`b19e56c2e`](https://github.com/npm/cli/commit/b19e56c2e54c035518165470c10480201cefa997) - [#3382](https://github.com/npm/cli/issues/3382) - [#3429](https://github.com/npm/cli/issues/3429) - fix(ls): respect prod config for workspaces - ([@ruyadorno](https://github.com/ruyadorno)) -* [`c99b8b53c`](https://github.com/npm/cli/commit/c99b8b53c3d7a9b0daa6d4416e9c40202ddd59a2) - [#3430](https://github.com/npm/cli/issues/3430) - fix(config): add flatOptions.npxCache - ([@wraithgar](https://github.com/wraithgar)) -* [`e5abf2a21`](https://github.com/npm/cli/commit/e5abf2a2171d95bafc0993f337230d2b6633a6ed) - [#3386](https://github.com/npm/cli/issues/3386) - chore(libnpmdiff): added as workspace - ([@ruyadorno](https://github.com/ruyadorno)) -* [`c6a8734d7`](https://github.com/npm/cli/commit/c6a8734d7d6e4b6d061110a01e45e1d418d56489) - [#3388](https://github.com/npm/cli/issues/3388) - chore(refactor): finish passing npm context - ([@wraithgar](https://github.com/wraithgar)) -* [`d16ee452a`](https://github.com/npm/cli/commit/d16ee452a4a034caada4e9b96faf5c453a658876) - [#3426](https://github.com/npm/cli/issues/3426) - chore(tests): use path.resolve - ([@wraithgar](https://github.com/wraithgar)) - -## DEPENDENCIES - -* [`6b951c042`](https://github.com/npm/cli/commit/6b951c042084e639be929a7ea783c2d85b311bad) - `libnpmversion@1.2.1`: - * fix(retrieve-tag): pass match in a way git accepts -* [`de820a021`](https://github.com/npm/cli/commit/de820a0213f54bbcd155dff25b05d072d5c4a57a) - `npm-package-arg@8.1.5`: - * fix: Make file: URLs (mostly) RFC 8909 compliant -* [`16a95c647`](https://github.com/npm/cli/commit/16a95c64731609c69630c17c45b16edb53ee81b2) - `@npmcli/arborist@2.6.3`: - * fix(inventory) handle old and british forms of 'license' - * fix: removes [_complete] check to apply correct metadata - * ensure node.fsParent is not set to node itself - * fix extraneous deps on load-actual -* [`d341bd86c`](https://github.com/npm/cli/commit/d341bd86ce05fabe44f3be5888ba2611b61914b4) - `make-fetch-happen@9.0.3`: - * fix: implement cache modes correctly -* [`c90612cf5`](https://github.com/npm/cli/commit/c90612cf566d563199553749900d8b05367e2532) - `libnpmexec@2.0.0`: - * use new npxCache option - - -## v7.17.0 (2021-06-10) - -## FEATURES - -* [`ef668ab57`](https://github.com/npm/cli/commit/ef668ab57b15789c6e2971ac39d8ecb3757629fa) - [#3368](https://github.com/npm/cli/issues/3368) - feat(diff): add workspace support - ([@wraithgar](https://github.com/wraithgar)) - -## BUG FIXES - -* [`26d00c477`](https://github.com/npm/cli/commit/26d00c47785dfb300eab6a926f9d7c4d566776b1) - [#3364](https://github.com/npm/cli/issues/3364) - fix(tests): mock writeFile in pack tests so we dont create 0 byte files in the repo - ([@nlf](https://github.com/nlf)) -* [`f130a81d6`](https://github.com/npm/cli/commit/f130a81d62bf4f540ab252a09ff5a618827f9265) - [#3367](https://github.com/npm/cli/issues/3367) - fix(linting): add scripts, docs, smoke-tests - ([@wraithgar](https://github.com/wraithgar)) -* [`992799cd8`](https://github.com/npm/cli/commit/992799cd8c4427ed8c57270b399b2d6bbc94f2a8) - [#3383](https://github.com/npm/cli/issues/3383) - fix(login): properly save scope if defined - ([@wraithgar](https://github.com/wraithgar)) - -## DOCUMENTATION - -* [`844229519`](https://github.com/npm/cli/commit/844229519dd51d0bcafc8c39109a671b6333cf6c) - [#3392](https://github.com/npm/cli/issues/3392) - docs(workspaces): update using npm section - Added examples of using `npm init` to bootstrap a new workspace and a - section on how to add/manage dependencies to workspaces. - ([@ruyadorno](https://github.com/ruyadorno)) - -## DEPENDENCIES - -* [`3654890fb`](https://github.com/npm/cli/commit/3654890fb3be8b57e73f7e6ac4d895017603ca9e) - remove ignored dep - ([@nlf](https://github.com/nlf)) -* [`a4a0e68a9`](https://github.com/npm/cli/commit/a4a0e68a9e34a4c99e10e4fb8c5f89d323a4192f) - [#3362](https://github.com/npm/cli/issues/3362) - check less stuff into node_modules - ([@isaacs](https://github.com/isaacs)) -* [`7d5b049b6`](https://github.com/npm/cli/commit/7d5b049b654f96fc4c49d2f18a19adb4aa0f7d3c) - [#3365](https://github.com/npm/cli/issues/3365) - chore(package) Use a "files" list - ([@isaacs](https://github.com/isaacs)) - -## v7.16.0 (2021-06-03) - -## FEATURES - -* [`e92b5f2ba`](https://github.com/npm/cli/commit/e92b5f2ba07746ae07646566f3dc73c9e004a2fc) - `npm-registry-fetch@11.0.0` - * feat: improved logging of cache status - -## BUG FIXES - -* [`e864bd3ce`](https://github.com/npm/cli/commit/e864bd3ce8e8467e0f8ebb499dc2daf06143bc33) - [#3345](https://github.com/npm/cli/issues/3345) - fix(update-notifier): do not update notify when installing npm@spec - ([@isaacs](https://github.com/isaacs)) -* [`aafe23572`](https://github.com/npm/cli/commit/aafe2357279230e333d3342752a28fce6b9cd152) - [#3348](https://github.com/npm/cli/issues/3348) - fix(update-notifier): parallelize check for updates - ([@isaacs](https://github.com/isaacs)) - -## DOCUMENTATION - -* [`bc9c57dda`](https://github.com/npm/cli/commit/bc9c57dda7cf3abcdee17550205daf1a82e90438) - [#3353](https://github.com/npm/cli/issues/3353) - fix(docs): remove documentation for '--scripts-prepend-node-path' as it was removed in npm@7 - ([@gimli01](https://github.com/gimli01)) -* [`ca2822110`](https://github.com/npm/cli/commit/ca28221103aa0e9ccba7043ac515a541b625c53a) - [#3360](https://github.com/npm/cli/issues/3360) - fix(docs): link foreground-scripts w/ loglevel - ([@wraithgar](https://github.com/wraithgar)) -* [`fb630b5a9`](https://github.com/npm/cli/commit/fb630b5a9af86c71602803297634ec291eeedee0) - [#3342](https://github.com/npm/cli/issues/3342) - chore(docs): manage docs as a workspace - ([@ruyadorno](https://github.com/ruyadorno)) - -## DEPENDENCIES - -* [`54de5c6a4`](https://github.com/npm/cli/commit/54de5c6a4cd593bbbe364132f3f7348586441b31) - `npm-package-arg@8.1.4`: - * fix: trim whitespace from fetchSpec - * fix: handle file: when root directory begins with a special character -* [`e92b5f2ba`](https://github.com/npm/cli/commit/e92b5f2ba07746ae07646566f3dc73c9e004a2fc) - `make-fetch-happen@9.0.1` - * breaking: complete refactor of caching. drops warning headers, - prevents cache indexes from growing for every request, correctly - handles varied requests to the same url, and now caches redirects. - * fix: support url-encoded proxy authorization - * fix: do not lazy-load proxy agents or agentkeepalive. fixes the - intermittent failures to update npm on slower connections. - `npm-registry-fetch@11.0.0` - * breaking: drop handling of deprecated warning headers - * docs: fix header type for npm-command - * docs: update registry param - * feat: improved logging of cache status -* [`23c50a45f`](https://github.com/npm/cli/commit/23c50a45f59ea3ed4c36f35df15e54adc5603034) - `make-fetch-happen@9.0.2`: - * fix: work around negotiator's lazy loading - -## AUTOMATION - -* [`c4ef78b08`](https://github.com/npm/cli/commit/c4ef78b08e6859fc191cabbe58c8d88c070e0612) - [#3344](https://github.com/npm/cli/issues/3344) - fix(automation): update incorrect variable name in create-cli-deps-pr workflow - ([@gimli01](https://github.com/gimli01)) - -## v7.15.1 (2021-05-31) - -### BUG FIXES - -* [`598a17a26`](https://github.com/npm/cli/commit/598a17a2671c9e3bc204dddd6488169c9a72c6a1) - [#3329](https://github.com/npm/cli/issues/3329) - fix(libnpmexec): don't detach output from npm - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`c4fc03e9e`](https://github.com/npm/cli/commit/c4fc03e9eb3a6386e8feacb67c19f0a1578dfe38) - `@npmcli/arborist@2.6.1` - * fixes reifying deps with mismatching version ranges between - actual and virtual trees -* [`9159fa62a`](https://github.com/npm/cli/commit/9159fa62a10dee09daef178fc7be161a02824004) - `libnpmexec@1.2.0` - -## v7.15.0 (2021-05-27) - -### FEATURES - -* [`399ff8cbc`](https://github.com/npm/cli/commit/399ff8cbccd5198f637518ccafa86c43bab47a4a) - [#3312](https://github.com/npm/cli/issues/3312) - feat(link): add workspace support - ([@isaacs](https://github.com/isaacs)) - -### BUG FIXES - -* [`46a9bcbcb`](https://github.com/npm/cli/commit/46a9bcbcb0bb2435dca6f45a61b8631f580c7f06) - [#3282](https://github.com/npm/cli/issues/3282) - fix(docs): proper postinstall script file name - ([@KevinFCormier](https://github.com/KevinFCormier)) -* [`83590d40f`](https://github.com/npm/cli/commit/83590d40f94347f21714dbd158b9ddcad9c82de9) - [#3272](https://github.com/npm/cli/issues/3272) - fix(ls): show relative paths from root - ([@isaacs](https://github.com/isaacs)) -* [`a574b518a`](https://github.com/npm/cli/commit/a574b518ae5b8f0664ed388cf1be6288d8c2e68d) - [#3304](https://github.com/npm/cli/issues/3304) - fix(completion): restore IFS even if `npm completion` returns error - ([@NariyasuHeseri](https://github.com/NariyasuHeseri)) -* [`554e8a5cd`](https://github.com/npm/cli/commit/554e8a5cd7034052a59a9ada31e4b8f73712211a) - [#3311](https://github.com/npm/cli/issues/3311) - set audit exit code properly - ([@isaacs](https://github.com/isaacs)) -* [`4a4fbe33c`](https://github.com/npm/cli/commit/4a4fbe33c51413adcd558b4af6f1e204b1b87e41) - [#3268](https://github.com/npm/cli/issues/3268) - [#3285](https://github.com/npm/cli/issues/3285) - fix(publish): skip private workspaces - ([@ruyadorno](https://github.com/ruyadorno)) - -### DOCUMENTATION - -* [`3c53d631f`](https://github.com/npm/cli/commit/3c53d631f557cf2484e2f6a6172c44e36aea4817) - [#3307](https://github.com/npm/cli/issues/3307) - fix(docs): typo in package-lock.json docs - ([@rethab](https://github.com/rethab)) -* [`96367f93f`](https://github.com/npm/cli/commit/96367f93f46c24494d084c8b8d34e4de9cd375da) - rebuild npm-pack doc - ([@isaacs](https://github.com/isaacs)) -* [`64b13dd10`](https://github.com/npm/cli/commit/64b13dd1082b6ca7eac4e8e329bfdd8cd8daf157) - [#3313](https://github.com/npm/cli/issues/3313) - Drop stale Python 3<->node-gyp remark - ([@spencerwilson](https://github.com/spencerwilson)) - -### DEPENDENCIES - -* [`7b56bfdf3`](https://github.com/npm/cli/commit/7b56bfdf3f2ac67a926fc7893b883a16b46eb3fd) - `cacache@15.2.0`: - * feat: allow fully deleting indices - * feat: add a validateEntry option to compact - * chore: lint - * chore: use standard npm style release scripts -* [`dbbc151a3`](https://github.com/npm/cli/commit/dbbc151a3bcf89e2627dc267063edd185ead1cb8) - `npm-audit-report@2.1.5`: - * fix(exit-code): account for null auditLevel default (#46) -* [`5b2604507`](https://github.com/npm/cli/commit/5b26045076477d3d350f539e60adf48a80376fda) - chore(package-lock): update devDependencies - ([@Gar](https://github.com/Gar)) - -### AUTOMATION - -* [`3d5df0082`](https://github.com/npm/cli/commit/3d5df0082ae904dacdea8644286e8362d4a2ed50) - [#3294](https://github.com/npm/cli/issues/3294) - chore(ci): move node release PR workflow to cli repo - ([@gimli01](https://github.com/gimli01)) - -## v7.14.0 (2021-05-20) - -### FEATURES - -* [`0d1a9d787`](https://github.com/npm/cli/commit/0d1a9d78779dc015242fc03d2dad2039004fa2df) - [#3227](https://github.com/npm/cli/issues/3227) - feat(install): add workspaces support to npm install commands - ([@isaacs](https://github.com/isaacs)) -* [`c18626f04`](https://github.com/npm/cli/commit/c18626f047e3a0fedd3c86554a4a0a8f27925e77) - [#3250](https://github.com/npm/cli/issues/3250) - feat(ls): add workspaces support - ([@ruyadorno](https://github.com/ruyadorno)) -* [`41099d395`](https://github.com/npm/cli/commit/41099d3958d08f166313b7eb69b76458f8f9224c) - [#3265](https://github.com/npm/cli/issues/3265) - feat(explain): add workspaces support - ([@ruyadorno](https://github.com/ruyadorno)) -* [`fde354669`](https://github.com/npm/cli/commit/fde35466915b5ac5958c827fa7e919e1f186db51) - [#3251](https://github.com/npm/cli/issues/3251) - feat(unpublish): add workspace/dry-run support - ([@wraithgar](https://github.com/wraithgar)) -* [`83df3666c`](https://github.com/npm/cli/commit/83df3666cd82819230fb45f2a40afd531fe3b3c7) - [#3260](https://github.com/npm/cli/issues/3260) - feat(outdated): add workspaces support - ([@ruyadorno](https://github.com/ruyadorno)) -* [`63a7635f7`](https://github.com/npm/cli/commit/63a7635f7a2225a4edd1fe92f94a563965ac06c7) - [#3217](https://github.com/npm/cli/issues/3217) - feat(pack): add support to json config/output - ([@mrmlnc](https://github.com/mrmlnc)) - -### BUG FIXES - -* [`faa12ccc2`](https://github.com/npm/cli/commit/faa12ccc26b5f0790f79b2589780e536f4284491) - [#3253](https://github.com/npm/cli/issues/3253) - fix search description typos - ([@juanpicado](https://github.com/juanpicado)) -* [`2f5c28a68`](https://github.com/npm/cli/commit/2f5c28a68719e948d2efedf463ebcb35972aaefb) - [#3243](https://github.com/npm/cli/issues/3243) - fix(docs): autogenerate config docs for commands - ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES - -* [`ec256a14a`](https://github.com/npm/cli/commit/ec256a14aa6eb2bd59fd55dcc6a4bc0148662c4e) - `@npmcli/arborist@2.6.0` -* [`5f15aba86`](https://github.com/npm/cli/commit/5f15aba866026e7c0d6844e6c07a528dc7454f14) - `cacache@15.1.0` -* [`b3add87e6`](https://github.com/npm/cli/commit/b3add87e686968b7af3067c685d2561baf90e397) - [#3262](https://github.com/npm/cli/pull/3262) - `npm-registry-client@10.1.2`: - * fixed sso login token - -## v7.13.0 (2021-05-13) - -### FEATURES - -* [`076420c14`](https://github.com/npm/cli/commit/076420c149d097056f687e44e21744b743b86e4e) - [#3231](https://github.com/npm/cli/issues/3231) - feat(publish): add workspace support - ([@wraithgar](https://github.com/wraithgar)) -* [`370b36a36`](https://github.com/npm/cli/commit/370b36a36ca226840761e4214cbccaf2a1a90e3c) - [#3241](https://github.com/npm/cli/issues/3241) - feat(fund): add workspaces support - ([@ruyadorno](https://github.com/ruyadorno)) - -### DEPENDENCIES - -* [`0c18e4f77`](https://github.com/npm/cli/commit/0c18e4f774562fa054fedf323bea25805ebf39b3) - `@npmcli/arborist@2.5.0` -* [`b551c6811`](https://github.com/npm/cli/commit/b551c6811251dbc901f47fea3c137f93e205a9e4) - `libnpmfund@1.1.0` - -## v7.12.1 (2021-05-10) - -### BUG FIXES - -* [`de49f58f5`](https://github.com/npm/cli/commit/de49f58f55dc2ac3a5057cd492a43c32ae41381e) - [#3216](https://github.com/npm/cli/issues/3216) - fix(contributing): link to proper cli repo - ([@mrmlnc](https://github.com/mrmlnc)) -* [`1d092144e`](https://github.com/npm/cli/commit/1d092144eaaabff63ac8424b40b2286822be7677) - [#3203](https://github.com/npm/cli/issues/3203) - fix(packages): locale-agnostic string sorting - ([@isaacs](https://github.com/isaacs)) -* [`0696fca13`](https://github.com/npm/cli/commit/0696fca13d10726e04ca97ff50eef7bd7455a3ab) - [#3209](https://github.com/npm/cli/issues/3209) - fix(view): fix non-registry specs - ([@wraithgar](https://github.com/wraithgar)) -* [`71ac93597`](https://github.com/npm/cli/commit/71ac935976390e4fd05987ff510049f82bc6e2a9) - [#3206](https://github.com/npm/cli/issues/3206) - chore(github): Convert md issue template to yaml - ([@lukehefson](https://github.com/lukehefson)) -* [`6fb386d3b`](https://github.com/npm/cli/commit/6fb386d3bfbaa8e4771ff87a08de1f3aa6f9b34d) - [#3201](https://github.com/npm/cli/issues/3201) - fix(tests): increase test fuzziness - ([@wraithgar](https://github.com/wraithgar)) -* [`f3a662fcd`](https://github.com/npm/cli/commit/f3a662fcd869653f9753aef3d40cc96ed28ed509) - [#3211](https://github.com/npm/cli/issues/3211) - fix(tests): use config defaults - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`285976fd1`](https://github.com/npm/cli/commit/285976fd12f037f59da47307d98df7ebda5278d9) - `@npmcli/arborist@2.4.4` - * fix(reify): properly save spec if prerelease -* [`f9f24d17c`](https://github.com/npm/cli/commit/f9f24d17c29c421de3c9b82c6b98a40268aeb920) - `libnpmexec@1.1.1` - * fix(add): Specify 'en' locale to String.localeCompare -* [`cb9f17499`](https://github.com/npm/cli/commit/cb9f174996dbb4779a1be82890564f9abffb11f4) - `glob@7.1.7` - * force 'en' locale in string sorting -* [`24b4e4a41`](https://github.com/npm/cli/commit/24b4e4a41b451db3de381fac6b719149db14c288) - `ignore-walk@3.0.4` - * Avoid locale-specific sorting issues -* [`1eb7e5c7d`](https://github.com/npm/cli/commit/1eb7e5c7d466293b472c2506c64e5a89ec84ac2f) - `@npmcli/arborist@2.4.3` - * guard against locale-specific sorting -* [`a6a826067`](https://github.com/npm/cli/commit/a6a826067cb46c711521772c2d0158257d54400a) - `npm-packlist@2.2.2`: - * fix(sort): avoid locale-dependent sorting issues - -## v7.12.0 (2021-05-06) - -### FEATURES - -* [`701627c51`](https://github.com/npm/cli/commit/701627c5169934e59da2959d76a49c77278cc9dc) - [#3098](https://github.com/npm/cli/issues/3098) - feat(cache): Allow `add` to accept multiple specs - ([@mjsir911](https://github.com/mjsir911)) -* [`59171f030`](https://github.com/npm/cli/commit/59171f0304f048a009f1697eec6f74f778bc52ff) - [#3187](https://github.com/npm/cli/issues/3187) - feat(config): add workspaces boolean to user-agent - ([@nlf](https://github.com/nlf)) - -### BUG FIXES - -* [`2c9b8713c`](https://github.com/npm/cli/commit/2c9b8713c4c88fbd0c3c48eb0de84dbd7269398f) - [#3182](https://github.com/npm/cli/issues/3182) - fix(docs): fix broken links - ([@wangsai](https://github.com/wangsai)) -* [`88cbc8c44`](https://github.com/npm/cli/commit/88cbc8c447cbaef20b5a8f19246211ce4918f4d8) - [#3198](https://github.com/npm/cli/issues/3198) - fix(tests): reflect new libnpmexec logic - -### DEPENDENCIES - -* [`d01ce5e13`](https://github.com/npm/cli/commit/d01ce5e132cb4661698012fd5017753c2bdb660b) - `libnpmexec@1.1.0`: - * feat: add walk up dir lookup to satisfy local bins -* [`81c1dfaaa`](https://github.com/npm/cli/commit/81c1dfaaaf918229316a975aa8075769ffafdb6d) - `@npmcli/arborist@2.4.2`: - * fix(add): save packages in the right place - * fix(reify): do not clean up nodes with no parent - * fix(audit): support alias specs & root package names -* [`87c2303ea`](https://github.com/npm/cli/commit/87c2303eaa6edfa5309da0a30f5ad291b6d57640) - `@npmcli/git@2.0.9`: - * fix(clone): Do not allow git replacement objects by default -* [`99ff40dff`](https://github.com/npm/cli/commit/99ff40dff5e5e55a5d5f045ba90e76c08174ca38) - `npm-packlist@2.2.0`: - * feat(npmignore): Do not force include history, changelogs, notice - * fix(package.json): add missing bin/index.js to files - -## v7.11.2 (2021-04-29) - -### BUG FIXES - -* [`c371f183e`](https://github.com/npm/cli/commit/c371f183ebe833c2439e98b679f14e7a59f22c34) - [#3137](https://github.com/npm/cli/issues/3137) - [#3140](https://github.com/npm/cli/issues/3140) - fix(ls): do not warn on missing optional deps - ([@isaacs](https://github.com/isaacs)) -* [`861f606c7`](https://github.com/npm/cli/commit/861f606c7609d177c644814a171581afbb72f6db) - [#3156](https://github.com/npm/cli/issues/3156) - fix(build): make prune rule work on case-sensitive file systems - ([@lpinca](https://github.com/lpinca)) - -### DEPENDENCIES - -* [`fb79d89a0`](https://github.com/npm/cli/commit/fb79d89a07ef03e76633db275463f701d3dae42f) - `tap@15.0.6` -* [`ce3820043`](https://github.com/npm/cli/commit/ce38200437e9ed527df973794909b2699909bc9b) - `@npmcli/arborist@2.4.1` - * fix: prevent and eliminate unnecessary duplicates - * fix: support resolvable partial intersecting peerSets - -### DOCUMENTATION - -* [`e479f1dac`](https://github.com/npm/cli/commit/e479f1dac9a7639304d20116583034861635b2b1) - [#3146](https://github.com/npm/cli/issues/3146) - mention `directories.bin` in `bin` - ([@felipecrs](https://github.com/felipecrs)) - -## v7.11.1 (2021-04-23) - -### DEPENDENCIES - -* [`7925cca24`](https://github.com/npm/cli/commit/7925cca24543d9e1a8297844b3e53e11057643ef) - `pacote@11.3.3`: - * fix(registry): normalize manfest -* [`b61eac693`](https://github.com/npm/cli/commit/b61eac693df82c52b955e6c18ec4dcf4cedea8a3) - [#3130](https://github.com/npm/cli/issues/3130) - `@npmcli/config@2.2.0` -* [`c74e67fc6`](https://github.com/npm/cli/commit/c74e67fc6572bb001d74c7486c05d211a0e03de8) - [#3130](https://github.com/npm/cli/issues/3130) - `npm-registry-fetch@10.1.1` - -### DOCUMENTATION - -* [`efdd7dd44`](https://github.com/npm/cli/commit/efdd7dd4427a0ee856c18aab1df2d3d30a307997) - Remove unused and incorrectly documented `--always-auth` config definition - ([@isaacs](https://github.com/isaacs)) - -## v7.11.0 (2021-04-22) - -### FEATURES - -* [`4c1f16d2c`](https://github.com/npm/cli/commit/4c1f16d2c29a7a56c19b97f2820e6305a6075083) - [#3095](https://github.com/npm/cli/issues/3095) - feat(init): add workspaces support - ([@ruyadorno](https://github.com/ruyadorno)) - -### BUG FIXES - -* [`42ca59eee`](https://github.com/npm/cli/commit/42ca59eeedd3e402aa1c606941f7f52864e6039b) - [#3086](https://github.com/npm/cli/issues/3086) - fix(ls): do not exit with error when all problems are extraneous deps - ([@nlf](https://github.com/nlf)) -* [`2aecec591`](https://github.com/npm/cli/commit/2aecec591df6866e27d0b17dc49cef8f7d738d77) - [#2724](https://github.com/npm/cli/issues/2724) - [#3119](https://github.com/npm/cli/issues/3119) - fix(ls): make --long work when missing deps - ([@ruyadorno](https://github.com/ruyadorno)) -* [`42e0587a9`](https://github.com/npm/cli/commit/42e0587a9ea6940a5d5be5903370ad1113feef21) - [#3115](https://github.com/npm/cli/issues/3115) - fix(pack): refuse to pack invalid packument - ([@wraithgar](https://github.com/wraithgar)) -* [`1c4eff7b5`](https://github.com/npm/cli/commit/1c4eff7b513b8e84876818ede014d3ab19d203c6) - [#3126](https://github.com/npm/cli/issues/3126) - fix(logout): use isBasicAuth attribute - ([@wraithgar](https://github.com/wraithgar)) - -### DOCUMENTATION - -* [`c93f1c39e`](https://github.com/npm/cli/commit/c93f1c39e326feff0857712a10ef6183fbafe1ab) - [#3101](https://github.com/npm/cli/issues/3101) - chore(docs): update view docs - ([@wraithgar](https://github.com/wraithgar)) -* [`c4ff4bc11`](https://github.com/npm/cli/commit/c4ff4bc113c3a5b6ee5d74ab0b1adee95169ed32) - [npm/statusboard#313](https://github.com/npm/statusboard/issues/313) - [#3109](https://github.com/npm/cli/issues/3109) - fix(usage): fix refs to ws shorthand - ([@ruyadorno](https://github.com/ruyadorno)) - -### DEPENDENCIES - -* [`83166ebcc`](https://github.com/npm/cli/commit/83166ebcc4ba5e3bf215f08151437d96637f4f33) - `npm-registry-fetch@10.1.0` - * feat(auth): set isBasicAuth -* [`e02bda6da`](https://github.com/npm/cli/commit/e02bda6da68b8e8f490bf270cb5d6adec81685ea) - `npm-registry-fetch@10.0.0` - * feat(auth) load/send based on URI, not registry -* [`a0382deba`](https://github.com/npm/cli/commit/a0382deba346b09834e75db89e1fd4527f1f07dd) - `@npmcli/run-script@1.8.5` - * fix: windows ComSpec env variable name -* [`7f82ef5a8`](https://github.com/npm/cli/commit/7f82ef5a84d70e28983ed43ba1d8aced0fb4ba45) - `pacote@11.3.2` -* [`35e49b94f`](https://github.com/npm/cli/commit/35e49b94fba478a63df6cc9b62816eafe5f1fbdd) - `@npmcli/arborist@2.4.0` -* [`95faf8ce6`](https://github.com/npm/cli/commit/95faf8ce6c007082a02c160977da194c08ee9d82) - `libnpmaccess@4.0.2` -* [`17fffc0e4`](https://github.com/npm/cli/commit/17fffc0e42b2a9e7b84691093e45ba511906cbfa) - `libnpmhook@6.0.2` -* [`1b5a213aa`](https://github.com/npm/cli/commit/1b5a213aaf39652661ba72ba2e8751f049b170fb) - `libnpmorg@2.0.2` -* [`9f83e6484`](https://github.com/npm/cli/commit/9f83e6484aa163d066f318df42ec89c8234b614e) - `libnpmpublish@4.0.1` -* [`251f788c5`](https://github.com/npm/cli/commit/251f788c554a198ab42682453fa5504f8abe93fe) - `libnpmsearch@3.1.1` -* [`35873a989`](https://github.com/npm/cli/commit/35873a989fe67041ddcf30a0a278ed77ace5ee3c) - `libnpmteam@2.0.3` -* [`23e12b4d8`](https://github.com/npm/cli/commit/23e12b4d8f63d765a48036e7bb08f53319c73304) - `npm-profile@5.0.3` - -## v7.10.0 (2021-04-15) - -### FEATURES - -* [`f9b639eb6`](https://github.com/npm/cli/commit/f9b639eb6c504ded6cdd59e83e26a392bfe81e5d) - [#3052](https://github.com/npm/cli/issues/3052) - feat(bugs): fall back to email if provided - ([@Yash-Singh1](https://github.com/Yash-Singh1)) -* [`8c9e24778`](https://github.com/npm/cli/commit/8c9e24778db867cb3148bc247c7e321639aa9f58) - [#3055](https://github.com/npm/cli/issues/3055) - feat(version): add workspace support - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`f1e6743a6`](https://github.com/npm/cli/commit/f1e6743a6e8e32ddad6d1964eb05d17e6c50a456) - `libnpmversion@1.2.0` - * feat(retrieve-tag): retrieve unannotated git tags - * fix(retrieve-tag): use semver to look for semver -* [`3b476a24c`](https://github.com/npm/cli/commit/3b476a24cf0b2823fdf92505b84bddde4fcc8b14) - `@npmcl/git@2.0.8` - * fix(git): do not use shell when calling git -* [`dfcd0c1e2`](https://github.com/npm/cli/commit/dfcd0c1e2331c1f4b6573466b50505772eddaf22) - [#3069](https://github.com/npm/cli/issues/3069) - `tap@15.0.2` - -### DOCUMENTATION - -* [`90b61eda9`](https://github.com/npm/cli/commit/90b61eda9b41af108ed69fc0c43a522a92745047) - [#3053](https://github.com/npm/cli/issues/3053) - fix(contributing.md): explicitely outline dep updates - ([@darcyclarke](https://github.com/darcyclarke)) - -## v7.9.0 (2021-04-08) - -### FEATURES - -* [`1f3e88eba`](https://github.com/npm/cli/commit/1f3e88ebaf4901d8f9f07b43404d824fef7e5ff5) - [#3032](https://github.com/npm/cli/issues/3032) - feat(dist-tag): add workspace support - ([@nlf](https://github.com/nlf)) -* [`6e31df4e7`](https://github.com/npm/cli/commit/6e31df4e7957337962fd3d93e495931e3592bb9e) - [#3033](https://github.com/npm/cli/issues/3033) - feat(pack): add workspace support - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`ba4f7fea8`](https://github.com/npm/cli/commit/ba4f7fea8fca8e3509469a218f094fe69095888b) - `licensee@8.2.0` - -## v7.8.0 (2021-04-01) - -### FEATURES - - -* [`8bcc5d73f`](https://github.com/npm/cli/commit/8bcc5d73f35434e781ff56419dd7f0c380efd072) - [#2972](https://github.com/npm/cli/issues/2972) - feat(workspaces): add repo and docs - ([@wraithgar](https://github.com/wraithgar)) -* [`ec520ce32`](https://github.com/npm/cli/commit/ec520ce32d5e834a32ebd58491df4200e01ce690) - [#2998](https://github.com/npm/cli/issues/2998) - feat(set-script): implement workspaces -* [`32717a60e`](https://github.com/npm/cli/commit/32717a60eb55fcf8c7e5016223bfee78a6daba0e) - [#3001](https://github.com/npm/cli/issues/3001) - feat(view): add workspace support - ([@wraithgar](https://github.com/wraithgar)) -* [`7b177e43f`](https://github.com/npm/cli/commit/7b177e43f3bfb558bcd8723cdb2166a3df19647a) - [#3014](https://github.com/npm/cli/issues/3014) - feat(config): add 'envExport' flag - ([@isaacs](https://github.com/isaacs)) - -### BUG FIXES - -* [`4c4252348`](https://github.com/npm/cli/commit/4c4252348c538246e1072421d65f4558dc948080) - [#3016](https://github.com/npm/cli/issues/3016) - fix(usage): specify the key each time for multiples - ([@isaacs](https://github.com/isaacs)) -* [`9237d375b`](https://github.com/npm/cli/commit/9237d375b0b7d34c7dc5ba70aec7f616f4133732) - [#3013](https://github.com/npm/cli/issues/3013) - fix(docs): add workspaces configuration - ([@wraithgar](https://github.com/wraithgar)) -* [`cb6eb0d20`](https://github.com/npm/cli/commit/cb6eb0d206b7e2f63d5c7a7a17bea4aed1b9f2bf) - [#3015](https://github.com/npm/cli/issues/3015) - fix(ERESOLVE): better errors when current is missing - ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES - -* [`61da39beb`](https://github.com/npm/cli/commit/61da39beb5373320e2b591b61ecd6596eeaba6ed) - `@npmcli/config@2.1.0` - * feat(config): add support for envExport:false -* [`fb095a708`](https://github.com/npm/cli/commit/fb095a708a1f930bbd0195446ac611b82bfeff14) - `@npmcli/arborist@2.3.0`: - * [#2896](https://github.com/npm/cli/issues/2896) Provide currentEdge in - ERESOLVE if known, and address self-linking edge case. - * Add/remove dependencies to/from workspaces when set, not root project - * Only reify the portions of the dependency graph identified by the - `workspace` configuration value. - * Do not recursively `chown` the project root path. - -## v7.7.6 (2021-03-29) - -### BUG FIXES - -* [`9dd2ed518`](https://github.com/npm/cli/commit/9dd2ed5189b6f283094664e9e192cf1598ec3f79) - fix empty newline printed to stderr - ([@ruyadorno](https://github.com/ruyadorno)) -* [`9d391462a`](https://github.com/npm/cli/commit/9d391462a25f637219501e2430ef1f7b89710816) - [#2973](https://github.com/npm/cli/issues/2973) - fix spelling in workspaces.md file - ([@sethomas](https://github.com/sethomas)) -* [`4b100249a`](https://github.com/npm/cli/commit/4b100249a6cad67e002186816e64817313b636c7) - [#2979](https://github.com/npm/cli/issues/2979) - change 'maxsockets' default value back to 15 - ([@wallrat](https://github.com/wallrat)) - -### DEPENDENCIES - -* [`a28f89572`](https://github.com/npm/cli/commit/a28f89572a708cced69cc938f877eaa969dbad9e) - `libnpmversion@1.1.0` - * fix reading `script-shell` config on `npm version` lifecycle scripts -* [`03734c29e`](https://github.com/npm/cli/commit/03734c29e00191d17f164d1c0e75d9f228268842) - `npm-packlist@2.1.5` - * fix packaging `bundledDependencies` -* [`80ce2a019`](https://github.com/npm/cli/commit/80ce2a019526632b01b70e1c75c42608dc160332) - `@npmcli/metavuln-calculator@1.1.1` - * fix error auditing package documents with missing dependencies - -## v7.7.5 (2021-03-25) - -### BUG FIXES - -* [`95ba87622`](https://github.com/npm/cli/commit/95ba87622e00d68270eda9e071b19737718fca16) - [#2949](https://github.com/npm/cli/issues/2949) - fix handling manual indexes in `npm help` - ([@dmchurch](https://github.com/dmchurch)) -* [`59cf37962`](https://github.com/npm/cli/commit/59cf37962a2286e0f7d3bd37fa9c8bc3bac94218) - [#2958](https://github.com/npm/cli/issues/2958) - always set `npm.command` to canonical command name - ([@isaacs](https://github.com/isaacs)) -* [`1415b4bde`](https://github.com/npm/cli/commit/1415b4bdeeaabb6e0ba12b6b1b0cc56502bd64ab) - [#2964](https://github.com/npm/cli/issues/2964) - fix(config): properly translate user-agent - ([@wraithgar](https://github.com/wraithgar)) -* [`59271936d`](https://github.com/npm/cli/commit/59271936d90fbd6956a41967119f578c0ba63db9) - [#2965](https://github.com/npm/cli/issues/2965) - fix(config): tie save-exact/save-prefix together - ([@wraithgar](https://github.com/wraithgar)) - -### TESTS - -* [`97b415287`](https://github.com/npm/cli/commit/97b41528739460b2e9e72e09000aded412418cb2) - [#2959](https://github.com/npm/cli/issues/2959) - add smoke tests - ([@ruyadorno](https://github.com/ruyadorno)) - -## v7.7.4 (2021-03-24) - -### BUG FIXES - -* [`200bee74b`](https://github.com/npm/cli/commit/200bee74b31a738687446b7b535cac67b1c582fd) - [#2951](https://github.com/npm/cli/issues/2951) - fix(config): accept explicit `production=false` - ([@wraithgar](https://github.com/wraithgar)) -* [`7b45e9df6`](https://github.com/npm/cli/commit/7b45e9df6102c7bd6e403d1fdc9939581c38f546) - [#2950](https://github.com/npm/cli/issues/2950) - warn if using workspaces config options in `npm config` - ([@ruyadorno](https://github.com/ruyadorno)) - -## v7.7.3 (2021-03-24) - -### BUG FIXES - -* [`c76f04ac2`](https://github.com/npm/cli/commit/c76f04ac28ddf2ae4df4b3ce0aec684a118de1b5) - [#2925](https://github.com/npm/cli/issues/2925) - fix(set-script): add completion - ([@Yash-Singh1](https://github.com/Yash-Singh1)) -* [`0379eab69`](https://github.com/npm/cli/commit/0379eab698b78ae4aa89bbe2043607f420e52f11) - [#2929](https://github.com/npm/cli/issues/2929) - fix(install): ignore auditLevel - `npm install` should not be affected by the `auditLevel` config, as the - results of audit do not change its exit status. - ([@wraithgar](https://github.com/wraithgar)) -* [`98efadeb4`](https://github.com/npm/cli/commit/98efadeb4b2ae9289f14ed6f42a169230faf7239) - [#2923](https://github.com/npm/cli/issues/2923) - fix(audit-level): add `info` audit level - This is a valid level but wasn't configured to be allowed. - Also added this param to the usage output for `npm audit` - ([@wraithgar](https://github.com/wraithgar)) -* [`e8d2adcf4`](https://github.com/npm/cli/commit/e8d2adcf40ad63030f844c9aa44c6d16e2146797) - [#2945](https://github.com/npm/cli/issues/2945) - config should not error when workspaces are configured - ([@nlf](https://github.com/nlf)) -* [`aba2bc623`](https://github.com/npm/cli/commit/aba2bc623ea99e563b1b15b81dbb4ba94f86fe4c) - [#2944](https://github.com/npm/cli/issues/2944) - fix(progress): re-add progress bar to reify - The logger was no longer in flatOptions, we pass it in explicitly now - ([@wraithgar](https://github.com/wraithgar)) -* [`877b4ed29`](https://github.com/npm/cli/commit/877b4ed2925c97b5249a4d33575420dda64f7339) - [#2946](https://github.com/npm/cli/issues/2946) - fix(flatOptions): re-add `_auth` - This was not being added to flatOptions, and things like - `npm-registry-fetch` are looking for it. - ([@wraithgar](https://github.com/wraithgar)) - -## v7.7.2 (2021-03-24) - -### BUG FIXES -* [`a4df2b98d`](https://github.com/npm/cli/commit/a4df2b98d89429b19cd29b5fc895cdbfc0a6bd78) - [#2942](https://github.com/npm/cli/issues/2942) - Restore --dev flag, unify --omit flatteners - ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES -* [`2cbfaac0e`](https://github.com/npm/cli/commit/2cbfaac0ecd5810316f6d76168ed9618bd11bf3a) - `hosted-git-info@4.0.2` - * [#83](https://github.com/npm/hosted-git-info/pull/83) Do not parse - urls for gitlab - ([@nlf](https://github.com/nlf)) - -## v7.7.1 (2021-03-24) - -### BUG FIXES - -* [`543b0e39b`](https://github.com/npm/cli/commit/543b0e39bcb94fc408804b01ca9c0d7b960b2681) - [#2930](https://github.com/npm/cli/issues/2930) - fix(uninstall): use correct local prefix - ([@jameschensmith](https://github.com/jameschensmith)) -* [`dce4960ef`](https://github.com/npm/cli/commit/dce4960ef6d52af128affe7755b2ca72de913b6c) - [#2932](https://github.com/npm/cli/issues/2932) - fix(config): flatten savePrefix properly - ([@wraithgar](https://github.com/wraithgar)) - -## v7.7.0 (2021-03-23) - -### FEATURES - -* [`33c4189f9`](https://github.com/npm/cli/commit/33c4189f939aebdfaf85ea419e6ea01d0977b79d) - [#2864](https://github.com/npm/cli/issues/2864) - add `npm run-script` workspaces support - ([@ruyadorno](https://github.com/ruyadorno)) -* [`e1b3b318f`](https://github.com/npm/cli/commit/e1b3b318f095a7e1a7cc4b131907de4955275d9d) - [#2886](https://github.com/npm/cli/issues/2886) - add `npm exec` workspaces support - ([@ruyadorno](https://github.com/ruyadorno)) -* [`41facf643`](https://github.com/npm/cli/commit/41facf6435ced4e416d74111d9c3ff00ee19ab7d) - [#2859](https://github.com/npm/cli/issues/2859) - expanded "Did you mean?" suggestions for missing cmds and scripts - ([@wraithgar](https://github.com/wraithgar)) - -### BUG FIXES - -* [`8cce4282f`](https://github.com/npm/cli/commit/8cce4282f7bef11aeeb73cffd532b477b241985e) - [#2865](https://github.com/npm/cli/issues/2865) - `npm publish`: handle case where multiple config list is present - ([@kenrick95](https://github.com/kenrick95)) -* [`6598bfe86`](https://github.com/npm/cli/commit/6598bfe8697439e827d84981f8504febca64a55a) - mark deprecated configs - ([@isaacs](https://github.com/isaacs)) -* [`8a38afe77`](https://github.com/npm/cli/commit/8a38afe779ce71a10178ed62b13709d06adf7a66) - [#2881](https://github.com/npm/cli/issues/2881) - docs(package-json): document default main behavior - ([@klausbayrhammer](https://github.com/klausbayrhammer)) -* [`93a061d73`](https://github.com/npm/cli/commit/93a061d737dc769663652368e8586e4202267b9e) - [#2917](https://github.com/npm/cli/issues/2917) - add action items to `npm run` error output - ([@wraithgar](https://github.com/wraithgar)) - -### DOCUMENTATION - -* [`ad65bd910`](https://github.com/npm/cli/commit/ad65bd9101aa8e8b94bc1e48df3ef93deca6d30c) - [#2860](https://github.com/npm/cli/issues/2860) - fix link in configuring-npm - ([@varmakarthik12](https://github.com/varmakarthik12)) -* [`b419bfb02`](https://github.com/npm/cli/commit/b419bfb0259596fb338d45b2eaeab25a7a0d1f1e) - [#2876](https://github.com/npm/cli/issues/2876) - fix test-coverage command in contributing guide - ([@chowkapow](https://github.com/chowkapow)) - -### DEPENDENCIES - -* [`7b5606b93`](https://github.com/npm/cli/commit/7b5606b931083e8a70f5ea094c2b46f0b7a38a18) - `@npmcli/arborist@2.2.9` - * [#254](https://github.com/npm/arborist/pull/254) Honor explicit - prefix when saving dependencies - ([@jameschensmith](https://github.com/jameschensmith)) - * [#255](https://github.com/npm/arborist/pull/255) Never save to - `bundleDependencies` when saving a `peer` or `peerOptional` - dependency. ([@isaacs](https://github.com/isaacs)) -* [`f76e7c21f`](https://github.com/npm/cli/commit/f76e7c21ffd87b08593d8c396a78ab9c5fa790bd) - `pacote@11.3.1` - * increases tarball compression level -* [`4928512bc`](https://github.com/npm/cli/commit/4928512bcefd8448ff5852978cfc7f903e3ae996) - `semver@7.3.5` - * fix handling prereleases/ANY ranges in subset -* [`1924eb457`](https://github.com/npm/cli/commit/1924eb457aea7c93dfaf4a911355a63d84d66eee) - `libnpmversion@1.0.12` - * fix removing undescored-prefixed package.json properties in `npm version` -* [`916623056`](https://github.com/npm/cli/commit/91662305643509eebd2f79ed7e3ff01562aa4968) - `@npmcli/run-script@1.8.4` - * fix expanding windows-style environment variables -* [`a8d0751e4`](https://github.com/npm/cli/commit/a8d0751e4b7c7d8b808c8a49f288fc7272f729b0) - `npm-pick-manifest@6.1.1` - * fix running packages with a single executable binary with `npm exec` -* [`af7eaac50`](https://github.com/npm/cli/commit/af7eaac5018ed821d72d43d08f1d7e49e7491453) - `hosted-git-info@4.0.1` -* [`f52c51db1`](https://github.com/npm/cli/commit/f52c51db13c39cfbaed18dbd13ba7302a4b6a0d9) - `@npmcli/config@2.0.0` - -## v7.6.3 (2021-03-11) - -### DOCUMENTATION - -* [`8c44e999b`](https://github.com/npm/cli/commit/8c44e999bdf7639893535c55beebf7996da2c47f) - [#2855](https://github.com/npm/cli/issues/2855) - Correct "npm COMMAND help" to "npm help COMMAND" - ([@dwardu](https://github.com/dwardu)) - -### DEPENDENCIES - -* [`57ed390d6`](https://github.com/npm/cli/commit/57ed390d64a44ae0a1b2c4afd79d690170b194ec) - `@npmcli/arborist@2.2.8` - * Respect link deps when calculating peerDep sets - -## v7.6.2 (2021-03-09) - -### BUG FIXES - -* [`e0a3a5218`](https://github.com/npm/cli/commit/e0a3a5218cac7ca5850930aaaad8a939ddf75d4d) - [#2831](https://github.com/npm/cli/issues/2831) - Fix cb() never called in search with --json option - ([@fraqe](https://github.com/fraqe)) -* [`85a8694dd`](https://github.com/npm/cli/commit/85a8694dd9b4a924a474ba75261914511a216868) - [#2795](https://github.com/npm/cli/issues/2795) - fix(npm.output): make output go through npm.output - ([@wraithgar](https://github.com/wraithgar)) -* [`9fe0df5b5`](https://github.com/npm/cli/commit/9fe0df5b5d7606e5841288d9931be6c04767c9ca) - [#2821](https://github.com/npm/cli/issues/2821) - fix(usage): clean up usage declarations - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`7f470b5c2`](https://github.com/npm/cli/commit/7f470b5c25d544e36d97b28e28ae20dfa1d4ab31) - `@npmcli/arborist@2.2.7` - * fix(install): Do not revert a file: dep to version on bare name re-install -* [`e9b7fc275`](https://github.com/npm/cli/commit/e9b7fc275a0bdf8f00dbcf5dd2283675776fc459) - `libnpmdiff@2.0.4` - * fix(diff): Gracefully handle packages with prepare script -* [`c7314aa62`](https://github.com/npm/cli/commit/c7314aa62195b7f0d8886776692e8a2c892413ed) - `byte-size@7.0.1` -* [`864f48d43`](https://github.com/npm/cli/commit/864f48d4327269f521161cf89888ea2b6db5fdab) - `pacote@11.3.0` - -## v7.6.1 (2021-03-04) - -### BUG FIXES - -* [`3c9a589b0`](https://github.com/npm/cli/commit/3c9a589b004fa828a304abaf52d1d781710e1143) - [#2807](https://github.com/npm/cli/issues/2807) - `npm explain` show when an edge is a bundled edge - ([@kumavis](https://github.com/kumavis)) -* [`b33c760ce`](https://github.com/npm/cli/commit/b33c760cea7fe2696d35b5530abc1b455980fef1) - [#2766](https://github.com/npm/cli/issues/2766) - unused arguments cleanup - ([@sandersn](https://github.com/sandersn)) -* [`4a5dd3a5a`](https://github.com/npm/cli/commit/4a5dd3a5a200b3f4f7b47168497d8e03dca3a2ca) - [#2772](https://github.com/npm/cli/issues/2772) - fix(npm) pass npm context everywhere - ([@wraithgar](https://github.com/wraithgar)) -* [`e69be2ac5`](https://github.com/npm/cli/commit/e69be2ac5c35e985732e2baa00b70d39332e4b9f) - [#2789](https://github.com/npm/cli/issues/2789) - fix npm prefix on all Windows unix shells - ([@isaacs](https://github.com/isaacs)) -* [`2d682e4ca`](https://github.com/npm/cli/commit/2d682e4cab0cf109a16332f3222f1e9a4027db69) - [#2803](https://github.com/npm/cli/issues/2803) - fix(search): don't pass unused args - ([@wraithgar](https://github.com/wraithgar)) -* [`b3e7dd19b`](https://github.com/npm/cli/commit/b3e7dd19bb4888dad2bfb6702aed6560a7f91bf8) - [#2822](https://github.com/npm/cli/issues/2822) - fix(diff): set option "where" for pacote - ([@ruyadorno](https://github.com/ruyadorno)) -* [`96006640b`](https://github.com/npm/cli/commit/96006640b902d31415260df5ce3ad8d066a64623) - [#2824](https://github.com/npm/cli/issues/2824) - fix(repo, auth.sso): don't promisify open-url - ([@wraithgar](https://github.com/wraithgar)) - -### DOCUMENTATION - -* [`c8b73db82`](https://github.com/npm/cli/commit/c8b73db82f0f2445c20a0a64110586253accd66b) - [#2690](https://github.com/npm/cli/issues/2690) - fix(docs): update scripts docs - ([@wraithgar](https://github.com/wraithgar)) -* [`5d922394b`](https://github.com/npm/cli/commit/5d922394b7874b2b38d34f03f2decbe0eb3e8583) - [#2809](https://github.com/npm/cli/issues/2809) - update republish timeout after unpublish - ([@BAJ-](https://github.com/BAJ-)) - -### DEPENDENCIES - -* [`2d4ae598f`](https://github.com/npm/cli/commit/2d4ae598f30049680797685f76154b16a7e15a66) - `@npmcli/arborist@2.2.6` - -## v7.6.0 (2021-02-25) - -### FEATURES - -* [`983d218f7`](https://github.com/npm/cli/commit/983d218f7e68e3c7866f2efa23ea2aff7ff3881e) - [#2750](https://github.com/npm/cli/issues/2750) - feat(explain): mark when dependency is bundled - ([@kumavis](https://github.com/kumavis)) - -### DEPENDENCIES - -* [`b9fa7e32a`](https://github.com/npm/cli/commit/b9fa7e32a63a3dc3a4865865c4ca737c862b9cf2) - chore(package-lock): resetdeps and `eslint@7.20.0` - ([@wraithgar](https://github.com/wraithgar)) -* [`28d036ae9`](https://github.com/npm/cli/commit/28d036ae9179f742bd0518e558a54f014a7a895e) - `arborist@2.2.5` - * fix: hidden lockfiles were not respected on Node v10.0-10.12 - -### DOCUMENTATION - -* [`ba1adef42`](https://github.com/npm/cli/commit/ba1adef4292123e87e26b59e0c6fd6f5ff1fe775) - [#2760](https://github.com/npm/cli/issues/2760) - chore(docs): capitalize all Instaces of "package" - ([@MrBrain295](https://github.com/MrBrain295)) -* [`8bfa05fa1`](https://github.com/npm/cli/commit/8bfa05fa1dfd4a64381c7ec750df6d174724e8c1) - [#2775](https://github.com/npm/cli/issues/2775) - chore(docs): add navigation configuration - ([@ethomson](https://github.com/ethomson)) -* [`238e474a4`](https://github.com/npm/cli/commit/238e474a48ddecc33c76eb3d2c4d0642cfe8829a) - [#2778](https://github.com/npm/cli/issues/2778) - chore(docs):update unpublish cooldown - ([@christoflemke](https://github.com/christoflemke)) - -## v7.5.6 (2021-02-22) - -### BUG FIXES - -* [`4e58274ed`](https://github.com/npm/cli/commit/4e58274ed0fd2dd29d3c8d6c7c47f37a37dc0f0f) - [#2742](https://github.com/npm/cli/issues/2742) - Do not print error banner for shell proxy commands - ([@isaacs](https://github.com/isaacs)) - -### DOCS - -* [`3c72ab441`](https://github.com/npm/cli/commit/3c72ab4412111c708736e3a7b8342150372a4af4) - [#2749](https://github.com/npm/cli/issues/2749) - Capitalize Package in a Heading - ([@MrBrain295](https://github.com/MrBrain295)) - -### DEPENDENCIES - -* [`f3ae6ed0d`](https://github.com/npm/cli/commit/f3ae6ed0d25ce80868f59353ef71c09ac77b1cf5) - `read-package-json@3.0.1`, `read-package-json-fast@2.0.2` -* [`9b311fe52`](https://github.com/npm/cli/commit/9b311fe522077c7f8a242b94b0e1dbe746992bef) - [#2736](https://github.com/npm/cli/issue/2736) `@npmcli/arborist@2.2.4`: - * Do not rely on underscore fields in `package.json` files - * Do not remove global packages when updating by name - * Keep `yarn.lock` and `package-lock.json` more in sync - -## v7.5.5 (2021-02-22) - -### BUG FIXES -* [`49c95375a`](https://github.com/npm/cli/commit/49c95375af49308e2db6ba28e91c65193754e091) - [#2688](https://github.com/npm/cli/issues/2688) - fix shrinkwrap in node v10.0 - ([@ljharb](https://github.com/ljharb)) -* [`00afa3161`](https://github.com/npm/cli/commit/00afa316195f2db903146110a07ffdaec9bb6aa2) - [#2718](https://github.com/npm/cli/issues/2718) - restore the prefix on output from `npm version <inc>` - ([@nlf](https://github.com/nlf)) -* [`69e0c4e8c`](https://github.com/npm/cli/commit/69e0c4e8cd684c475a4450c40dfb32c995061aea) - [#2716](https://github.com/npm/cli/issues/2716) - throw an error when trying to dedupe in global mode - ([@nlf](https://github.com/nlf)) -* [`b018eb842`](https://github.com/npm/cli/commit/b018eb84266dc5a02274849135ca148cb59cc349) - [#2719](https://github.com/npm/cli/issues/2719) - obey silent loglevel in run-script - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES -* [`8c36697df`](https://github.com/npm/cli/commit/8c36697dfffe8b5e853fe889c9ead5578100c413) - `@npmcli/arborist@2.2.3` - * [#1875](https://github.com/npm/cli/issues/1875) - [arborist#230](https://github.com/npm/arborist/pull/230) - Set default advisory `severity`/`vulnerable_range` when missing from audit endpoint data - ([@isaacs](https://github.com/isaacs)) - * [npm/arborist#231](https://github.com/npm/arborist/pull/231) - skip optional deps with mismatched platform or engine - ([@nlf](https://github.com/nlf)) - * [#2251](https://github.com/npm/cli/issues/2251) - Unpack shrinkwrapped deps not already unpacked - ([@isaacs](https://github.com/isaacs), - [@nlf](https://github.com/nlf)) - * [#2714](https://github.com/npm/cli/issues/2714) - Do not write package.json if nothing changed - ([@isaacs](https://github.com/isaacs)) - * [npm/rfcs#324](https://github.com/npm/rfcs/issues/324) - Prefer peer over prod dep, if both specified - ([@isaacs](https://github.com/isaacs)) - * [npm/arborist#236](https://github.com/npm/arborist/issues/236) - Fix additional peerOptional conflict cases - ([@isaacs](https://github.com/isaacs)) -* [`d865b101f`](https://github.com/npm/cli/commit/d865b101f72142619531311645479f0596a68a1a) - `libnpmpack@2.0.1` - * respect silent loglevel -* [`e606953e5`](https://github.com/npm/cli/commit/e606953e5795803a7c4eddb4ea993735ef65ec95) - `libnpmversion@1.0.11` - * respect silent loglevel -* [`9c51005a1`](https://github.com/npm/cli/commit/9c51005a19fd4c3e7cd4c987d2e39d1b763036bf) - `npm-package-arg@8.1.1` - * do a better job of detecting git specifiers like `git@github.com:npm/cli` -* [`8b6bf0db4`](https://github.com/npm/cli/commit/8b6bf0db49a3378bd85a0d1ffdd19fbdd68a944a) - `pacote@11.2.7` - * respect silent loglevel - * fix INVALID_URL errors for certain git dependencies - -### TESTS -* [`80c2ac995`](https://github.com/npm/cli/commit/80c2ac995170a05b26856a2b72fe9c8163b2c999) - [#2717](https://github.com/npm/cli/issues/2717) - refactor publish tests - ([@wraithgar](https://github.com/wraithgar)) -* [`9d81e0ceb`](https://github.com/npm/cli/commit/9d81e0ceba7d69e0651662508415ee3705bddfd9) - [#2729](https://github.com/npm/cli/issues/2729) - fix typo in shrinkwrap tests - ([@eltociear](https://github.com/eltociear)) - -### DOCUMENTATION -* [`e3de7befb`](https://github.com/npm/cli/commit/e3de7befb3a9e2fcb7aac5b740d09b3b7d99d724) - [#2685](https://github.com/npm/cli/issues/2685) - docs(readme): add note back about branding/origin - ([@darcyclarke](https://github.com/darcyclarke)) -* [`38d87e7c2`](https://github.com/npm/cli/commit/38d87e7c24aea13b0f1c1157aad58d9d15bf8e63) - [#2698](https://github.com/npm/cli/issues/2698) - mention nodenv in README.md - ([@RA80533](https://github.com/RA80533)) -* [`af4422cdb`](https://github.com/npm/cli/commit/af4422cdbc110f93203667efc08b16f7aa74ac2f) - [#2711](https://github.com/npm/cli/issues/2711) - validate that the docs can be parsed by mdx - ([@ethomson](https://github.com/ethomson)) - - -## v7.5.4 (2021-02-12) - -### BUG FIXES - -* [`ef687f545`](https://github.com/npm/cli/commit/ef687f545b177d0496ce74faacf1bf738978355a) - [#2655](https://github.com/npm/cli/issues/2655) - fix(env): Do not clobber defined 'env' script - ([@isaacs](https://github.com/isaacs)) -* [`868954a72`](https://github.com/npm/cli/commit/868954a72c06ff2210b35e1e75571f4ec3357c43) - [#2654](https://github.com/npm/cli/issues/2654) - [fix] node v10.0 lacks `fs.promises` - ([@ljharb](https://github.com/ljharb)) - - -### DEPENDENCIES - -* [`14dd93853`](https://github.com/npm/cli/commit/14dd9385358b3815c2285526f7c2e53ed3c5e8da) - fix(package.json): resetdeps - ([@wraithgar](https://github.com/wraithgar)) -* [`39e4a6401`](https://github.com/npm/cli/commit/39e4a640130b85d62199a33cc2026b04390520ee) - `graceful-fs@4.2.6` -* [`96dffab98`](https://github.com/npm/cli/commit/96dffab988048164516d8cf73c1fbf66781f86df) - `eslint-plugin-promise@4.3.1` -* [`9a6e9d38a`](https://github.com/npm/cli/commit/9a6e9d38abccec793b6ac14871c2b639d62a6c41) - `@npmcli/run-script@1.8.3` - * fix fs.promises reference to run in node v10.0 -* [`584b746a2`](https://github.com/npm/cli/commit/584b746a2c8cdc697629298be27dd23d19de1231) - `@npmcli/git@2.0.5` -* [`6305ebde4`](https://github.com/npm/cli/commit/6305ebde43796737014aedbe019db8cd81dcbbec) - `make-fetch-happen@8.0.14` -* [`e99881117`](https://github.com/npm/cli/commit/e998811170ce5df00a725b2d683b4bff124c6792) - `libnpmversion@1.0.10` -* [`554d91cdf`](https://github.com/npm/cli/commit/554d91cdf82e9c92c2ac3752ed91e7081c2271e5) - chore(package-lock): rebuild package-lock - ([@wraithgar](https://github.com/wraithgar)) -* [`37e8cc507`](https://github.com/npm/cli/commit/37e8cc507b2ce0b89f92e7e77b1d909d1bf5513f) - `@npmcli/arborist@2.2.2` - * [#2505](https://github.com/npm/cli/issues/2505) properly install - dependenciess of linked dependencies - ([@ruyadorno](https://github.com/ruyadorno)) - * [#2504](https://github.com/npm/cli/issues/2504) Allow `--force` to - override conflicted optional peerDependencies - ([@isaacs](https://github.com/isaacs)) - * Ensure correct flags on shrinkwrapped module deps - ([@isaacs](https://github.com/isaacs)) - * Correct relative paths for global packages installed from tarball files - ([nlf](https://github.com/nlf)) -* [`7788ce47b`](https://github.com/npm/cli/commit/7788ce47bc264d9d951055da85f2b695eb8b3f15) - `@npmcli/map-workspaces@1.0.3` - -### TESTS - -* [`3a159d27e`](https://github.com/npm/cli/commit/3a159d27e976933098ec18fa9c3e474c85b5b332) - [#2681](https://github.com/npm/cli/issues/2681) - fix(tests): rewrite doctor tests - ([@ljharb](https://github.com/ljharb)) -* [`abcc96a20`](https://github.com/npm/cli/commit/abcc96a204ed581fc7cd603f47cdca0afe299530) - [#2682](https://github.com/npm/cli/issues/2682) - [tests] separate tests from linting and license validation - ([@ljharb](https://github.com/ljharb)) - -### DOCUMENTATION - -* [`7e1e84181`](https://github.com/npm/cli/commit/7e1e84181ccaca8a8b499a21b1aa7d731a14d5b7) - [#2662](https://github.com/npm/cli/issues/2662) - fix(docs): fix angle brackets in npm diff docs - ([@ethomson](https://github.com/ethomson)) - -## v7.5.3 (2021-02-08) - -### BUG FIXES - -* [`df596bf4c`](https://github.com/npm/cli/commit/df596bf4c10d6917672579cc38800f5e846002bc) - fix(publish): follow all configs for registry auth check - [#2602](https://github.com/npm/cli/issues/2602) - ([@wraithgar](https://github.com/wraithgar)) -* [`6d7afb03c`](https://github.com/npm/cli/commit/6d7afb03cd7602b60e709516711a2f94cd61ff25) - [#2613](https://github.com/npm/cli/issues/2613) - install script: pass -q to curl calls to disable user .curlrc files - ([@nlf](https://github.com/nlf)) - -### DEPENDENCIES - -* [`3294fed6f`](https://github.com/npm/cli/commit/3294fed6f18626516978c21fac5f28ecfdb58124) - `pacote@11.2.5` - * prevent infinite recursion in git dep preparation -* [`0f7a3a87c`](https://github.com/npm/cli/commit/0f7a3a87c12e30bdd2cdab596ca6511de787c969) - `read-package-json-fast@2.0.1` - * avoid duplicating optionalDependencies as dependencies in package.json -* [`6f46b0f7f`](https://github.com/npm/cli/commit/6f46b0f7fef9891e6de4af3547c70a67cb3a7a13) - `init-package-json@2.0.2` -* [`df4f65acc`](https://github.com/npm/cli/commit/df4f65acc4ceaf15db4c227670e80f94584c055c) - `@npmcli/arborist@2.2.0` -* [`7038c2ff4`](https://github.com/npm/cli/commit/7038c2ff49022f8babd495d1b831b5c82d6aed05) - `@npmcli/run-script@1.8.2` -* [`54cd4c87a`](https://github.com/npm/cli/commit/54cd4c87a71c9381519d8ac52e306096066dc92e) - `libnpmversion@1.0.8` -* [`9ab36aae4`](https://github.com/npm/cli/commit/9ab36aae429784df754211d5f086a515012b9bdd) - `graceful-fs@4.2.5` -* [`e1822cf27`](https://github.com/npm/cli/commit/e1822cf277336728f1d5696ffe0db3ea6e700d9e) - `@npmcli/installed-package-contents@1.0.7` - -## v7.5.2 (2021-02-02) - -### BUG FIXES - -* [`37613e4e6`](https://github.com/npm/cli/commit/37613e4e686e4891210acaabc9c23f41456eda3f) -[#2395](https://github.com/npm/cli/issues/2395) -[#2329](https://github.com/npm/cli/issues/2329) -fix(exec): use latest version when possible -([@wraithgar](https://github.com/wraithgar)) -* [`567c9bd03`](https://github.com/npm/cli/commit/567c9bd03a7669111fbba6eb6d1f12ed7cad5a1b) -fix(lib/npm): do not clobber config.execPath -([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`643709706`](https://github.com/npm/cli/commit/64370970653af5c8d7a2be2c2144e355aa6431b0) -`@npmcli/config@1.2.9` ([@isaacs](https://github.com/isaacs)) - * [`4c6be4a`](https://github.com/npm/config/commit/4c6be4a66a3e89ae607e08172b8543b588a95fb5) Restore npm v6 behavior with `INIT_CWD` - * [`bbebc66`](https://github.com/npm/config/commit/bbebc668888f71dba57959682364b6ff26ff4fac) Do not set the `PREFIX` environment variable - -## v7.5.1 (2021-02-01 - -### BUG FIXES - -* [`0ea134e41`](https://github.com/npm/cli/commit/0ea134e4190f322138299c51672eab5387ec41bb) - [#2587](https://github.com/npm/cli/issues/2587) - pass all settings through to pacote.packument, fixes #2060 - ([@nlf](https://github.com/nlf)) -* [`8c5ca2f51`](https://github.com/npm/cli/commit/8c5ca2f516f5ac87f3bbd7f1fd95c0b283a21f14) - Add test for npm-usage.js, and fix 'npm --long' output - ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES - -* [`7e4e88e93`](https://github.com/npm/cli/commit/7e4e88e938323e34a2a41176472d8e43e84bd4dd) - `@npmcli/arborist@2.1.1`, `pacote@11.2.4` - * Properly raise ERESOLVE errors on root dev dependencies - * Ignore ERESOLVE errors when performing git dep 'prepare' scripts - * Always reinstall packages that are explicitly requested - * fix global update all so it actually updates things - * Install bins properly when global root is a link - ([@isaacs](https://github.com/isaacs)) - -### DOCUMENTATION - -* [`23dac2fef`](https://github.com/npm/cli/commit/23dac2feff1d02193791c7e39d9e93bc9bf8e624) - [#2557](https://github.com/npm/cli/issues/2557) - npm team revamp - ([@ruyadorno](https://github.com/ruyadorno)) -* [`dd05ba0c0`](https://github.com/npm/cli/commit/dd05ba0c0b2f4c70eb8558c0ecc54889efbe98f5) - [#2572](https://github.com/npm/cli/issues/2572) - add note about `--force` overriding peer dependencies - ([@isaacs](https://github.com/isaacs)) -* [`e27639780`](https://github.com/npm/cli/commit/e276397809aceb01cc468e02a83bc6f2265376d9) - [#2584](https://github.com/npm/cli/issues/2584) - Fixed the spelling of contributor as it was written as conributor - ([@pavanbellamkonda](https://github.com/pavanbellamkonda)) -* [`13a5e3178`](https://github.com/npm/cli/commit/13a5e31781cdaa37d3f007e1c8583c7cb591c62a) - [#2502](https://github.com/npm/cli/issues/2502) - elaborate that npm help uses browser - ([@ariccio](https://github.com/ariccio)) - -## v7.5.0 (2021-01-28) - -### FEATURES - -* [`d011266b7`](https://github.com/npm/cli/commit/d011266b733367aad283ccbfb9d2b19442c3405f) - [#1319](https://github.com/npm/cli/issues/1319) - add npm diff command - ([@ruyadorno](https://github.com/ruyadorno)) - -### BUG FIXES - -* [`d2f8af2da`](https://github.com/npm/cli/commit/d2f8af2da64d510d3d363aec10531bebf840d84e) - [#2445](https://github.com/npm/cli/issues/2445) - publish: don't complain about missing auth until after registry is chosen - ([@dr-js](https://github.com/dr-js)) - -### DOCUMENTATION - -* [`8d3fd63aa`](https://github.com/npm/cli/commit/8d3fd63aaa6a5c9b3d2281dd0bd9e1c270b35941) - [#2559](https://github.com/npm/cli/issues/2559) - updates to readme, removal, contributing and several other docs - ([@darcyclarke](https://github.com/darcyclarke)) -* [`7772d9f9f`](https://github.com/npm/cli/commit/7772d9f9f9f853573a7ff8e7fb60c5e46566f596) - [#2542](https://github.com/npm/cli/issues/2542) - fix grammar on caching docs for search, exec and init - ([@wraithgar](https://github.com/wraithgar)) -* [`52e8a1aef`](https://github.com/npm/cli/commit/52e8a1aef4aab3f378c20276a9109bb3f00eccd5) - [#2558](https://github.com/npm/cli/issues/2558) - refreshed npm updated docs - ([@ruyadorno](https://github.com/ruyadorno)) -* [`abae00ca0`](https://github.com/npm/cli/commit/abae00ca05925e521696dd12480853509aab6c0a) - [#2565](https://github.com/npm/cli/issues/2565) - update npm command docs - ([@wraithgar](https://github.com/wraithgar)) -* [`9351cbf9a`](https://github.com/npm/cli/commit/9351cbf9afd2310c56b9953c005505ea5126a5d4) - [#2566](https://github.com/npm/cli/issues/2566) - refresh npm run-script docs - ([@ruyadorno](https://github.com/ruyadorno)) - -### DEPENDENCIES - -* [`56c08863e`](https://github.com/npm/cli/commit/56c08863e15cb9cf8662b99ddc627cfcdff0348d) - `hosted-git-info@3.0.8` -* [`18a93f06b`](https://github.com/npm/cli/commit/18a93f06b632be051b9455e32a85e4e75066f52c) - `ssri@8.0.1` -* [`cb768f671`](https://github.com/npm/cli/commit/cb768f671c4d8d5a09d9a6c5a74227d300e81104) - `@npmcli/move-file@1.1.1` -* [`32cc0a4be`](https://github.com/npm/cli/commit/32cc0a4be76465093e3d0f314215a0ec46dc03c6) - `minipass-fetch@1.3.3` - * fixes ssl settings passthrough -* [`530997968`](https://github.com/npm/cli/commit/530997968fbbd9e8bf016689b1d192daa812b4de) - `@npmcli/arborist@2.1.0` - * added signal handler to rollback when possible - * prevent ERESOLVEs caused by loose root dep specs - * detect conflicts among nested peerOptional deps - * properly buildIdealTree when root is a symlink - -## v7.4.3 (2021-01-21) - -### DOCUMENTATION - -* [`ec1f06d06`](https://github.com/npm/cli/commit/ec1f06d06447a29c74bee063cff103ede7a2111b) - [#2498](https://github.com/npm/cli/issues/2498) - docs(npm): update `npm` docs - ([@darcyclarke](https://github.com/darcyclarke)) - -### DEPENDENCIES -* [`bc23284cd`](https://github.com/npm/cli/commit/bc23284cd5c4cc4532875aff14df94213727a509) - [#2511](https://github.com/npm/cli/issues/2511) - remove coverage files - ([@ruyadorno](https://github.com/ruyadorno)) -* [`fcbc676b8`](https://github.com/npm/cli/commit/fcbc676b88e1b7c8d01a3799683cd388a82c44d6) - `pacote@11.2.3` -* [`ebd3a24ff`](https://github.com/npm/cli/commit/ebd3a24ff8381f2def306136b745d1615fd6139f) - `@npmcli/arborist@2.0.6` - * Preserve git+https auth when provided - -## v7.4.2 (2021-01-15) - -### DEPENDENCIES - -* [`e5ce6bbba`](https://github.com/npm/cli/commit/e5ce6bbbad82b85c8e74a4558503513e4f337476) - * `@npmcli/arborist@2.0.5` - * fix creating missing dirs when using --prefix and --global - * fix omit types of deps in global installs - * fix prioritizing npm-shrinkwrap.json over package-lock.json - * better cache system for packuments - * improves audit performance - -## v7.4.1 (2021-01-14) - -### BUG FIXES - -* [`23df96d33`](https://github.com/npm/cli/commit/23df96d3394ba0b69a37f416d7f0c26bb9354975) - [#2486](https://github.com/npm/cli/issues/2486) - npm link no longer deletes entire project when global prefix is a symlink - ([@nlf](https://github.com/nlf)) - -### DOCUMENTATION - -* [`7dd0dfc59`](https://github.com/npm/cli/commit/7dd0dfc59c861e7d3e30a86a8e6db10872fc6b44) - [#2459](https://github.com/npm/cli/issues/2459) - fix(docs): clean up `npm start` docs - ([@wraithgar](https://github.com/wraithgar)) -* [`307b3bd9f`](https://github.com/npm/cli/commit/307b3bd9f90e96fcc8805a1d5ddec80787a3d3a7) - [#2460](https://github.com/npm/cli/issues/2460) - fix(docs): clean up `npm stop` docs - ([@wraithgar](https://github.com/wraithgar)) -* [`23f01b739`](https://github.com/npm/cli/commit/23f01b739d7a01a7dc3672322e14eb76ff33d712) - [#2462](https://github.com/npm/cli/issues/2462) - fix(docs): clean up `npm test` docs - ([@wraithgar](https://github.com/wraithgar)) -* [`4b43656fc`](https://github.com/npm/cli/commit/4b43656fc608783a29ccf8495dc305459abc5cc7) - [#2463](https://github.com/npm/cli/issues/2463) - fix(docs): clean up `npm prefix` docs - ([@wraithgar](https://github.com/wraithgar)) -* [`1135539ba`](https://github.com/npm/cli/commit/1135539bac9f98bb1a5d5ed05227a8ecd19493d3) - [`a07bb8e69`](https://github.com/npm/cli/commit/a07bb8e692a85b55d51850534c09fa58224c2285) - [`9b55b798e`](https://github.com/npm/cli/commit/9b55b798ed8f2b9be7b3199a1bfc23b1cd89c4cd) - [`cd5eeaaa0`](https://github.com/npm/cli/commit/cd5eeaaa08eabb505b65747a428c3c59159663dc) - [`6df69ce10`](https://github.com/npm/cli/commit/6df69ce107912f8429665eb851825d2acebc8575) - [`dc6b2a8b0`](https://github.com/npm/cli/commit/dc6b2a8b032d118be3566ce0fa7c67c171c8d2cb) - [`a3c127446`](https://github.com/npm/cli/commit/a3c1274460e16d1edbdca6a0cee86ef313fdd961) - [#2464](https://github.com/npm/cli/issues/2464) - fix(docs): clean up `npm uninstall` docs - ([@wraithgar](https://github.com/wraithgar)) -* [`cfdcf32fd`](https://github.com/npm/cli/commit/cfdcf32fd7628501712b8cad4a541c6b8e7b66bc) - [#2474](https://github.com/npm/cli/issues/2474) - fix(docs): clean up `npm unpublish` docs - ([@wraithgar](https://github.com/wraithgar)) -* [`acd5b062a`](https://github.com/npm/cli/commit/acd5b062a811fcd98849df908ce26855823ca671) - [#2475](https://github.com/npm/cli/issues/2475) - fix(docs): update `package-lock.json` docs - ([@isaacs](https://github.com/isaacs)) -* [`b0b0edf6d`](https://github.com/npm/cli/commit/b0b0edf6de1678de7f4a000700c88daa5f7194ef) - [#2482](https://github.com/npm/cli/issues/2482) - fix(docs): clean up `npm token` docs - ([@wraithgar](https://github.com/wraithgar)) -* [`35559201a`](https://github.com/npm/cli/commit/35559201a4a0a5b111ce58d6824e5b4030eb4496) - [#2487](https://github.com/npm/cli/issues/2487) - fix(docs): clean up `npm search` docs - ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`ea8c02169`](https://github.com/npm/cli/commit/ea8c02169cfbf0484d67db7c0e7a6ec8aecb7210) - `@npmcli/arborist@2.0.5` -* [`fb6f2c313`](https://github.com/npm/cli/commit/fb6f2c313d1d9770cc7d02a3900c7945df3cb661) - `pacote@11.2.1` -* [`c549b7657`](https://github.com/npm/cli/commit/c549b76573b1835a63e1e5898e9c16860079d84e) - `make-fetch-happen@8.0.13` - -## v7.4.0 (2021-01-07) - -### FEATURES - -* [`47ed2dfd8`](https://github.com/npm/cli/commit/47ed2dfd865566643bc1d39e8a4f98d2e1add99a) - [#2456](https://github.com/npm/cli/issues/2456) add - `--foreground-scripts` option ([@isaacs](https://github.com/isaacs)) - -### BUG FIXES - -* [`d01746a5a`](https://github.com/npm/cli/commit/d01746a5a6dde115ee6a600cdf54c9b35afcab3f) - [#2444](https://github.com/npm/cli/issues/2444) - [#1103](https://github.com/npm/cli/issues/1103) Remove deprecated - `process.umask()` ([@isaacs](https://github.com/isaacs)) -* [`b2e2edf8a`](https://github.com/npm/cli/commit/b2e2edf8aee57347c96a61209c7a10139a0cc85a) - [#2422](https://github.com/npm/cli/issues/2422) npm publish --dry-run - should not check login status ([@buyan302](https://github.com/buyan302)) -* [`99156df80`](https://github.com/npm/cli/commit/99156df8099f55bc69dfa99d7ddcf8d1d569016e) - [#2448](https://github.com/npm/cli/issues/2448) - [#2425](https://github.com/npm/cli/issues/2425) pass extra arguments - directly to run-script as an array ([@nlf](https://github.com/nlf)) -* [`907b34b2e`](https://github.com/npm/cli/commit/907b34b2ecc34ac376d989f824f7492064e43ef4) - [#2455](https://github.com/npm/cli/issues/2455) fix(ci): pay attention to - --ignore-scripts ([@wraithgar](https://github.com/wraithgar)) - -### DEPENDENCIES - -* [`7a49fd4af`](https://github.com/npm/cli/commit/7a49fd4afc8cd24db40aee008031ea648583d0bc) - `tar@6.1.0`, `pacote@11.1.14` -* [`54a7bd16c`](https://github.com/npm/cli/commit/54a7bd16c130525ade71ec9894af71c2825d8584) - `@npmcli/arborist@2.0.3` - -### DOCUMENTATION - -* [`a390d7456`](https://github.com/npm/cli/commit/a390d74561b72f0b13cba65844ce60c379198087) - [#2440](https://github.com/npm/cli/issues/2440) Updated the url for RFC - 19 so that it isn't a 404. - ([@therealjeffg](https://github.com/therealjeffg)) -* [`e02b46ad7`](https://github.com/npm/cli/commit/e02b46ad7acdeb9fbb63f782e546c2f8db94ae6e) - [#2436](https://github.com/npm/cli/issues/2436) Grammatical Fix in npm-ls - Documentation 'Therefore' is spelled 'Therefor' - ([@marsonya](https://github.com/marsonya)) -* [`0fed44dea`](https://github.com/npm/cli/commit/0fed44dea12f125b639b5e3575adcea74a86d3a0) - [#2417](https://github.com/npm/cli/issues/2417) Fix npm bug reporting url - ([@AkiaCode](https://github.com/AkiaCode)) - -## 7.3.0 (2020-12-18) - -### FEATURES - -* [`a9b8bf263`](https://github.com/npm/cli/commit/a9b8bf2634c627fbb16ca3a6bb2c2f1058c3e586) - [#2362](https://github.com/npm/cli/issues/2362) - Support multiple set/get/deletes in npm config - ([@isaacs](https://github.com/isaacs)) - -### BUG FIXES - -* [`9eef63849`](https://github.com/npm/cli/commit/9eef638499c88689acb00d812c10f0407cb95c08) - Pass full set of options to login helper functions. - This fixes `npm login --no-strict-ssl`, as well as a host of other - options that one might want to set while logging in. - Reported by: [@toddself](https://github.com/toddself) - ([@isaacs](https://github.com/isaacs)) -* [`628a554bc`](https://github.com/npm/cli/commit/628a554bc113e4e115d34778bfe8a77cfad1d933) - [#2358](https://github.com/npm/cli/issues/2358) - fix doctor test to work correctly for node pre-release versions - ([@nlf](https://github.com/nlf)) -* [`be4a0900b`](https://github.com/npm/cli/commit/be4a0900b14b2c6315bf62bed8f5affb648215ae) - [#2360](https://github.com/npm/cli/issues/2360) - raise an error early if publishing without login, registry - ([@isaacs](https://github.com/isaacs)) -* [`44d433105`](https://github.com/npm/cli/commit/44d4331058c53909ada62470b23b2185102b2128) - [#2366](https://github.com/npm/cli/issues/2366) - Include prerelease versions when deprecating - ([@tiegz](https://github.com/tiegz)) -* [`cba3341da`](https://github.com/npm/cli/commit/cba3341dae4c92541049dc976e82e2ba19566e95) - [#2373](https://github.com/npm/cli/issues/2373) - npm profile refactor - ([@ruyadorno](https://github.com/ruyadorno)) -* [`7539504e3`](https://github.com/npm/cli/commit/7539504e3abdec28039a7798e5ccb745b536cb6e) - [#2382](https://github.com/npm/cli/issues/2382) - remove the metrics sender - ([@nlf](https://github.com/nlf)) - -### DOCS - -* [`b98569a8c`](https://github.com/npm/cli/commit/b98569a8ca28dbd611fe84492aee996e2e567b55) - add note about `INIT_CWD` to run-script doc -* [`292929279`](https://github.com/npm/cli/commit/292929279854a06ca60ff737b574cbd6503ec5db) - [#2368](https://github.com/npm/cli/issues/2368) - Revert bug-reporting links to GH. - Re: <https://blog.npmjs.org/post/188841555980/updates-to-community-docs-more> - ([@tiegz](https://github.com/tiegz)) -* [`f4560626f`](https://github.com/npm/cli/commit/f4560626f09dba4889d752f7f739aa5a5f3da741) - update `ISSUE_TEMPLATE` with modern links - ([@isaacs](https://github.com/isaacs)) -* [`bc1c567ed`](https://github.com/npm/cli/commit/bc1c567ed3d853ed4f01d33a800eb453956de6ef) - update npm command doc feature request links - ([@isaacs](https://github.com/isaacs)) -* [`0ad958fe1`](https://github.com/npm/cli/commit/0ad958fe1cb811699caca235f361c8328baac8c4) - [#2381](https://github.com/npm/cli/issues/2381) - (docs,test): assorted typo fixes - ([@XhmikosR](https://github.com/XhmikosR)) - -### TESTING - -* [`a92d310b7`](https://github.com/npm/cli/commit/a92d310b7e9e4c48b08f52785c2e3a6d52a82ad7) - [#2361](https://github.com/npm/cli/issues/2361) - Add max-len to lint rules - ([@Edu93Jer](https://github.com/Edu93Jer)) - -### DEPENDENCIES - -* [`4fc2f3e05`](https://github.com/npm/cli/commit/4fc2f3e05b600aa64fe5eb6b8b77bc070e5a9403) - [#2300](https://github.com/npm/cli/issues/2300) - `@npmcli/config@1.2.8`: - * Support setting email without username/password - -## 7.2.0 (2020-12-15) - -### FEATURES - -* [`a9c4b158c`](https://github.com/npm/cli/commit/a9c4b158c46dd0d0c8d8744a97750ffd0c30cc09) - [#2342](https://github.com/npm/cli/issues/2342) - allow npm rebuild to accept a path to a module - ([@nlf](https://github.com/nlf)) - -### DEPENDENCIES - -* [`beb371800`](https://github.com/npm/cli/commit/beb371800292140bf3882253c447168a378bc154) - [#2334](https://github.com/npm/cli/issues/2334) - remove unused top level dep tough-cookie - ([@darcyclarke](https://github.com/darcyclarke)) -* [`d45e181d1`](https://github.com/npm/cli/commit/d45e181d17dd88d82b3a97f8d9cd5fa5b6230e48) - [#2335](https://github.com/npm/cli/issues/2335) - `ini@2.0.0`, `@npmcli/config@1.2.7` - ([@isaacs](https://github.com/isaacs)) -* [`ef4b18b5a`](https://github.com/npm/cli/commit/ef4b18b5a70381b264d234817cff32eeb6848a73) - [#2309](https://github.com/npm/cli/issues/2309) - `@npmcli/arborist@2.0.2` - * properly remove deps when no lockfile and package.json is present -* [`c6c013e6e`](https://github.com/npm/cli/commit/c6c013e6ebc4fe036695db1fd491eb68f3b57c68) - `readdir-scoped-modules@1.1.0` -* [`a1a2134aa`](https://github.com/npm/cli/commit/a1a2134aa9a1092493db6d6c9a729ff5203f0dd4) - remove unused sorted-object dep - ([@nlf](https://github.com/nlf)) -* [`85c2a2d31`](https://github.com/npm/cli/commit/85c2a2d318ae066fb2c161174f5aea97e18bc9c5) - [#2344](https://github.com/npm/cli/issues/2344) - remove editor dependency - ([@nlf](https://github.com/nlf)) - -### TESTING - -* [`3a6dd511c`](https://github.com/npm/cli/commit/3a6dd511c944c5f2699825a99bba1dde333a45ef) - npm edit - ([@nlf](https://github.com/nlf)) -* [`3ba5de4e7`](https://github.com/npm/cli/commit/3ba5de4e7f6c5c0f995a29844926d6ed2833addd) - [#2347](https://github.com/npm/cli/issues/2347) - npm help-search - ([@nlf](https://github.com/nlf)) -* [`6caf19f49`](https://github.com/npm/cli/commit/6caf19f491e144be3e2a1a50f492dad48b01f361) - [#2348](https://github.com/npm/cli/issues/2348) - npm help - ([@nlf](https://github.com/nlf)) -* [`cb5847e32`](https://github.com/npm/cli/commit/cb5847e3203c52062485b5de68e4f6d29b33c361) - [#2349](https://github.com/npm/cli/issues/2349) - npm hook - ([@nlf](https://github.com/nlf)) -* [`996a2f6b1`](https://github.com/npm/cli/commit/996a2f6b130d6678998a2f6a5ec97d75534d5f66) - [#2353](https://github.com/npm/cli/issues/2353) - npm org - ([@nlf](https://github.com/nlf)) -* [`8c67c38a4`](https://github.com/npm/cli/commit/8c67c38a4f476ff5be938db6b6b3ee9ac6b44db5) - [#2354](https://github.com/npm/cli/issues/2354) - npm set - ([@nlf](https://github.com/nlf)) - -## 7.1.2 (2020-12-11) - -### DEPENDENCIES - -* [`c3ba1daf7`](https://github.com/npm/cli/commit/c3ba1daf7cd335d72aeba80ae0e9f9d215ca9ea5) - [#2033](https://github.com/npm/cli/issues/2033) `@npmcli/config@1.2.6`: - * Set `INIT_CWD` to initial current working directory - * Set `NODE` to initial process.execPath -* [`8029608b9`](https://github.com/npm/cli/commit/8029608b914fe5ba35a7cd37ae95ab93b0532e2e) - `json-parse-even-better-errors@2.3.1` -* [`0233818e6`](https://github.com/npm/cli/commit/0233818e606888b80881b17a2c6aca9f10a619b2) - [#2332](https://github.com/npm/cli/issues/2332) `treeverse@1.0.4` -* [`e401d6bb3`](https://github.com/npm/cli/commit/e401d6bb37ffc767b4fefe89878dd3c3ef490b2c) - `ini@1.3.8` -* [`011bb1220`](https://github.com/npm/cli/commit/011bb122035dcd43769ec35982662cca41635068) - [#2320](https://github.com/npm/cli/issues/2320) `@npmcli/arborist@2.0.1`: - * Do not save with `^` and no version - -### BUGFIXES - -* [`244c2069f`](https://github.com/npm/cli/commit/244c2069fd093f053d3061c85575ac13e72e2454) - [#2325](https://github.com/npm/cli/issues/2325) npm search - include/exclude ([@ruyadorno](https://github.com/ruyadorno)) -* [`d825e901e`](https://github.com/npm/cli/commit/d825e901eceea4cf8d860e35238dc30008eb4da4) - [#1905](https://github.com/npm/cli/issues/1905) - [#2316](https://github.com/npm/cli/issues/2316) run install scripts for - root project -* [`315449142`](https://github.com/npm/cli/commit/31544914294948085a84097af7f0f5de2a2e8f7e) - [#2331](https://github.com/npm/cli/issues/2331) - [#2021](https://github.com/npm/cli/issues/2021) Set `NODE_ENV=production` - if 'dev' is on the omit list ([@isaacs](https://github.com/isaacs)) - -### TESTING - -* [`c243e3b9d`](https://github.com/npm/cli/commit/c243e3b9d9bda0580a0fc1b3e230b4d47412176e) - [#2313](https://github.com/npm/cli/issues/2313) tests: completion - ([@nlf](https://github.com/nlf)) -* [`7ff6efbb8`](https://github.com/npm/cli/commit/7ff6efbb866591b2330b967215cef8146dff3ebf) - [#2314](https://github.com/npm/cli/issues/2314) npm team - ([@ruyadorno](https://github.com/ruyadorno)) -* [`7a4f0c96c`](https://github.com/npm/cli/commit/7a4f0c96c2ab9f264f7bda2caf7e72c881571270) - [#2323](https://github.com/npm/cli/issues/2323) npm doctor - ([@nlf](https://github.com/nlf)) - -### DOCUMENTATION - -* [`e340cf64b`](https://github.com/npm/cli/commit/e340cf64ba31ef329a9049b60c32ffd0342cfb7d) - [#2330](https://github.com/npm/cli/issues/2330) explain through - run-script ([@isaacs](https://github.com/isaacs)) - -## 7.1.1 (2020-12-08) - -### DEPENDENCIES - -* [`bf09e719c`](https://github.com/npm/cli/commit/bf09e719c7f563a255b1e9af6b1237ebc5598db6) - `@npmcli/arborist@2.0.0` - * Much stricter tree integrity guarantees - * Fix issues where the root project is a symlink, or linked as a - workspace -* [`7ceb5b728`](https://github.com/npm/cli/commit/7ceb5b728b9f326c567f5ffe5831c9eccf013aa0) - `ini@1.3.6` -* [`77c6ced2a`](https://github.com/npm/cli/commit/77c6ced2a6daaadbff715c8f05b2e61ba76e9bab) - `make-fetch-happen@8.0.11` - * Avoid caching headers that are hazardous or unnecessary to leave - lying around (authorization, npm-session, etc.) - * [#38](https://github.com/npm/make-fetch-happen/pull/38) Include query - string in cache key ([@jpb](https://github.com/jpb)) -* [`0ef25b6cd`](https://github.com/npm/cli/commit/0ef25b6cd2921794d36f066e2b11c406342cf167) - `libnpmsearch@3.1.0`: - * Update to accept query params as options, so we can paginate. - ([@nlf](https://github.com/nlf)) -* [`518a66450`](https://github.com/npm/cli/commit/518a664500bcde30475788e8c1c3e651f23e881b) - `@npmcli/config@1.2.4`: - * Do not allow path options to be set to a boolean `false` value -* [`3d7aff9d8`](https://github.com/npm/cli/commit/3d7aff9d8dd1cf29956aa306464cd44fbc2af426) - update all dependencies using latest npm to install them - -### TESTS - -* [`2848f5940`](https://github.com/npm/cli/commit/2848f594034b87939bfc5546e3e603f123d98a01) - [npm/statusboard#173](https://github.com/npm/statusboard/issues/173) - [#2293](https://github.com/npm/cli/issues/2293) npm shrinkwrap - ([@ruyadorno](https://github.com/ruyadorno)) -* [`f6824459a`](https://github.com/npm/cli/commit/f6824459ae0c86e2fa9c84b3dcec85f572ae8e1b) - [#2302](https://github.com/npm/cli/issues/2302) npm deprecate - ([@nlf](https://github.com/nlf)) -* [`b7d74b627`](https://github.com/npm/cli/commit/b7d74b627859f08fca23209d6e0d3ec6657a4489) - [npm/statusboard#180](https://github.com/npm/statusboard/issues/180) - [#2304](https://github.com/npm/cli/issues/2304) npm unpublish - ([@ruyadorno](https://github.com/ruyadorno)) - -### FEATURES - -* [`3db90d944`](https://github.com/npm/cli/commit/3db90d94474f673591811fdab5eb6a5bfdeba261) - [#2303](https://github.com/npm/cli/issues/2303) allow for passing object - keys to searchopts to allow pagination ([@nlf](https://github.com/nlf)) - -## 7.1.0 (2020-12-04) - -### FEATURES - -* [`6b1575110`](https://github.com/npm/cli/commit/6b15751106beb99234aa4bf39ae05cf40076d42a) - [#2237](https://github.com/npm/cli/pull/2237) - add `npm set-script` command - ([@Yash-Singh1](https://github.com/Yash-Singh1)) -* [`15d7333f8`](https://github.com/npm/cli/commit/15d7333f832e3d68ae16895569f27a27ef86573e) - add interactive `npm exec` - ([@isaacs](https://github.com/isaacs)) - -### BUG FIXES - -* [`2a1192e4b`](https://github.com/npm/cli/commit/2a1192e4b03acdf6e6e24e58de68f736ab9bb35f) - [#2202](https://github.com/npm/cli/pull/2202) - Do not run interactive `npm exec` in CI when a TTY - ([@isaacs](https://github.com/isaacs)) - -### DOCUMENTATION - -* [`0599cc37d`](https://github.com/npm/cli/commit/0599cc37df453bf79d47490eb4fca3cd63f67f80) - [#2271](https://github.com/npm/cli/pull/2271) - don't wrap code block - ([@ethomson](https://github.com/ethomson)) - -### DEPENDENCIES - -* [`def85c726`](https://github.com/npm/cli/commit/def85c72640ffe2d27977c56b7aa06c6f6346ca9) - `@npmcli/arborist@1.0.14` - * fixes running `npm exec` from file system root folder -* [`4c94673ab`](https://github.com/npm/cli/commit/4c94673ab5399d27e5a48e52f7a65b038a456265) - `semver@7.3.4` - -## 7.0.15 (2020-11-27) - -### DEPENDENCIES - -* [`00e6028ef`](https://github.com/npm/cli/commit/00e6028ef83bf76eaae10241fd7ba59e39768603) - `@npmcli/arborist@1.0.13` - * do not override user-defined shorthand values when saving `package.json` - -### BUG FIXES - -* [`9c3413fbc`](https://github.com/npm/cli/commit/9c3413fbcb37e79fc0b3d980e0b5810d7961277c) - [#2034](https://github.com/npm/cli/issues/2034) - [#2245](https://github.com/npm/cli/issues/2245) - `npm link <pkg>` should not save `package.json` - ([@ruyadorno](https://github.com/ruyadorno)) - -### DOCUMENTATION - -* [`1875347f9`](https://github.com/npm/cli/commit/1875347f9f4f2b50c28fe8857c5533eeebf42da2) - [#2196](https://github.com/npm/cli/issues/2196) - remove doc on obsolete `unsafe-perm` flag - ([@kaizhu256](https://github.com/kaizhu256)) -* [`f51e50603`](https://github.com/npm/cli/commit/f51e5060340c783a8a00dadd98e5786960caf43f) - [#2200](https://github.com/npm/cli/issues/2200) - `config.md` cleanup - ([@alexwoollam](https://github.com/alexwoollam)) -* [`997cbdb40`](https://github.com/npm/cli/commit/997cbdb400bcd22e457e8a06b69a7be697cfd66d) - [#2238](https://github.com/npm/cli/issues/2238) - Fix broken link to `package.json` documentation - ([@d-fischer](https://github.com/d-fischer)) -* [`9da972dc4`](https://github.com/npm/cli/commit/9da972dc44c21cf0e337f1c3fca44eb9df3e40d5) - [#2241](https://github.com/npm/cli/issues/2241) - `npm star` docs cleanup - ([@ruyadorno](https://github.com/ruyadorno)) - -## 7.0.14 (2020-11-23) - -### DEPENDENCIES -* [`09d21ab90`](https://github.com/npm/cli/commit/09d21ab903dcfebdfd446b8b29ad46c425b6510e) - `@npmcli/run-script@1.8.1` - - fix a regression in how scripts are escaped - -## 7.0.13 (2020-11-20) - -### BUG FIXES -* [`5fc56b6db`](https://github.com/npm/cli/commit/5fc56b6dbcc7d7d1463a761abb67d2fc16ad3657) - [npm/statusboard#174](https://github.com/npm/statusboard/issues/174) - [#2204](https://github.com/npm/cli/issues/2204) - fix npm unstar command - ([@ruyadorno](https://github.com/ruyadorno)) -* [`7842b4d4d`](https://github.com/npm/cli/commit/7842b4d4dca1e076b0d26d554f9dce67484cd7be) - [npm/statusboard#182](https://github.com/npm/statusboard/issues/182) - [#2205](https://github.com/npm/cli/issues/2205) - fix npm version usage output - ([@ruyadorno](https://github.com/ruyadorno)) -* [`a0adbf9f8`](https://github.com/npm/cli/commit/a0adbf9f8f77531fcf81ae31bbc7102698765ee3) - [#2206](https://github.com/npm/cli/issues/2206) - [#2213](https://github.com/npm/cli/issues/2213) - fix: fix flatOptions usage in npm init - ([@ruyadorno](https://github.com/ruyadorno)) - -### DEPENDENCIES - -* [`3daaf000a`](https://github.com/npm/cli/commit/3daaf000aee0ba81af855977d7011850e79099e6) - `@npmcli/arborist@1.0.12` - - fixes some windows specific bugs in how paths are handled and compared - -### DOCUMENTATION - -* [`084a7b6ad`](https://github.com/npm/cli/commit/084a7b6ad6eaf9f2d92eb05da93e745f5357cce2) - [#2210](https://github.com/npm/cli/issues/2210) - docs: Fix typo - ([@HollowMan6](https://github.com/HollowMan6)) - -## 7.0.12 (2020-11-17) - -### BUG FIXES - -* [`7b89576bd`](https://github.com/npm/cli/commit/7b89576bd1fa557a312a841afa66b895558d1b12) - [#2174](https://github.com/npm/cli/issues/2174) - fix running empty scripts with `npm run-script` - ([@nlf](https://github.com/nlf)) -* [`bc9afb195`](https://github.com/npm/cli/commit/bc9afb195f5aad7c06bc96049c0f00dc8e752dee) - [#2002](https://github.com/npm/cli/issues/2002) - [#2184](https://github.com/npm/cli/issues/2184) - Preserve builtin conf when installing npm globally - ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES - -* [`b74c05d88`](https://github.com/npm/cli/commit/b74c05d88dc48fabef031ea66ffaa4e548845655) - `@npmcli/run-script@1.8.0` - * fix windows command-line argument escaping - -### DOCUMENTATION - -* [`4e522fdc9`](https://github.com/npm/cli/commit/4e522fdc917bc85af2ca8ff7669a0178e2f35123) - [#2179](https://github.com/npm/cli/issues/2179) - remove mention to --parseable option from `npm audit` docs - ([@Primajin](https://github.com/Primajin)) - -## 7.0.11 (2020-11-13) - -### DEPENDENCIES - -* [`629a667a9`](https://github.com/npm/cli/commit/629a667a9b30b0b870075da965606979622a5e2e) - `eslint@7.13.0` -* [`de9891bd2`](https://github.com/npm/cli/commit/de9891bd2a16fe890ff5cfb140c7b1209aeac0de) - `eslint-plugin-standard@4.1.0` -* [`c3e7aa31c`](https://github.com/npm/cli/commit/c3e7aa31c565dfe21cd1f55a8433bfbcf58aa289) - [#2123](https://github.com/npm/cli/issues/2123) - [#1957](https://github.com/npm/cli/issues/1957) - `@npmcli/arborist@1.0.11` - -### BUG FIXES - -* [`a8aa38513`](https://github.com/npm/cli/commit/a8aa38513ad5c4ad44e6bb3e1499bfc40c31e213) - [#2134](https://github.com/npm/cli/issues/2134) - [#2156](https://github.com/npm/cli/issues/2156) - Fix `cannot read property length of undefined` in `ERESOLVE` explanation code - ([@isaacs](https://github.com/isaacs)) -* [`1dbf0f9bb`](https://github.com/npm/cli/commit/1dbf0f9bb26ba70f4c6d0a807701d7652c31d7d4) - [#2150](https://github.com/npm/cli/issues/2150) - [#2155](https://github.com/npm/cli/issues/2155) - send json errors to stderr, not stdout - ([@isaacs](https://github.com/isaacs)) -* [`fd1d7a21b`](https://github.com/npm/cli/commit/fd1d7a21b247bb35d112c51ff8d8a06fd83c8b44) - [#1927](https://github.com/npm/cli/issues/1927) - [#2154](https://github.com/npm/cli/issues/2154) - Set process.title a bit more usefully - ([@isaacs](https://github.com/isaacs)) -* [`2a80c67ef`](https://github.com/npm/cli/commit/2a80c67ef8c12c3d9d254f5be6293a6461067d99) - [#2008](https://github.com/npm/cli/issues/2008) - [#2153](https://github.com/npm/cli/issues/2153) - Support legacy auth tokens for registries that use them - ([@ruyadorno](https://github.com/ruyadorno)) -* [`786e36404`](https://github.com/npm/cli/commit/786e36404068fd51657ddac766e066a98754edbf) - [#2017](https://github.com/npm/cli/issues/2017) - [#2159](https://github.com/npm/cli/issues/2159) - pass all options to Arborist for `npm ci` - ([@darcyclarke](https://github.com/darcyclarke)) -* [`b47ada7d1`](https://github.com/npm/cli/commit/b47ada7d1623e9ee586ee0cf781ee3ac5ea3c223) - [#2161](https://github.com/npm/cli/issues/2161) - fixed typo - ([@scarabedore](https://github.com/scarabedore)) - -## 7.0.10 (2020-11-10) - -### DOCUMENTATION - -* [`e48badb03`](https://github.com/npm/cli/commit/e48badb03058286a557584d7319db4143049cc6b) - [#2148](https://github.com/npm/cli/issues/2148) - Fix link in documentation - ([@gurdiga](https://github.com/gurdiga)) - -### BUG FIXES - -* [`8edbbdc70`](https://github.com/npm/cli/commit/8edbbdc706694fa32f52d0991c76ae9f207b7bbc) - [#1972](https://github.com/npm/cli/issues/1972) - Support exec auto pick bin when all bin is alias - ([@dr-js](https://github.com/dr-js)) - -### DEPENDENCIES - -* [`04a3e8c10`](https://github.com/npm/cli/commit/04a3e8c10c3f38e1c7a35976d77c2929bdc39868) - [#1962](https://github.com/npm/cli/issues/1962) - `@npmcli/arborist@1.0.10`: - * prevent self-assignment of parent/fsParent - * Support update options in global package space - -## 7.0.9 (2020-11-06) - -### BUG FIXES - -* [`96a0d2802`](https://github.com/npm/cli/commit/96a0d2802d3e619c6ea47290f5c460edfe94070a) - default the 'start' script when server.js present - ([@isaacs](https://github.com/isaacs)) -* [`7716e423e`](https://github.com/npm/cli/commit/7716e423ee92a81730c0dfe5b9ecb4bb41a3f947) - [#2075](https://github.com/npm/cli/issues/2075) - [#2071](https://github.com/npm/cli/issues/2071) print the registry when - using 'npm login' ([@Wicked7000](https://github.com/Wicked7000)) -* [`7046fe10c`](https://github.com/npm/cli/commit/7046fe10c5035ac57246a31ca8a6b09e3f5562bf) - [#2122](https://github.com/npm/cli/issues/2122) tests for `npm cache` - command ([@nlf](https://github.com/nlf)) - -### DEPENDENCIES - -* [`74325f53b`](https://github.com/npm/cli/commit/74325f53b9d813b0e42203c037189418fad2f64a) - [#2124](https://github.com/npm/cli/issues/2124) - `@npmcli/run-script@1.7.5`: - * Export the `isServerPackage` method - * Proxy signals to and from foreground child processes -* [`0e58e6f6b`](https://github.com/npm/cli/commit/0e58e6f6b8f0cd62294642a502c17561aaf46553) - [#1984](https://github.com/npm/cli/issues/1984) - [#2079](https://github.com/npm/cli/issues/2079) - [#1923](https://github.com/npm/cli/issues/1923) - [#606](https://github.com/npm/cli/issues/606) - [#2031](https://github.com/npm/cli/issues/2031) `@npmcli/arborist@1.0.9`: - * Process deps for all link nodes - * Use junctions instead of symlinks - * Use @npmcli/move-file instead of fs.rename -* [`1dad328a1`](https://github.com/npm/cli/commit/1dad328a17d93def7799545596b4eba9833b35aa) - [#1865](https://github.com/npm/cli/issues/1865) - [#2106](https://github.com/npm/cli/issues/2106) - [#2084](https://github.com/npm/cli/issues/2084) `pacote@11.1.13`: - * Properly set the installation command for `prepare` scripts when - installing git/dir deps -* [`e090d706c`](https://github.com/npm/cli/commit/e090d706ca637d4df96d28bff1660590aa3f3b62) - [#2097](https://github.com/npm/cli/issues/2097) `libnpmversion@1.0.7`: - * Do not crash when the package.json file lacks a 'version' field -* [`8fa541a10`](https://github.com/npm/cli/commit/8fa541a10dbdc09376175db7a378cc9b33e8b17b) - `cmark-gfm@0.8.4` - -## 7.0.8 (2020-11-03) - -### DOCUMENTATION - -* [`052e977b9`](https://github.com/npm/cli/commit/052e977b9d071e1b3654976881d10cd3ddcba788) - [#1822](https://github.com/npm/cli/issues/1822) - [#1247](https://github.com/npm/cli/issues/1247) - add section on peerDependenciesMeta field in package.json - ([@foxxyz](https://github.com/foxxyz)) -* [`52d32d175`](https://github.com/npm/cli/commit/52d32d1758c5ebc58944a1e8d98d57e30048e527) - [#1970](https://github.com/npm/cli/issues/1970) - match npm-exec.md -p usage with lib/exec.js - ([@dr-js](https://github.com/dr-js)) -* [`48ee8d01e`](https://github.com/npm/cli/commit/48ee8d01edd11ed6186c483e1169ff4d2070b963) - [#2096](https://github.com/npm/cli/issues/2096) - Fix RFC links in changelog - ([@jtojnar](https://github.com/jtojnar)) - - -### BUG FIXES - -* [`6cd3cd08a`](https://github.com/npm/cli/commit/6cd3cd08af56445e13757cac3af87f3e7d54ed27) - Support *all* conf keys in publishConfig -* [`a1f9be8a7`](https://github.com/npm/cli/commit/a1f9be8a7f9b7a3a813fc3e5e705bc982470b0e2) - [#2074](https://github.com/npm/cli/issues/2074) - Support publishing any kind of spec, not just directories - -### DEPENDENCIES - -* [`545382df6`](https://github.com/npm/cli/commit/545382df62e3014f3e51d7034e52498fb2b01a37) - `libnpmpublish@4.0.0`: - * Support publishing things other than folders -* [`7d88f1719`](https://github.com/npm/cli/commit/7d88f17197e3c8cca9b277378d6f9b054b1b7886) - `npm-registry-fetch@9.0.0` -* [`823b40a4e`](https://github.com/npm/cli/commit/823b40a4e9c6ef76388af6fe01a3624f6f7675be) - `pacote@11.1.12` -* [`90bf57826`](https://github.com/npm/cli/commit/90bf57826edf2f78ddf8deb0793115ead8a8b556) - `npm-profile@5.0.2` -* [`e5a413577`](https://github.com/npm/cli/commit/e5a4135770d13cf114fac439167637181f87d824) - `libnpmteam@2.0.2` -* [`fc5aa7b4a`](https://github.com/npm/cli/commit/fc5aa7b4ad45cb65893f734e1229a6720f7966e5) - `libnpmsearch@3.0.1` -* [`9fc1dee13`](https://github.com/npm/cli/commit/9fc1dee138ca33ecdbd57e63142b27c60cf88f9b) - `libnpmorg@2.0.1` -* [`0ea870ec5`](https://github.com/npm/cli/commit/0ea870ec5d2be1d44f050ad8bc24ed936cc45fde) - `libnpmhook@6.0.1` -* [`32fd744ea`](https://github.com/npm/cli/commit/32fd744ea745f297f0be79a80955f077a57c4ac7) - `libnpmaccess@4.0.1` -* [`fc76f3d9f`](https://github.com/npm/cli/commit/fc76f3d9fcf19e65a9373ab3d9068c4326d2f782) - `@npmcli/arborist@1.0.8` - * Fix `cannot read property 'description' of undefined` in `npm ls` - when `package-lock.json` is corrupted - * Do not allow peerDependencies to be nested under dependents in any - circumstances - * Always resolve peerDependencies in `--prefer-dedupe` mode - -## 7.0.7 (2020-10-30) - -### BUG FIXES - -* [`3990b422d`](https://github.com/npm/cli/commit/3990b422d3ff63c54d96b61596bdb8f26a45ca7b) - [#2067](https://github.com/npm/cli/pull/2067) - use sh as default unix shell, not bash - ([@isaacs](https://github.com/isaacs)) -* [`81d6ceef6`](https://github.com/npm/cli/commit/81d6ceef6947e46355eb3ddb05a73da50870dfc1) - [#1975](https://github.com/npm/cli/issues/1975) - fix npm exec on folders missing package.json - ([@ruyadorno](https://github.com/ruyadorno)) -* [`2a680e91a`](https://github.com/npm/cli/commit/2a680e91a2be1f3f03a6fbd946f74628ee1cb370) - [#2083](https://github.com/npm/cli/pull/2083) - delete the contents of `node_modules` only in `npm ci` - ([@nlf](https://github.com/nlf)) -* [`2636fe1f4`](https://github.com/npm/cli/commit/2636fe1f45383cb1b6fc164564dc49318815db37) - [#2086](https://github.com/npm/cli/pull/2086) - disable banner output if loglevel is silent in `npm run-script` - ([@macno](https://github.com/macno)) - -### DEPENDENCIES - -* [`4156f053e`](https://github.com/npm/cli/commit/4156f053ee8712a4b53a210e62fba1e6562ba43a) - `@npmcli/run-script@1.7.4` - * restore the default `npm start` script -* [`1900ae9ad`](https://github.com/npm/cli/commit/1900ae9adecd227dd6f8b49de61a99c978ba89cf) - `@npmcli/promise-spawn@1.3.2` - * fix errors when processing scripts as root -* [`8cb0c166c`](https://github.com/npm/cli/commit/8cb0c166ccc019146a7a94d13c12723f001d2551) - `@npmcli/arborist@1.0.6` - * make sure missing bin links get set on reify - -## 7.0.6 (2020-10-27) - -### BUG FIXES - -* [`46c7f792a`](https://github.com/npm/cli/commit/46c7f792ab16dd0b091e1ad6d37de860c8885883) - [#2047](https://github.com/npm/cli/pull/2047) - [#1935](https://github.com/npm/cli/issues/1935) - skip the prompt when in a known ci environment - ([@nlf](https://github.com/nlf)) -* [`f8f6e1fad`](https://github.com/npm/cli/commit/f8f6e1fad8057edc02e4ce4382b1bc086d01211c) - [#2049](https://github.com/npm/cli/pull/2049) - properly remove pycache in release script - ([@MylesBorins](https://github.com/MylesBorins)) -* [`5db95b393`](https://github.com/npm/cli/commit/5db95b393e9c461ad34c1774f3515c322bf375bf) - [#2050](https://github.com/npm/cli/pull/2050) - pack: do not show individual files of bundled deps - ([@isaacs](https://github.com/isaacs)) -* [`3ee8f3b34`](https://github.com/npm/cli/commit/3ee8f3b34055da2ef1e735e1a06f64593512f1e3) - [#2051](https://github.com/npm/cli/pull/2051) - view: Better errors when package.json is not JSON - ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES - -* [`99ae633f6`](https://github.com/npm/cli/commit/99ae633f6ccc8aa93dc3dcda863071658b0653db) - `libnpmversion@1.0.6` - - respect gitTagVersion = false -* [`d4173f58d`](https://github.com/npm/cli/commit/d4173f58ddefdd5456145f34f3c9f4ba5fca407e) - `@npmcli/promise-spawn@1.3.1` - - do not return empty buffer when stdio is inherited - - attach child process to returned promise -* [`c09380fa5`](https://github.com/npm/cli/commit/c09380fa51b720141a9971602f4bb7aabd4d6242) - `@npmcli/run-script@1.7.3` - - forward SIGINT and SIGTERM to children that inherit stdio -* [`b154861ad`](https://github.com/npm/cli/commit/b154861ad244b6a14020c43738d0cce1948bfdd3) - `@npmcli/arborist@1.0.5` -* [`ffea6596b`](https://github.com/npm/cli/commit/ffea6596b8653da32a2b4c9a4903970e7146eee4) - `agent-base@6.0.2` - - support http proxy for https registries - -## 7.0.5 (2020-10-23) - -* [`77ad86b5e`](https://github.com/npm/cli/commit/77ad86b5eedf139dda3329a6686d5f104dc233bb) - Merge docs deps with main project - -## 7.0.4 (2020-10-23) - -### DOCUMENTATION - -* [`cc026daf8`](https://github.com/npm/cli/commit/cc026daf8c8330256de01375350a1407064562f9) - docs: `npm-dedupe` through `npm-install` -* [`aec77acf8`](https://github.com/npm/cli/commit/aec77acf886d73f85e747cafdf7a2b360befba16) - [#1915](https://github.com/npm/cli/pull/1915) - use "dockhand" for faster static documentation generation - ([@ethomson](https://github.com/ethomson)) -* [`aeb10d210`](https://github.com/npm/cli/commit/aeb10d210816cf6829e0ac557c79d9efd8c4bdd1) - [#2024](https://github.com/npm/cli/pull/2024) - Fix post-install script name - ([@irajtaghlidi](https://github.com/irajtaghlidi)) - -### BUG FIXES - -* [`59e8dd6c6`](https://github.com/npm/cli/commit/59e8dd6c621f9a5c6e0b65533d8256be87a8e0d3) - [#2015](https://github.com/npm/cli/issues/2015) - [#2016](https://github.com/npm/cli/pull/2016) - Properly set `npm_command` environment variable. - -### TESTS - -* [`39ad1ad9e`](https://github.com/npm/cli/commit/39ad1ad9e1e1a9530db5b90a588b5081b71abc8d) - [#2001](https://github.com/npm/cli/pull/2001) - `npm config` tests - ([@ruyadorno](https://github.com/ruyadorno)) -* [`b9c1caa8e`](https://github.com/npm/cli/commit/b9c1caa8e4cc7c900d09657425ea361db5974319) - [#2026](https://github.com/npm/cli/pull/2026) - `npm owner` test and refactor - ([@ruyadorno](https://github.com/ruyadorno)) - -### DEPENDENCIES - -* [`ed6e6a9d3`](https://github.com/npm/cli/commit/ed6e6a9d3c36ffc5fb77fc25b6d66dbcb26beeb9) - `eslint-plugin-standard@4.0.2` -* [`b737ee999`](https://github.com/npm/cli/commit/b737ee99961364827bacf210a3e5ca5d2b7edad2) - [#2009](https://github.com/npm/cli/issues/2009) - [#2007](https://github.com/npm/cli/issues/2007) - `npm-packlist@2.1.4`: - - * Maintain order in package.json files array globs - * Strip slashes from package files list results - -* [`783965508`](https://github.com/npm/cli/commit/783965508d49f8ab0d8ceff38bee700cd0a06a54) - [#1997](https://github.com/npm/cli/issues/1997) - [#2000](https://github.com/npm/cli/issues/2000) - [#2005](https://github.com/npm/cli/issues/2005) - `@npmcli/arborist@1.0.4` - - * Ensure that root is added when root.meta is set - * Include all edges in explain() output when a root edge exists - * Do not conflict on meta-peers that will not be replaced - * Install peerOptionals if explicitly requested, or dev - -## 7.0.3 (2020-10-20) - -### BUG FIXES - -* [`ce4724a38`](https://github.com/npm/cli/commit/ce4724a3835ded9a4a29d8d67323f925461155e5) - [#1986](https://github.com/npm/cli/pull/1986) - check `result` when determining exit code of `ls <filter>` - ([@G-Rath](https://github.com/G-Rath)) -* [`00d926f8d`](https://github.com/npm/cli/commit/00d926f8d884872d08d9a0cd73aa9cace2acb91b) - [#1987](https://github.com/npm/cli/pull/1987) - don't suppress run output when `--silent` is passed - ([@G-Rath](https://github.com/G-Rath)) -* [`043da2347`](https://github.com/npm/cli/commit/043da234745f36d55742e827314837dead5807ab) - improve cache clear error message - ([@isaacs](https://github.com/isaacs)) - -### DOCUMENTATION - -* [`a57f5c466`](https://github.com/npm/cli/commit/a57f5c466ceae59575ef05bb7941cce8752d8c58) - update docs for: access, adduser, audit, bin, bugs, build, cache, ci, - completion, config and dedupe - ([@isaacs](https://github.com/isaacs)) -* [`5b88b72b9`](https://github.com/npm/cli/commit/5b88b72b9821f7114cc4e475bbf52726a1674e52) - remove the long-gone bundle command - ([@isaacs](https://github.com/isaacs)) -* [`ae09aa5c1`](https://github.com/npm/cli/commit/ae09aa5c1cd150727b05ccfaeaba8d45e5697e50) - [#1993](https://github.com/npm/cli/pull/1993) - document --save-peer as a common option to npm install - ([@JakeChampion](https://github.com/JakeChampion)) -* [`c9993e6b1`](https://github.com/npm/cli/commit/c9993e6b1c2918699c2d125bf9b966f44f5d3ebe) - [#1982](https://github.com/npm/cli/pull/1982) - fix url links for init-package-json/node-semver - ([@takenspc](https://github.com/takenspc)) - -### DEPENDENCIES - -* [`5d9df8395`](https://github.com/npm/cli/commit/5d9df83958d3d5e6d8acad2ebabfbe5f3fd23c13) - `node-gyp@7.1.2` - -## 7.0.2 (2020-10-16) - -### DOCUMENTATION - -* [`9476734b7`](https://github.com/npm/cli/commit/9476734b7d5fa6df80ad17ad277a6bee9a16235c) - [#1967](https://github.com/npm/cli/pull/1967) - add mention to workspaces prepare lifecycle - ([@ruyadorno](https://github.com/ruyadorno)) - -### BUG FIXES - -* [`5cf71c689`](https://github.com/npm/cli/commit/5cf71c689bcfcd423405e59d05b7cc5704cb4c02) - [#1971](https://github.com/npm/cli/pull/1971) - owner rm at local pkg not work - ([@ShangguanQuail](https://github.com/ShangguanQuail)) - -### DEPENDENCIES - -* [`722b7ae63`](https://github.com/npm/cli/commit/722b7ae63da8b386fe188066dc2dae0121d9353b) - [#1974](https://github.com/npm/cli/pull/1974) - patch node-gyp - ([@targos](https://github.com/MylesBorins)) -* [`4ae825c01`](https://github.com/npm/cli/commit/4ae825c01c7ca3031361f9df72594a190c6ed1e4) - [#1976](https://github.com/npm/cli/pull/1976) - patch node-gyp - ([@MylesBorins](https://github.com/MylesBorins)) -* [`181eabf13`](https://github.com/npm/cli/commit/181eabf132c823af086380368de73d2f42e5aac1) - `@npmcli/arborist@1.0.3` - * fix workspaces `prepare` lifecycle scripts - * fix peer deps overchecks resulting in ERESOLVE -* [`6cc115409`](https://github.com/npm/cli/commit/6cc115409b7eb2df8e11db6232ee3d00e4316a7d) - `init-package-json@2.0.1` -* [`dbf9d6d1f`](https://github.com/npm/cli/commit/dbf9d6d1f060ea43b700409306574396a798127d) - `libnpmpublish@3.0.2` - -## 7.0.1 (2020-10-15) - -### DOCUMENTATION - -* [`03fca6a3b`](https://github.com/npm/cli/commit/03fca6a3b227f71562863bec7a1de1732bd719f1) - Adds docs on workspaces, explaining its basic concept and how to use it. - ([@ruyadorno](https://github.com/ruyadorno)) - -### BUG FIXES - -* [`2ccb63659`](https://github.com/npm/cli/commit/2ccb63659f9a757201658d5d019099b492d04a5b) - [#1951](https://github.com/npm/cli/issues/1951) - [#1956](https://github.com/npm/cli/pull/1956) - Handle errors from audit endpoint appropriately - ([@isaacs](https://github.com/isaacs)) - -### DEPENDENCIES - -* [`120e62736`](https://github.com/npm/cli/commit/120e6273604f15a2ce55668dfb2c23d06bf1e06c) - `node-gyp@7.1.1` -* [`6560b8d95`](https://github.com/npm/cli/commit/6560b8d952a613cefbd900186aa38df53bc201d1) - `@npmcli/arborist@1.0.2` - * do not drop scope information when fetching scoped package tarballs - * fix cycles/ordering resolution when peer deps require nesting -* [`282a1e008`](https://github.com/npm/cli/commit/282a1e00820b9abfb3465d044b30b2cade107909) - `npm-user-validate@1.0.1` -* [`b259edcb4`](https://github.com/npm/cli/commit/b259edcb4bac37e6f26d56af5f6666afbda8c126) - `hosted-git-info@3.0.7` - -## v7.0.0 (2020-10-12) - -### BUG FIXES - -* [`7bcdb3636`](https://github.com/npm/cli/commit/7bcdb3636e29291b9c722fe03a8450859dcb5b4f) - [#1949](https://github.com/npm/cli/pull/1949) fix: ensure `publishConfig` - is passed through ([@nlf](https://github.com/nlf)) -* [`97978462e`](https://github.com/npm/cli/commit/97978462e9050261e4ce2549e71fe94a48796577) - fix: patch `config.js` to remove duplicate vals - ([@darcyclarke](https://github.com/darcyclarke)) - -### DOCUMENTATION - -* [`60769d757`](https://github.com/npm/cli/commit/60769d757859c88e2cceab66975f182a47822816) - [#1911](https://github.com/npm/cli/pull/1911) docs: v7 npm-install - refresh ([@ruyadorno](https://github.com/ruyadorno)) -* [`08de49042`](https://github.com/npm/cli/commit/08de4904255742cbf7477a20bdeebe82f283a406) - [#1938](https://github.com/npm/cli/pull/1938) docs: v7 using npm config - updates ([@ruyadorno](https://github.com/ruyadorno)) - -### DEPENDENCIES - -* [`15366a1cf`](https://github.com/npm/cli/commit/15366a1cf0073327b90ac7eb977ff8a73b52cc62) - `npm-registry-fetch@8.1.5` -* [`f04a74140`](https://github.com/npm/cli/commit/f04a74140bf65db36be3c379e0eb20dd6db3cc5c) - `init-package-json@2.0.0` - * [`1de21dce0`](https://github.com/npm/cli/commit/1de21dce0e56874203a789ce33124a4fc4d3b15f) - fix: support dot-separated aliases defined in a `.npmrc` ini files - for `init-*` configs ([@ruyadorno](https://github.com/ruyadorno)) -* [`a67275cd9`](https://github.com/npm/cli/commit/a67275cd9a75fa05ee3d3265832d0a015b14e81c) - `eslint@7.11.0` -* [`6fb83b78d`](https://github.com/npm/cli/commit/6fb83b78db09adfafd7cbd4b926e77802c4993e4) - `hosted-git-info@3.0.6` -* [`1ca30cc9b`](https://github.com/npm/cli/commit/1ca30cc9b8e7edc2043c1f848855f19781729dc9) - `libnpmfund@1.0.0` -* [`28a2d2ba4`](https://github.com/npm/cli/commit/28a2d2ba4a63808614f5d98685a64531e3198b93) - `@npmcli/arborist@1.0.0` - * [npm/rfcs#239](https://github.com/npm/rfcs/pull/239) Improve handling - of conflicting `peerDependencies` in transitive dependencies, so that - `--force` will always accept a best effort override, and - `--strict-peer-deps` will fail faster on conflicts. -* [`9306c6833`](https://github.com/npm/cli/commit/9306c6833e2e77675e0cfddd569b6b54a8bcf172) - `libnpmfund@1.0.1` -* [`fafb348ef`](https://github.com/npm/cli/commit/fafb348ef976116d47ada238beb258d5db5758a7) - `npm-package-arg@8.1.0` -* [`365f2e756`](https://github.com/npm/cli/commit/365f2e7565d0cfde858a43d894a77fb3c6338bb7) - `read-package-json@3.0.0` - -## v7.0.0-rc.4 (2020-10-09) - -* [`09b456f2d`](https://github.com/npm/cli/commit/09b456f2d776e2757956d2b9869febd1e01a1076) - `@npmcli/config@1.2.1` - * [#1919](https://github.com/npm/cli/pull/1919) - exposes `npm_config_user_agent` env variable - ([@nlf](https://github.com/nlf)) -* [`e859fba9e`](https://github.com/npm/cli/commit/e859fba9e7c267b0587b7d22da72e33f3e8f906b) - [#1936](https://github.com/npm/cli/pull/1936) - fix npx for non-interactive shells - ([@nlf](https://github.com/nlf)) -* [`9320b8e4f`](https://github.com/npm/cli/commit/9320b8e4f0e0338ea95e970ec9bbf0704def64b8) - [#1906](https://github.com/npm/cli/pull/1906) - restore old npx behavior of running existing bins first - ([@nlf](https://github.com/nlf)) -* [`7bd47ca2c`](https://github.com/npm/cli/commit/7bd47ca2c718df0a7d809f1992b7a87eece3f6dc) - `@npmcli/arborist@0.0.33` - * fixed handling of invalid package.json file -* [`02737453b`](https://github.com/npm/cli/commit/02737453bc2363daeef8c4e4b7d239e2299029b2) - `make-fetch-happen@8.0.10` - * do not calculate integrity values of http errors - -## v7.0.0-rc.3 (2020-10-06) - -* [`d816c2efa`](https://github.com/npm/cli/commit/d816c2efae41930cbdf4fff8657e0adc450d1dd4) - [`c8f0d5457`](https://github.com/npm/cli/commit/c8f0d5457dd913b425987ae30a611d4eb9e84b7d) - [`d48086d0d`](https://github.com/npm/cli/commit/d48086d0d3e006e76f364fb2c62b406a97ce8f68) - [`f34595f2e`](https://github.com/npm/cli/commit/f34595f2e5814a929049aca0349ce418a7f400c6) - [#1902](https://github.com/npm/cli/pull/1902) - tests for several commands - ([@nlf](https://github.com/nlf)) -* [`6d49207db`](https://github.com/npm/cli/commit/6d49207dbc5d66f91f4f462f05dd8916046e3a7b) - [#1903](https://github.com/npm/cli/pull/1903) - Revert "Remove unused npx binary" - ([@MylesBorins](https://github.com/MylesBorins)) -* [`138dfc202`](https://github.com/npm/cli/commit/138dfc202f401d2d93b4b5d2499799be6eb4ff0b) - set executable permissions on bins that node installer uses -* [`b06d68078`](https://github.com/npm/cli/commit/b06d68078830cc2446b1e51553db10e87591865b) - `@npmcli/arborist@0.0.32` - * Do not remove `node_modules` folders from Workspaces when - `loadActual` races with `buildIdealTree` ([@ruyadorno](https://github.com/ruyadorno)) -* [`2509e3a1b`](https://github.com/npm/cli/commit/2509e3a1bf76289062f1f6f06eee184df386054b) - `uuid@8.3.1` - -## v7.0.0-rc.2 (2020-10-02) - -* [`6de81a013`](https://github.com/npm/cli/commit/6de81a013833e0961abdec6f7c1ad50b63faaae6) - `@npmcli/run-script@1.7.2` - * Fix regression running 'install' scripts when package.json does not - contain a scripts object - -## v7.0.0-rc.1 (2020-10-02) - -* [`281a7f39a`](https://github.com/npm/cli/commit/281a7f39ac314bd7657ce2bcd7918b21eee99210) - `@npmcli/arborist@0.0.31` - * Allow `npm update` to update bundled root dependencies - * Only do implicit node-gyp build for gyp files named `binding.gyp` -* [`384f5ec47`](https://github.com/npm/cli/commit/384f5ec47091eed66c2a47f2c98df3ba7506ec9f) - update minipass-fetch to fix many 'cb() never called' errors -* [`7b1e75906`](https://github.com/npm/cli/commit/7b1e75906351bd73cde2f745ccaf63b9ad7de435) - `@npmcli/run-script@1.7.1` - * Only do implicit node-gyp build for gyp files named `binding.gyp` -* [`c20e2f0c7`](https://github.com/npm/cli/commit/c20e2f0c7766a04f999fdc64faad29277904c2d3) - [#1892](https://github.com/npm/cli/pull/1892) - Support `--omit` options in npm outdated - -## v7.0.0-rc.0 (2020-10-01) - -* [`3b417055c`](https://github.com/npm/cli/commit/3b417055cf07c4ef8e4c5063f00d3c24b5f5cbd2) - [#1859](https://github.com/npm/cli/pull/1859) - fix `proxy` and `https-proxy` config support - ([@badeggg](https://github.com/badeggg)) -* [`dd7d7a284`](https://github.com/npm/cli/commit/dd7d7a284d5150d1804d0cd5a85519c86adf3bc2) - `@npmcli/arborist@0.0.30` - * [#1849](https://github.com/npm/cli/issues/1849) Do not drop peer/dev - dep while saving if both set - * Do not install or build if there is a global top bin conflict - * Default to building node-gyp dependencies -* [`40c17e12c`](https://github.com/npm/cli/commit/40c17e12c5a734c37b88692e36221ac974c0c63d) - `cli-table3@0.6.0` -* [`47a8ca1d7`](https://github.com/npm/cli/commit/47a8ca1d72f0f0835b45cfb2c4fb8ab1218dc14a) - `byte-size@7.0.0` -* [`81073f99a`](https://github.com/npm/cli/commit/81073f99a93b680e3ca08b8f099e9aca2aaf50be) - `eslint@7.10.0` -* [`67793abd4`](https://github.com/npm/cli/commit/67793abd4abdf315816b6266ddb045289f607b03) - `eslint-plugin-import@2.22.1` -* [`a27e8d006`](https://github.com/npm/cli/commit/a27e8d00664e5d4c3e81d664253a10176adb39c8) - `is-cidr@4.0.2` -* [`893fed45e`](https://github.com/npm/cli/commit/893fed45e2272ef764ebf927c659fcf5e7b355b3) - `marked-man@0.7.0` -* [`bc20e0c8a`](https://github.com/npm/cli/commit/bc20e0c8ae30a202c72af88586ab9c167dff980a) - `rimraf@3.0.2` -* [`a2b8fd3c1`](https://github.com/npm/cli/commit/a2b8fd3c153ecca55cb2d60654fff207688532ab) - `uuid@8.3.0` -* [`ee4c85b87`](https://github.com/npm/cli/commit/ee4c85b878410143644460c3860ab706a8c925e0) - `write-file-atomic@3.0.3` -* [`4bdad5fdf`](https://github.com/npm/cli/commit/4bdad5fdf6ef387e2159b529ba4652f0221433b5) - `bin-links@2.2.1` -* [`c394937ec`](https://github.com/npm/cli/commit/c394937ec1911cd17ec42c8fc74773047d47322c) - `@npmcli/run-script@1.7.0` - * Default to building node-gyp dependencies and projects -* remove many unused dependencies - ([@ruyadorno](https://github.com/ruyadorno)) - * [`558e9781a`](https://github.com/npm/cli/commit/558e9781ada06b66be4d2d5d0f7e763f645eda25) - deep-equal - * [`2aa9a1f8a`](https://github.com/npm/cli/commit/2aa9a1f8a5773b9a960b14b51c8111fb964bc9ae) - request - * [`d77594e52`](https://github.com/npm/cli/commit/d77594e52f2f7d65d45347f542f48e4dbb6d2f26) - npm-registry-couchapp - * [`8ec84d9f6`](https://github.com/npm/cli/commit/8ec84d9f691686da67bd14c2728472c94ab3b955) - tacks - * [`a07b421f7`](https://github.com/npm/cli/commit/a07b421f708c13d8239e7283ad89611b24b23d0a) - lincesee - * [`41126e165`](https://github.com/npm/cli/commit/41126e165d3d5625a55e140b84fdd02052520146) - npm-cache-filename - * [`130da51b5`](https://github.com/npm/cli/commit/130da51b553e550584f31e2a8a961f4338f2a0cd) - npm-registry-mock - * [`b355af486`](https://github.com/npm/cli/commit/b355af48696bb5001c6d2b938974d9ab9f5e2360) - sprintf-js - * [`721c0a873`](https://github.com/npm/cli/commit/721c0a8736f3cd0a0e75e0b89518a431553843c6) - uid-number - * [`9c920e5f5`](https://github.com/npm/cli/commit/9c920e5f584e4d912aabc6e412693f7142242a89) - umask - * [`aae1c38bb`](https://github.com/npm/cli/commit/aae1c38bbb983cf40e9b3df012b18bebba5e5400) - config-chain - * [`450845eac`](https://github.com/npm/cli/commit/450845eaceb7e178c8ec7867a67e5cc948986904) - find-npm-prefix - * [`963d542d3`](https://github.com/npm/cli/commit/963d542d385c7fe26830a885fe40d96010d01862) - has-unicode - * [`cad9cbc70`](https://github.com/npm/cli/commit/cad9cbc70561c8638ed6e56286f753693f411000) - infer-owner - * [`3ae02914d`](https://github.com/npm/cli/commit/3ae02914d49f3302d25c85d2242096bb2291f9f4) - lockfile - * [`7bc474d7c`](https://github.com/npm/cli/commit/7bc474d7cb2e2e083fd8358d0648d7c5fb43707f) - once - * [`5c5e0099a`](https://github.com/npm/cli/commit/5c5e0099a4708ec84da3d2e427e16c4a9cfe3c8a) - retry - * [`cfaddd334`](https://github.com/npm/cli/commit/cfaddd334b8b1eddcefa3cd2a9b823ec140271a4) - sha - * [`3a978ffc7`](https://github.com/npm/cli/commit/3a978ffc7fddd6802c81996a5710b2efd15edc11) - slide - -## v7.0.0-beta.13 (2020-09-29) - -* [`405e051f7`](https://github.com/npm/cli/commit/405e051f724a2e79844f78f8ea9ba019fdc513aa) - Fix EBADPLATFORM error message - ([@#1876](https://github.com/#1876)) -* [`e4d911d21`](https://github.com/npm/cli/commit/e4d911d219899c0fdc12f8951b7d70e0887909f8) - `@npmcli/arborist@0.0.28` - * fix: workspaces install entering an infinite loop - * Save provided range if not a subset of savePrefix - * package-lock.json custom indentation - * Check engine and platform when building ideal tree -* [`90550b2e0`](https://github.com/npm/cli/commit/90550b2e023e7638134e91c80ed96828afb41539) - [#1853](https://github.com/npm/cli/pull/1853) - test coverage and refactor for token command - ([@nlf](https://github.com/nlf)) -* [`2715220c9`](https://github.com/npm/cli/commit/2715220c9b5d3f325e65e95bae2b5af8a485a579) - [#1858](https://github.com/npm/cli/pull/1858) - [#1813](https://github.com/npm/cli/issues/1813) - do not include omitted optional dependencies in install output - ([@ruyadorno](https://github.com/ruyadorno)) -* [`e225ddcf8`](https://github.com/npm/cli/commit/e225ddcf8d74a6b1cfb24ec49e37e3f5d06e5151) - [#1862](https://github.com/npm/cli/pull/1862) - [#1861](https://github.com/npm/cli/issues/1861) - respect depth when running `npm ls <pkg>` - ([@ruyadorno](https://github.com/ruyadorno)) -* [`2469ae515`](https://github.com/npm/cli/commit/2469ae5153fa4114a72684376a1b226aa07edf81) - [#1870](https://github.com/npm/cli/pull/1870) - [#1780](https://github.com/npm/cli/issues/1780) - Add 'fetch-timeout' config - ([@isaacs](https://github.com/isaacs)) -* [`52114b75e`](https://github.com/npm/cli/commit/52114b75e83db8a5e08f23889cce41c89af9eb93) - [#1871](https://github.com/npm/cli/pull/1871) - fix `npm ls` for linked dependencies - ([@ruyadorno](https://github.com/ruyadorno)) -* [`9981211c0`](https://github.com/npm/cli/commit/9981211c070ce2b1e34d30223d12bd275adcacf5) - [#1857](https://github.com/npm/cli/pull/1857) - [#1703](https://github.com/npm/cli/issues/1703) - fix `npm outdated` parsing invalid specs - ([@ruyadorno](https://github.com/ruyadorno)) - -## v7.0.0-beta.12 (2020-09-22) - -* [`24f3a5448`](https://github.com/npm/cli/commit/24f3a5448f021ad603046dfb9fd97ed66bd63bba) - [#1811](https://github.com/npm/cli/issues/1811) - npm ci should never save package.json or lockfile - ([@isaacs](https://github.com/isaacs)) -* [`5e780a5f0`](https://github.com/npm/cli/commit/5e780a5f067476c1d207173fc9249faf9eaac0c2) - remove unused spec parameter, assign error code - ([@nlf](https://github.com/nlf)) -* [`f019a248a`](https://github.com/npm/cli/commit/f019a248a67e8c46dbe41bf31f4818c5ca2138bf) - Remove unused npx binary - ([@isaacs](https://github.com/isaacs)) -* [`db157b3ce`](https://github.com/npm/cli/commit/db157b3ceb46327ca2089604d5f4fc9de391584e) - `@npmcli/arborist@0.0.27` - * Resolve race condition with conflicting bin links in local installs - * [#1812](https://github.com/npm/cli/issues/1812) Log engine mismatches more usefully - * [#1814](https://github.com/npm/cli/issues/1814) Do not loop trying to resolve dependencies that fail to load - * [npm/rfcs#224](https://github.com/npm/rfcs/pull/224) Do not automatically install optional peer dependencies - * Add the `strictPeerDeps` option, defaulting to `false` - * fix forwarding configs to resolve pkg spec when adding new deps -* [`b3a50d275`](https://github.com/npm/cli/commit/b3a50d27501e47c61b52c3cc4de99ff4e4641efe) - [#1846](https://github.com/npm/cli/pull/1846) - `@npmcli/run-script@1.6.0` - * This updates node-gyp to v7, allowing us to deduplicate a lot of significant dependencies. -* [`a1d375f6b`](https://github.com/npm/cli/commit/a1d375f6b0ee358be41110a49acc1c9fdb775fbe) - [#1819](https://github.com/npm/cli/pull/1819) - Add `--strict-peer-deps` option - ([@isaacs](https://github.com/isaacs)) -* [`5837a4843`](https://github.com/npm/cli/commit/5837a4843ab1f19fb62f60151f522ca0fa5449ae) - [#1699](https://github.com/npm/cli/pull/1699) - Use allow/deny list in docs - ([@luciomartinez](https://github.com/luciomartinez)) - -## v7.0.0-beta.11 (2020-09-16) - -* [`63005f4a9`](https://github.com/npm/cli/commit/63005f4a98d55786fda46f3bbb3feab044d078df) - [#1639](https://github.com/npm/cli/issues/1639) - npm view should not output extra newline ([@MylesBorins](https://github.com/MylesBorins)) -* [`3743a42c8`](https://github.com/npm/cli/commit/3743a42c854d9ea7e333d7ff86d206a4b079a352) - [#1750](https://github.com/npm/cli/pull/1750) - add outdated tests ([@claudiahdz](https://github.com/claudiahdz)) -* [`2019abdf1`](https://github.com/npm/cli/commit/2019abdf159eb13c9fb3a2bd2f35897a8f52b0d9) - [#1786](https://github.com/npm/cli/pull/1786) - add lib/link.js tests ([@ruyadorno](https://github.com/ruyadorno)) -* [`2f8d11968`](https://github.com/npm/cli/commit/2f8d11968607a74c8def3c05266049bee5e313eb) - `@npmcli/arborist@0.0.25` - * add meta vulnerability calculator for faster audits - * changed parsing specs to be relative to cwd - * fix logging script execution - * fix properly following resolved symlinks - * fix package.json dependencies order -* [`49b2bf5a7`](https://github.com/npm/cli/commit/49b2bf5a798b49d52166744088a80b8a39ccaeb6) - `@npmcli/config@1.1.8` - * fix unknown envs to be passed through - * fix setting correct globalPrefix on load -* [`f9aac351d`](https://github.com/npm/cli/commit/f9aac351dd36a19d14e1f951a2e8e20b41545822) - `libnpmversion@1.0.5` - * fix git ignored lockfiles - -## v7.0.0-beta.10 (2020-09-08) - -* [`7418970f0`](https://github.com/npm/cli/commit/7418970f03229dd2bce7973b99b981779aee6916) - Improve output of dependency node explanations -* [`5e49bdaa3`](https://github.com/npm/cli/commit/5e49bdaa34e29dbd25c687f8e6881747a86b7435) - [#1776](https://github.com/npm/cli/pull/1776) Add 'npm explain' command - -## v7.0.0-beta.9 (2020-09-04) - -* [`ef8f5676b`](https://github.com/npm/cli/commit/ef8f5676b1c90dcf44256b8ed1f61ddb6277c23a) - [#1757](https://github.com/npm/cli/pull/1757) - view: always fetch fullMetadata, and preferOnline -* [`ac5aa709a`](https://github.com/npm/cli/commit/ac5aa709a8609ec2beb7a8c60b3bde18f882f4e8) - [#1758](https://github.com/npm/cli/pull/1758) - fix scope config -* [`a36e2537f`](https://github.com/npm/cli/commit/a36e2537fd4c81df53fb6de01900beb9fa4fa0aa) - outdated: don't throw on non-version/tag/range dep -* [`371f0f062`](https://github.com/npm/cli/commit/371f0f06215ad8caf598c20e3d0d38ff597531e9) - `@npmcli/arborist@0.0.20` - - * Provide explanation objects for `ERESOLVE` errors - * Support overriding certain classes of `ERESOLVE` errors with `--force` - * Detect changes to package.json requiring package-lock dependency flag - re-evaluation - -* [`2a4e2e9ef`](https://github.com/npm/cli/commit/2a4e2e9efecb7f86147e5071c59cfc2461a5a7f5) - [#1761](https://github.com/npm/cli/pull/1761) - Explain `ERESOLVE` errors -* [`8e3e83bd4`](https://github.com/npm/cli/commit/8e3e83bd4f816bfed0efb8266985143ee9b94b86) - `@npmcli/arborist@0.0.21` - - * Remove bin links on prune - * Remove unnecessary tree walk for workspace projects - * Install workspaces on update:true - -* [`d6b134fd9`](https://github.com/npm/cli/commit/d6b134fd9005d911343831270615f80dfead7e3d) - [#1738](https://github.com/npm/cli/pull/1738) - [#1734](https://github.com/npm/cli/pull/1734) - fix package spec parsing during cache add process - ([@mjeanroy](https://github.com/mjeanroy)) -* [`f105eb833`](https://github.com/npm/cli/commit/f105eb8333fa3300c5b47464b129c1b0057ed7bf) - `npm-audit-report@2.1.4`: - - * Do not crash on cyclical meta-vulnerability references - -* [`03a9f569b`](https://github.com/npm/cli/commit/03a9f569b5121a173f14711980db297d4a04ac6b) - `opener@1.5.2` -* [`5616a23b4`](https://github.com/npm/cli/commit/5616a23b4b868d19aa100a6d86d781cc9bfd94f7) - `@npmcli/git@2.0.4` - - * Support `.git` files, so that git worktrees are respected - -## v7.0.0-beta.8 (2020-09-01) - -* [`834e62a0e`](https://github.com/npm/cli/commit/834e62a0e5b76e97cfe9ea3d3188661579ebc874) - * fix: npm ls extraneous workspaces - * `@npmcli/arborist@0.0.19` -* [`758b02358`](https://github.com/npm/cli/commit/758b02358613591ea877e26fcdb76e5b1d40f892) - [#1739](https://github.com/npm/cli/pull/1739) - add full install options to npm exec - ([@ruyadorno](https://github.com/ruyadorno)) -* [`2ee7c8a98`](https://github.com/npm/cli/commit/2ee7c8a98cf01225a3c9ac247139243f868e2e03) - `@npmcli/config@1.1.7` - ([@ruyadorno](https://github.com/ruyadorno)) - -## v7.0.0-beta.7 (2020-08-25) - -* [`b38f68acd`](https://github.com/npm/cli/commit/b38f68acd9292b7432c936db3b6d2d12e896f45d) - ensure `npm-command` HTTP header is sent properly -* [`9f200abb9`](https://github.com/npm/cli/commit/9f200abb94ea2127d9a104c225159b1b7080c82c) - Properly exit with error status code -* [`aa0152b58`](https://github.com/npm/cli/commit/aa0152b58f34f8cdae05be63853c6e0ace03236a) - [#1719](https://github.com/npm/cli/pull/1719) Detect CI properly -* [`50f9740ca`](https://github.com/npm/cli/commit/50f9740ca8000b1c4bd3155bf1bc3d58fb6f0e20) - [#1717](https://github.com/npm/cli/pull/1717) fund with multiple funding - sources ([@ruyadorno](https://github.com/ruyadorno)) -* [`3a63ecb6f`](https://github.com/npm/cli/commit/3a63ecb6f6a0b235660f73a3ffa329b1f131b0c3) - [#1718](https://github.com/npm/cli/pull/1718) - [RFC-0029](https://github.com/npm/rfcs/blob/latest/implemented/0029-add-ability-to-skip-hooks.md) - add ability to skip pre/post hooks to `npm run-script` by using - `--ignore-scripts` ([@ruyadorno](https://github.com/ruyadorno)) - -## v7.0.0-beta.6 (2020-08-21) - -* [`707207bdd`](https://github.com/npm/cli/commit/707207bddb2900d6f7a57ff864cef26cda75a71a) - add `@npmcli/config` dependency - -* [`5cb9a1d4d`](https://github.com/npm/cli/commit/5cb9a1d4d985aaa8e988c51fe5ae7f7ed3602811) - [#1688](https://github.com/npm/cli/pull/1688) use `@npmcli/config` for - configuration ([@isaacs](https://github.com/isaacs)) - -* [`a4295f5db`](https://github.com/npm/cli/commit/a4295f5db7667e8cc6b83abdad168619ad31a12f) - `npm-registry-fetch@8.1.4`: - - * Redact passwords from HTTP logs - -* [`a5a6a516d`](https://github.com/npm/cli/commit/a5a6a516d16828c1375eaf41d04468d919df4a57) - `json-parse-even-better-errors@2.3.0`: - - * Adds support for indentation/newline formatting preservation - -* [`a14054558`](https://github.com/npm/cli/commit/a1405455843db1b14938596303b29fb3ad4f90f0) - `read-package-json-fast@1.2.1`: - - * Adds support for indentation/newline formatting preservation - -* [`f8603c8af`](https://github.com/npm/cli/commit/f8603c8affefc342d81c109e4676d498a8359b78) - `libnpmversion@1.0.4`: - - * Adds support for indentation/newline formatting preservation - -* [`9891fa71c`](https://github.com/npm/cli/commit/9891fa71c88f425bef8d881c3795e5823d732e1f) - `read-package-json@2.1.2`: - - * Adds support for indentation/newline formatting preservation - -* [`b44768aac`](https://github.com/npm/cli/commit/b44768aace0e9c938ebd6d05a5de1cc4368e2d7d) - [#1662](https://github.com/npm/cli/issues/1662) - [#1693](https://github.com/npm/cli/issues/1693) - [#1690](https://github.com/npm/cli/issues/1690) - `@npmcli/arborist@0.0.17`: - - * Load root project `package.json` when running loadVirtual. - * Fetch metadata from registry when loading tree from outdated - package-lock.json file. This avoids a situation where a lockfile or - shrinkwrap from npm v5 would result in deleting dependencies on - install. - * Preserve `package.json` and `package-lock.json` formatting in all - places where these files are written. - -* [`281da6fdc`](https://github.com/npm/cli/commit/281da6fdcda3fb3860b73ed35daa234ad228c363) - `tar@6.0.5` - -* [`1faa5b33d`](https://github.com/npm/cli/commit/1faa5b33dcc6d7e4eba1c0d85ad30cf0c237c9e1) - [#1655](https://github.com/npm/cli/issues/1655) show usage when - `help-search` finds no results - -* [`10fcff73a`](https://github.com/npm/cli/commit/10fcff73a3381ea5e6dcb03888679ae4b501d2f0) - [#1695](https://github.com/npm/cli/issues/1695) fix `pulseWhileDone` - promise handling - -* [`88e4241c5`](https://github.com/npm/cli/commit/88e4241c5d4f512a4e2b09d26fcdcc7f877e65ed) - [#1698](https://github.com/npm/cli/pull/1698) add lib/logout.js unit - tests ([@ruyadorno](https://github.com/ruyadorno)) - -## v7.0.0-beta.5 (2020-08-18) - -* [`b718b0e28`](https://github.com/npm/cli/commit/b718b0e2844d9244cc63667f62ccf81864cc1092) - [#1657](https://github.com/npm/cli/pull/1657) display multiple versions - when using `--json` with `npm view` - ([@claudiahdz](https://github.com/claudiahdz)) -* [`9e7cc42f6`](https://github.com/npm/cli/commit/9e7cc42f687b479d96d222b61f76b2a30c7e6507) - [#1071](https://github.com/npm/cli/pull/1071) migrate from `meant` to - `leven` ([@jamesgeorge007](https://github.com/jamesgeorge007)) -* [`85027f40c`](https://github.com/npm/cli/commit/85027f40ca5237bd750a5633104d12bcc248551c) - [#1664](https://github.com/npm/cli/pull/1664) refactor and add tests for - `npm adduser` ([@ruyadorno](https://github.com/ruyadorno)) -* [`6e03e5583`](https://github.com/npm/cli/commit/6e03e55833d50fd0f5b7824ed14b7e2b14f70eaf) - [#1672](https://github.com/npm/cli/pull/1672) refactor and add tests for - `npm audit` ([@claudiahdz](https://github.com/claudiahdz)) - -## v7.0.0-beta.4 (2020-08-11) - -Replace some environment variables that were excluded. This implements the -[amendment to RFC0021](https://github.com/npm/rfcs/pull/183). - -* [`631142f4a`](https://github.com/npm/cli/commit/631142f4a13959fbe02dc115fb6efa55a3368795) - `@npmcli/run-script@1.5.0` -* [`da95386ae`](https://github.com/npm/cli/commit/da95386aedb3f0c0cc51761bfa750b64ac0eabc9) - [#1650](https://github.com/npm/cli/pull/1650) - [#1652](https://github.com/npm/cli/pull/1652) - include booleans, skip already-set envs - -## v7.0.0-beta.3 (2020-08-10) - -Bring back support for `npm audit --production`, fix a minor `npm version` -annoyance, and track down a very serious issue where a project could be -blown away when it matches a meta-dep in the tree. - -* [`5fb217701`](https://github.com/npm/cli/commit/5fb217701c060e37a3fb4a2e985f80fb015157b9) - [#1641](https://github.com/npm/cli/issues/1641) `@npmcli/arborist@0.0.15` -* [`3598fe1f2`](https://github.com/npm/cli/commit/3598fe1f2dfe6c55221bbac8aaf21feab74a936a) - `@npmcli/arborist@0.0.16` Add support for `npm audit --production` -* [`8ba2aeaee`](https://github.com/npm/cli/commit/8ba2aeaeeb77718cb06fe577fdd56dcdcbfe9c52) - `libnpmversion@1.0.3` - -## v7.0.0-beta.2 (2020-08-07) - -New notification style for updates, and a working doctor. - -* [`cf2819210`](https://github.com/npm/cli/commit/cf2819210327952696346486002239f9fc184a3e) - [#1622](https://github.com/npm/cli/pull/1622) - Improve abbrevs for install and help -* [`d062b2c02`](https://github.com/npm/cli/commit/d062b2c02a4d6d5f1a274aa8eb9c5969ca6253db) - new npm-specific update-notifier implementation -* [`f6d468a3b`](https://github.com/npm/cli/commit/f6d468a3b4bef0b3cc134065d776969869fca51e) - update doctor command -* [`b8b4d77af`](https://github.com/npm/cli/commit/b8b4d77af836f8c49832dda29a0de1b3c2d39233) - [#1638](https://github.com/npm/cli/pull/1638) - Direct users to our GitHub issues instead of npm.community - -## v7.0.0-beta.1 (2020-08-05) - -Fix some issues found in the beta pubish process, and initial attempts to -use npm v7 with [citgm](https://github.com/nodejs/citgm/). - -* [`2c305e8b7`](https://github.com/npm/cli/commit/2c305e8b7bfa28b07812df74f46983fad2cb85b6) - output generated tarball filename -* [`0808328c9`](https://github.com/npm/cli/commit/0808328c93d9cd975837eeb53202ce3844e1cf70) - pack: set correct filename for scoped packages - ([@isaacs](https://github.com/isaacs)) -* [`cf27df035`](https://github.com/npm/cli/commit/cf27df035cfba4f859d14859229bb90841b8fda6) - `@npmcli/arborist@0.0.14` ([@isaacs](https://github.com/isaacs)) - -## v7.0.0-beta.0 (2020-08-04) - -Major refactoring and overhaul of, well, pretty much everything. Almost -all dependencies have been updated, many have been removed, and the entire -`Installer` class is moved into -[`@npmcli/arborist`](http://npm.im/@npmcli/arborist). - -### Some High-level Changes and Improvements - -- You can install GitHub pull requests by adding `#pull/<number>` to the - git url. So it'd be something like `npm install - github:user/project#pull/123` to install PR number 123 of the - `user/project` git repo. You can of course also use this in - dependencies, or anywhere else dependency specifiers are found. -- Initial Workspaces support is added. If you `npm install` in a project - with a `workspaces` declaration, npm will install all your sub-projects' - dependencies as well, and link everything up proper. -- `npm exec` is added, to run any arbitrary command as if it was an npm - script. This is sort of like `npx`, which is also ported to use `npm - exec` under the hood. -- `npm audit` output is tightened up, and prettified. Audit can also now - fix a few more classes of problems, sends far less data over the wire, - and doesn't place blame on the wrong maintainers. (Technically this is a - breaking change if you depend on the specific audit output, but it's - also a big improvement!) -- `npm install` got faster. Like a lot faster. "So fast you'll think it's - broken" faster. `npm ls` got even fasterer. A lot of stuff sped up, is - what we're saying. -- Support has been dropped for Node.js versions less than v10. - -### On the "Breaking" in "Breaking Changes" - -The Semantic Versioning specification precisely defines what constitutes a -"breaking" change. In a nutshell, it's any change that causes a you to -change _your_ code in order to start using _our_ code. We hasten to point -this out, because a "breaking change" does not mean that something about -the update is "broken", necessarily. - -We're sure that some things likely _are_ broken in this beta, because beta -software, and a healthy pessimism about things. But nothing is "broken" on -purpose here, and if you find a bug, we'd love for you to [let us -know](https://github.com/npm/cli/issues). - -### Known Issues, and What's Missing From This Beta (Why Not GA?) - -It's beta software! - -#### Tests - -We have not yet gotten to 100% test coverage of the npm CLI codebase. As -such, there are almost certainly bugs lying in wait. We _do_ have 100% -test coverage of most of the commands, and all recently-updated -dependencies in the npm stack, so it's certainly more well-tested than any -version of npm before. - -#### Docs - -The documentation is incorrect and out of date in most places. Prior to a -GA release, we'll be going through all of our documentation with a -fine-toothed comb to minimize the lies that it tells. - -#### Error Messaging - -There are a few cases where this release will just say something failed, -and not give you as much help as we'd like. We know, and we'll fix that -prior to the GA 7.0.0 release. - -In particular, if you install a project that has conflicting -`peerDependencies` in the tree, it'll just say "Unable to resolve package -tree". Prior to GA release, it'll tell you how to fix it. (For the time -being, just run it again with `--legacy-peer-deps`, and that'll make it -operate like npm v6.) - -#### Audit Issue - -There is a known performance issue in some cases that we've identified -where `npm audit` can spin wildly out of control like a dancer gripped by a -fever, heating up your laptop with fires of passion and CPU work. This -happens when a vulnerability is in a tree with a _lot_ of cross-linked -dependencies that all depend on one another. - -We have a fix for it, but if you run into this issue, you can run with -`--no-audit` to tell npm to chill out a little bit. - -That's about it! It's ready to use, and you should try it out. - -Now on to the list of **BREAKING CHANGES**! - -### Programmatic Usage - -- [RFC - 20](https://github.com/npm/rfcs/blob/latest/implemented/0020-npm-option-handling.md) - The CLI and its dependencies no longer use the `figgy-pudding` library - for configs. Configuration is done using a flat plain old JavaScript - object. -- The `lib/fetch-package-metadata.js` module is removed. Use - [`pacote`](http://npm.im/pacote) to fetch package metadata. -- [`@npmcli/arborist`](http://npm.im/@npmcli/arborist) should be used to do - most things programmatically involving dependency trees. -- The `onload-script` option is no longer supported. -- The `log-stream` option is no longer supported. -- `npm.load()` MUST be called with two arguments (the parsed cli options - and a callback). -- `npm.root` alias for `npm.dir` removed. -- The `package.json` in npm now defines an `exports` field, making it no - longer possible to `require()` npm's internal modules. (This was always - a bad idea, but now it won't work.) - -### All Registry Interactions - -The following affect all commands that contact the npm registry. - -- `referer` header no longer sent -- `npm-command` header added - -### All Lifecycle Scripts - -The environment for lifecycle scripts (eg, build scripts, `npm test`, etc.) -has changed. - -- [RFC - 21](https://github.com/npm/rfcs/blob/latest/implemented/0021-reduce-lifecycle-script-environment.md) - Environment no longer includes `npm_package_*` fields, or `npm_config_*` - fields for default configs. `npm_package_json`, `npm_package_integrity`, - `npm_package_resolved`, and `npm_command` environment variables added. - - (NB: this [will change a bit prior to a `v7.0.0` GA - release](https://github.com/npm/rfcs/pull/183)) - -- [RFC - 22](https://github.com/npm/rfcs/blob/latest/implemented/0022-quieter-install-scripts.md) - Scripts run during the normal course of installation are silenced unless - they exit in error (ie, with a signal or non-zero exit status code), and - are for a non-optional dependency. - -- [RFC - 24](https://github.com/npm/rfcs/blob/latest/implemented/0024-npm-run-traverse-directory-tree.md) - `PATH` environment variable includes all `node_modules/.bin` folders, - even if found outside of an existing `node_modules` folder hierarchy. - -- The `user`, `group`, `uid`, `gid`, and `unsafe-perms` configurations are - no longer relevant. When npm is run as root, scripts are always run with - the effective `uid` and `gid` of the working directory owner. - -- Commands that just run a single script (`npm test`, `npm start`, `npm - stop`, and `npm restart`) will now run their script even if - `--ignore-scripts` is set. Prior to the GA v7.0.0 release, [they will - _not_ run the pre/post scripts](https://github.com/npm/rfcs/pull/185), - however. (So, it'll be possible to run `npm test --ignore-scripts` to - run your test but not your linter, for example.) - -### npx - -The `npx` binary was rewritten in npm v7, and the standalone `npx` package -deprecated when v7.0.0 hits GA. `npx` uses the new `npm exec` command -instead of a separate argument parser and install process, with some -affordances to maintain backwards compatibility with the arguments it -accepted in previous versions. - -This resulted in some shifts in its functionality: - -- Any `npm` config value may be provided. -- To prevent security and user-experience problems from mistyping package - names, `npx` prompts before installing anything. Suppress this - prompt with the `-y` or `--yes` option. -- The `--no-install` option is deprecated, and will be converted to `--no`. -- Shell fallback functionality is removed, as it is not advisable. -- The `-p` argument is a shorthand for `--parseable` in npm, but shorthand - for `--package` in npx. This is maintained, but only for the `npx` - executable. (Ie, running `npm exec -p foo` will be different from - running `npx -p foo`.) -- The `--ignore-existing` option is removed. Locally installed bins are - always present in the executed process `PATH`. -- The `--npm` option is removed. `npx` will always use the `npm` it ships - with. -- The `--node-arg` and `-n` options are removed. -- The `--always-spawn` option is redundant, and thus removed. -- The `--shell` option is replaced with `--script-shell`, but maintained - in the `npx` executable for backwards compatibility. - -We do intend to continue supporting the `npx` that npm ships; just not the -`npm install -g npx` library that is out in the wild today. - -### Files On Disk - -- [RFC - 13](https://github.com/npm/rfcs/blob/latest/implemented/0013-no-package-json-_fields.md) - Installed `package.json` files no longer are mutated to include extra - metadata. (This extra metadata is stored in the lockfile.) -- `package-lock.json` is updated to a newer format, using - `"lockfileVersion": 2`. This format is backwards-compatible with npm CLI - versions using `"lockfileVersion": 1`, but older npm clients will print a - warning about the version mismatch. -- `yarn.lock` files used as source of package metadata and resolution - guidance, if available. (Prior to v7, they were ignored.) - -### Dependency Resolution - -These changes affect `install`, `ci`, `install-test`, `install-ci-test`, -`update`, `prune`, `dedupe`, `uninstall`, `link`, and `audit fix`. - -- [RFC - 25](https://github.com/npm/rfcs/blob/latest/implemented/0025-install-peer-deps.md) - `peerDependencies` are installed by default. This behavior can be - disabled by setting the `legacy-peer-deps` configuration flag. - - **BREAKING CHANGE**: this can cause some packages to not be - installable, if they have unresolveable peer dependency conflicts. - While the correct solution is to fix the conflict, this was not forced - upon users for several years, and some have come to rely on this lack - of correctness. Use the `--legacy-peer-deps` config flag if impacted. - -- [RFC - 23](https://github.com/npm/rfcs/blob/latest/implemented/0023-acceptDependencies.md) - Support for `acceptDependencies` is added. This can result in dependency - resolutions that previous versions of npm will incorrectly flag as invalid. - -- Git dependencies on known git hosts (GitHub, BitBucket, etc.) will - always attempt to fetch package contents from the relevant tarball CDNs - if possible, falling back to `git+ssh` for private packages. `resolved` - value in `package-lock.json` will always reflect the `git+ssh` url value. - Saved value in `package.json` dependencies will always reflect the - canonical shorthand value. - -- Support for the `--link` flag (to install a link to a globall-installed - copy of a module if present, otherwise install locally) has been removed. - Local installs are always local, and `npm link <pkg>` must be used - explicitly if desired. - -- Installing a dependency with the same name as the root project no longer - requires `--force`. (That is, the `ENOSELF` error is removed.) - -### Workspaces - -- [RFC - 26](https://github.com/npm/rfcs/blob/latest/implemented/0026-workspaces.md) - First phase of `workspaces` support is added. This changes npm's - behavior when a root project's `package.json` file contains a - `workspaces` field. - -### `npm update` - -- [RFC - 19](https://github.com/npm/rfcs/blob/latest/implemented/0019-remove-update-depth-option.md) - Update all dependencies when `npm update` is run without any arguments. - As it is no longer relevant, `--depth` config flag removed from `npm - update`. - -### `npm outdated` - -- [RFC - 27](https://github.com/npm/rfcs/blob/latest/implemented/0027-remove-depth-outdated.md) - Remove `--depth` config from `npm outdated`. Only top-level dependencies - are shown, unless `--all` config option is set. - -### `npm adduser`, `npm login` - -- The `--sso` options are deprecated, and will print a warning. - -### `npm audit` - -- Output and data structure is significantly refactored to call attention - to issues, identify classes of fixes not previously available, and - remove extraneous data not used for any purpose. - - **BREAKING CHANGE**: Any tools consuming the output of `npm audit` will - almost certainly need to be updated, as this has changed significantly, - both in the readable and `--json` output styles. - -### `npm dedupe` - -- Performs a full dependency tree reification to disk. As a result, `npm - dedupe` can cause missing or invalid packages to be installed or updated, - though it will only do this if required by the stated dependency - semantics. - -- Note that the `--prefer-dedupe` flag has been added, so that you may - install in a maximally deduplicated state from the outset. - -### `npm fund` - -- Human readable output updated, reinstating depth level to the printed - output. - -### `npm ls` - -- Extraneous dependencies are listed based on their location in the - `node_modules` tree. -- `npm ls` only prints the first level of dependencies by default. You can - make it print more of the tree by using `--depth=<n>` to set a specific - depth, or `--all` to print all of them. - -### `npm pack`, `npm publish` - -- Generated gzipped tarballs no longer contain the zlib OS indicator. As a - result, they are truly dependent _only_ on the contents of the package, - and fully reproducible. However, anyone relying on this byte to identify - the operating system of a package's creation may no longer rely on it. - -### `npm rebuild` - -- Runs package installation scripts as well as re-creating links to bins. - Properly respects the `--ignore-scripts` and `--bin-links=false` - configuration options. - -### `npm build`, `npm unbuild` - -- These two internal commands were removed, as they are no longer needed. - -### `npm test` - -- When no test is specified, will fail with `missing script: test` rather - than injecting a synthetic `echo 'Error: no test specified'` test script - into the `package.json` data. - -## Credits - -Huge thanks to the people who wrote code for this update, as well as our -group of dedicated Open RFC call participants. Your participation has -contributed immeasurably to the quality and design of npm. diff --git a/debian/NEWS b/debian/NEWS deleted file mode 100644 index c8f5be0..0000000 --- a/debian/NEWS +++ /dev/null @@ -1,11 +0,0 @@ -npm (1.1.4~dfsg-1) unstable; urgency=low - - This release of npm does not support previous modules layouts. - Modules are now installed in ./node_modules when used in the default - local mode. - - More information can be found in the nodejs Modules documentation, - /usr/share/doc/npm/README.Debian, and npm-folders(1) and npm-link(1) - man pages. - - -- Jérémy Lal <kapouer@melix.org> Tue, 25 Oct 2011 15:19:32 +0200 diff --git a/debian/README.Debian b/debian/README.Debian deleted file mode 100644 index 0357575..0000000 --- a/debian/README.Debian +++ /dev/null @@ -1,50 +0,0 @@ -npm for Debian -============== - -nodejs Debian package provides /usr/bin/nodejs ----------------------------------------------- - -Modules installed by npm can ship executables. -These executables depend on /usr/bin/node, which is -provided by the nodejs-legacy Debian package. - -More information: -/usr/share/doc/nodejs/README.Debian - - -global mode npm ---------------- - -When run in global mode, npm is configured like this : - - prefix=/usr/local - globalconfig=/etc/npmrc - globalignorefile=/etc/npmignore - -That means npm -g install mymodule will be installed in : - - /usr/local/lib/node_modules/ - -If mymodule installs executables, they go to : - - /usr/local/bin - -And man pages to - - /usr/local/share/man - -Please read npm-config(1), npm-folders(1) and npm-link(1) man pages. - -This global configuration is kept across a global self update of npm. -It is not guaranteed it will stay like this, so it's safer to update -npm debian package instead. - - -do not confuse with /usr/lib/nodejs ------------------------------------ - -/usr/lib/nodejs directory is reserved for modules that are provided by a -debian package. - - - -- Jérémy Lal <kapouer@melix.org> Fri, 28 Jan 2011 00:33:28 +0200 diff --git a/debian/README.source b/debian/README.source deleted file mode 100644 index 2906e04..0000000 --- a/debian/README.source +++ /dev/null @@ -1,24 +0,0 @@ -git-buildpackage -================ - - -CDBS+git-buildpackage ---------------------- - -This source package uses CDBS and git-buildpackage. NMUs need not (but -are encouraged to) make special use of these tools. In particular, the -debian/control.in file can be completely ignored. - -More info here: http://wiki.debian.org/CDBS+git-buildpackage - - -symlinks to man pages ---------------------- - -npm searches for man pages in ./man/man1/*.1, and that is why symlinks -are there : -/usr/share/man/man1/npm-xxx.1.gz -> /usr/share/npm/man/man1/xxx.1 - -npm does not search for man pages with .gz extension, so we get : -E: npm: compressed-symlink-with-wrong-ext -This is just to avoid having to patch npm. diff --git a/debian/TODO b/debian/TODO deleted file mode 100644 index 4eb1217..0000000 --- a/debian/TODO +++ /dev/null @@ -1,2 +0,0 @@ -* Generate html and man pages from ronnjs. Exclude them too. - + nodejs >= 0.6.12 ships node-marked. Check if npm will use that tool. diff --git a/debian/changelog b/debian/changelog deleted file mode 100644 index ab86301..0000000 --- a/debian/changelog +++ /dev/null @@ -1,5 +0,0 @@ -npm (8.5.1~ds-ok1) yangtze; urgency=medium - - * Build for openKylin. - - -- zhouganqing <zhouganqing@kylinos.cn> Thu, 16 Feb 2023 14:32:28 +0800 diff --git a/debian/clean b/debian/clean deleted file mode 100644 index 98c3f14..0000000 --- a/debian/clean +++ /dev/null @@ -1,35 +0,0 @@ -.nyc_output/ -debian/tests/test_modules/npm-registry-mock/.nyc_output/ -doc/misc/npm-index.md -npmrc -man/ -test/fixtures/config/userconfig-with-gc -test/npm_cache_adduser-always-auth/ -test/npm_cache_anon-cli-metrics/ -test/npm_cache_bugs/ -test/npm_cache_ci-header/ -test/npm_cache_circular-dep/ -test/npm_cache_dedupe/ -test/npm_cache_deprecate/ -test/npm_cache_git-prepare/ -test/npm_cache_peer-deps/ -test/npm_cache_repo/ -test/npm_cache_shrinkwrap-_auth/ -test/tap/adduser-always-auth/ -test/tap/audit-fix/ -test/tap/bugs/ -test/tap/ci-header/ -test/tap/circular-dep/ -test/tap/dist-tag/ -test/tap/git-prepare/ -test/tap/false-name/ -test/tap/ignore-scripts/ -test/tap/pack-files-and-ignores/ -test/tap/pack/ -test/tap/peer-deps/ -test/tap/prepublish/ -test/tap/prune-dev-dep-cycle/ -test/tap/prune-dev-dep-with-bins/ -test/tap/shrinkwrap-_auth/ -test/tap/shrinkwrap-global-auth/ -test/tap/shrinkwrap-scoped-auth/ diff --git a/debian/control b/debian/control deleted file mode 100644 index c284202..0000000 --- a/debian/control +++ /dev/null @@ -1,155 +0,0 @@ -Source: npm -Maintainer: OpenKylin Developers <packaging@lists.openkylin.top> -Section: javascript -Testsuite: autopkgtest-pkg-nodejs -Priority: optional -Build-Depends: debhelper-compat (= 13), - bash-completion, - dh-sequence-nodejs (>= 0.11.5~), - help2man <!nodoc>, - node-abbrev <!nocheck>, - node-agent-base <!nocheck>, - node-ansistyles <!nocheck>, - node-aproba <!nocheck>, - node-archy <!nocheck>, - node-asap <!nocheck>, - node-cacache <!nocheck>, - node-chalk <!nocheck>, - node-chownr <!nocheck>, - node-cli-table3 <!nocheck>, - node-colors <!nocheck>, - node-columnify <!nocheck>, - node-debug <!nocheck>, - node-depd <!nocheck>, - node-emoji-regex <!nocheck>, - node-encoding <!nocheck>, - node-glob <!nocheck>, - node-got <!nocheck>, - node-graceful-fs <!nocheck>, - node-gyp <!nocheck>, - node-hosted-git-info <!nocheck>, - node-https-proxy-agent <!nocheck>, - node-ini <!nocheck>, - node-ip <!nocheck>, - node-ip-regex <!nocheck>, - node-json-parse-better-errors <!nocheck>, - node-jsonparse <!nocheck>, - node-lru-cache <!nocheck>, - node-marked-man, - node-minimatch <!nocheck>, - node-minipass <!nocheck>, - node-mkdirp <!nocheck>, - node-ms <!nocheck>, - node-negotiator <!nocheck>, - node-nopt <!nocheck>, - node-normalize-package-data <!nocheck>, - node-npm-bundled <!nocheck>, - node-npm-package-arg <!nocheck>, - node-npmlog <!nocheck>, - node-once <!nocheck>, - node-opener <!nocheck>, - node-promise-retry <!nocheck>, - node-promzard <!nocheck>, - node-read <!nocheck>, - node-read-package-json <!nocheck>, - node-rimraf <!nocheck>, - node-semver <!nocheck>, - node-ssri <!nocheck>, - node-string-width <!nocheck>, - node-strip-ansi <!nocheck>, - node-tap <!nodoc>, - node-tar <!nocheck>, - node-text-table <!nocheck>, - node-validate-npm-package-license <!nocheck>, - node-validate-npm-package-name <!nocheck>, - node-which <!nocheck>, - node-wrappy <!nocheck>, - node-write-file-atomic <!nocheck>, - node-yallist -Standards-Version: 4.6.0 -Vcs-Browser: https://gitee.com/openkylin/npm -Vcs-Git: https://gitee.com/openkylin/npm.git -Homepage: https://docs.npmjs.com/ -Rules-Requires-Root: no - -Package: npm -Architecture: all -Depends: ${misc:Depends}, - ca-certificates, - node-abbrev, - node-agent-base, - node-ansistyles, - node-aproba, - node-archy, - node-asap, - node-cacache, - node-chalk, - node-chownr, - node-cli-table3, - node-colors, - node-columnify, - node-debug, - node-depd, - node-emoji-regex, - node-encoding, - node-glob, - node-got, - node-graceful-fs, - node-gyp, - node-hosted-git-info, - node-https-proxy-agent, - node-ini, - node-ip, - node-ip-regex, - node-json-parse-better-errors, - node-jsonparse, - node-lru-cache, - node-minimatch, - node-minipass, - node-mkdirp, - node-ms, - node-negotiator, - node-nopt, - node-normalize-package-data, - node-npm-bundled, - node-npm-package-arg, - node-npmlog, - node-once, - node-promise-retry, - node-promzard, - node-read, - node-read-package-json, - node-rimraf, - node-semver, - node-ssri, - node-string-width, - node-strip-ansi, - node-tar, - node-text-table, - node-validate-npm-package-license, - node-validate-npm-package-name, - node-which, - node-wrappy, - node-write-file-atomic, - node-yallist, - nodejs:any (>= 10), -Recommends: git - , node-tap -Suggests: node-opener -Provides: ${nodejs:Provides} - , arborist (= ${arborist:Version}) - , npm-packlist (= ${npmpl:Version}) - , pacote (= ${pacote:Version}) - , qrcode-terminal (= ${qrt:Version}) -Description: package manager for Node.js - Node.js is an event-based server-side javascript engine. - . - npm is the package manager for the Node JavaScript platform. It puts - modules in place so that node can find them, and manages dependency - conflicts intelligently. - . - It is extremely configurable to support a wide variety of use cases. - Most commonly, it is used to publish, discover, install, and develop - node programs. - . - Install also node-opener to have full npm features enabled. diff --git a/debian/copyright b/debian/copyright deleted file mode 100644 index 9ed2cb9..0000000 --- a/debian/copyright +++ /dev/null @@ -1,501 +0,0 @@ -Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ -Upstream-Name: npm -Upstream-Contact: https://github.com/npm/cli/issues -Source: https://github.com/npm/cli - Repackaged for easier copyright maintainability - note also that underscore contains a minified file. - Either external modules are available as debian packages, in which case - they are removed; or they are not good candidates for being packaged - at the moment, in which case they are kept. -Files-Excluded: - node_modules/abbrev - node_modules/agent-base - node_modules/aggregate-error - node_modules/ansi-regex - node_modules/ansi-styles - node_modules/ansistyles - node_modules/aproba - node_modules/archy - node_modules/are-we-there-yet - node_modules/asap - node_modules/balanced-match - node_modules/binary-extensions - node_modules/brace-expansion - node_modules/builtins - node_modules/cacache - node_modules/chalk - node_modules/chownr - node_modules/clean-stack - node_modules/cli-table3 - node_modules/clone - node_modules/color-convert - node_modules/color-name - node_modules/colors - node_modules/color-support - node_modules/columnify - node_modules/concat-map - node_modules/console-control-strings - node_modules/debug - node_modules/defaults - node_modules/delegates - node_modules/depd - node_modules/diff - node_modules/emoji-regex - node_modules/encoding - node_modules/err-code - node_modules/fs.realpath - node_modules/function-bind - node_modules/gauge - node_modules/glob - node_modules/graceful-fs - node_modules/has - node_modules/has-flag - node_modules/has-unicode - node_modules/hosted-git-info - node_modules/http-cache-semantics - node_modules/http-proxy-agent - node_modules/https-proxy-agent - node_modules/iconv-lite - node_modules/imurmurhash - node_modules/indent-string - node_modules/inflight - node_modules/inherits - node_modules/ini - node_modules/ip - node_modules/ip-regex - node_modules/is-core-module - node_modules/is-fullwidth-code-point - node_modules/isexe - node_modules/is-typedarray - node_modules/jsonparse - node_modules/json-parse-even-better-errors - node_modules/lru-cache - node_modules/minimatch - node_modules/minipass-collect - node_modules/minipass-fetch - node_modules/minipass-flush - node_modules/minipass-json-stream - node_modules/minipass-pipeline - node_modules/minipass-sized - node_modules/minipass - node_modules/minizlib - node_modules/mkdirp - node_modules/ms - node_modules/mute-stream - node_modules/negotiator - node_modules/node-gyp - node_modules/nopt - node_modules/normalize-package-data - node_modules/npm-bundled - node_modules/@npmcli/move-file - node_modules/npmlog - node_modules/npm-package-arg - node_modules/once - node_modules/opener - node_modules/path-is-absolute - node_modules/p-map - node_modules/promise-inflight - node_modules/promise-retry - node_modules/promzard - node_modules/read - node_modules/readable-stream - node_modules/read-package-json - node_modules/retry - node_modules/rimraf - node_modules/safe-buffer - node_modules/safer-buffer - node_modules/semver - node_modules/set-blocking - node_modules/signal-exit - node_modules/spdx-correct - node_modules/spdx-exceptions - node_modules/spdx-expression-parse - node_modules/spdx-license-ids - node_modules/ssri - node_modules/string_decoder - node_modules/string-width - node_modules/strip-ansi - node_modules/supports-color - node_modules/tar - node_modules/text-table - node_modules/@tootallnate/once - node_modules/typedarray-to-buffer - node_modules/unique-filename - node_modules/util-deprecate - node_modules/validate-npm-package-license - node_modules/validate-npm-package-name - node_modules/wcwidth - node_modules/which - node_modules/wide-align - node_modules/wrappy - node_modules/write-file-atomic - node_modules/yallist - -Files: * -Copyright: npm, Inc. and Contributors -License: Artistic-2.0 - -Files: docs/* -Copyright: 2015, gatsbyjs -License: Expat - -Files: node_modules/* -Copyright: npm, Inc. -License: ISC - -Files: node_modules/agentkeepalive/* -Copyright: 2012-2015, fengmk2 <fengmk2@gmail.com> - Joyent, Inc. and other Node contributors -License: Expat - -Files: node_modules/ansicolors/* -Copyright: 2013, Thorsten Lorenz -License: Expat - -Files: node_modules/fastest-levenshtein/* -Copyright: 2020 Kasper Unn Weihe -License: Expat - -Files: node_modules/cidr-regex/* - node_modules/is-cidr/* -Copyright: silverwind -License: Expat - -Files: node_modules/cli-columns/* -Copyright: Shannon Moeller <me@shannonmoeller.com> -License: Expat - -Files: node_modules/common-ancestor-path/* - node_modules/dezalgo/* - node_modules/fs-minipass/* - node_modules/ignore-walk/* - node_modules/json-stringify-nice/* - node_modules/mkdirp-infer-owner/* - node_modules/npm-packlist/* - node_modules/pacote/* - node_modules/promise-all-reject-late/* - node_modules/promise-call-limit/* - node_modules/readdir-scoped-modules/* - node_modules/walk-up-path/* -Copyright: Isaac Z. Schlueter -License: ISC - -Files: node_modules/debuglog/* -Copyright: Joyent, Inc. and other Node contributors -License: Expat - -Files: node_modules/humanize-ms/* -Copyright: dead-horse <dead_horse@qq.com> -License: Expat - -Files: node_modules/is-lambda/* -Copyright: 2016-2017 Thomas Watson Steen -License: Expat - -Files: node_modules/just-diff-apply/* - node_modules/just-diff/* -Copyright: 2016 angus croll -License: Expat - -Files: node_modules/npm-install-checks/* -Copyright: Robert Kowalski <rok@kowalski.gd> - Isaac Z. Schlueter -License: BSD-2-Clause - -Files: node_modules/npm-user-validate/* -Copyright: Robert Kowalski <rok@kowalski.gd> -License: BSD-2-Clause - -Files: node_modules/qrcode-terminal/* -Copyright: Unknown -License: Apache-2.0 - -Files: node_modules/qrcode-terminal/vendor/QRCode/* -Copyright: 2009 Kazuhiko Arase -License: Expat - -Files: node_modules/read-cmd-shim/* -Copyright: 2015 Rebecca Turner -License: ISC - -Files: node_modules/smart-buffer/* - node_modules/socks/* -Copyright: 2013-2017, Josh Glazebrook -License: Expat - -Files: node_modules/tiny-relative-date/* -Copyright: 2017, Joseph Wynn -License: Expat - -Files: debian/* -Copyright: 2011-2019, Jérémy Lal <kapouer@melix.org> - 2011-2012, Jonas Smedegaard <dr@jones.dk> - 2018-2020, Pirate Praveen <praveen@debian.org> - 2019, Manas Kashyap <manaskashyaptech@gmail.com> - 2019-2021, Yadd <yadd@debian.org> -License: Artistic-2.0 - -License: Apache-2.0 - On Debian systems, the complete text of the Apache version 2.0 license - can be found in `/usr/share/common-licenses/Apache-2.0'. - -License: Artistic-2.0 - The Artistic License 2.0 - . - Copyright (c) 2000-2006, The Perl Foundation. - . - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - . - Preamble - . - This license establishes the terms under which a given free software - Package may be copied, modified, distributed, and/or redistributed. - The intent is that the Copyright Holder maintains some artistic - control over the development of that Package while still keeping the - Package available as open source and free software. - . - You are always permitted to make arrangements wholly outside of this - license directly with the Copyright Holder of a given Package. If the - terms of this license do not permit the full use that you propose to - make of the Package, you should contact the Copyright Holder and seek - a different licensing arrangement. - . - Definitions - . - "Copyright Holder" means the individual(s) or organization(s) - named in the copyright notice for the entire Package. - . - "Contributor" means any party that has contributed code or other - material to the Package, in accordance with the Copyright Holder's - procedures. - . - "You" and "your" means any person who would like to copy, - distribute, or modify the Package. - . - "Package" means the collection of files distributed by the - Copyright Holder, and derivatives of that collection and/or of - those files. A given Package may consist of either the Standard - Version, or a Modified Version. - . - "Distribute" means providing a copy of the Package or making it - accessible to anyone else, or in the case of a company or - organization, to others outside of your company or organization. - . - "Distributor Fee" means any fee that you charge for Distributing - this Package or providing support for this Package to another - party. It does not mean licensing fees. - . - "Standard Version" refers to the Package if it has not been - modified, or has been modified only in ways explicitly requested - by the Copyright Holder. - . - "Modified Version" means the Package, if it has been changed, and - such changes were not explicitly requested by the Copyright - Holder. - . - "Original License" means this Artistic License as Distributed with - the Standard Version of the Package, in its current version or as - it may be modified by The Perl Foundation in the future. - . - "Source" form means the source code, documentation source, and - configuration files for the Package. - . - "Compiled" form means the compiled bytecode, object code, binary, - or any other form resulting from mechanical transformation or - translation of the Source form. - . - . - Permission for Use and Modification Without Distribution - . - (1) You are permitted to use the Standard Version and create and use - Modified Versions for any purpose without restriction, provided that - you do not Distribute the Modified Version. - . - . - Permissions for Redistribution of the Standard Version - . - (2) You may Distribute verbatim copies of the Source form of the - Standard Version of this Package in any medium without restriction, - either gratis or for a Distributor Fee, provided that you duplicate - all of the original copyright notices and associated disclaimers. At - your discretion, such verbatim copies may or may not include a - Compiled form of the Package. - . - (3) You may apply any bug fixes, portability changes, and other - modifications made available from the Copyright Holder. The resulting - Package will still be considered the Standard Version, and as such - will be subject to the Original License. - . - . - Distribution of Modified Versions of the Package as Source - . - (4) You may Distribute your Modified Version as Source (either gratis - or for a Distributor Fee, and with or without a Compiled form of the - Modified Version) provided that you clearly document how it differs - from the Standard Version, including, but not limited to, documenting - any non-standard features, executables, or modules, and provided that - you do at least ONE of the following: - . - (a) make the Modified Version available to the Copyright Holder - of the Standard Version, under the Original License, so that the - Copyright Holder may include your modifications in the Standard - Version. - . - (b) ensure that installation of your Modified Version does not - prevent the user installing or running the Standard Version. In - addition, the Modified Version must bear a name that is different - from the name of the Standard Version. - . - (c) allow anyone who receives a copy of the Modified Version to - make the Source form of the Modified Version available to others - under - . - (i) the Original License or - . - (ii) a license that permits the licensee to freely copy, - modify and redistribute the Modified Version using the same - licensing terms that apply to the copy that the licensee - received, and requires that the Source form of the Modified - Version, and of any works derived from it, be made freely - available in that license fees are prohibited but Distributor - Fees are allowed. - . - . - Distribution of Compiled Forms of the Standard Version - or Modified Versions without the Source - . - (5) You may Distribute Compiled forms of the Standard Version without - the Source, provided that you include complete instructions on how to - get the Source of the Standard Version. Such instructions must be - valid at the time of your distribution. If these instructions, at any - time while you are carrying out such distribution, become invalid, you - must provide new instructions on demand or cease further distribution. - If you provide valid instructions or cease distribution within thirty - days after you become aware that the instructions are invalid, then - you do not forfeit any of your rights under this license. - . - (6) You may Distribute a Modified Version in Compiled form without - the Source, provided that you comply with Section 4 with respect to - the Source of the Modified Version. - . - . - Aggregating or Linking the Package - . - (7) You may aggregate the Package (either the Standard Version or - Modified Version) with other packages and Distribute the resulting - aggregation provided that you do not charge a licensing fee for the - Package. Distributor Fees are permitted, and licensing fees for other - components in the aggregation are permitted. The terms of this license - apply to the use and Distribution of the Standard or Modified Versions - as included in the aggregation. - . - (8) You are permitted to link Modified and Standard Versions with - other works, to embed the Package in a larger work of your own, or to - build stand-alone binary or bytecode versions of applications that - include the Package, and Distribute the result without restriction, - provided the result does not expose a direct interface to the Package. - . - . - Items That are Not Considered Part of a Modified Version - . - (9) Works (including, but not limited to, modules and scripts) that - merely extend or make use of the Package, do not, by themselves, cause - the Package to be a Modified Version. In addition, such works are not - considered parts of the Package itself, and are not subject to the - terms of this license. - . - . - General Provisions - . - (10) Any use, modification, and distribution of the Standard or - Modified Versions is governed by this Artistic License. By using, - modifying or distributing the Package, you accept this license. Do not - use, modify, or distribute the Package, if you do not accept this - license. - . - (11) If your Modified Version has been derived from a Modified - Version made by someone other than you, you are nevertheless required - to ensure that your Modified Version complies with the requirements of - this license. - . - (12) This license does not grant you the right to use any trademark, - service mark, tradename, or logo of the Copyright Holder. - . - (13) This license includes the non-exclusive, worldwide, - free-of-charge patent license to make, have made, use, offer to sell, - sell, import and otherwise transfer the Package with respect to any - patent claims licensable by the Copyright Holder that are necessarily - infringed by the Package. If you institute patent litigation - (including a cross-claim or counterclaim) against any party alleging - that the Package constitutes direct or contributory patent - infringement, then this Artistic License to you shall terminate on the - date that such litigation is filed. - . - (14) Disclaimer of Warranty: - THE PACKAGE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS - IS' AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES. THE IMPLIED - WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR - NON-INFRINGEMENT ARE DISCLAIMED TO THE EXTENT PERMITTED BY YOUR LOCAL - LAW. UNLESS REQUIRED BY LAW, NO COPYRIGHT HOLDER OR CONTRIBUTOR WILL - BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL - DAMAGES ARISING IN ANY WAY OUT OF THE USE OF THE PACKAGE, EVEN IF - ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -License: BSD-2-Clause - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - . - 1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - . - 2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - . - THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR - PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS - BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF - SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR - BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE - OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -License: Expat - Permission is hereby granted, free of charge, to any person obtaining a - copy of this software and associated documentation files (the - "Software"), to deal in the Software without restriction, including - without limitation the rights to use, copy, modify, merge, publish, - distribute, sublicense, and/or sell copies of the Software, and to - permit persons to whom the Software is furnished to do so, subject to - the following conditions: - . - The above copyright notice and this permission notice shall be included - in all copies or substantial portions of the Software. - . - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS - OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. - IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY - CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, - TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE - SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -License: ISC - Permission to use, copy, modify, and/or distribute this software for - any purpose with or without fee is hereby granted, provided that the - above copyright notice and this permission notice appear in all - copies. - . - THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL - WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED - WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE - AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL - DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA - OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER - TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - PERFORMANCE OF THIS SOFTWARE. diff --git a/debian/copyright_hints b/debian/copyright_hints deleted file mode 100644 index d1593bb..0000000 --- a/debian/copyright_hints +++ /dev/null @@ -1,1394 +0,0 @@ -Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ -Upstream-Name: FIXME -Upstream-Contact: FIXME -Source: FIXME -Disclaimer: Autogenerated by CDBS - -Files: CHANGELOG.md - Makefile - README.md - bin/node-gyp-bin/node-gyp - bin/node-gyp-bin/node-gyp.cmd - bin/npm - bin/npm-cli.js - bin/npm.cmd - bin/npx - bin/npx-cli.js - bin/npx.cmd - changelogs/CHANGELOG-1.md - changelogs/CHANGELOG-5.md - changelogs/CHANGELOG-6.md - configure - debian/README.source - debian/TODO - debian/clean - debian/gbp.conf - debian/install - debian/links - debian/manpages - debian/npm.bash-completion - debian/npm.lintian-overrides - debian/npm.maintscript - debian/npmrc - debian/patches/2011_node-gyp-path.patch - debian/patches/2012_dont_install_man_deps.patch - debian/patches/series - debian/rules - debian/salsa-ci.yml - debian/source/format - debian/source/lintian-overrides - debian/source/local-options - debian/tests/control - debian/tests/install-test - debian/tests/no-duplication - debian/tests/pkg-js/files - debian/tests/pkg-js/test - debian/tests/test_modules/hock/Makefile - debian/tests/test_modules/hock/lib/hock.js - debian/tests/test_modules/hock/lib/request.js - debian/tests/test_modules/hock/node_modules/deep-equal/index.js - debian/tests/test_modules/hock/node_modules/deep-equal/lib/is_arguments.js - debian/tests/test_modules/hock/node_modules/deep-equal/lib/keys.js - debian/tests/test_modules/hock/node_modules/deep-equal/package.json - debian/tests/test_modules/hock/package.json - debian/tests/test_modules/npm-registry-mock/add-fixture.sh - debian/tests/test_modules/npm-registry-mock/index.js - debian/tests/test_modules/npm-registry-mock/lib/predefines.js - debian/tests/test_modules/npm-registry-mock/package.json - debian/tests/tests_excluded - debian/upstream - debian/watch - docs/config.json - docs/content/commands/npm-access.md - docs/content/commands/npm-adduser.md - docs/content/commands/npm-audit.md - docs/content/commands/npm-bin.md - docs/content/commands/npm-bugs.md - docs/content/commands/npm-cache.md - docs/content/commands/npm-ci.md - docs/content/commands/npm-completion.md - docs/content/commands/npm-config.md - docs/content/commands/npm-dedupe.md - docs/content/commands/npm-deprecate.md - docs/content/commands/npm-dist-tag.md - docs/content/commands/npm-docs.md - docs/content/commands/npm-doctor.md - docs/content/commands/npm-edit.md - docs/content/commands/npm-exec.md - docs/content/commands/npm-explain.md - docs/content/commands/npm-explore.md - docs/content/commands/npm-fund.md - docs/content/commands/npm-help-search.md - docs/content/commands/npm-help.md - docs/content/commands/npm-hook.md - docs/content/commands/npm-init.md - docs/content/commands/npm-install-ci-test.md - docs/content/commands/npm-install-test.md - docs/content/commands/npm-install.md - docs/content/commands/npm-link.md - docs/content/commands/npm-logout.md - docs/content/commands/npm-ls.md - docs/content/commands/npm-org.md - docs/content/commands/npm-outdated.md - docs/content/commands/npm-owner.md - docs/content/commands/npm-pack.md - docs/content/commands/npm-ping.md - docs/content/commands/npm-prefix.md - docs/content/commands/npm-profile.md - docs/content/commands/npm-prune.md - docs/content/commands/npm-publish.md - docs/content/commands/npm-rebuild.md - docs/content/commands/npm-repo.md - docs/content/commands/npm-restart.md - docs/content/commands/npm-root.md - docs/content/commands/npm-run-script.md - docs/content/commands/npm-search.md - docs/content/commands/npm-shrinkwrap.md - docs/content/commands/npm-star.md - docs/content/commands/npm-stars.md - docs/content/commands/npm-start.md - docs/content/commands/npm-stop.md - docs/content/commands/npm-team.md - docs/content/commands/npm-test.md - docs/content/commands/npm-token.md - docs/content/commands/npm-uninstall.md - docs/content/commands/npm-unpublish.md - docs/content/commands/npm-update.md - docs/content/commands/npm-version.md - docs/content/commands/npm-view.md - docs/content/commands/npm-whoami.md - docs/content/commands/npm.md - docs/content/commands/npx.md - docs/content/configuring-npm/folders.md - docs/content/configuring-npm/install.md - docs/content/configuring-npm/npmrc.md - docs/content/configuring-npm/package-json.md - docs/content/configuring-npm/package-lock-json.md - docs/content/configuring-npm/package-locks.md - docs/content/configuring-npm/shrinkwrap-json.md - docs/content/using-npm/config.md - docs/content/using-npm/developers.md - docs/content/using-npm/orgs.md - docs/content/using-npm/registry.md - docs/content/using-npm/removal.md - docs/content/using-npm/scope.md - docs/content/using-npm/scripts.md - docs/content/using-npm/workspaces.md - docs/dockhand.js - docs/template.html - lib/access.js - lib/adduser.js - lib/audit.js - lib/auth/legacy.js - lib/auth/oauth.js - lib/auth/saml.js - lib/auth/sso.js - lib/bin.js - lib/birthday.js - lib/bugs.js - lib/cache.js - lib/ci.js - lib/cli.js - lib/completion.js - lib/config.js - lib/dedupe.js - lib/deprecate.js - lib/dist-tag.js - lib/docs.js - lib/doctor.js - lib/edit.js - lib/exec.js - lib/explain.js - lib/explore.js - lib/find-dupes.js - lib/fund.js - lib/get.js - lib/help-search.js - lib/help.js - lib/hook.js - lib/init.js - lib/install-ci-test.js - lib/install-test.js - lib/install.js - lib/link.js - lib/ll.js - lib/logout.js - lib/ls.js - lib/npm.js - lib/org.js - lib/outdated.js - lib/owner.js - lib/pack.js - lib/ping.js - lib/prefix.js - lib/profile.js - lib/prune.js - lib/publish.js - lib/rebuild.js - lib/repo.js - lib/restart.js - lib/root.js - lib/run-script.js - lib/search.js - lib/search/format-package-stream.js - lib/search/package-filter.js - lib/set.js - lib/shrinkwrap.js - lib/star.js - lib/stars.js - lib/start.js - lib/stop.js - lib/team.js - lib/test.js - lib/token.js - lib/uninstall.js - lib/unpublish.js - lib/update.js - lib/utils/ansi-trim.js - lib/utils/audit-error.js - lib/utils/cache-file.js - lib/utils/child-path.js - lib/utils/cleanup-log-files.js - lib/utils/cmd-list.js - lib/utils/completion.sh - lib/utils/completion/file-completion.js - lib/utils/completion/installed-deep.js - lib/utils/completion/installed-shallow.js - lib/utils/completion/none.js - lib/utils/config.js - lib/utils/deep-sort-object.js - lib/utils/depr-check.js - lib/utils/deref-command.js - lib/utils/did-you-mean.js - lib/utils/error-handler.js - lib/utils/error-message.js - lib/utils/escape-arg.js - lib/utils/escape-exec-path.js - lib/utils/explain-dep.js - lib/utils/explain-eresolve.js - lib/utils/file-exists.js - lib/utils/flat-options.js - lib/utils/get-identity.js - lib/utils/get-project-scope.js - lib/utils/git.js - lib/utils/hosted-git-info-from-manifest.js - lib/utils/is-windows-bash.js - lib/utils/is-windows-shell.js - lib/utils/is-windows.js - lib/utils/lifecycle-cmd.js - lib/utils/metrics-launch.js - lib/utils/metrics.js - lib/utils/module-name.js - lib/utils/no-progress-while-running.js - lib/utils/npm-usage.js - lib/utils/open-url.js - lib/utils/otplease.js - lib/utils/output.js - lib/utils/package-id.js - lib/utils/path.js - lib/utils/perf.js - lib/utils/pick-manifest-from-registry-metadata.js - lib/utils/ping.js - lib/utils/proc-log-listener.js - lib/utils/pulse-till-done.js - lib/utils/read-local-package.js - lib/utils/read-user-info.js - lib/utils/reify-output.js - lib/utils/replace-info.js - lib/utils/save-stack.js - lib/utils/setup-log.js - lib/utils/spawn.js - lib/utils/tar.js - lib/utils/unix-format-path.js - lib/utils/unsupported.js - lib/utils/update-notifier.js - lib/utils/usage.js - lib/utils/warn-deprecated.js - lib/version.js - lib/view.js - lib/whoami.js - make.bat - netlify.toml - node_modules/.gitignore - node_modules/@npmcli/arborist/README.md - node_modules/@npmcli/arborist/lib/add-rm-pkg-deps.js - node_modules/@npmcli/arborist/lib/arborist/audit.js - node_modules/@npmcli/arborist/lib/arborist/deduper.js - node_modules/@npmcli/arborist/lib/arborist/index.js - node_modules/@npmcli/arborist/lib/arborist/load-actual.js - node_modules/@npmcli/arborist/lib/arborist/load-virtual.js - node_modules/@npmcli/arborist/lib/arborist/load-workspaces.js - node_modules/@npmcli/arborist/lib/arborist/pruner.js - node_modules/@npmcli/arborist/lib/arborist/rebuild.js - node_modules/@npmcli/arborist/lib/arborist/reify.js - node_modules/@npmcli/arborist/lib/audit-report.js - node_modules/@npmcli/arborist/lib/calc-dep-flags.js - node_modules/@npmcli/arborist/lib/consistent-resolve.js - node_modules/@npmcli/arborist/lib/debug.js - node_modules/@npmcli/arborist/lib/dep-spec.js - node_modules/@npmcli/arborist/lib/dep-valid.js - node_modules/@npmcli/arborist/lib/diff.js - node_modules/@npmcli/arborist/lib/edge.js - node_modules/@npmcli/arborist/lib/from-path.js - node_modules/@npmcli/arborist/lib/gather-dep-set.js - node_modules/@npmcli/arborist/lib/index.js - node_modules/@npmcli/arborist/lib/inventory.js - node_modules/@npmcli/arborist/lib/link.js - node_modules/@npmcli/arborist/lib/node.js - node_modules/@npmcli/arborist/lib/optional-set.js - node_modules/@npmcli/arborist/lib/peer-set.js - node_modules/@npmcli/arborist/lib/proc-log.js - node_modules/@npmcli/arborist/lib/realpath.js - node_modules/@npmcli/arborist/lib/relpath.js - node_modules/@npmcli/arborist/lib/reset-dep-flags.js - node_modules/@npmcli/arborist/lib/retire-path.js - node_modules/@npmcli/arborist/lib/shrinkwrap.js - node_modules/@npmcli/arborist/lib/spec-from-lock.js - node_modules/@npmcli/arborist/lib/tracker.js - node_modules/@npmcli/arborist/lib/version-from-tgz.js - node_modules/@npmcli/arborist/lib/vuln.js - node_modules/@npmcli/arborist/lib/yarn-lock.js - node_modules/@npmcli/arborist/package.json - node_modules/@npmcli/ci-detect/README.md - node_modules/@npmcli/ci-detect/index.js - node_modules/@npmcli/ci-detect/package.json - node_modules/@npmcli/config/README.md - node_modules/@npmcli/config/lib/env-replace.js - node_modules/@npmcli/config/lib/get-user-agent.js - node_modules/@npmcli/config/lib/index.js - node_modules/@npmcli/config/lib/nerf-dart.js - node_modules/@npmcli/config/lib/parse-field.js - node_modules/@npmcli/config/lib/proc-log.js - node_modules/@npmcli/config/lib/set-envs.js - node_modules/@npmcli/config/lib/type-defs.js - node_modules/@npmcli/config/lib/type-description.js - node_modules/@npmcli/config/lib/umask.js - node_modules/@npmcli/config/package.json - node_modules/@npmcli/git/README.md - node_modules/@npmcli/git/lib/clone.js - node_modules/@npmcli/git/lib/env.js - node_modules/@npmcli/git/lib/find.js - node_modules/@npmcli/git/lib/index.js - node_modules/@npmcli/git/lib/is-clean.js - node_modules/@npmcli/git/lib/is.js - node_modules/@npmcli/git/lib/lines-to-revs.js - node_modules/@npmcli/git/lib/opts.js - node_modules/@npmcli/git/lib/proc-log.js - node_modules/@npmcli/git/lib/revs.js - node_modules/@npmcli/git/lib/should-retry.js - node_modules/@npmcli/git/lib/spawn.js - node_modules/@npmcli/git/lib/which.js - node_modules/@npmcli/git/package.json - node_modules/@npmcli/installed-package-contents/README.md - node_modules/@npmcli/installed-package-contents/index.js - node_modules/@npmcli/installed-package-contents/package.json - node_modules/@npmcli/map-workspaces/CHANGELOG.md - node_modules/@npmcli/map-workspaces/README.md - node_modules/@npmcli/map-workspaces/index.js - node_modules/@npmcli/map-workspaces/package.json - node_modules/@npmcli/metavuln-calculator/README.md - node_modules/@npmcli/metavuln-calculator/lib/advisory.js - node_modules/@npmcli/metavuln-calculator/lib/get-dep-spec.js - node_modules/@npmcli/metavuln-calculator/lib/hash.js - node_modules/@npmcli/metavuln-calculator/lib/index.js - node_modules/@npmcli/metavuln-calculator/package.json - node_modules/@npmcli/name-from-folder/README.md - node_modules/@npmcli/name-from-folder/index.js - node_modules/@npmcli/name-from-folder/package.json - node_modules/@npmcli/node-gyp/lib/index.js - node_modules/@npmcli/node-gyp/package.json - node_modules/@npmcli/promise-spawn/README.md - node_modules/@npmcli/promise-spawn/index.js - node_modules/@npmcli/promise-spawn/package.json - node_modules/@npmcli/run-script/README.md - node_modules/@npmcli/run-script/lib/is-server-package.js - node_modules/@npmcli/run-script/lib/is-windows.js - node_modules/@npmcli/run-script/lib/make-spawn-args.js - node_modules/@npmcli/run-script/lib/node-gyp-bin/node-gyp - node_modules/@npmcli/run-script/lib/node-gyp-bin/node-gyp.cmd - node_modules/@npmcli/run-script/lib/package-envs.js - node_modules/@npmcli/run-script/lib/run-script-pkg.js - node_modules/@npmcli/run-script/lib/run-script.js - node_modules/@npmcli/run-script/lib/set-path.js - node_modules/@npmcli/run-script/lib/signal-manager.js - node_modules/@npmcli/run-script/lib/validate-options.js - node_modules/@npmcli/run-script/package.json - node_modules/@tootallnate/once/dist/index.d.ts - node_modules/@tootallnate/once/dist/index.js - node_modules/@tootallnate/once/dist/index.js.map - node_modules/@tootallnate/once/package.json - node_modules/agent-base/dist/src/index.d.ts - node_modules/agent-base/dist/src/index.js - node_modules/agent-base/dist/src/index.js.map - node_modules/agent-base/dist/src/promisify.d.ts - node_modules/agent-base/dist/src/promisify.js - node_modules/agent-base/dist/src/promisify.js.map - node_modules/agent-base/package.json - node_modules/agent-base/src/index.ts - node_modules/agent-base/src/promisify.ts - node_modules/agentkeepalive/README.md - node_modules/agentkeepalive/browser.js - node_modules/agentkeepalive/index.d.ts - node_modules/agentkeepalive/index.js - node_modules/agentkeepalive/lib/agent.js - node_modules/agentkeepalive/lib/constants.js - node_modules/agentkeepalive/lib/https_agent.js - node_modules/agentkeepalive/package.json - node_modules/aggregate-error/index.d.ts - node_modules/aggregate-error/index.js - node_modules/aggregate-error/package.json - node_modules/aggregate-error/readme.md - node_modules/ansicolors/README.md - node_modules/ansicolors/ansicolors.js - node_modules/ansicolors/package.json - node_modules/ansicolors/test/ansicolors.js - node_modules/bin-links/CHANGELOG.md - node_modules/bin-links/README.md - node_modules/bin-links/index.js - node_modules/bin-links/lib/bin-target.js - node_modules/bin-links/lib/check-bin.js - node_modules/bin-links/lib/check-bins.js - node_modules/bin-links/lib/fix-bin.js - node_modules/bin-links/lib/get-node-modules.js - node_modules/bin-links/lib/get-paths.js - node_modules/bin-links/lib/get-prefix.js - node_modules/bin-links/lib/is-windows.js - node_modules/bin-links/lib/link-bin.js - node_modules/bin-links/lib/link-bins.js - node_modules/bin-links/lib/link-gently.js - node_modules/bin-links/lib/link-mans.js - node_modules/bin-links/lib/man-target.js - node_modules/bin-links/lib/shim-bin.js - node_modules/bin-links/package.json - node_modules/byte-size/dist/index.js - node_modules/byte-size/index.mjs - node_modules/byte-size/package.json - node_modules/cidr-regex/index.d.ts - node_modules/cidr-regex/index.js - node_modules/cidr-regex/package.json - node_modules/clean-stack/index.d.ts - node_modules/clean-stack/index.js - node_modules/clean-stack/package.json - node_modules/cli-columns/color.js - node_modules/cli-columns/index.js - node_modules/cli-columns/package.json - node_modules/cli-columns/test.js - node_modules/cli-table3/CHANGELOG.md - node_modules/cli-table3/index.d.ts - node_modules/cli-table3/index.js - node_modules/cli-table3/node_modules/ansi-regex/index.d.ts - node_modules/cli-table3/node_modules/ansi-regex/index.js - node_modules/cli-table3/node_modules/ansi-regex/package.json - node_modules/cli-table3/node_modules/ansi-regex/readme.md - node_modules/cli-table3/node_modules/is-fullwidth-code-point/index.d.ts - node_modules/cli-table3/node_modules/is-fullwidth-code-point/index.js - node_modules/cli-table3/node_modules/is-fullwidth-code-point/package.json - node_modules/cli-table3/node_modules/string-width/index.d.ts - node_modules/cli-table3/node_modules/string-width/index.js - node_modules/cli-table3/node_modules/string-width/package.json - node_modules/cli-table3/node_modules/string-width/readme.md - node_modules/cli-table3/node_modules/strip-ansi/index.d.ts - node_modules/cli-table3/node_modules/strip-ansi/index.js - node_modules/cli-table3/node_modules/strip-ansi/package.json - node_modules/cli-table3/node_modules/strip-ansi/readme.md - node_modules/cli-table3/package.json - node_modules/cli-table3/src/cell.js - node_modules/cli-table3/src/layout-manager.js - node_modules/cli-table3/src/table.js - node_modules/cli-table3/src/utils.js - node_modules/cmd-shim/README.md - node_modules/cmd-shim/index.js - node_modules/cmd-shim/lib/to-batch-syntax.js - node_modules/cmd-shim/package.json - node_modules/code-point-at/index.js - node_modules/code-point-at/package.json - node_modules/common-ancestor-path/README.md - node_modules/common-ancestor-path/index.js - node_modules/common-ancestor-path/package.json - node_modules/debuglog/README.md - node_modules/debuglog/debuglog.js - node_modules/debuglog/package.json - node_modules/depd/History.md - node_modules/depd/Readme.md - node_modules/depd/package.json - node_modules/dezalgo/.travis.yml - node_modules/dezalgo/README.md - node_modules/dezalgo/dezalgo.js - node_modules/dezalgo/test/basic.js - node_modules/emoji-regex/es2015/index.js - node_modules/emoji-regex/es2015/text.js - node_modules/emoji-regex/index.d.ts - node_modules/emoji-regex/index.js - node_modules/emoji-regex/package.json - node_modules/emoji-regex/text.js - node_modules/env-paths/index.d.ts - node_modules/env-paths/index.js - node_modules/env-paths/package.json - node_modules/fast-json-stable-stringify/.eslintrc.yml - node_modules/fast-json-stable-stringify/.github/FUNDING.yml - node_modules/fast-json-stable-stringify/.travis.yml - node_modules/fast-json-stable-stringify/README.md - node_modules/fast-json-stable-stringify/benchmark/index.js - node_modules/fast-json-stable-stringify/benchmark/test.json - node_modules/fast-json-stable-stringify/example/key_cmp.js - node_modules/fast-json-stable-stringify/example/nested.js - node_modules/fast-json-stable-stringify/example/str.js - node_modules/fast-json-stable-stringify/example/value_cmp.js - node_modules/fast-json-stable-stringify/index.d.ts - node_modules/fast-json-stable-stringify/index.js - node_modules/fast-json-stable-stringify/package.json - node_modules/fast-json-stable-stringify/test/cmp.js - node_modules/fast-json-stable-stringify/test/nested.js - node_modules/fast-json-stable-stringify/test/str.js - node_modules/fast-json-stable-stringify/test/to-json.js - node_modules/fs-minipass/README.md - node_modules/fs-minipass/index.js - node_modules/fs-minipass/package.json - node_modules/http-cache-semantics/README.md - node_modules/http-cache-semantics/index.js - node_modules/http-cache-semantics/package.json - node_modules/http-proxy-agent/dist/agent.d.ts - node_modules/http-proxy-agent/dist/agent.js - node_modules/http-proxy-agent/dist/agent.js.map - node_modules/http-proxy-agent/dist/index.d.ts - node_modules/http-proxy-agent/dist/index.js - node_modules/http-proxy-agent/dist/index.js.map - node_modules/http-proxy-agent/package.json - node_modules/https-proxy-agent/dist/agent.d.ts - node_modules/https-proxy-agent/dist/agent.js - node_modules/https-proxy-agent/dist/agent.js.map - node_modules/https-proxy-agent/dist/index.d.ts - node_modules/https-proxy-agent/dist/index.js - node_modules/https-proxy-agent/dist/index.js.map - node_modules/https-proxy-agent/dist/parse-proxy-response.d.ts - node_modules/https-proxy-agent/dist/parse-proxy-response.js - node_modules/https-proxy-agent/dist/parse-proxy-response.js.map - node_modules/https-proxy-agent/package.json - node_modules/humanize-ms/History.md - node_modules/humanize-ms/README.md - node_modules/humanize-ms/package.json - node_modules/ignore-walk/README.md - node_modules/ignore-walk/index.js - node_modules/ignore-walk/package.json - node_modules/infer-owner/README.md - node_modules/infer-owner/index.js - node_modules/infer-owner/package.json - node_modules/init-package-json/CHANGELOG.md - node_modules/init-package-json/README.md - node_modules/init-package-json/default-input.js - node_modules/init-package-json/init-package-json.js - node_modules/init-package-json/package.json - node_modules/is-cidr/index.d.ts - node_modules/is-cidr/index.js - node_modules/is-cidr/package.json - node_modules/is-fullwidth-code-point/index.js - node_modules/is-fullwidth-code-point/package.json - node_modules/is-lambda/.npmignore - node_modules/is-lambda/.travis.yml - node_modules/is-lambda/README.md - node_modules/is-lambda/index.js - node_modules/is-lambda/package.json - node_modules/is-lambda/test.js - node_modules/is-typedarray/README.md - node_modules/is-typedarray/index.js - node_modules/is-typedarray/package.json - node_modules/is-typedarray/test.js - node_modules/json-parse-even-better-errors/CHANGELOG.md - node_modules/json-parse-even-better-errors/README.md - node_modules/json-parse-even-better-errors/index.js - node_modules/json-parse-even-better-errors/package.json - node_modules/json-stringify-nice/.github/FUNDING.yml - node_modules/json-stringify-nice/.npmignore - node_modules/json-stringify-nice/README.md - node_modules/json-stringify-nice/index.js - node_modules/json-stringify-nice/package.json - node_modules/json-stringify-nice/tap-snapshots/test-basic.js-TAP.test.js - node_modules/json-stringify-nice/test/basic.js - node_modules/just-diff-apply/README.md - node_modules/just-diff-apply/index.js - node_modules/just-diff-apply/package.json - node_modules/just-diff/README.md - node_modules/just-diff/index.js - node_modules/just-diff/package.json - node_modules/libnpmaccess/.github/settings.yml - node_modules/libnpmaccess/.github/workflows/ci.yml - node_modules/libnpmaccess/CHANGELOG.md - node_modules/libnpmaccess/README.md - node_modules/libnpmaccess/index.js - node_modules/libnpmaccess/package.json - node_modules/libnpmaccess/test/fixtures/tnock.js - node_modules/libnpmaccess/test/index.js - node_modules/libnpmfund/CHANGELOG.md - node_modules/libnpmfund/README.md - node_modules/libnpmfund/index.js - node_modules/libnpmfund/package.json - node_modules/libnpmhook/CHANGELOG.md - node_modules/libnpmhook/README.md - node_modules/libnpmhook/index.js - node_modules/libnpmhook/package.json - node_modules/libnpmorg/CHANGELOG.md - node_modules/libnpmorg/README.md - node_modules/libnpmorg/index.js - node_modules/libnpmorg/package.json - node_modules/libnpmpack/CHANGELOG.md - node_modules/libnpmpack/README.md - node_modules/libnpmpack/index.js - node_modules/libnpmpack/package.json - node_modules/libnpmpublish/CHANGELOG.md - node_modules/libnpmpublish/README.md - node_modules/libnpmpublish/index.js - node_modules/libnpmpublish/package.json - node_modules/libnpmpublish/publish.js - node_modules/libnpmpublish/unpublish.js - node_modules/libnpmsearch/CHANGELOG.md - node_modules/libnpmsearch/README.md - node_modules/libnpmsearch/index.js - node_modules/libnpmsearch/package.json - node_modules/libnpmteam/CHANGELOG.md - node_modules/libnpmteam/README.md - node_modules/libnpmteam/index.js - node_modules/libnpmteam/package.json - node_modules/libnpmversion/README.md - node_modules/libnpmversion/lib/commit.js - node_modules/libnpmversion/lib/enforce-clean.js - node_modules/libnpmversion/lib/index.js - node_modules/libnpmversion/lib/proc-log.js - node_modules/libnpmversion/lib/retrieve-tag.js - node_modules/libnpmversion/lib/tag.js - node_modules/libnpmversion/lib/version.js - node_modules/libnpmversion/lib/write-json.js - node_modules/libnpmversion/package.json - node_modules/make-fetch-happen/CHANGELOG.md - node_modules/make-fetch-happen/README.md - node_modules/make-fetch-happen/agent.js - node_modules/make-fetch-happen/cache.js - node_modules/make-fetch-happen/package.json - node_modules/make-fetch-happen/utils/configure-options.js - node_modules/make-fetch-happen/utils/initialize-cache.js - node_modules/make-fetch-happen/utils/is-header-conditional.js - node_modules/make-fetch-happen/utils/iterable-to-object.js - node_modules/make-fetch-happen/utils/make-policy.js - node_modules/make-fetch-happen/warning.js - node_modules/minipass-collect/README.md - node_modules/minipass-collect/index.js - node_modules/minipass-collect/package.json - node_modules/minipass-fetch/README.md - node_modules/minipass-fetch/index.js - node_modules/minipass-fetch/lib/abort-error.js - node_modules/minipass-fetch/lib/blob.js - node_modules/minipass-fetch/lib/body.js - node_modules/minipass-fetch/lib/fetch-error.js - node_modules/minipass-fetch/lib/headers.js - node_modules/minipass-fetch/lib/index.js - node_modules/minipass-fetch/lib/request.js - node_modules/minipass-fetch/lib/response.js - node_modules/minipass-fetch/package.json - node_modules/minipass-flush/README.md - node_modules/minipass-flush/index.js - node_modules/minipass-flush/package.json - node_modules/minipass-json-stream/index.js - node_modules/minipass-json-stream/package.json - node_modules/minipass-pipeline/README.md - node_modules/minipass-pipeline/index.js - node_modules/minipass-pipeline/package.json - node_modules/minipass-sized/.npmignore - node_modules/minipass-sized/README.md - node_modules/minipass-sized/index.js - node_modules/minipass-sized/package.json - node_modules/minipass-sized/test/basic.js - node_modules/minipass/README.md - node_modules/minipass/index.js - node_modules/minipass/package.json - node_modules/minizlib/README.md - node_modules/minizlib/constants.js - node_modules/minizlib/index.js - node_modules/minizlib/package.json - node_modules/mkdirp-infer-owner/README.md - node_modules/mkdirp-infer-owner/index.js - node_modules/mkdirp-infer-owner/package.json - node_modules/npm-audit-report/CHANGELOG.md - node_modules/npm-audit-report/README.md - node_modules/npm-audit-report/lib/colors.js - node_modules/npm-audit-report/lib/exit-code.js - node_modules/npm-audit-report/lib/index.js - node_modules/npm-audit-report/lib/reporters/detail.js - node_modules/npm-audit-report/lib/reporters/install.js - node_modules/npm-audit-report/lib/reporters/json.js - node_modules/npm-audit-report/lib/reporters/quiet.js - node_modules/npm-audit-report/package.json - node_modules/npm-install-checks/CHANGELOG.md - node_modules/npm-install-checks/README.md - node_modules/npm-install-checks/index.js - node_modules/npm-install-checks/package.json - node_modules/npm-normalize-package-bin/.github/settings.yml - node_modules/npm-normalize-package-bin/.npmignore - node_modules/npm-normalize-package-bin/README.md - node_modules/npm-normalize-package-bin/index.js - node_modules/npm-normalize-package-bin/package.json - node_modules/npm-normalize-package-bin/test/array.js - node_modules/npm-normalize-package-bin/test/nobin.js - node_modules/npm-normalize-package-bin/test/string.js - node_modules/npm-packlist/README.md - node_modules/npm-packlist/bin/index.js - node_modules/npm-packlist/index.js - node_modules/npm-packlist/package.json - node_modules/npm-pick-manifest/README.md - node_modules/npm-pick-manifest/index.js - node_modules/npm-pick-manifest/package.json - node_modules/npm-profile/CHANGELOG.md - node_modules/npm-profile/README.md - node_modules/npm-profile/index.js - node_modules/npm-profile/package.json - node_modules/npm-registry-fetch/CHANGELOG.md - node_modules/npm-registry-fetch/README.md - node_modules/npm-registry-fetch/auth.js - node_modules/npm-registry-fetch/check-response.js - node_modules/npm-registry-fetch/default-opts.js - node_modules/npm-registry-fetch/errors.js - node_modules/npm-registry-fetch/index.js - node_modules/npm-registry-fetch/package.json - node_modules/npm-registry-fetch/silentlog.js - node_modules/npm-user-validate/README.md - node_modules/npm-user-validate/npm-user-validate.js - node_modules/npm-user-validate/package.json - node_modules/pacote/README.md - node_modules/pacote/lib/bin.js - node_modules/pacote/lib/dir.js - node_modules/pacote/lib/fetcher.js - node_modules/pacote/lib/file.js - node_modules/pacote/lib/git.js - node_modules/pacote/lib/index.js - node_modules/pacote/lib/registry.js - node_modules/pacote/lib/remote.js - node_modules/pacote/lib/util/cache-dir.js - node_modules/pacote/lib/util/is-package-bin.js - node_modules/pacote/lib/util/npm.js - node_modules/pacote/lib/util/proc-log.js - node_modules/pacote/package.json - node_modules/parse-conflict-json/README.md - node_modules/parse-conflict-json/index.js - node_modules/parse-conflict-json/package.json - node_modules/path-parse/.travis.yml - node_modules/path-parse/index.js - node_modules/path-parse/package.json - node_modules/path-parse/test.js - node_modules/promise-all-reject-late/.github/FUNDING.yml - node_modules/promise-all-reject-late/.npmignore - node_modules/promise-all-reject-late/README.md - node_modules/promise-all-reject-late/index.js - node_modules/promise-all-reject-late/package.json - node_modules/promise-all-reject-late/test/index.js - node_modules/promise-call-limit/README.md - node_modules/promise-call-limit/index.js - node_modules/promise-call-limit/package.json - node_modules/qrcode-terminal/.travis.yml - node_modules/qrcode-terminal/README.md - node_modules/qrcode-terminal/bin/qrcode-terminal.js - node_modules/qrcode-terminal/example/basic.js - node_modules/qrcode-terminal/example/callback.js - node_modules/qrcode-terminal/example/small-qrcode.js - node_modules/qrcode-terminal/lib/main.js - node_modules/qrcode-terminal/package.json - node_modules/qrcode-terminal/test/main.js - node_modules/qrcode-terminal/vendor/QRCode/QR8bitByte.js - node_modules/qrcode-terminal/vendor/QRCode/QRBitBuffer.js - node_modules/qrcode-terminal/vendor/QRCode/QRErrorCorrectLevel.js - node_modules/qrcode-terminal/vendor/QRCode/QRMaskPattern.js - node_modules/qrcode-terminal/vendor/QRCode/QRMath.js - node_modules/qrcode-terminal/vendor/QRCode/QRMode.js - node_modules/qrcode-terminal/vendor/QRCode/QRPolynomial.js - node_modules/qrcode-terminal/vendor/QRCode/QRRSBlock.js - node_modules/qrcode-terminal/vendor/QRCode/QRUtil.js - node_modules/read-cmd-shim/README.md - node_modules/read-cmd-shim/index.js - node_modules/read-cmd-shim/package.json - node_modules/read-package-json-fast/README.md - node_modules/read-package-json-fast/index.js - node_modules/read-package-json-fast/package.json - node_modules/readdir-scoped-modules/README.md - node_modules/readdir-scoped-modules/package.json - node_modules/readdir-scoped-modules/readdir.js - node_modules/smart-buffer/.prettierrc.yaml - node_modules/smart-buffer/.travis.yml - node_modules/smart-buffer/build/smartbuffer.js - node_modules/smart-buffer/build/smartbuffer.js.map - node_modules/smart-buffer/build/utils.js - node_modules/smart-buffer/build/utils.js.map - node_modules/smart-buffer/docs/CHANGELOG.md - node_modules/smart-buffer/package.json - node_modules/smart-buffer/typings/smartbuffer.d.ts - node_modules/smart-buffer/typings/utils.d.ts - node_modules/socks-proxy-agent/dist/agent.d.ts - node_modules/socks-proxy-agent/dist/agent.js - node_modules/socks-proxy-agent/dist/agent.js.map - node_modules/socks-proxy-agent/dist/index.d.ts - node_modules/socks-proxy-agent/dist/index.js - node_modules/socks-proxy-agent/dist/index.js.map - node_modules/socks-proxy-agent/package.json - node_modules/socks/.prettierrc.yaml - node_modules/socks/.travis.yml - node_modules/socks/build/client/socksclient.js - node_modules/socks/build/client/socksclient.js.map - node_modules/socks/build/common/constants.js - node_modules/socks/build/common/constants.js.map - node_modules/socks/build/common/helpers.js - node_modules/socks/build/common/helpers.js.map - node_modules/socks/build/common/receivebuffer.js - node_modules/socks/build/common/receivebuffer.js.map - node_modules/socks/build/common/util.js - node_modules/socks/build/common/util.js.map - node_modules/socks/build/index.js - node_modules/socks/build/index.js.map - node_modules/socks/docs/examples/index.md - node_modules/socks/docs/examples/javascript/associateExample.md - node_modules/socks/docs/examples/javascript/bindExample.md - node_modules/socks/docs/examples/javascript/connectExample.md - node_modules/socks/docs/examples/typescript/associateExample.md - node_modules/socks/docs/examples/typescript/bindExample.md - node_modules/socks/docs/examples/typescript/connectExample.md - node_modules/socks/docs/index.md - node_modules/socks/docs/migratingFromV1.md - node_modules/socks/package.json - node_modules/socks/typings/client/socksclient.d.ts - node_modules/socks/typings/common/constants.d.ts - node_modules/socks/typings/common/helpers.d.ts - node_modules/socks/typings/common/receiveBuffer.d.ts - node_modules/socks/typings/common/util.d.ts - node_modules/socks/typings/index.d.ts - node_modules/stringify-package/CHANGELOG.md - node_modules/stringify-package/README.md - node_modules/stringify-package/index.js - node_modules/stringify-package/package.json - node_modules/tiny-relative-date/README.md - node_modules/tiny-relative-date/lib/factory.js - node_modules/tiny-relative-date/lib/index.js - node_modules/tiny-relative-date/package.json - node_modules/tiny-relative-date/src/factory.js - node_modules/tiny-relative-date/src/index.js - node_modules/tiny-relative-date/translations/da.js - node_modules/tiny-relative-date/translations/de.js - node_modules/tiny-relative-date/translations/en-short.js - node_modules/tiny-relative-date/translations/en.js - node_modules/treeverse/README.md - node_modules/treeverse/index.js - node_modules/treeverse/lib/breadth.js - node_modules/treeverse/lib/depth-descent.js - node_modules/treeverse/lib/depth.js - node_modules/treeverse/package.json - node_modules/unique-slug/.travis.yml - node_modules/unique-slug/README.md - node_modules/unique-slug/index.js - node_modules/unique-slug/package.json - node_modules/unique-slug/test/index.js - node_modules/walk-up-path/README.md - node_modules/walk-up-path/index.js - node_modules/walk-up-path/package.json - package-lock.json - package.json - scripts/bundle-and-gitignore-deps.js - scripts/changelog.js - scripts/clean-old.sh - scripts/docs-build.js - scripts/install.sh - scripts/maketest - scripts/pr - scripts/publish-tag.js - scripts/release.sh - scripts/relocate.sh - scripts/resetdeps.sh - scripts/update-authors.sh - scripts/update-dist-tags.js - tap-snapshots/test-lib-config.js-TAP.test.js - tap-snapshots/test-lib-dist-tag.js-TAP.test.js - tap-snapshots/test-lib-fund.js-TAP.test.js - tap-snapshots/test-lib-link.js-TAP.test.js - tap-snapshots/test-lib-ls.js-TAP.test.js - tap-snapshots/test-lib-outdated.js-TAP.test.js - tap-snapshots/test-lib-owner.js-TAP.test.js - tap-snapshots/test-lib-publish.js-TAP.test.js - tap-snapshots/test-lib-utils-cmd-list.js-TAP.test.js - tap-snapshots/test-lib-utils-config.js-TAP.test.js - tap-snapshots/test-lib-utils-error-handler.js-TAP.test.js - tap-snapshots/test-lib-utils-error-message.js-TAP.test.js - tap-snapshots/test-lib-utils-explain-dep.js-TAP.test.js - tap-snapshots/test-lib-utils-explain-eresolve.js-TAP.test.js - tap-snapshots/test-lib-utils-flat-options.js-TAP.test.js - tap-snapshots/test-lib-utils-reify-output.js-TAP.test.js - tap-snapshots/test-lib-utils-tar.js-TAP.test.js - tap-snapshots/test-lib-utils-update-notifier.js-TAP.test.js - tap-snapshots/test-lib-view.js-TAP.test.js - tap-snapshots/test-tap-repo.js-TAP.test.js - test/bin/npm-cli.js - test/bin/npx-cli.js - test/coverage-map.js - test/fixtures/eresolve-explanations.js - test/lib/access.js - test/lib/adduser.js - test/lib/audit.js - test/lib/auth/legacy.js - test/lib/auth/oauth.js - test/lib/auth/saml.js - test/lib/auth/sso.js - test/lib/bin.js - test/lib/birthday.js - test/lib/bugs.js - test/lib/ci.js - test/lib/cli.js - test/lib/config.js - test/lib/dedupe.js - test/lib/dist-tag.js - test/lib/docs.js - test/lib/exec.js - test/lib/explain.js - test/lib/explore.js - test/lib/find-dupes.js - test/lib/fund.js - test/lib/get.js - test/lib/install.js - test/lib/link.js - test/lib/ll.js - test/lib/load-all-commands.js - test/lib/load-all.js - test/lib/logout.js - test/lib/ls.js - test/lib/npm.js - test/lib/outdated.js - test/lib/owner.js - test/lib/pack.js - test/lib/ping.js - test/lib/prefix.js - test/lib/prune.js - test/lib/publish.js - test/lib/repo.js - test/lib/restart.js - test/lib/root.js - test/lib/run-script.js - test/lib/start.js - test/lib/stop.js - test/lib/test.js - test/lib/token.js - test/lib/utils/audit-error.js - test/lib/utils/cleanup-log-files.js - test/lib/utils/cmd-list.js - test/lib/utils/completion/installed-deep.js - test/lib/utils/completion/installed-shallow.js - test/lib/utils/completion/none.js - test/lib/utils/config.js - test/lib/utils/deref-command.js - test/lib/utils/did-you-mean.js - test/lib/utils/error-handler.js - test/lib/utils/error-message.js - test/lib/utils/escape-arg.js - test/lib/utils/escape-exec-path.js - test/lib/utils/explain-dep.js - test/lib/utils/explain-eresolve.js - test/lib/utils/file-exists.js - test/lib/utils/flat-options.js - test/lib/utils/get-identity.js - test/lib/utils/get-project-scope.js - test/lib/utils/hosted-git-info-from-manifest.js - test/lib/utils/is-windows-bash.js - test/lib/utils/is-windows-shell.js - test/lib/utils/is-windows.js - test/lib/utils/lifecycle-cmd.js - test/lib/utils/output.js - test/lib/utils/path.js - test/lib/utils/perf.js - test/lib/utils/ping.js - test/lib/utils/proc-log-listener.js - test/lib/utils/read-local-package.js - test/lib/utils/reify-output.js - test/lib/utils/replace-info.js - test/lib/utils/setup-log.js - test/lib/utils/tar.js - test/lib/utils/unsupported.js - test/lib/utils/update-notifier.js - test/lib/view.js - test/lib/whoami.js -Copyright: NONE -License: UNKNOWN - FIXME - -Files: node_modules/@npmcli/arborist/LICENSE - node_modules/@npmcli/ci-detect/LICENSE - node_modules/@npmcli/config/LICENSE - node_modules/@npmcli/git/LICENSE - node_modules/@npmcli/installed-package-contents/LICENSE - node_modules/@npmcli/metavuln-calculator/LICENSE - node_modules/@npmcli/name-from-folder/LICENSE - node_modules/@npmcli/promise-spawn/LICENSE - node_modules/@npmcli/run-script/LICENSE - node_modules/bin-links/LICENSE - node_modules/libnpmhook/LICENSE.md - node_modules/make-fetch-happen/LICENSE - node_modules/npm-audit-report/LICENSE - node_modules/npm-normalize-package-bin/LICENSE - node_modules/npm-pick-manifest/LICENSE.md - node_modules/npm-registry-fetch/LICENSE.md -Copyright: npm, Inc. -License: ISC - FIXME - -Files: node_modules/dezalgo/LICENSE - node_modules/fs-minipass/LICENSE - node_modules/ignore-walk/LICENSE - node_modules/json-stringify-nice/LICENSE - node_modules/minipass-collect/LICENSE - node_modules/minipass-flush/LICENSE - node_modules/minipass-pipeline/LICENSE - node_modules/minipass-sized/LICENSE - node_modules/npm-packlist/LICENSE - node_modules/readdir-scoped-modules/LICENSE -Copyright: Isaac Z. Schlueter and Contributors -License: ISC - FIXME - -Files: node_modules/aggregate-error/license - node_modules/clean-stack/license - node_modules/cli-table3/node_modules/ansi-regex/license - node_modules/cli-table3/node_modules/is-fullwidth-code-point/license - node_modules/cli-table3/node_modules/string-width/license - node_modules/cli-table3/node_modules/strip-ansi/license - node_modules/code-point-at/license - node_modules/env-paths/license - node_modules/is-fullwidth-code-point/license -Copyright: Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com) -License: Expat - FIXME - -Files: node_modules/libnpmaccess/LICENSE - node_modules/libnpmorg/LICENSE - node_modules/libnpmpack/LICENSE - node_modules/libnpmpublish/LICENSE - node_modules/libnpmsearch/LICENSE - node_modules/libnpmteam/LICENSE - node_modules/npm-profile/LICENSE - node_modules/stringify-package/LICENSE - node_modules/unique-slug/LICENSE -Copyright: npm, Inc -License: ISC - FIXME - -Files: node_modules/common-ancestor-path/LICENSE - node_modules/init-package-json/LICENSE - node_modules/libnpmversion/LICENSE - node_modules/mkdirp-infer-owner/LICENSE - node_modules/promise-all-reject-late/LICENSE - node_modules/promise-call-limit/LICENSE - node_modules/walk-up-path/LICENSE -Copyright: Isaac Z. Schlueter -License: ISC - FIXME - -Files: node_modules/humanize-ms/LICENSE - node_modules/is-typedarray/LICENSE.md - node_modules/minipass-json-stream/README.md - node_modules/smart-buffer/README.md - node_modules/smart-buffer/docs/README_v3.md - node_modules/socks/README.md -Copyright: NONE -License: Expat - FIXME - -Files: node_modules/cmd-shim/LICENSE - node_modules/infer-owner/LICENSE - node_modules/minipass/LICENSE - node_modules/parse-conflict-json/LICENSE - node_modules/read-package-json-fast/LICENSE - node_modules/treeverse/LICENSE -Copyright: npm, Inc. and Contributors -License: ISC - FIXME - -Files: node_modules/clean-stack/readme.md - node_modules/cli-table3/node_modules/is-fullwidth-code-point/readme.md - node_modules/code-point-at/readme.md - node_modules/env-paths/readme.md - node_modules/is-fullwidth-code-point/readme.md -Copyright: [Sindre Sorhus -License: UNKNOWN - FIXME - -Files: node_modules/agent-base/README.md - node_modules/http-proxy-agent/README.md - node_modules/https-proxy-agent/README.md - node_modules/socks-proxy-agent/README.md -Copyright: 2013, Nathan Rajlich <nathan@tootallnate.net> -License: Expat - FIXME - -Files: CONTRIBUTING.md - changelogs/CHANGELOG-4.md - node_modules/tiny-relative-date/translations/es.js -Copyright: -License: UNKNOWN - FIXME - -Files: debian/control - debian/patches/2004_remove_shebang.patch - debian/patches/2010_privacy_breach_travis.patch -Copyright: rémy Lal <kapouer@melix.org> -License: UNKNOWN - FIXME - -Files: node_modules/cidr-regex/LICENSE - node_modules/is-cidr/LICENSE -Copyright: silverwind -License: BSD-2-clause - FIXME - -Files: node_modules/smart-buffer/LICENSE - node_modules/socks/LICENSE -Copyright: 2013, Josh Glazebrook - 2013-2017, Josh Glazebrook -License: Expat - FIXME - -Files: node_modules/just-diff-apply/LICENSE - node_modules/just-diff/LICENSE -Copyright: 2016, angus croll -License: Expat - FIXME - -Files: node_modules/cli-columns/LICENSE - node_modules/cli-columns/README.md -Copyright: Shannon Moeller <me@shannonmoeller.com> (shannonmoeller.com) -License: Expat - FIXME - -Files: node_modules/@npmcli/map-workspaces/LICENSE - node_modules/libnpmfund/LICENSE -Copyright: npm Inc. -License: ISC - FIXME - -Files: node_modules/depd/lib/browser/index.js - node_modules/depd/lib/compat/event-listener-count.js -Copyright: (c) 2015 Douglas Christopher Wilson -License: UNKNOWN - FIXME - -Files: node_modules/byte-size/README.hbs - node_modules/byte-size/README.md -Copyright: 2014, -20 Lloyd Brookes <75pound@gmail.com>. -License: UNKNOWN - FIXME - -Files: node_modules/cidr-regex/README.md - node_modules/is-cidr/README.md -Copyright: [silverwind -License: UNKNOWN - FIXME - -Files: node_modules/make-fetch-happen/index.js -Copyright: 2010-2012, Mikeal Rogers -License: Apache-2.0 - FIXME - -Files: node_modules/qrcode-terminal/LICENSE -Copyright: [yyyy - license to reproduce, prepare Derivative Works of, - patent, trademark, and -License: Apache-2.0 and/or Expat - FIXME - -Files: changelogs/CHANGELOG-3.md -Copyright: -License: Artistic-2.0 - FIXME - -Files: LICENSE -Copyright: 2000-2006, The Perl Foundation. - Mathias Pettersson and Brian Hammond - Tjarda Koster, https:jelloween.deviantart.com - allow anyone who receives a copy of the Modified Version to - npm, Inc. and Contributors - their respective copyright owners -License: Artistic-2.0 - FIXME - -Files: changelogs/CHANGELOG-2.md -Copyright: NONE -License: Artistic-2.0 - FIXME - -Files: node_modules/http-cache-semantics/LICENSE -Copyright: 2016-2018, Kornel Lesiński -License: BSD-2-clause - FIXME - -Files: node_modules/npm-user-validate/LICENSE -Copyright: Robert Kowalski -License: BSD-2-clause - FIXME - -Files: node_modules/npm-install-checks/LICENSE -Copyright: Robert Kowalski and Isaac Z. Schlueter ("Authors") -License: BSD-2-clause - FIXME - -Files: node_modules/agentkeepalive/LICENSE -Copyright: (c) 2012 - 2015 fengmk2 <fengmk2@gmail.com> - (c) node-modules and other contributors. -License: Expat - FIXME - -Files: node_modules/byte-size/LICENSE -Copyright: 2014, -20 Lloyd Brookes <75pound@gmail.com> -License: Expat - FIXME - -Files: node_modules/minipass-fetch/LICENSE -Copyright: 2016, David Frank - Isaac Z. Schlueter and Contributors -License: Expat - FIXME - -Files: node_modules/minipass-json-stream/LICENSE -Copyright: 2011, Dominic Tarr - Isaac Z. Schlueter and Contributors -License: Expat - FIXME - -Files: node_modules/depd/LICENSE -Copyright: 2014-2017, Douglas Christopher Wilson -License: Expat - FIXME - -Files: node_modules/fast-json-stable-stringify/LICENSE -Copyright: 2013, James Halliday - 2017, Evgeny Poberezkin -License: Expat - FIXME - -Files: node_modules/cli-table3/README.md -Copyright: 2010, LearnBoost <dev@learnboost.com> - 2014, James Talmage <james.talmage@jrtechnical.com> -License: Expat - FIXME - -Files: node_modules/cli-table3/LICENSE -Copyright: 2014, James Talmage <james.talmage@jrtechnical.com> -License: Expat - FIXME - -Files: node_modules/path-parse/LICENSE -Copyright: 2015, Javier Blanco -License: Expat - FIXME - -Files: node_modules/tiny-relative-date/LICENSE.md -Copyright: 2017, Joseph Wynn -License: Expat - FIXME - -Files: node_modules/json-parse-even-better-errors/LICENSE.md -Copyright: 2017, Kat Marchán - npm, Inc. -License: Expat - FIXME - -Files: node_modules/qrcode-terminal/vendor/QRCode/index.js -Copyright: 2009, Kazuhiko Arase -License: Expat - FIXME - -Files: node_modules/is-lambda/LICENSE -Copyright: 2016-2017, Thomas Watson Steen -License: Expat - FIXME - -Files: node_modules/ansicolors/LICENSE -Copyright: 2013, Thorsten Lorenz. -License: Expat - FIXME - -Files: node_modules/emoji-regex/README.md -Copyright: - code points: 1 - emoji modifier base (Emoji_Modifier_Base) - 🏿 - code points: 2 - 🏿 emoji modifier base followed by a modifier -License: Expat - FIXME - -Files: node_modules/minizlib/LICENSE -Copyright: Isaac Z. Schlueter and Contributors - Joyent, Inc. and other Node contributors. - Node.js contributors. -License: Expat - FIXME - -Files: node_modules/debuglog/LICENSE -Copyright: Joyent, Inc. and other Node contributors. -License: Expat - FIXME - -Files: node_modules/emoji-regex/LICENSE-MIT.txt -Copyright: Mathias Bynens <https:mathiasbynens.be/> -License: Expat - FIXME - -Files: node_modules/read-cmd-shim/LICENSE -Copyright: 2015, Rebecca Turner <me@re-becca.org> -License: ISC - FIXME - -Files: node_modules/pacote/LICENSE -Copyright: Isaac Z. Schlueter, Kat Marchán, npm, Inc., and Contributors -License: ISC - FIXME - -Files: node_modules/depd/lib/compat/callsite-tostring.js -Copyright: (c) 2014 Douglas Christopher Wilson -License: UNKNOWN - FIXME - -Files: node_modules/humanize-ms/index.js -Copyright: (c) 2014 dead_horse <dead_horse@qq.com> -License: UNKNOWN - FIXME - -Files: node_modules/depd/lib/compat/index.js -Copyright: (c) 2014-2015 Douglas Christopher Wilson -License: UNKNOWN - FIXME - -Files: node_modules/depd/index.js -Copyright: (c) 2014-2017 Douglas Christopher Wilson -License: UNKNOWN - FIXME - -Files: node_modules/agentkeepalive/History.md -Copyright: <<whxaxes@qq.com>>) -License: UNKNOWN - FIXME - -Files: node_modules/qrcode-terminal/example/basic.png -Copyright: Copyright Apple, Inc., 2013 -License: UNKNOWN - FIXME - -Files: AUTHORS -Copyright: Herculano <andresilveirah@gmail.com> - bastien Santoro <dereckson@espace-win.org> - déric Harper <fharper@npmjs.com> - rémy Lal <kapouer@melix.org> -License: UNKNOWN - FIXME - -Files: docs/content/using-npm/semver.md -Copyright: Isaac Z. Schlueter -License: UNKNOWN - FIXME - -Files: node_modules/path-parse/README.md -Copyright: [Javier Blanco -License: UNKNOWN - FIXME - -Files: node_modules/@npmcli/arborist/lib/arborist/build-ideal-tree.js -Copyright: an already-placed peer in a different peer set at the same level. -License: UNKNOWN - FIXME - -Files: node_modules/npm-pick-manifest/CHANGELOG.md -Copyright: as belonging to npm, Inc. -License: UNKNOWN - FIXME - -Files: node_modules/dezalgo/package.json -Copyright: aÌ›Í - òr̹̰̖͉͈͝d̷̲̦̖͓eÌ²Í“Ì - v̺͉͇̩e̵͖-̺̪m͍i̜n̪̲̲̲̮dÌ· Ì¢rÍ˜Ì - ̘̖̰e ̥̘͓͉͔͙̼N̟̜̣̘͔̪e̞̞̤͢z̰̖̘͇pÍŸÌ - ̙a̲͖̻̗̹o̥̼̫s̝̖̜̝͚̫̟.̺͚ ̸̱̲W̶̥̣͖̦iÍÌ¤Ì¬Ì±Ì³Í - ̤̦̮͇̞̦̲B͎̭͇̦̼eÌ¢hin͏͙̟̪dÌ´Ì°Í“Ì»Ì£Ì®Í - Ì©e͏̣n͚͇̗̭̺͍tì͙̣n͏̖̥̗͎̰̪g̞͓̭̱̯̫̕ ÍœÌ£Í - ̩͚kÌ¢Ì¥Ì - ̫͍̩ ̩̮̖̟͇͉́t͔͔͎̗h͏̗̟eÌ˜Í‰Ì°Ì¦Ì - ̭̫͚̱a̤͉̤͔͜osÍ€Í•Ì¤Ì¼ÍÌ²Í - ̳̟͈.̪̦̰̳", -License: UNKNOWN - FIXME - -Files: docs/content/using-npm/disputes.md -Copyright: npm, Inc. - or licenses (for example, cloning an MIT-licensed -License: UNKNOWN - FIXME - -Files: node_modules/npm-normalize-package-bin/test/object.js -Copyright: pm': 'target', -License: UNKNOWN - FIXME - -Files: debian/README.Debian -Copyright: rémy Lal <kapouer@melix.org> Fri, 28 Jan 2011 00:33:28 +0200 -License: UNKNOWN - FIXME - -Files: debian/NEWS -Copyright: rémy Lal <kapouer@melix.org> Tue, 25 Oct 2011 15:19:32 +0200 -License: UNKNOWN - FIXME - diff --git a/debian/docs b/debian/docs deleted file mode 100644 index a0ad18c..0000000 --- a/debian/docs +++ /dev/null @@ -1,3 +0,0 @@ -CONTRIBUTING.md -README.md -changelogs/* diff --git a/debian/install b/debian/install deleted file mode 100644 index a3cd21e..0000000 --- a/debian/install +++ /dev/null @@ -1 +0,0 @@ -debian/npmrc usr/share/nodejs/npm diff --git a/debian/links b/debian/links deleted file mode 100644 index 0e81330..0000000 --- a/debian/links +++ /dev/null @@ -1,3 +0,0 @@ -usr/share/man usr/share/nodejs/npm/man -usr/share/nodejs/npm usr/share/npm -usr/share/man/man1/npm-arborist.1.gz usr/share/man/man1/arborist.1.gz diff --git a/debian/manpages b/debian/manpages deleted file mode 100644 index 6c21da0..0000000 --- a/debian/manpages +++ /dev/null @@ -1,3 +0,0 @@ -man/man1/*.1 -man/man5/n*.5 -man/man5/p*.5 diff --git a/debian/nodejs/additional_components b/debian/nodejs/additional_components deleted file mode 100644 index fa1e8e3..0000000 --- a/debian/nodejs/additional_components +++ /dev/null @@ -1,3 +0,0 @@ -node_modules/* -node_modules/@*/* -packages/* diff --git a/debian/nodejs/files b/debian/nodejs/files deleted file mode 100644 index 57b480f..0000000 --- a/debian/nodejs/files +++ /dev/null @@ -1,2 +0,0 @@ -bin -lib diff --git a/debian/nodejs/links b/debian/nodejs/links deleted file mode 100644 index e339301..0000000 --- a/debian/nodejs/links +++ /dev/null @@ -1,10 +0,0 @@ -npm/node_modules @npmcli/node_modules -npm/node_modules npm-packlist/node_modules -npm/node_modules pacote/node_modules -npm/bin/npm-cli.js /usr/bin/npm -npm/bin/npx-cli.js /usr/bin/npx -@npmcli/arborist/bin/index.js /usr/bin/arborist -@npmcli/arborist/bin/index.js /usr/bin/npm-arborist -npm-packlist/bin/index.js /usr/bin/npm-packlist -pacote/lib/bin.js /usr/bin/pacote -qrcode-terminal/bin/qrcode-terminal.js /usr/bin/qrcode-terminal diff --git a/debian/nodejs/root_modules b/debian/nodejs/root_modules deleted file mode 100644 index 27c3be9..0000000 --- a/debian/nodejs/root_modules +++ /dev/null @@ -1,5 +0,0 @@ -node_modules/@npmcli/* -node_modules/npm-packlist -packages/* -node_modules/pacote -node_modules/qrcode-terminal diff --git a/debian/npm.bash-completion b/debian/npm.bash-completion deleted file mode 100644 index 780af75..0000000 --- a/debian/npm.bash-completion +++ /dev/null @@ -1 +0,0 @@ -lib/utils/completion.sh npm diff --git a/debian/npm.lintian-overrides b/debian/npm.lintian-overrides deleted file mode 100644 index 50ba118..0000000 --- a/debian/npm.lintian-overrides +++ /dev/null @@ -1,6 +0,0 @@ -# False positive -executable-not-elf-or-script usr/share/nodejs/@npmcli/run-script/lib/node-gyp-bin/node-gyp.cmd -extra-license-file usr/share/nodejs/@npmcli/arborist/bin/license.js -repeated-path-segment arborist usr/share/nodejs/@npmcli/arborist/lib/arborist/ -# Unneeded chmod +x -script-not-executable usr/share/nodejs/npm/node_modules/* diff --git a/debian/npm.maintscript b/debian/npm.maintscript deleted file mode 100644 index cd8fdf9..0000000 --- a/debian/npm.maintscript +++ /dev/null @@ -1,3 +0,0 @@ -rm_conffile /etc/bash_completion.d/npm 5.8.0+ds6-4~ -dir_to_symlink /usr/share/npm nodejs/npm 7.0.8+ds-2~ -symlink_to_dir /usr/share/nodejs/npm ../npm 7.0.8+ds-2~ diff --git a/debian/npmrc b/debian/npmrc deleted file mode 100644 index 57ec023..0000000 --- a/debian/npmrc +++ /dev/null @@ -1,5 +0,0 @@ -# DO NOT MODIFY THIS FILE - use /etc/npmrc instead. -globalconfig=/etc/npmrc -globalignorefile=/etc/npmignore -prefix=/usr/local - diff --git a/debian/patches/2004_remove_shebang.patch b/debian/patches/2004_remove_shebang.patch deleted file mode 100644 index 8a75435..0000000 --- a/debian/patches/2004_remove_shebang.patch +++ /dev/null @@ -1,11 +0,0 @@ -Description: remove shebang from completion script -Forwarded: not-needed -Author: Jérémy Lal <kapouer@melix.org> -Last-Update: 2012-04-07 ---- a/lib/utils/completion.sh -+++ b/lib/utils/completion.sh -@@ -1,4 +1,3 @@ --#!/bin/bash - ###-begin-npm-completion-### - # - # npm command completion script diff --git a/debian/patches/2011_node-gyp-path.patch b/debian/patches/2011_node-gyp-path.patch deleted file mode 100644 index 534b8c0..0000000 --- a/debian/patches/2011_node-gyp-path.patch +++ /dev/null @@ -1,17 +0,0 @@ -Author: Diane Trout <diane@ghic.org> -Forwarded: not-needed -Description: Use the Debian packaged version of node-gyp instead - of the convenience copy that was removed on repack. -Reviewed-By: Xavier Guimard <yadd@debian.org> -Last-Update: 2020-10-08 - ---- a/bin/node-gyp-bin/node-gyp -+++ b/bin/node-gyp-bin/node-gyp -@@ -1,6 +1,6 @@ - #!/usr/bin/env sh - if [ "x$npm_config_node_gyp" = "x" ]; then -- node "`dirname "$0"`/../../node_modules/node-gyp/bin/node-gyp.js" "$@" -+ /usr/bin/node-gyp "$@" - else - "$npm_config_node_gyp" "$@" - fi diff --git a/debian/patches/2012_dont_install_man_deps.patch b/debian/patches/2012_dont_install_man_deps.patch deleted file mode 100644 index 851d113..0000000 --- a/debian/patches/2012_dont_install_man_deps.patch +++ /dev/null @@ -1,16 +0,0 @@ -Description: don't install dependencies during build -Author: Xavier Guimard <yadd@debian.org> -Forwarded: not-needed -Last-Update: 2021-09-22 - ---- a/Makefile -+++ b/Makefile -@@ -32,7 +32,7 @@ - - # don't regenerate the snapshot if we're generating - # snapshots, since presumably we just did that. --mandocs: dev-deps $(mandocs) -+mandocs: $(mandocs) - @ ! [ $${npm_lifecycle_event} = "snap" ] && \ - ! [ $${npm_lifecycle_event} = "postsnap" ] && \ - TAP_SNAPSHOT=1 node test/lib/utils/config/definitions.js || true diff --git a/debian/patches/2020_reproducible_documentation_build.patch b/debian/patches/2020_reproducible_documentation_build.patch deleted file mode 100644 index 0d65d99..0000000 --- a/debian/patches/2020_reproducible_documentation_build.patch +++ /dev/null @@ -1,19 +0,0 @@ -Description: Use source-date-epoch as timestamp source for documentation -Author: James Addison <jay+salsa@jp-hosting.net> -Origin: https://salsa.debian.org/js-team/npm/-/merge_requests/7 -Forwarded: no -Reviewed-By: Yadd <yadd@debian.org> -Last-Update: 2021-11-27 - ---- a/scripts/docs-build.js -+++ b/scripts/docs-build.js -@@ -36,7 +36,8 @@ - .replace(/\[([^\]]+)\]\(\/using-npm\/([^)]+)\)/g, replacer) - .trim() - -- fs.writeFile(dest, marked(result), 'utf8', function (err) { -+ var date = new Date(process.env.SOURCE_DATE_EPOCH) -+ fs.writeFile(dest, marked(result, {date}), 'utf8', function (err) { - if (err) { - return console.log(err) - } diff --git a/debian/patches/dont-check-for-last-version.patch b/debian/patches/dont-check-for-last-version.patch deleted file mode 100644 index 9e910ee..0000000 --- a/debian/patches/dont-check-for-last-version.patch +++ /dev/null @@ -1,95 +0,0 @@ -Description: don't check for last version -Author: Yadd <yadd@debian.org> -Forwarded: not-needed -Last-Update: 2021-12-13 - ---- a/lib/utils/update-notifier.js -+++ b/lib/utils/update-notifier.js -@@ -35,85 +35,8 @@ - } - - const updateNotifier = async (npm, spec = 'latest') => { -- // never check for updates in CI, when updating npm already, or opted out -- if (!npm.config.get('update-notifier') || -- isGlobalNpmUpdate(npm) || -- ciDetect()) { -- return null -- } -- -- // if we're on a prerelease train, then updates are coming fast -- // check for a new one daily. otherwise, weekly. -- const { version } = npm -- const current = semver.parse(version) -- -- // if we're on a beta train, always get the next beta -- if (current.prerelease.length) { -- spec = `^${version}` -- } -- -- // while on a beta train, get updates daily -- const duration = spec !== 'latest' ? DAILY : WEEKLY -- -- // if we've already checked within the specified duration, don't check again -- if (!(await checkTimeout(npm, duration))) { -- return null -- } -- -- // if they're currently using a prerelease, nudge to the next prerelease -- // otherwise, nudge to latest. -- const useColor = log.useColor() -- -- const mani = await pacote.manifest(`npm@${spec}`, { -- // always prefer latest, even if doing --tag=whatever on the cmd -- defaultTag: 'latest', -- ...npm.flatOptions, -- }).catch(() => null) -- -- // if pacote failed, give up -- if (!mani) { -- return null -- } -- -- const latest = mani.version -- -- // if the current version is *greater* than latest, we're on a 'next' -- // and should get the updates from that release train. -- // Note that this isn't another http request over the network, because -- // the packument will be cached by pacote from previous request. -- if (semver.gt(version, latest) && spec === 'latest') { -- return updateNotifier(npm, `^${version}`) -- } -- -- // if we already have something >= the desired spec, then we're done -- if (semver.gte(version, latest)) { -- return null -- } -- -- // ok! notify the user about this update they should get. -- // The message is saved for printing at process exit so it will not get -- // lost in any other messages being printed as part of the command. -- const update = semver.parse(mani.version) -- const type = update.major !== current.major ? 'major' -- : update.minor !== current.minor ? 'minor' -- : update.patch !== current.patch ? 'patch' -- : 'prerelease' -- const typec = !useColor ? type -- : type === 'major' ? chalk.red(type) -- : type === 'minor' ? chalk.yellow(type) -- : chalk.green(type) -- const oldc = !useColor ? current : chalk.red(current) -- const latestc = !useColor ? latest : chalk.green(latest) -- const changelog = `https://github.com/npm/cli/releases/tag/v${latest}` -- const changelogc = !useColor ? `<${changelog}>` : chalk.cyan(changelog) -- const cmd = `npm install -g npm@${latest}` -- const cmdc = !useColor ? `\`${cmd}\`` : chalk.green(cmd) -- const message = `\nNew ${typec} version of npm available! ` + -- `${oldc} -> ${latestc}\n` + -- `Changelog: ${changelogc}\n` + -- `Run ${cmdc} to update!\n` -- -- return message -+ // Maintained by Debian JS Team -+ return null - } - - // only update the notification timeout if we actually finished checking diff --git a/debian/patches/fix-test.patch b/debian/patches/fix-test.patch deleted file mode 100644 index 799c6fb..0000000 --- a/debian/patches/fix-test.patch +++ /dev/null @@ -1,64 +0,0 @@ -Description: fix test -Author: Yadd <yadd@debian.org> -Forwarded: not-needed -Last-Update: 2021-10-06 - ---- a/test/lib/edit.js -+++ b/test/lib/edit.js -@@ -52,11 +52,11 @@ - editorOpts = null - }) - -- return edit.exec(['semver'], (err) => { -+ return edit.exec(['init-package-json'], (err) => { - if (err) - throw err - -- const path = resolve(__dirname, '../../node_modules/semver') -+ const path = resolve(__dirname, '../../node_modules/init-package-json') - t.strictSame(editorBin, EDITOR, 'used the correct editor') - t.strictSame(editorArgs, [path], 'edited the correct directory') - t.strictSame(editorOpts, { stdio: 'inherit' }, 'passed the correct opts') -@@ -75,8 +75,8 @@ - }) - - rebuildFail = new Error('test error') -- return edit.exec(['semver'], (err) => { -- const path = resolve(__dirname, '../../node_modules/semver') -+ return edit.exec(['init-package-json'], (err) => { -+ const path = resolve(__dirname, '../../node_modules/init-package-json') - t.strictSame(editorBin, EDITOR, 'used the correct editor') - t.strictSame(editorArgs, [path], 'edited the correct directory') - t.strictSame(editorOpts, { stdio: 'inherit' }, 'passed the correct opts') -@@ -96,11 +96,11 @@ - EDITOR = 'vim' - }) - -- return edit.exec(['semver'], (err) => { -+ return edit.exec(['init-package-json'], (err) => { - if (err) - throw err - -- const path = resolve(__dirname, '../../node_modules/semver') -+ const path = resolve(__dirname, '../../node_modules/init-package-json') - t.strictSame(editorBin, 'code', 'used the correct editor') - t.strictSame(editorArgs, ['-w', path], 'edited the correct directory, keeping flags') - t.strictSame(editorOpts, { stdio: 'inherit' }, 'passed the correct opts') -@@ -125,7 +125,7 @@ - gracefulFs.lstat = _lstat - }) - -- return edit.exec(['semver'], (err) => { -+ return edit.exec(['init-package-json'], (err) => { - t.match(err, /lstat failed/, 'user received correct error') - t.end() - }) -@@ -137,7 +137,7 @@ - EDITOR_CODE = 0 - }) - -- return edit.exec(['semver'], (err) => { -+ return edit.exec(['init-package-json'], (err) => { - t.match(err, /exited with code: 137/, 'user received correct error') - t.end() - }) diff --git a/debian/patches/fix-tests.patch b/debian/patches/fix-tests.patch deleted file mode 100644 index 60c48a3..0000000 --- a/debian/patches/fix-tests.patch +++ /dev/null @@ -1,70 +0,0 @@ -Description: remove some tests (needs tap ≥ 14) -Author: Xavier Guimard <yadd@debian.org> -Forwarded: not-needed -Last-Update: 2021-03-15 - ---- a/test/lib/utils/config.js -+++ b/test/lib/utils/config.js -@@ -65,28 +65,6 @@ - const os = { networkInterfaces, tmpdir } - const pkg = { version: '7.0.0' } - --t.test('working network interfaces, not windows', t => { -- const config = requireInject('../../../lib/utils/config.js', { -- os, -- '@npmcli/ci-detect': () => false, -- '../../../lib/utils/is-windows.js': false, -- '../../../package.json': pkg, -- }) -- t.matchSnapshot(config) -- t.end() --}) -- --t.test('no working network interfaces, on windows', t => { -- const config = requireInject('../../../lib/utils/config.js', { -- os: { tmpdir, networkInterfaces: networkInterfacesThrow }, -- '@npmcli/ci-detect': () => false, -- '../../../lib/utils/is-windows.js': true, -- '../../../package.json': pkg, -- }) -- t.matchSnapshot(config) -- t.end() --}) -- - t.test('no comspec on windows', t => { - delete process.env.ComSpec - const config = requireInject('../../../lib/utils/config.js', { ---- a/test/lib/utils/flat-options.js -+++ b/test/lib/utils/flat-options.js -@@ -142,7 +142,6 @@ - npmSession: '12345', - cache: generatedFlat.cache.replace(/\\/g, '/'), - } -- t.matchSnapshot(clean, 'flat options') - t.equal(generatedFlat.npmCommand, null, 'command not set yet') - npm.command = 'view' - t.equal(generatedFlat.npmCommand, 'view', 'command updated via getter') ---- a/test/lib/utils/reify-finish.js -+++ b/test/lib/utils/reify-finish.js -@@ -63,21 +63,6 @@ - }) - }) - --t.test('should write if everything above passes', async t => { -- expectWrite = true -- delete builtinConfMock.loadError -- const path = t.testdir() -- await reifyFinish(npm, { -- options: { global: true }, -- actualTree: { -- inventory: new Map([['node_modules/npm', {path}]]), -- }, -- }) -- // windowwwwwwssss!!!!! -- const data = fs.readFileSync(`${path}/npmrc`, 'utf8').replace(/\r\n/g, '\n') -- t.matchSnapshot(data, 'written config') --}) -- - t.test('works without fs.promises', async t => { - t.doesNotThrow(() => requireInject('../../../lib/utils/reify-finish.js', { - fs: { ...fs, promises: null }, diff --git a/debian/patches/series b/debian/patches/series deleted file mode 100644 index f717fa1..0000000 --- a/debian/patches/series +++ /dev/null @@ -1,6 +0,0 @@ -2004_remove_shebang.patch -2011_node-gyp-path.patch -2012_dont_install_man_deps.patch -2020_reproducible_documentation_build.patch -dont-check-for-last-version.patch -#fix-test.patch diff --git a/debian/rules b/debian/rules deleted file mode 100755 index fce9e7b..0000000 --- a/debian/rules +++ /dev/null @@ -1,57 +0,0 @@ -#!/usr/bin/make -f -# -*- makefile -*- - -# Uncomment this to turn on verbose mode. -# export DH_VERBOSE=1 - -export HOME=/tmp -ARBORIST_VERSION=$(shell pkgjs-pjson node_modules/@npmcli/arborist version) -NPM_PACKLIST_VERSION=$(shell pkgjs-pjson node_modules/npm-packlist version) -PACOTE_VERSION=$(shell pkgjs-pjson node_modules/pacote version) -QRT_VERSION=$(shell pkgjs-pjson node_modules/qrcode-terminal version) - -%: - dh $@ --with bash-completion - -override_dh_auto_build: -ifeq (,$(filter nodoc,$(DEB_BUILD_PROFILES))) - prefix=/usr make mandocs - help2man --no-discard-stderr -n "the npm tree doctor" -N \ - --version-string $(ARBORIST_VERSION) \ - node_modules/@npmcli/arborist/bin/index.js \ - >man/man1/npm-arborist.1 - node_modules/qrcode-terminal/bin/qrcode-terminal.js --help - help2man -N -n 'The JavaScript Package Handler' --version-string $(PACOTE_VERSION) \ - node_modules/pacote/lib/bin.js >man/man1/pacote.1 - help2man -N -n 'List files to embed in npm package' --version-string $(NPM_PACKLIST_VERSION) \ - node_modules/npm-packlist/bin/index.js >man/man1/npm-packlist.1 -endif - -override_dh_fixperms: - dh_fixperms - chmod a-x debian/npm/usr/share/nodejs/npm/lib/utils/completion.sh - chmod a+x debian/npm/usr/share/nodejs/npm/bin/npm-cli.js - chmod a+x debian/npm/usr/share/nodejs/npm/bin/npx-cli.js - chmod a+x debian/npm/usr/share/nodejs/@npmcli/arborist/bin/index.js - chmod a+x debian/npm/usr/share/nodejs/npm-packlist/bin/index.js - chmod a+x debian/npm/usr/share/nodejs/pacote/lib/bin.js - chmod a+x debian/npm/usr/share/nodejs/qrcode-terminal/bin/qrcode-terminal.js - -override_dh_auto_test: - # Test are lauched only during autopkgtest - -override_dh_auto_install: - dh_auto_install --buildsystem=nodejs - rm -vf debian/npm/usr/share/nodejs/npm/bin/node-gyp-bin/node-gyp.cmd \ - debian/npm/usr/share/nodejs/npm/bin/*.cmd \ - debian/npm/usr/share/nodejs/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin/node-gyp.cmd - -override_dh_link: - rm -rf debian/npm/usr/share/nodejs/npm/man - dh_link - -override_dh_gencontrol: - dh_gencontrol -- -Vpacote:Version="$(PACOTE_VERSION)" \ - -Vqrt:Version="$(QRT_VERSION)" \ - -Vnpmpl:Version="$(NPM_PACKLIST_VERSION)" \ - -Varborist:Version="$(ARBORIST_VERSION)" diff --git a/debian/source/format b/debian/source/format deleted file mode 100644 index 89ae9db..0000000 --- a/debian/source/format +++ /dev/null @@ -1 +0,0 @@ -3.0 (native) diff --git a/debian/source/lintian-overrides b/debian/source/lintian-overrides deleted file mode 100644 index a0a10dd..0000000 --- a/debian/source/lintian-overrides +++ /dev/null @@ -1,30 +0,0 @@ -# False positives -source-is-missing node_modules/emoji-regex/index.js -source-is-missing node_modules/emoji-regex/text.js -source-is-missing workspaces/*/test/fixtures/* -source-contains-prebuilt-javascript-object node_modules/emoji-regex/es2015/index.js -source-contains-prebuilt-javascript-object node_modules/emoji-regex/es2015/text.js -source-contains-prebuilt-javascript-object node_modules/emoji-regex/index.js -source-contains-prebuilt-javascript-object node_modules/emoji-regex/text.js -source-contains-prebuilt-javascript-object workspaces/*/test/fixtures/* -very-long-line-length-in-source-file *.md line * -very-long-line-length-in-source-file *.json line * -very-long-line-length-in-source-file changelogs/CHANGELOG-* line * -very-long-line-length-in-source-file node_modules/emoji-regex/es2015/index.js line 5 is 11033 characters long (>512) -very-long-line-length-in-source-file node_modules/emoji-regex/es2015/text.js line 5 is 11034 characters long (>512) -very-long-line-length-in-source-file node_modules/emoji-regex/index.js line 5 is 10209 characters long (>512) -very-long-line-length-in-source-file node_modules/emoji-regex/text.js line 5 is 10210 characters long (>512) -very-long-line-length-in-source-file node_modules/smart-buffer/build/smartbuffer.js.map line 1 is 20978 characters long (>512) -very-long-line-length-in-source-file node_modules/smart-buffer/build/utils.js.map line 1 is 2024 characters long (>512) -very-long-line-length-in-source-file node_modules/socks-proxy-agent/dist/agent.js.map line 1 is 4149 characters long (>512) -very-long-line-length-in-source-file node_modules/socks/build/client/socksclient.js.map line 1 is 22601 characters long (>512) -very-long-line-length-in-source-file node_modules/socks/build/common/constants.js.map line 1 is 2402 characters long (>512) -very-long-line-length-in-source-file node_modules/socks/build/common/helpers.js.map line 1 is 3584 characters long (>512) -very-long-line-length-in-source-file node_modules/socks/build/common/receivebuffer.js.map line 1 is 1605 characters long (>512) -very-long-line-length-in-source-file node_modules/socks/build/common/util.js.map line 1 is 662 characters long (>512) -very-long-line-length-in-source-file smoke-tests/content/abbrev.json line 442 is 547 characters long (>512) -very-long-line-length-in-source-file smoke-tests/content/promise-all-reject-late.json line * -very-long-line-length-in-source-file smoke-tests/content/promise-all-reject-late.min.json line * -very-long-line-length-in-source-file tap-snapshots/test/lib/commands/search.js.test.cjs line 19 is 1110 characters long (>512) -very-long-line-length-in-source-file workspaces/*/test/fixtures/* line * -very-long-line-length-in-source-file workspaces/arborist/docs/*.svg line * diff --git a/debian/tests/control b/debian/tests/control deleted file mode 100644 index 408c50b..0000000 --- a/debian/tests/control +++ /dev/null @@ -1,8 +0,0 @@ -Tests: install-test, no-duplication -Depends: @ -Restrictions: allow-stderr, needs-internet, skippable - -Test-Command: npm --version -Depends: @ -Restrictions: superficial -Features: test-name=npm-version diff --git a/debian/tests/install-test b/debian/tests/install-test deleted file mode 100755 index 1d9572f..0000000 --- a/debian/tests/install-test +++ /dev/null @@ -1,9 +0,0 @@ -set -ex -export HOME=${AUTOPKGTEST_TMP:-${TMPDIR:-/tmp}} -/usr/bin/npm outdated || true -cd "$AUTOPKGTEST_TMP" -/usr/bin/npm list -/usr/bin/npm init --yes -/usr/bin/npm install --save-prod --production -q pretty-ms -/usr/bin/npm view babel-core -/usr/bin/npm search pretty-ms diff --git a/debian/tests/no-duplication b/debian/tests/no-duplication deleted file mode 100755 index 63722cd..0000000 --- a/debian/tests/no-duplication +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/sh - -RE=`grep node_modules/ debian/nodejs/root_modules | perl -ne 'chomp;m#^node_modules/(.*?)(?:/.*)?$# && push @a,$1;END{print "(",join("|",@a).")"}'` -if pkgjs-ls|grep DUPLICATE|egrep -v "$RE"; then - echo "code duplication found" >&2 - exit 77 -else - echo "no duplication found" - exit 0 -fi diff --git a/debian/tests/pkg-js/SKIP b/debian/tests/pkg-js/SKIP deleted file mode 100644 index 118efc1..0000000 --- a/debian/tests/pkg-js/SKIP +++ /dev/null @@ -1 +0,0 @@ -require \ No newline at end of file diff --git a/debian/tests/test_excluded b/debian/tests/test_excluded deleted file mode 100644 index 80205e3..0000000 --- a/debian/tests/test_excluded +++ /dev/null @@ -1 +0,0 @@ -test/lib/utils/update-notifier.js diff --git a/debian/watch b/debian/watch deleted file mode 100644 index f24c4e5..0000000 --- a/debian/watch +++ /dev/null @@ -1,10 +0,0 @@ -version=4 -opts=\ -repacksuffix=~ds,\ -repack,compression=xz,\ -filenamemangle=s/.*?(\d[\d\.-]*@ARCHIVE_EXT@)/npm-$1/,\ -dversionmangle=auto \ - https://github.com/npm/cli/tags .*/archive/.*/v?([\d\.]+).tar.gz - -# Experimental releases -# https://github.com/npm/cli/tags .*/archive/.*/v?([\d\.]+(?:\-[\w\.]+)?).tar.gz diff --git a/docs/.eslintrc.js b/docs/.eslintrc.js new file mode 100644 index 0000000..5db9f81 --- /dev/null +++ b/docs/.eslintrc.js @@ -0,0 +1,17 @@ +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' + +const { readdirSync: readdir } = require('fs') + +const localConfigs = readdir(__dirname) + .filter((file) => file.startsWith('.eslintrc.local.')) + .map((file) => `./${file}`) + +module.exports = { + root: true, + extends: [ + '@npmcli', + ...localConfigs, + ], +} diff --git a/docs/.gitignore b/docs/.gitignore new file mode 100644 index 0000000..79af2bf --- /dev/null +++ b/docs/.gitignore @@ -0,0 +1,21 @@ +# This file is automatically added by @npmcli/template-oss. Do not edit. + +# ignore everything in the root +/* + +# keep these +!**/.gitignore +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ +!/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/docs/README.md b/docs/README.md new file mode 100644 index 0000000..5fc7ccf --- /dev/null +++ b/docs/README.md @@ -0,0 +1,5 @@ +# docs + +[![CI - docs](https://github.com/npm/cli/actions/workflows/ci-docs.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-docs.yml) + +Scripts to build the npm docs. diff --git a/docs/bin/build.js b/docs/bin/build.js new file mode 100644 index 0000000..6832274 --- /dev/null +++ b/docs/bin/build.js @@ -0,0 +1,9 @@ +const run = require('../lib/build.js') +const { paths } = require('../lib/index') + +run(paths) + .then((res) => console.log(`Wrote ${res.length} files`)) + .catch((err) => { + process.exitCode = 1 + console.error(err) + }) diff --git a/docs/config.json b/docs/config.json deleted file mode 100644 index 08df95a..0000000 --- a/docs/config.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "github_repo": "npm/cli", - "github_branch": "latest", - "github_path": "docs/content" -} diff --git a/docs/content/commands/npm-adduser.md b/docs/content/commands/npm-adduser.md deleted file mode 100644 index 21a31ca..0000000 --- a/docs/content/commands/npm-adduser.md +++ /dev/null @@ -1,94 +0,0 @@ ---- -title: npm-adduser -section: 1 -description: Add a registry user account ---- - -### Synopsis - -```bash -npm adduser [--registry=url] [--scope=@orgname] [--auth-type=legacy] - -aliases: login, add-user -``` - -Note: This command is unaware of workspaces. - -### Description - -Create or verify a user named `<username>` 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)). - -The username, password, and email are read in from prompts. - -To reset your password, go to <https://www.npmjs.com/forgot> - -To change your email address, go to <https://www.npmjs.com/email-edit> - -You may use this command multiple times with the same user account to -authorize on a new machine. When authenticating on a new machine, -the username, password and email address must all match with -your existing record. - -`npm login` is an alias to `adduser` and behaves exactly the same way. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `scope` - -* Default: the scope of the current project, if any, or "" -* Type: String - -Associate an operation with a scope for a scoped registry. - -Useful when logging in to or out of a private registry: - -``` -# log in, linking the scope to the custom registry -npm login --scope=@mycorp --registry=https://registry.mycorp.com - -# log out, removing the link and the auth token -npm logout --scope=@mycorp -``` - -This will cause `@mycorp` to be mapped to the registry for future -installation of packages specified according to the pattern -`@mycorp/package`. - -This will also cause `npm init` to create a scoped package. - -``` -# accept all defaults, and create a package named "@foo/whatever", -# instead of just named "whatever" -npm init --scope=@foo --yes -``` - - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm registry](/using-npm/registry) -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) -* [npm owner](/commands/npm-owner) -* [npm whoami](/commands/npm-whoami) -* [npm token](/commands/npm-token) -* [npm profile](/commands/npm-profile) diff --git a/docs/content/commands/npm-bin.md b/docs/content/commands/npm-bin.md deleted file mode 100644 index 2d7c1d5..0000000 --- a/docs/content/commands/npm-bin.md +++ /dev/null @@ -1,49 +0,0 @@ ---- -title: npm-bin -section: 1 -description: Display npm bin folder ---- - -### Synopsis - -```bash -npm bin [-g|--global] -``` - -Note: This command is unaware of workspaces. - -### Description - -Print the folder where npm will install executables. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm prefix](/commands/npm-prefix) -* [npm root](/commands/npm-root) -* [npm folders](/configuring-npm/folders) -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) diff --git a/docs/content/commands/npm-bugs.md b/docs/content/commands/npm-bugs.md deleted file mode 100644 index f92241a..0000000 --- a/docs/content/commands/npm-bugs.md +++ /dev/null @@ -1,62 +0,0 @@ ---- -title: npm-bugs -section: 1 -description: Report bugs for a package in a web browser ---- - -### Synopsis - -```bash -npm bugs [<pkgname> [<pkgname> ...]] - -aliases: issues -``` - -### Description - -This command tries to guess at the likely location of a package's bug -tracker URL or the `mailto` URL of the support email, and then tries to -open it using the `--browser` config param. If no package name is provided, it -will search for a `package.json` in the current folder and use the `name` property. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `browser` - -* Default: OS X: `"open"`, Windows: `"start"`, Others: `"xdg-open"` -* Type: null, Boolean, or String - -The browser that is called by npm commands to open websites. - -Set to `false` to suppress browser behavior and instead print urls to -terminal. - -Set to `true` to use default system URL opener. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm docs](/commands/npm-docs) -* [npm view](/commands/npm-view) -* [npm publish](/commands/npm-publish) -* [npm registry](/using-npm/registry) -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) -* [package.json](/configuring-npm/package-json) diff --git a/docs/content/commands/npm-ci.md b/docs/content/commands/npm-ci.md deleted file mode 100644 index 1ce50c6..0000000 --- a/docs/content/commands/npm-ci.md +++ /dev/null @@ -1,117 +0,0 @@ ---- -title: npm-ci -section: 1 -description: Install a project with a clean slate ---- - -### Synopsis - -```bash -npm ci -``` - -### Description - -This command is similar to [`npm install`](/commands/npm-install), except -it's meant to be used in automated environments such as test platforms, -continuous integration, and deployment -- or any situation where you want -to make sure you're doing a clean install of your dependencies. - -`npm ci` will be significantly faster when: - -- There is a `package-lock.json` or `npm-shrinkwrap.json` file. -- The `node_modules` folder is missing or empty. - -In short, the main differences between using `npm install` and `npm ci` are: - -* The project **must** have an existing `package-lock.json` or - `npm-shrinkwrap.json`. -* If dependencies in the package lock do not match those in `package.json`, - `npm ci` will exit with an error, instead of updating the package lock. -* `npm ci` can only install entire projects at a time: individual - dependencies cannot be added with this command. -* If a `node_modules` is already present, it will be automatically removed - before `npm ci` begins its install. -* It will never write to `package.json` or any of the package-locks: - installs are essentially frozen. - -### Example - -Make sure you have a package-lock and an up-to-date install: - -```bash -$ cd ./my/npm/project -$ npm install -added 154 packages in 10s -$ ls | grep package-lock -``` - -Run `npm ci` in that project - -```bash -$ npm ci -added 154 packages in 5s -``` - -Configure Travis to build using `npm ci` instead of `npm install`: - -```bash -# .travis.yml -install: -- npm ci -# keep the npm cache around to speed up installs -cache: - directories: - - "$HOME/.npm" -``` - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `audit` - -* Default: true -* Type: Boolean - -When "true" submit audit reports alongside the current npm command to the -default registry and all registries configured for scopes. See the -documentation for [`npm audit`](/commands/npm-audit) for details on what is -submitted. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `script-shell` - -* Default: '/bin/sh' on POSIX systems, 'cmd.exe' on Windows -* Type: null or String - -The shell to use for scripts run with the `npm exec`, `npm run` and `npm -init <pkg>` commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm install](/commands/npm-install) -* [package-lock.json](/configuring-npm/package-lock-json) diff --git a/docs/content/commands/npm-config.md b/docs/content/commands/npm-config.md deleted file mode 100644 index 2d77f04..0000000 --- a/docs/content/commands/npm-config.md +++ /dev/null @@ -1,173 +0,0 @@ ---- -title: npm-config -section: 1 -description: Manage the npm configuration files ---- - -### Synopsis - -```bash -npm config set <key>=<value> [<key>=<value> ...] -npm config get [<key> [<key> ...]] -npm config delete <key> [<key> ...] -npm config list [--json] -npm config edit -npm set <key>=<value> [<key>=<value> ...] -npm get [<key> [<key> ...]] - -alias: c -``` - -Note: This command is unaware of workspaces. - -### Description - -npm gets its config settings from the command line, environment -variables, `npmrc` files, and in some cases, the `package.json` file. - -See [npmrc](/configuring-npm/npmrc) for more information about the npmrc -files. - -See [config(7)](/using-npm/config) for a more thorough explanation of the -mechanisms involved, and a full list of config options available. - -The `npm config` command can be used to update and edit the contents -of the user and global npmrc files. - -### Sub-commands - -Config supports the following sub-commands: - -#### set - -```bash -npm config set key=value [key=value...] -npm set key=value [key=value...] -``` - -Sets each of the config keys to the value provided. - -If value is omitted, then it sets it to an empty string. - -Note: for backwards compatibility, `npm config set key value` is supported -as an alias for `npm config set key=value`. - -#### get - -```bash -npm config get [key ...] -npm get [key ...] -``` - -Echo the config value(s) to stdout. - -If multiple keys are provided, then the values will be prefixed with the -key names. - -If no keys are provided, then this command behaves the same as `npm config -list`. - -#### list - -```bash -npm config list -``` - -Show all the config settings. Use `-l` to also show defaults. Use `--json` -to show the settings in json format. - -#### delete - -```bash -npm config delete key [key ...] -``` - -Deletes the specified keys from all configuration files. - -#### edit - -```bash -npm config edit -``` - -Opens the config file in an editor. Use the `--global` flag to edit the -global config. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `editor` - -* Default: The EDITOR or VISUAL environment variables, or 'notepad.exe' on - Windows, or 'vim' on Unix systems -* Type: String - -The command to run for `npm edit` and `npm config edit`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `location` - -* Default: "user" unless `--global` is passed, which will also set this value - to "global" -* Type: "global", "user", or "project" - -When passed to `npm config` this refers to which config file to use. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `long` - -* Default: false -* Type: Boolean - -Show extended information in `ls`, `search`, and `help-search`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm folders](/configuring-npm/folders) -* [npm config](/commands/npm-config) -* [package.json](/configuring-npm/package-json) -* [npmrc](/configuring-npm/npmrc) -* [npm](/commands/npm) diff --git a/docs/content/commands/npm-dedupe.md b/docs/content/commands/npm-dedupe.md deleted file mode 100644 index 53d2e64..0000000 --- a/docs/content/commands/npm-dedupe.md +++ /dev/null @@ -1,310 +0,0 @@ ---- -title: npm-dedupe -section: 1 -description: Reduce duplication in the package tree ---- - -### Synopsis - -```bash -npm dedupe -npm ddp - -aliases: ddp -``` - -### Description - -Searches the local package tree and attempts to simplify the overall -structure by moving dependencies further up the tree, where they can -be more effectively shared by multiple dependent packages. - -For example, consider this dependency graph: - -``` -a -+-- b <-- depends on c@1.0.x -| `-- c@1.0.3 -`-- d <-- depends on c@~1.0.9 - `-- c@1.0.10 -``` - -In this case, `npm dedupe` will transform the tree to: - -```bash -a -+-- b -+-- d -`-- c@1.0.10 -``` - -Because of the hierarchical nature of node's module lookup, b and d -will both get their dependency met by the single c package at the root -level of the tree. - -In some cases, you may have a dependency graph like this: - -``` -a -+-- b <-- depends on c@1.0.x -+-- c@1.0.3 -`-- d <-- depends on c@1.x - `-- c@1.9.9 -``` - -During the installation process, the `c@1.0.3` dependency for `b` was -placed in the root of the tree. Though `d`'s dependency on `c@1.x` could -have been satisfied by `c@1.0.3`, the newer `c@1.9.0` dependency was used, -because npm favors updates by default, even when doing so causes -duplication. - -Running `npm dedupe` will cause npm to note the duplication and -re-evaluate, deleting the nested `c` module, because the one in the root is -sufficient. - -To prefer deduplication over novelty during the installation process, run -`npm install --prefer-dedupe` or `npm config set prefer-dedupe true`. - -Arguments are ignored. Dedupe always acts on the entire tree. - -Note that this operation transforms the dependency tree, but will never -result in new modules being installed. - -Using `npm find-dupes` will run the command in `--dry-run` mode. - -Note that by default `npm dedupe` will not update the semver values of direct -dependencies in your project `package.json`, if you want to also update -values in `package.json` you can run: `npm dedupe --save` (or add the -`save=true` option to a [configuration file](/configuring-npm/npmrc) -to make that the default behavior). - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `global-style` - -* Default: false -* Type: Boolean - -Causes npm to install the package into your local `node_modules` folder with -the same layout it uses with the global `node_modules` folder. Only your -direct dependencies will show in `node_modules` and everything they depend -on will be flattened in their `node_modules` folders. This obviously will -eliminate some deduping. If used with `legacy-bundling`, `legacy-bundling` -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `legacy-bundling` - -* Default: false -* Type: Boolean - -Causes npm to install the package such that versions of npm prior to 1.4, -such as the one included with node 0.8, can install the package. This -eliminates all automatic deduping. If used with `global-style` this option -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `strict-peer-deps` - -* Default: false -* Type: Boolean - -If set to `true`, and `--legacy-peer-deps` is not set, then _any_ -conflicting `peerDependencies` will be treated as an install failure, even -if npm could reasonably guess the appropriate resolution based on non-peer -dependency relationships. - -By default, conflicting `peerDependencies` deep in the dependency graph will -be resolved using the nearest non-peer dependency specification, even if -doing so will result in some packages receiving a peer dependency outside -the range set in their package's `peerDependencies` object. - -When such and override is performed, a warning is printed, explaining the -conflict and the packages involved. If `--strict-peer-deps` is set, then -this warning is treated as a failure. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `package-lock` - -* Default: true -* Type: Boolean - -If set to false, then ignore `package-lock.json` files when installing. This -will also prevent _writing_ `package-lock.json` if `save` is true. - -When package package-locks are disabled, automatic pruning of extraneous -modules will also be disabled. To remove extraneous modules with -package-locks disabled use `npm prune`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `omit` - -* Default: 'dev' if the `NODE_ENV` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -`package-lock.json` or `npm-shrinkwrap.json` file. They are just not -physically installed on disk. - -If a package type appears in both the `--include` and `--omit` lists, then -it will be included. - -If the resulting omit list includes `'dev'`, then the `NODE_ENV` environment -variable will be set to `'production'` for all lifecycle scripts. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `audit` - -* Default: true -* Type: Boolean - -When "true" submit audit reports alongside the current npm command to the -default registry and all registries configured for scopes. See the -documentation for [`npm audit`](/commands/npm-audit) for details on what is -submitted. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `bin-links` - -* Default: true -* Type: Boolean - -Tells npm to create symlinks (or `.cmd` shims on Windows) for package -executables. - -Set to false to have it not do this. This can be used to work around the -fact that some file systems don't support symlinks, even on ostensibly Unix -systems. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fund` - -* Default: true -* Type: Boolean - -When "true" displays the message at the end of each `npm install` -acknowledging the number of dependencies looking for funding. See [`npm -fund`](/commands/npm-fund) for details. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `dry-run` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, `install`, `update`, -`dedupe`, `uninstall`, as well as `pack` and `publish`. - -Note: This is NOT honored by other network related commands, eg `dist-tags`, -`owner`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm find-dupes](/commands/npm-find-dupes) -* [npm ls](/commands/npm-ls) -* [npm update](/commands/npm-update) -* [npm install](/commands/npm-install) diff --git a/docs/content/commands/npm-docs.md b/docs/content/commands/npm-docs.md deleted file mode 100644 index 970d17a..0000000 --- a/docs/content/commands/npm-docs.md +++ /dev/null @@ -1,122 +0,0 @@ ---- -title: npm-docs -section: 1 -description: Open documentation for a package in a web browser ---- - -### Synopsis - -```bash -npm docs [<pkgname> [<pkgname> ...]] - -aliases: home -``` - -### Description - -This command tries to guess at the likely location of a package's -documentation URL, and then tries to open it using the `--browser` config -param. You can pass multiple package names at once. If no package name is -provided, it will search for a `package.json` in the current folder and use -the `name` property. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `browser` - -* Default: OS X: `"open"`, Windows: `"start"`, Others: `"xdg-open"` -* Type: null, Boolean, or String - -The browser that is called by npm commands to open websites. - -Set to `false` to suppress browser behavior and instead print urls to -terminal. - -Set to `true` to use default system URL opener. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm view](/commands/npm-view) -* [npm publish](/commands/npm-publish) -* [npm registry](/using-npm/registry) -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) -* [package.json](/configuring-npm/package-json) diff --git a/docs/content/commands/npm-explain.md b/docs/content/commands/npm-explain.md deleted file mode 100644 index 5f05cac..0000000 --- a/docs/content/commands/npm-explain.md +++ /dev/null @@ -1,112 +0,0 @@ ---- -title: npm-explain -section: 1 -description: Explain installed packages ---- - -### Synopsis - -```bash -npm explain <folder | specifier> - -alias: why -``` - -### Description - -This command will print the chain of dependencies causing a given package -to be installed in the current project. - -Positional arguments can be either folders within `node_modules`, or -`name@version-range` specifiers, which will select the dependency -relationships to explain. - -For example, running `npm explain glob` within npm's source tree will show: - -```bash -glob@7.1.6 -node_modules/glob - glob@"^7.1.4" from the root project - -glob@7.1.1 dev -node_modules/tacks/node_modules/glob - glob@"^7.0.5" from rimraf@2.6.2 - node_modules/tacks/node_modules/rimraf - rimraf@"^2.6.2" from tacks@1.3.0 - node_modules/tacks - dev tacks@"^1.3.0" from the root project -``` - -To explain just the package residing at a specific folder, pass that as the -argument to the command. This can be useful when trying to figure out -exactly why a given dependency is being duplicated to satisfy conflicting -version requirements within the project. - -```bash -$ npm explain node_modules/nyc/node_modules/find-up -find-up@3.0.0 dev -node_modules/nyc/node_modules/find-up - find-up@"^3.0.0" from nyc@14.1.1 - node_modules/nyc - nyc@"^14.1.1" from tap@14.10.8 - node_modules/tap - dev tap@"^14.10.8" from the root project -``` - -### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) -* [npm folders](/configuring-npm/folders) -* [npm ls](/commands/npm-ls) -* [npm install](/commands/npm-install) -* [npm link](/commands/npm-link) -* [npm prune](/commands/npm-prune) -* [npm outdated](/commands/npm-outdated) -* [npm update](/commands/npm-update) diff --git a/docs/content/commands/npm-find-dupes.md b/docs/content/commands/npm-find-dupes.md deleted file mode 100644 index f7dc84f..0000000 --- a/docs/content/commands/npm-find-dupes.md +++ /dev/null @@ -1,232 +0,0 @@ ---- -title: npm-find-dupes -section: 1 -description: Find duplication in the package tree ---- - -### Synopsis - -```bash -npm find-dupes -``` - -### Description - -Runs `npm dedupe` in `--dry-run` mode, making npm only output the -duplications, without actually changing the package tree. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `global-style` - -* Default: false -* Type: Boolean - -Causes npm to install the package into your local `node_modules` folder with -the same layout it uses with the global `node_modules` folder. Only your -direct dependencies will show in `node_modules` and everything they depend -on will be flattened in their `node_modules` folders. This obviously will -eliminate some deduping. If used with `legacy-bundling`, `legacy-bundling` -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `legacy-bundling` - -* Default: false -* Type: Boolean - -Causes npm to install the package such that versions of npm prior to 1.4, -such as the one included with node 0.8, can install the package. This -eliminates all automatic deduping. If used with `global-style` this option -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `strict-peer-deps` - -* Default: false -* Type: Boolean - -If set to `true`, and `--legacy-peer-deps` is not set, then _any_ -conflicting `peerDependencies` will be treated as an install failure, even -if npm could reasonably guess the appropriate resolution based on non-peer -dependency relationships. - -By default, conflicting `peerDependencies` deep in the dependency graph will -be resolved using the nearest non-peer dependency specification, even if -doing so will result in some packages receiving a peer dependency outside -the range set in their package's `peerDependencies` object. - -When such and override is performed, a warning is printed, explaining the -conflict and the packages involved. If `--strict-peer-deps` is set, then -this warning is treated as a failure. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `package-lock` - -* Default: true -* Type: Boolean - -If set to false, then ignore `package-lock.json` files when installing. This -will also prevent _writing_ `package-lock.json` if `save` is true. - -When package package-locks are disabled, automatic pruning of extraneous -modules will also be disabled. To remove extraneous modules with -package-locks disabled use `npm prune`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `omit` - -* Default: 'dev' if the `NODE_ENV` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -`package-lock.json` or `npm-shrinkwrap.json` file. They are just not -physically installed on disk. - -If a package type appears in both the `--include` and `--omit` lists, then -it will be included. - -If the resulting omit list includes `'dev'`, then the `NODE_ENV` environment -variable will be set to `'production'` for all lifecycle scripts. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `audit` - -* Default: true -* Type: Boolean - -When "true" submit audit reports alongside the current npm command to the -default registry and all registries configured for scopes. See the -documentation for [`npm audit`](/commands/npm-audit) for details on what is -submitted. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `bin-links` - -* Default: true -* Type: Boolean - -Tells npm to create symlinks (or `.cmd` shims on Windows) for package -executables. - -Set to false to have it not do this. This can be used to work around the -fact that some file systems don't support symlinks, even on ostensibly Unix -systems. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fund` - -* Default: true -* Type: Boolean - -When "true" displays the message at the end of each `npm install` -acknowledging the number of dependencies looking for funding. See [`npm -fund`](/commands/npm-fund) for details. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm dedupe](/commands/npm-dedupe) -* [npm ls](/commands/npm-ls) -* [npm update](/commands/npm-update) -* [npm install](/commands/npm-install) - diff --git a/docs/content/commands/npm-fund.md b/docs/content/commands/npm-fund.md deleted file mode 100644 index 606b0a1..0000000 --- a/docs/content/commands/npm-fund.md +++ /dev/null @@ -1,155 +0,0 @@ ---- -title: npm-fund -section: 1 -description: Retrieve funding information ---- - -### Synopsis - -```bash -npm fund [<pkg>] -npm fund [-w <workspace-name>] -``` - -### Description - -This command retrieves information on how to fund the dependencies of a -given project. If no package name is provided, it will list all -dependencies that are looking for funding in a tree structure, listing the -type of funding and the url to visit. If a package name is provided then it -tries to open its funding url using the `--browser` config param; if there -are multiple funding sources for the package, the user will be instructed -to pass the `--which` option to disambiguate. - -The list will avoid duplicated entries and will stack all packages that -share the same url as a single entry. Thus, the list does not have the same -shape of the output from `npm ls`. - -#### Example - -### Workspaces support - -It's possible to filter the results to only include a single workspace and its -dependencies using the `workspace` config option. - -#### Example: - -Here's an example running `npm fund` in a project with a configured -workspace `a`: - -```bash -$ npm fund -test-workspaces-fund@1.0.0 -+-- https://example.com/a -| | `-- a@1.0.0 -| `-- https://example.com/maintainer -| `-- foo@1.0.0 -+-- https://example.com/npmcli-funding -| `-- @npmcli/test-funding -`-- https://example.com/org - `-- bar@2.0.0 -``` - -And here is an example of the expected result when filtering only by -a specific workspace `a` in the same project: - -```bash -$ npm fund -w a -test-workspaces-fund@1.0.0 -`-- https://example.com/a - | `-- a@1.0.0 - `-- https://example.com/maintainer - `-- foo@2.0.0 -``` - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `browser` - -* Default: OS X: `"open"`, Windows: `"start"`, Others: `"xdg-open"` -* Type: null, Boolean, or String - -The browser that is called by npm commands to open websites. - -Set to `false` to suppress browser behavior and instead print urls to -terminal. - -Set to `true` to use default system URL opener. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `unicode` - -* Default: false on windows, true on mac/unix systems with a unicode locale, - as defined by the `LC_ALL`, `LC_CTYPE`, or `LANG` environment variables. -* Type: Boolean - -When set to true, npm uses unicode characters in the tree output. When -false, it uses ascii characters instead of unicode glyphs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `which` - -* Default: null -* Type: null or Number - -If there are multiple funding sources, which 1-indexed source URL to open. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -## See Also - -* [npm install](/commands/npm-install) -* [npm docs](/commands/npm-docs) -* [npm ls](/commands/npm-ls) -* [npm config](/commands/npm-config) -* [npm workspaces](/using-npm/workspaces) diff --git a/docs/content/commands/npm-install-ci-test.md b/docs/content/commands/npm-install-ci-test.md deleted file mode 100644 index 5c37ed8..0000000 --- a/docs/content/commands/npm-install-ci-test.md +++ /dev/null @@ -1,69 +0,0 @@ ---- -title: npm-install-ci-test -section: 1 -description: Install a project with a clean slate and run tests ---- - -### Synopsis - -```bash -npm install-ci-test - -alias: npm cit -``` - -### Description - -This command runs `npm ci` followed immediately by `npm test`. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `audit` - -* Default: true -* Type: Boolean - -When "true" submit audit reports alongside the current npm command to the -default registry and all registries configured for scopes. See the -documentation for [`npm audit`](/commands/npm-audit) for details on what is -submitted. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `script-shell` - -* Default: '/bin/sh' on POSIX systems, 'cmd.exe' on Windows -* Type: null or String - -The shell to use for scripts run with the `npm exec`, `npm run` and `npm -init <pkg>` commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm install-test](/commands/npm-install-test) -* [npm ci](/commands/npm-ci) -* [npm test](/commands/npm-test) diff --git a/docs/content/commands/npm-install-test.md b/docs/content/commands/npm-install-test.md deleted file mode 100644 index c464e5b..0000000 --- a/docs/content/commands/npm-install-test.md +++ /dev/null @@ -1,297 +0,0 @@ ---- -title: npm-install-test -section: 1 -description: Install package(s) and run tests ---- - -### Synopsis - -```bash -npm install-test (with no args, in package dir) -npm install-test [<@scope>/]<name> -npm install-test [<@scope>/]<name>@<tag> -npm install-test [<@scope>/]<name>@<version> -npm install-test [<@scope>/]<name>@<version range> -npm install-test <tarball file> -npm install-test <tarball url> -npm install-test <folder> - -alias: npm it -common options: [--save|--save-dev|--save-optional] [--save-exact] [--dry-run] -``` - -### Description - -This command runs an `npm install` followed immediately by an `npm test`. It -takes exactly the same arguments as `npm install`. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `save` - -* Default: true -* Type: Boolean - -Save installed packages to a package.json file as dependencies. - -When used with the `npm rm` command, removes the dependency from -package.json. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `save-exact` - -* Default: false -* Type: Boolean - -Dependencies saved to package.json will be configured with an exact version -rather than using npm's default semver range operator. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global-style` - -* Default: false -* Type: Boolean - -Causes npm to install the package into your local `node_modules` folder with -the same layout it uses with the global `node_modules` folder. Only your -direct dependencies will show in `node_modules` and everything they depend -on will be flattened in their `node_modules` folders. This obviously will -eliminate some deduping. If used with `legacy-bundling`, `legacy-bundling` -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `legacy-bundling` - -* Default: false -* Type: Boolean - -Causes npm to install the package such that versions of npm prior to 1.4, -such as the one included with node 0.8, can install the package. This -eliminates all automatic deduping. If used with `global-style` this option -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `strict-peer-deps` - -* Default: false -* Type: Boolean - -If set to `true`, and `--legacy-peer-deps` is not set, then _any_ -conflicting `peerDependencies` will be treated as an install failure, even -if npm could reasonably guess the appropriate resolution based on non-peer -dependency relationships. - -By default, conflicting `peerDependencies` deep in the dependency graph will -be resolved using the nearest non-peer dependency specification, even if -doing so will result in some packages receiving a peer dependency outside -the range set in their package's `peerDependencies` object. - -When such and override is performed, a warning is printed, explaining the -conflict and the packages involved. If `--strict-peer-deps` is set, then -this warning is treated as a failure. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `package-lock` - -* Default: true -* Type: Boolean - -If set to false, then ignore `package-lock.json` files when installing. This -will also prevent _writing_ `package-lock.json` if `save` is true. - -When package package-locks are disabled, automatic pruning of extraneous -modules will also be disabled. To remove extraneous modules with -package-locks disabled use `npm prune`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `omit` - -* Default: 'dev' if the `NODE_ENV` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -`package-lock.json` or `npm-shrinkwrap.json` file. They are just not -physically installed on disk. - -If a package type appears in both the `--include` and `--omit` lists, then -it will be included. - -If the resulting omit list includes `'dev'`, then the `NODE_ENV` environment -variable will be set to `'production'` for all lifecycle scripts. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `audit` - -* Default: true -* Type: Boolean - -When "true" submit audit reports alongside the current npm command to the -default registry and all registries configured for scopes. See the -documentation for [`npm audit`](/commands/npm-audit) for details on what is -submitted. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `bin-links` - -* Default: true -* Type: Boolean - -Tells npm to create symlinks (or `.cmd` shims on Windows) for package -executables. - -Set to false to have it not do this. This can be used to work around the -fact that some file systems don't support symlinks, even on ostensibly Unix -systems. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fund` - -* Default: true -* Type: Boolean - -When "true" displays the message at the end of each `npm install` -acknowledging the number of dependencies looking for funding. See [`npm -fund`](/commands/npm-fund) for details. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `dry-run` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, `install`, `update`, -`dedupe`, `uninstall`, as well as `pack` and `publish`. - -Note: This is NOT honored by other network related commands, eg `dist-tags`, -`owner`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm install](/commands/npm-install) -* [npm install-ci-test](/commands/npm-install-ci-test) -* [npm test](/commands/npm-test) diff --git a/docs/content/commands/npm-link.md b/docs/content/commands/npm-link.md deleted file mode 100644 index d4ef41a..0000000 --- a/docs/content/commands/npm-link.md +++ /dev/null @@ -1,384 +0,0 @@ ---- -title: npm-link -section: 1 -description: Symlink a package folder ---- - -### Synopsis - -```bash -npm link (in package dir) -npm link [<@scope>/]<pkg>[@<version>] - -alias: npm ln -``` - -### Description - -This is handy for installing your own stuff, so that you can work on it and -test iteratively without having to continually rebuild. - -Package linking is a two-step process. - -First, `npm link` in a package folder will create a symlink in the global -folder `{prefix}/lib/node_modules/<package>` that links to the package -where the `npm link` command was executed. It will also link any bins in -the package to `{prefix}/bin/{name}`. Note that `npm link` uses the global -prefix (see `npm prefix -g` for its value). - -Next, in some other location, `npm link package-name` will create a -symbolic link from globally-installed `package-name` to `node_modules/` of -the current folder. - -Note that `package-name` is taken from `package.json`, _not_ from the -directory name. - -The package name can be optionally prefixed with a scope. See -[`scope`](/using-npm/scope). The scope must be preceded by an @-symbol and -followed by a slash. - -When creating tarballs for `npm publish`, the linked packages are -"snapshotted" to their current state by resolving the symbolic links, if -they are included in `bundleDependencies`. - -For example: - -```bash -cd ~/projects/node-redis # go into the package directory -npm link # creates global link -cd ~/projects/node-bloggy # go into some other package directory. -npm link redis # link-install the package -``` - -Now, any changes to `~/projects/node-redis` will be reflected in -`~/projects/node-bloggy/node_modules/node-redis/`. Note that the link -should be to the package name, not the directory name for that package. - -You may also shortcut the two steps in one. For example, to do the -above use-case in a shorter way: - -```bash -cd ~/projects/node-bloggy # go into the dir of your main project -npm link ../node-redis # link the dir of your dependency -``` - -The second line is the equivalent of doing: - -```bash -(cd ../node-redis; npm link) -npm link redis -``` - -That is, it first creates a global link, and then links the global -installation target into your project's `node_modules` folder. - -Note that in this case, you are referring to the directory name, -`node-redis`, rather than the package name `redis`. - -If your linked package is scoped (see [`scope`](/using-npm/scope)) your -link command must include that scope, e.g. - -```bash -npm link @myorg/privatepackage -``` - -### Caveat - -Note that package dependencies linked in this way are _not_ saved to -`package.json` by default, on the assumption that the intention is to have -a link stand in for a regular non-link dependency. Otherwise, for example, -if you depend on `redis@^3.0.1`, and ran `npm link redis`, it would replace -the `^3.0.1` dependency with `file:../path/to/node-redis`, which you -probably don't want! Additionally, other users or developers on your -project would run into issues if they do not have their folders set up -exactly the same as yours. - -If you are adding a _new_ dependency as a link, you should add it to the -relevant metadata by running `npm install <dep> --package-lock-only`. - -If you _want_ to save the `file:` reference in your `package.json` and -`package-lock.json` files, you can use `npm link <dep> --save` to do so. - -### Workspace Usage - -`npm link <pkg> --workspace <name>` will link the relevant package as a -dependency of the specified workspace(s). Note that It may actually be -linked into the parent project's `node_modules` folder, if there are no -conflicting dependencies. - -`npm link --workspace <name>` will create a global link to the specified -workspace(s). - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `save` - -* Default: true -* Type: Boolean - -Save installed packages to a package.json file as dependencies. - -When used with the `npm rm` command, removes the dependency from -package.json. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `save-exact` - -* Default: false -* Type: Boolean - -Dependencies saved to package.json will be configured with an exact version -rather than using npm's default semver range operator. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global-style` - -* Default: false -* Type: Boolean - -Causes npm to install the package into your local `node_modules` folder with -the same layout it uses with the global `node_modules` folder. Only your -direct dependencies will show in `node_modules` and everything they depend -on will be flattened in their `node_modules` folders. This obviously will -eliminate some deduping. If used with `legacy-bundling`, `legacy-bundling` -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `legacy-bundling` - -* Default: false -* Type: Boolean - -Causes npm to install the package such that versions of npm prior to 1.4, -such as the one included with node 0.8, can install the package. This -eliminates all automatic deduping. If used with `global-style` this option -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `strict-peer-deps` - -* Default: false -* Type: Boolean - -If set to `true`, and `--legacy-peer-deps` is not set, then _any_ -conflicting `peerDependencies` will be treated as an install failure, even -if npm could reasonably guess the appropriate resolution based on non-peer -dependency relationships. - -By default, conflicting `peerDependencies` deep in the dependency graph will -be resolved using the nearest non-peer dependency specification, even if -doing so will result in some packages receiving a peer dependency outside -the range set in their package's `peerDependencies` object. - -When such and override is performed, a warning is printed, explaining the -conflict and the packages involved. If `--strict-peer-deps` is set, then -this warning is treated as a failure. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `package-lock` - -* Default: true -* Type: Boolean - -If set to false, then ignore `package-lock.json` files when installing. This -will also prevent _writing_ `package-lock.json` if `save` is true. - -When package package-locks are disabled, automatic pruning of extraneous -modules will also be disabled. To remove extraneous modules with -package-locks disabled use `npm prune`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `omit` - -* Default: 'dev' if the `NODE_ENV` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -`package-lock.json` or `npm-shrinkwrap.json` file. They are just not -physically installed on disk. - -If a package type appears in both the `--include` and `--omit` lists, then -it will be included. - -If the resulting omit list includes `'dev'`, then the `NODE_ENV` environment -variable will be set to `'production'` for all lifecycle scripts. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `audit` - -* Default: true -* Type: Boolean - -When "true" submit audit reports alongside the current npm command to the -default registry and all registries configured for scopes. See the -documentation for [`npm audit`](/commands/npm-audit) for details on what is -submitted. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `bin-links` - -* Default: true -* Type: Boolean - -Tells npm to create symlinks (or `.cmd` shims on Windows) for package -executables. - -Set to false to have it not do this. This can be used to work around the -fact that some file systems don't support symlinks, even on ostensibly Unix -systems. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fund` - -* Default: true -* Type: Boolean - -When "true" displays the message at the end of each `npm install` -acknowledging the number of dependencies looking for funding. See [`npm -fund`](/commands/npm-fund) for details. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `dry-run` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, `install`, `update`, -`dedupe`, `uninstall`, as well as `pack` and `publish`. - -Note: This is NOT honored by other network related commands, eg `dist-tags`, -`owner`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm developers](/using-npm/developers) -* [package.json](/configuring-npm/package-json) -* [npm install](/commands/npm-install) -* [npm folders](/configuring-npm/folders) -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) diff --git a/docs/content/commands/npm-logout.md b/docs/content/commands/npm-logout.md deleted file mode 100644 index cb7c849..0000000 --- a/docs/content/commands/npm-logout.md +++ /dev/null @@ -1,83 +0,0 @@ ---- -title: npm-logout -section: 1 -description: Log out of the registry ---- - -### Synopsis - -```bash -npm logout [--registry=<url>] [--scope=<@scope>] -``` - -Note: This command is unaware of workspaces. - -### Description - -When logged into a registry that supports token-based authentication, tell -the server to end this token's session. This will invalidate the token -everywhere you're using it, not just for the current environment. - -When logged into a legacy registry that uses username and password -authentication, this will clear the credentials in your user configuration. -In this case, it will _only_ affect the current environment. - -If `--scope` is provided, this will find the credentials for the registry -connected to that scope, if set. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `scope` - -* Default: the scope of the current project, if any, or "" -* Type: String - -Associate an operation with a scope for a scoped registry. - -Useful when logging in to or out of a private registry: - -``` -# log in, linking the scope to the custom registry -npm login --scope=@mycorp --registry=https://registry.mycorp.com - -# log out, removing the link and the auth token -npm logout --scope=@mycorp -``` - -This will cause `@mycorp` to be mapped to the registry for future -installation of packages specified according to the pattern -`@mycorp/package`. - -This will also cause `npm init` to create a scoped package. - -``` -# accept all defaults, and create a package named "@foo/whatever", -# instead of just named "whatever" -npm init --scope=@foo --yes -``` - - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm adduser](/commands/npm-adduser) -* [npm registry](/using-npm/registry) -* [npm config](/commands/npm-config) -* [npm whoami](/commands/npm-whoami) diff --git a/docs/content/commands/npm-ls.md b/docs/content/commands/npm-ls.md deleted file mode 100644 index 3b33f0a..0000000 --- a/docs/content/commands/npm-ls.md +++ /dev/null @@ -1,290 +0,0 @@ ---- -title: npm-ls -section: 1 -description: List installed packages ---- - -### Synopsis - -```bash -npm ls [[<@scope>/]<pkg> ...] - -aliases: list, la, ll -``` - -### Description - -This command will print to stdout all the versions of packages that are -installed, as well as their dependencies when `--all` is specified, in a -tree structure. - -Note: to get a "bottoms up" view of why a given package is included in the -tree at all, use [`npm explain`](/commands/npm-explain). - -Positional arguments are `name@version-range` identifiers, which will limit -the results to only the paths to the packages named. Note that nested -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@@VERSION@ /path/to/npm -└─┬ init-package-json@0.0.4 - └── promzard@0.1.5 -``` - -It will print out extraneous, missing, and invalid packages. - -If a project specifies git urls for dependencies these are shown -in parentheses after the name@version to make it easier for users to -recognize potential forks of a project. - -The tree shown is the logical dependency tree, based on package -dependencies, not the physical layout of your `node_modules` folder. - -When run as `ll` or `la`, it shows extended information by default. - -### Note: Design Changes Pending - -The `npm ls` command's output and behavior made a _ton_ of sense when npm -created a `node_modules` folder that naively nested every dependency. In -such a case, the logical dependency graph and physical tree of packages on -disk would be roughly identical. - -With the advent of automatic install-time deduplication of dependencies in -npm v3, the `ls` output was modified to display the logical dependency -graph as a tree structure, since this was more useful to most users. -However, without using `npm ls -l`, it became impossible show _where_ a -package was actually installed much of the time! - -With the advent of automatic installation of `peerDependencies` in npm v7, -this gets even more curious, as `peerDependencies` are logically -"underneath" their dependents in the dependency graph, but are always -physically at or above their location on disk. - -Also, in the years since npm got an `ls` command (in version 0.0.2!), -dependency graphs have gotten much larger as a general rule. Therefore, in -order to avoid dumping an excessive amount of content to the terminal, `npm -ls` now only shows the _top_ level dependencies, unless `--all` is -provided. - -A thorough re-examination of the use cases, intention, behavior, and output -of this command, is currently underway. Expect significant changes to at -least the default human-readable `npm ls` output in npm v8. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `all` - -* Default: false -* Type: Boolean - -When running `npm outdated` and `npm ls`, setting `--all` will show all -outdated or installed packages, rather than only those directly depended -upon by the current project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `long` - -* Default: false -* Type: Boolean - -Show extended information in `ls`, `search`, and `help-search`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `parseable` - -* Default: false -* Type: Boolean - -Output parseable results from commands that write to standard output. For -`npm search`, this will be tab-separated table format. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `depth` - -* Default: `Infinity` if `--all` is set, otherwise `1` -* Type: null or Number - -The depth to go when recursing packages for `npm ls`. - -If not set, `npm ls` will show only the immediate dependencies of the root -project. If `--all` is set, then npm will show all dependencies by default. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `omit` - -* Default: 'dev' if the `NODE_ENV` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -`package-lock.json` or `npm-shrinkwrap.json` file. They are just not -physically installed on disk. - -If a package type appears in both the `--include` and `--omit` lists, then -it will be included. - -If the resulting omit list includes `'dev'`, then the `NODE_ENV` environment -variable will be set to `'production'` for all lifecycle scripts. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `link` - -* Default: false -* Type: Boolean - -Used with `npm ls`, limiting output to only those packages that are linked. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `package-lock-only` - -* Default: false -* Type: Boolean - -If set to true, the current operation will only use the `package-lock.json`, -ignoring `node_modules`. - -For `update` this means only the `package-lock.json` will be updated, -instead of checking `node_modules` and downloading dependencies. - -For `list` this means the output will be based on the tree described by the -`package-lock.json`, rather than the contents of `node_modules`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `unicode` - -* Default: false on windows, true on mac/unix systems with a unicode locale, - as defined by the `LC_ALL`, `LC_CTYPE`, or `LANG` environment variables. -* Type: Boolean - -When set to true, npm uses unicode characters in the tree output. When -false, it uses ascii characters instead of unicode glyphs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm explain](/commands/npm-explain) -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) -* [npm folders](/configuring-npm/folders) -* [npm explain](/commands/npm-explain) -* [npm install](/commands/npm-install) -* [npm link](/commands/npm-link) -* [npm prune](/commands/npm-prune) -* [npm outdated](/commands/npm-outdated) -* [npm update](/commands/npm-update) diff --git a/docs/content/commands/npm-org.md b/docs/content/commands/npm-org.md deleted file mode 100644 index 2f08f61..0000000 --- a/docs/content/commands/npm-org.md +++ /dev/null @@ -1,121 +0,0 @@ ---- -title: npm-org -section: 1 -description: Manage orgs ---- - -### Synopsis - -```bash -npm org set <orgname> <username> [developer | admin | owner] -npm org rm <orgname> <username> -npm org ls <orgname> [<username>] -``` - -Note: This command is unaware of workspaces. - -### Example - -Add a new developer to an org: - -```bash -$ npm org set my-org @mx-smith -``` - -Add a new admin to an org (or change a developer to an admin): - -```bash -$ npm org set my-org @mx-santos admin -``` - -Remove a user from an org: - -```bash -$ npm org rm my-org mx-santos -``` - -List all users in an org: - -```bash -$ npm org ls my-org -``` - -List all users in JSON format: - -```bash -$ npm org ls my-org --json -``` - -See what role a user has in an org: - -```bash -$ npm org ls my-org @mx-santos -``` - -### Description - -You can use the `npm org` commands to manage and view users of an -organization. It supports adding and removing users, changing their roles, -listing them, and finding specific ones and their roles. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `otp` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with `npm access`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `parseable` - -* Default: false -* Type: Boolean - -Output parseable results from commands that write to standard output. For -`npm search`, this will be tab-separated table format. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [using orgs](/using-npm/orgs) -* [Documentation on npm Orgs](https://docs.npmjs.com/orgs/) diff --git a/docs/content/commands/npm-pack.md b/docs/content/commands/npm-pack.md deleted file mode 100644 index 5394598..0000000 --- a/docs/content/commands/npm-pack.md +++ /dev/null @@ -1,140 +0,0 @@ ---- -title: npm-pack -section: 1 -description: Create a tarball from a package ---- - -### Synopsis - -```bash -npm pack [[<@scope>/]<pkg>...] [--dry-run] [--json] -``` - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `dry-run` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, `install`, `update`, -`dedupe`, `uninstall`, as well as `pack` and `publish`. - -Note: This is NOT honored by other network related commands, eg `dist-tags`, -`owner`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `pack-destination` - -* Default: "." -* Type: String - -Directory in which `npm pack` will save tarballs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### Description - -For anything that's installable (that is, a package folder, tarball, -tarball url, git url, name@tag, name@version, name, or scoped name), this -command will fetch it to the cache, copy the tarball to the current working -directory as `<name>-<version>.tgz`, and then write the filenames out to -stdout. - -If the same package is specified multiple times, then the file will be -overwritten the second time. - -If no arguments are supplied, then npm packs the current package folder. - -### See Also - -* [npm-packlist package](http://npm.im/npm-packlist) -* [npm cache](/commands/npm-cache) -* [npm publish](/commands/npm-publish) -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) diff --git a/docs/content/commands/npm-prefix.md b/docs/content/commands/npm-prefix.md deleted file mode 100644 index 276a9e9..0000000 --- a/docs/content/commands/npm-prefix.md +++ /dev/null @@ -1,66 +0,0 @@ ---- -title: npm-prefix -section: 1 -description: Display prefix ---- - -### Synopsis - -```bash -npm prefix [-g] -``` - -Note: This command is unaware of workspaces. - -### Description - -Print the local prefix to standard output. This is the closest parent directory -to contain a `package.json` file or `node_modules` directory, unless `-g` is -also specified. - -If `-g` is specified, this will be the value of the global prefix. See -[`npm config`](/commands/npm-config) for more detail. - -### Example - -```bash -npm prefix -/usr/local/projects/foo -``` - -```bash -npm prefix -g -/usr/local -``` - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm root](/commands/npm-root) -* [npm bin](/commands/npm-bin) -* [npm folders](/configuring-npm/folders) -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) diff --git a/docs/content/commands/npm-prune.md b/docs/content/commands/npm-prune.md deleted file mode 100644 index 658ab26..0000000 --- a/docs/content/commands/npm-prune.md +++ /dev/null @@ -1,159 +0,0 @@ ---- -title: npm-prune -section: 1 -description: Remove extraneous packages ---- - -### Synopsis - -```bash -npm prune [[<@scope>/]<pkg>...] [--production] [--dry-run] [--json] -``` - -### Description - -This command removes "extraneous" packages. If a package name is provided, -then only packages matching one of the supplied names are removed. - -Extraneous packages are those present in the `node_modules` folder that are -not listed as any package's dependency list. - -If the `--production` flag is specified or the `NODE_ENV` environment -variable is set to `production`, this command will remove the packages -specified in your `devDependencies`. Setting `--no-production` will negate -`NODE_ENV` being set to `production`. - -If the `--dry-run` flag is used then no changes will actually be made. - -If the `--json` flag is used, then the changes `npm prune` made (or would -have made with `--dry-run`) are printed as a JSON object. - -In normal operation, extraneous modules are pruned automatically, so you'll -only need this command with the `--production` flag. However, in the real -world, operation is not always "normal". When crashes or mistakes happen, -this command can help clean up any resulting garbage. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `omit` - -* Default: 'dev' if the `NODE_ENV` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -`package-lock.json` or `npm-shrinkwrap.json` file. They are just not -physically installed on disk. - -If a package type appears in both the `--include` and `--omit` lists, then -it will be included. - -If the resulting omit list includes `'dev'`, then the `NODE_ENV` environment -variable will be set to `'production'` for all lifecycle scripts. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `dry-run` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, `install`, `update`, -`dedupe`, `uninstall`, as well as `pack` and `publish`. - -Note: This is NOT honored by other network related commands, eg `dist-tags`, -`owner`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm uninstall](/commands/npm-uninstall) -* [npm folders](/configuring-npm/folders) -* [npm ls](/commands/npm-ls) diff --git a/docs/content/commands/npm-publish.md b/docs/content/commands/npm-publish.md deleted file mode 100644 index 6958b10..0000000 --- a/docs/content/commands/npm-publish.md +++ /dev/null @@ -1,250 +0,0 @@ ---- -title: npm-publish -section: 1 -description: Publish a package ---- - -### Synopsis - -```bash -npm publish [<tarball>|<folder>] [--tag <tag>] [--access <public|restricted>] [--otp otpcode] [--dry-run] - -Publishes '.' if no argument supplied -Sets tag 'latest' if no --tag specified -``` - -### Description - -Publishes a package to the registry so that it can be installed by name. - -By default npm will publish to the public registry. This can be overridden -by specifying a different default registry or using a -[`scope`](/using-npm/scope) in the name (see -[`package.json`](/configuring-npm/package-json)). - -* `<folder>`: A folder containing a package.json file - -* `<tarball>`: A url or file path to a gzipped tar archive containing a - single folder with a package.json file inside. - -* `[--tag <tag>]`: Registers the published package with the given tag, such - that `npm install <name>@<tag>` will install this version. By default, - `npm publish` updates and `npm install` installs the `latest` tag. See - [`npm-dist-tag`](npm-dist-tag) for details about tags. - -* `[--access <public|restricted>]`: Tells the registry whether this package - should be published as public or restricted. Only applies to scoped - packages, which default to `restricted`. If you don't have a paid - account, you must publish with `--access public` to publish scoped - packages. - -* `[--otp <otpcode>]`: If you have two-factor authentication enabled in - `auth-and-writes` mode then you can provide a code from your - authenticator with this. If you don't include this and you're running - from a TTY then you'll be prompted. - -* `[--dry-run]`: As of `npm@6`, does everything publish would do except - actually publishing to the registry. Reports the details of what would - have been published. - -* `[--workspaces]`: Enables workspace context while publishing. All - workspace packages will be published. - -* `[--workspace]`: Enables workspaces context and limits results to only - those specified by this config item. Only the packages in the - workspaces given will be published. - -The publish will fail if the package name and version combination already -exists in the specified registry. - -Once a package is published with a given name and version, that specific -name and version combination can never be used again, even if it is removed -with [`npm unpublish`](/commands/npm-unpublish). - -As of `npm@5`, both a sha1sum and an integrity field with a sha512sum of the -tarball will be submitted to the registry during publication. Subsequent -installs will use the strongest supported algorithm to verify downloads. - -Similar to `--dry-run` see [`npm pack`](/commands/npm-pack), which figures -out the files to be included and packs them into a tarball to be uploaded -to the registry. - -### Files included in package - -To see what will be included in your package, run `npx npm-packlist`. All -files are included by default, with the following exceptions: - -- Certain files that are relevant to package installation and distribution - are always included. For example, `package.json`, `README.md`, - `LICENSE`, and so on. - -- If there is a "files" list in - [`package.json`](/configuring-npm/package-json), then only the files - specified will be included. (If directories are specified, then they - will be walked recursively and their contents included, subject to the - same ignore rules.) - -- If there is a `.gitignore` or `.npmignore` file, then ignored files in - that and all child directories will be excluded from the package. If - _both_ files exist, then the `.gitignore` is ignored, and only the - `.npmignore` is used. - - `.npmignore` files follow the [same pattern - rules](https://git-scm.com/book/en/v2/Git-Basics-Recording-Changes-to-the-Repository#_ignoring) - as `.gitignore` files - -- If the file matches certain patterns, then it will _never_ be included, - unless explicitly added to the `"files"` list in `package.json`, or - un-ignored with a `!` rule in a `.npmignore` or `.gitignore` file. - -- Symbolic links are never included in npm packages. - - -See [`developers`](/using-npm/developers) for full details on what's -included in the published package, as well as details on how the package is -built. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `tag` - -* Default: "latest" -* Type: String - -If you ask npm to install a package and don't tell it a specific version, -then it will install the specified tag. - -Also the tag that is added to the package@version specified by the `npm tag` -command, if no explicit tag is given. - -When used by the `npm diff` command, this is the tag used to fetch the -tarball that will be compared with the local files by default. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `access` - -* Default: 'restricted' for scoped packages, 'public' for unscoped packages -* Type: null, "restricted", or "public" - -When publishing scoped packages, the access level defaults to `restricted`. -If you want your scoped package to be publicly viewable (and installable) -set `--access=public`. The only valid values for `access` are `public` and -`restricted`. Unscoped packages _always_ have an access level of `public`. - -Note: Using the `--access` flag on the `npm publish` command will only set -the package access level on the initial publish of the package. Any -subsequent `npm publish` commands using the `--access` flag will not have an -effect to the access level. To make changes to the access level after the -initial publish use `npm access`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `dry-run` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, `install`, `update`, -`dedupe`, `uninstall`, as well as `pack` and `publish`. - -Note: This is NOT honored by other network related commands, eg `dist-tags`, -`owner`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `otp` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with `npm access`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm-packlist package](http://npm.im/npm-packlist) -* [npm registry](/using-npm/registry) -* [npm scope](/using-npm/scope) -* [npm adduser](/commands/npm-adduser) -* [npm owner](/commands/npm-owner) -* [npm deprecate](/commands/npm-deprecate) -* [npm dist-tag](/commands/npm-dist-tag) -* [npm pack](/commands/npm-pack) -* [npm profile](/commands/npm-profile) diff --git a/docs/content/commands/npm-rebuild.md b/docs/content/commands/npm-rebuild.md deleted file mode 100644 index 75e71c6..0000000 --- a/docs/content/commands/npm-rebuild.md +++ /dev/null @@ -1,143 +0,0 @@ ---- -title: npm-rebuild -section: 1 -description: Rebuild a package ---- - -### Synopsis - -```bash -npm rebuild [[<@scope>/]<name>[@<version>] ...] - -alias: rb -``` - -### Description - -This command runs the `npm build` command on the matched folders. This is -useful when you install a new version of node, and must recompile all your -C++ addons with the new binary. It is also useful when installing with -`--ignore-scripts` and `--no-bin-links`, to explicitly choose which -packages to build and/or link bins. - -If one or more package names (and optionally version ranges) are provided, -then only packages with a name and version matching one of the specifiers -will be rebuilt. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `bin-links` - -* Default: true -* Type: Boolean - -Tells npm to create symlinks (or `.cmd` shims on Windows) for package -executables. - -Set to false to have it not do this. This can be used to work around the -fact that some file systems don't support symlinks, even on ostensibly Unix -systems. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm install](/commands/npm-install) diff --git a/docs/content/commands/npm-repo.md b/docs/content/commands/npm-repo.md deleted file mode 100644 index cd47fde..0000000 --- a/docs/content/commands/npm-repo.md +++ /dev/null @@ -1,105 +0,0 @@ ---- -title: npm-repo -section: 1 -description: Open package repository page in the browser ---- - -### Synopsis - -```bash -npm repo [<pkgname> [<pkgname> ...]] -``` - -### Description - -This command tries to guess at the likely location of a package's -repository URL, and then tries to open it using the `--browser` config -param. If no package name is provided, it will search for a `package.json` -in the current folder and use the `repository` property. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `browser` - -* Default: OS X: `"open"`, Windows: `"start"`, Others: `"xdg-open"` -* Type: null, Boolean, or String - -The browser that is called by npm commands to open websites. - -Set to `false` to suppress browser behavior and instead print urls to -terminal. - -Set to `true` to use default system URL opener. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm docs](/commands/npm-docs) -* [npm config](/commands/npm-config) diff --git a/docs/content/commands/npm-restart.md b/docs/content/commands/npm-restart.md deleted file mode 100644 index 80f8ab7..0000000 --- a/docs/content/commands/npm-restart.md +++ /dev/null @@ -1,77 +0,0 @@ ---- -title: npm-restart -section: 1 -description: Restart a package ---- - -### Synopsis - -```bash -npm restart [-- <args>] -``` - -### Description - -This restarts a project. It is equivalent to running `npm run-script -restart`. - -If the current project has a `"restart"` script specified in -`package.json`, then the following scripts will be run: - -1. prerestart -2. restart -3. postrestart - -If it does _not_ have a `"restart"` script specified, but it does have -`stop` and/or `start` scripts, then the following scripts will be run: - -1. prerestart -2. prestop -3. stop -4. poststop -6. prestart -7. start -8. poststart -9. postrestart - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `script-shell` - -* Default: '/bin/sh' on POSIX systems, 'cmd.exe' on Windows -* Type: null or String - -The shell to use for scripts run with the `npm exec`, `npm run` and `npm -init <pkg>` commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm run-script](/commands/npm-run-script) -* [npm scripts](/using-npm/scripts) -* [npm test](/commands/npm-test) -* [npm start](/commands/npm-start) -* [npm stop](/commands/npm-stop) -* [npm restart](/commands/npm-restart) diff --git a/docs/content/commands/npm-root.md b/docs/content/commands/npm-root.md deleted file mode 100644 index 98d1108..0000000 --- a/docs/content/commands/npm-root.md +++ /dev/null @@ -1,56 +0,0 @@ ---- -title: npm-root -section: 1 -description: Display npm root ---- - -### Synopsis - -```bash -npm root [-g] -``` - -### Description - -Print the effective `node_modules` folder to standard out. - -Useful for using npm in shell scripts that do things with the -`node_modules` folder. For example: - -```bash -#!/bin/bash -global_node_modules="$(npm root --global)" -echo "Global packages installed in: ${global_node_modules}" -``` - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm prefix](/commands/npm-prefix) -* [npm bin](/commands/npm-bin) -* [npm folders](/configuring-npm/folders) -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) diff --git a/docs/content/commands/npm-run-script.md b/docs/content/commands/npm-run-script.md deleted file mode 100644 index 6dd602d..0000000 --- a/docs/content/commands/npm-run-script.md +++ /dev/null @@ -1,253 +0,0 @@ ---- -title: npm-run-script -section: 1 -description: Run arbitrary package scripts ---- - -### Synopsis - -```bash -npm run-script <command> [--if-present] [--silent] [-- <args>] -npm run-script <command> [--workspace=<workspace-name>] -npm run-script <command> [--workspaces] - -aliases: run, rum, urn -``` - -### Description - -This runs an arbitrary command from a package's `"scripts"` object. If no -`"command"` is provided, it will list the available scripts. - -`run[-script]` is used by the test, start, restart, and stop commands, but -can be called directly, as well. When the scripts in the package are -printed out, they're separated into lifecycle (test, start, restart) and -directly-run scripts. - -Any positional arguments are passed to the specified script. Use `--` to -pass `-`-prefixed flags and options which would otherwise be parsed by npm. - -For example: - -```bash -npm run test -- --grep="pattern" -``` - -The arguments will only be passed to the script specified after `npm run` -and not to any `pre` or `post` script. - -The `env` script is a special built-in command that can be used to list -environment variables that will be available to the script at runtime. If an -"env" command is defined in your package, it will take precedence over the -built-in. - -In addition to the shell's pre-existing `PATH`, `npm run` adds -`node_modules/.bin` to the `PATH` provided to scripts. Any binaries -provided by locally-installed dependencies can be used without the -`node_modules/.bin` prefix. For example, if there is a `devDependency` on -`tap` in your package, you should write: - -```bash -"scripts": {"test": "tap test/*.js"} -``` - -instead of - -```bash -"scripts": {"test": "node_modules/.bin/tap test/*.js"} -``` - -The actual shell your script is run within is platform dependent. By default, -on Unix-like systems it is the `/bin/sh` command, on Windows it is -`cmd.exe`. -The actual shell referred to by `/bin/sh` also depends on the system. -You can customize the shell with the `script-shell` configuration. - -Scripts are run from the root of the package folder, regardless of what the -current working directory is when `npm run` is called. If you want your -script to use different behavior based on what subdirectory you're in, you -can use the `INIT_CWD` environment variable, which holds the full path you -were in when you ran `npm run`. - -`npm run` sets the `NODE` environment variable to the `node` executable -with which `npm` is executed. - -If you try to run a script without having a `node_modules` directory and it -fails, you will be given a warning to run `npm install`, just in case you've -forgotten. - -### Workspaces support - -You may use the `workspace` or `workspaces` configs in order to run an -arbitrary command from a package's `"scripts"` object in the context of the -specified workspaces. If no `"command"` is provided, it will list the available -scripts for each of these configured workspaces. - -Given a project with configured workspaces, e.g: - -``` -. -+-- package.json -`-- packages - +-- a - | `-- package.json - +-- b - | `-- package.json - `-- c - `-- package.json -``` - -Assuming the workspace configuration is properly set up at the root level -`package.json` file. e.g: - -``` -{ - "workspaces": [ "./packages/*" ] -} -``` - -And that each of the configured workspaces has a configured `test` script, -we can run tests in all of them using the `workspaces` config: - -``` -npm test --workspaces -``` - -#### Filtering workspaces - -It's also possible to run a script in a single workspace using the `workspace` -config along with a name or directory path: - -``` -npm test --workspace=a -``` - -The `workspace` config can also be specified multiple times in order to run a -specific script in the context of multiple workspaces. When defining values for -the `workspace` config in the command line, it also possible to use `-w` as a -shorthand, e.g: - -``` -npm test -w a -w b -``` - -This last command will run `test` in both `./packages/a` and `./packages/b` -packages. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `if-present` - -* 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 -running scripts that may only apply for some builds in an otherwise generic -CI setup. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `script-shell` - -* Default: '/bin/sh' on POSIX systems, 'cmd.exe' on Windows -* Type: null or String - -The shell to use for scripts run with the `npm exec`, `npm run` and `npm -init <pkg>` commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm scripts](/using-npm/scripts) -* [npm test](/commands/npm-test) -* [npm start](/commands/npm-start) -* [npm restart](/commands/npm-restart) -* [npm stop](/commands/npm-stop) -* [npm config](/commands/npm-config) -* [npm workspaces](/using-npm/workspaces) diff --git a/docs/content/commands/npm-search.md b/docs/content/commands/npm-search.md deleted file mode 100644 index 252822e..0000000 --- a/docs/content/commands/npm-search.md +++ /dev/null @@ -1,175 +0,0 @@ ---- -title: npm-search -section: 1 -description: Search for packages ---- - -### Synopsis - -```bash -npm search [-l|--long] [--json] [--parseable] [--no-description] [search terms ...] - -aliases: s, se, find -``` - -Note: This command is unaware of workspaces. - -### Description - -Search the registry for packages matching the search terms. `npm search` -performs a linear, incremental, lexically-ordered search through package -metadata for all files in the registry. If your terminal has color -support, it will further highlight the matches in the results. This can -be disabled with the config item `color` - -Additionally, using the `--searchopts` and `--searchexclude` options -paired with more search terms will include and exclude further patterns. -The main difference between `--searchopts` and the standard search terms -is that the former does not highlight results in the output and you can -use them more fine-grained filtering. Additionally, you can add both of -these to your config to change default search filtering behavior. - -Search also allows targeting of maintainers in search results, by prefixing -their npm username with `=`. - -If a term starts with `/`, then it's interpreted as a regular expression -and supports standard JavaScript RegExp syntax. In this case search will -ignore a trailing `/` . (Note you must escape or quote many regular -expression characters in most shells.) - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `long` - -* Default: false -* Type: Boolean - -Show extended information in `ls`, `search`, and `help-search`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `color` - -* Default: true unless the NO_COLOR environ is set to something other than '0' -* Type: "always" or Boolean - -If false, never shows colors. If `"always"` then always shows colors. If -true, then only prints color codes for tty file descriptors. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `parseable` - -* Default: false -* Type: Boolean - -Output parseable results from commands that write to standard output. For -`npm search`, this will be tab-separated table format. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `description` - -* Default: true -* Type: Boolean - -Show the description in `npm search` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `searchopts` - -* Default: "" -* Type: String - -Space-separated options that are always passed to search. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `searchexclude` - -* Default: "" -* Type: String - -Space-separated options that limit the results from search. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `prefer-online` - -* Default: false -* Type: Boolean - -If true, staleness checks for cached data will be forced, making the CLI -look for updates immediately even for fresh package data. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `prefer-offline` - -* Default: false -* Type: Boolean - -If true, staleness checks for cached data will be bypassed, but missing data -will be requested from the server. To force full offline mode, use -`--offline`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `offline` - -* Default: false -* Type: Boolean - -Force offline mode: no network requests will be done during install. To -allow the CLI to fill in missing cache data, see `--prefer-offline`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm registry](/using-npm/registry) -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) -* [npm view](/commands/npm-view) -* [npm cache](/commands/npm-cache) -* https://npm.im/npm-registry-fetch diff --git a/docs/content/commands/npm-set-script.md b/docs/content/commands/npm-set-script.md deleted file mode 100644 index 869ceed..0000000 --- a/docs/content/commands/npm-set-script.md +++ /dev/null @@ -1,101 +0,0 @@ ---- -title: npm-set-script -section: 1 -description: Set tasks in the scripts section of package.json ---- - -### Synopsis -An npm command that lets you create a task in the `scripts` section of the `package.json`. - -```bash -npm set-script [<script>] [<command>] -``` - - -**Example:** - -* `npm set-script start "http-server ."` - -```json -{ - "name": "my-project", - "scripts": { - "start": "http-server .", - "test": "some existing value" - } -} -``` - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm run-script](/commands/npm-run-script) -* [npm install](/commands/npm-install) -* [npm test](/commands/npm-test) -* [npm start](/commands/npm-start) diff --git a/docs/content/commands/npm-stop.md b/docs/content/commands/npm-stop.md deleted file mode 100644 index d4de4ca..0000000 --- a/docs/content/commands/npm-stop.md +++ /dev/null @@ -1,80 +0,0 @@ ---- -title: npm-stop -section: 1 -description: Stop a package ---- - -### Synopsis - -```bash -npm stop [-- <args>] -``` - -### Description - -This runs a predefined command specified in the "stop" property of a -package's "scripts" object. - -Unlike with [npm start](/commands/npm-start), there is no default script -that will run if the `"stop"` property is not defined. - -### Example - -```json -{ - "scripts": { - "stop": "node bar.js" - } -} -``` - -```bash -npm stop - -> npm@x.x.x stop -> node bar.js - -(bar.js output would be here) - -``` - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `script-shell` - -* Default: '/bin/sh' on POSIX systems, 'cmd.exe' on Windows -* Type: null or String - -The shell to use for scripts run with the `npm exec`, `npm run` and `npm -init <pkg>` commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm run-script](/commands/npm-run-script) -* [npm scripts](/using-npm/scripts) -* [npm test](/commands/npm-test) -* [npm start](/commands/npm-start) -* [npm restart](/commands/npm-restart) diff --git a/docs/content/commands/npm-test.md b/docs/content/commands/npm-test.md deleted file mode 100644 index 2059f93..0000000 --- a/docs/content/commands/npm-test.md +++ /dev/null @@ -1,77 +0,0 @@ ---- -title: npm-test -section: 1 -description: Test a package ---- - -### Synopsis - -```bash -npm test [-- <args>] - -aliases: t, tst -``` - -### Description - -This runs a predefined command specified in the `"test"` property of -a package's `"scripts"` object. - -### Example - -```json -{ - "scripts": { - "test": "node test.js" - } -} -``` - -```bash -npm test -> npm@x.x.x test -> node test.js - -(test.js output would be here) -``` - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `script-shell` - -* Default: '/bin/sh' on POSIX systems, 'cmd.exe' on Windows -* Type: null or String - -The shell to use for scripts run with the `npm exec`, `npm run` and `npm -init <pkg>` commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm run-script](/commands/npm-run-script) -* [npm scripts](/using-npm/scripts) -* [npm start](/commands/npm-start) -* [npm restart](/commands/npm-restart) -* [npm stop](/commands/npm-stop) diff --git a/docs/content/commands/npm-uninstall.md b/docs/content/commands/npm-uninstall.md deleted file mode 100644 index 824d0d8..0000000 --- a/docs/content/commands/npm-uninstall.md +++ /dev/null @@ -1,143 +0,0 @@ ---- -title: npm-uninstall -section: 1 -description: Remove a package ---- - -### Synopsis - -```bash -npm uninstall [<@scope>/]<pkg>[@<version>]... [-S|--save|--no-save] - -aliases: remove, rm, r, un, unlink -``` - -### Description - -This uninstalls a package, completely removing everything npm installed -on its behalf. - -It also removes the package from the `dependencies`, `devDependencies`, -`optionalDependencies`, and `peerDependencies` objects in your -`package.json`. - -Futher, if you have an `npm-shrinkwrap.json` or `package-lock.json`, npm -will update those files as well. - -`--no-save` will tell npm not to remove the package from your -`package.json`, `npm-shrinkwrap.json`, or `package-lock.json` files. - -`--save` or `-S` will tell npm to remove the package from your -`package.json`, `npm-shrinkwrap.json`, and `package-lock.json` files. -This is the default, but you may need to use this if you have for -instance `save=false` in your `npmrc` file - -In global mode (ie, with `-g` or `--global` appended to the command), -it uninstalls the current package context as a global package. -`--no-save` is ignored in this case. - -Scope is optional and follows the usual rules for [`scope`](/using-npm/scope). - -### Examples - -```bash -npm uninstall sax -``` - -`sax` will no longer be in your `package.json`, `npm-shrinkwrap.json`, or -`package-lock.json` files. - -```bash -npm uninstall lodash --no-save -``` - -`lodash` will not be removed from your `package.json`, -`npm-shrinkwrap.json`, or `package-lock.json` files. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `save` - -* Default: true -* Type: Boolean - -Save installed packages to a package.json file as dependencies. - -When used with the `npm rm` command, removes the dependency from -package.json. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm prune](/commands/npm-prune) -* [npm install](/commands/npm-install) -* [npm folders](/configuring-npm/folders) -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) diff --git a/docs/content/commands/npm-unpublish.md b/docs/content/commands/npm-unpublish.md deleted file mode 100644 index 13589a0..0000000 --- a/docs/content/commands/npm-unpublish.md +++ /dev/null @@ -1,152 +0,0 @@ ---- -title: npm-unpublish -section: 1 -description: Remove a package from the registry ---- - -### Synopsis - -To learn more about how the npm registry treats unpublish, see our <a -href="https://docs.npmjs.com/policies/unpublish" target="_blank" -rel="noopener noreferrer"> unpublish policies</a> - -#### Unpublishing a single version of a package - -```bash -npm unpublish [<@scope>/]<pkg>@<version> -``` - -#### Unpublishing an entire package - -```bash -npm unpublish [<@scope>/]<pkg> --force -``` - -### Warning - -Consider using the [`deprecate`](/commands/npm-deprecate) command instead, -if your intent is to encourage users to upgrade, or if you no longer -want to maintain a package. - -### Description - -This removes a package version from the registry, deleting its entry and -removing the tarball. - -The npm registry will return an error if you are not [logged -in](/commands/npm-adduser). - -If you do not specify a version or if you remove all of a package's -versions then the registry will remove the root package entry entirely. - -Even if you unpublish a package version, that specific name and version -combination can never be reused. In order to publish the package again, -you must use a new version number. If you unpublish the entire package, -you may not publish any new versions of that package until 24 hours have -passed. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `dry-run` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, `install`, `update`, -`dedupe`, `uninstall`, as well as `pack` and `publish`. - -Note: This is NOT honored by other network related commands, eg `dist-tags`, -`owner`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `force` - -* Default: false -* Type: Boolean - -Removes various protections against unfortunate side effects, common -mistakes, unnecessary performance degradation, and malicious input. - -* Allow clobbering non-npm files in global installs. -* Allow the `npm version` command to work on an unclean git repository. -* Allow deleting the cache folder with `npm cache clean`. -* Allow installing packages that have an `engines` declaration requiring a - different version of npm. -* Allow installing packages that have an `engines` declaration requiring a - different version of `node`, even if `--engine-strict` is enabled. -* Allow `npm audit fix` to install modules outside your stated dependency - range (including SemVer-major changes). -* Allow unpublishing all versions of a published package. -* Allow conflicting peerDependencies to be installed in the root project. -* Implicitly set `--yes` during `npm init`. -* Allow clobbering existing values in `npm pkg` - -If you don't have a clear idea of what you want to do, it is strongly -recommended that you do not use this option! - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm deprecate](/commands/npm-deprecate) -* [npm publish](/commands/npm-publish) -* [npm registry](/using-npm/registry) -* [npm adduser](/commands/npm-adduser) -* [npm owner](/commands/npm-owner) -* [npm login](/commands/npm-adduser) diff --git a/docs/content/commands/npm-unstar.md b/docs/content/commands/npm-unstar.md deleted file mode 100644 index d6e3620..0000000 --- a/docs/content/commands/npm-unstar.md +++ /dev/null @@ -1,82 +0,0 @@ ---- -title: npm-unstar -section: 1 -description: Remove an item from your favorite packages ---- - -### Synopsis - -```bash -npm unstar [<pkg>...] -``` - -Note: This command is unaware of workspaces. - -### Description - -"Unstarring" a package is the opposite of [`npm star`](/commands/npm-star), -it removes an item from your list of favorite packages. - -### More - -There's also these extra commands to help you manage your favorite packages: - -#### Star - -You can "star" a package using [`npm star`](/commands/npm-star) - -#### Listing stars - -You can see all your starred packages using [`npm stars`](/commands/npm-stars) - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `unicode` - -* Default: false on windows, true on mac/unix systems with a unicode locale, - as defined by the `LC_ALL`, `LC_CTYPE`, or `LANG` environment variables. -* Type: Boolean - -When set to true, npm uses unicode characters in the tree output. When -false, it uses ascii characters instead of unicode glyphs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `otp` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with `npm access`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm star](/commands/npm-star) -* [npm stars](/commands/npm-stars) -* [npm view](/commands/npm-view) -* [npm whoami](/commands/npm-whoami) -* [npm adduser](/commands/npm-adduser) - diff --git a/docs/content/commands/npm-update.md b/docs/content/commands/npm-update.md deleted file mode 100644 index 1889d60..0000000 --- a/docs/content/commands/npm-update.md +++ /dev/null @@ -1,406 +0,0 @@ ---- -title: npm-update -section: 1 -description: Update packages ---- - -### Synopsis - -```bash -npm update [-g] [<pkg>...] - -aliases: up, upgrade -``` - -### Description - -This command will update all the packages listed to the latest version -(specified by the `tag` config), respecting the semver constraints of -both your package and its dependencies (if they also require the same -package). - -It will also install missing packages. - -If the `-g` flag is specified, this command will update globally installed -packages. - -If no package name is specified, all packages in the specified location (global -or local) will be updated. - -Note that by default `npm update` will not update the semver values of direct -dependencies in your project `package.json`, if you want to also update -values in `package.json` you can run: `npm update --save` (or add the -`save=true` option to a [configuration file](/configuring-npm/npmrc) -to make that the default behavior). - -### Example - -For the examples below, assume that the current package is `app` and it depends -on dependencies, `dep1` (`dep2`, .. etc.). The published versions of `dep1` -are: - -```json -{ - "dist-tags": { "latest": "1.2.2" }, - "versions": [ - "1.2.2", - "1.2.1", - "1.2.0", - "1.1.2", - "1.1.1", - "1.0.0", - "0.4.1", - "0.4.0", - "0.2.0" - ] -} -``` - -#### Caret Dependencies - -If `app`'s `package.json` contains: - -```json -"dependencies": { - "dep1": "^1.1.1" -} -``` - -Then `npm update` will install `dep1@1.2.2`, because `1.2.2` is `latest` and -`1.2.2` satisfies `^1.1.1`. - -#### Tilde Dependencies - -However, if `app`'s `package.json` contains: - -```json -"dependencies": { - "dep1": "~1.1.1" -} -``` - -In this case, running `npm update` will install `dep1@1.1.2`. Even though the -`latest` tag points to `1.2.2`, this version do not satisfy `~1.1.1`, which is -equivalent to `>=1.1.1 <1.2.0`. So the highest-sorting version that satisfies -`~1.1.1` is used, which is `1.1.2`. - -#### Caret Dependencies below 1.0.0 - -Suppose `app` has a caret dependency on a version below `1.0.0`, for example: - -```json -"dependencies": { - "dep1": "^0.2.0" -} -``` - -`npm update` will install `dep1@0.2.0`, because there are no other -versions which satisfy `^0.2.0`. - -If the dependence were on `^0.4.0`: - -```json -"dependencies": { - "dep1": "^0.4.0" -} -``` - -Then `npm update` will install `dep1@0.4.1`, because that is the highest-sorting -version that satisfies `^0.4.0` (`>= 0.4.0 <0.5.0`) - - -#### Subdependencies - -Suppose your app now also has a dependency on `dep2` - -```json -{ - "name": "my-app", - "dependencies": { - "dep1": "^1.0.0", - "dep2": "1.0.0" - } -} -``` - -and `dep2` itself depends on this limited range of `dep1` - -```json -{ -"name": "dep2", - "dependencies": { - "dep1": "~1.1.1" - } -} -``` - -Then `npm update` will install `dep1@1.1.2` because that is the highest -version that `dep2` allows. npm will prioritize having a single version -of `dep1` in your tree rather than two when that single version can -satisfy the semver requirements of multiple dependencies in your tree. -In this case if you really did need your package to use a newer version -you would need to use `npm install`. - - -#### Updating Globally-Installed Packages - -`npm update -g` will apply the `update` action to each globally installed -package that is `outdated` -- that is, has a version that is different from -`wanted`. - -Note: Globally installed packages are treated as if they are installed with a -caret semver range specified. So if you require to update to `latest` you may -need to run `npm install -g [<pkg>...]` - -NOTE: If a package has been upgraded to a version newer than `latest`, it will -be _downgraded_. - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global-style` - -* Default: false -* Type: Boolean - -Causes npm to install the package into your local `node_modules` folder with -the same layout it uses with the global `node_modules` folder. Only your -direct dependencies will show in `node_modules` and everything they depend -on will be flattened in their `node_modules` folders. This obviously will -eliminate some deduping. If used with `legacy-bundling`, `legacy-bundling` -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `legacy-bundling` - -* Default: false -* Type: Boolean - -Causes npm to install the package such that versions of npm prior to 1.4, -such as the one included with node 0.8, can install the package. This -eliminates all automatic deduping. If used with `global-style` this option -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `strict-peer-deps` - -* Default: false -* Type: Boolean - -If set to `true`, and `--legacy-peer-deps` is not set, then _any_ -conflicting `peerDependencies` will be treated as an install failure, even -if npm could reasonably guess the appropriate resolution based on non-peer -dependency relationships. - -By default, conflicting `peerDependencies` deep in the dependency graph will -be resolved using the nearest non-peer dependency specification, even if -doing so will result in some packages receiving a peer dependency outside -the range set in their package's `peerDependencies` object. - -When such and override is performed, a warning is printed, explaining the -conflict and the packages involved. If `--strict-peer-deps` is set, then -this warning is treated as a failure. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `package-lock` - -* Default: true -* Type: Boolean - -If set to false, then ignore `package-lock.json` files when installing. This -will also prevent _writing_ `package-lock.json` if `save` is true. - -When package package-locks are disabled, automatic pruning of extraneous -modules will also be disabled. To remove extraneous modules with -package-locks disabled use `npm prune`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `omit` - -* Default: 'dev' if the `NODE_ENV` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -`package-lock.json` or `npm-shrinkwrap.json` file. They are just not -physically installed on disk. - -If a package type appears in both the `--include` and `--omit` lists, then -it will be included. - -If the resulting omit list includes `'dev'`, then the `NODE_ENV` environment -variable will be set to `'production'` for all lifecycle scripts. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `audit` - -* Default: true -* Type: Boolean - -When "true" submit audit reports alongside the current npm command to the -default registry and all registries configured for scopes. See the -documentation for [`npm audit`](/commands/npm-audit) for details on what is -submitted. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `bin-links` - -* Default: true -* Type: Boolean - -Tells npm to create symlinks (or `.cmd` shims on Windows) for package -executables. - -Set to false to have it not do this. This can be used to work around the -fact that some file systems don't support symlinks, even on ostensibly Unix -systems. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fund` - -* Default: true -* Type: Boolean - -When "true" displays the message at the end of each `npm install` -acknowledging the number of dependencies looking for funding. See [`npm -fund`](/commands/npm-fund) for details. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `dry-run` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, `install`, `update`, -`dedupe`, `uninstall`, as well as `pack` and `publish`. - -Note: This is NOT honored by other network related commands, eg `dist-tags`, -`owner`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See Also - -* [npm install](/commands/npm-install) -* [npm outdated](/commands/npm-outdated) -* [npm shrinkwrap](/commands/npm-shrinkwrap) -* [npm registry](/using-npm/registry) -* [npm folders](/configuring-npm/folders) -* [npm ls](/commands/npm-ls) diff --git a/docs/content/commands/npm-version.md b/docs/content/commands/npm-version.md deleted file mode 100644 index 91ab0de..0000000 --- a/docs/content/commands/npm-version.md +++ /dev/null @@ -1,244 +0,0 @@ ---- -title: npm-version -section: 1 -description: Bump a package version ---- - -### Synopsis - -```bash -npm version [<newversion> | major | minor | patch | premajor | preminor | prepatch | prerelease [--preid=<prerelease-id>] | from-git] - -'npm [-v | --version]' to print npm version -'npm view <pkg> version' to view a package's published version -'npm ls' to inspect current package/dependency versions -``` - -### Configuration - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `allow-same-version` - -* Default: false -* Type: Boolean - -Prevents throwing an error when `npm version` is used to set the new version -to the same value as the current version. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `commit-hooks` - -* Default: true -* Type: Boolean - -Run git commit hooks when using the `npm version` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `git-tag-version` - -* Default: true -* Type: Boolean - -Tag the commit when using the `npm version` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `preid` - -* Default: "" -* Type: String - -The "prerelease identifier" to use as a prefix for the "prerelease" part of -a semver. Like the `rc` in `1.2.0-rc.8`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `sign-git-tag` - -* Default: false -* Type: Boolean - -If set to true, then the `npm version` command will tag the version using -`-s` to add a signature. - -Note that git requires you to have set up GPG keys in your git configs for -this to work properly. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### Description - -Run this in a package directory to bump the version and write the new data -back to `package.json`, `package-lock.json`, and, if present, -`npm-shrinkwrap.json`. - -The `newversion` argument should be a valid semver string, a valid second -argument to [semver.inc](https://github.com/npm/node-semver#functions) (one -of `patch`, `minor`, `major`, `prepatch`, `preminor`, `premajor`, -`prerelease`), or `from-git`. In the second case, the existing version will -be incremented by 1 in the specified field. `from-git` will try to read -the latest git tag, and use that as the new npm version. - -If run in a git repo, it will also create a version commit and tag. This -behavior is controlled by `git-tag-version` (see below), and can be -disabled on the command line by running `npm --no-git-tag-version version`. -It will fail if the working directory is not clean, unless the `-f` or -`--force` flag is set. - -If supplied with `-m` or `--message` config option, npm will use it as a -commit message when creating a version commit. If the `message` config -contains `%s` then that will be replaced with the resulting version number. -For example: - -```bash -npm version patch -m "Upgrade to %s for reasons" -``` - -If the `sign-git-tag` config is set, then the tag will be signed using the -`-s` flag to git. Note that you must have a default GPG key set up in your -git config for this to work properly. For example: - -```bash -$ npm config set sign-git-tag true -$ npm version patch - -You need a passphrase to unlock the secret key for -user: "isaacs (http://blog.izs.me/) <i@izs.me>" -2048-bit RSA key, ID 6C481CF6, created 2010-08-31 - -Enter passphrase: -``` - -If `preversion`, `version`, or `postversion` are in the `scripts` property -of the package.json, they will be executed as part of running `npm -version`. - -The exact order of execution is as follows: - -1. Check to make sure the git working directory is clean before we get - started. Your scripts may add files to the commit in future steps. - This step is skipped if the `--force` flag is set. -2. Run the `preversion` script. These scripts have access to the old - `version` in package.json. A typical use would be running your full - test suite before deploying. Any files you want added to the commit - should be explicitly added using `git add`. -3. Bump `version` in `package.json` as requested (`patch`, `minor`, - `major`, etc). -4. Run the `version` script. These scripts have access to the new `version` - in package.json (so they can incorporate it into file headers in - generated files for example). Again, scripts should explicitly add - generated files to the commit using `git add`. -5. Commit and tag. -6. Run the `postversion` script. Use it to clean up the file system or - automatically push the commit and/or tag. - -Take the following example: - -```json -{ - "scripts": { - "preversion": "npm test", - "version": "npm run build && git add -A dist", - "postversion": "git push && git push --tags && rm -rf build/temp" - } -} -``` - -This runs all your tests and proceeds only if they pass. Then runs your -`build` script, and adds everything in the `dist` directory to the commit. -After the commit, it pushes the new commit and tag up to the server, and -deletes the `build/temp` directory. - -### See Also - -* [npm init](/commands/npm-init) -* [npm run-script](/commands/npm-run-script) -* [npm scripts](/using-npm/scripts) -* [package.json](/configuring-npm/package-json) -* [config](/using-npm/config) diff --git a/docs/content/using-npm/config.md b/docs/content/using-npm/config.md deleted file mode 100644 index 9fbb614..0000000 --- a/docs/content/using-npm/config.md +++ /dev/null @@ -1,2051 +0,0 @@ ---- -title: config -section: 7 -description: More than you probably want to know about npm configuration ---- - -### Description - -npm gets its configuration values from the following sources, sorted by priority: - -#### Command Line Flags - -Putting `--foo bar` on the command line sets the `foo` configuration -parameter to `"bar"`. A `--` argument tells the cli parser to stop -reading flags. Using `--flag` without specifying any value will set -the value to `true`. - -Example: `--flag1 --flag2` will set both configuration parameters -to `true`, while `--flag1 --flag2 bar` will set `flag1` to `true`, -and `flag2` to `bar`. Finally, `--flag1 --flag2 -- bar` will set -both configuration parameters to `true`, and the `bar` is taken -as a command argument. - -#### Environment Variables - -Any environment variables that start with `npm_config_` will be -interpreted as a configuration parameter. For example, putting -`npm_config_foo=bar` in your environment will set the `foo` -configuration parameter to `bar`. Any environment configurations that -are not given a value will be given the value of `true`. Config -values are case-insensitive, so `NPM_CONFIG_FOO=bar` will work the -same. However, please note that inside [`scripts`](/using-npm/scripts) -npm will set its own environment variables and Node will prefer -those lowercase versions over any uppercase ones that you might set. -For details see [this issue](https://github.com/npm/npm/issues/14528). - -Notice that you need to use underscores instead of dashes, so `--allow-same-version` -would become `npm_config_allow_same_version=true`. - -#### npmrc Files - -The four relevant files are: - -* per-project configuration file (`/path/to/my/project/.npmrc`) -* per-user configuration file (defaults to `$HOME/.npmrc`; configurable via CLI - option `--userconfig` or environment variable `$NPM_CONFIG_USERCONFIG`) -* global configuration file (defaults to `$PREFIX/etc/npmrc`; configurable via - CLI option `--globalconfig` or environment variable `$NPM_CONFIG_GLOBALCONFIG`) -* npm's built-in configuration file (`/path/to/npm/npmrc`) - -See [npmrc](/configuring-npm/npmrc) for more details. - -#### Default Configs - -Run `npm config ls -l` to see a set of configuration parameters that are -internal to npm, and are defaults if nothing else is specified. - -### Shorthands and Other CLI Niceties - -The following shorthands are parsed on the command-line: - -<!-- AUTOGENERATED CONFIG SHORTHANDS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -* `-a`: `--all` -* `--enjoy-by`: `--before` -* `-c`: `--call` -* `--desc`: `--description` -* `-f`: `--force` -* `-g`: `--global` -* `-L`: `--location` -* `-d`: `--loglevel info` -* `-s`: `--loglevel silent` -* `--silent`: `--loglevel silent` -* `--ddd`: `--loglevel silly` -* `--dd`: `--loglevel verbose` -* `--verbose`: `--loglevel verbose` -* `-q`: `--loglevel warn` -* `--quiet`: `--loglevel warn` -* `-l`: `--long` -* `-m`: `--message` -* `--local`: `--no-global` -* `-n`: `--no-yes` -* `--no`: `--no-yes` -* `-p`: `--parseable` -* `--porcelain`: `--parseable` -* `-C`: `--prefix` -* `--readonly`: `--read-only` -* `--reg`: `--registry` -* `-S`: `--save` -* `-B`: `--save-bundle` -* `-D`: `--save-dev` -* `-E`: `--save-exact` -* `-O`: `--save-optional` -* `-P`: `--save-prod` -* `-?`: `--usage` -* `-h`: `--usage` -* `-H`: `--usage` -* `--help`: `--usage` -* `-v`: `--version` -* `-w`: `--workspace` -* `--ws`: `--workspaces` -* `-y`: `--yes` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -<!-- AUTOGENERATED CONFIG SHORTHANDS END --> - -If the specified configuration param resolves unambiguously to a known -configuration parameter, then it is expanded to that configuration -parameter. For example: - -```bash -npm ls --par -# same as: -npm ls --parseable -``` - -If multiple single-character shorthands are strung together, and the -resulting combination is unambiguously not some other configuration -param, then it is expanded to its various component pieces. For -example: - -```bash -npm ls -gpld -# same as: -npm ls --global --parseable --long --loglevel info -``` - -### Config Settings - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `_auth` - -* Default: null -* Type: null or String - -A basic-auth string to use when authenticating against the npm registry. - -Warning: This should generally not be set via a command-line option. It is -safer to use a registry-provided authentication bearer token stored in the -~/.npmrc file by running `npm login`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `access` - -* Default: 'restricted' for scoped packages, 'public' for unscoped packages -* Type: null, "restricted", or "public" - -When publishing scoped packages, the access level defaults to `restricted`. -If you want your scoped package to be publicly viewable (and installable) -set `--access=public`. The only valid values for `access` are `public` and -`restricted`. Unscoped packages _always_ have an access level of `public`. - -Note: Using the `--access` flag on the `npm publish` command will only set -the package access level on the initial publish of the package. Any -subsequent `npm publish` commands using the `--access` flag will not have an -effect to the access level. To make changes to the access level after the -initial publish use `npm access`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `all` - -* Default: false -* Type: Boolean - -When running `npm outdated` and `npm ls`, setting `--all` will show all -outdated or installed packages, rather than only those directly depended -upon by the current project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `allow-same-version` - -* Default: false -* Type: Boolean - -Prevents throwing an error when `npm version` is used to set the new version -to the same value as the current version. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `audit` - -* Default: true -* Type: Boolean - -When "true" submit audit reports alongside the current npm command to the -default registry and all registries configured for scopes. See the -documentation for [`npm audit`](/commands/npm-audit) for details on what is -submitted. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `audit-level` - -* Default: null -* Type: null, "info", "low", "moderate", "high", "critical", or "none" - -The minimum level of vulnerability for `npm audit` to exit with a non-zero -exit code. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `before` - -* Default: null -* Type: null or Date - -If passed to `npm install`, will rebuild the npm tree such that only -versions that were available **on or before** the `--before` time get -installed. If there's no versions available for the current set of direct -dependencies, the command will error. - -If the requested version is a `dist-tag` and the given tag does not pass the -`--before` filter, the most recent version less than or equal to that tag -will be used. For example, `foo@latest` might install `foo@1.2` even though -`latest` is `2.0`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `bin-links` - -* Default: true -* Type: Boolean - -Tells npm to create symlinks (or `.cmd` shims on Windows) for package -executables. - -Set to false to have it not do this. This can be used to work around the -fact that some file systems don't support symlinks, even on ostensibly Unix -systems. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `browser` - -* Default: OS X: `"open"`, Windows: `"start"`, Others: `"xdg-open"` -* Type: null, Boolean, or String - -The browser that is called by npm commands to open websites. - -Set to `false` to suppress browser behavior and instead print urls to -terminal. - -Set to `true` to use default system URL opener. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ca` - -* Default: null -* Type: null or String (can be set multiple times) - -The Certificate Authority signing certificate that is trusted for SSL -connections to the registry. Values should be in PEM format (Windows calls -it "Base-64 encoded X.509 (.CER)") with newlines replaced by the string -"\n". For example: - -```ini -ca="-----BEGIN CERTIFICATE-----\nXXXX\nXXXX\n-----END CERTIFICATE-----" -``` - -Set to `null` to only allow "known" registrars, or to a specific CA cert to -trust only that specific signing authority. - -Multiple CAs can be trusted by specifying an array of certificates: - -```ini -ca[]="..." -ca[]="..." -``` - -See also the `strict-ssl` config. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `cache` - -* Default: Windows: `%LocalAppData%\npm-cache`, Posix: `~/.npm` -* Type: Path - -The location of npm's cache directory. See [`npm -cache`](/commands/npm-cache) - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `cafile` - -* Default: null -* Type: Path - -A path to a file containing one or multiple Certificate Authority signing -certificates. Similar to the `ca` setting, but allows for multiple CA's, as -well as for the CA information to be stored in a file on disk. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `call` - -* Default: "" -* Type: String - -Optional companion option for `npm exec`, `npx` that allows for specifying a -custom command to be run along with the installed packages. - -```bash -npm exec --package yo --package generator-node --call "yo node" -``` - - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `cert` - -* Default: null -* Type: null or String - -A client certificate to pass when accessing the registry. Values should be -in PEM format (Windows calls it "Base-64 encoded X.509 (.CER)") with -newlines replaced by the string "\n". For example: - -```ini -cert="-----BEGIN CERTIFICATE-----\nXXXX\nXXXX\n-----END CERTIFICATE-----" -``` - -It is _not_ the path to a certificate file (and there is no "certfile" -option). - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ci-name` - -* Default: The name of the current CI system, or `null` when not on a known CI - platform. -* Type: null or String - -The name of a continuous integration system. If not set explicitly, npm will -detect the current CI environment using the -[`@npmcli/ci-detect`](http://npm.im/@npmcli/ci-detect) module. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `cidr` - -* Default: null -* Type: null or String (can be set multiple times) - -This is a list of CIDR address to be used when configuring limited access -tokens with the `npm token create` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `color` - -* Default: true unless the NO_COLOR environ is set to something other than '0' -* Type: "always" or Boolean - -If false, never shows colors. If `"always"` then always shows colors. If -true, then only prints color codes for tty file descriptors. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `commit-hooks` - -* Default: true -* Type: Boolean - -Run git commit hooks when using the `npm version` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `depth` - -* Default: `Infinity` if `--all` is set, otherwise `1` -* Type: null or Number - -The depth to go when recursing packages for `npm ls`. - -If not set, `npm ls` will show only the immediate dependencies of the root -project. If `--all` is set, then npm will show all dependencies by default. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `description` - -* Default: true -* Type: Boolean - -Show the description in `npm search` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff` - -* Default: -* Type: String (can be set multiple times) - -Define arguments to compare in `npm diff`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-dst-prefix` - -* Default: "b/" -* Type: String - -Destination prefix to be used in `npm diff` output. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-ignore-all-space` - -* Default: false -* Type: Boolean - -Ignore whitespace when comparing lines in `npm diff`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-name-only` - -* Default: false -* Type: Boolean - -Prints only filenames when using `npm diff`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-no-prefix` - -* Default: false -* Type: Boolean - -Do not show any source or destination prefix in `npm diff` output. - -Note: this causes `npm diff` to ignore the `--diff-src-prefix` and -`--diff-dst-prefix` configs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-src-prefix` - -* Default: "a/" -* Type: String - -Source prefix to be used in `npm diff` output. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-text` - -* Default: false -* Type: Boolean - -Treat all files as text in `npm diff`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-unified` - -* Default: 3 -* Type: Number - -The number of lines of context to print in `npm diff`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `dry-run` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, `install`, `update`, -`dedupe`, `uninstall`, as well as `pack` and `publish`. - -Note: This is NOT honored by other network related commands, eg `dist-tags`, -`owner`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `editor` - -* Default: The EDITOR or VISUAL environment variables, or 'notepad.exe' on - Windows, or 'vim' on Unix systems -* Type: String - -The command to run for `npm edit` and `npm config edit`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `engine-strict` - -* Default: false -* Type: Boolean - -If set to true, then npm will stubbornly refuse to install (or even consider -installing) any package that claims to not be compatible with the current -Node.js version. - -This can be overridden by setting the `--force` flag. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fetch-retries` - -* Default: 2 -* Type: Number - -The "retries" config for the `retry` module to use when fetching packages -from the registry. - -npm will retry idempotent read requests to the registry in the case of -network failures or 5xx HTTP errors. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fetch-retry-factor` - -* Default: 10 -* Type: Number - -The "factor" config for the `retry` module to use when fetching packages. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fetch-retry-maxtimeout` - -* Default: 60000 (1 minute) -* Type: Number - -The "maxTimeout" config for the `retry` module to use when fetching -packages. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fetch-retry-mintimeout` - -* Default: 10000 (10 seconds) -* Type: Number - -The "minTimeout" config for the `retry` module to use when fetching -packages. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fetch-timeout` - -* Default: 300000 (5 minutes) -* Type: Number - -The maximum amount of time to wait for HTTP requests to complete. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `force` - -* Default: false -* Type: Boolean - -Removes various protections against unfortunate side effects, common -mistakes, unnecessary performance degradation, and malicious input. - -* Allow clobbering non-npm files in global installs. -* Allow the `npm version` command to work on an unclean git repository. -* Allow deleting the cache folder with `npm cache clean`. -* Allow installing packages that have an `engines` declaration requiring a - different version of npm. -* Allow installing packages that have an `engines` declaration requiring a - different version of `node`, even if `--engine-strict` is enabled. -* Allow `npm audit fix` to install modules outside your stated dependency - range (including SemVer-major changes). -* Allow unpublishing all versions of a published package. -* Allow conflicting peerDependencies to be installed in the root project. -* Implicitly set `--yes` during `npm init`. -* Allow clobbering existing values in `npm pkg` - -If you don't have a clear idea of what you want to do, it is strongly -recommended that you do not use this option! - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `foreground-scripts` - -* Default: false -* Type: Boolean - -Run all build scripts (ie, `preinstall`, `install`, and `postinstall`) -scripts for installed packages in the foreground process, sharing standard -input, output, and error with the main npm process. - -Note that this will generally make installs run slower, and be much noisier, -but can be useful for debugging. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `format-package-lock` - -* Default: true -* Type: Boolean - -Format `package-lock.json` or `npm-shrinkwrap.json` as a human readable -file. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fund` - -* Default: true -* Type: Boolean - -When "true" displays the message at the end of each `npm install` -acknowledging the number of dependencies looking for funding. See [`npm -fund`](/commands/npm-fund) for details. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `git` - -* Default: "git" -* Type: String - -The command to use for git commands. If git is installed on the computer, -but is not in the `PATH`, then set this to the full path to the git binary. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `git-tag-version` - -* Default: true -* Type: Boolean - -Tag the commit when using the `npm version` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global-style` - -* Default: false -* Type: Boolean - -Causes npm to install the package into your local `node_modules` folder with -the same layout it uses with the global `node_modules` folder. Only your -direct dependencies will show in `node_modules` and everything they depend -on will be flattened in their `node_modules` folders. This obviously will -eliminate some deduping. If used with `legacy-bundling`, `legacy-bundling` -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `globalconfig` - -* Default: The global --prefix setting plus 'etc/npmrc'. For example, - '/usr/local/etc/npmrc' -* Type: Path - -The config file to read for global config options. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `heading` - -* Default: "npm" -* Type: String - -The string that starts all the debugging log output. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `https-proxy` - -* Default: null -* Type: null or URL - -A proxy to use for outgoing https requests. If the `HTTPS_PROXY` or -`https_proxy` or `HTTP_PROXY` or `http_proxy` environment variables are set, -proxy settings will be honored by the underlying `make-fetch-happen` -library. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `if-present` - -* 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 -running scripts that may only apply for some builds in an otherwise generic -CI setup. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include` - -* Default: -* Type: "prod", "dev", "optional", or "peer" (can be set multiple times) - -Option that allows for defining which types of dependencies to install. - -This is the inverse of `--omit=<type>`. - -Dependency types specified in `--include` will not be omitted, regardless of -the order in which omit/include are specified on the command-line. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-staged` - -* Default: false -* Type: Boolean - -Allow installing "staged" published packages, as defined by [npm RFC PR -#92](https://github.com/npm/rfcs/pull/92). - -This is experimental, and not implemented by the npm public registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init-author-email` - -* Default: "" -* Type: String - -The value `npm init` should use by default for the package author's email. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init-author-name` - -* Default: "" -* Type: String - -The value `npm init` should use by default for the package author's name. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init-author-url` - -* Default: "" -* Type: "" or URL - -The value `npm init` should use by default for the package author's -homepage. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init-license` - -* Default: "ISC" -* Type: String - -The value `npm init` should use by default for the package license. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init-module` - -* Default: "~/.npm-init.js" -* Type: Path - -A module that will be loaded by the `npm init` command. See the -documentation for the -[init-package-json](https://github.com/npm/init-package-json) module for -more information, or [npm init](/commands/npm-init). - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init-version` - -* Default: "1.0.0" -* Type: SemVer string - -The value that `npm init` should use by default for the package version -number, if not already set in package.json. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `key` - -* Default: null -* Type: null or String - -A client key to pass when accessing the registry. Values should be in PEM -format with newlines replaced by the string "\n". For example: - -```ini -key="-----BEGIN PRIVATE KEY-----\nXXXX\nXXXX\n-----END PRIVATE KEY-----" -``` - -It is _not_ the path to a key file (and there is no "keyfile" option). - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `legacy-bundling` - -* Default: false -* Type: Boolean - -Causes npm to install the package such that versions of npm prior to 1.4, -such as the one included with node 0.8, can install the package. This -eliminates all automatic deduping. If used with `global-style` this option -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `legacy-peer-deps` - -* Default: false -* Type: Boolean - -Causes npm to completely ignore `peerDependencies` when building a package -tree, as in npm versions 3 through 6. - -If a package cannot be installed because of overly strict `peerDependencies` -that collide, it provides a way to move forward resolving the situation. - -This differs from `--omit=peer`, in that `--omit=peer` will avoid unpacking -`peerDependencies` on disk, but will still design a tree such that -`peerDependencies` _could_ be unpacked in a correct place. - -Use of `legacy-peer-deps` is not recommended, as it will not enforce the -`peerDependencies` contract that meta-dependencies may rely on. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `link` - -* Default: false -* Type: Boolean - -Used with `npm ls`, limiting output to only those packages that are linked. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `local-address` - -* Default: null -* Type: IP Address - -The IP address of the local interface to use when making connections to the -npm registry. Must be IPv4 in versions of Node prior to 0.12. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `location` - -* Default: "user" unless `--global` is passed, which will also set this value - to "global" -* Type: "global", "user", or "project" - -When passed to `npm config` this refers to which config file to use. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `lockfile-version` - -* Default: Version 2 if no lockfile or current lockfile version less than or - equal to 2, otherwise maintain current lockfile version -* Type: null, 1, 2, 3, "1", "2", or "3" - -Set the lockfile format version to be used in package-lock.json and -npm-shrinkwrap-json files. Possible options are: - -1: The lockfile version used by npm versions 5 and 6. Lacks some data that -is used during the install, resulting in slower and possibly less -deterministic installs. Prevents lockfile churn when interoperating with -older npm versions. - -2: The default lockfile version used by npm version 7. Includes both the -version 1 lockfile data and version 3 lockfile data, for maximum determinism -and interoperability, at the expense of more bytes on disk. - -3: Only the new lockfile information introduced in npm version 7. Smaller on -disk than lockfile version 2, but not interoperable with older npm versions. -Ideal if all users are on npm version 7 and higher. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `loglevel` - -* Default: "notice" -* Type: "silent", "error", "warn", "notice", "http", "timing", "info", - "verbose", or "silly" - -What level of logs to report. All logs are written to a debug log, with the -path to that file printed if the execution of a command fails. - -Any logs of a higher level than the setting are shown. The default is -"notice". - -See also the `foreground-scripts` config. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `logs-max` - -* Default: 10 -* Type: Number - -The maximum number of log files to store. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `long` - -* Default: false -* Type: Boolean - -Show extended information in `ls`, `search`, and `help-search`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `maxsockets` - -* Default: 15 -* Type: Number - -The maximum number of connections to use per origin (protocol/host/port -combination). - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `message` - -* Default: "%s" -* Type: String - -Commit message which is used by `npm version` when creating version commit. - -Any "%s" in the message will be replaced with the version number. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `node-options` - -* Default: null -* Type: null or String - -Options to pass through to Node.js via the `NODE_OPTIONS` environment -variable. This does not impact how npm itself is executed but it does impact -how lifecycle scripts are called. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `node-version` - -* Default: Node.js `process.version` value -* Type: SemVer string - -The node version to use when checking a package's `engines` setting. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `noproxy` - -* Default: The value of the NO_PROXY environment variable -* Type: String (can be set multiple times) - -Domain extensions that should bypass any proxies. - -Also accepts a comma-delimited string. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `npm-version` - -* Default: Output of `npm --version` -* Type: SemVer string - -The npm version to use when checking a package's `engines` setting. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `offline` - -* Default: false -* Type: Boolean - -Force offline mode: no network requests will be done during install. To -allow the CLI to fill in missing cache data, see `--prefer-offline`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `omit` - -* Default: 'dev' if the `NODE_ENV` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -`package-lock.json` or `npm-shrinkwrap.json` file. They are just not -physically installed on disk. - -If a package type appears in both the `--include` and `--omit` lists, then -it will be included. - -If the resulting omit list includes `'dev'`, then the `NODE_ENV` environment -variable will be set to `'production'` for all lifecycle scripts. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `otp` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with `npm access`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `pack-destination` - -* Default: "." -* Type: String - -Directory in which `npm pack` will save tarballs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `package` - -* Default: -* Type: String (can be set multiple times) - -The package to install for [`npm exec`](/commands/npm-exec) - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `package-lock` - -* Default: true -* Type: Boolean - -If set to false, then ignore `package-lock.json` files when installing. This -will also prevent _writing_ `package-lock.json` if `save` is true. - -When package package-locks are disabled, automatic pruning of extraneous -modules will also be disabled. To remove extraneous modules with -package-locks disabled use `npm prune`. - -This configuration does not affect `npm ci`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `package-lock-only` - -* Default: false -* Type: Boolean - -If set to true, the current operation will only use the `package-lock.json`, -ignoring `node_modules`. - -For `update` this means only the `package-lock.json` will be updated, -instead of checking `node_modules` and downloading dependencies. - -For `list` this means the output will be based on the tree described by the -`package-lock.json`, rather than the contents of `node_modules`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `parseable` - -* Default: false -* Type: Boolean - -Output parseable results from commands that write to standard output. For -`npm search`, this will be tab-separated table format. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `prefer-offline` - -* Default: false -* Type: Boolean - -If true, staleness checks for cached data will be bypassed, but missing data -will be requested from the server. To force full offline mode, use -`--offline`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `prefer-online` - -* Default: false -* Type: Boolean - -If true, staleness checks for cached data will be forced, making the CLI -look for updates immediately even for fresh package data. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `prefix` - -* Default: In global mode, the folder where the node executable is installed. - In local mode, the nearest parent folder containing either a package.json - file or a node_modules folder. -* Type: Path - -The location to install global items. If set on the command line, then it -forces non-global commands to run in the specified folder. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `preid` - -* Default: "" -* Type: String - -The "prerelease identifier" to use as a prefix for the "prerelease" part of -a semver. Like the `rc` in `1.2.0-rc.8`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `progress` - -* Default: `true` unless running in a known CI system -* Type: Boolean - -When set to `true`, npm will display a progress bar during time intensive -operations, if `process.stderr` is a TTY. - -Set to `false` to suppress the progress bar. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `proxy` - -* Default: null -* Type: null, false, or URL - -A proxy to use for outgoing http requests. If the `HTTP_PROXY` or -`http_proxy` environment variables are set, proxy settings will be honored -by the underlying `request` library. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `read-only` - -* Default: false -* Type: Boolean - -This is used to mark a token as unable to publish when configuring limited -access tokens with the `npm token create` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `rebuild-bundle` - -* Default: true -* Type: Boolean - -Rebuild bundled dependencies after installation. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `save` - -* Default: `true` unless when using `npm update` or `npm dedupe` where it - defaults to `false` -* Type: Boolean - -Save installed packages to a `package.json` file as dependencies. - -When used with the `npm rm` command, removes the dependency from -`package.json`. - -Will also prevent writing to `package-lock.json` if set to `false`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `save-bundle` - -* Default: false -* Type: Boolean - -If a package would be saved at install time by the use of `--save`, -`--save-dev`, or `--save-optional`, then also put it in the -`bundleDependencies` list. - -Ignored if `--save-peer` is set, since peerDependencies cannot be bundled. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `save-dev` - -* Default: false -* Type: Boolean - -Save installed packages to a package.json file as `devDependencies`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `save-exact` - -* Default: false -* Type: Boolean - -Dependencies saved to package.json will be configured with an exact version -rather than using npm's default semver range operator. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `save-optional` - -* Default: false -* Type: Boolean - -Save installed packages to a package.json file as `optionalDependencies`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `save-peer` - -* Default: false -* Type: Boolean - -Save installed packages to a package.json file as `peerDependencies` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `save-prefix` - -* Default: "^" -* Type: String - -Configure how versions of packages installed to a package.json file via -`--save` or `--save-dev` get prefixed. - -For example if a package has version `1.2.3`, by default its version is set -to `^1.2.3` which allows minor upgrades for that package, but after `npm -config set save-prefix='~'` it would be set to `~1.2.3` which only allows -patch upgrades. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `save-prod` - -* Default: false -* Type: Boolean - -Save installed packages into `dependencies` specifically. This is useful if -a package already exists in `devDependencies` or `optionalDependencies`, but -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `scope` - -* Default: the scope of the current project, if any, or "" -* Type: String - -Associate an operation with a scope for a scoped registry. - -Useful when logging in to or out of a private registry: - -``` -# log in, linking the scope to the custom registry -npm login --scope=@mycorp --registry=https://registry.mycorp.com - -# log out, removing the link and the auth token -npm logout --scope=@mycorp -``` - -This will cause `@mycorp` to be mapped to the registry for future -installation of packages specified according to the pattern -`@mycorp/package`. - -This will also cause `npm init` to create a scoped package. - -``` -# accept all defaults, and create a package named "@foo/whatever", -# instead of just named "whatever" -npm init --scope=@foo --yes -``` - - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `script-shell` - -* Default: '/bin/sh' on POSIX systems, 'cmd.exe' on Windows -* Type: null or String - -The shell to use for scripts run with the `npm exec`, `npm run` and `npm -init <pkg>` commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `searchexclude` - -* Default: "" -* Type: String - -Space-separated options that limit the results from search. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `searchlimit` - -* Default: 20 -* Type: Number - -Number of items to limit search results to. Will not apply at all to legacy -searches. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `searchopts` - -* Default: "" -* Type: String - -Space-separated options that are always passed to search. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `searchstaleness` - -* Default: 900 -* Type: Number - -The age of the cache, in seconds, before another registry request is made if -using legacy search endpoint. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `shell` - -* Default: SHELL environment variable, or "bash" on Posix, or "cmd.exe" on - Windows -* Type: String - -The shell to run for the `npm explore` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `sign-git-commit` - -* Default: false -* Type: Boolean - -If set to true, then the `npm version` command will commit the new package -version using `-S` to add a signature. - -Note that git requires you to have set up GPG keys in your git configs for -this to work properly. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `sign-git-tag` - -* Default: false -* Type: Boolean - -If set to true, then the `npm version` command will tag the version using -`-s` to add a signature. - -Note that git requires you to have set up GPG keys in your git configs for -this to work properly. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `strict-peer-deps` - -* Default: false -* Type: Boolean - -If set to `true`, and `--legacy-peer-deps` is not set, then _any_ -conflicting `peerDependencies` will be treated as an install failure, even -if npm could reasonably guess the appropriate resolution based on non-peer -dependency relationships. - -By default, conflicting `peerDependencies` deep in the dependency graph will -be resolved using the nearest non-peer dependency specification, even if -doing so will result in some packages receiving a peer dependency outside -the range set in their package's `peerDependencies` object. - -When such and override is performed, a warning is printed, explaining the -conflict and the packages involved. If `--strict-peer-deps` is set, then -this warning is treated as a failure. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `strict-ssl` - -* Default: true -* Type: Boolean - -Whether or not to do SSL key validation when making requests to the registry -via https. - -See also the `ca` config. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `tag` - -* Default: "latest" -* Type: String - -If you ask npm to install a package and don't tell it a specific version, -then it will install the specified tag. - -Also the tag that is added to the package@version specified by the `npm tag` -command, if no explicit tag is given. - -When used by the `npm diff` command, this is the tag used to fetch the -tarball that will be compared with the local files by default. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `tag-version-prefix` - -* Default: "v" -* Type: String - -If set, alters the prefix used when tagging a new version when performing a -version increment using `npm-version`. To remove the prefix altogether, set -it to the empty string: `""`. - -Because other tools may rely on the convention that npm version tags look -like `v1.0.0`, _only use this property if it is absolutely necessary_. In -particular, use care when overriding this setting for public packages. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `timing` - -* Default: false -* Type: Boolean - -If true, writes an `npm-debug` log to `_logs` and timing information to -`_timing.json`, both in your cache, even if the command completes -successfully. `_timing.json` is a newline delimited list of JSON objects. - -You can quickly view it with this [json](https://npm.im/json) command line: -`npm exec -- json -g < ~/.npm/_timing.json`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `umask` - -* Default: 0 -* Type: Octal numeric string in range 0000..0777 (0..511) - -The "umask" value to use when setting the file creation mode on files and -folders. - -Folders and executables are given a mode which is `0o777` masked against -this value. Other files are given a mode which is `0o666` masked against -this value. - -Note that the underlying system will _also_ apply its own umask value to -files and folders that are created, and npm does not circumvent this, but -rather adds the `--umask` config to it. - -Thus, the effective default umask value on most POSIX systems is 0o22, -meaning that folders and executables are created with a mode of 0o755 and -other files are created with a mode of 0o644. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `unicode` - -* Default: false on windows, true on mac/unix systems with a unicode locale, - as defined by the `LC_ALL`, `LC_CTYPE`, or `LANG` environment variables. -* Type: Boolean - -When set to true, npm uses unicode characters in the tree output. When -false, it uses ascii characters instead of unicode glyphs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `update-notifier` - -* Default: true -* Type: Boolean - -Set to false to suppress the update notification when using an older version -of npm than the latest. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `usage` - -* Default: false -* Type: Boolean - -Show short usage output about the command specified. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `user-agent` - -* Default: "npm/{npm-version} node/{node-version} {platform} {arch} - workspaces/{workspaces} {ci}" -* Type: String - -Sets the User-Agent request header. The following fields are replaced with -their actual counterparts: - -* `{npm-version}` - The npm version in use -* `{node-version}` - The Node.js version in use -* `{platform}` - The value of `process.platform` -* `{arch}` - The value of `process.arch` -* `{workspaces}` - Set to `true` if the `workspaces` or `workspace` options - are set. -* `{ci}` - The value of the `ci-name` config, if set, prefixed with `ci/`, or - an empty string if `ci-name` is empty. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `userconfig` - -* Default: "~/.npmrc" -* Type: Path - -The location of user-level configuration settings. - -This may be overridden by the `npm_config_userconfig` environment variable -or the `--userconfig` command line option, but may _not_ be overridden by -settings in the `globalconfig` file. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `version` - -* Default: false -* Type: Boolean - -If true, output the npm version and exit successfully. - -Only relevant when specified explicitly on the command line. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `versions` - -* Default: false -* Type: Boolean - -If true, output the npm version as well as node's `process.versions` map and -the version in the current working directory's `package.json` file if one -exists, and exit successfully. - -Only relevant when specified explicitly on the command line. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `viewer` - -* Default: "man" on Posix, "browser" on Windows -* Type: String - -The program to use to view help content. - -Set to `"browser"` to view html help content in the default web browser. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `which` - -* Default: null -* Type: null or Number - -If there are multiple funding sources, which 1-indexed source URL to open. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `yes` - -* Default: null -* Type: null or Boolean - -Automatically answer "yes" to any prompts that npm might print on the -command line. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `also` - -* Default: null -* Type: null, "dev", or "development" -* DEPRECATED: Please use --include=dev instead. - -When set to `dev` or `development`, this is an alias for `--include=dev`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `auth-type` - -* Default: "legacy" -* Type: "legacy", "sso", "saml", or "oauth" -* DEPRECATED: This method of SSO/SAML/OAuth is deprecated and will be removed - in a future version of npm in favor of web-based login. - -What authentication strategy to use with `adduser`/`login`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `cache-max` - -* Default: Infinity -* Type: Number -* DEPRECATED: This option has been deprecated in favor of `--prefer-online` - -`--cache-max=0` is an alias for `--prefer-online` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `cache-min` - -* Default: 0 -* Type: Number -* DEPRECATED: This option has been deprecated in favor of `--prefer-offline`. - -`--cache-min=9999 (or bigger)` is an alias for `--prefer-offline`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `dev` - -* Default: false -* Type: Boolean -* DEPRECATED: Please use --include=dev instead. - -Alias for `--include=dev`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init.author.email` - -* Default: "" -* Type: String -* DEPRECATED: Use `--init-author-email` instead. - -Alias for `--init-author-email` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init.author.name` - -* Default: "" -* Type: String -* DEPRECATED: Use `--init-author-name` instead. - -Alias for `--init-author-name` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init.author.url` - -* Default: "" -* Type: "" or URL -* DEPRECATED: Use `--init-author-url` instead. - -Alias for `--init-author-url` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init.license` - -* Default: "ISC" -* Type: String -* DEPRECATED: Use `--init-license` instead. - -Alias for `--init-license` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init.module` - -* Default: "~/.npm-init.js" -* Type: Path -* DEPRECATED: Use `--init-module` instead. - -Alias for `--init-module` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `init.version` - -* Default: "1.0.0" -* Type: SemVer string -* DEPRECATED: Use `--init-version` instead. - -Alias for `--init-version` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `only` - -* Default: null -* Type: null, "prod", or "production" -* DEPRECATED: Use `--omit=dev` to omit dev dependencies from the install. - -When set to `prod` or `production`, this is an alias for `--omit=dev`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `optional` - -* Default: null -* Type: null or Boolean -* DEPRECATED: Use `--omit=optional` to exclude optional dependencies, or - `--include=optional` to include them. - -Default value does install optional deps unless otherwise omitted. - -Alias for --include=optional or --omit=optional - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `production` - -* Default: null -* Type: null or Boolean -* DEPRECATED: Use `--omit=dev` instead. - -Alias for `--omit=dev` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `shrinkwrap` - -* Default: true -* Type: Boolean -* DEPRECATED: Use the --package-lock setting instead. - -Alias for --package-lock - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `sso-poll-frequency` - -* Default: 500 -* Type: Number -* DEPRECATED: The --auth-type method of SSO/SAML/OAuth will be removed in a - future version of npm in favor of web-based login. - -When used with SSO-enabled `auth-type`s, configures how regularly the -registry should be polled while the user is completing authentication. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `sso-type` - -* Default: "oauth" -* Type: null, "oauth", or "saml" -* DEPRECATED: The --auth-type method of SSO/SAML/OAuth will be removed in a - future version of npm in favor of web-based login. - -If `--auth-type=sso`, the type of SSO type to use. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `tmp` - -* Default: The value returned by the Node.js `os.tmpdir()` method - <https://nodejs.org/api/os.html#os_os_tmpdir> -* Type: Path -* DEPRECATED: This setting is no longer used. npm stores temporary files in a - special location in the cache, and they are managed by - [`cacache`](http://npm.im/cacache). - -Historically, the location where temporary files were stored. No longer -relevant. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> - -### See also - -* [npm config](/commands/npm-config) -* [npmrc](/configuring-npm/npmrc) -* [npm scripts](/using-npm/scripts) -* [npm folders](/configuring-npm/folders) -* [npm](/commands/npm) diff --git a/docs/content/using-npm/logging.md b/docs/content/using-npm/logging.md deleted file mode 100644 index b7c5e89..0000000 --- a/docs/content/using-npm/logging.md +++ /dev/null @@ -1,60 +0,0 @@ ---- -title: Logging -section: 7 -description: Why, What & How we Log ---- - -### Description - -The `npm` CLI has various mechanisms for showing different levels of information back to end-users for certain commands, configurations & environments. - -### Setting Log Levels - -#### `loglevel` - -`loglevel` is a global argument/config that can be set to determine the type of information to be displayed. - -The default value of `loglevel` is `"notice"` but there are several levels/types of logs available, including: - -- `"silent"` -- `"error"` -- `"warn"` -- `"notice"` -- `"http"` -- `"timing"` -- `"info"` -- `"verbose"` -- `"silly"` - -All logs pertaining to a level proceeding the current setting will be shown. - -All logs are written to a debug log, with the path to that file printed if the execution of a command fails. - -##### Aliases - -The log levels listed above have various corresponding aliases, including: - -- `-d`: `--loglevel info` -- `--dd`: `--loglevel verbose` -- `--verbose`: `--loglevel verbose` -- `--ddd`: `--loglevel silly` -- `-q`: `--loglevel warn` -- `--quiet`: `--loglevel warn` -- `-s`: `--loglevel silent` -- `--silent`: `--loglevel silent` - -#### `foreground-scripts` - -The `npm` CLI began hiding the output of lifecycle scripts for `npm install` as of `v7`. Notably, this means you will not see logs/output from packages that may be using "install scripts" to display information back to you or from your own project's scripts defined in `package.json`. If you'd like to change this behavior & log this output you can set `foreground-scripts` to `true`. - -### Registry Response Headers - -#### `npm-notice` - -The `npm` CLI reads from & logs any `npm-notice` headers that are returned from the configured registry. This mechanism can be used by third-party registries to provide useful information when network-dependent requests occur. - -This header is not cached, and will not be logged if the request is served from the cache. - -### See also - -* [config](/using-npm/config) diff --git a/docs/dockhand.js b/docs/dockhand.js deleted file mode 100644 index 77d3d63..0000000 --- a/docs/dockhand.js +++ /dev/null @@ -1,333 +0,0 @@ -#!/usr/bin/env node - -const path = require('path') -const fs = require('fs') -const yaml = require('yaml') -const cmark = require('cmark-gfm') -const mdx = require('@mdx-js/mdx') -const mkdirp = require('mkdirp') -const jsdom = require('jsdom') -const npm = require('../lib/npm.js') - -const config = require('./config.json') - -const docsRoot = __dirname -const inputRoot = path.join(docsRoot, 'content') -const outputRoot = path.join(docsRoot, 'output') - -const template = fs.readFileSync('template.html').toString() - -const run = async function () { - try { - const navPaths = await getNavigationPaths() - const fsPaths = await renderFilesystemPaths() - - if (!ensureNavigationComplete(navPaths, fsPaths)) { - process.exit(1) - } - } catch (error) { - console.error(error) - } -} - -run() - -function ensureNavigationComplete (navPaths, fsPaths) { - const unmatchedNav = {} - const unmatchedFs = {} - - for (const navPath of navPaths) { - unmatchedNav[navPath] = true - } - - for (let fsPath of fsPaths) { - fsPath = '/' + fsPath.replace(/\.md$/, '') - - if (unmatchedNav[fsPath]) { - delete unmatchedNav[fsPath] - } else { - unmatchedFs[fsPath] = true - } - } - - const missingNav = Object.keys(unmatchedNav).sort() - const missingFs = Object.keys(unmatchedFs).sort() - - if (missingNav.length > 0 || missingFs.length > 0) { - let message = 'Error: documentation navigation (nav.yml) does not match filesystem.\n' - - if (missingNav.length > 0) { - message += '\nThe following path(s) exist on disk but are not present in nav.yml:\n\n' - - for (const nav of missingNav) { - message += ` ${nav}\n` - } - } - - if (missingNav.length > 0 && missingFs.length > 0) { - message += '\nThe following path(s) exist in nav.yml but are not present on disk:\n\n' - - for (const fs of missingFs) { - message += ` ${fs}\n` - } - } - - message += '\nUpdate nav.yml to ensure that all files are listed in the appropriate place.' - - console.error(message) - - return false - } - - return true -} - -function getNavigationPaths () { - const navFilename = path.join(docsRoot, 'nav.yml') - const nav = yaml.parse(fs.readFileSync(navFilename).toString(), 'utf8') - - return walkNavigation(nav) -} - -function walkNavigation (entries) { - const paths = [] - - for (const entry of entries) { - if (entry.children) { - paths.push(...walkNavigation(entry.children)) - } else { - paths.push(entry.url) - } - } - - return paths -} - -async function renderFilesystemPaths () { - return await walkFilesystem(inputRoot) -} - -async function walkFilesystem (root, dirRelative) { - const paths = [] - - const dirPath = dirRelative ? path.join(root, dirRelative) : root - const children = fs.readdirSync(dirPath) - - for (const childFilename of children) { - const childRelative = dirRelative ? path.join(dirRelative, childFilename) : childFilename - const childPath = path.join(root, childRelative) - - if (fs.lstatSync(childPath).isDirectory()) { - paths.push(...(await walkFilesystem(root, childRelative))) - } else { - await renderFile(childRelative) - paths.push(childRelative) - } - } - - return paths -} - -async function renderFile (childPath) { - const inputPath = path.join(inputRoot, childPath) - - if (!inputPath.match(/\.md$/)) { - console.log(`warning: unknown file type ${inputPath}, ignored`) - return - } - - const outputPath = path.join(outputRoot, childPath.replace(/\.md$/, '.html')) - - let md = fs.readFileSync(inputPath).toString() - let frontmatter = {} - - // Take the leading frontmatter out of the markdown - md = md.replace(/^---\n([\s\S]+)\n---\n/, (header, fm) => { - frontmatter = yaml.parse(fm, 'utf8') - return '' - }) - - // Replace any tokens in the source - md = md.replace(/@VERSION@/, npm.version) - - // Render the markdown into an HTML snippet using a GFM renderer. - const content = cmark.renderHtmlSync(md, { - smart: false, - githubPreLang: true, - strikethroughDoubleTilde: true, - unsafe: false, - extensions: { - table: true, - strikethrough: true, - tagfilter: true, - autolink: true, - }, - }) - - // Test that mdx can parse this markdown file. We don't actually - // use the output, it's just to ensure that the upstream docs - // site (docs.npmjs.com) can parse it when this file gets there. - try { - await mdx(md, { skipExport: true }) - } catch (error) { - throw new MarkdownError(childPath, error) - } - - // Inject this data into the template, using a mustache-like - // replacement scheme. - const html = template.replace(/{{\s*([\w.]+)\s*}}/g, (token, key) => { - switch (key) { - case 'content': - return `<div id="_content">${content}</div>` - case 'path': - return childPath - case 'url_path': - return encodeURI(childPath) - - case 'toc': - return '<div id="_table_of_contents"></div>' - - case 'title': - case 'section': - case 'description': - return frontmatter[key] - - case 'config.github_repo': - case 'config.github_branch': - case 'config.github_path': - return config[key.replace(/^config\./, '')] - - default: - console.log(`warning: unknown token '${token}' in ${inputPath}`) - return '' - } - }) - - const dom = new jsdom.JSDOM(html) - const document = dom.window.document - - // Rewrite relative URLs in links and image sources to be relative to - // this file; this is for supporting `file://` links. HTML pages need - // suffix appended. - const links = [ - { tag: 'a', attr: 'href', suffix: '.html' }, - { tag: 'img', attr: 'src' }, - ] - - for (const linktype of links) { - for (const tag of document.querySelectorAll(linktype.tag)) { - let url = tag.getAttribute(linktype.attr) - - if (url.startsWith('/')) { - const childDepth = childPath.split('/').length - 1 - const prefix = childDepth > 0 ? '../'.repeat(childDepth) : './' - - url = url.replace(/^\//, prefix) - - if (linktype.suffix) { - url += linktype.suffix - } - - tag.setAttribute(linktype.attr, url) - } - } - } - - // Give headers a unique id so that they can be linked within the doc - const headerIds = [] - for (const header of document.querySelectorAll('h1, h2, h3, h4, h5, h6')) { - if (header.getAttribute('id')) { - headerIds.push(header.getAttribute('id')) - continue - } - - const headerText = header.textContent - .replace(/[A-Z]/g, x => x.toLowerCase()) - .replace(/ /g, '-') - .replace(/[^a-z0-9-]/g, '') - let headerId = headerText - let headerIncrement = 1 - - while (document.getElementById(headerId) !== null) { - headerId = headerText + ++headerIncrement - } - - headerIds.push(headerId) - header.setAttribute('id', headerId) - } - - // Walk the dom and build a table of contents - const toc = document.getElementById('_table_of_contents') - - if (toc) { - toc.appendChild(generateTableOfContents(document)) - } - - // Write the final output - const output = dom.serialize() - - mkdirp.sync(path.dirname(outputPath)) - fs.writeFileSync(outputPath, output) -} - -function generateTableOfContents (document) { - const headers = [] - walkHeaders(document.getElementById('_content'), headers) - - // The nesting depth of headers are not necessarily the header level. - // (eg, h1 > h3 > h5 is a depth of three even though there's an h5.) - const hierarchy = [] - for (const header of headers) { - const level = headerLevel(header) - - while (hierarchy.length && hierarchy[hierarchy.length - 1].headerLevel > level) { - hierarchy.pop() - } - - if (!hierarchy.length || hierarchy[hierarchy.length - 1].headerLevel < level) { - const newList = document.createElement('ul') - newList.headerLevel = level - - if (hierarchy.length) { - hierarchy[hierarchy.length - 1].appendChild(newList) - } - - hierarchy.push(newList) - } - - const element = document.createElement('li') - - const link = document.createElement('a') - link.setAttribute('href', `#${header.getAttribute('id')}`) - link.innerHTML = header.innerHTML - element.appendChild(link) - - const list = hierarchy[hierarchy.length - 1] - list.appendChild(element) - } - - return hierarchy[0] -} - -function walkHeaders (element, headers) { - for (const child of element.childNodes) { - if (headerLevel(child)) { - headers.push(child) - } - - walkHeaders(child, headers) - } -} - -function headerLevel (node) { - const level = node.tagName ? node.tagName.match(/^[Hh]([123456])$/) : null - return level ? level[1] : 0 -} - -class MarkdownError extends Error { - constructor (file, inner) { - super(`failed to parse ${file}`) - this.file = file - this.inner = inner - } -} diff --git a/docs/lib/build.js b/docs/lib/build.js new file mode 100644 index 0000000..563b406 --- /dev/null +++ b/docs/lib/build.js @@ -0,0 +1,137 @@ +const { join, dirname, basename, extname, sep, posix } = require('path') +const fs = require('fs/promises') +const ignoreWalk = require('ignore-walk') +const yaml = require('yaml') +const parseFrontMatter = require('front-matter') + +const checkNav = require('./check-nav.js') +const { DOC_EXT, ...transform } = require('./index.js') + +const mkDirs = async (paths) => { + const uniqDirs = [...new Set(paths.map((p) => dirname(p)))] + return Promise.all(uniqDirs.map((d) => fs.mkdir(d, { recursive: true }))) +} + +const rmAll = (...dirs) => Promise.all(dirs.map((d) => fs.rm(d, { recursive: true, force: true }))) +const readDocs = (path) => ignoreWalk({ path }).then(ps => ps.filter(p => extname(p) === DOC_EXT)) +const readMd = (path) => fs.readFile(path, 'utf-8').then(parseFrontMatter) +const readHtml = (path) => fs.readFile(path, 'utf-8') +const readYaml = (path) => fs.readFile(path, 'utf-8').then(yaml.parse) +const makeTransforms = (...args) => (src, trs) => trs.reduce((acc, tr) => tr(acc, ...args), src) + +const pAll = async (obj) => { + const entries = Object.entries(obj) + const results = await Promise.all(entries.map(e => e[1])) + return results.reduce((acc, res, index) => { + acc[entries[index][0]] = res + return acc + }, {}) +} + +const run = async ({ content, template, nav, man, html, md }) => { + await rmAll(man, html, md) + const [contentPaths, navFile, options] = await Promise.all([ + readDocs(content), + readYaml(nav), + pAll({ + template: readHtml(template), + // these deps are esm only so we have to import them once we + // are inside our main async function + unified: import('unified').then(r => r.unified), + remarkParse: import('remark-parse').then(r => r.default), + remarkGfm: import('remark-gfm').then(r => r.default), + remarkRehype: import('remark-rehype').then(r => r.default), + rehypeStringify: import('rehype-stringify').then(r => r.default), + remarkMan: import('remark-man').then(r => r.default), + }), + ]) + + const sources = await Promise.all(contentPaths.map(async (childPath) => { + const name = basename(childPath, DOC_EXT) + const fullPath = join(content, childPath) + const fullName = join(dirname(childPath), name).split(sep).join(posix.sep) + + const { body, attributes: data, frontmatter } = await readMd(fullPath) + + return { + body, + data, + frontmatter, + name, + fullName, + childPath, + } + })) + + const entriesByType = sources.reduce((acc, { + body, + data, + frontmatter, + name, + childPath, + fullName, + }) => { + const applyTransforms = makeTransforms({ + path: childPath, + data: { + ...data, + github_repo: 'npm/cli', + github_branch: 'latest', + github_path: 'docs/content', + }, + frontmatter, + ...options, + }) + + const transformedSrc = applyTransforms(body, [ + transform.version, + ...(fullName.startsWith('commands/') + ? [transform.usage, transform.params] + : []), + ...(fullName === 'using-npm/config' + ? [transform.shorthands, transform.config] + : []), + ]) + + if (data.section) { + const manSrc = applyTransforms(transformedSrc, [ + transform.helpLinks, + transform.man, + ]) + const manPaths = [ + name, + fullName === 'configuring-npm/package-json' && 'npm-json', + fullName === 'configuring-npm/folders' && 'npm-global', + ].filter(Boolean).map(p => applyTransforms(p, [transform.manPath])) + + acc.man.push(...manPaths.map((manPath) => ({ + path: manPath, + fullPath: join(man, manPath), + src: manSrc, + }))) + } + + acc.html.push({ + path: `${fullName}.html`, + fullPath: join(html, `${fullName}.html`), + src: applyTransforms(transformedSrc, [transform.html]), + }) + + acc.md.push({ + path: childPath, + fullPath: join(md, childPath), + src: applyTransforms(transformedSrc, [transform.md]), + }) + return acc + }, { man: [], html: [], md: [] }) + + const docEntries = Object.values(entriesByType).flat() + await mkDirs(docEntries.map(({ fullPath }) => fullPath)) + await Promise.all(docEntries.map(({ fullPath, src }) => fs.writeFile(fullPath, src, 'utf-8'))) + + checkNav(navFile, entriesByType.md.map(({ path }) => path), DOC_EXT) + + return docEntries +} + +module.exports = run diff --git a/docs/lib/check-nav.js b/docs/lib/check-nav.js new file mode 100644 index 0000000..ac2c010 --- /dev/null +++ b/docs/lib/check-nav.js @@ -0,0 +1,62 @@ +const { basename, join, dirname, sep, posix } = require('path') + +function ensureNavigationComplete (nav, fsPaths, ext) { + const navPaths = getNavigationPaths(nav) + const unmatchedNav = {} + const unmatchedFs = {} + + for (const navPath of navPaths) { + // every nav path starts as an unmatched fs path + unmatchedFs[navPath] = true + } + + for (const path of fsPaths) { + const key = posix.sep + join(dirname(path), basename(path, ext)).split(sep).join(posix.sep) + // for each fs path, if it exists in the nav we + // unmark it as unmatched on the filesystem. + // otherwise its unmarked in the nav + if (unmatchedFs[key]) { + delete unmatchedFs[key] + } else { + unmatchedNav[key] = true + } + } + + const toKeys = (v) => Object.keys(v).sort().map((p) => p.split(posix.sep).join(sep)) + const missingNav = toKeys(unmatchedNav) + const missingFs = toKeys(unmatchedFs) + + const errors = [] + + if (missingNav.length) { + errors.push('The following path(s) exist on disk but are not present in nav.yml:') + errors.push(...missingNav.map(n => ` ${n}`)) + } + + if (missingFs.length) { + errors.push('The following path(s) exist in nav.yml but are not present on disk:') + errors.push(...missingFs.map(n => ` ${n}`)) + } + + if (errors.length) { + errors.unshift('Documentation navigation (nav.yml) does not match filesystem.') + errors.push('Update nav.yml to ensure that all files are listed in the appropriate place.') + throw new Error(errors.join('\n')) + } +} + +function getNavigationPaths (entries) { + const paths = [] + + for (const entry of entries) { + if (entry.children) { + paths.push(...getNavigationPaths(entry.children)) + } else { + paths.push(entry.url) + } + } + + return paths +} + +module.exports = ensureNavigationComplete diff --git a/docs/content/commands/npm-access.md b/docs/lib/content/commands/npm-access.md similarity index 62% rename from docs/content/commands/npm-access.md rename to docs/lib/content/commands/npm-access.md index 1f661c9..819fe9a 100644 --- a/docs/content/commands/npm-access.md +++ b/docs/lib/content/commands/npm-access.md @@ -6,20 +6,7 @@ description: Set access level on published packages ### Synopsis -```bash -npm access public [<package>] -npm access restricted [<package>] - -npm access grant <read-only|read-write> <scope:team> [<package>] -npm access revoke <scope:team> [<package>] - -npm access 2fa-required [<package>] -npm access 2fa-not-required [<package>] - -npm access ls-packages [<user>|<scope>|<scope:team>] -npm access ls-collaborators [<package> [<user>]] -npm access edit [<package>] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description @@ -29,29 +16,28 @@ For all of the subcommands, `npm access` will perform actions on the packages in the current working directory if no package name is passed to the subcommand. -* public / restricted: +* public / restricted (deprecated): Set a package to be either publicly accessible or restricted. -* grant / revoke: +* grant / revoke (deprecated): Add or remove the ability of users and teams to have read-only or read-write access to a package. -* 2fa-required / 2fa-not-required: +* 2fa-required / 2fa-not-required (deprecated): Configure whether a package requires that anyone publishing it have two-factor authentication enabled on their account. -* ls-packages: +* ls-packages (deprecated): Show all of the packages a user or a team is able to access, along with the access level, except for read-only public packages (it won't print the whole registry listing) -* ls-collaborators: +* ls-collaborators (deprecated): Show all of the access privileges for a package. Will only show permissions for packages to which you have at least read access. If `<user>` is passed in, the list is filtered only to teams _that_ user happens to belong to. -* edit: - Set the access privileges for a package at once using `$EDITOR`. +* edit (not implemented) ### Details @@ -83,34 +69,7 @@ Management of teams and team memberships is done with the `npm team` command. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `otp` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with `npm access`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/lib/content/commands/npm-adduser.md b/docs/lib/content/commands/npm-adduser.md new file mode 100644 index 0000000..fa957cb --- /dev/null +++ b/docs/lib/content/commands/npm-adduser.md @@ -0,0 +1,34 @@ +--- +title: npm-adduser +section: 1 +description: Add a registry user account +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +Note: This command is unaware of workspaces. + +### Description + +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 using `legacy` for your `auth-type`, the username, password, and +email are read in from prompts. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm registry](/using-npm/registry) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) +* [npm owner](/commands/npm-owner) +* [npm whoami](/commands/npm-whoami) +* [npm token](/commands/npm-token) +* [npm profile](/commands/npm-profile) diff --git a/docs/content/commands/npm-audit.md b/docs/lib/content/commands/npm-audit.md similarity index 50% rename from docs/content/commands/npm-audit.md rename to docs/lib/content/commands/npm-audit.md index 58c614d..7a39b34 100644 --- a/docs/content/commands/npm-audit.md +++ b/docs/lib/content/commands/npm-audit.md @@ -6,12 +6,7 @@ description: Run a security audit ### Synopsis -```bash -npm audit [--json] [--production] [--audit-level=(low|moderate|high|critical)] -npm audit fix [--force|--package-lock-only|--dry-run|--production|--only=(dev|prod)] - -common options: [--production] [--only=(dev|prod)] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description @@ -35,6 +30,58 @@ vulnerability is found. It may be useful in CI environments to include the will cause the command to fail. This option does not filter the report output, it simply changes the command's failure threshold. +### Audit Signatures + +To ensure the integrity of packages you download from the public npm registry, or any registry that supports signatures, you can verify the registry signatures of downloaded packages using the npm CLI. + +Registry signatures can be verified using the following `audit` command: + +```bash +$ npm audit signatures +``` + +The npm CLI supports registry signatures and signing keys provided by any registry if the following conventions are followed: + +1. Signatures are provided in the package's `packument` in each published version within the `dist` object: + +```json +"dist":{ + "..omitted..": "..omitted..", + "signatures": [{ + "keyid": "SHA256:{{SHA256_PUBLIC_KEY}}", + "sig": "a312b9c3cb4a1b693e8ebac5ee1ca9cc01f2661c14391917dcb111517f72370809..." + }] +} +``` + +See this [example](https://registry.npmjs.org/light-cycle/1.4.3) of a signed package from the public npm registry. + +The `sig` is generated using the following template: `${package.name}@${package.version}:${package.dist.integrity}` and the `keyid` has to match one of the public signing keys below. + +2. Public signing keys are provided at `registry-host.tld/-/npm/v1/keys` in the following format: + +``` +{ + "keys": [{ + "expires": null, + "keyid": "SHA256:{{SHA256_PUBLIC_KEY}}", + "keytype": "ecdsa-sha2-nistp256", + "scheme": "ecdsa-sha2-nistp256", + "key": "{{B64_PUBLIC_KEY}}" + }] +} +``` + +Keys response: + +- `expires`: null or a simplified extended <a href="https://en.wikipedia.org/wiki/ISO_8601" target="_blank">ISO 8601 format</a>: `YYYY-MM-DDTHH:mm:ss.sssZ` +- `keydid`: sha256 fingerprint of the public key +- `keytype`: only `ecdsa-sha2-nistp256` is currently supported by the npm CLI +- `scheme`: only `ecdsa-sha2-nistp256` is currently supported by the npm CLI +- `key`: base64 encoded public key + +See this <a href="https://registry.npmjs.org/-/npm/v1/keys" target="_blank">example key's response from the public npm registry</a>. + ### Audit Endpoints There are two audit endpoints that npm may use to fetch vulnerability @@ -51,9 +98,9 @@ the path `/-/npm/v1/security/advisories/bulk`. Any packages in the tree that do not have a `version` field in their package.json file will be ignored. If any `--omit` options are specified -(either via the `--omit` config, or one of the shorthands such as -`--production`, `--only=dev`, and so on), then packages will be omitted -from the submitted payload as appropriate. +(either via the [`--omit` config](/using-npm/config#omit), or one of the +shorthands such as `--production`, `--only=dev`, and so on), then packages will +be omitted from the submitted payload as appropriate. If the registry responds with an error, or with an invalid response, then npm will attempt to load advisory data from the `Quick Audit` endpoint. @@ -130,7 +177,7 @@ vulnerabilities are found _or_ if the remediation is able to successfully fix all vulnerabilities. If vulnerabilities were found the exit code will depend on the -`audit-level` configuration setting. +[`audit-level` config](/using-npm/config#audit-level). ### Examples @@ -189,178 +236,7 @@ $ npm audit --audit-level=moderate ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `audit-level` - -* Default: null -* Type: null, "info", "low", "moderate", "high", "critical", or "none" - -The minimum level of vulnerability for `npm audit` to exit with a non-zero -exit code. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `dry-run` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, `install`, `update`, -`dedupe`, `uninstall`, as well as `pack` and `publish`. - -Note: This is NOT honored by other network related commands, eg `dist-tags`, -`owner`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `force` - -* Default: false -* Type: Boolean - -Removes various protections against unfortunate side effects, common -mistakes, unnecessary performance degradation, and malicious input. - -* Allow clobbering non-npm files in global installs. -* Allow the `npm version` command to work on an unclean git repository. -* Allow deleting the cache folder with `npm cache clean`. -* Allow installing packages that have an `engines` declaration requiring a - different version of npm. -* Allow installing packages that have an `engines` declaration requiring a - different version of `node`, even if `--engine-strict` is enabled. -* Allow `npm audit fix` to install modules outside your stated dependency - range (including SemVer-major changes). -* Allow unpublishing all versions of a published package. -* Allow conflicting peerDependencies to be installed in the root project. -* Implicitly set `--yes` during `npm init`. -* Allow clobbering existing values in `npm pkg` - -If you don't have a clear idea of what you want to do, it is strongly -recommended that you do not use this option! - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `package-lock-only` - -* Default: false -* Type: Boolean - -If set to true, the current operation will only use the `package-lock.json`, -ignoring `node_modules`. - -For `update` this means only the `package-lock.json` will be updated, -instead of checking `node_modules` and downloading dependencies. - -For `list` this means the output will be based on the tree described by the -`package-lock.json`, rather than the contents of `node_modules`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `omit` - -* Default: 'dev' if the `NODE_ENV` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -`package-lock.json` or `npm-shrinkwrap.json` file. They are just not -physically installed on disk. - -If a package type appears in both the `--include` and `--omit` lists, then -it will be included. - -If the resulting omit list includes `'dev'`, then the `NODE_ENV` environment -variable will be set to `'production'` for all lifecycle scripts. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/lib/content/commands/npm-bugs.md b/docs/lib/content/commands/npm-bugs.md new file mode 100644 index 0000000..4cf9051 --- /dev/null +++ b/docs/lib/content/commands/npm-bugs.md @@ -0,0 +1,31 @@ +--- +title: npm-bugs +section: 1 +description: Report bugs for a package in a web browser +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command tries to guess at the likely location of a package's bug +tracker URL or the `mailto` URL of the support email, and then tries to +open it using the [`--browser` config](/using-npm/config#browser) param. If no +package name is provided, it will search for a `package.json` in the current +folder and use the `name` property. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm docs](/commands/npm-docs) +* [npm view](/commands/npm-view) +* [npm publish](/commands/npm-publish) +* [npm registry](/using-npm/registry) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) +* [package.json](/configuring-npm/package-json) diff --git a/docs/content/commands/npm-cache.md b/docs/lib/content/commands/npm-cache.md similarity index 79% rename from docs/content/commands/npm-cache.md rename to docs/lib/content/commands/npm-cache.md index 6497a39..2aedc54 100644 --- a/docs/content/commands/npm-cache.md +++ b/docs/lib/content/commands/npm-cache.md @@ -6,17 +6,7 @@ description: Manipulates packages cache ### Synopsis -```bash -npm cache add <tarball file>... -npm cache add <folder>... -npm cache add <tarball url>... -npm cache add <name>@<version>... - -npm cache clean -aliases: npm cache clear, npm cache rm - -npm cache verify -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -75,24 +65,11 @@ verify`. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `cache` - -* Default: Windows: `%LocalAppData%\npm-cache`, Posix: `~/.npm` -* Type: Path - -The location of npm's cache directory. See [`npm -cache`](/commands/npm-cache) - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also +* [package spec](/using-npm/package-spec) * [npm folders](/configuring-npm/folders) * [npm config](/commands/npm-config) * [npmrc](/configuring-npm/npmrc) diff --git a/docs/lib/content/commands/npm-ci.md b/docs/lib/content/commands/npm-ci.md new file mode 100644 index 0000000..d26691c --- /dev/null +++ b/docs/lib/content/commands/npm-ci.md @@ -0,0 +1,76 @@ +--- +title: npm-ci +section: 1 +description: Clean install a project +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command is similar to [`npm install`](/commands/npm-install), except +it's meant to be used in automated environments such as test platforms, +continuous integration, and deployment -- or any situation where you want +to make sure you're doing a clean install of your dependencies. + +The main differences between using `npm install` and `npm ci` are: + +* The project **must** have an existing `package-lock.json` or + `npm-shrinkwrap.json`. +* If dependencies in the package lock do not match those in `package.json`, + `npm ci` will exit with an error, instead of updating the package lock. +* `npm ci` can only install entire projects at a time: individual + dependencies cannot be added with this command. +* If a `node_modules` is already present, it will be automatically removed + before `npm ci` begins its install. +* It will never write to `package.json` or any of the package-locks: + installs are essentially frozen. + +NOTE: If you create your `package-lock.json` file by running `npm install` +with flags that can affect the shape of your dependency tree, such as +`--legacy-peer-deps` or `--install-links`, you _must_ provide the same +flags to `npm ci` or you are likely to encounter errors. An easy way to do +this is to run, for example, +`npm config set legacy-peer-deps=true --location=project` and commit the +`.npmrc` file to your repo. + +### Example + +Make sure you have a package-lock and an up-to-date install: + +```bash +$ cd ./my/npm/project +$ npm install +added 154 packages in 10s +$ ls | grep package-lock +``` + +Run `npm ci` in that project + +```bash +$ npm ci +added 154 packages in 5s +``` + +Configure Travis CI to build using `npm ci` instead of `npm install`: + +```bash +# .travis.yml +install: +- npm ci +# keep the npm cache around to speed up installs +cache: + directories: + - "$HOME/.npm" +``` + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm install](/commands/npm-install) +* [package-lock.json](/configuring-npm/package-lock-json) diff --git a/docs/content/commands/npm-completion.md b/docs/lib/content/commands/npm-completion.md similarity index 95% rename from docs/content/commands/npm-completion.md rename to docs/lib/content/commands/npm-completion.md index 9dbd960..3a5bae3 100644 --- a/docs/content/commands/npm-completion.md +++ b/docs/lib/content/commands/npm-completion.md @@ -6,9 +6,7 @@ description: Tab Completion for npm ### Synopsis -```bash -source <(npm completion) -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. diff --git a/docs/lib/content/commands/npm-config.md b/docs/lib/content/commands/npm-config.md new file mode 100644 index 0000000..5267d49 --- /dev/null +++ b/docs/lib/content/commands/npm-config.md @@ -0,0 +1,106 @@ +--- +title: npm-config +section: 1 +description: Manage the npm configuration files +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +Note: This command is unaware of workspaces. + +### Description + +npm gets its config settings from the command line, environment +variables, `npmrc` files, and in some cases, the `package.json` file. + +See [npmrc](/configuring-npm/npmrc) for more information about the npmrc +files. + +See [config](/using-npm/config) for a more thorough explanation of the +mechanisms involved, and a full list of config options available. + +The `npm config` command can be used to update and edit the contents +of the user and global npmrc files. + +### Sub-commands + +Config supports the following sub-commands: + +#### set + +```bash +npm config set key=value [key=value...] +npm set key=value [key=value...] +``` + +Sets each of the config keys to the value provided. + +If value is omitted, then it sets it to an empty string. + +Note: for backwards compatibility, `npm config set key value` is supported +as an alias for `npm config set key=value`. + +#### get + +```bash +npm config get [key ...] +npm get [key ...] +``` + +Echo the config value(s) to stdout. + +If multiple keys are provided, then the values will be prefixed with the +key names. + +If no keys are provided, then this command behaves the same as `npm config +list`. + +#### list + +```bash +npm config list +``` + +Show all the config settings. Use `-l` to also show defaults. Use `--json` +to show the settings in json format. + +#### delete + +```bash +npm config delete key [key ...] +``` + +Deletes the specified keys from all configuration files. + +#### edit + +```bash +npm config edit +``` + +Opens the config file in an editor. Use the `--global` flag to edit the +global config. + +#### fix + +```bash +npm config fix +``` + +Attempts to repair invalid configuration items. Usually this means +attaching authentication config (i.e. `_auth`, `_authToken`) to the +configured `registry`. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm folders](/configuring-npm/folders) +* [npm config](/commands/npm-config) +* [package.json](/configuring-npm/package-json) +* [npmrc](/configuring-npm/npmrc) +* [npm](/commands/npm) diff --git a/docs/lib/content/commands/npm-dedupe.md b/docs/lib/content/commands/npm-dedupe.md new file mode 100644 index 0000000..877a130 --- /dev/null +++ b/docs/lib/content/commands/npm-dedupe.md @@ -0,0 +1,83 @@ +--- +title: npm-dedupe +section: 1 +description: Reduce duplication in the package tree +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +Searches the local package tree and attempts to simplify the overall +structure by moving dependencies further up the tree, where they can +be more effectively shared by multiple dependent packages. + +For example, consider this dependency graph: + +``` +a ++-- b <-- depends on c@1.0.x +| `-- c@1.0.3 +`-- d <-- depends on c@~1.0.9 + `-- c@1.0.10 +``` + +In this case, `npm dedupe` will transform the tree to: + +```bash +a ++-- b ++-- d +`-- c@1.0.10 +``` + +Because of the hierarchical nature of node's module lookup, b and d +will both get their dependency met by the single c package at the root +level of the tree. + +In some cases, you may have a dependency graph like this: + +``` +a ++-- b <-- depends on c@1.0.x ++-- c@1.0.3 +`-- d <-- depends on c@1.x + `-- c@1.9.9 +``` + +During the installation process, the `c@1.0.3` dependency for `b` was +placed in the root of the tree. Though `d`'s dependency on `c@1.x` could +have been satisfied by `c@1.0.3`, the newer `c@1.9.0` dependency was used, +because npm favors updates by default, even when doing so causes +duplication. + +Running `npm dedupe` will cause npm to note the duplication and +re-evaluate, deleting the nested `c` module, because the one in the root is +sufficient. + +To prefer deduplication over novelty during the installation process, run +`npm install --prefer-dedupe` or `npm config set prefer-dedupe true`. + +Arguments are ignored. Dedupe always acts on the entire tree. + +Note that this operation transforms the dependency tree, but will never +result in new modules being installed. + +Using `npm find-dupes` will run the command in `--dry-run` mode. + +Note: `npm dedupe` will never update the semver values of direct +dependencies in your project `package.json`, if you want to update +values in `package.json` you can run: `npm update --save` instead. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm find-dupes](/commands/npm-find-dupes) +* [npm ls](/commands/npm-ls) +* [npm update](/commands/npm-update) +* [npm install](/commands/npm-install) diff --git a/docs/content/commands/npm-deprecate.md b/docs/lib/content/commands/npm-deprecate.md similarity index 56% rename from docs/content/commands/npm-deprecate.md rename to docs/lib/content/commands/npm-deprecate.md index 438a54e..3cf02ac 100644 --- a/docs/content/commands/npm-deprecate.md +++ b/docs/lib/content/commands/npm-deprecate.md @@ -6,9 +6,7 @@ description: Deprecate a version of a package ### Synopsis -```bash -npm deprecate <pkg>[@<version range>] <message> -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -36,43 +34,17 @@ In this case, a version `my-thing@1.0.0-beta.0` will also be deprecated. You must be the package owner to deprecate something. See the `owner` and `adduser` help topics. -To un-deprecate a package, specify an empty string (`""`) for the `message` -argument. Note that you must use double quotes with no space between them to +To un-deprecate a package, specify an empty string (`""`) for the `message` +argument. Note that you must use double quotes with no space between them to format an empty string. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `otp` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with `npm access`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also +* [package spec](/using-npm/package-spec) * [npm publish](/commands/npm-publish) * [npm registry](/using-npm/registry) * [npm owner](/commands/npm-owner) diff --git a/docs/content/commands/npm-diff.md b/docs/lib/content/commands/npm-diff.md similarity index 50% rename from docs/content/commands/npm-diff.md rename to docs/lib/content/commands/npm-diff.md index 8d05df7..5a10841 100644 --- a/docs/content/commands/npm-diff.md +++ b/docs/lib/content/commands/npm-diff.md @@ -6,13 +6,7 @@ description: The registry diff command ### Synopsis -```bash -npm diff [...<paths>] -npm diff --diff=<pkg-name> [...<paths>] -npm diff --diff=<version-a> [--diff=<version-b>] [...<paths>] -npm diff --diff=<spec-a> [--diff=<spec-b>] [...<paths>] -npm diff [--diff-ignore-all-space] [--diff-name-only] [...<paths>] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description @@ -153,187 +147,7 @@ located within the folder `./lib/` and changed lines of code within the ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `diff` - -* Default: -* Type: String (can be set multiple times) - -Define arguments to compare in `npm diff`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-name-only` - -* Default: false -* Type: Boolean - -Prints only filenames when using `npm diff`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-unified` - -* Default: 3 -* Type: Number - -The number of lines of context to print in `npm diff`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-ignore-all-space` - -* Default: false -* Type: Boolean - -Ignore whitespace when comparing lines in `npm diff`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-no-prefix` - -* Default: false -* Type: Boolean - -Do not show any source or destination prefix in `npm diff` output. - -Note: this causes `npm diff` to ignore the `--diff-src-prefix` and -`--diff-dst-prefix` configs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-src-prefix` - -* Default: "a/" -* Type: String - -Source prefix to be used in `npm diff` output. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-dst-prefix` - -* Default: "b/" -* Type: String - -Destination prefix to be used in `npm diff` output. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `diff-text` - -* Default: false -* Type: Boolean - -Treat all files as text in `npm diff`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `tag` - -* Default: "latest" -* Type: String - -If you ask npm to install a package and don't tell it a specific version, -then it will install the specified tag. - -Also the tag that is added to the package@version specified by the `npm tag` -command, if no explicit tag is given. - -When used by the `npm diff` command, this is the tag used to fetch the -tarball that will be compared with the local files by default. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ## See Also * [npm outdated](/commands/npm-outdated) diff --git a/docs/content/commands/npm-dist-tag.md b/docs/lib/content/commands/npm-dist-tag.md similarity index 53% rename from docs/content/commands/npm-dist-tag.md rename to docs/lib/content/commands/npm-dist-tag.md index a4e0243..34781eb 100644 --- a/docs/content/commands/npm-dist-tag.md +++ b/docs/lib/content/commands/npm-dist-tag.md @@ -6,23 +6,17 @@ description: Modify package distribution tags ### Synopsis -```bash -npm dist-tag add <pkg>@<version> [<tag>] -npm dist-tag rm <pkg> <tag> -npm dist-tag ls [<pkg>] - -aliases: dist-tags -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description Add, remove, and enumerate distribution tags on a package: -* add: Tags the specified version of the package with the specified tag, or - the `--tag` config if not specified. If you have two-factor - authentication on auth-and-writes then you’ll need to include a one-time - password on the command line with `--otp <one-time password>`, or at the - OTP prompt. +* add: Tags the specified version of the package with the specified tag, + or the [`--tag` config](/using-npm/config#tag) if not specified. If you have + two-factor authentication on auth-and-writes then you’ll need to include a + one-time password on the command line with + `--otp <one-time password>`, or at the OTP prompt. * rm: Clear a tag that is no longer in use from the package. If you have two-factor authentication on auth-and-writes then you’ll need to include @@ -90,73 +84,11 @@ not begin with a number or the letter `v`. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also +* [package spec](/using-npm/package-spec) * [npm publish](/commands/npm-publish) * [npm install](/commands/npm-install) * [npm dedupe](/commands/npm-dedupe) diff --git a/docs/lib/content/commands/npm-docs.md b/docs/lib/content/commands/npm-docs.md new file mode 100644 index 0000000..140d23d --- /dev/null +++ b/docs/lib/content/commands/npm-docs.md @@ -0,0 +1,30 @@ +--- +title: npm-docs +section: 1 +description: Open documentation for a package in a web browser +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command tries to guess at the likely location of a package's +documentation URL, and then tries to open it using the +[`--browser` config](/using-npm/config#browser) param. You can pass multiple +package names at once. If no package name is provided, it will search for a +`package.json` in the current folder and use the `name` property. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm view](/commands/npm-view) +* [npm publish](/commands/npm-publish) +* [npm registry](/using-npm/registry) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) +* [package.json](/configuring-npm/package-json) diff --git a/docs/content/commands/npm-doctor.md b/docs/lib/content/commands/npm-doctor.md similarity index 90% rename from docs/content/commands/npm-doctor.md rename to docs/lib/content/commands/npm-doctor.md index 0cce60c..5682f20 100644 --- a/docs/content/commands/npm-doctor.md +++ b/docs/lib/content/commands/npm-doctor.md @@ -6,9 +6,7 @@ description: Check your npm environment ### Synopsis -```bash -npm doctor -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -33,8 +31,10 @@ Also, in addition to this, there are also very many issue reports due to using old versions of npm. Since npm is constantly improving, running `npm@latest` is better than an old version. -`npm doctor` verifies the following items in your environment, and if there -are any recommended changes, it will display them. +`npm doctor` verifies the following items in your environment, and if +there are any recommended changes, it will display them. By default npm +runs all of these checks. You can limit what checks are ran by +specifying them as extra arguments. #### `npm ping` @@ -104,20 +104,7 @@ reset the cache. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/content/commands/npm-edit.md b/docs/lib/content/commands/npm-edit.md similarity index 61% rename from docs/content/commands/npm-edit.md rename to docs/lib/content/commands/npm-edit.md index 5ae7f24..6de2b6e 100644 --- a/docs/content/commands/npm-edit.md +++ b/docs/lib/content/commands/npm-edit.md @@ -6,9 +6,7 @@ description: Edit an installed package ### Synopsis -```bash -npm edit <pkg> -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -27,21 +25,7 @@ changes to your locally installed copy. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `editor` - -* Default: The EDITOR or VISUAL environment variables, or 'notepad.exe' on - Windows, or 'vim' on Unix systems -* Type: String - -The command to run for `npm edit` and `npm config edit`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/content/commands/npm-exec.md b/docs/lib/content/commands/npm-exec.md similarity index 68% rename from docs/content/commands/npm-exec.md rename to docs/lib/content/commands/npm-exec.md index d154f57..33fc1a0 100644 --- a/docs/content/commands/npm-exec.md +++ b/docs/lib/content/commands/npm-exec.md @@ -6,26 +6,7 @@ description: Run a command from a local or remote npm package ### Synopsis -```bash -npm exec -- <pkg>[@<version>] [args...] -npm exec --package=<pkg>[@<version>] -- <cmd> [args...] -npm exec -c '<cmd> [args...]' -npm exec --package=foo -c '<cmd> [args...]' -npm exec [--ws] [-w <workspace-name] [args...] - -npx <pkg>[@<specifier>] [args...] -npx -p <pkg>[@<specifier>] <cmd> [args...] -npx -c '<cmd> [args...]' -npx -p <pkg>[@<specifier>] -c '<cmd> [args...]' -Run without --call or positional args to open interactive subshell - -alias: npm x, npx - -common options: ---package=<pkg> (may be specified multiple times) --p is a shorthand for --package only when using npx executable --c <cmd> --call=<cmd> (may not be mixed with positional arguments) -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description @@ -45,10 +26,11 @@ specified multiple times, to execute the supplied command in an environment where all specified packages are available. If any requested packages are not present in the local project -dependencies, then they are installed to a folder in the npm cache, which -is added to the `PATH` environment variable in the executed process. A -prompt is printed (which can be suppressed by providing either `--yes` or -`--no`). +dependencies, then a prompt is printed, which can be suppressed by +providing either `--yes` or `--no`. When standard input is not a TTY or a +CI environment is detected, `--yes` is assumed. The requested packages are +installed to a folder in the npm cache, which is added to the `PATH` +environment variable in the executed process. Package names provided without a specifier will be matched with whatever version exists in the local project. Package names with a specifier will @@ -122,96 +104,7 @@ $ npm exec -- foo@latest bar --package=@npmcli/foo ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `package` - -* Default: -* Type: String (can be set multiple times) - -The package to install for [`npm exec`](/commands/npm-exec) - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `call` - -* Default: "" -* Type: String - -Optional companion option for `npm exec`, `npx` that allows for specifying a -custom command to be run along with the installed packages. - -```bash -npm exec --package yo --package generator-node --call "yo node" -``` - - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### Examples @@ -241,7 +134,8 @@ $ npx -c 'eslint && say "hooray, lint passed"' ### Workspaces support -You may use the `workspace` or `workspaces` configs in order to run an +You may use the [`workspace`](/using-npm/config#workspace) or +[`workspaces`](/using-npm/config#workspaces) configs in order to run an arbitrary command from an npm package (either one installed locally, or fetched remotely) in the context of the specified workspaces. If no positional argument or `--call` option is provided, it will open an @@ -272,9 +166,9 @@ Assuming the workspace configuration is properly set up at the root level ``` You can execute an arbitrary command from a package in the context of each of -the configured workspaces when using the `workspaces` configuration options, -in this example we're using **eslint** to lint any js file found within each -workspace folder: +the configured workspaces when using the +[`workspaces` config options](/using-npm/config#workspace), in this example +we're using **eslint** to lint any js file found within each workspace folder: ``` npm exec --ws -- eslint ./*.js diff --git a/docs/lib/content/commands/npm-explain.md b/docs/lib/content/commands/npm-explain.md new file mode 100644 index 0000000..8de05c9 --- /dev/null +++ b/docs/lib/content/commands/npm-explain.md @@ -0,0 +1,67 @@ +--- +title: npm-explain +section: 1 +description: Explain installed packages +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command will print the chain of dependencies causing a given package +to be installed in the current project. + +If one or more package specs are provided, then only packages matching +one of the specifiers will have their relationships explained. + +The package spec can also refer to a folder within `./node_modules` + +For example, running `npm explain glob` within npm's source tree will show: + +```bash +glob@7.1.6 +node_modules/glob + glob@"^7.1.4" from the root project + +glob@7.1.1 dev +node_modules/tacks/node_modules/glob + glob@"^7.0.5" from rimraf@2.6.2 + node_modules/tacks/node_modules/rimraf + rimraf@"^2.6.2" from tacks@1.3.0 + node_modules/tacks + dev tacks@"^1.3.0" from the root project +``` + +To explain just the package residing at a specific folder, pass that as the +argument to the command. This can be useful when trying to figure out +exactly why a given dependency is being duplicated to satisfy conflicting +version requirements within the project. + +```bash +$ npm explain node_modules/nyc/node_modules/find-up +find-up@3.0.0 dev +node_modules/nyc/node_modules/find-up + find-up@"^3.0.0" from nyc@14.1.1 + node_modules/nyc + nyc@"^14.1.1" from tap@14.10.8 + node_modules/tap + dev tap@"^14.10.8" from the root project +``` + +### Configuration +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [package spec](/using-npm/package-spec) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) +* [npm folders](/configuring-npm/folders) +* [npm ls](/commands/npm-ls) +* [npm install](/commands/npm-install) +* [npm link](/commands/npm-link) +* [npm prune](/commands/npm-prune) +* [npm outdated](/commands/npm-outdated) +* [npm update](/commands/npm-update) diff --git a/docs/content/commands/npm-explore.md b/docs/lib/content/commands/npm-explore.md similarity index 61% rename from docs/content/commands/npm-explore.md rename to docs/lib/content/commands/npm-explore.md index 3979da9..7557d9a 100644 --- a/docs/content/commands/npm-explore.md +++ b/docs/lib/content/commands/npm-explore.md @@ -6,9 +6,7 @@ description: Browse an installed package ### Synopsis -```bash -npm explore <pkg> [ -- <command>] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -31,21 +29,7 @@ sure to use `npm rebuild <pkg>` if you make any changes. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `shell` - -* Default: SHELL environment variable, or "bash" on Posix, or "cmd.exe" on - Windows -* Type: String - -The shell to run for the `npm explore` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/lib/content/commands/npm-find-dupes.md b/docs/lib/content/commands/npm-find-dupes.md new file mode 100644 index 0000000..1e0e8df --- /dev/null +++ b/docs/lib/content/commands/npm-find-dupes.md @@ -0,0 +1,26 @@ +--- +title: npm-find-dupes +section: 1 +description: Find duplication in the package tree +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +Runs `npm dedupe` in `--dry-run` mode, making npm only output the +duplications, without actually changing the package tree. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm dedupe](/commands/npm-dedupe) +* [npm ls](/commands/npm-ls) +* [npm update](/commands/npm-update) +* [npm install](/commands/npm-install) + diff --git a/docs/lib/content/commands/npm-fund.md b/docs/lib/content/commands/npm-fund.md new file mode 100644 index 0000000..f200aaf --- /dev/null +++ b/docs/lib/content/commands/npm-fund.md @@ -0,0 +1,75 @@ +--- +title: npm-fund +section: 1 +description: Retrieve funding information +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command retrieves information on how to fund the dependencies of a +given project. If no package name is provided, it will list all +dependencies that are looking for funding in a tree structure, listing +the type of funding and the url to visit. If a package name is provided +then it tries to open its funding url using the +[`--browser` config](/using-npm/config#browser) param; if there are multiple +funding sources for the package, the user will be instructed to pass the +`--which` option to disambiguate. + +The list will avoid duplicated entries and will stack all packages that +share the same url as a single entry. Thus, the list does not have the +same shape of the output from `npm ls`. + +#### Example + +### Workspaces support + +It's possible to filter the results to only include a single workspace +and its dependencies using the +[`workspace` config](/using-npm/config#workspace) option. + +#### Example: + +Here's an example running `npm fund` in a project with a configured +workspace `a`: + +```bash +$ npm fund +test-workspaces-fund@1.0.0 ++-- https://example.com/a +| | `-- a@1.0.0 +| `-- https://example.com/maintainer +| `-- foo@1.0.0 ++-- https://example.com/npmcli-funding +| `-- @npmcli/test-funding +`-- https://example.com/org + `-- bar@2.0.0 +``` + +And here is an example of the expected result when filtering only by a +specific workspace `a` in the same project: + +```bash +$ npm fund -w a +test-workspaces-fund@1.0.0 +`-- https://example.com/a + | `-- a@1.0.0 + `-- https://example.com/maintainer + `-- foo@2.0.0 +``` + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +## See Also + +* [package spec](/using-npm/package-spec) +* [npm install](/commands/npm-install) +* [npm docs](/commands/npm-docs) +* [npm ls](/commands/npm-ls) +* [npm config](/commands/npm-config) +* [npm workspaces](/using-npm/workspaces) diff --git a/docs/content/commands/npm-help-search.md b/docs/lib/content/commands/npm-help-search.md similarity index 57% rename from docs/content/commands/npm-help-search.md rename to docs/lib/content/commands/npm-help-search.md index 78553a1..fb37036 100644 --- a/docs/content/commands/npm-help-search.md +++ b/docs/lib/content/commands/npm-help-search.md @@ -6,9 +6,7 @@ description: Search npm help documentation ### Synopsis -```bash -npm help-search <text> -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -25,20 +23,7 @@ directly. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `long` - -* Default: false -* Type: Boolean - -Show extended information in `ls`, `search`, and `help-search`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/content/commands/npm-help.md b/docs/lib/content/commands/npm-help.md similarity index 58% rename from docs/content/commands/npm-help.md rename to docs/lib/content/commands/npm-help.md index a8002ee..717092c 100644 --- a/docs/content/commands/npm-help.md +++ b/docs/lib/content/commands/npm-help.md @@ -6,9 +6,7 @@ description: Get help on npm ### Synopsis -```bash -npm help <term> [<terms..>] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -23,22 +21,7 @@ topic, so unique matches are equivalent to specifying a topic name. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `viewer` - -* Default: "man" on Posix, "browser" on Windows -* Type: String - -The program to use to view help content. - -Set to `"browser"` to view html help content in the default web browser. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/content/commands/npm-hook.md b/docs/lib/content/commands/npm-hook.md similarity index 65% rename from docs/content/commands/npm-hook.md rename to docs/lib/content/commands/npm-hook.md index c91bce3..75e7fcc 100644 --- a/docs/content/commands/npm-hook.md +++ b/docs/lib/content/commands/npm-hook.md @@ -6,12 +6,7 @@ description: Manage registry hooks ### Synopsis -```bash -npm hook ls [pkg] -npm hook add <entity> <url> <secret> -npm hook update <id> <url> [secret] -npm hook rm <id> -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -85,34 +80,7 @@ $ npm hook rm id-deadbeef ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `otp` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with `npm access`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/content/commands/npm-init.md b/docs/lib/content/commands/npm-init.md similarity index 53% rename from docs/content/commands/npm-init.md rename to docs/lib/content/commands/npm-init.md index a608061..832d786 100644 --- a/docs/content/commands/npm-init.md +++ b/docs/lib/content/commands/npm-init.md @@ -6,12 +6,7 @@ description: Create a package.json file ### Synopsis -```bash -npm init [--yes|-y|--scope] -npm init <@scope> (same as `npm exec <@scope>/create`) -npm init [<@scope>/]<name> (same as `npm exec [<@scope>/]create-<name>`) -npm init [-w <dir>] [args...] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description @@ -29,6 +24,8 @@ follows: * `npm init foo` -> `npm exec create-foo` * `npm init @usr/foo` -> `npm exec @usr/create-foo` * `npm init @usr` -> `npm exec @usr/create` +* `npm init @usr@2.0.0` -> `npm exec @usr/create@2.0.0` +* `npm init @usr/foo@2.0.0` -> `npm exec @usr/create-foo@2.0.0` If the initializer is omitted (by just calling `npm init`), init will fall back to legacy init behavior. It will ask you a bunch of questions, and @@ -38,6 +35,15 @@ strictly additive, so it will keep any fields and values that were already set. You can also use `-y`/`--yes` to skip the questionnaire altogether. If you pass `--scope`, it will create a scoped package. +*Note:* if a user already has the `create-<initializer>` package +globally installed, that will be what `npm init` uses. If you want npm +to use the latest version, or another specific version you must specify +it: + +* `npm init foo@latest` # fetches and runs the latest `create-foo` from + the registry +* `npm init foo@1.2.3` # runs `create-foo@1.2.3` specifically + #### Forwarding additional options Any additional options will be passed directly to the command, so `npm init @@ -145,112 +151,11 @@ dot to represent the current directory in that context, e.g: `react-app .`: ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `yes` - -* Default: null -* Type: null or Boolean - -Automatically answer "yes" to any prompts that npm might print on the -command line. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `force` - -* Default: false -* Type: Boolean - -Removes various protections against unfortunate side effects, common -mistakes, unnecessary performance degradation, and malicious input. - -* Allow clobbering non-npm files in global installs. -* Allow the `npm version` command to work on an unclean git repository. -* Allow deleting the cache folder with `npm cache clean`. -* Allow installing packages that have an `engines` declaration requiring a - different version of npm. -* Allow installing packages that have an `engines` declaration requiring a - different version of `node`, even if `--engine-strict` is enabled. -* Allow `npm audit fix` to install modules outside your stated dependency - range (including SemVer-major changes). -* Allow unpublishing all versions of a published package. -* Allow conflicting peerDependencies to be installed in the root project. -* Implicitly set `--yes` during `npm init`. -* Allow clobbering existing values in `npm pkg` - -If you don't have a clear idea of what you want to do, it is strongly -recommended that you do not use this option! - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also +* [package spec](/using-npm/package-spec) * [init-package-json module](http://npm.im/init-package-json) * [package.json](/configuring-npm/package-json) * [npm version](/commands/npm-version) diff --git a/docs/lib/content/commands/npm-install-ci-test.md b/docs/lib/content/commands/npm-install-ci-test.md new file mode 100644 index 0000000..9685eaa --- /dev/null +++ b/docs/lib/content/commands/npm-install-ci-test.md @@ -0,0 +1,23 @@ +--- +title: npm-install-ci-test +section: 1 +description: Install a project with a clean slate and run tests +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command runs `npm ci` followed immediately by `npm test`. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm install-test](/commands/npm-install-test) +* [npm ci](/commands/npm-ci) +* [npm test](/commands/npm-test) diff --git a/docs/lib/content/commands/npm-install-test.md b/docs/lib/content/commands/npm-install-test.md new file mode 100644 index 0000000..4a2798b --- /dev/null +++ b/docs/lib/content/commands/npm-install-test.md @@ -0,0 +1,24 @@ +--- +title: npm-install-test +section: 1 +description: Install package(s) and run tests +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command runs an `npm install` followed immediately by an `npm test`. It +takes exactly the same arguments as `npm install`. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm install](/commands/npm-install) +* [npm install-ci-test](/commands/npm-install-ci-test) +* [npm test](/commands/npm-test) diff --git a/docs/content/commands/npm-install.md b/docs/lib/content/commands/npm-install.md similarity index 62% rename from docs/content/commands/npm-install.md rename to docs/lib/content/commands/npm-install.md index b4f8da8..a705da2 100644 --- a/docs/content/commands/npm-install.md +++ b/docs/lib/content/commands/npm-install.md @@ -6,22 +6,7 @@ description: Install a package ### Synopsis -```bash -npm install (with no args, in package dir) -npm install [<@scope>/]<name> -npm install [<@scope>/]<name>@<tag> -npm install [<@scope>/]<name>@<version> -npm install [<@scope>/]<name>@<version range> -npm install <alias>@npm:<name> -npm install <git-host>:<git-user>/<repo-name> -npm install <git repo url> -npm install <tarball file> -npm install <tarball url> -npm install <folder> - -aliases: npm i, npm add -common options: [-P|--save-prod|-D|--save-dev|-O|--save-optional|--save-peer] [-E|--save-exact] [-B|--save-bundle] [--no-save] [--dry-run] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description @@ -84,12 +69,12 @@ into a tarball (b). *npm will not install the package dependencies* in the directory `<folder>`, but it will create a symlink to `<folder>`. - > NOTE: If you want to install the content of a directory like a package from the registry instead of creating a link, you would need to use [`npm pack`](/commands/npm-pack) while in the `<folder>` directory, and then install the resulting tarball instead of the `<folder>` using `npm install <tarball file>` + > NOTE: If you want to install the content of a directory like a package from the registry instead of creating a link, you would need to use the `--install-links` option. Example: ```bash - npm install ../../other-package + npm install ../../other-package --install-links npm install ./sub-package ``` @@ -129,7 +114,7 @@ into a tarball (b). * `npm install [<@scope>/]<name>`: Do a `<name>@<tag>` install, where `<tag>` is the "tag" config. (See - [`config`](/using-npm/config). The config's default value is `latest`.) + [`config`](/using-npm/config#tag). The config's default value is `latest`.) In most cases, this will install the version of the modules tagged as `latest` on the npm registry. @@ -313,7 +298,7 @@ into a tarball (b). can be any valid semver range or exact version, and npm will look for any tags or refs matching that range in the remote repository, much as it would for a registry dependency. If neither `#<commit-ish>` or - `#semver:<semver>` is specified, then `master` is used. + `#semver:<semver>` is specified, then the default branch is used. As with regular git dependencies, `dependencies` and `devDependencies` will be installed if the package has a `prepare` script before the @@ -420,268 +405,7 @@ does. These are some of the most common options related to installation. -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `save` - -* Default: true -* Type: Boolean - -Save installed packages to a package.json file as dependencies. - -When used with the `npm rm` command, removes the dependency from -package.json. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `save-exact` - -* Default: false -* Type: Boolean - -Dependencies saved to package.json will be configured with an exact version -rather than using npm's default semver range operator. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global-style` - -* Default: false -* Type: Boolean - -Causes npm to install the package into your local `node_modules` folder with -the same layout it uses with the global `node_modules` folder. Only your -direct dependencies will show in `node_modules` and everything they depend -on will be flattened in their `node_modules` folders. This obviously will -eliminate some deduping. If used with `legacy-bundling`, `legacy-bundling` -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `legacy-bundling` - -* Default: false -* Type: Boolean - -Causes npm to install the package such that versions of npm prior to 1.4, -such as the one included with node 0.8, can install the package. This -eliminates all automatic deduping. If used with `global-style` this option -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `strict-peer-deps` - -* Default: false -* Type: Boolean - -If set to `true`, and `--legacy-peer-deps` is not set, then _any_ -conflicting `peerDependencies` will be treated as an install failure, even -if npm could reasonably guess the appropriate resolution based on non-peer -dependency relationships. - -By default, conflicting `peerDependencies` deep in the dependency graph will -be resolved using the nearest non-peer dependency specification, even if -doing so will result in some packages receiving a peer dependency outside -the range set in their package's `peerDependencies` object. - -When such and override is performed, a warning is printed, explaining the -conflict and the packages involved. If `--strict-peer-deps` is set, then -this warning is treated as a failure. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `package-lock` - -* Default: true -* Type: Boolean - -If set to false, then ignore `package-lock.json` files when installing. This -will also prevent _writing_ `package-lock.json` if `save` is true. - -When package package-locks are disabled, automatic pruning of extraneous -modules will also be disabled. To remove extraneous modules with -package-locks disabled use `npm prune`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `omit` - -* Default: 'dev' if the `NODE_ENV` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -`package-lock.json` or `npm-shrinkwrap.json` file. They are just not -physically installed on disk. - -If a package type appears in both the `--include` and `--omit` lists, then -it will be included. - -If the resulting omit list includes `'dev'`, then the `NODE_ENV` environment -variable will be set to `'production'` for all lifecycle scripts. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `audit` - -* Default: true -* Type: Boolean - -When "true" submit audit reports alongside the current npm command to the -default registry and all registries configured for scopes. See the -documentation for [`npm audit`](/commands/npm-audit) for details on what is -submitted. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `bin-links` - -* Default: true -* Type: Boolean - -Tells npm to create symlinks (or `.cmd` shims on Windows) for package -executables. - -Set to false to have it not do this. This can be used to work around the -fact that some file systems don't support symlinks, even on ostensibly Unix -systems. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `fund` - -* Default: true -* Type: Boolean - -When "true" displays the message at the end of each `npm install` -acknowledging the number of dependencies looking for funding. See [`npm -fund`](/commands/npm-fund) for details. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `dry-run` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, `install`, `update`, -`dedupe`, `uninstall`, as well as `pack` and `publish`. - -Note: This is NOT honored by other network related commands, eg `dist-tags`, -`owner`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### Algorithm diff --git a/docs/lib/content/commands/npm-link.md b/docs/lib/content/commands/npm-link.md new file mode 100644 index 0000000..232e55f --- /dev/null +++ b/docs/lib/content/commands/npm-link.md @@ -0,0 +1,119 @@ +--- +title: npm-link +section: 1 +description: Symlink a package folder +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This is handy for installing your own stuff, so that you can work on it and +test iteratively without having to continually rebuild. + +Package linking is a two-step process. + +First, `npm link` in a package folder with no arguments will create a +symlink in the global folder `{prefix}/lib/node_modules/<package>` that +links to the package where the `npm link` command was executed. It will +also link any bins in the package to `{prefix}/bin/{name}`. Note that +`npm link` uses the global prefix (see `npm prefix -g` for its value). + +Next, in some other location, `npm link package-name` will create a +symbolic link from globally-installed `package-name` to `node_modules/` of +the current folder. + +Note that `package-name` is taken from `package.json`, _not_ from the +directory name. + +The package name can be optionally prefixed with a scope. See +[`scope`](/using-npm/scope). The scope must be preceded by an @-symbol and +followed by a slash. + +When creating tarballs for `npm publish`, the linked packages are +"snapshotted" to their current state by resolving the symbolic links, if +they are included in `bundleDependencies`. + +For example: + +```bash +cd ~/projects/node-redis # go into the package directory +npm link # creates global link +cd ~/projects/node-bloggy # go into some other package directory. +npm link redis # link-install the package +``` + +Now, any changes to `~/projects/node-redis` will be reflected in +`~/projects/node-bloggy/node_modules/node-redis/`. Note that the link +should be to the package name, not the directory name for that package. + +You may also shortcut the two steps in one. For example, to do the +above use-case in a shorter way: + +```bash +cd ~/projects/node-bloggy # go into the dir of your main project +npm link ../node-redis # link the dir of your dependency +``` + +The second line is the equivalent of doing: + +```bash +(cd ../node-redis; npm link) +npm link redis +``` + +That is, it first creates a global link, and then links the global +installation target into your project's `node_modules` folder. + +Note that in this case, you are referring to the directory name, +`node-redis`, rather than the package name `redis`. + +If your linked package is scoped (see [`scope`](/using-npm/scope)) your +link command must include that scope, e.g. + +```bash +npm link @myorg/privatepackage +``` + +### Caveat + +Note that package dependencies linked in this way are _not_ saved to +`package.json` by default, on the assumption that the intention is to have +a link stand in for a regular non-link dependency. Otherwise, for example, +if you depend on `redis@^3.0.1`, and ran `npm link redis`, it would replace +the `^3.0.1` dependency with `file:../path/to/node-redis`, which you +probably don't want! Additionally, other users or developers on your +project would run into issues if they do not have their folders set up +exactly the same as yours. + +If you are adding a _new_ dependency as a link, you should add it to the +relevant metadata by running `npm install <dep> --package-lock-only`. + +If you _want_ to save the `file:` reference in your `package.json` and +`package-lock.json` files, you can use `npm link <dep> --save` to do so. + +### Workspace Usage + +`npm link <pkg> --workspace <name>` will link the relevant package as a +dependency of the specified workspace(s). Note that It may actually be +linked into the parent project's `node_modules` folder, if there are no +conflicting dependencies. + +`npm link --workspace <name>` will create a global link to the specified +workspace(s). + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [package spec](/using-npm/package-spec) +* [npm developers](/using-npm/developers) +* [package.json](/configuring-npm/package-json) +* [npm install](/commands/npm-install) +* [npm folders](/configuring-npm/folders) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) diff --git a/docs/lib/content/commands/npm-login.md b/docs/lib/content/commands/npm-login.md new file mode 100644 index 0000000..f1dd29d --- /dev/null +++ b/docs/lib/content/commands/npm-login.md @@ -0,0 +1,43 @@ +--- +title: npm-login +section: 1 +description: Login to a registry user account +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +Note: This command is unaware of workspaces. + +### Description + +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 using `legacy` for your `auth-type`, the username and password, are +read in from prompts. + +To reset your password, go to <https://www.npmjs.com/forgot> + +To change your email address, go to <https://www.npmjs.com/email-edit> + +You may use this command multiple times with the same user account to +authorize on a new machine. When authenticating on a new machine, +the username, password and email address must all match with +your existing record. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm registry](/using-npm/registry) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) +* [npm owner](/commands/npm-owner) +* [npm whoami](/commands/npm-whoami) +* [npm token](/commands/npm-token) +* [npm profile](/commands/npm-profile) diff --git a/docs/lib/content/commands/npm-logout.md b/docs/lib/content/commands/npm-logout.md new file mode 100644 index 0000000..df58af1 --- /dev/null +++ b/docs/lib/content/commands/npm-logout.md @@ -0,0 +1,35 @@ +--- +title: npm-logout +section: 1 +description: Log out of the registry +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +Note: This command is unaware of workspaces. + +### Description + +When logged into a registry that supports token-based authentication, tell +the server to end this token's session. This will invalidate the token +everywhere you're using it, not just for the current environment. + +When logged into a legacy registry that uses username and password +authentication, this will clear the credentials in your user configuration. +In this case, it will _only_ affect the current environment. + +If `--scope` is provided, this will find the credentials for the registry +connected to that scope, if set. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm adduser](/commands/npm-adduser) +* [npm registry](/using-npm/registry) +* [npm config](/commands/npm-config) +* [npm whoami](/commands/npm-whoami) diff --git a/docs/lib/content/commands/npm-ls.md b/docs/lib/content/commands/npm-ls.md new file mode 100644 index 0000000..04c4f2c --- /dev/null +++ b/docs/lib/content/commands/npm-ls.md @@ -0,0 +1,86 @@ +--- +title: npm-ls +section: 1 +description: List installed packages +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command will print to stdout all the versions of packages that are +installed, as well as their dependencies when `--all` is specified, in a +tree structure. + +Note: to get a "bottoms up" view of why a given package is included in the +tree at all, use [`npm explain`](/commands/npm-explain). + +Positional arguments are `name@version-range` identifiers, which will limit +the results to only the paths to the packages named. Note that nested +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@@VERSION@ /path/to/npm +└─┬ init-package-json@0.0.4 + └── promzard@0.1.5 +``` + +It will print out extraneous, missing, and invalid packages. + +If a project specifies git urls for dependencies these are shown +in parentheses after the `name@version` to make it easier for users to +recognize potential forks of a project. + +The tree shown is the logical dependency tree, based on package +dependencies, not the physical layout of your `node_modules` folder. + +When run as `ll` or `la`, it shows extended information by default. + +### Note: Design Changes Pending + +The `npm ls` command's output and behavior made a _ton_ of sense when npm +created a `node_modules` folder that naively nested every dependency. In +such a case, the logical dependency graph and physical tree of packages on +disk would be roughly identical. + +With the advent of automatic install-time deduplication of dependencies in +npm v3, the `ls` output was modified to display the logical dependency +graph as a tree structure, since this was more useful to most users. +However, without using `npm ls -l`, it became impossible to show _where_ a +package was actually installed much of the time! + +With the advent of automatic installation of `peerDependencies` in npm v7, +this gets even more curious, as `peerDependencies` are logically +"underneath" their dependents in the dependency graph, but are always +physically at or above their location on disk. + +Also, in the years since npm got an `ls` command (in version 0.0.2!), +dependency graphs have gotten much larger as a general rule. Therefore, in +order to avoid dumping an excessive amount of content to the terminal, `npm +ls` now only shows the _top_ level dependencies, unless `--all` is +provided. + +A thorough re-examination of the use cases, intention, behavior, and output +of this command, is currently underway. Expect significant changes to at +least the default human-readable `npm ls` output in npm v8. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [package spec](/using-npm/package-spec) +* [npm explain](/commands/npm-explain) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) +* [npm folders](/configuring-npm/folders) +* [npm explain](/commands/npm-explain) +* [npm install](/commands/npm-install) +* [npm link](/commands/npm-link) +* [npm prune](/commands/npm-prune) +* [npm outdated](/commands/npm-outdated) +* [npm update](/commands/npm-update) diff --git a/docs/lib/content/commands/npm-org.md b/docs/lib/content/commands/npm-org.md new file mode 100644 index 0000000..ca4d887 --- /dev/null +++ b/docs/lib/content/commands/npm-org.md @@ -0,0 +1,64 @@ +--- +title: npm-org +section: 1 +description: Manage orgs +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +Note: This command is unaware of workspaces. + +### Example + +Add a new developer to an org: + +```bash +$ npm org set my-org @mx-smith +``` + +Add a new admin to an org (or change a developer to an admin): + +```bash +$ npm org set my-org @mx-santos admin +``` + +Remove a user from an org: + +```bash +$ npm org rm my-org mx-santos +``` + +List all users in an org: + +```bash +$ npm org ls my-org +``` + +List all users in JSON format: + +```bash +$ npm org ls my-org --json +``` + +See what role a user has in an org: + +```bash +$ npm org ls my-org @mx-santos +``` + +### Description + +You can use the `npm org` commands to manage and view users of an +organization. It supports adding and removing users, changing their roles, +listing them, and finding specific ones and their roles. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [using orgs](/using-npm/orgs) +* [Documentation on npm Orgs](https://docs.npmjs.com/orgs/) diff --git a/docs/content/commands/npm-outdated.md b/docs/lib/content/commands/npm-outdated.md similarity index 57% rename from docs/content/commands/npm-outdated.md rename to docs/lib/content/commands/npm-outdated.md index 1b58a6a..c4d39a6 100644 --- a/docs/content/commands/npm-outdated.md +++ b/docs/lib/content/commands/npm-outdated.md @@ -6,9 +6,7 @@ description: Check for outdated packages ### Synopsis -```bash -npm outdated [[<@scope>/]<pkg> ...] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description @@ -86,103 +84,11 @@ A few things to note: ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `all` - -* Default: false -* Type: Boolean - -When running `npm outdated` and `npm ls`, setting `--all` will show all -outdated or installed packages, rather than only those directly depended -upon by the current project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `long` - -* Default: false -* Type: Boolean - -Show extended information in `ls`, `search`, and `help-search`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `parseable` - -* Default: false -* Type: Boolean - -Output parseable results from commands that write to standard output. For -`npm search`, this will be tab-separated table format. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `global` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the `prefix` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the `{prefix}/lib/node_modules` folder, instead - of the current working directory. -* bin files are linked to `{prefix}/bin` -* man pages are linked to `{prefix}/share/man` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also +* [package spec](/using-npm/package-spec) * [npm update](/commands/npm-update) * [npm dist-tag](/commands/npm-dist-tag) * [npm registry](/using-npm/registry) diff --git a/docs/content/commands/npm-owner.md b/docs/lib/content/commands/npm-owner.md similarity index 54% rename from docs/content/commands/npm-owner.md rename to docs/lib/content/commands/npm-owner.md index 74e7f84..c35b369 100644 --- a/docs/content/commands/npm-owner.md +++ b/docs/lib/content/commands/npm-owner.md @@ -6,13 +6,7 @@ description: Manage package owners ### Synopsis -```bash -npm owner add <user> [<@scope>/]<pkg> -npm owner rm <user> [<@scope>/]<pkg> -npm owner ls [<@scope>/]<pkg> - -aliases: author -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -37,37 +31,11 @@ on the command line when changing ownership with `--otp`. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `otp` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with `npm access`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also +* [package spec](/using-npm/package-spec) * [npm profile](/commands/npm-profile) * [npm publish](/commands/npm-publish) * [npm registry](/using-npm/registry) diff --git a/docs/lib/content/commands/npm-pack.md b/docs/lib/content/commands/npm-pack.md new file mode 100644 index 0000000..0793ee2 --- /dev/null +++ b/docs/lib/content/commands/npm-pack.md @@ -0,0 +1,35 @@ +--- +title: npm-pack +section: 1 +description: Create a tarball from a package +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### Description + +For anything that's installable (that is, a package folder, tarball, +tarball url, git url, name@tag, name@version, name, or scoped name), this +command will fetch it to the cache, copy the tarball to the current working +directory as `<name>-<version>.tgz`, and then write the filenames out to +stdout. + +If the same package is specified multiple times, then the file will be +overwritten the second time. + +If no arguments are supplied, then npm packs the current package folder. + +### See Also + +* [package spec](/using-npm/package-spec) +* [npm-packlist package](http://npm.im/npm-packlist) +* [npm cache](/commands/npm-cache) +* [npm publish](/commands/npm-publish) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) diff --git a/docs/content/commands/npm-ping.md b/docs/lib/content/commands/npm-ping.md similarity index 58% rename from docs/content/commands/npm-ping.md rename to docs/lib/content/commands/npm-ping.md index c59a56e..2bf16b2 100644 --- a/docs/content/commands/npm-ping.md +++ b/docs/lib/content/commands/npm-ping.md @@ -6,9 +6,7 @@ description: Ping npm registry ### Synopsis -```bash -npm ping [--registry <registry>] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -30,20 +28,7 @@ npm ERR! 404 Not Found - GET http://www.foo.com/-/ping?write=true ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/content/commands/npm-pkg.md b/docs/lib/content/commands/npm-pkg.md similarity index 56% rename from docs/content/commands/npm-pkg.md rename to docs/lib/content/commands/npm-pkg.md index beee9c1..dbb2f27 100644 --- a/docs/content/commands/npm-pkg.md +++ b/docs/lib/content/commands/npm-pkg.md @@ -6,11 +6,7 @@ description: Manages your package.json ### Synopsis -```bash -npm pkg get [<field> [.<subfield> ...]] -npm pkg set <field>=<value> [.<subfield>=<value> ...] -npm pkg delete <field> [.<subfield> ...] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description @@ -65,6 +61,14 @@ Returned values are always in **json** format. npm pkg get contributors[0].email ``` + For complex fields you can also name a property in square brackets + to specifically select a child field. This is especially helpful + with the exports object: + + ```bash + npm pkg get "exports[.].require" + ``` + * `npm pkg set <field>=<value>` Sets a `value` in your `package.json` based on the `field` value. When @@ -134,7 +138,8 @@ Returned values are always in **json** format. ### Workspaces support You can set/get/delete items across your configured workspaces by using the -`workspace` or `workspaces` config options. +[`workspace`](/using-npm/config#workspace) or +[`workspaces`](/using-npm/config#workspaces) config options. For example, setting a `funding` value across all configured workspaces of a project: @@ -164,99 +169,7 @@ npm pkg get name version --ws ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `force` - -* Default: false -* Type: Boolean - -Removes various protections against unfortunate side effects, common -mistakes, unnecessary performance degradation, and malicious input. - -* Allow clobbering non-npm files in global installs. -* Allow the `npm version` command to work on an unclean git repository. -* Allow deleting the cache folder with `npm cache clean`. -* Allow installing packages that have an `engines` declaration requiring a - different version of npm. -* Allow installing packages that have an `engines` declaration requiring a - different version of `node`, even if `--engine-strict` is enabled. -* Allow `npm audit fix` to install modules outside your stated dependency - range (including SemVer-major changes). -* Allow unpublishing all versions of a published package. -* Allow conflicting peerDependencies to be installed in the root project. -* Implicitly set `--yes` during `npm init`. -* Allow clobbering existing values in `npm pkg` - -If you don't have a clear idea of what you want to do, it is strongly -recommended that you do not use this option! - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ## See Also * [npm install](/commands/npm-install) diff --git a/docs/lib/content/commands/npm-prefix.md b/docs/lib/content/commands/npm-prefix.md new file mode 100644 index 0000000..3da516f --- /dev/null +++ b/docs/lib/content/commands/npm-prefix.md @@ -0,0 +1,44 @@ +--- +title: npm-prefix +section: 1 +description: Display prefix +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +Note: This command is unaware of workspaces. + +### Description + +Print the local prefix to standard output. This is the closest parent directory +to contain a `package.json` file or `node_modules` directory, unless `-g` is +also specified. + +If `-g` is specified, this will be the value of the global prefix. See +[`npm config`](/commands/npm-config) for more detail. + +### Example + +```bash +npm prefix +/usr/local/projects/foo +``` + +```bash +npm prefix -g +/usr/local +``` + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm root](/commands/npm-root) +* [npm bin](/commands/npm-bin) +* [npm folders](/configuring-npm/folders) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) diff --git a/docs/content/commands/npm-profile.md b/docs/lib/content/commands/npm-profile.md similarity index 63% rename from docs/content/commands/npm-profile.md rename to docs/lib/content/commands/npm-profile.md index cecc485..36eb3fb 100644 --- a/docs/content/commands/npm-profile.md +++ b/docs/lib/content/commands/npm-profile.md @@ -6,13 +6,7 @@ description: Change settings on your registry profile ### Synopsis -```bash -npm profile get [--json|--parseable] [<property>] -npm profile set [--json|--parseable] <property> <value> -npm profile set password -npm profile enable-2fa [auth-and-writes|auth-only] -npm profile disable-2fa -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -75,60 +69,7 @@ Some of these commands may not be available on non npmjs.com registries. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `parseable` - -* Default: false -* Type: Boolean - -Output parseable results from commands that write to standard output. For -`npm search`, this will be tab-separated table format. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `otp` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with `npm access`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/lib/content/commands/npm-prune.md b/docs/lib/content/commands/npm-prune.md new file mode 100644 index 0000000..d0871c5 --- /dev/null +++ b/docs/lib/content/commands/npm-prune.md @@ -0,0 +1,42 @@ +--- +title: npm-prune +section: 1 +description: Remove extraneous packages +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command removes "extraneous" packages. If a package name is provided, +then only packages matching one of the supplied names are removed. + +Extraneous packages are those present in the `node_modules` folder that are +not listed as any package's dependency list. + +If the `--production` flag is specified or the `NODE_ENV` environment +variable is set to `production`, this command will remove the packages +specified in your `devDependencies`. Setting `--no-production` will negate +`NODE_ENV` being set to `production`. + +If the `--dry-run` flag is used then no changes will actually be made. + +If the `--json` flag is used, then the changes `npm prune` made (or would +have made with `--dry-run`) are printed as a JSON object. + +In normal operation, extraneous modules are pruned automatically, so you'll +only need this command with the `--production` flag. However, in the real +world, operation is not always "normal". When crashes or mistakes happen, +this command can help clean up any resulting garbage. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm uninstall](/commands/npm-uninstall) +* [npm folders](/configuring-npm/folders) +* [npm ls](/commands/npm-ls) diff --git a/docs/lib/content/commands/npm-publish.md b/docs/lib/content/commands/npm-publish.md new file mode 100644 index 0000000..f8481a9 --- /dev/null +++ b/docs/lib/content/commands/npm-publish.md @@ -0,0 +1,101 @@ +--- +title: npm-publish +section: 1 +description: Publish a package +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +Publishes a package to the registry so that it can be installed by name. + +By default npm will publish to the public registry. This can be +overridden by specifying a different default registry or using a +[`scope`](/using-npm/scope) in the name, combined with a +scope-configured registry (see +[`package.json`](/configuring-npm/package-json)). + + +A `package` is interpreted the same way as other commands (like +`npm install` and can be: + +* a) a folder containing a program described by a + [`package.json`](/configuring-npm/package-json) file +* b) a gzipped tarball containing (a) +* c) a url that resolves to (b) +* d) a `<name>@<version>` that is published on the registry (see + [`registry`](/using-npm/registry)) with (c) +* e) a `<name>@<tag>` (see [`npm dist-tag`](/commands/npm-dist-tag)) that + points to (d) +* f) a `<name>` that has a "latest" tag satisfying (e) +* g) a `<git remote url>` that resolves to (a) + +The publish will fail if the package name and version combination already +exists in the specified registry. + +Once a package is published with a given name and version, that specific +name and version combination can never be used again, even if it is removed +with [`npm unpublish`](/commands/npm-unpublish). + +As of `npm@5`, both a sha1sum and an integrity field with a sha512sum of the +tarball will be submitted to the registry during publication. Subsequent +installs will use the strongest supported algorithm to verify downloads. + +Similar to `--dry-run` see [`npm pack`](/commands/npm-pack), which figures +out the files to be included and packs them into a tarball to be uploaded +to the registry. + +### Files included in package + +To see what will be included in your package, run `npx npm-packlist`. All +files are included by default, with the following exceptions: + +- Certain files that are relevant to package installation and distribution + are always included. For example, `package.json`, `README.md`, + `LICENSE`, and so on. + +- If there is a "files" list in + [`package.json`](/configuring-npm/package-json), then only the files + specified will be included. (If directories are specified, then they + will be walked recursively and their contents included, subject to the + same ignore rules.) + +- If there is a `.gitignore` or `.npmignore` file, then ignored files in + that and all child directories will be excluded from the package. If + _both_ files exist, then the `.gitignore` is ignored, and only the + `.npmignore` is used. + + `.npmignore` files follow the [same pattern + rules](https://git-scm.com/book/en/v2/Git-Basics-Recording-Changes-to-the-Repository#_ignoring) + as `.gitignore` files + +- If the file matches certain patterns, then it will _never_ be included, + unless explicitly added to the `"files"` list in `package.json`, or + un-ignored with a `!` rule in a `.npmignore` or `.gitignore` file. + +- Symbolic links are never included in npm packages. + + +See [`developers`](/using-npm/developers) for full details on what's +included in the published package, as well as details on how the package is +built. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [package spec](/using-npm/package-spec) +* [npm-packlist package](http://npm.im/npm-packlist) +* [npm registry](/using-npm/registry) +* [npm scope](/using-npm/scope) +* [npm adduser](/commands/npm-adduser) +* [npm owner](/commands/npm-owner) +* [npm deprecate](/commands/npm-deprecate) +* [npm dist-tag](/commands/npm-dist-tag) +* [npm pack](/commands/npm-pack) +* [npm profile](/commands/npm-profile) diff --git a/docs/lib/content/commands/npm-query.md b/docs/lib/content/commands/npm-query.md new file mode 100644 index 0000000..e6bf53f --- /dev/null +++ b/docs/lib/content/commands/npm-query.md @@ -0,0 +1,143 @@ +--- +title: npm-query +section: 1 +description: Dependency selector query +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +The `npm query` command allows for usage of css selectors in order to retrieve +an array of dependency objects. + +### Piping npm query to other commands + +```bash +# find all dependencies with postinstall scripts & uninstall them +npm query ":attr(scripts, [postinstall])" | jq 'map(.name)|join("\n")' -r | xargs -I {} npm uninstall {} + +# find all git dependencies & explain who requires them +npm query ":type(git)" | jq 'map(.name)' | xargs -I {} npm why {} +``` + +### Extended Use Cases & Queries + +```stylus +// all deps +* + +// all direct deps +:root > * + +// direct production deps +:root > .prod + +// direct development deps +:root > .dev + +// any peer dep of a direct deps +:root > * > .peer + +// any workspace dep +.workspace + +// all workspaces that depend on another workspace +.workspace > .workspace + +// all workspaces that have peer deps +.workspace:has(.peer) + +// any dep named "lodash" +// equivalent to [name="lodash"] +#lodash + +// any deps named "lodash" & within semver range ^"1.2.3" +#lodash@^1.2.3 +// equivalent to... +[name="lodash"]:semver(^1.2.3) + +// get the hoisted node for a given semver range +#lodash@^1.2.3:not(:deduped) + +// querying deps with a specific version +#lodash@2.1.5 +// equivalent to... +[name="lodash"][version="2.1.5"] + +// has any deps +:has(*) + +// deps with no other deps (ie. "leaf" nodes) +:empty + +// manually querying git dependencies +[repository^=github:], +[repository^=git:], +[repository^=https://github.com], +[repository^=http://github.com], +[repository^=https://github.com], +[repository^=+git:...] + +// querying for all git dependencies +:type(git) + +// get production dependencies that aren't also dev deps +.prod:not(.dev) + +// get dependencies with specific licenses +[license=MIT], [license=ISC] + +// find all packages that have @ruyadorno as a contributor +:attr(contributors, [email=ruyadorno@github.com]) +``` + +### Example Response Output + +- an array of dependency objects is returned which can contain multiple copies of the same package which may or may not have been linked or deduped + +```json +[ + { + "name": "", + "version": "", + "description": "", + "homepage": "", + "bugs": {}, + "author": {}, + "license": {}, + "funding": {}, + "files": [], + "main": "", + "browser": "", + "bin": {}, + "man": [], + "directories": {}, + "repository": {}, + "scripts": {}, + "config": {}, + "dependencies": {}, + "devDependencies": {}, + "optionalDependencies": {}, + "bundledDependencies": {}, + "peerDependencies": {}, + "peerDependenciesMeta": {}, + "engines": {}, + "os": [], + "cpu": [], + "workspaces": {}, + "keywords": [], + ... + }, + ... +``` + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> +## See Also + +* [dependency selectors](/using-npm/dependency-selectors) + diff --git a/docs/lib/content/commands/npm-rebuild.md b/docs/lib/content/commands/npm-rebuild.md new file mode 100644 index 0000000..da3a088 --- /dev/null +++ b/docs/lib/content/commands/npm-rebuild.md @@ -0,0 +1,29 @@ +--- +title: npm-rebuild +section: 1 +description: Rebuild a package +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command runs the `npm build` command on the matched folders. This is +useful when you install a new version of node, and must recompile all your +C++ addons with the new binary. It is also useful when installing with +`--ignore-scripts` and `--no-bin-links`, to explicitly choose which +packages to build and/or link bins. + +If one or more package specs are provided, then only packages with a +name and version matching one of the specifiers will be rebuilt. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [package spec](/using-npm/package-spec) +* [npm install](/commands/npm-install) diff --git a/docs/lib/content/commands/npm-repo.md b/docs/lib/content/commands/npm-repo.md new file mode 100644 index 0000000..e5968b3 --- /dev/null +++ b/docs/lib/content/commands/npm-repo.md @@ -0,0 +1,26 @@ +--- +title: npm-repo +section: 1 +description: Open package repository page in the browser +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command tries to guess at the likely location of a package's +repository URL, and then tries to open it using the +[`--browser` config](/using-npm/config#browser) param. If no package name is +provided, it will search for a `package.json` in the current folder and use the +`repository` property. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm docs](/commands/npm-docs) +* [npm config](/commands/npm-config) diff --git a/docs/lib/content/commands/npm-restart.md b/docs/lib/content/commands/npm-restart.md new file mode 100644 index 0000000..c337ed6 --- /dev/null +++ b/docs/lib/content/commands/npm-restart.md @@ -0,0 +1,46 @@ +--- +title: npm-restart +section: 1 +description: Restart a package +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This restarts a project. It is equivalent to running `npm run-script +restart`. + +If the current project has a `"restart"` script specified in +`package.json`, then the following scripts will be run: + +1. prerestart +2. restart +3. postrestart + +If it does _not_ have a `"restart"` script specified, but it does have +`stop` and/or `start` scripts, then the following scripts will be run: + +1. prerestart +2. prestop +3. stop +4. poststop +6. prestart +7. start +8. poststart +9. postrestart + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm run-script](/commands/npm-run-script) +* [npm scripts](/using-npm/scripts) +* [npm test](/commands/npm-test) +* [npm start](/commands/npm-start) +* [npm stop](/commands/npm-stop) +* [npm restart](/commands/npm-restart) diff --git a/docs/lib/content/commands/npm-root.md b/docs/lib/content/commands/npm-root.md new file mode 100644 index 0000000..6bf6c3e --- /dev/null +++ b/docs/lib/content/commands/npm-root.md @@ -0,0 +1,34 @@ +--- +title: npm-root +section: 1 +description: Display npm root +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +Print the effective `node_modules` folder to standard out. + +Useful for using npm in shell scripts that do things with the +`node_modules` folder. For example: + +```bash +#!/bin/bash +global_node_modules="$(npm root --global)" +echo "Global packages installed in: ${global_node_modules}" +``` + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm prefix](/commands/npm-prefix) +* [npm bin](/commands/npm-bin) +* [npm folders](/configuring-npm/folders) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) diff --git a/docs/lib/content/commands/npm-run-script.md b/docs/lib/content/commands/npm-run-script.md new file mode 100644 index 0000000..3c35a47 --- /dev/null +++ b/docs/lib/content/commands/npm-run-script.md @@ -0,0 +1,146 @@ +--- +title: npm-run-script +section: 1 +description: Run arbitrary package scripts +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This runs an arbitrary command from a package's `"scripts"` object. If no +`"command"` is provided, it will list the available scripts. + +`run[-script]` is used by the test, start, restart, and stop commands, but +can be called directly, as well. When the scripts in the package are +printed out, they're separated into lifecycle (test, start, restart) and +directly-run scripts. + +Any positional arguments are passed to the specified script. Use `--` to +pass `-`-prefixed flags and options which would otherwise be parsed by npm. + +For example: + +```bash +npm run test -- --grep="pattern" +``` + +The arguments will only be passed to the script specified after `npm run` +and not to any `pre` or `post` script. + +The `env` script is a special built-in command that can be used to list +environment variables that will be available to the script at runtime. If an +"env" command is defined in your package, it will take precedence over the +built-in. + +In addition to the shell's pre-existing `PATH`, `npm run` adds +`node_modules/.bin` to the `PATH` provided to scripts. Any binaries +provided by locally-installed dependencies can be used without the +`node_modules/.bin` prefix. For example, if there is a `devDependency` on +`tap` in your package, you should write: + +```bash +"scripts": {"test": "tap test/*.js"} +``` + +instead of + +```bash +"scripts": {"test": "node_modules/.bin/tap test/*.js"} +``` + +The actual shell your script is run within is platform dependent. By default, +on Unix-like systems it is the `/bin/sh` command, on Windows it is +`cmd.exe`. +The actual shell referred to by `/bin/sh` also depends on the system. +You can customize the shell with the +[`script-shell` config](/using-npm/config#script-shell). + +Scripts are run from the root of the package folder, regardless of what the +current working directory is when `npm run` is called. If you want your +script to use different behavior based on what subdirectory you're in, you +can use the `INIT_CWD` environment variable, which holds the full path you +were in when you ran `npm run`. + +`npm run` sets the `NODE` environment variable to the `node` executable +with which `npm` is executed. + +If you try to run a script without having a `node_modules` directory and it +fails, you will be given a warning to run `npm install`, just in case you've +forgotten. + +### Workspaces support + +You may use the [`workspace`](/using-npm/config#workspace) or +[`workspaces`](/using-npm/config#workspaces) configs in order to run an +arbitrary command from a package's `"scripts"` object in the context of the +specified workspaces. If no `"command"` is provided, it will list the available +scripts for each of these configured workspaces. + +Given a project with configured workspaces, e.g: + +``` +. ++-- package.json +`-- packages + +-- a + | `-- package.json + +-- b + | `-- package.json + `-- c + `-- package.json +``` + +Assuming the workspace configuration is properly set up at the root level +`package.json` file. e.g: + +``` +{ + "workspaces": [ "./packages/*" ] +} +``` + +And that each of the configured workspaces has a configured `test` script, +we can run tests in all of them using the +[`workspaces` config](/using-npm/config#workspaces): + +``` +npm test --workspaces +``` + +#### Filtering workspaces + +It's also possible to run a script in a single workspace using the `workspace` +config along with a name or directory path: + +``` +npm test --workspace=a +``` + +The `workspace` config can also be specified multiple times in order to run a +specific script in the context of multiple workspaces. When defining values for +the `workspace` config in the command line, it also possible to use `-w` as a +shorthand, e.g: + +``` +npm test -w a -w b +``` + +This last command will run `test` in both `./packages/a` and `./packages/b` +packages. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm scripts](/using-npm/scripts) +* [npm test](/commands/npm-test) +* [npm start](/commands/npm-start) +* [npm restart](/commands/npm-restart) +* [npm stop](/commands/npm-stop) +* [npm config](/commands/npm-config) +* [npm workspaces](/using-npm/workspaces) diff --git a/docs/lib/content/commands/npm-search.md b/docs/lib/content/commands/npm-search.md new file mode 100644 index 0000000..7cf2cf4 --- /dev/null +++ b/docs/lib/content/commands/npm-search.md @@ -0,0 +1,47 @@ +--- +title: npm-search +section: 1 +description: Search for packages +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +Note: This command is unaware of workspaces. + +### Description + +Search the registry for packages matching the search terms. `npm search` +performs a linear, incremental, lexically-ordered search through package +metadata for all files in the registry. If your terminal has color +support, it will further highlight the matches in the results. This can +be disabled with the config item `color` + +Additionally, using the `--searchopts` and `--searchexclude` options +paired with more search terms will include and exclude further patterns. +The main difference between `--searchopts` and the standard search terms +is that the former does not highlight results in the output and you can +use them more fine-grained filtering. Additionally, you can add both of +these to your config to change default search filtering behavior. + +Search also allows targeting of maintainers in search results, by prefixing +their npm username with `=`. + +If a term starts with `/`, then it's interpreted as a regular expression +and supports standard JavaScript RegExp syntax. In this case search will +ignore a trailing `/` . (Note you must escape or quote many regular +expression characters in most shells.) + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm registry](/using-npm/registry) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) +* [npm view](/commands/npm-view) +* [npm cache](/commands/npm-cache) +* https://npm.im/npm-registry-fetch diff --git a/docs/content/commands/npm-shrinkwrap.md b/docs/lib/content/commands/npm-shrinkwrap.md similarity index 95% rename from docs/content/commands/npm-shrinkwrap.md rename to docs/lib/content/commands/npm-shrinkwrap.md index 6786229..0a4f220 100644 --- a/docs/content/commands/npm-shrinkwrap.md +++ b/docs/lib/content/commands/npm-shrinkwrap.md @@ -6,9 +6,7 @@ description: Lock down dependency versions for publication ### Synopsis -```bash -npm shrinkwrap -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. diff --git a/docs/content/commands/npm-star.md b/docs/lib/content/commands/npm-star.md similarity index 50% rename from docs/content/commands/npm-star.md rename to docs/lib/content/commands/npm-star.md index 21109c3..1e7bbce 100644 --- a/docs/content/commands/npm-star.md +++ b/docs/lib/content/commands/npm-star.md @@ -6,9 +6,7 @@ description: Mark your favorite packages ### Synopsis -```bash -npm star [<pkg>...] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -35,35 +33,11 @@ You can see all your starred packages using [`npm stars`](/commands/npm-stars) ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `unicode` - -* Default: false on windows, true on mac/unix systems with a unicode locale, - as defined by the `LC_ALL`, `LC_CTYPE`, or `LANG` environment variables. -* Type: Boolean - -When set to true, npm uses unicode characters in the tree output. When -false, it uses ascii characters instead of unicode glyphs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also +* [package spec](/using-npm/package-spec) * [npm unstar](/commands/npm-unstar) * [npm stars](/commands/npm-stars) * [npm view](/commands/npm-view) diff --git a/docs/content/commands/npm-stars.md b/docs/lib/content/commands/npm-stars.md similarity index 58% rename from docs/content/commands/npm-stars.md rename to docs/lib/content/commands/npm-stars.md index 101559a..c1d3359 100644 --- a/docs/content/commands/npm-stars.md +++ b/docs/lib/content/commands/npm-stars.md @@ -5,9 +5,8 @@ description: View packages marked as favorites --- ### Synopsis -```bash -npm stars [<user>] -``` + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -21,20 +20,7 @@ you will most certainly enjoy this command. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/content/commands/npm-start.md b/docs/lib/content/commands/npm-start.md similarity index 50% rename from docs/content/commands/npm-start.md rename to docs/lib/content/commands/npm-start.md index 50a54cb..c30dda9 100644 --- a/docs/content/commands/npm-start.md +++ b/docs/lib/content/commands/npm-start.md @@ -6,9 +6,7 @@ description: Start a package ### Synopsis -```bash -npm start [-- <args>] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description @@ -47,36 +45,7 @@ npm start ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `ignore-scripts` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `script-shell` - -* Default: '/bin/sh' on POSIX systems, 'cmd.exe' on Windows -* Type: null or String - -The shell to use for scripts run with the `npm exec`, `npm run` and `npm -init <pkg>` commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/lib/content/commands/npm-stop.md b/docs/lib/content/commands/npm-stop.md new file mode 100644 index 0000000..e4924d4 --- /dev/null +++ b/docs/lib/content/commands/npm-stop.md @@ -0,0 +1,49 @@ +--- +title: npm-stop +section: 1 +description: Stop a package +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This runs a predefined command specified in the "stop" property of a +package's "scripts" object. + +Unlike with [npm start](/commands/npm-start), there is no default script +that will run if the `"stop"` property is not defined. + +### Example + +```json +{ + "scripts": { + "stop": "node bar.js" + } +} +``` + +```bash +npm stop + +> npm@x.x.x stop +> node bar.js + +(bar.js output would be here) + +``` + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm run-script](/commands/npm-run-script) +* [npm scripts](/using-npm/scripts) +* [npm test](/commands/npm-test) +* [npm start](/commands/npm-start) +* [npm restart](/commands/npm-restart) diff --git a/docs/content/commands/npm-team.md b/docs/lib/content/commands/npm-team.md similarity index 64% rename from docs/content/commands/npm-team.md rename to docs/lib/content/commands/npm-team.md index 6050af1..f82e8cf 100644 --- a/docs/content/commands/npm-team.md +++ b/docs/lib/content/commands/npm-team.md @@ -6,15 +6,7 @@ description: Manage organization teams and team memberships ### Synopsis -```bash -npm team create <scope:team> -npm team destroy <scope:team> - -npm team add <scope:team> <user> -npm team rm <scope:team> <user> - -npm team ls <scope>|<scope:team> -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -103,60 +95,7 @@ use the `npm access` command to grant or revoke the appropriate permissions. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `otp` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with `npm access`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `parseable` - -* Default: false -* Type: Boolean - -Output parseable results from commands that write to standard output. For -`npm search`, this will be tab-separated table format. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/lib/content/commands/npm-test.md b/docs/lib/content/commands/npm-test.md new file mode 100644 index 0000000..11a4d79 --- /dev/null +++ b/docs/lib/content/commands/npm-test.md @@ -0,0 +1,44 @@ +--- +title: npm-test +section: 1 +description: Test a package +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This runs a predefined command specified in the `"test"` property of +a package's `"scripts"` object. + +### Example + +```json +{ + "scripts": { + "test": "node test.js" + } +} +``` + +```bash +npm test +> npm@x.x.x test +> node test.js + +(test.js output would be here) +``` + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm run-script](/commands/npm-run-script) +* [npm scripts](/using-npm/scripts) +* [npm start](/commands/npm-start) +* [npm restart](/commands/npm-restart) +* [npm stop](/commands/npm-stop) diff --git a/docs/content/commands/npm-token.md b/docs/lib/content/commands/npm-token.md similarity index 68% rename from docs/content/commands/npm-token.md rename to docs/lib/content/commands/npm-token.md index 16da1f7..85b6010 100644 --- a/docs/content/commands/npm-token.md +++ b/docs/lib/content/commands/npm-token.md @@ -5,11 +5,8 @@ description: Manage your authentication tokens --- ### Synopsis -```bash - npm token list [--json|--parseable] - npm token create [--read-only] [--cidr=1.1.1.1/24,2.2.2.2/16] - npm token revoke <id|token> -``` + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -76,56 +73,7 @@ This lets you list, create and revoke authentication tokens. ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `read-only` - -* Default: false -* Type: Boolean - -This is used to mark a token as unable to publish when configuring limited -access tokens with the `npm token create` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `cidr` - -* Default: null -* Type: null or String (can be set multiple times) - -This is a list of CIDR address to be used when configuring limited access -tokens with the `npm token create` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `otp` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with `npm access`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/lib/content/commands/npm-uninstall.md b/docs/lib/content/commands/npm-uninstall.md new file mode 100644 index 0000000..46e5af0 --- /dev/null +++ b/docs/lib/content/commands/npm-uninstall.md @@ -0,0 +1,63 @@ +--- +title: npm-uninstall +section: 1 +description: Remove a package +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This uninstalls a package, completely removing everything npm installed +on its behalf. + +It also removes the package from the `dependencies`, `devDependencies`, +`optionalDependencies`, and `peerDependencies` objects in your +`package.json`. + +Further, if you have an `npm-shrinkwrap.json` or `package-lock.json`, npm +will update those files as well. + +`--no-save` will tell npm not to remove the package from your +`package.json`, `npm-shrinkwrap.json`, or `package-lock.json` files. + +`--save` or `-S` will tell npm to remove the package from your +`package.json`, `npm-shrinkwrap.json`, and `package-lock.json` files. +This is the default, but you may need to use this if you have for +instance `save=false` in your `npmrc` file + +In global mode (ie, with `-g` or `--global` appended to the command), +it uninstalls the current package context as a global package. +`--no-save` is ignored in this case. + +Scope is optional and follows the usual rules for [`scope`](/using-npm/scope). + +### Examples + +```bash +npm uninstall sax +``` + +`sax` will no longer be in your `package.json`, `npm-shrinkwrap.json`, or +`package-lock.json` files. + +```bash +npm uninstall lodash --no-save +``` + +`lodash` will not be removed from your `package.json`, +`npm-shrinkwrap.json`, or `package-lock.json` files. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm prune](/commands/npm-prune) +* [npm install](/commands/npm-install) +* [npm folders](/configuring-npm/folders) +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) diff --git a/docs/lib/content/commands/npm-unpublish.md b/docs/lib/content/commands/npm-unpublish.md new file mode 100644 index 0000000..76f4cd0 --- /dev/null +++ b/docs/lib/content/commands/npm-unpublish.md @@ -0,0 +1,50 @@ +--- +title: npm-unpublish +section: 1 +description: Remove a package from the registry +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +To learn more about how the npm registry treats unpublish, see our <a +href="https://docs.npmjs.com/policies/unpublish" target="_blank" +rel="noopener noreferrer"> unpublish policies</a> + +### Warning + +Consider using the [`deprecate`](/commands/npm-deprecate) command instead, +if your intent is to encourage users to upgrade, or if you no longer +want to maintain a package. + +### Description + +This removes a package version from the registry, deleting its entry and +removing the tarball. + +The npm registry will return an error if you are not [logged +in](/commands/npm-adduser). + +If you do not specify a version or if you remove all of a package's +versions then the registry will remove the root package entry entirely. + +Even if you unpublish a package version, that specific name and version +combination can never be reused. In order to publish the package again, +you must use a new version number. If you unpublish the entire package, +you may not publish any new versions of that package until 24 hours have +passed. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [package spec](/using-npm/package-spec) +* [npm deprecate](/commands/npm-deprecate) +* [npm publish](/commands/npm-publish) +* [npm registry](/using-npm/registry) +* [npm adduser](/commands/npm-adduser) +* [npm owner](/commands/npm-owner) +* [npm login](/commands/npm-adduser) diff --git a/docs/lib/content/commands/npm-unstar.md b/docs/lib/content/commands/npm-unstar.md new file mode 100644 index 0000000..8891ece --- /dev/null +++ b/docs/lib/content/commands/npm-unstar.md @@ -0,0 +1,41 @@ +--- +title: npm-unstar +section: 1 +description: Remove an item from your favorite packages +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +Note: This command is unaware of workspaces. + +### Description + +"Unstarring" a package is the opposite of [`npm star`](/commands/npm-star), +it removes an item from your list of favorite packages. + +### More + +There's also these extra commands to help you manage your favorite packages: + +#### Star + +You can "star" a package using [`npm star`](/commands/npm-star) + +#### Listing stars + +You can see all your starred packages using [`npm stars`](/commands/npm-stars) + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm star](/commands/npm-star) +* [npm stars](/commands/npm-stars) +* [npm view](/commands/npm-view) +* [npm whoami](/commands/npm-whoami) +* [npm adduser](/commands/npm-adduser) + diff --git a/docs/lib/content/commands/npm-update.md b/docs/lib/content/commands/npm-update.md new file mode 100644 index 0000000..7e4f056 --- /dev/null +++ b/docs/lib/content/commands/npm-update.md @@ -0,0 +1,165 @@ +--- +title: npm-update +section: 1 +description: Update packages +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Description + +This command will update all the packages listed to the latest version +(specified by the [`tag` config](/using-npm/config#tag)), respecting the semver +constraints of both your package and its dependencies (if they also require the +same package). + +It will also install missing packages. + +If the `-g` flag is specified, this command will update globally installed +packages. + +If no package name is specified, all packages in the specified location (global +or local) will be updated. + +Note that by default `npm update` will not update the semver values of direct +dependencies in your project `package.json`, if you want to also update +values in `package.json` you can run: `npm update --save` (or add the +`save=true` option to a [configuration file](/configuring-npm/npmrc) +to make that the default behavior). + +### Example + +For the examples below, assume that the current package is `app` and it depends +on dependencies, `dep1` (`dep2`, .. etc.). The published versions of `dep1` +are: + +```json +{ + "dist-tags": { "latest": "1.2.2" }, + "versions": [ + "1.2.2", + "1.2.1", + "1.2.0", + "1.1.2", + "1.1.1", + "1.0.0", + "0.4.1", + "0.4.0", + "0.2.0" + ] +} +``` + +#### Caret Dependencies + +If `app`'s `package.json` contains: + +```json +"dependencies": { + "dep1": "^1.1.1" +} +``` + +Then `npm update` will install `dep1@1.2.2`, because `1.2.2` is `latest` and +`1.2.2` satisfies `^1.1.1`. + +#### Tilde Dependencies + +However, if `app`'s `package.json` contains: + +```json +"dependencies": { + "dep1": "~1.1.1" +} +``` + +In this case, running `npm update` will install `dep1@1.1.2`. Even though the +`latest` tag points to `1.2.2`, this version do not satisfy `~1.1.1`, which is +equivalent to `>=1.1.1 <1.2.0`. So the highest-sorting version that satisfies +`~1.1.1` is used, which is `1.1.2`. + +#### Caret Dependencies below 1.0.0 + +Suppose `app` has a caret dependency on a version below `1.0.0`, for example: + +```json +"dependencies": { + "dep1": "^0.2.0" +} +``` + +`npm update` will install `dep1@0.2.0`, because there are no other +versions which satisfy `^0.2.0`. + +If the dependence were on `^0.4.0`: + +```json +"dependencies": { + "dep1": "^0.4.0" +} +``` + +Then `npm update` will install `dep1@0.4.1`, because that is the highest-sorting +version that satisfies `^0.4.0` (`>= 0.4.0 <0.5.0`) + + +#### Subdependencies + +Suppose your app now also has a dependency on `dep2` + +```json +{ + "name": "my-app", + "dependencies": { + "dep1": "^1.0.0", + "dep2": "1.0.0" + } +} +``` + +and `dep2` itself depends on this limited range of `dep1` + +```json +{ +"name": "dep2", + "dependencies": { + "dep1": "~1.1.1" + } +} +``` + +Then `npm update` will install `dep1@1.1.2` because that is the highest +version that `dep2` allows. npm will prioritize having a single version +of `dep1` in your tree rather than two when that single version can +satisfy the semver requirements of multiple dependencies in your tree. +In this case if you really did need your package to use a newer version +you would need to use `npm install`. + + +#### Updating Globally-Installed Packages + +`npm update -g` will apply the `update` action to each globally installed +package that is `outdated` -- that is, has a version that is different from +`wanted`. + +Note: Globally installed packages are treated as if they are installed with a +caret semver range specified. So if you require to update to `latest` you may +need to run `npm install -g [<pkg>...]` + +NOTE: If a package has been upgraded to a version newer than `latest`, it will +be _downgraded_. + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See Also + +* [npm install](/commands/npm-install) +* [npm outdated](/commands/npm-outdated) +* [npm shrinkwrap](/commands/npm-shrinkwrap) +* [npm registry](/using-npm/registry) +* [npm folders](/configuring-npm/folders) +* [npm ls](/commands/npm-ls) diff --git a/docs/lib/content/commands/npm-version.md b/docs/lib/content/commands/npm-version.md new file mode 100644 index 0000000..08e74ef --- /dev/null +++ b/docs/lib/content/commands/npm-version.md @@ -0,0 +1,104 @@ +--- +title: npm-version +section: 1 +description: Bump a package version +--- + +### Synopsis + +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> + +### Configuration + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### Description + +Run this in a package directory to bump the version and write the new data +back to `package.json`, `package-lock.json`, and, if present, +`npm-shrinkwrap.json`. + +The `newversion` argument should be a valid semver string, a valid second +argument to [semver.inc](https://github.com/npm/node-semver#functions) (one +of `patch`, `minor`, `major`, `prepatch`, `preminor`, `premajor`, +`prerelease`), or `from-git`. In the second case, the existing version will +be incremented by 1 in the specified field. `from-git` will try to read +the latest git tag, and use that as the new npm version. + +If run in a git repo, it will also create a version commit and tag. This +behavior is controlled by `git-tag-version` (see below), and can be +disabled on the command line by running `npm --no-git-tag-version version`. +It will fail if the working directory is not clean, unless the `-f` or +`--force` flag is set. + +If supplied with `-m` or [`--message` config](/using-npm/config#message) option, +npm will use it as a commit message when creating a version commit. If the +`message` config contains `%s` then that will be replaced with the resulting +version number. For example: + +```bash +npm version patch -m "Upgrade to %s for reasons" +``` + +If the [`sign-git-tag` config](/using-npm/config#sign-git-tag) is set, then the +tag will be signed using the `-s` flag to git. Note that you must have a default +GPG key set up in your git config for this to work properly. For example: + +```bash +$ npm config set sign-git-tag true +$ npm version patch + +You need a passphrase to unlock the secret key for +user: "isaacs (http://blog.izs.me/) <i@izs.me>" +2048-bit RSA key, ID 6C481CF6, created 2010-08-31 + +Enter passphrase: +``` + +If `preversion`, `version`, or `postversion` are in the `scripts` property +of the package.json, they will be executed as part of running `npm +version`. + +The exact order of execution is as follows: + +1. Check to make sure the git working directory is clean before we get + started. Your scripts may add files to the commit in future steps. + This step is skipped if the `--force` flag is set. +2. Run the `preversion` script. These scripts have access to the old + `version` in package.json. A typical use would be running your full + test suite before deploying. Any files you want added to the commit + should be explicitly added using `git add`. +3. Bump `version` in `package.json` as requested (`patch`, `minor`, + `major`, etc). +4. Run the `version` script. These scripts have access to the new `version` + in package.json (so they can incorporate it into file headers in + generated files for example). Again, scripts should explicitly add + generated files to the commit using `git add`. +5. Commit and tag. +6. Run the `postversion` script. Use it to clean up the file system or + automatically push the commit and/or tag. + +Take the following example: + +```json +{ + "scripts": { + "preversion": "npm test", + "version": "npm run build && git add -A dist", + "postversion": "git push && git push --tags && rm -rf build/temp" + } +} +``` + +This runs all your tests and proceeds only if they pass. Then runs your +`build` script, and adds everything in the `dist` directory to the commit. +After the commit, it pushes the new commit and tag up to the server, and +deletes the `build/temp` directory. + +### See Also + +* [npm init](/commands/npm-init) +* [npm run-script](/commands/npm-run-script) +* [npm scripts](/using-npm/scripts) +* [package.json](/configuring-npm/package-json) +* [config](/using-npm/config) diff --git a/docs/content/commands/npm-view.md b/docs/lib/content/commands/npm-view.md similarity index 54% rename from docs/content/commands/npm-view.md rename to docs/lib/content/commands/npm-view.md index 9a1793f..a74427f 100644 --- a/docs/content/commands/npm-view.md +++ b/docs/lib/content/commands/npm-view.md @@ -6,11 +6,7 @@ description: View registry info ### Synopsis -```bash -npm view [<@scope>/]<name>[@<version>] [<field>[.<subfield>]...] - -aliases: info, show, v -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description @@ -63,6 +59,12 @@ contributor in the list, you can run: npm view express contributors[0].email ``` +If the field value you are querying for is a property of an object, you should run: + +```bash +npm view express time'[4.8.0]' +``` + Multiple fields may be specified, and will be printed one after another. For example, to get all the contributor names and email addresses, you can do this: @@ -96,85 +98,7 @@ npm view connect versions ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `json` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In `npm pkg set` it enables parsing set values with JSON.parse() before - saving them to your `package.json`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspace` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the `workspace` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the `npm init` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `workspaces` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like `install` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the `node_modules` tree (install, update, etc.) -will link workspaces into the `node_modules` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the `workspace` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### `include-workspace-root` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the `workspace` config, or -all workspaces via the `workspaces` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### Output @@ -192,6 +116,7 @@ the field name. ### See Also +* [package spec](/using-npm/package-spec) * [npm search](/commands/npm-search) * [npm registry](/using-npm/registry) * [npm config](/commands/npm-config) diff --git a/docs/content/commands/npm-whoami.md b/docs/lib/content/commands/npm-whoami.md similarity index 59% rename from docs/content/commands/npm-whoami.md rename to docs/lib/content/commands/npm-whoami.md index 2cd7ffd..5dfae17 100644 --- a/docs/content/commands/npm-whoami.md +++ b/docs/lib/content/commands/npm-whoami.md @@ -6,9 +6,7 @@ description: Display npm username ### Synopsis -```bash -npm whoami [--registry <registry>] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> Note: This command is unaware of workspaces. @@ -25,20 +23,7 @@ If logged into a registry that uses Basic Auth, then simply print the ### Configuration -<!-- AUTOGENERATED CONFIG DESCRIPTIONS START --> -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> -#### `registry` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -<!-- AUTOGENERATED CONFIG DESCRIPTIONS END --> +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> ### See Also diff --git a/docs/content/commands/npm.md b/docs/lib/content/commands/npm.md similarity index 98% rename from docs/content/commands/npm.md rename to docs/lib/content/commands/npm.md index de51087..d47a34e 100644 --- a/docs/content/commands/npm.md +++ b/docs/lib/content/commands/npm.md @@ -6,9 +6,7 @@ description: javascript package manager ### Synopsis -```bash -npm <command> [args] -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Version @@ -103,7 +101,7 @@ following help topics: done via [`npm install`](/commands/npm-install) * adduser: Create an account or log in. When you do this, npm will store - credentials in the user config file config file. + credentials in the user config file. * publish: Use the [`npm publish`](/commands/npm-publish) command to upload your code to the registry. diff --git a/docs/content/commands/npx.md b/docs/lib/content/commands/npx.md similarity index 91% rename from docs/content/commands/npx.md rename to docs/lib/content/commands/npx.md index c1aae0b..6d6aed6 100644 --- a/docs/content/commands/npx.md +++ b/docs/lib/content/commands/npx.md @@ -6,23 +6,7 @@ description: Run a command from a local or remote npm package ### Synopsis -```bash -npm exec -- <pkg>[@<version>] [args...] -npm exec --package=<pkg>[@<version>] -- <cmd> [args...] -npm exec -c '<cmd> [args...]' -npm exec --package=foo -c '<cmd> [args...]' - -npx <pkg>[@<specifier>] [args...] -npx -p <pkg>[@<specifier>] <cmd> [args...] -npx -c '<cmd> [args...]' -npx -p <pkg>[@<specifier>] -c '<cmd> [args...]' - -alias: npm x, npx - ---package=<pkg> (may be specified multiple times) --p is a shorthand for --package only when using npx executable --c <cmd> --call=<cmd> (may not be mixed with positional arguments) -``` +<!-- AUTOGENERATED USAGE DESCRIPTIONS --> ### Description diff --git a/docs/content/configuring-npm/folders.md b/docs/lib/content/configuring-npm/folders.md similarity index 81% rename from docs/content/configuring-npm/folders.md rename to docs/lib/content/configuring-npm/folders.md index 2188707..6295fd7 100644 --- a/docs/content/configuring-npm/folders.md +++ b/docs/lib/content/configuring-npm/folders.md @@ -22,10 +22,10 @@ This document will tell you what it puts where. #### prefix Configuration -The `prefix` config defaults to the location where node is installed. -On most systems, this is `/usr/local`. On Windows, it's `%AppData%\npm`. -On Unix systems, it's one level up, since node is typically installed at -`{prefix}/bin/node` rather than `{prefix}/node.exe`. +The [`prefix` config](/using-npm/config#prefix) defaults to the location where +node is installed. On most systems, this is `/usr/local`. On Windows, it's +`%AppData%\npm`. On Unix systems, it's one level up, since node is typically +installed at `{prefix}/bin/node` rather than `{prefix}/node.exe`. When the `global` flag is set, npm installs things into this prefix. When it is not set, it uses the root of the current package, or the @@ -74,13 +74,13 @@ Man pages are not installed on Windows systems. See [`npm cache`](/commands/npm-cache). Cache files are stored in `~/.npm` on Posix, or `%AppData%/npm-cache` on Windows. -This is controlled by the `cache` configuration param. +This is controlled by the [`cache` config](/using-npm/config#cache) param. #### Temp Files Temporary files are stored by default in the folder specified by the -`tmp` config, which defaults to the TMPDIR, TMP, or TEMP environment -variables, or `/tmp` on Unix and `c:\windows\temp` on Windows. +[`tmp` config](/using-npm/config#tmp), which defaults to the TMPDIR, TMP, or +TEMP environment variables, or `/tmp` on Unix and `c:\windows\temp` on Windows. Temp files are given a unique folder under this root for each run of the program, and are deleted upon successful exit. @@ -111,7 +111,7 @@ be found by npm scripts when necessary. #### Global Installation -If the `global` configuration is set to true, then npm will +If the [`global` config](/using-npm/config#global) is set to true, then npm will install packages "globally". For global installation, packages are installed roughly the same way, @@ -128,8 +128,8 @@ Consider the case above, where `foo -> bar -> baz`. Imagine if, in addition to that, baz depended on bar, so you'd have: `foo -> bar -> baz -> bar -> baz ...`. However, since the folder structure is: `foo/node_modules/bar/node_modules/baz`, there's no need to -put another copy of bar into `.../baz/node_modules`, since when it calls -require("bar"), it will get the copy that is installed in +put another copy of bar into `.../baz/node_modules`, since when baz calls +`require("bar")`, it will get the copy that is installed in `foo/node_modules/bar`. This shortcut is only used if the exact same @@ -140,7 +140,8 @@ exact same package multiple times, an infinite regress will always be prevented. Another optimization can be made by installing dependencies at the -highest level possible, below the localized "target" folder. +highest level possible, below the localized "target" folder (hoisting). +Since version 3, npm hoists dependencies by default. #### Example @@ -160,21 +161,19 @@ foo `-- bar ``` -In this case, we might expect a folder structure like this: +In this case, we might expect a folder structure like this +(with all dependencies hoisted to the highest level possible): ```bash foo +-- node_modules +-- blerg (1.2.5) <---[A] +-- bar (1.2.3) <---[B] - | `-- node_modules + | +-- node_modules | +-- baz (2.0.2) <---[C] - | | `-- node_modules - | | `-- quux (3.2.0) - | `-- asdf (2.3.4) - `-- baz (1.2.3) <---[D] - `-- node_modules - `-- quux (3.2.0) <---[E] + +-- asdf (2.3.4) + +-- baz (1.2.3) <---[D] + +-- quux (3.2.0) <---[E] ``` Since foo depends directly on `bar@1.2.3` and `baz@1.2.3`, those are @@ -185,24 +184,23 @@ dependency on version 1.2.5. So, that gets installed at [A]. Since the parent installation of blerg satisfies bar's dependency on `blerg@1.x`, it does not install another copy under [B]. -Bar [B] also has dependencies on baz and asdf, so those are installed in -bar's `node_modules` folder. Because it depends on `baz@2.x`, it cannot +Bar [B] also has dependencies on baz and asdf. Because it depends on `baz@2.x`, it cannot re-use the `baz@1.2.3` installed in the parent `node_modules` folder [D], -and must install its own copy [C]. +and must install its own copy [C]. In order to minimize duplication, npm hoists +dependencies to the top level by default, so asdf is installed under [A]. Underneath bar, the `baz -> quux -> bar` dependency creates a cycle. However, because bar is already in quux's ancestry [B], it does not -unpack another copy of bar into that folder. - -Underneath `foo -> baz` [D], quux's [E] folder tree is empty, because its -dependency on bar is satisfied by the parent folder copy installed at [B]. +unpack another copy of bar into that folder. Likewise, quux's [E] +folder tree is empty, because its dependency on bar is satisfied +by the parent folder copy installed at [B]. For a graphical breakdown of what is installed where, use `npm ls`. #### Publishing Upon publishing, npm will look in the `node_modules` folder. If any of -the items there are not in the `bundledDependencies` array, then they will +the items there are not in the `bundleDependencies` array, then they will not be included in the package tarball. This allows a package maintainer to install all of their dependencies diff --git a/docs/content/configuring-npm/install.md b/docs/lib/content/configuring-npm/install.md similarity index 100% rename from docs/content/configuring-npm/install.md rename to docs/lib/content/configuring-npm/install.md diff --git a/docs/content/configuring-npm/npm-shrinkwrap-json.md b/docs/lib/content/configuring-npm/npm-shrinkwrap-json.md similarity index 100% rename from docs/content/configuring-npm/npm-shrinkwrap-json.md rename to docs/lib/content/configuring-npm/npm-shrinkwrap-json.md diff --git a/docs/content/configuring-npm/npmrc.md b/docs/lib/content/configuring-npm/npmrc.md similarity index 70% rename from docs/content/configuring-npm/npmrc.md rename to docs/lib/content/configuring-npm/npmrc.md index 83310ff..8cd532a 100644 --- a/docs/content/configuring-npm/npmrc.md +++ b/docs/lib/content/configuring-npm/npmrc.md @@ -91,6 +91,43 @@ consistent across updates. Set fields in here using the `./configure` script that comes with npm. This is primarily for distribution maintainers to override default configs in a standard and consistent manner. +### Auth related configuration + +The settings `_auth`, `_authToken`, `username` and `_password` must all be +scoped to a specific registry. This ensures that `npm` will never send +credentials to the wrong host. + +The full list is: + - `_auth` (base64 authentication string) + - `_authToken` (authentication token) + - `username` + - `_password` + - `email` + - `certfile` (path to certificate file) + - `keyfile` (path to key file) + +In order to scope these values, they must be prefixed by a URI fragment. +If the credential is meant for any request to a registry on a single host, +the scope may look like `//registry.npmjs.org/:`. If it must be scoped to a +specific path on the host that path may also be provided, such as +`//my-custom-registry.org/unique/path:`. + +``` +; bad config +_authToken=MYTOKEN + +; good config +@myorg:registry=https://somewhere-else.com/myorg +@another:registry=https://somewhere-else.com/another +//registry.npmjs.org/:_authToken=MYTOKEN +; would apply to both @myorg and @another +; //somewhere-else.com/:_authToken=MYTOKEN +; would apply only to @myorg +//somewhere-else.com/myorg/:_authToken=MYTOKEN1 +; would apply only to @another +//somewhere-else.com/another/:_authToken=MYTOKEN2 +``` + ### See also * [npm folders](/configuring-npm/folders) diff --git a/docs/content/configuring-npm/package-json.md b/docs/lib/content/configuring-npm/package-json.md similarity index 92% rename from docs/content/configuring-npm/package-json.md rename to docs/lib/content/configuring-npm/package-json.md index 530df09..68a4a62 100644 --- a/docs/content/configuring-npm/package-json.md +++ b/docs/lib/content/configuring-npm/package-json.md @@ -124,7 +124,7 @@ IDs](https://spdx.org/licenses/). Ideally you should pick one that is If your package is licensed under multiple common licenses, use an [SPDX license expression syntax version 2.0 -string](https://www.npmjs.com/package/spdx), like this: +string](https://spdx.dev/specifications/), like this: ```json { @@ -222,7 +222,7 @@ npm also sets a top-level "maintainers" field with your npm user info. ### funding -You can specify an object containing an URL that provides up-to-date +You can specify an object containing a URL that provides up-to-date information about ways to help fund development of your package, or a string URL, or an array of these: @@ -323,7 +323,7 @@ This should be a module relative to the root of your package folder. For most modules, it makes the most sense to have a main script and often not much else. -If `main` is not set it defaults to `index.js` in the packages root folder. +If `main` is not set it defaults to `index.js` in the package's root folder. ### browser @@ -339,12 +339,14 @@ install into the PATH. npm makes this pretty easy (in fact, it uses this feature to install the "npm" executable.) To use this, supply a `bin` field in your package.json which is a map of -command name to local file name. When this package is installed -globally, that file will be linked where global bins go so it is -available to run by name. 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`. +command name to local file name. When this package is installed globally, +that file will be either linked inside the global bins directory or +a cmd (Windows Command File) will be created which executes the specified +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`. For example, myapp could have this: @@ -357,8 +359,10 @@ For example, myapp could have this: } ``` -So, when you install myapp, it'll create a symlink from the `cli.js` script -to `/usr/local/bin/myapp`. +So, when you install myapp, in case of unix-like OS it'll create a symlink +from the `cli.js` script to `/usr/local/bin/myapp` and in case of windows it +will create a cmd file usually at `C:\Users\{Username}\AppData\Roaming\npm\myapp.cmd` +which runs the `cli.js` script. If you have a single executable, and its name should be the name of the package, then you can just supply it as a string. For example: @@ -632,7 +636,7 @@ commit. If the commit-ish has the format `#semver:<semver>`, `<semver>` can be any valid semver range or exact version, and npm will look for any tags or refs matching that range in the remote repository, much as it would for a registry dependency. If neither `#<commit-ish>` or `#semver:<semver>` is -specified, then `master` is used. +specified, then the default branch is used. Examples: @@ -643,6 +647,26 @@ git+https://isaacs@github.com/npm/cli.git git://github.com/npm/cli.git#v1.0.27 ``` +When installing from a `git` repository, the presence of certain fields in the +`package.json` will cause npm to believe it needs to perform a build. To do so +your repository will be cloned into a temporary directory, all of its deps +installed, relevant scripts run, and the resulting directory packed and +installed. + +This flow will occur if your git dependency uses `workspaces`, or if any of the +following scripts are present: + +* `build` +* `prepare` +* `prepack` +* `preinstall` +* `install` +* `postinstall` + +If your git repository includes pre-built artifacts, you will likely want to +make sure that none of the above scripts are defined, or your dependency +will be rebuilt for every installation. + #### GitHub URLs As of version 1.1.65, you can refer to GitHub urls as just "foo": @@ -690,6 +714,10 @@ This feature is helpful for local offline development and creating tests that require npm installing where you don't want to hit an external server, but should not be used when publishing packages to the public registry. +*note*: Packages linked by local path will not have their own +dependencies installed when `npm install` is ran in this case. You must +run `npm install` from inside the local path itself. + ### devDependencies If someone is planning on downloading and using your module in their @@ -805,14 +833,14 @@ if the `soy-milk` package is not installed on the host. This allows you to integrate and interact with a variety of host packages without requiring all of them to be installed. -### bundledDependencies +### bundleDependencies This defines an array of package names that will be bundled when publishing the package. In cases where you need to preserve npm packages locally or have them available through a single file download, you can bundle the packages in a -tarball file by specifying the package names in the `bundledDependencies` +tarball file by specifying the package names in the `bundleDependencies` array and executing `npm pack`. For example: @@ -823,7 +851,7 @@ If we define a package.json like this: { "name": "awesome-web-framework", "version": "1.0.0", - "bundledDependencies": [ + "bundleDependencies": [ "renderized", "super-streams" ] @@ -836,9 +864,9 @@ can be installed in a new project by executing `npm install awesome-web-framework-1.0.0.tgz`. Note that the package names do not include any versions, as that information is specified in `dependencies`. -If this is spelled `"bundleDependencies"`, then that is also honored. +If this is spelled `"bundledDependencies"`, then that is also honored. -Alternatively, `"bundledDependencies"` can be defined as a boolean value. A +Alternatively, `"bundleDependencies"` can be defined as a boolean value. A value of `true` will bundle all dependencies, a value of `false` will bundle none. @@ -849,7 +877,7 @@ be found or fails to install, then you may put it in the `optionalDependencies` object. This is a map of package name to version or url, just like the `dependencies` object. The difference is that build failures do not cause installation to fail. Running `npm install ---no-optional` will prevent these dependencies from being installed. +--omit=optional` will prevent these dependencies from being installed. It is still your program's responsibility to handle the lack of the dependency. For example, something like this: @@ -1004,9 +1032,10 @@ capable of properly installing your program. For example: } ``` -Unless the user has set the `engine-strict` config flag, this field is -advisory only and will only produce warnings when your package is installed -as a dependency. +Unless the user has set the +[`engine-strict` config](/using-npm/config#engine-strict) flag, this field is +advisory only and will only produce warnings when your package is installed as a +dependency. ### os diff --git a/docs/content/configuring-npm/package-lock-json.md b/docs/lib/content/configuring-npm/package-lock-json.md similarity index 100% rename from docs/content/configuring-npm/package-lock-json.md rename to docs/lib/content/configuring-npm/package-lock-json.md diff --git a/docs/nav.yml b/docs/lib/content/nav.yml similarity index 94% rename from docs/nav.yml rename to docs/lib/content/nav.yml index a82847f..00e62ea 100644 --- a/docs/nav.yml +++ b/docs/lib/content/nav.yml @@ -18,9 +18,6 @@ - title: npm audit url: /commands/npm-audit description: Run a security audit - - title: npm bin - url: /commands/npm-bin - description: Display npm bin folder - title: npm bugs url: /commands/npm-bugs description: Bugs for a package in a web browser maybe @@ -96,6 +93,9 @@ - title: npm link url: /commands/npm-link description: Symlink a package folder + - title: npm login + url: /commands/npm-login + description: Login to a registry user account - title: npm logout url: /commands/npm-logout description: Log out of the registry @@ -132,6 +132,9 @@ - title: npm publish url: /commands/npm-publish description: Publish a package + - title: npm query + url: /commands/npm-query + description: Retrieve a filtered list of packages - title: npm rebuild url: /commands/npm-rebuild description: Rebuild a package @@ -150,9 +153,6 @@ - title: npm search url: /commands/npm-search description: Search for packages - - title: npm set-script - url: /commands/npm-set-script - description: Set tasks in the scripts section of package.json - title: npm shrinkwrap url: /commands/npm-shrinkwrap description: Lock down dependency versions for publication @@ -232,6 +232,9 @@ - title: Registry url: /using-npm/registry description: The JavaScript Package Registry + - title: Package spec + url: /using-npm/package-spec + description: Package name specifier - title: Config url: /using-npm/config description: About npm configuration @@ -250,6 +253,9 @@ - title: Organizations url: /using-npm/orgs description: Working with teams & organizations + - title: Dependency Selectors + url: /using-npm/dependency-selectors + description: Dependency Selector Syntax & Querying - title: Developers url: /using-npm/developers description: Developer guide diff --git a/docs/lib/content/using-npm/config.md b/docs/lib/content/using-npm/config.md new file mode 100644 index 0000000..14972ea --- /dev/null +++ b/docs/lib/content/using-npm/config.md @@ -0,0 +1,95 @@ +--- +title: config +section: 7 +description: More than you probably want to know about npm configuration +--- + +### Description + +npm gets its configuration values from the following sources, sorted by priority: + +#### Command Line Flags + +Putting `--foo bar` on the command line sets the `foo` configuration +parameter to `"bar"`. A `--` argument tells the cli parser to stop +reading flags. Using `--flag` without specifying any value will set +the value to `true`. + +Example: `--flag1 --flag2` will set both configuration parameters +to `true`, while `--flag1 --flag2 bar` will set `flag1` to `true`, +and `flag2` to `bar`. Finally, `--flag1 --flag2 -- bar` will set +both configuration parameters to `true`, and the `bar` is taken +as a command argument. + +#### Environment Variables + +Any environment variables that start with `npm_config_` will be +interpreted as a configuration parameter. For example, putting +`npm_config_foo=bar` in your environment will set the `foo` +configuration parameter to `bar`. Any environment configurations that +are not given a value will be given the value of `true`. Config +values are case-insensitive, so `NPM_CONFIG_FOO=bar` will work the +same. However, please note that inside [`scripts`](/using-npm/scripts) +npm will set its own environment variables and Node will prefer +those lowercase versions over any uppercase ones that you might set. +For details see [this issue](https://github.com/npm/npm/issues/14528). + +Notice that you need to use underscores instead of dashes, so `--allow-same-version` +would become `npm_config_allow_same_version=true`. + +#### npmrc Files + +The four relevant files are: + +* per-project configuration file (`/path/to/my/project/.npmrc`) +* per-user configuration file (defaults to `$HOME/.npmrc`; configurable via CLI + option `--userconfig` or environment variable `$NPM_CONFIG_USERCONFIG`) +* global configuration file (defaults to `$PREFIX/etc/npmrc`; configurable via + CLI option `--globalconfig` or environment variable `$NPM_CONFIG_GLOBALCONFIG`) +* npm's built-in configuration file (`/path/to/npm/npmrc`) + +See [npmrc](/configuring-npm/npmrc) for more details. + +#### Default Configs + +Run `npm config ls -l` to see a set of configuration parameters that are +internal to npm, and are defaults if nothing else is specified. + +### Shorthands and Other CLI Niceties + +The following shorthands are parsed on the command-line: + +<!-- AUTOGENERATED CONFIG SHORTHANDS --> + +If the specified configuration param resolves unambiguously to a known +configuration parameter, then it is expanded to that configuration +parameter. For example: + +```bash +npm ls --par +# same as: +npm ls --parseable +``` + +If multiple single-character shorthands are strung together, and the +resulting combination is unambiguously not some other configuration +param, then it is expanded to its various component pieces. For +example: + +```bash +npm ls -gpld +# same as: +npm ls --global --parseable --long --loglevel info +``` + +### Config Settings + +<!-- AUTOGENERATED CONFIG DESCRIPTIONS --> + +### See also + +* [npm config](/commands/npm-config) +* [npmrc](/configuring-npm/npmrc) +* [npm scripts](/using-npm/scripts) +* [npm folders](/configuring-npm/folders) +* [npm](/commands/npm) diff --git a/docs/lib/content/using-npm/dependency-selectors.md b/docs/lib/content/using-npm/dependency-selectors.md new file mode 100644 index 0000000..5cedf8f --- /dev/null +++ b/docs/lib/content/using-npm/dependency-selectors.md @@ -0,0 +1,207 @@ +--- +title: Dependency Selector Syntax & Querying +section: 7 +description: Dependency Selector Syntax & Querying +--- + +### Description + +The [`npm query`](/commands/npm-query) command exposes a new dependency selector syntax (informed by & respecting many aspects of the [CSS Selectors 4 Spec](https://dev.w3.org/csswg/selectors4/#relational)) which: + +- Standardizes the shape of, & querying of, dependency graphs with a robust object model, metadata & selector syntax +- Leverages existing, known language syntax & operators from CSS to make disparate package information broadly accessible +- Unlocks the ability to answer complex, multi-faceted questions about dependencies, their relationships & associative metadata +- Consolidates redundant logic of similar query commands in `npm` (ex. `npm fund`, `npm ls`, `npm outdated`, `npm audit` ...) + +### Dependency Selector Syntax `v1.0.0` + +#### Overview: + +- there is no "type" or "tag" selectors (ex. `div, h1, a`) as a dependency/target is the only type of `Node` that can be queried +- the term "dependencies" is in reference to any `Node` found in a `tree` returned by `Arborist` + +#### Combinators + +- `>` direct descendant/child +- ` ` any descendant/child +- `~` sibling + +#### Selectors + +- `*` universal selector +- `#<name>` dependency selector (equivalent to `[name="..."]`) +- `#<name>@<version>` (equivalent to `[name=<name>]:semver(<version>)`) +- `,` selector list delimiter +- `.` dependency type selector +- `:` pseudo selector + +#### Dependency Type Selectors + +- `.prod` dependency found in the `dependencies` section of `package.json`, or is a child of said dependency +- `.dev` dependency found in the `devDependencies` section of `package.json`, or is a child of said dependency +- `.optional` dependency found in the `optionalDependencies` section of `package.json`, or has `"optional": true` set in its entry in the `peerDependenciesMeta` section of `package.json`, or a child of said dependency +- `.peer` dependency found in the `peerDependencies` section of `package.json` +- `.workspace` dependency found in the [`workspaces`](https://docs.npmjs.com/cli/v8/using-npm/workspaces) section of `package.json` +- `.bundled` dependency found in the `bundleDependencies` section of `package.json`, or is a child of said dependency + +#### Pseudo Selectors +- [`:not(<selector>)`](https://developer.mozilla.org/en-US/docs/Web/CSS/:not) +- [`:has(<selector>)`](https://developer.mozilla.org/en-US/docs/Web/CSS/:has) +- [`:is(<selector list>)`](https://developer.mozilla.org/en-US/docs/Web/CSS/:is) +- [`:root`](https://developer.mozilla.org/en-US/docs/Web/CSS/:root) matches the root node/dependency +- [`:scope`](https://developer.mozilla.org/en-US/docs/Web/CSS/:scope) matches node/dependency it was queried against +- [`:empty`](https://developer.mozilla.org/en-US/docs/Web/CSS/:empty) when a dependency has no dependencies +- [`:private`](https://docs.npmjs.com/cli/v8/configuring-npm/package-json#private) when a dependency is private +- `:link` when a dependency is linked (for instance, workspaces or packages manually [`linked`](https://docs.npmjs.com/cli/v8/commands/npm-link) +- `:deduped` when a dependency has been deduped (note that this does *not* always mean the dependency has been hoisted to the root of node_modules) +- `:overridden` when a dependency has been overridden +- `:extraneous` when a dependency exists but is not defined as a dependency of any node +- `:invalid` when a dependency version is out of its ancestors specified range +- `:missing` when a dependency is not found on disk +- `:semver(<spec>, [selector], [function])` match a valid [`node-semver`](https://github.com/npm/node-semver) version or range to a selector +- `:path(<path>)` [glob](https://www.npmjs.com/package/glob) matching based on dependencies path relative to the project +- `:type(<type>)` [based on currently recognized types](https://github.com/npm/npm-package-arg#result-object) +- `:outdated(<type>)` when a dependency is outdated + +##### `:semver(<spec>, [selector], [function])` + +The `:semver()` pseudo selector allows comparing fields from each node's `package.json` using [semver](https://github.com/npm/node-semver#readme) methods. It accepts up to 3 parameters, all but the first of which are optional. + +- `spec` a semver version or range +- `selector` an attribute selector for each node (default `[version]`) +- `function` a semver method to apply, one of: `satisfies`, `intersects`, `subset`, `gt`, `gte`, `gtr`, `lt`, `lte`, `ltr`, `eq`, `neq` or the special function `infer` (default `infer`) + +When the special `infer` function is used the `spec` and the actual value from the node are compared. If both are versions, according to `semver.valid()`, `eq` is used. If both values are ranges, according to `!semver.valid()`, `intersects` is used. If the values are mixed types `satisfies` is used. + +Some examples: + +- `:semver(^1.0.0)` returns every node that has a `version` satisfied by the provided range `^1.0.0` +- `:semver(16.0.0, :attr(engines, [node]))` returns every node which has an `engines.node` property satisfying the version `16.0.0` +- `:semver(1.0.0, [version], lt)` every node with a `version` less than `1.0.0` + +##### `:outdated(<type>)` + +The `:outdated` pseudo selector retrieves data from the registry and returns information about which of your dependencies are outdated. The type parameter may be one of the following: + +- `any` (default) a version exists that is greater than the current one +- `in-range` a version exists that is greater than the current one, and satisfies at least one if its dependents +- `out-of-range` a version exists that is greater than the current one, does not satisfy at least one of its dependents +- `major` a version exists that is a semver major greater than the current one +- `minor` a version exists that is a semver minor greater than the current one +- `patch` a version exists that is a semver patch greater than the current one + +In addition to the filtering performed by the pseudo selector, some extra data is added to the resulting objects. The following data can be found under the `queryContext` property of each node. + +- `versions` an array of every available version of the given node +- `outdated.inRange` an array of objects, each with a `from` and `versions`, where `from` is the on-disk location of the node that depends on the current node and `versions` is an array of all available versions that satisfies that dependency. This is only populated if `:outdated(in-range)` is used. +- `outdated.outOfRange` an array of objects, identical in shape to `inRange`, but where the `versions` array is every available version that does not satisfy the dependency. This is only populated if `:outdated(out-of-range)` is used. + +Some examples: + +- `:root > :outdated(major)` returns every direct dependency that has a new semver major release +- `.prod:outdated(in-range)` returns production dependencies that have a new release that satisfies at least one of its edges in + +#### [Attribute Selectors](https://developer.mozilla.org/en-US/docs/Web/CSS/Attribute_selectors) + +The attribute selector evaluates the key/value pairs in `package.json` if they are `String`s. + +- `[]` attribute selector (ie. existence of attribute) +- `[attribute=value]` attribute value is equivalant... +- `[attribute~=value]` attribute value contains word... +- `[attribute*=value]` attribute value contains string... +- `[attribute|=value]` attribute value is equal to or starts with... +- `[attribute^=value]` attribute value starts with... +- `[attribute$=value]` attribute value ends with... + +#### `Array` & `Object` Attribute Selectors + +The generic `:attr()` pseudo selector standardizes a pattern which can be used for attribute selection of `Object`s, `Array`s or `Arrays` of `Object`s accessible via `Arborist`'s `Node.package` metadata. This allows for iterative attribute selection beyond top-level `String` evaluation. The last argument passed to `:attr()` must be an `attribute` selector or a nested `:attr()`. See examples below: + +#### `Objects` + +```css +/* return dependencies that have a `scripts.test` containing `"tap"` */ +*:attr(scripts, [test~=tap]) +``` + +#### Nested `Objects` + +Nested objects are expressed as sequential arguments to `:attr()`. + +```css +/* return dependencies that have a testling config for opera browsers */ +*:attr(testling, browsers, [~=opera]) +``` + +#### `Arrays` + +`Array`s specifically uses a special/reserved `.` character in place of a typical attribute name. `Arrays` also support exact `value` matching when a `String` is passed to the selector. + +##### Example of an `Array` Attribute Selection: +```css +/* removes the distinction between properties & arrays */ +/* ie. we'd have to check the property & iterate to match selection */ +*:attr([keywords^=react]) +*:attr(contributors, :attr([name~=Jordan])) +``` + +##### Example of an `Array` matching directly to a value: +```css +/* return dependencies that have the exact keyword "react" */ +/* this is equivalent to `*:keywords([value="react"])` */ +*:attr([keywords=react]) +``` + +##### Example of an `Array` of `Object`s: +```css +/* returns */ +*:attr(contributors, [email=ruyadorno@github.com]) +``` + +### Groups + +Dependency groups are defined by the package relationships to their ancestors (ie. the dependency types that are defined in `package.json`). This approach is user-centric as the ecosystem has been taught to think about dependencies in these groups first-and-foremost. Dependencies are allowed to be included in multiple groups (ex. a `prod` dependency may also be a `dev` dependency (in that it's also required by another `dev` dependency) & may also be `bundled` - a selector for that type of dependency would look like: `*.prod.dev.bundled`). + +- `.prod` +- `.dev` +- `.optional` +- `.peer` +- `.bundled` +- `.workspace` + +Please note that currently `workspace` deps are always `prod` dependencies. Additionally the `.root` dependency is also considered a `prod` dependency. + +### Programmatic Usage + +- `Arborist`'s `Node` Class has a `.querySelectorAll()` method + - this method will return a filtered, flattened dependency Arborist `Node` list based on a valid query selector + +```js +const Arborist = require('@npmcli/arborist') +const arb = new Arborist({}) +``` + +```js +// root-level +arb.loadActual().then(async (tree) => { + // query all production dependencies + const results = await tree.querySelectorAll('.prod') + console.log(results) +}) +``` + +```js +// iterative +arb.loadActual().then(async (tree) => { + // query for the deduped version of react + const results = await tree.querySelectorAll('#react:not(:deduped)') + // query the deduped react for git deps + const deps = await results[0].querySelectorAll(':type(git)') + console.log(deps) +}) +``` + +## See Also + +* [npm query](/commands/npm-query) +* [@npmcli/arborist](https://npm.im/@npmcli/arborist) diff --git a/docs/content/using-npm/developers.md b/docs/lib/content/using-npm/developers.md similarity index 100% rename from docs/content/using-npm/developers.md rename to docs/lib/content/using-npm/developers.md diff --git a/docs/lib/content/using-npm/logging.md b/docs/lib/content/using-npm/logging.md new file mode 100644 index 0000000..4470d5d --- /dev/null +++ b/docs/lib/content/using-npm/logging.md @@ -0,0 +1,96 @@ +--- +title: Logging +section: 7 +description: Why, What & How We Log +--- + +### Description + +The `npm` CLI has various mechanisms for showing different levels of information back to end-users for certain commands, configurations & environments. + +### Setting Log File Location + +All logs are written to a debug log, with the path to that file printed if the execution of a command fails. + +The default location of the logs directory is a directory named `_logs` inside the npm cache. This can be changed with the `logs-dir` config option. + +For example, if you wanted to write all your logs to the current working directory, you could run: `npm install --logs-dir=.`. This is especially helpful in debugging a specific `npm` issue as you can run +a command multiple times with different config values and then diff all the log files. + +Log files will be removed from the `logs-dir` when the number of log files exceeds `logs-max`, with the oldest logs being deleted first. + +To turn off logs completely set `--logs-max=0`. + +### Setting Log Levels + +#### `loglevel` + +`loglevel` is a global argument/config that can be set to determine the type of information to be displayed. + +The default value of `loglevel` is `"notice"` but there are several levels/types of logs available, including: + +- `"silent"` +- `"error"` +- `"warn"` +- `"notice"` +- `"http"` +- `"info"` +- `"verbose"` +- `"silly"` + +All logs pertaining to a level proceeding the current setting will be shown. + +##### Aliases + +The log levels listed above have various corresponding aliases, including: + +- `-d`: `--loglevel info` +- `--dd`: `--loglevel verbose` +- `--verbose`: `--loglevel verbose` +- `--ddd`: `--loglevel silly` +- `-q`: `--loglevel warn` +- `--quiet`: `--loglevel warn` +- `-s`: `--loglevel silent` +- `--silent`: `--loglevel silent` + +#### `foreground-scripts` + +The `npm` CLI began hiding the output of lifecycle scripts for `npm install` as of `v7`. Notably, this means you will not see logs/output from packages that may be using "install scripts" to display information back to you or from your own project's scripts defined in `package.json`. If you'd like to change this behavior & log this output you can set `foreground-scripts` to `true`. + +### Timing Information + +The [`--timing` config](/using-npm/config#timing) can be set which does a few +things: + +1. Always shows the full path to the debug log regardless of command exit status +1. Write timing information to a process specific timing file in the cache or `logs-dir` +1. Output timing information to the terminal + +This file contains a `timers` object where the keys are an identifier for the +portion of the process being timed and the value is the number of milliseconds it took to complete. + +Sometimes it is helpful to get timing information without outputting anything to the terminal. For +example, the performance might be affected by writing to the terminal. In this case you can use +`--timing --silent` which will still write the timing file, but not output anything to the terminal +while running. + +### Registry Response Headers + +#### `npm-notice` + +The `npm` CLI reads from & logs any `npm-notice` headers that are returned from the configured registry. This mechanism can be used by third-party registries to provide useful information when network-dependent requests occur. + +This header is not cached, and will not be logged if the request is served from the cache. + +### Logs and Sensitive Information + +The `npm` CLI makes a best effort to redact the following from terminal output and log files: + +- Passwords inside basic auth URLs +- npm tokens + +However, this behavior should not be relied on to keep all possible sensitive information redacted. If you are concerned about secrets in your log file or terminal output, you can use `--loglevel=silent` and `--logs-max=0` to ensure no logs are written to your terminal or filesystem. + +### See also + +* [config](/using-npm/config) diff --git a/docs/content/using-npm/orgs.md b/docs/lib/content/using-npm/orgs.md similarity index 100% rename from docs/content/using-npm/orgs.md rename to docs/lib/content/using-npm/orgs.md diff --git a/docs/lib/content/using-npm/package-spec.md b/docs/lib/content/using-npm/package-spec.md new file mode 100644 index 0000000..1ace780 --- /dev/null +++ b/docs/lib/content/using-npm/package-spec.md @@ -0,0 +1,106 @@ +--- +title: package-spec +section: 7 +description: Package name specifier +--- + + +### Description + +Commands like `npm install` and the dependency sections in the +`package.json` use a package name specifier. This can be many different +things that all refer to a "package". Examples include a package name, +git url, tarball, or local directory. These will generally be referred +to as `<package-spec>` in the help output for the npm commands that use +this package name specifier. + +### Package name + +* `[<@scope>/]<pkg>` +* `[<@scope>/]<pkg>@<tag>` +* `[<@scope>/]<pkg>@<version>` +* `[<@scope>/]<pkg>@<version range>` + +Refers to a package by name, with or without a scope, and optionally +tag, version, or version range. This is typically used in combination +with the [registry](/using-npm/config#registry) config to refer to a +package in a registry. + +Examples: +* `npm` +* `@npmcli/arborist` +* `@npmcli/arborist@latest` +* `npm@6.13.1` +* `npm@^4.0.0` + +### Aliases + +* `<alias>@npm:<name>` + +Primarily used by commands like `npm install` and in the dependency +sections in the `package.json`, this refers to a package by an alias. +The `<alias>` is the name of the package as it is reified in the +`node_modules` folder, and the `<name>` refers to a package name as +found in the configured registry. + +See `Package name` above for more info on referring to a package by +name, and [registry](/using-npm/config#registry) for configuring which +registry is used when referring to a package by name. + +Examples: +* `semver:@npm:@npmcli/semver-with-patch` +* `semver:@npm:semver@7.2.2` +* `semver:@npm:semver@legacy` + +### Folders + +* `<folder>` + +This refers to a package on the local filesystem. Specifically this is +a folder with a `package.json` file in it. This *should* always be +prefixed with a `/` or `./` (or your OS equivalent) to reduce confusion. +npm currently will parse a string with more than one `/` in it as a +folder, but this is legacy behavior that may be removed in a future +version. + +Examples: + +* `./my-package` +* `/opt/npm/my-package` + +### Tarballs + +* `<tarball file>` +* `<tarball url>` + +Examples: + +* `./my-package.tgz` +* `https://registry.npmjs.org/semver/-/semver-1.0.0.tgz` + +Refers to a package in a tarball format, either on the local filesystem +or remotely via url. This is the format that packages exist in when +uploaded to a registry. + +### git urls + +* `<git:// url>` +* `<github username>/<github project>` + +Refers to a package in a git repo. This can be a full git url, git +shorthand, or a username/package on GitHub. You can specify a +git tag, branch, or other git ref by appending `#ref`. + +Examples: + +* `https://github.com/npm/cli.git` +* `git@github.com:npm/cli.git` +* `git+ssh://git@github.com/npm/cli#v6.0.0` +* `github:npm/cli#HEAD` +* `npm/cli#c12ea07` + +### See also + +* [npm-package-arg](https://npm.im/npm-package-arg) +* [scope](/using-npm/scope) +* [config](/using-npm/config) diff --git a/docs/content/using-npm/registry.md b/docs/lib/content/using-npm/registry.md similarity index 87% rename from docs/content/using-npm/registry.md rename to docs/lib/content/using-npm/registry.md index 4a265db..8d5ac94 100644 --- a/docs/content/using-npm/registry.md +++ b/docs/lib/content/using-npm/registry.md @@ -26,9 +26,14 @@ The npm public registry is powered by a CouchDB database, of which there is a public mirror at <https://skimdb.npmjs.com/registry>. The registry URL used is determined by the scope of the package (see -[`scope`](/using-npm/scope). If no scope is specified, the default registry is used, which is -supplied by the `registry` config parameter. See [`npm config`](/commands/npm-config), -[`npmrc`](/configuring-npm/npmrc), and [`config`](/using-npm/config) for more on managing npm's configuration. +[`scope`](/using-npm/scope). If no scope is specified, the default registry is +used, which is supplied by the [`registry` config](/using-npm/config#registry) +parameter. See [`npm config`](/commands/npm-config), +[`npmrc`](/configuring-npm/npmrc), and [`config`](/using-npm/config) for more on +managing npm's configuration. +Authentication configuration such as auth tokens and certificates are configured +specifically scoped to an individual registry. See +[Auth Related Configuration](/configuring-npm/npmrc#auth-related-configuration) When the default registry is used in a package-lock or shrinkwrap is has the special meaning of "the currently configured registry". If you create a lock @@ -69,7 +74,7 @@ to force it to be published only to your internal/private registry. See [`package.json`](/configuring-npm/package-json) for more info on what goes in the package.json file. -### Where can I find my own, & other's, published packages? +### Where can I find my (and others') published packages? <https://www.npmjs.com/> diff --git a/docs/content/using-npm/removal.md b/docs/lib/content/using-npm/removal.md similarity index 100% rename from docs/content/using-npm/removal.md rename to docs/lib/content/using-npm/removal.md diff --git a/docs/content/using-npm/scope.md b/docs/lib/content/using-npm/scope.md similarity index 83% rename from docs/content/using-npm/scope.md rename to docs/lib/content/using-npm/scope.md index 911d7ea..829e6cc 100644 --- a/docs/content/using-npm/scope.md +++ b/docs/lib/content/using-npm/scope.md @@ -79,9 +79,23 @@ If you wish, you may associate a scope with a registry; see below. #### Publishing public scoped packages to the primary npm registry -To publish a public scoped package, you must specify `--access public` with -the initial publication. This will publish the package and set access -to `public` as if you had run `npm access public` after publishing. +Publishing to a scope, you have two options: + +- Publishing to your user scope (example: `@username/module`) +- Publishing to an organization scope (example: `@org/module`) + +If publishing a public module to an organization scope, you must +first either create an organization with the name of the scope +that you'd like to publish to or be added to an existing organization +with the appropriate permissions. For example, if you'd like to +publish to `@org`, you would need to create the `org` organization +on npmjs.com prior to trying to publish. + +Scoped packages are not public by default. You will need to specify +`--access public` with the initial `npm publish` command. This will publish +the package and set access to `public` as if you had run `npm access public` +after publishing. You do not need to do this when publishing new versions of +an existing scoped package. #### Publishing private scoped packages to the npm registry diff --git a/docs/content/using-npm/scripts.md b/docs/lib/content/using-npm/scripts.md similarity index 92% rename from docs/content/using-npm/scripts.md rename to docs/lib/content/using-npm/scripts.md index a3fa868..1c921eb 100644 --- a/docs/content/using-npm/scripts.md +++ b/docs/lib/content/using-npm/scripts.md @@ -39,15 +39,13 @@ There are some special life cycle scripts that happen only in certain situations. These scripts happen in addition to the `pre<event>`, `post<event>`, and `<event>` scripts. -* `prepare`, `prepublish`, `prepublishOnly`, `prepack`, `postpack` +* `prepare`, `prepublish`, `prepublishOnly`, `prepack`, `postpack`, `dependencies` **prepare** (since `npm@4.0.0`) -* Runs any time before the package is packed, i.e. during `npm publish` +* Runs BEFORE the package is packed, i.e. during `npm publish` and `npm pack` -* Runs BEFORE the package is packed -* Runs BEFORE the package is published * Runs on local `npm install` without any arguments -* Run AFTER `prepublish`, but BEFORE `prepublishOnly` +* Runs AFTER `prepublish`, but BEFORE `prepublishOnly` * NOTE: If a package being installed through git contains a `prepare` script, its `dependencies` and `devDependencies` will be installed, and @@ -71,6 +69,10 @@ situations. These scripts happen in addition to the `pre<event>`, `post<event>`, **postpack** * Runs AFTER the tarball has been generated but before it is moved to its final destination (if at all, publish does not save the tarball locally) +**dependencies** +* Runs AFTER any operations that modify the `node_modules` directory IF changes occurred. +* Does NOT run in global mode + #### Prepare and Prepublish **Deprecation Note: prepublish** @@ -96,6 +98,10 @@ The advantage of doing these things at `prepublish` time is that they can be don * You don't need to rely on your users having `curl` or `wget` or other system tools on the target machines. +#### Dependencies + +The `dependencies` script is run any time an `npm` command causes changes to the `node_modules` directory. It is run AFTER the changes have been applied and the `package.json` and `package-lock.json` files have been updated. + ### Life Cycle Operation Order #### [`npm cache add`](/commands/npm-cache) @@ -203,6 +209,12 @@ will default the `start` command to `node server.js`. `prestart` and * `test` * `posttest` +#### [`npm version`](/commands/npm-version) + +* `preversion` +* `version` +* `postversion` + #### A Note on a lack of [`npm uninstall`](/commands/npm-uninstall) scripts While npm v6 had `uninstall` lifecycle scripts, npm v7 does not. Removal of a package can happen for a wide variety of reasons, and there's no clear way to currently give the script enough context to be useful. @@ -339,11 +351,16 @@ file. * Don't prefix your script commands with "sudo". If root permissions are required for some reason, then it'll fail with that error, and the user will sudo the npm command in question. -* Don't use `install`. Use a `.gyp` file for compilation, and `prepublish` +* Don't use `install`. Use a `.gyp` file for compilation, and `prepare` for anything else. You should almost never have to explicitly set a preinstall or install script. If you are doing this, please consider if there is another option. The only valid use of `install` or `preinstall` scripts is for compilation which must be done on the target architecture. +* Scripts are run from the root of the package folder, regardless of what the + current working directory is when `npm` is invoked. If you want your + script to use different behavior based on what subdirectory you're in, you + can use the `INIT_CWD` environment variable, which holds the full path you + were in when you ran `npm run`. ### See Also diff --git a/docs/content/using-npm/workspaces.md b/docs/lib/content/using-npm/workspaces.md similarity index 91% rename from docs/content/using-npm/workspaces.md rename to docs/lib/content/using-npm/workspaces.md index 26d6a5d..bbfa2d8 100644 --- a/docs/content/using-npm/workspaces.md +++ b/docs/lib/content/using-npm/workspaces.md @@ -57,7 +57,7 @@ structure of files and folders: ``` . +-- node_modules -| `-- packages/a -> ../packages/a +| `-- a -> ../packages/a +-- package-lock.json +-- package.json `-- packages @@ -112,15 +112,15 @@ respect the provided `workspace` configuration. Given the [specifities of how Node.js handles module resolution](https://nodejs.org/dist/latest-v14.x/docs/api/modules.html#modules_all_together) it's possible to consume any defined workspace by its declared `package.json` `name`. Continuing from the example defined -above, let's also create a Node.js script that will require the `workspace-a` +above, let's also create a Node.js script that will require the workspace `a` example module, e.g: ``` -// ./workspace-a/index.js +// ./packages/a/index.js module.exports = 'a' // ./lib/index.js -const moduleA = require('workspace-a') +const moduleA = require('a') console.log(moduleA) // -> a ``` @@ -137,6 +137,8 @@ nested workspaces to be consumed elsewhere. You can use the `workspace` configuration option to run commands in the context of a configured workspace. +Additionally, if your current directory is in a workspace, the `workspace` +configuration is implicitly set, and `prefix` is set to the root workspace. Following is a quick example on how to use the `npm run` command in the context of nested workspaces. For a project containing multiple workspaces, e.g: @@ -158,7 +160,13 @@ given command in the context of that specific workspace. e.g: npm run test --workspace=a ``` -This will run the `test` script defined within the +You could also run the command within the workspace. + +``` +cd packages/a && npm run test +``` + +Either will run the `test` script defined within the `./packages/a/package.json` file. Please note that you can also specify this argument multiple times in the @@ -168,6 +176,11 @@ command-line in order to target multiple workspaces, e.g: npm run test --workspace=a --workspace=b ``` +Or run the command for each workspace within the 'packages' folder: +``` +npm run test --workspace=packages +``` + It's also possible to use the `workspaces` (plural) configuration option to enable the same behavior but running that command in the context of **all** configured workspaces. e.g: diff --git a/docs/lib/index.js b/docs/lib/index.js new file mode 100644 index 0000000..74aa032 --- /dev/null +++ b/docs/lib/index.js @@ -0,0 +1,175 @@ +const localeCompare = require('@isaacs/string-locale-compare')('en') +const { join, basename, resolve } = require('path') +const transformHTML = require('./transform-html.js') +const { version } = require('../../lib/npm.js') +const { aliases } = require('../../lib/utils/cmd-list') +const { shorthands, definitions } = require('../../lib/utils/config/index.js') + +const DOC_EXT = '.md' + +const TAGS = { + CONFIG: '<!-- AUTOGENERATED CONFIG DESCRIPTIONS -->', + USAGE: '<!-- AUTOGENERATED USAGE DESCRIPTIONS -->', + SHORTHANDS: '<!-- AUTOGENERATED CONFIG SHORTHANDS -->', +} + +const assertPlaceholder = (src, path, placeholder) => { + if (!src.includes(placeholder)) { + throw new Error( + `Cannot replace ${placeholder} in ${path} due to missing placeholder` + ) + } + return placeholder +} + +const getCommandByDoc = (docFile, docExt) => { + // Grab the command name from the *.md filename + // NOTE: We cannot use the name property command file because in the case of + // `npx` the file being used is `lib/commands/exec.js` + const name = basename(docFile, docExt).replace('npm-', '') + + if (name === 'npm') { + return { + name, + params: null, + usage: 'npm', + } + } + + // special case for `npx`: + // `npx` is not technically a command in and of itself, + // so it just needs the usage of npm exex + const srcName = name === 'npx' ? 'exec' : name + const { params, usage = [''] } = require(`../../lib/commands/${srcName}`) + const usagePrefix = name === 'npx' ? 'npx' : `npm ${name}` + + return { + name, + params: name === 'npx' ? null : params, + usage: usage.map(u => `${usagePrefix} ${u}`.trim()).join('\n'), + } +} + +const replaceVersion = (src) => src.replace(/@VERSION@/g, version) + +const replaceUsage = (src, { path }) => { + const replacer = assertPlaceholder(src, path, TAGS.USAGE) + const { usage, name } = getCommandByDoc(path, DOC_EXT) + + const synopsis = ['```bash', usage] + + const cmdAliases = Object.keys(aliases).reduce((p, c) => { + if (aliases[c] === name) { + p.push(c) + } + return p + }, []) + + if (cmdAliases.length === 1) { + synopsis.push('') + synopsis.push(`alias: ${cmdAliases[0]}`) + } else if (cmdAliases.length > 1) { + synopsis.push('') + synopsis.push(`aliases: ${cmdAliases.join(', ')}`) + } + + synopsis.push('```') + + return src.replace(replacer, synopsis.join('\n')) +} + +const replaceParams = (src, { path }) => { + const { params } = getCommandByDoc(path, DOC_EXT) + const replacer = params && assertPlaceholder(src, path, TAGS.CONFIG) + + if (!params) { + return src + } + + const paramsConfig = params.map((n) => definitions[n].describe()) + + return src.replace(replacer, paramsConfig.join('\n\n')) +} + +const replaceConfig = (src, { path }) => { + const replacer = assertPlaceholder(src, path, TAGS.CONFIG) + + // sort not-deprecated ones to the top + /* istanbul ignore next - typically already sorted in the definitions file, + * but this is here so that our help doc will stay consistent if we decide + * to move them around. */ + const sort = ([keya, { deprecated: depa }], [keyb, { deprecated: depb }]) => { + return depa && !depb ? 1 + : !depa && depb ? -1 + : localeCompare(keya, keyb) + } + + const allConfig = Object.entries(definitions).sort(sort) + .map(([_, def]) => def.describe()) + .join('\n\n') + + return src.replace(replacer, allConfig) +} + +const replaceShorthands = (src, { path }) => { + const replacer = assertPlaceholder(src, path, TAGS.SHORTHANDS) + + const sh = Object.entries(shorthands) + .sort(([shorta, expansiona], [shortb, expansionb]) => + // sort by what they're short FOR + localeCompare(expansiona.join(' '), expansionb.join(' ')) || localeCompare(shorta, shortb) + ) + .map(([short, expansion]) => { + // XXX: this is incorrect. we have multicharacter flags like `-iwr` that + // can only be set with a single dash + const dash = short.length === 1 ? '-' : '--' + return `* \`${dash}${short}\`: \`${expansion.join(' ')}\`` + }) + + return src.replace(replacer, sh.join('\n')) +} + +const replaceHelpLinks = (src) => { + // replaces markdown links with equivalent-ish npm help commands + return src.replace( + /\[`?([\w\s-]+)`?\]\(\/(?:commands|configuring-npm|using-npm)\/(?:[\w\s-]+)\)/g, + (_, p1) => { + const term = p1.replace(/npm\s/g, '').replace(/\s+/g, ' ').trim() + const help = `npm help ${term.includes(' ') ? `"${term}"` : term}` + return help + } + ) +} + +const transformMan = (src, { data, unified, remarkParse, remarkMan }) => unified() + .use(remarkParse) + .use(remarkMan) + .processSync(`# ${data.title}(${data.section}) - ${data.description}\n\n${src}`) + .toString() + +const manPath = (name, { data }) => join(`man${data.section}`, `${name}.${data.section}`) + +const transformMd = (src, { frontmatter }) => ['---', frontmatter, '---', '', src].join('\n') + +module.exports = { + DOC_EXT, + TAGS, + paths: { + content: resolve(__dirname, 'content'), + nav: resolve(__dirname, 'content', 'nav.yml'), + template: resolve(__dirname, 'template.html'), + man: resolve(__dirname, '..', '..', 'man'), + html: resolve(__dirname, '..', 'output'), + md: resolve(__dirname, '..', 'content'), + }, + usage: replaceUsage, + params: replaceParams, + config: replaceConfig, + shorthands: replaceShorthands, + version: replaceVersion, + helpLinks: replaceHelpLinks, + man: transformMan, + manPath: manPath, + md: transformMd, + html: transformHTML, +} diff --git a/docs/template.html b/docs/lib/template.html similarity index 100% rename from docs/template.html rename to docs/lib/template.html diff --git a/docs/lib/transform-html.js b/docs/lib/transform-html.js new file mode 100644 index 0000000..c587d75 --- /dev/null +++ b/docs/lib/transform-html.js @@ -0,0 +1,157 @@ +const jsdom = require('jsdom') + +function transformHTML ( + src, + { path, template, data, unified, remarkParse, remarkGfm, remarkRehype, rehypeStringify } +) { + const content = unified() + .use(remarkParse) + .use(remarkGfm, { + singleTilde: false, + }) + .use(remarkRehype) + .use(rehypeStringify) + .processSync(src) + .toString() + + // Inject this data into the template, using a mustache-like + // replacement scheme. + const html = template.replace(/{{\s*([\w.]+)\s*}}/g, (token, key) => { + switch (key) { + case 'content': + return `<div id="_content">${content}</div>` + case 'url_path': + return encodeURI(path) + + case 'toc': + return '<div id="_table_of_contents"></div>' + + case 'title': + case 'section': + case 'description': + return data[key] + + case 'config.github_repo': + case 'config.github_branch': + case 'config.github_path': + return data[key.replace(/^config\./, '')] + + default: + throw new Error(`warning: unknown token '${token}' in ${path}`) + } + }) + + const dom = new jsdom.JSDOM(html) + const document = dom.window.document + + // Rewrite relative URLs in links and image sources to be relative to + // this file; this is for supporting `file://` links. HTML pages need + // suffix appended. + const links = [ + { tag: 'a', attr: 'href', suffix: '.html' }, + { tag: 'img', attr: 'src' }, + ] + + for (const linktype of links) { + for (const tag of document.querySelectorAll(linktype.tag)) { + let url = tag.getAttribute(linktype.attr) + + if (url.startsWith('/')) { + const childDepth = path.split('/').length - 1 + const prefix = childDepth > 0 ? '../'.repeat(childDepth) : './' + + url = url.replace(/^\//, prefix) + + if (linktype.suffix) { + url += linktype.suffix + } + + tag.setAttribute(linktype.attr, url) + } + } + } + + // Give headers a unique id so that they can be linked within the doc + const headerIds = [] + for (const header of document.querySelectorAll('h1, h2, h3, h4, h5, h6')) { + const headerText = header.textContent + .replace(/[A-Z]/g, x => x.toLowerCase()) + .replace(/ /g, '-') + .replace(/[^a-z0-9-]/g, '') + let headerId = headerText + let headerIncrement = 1 + + while (document.getElementById(headerId) !== null) { + headerId = headerText + ++headerIncrement + } + + headerIds.push(headerId) + header.setAttribute('id', headerId) + } + + // Walk the dom and build a table of contents + const tocEl = document.getElementById('_table_of_contents') + if (tocEl) { + const toc = generateTableOfContents(document) + if (toc) { + tocEl.appendChild(toc) + } + } + + return dom.serialize() +} + +function generateTableOfContents (document) { + const headers = walkHeaders(document.getElementById('_content')) + + // The nesting depth of headers are not necessarily the header level. + // (eg, h1 > h3 > h5 is a depth of three even though there's an h5.) + const hierarchy = [] + for (const header of headers) { + const level = headerLevel(header) + + while (hierarchy.length && hierarchy[hierarchy.length - 1].headerLevel > level) { + hierarchy.pop() + } + + if (!hierarchy.length || hierarchy[hierarchy.length - 1].headerLevel < level) { + const newList = document.createElement('ul') + newList.headerLevel = level + + if (hierarchy.length) { + hierarchy[hierarchy.length - 1].appendChild(newList) + } + + hierarchy.push(newList) + } + + const element = document.createElement('li') + + const link = document.createElement('a') + link.setAttribute('href', `#${header.getAttribute('id')}`) + link.innerHTML = header.innerHTML + element.appendChild(link) + + hierarchy[hierarchy.length - 1].appendChild(element) + } + + return hierarchy[0] +} + +function walkHeaders (element, headers = []) { + for (const child of element.childNodes) { + if (headerLevel(child)) { + headers.push(child) + } + + walkHeaders(child, headers) + } + return headers +} + +function headerLevel (node) { + const level = node.tagName ? node.tagName.match(/^[Hh]([123456])$/) : null + return level ? level[1] : 0 +} + +module.exports = transformHTML diff --git a/docs/package.json b/docs/package.json index be36f20..704ff75 100644 --- a/docs/package.json +++ b/docs/package.json @@ -1,21 +1,67 @@ { - "name": "docs", + "name": "@npmcli/docs", "description": "The npm cli documentation", "version": "1.0.0", + "private": true, + "main": "lib/index.js", "scripts": { - "build": "node dockhand", - "eslint": "eslint", - "lint": "npm run eslint -- ./*.js" + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "node .. run lint -- --fix", + "snap": "tap", + "test": "tap", + "posttest": "node .. run lint", + "build": "node bin/build.js" }, "repository": { "type": "git", - "url": "https://github.com/npm/cli" + "url": "https://github.com/npm/cli.git", + "directory": "docs" }, "devDependencies": { - "@mdx-js/mdx": "^1.6.22", - "cmark-gfm": "^0.9.0", - "jsdom": "^18.1.0", - "marked-man": "^0.7.0", - "yaml": "^1.10.0" + "@isaacs/string-locale-compare": "^1.1.0", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "front-matter": "^4.0.2", + "ignore-walk": "^6.0.0", + "jsdom": "^20.0.3", + "mkdirp": "^1.0.4", + "rehype-stringify": "^9.0.3", + "remark-gfm": "^3.0.1", + "remark-man": "^8.0.1", + "remark-parse": "^10.0.1", + "remark-rehype": "^10.1.0", + "tap": "^16.3.2", + "unified": "^10.1.2", + "yaml": "^2.1.3" + }, + "author": "GitHub Inc.", + "license": "ISC", + "files": [ + "bin/", + "lib/" + ], + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "tap": { + "timeout": 600, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "ciVersions": "latest", + "engines": "^14.17.0 || ^16.13.0 || >=18.0.0", + "version": "4.11.0", + "content": "../scripts/template-oss/index.js", + "workspaceRepo": { + "add": { + ".github/workflows/ci-{{ pkgNameFs }}.yml": "ci-npmcli-docs.yml" + } + } } } diff --git a/docs/test/index.js b/docs/test/index.js new file mode 100644 index 0000000..8452428 --- /dev/null +++ b/docs/test/index.js @@ -0,0 +1,111 @@ +const t = require('tap') +const { join } = require('path') +const walk = require('ignore-walk') +const { paths: { content: CONTENT_DIR, nav: NAV, template: TEMPLATE } } = require('../lib/index.js') + +const testBuildDocs = async (t, { verify, ...opts } = {}) => { + const mockedBuild = require('../lib/build.js') + + const fixtures = { + man: {}, + html: {}, + md: {}, + ...opts, + } + + const root = t.testdir(fixtures) + + const paths = { + content: fixtures.content ? join(root, 'content') : CONTENT_DIR, + template: fixtures.template ? join(root, 'template') : TEMPLATE, + nav: fixtures.nav ? join(root, 'nav') : NAV, + man: join(root, 'man'), + html: join(root, 'html'), + md: join(root, 'md'), + } + + return { + results: await mockedBuild({ ...paths, verify }), + root, + ...paths, + } +} + +t.test('builds and verifies the real docs', async (t) => { + const { man, html, md, results } = await testBuildDocs(t, { verify: true }) + + const allFiles = (await Promise.all([ + walk({ path: man }).then(r => r.length), + walk({ path: html }).then(r => r.length), + walk({ path: md }).then(r => r.length), + ])).reduce((a, b) => a + b, 0) + + t.equal(allFiles, results.length) +}) + +t.test('fails on mismatched nav', async t => { + await t.rejects(() => testBuildDocs(t, { + content: { 'test.md': '' }, + nav: '- url: /test2', + }), 'Documentation navigation (nav.yml) does not match filesystem') +}) + +t.test('missing placeholders', async t => { + t.test('command', async t => { + await t.rejects(testBuildDocs(t, { + content: { + commands: { 'npm-access.md': '<!-- AUTOGENERATED USAGE DESCRIPTIONS -->' }, + }, + }), /npm-access\.md/) + await t.rejects(testBuildDocs(t, { + content: { + commands: { 'npm-access.md': '<!-- AUTOGENERATED CONFIG DESCRIPTIONS -->' }, + }, + }), /npm-access\.md/) + }) + + t.test('definitions', async t => { + await t.rejects(testBuildDocs(t, { + content: { + 'using-npm': { 'config.md': '<!-- AUTOGENERATED CONFIG SHORTHANDS -->' }, + }, + }), /config\.md/) + await t.rejects(testBuildDocs(t, { + content: { + 'using-npm': { 'config.md': '<!-- AUTOGENERATED CONFIG DESCRIPTIONS -->' }, + }, + }), /config\.md/) + }) +}) + +t.test('html', async t => { + // these don't happen anywhere in the docs so test this for coverage + // but we test for coverage + t.test('files can link to root pages', async t => { + await testBuildDocs(t, { + content: { 'test.md': '[link](/test)' }, + nav: '- url: /test', + }) + }) + + t.test('succeeds with empty content', async t => { + await testBuildDocs(t, { + content: { 'test.md': '' }, + nav: '- url: /test', + template: '{{ content }}', + }) + }) + + t.test('fails on missing vars in template', async t => { + await t.rejects(() => testBuildDocs(t, { + template: '{{ hello }}', + }), /\{\{ hello \}\}/) + }) + + t.test('rewrites img src', async t => { + await testBuildDocs(t, { + content: { 'test.md': '![](/src)' }, + nav: '- url: /test', + }) + }) +}) diff --git a/lib/arborist-cmd.js b/lib/arborist-cmd.js index 931ead8..29efe98 100644 --- a/lib/arborist-cmd.js +++ b/lib/arborist-cmd.js @@ -1,3 +1,5 @@ +const log = require('./utils/log-shim.js') + // This is the base for all commands whose execWorkspaces just gets // a list of workspace names and passes it on to new Arborist() to // be able to run a filtered Arborist.reify() at some point. @@ -12,8 +14,23 @@ class ArboristCmd extends BaseCommand { 'workspace', 'workspaces', 'include-workspace-root', + 'install-links', ] + static ignoreImplicitWorkspace = false + + constructor (npm) { + super(npm) + if (this.npm.config.isDefault('audit') + && (this.npm.global || this.npm.config.get('location') !== 'project') + ) { + this.npm.config.set('audit', false) + } else if (this.npm.global && this.npm.config.get('audit')) { + log.warn('config', + 'includes both --global and --audit, which is currently unsupported.') + } + } + async execWorkspaces (args, filters) { await this.setWorkspaces(filters) return this.exec(args) diff --git a/lib/auth/legacy.js b/lib/auth/legacy.js deleted file mode 100644 index d1401ce..0000000 --- a/lib/auth/legacy.js +++ /dev/null @@ -1,92 +0,0 @@ -const profile = require('npm-profile') -const log = require('../utils/log-shim') -const openUrl = require('../utils/open-url.js') -const read = require('../utils/read-user-info.js') - -const loginPrompter = async (creds) => { - creds.username = await read.username('Username:', creds.username) - creds.password = await read.password('Password:', creds.password) - creds.email = await read.email('Email: (this IS public) ', creds.email) - - return creds -} - -const login = async (npm, opts) => { - let res - - const requestOTP = async () => { - const otp = await read.otp( - 'Enter one-time password: ' - ) - - return profile.loginCouch( - opts.creds.username, - opts.creds.password, - { ...opts, otp } - ) - } - - const addNewUser = async () => { - let newUser - - try { - newUser = await profile.adduserCouch( - opts.creds.username, - opts.creds.email, - opts.creds.password, - opts - ) - } catch (err) { - if (err.code === 'EOTP') { - newUser = await requestOTP() - } else { - throw err - } - } - - return newUser - } - - const openerPromise = (url) => openUrl(npm, url, 'to complete your login please visit') - try { - res = await profile.login(openerPromise, loginPrompter, opts) - } catch (err) { - const needsMoreInfo = !(opts && - opts.creds && - opts.creds.username && - opts.creds.password && - opts.creds.email) - if (err.code === 'EOTP') { - res = await requestOTP() - } else if (needsMoreInfo) { - throw err - } else { - // TODO: maybe this needs to check for err.code === 'E400' instead? - res = await addNewUser() - } - } - - const newCreds = {} - if (res && res.token) { - newCreds.token = res.token - } else { - newCreds.username = opts.creds.username - newCreds.password = opts.creds.password - newCreds.email = opts.creds.email - newCreds.alwaysAuth = opts.creds.alwaysAuth - } - - const usermsg = opts.creds.username ? ` user ${opts.creds.username}` : '' - const scopeMessage = opts.scope ? ` to scope ${opts.scope}` : '' - const userout = opts.creds.username ? ` as ${opts.creds.username}` : '' - const message = `Logged in${userout}${scopeMessage} on ${opts.registry}.` - - log.info('login', `Authorized${usermsg}`) - - return { - message, - newCreds, - } -} - -module.exports = login diff --git a/lib/auth/oauth.js b/lib/auth/oauth.js deleted file mode 100644 index 99c2ca0..0000000 --- a/lib/auth/oauth.js +++ /dev/null @@ -1,8 +0,0 @@ -const sso = require('./sso.js') - -const login = (npm, opts) => { - npm.config.set('sso-type', 'oauth') - return sso(npm, opts) -} - -module.exports = login diff --git a/lib/auth/saml.js b/lib/auth/saml.js deleted file mode 100644 index 3dd31ca..0000000 --- a/lib/auth/saml.js +++ /dev/null @@ -1,8 +0,0 @@ -const sso = require('./sso.js') - -const login = (npm, opts) => { - npm.config.set('sso-type', 'saml') - return sso(npm, opts) -} - -module.exports = login diff --git a/lib/auth/sso.js b/lib/auth/sso.js deleted file mode 100644 index 795eb89..0000000 --- a/lib/auth/sso.js +++ /dev/null @@ -1,83 +0,0 @@ -// XXX: To date, npm Enterprise Legacy is the only system that ever -// implemented support for this type of login. A better way to do -// SSO is to use the WebLogin type of login supported by the npm-login -// module. This more forward-looking login style is, ironically, -// supported by the '--auth-type=legacy' type of login. -// When and if npm Enterprise Legacy is no longer supported by the npm -// CLI, we can remove this, and fold the lib/auth/legacy.js back into -// lib/adduser.js - -const profile = require('npm-profile') -const npmFetch = require('npm-registry-fetch') -const log = require('../utils/log-shim') -const openUrl = require('../utils/open-url.js') -const otplease = require('../utils/otplease.js') - -const pollForSession = ({ registry, token, opts }) => { - log.info('adduser', 'Polling for validated SSO session') - return npmFetch.json( - '/-/whoami', { ...opts, registry, forceAuth: { token } } - ).then( - ({ username }) => username, - err => { - if (err.code === 'E401') { - return sleep(opts.ssoPollFrequency).then(() => { - return pollForSession({ registry, token, opts }) - }) - } else { - throw err - } - } - ) -} - -function sleep (time) { - return new Promise((resolve) => setTimeout(resolve, time)) -} - -const login = async (npm, { creds, registry, scope }) => { - log.warn('deprecated', 'SSO --auth-type is deprecated') - - const opts = { ...npm.flatOptions, creds, registry, scope } - const { ssoType } = opts - - if (!ssoType) { - throw new Error('Missing option: sso-type') - } - - // We're reusing the legacy login endpoint, so we need some dummy - // stuff here to pass validation. They're never used. - const auth = { - username: 'npm_' + ssoType + '_auth_dummy_user', - password: 'placeholder', - email: 'support@npmjs.com', - authType: ssoType, - } - - const { token, sso } = await otplease(opts, - opts => profile.loginCouch(auth.username, auth.password, opts) - ) - - if (!token) { - throw new Error('no SSO token returned') - } - if (!sso) { - throw new Error('no SSO URL returned by services') - } - - await openUrl(npm, sso, 'to complete your login please visit') - - const username = await pollForSession({ registry, token, opts }) - - log.info('adduser', `Authorized user ${username}`) - - const scopeMessage = scope ? ' to scope ' + scope : '' - const message = `Logged in as ${username}${scopeMessage} on ${registry}.` - - return { - message, - newCreds: { token }, - } -} - -module.exports = login diff --git a/lib/base-command.js b/lib/base-command.js index f67f99f..b57b747 100644 --- a/lib/base-command.js +++ b/lib/base-command.js @@ -2,14 +2,19 @@ const { relative } = require('path') -const usageUtil = require('./utils/usage.js') const ConfigDefinitions = require('./utils/config/definitions.js') const getWorkspaces = require('./workspaces/get-workspaces.js') +const cmdAliases = require('./utils/cmd-list').aliases + class BaseCommand { constructor (npm) { this.wrapWidth = 80 this.npm = npm + + if (!this.skipConfigValidation) { + this.npm.config.validate() + } } get name () { @@ -20,29 +25,52 @@ class BaseCommand { return this.constructor.description } - get usage () { - let usage = `npm ${this.constructor.name}\n\n` - if (this.constructor.description) { - usage = `${usage}${this.constructor.description}\n\n` - } + get ignoreImplicitWorkspace () { + return this.constructor.ignoreImplicitWorkspace + } + + get skipConfigValidation () { + return this.constructor.skipConfigValidation + } + + get usage () { + const usage = [ + `${this.constructor.description}`, + '', + 'Usage:', + ] - usage = `${usage}Usage:\n` if (!this.constructor.usage) { - usage = `${usage}npm ${this.constructor.name}` + usage.push(`npm ${this.constructor.name}`) } else { - usage = `${usage}${this.constructor.usage - .map(u => `npm ${this.constructor.name} ${u}`) - .join('\n')}` + usage.push(...this.constructor.usage.map(u => `npm ${this.constructor.name} ${u}`)) } if (this.constructor.params) { - usage = `${usage}\n\nOptions:\n${this.wrappedParams}` + usage.push('') + usage.push('Options:') + usage.push(this.wrappedParams) } - // Mostly this just appends aliases, this could be more clear - usage = usageUtil(this.constructor.name, usage) - usage = `${usage}\n\nRun "npm help ${this.constructor.name}" for more info` - return usage + const aliases = Object.keys(cmdAliases).reduce((p, c) => { + if (cmdAliases[c] === this.constructor.name) { + p.push(c) + } + return p + }, []) + + if (aliases.length === 1) { + usage.push('') + usage.push(`alias: ${aliases.join(', ')}`) + } else if (aliases.length > 1) { + usage.push('') + usage.push(`aliases: ${aliases.join(', ')}`) + } + + usage.push('') + usage.push(`Run "npm help ${this.constructor.name}" for more info`) + + return usage.join('\n') } get wrappedParams () { @@ -65,7 +93,7 @@ class BaseCommand { if (prefix) { prefix += '\n\n' } - return Object.assign(new Error(`\nUsage: ${prefix}${this.usage}`), { + return Object.assign(new Error(`\n${prefix}${this.usage}`), { code: 'EUSAGE', }) } diff --git a/lib/cli.js b/lib/cli.js index 3d0c32d..9aaf6c5 100644 --- a/lib/cli.js +++ b/lib/cli.js @@ -1,42 +1,111 @@ +// This is separate to indicate that it should contain code we expect to work in +// all conceivably runnable versions of node. This is a best effort to catch +// syntax errors to give users a good error message if they are using a node +// version that doesn't allow syntax we are using such as private properties, etc +const createEnginesValidation = () => { + const node = process.version.replace(/-.*$/, '') + const pkg = require('../package.json') + const engines = pkg.engines.node + const npm = `v${pkg.version}` + + const cols = Math.min(Math.max(20, process.stdout.columns) || 80, 80) + const wrap = (lines) => lines + .join(' ') + .split(/[ \n]+/) + .reduce((left, right) => { + const last = left.split('\n').pop() + const join = last.length && last.length + right.length > cols ? '\n' : ' ' + return left + join + right + }) + .trim() + + const unsupportedMessage = wrap([ + `npm ${npm} does not support Node.js ${node}.`, + `You should probably upgrade to a newer version of node as we can't make any`, + `promises that npm will work with this version.`, + `This version of npm supports the following node versions: \`${engines}\`.`, + 'You can find the latest version at https://nodejs.org/.', + ]) + + const brokenMessage = wrap([ + `ERROR: npm ${npm} is known not to run on Node.js ${node}.`, + `You'll need to upgrade to a newer Node.js version in order to use this version of npm.`, + `This version of npm supports the following node versions: \`${engines}\`.`, + 'You can find the latest version at https://nodejs.org/.', + ]) + + // coverage ignored because this is only hit in very unsupported node versions + // and it's a best effort attempt to show something nice in those cases + /* istanbul ignore next */ + const syntaxErrorHandler = (err) => { + if (err instanceof SyntaxError) { + // eslint-disable-next-line no-console + console.error(`${brokenMessage}\n\nERROR:`) + // eslint-disable-next-line no-console + console.error(err) + return process.exit(1) + } + throw err + } + + process.on('uncaughtException', syntaxErrorHandler) + process.on('unhandledRejection', syntaxErrorHandler) + + return { + node, + engines, + unsupportedMessage, + off: () => { + process.off('uncaughtException', syntaxErrorHandler) + process.off('unhandledRejection', syntaxErrorHandler) + }, + } +} + // Separated out for easier unit testing module.exports = async process => { // set it here so that regardless of what happens later, we don't // leak any private CLI configs to other programs process.title = 'npm' - // We used to differentiate between known broken and unsupported - // versions of node and attempt to only log unsupported but still run. - // After we dropped node 10 support, we can use new features - // (like static, private, etc) which will only give vague syntax errors, - // so now both broken and unsupported use console, but only broken - // will process.exit. It is important to now perform *both* of these - // checks as early as possible so the user gets the error message. - const { checkForBrokenNode, checkForUnsupportedNode } = require('./utils/unsupported.js') - checkForBrokenNode() - checkForUnsupportedNode() + // Nothing should happen before this line if we can't guarantee it will + // not have syntax errors in some version of node + const validateEngines = createEnginesValidation() + const satisfies = require('semver/functions/satisfies') const exitHandler = require('./utils/exit-handler.js') - process.on('uncaughtException', exitHandler) - process.on('unhandledRejection', exitHandler) - const Npm = require('./npm.js') const npm = new Npm() exitHandler.setNpm(npm) - // if npm is called as "npmg" or "npm_g", then - // run in global mode. + // if npm is called as "npmg" or "npm_g", then run in global mode. if (process.argv[1][process.argv[1].length - 1] === 'g') { process.argv.splice(1, 1, 'npm', '-g') } + // only log node and npm paths in argv initially since argv can contain + // sensitive info. a cleaned version will be logged later const log = require('./utils/log-shim.js') - const replaceInfo = require('./utils/replace-info.js') - log.verbose('cli', replaceInfo(process.argv)) - + log.verbose('cli', process.argv.slice(0, 2).join(' ')) log.info('using', 'npm@%s', npm.version) log.info('using', 'node@%s', process.version) - const updateNotifier = require('./utils/update-notifier.js') + // At this point we've required a few files and can be pretty sure + // we dont contain invalid syntax for this version of node. It's + // possible a lazy require would, but that's unlikely enough that + // it's not worth catching anymore and we attach the more important + // exit handlers. + validateEngines.off() + process.on('uncaughtException', exitHandler) + process.on('unhandledRejection', exitHandler) + + // It is now safe to log a warning if they are using a version of node + // that is not going to fail on syntax errors but is still unsupported + // and untested and might not work reliably. This is safe to use the logger + // now which we want since this will show up in the error log too. + if (!satisfies(validateEngines.node, validateEngines.engines)) { + log.warn('cli', validateEngines.unsupportedMessage) + } let cmd // now actually fire up npm and run the command. @@ -54,8 +123,6 @@ module.exports = async process => { npm.config.set('usage', false, 'cli') } - updateNotifier(npm) - cmd = npm.argv.shift() if (!cmd) { npm.output(await npm.usage) diff --git a/lib/commands/access.js b/lib/commands/access.js index 7d3930d..d5ac5bb 100644 --- a/lib/commands/access.js +++ b/lib/commands/access.js @@ -1,209 +1,221 @@ const path = require('path') -const libaccess = require('libnpmaccess') +const libnpmaccess = require('libnpmaccess') +const npa = require('npm-package-arg') const readPackageJson = require('read-package-json-fast') +const localeCompare = require('@isaacs/string-locale-compare')('en') -const log = require('../utils/log-shim.js') const otplease = require('../utils/otplease.js') const getIdentity = require('../utils/get-identity.js') const BaseCommand = require('../base-command.js') -const subcommands = [ - 'public', - 'restricted', +const commands = [ + 'get', 'grant', + 'list', 'revoke', - 'ls-packages', - 'ls-collaborators', - 'edit', - '2fa-required', - '2fa-not-required', + 'set', +] + +const setCommands = [ + 'status=public', + 'status=private', + 'mfa=none', + 'mfa=publish', + 'mfa=automation', + '2fa=none', + '2fa=publish', + '2fa=automation', ] class Access extends BaseCommand { static description = 'Set access level on published packages' static name = 'access' static params = [ - 'registry', + 'json', 'otp', + 'registry', ] + static ignoreImplicitWorkspace = true + static usage = [ - 'public [<package>]', - 'restricted [<package>]', + 'list packages [<user>|<scope>|<scope:team> [<package>]', + 'list collaborators [<package> [<user>]]', + 'get status [<package>]', + 'set status=public|private [<package>]', + 'set mfa=none|publish|automation [<package>]', 'grant <read-only|read-write> <scope:team> [<package>]', 'revoke <scope:team> [<package>]', - '2fa-required [<package>]', - '2fa-not-required [<package>]', - 'ls-packages [<user>|<scope>|<scope:team>]', - 'ls-collaborators [<package> [<user>]]', - 'edit [<package>]', ] async completion (opts) { const argv = opts.conf.argv.remain if (argv.length === 2) { - return subcommands + return commands } switch (argv[2]) { case 'grant': - if (argv.length === 3) { - return ['read-only', 'read-write'] - } else { - return [] - } - - case 'public': - case 'restricted': - case 'ls-packages': - case 'ls-collaborators': - case 'edit': - case '2fa-required': - case '2fa-not-required': + return ['read-only', 'read-write'] case 'revoke': return [] + case 'list': + case 'ls': + return ['packages', 'collaborators'] + case 'get': + return ['status'] + case 'set': + return setCommands default: throw new Error(argv[2] + ' not recognized') } } - async exec ([cmd, ...args]) { + async exec ([cmd, subcmd, ...args]) { if (!cmd) { - throw this.usageError('Subcommand is required.') + throw this.usageError() + } + if (!commands.includes(cmd)) { + throw this.usageError(`${cmd} is not a valid access command`) + } + // All commands take at least one more parameter so we can do this check up front + if (!subcmd) { + throw this.usageError() } - if (!subcommands.includes(cmd) || !this[cmd]) { - throw this.usageError(`${cmd} is not a recognized subcommand.`) + switch (cmd) { + case 'grant': + if (!['read-only', 'read-write'].includes(subcmd)) { + throw this.usageError('grant must be either `read-only` or `read-write`') + } + if (!args[0]) { + throw this.usageError('`<scope:team>` argument is required') + } + return this.#grant(subcmd, args[0], args[1]) + case 'revoke': + return this.#revoke(subcmd, args[0]) + case 'list': + case 'ls': + if (subcmd === 'packages') { + return this.#listPackages(args[0], args[1]) + } + if (subcmd === 'collaborators') { + return this.#listCollaborators(args[0], args[1]) + } + throw this.usageError(`list ${subcmd} is not a valid access command`) + case 'get': + if (subcmd !== 'status') { + throw this.usageError(`get ${subcmd} is not a valid access command`) + } + return this.#getStatus(args[0]) + case 'set': + if (!setCommands.includes(subcmd)) { + throw this.usageError(`set ${subcmd} is not a valid access command`) + } + return this.#set(subcmd, args[0]) } + } - return this[cmd](args, { - ...this.npm.flatOptions, - log, + async #grant (permissions, scope, pkg) { + await libnpmaccess.setPermissions(scope, pkg, permissions) + } + + async #revoke (scope, pkg) { + await libnpmaccess.removePermissions(scope, pkg) + } + + async #listPackages (owner, pkg) { + if (!owner) { + owner = await getIdentity(this.npm, this.npm.flatOptions) + } + const pkgs = await libnpmaccess.getPackages(owner, this.npm.flatOptions) + this.#output(pkgs, pkg) + } + + async #listCollaborators (pkg, user) { + const pkgName = await this.#getPackage(pkg, false) + const collabs = await libnpmaccess.getCollaborators(pkgName, this.npm.flatOptions) + this.#output(collabs, user) + } + + async #getStatus (pkg) { + const pkgName = await this.#getPackage(pkg, false) + const visibility = await libnpmaccess.getVisibility(pkgName, this.npm.flatOptions) + this.#output({ [pkgName]: visibility.public ? 'public' : 'private' }) + } + + async #set (subcmd, pkg) { + const [subkey, subval] = subcmd.split('=') + switch (subkey) { + case 'mfa': + case '2fa': + return this.#setMfa(pkg, subval) + case 'status': + return this.#setStatus(pkg, subval) + } + } + + async #setMfa (pkg, level) { + const pkgName = await this.#getPackage(pkg, false) + await otplease(this.npm, this.npm.flatOptions, (opts) => { + return libnpmaccess.setMfa(pkgName, level, opts) }) } - public ([pkg], opts) { - return this.modifyPackage(pkg, opts, libaccess.public) - } - - restricted ([pkg], opts) { - return this.modifyPackage(pkg, opts, libaccess.restricted) - } - - async grant ([perms, scopeteam, pkg], opts) { - if (!perms || (perms !== 'read-only' && perms !== 'read-write')) { - throw this.usageError('First argument must be either `read-only` or `read-write`.') + async #setStatus (pkg, status) { + // only scoped packages can have their access changed + const pkgName = await this.#getPackage(pkg, true) + if (status === 'private') { + status = 'restricted' } - - if (!scopeteam) { - throw this.usageError('`<scope:team>` argument is required.') - } - - const [, scope, team] = scopeteam.match(/^@?([^:]+):(.*)$/) || [] - - if (!scope && !team) { - throw this.usageError( - 'Second argument used incorrect format.\n' + - 'Example: @example:developers' - ) - } - - return this.modifyPackage(pkg, opts, (pkgName, opts) => - libaccess.grant(pkgName, scopeteam, perms, opts), false) + await otplease(this.npm, this.npm.flatOptions, (opts) => { + return libnpmaccess.setAccess(pkgName, status, opts) + }) + return this.#getStatus(pkgName) } - async revoke ([scopeteam, pkg], opts) { - if (!scopeteam) { - throw this.usageError('`<scope:team>` argument is required.') - } - - const [, scope, team] = scopeteam.match(/^@?([^:]+):(.*)$/) || [] - - if (!scope || !team) { - throw this.usageError( - 'First argument used incorrect format.\n' + - 'Example: @example:developers' - ) - } - - return this.modifyPackage(pkg, opts, (pkgName, opts) => - libaccess.revoke(pkgName, scopeteam, opts)) - } - - get ['2fa-required'] () { - return this.tfaRequired - } - - tfaRequired ([pkg], opts) { - return this.modifyPackage(pkg, opts, libaccess.tfaRequired, false) - } - - get ['2fa-not-required'] () { - return this.tfaNotRequired - } - - tfaNotRequired ([pkg], opts) { - return this.modifyPackage(pkg, opts, libaccess.tfaNotRequired, false) - } - - get ['ls-packages'] () { - return this.lsPackages - } - - async lsPackages ([owner], opts) { - if (!owner) { - owner = await getIdentity(this.npm, opts) - } - - const pkgs = await libaccess.lsPackages(owner, opts) - - // TODO - print these out nicely (breaking change) - this.npm.output(JSON.stringify(pkgs, null, 2)) - } - - get ['ls-collaborators'] () { - return this.lsCollaborators - } - - async lsCollaborators ([pkg, usr], opts) { - const pkgName = await this.getPackage(pkg, false) - const collabs = await libaccess.lsCollaborators(pkgName, usr, opts) - - // TODO - print these out nicely (breaking change) - this.npm.output(JSON.stringify(collabs, null, 2)) - } - - async edit () { - throw new Error('edit subcommand is not implemented yet') - } - - modifyPackage (pkg, opts, fn, requireScope = true) { - return this.getPackage(pkg, requireScope) - .then(pkgName => otplease(opts, opts => fn(pkgName, opts))) - } - - async getPackage (name, requireScope) { - if (name && name.trim()) { - return name.trim() - } else { + async #getPackage (name, requireScope) { + if (!name) { try { const pkg = await readPackageJson(path.resolve(this.npm.prefix, 'package.json')) name = pkg.name } catch (err) { if (err.code === 'ENOENT') { - throw new Error( - 'no package name passed to command and no package.json found' - ) + throw Object.assign(new Error('no package name given and no package.json found'), { + code: 'ENOENT', + }) } else { throw err } } + } - if (requireScope && !name.match(/^@[^/]+\/.*$/)) { - throw this.usageError('This command is only available for scoped packages.') - } else { - return name + const spec = npa(name) + if (requireScope && !spec.scope) { + throw this.usageError('This command is only available for scoped packages.') + } + return name + } + + #output (items, limiter) { + const output = {} + const lookup = { + __proto__: null, + read: 'read-only', + write: 'read-write', + } + for (const item in items) { + const val = items[item] + output[item] = lookup[val] || val + } + if (this.npm.config.get('json')) { + this.npm.output(JSON.stringify(output, null, 2)) + } else { + for (const item of Object.keys(output).sort(localeCompare)) { + if (!limiter || limiter === item) { + this.npm.output(`${item}: ${output[item]}`) + } } } } diff --git a/lib/commands/adduser.js b/lib/commands/adduser.js index 1cf70ff..1e92b35 100644 --- a/lib/commands/adduser.js +++ b/lib/commands/adduser.js @@ -1,12 +1,8 @@ const log = require('../utils/log-shim.js') const replaceInfo = require('../utils/replace-info.js') +const auth = require('../utils/auth.js') + const BaseCommand = require('../base-command.js') -const authTypes = { - legacy: require('../auth/legacy.js'), - oauth: require('../auth/oauth.js'), - saml: require('../auth/saml.js'), - sso: require('../auth/sso.js'), -} class AddUser extends BaseCommand { static description = 'Add a registry user account' @@ -14,63 +10,44 @@ class AddUser extends BaseCommand { static params = [ 'registry', 'scope', + 'auth-type', ] + static ignoreImplicitWorkspace = true + async exec (args) { - const { scope } = this.npm.flatOptions - const registry = this.getRegistry(this.npm.flatOptions) - const auth = this.getAuthType(this.npm.flatOptions) - const creds = this.npm.config.getCredentialsByURI(registry) + const scope = this.npm.config.get('scope') + let registry = this.npm.config.get('registry') - log.disableProgress() - - log.notice('', `Log in on ${replaceInfo(registry)}`) - - const { message, newCreds } = await auth(this.npm, { - ...this.npm.flatOptions, - creds, - registry, - scope, - log, - }) - - await this.updateConfig({ - newCreds, - registry, - scope, - }) - - this.npm.output(message) - } - - getRegistry ({ scope, registry }) { if (scope) { const scopedRegistry = this.npm.config.get(`${scope}:registry`) const cliRegistry = this.npm.config.get('registry', 'cli') if (scopedRegistry && !cliRegistry) { - return scopedRegistry + registry = scopedRegistry } } - return registry - } - getAuthType ({ authType }) { - const type = authTypes[authType] + const creds = this.npm.config.getCredentialsByURI(registry) - if (!type) { - throw new Error('no such auth module') - } + log.disableProgress() + log.notice('', `Log in on ${replaceInfo(registry)}`) - return type - } + const { message, newCreds } = await auth.adduser(this.npm, { + ...this.npm.flatOptions, + creds, + registry, + }) - async updateConfig ({ newCreds, registry, scope }) { this.npm.config.delete('_token', 'user') // prevent legacy pollution this.npm.config.setCredentialsByURI(registry, newCreds) + if (scope) { this.npm.config.set(scope + ':registry', registry, 'user') } + await this.npm.config.save('user') + + this.npm.output(message) } } module.exports = AddUser diff --git a/lib/commands/audit.js b/lib/commands/audit.js index fad43fe..feccefd 100644 --- a/lib/commands/audit.js +++ b/lib/commands/audit.js @@ -1,8 +1,337 @@ const Arborist = require('@npmcli/arborist') const auditReport = require('npm-audit-report') -const reifyFinish = require('../utils/reify-finish.js') -const auditError = require('../utils/audit-error.js') +const fetch = require('npm-registry-fetch') +const localeCompare = require('@isaacs/string-locale-compare')('en') +const npa = require('npm-package-arg') +const pacote = require('pacote') +const pMap = require('p-map') + const ArboristWorkspaceCmd = require('../arborist-cmd.js') +const auditError = require('../utils/audit-error.js') +const log = require('../utils/log-shim.js') +const reifyFinish = require('../utils/reify-finish.js') + +const sortAlphabetically = (a, b) => localeCompare(a.name, b.name) + +class VerifySignatures { + constructor (tree, filterSet, npm, opts) { + this.tree = tree + this.filterSet = filterSet + this.npm = npm + this.opts = opts + this.keys = new Map() + this.invalid = [] + this.missing = [] + this.checkedPackages = new Set() + this.auditedWithKeysCount = 0 + this.verifiedCount = 0 + this.output = [] + this.exitCode = 0 + } + + async run () { + const start = process.hrtime.bigint() + + // Find all deps in tree + const { edges, registries } = this.getEdgesOut(this.tree.inventory.values(), this.filterSet) + if (edges.size === 0) { + throw new Error('found no installed dependencies to audit') + } + + await Promise.all([...registries].map(registry => this.setKeys({ registry }))) + + const progress = log.newItem('verifying registry signatures', edges.size) + const mapper = async (edge) => { + progress.completeWork(1) + await this.getVerifiedInfo(edge) + } + await pMap(edges, mapper, { concurrency: 20, stopOnError: true }) + + // Didn't find any dependencies that could be verified, e.g. only local + // deps, missing version, not on a registry etc. + if (!this.auditedWithKeysCount) { + throw new Error('found no dependencies to audit that where installed from ' + + 'a supported registry') + } + + const invalid = this.invalid.sort(sortAlphabetically) + const missing = this.missing.sort(sortAlphabetically) + + const hasNoInvalidOrMissing = invalid.length === 0 && missing.length === 0 + + if (!hasNoInvalidOrMissing) { + this.exitCode = 1 + } + + if (this.npm.config.get('json')) { + this.appendOutput(JSON.stringify({ + invalid: this.makeJSON(invalid), + missing: this.makeJSON(missing), + }, null, 2)) + return + } + const end = process.hrtime.bigint() + const elapsed = end - start + + const auditedPlural = this.auditedWithKeysCount > 1 ? 's' : '' + const timing = `audited ${this.auditedWithKeysCount} package${auditedPlural} in ` + + `${Math.floor(Number(elapsed) / 1e9)}s` + this.appendOutput(`${timing}\n`) + + if (this.verifiedCount) { + const verifiedBold = this.npm.chalk.bold('verified') + const msg = this.verifiedCount === 1 ? + `${this.verifiedCount} package has a ${verifiedBold} registry signature\n` : + `${this.verifiedCount} packages have ${verifiedBold} registry signatures\n` + this.appendOutput(msg) + } + + if (missing.length) { + const missingClr = this.npm.chalk.bold(this.npm.chalk.red('missing')) + const msg = missing.length === 1 ? + `package has a ${missingClr} registry signature` : + `packages have ${missingClr} registry signatures` + this.appendOutput( + `${missing.length} ${msg} but the registry is ` + + `providing signing keys:\n` + ) + this.appendOutput(this.humanOutput(missing)) + } + + if (invalid.length) { + const invalidClr = this.npm.chalk.bold(this.npm.chalk.red('invalid')) + const msg = invalid.length === 1 ? + `${invalid.length} package has an ${invalidClr} registry signature:\n` : + `${invalid.length} packages have ${invalidClr} registry signatures:\n` + this.appendOutput( + `${missing.length ? '\n' : ''}${msg}` + ) + this.appendOutput(this.humanOutput(invalid)) + const tamperMsg = invalid.length === 1 ? + `\nSomeone might have tampered with this package since it was ` + + `published on the registry!\n` : + `\nSomeone might have tampered with these packages since they where ` + + `published on the registry!\n` + this.appendOutput(tamperMsg) + } + } + + appendOutput (...args) { + this.output.push(...args.flat()) + } + + report () { + return { report: this.output.join('\n'), exitCode: this.exitCode } + } + + getEdgesOut (nodes, filterSet) { + const edges = new Set() + const registries = new Set() + for (const node of nodes) { + for (const edge of node.edgesOut.values()) { + const filteredOut = + edge.from + && filterSet + && filterSet.size > 0 + && !filterSet.has(edge.from.target) + + if (!filteredOut) { + const spec = this.getEdgeSpec(edge) + if (spec) { + // Prefetch and cache public keys from used registries + registries.add(this.getSpecRegistry(spec)) + } + edges.add(edge) + } + } + } + return { edges, registries } + } + + async setKeys ({ registry }) { + const keys = await fetch.json('/-/npm/v1/keys', { + ...this.npm.flatOptions, + registry, + }).then(({ keys }) => keys.map((key) => ({ + ...key, + pemkey: `-----BEGIN PUBLIC KEY-----\n${key.key}\n-----END PUBLIC KEY-----`, + }))).catch(err => { + if (err.code === 'E404' || err.code === 'E400') { + return null + } else { + throw err + } + }) + if (keys) { + this.keys.set(registry, keys) + } + } + + getEdgeType (edge) { + return edge.optional ? 'optionalDependencies' + : edge.peer ? 'peerDependencies' + : edge.dev ? 'devDependencies' + : 'dependencies' + } + + getEdgeSpec (edge) { + let name = edge.name + try { + name = npa(edge.spec).subSpec.name + } catch { + // leave it as edge.name + } + try { + return npa(`${name}@${edge.spec}`) + } catch { + // Skip packages with invalid spec + } + } + + buildRegistryConfig (registry) { + const keys = this.keys.get(registry) || [] + const parsedRegistry = new URL(registry) + const regKey = `//${parsedRegistry.host}${parsedRegistry.pathname}` + return { + [`${regKey}:_keys`]: keys, + } + } + + getSpecRegistry (spec) { + return fetch.pickRegistry(spec, this.npm.flatOptions) + } + + getValidPackageInfo (edge) { + const type = this.getEdgeType(edge) + // Skip potentially optional packages that are not on disk, as these could + // be omitted during install + if (edge.error === 'MISSING' && type !== 'dependencies') { + return + } + + const spec = this.getEdgeSpec(edge) + // Skip invalid version requirements + if (!spec) { + return + } + const node = edge.to || edge + const { version } = node.package || {} + + if (node.isWorkspace || // Skip local workspaces packages + !version || // Skip packages that don't have a installed version, e.g. optonal dependencies + !spec.registry) { // Skip if not from registry, e.g. git package + return + } + + for (const omitType of this.npm.config.get('omit')) { + if (node[omitType]) { + return + } + } + + return { + name: spec.name, + version, + type, + location: node.location, + registry: this.getSpecRegistry(spec), + } + } + + async verifySignatures (name, version, registry) { + const { + _integrity: integrity, + _signatures, + _resolved: resolved, + } = await pacote.manifest(`${name}@${version}`, { + verifySignatures: true, + ...this.buildRegistryConfig(registry), + ...this.npm.flatOptions, + }) + const signatures = _signatures || [] + return { + integrity, + signatures, + resolved, + } + } + + async getVerifiedInfo (edge) { + const info = this.getValidPackageInfo(edge) + if (!info) { + return + } + const { name, version, location, registry, type } = info + if (this.checkedPackages.has(location)) { + // we already did or are doing this one + return + } + this.checkedPackages.add(location) + + // We only "audit" or verify the signature, or the presence of it, on + // packages whose registry returns signing keys + const keys = this.keys.get(registry) || [] + if (keys.length) { + this.auditedWithKeysCount += 1 + } + + try { + const { integrity, signatures, resolved } = await this.verifySignatures( + name, version, registry + ) + + // Currently we only care about missing signatures on registries that provide a public key + // We could make this configurable in the future with a strict/paranoid mode + if (signatures.length) { + this.verifiedCount += 1 + } else if (keys.length) { + this.missing.push({ + name, + version, + location, + resolved, + integrity, + registry, + }) + } + } catch (e) { + if (e.code === 'EINTEGRITYSIGNATURE') { + const { signature, keyid, integrity, resolved } = e + this.invalid.push({ + name, + type, + version, + resolved, + location, + integrity, + registry, + signature, + keyid, + }) + } else { + throw e + } + } + } + + humanOutput (list) { + return list.map(v => + `${this.npm.chalk.red(`${v.name}@${v.version}`)} (${v.registry})` + ).join('\n') + } + + makeJSON (deps) { + return deps.map(d => ({ + name: d.name, + version: d.version, + location: d.location, + resolved: d.resolved, + integrity: d.integrity, + signature: d.signature, + keyid: d.keyid, + })) + } +} class Audit extends ArboristWorkspaceCmd { static description = 'Run a security audit' @@ -14,10 +343,12 @@ class Audit extends ArboristWorkspaceCmd { 'json', 'package-lock-only', 'omit', + 'foreground-scripts', + 'ignore-scripts', ...super.params, ] - static usage = ['[fix]'] + static usage = ['[fix|signatures]'] async completion (opts) { const argv = opts.conf.argv.remain @@ -30,11 +361,21 @@ class Audit extends ArboristWorkspaceCmd { case 'fix': return [] default: - throw new Error(argv[2] + ' not recognized') + throw Object.assign(new Error(argv[2] + ' not recognized'), { + code: 'EUSAGE', + }) } } async exec (args) { + if (args[0] === 'signatures') { + await this.auditSignatures() + } else { + await this.auditAdvisories(args) + } + } + + async auditAdvisories (args) { const reporter = this.npm.config.get('json') ? 'json' : 'detail' const opts = { ...this.npm.flatOptions, @@ -57,6 +398,44 @@ class Audit extends ArboristWorkspaceCmd { this.npm.output(result.report) } } + + async auditSignatures () { + if (this.npm.global) { + throw Object.assign( + new Error('`npm audit signatures` does not support global packages'), { + code: 'EAUDITGLOBAL', + } + ) + } + + log.verbose('loading installed dependencies') + const opts = { + ...this.npm.flatOptions, + path: this.npm.prefix, + workspaces: this.workspaceNames, + } + + const arb = new Arborist(opts) + const tree = await arb.loadActual() + let filterSet = new Set() + if (opts.workspaces && opts.workspaces.length) { + filterSet = + arb.workspaceDependencySet( + tree, + opts.workspaces, + this.npm.flatOptions.includeWorkspaceRoot + ) + } else if (!this.npm.flatOptions.workspacesEnabled) { + filterSet = + arb.excludeWorkspacesDependencySet(tree) + } + + const verify = new VerifySignatures(tree, filterSet, this.npm, { ...opts }) + await verify.run() + const result = verify.report() + process.exitCode = process.exitCode || result.exitCode + this.npm.output(result.report) + } } module.exports = Audit diff --git a/lib/commands/bin.js b/lib/commands/bin.js deleted file mode 100644 index bb700d4..0000000 --- a/lib/commands/bin.js +++ /dev/null @@ -1,18 +0,0 @@ -const envPath = require('../utils/path.js') -const BaseCommand = require('../base-command.js') - -class Bin extends BaseCommand { - static description = 'Display npm bin folder' - static name = 'bin' - static params = ['global'] - - async exec (args) { - const b = this.npm.bin - this.npm.output(b) - if (this.npm.config.get('global') && !envPath.includes(b)) { - // XXX: does this need to be console? - console.error('(not in PATH env variable)') - } - } -} -module.exports = Bin diff --git a/lib/commands/birthday.js b/lib/commands/birthday.js deleted file mode 100644 index 27fe2c5..0000000 --- a/lib/commands/birthday.js +++ /dev/null @@ -1,11 +0,0 @@ -const BaseCommand = require('../base-command.js') - -class Birthday extends BaseCommand { - static name = 'birthday' - async exec () { - this.npm.config.set('yes', true) - return this.npm.exec('exec', ['@npmcli/npm-birthday']) - } -} - -module.exports = Birthday diff --git a/lib/commands/bugs.js b/lib/commands/bugs.js index 5dfd1eb..17cbd96 100644 --- a/lib/commands/bugs.js +++ b/lib/commands/bugs.js @@ -1,32 +1,10 @@ -const pacote = require('pacote') -const log = require('../utils/log-shim') -const openUrl = require('../utils/open-url.js') -const hostedFromMani = require('../utils/hosted-git-info-from-manifest.js') -const BaseCommand = require('../base-command.js') +const PackageUrlCmd = require('../package-url-cmd.js') -class Bugs extends BaseCommand { +class Bugs extends PackageUrlCmd { static description = 'Report bugs for a package in a web browser' static name = 'bugs' - static usage = ['[<pkgname>]'] - static params = ['browser', 'registry'] - async exec (args) { - if (!args || !args.length) { - args = ['.'] - } - - await Promise.all(args.map(pkg => this.getBugs(pkg))) - } - - async getBugs (pkg) { - const opts = { ...this.npm.flatOptions, fullMetadata: true } - const mani = await pacote.manifest(pkg, opts) - const url = this.getBugsUrl(mani) - log.silly('bugs', 'url', url) - await openUrl(this.npm, url, `${mani.name} bug list available at the following URL`) - } - - getBugsUrl (mani) { + getUrl (spec, mani) { if (mani.bugs) { if (typeof mani.bugs === 'string') { return mani.bugs @@ -42,7 +20,7 @@ class Bugs extends BaseCommand { } // try to get it from the repo, if possible - const info = hostedFromMani(mani) + const info = this.hostedFromMani(mani) if (info) { return info.bugs() } diff --git a/lib/commands/cache.js b/lib/commands/cache.js index ecb34cb..a2e6434 100644 --- a/lib/commands/cache.js +++ b/lib/commands/cache.js @@ -1,4 +1,5 @@ const cacache = require('cacache') +const Arborist = require('@npmcli/arborist') const { promisify } = require('util') const pacote = require('pacote') const path = require('path') @@ -10,11 +11,7 @@ const jsonParse = require('json-parse-even-better-errors') const localeCompare = require('@isaacs/string-locale-compare')('en') const log = require('../utils/log-shim') -const searchCachePackage = async (path, spec, cacheKeys) => { - const parsed = npa(spec) - if (parsed.rawSpec !== '' && parsed.type === 'tag') { - throw new Error(`Cannot list cache keys for a tagged package.`) - } +const searchCachePackage = async (path, parsed, cacheKeys) => { /* eslint-disable-next-line max-len */ const searchMFH = new RegExp(`^make-fetch-happen:request-cache:.*(?<!/[@a-zA-Z]+)/${parsed.name}/-/(${parsed.name}[^/]+.tgz)$`) const searchPack = new RegExp(`^make-fetch-happen:request-cache:.*/${parsed.escapedName}$`) @@ -50,6 +47,7 @@ const searchCachePackage = async (path, spec, cacheKeys) => { if (!packument.versions || typeof packument.versions !== 'object') { continue } + // assuming this is a packument for (const ver of Object.keys(packument.versions)) { if (semver.satisfies(ver, parsed.rawSpec)) { @@ -71,16 +69,14 @@ class Cache extends BaseCommand { static name = 'cache' static params = ['cache'] static usage = [ - 'add <tarball file>', - 'add <folder>', - 'add <tarball url>', - 'add <git url>', - 'add <name>@<version>', + 'add <package-spec>', 'clean [<key>]', 'ls [<name>@<version>]', 'verify', ] + static ignoreImplicitWorkspace = true + async completion (opts) { const argv = opts.conf.argv.remain if (argv.length === 2) { @@ -146,6 +142,7 @@ class Cache extends BaseCommand { } this.npm.output(`Deleted: ${key}`) await cacache.rm.entry(cachePath, key) + // XXX this could leave other entries without content! await cacache.rm.content(cachePath, entry.integrity) } } @@ -168,14 +165,14 @@ class Cache extends BaseCommand { return pacote.tarball.stream(spec, stream => { stream.resume() return stream.promise() - }, this.npm.flatOptions) + }, { ...this.npm.flatOptions, Arborist }) })) } async verify () { const cache = path.join(this.npm.cache, '_cacache') const prefix = cache.indexOf(process.env.HOME) === 0 - ? `~${cache.substr(process.env.HOME.length)}` + ? `~${cache.slice(process.env.HOME.length)}` : cache const stats = await cacache.verify(cache) this.npm.output(`Cache verified and compressed (${prefix})`) @@ -202,7 +199,11 @@ class Cache extends BaseCommand { // get results for each package spec specified const results = new Set() for (const spec of specs) { - const keySet = await searchCachePackage(cachePath, spec, cacheKeys) + const parsed = npa(spec) + if (parsed.rawSpec !== '' && parsed.type === 'tag') { + throw this.usageError('Cannot list cache keys for a tagged package.') + } + const keySet = await searchCachePackage(cachePath, parsed, cacheKeys) for (const key of keySet) { results.add(key) } diff --git a/lib/commands/ci.js b/lib/commands/ci.js index 5e862a4..38ee142 100644 --- a/lib/commands/ci.js +++ b/lib/commands/ci.js @@ -8,31 +8,20 @@ const readdir = util.promisify(fs.readdir) const log = require('../utils/log-shim.js') const validateLockfile = require('../utils/validate-lockfile.js') -const removeNodeModules = async where => { - const rimrafOpts = { glob: false } - process.emit('time', 'npm-ci:rm') - const path = `${where}/node_modules` - // get the list of entries so we can skip the glob for performance - const entries = await readdir(path, null).catch(er => []) - await Promise.all(entries.map(f => rimraf(`${path}/${f}`, rimrafOpts))) - process.emit('timeEnd', 'npm-ci:rm') -} const ArboristWorkspaceCmd = require('../arborist-cmd.js') +const Install = require('./install.js') class CI extends ArboristWorkspaceCmd { - static description = 'Install a project with a clean slate' + static description = 'Clean install a project' static name = 'ci' - static params = [ - 'audit', - 'ignore-scripts', - 'script-shell', - ] + + static params = Install.params async exec () { - if (this.npm.config.get('global')) { - const err = new Error('`npm ci` does not work for global packages') - err.code = 'ECIGLOBAL' - throw err + if (this.npm.global) { + throw Object.assign(new Error('`npm ci` does not work for global packages'), { + code: 'ECIGLOBAL', + }) } const where = this.npm.prefix @@ -40,23 +29,19 @@ class CI extends ArboristWorkspaceCmd { ...this.npm.flatOptions, packageLock: true, // npm ci should never skip lock files path: where, - log, save: false, // npm ci should never modify the lockfile or package.json workspaces: this.workspaceNames, } const arb = new Arborist(opts) - await Promise.all([ - arb.loadVirtual().catch(er => { - log.verbose('loadVirtual', er.stack) - const msg = - 'The `npm ci` command can only install with an existing package-lock.json or\n' + - 'npm-shrinkwrap.json with lockfileVersion >= 1. Run an install with npm@5 or\n' + - 'later to generate a package-lock.json file, then try again.' - throw new Error(msg) - }), - removeNodeModules(where), - ]) + await arb.loadVirtual().catch(er => { + log.verbose('loadVirtual', er.stack) + const msg = + 'The `npm ci` command can only install with an existing package-lock.json or\n' + + 'npm-shrinkwrap.json with lockfileVersion >= 1. Run an install with npm@5 or\n' + + 'later to generate a package-lock.json file, then try again.' + throw this.usageError(msg) + }) // retrieves inventory of packages from loaded virtual tree (lock file) const virtualInventory = new Map(arb.virtualTree.inventory) @@ -70,15 +55,24 @@ class CI extends ArboristWorkspaceCmd { // throws a validation error in case of mismatches const errors = validateLockfile(virtualInventory, arb.idealTree.inventory) if (errors.length) { - throw new Error( + throw this.usageError( '`npm ci` can only install packages when your package.json and ' + 'package-lock.json or npm-shrinkwrap.json are in sync. Please ' + 'update your lock file with `npm install` ' + 'before continuing.\n\n' + - errors.join('\n') + '\n' + errors.join('\n') ) } + // Only remove node_modules after we've successfully loaded the virtual + // tree and validated the lockfile + await this.npm.time('npm-ci:rm', async () => { + const path = `${where}/node_modules` + // get the list of entries so we can skip the glob for performance + const entries = await readdir(path, null).catch(er => []) + return Promise.all(entries.map(f => rimraf(`${path}/${f}`, { glob: false }))) + }) + await arb.reify(opts) const ignoreScripts = this.npm.config.get('ignore-scripts') @@ -100,8 +94,7 @@ class CI extends ArboristWorkspaceCmd { args: [], scriptShell, stdio: 'inherit', - stdioString: true, - banner: log.level !== 'silent', + banner: !this.npm.silent, event, }) } diff --git a/lib/commands/completion.js b/lib/commands/completion.js index 4ded2de..8fc05b2 100644 --- a/lib/commands/completion.js +++ b/lib/commands/completion.js @@ -29,24 +29,32 @@ // as an array. // -const { definitions, shorthands } = require('../utils/config/index.js') -const deref = require('../utils/deref-command.js') -const { aliases, cmdList, plumbing } = require('../utils/cmd-list.js') -const aliasNames = Object.keys(aliases) -const fullList = cmdList.concat(aliasNames).filter(c => !plumbing.includes(c)) +const fs = require('fs/promises') const nopt = require('nopt') + +const { definitions, shorthands } = require('../utils/config/index.js') +const { aliases, commands, plumbing } = require('../utils/cmd-list.js') +const aliasNames = Object.keys(aliases) +const fullList = commands.concat(aliasNames).filter(c => !plumbing.includes(c)) const configNames = Object.keys(definitions) const shorthandNames = Object.keys(shorthands) const allConfs = configNames.concat(shorthandNames) -const isWindowsShell = require('../utils/is-windows-shell.js') -const fileExists = require('../utils/file-exists.js') +const { isWindowsShell } = require('../utils/is-windows.js') +const fileExists = async (file) => { + try { + const stat = await fs.stat(file) + return stat.isFile() + } catch { + return false + } +} -const { promisify } = require('util') const BaseCommand = require('../base-command.js') class Completion extends BaseCommand { static description = 'Tab Completion for npm' static name = 'completion' + static ignoreImplicitWorkspace = true // completion for the completion command async completion (opts) { @@ -97,17 +105,17 @@ class Completion extends BaseCommand { const word = words[w] const line = COMP_LINE const point = +COMP_POINT - const partialLine = line.substr(0, point) + const partialLine = line.slice(0, point) const partialWords = words.slice(0, w) // figure out where in that last word the point is. const partialWordRaw = args[w] let i = partialWordRaw.length - while (partialWordRaw.substr(0, i) !== partialLine.substr(-1 * i) && i > 0) { + while (partialWordRaw.slice(0, i) !== partialLine.slice(-1 * i) && i > 0) { i-- } - const partialWord = unescape(partialWordRaw.substr(0, i)) + const partialWord = unescape(partialWordRaw.slice(0, i)) partialWords.push(partialWord) const opts = { @@ -151,7 +159,7 @@ class Completion extends BaseCommand { // check if there's a command already. const cmd = parsed.argv.remain[1] if (!cmd) { - return this.wrap(opts, cmdCompl(opts)) + return this.wrap(opts, cmdCompl(opts, this.npm)) } Object.keys(parsed).forEach(k => this.npm.config.set(k, parsed[k])) @@ -189,12 +197,10 @@ class Completion extends BaseCommand { } const dumpScript = async () => { - const fs = require('fs') - const readFile = promisify(fs.readFile) const { resolve } = require('path') const p = resolve(__dirname, '..', 'utils', 'completion.sh') - const d = (await readFile(p, 'utf8')).replace(/^#!.*?\n/, '') + const d = (await fs.readFile(p, 'utf8')).replace(/^#!.*?\n/, '') await new Promise((res, rej) => { let done = false process.stdout.on('error', er => { @@ -268,13 +274,13 @@ const isFlag = word => { // complete against the npm commands // if they all resolve to the same thing, just return the thing it already is -const cmdCompl = opts => { +const cmdCompl = (opts, npm) => { const matches = fullList.filter(c => c.startsWith(opts.partialWord)) if (!matches.length) { return matches } - const derefs = new Set([...matches.map(c => deref(c))]) + const derefs = new Set([...matches.map(c => npm.deref(c))]) if (derefs.size === 1) { return [...derefs] } diff --git a/lib/commands/config.js b/lib/commands/config.js index 96524e0..103fbb5 100644 --- a/lib/commands/config.js +++ b/lib/commands/config.js @@ -1,12 +1,8 @@ // don't expand so that we only assemble the set of defaults when needed const configDefs = require('../utils/config/index.js') -const mkdirp = require('mkdirp-infer-owner') +const { mkdir, readFile, writeFile } = require('fs/promises') const { dirname, resolve } = require('path') -const { promisify } = require('util') -const fs = require('fs') -const readFile = promisify(fs.readFile) -const writeFile = promisify(fs.writeFile) const { spawn } = require('child_process') const { EOL } = require('os') const ini = require('ini') @@ -14,6 +10,18 @@ const localeCompare = require('@isaacs/string-locale-compare')('en') const rpj = require('read-package-json-fast') const log = require('../utils/log-shim.js') +// These are the configs that we can nerf-dart. Not all of them currently even +// *have* config definitions so we have to explicitly validate them here +const nerfDarts = [ + '_auth', + '_authToken', + 'username', + '_password', + 'email', + 'certfile', + 'keyfile', +] + // take an array of `[key, value, k2=v2, k3, v3, ...]` and turn into // { key: value, k2: v2, k3: v3 } const keyValues = args => { @@ -51,6 +59,7 @@ class Config extends BaseCommand { 'delete <key> [<key> ...]', 'list [--json]', 'edit', + 'fix', ] static params = [ @@ -61,6 +70,10 @@ class Config extends BaseCommand { 'long', ] + static ignoreImplicitWorkspace = false + + static skipConfigValidation = true + async completion (opts) { const argv = opts.conf.argv.remain if (argv[1] !== 'config') { @@ -68,7 +81,7 @@ class Config extends BaseCommand { } if (argv.length === 2) { - const cmds = ['get', 'set', 'delete', 'ls', 'rm', 'edit'] + const cmds = ['get', 'set', 'delete', 'ls', 'rm', 'edit', 'fix'] if (opts.partialWord !== 'l') { cmds.push('list') } @@ -93,6 +106,7 @@ class Config extends BaseCommand { case 'edit': case 'list': case 'ls': + case 'fix': default: return [] } @@ -125,6 +139,9 @@ class Config extends BaseCommand { case 'edit': await this.edit() break + case 'fix': + await this.fix() + break default: throw this.usageError() } @@ -141,6 +158,16 @@ class Config extends BaseCommand { const where = this.npm.flatOptions.location for (const [key, val] of Object.entries(keyValues(args))) { log.info('config', 'set %j %j', key, val) + const baseKey = key.split(':').pop() + if (!this.npm.config.definitions[baseKey] && !nerfDarts.includes(baseKey)) { + throw new Error(`\`${baseKey}\` is not a valid npm option`) + } + const deprecated = this.npm.config.definitions[baseKey]?.deprecated + if (deprecated) { + throw new Error( + `The \`${baseKey}\` option is deprecated, and can not be set in this way${deprecated}` + ) + } this.npm.config.set(key, val || '', where) if (!this.npm.config.validate(where)) { log.warn('config', 'omitting invalid config values') @@ -158,7 +185,7 @@ class Config extends BaseCommand { const out = [] for (const key of keys) { if (!publicVar(key)) { - throw new Error(`The ${key} option is protected, and cannot be retrieved in this way`) + throw new Error(`The ${key} option is protected, and can not be retrieved in this way`) } const pref = keys.length > 1 ? `${key}=` : '' @@ -222,7 +249,7 @@ ${data.split('\n').sort(localeCompare).join('\n').trim()} ${defData} `.split('\n').join(EOL) - await mkdirp(dirname(file)) + await mkdir(dirname(file), { recursive: true }) await writeFile(file, tmpData, 'utf8') await new Promise((resolve, reject) => { const [bin, ...args] = e.split(/\s+/) @@ -236,6 +263,49 @@ ${defData} }) } + async fix () { + let problems + + try { + this.npm.config.validate() + return // if validate doesn't throw we have nothing to do + } catch (err) { + // coverage skipped because we don't need to test rethrowing errors + // istanbul ignore next + if (err.code !== 'ERR_INVALID_AUTH') { + throw err + } + + problems = err.problems + } + + if (!this.npm.config.isDefault('location')) { + problems = problems.filter((problem) => { + return problem.where === this.npm.config.get('location') + }) + } + + this.npm.config.repair(problems) + const locations = [] + + this.npm.output('The following configuration problems have been repaired:\n') + const summary = problems.map(({ action, from, to, key, where }) => { + // coverage disabled for else branch because it is intentionally omitted + // istanbul ignore else + if (action === 'rename') { + // we keep track of which configs were modified here so we know what to save later + locations.push(where) + return `~ \`${from}\` renamed to \`${to}\` in ${where} config` + } else if (action === 'delete') { + locations.push(where) + return `- \`${key}\` deleted from ${where} config` + } + }).join('\n') + this.npm.output(summary) + + return await Promise.all(locations.map((location) => this.npm.config.save(location))) + } + async list () { const msg = [] // long does not have a flattener @@ -264,6 +334,9 @@ ${defData} if (!long) { msg.push( `; node bin location = ${process.execPath}`, + `; node version = ${process.version}`, + `; npm local prefix = ${this.npm.localPrefix}`, + `; npm version = ${this.npm.version}`, `; cwd = ${process.cwd()}`, `; HOME = ${process.env.HOME}`, '; Run `npm config ls -l` to show all defaults.' @@ -271,7 +344,7 @@ ${defData} msg.push('') } - if (!this.npm.config.get('global')) { + if (!this.npm.global) { const pkgPath = resolve(this.npm.prefix, 'package.json') const pkg = await rpj(pkgPath).catch(() => ({})) diff --git a/lib/commands/dedupe.js b/lib/commands/dedupe.js index 1c27024..0cc0e80 100644 --- a/lib/commands/dedupe.js +++ b/lib/commands/dedupe.js @@ -1,7 +1,6 @@ // dedupe duplicated packages, or find them in the tree const Arborist = require('@npmcli/arborist') const reifyFinish = require('../utils/reify-finish.js') -const log = require('../utils/log-shim.js') const ArboristWorkspaceCmd = require('../arborist-cmd.js') @@ -9,11 +8,11 @@ class Dedupe extends ArboristWorkspaceCmd { static description = 'Reduce duplication in the package tree' static name = 'dedupe' static params = [ - 'global-style', + 'install-strategy', 'legacy-bundling', + 'global-style', 'strict-peer-deps', 'package-lock', - 'save', 'omit', 'ignore-scripts', 'audit', @@ -24,26 +23,23 @@ class Dedupe extends ArboristWorkspaceCmd { ] async exec (args) { - if (this.npm.config.get('global')) { + if (this.npm.global) { const er = new Error('`npm dedupe` does not work in global mode.') er.code = 'EDEDUPEGLOBAL' throw er } - // In the context of `npm dedupe` the save - // config value should default to `false` - const save = this.npm.config.isDefault('save') - ? false - : this.npm.config.get('save') - const dryRun = this.npm.config.get('dry-run') const where = this.npm.prefix const opts = { ...this.npm.flatOptions, - log, path: where, dryRun, - save, + // Saving during dedupe would only update if one of your direct + // dependencies was also duplicated somewhere in your tree. It would be + // confusing if running this were to also update your package.json. In + // order to reduce potential confusion we set this to false. + save: false, workspaces: this.workspaceNames, } const arb = new Arborist(opts) diff --git a/lib/commands/deprecate.js b/lib/commands/deprecate.js index 5505b9b..1e1b899 100644 --- a/lib/commands/deprecate.js +++ b/lib/commands/deprecate.js @@ -1,5 +1,4 @@ const fetch = require('npm-registry-fetch') -const log = require('../utils/log-shim.js') const otplease = require('../utils/otplease.js') const npa = require('npm-package-arg') const semver = require('semver') @@ -10,19 +9,21 @@ const BaseCommand = require('../base-command.js') class Deprecate extends BaseCommand { static description = 'Deprecate a version of a package' static name = 'deprecate' - static usage = ['<pkg>[@<version>] <message>'] + static usage = ['<package-spec> <message>'] static params = [ 'registry', 'otp', ] + static ignoreImplicitWorkspace = false + async completion (opts) { if (opts.conf.argv.remain.length > 1) { return [] } const username = await getIdentity(this.npm, this.npm.flatOptions) - const packages = await libaccess.lsPackages(username, this.npm.flatOptions) + const packages = await libaccess.getPackages(username, this.npm.flatOptions) return Object.keys(packages) .filter((name) => packages[name] === 'write' && @@ -38,9 +39,7 @@ class Deprecate extends BaseCommand { // fetch the data and make sure it exists. const p = npa(pkg) - // npa makes the default spec "latest", but for deprecation - // "*" is the appropriate default. - const spec = p.rawSpec === '' ? '*' : p.fetchSpec + const spec = p.rawSpec === '*' ? '*' : p.fetchSpec if (semver.validRange(spec, true) === null) { throw new Error(`invalid version range: ${spec}`) @@ -51,7 +50,6 @@ class Deprecate extends BaseCommand { ...this.npm.flatOptions, spec: p, query: { write: true }, - log, }) Object.keys(packument.versions) @@ -60,13 +58,12 @@ class Deprecate extends BaseCommand { packument.versions[v].deprecated = msg }) - return otplease(this.npm.flatOptions, opts => fetch(uri, { + return otplease(this.npm, this.npm.flatOptions, opts => fetch(uri, { ...opts, spec: p, method: 'PUT', body: packument, ignoreBody: true, - log, })) } } diff --git a/lib/commands/diff.js b/lib/commands/diff.js index b3855aa..c8fd734 100644 --- a/lib/commands/diff.js +++ b/lib/commands/diff.js @@ -6,7 +6,7 @@ const Arborist = require('@npmcli/arborist') const pacote = require('pacote') const pickManifest = require('npm-pick-manifest') const log = require('../utils/log-shim') -const readPackageName = require('../utils/read-package-name.js') +const readPackage = require('read-package-json-fast') const BaseCommand = require('../base-command.js') class Diff extends BaseCommand { @@ -32,6 +32,8 @@ class Diff extends BaseCommand { 'include-workspace-root', ] + static ignoreImplicitWorkspace = false + async exec (args) { const specs = this.npm.config.get('diff').filter(d => d) if (specs.length > 2) { @@ -48,7 +50,7 @@ class Diff extends BaseCommand { // node_modules is sometimes under ./lib, and in global mode we're only ever // walking through node_modules (because we will have been given a package // name already) - if (this.npm.config.get('global')) { + if (this.npm.global) { this.top = resolve(this.npm.globalDir, '..') } else { this.top = this.prefix @@ -61,7 +63,6 @@ class Diff extends BaseCommand { ...this.npm.flatOptions, diffFiles: args, where: this.top, - log, }) return this.npm.output(res) } @@ -80,7 +81,8 @@ class Diff extends BaseCommand { async packageName (path) { let name try { - name = await readPackageName(this.prefix) + const pkg = await readPackage(resolve(this.prefix, 'package.json')) + name = pkg.name } catch (e) { log.verbose('diff', 'could not read project dir package.json') } @@ -104,7 +106,7 @@ class Diff extends BaseCommand { const pkgName = await this.packageName(this.prefix) return [ `${pkgName}@${this.npm.config.get('tag')}`, - `file:${this.prefix}`, + `file:${this.prefix.replace(/#/g, '%23')}`, ] } @@ -113,7 +115,8 @@ class Diff extends BaseCommand { let noPackageJson let pkgName try { - pkgName = await readPackageName(this.prefix) + const pkg = await readPackage(resolve(this.prefix, 'package.json')) + pkgName = pkg.name } catch (e) { log.verbose('diff', 'could not read project dir package.json') noPackageJson = true @@ -131,7 +134,7 @@ class Diff extends BaseCommand { } return [ `${pkgName}@${a}`, - `file:${this.prefix}`, + `file:${this.prefix.replace(/#/g, '%23')}`, ] } @@ -162,7 +165,7 @@ class Diff extends BaseCommand { } return [ `${spec.name}@${spec.fetchSpec}`, - `file:${this.prefix}`, + `file:${this.prefix.replace(/#/g, '%23')}`, ] } @@ -175,14 +178,14 @@ class Diff extends BaseCommand { } } - const aSpec = `file:${node.realpath}` + const aSpec = `file:${node.realpath.replace(/#/g, '%23')}` // finds what version of the package to compare against, if a exact // version or tag was passed than it should use that, otherwise // work from the top of the arborist tree to find the original semver // range declared in the package that depends on the package. let bSpec - if (spec.rawSpec) { + if (spec.rawSpec !== '*') { bSpec = spec.rawSpec } else { const bTargetVersion = @@ -194,7 +197,6 @@ class Diff extends BaseCommand { const packument = await pacote.packument(spec, { ...this.npm.flatOptions, preferOnline: true, - log, }) bSpec = pickManifest( packument, @@ -209,8 +211,8 @@ class Diff extends BaseCommand { ] } else if (spec.type === 'directory') { return [ - `file:${spec.fetchSpec}`, - `file:${this.prefix}`, + `file:${spec.fetchSpec.replace(/#/g, '%23')}`, + `file:${this.prefix.replace(/#/g, '%23')}`, ] } else { throw this.usageError(`Spec type ${spec.type} not supported.`) @@ -225,7 +227,8 @@ class Diff extends BaseCommand { if (semverA && semverB) { let pkgName try { - pkgName = await readPackageName(this.prefix) + const pkg = await readPackage(resolve(this.prefix, 'package.json')) + pkgName = pkg.name } catch (e) { log.verbose('diff', 'could not read project dir package.json') } @@ -266,7 +269,7 @@ class Diff extends BaseCommand { return specs.map(i => { const spec = npa(i) - if (spec.rawSpec) { + if (spec.rawSpec !== '*') { return i } @@ -276,7 +279,7 @@ class Diff extends BaseCommand { const res = !node || !node.package || !node.package.version ? spec.fetchSpec - : `file:${node.realpath}` + : `file:${node.realpath.replace(/#/g, '%23')}` return `${spec.name}@${res}` }) diff --git a/lib/commands/dist-tag.js b/lib/commands/dist-tag.js index e2b0132..8052e4f 100644 --- a/lib/commands/dist-tag.js +++ b/lib/commands/dist-tag.js @@ -1,9 +1,10 @@ const npa = require('npm-package-arg') +const path = require('path') const regFetch = require('npm-registry-fetch') const semver = require('semver') const log = require('../utils/log-shim') const otplease = require('../utils/otplease.js') -const readPackageName = require('../utils/read-package-name.js') +const readPackage = require('read-package-json-fast') const BaseCommand = require('../base-command.js') class DistTag extends BaseCommand { @@ -11,11 +12,13 @@ class DistTag extends BaseCommand { static params = ['workspace', 'workspaces', 'include-workspace-root'] static name = 'dist-tag' static usage = [ - 'add <pkg>@<version> [<tag>]', - 'rm <pkg> <tag>', - 'ls [<pkg>]', + 'add <package-spec (with version)> [<tag>]', + 'rm <package-spec> <tag>', + 'ls [<package-spec>]', ] + static ignoreImplicitWorkspace = false + async completion (opts) { const argv = opts.conf.argv.remain if (argv.length === 2) { @@ -31,7 +34,6 @@ class DistTag extends BaseCommand { async exec ([cmdName, pkg, tag]) { const opts = { ...this.npm.flatOptions, - log, } if (['add', 'a', 'set', 's'].includes(cmdName)) { @@ -88,7 +90,7 @@ class DistTag extends BaseCommand { log.verbose('dist-tag add', defaultTag, 'to', spec.name + '@' + version) if (!spec.name || !version || !defaultTag) { - throw this.usageError() + throw this.usageError('must provide a spec with a name and version, and a tag to add') } const t = defaultTag.trim() @@ -114,7 +116,7 @@ class DistTag extends BaseCommand { }, spec, } - await otplease(reqOpts, reqOpts => regFetch(url, reqOpts)) + await otplease(this.npm, reqOpts, reqOpts => regFetch(url, reqOpts)) this.npm.output(`+${t}: ${spec.name}@${version}`) } @@ -140,21 +142,21 @@ class DistTag extends BaseCommand { method: 'DELETE', spec, } - await otplease(reqOpts, reqOpts => regFetch(url, reqOpts)) + await otplease(this.npm, reqOpts, reqOpts => regFetch(url, reqOpts)) this.npm.output(`-${tag}: ${spec.name}@${version}`) } async list (spec, opts) { if (!spec) { - if (this.npm.config.get('global')) { + if (this.npm.global) { throw this.usageError() } - const pkg = await readPackageName(this.npm.prefix) - if (!pkg) { + const { name } = await readPackage(path.resolve(this.npm.prefix, 'package.json')) + if (!name) { throw this.usageError() } - return this.list(pkg, opts) + return this.list(name, opts) } spec = npa(spec) diff --git a/lib/commands/docs.js b/lib/commands/docs.js index 19cd735..5d20215 100644 --- a/lib/commands/docs.js +++ b/lib/commands/docs.js @@ -1,53 +1,19 @@ -const pacote = require('pacote') -const openUrl = require('../utils/open-url.js') -const hostedFromMani = require('../utils/hosted-git-info-from-manifest.js') -const log = require('../utils/log-shim') -const BaseCommand = require('../base-command.js') -class Docs extends BaseCommand { +const PackageUrlCmd = require('../package-url-cmd.js') +class Docs extends PackageUrlCmd { static description = 'Open documentation for a package in a web browser' static name = 'docs' - static params = [ - 'browser', - 'registry', - 'workspace', - 'workspaces', - 'include-workspace-root', - ] - static usage = ['[<pkgname> [<pkgname> ...]]'] - - async exec (args) { - if (!args || !args.length) { - args = ['.'] - } - - await Promise.all(args.map(pkg => this.getDocs(pkg))) - } - - async execWorkspaces (args, filters) { - await this.setWorkspaces(filters) - return this.exec(this.workspacePaths) - } - - async getDocs (pkg) { - const opts = { ...this.npm.flatOptions, fullMetadata: true } - const mani = await pacote.manifest(pkg, opts) - const url = this.getDocsUrl(mani) - log.silly('docs', 'url', url) - await openUrl(this.npm, url, `${mani.name} docs available at the following URL`) - } - - getDocsUrl (mani) { + getUrl (spec, mani) { if (mani.homepage) { return mani.homepage } - const info = hostedFromMani(mani) + const info = this.hostedFromMani(mani) if (info) { return info.docs() } - return 'https://www.npmjs.com/package/' + mani.name + return `https://www.npmjs.com/package/${mani.name}` } } module.exports = Docs diff --git a/lib/commands/doctor.js b/lib/commands/doctor.js index 47a522e..19262e5 100644 --- a/lib/commands/doctor.js +++ b/lib/commands/doctor.js @@ -1,16 +1,13 @@ const cacache = require('cacache') -const chalk = require('chalk') const fs = require('fs') const fetch = require('make-fetch-happen') -const table = require('text-table') +const Table = require('cli-table3') const which = require('which') const pacote = require('pacote') const { resolve } = require('path') const semver = require('semver') const { promisify } = require('util') const log = require('../utils/log-shim.js') -const ansiTrim = require('../utils/ansi-trim.js') -const isWindows = require('../utils/is-windows.js') const ping = require('../utils/ping.js') const { registry: { default: defaultRegistry }, @@ -19,6 +16,7 @@ const lstat = promisify(fs.lstat) const readdir = promisify(fs.readdir) const access = promisify(fs.access) const { R_OK, W_OK, X_OK } = fs.constants + const maskLabel = mask => { const label = [] if (mask & R_OK) { @@ -36,104 +34,125 @@ const maskLabel = mask => { return label.join(', ') } +const subcommands = [ + { + groups: ['ping', 'registry'], + title: 'npm ping', + cmd: 'checkPing', + }, { + groups: ['versions'], + title: 'npm -v', + cmd: 'getLatestNpmVersion', + }, { + groups: ['versions'], + title: 'node -v', + cmd: 'getLatestNodejsVersion', + }, { + groups: ['registry'], + title: 'npm config get registry', + cmd: 'checkNpmRegistry', + }, { + groups: ['environment'], + title: 'git executable in PATH', + cmd: 'getGitPath', + }, { + groups: ['environment'], + title: 'global bin folder in PATH', + cmd: 'getBinPath', + }, { + groups: ['permissions', 'cache'], + title: 'Perms check on cached files', + cmd: 'checkCachePermission', + windows: false, + }, { + groups: ['permissions'], + title: 'Perms check on local node_modules', + cmd: 'checkLocalModulesPermission', + windows: false, + }, { + groups: ['permissions'], + title: 'Perms check on global node_modules', + cmd: 'checkGlobalModulesPermission', + windows: false, + }, { + groups: ['permissions'], + title: 'Perms check on local bin folder', + cmd: 'checkLocalBinPermission', + windows: false, + }, { + groups: ['permissions'], + title: 'Perms check on global bin folder', + cmd: 'checkGlobalBinPermission', + windows: false, + }, { + groups: ['cache'], + title: 'Verify cache contents', + cmd: 'verifyCachedFiles', + windows: false, + }, + // TODO: + // group === 'dependencies'? + // - ensure arborist.loadActual() runs without errors and no invalid edges + // - ensure package-lock.json matches loadActual() + // - verify loadActual without hidden lock file matches hidden lockfile + // group === '???' + // - verify all local packages have bins linked + // What is the fix for these? +] const BaseCommand = require('../base-command.js') class Doctor extends BaseCommand { static description = 'Check your npm environment' static name = 'doctor' static params = ['registry'] + static ignoreImplicitWorkspace = false + static usage = [`[${subcommands.flatMap(s => s.groups) + .filter((value, index, self) => self.indexOf(value) === index) + .join('] [')}]`] + + static subcommands = subcommands + + // minimum width of check column, enough for the word `Check` + #checkWidth = 5 async exec (args) { log.info('Running checkup') - - // each message is [title, ok, message] - const messages = [] - - const actions = [ - ['npm ping', 'checkPing', []], - ['npm -v', 'getLatestNpmVersion', []], - ['node -v', 'getLatestNodejsVersion', []], - ['npm config get registry', 'checkNpmRegistry', []], - ['which git', 'getGitPath', []], - ...(isWindows - ? [] - : [ - ['Perms check on cached files', 'checkFilesPermission', [this.npm.cache, true, R_OK]], - [ - 'Perms check on local node_modules', - 'checkFilesPermission', - [this.npm.localDir, true], - ], - [ - 'Perms check on global node_modules', - 'checkFilesPermission', - [this.npm.globalDir, false], - ], - [ - 'Perms check on local bin folder', - 'checkFilesPermission', - [this.npm.localBin, false, R_OK | W_OK | X_OK], - ], - [ - 'Perms check on global bin folder', - 'checkFilesPermission', - [this.npm.globalBin, false, X_OK], - ], - ]), - ['Verify cache contents', 'verifyCachedFiles', [this.npm.flatOptions.cache]], - // TODO: - // - ensure arborist.loadActual() runs without errors and no invalid edges - // - ensure package-lock.json matches loadActual() - // - verify loadActual without hidden lock file matches hidden lockfile - // - verify all local packages have bins linked - ] - - // Do the actual work - for (const [msg, fn, args] of actions) { - const line = [msg] - try { - line.push(true, await this[fn](...args)) - } catch (er) { - line.push(false, er) - } - messages.push(line) - } - - const outHead = ['Check', 'Value', 'Recommendation/Notes'].map( - !this.npm.color ? h => h : h => chalk.underline(h) - ) let allOk = true - const outBody = messages.map( - !this.npm.color - ? item => { - allOk = allOk && item[1] - item[1] = item[1] ? 'ok' : 'not ok' - item[2] = String(item[2]) - return item - } - : item => { - allOk = allOk && item[1] - if (!item[1]) { - item[0] = chalk.red(item[0]) - item[2] = chalk.magenta(String(item[2])) - } - item[1] = item[1] ? chalk.green('ok') : chalk.red('not ok') - return item - } - ) - const outTable = [outHead, ...outBody] - const tableOpts = { - stringLength: s => ansiTrim(s).length, - } - const silent = log.levels[log.level] > log.levels.error - if (!silent) { - this.npm.output(table(outTable, tableOpts)) - if (!allOk) { - console.error('') + const actions = this.actions(args) + this.#checkWidth = actions.reduce((length, item) => + Math.max(item.title.length, length), this.#checkWidth) + + if (!this.npm.silent) { + this.output(['Check', 'Value', 'Recommendation/Notes'].map(h => this.npm.chalk.underline(h))) + } + // Do the actual work + for (const { title, cmd } of actions) { + const item = [title] + try { + item.push(true, await this[cmd]()) + } catch (err) { + item.push(false, err) + } + if (!item[1]) { + allOk = false + item[0] = this.npm.chalk.red(item[0]) + item[1] = this.npm.chalk.red('not ok') + item[2] = this.npm.chalk.magenta(String(item[2])) + } else { + item[1] = this.npm.chalk.green('ok') + } + if (!this.npm.silent) { + this.output(item) } } + if (!allOk) { - throw new Error('Some problems found. See above for recommendations.') + if (this.npm.silent) { + /* eslint-disable-next-line max-len */ + throw new Error('Some problems found. Check logs or disable silent mode for recommendations.') + } else { + throw new Error('Some problems found. See above for recommendations.') + } } } @@ -141,11 +160,11 @@ class Doctor extends BaseCommand { const tracker = log.newItem('checkPing', 1) tracker.info('checkPing', 'Pinging registry') try { - await ping(this.npm.flatOptions) + await ping({ ...this.npm.flatOptions, retry: false }) return '' } catch (er) { if (/^E\d{3}$/.test(er.code || '')) { - throw er.code.substr(1) + ' ' + er.message + throw er.code.slice(1) + ' ' + er.message } else { throw er.message } @@ -201,11 +220,36 @@ class Doctor extends BaseCommand { } } - async checkFilesPermission (root, shouldOwn, mask = null) { - if (mask === null) { - mask = shouldOwn ? R_OK | W_OK : R_OK + async getBinPath (dir) { + const tracker = log.newItem('getBinPath', 1) + tracker.info('getBinPath', 'Finding npm global bin in your PATH') + if (!process.env.PATH.includes(this.npm.globalBin)) { + throw new Error(`Add ${this.npm.globalBin} to your $PATH`) } + return this.npm.globalBin + } + async checkCachePermission () { + return this.checkFilesPermission(this.npm.cache, true, R_OK) + } + + async checkLocalModulesPermission () { + return this.checkFilesPermission(this.npm.localDir, true, R_OK | W_OK, true) + } + + async checkGlobalModulesPermission () { + return this.checkFilesPermission(this.npm.globalDir, false, R_OK) + } + + async checkLocalBinPermission () { + return this.checkFilesPermission(this.npm.localBin, false, R_OK | W_OK | X_OK, true) + } + + async checkGlobalBinPermission () { + return this.checkFilesPermission(this.npm.globalBin, false, X_OK) + } + + async checkFilesPermission (root, shouldOwn, mask, missingOk) { let ok = true const tracker = log.newItem(root, 1) @@ -215,10 +259,13 @@ class Doctor extends BaseCommand { const gid = process.getgid() const files = new Set([root]) for (const f of files) { - tracker.silly('checkFilesPermission', f.substr(root.length + 1)) + tracker.silly('checkFilesPermission', f.slice(root.length + 1)) const st = await lstat(f).catch(er => { - ok = false - tracker.warn('checkFilesPermission', 'error getting info for ' + f) + // if it can't be missing, or if it can and the error wasn't that it was missing + if (!missingOk || er.code !== 'ENOENT') { + ok = false + tracker.warn('checkFilesPermission', 'error getting info for ' + f) + } }) tracker.completeWork(1) @@ -275,7 +322,7 @@ class Doctor extends BaseCommand { try { return await which('git').catch(er => { tracker.warn(er) - throw "Install git and ensure it's in your PATH." + throw new Error("Install git and ensure it's in your PATH.") }) } finally { tracker.finish() @@ -323,6 +370,42 @@ class Doctor extends BaseCommand { return `using default registry (${defaultRegistry})` } } + + output (row) { + const t = new Table({ + chars: { top: '', + 'top-mid': '', + 'top-left': '', + 'top-right': '', + bottom: '', + 'bottom-mid': '', + 'bottom-left': '', + 'bottom-right': '', + left: '', + 'left-mid': '', + mid: '', + 'mid-mid': '', + right: '', + 'right-mid': '', + middle: ' ' }, + style: { 'padding-left': 0, 'padding-right': 0 }, + colWidths: [this.#checkWidth, 6], + }) + t.push(row) + this.npm.output(t.toString()) + } + + actions (params) { + return this.constructor.subcommands.filter(subcmd => { + if (process.platform === 'win32' && subcmd.windows === false) { + return false + } + if (params.length) { + return params.some(param => subcmd.groups.includes(param)) + } + return true + }) + } } module.exports = Doctor diff --git a/lib/commands/edit.js b/lib/commands/edit.js index 5f069c4..67ac32e 100644 --- a/lib/commands/edit.js +++ b/lib/commands/edit.js @@ -3,16 +3,38 @@ const { resolve } = require('path') const fs = require('graceful-fs') -const { spawn } = require('child_process') -const splitPackageNames = require('../utils/split-package-names.js') +const cp = require('child_process') const completion = require('../utils/completion/installed-shallow.js') const BaseCommand = require('../base-command.js') +const splitPackageNames = (path) => { + return path.split('/') + // combine scoped parts + .reduce((parts, part) => { + if (parts.length === 0) { + return [part] + } + + const lastPart = parts[parts.length - 1] + // check if previous part is the first part of a scoped package + if (lastPart[0] === '@' && !lastPart.includes('/')) { + parts[parts.length - 1] += '/' + part + } else { + parts.push(part) + } + + return parts + }, []) + .join('/node_modules/') + .replace(/(\/node_modules)+/, '/node_modules') +} + class Edit extends BaseCommand { static description = 'Edit an installed package' static name = 'edit' static usage = ['<pkg>[/<subpkg>...]'] static params = ['editor'] + static ignoreImplicitWorkspace = false // TODO /* istanbul ignore next */ @@ -35,12 +57,17 @@ class Edit extends BaseCommand { return reject(err) } const [bin, ...args] = this.npm.config.get('editor').split(/\s+/) - const editor = spawn(bin, [...args, dir], { stdio: 'inherit' }) - editor.on('exit', (code) => { + const editor = cp.spawn(bin, [...args, dir], { stdio: 'inherit' }) + editor.on('exit', async (code) => { if (code) { return reject(new Error(`editor process exited with code: ${code}`)) } - this.npm.exec('rebuild', [dir]).catch(reject).then(resolve) + try { + await this.npm.exec('rebuild', [dir]) + } catch (err) { + reject(err) + } + resolve() }) }) }) diff --git a/lib/commands/exec.js b/lib/commands/exec.js index 61a6d96..a77a632 100644 --- a/lib/commands/exec.js +++ b/lib/commands/exec.js @@ -1,32 +1,6 @@ +const path = require('path') const libexec = require('libnpmexec') const BaseCommand = require('../base-command.js') -const getLocationMsg = require('../exec/get-workspace-location-msg.js') -const log = require('../utils/log-shim') - -// it's like this: -// -// npm x pkg@version <-- runs the bin named "pkg" or the only bin if only 1 -// -// { name: 'pkg', bin: { pkg: 'pkg.js', foo: 'foo.js' }} <-- run pkg -// { name: 'pkg', bin: { foo: 'foo.js' }} <-- run foo? -// -// npm x -p pkg@version -- foo -// -// npm x -p pkg@version -- foo --registry=/dev/null -// -// const pkg = npm.config.get('package') || getPackageFrom(args[0]) -// const cmd = getCommand(pkg, args[0]) -// --> npm x -c 'cmd ...args.slice(1)' -// -// we've resolved cmd and args, and escaped them properly, and installed the -// relevant packages. -// -// Add the ${npx install prefix}/node_modules/.bin to PATH -// -// pkg = readPackageJson('./package.json') -// pkg.scripts.___npx = ${the -c arg} -// runScript({ pkg, event: 'npx', ... }) -// process.env.npm_lifecycle_event = 'npx' class Exec extends BaseCommand { static description = 'Run a command from a local or remote npm package' @@ -46,26 +20,37 @@ class Exec extends BaseCommand { '--package=foo -c \'<cmd> [args...]\'', ] - async exec (_args, { locationMsg, path, runPath } = {}) { - if (!path) { - path = this.npm.localPrefix - } + static ignoreImplicitWorkspace = false + static isShellout = true + async exec (_args, { locationMsg, runPath } = {}) { + // This is where libnpmexec will look for locally installed packages + const localPrefix = this.npm.localPrefix + + // This is where libnpmexec will actually run the scripts from if (!runPath) { runPath = process.cwd() } const args = [..._args] const call = this.npm.config.get('call') + let globalPath const { flatOptions, localBin, globalBin, + globalDir, } = this.npm - const output = (...outputArgs) => this.npm.output(...outputArgs) + const output = this.npm.output.bind(this.npm) const scriptShell = this.npm.config.get('script-shell') || undefined const packages = this.npm.config.get('package') const yes = this.npm.config.get('yes') + // --prefix sets both of these to the same thing, meaning the global prefix + // is invalid (i.e. no lib/node_modules). This is not a trivial thing to + // untangle and fix so we work around it here. + if (this.npm.localPrefix !== this.npm.globalPrefix) { + globalPath = path.resolve(globalDir, '..') + } if (call && _args.length) { throw this.usageError() @@ -73,15 +58,18 @@ class Exec extends BaseCommand { return libexec({ ...flatOptions, + // we explicitly set packageLockOnly to false because if it's true + // when we try to install a missing package, we won't actually install it + packageLockOnly: false, args, call, localBin, locationMsg, - log, globalBin, + globalPath, output, packages, - path, + path: localPrefix, runPath, scriptShell, yes, @@ -90,11 +78,11 @@ class Exec extends BaseCommand { async execWorkspaces (args, filters) { await this.setWorkspaces(filters) - const color = this.npm.color - for (const path of this.workspacePaths) { - const locationMsg = await getLocationMsg({ color, path }) - await this.exec(args, { locationMsg, path, runPath: path }) + for (const [name, path] of this.workspaces) { + const locationMsg = + `in workspace ${this.npm.chalk.green(name)} at location:\n${this.npm.chalk.dim(path)}` + await this.exec(args, { locationMsg, runPath: path }) } } } diff --git a/lib/commands/explain.js b/lib/commands/explain.js index fd62b87..a06ad24 100644 --- a/lib/commands/explain.js +++ b/lib/commands/explain.js @@ -10,12 +10,14 @@ const ArboristWorkspaceCmd = require('../arborist-cmd.js') class Explain extends ArboristWorkspaceCmd { static description = 'Explain installed packages' static name = 'explain' - static usage = ['<folder | specifier>'] + static usage = ['<package-spec>'] static params = [ 'json', 'workspace', ] + static ignoreImplicitWorkspace = false + // TODO /* istanbul ignore next */ async completion (opts) { @@ -57,7 +59,7 @@ class Explain extends ArboristWorkspaceCmd { const expls = [] for (const node of nodes) { - const { extraneous, dev, optional, devOptional, peer, inBundle } = node + const { extraneous, dev, optional, devOptional, peer, inBundle, overridden } = node const expl = node.explain() if (extraneous) { expl.extraneous = true @@ -67,6 +69,7 @@ class Explain extends ArboristWorkspaceCmd { expl.devOptional = devOptional expl.peer = peer expl.bundled = inBundle + expl.overridden = overridden } expls.push(expl) } diff --git a/lib/commands/explore.js b/lib/commands/explore.js index 90e6af6..0d915cb 100644 --- a/lib/commands/explore.js +++ b/lib/commands/explore.js @@ -13,6 +13,7 @@ class Explore extends BaseCommand { static name = 'explore' static usage = ['<pkg> [ -- <command>]'] static params = ['shell'] + static ignoreImplicitWorkspace = false // TODO /* istanbul ignore next */ @@ -58,7 +59,6 @@ class Explore extends BaseCommand { pkg, banner: false, path, - stdioString: true, event: '_explore', stdio: 'inherit', }).catch(er => { diff --git a/lib/commands/find-dupes.js b/lib/commands/find-dupes.js index a9de241..b99ea7a 100644 --- a/lib/commands/find-dupes.js +++ b/lib/commands/find-dupes.js @@ -5,8 +5,9 @@ class FindDupes extends ArboristWorkspaceCmd { static description = 'Find duplication in the package tree' static name = 'find-dupes' static params = [ - 'global-style', + 'install-strategy', 'legacy-bundling', + 'global-style', 'strict-peer-deps', 'package-lock', 'omit', diff --git a/lib/commands/fund.js b/lib/commands/fund.js index 47a51c3..9690cbc 100644 --- a/lib/commands/fund.js +++ b/lib/commands/fund.js @@ -5,7 +5,6 @@ const pacote = require('pacote') const semver = require('semver') const npa = require('npm-package-arg') const { depth } = require('treeverse') -const log = require('../utils/log-shim.js') const { readTree: getFundingInfo, normalizeFunding, isValidFunding } = require('libnpmfund') const completion = require('../utils/completion/installed-deep.js') @@ -21,7 +20,7 @@ class Fund extends ArboristWorkspaceCmd { static description = 'Retrieve funding information' static name = 'fund' static params = ['json', 'browser', 'unicode', 'workspace', 'which'] - static usage = ['[[<@scope>/]<pkg>]'] + static usage = ['[<package-spec>]'] // TODO /* istanbul ignore next */ @@ -46,7 +45,7 @@ class Fund extends ArboristWorkspaceCmd { throw err } - if (this.npm.config.get('global')) { + if (this.npm.global) { const err = new Error('`npm fund` does not support global packages') err.code = 'EFUNDGLOBAL' throw err @@ -69,7 +68,6 @@ class Fund extends ArboristWorkspaceCmd { // TODO: add !workspacesEnabled option handling to libnpmfund const fundingInfo = getFundingInfo(tree, { ...this.flatOptions, - log, workspaces: this.workspaceNames, }) diff --git a/lib/commands/get.js b/lib/commands/get.js index 7583ade..5e92e85 100644 --- a/lib/commands/get.js +++ b/lib/commands/get.js @@ -4,6 +4,7 @@ class Get extends BaseCommand { static description = 'Get a value from the npm configuration' static name = 'get' static usage = ['[<key> ...] (See `npm config`)'] + static ignoreImplicitWorkspace = false // TODO /* istanbul ignore next */ diff --git a/lib/commands/help-search.js b/lib/commands/help-search.js index 6025a6d..488189b 100644 --- a/lib/commands/help-search.js +++ b/lib/commands/help-search.js @@ -1,16 +1,19 @@ const fs = require('fs') const path = require('path') -const color = require('ansicolors') +const chalk = require('chalk') const { promisify } = require('util') const glob = promisify(require('glob')) const readFile = promisify(fs.readFile) const BaseCommand = require('../base-command.js') +const globify = pattern => pattern.split('\\').join('/') + class HelpSearch extends BaseCommand { static description = 'Search npm help documentation' static name = 'help-search' static usage = ['<text>'] static params = ['long'] + static ignoreImplicitWorkspace = true async exec (args) { if (!args.length) { @@ -18,7 +21,7 @@ class HelpSearch extends BaseCommand { } const docPath = path.resolve(__dirname, '..', '..', 'docs/content') - const files = await glob(`${docPath}/*/*.md`) + const files = await glob(`${globify(docPath)}/*/*.md`) const data = await this.readFiles(files) const results = await this.searchFiles(args, data, files) const formatted = this.formatResults(args, results) @@ -170,9 +173,9 @@ class HelpSearch extends BaseCommand { const finder = line.toLowerCase().split(arg.toLowerCase()) let p = 0 for (const f of finder) { - hilitLine.push(line.substr(p, f.length)) - const word = line.substr(p + f.length, arg.length) - const hilit = color.bgBlack(color.red(word)) + hilitLine.push(line.slice(p, p + f.length)) + const word = line.slice(p + f.length, p + f.length + arg.length) + const hilit = chalk.bgBlack.red(word) hilitLine.push(hilit) p += f.length + arg.length } diff --git a/lib/commands/help.js b/lib/commands/help.js index f94178d..e7d6395 100644 --- a/lib/commands/help.js +++ b/lib/commands/help.js @@ -5,25 +5,29 @@ const { promisify } = require('util') const glob = promisify(require('glob')) const localeCompare = require('@isaacs/string-locale-compare')('en') +const globify = pattern => pattern.split('\\').join('/') const BaseCommand = require('../base-command.js') // Strips out the number from foo.7 or foo.7. or foo.7.tgz // We don't currently compress our man pages but if we ever did this would // seemlessly continue supporting it const manNumberRegex = /\.(\d+)(\.[^/\\]*)?$/ +// Searches for the "npm-" prefix in page names, to prefer those. +const manNpmPrefixRegex = /\/npm-/ class Help extends BaseCommand { static description = 'Get help on npm' static name = 'help' static usage = ['<term> [<terms..>]'] static params = ['viewer'] + static ignoreImplicitWorkspace = true async completion (opts) { if (opts.conf.argv.remain.length > 2) { return [] } const g = path.resolve(__dirname, '../../man/man[0-9]/*.[0-9]') - const files = await glob(g) + const files = await glob(globify(g)) return Object.keys(files.reduce(function (acc, file) { file = path.basename(file).replace(/\.[0-9]+$/, '') @@ -58,15 +62,29 @@ class Help extends BaseCommand { const manroot = path.resolve(__dirname, '..', '..', 'man') // find either section.n or npm-section.n const f = `${manroot}/${manSearch}/?(npm-)${section}.[0-9]*` - let mans = await glob(f) + let mans = await glob(globify(f)) mans = mans.sort((a, b) => { - // Because of the glob we know the manNumberRegex will pass - const aManNumber = a.match(manNumberRegex)[1] - const bManNumber = b.match(manNumberRegex)[1] + // Prefer the page with an npm prefix, if there's only one. + const aHasPrefix = manNpmPrefixRegex.test(a) + const bHasPrefix = manNpmPrefixRegex.test(b) + if (aHasPrefix !== bHasPrefix) { + return aHasPrefix ? -1 : 1 + } - // man number sort first so that 1 aka commands are preferred - if (aManNumber !== bManNumber) { - return aManNumber - bManNumber + // Because the glob is (subtly) different from manNumberRegex, + // we can't rely on it passing. + const aManNumberMatch = a.match(manNumberRegex) + const bManNumberMatch = b.match(manNumberRegex) + if (aManNumberMatch) { + if (!bManNumberMatch) { + return -1 + } + // man number sort first so that 1 aka commands are preferred + if (aManNumberMatch[1] !== bManNumberMatch[1]) { + return aManNumberMatch[1] - bManNumberMatch[1] + } + } else if (bManNumberMatch) { + return 1 } return localeCompare(a, b) diff --git a/lib/commands/hook.js b/lib/commands/hook.js index c99a995..084741c 100644 --- a/lib/commands/hook.js +++ b/lib/commands/hook.js @@ -2,7 +2,6 @@ const hookApi = require('libnpmhook') const otplease = require('../utils/otplease.js') const relativeDate = require('tiny-relative-date') const Table = require('cli-table3') -const log = require('../utils/log-shim.js') const BaseCommand = require('../base-command.js') class Hook extends BaseCommand { @@ -20,10 +19,11 @@ class Hook extends BaseCommand { 'update <id> <url> <secret>', ] + static ignoreImplicitWorkspace = true + async exec (args) { - return otplease({ + return otplease(this.npm, { ...this.npm.flatOptions, - log, }, (opts) => { switch (args[0]) { case 'add': @@ -48,7 +48,7 @@ class Hook extends BaseCommand { } else if (opts.parseable) { this.npm.output(Object.keys(hook).join('\t')) this.npm.output(Object.keys(hook).map(k => hook[k]).join('\t')) - } else if (!opts.silent && opts.loglevel !== 'silent') { + } else if (!this.npm.silent) { this.npm.output(`+ ${this.hookName(hook)} ${ opts.unicode ? ' ➜ ' : ' -> ' } ${hook.endpoint}`) @@ -66,7 +66,7 @@ class Hook extends BaseCommand { }) } else if (!hooks.length) { this.npm.output("You don't have any hooks configured yet.") - } else if (!opts.silent && opts.loglevel !== 'silent') { + } else if (!this.npm.silent) { if (hooks.length === 1) { this.npm.output('You have one hook configured.') } else { @@ -103,7 +103,7 @@ class Hook extends BaseCommand { } else if (opts.parseable) { this.npm.output(Object.keys(hook).join('\t')) this.npm.output(Object.keys(hook).map(k => hook[k]).join('\t')) - } else if (!opts.silent && opts.loglevel !== 'silent') { + } else if (!this.npm.silent) { this.npm.output(`- ${this.hookName(hook)} ${ opts.unicode ? ' ✘ ' : ' X ' } ${hook.endpoint}`) @@ -117,7 +117,7 @@ class Hook extends BaseCommand { } else if (opts.parseable) { this.npm.output(Object.keys(hook).join('\t')) this.npm.output(Object.keys(hook).map(k => hook[k]).join('\t')) - } else if (!opts.silent && opts.loglevel !== 'silent') { + } else if (!this.npm.silent) { this.npm.output(`+ ${this.hookName(hook)} ${ opts.unicode ? ' ➜ ' : ' -> ' } ${hook.endpoint}`) @@ -126,9 +126,6 @@ class Hook extends BaseCommand { hookName (hook) { let target = hook.name - if (hook.type === 'scope') { - target = '@' + target - } if (hook.type === 'owner') { target = '~' + target } diff --git a/lib/commands/init.js b/lib/commands/init.js index 7e8a8f7..02a43b0 100644 --- a/lib/commands/init.js +++ b/lib/commands/init.js @@ -1,6 +1,6 @@ const fs = require('fs') const { relative, resolve } = require('path') -const mkdirp = require('mkdirp-infer-owner') +const { mkdir } = require('fs/promises') const initJson = require('init-package-json') const npa = require('npm-package-arg') const rpj = require('read-package-json-fast') @@ -8,20 +8,30 @@ const libexec = require('libnpmexec') const mapWorkspaces = require('@npmcli/map-workspaces') const PackageJson = require('@npmcli/package-json') const log = require('../utils/log-shim.js') +const updateWorkspaces = require('../workspaces/update-workspaces.js') -const getLocationMsg = require('../exec/get-workspace-location-msg.js') const BaseCommand = require('../base-command.js') class Init extends BaseCommand { static description = 'Create a package.json file' - static params = ['yes', 'force', 'workspace', 'workspaces', 'include-workspace-root'] + static params = [ + 'yes', + 'force', + 'scope', + 'workspace', + 'workspaces', + 'workspaces-update', + 'include-workspace-root', + ] + static name = 'init' static usage = [ - '[--force|-f|--yes|-y|--scope]', + '<package-spec> (same as `npx <package-spec>)', '<@scope> (same as `npx <@scope>/create`)', - '[<@scope>/]<name> (same as `npx [<@scope>/]create-<name>`)', ] + static ignoreImplicitWorkspace = false + async exec (args) { // npm exec style if (args.length) { @@ -44,11 +54,13 @@ class Init extends BaseCommand { const pkg = await rpj(resolve(this.npm.localPrefix, 'package.json')) const wPath = filterArg => resolve(this.npm.localPrefix, filterArg) + const workspacesPaths = [] // npm-exec style, runs in the context of each workspace filter if (args.length) { for (const filterArg of filters) { const path = wPath(filterArg) - await mkdirp(path) + await mkdir(path, { recursive: true }) + workspacesPaths.push(path) await this.execCreate({ args, path }) await this.setWorkspace({ pkg, workspacePath: path }) } @@ -58,18 +70,27 @@ class Init extends BaseCommand { // no args, uses classic init-package-json boilerplate for (const filterArg of filters) { const path = wPath(filterArg) - await mkdirp(path) + await mkdir(path, { recursive: true }) + workspacesPaths.push(path) await this.template(path) await this.setWorkspace({ pkg, workspacePath: path }) } + + // reify packages once all workspaces have been initialized + await this.update(workspacesPaths) } async execCreate ({ args, path }) { const [initerName, ...otherArgs] = args let packageName = initerName + // Only a scope, possibly with a version if (/^@[^/]+$/.test(initerName)) { - packageName = initerName + '/create' + const [, scope, version] = initerName.split('@') + packageName = `@${scope}/create` + if (version) { + packageName = `${packageName}@${version}` + } } else { const req = npa(initerName) if (req.type === 'git' && req.hosted) { @@ -77,15 +98,12 @@ class Init extends BaseCommand { packageName = initerName .replace(user + '/' + project, user + '/create-' + project) } else if (req.registry) { - packageName = req.name.replace(/^(@[^/]+\/)?/, '$1create-') - if (req.rawSpec) { - packageName += '@' + req.rawSpec - } + packageName = `${req.name.replace(/^(@[^/]+\/)?/, '$1create-')}@${req.rawSpec}` } else { throw Object.assign(new Error( 'Unrecognized initializer: ' + initerName + '\nFor more package binary executing power check out `npx`:' + - '\nhttps://www.npmjs.com/package/npx' + '\nhttps://docs.npmjs.com/cli/commands/npx' ), { code: 'EUNSUPPORTED' }) } } @@ -97,13 +115,7 @@ class Init extends BaseCommand { localBin, globalBin, } = this.npm - // this function is definitely called. But because of coverage map stuff - // it ends up both uncovered, and the coverage report doesn't even mention. - // the tests do assert that some output happens, so we know this line is - // being hit. - /* istanbul ignore next */ - const output = (...outputArgs) => this.npm.output(...outputArgs) - const locationMsg = await getLocationMsg({ color, path }) + const output = this.npm.output.bind(this.npm) const runPath = path const scriptShell = this.npm.config.get('script-shell') || undefined const yes = this.npm.config.get('yes') @@ -113,8 +125,6 @@ class Init extends BaseCommand { args: newArgs, color, localBin, - locationMsg, - log, globalBin, output, path, @@ -195,6 +205,34 @@ class Init extends BaseCommand { await pkgJson.save() } + + async update (workspacesPaths) { + // translate workspaces paths into an array containing workspaces names + const workspaces = [] + for (const path of workspacesPaths) { + const pkgPath = resolve(path, 'package.json') + const { name } = await rpj(pkgPath) + .catch(() => ({})) + + if (name) { + workspaces.push(name) + } + } + + const { + config, + flatOptions, + localPrefix, + } = this.npm + + await updateWorkspaces({ + config, + flatOptions, + localPrefix, + npm: this.npm, + workspaces, + }) + } } module.exports = Init diff --git a/lib/commands/install.js b/lib/commands/install.js index a92a5ed..246d7fd 100644 --- a/lib/commands/install.js +++ b/lib/commands/install.js @@ -14,15 +14,19 @@ const ArboristWorkspaceCmd = require('../arborist-cmd.js') class Install extends ArboristWorkspaceCmd { static description = 'Install a package' static name = 'install' + + // These are in the order they will show up in when running "-h" static params = [ 'save', 'save-exact', 'global', - 'global-style', + 'install-strategy', 'legacy-bundling', + 'global-style', + 'omit', 'strict-peer-deps', 'package-lock', - 'omit', + 'foreground-scripts', 'ignore-scripts', 'audit', 'bin-links', @@ -31,18 +35,7 @@ class Install extends ArboristWorkspaceCmd { ...super.params, ] - static usage = [ - '[<@scope>/]<pkg>', - '[<@scope>/]<pkg>@<tag>', - '[<@scope>/]<pkg>@<version>', - '[<@scope>/]<pkg>@<version range>', - '<alias>@npm:<name>', - '<folder>', - '<tarball file>', - '<tarball url>', - '<git:// url>', - '<github username>/<github project>', - ] + static usage = ['[<package-spec> ...]'] async completion (opts) { const { partialWord } = opts @@ -103,10 +96,9 @@ class Install extends ArboristWorkspaceCmd { // the /path/to/node_modules/.. const globalTop = resolve(this.npm.globalDir, '..') const ignoreScripts = this.npm.config.get('ignore-scripts') - const isGlobalInstall = this.npm.config.get('global') + const isGlobalInstall = this.npm.global const where = isGlobalInstall ? globalTop : this.npm.prefix const forced = this.npm.config.get('force') - const isDev = this.npm.config.get('dev') const scriptShell = this.npm.config.get('script-shell') || undefined // be very strict about engines when trying to update npm itself @@ -137,17 +129,14 @@ class Install extends ArboristWorkspaceCmd { args = ['.'] } - // TODO: Add warnings for other deprecated flags? or remove this one? - if (isDev) { - log.warn( - 'install', - 'Usage of the `--dev` option is deprecated. Use `--include=dev` instead.' - ) + // throw usage error if trying to install empty package + // name to global space, e.g: `npm i -g ""` + if (where === globalTop && !args.every(Boolean)) { + throw this.usageError() } const opts = { ...this.npm.flatOptions, - log, auditLevel: null, path: where, add: args, @@ -161,7 +150,7 @@ class Install extends ArboristWorkspaceCmd { 'preinstall', 'install', 'postinstall', - 'prepublish', // XXX should we remove this finally?? + 'prepublish', // XXX(npm9) should we remove this finally?? 'preprepare', 'prepare', 'postprepare', @@ -172,8 +161,7 @@ class Install extends ArboristWorkspaceCmd { args: [], scriptShell, stdio: 'inherit', - stdioString: true, - banner: log.level !== 'silent', + banner: !this.npm.silent, event, }) } diff --git a/lib/commands/link.js b/lib/commands/link.js index e8e2c6b..5af2c7c 100644 --- a/lib/commands/link.js +++ b/lib/commands/link.js @@ -7,7 +7,6 @@ const Arborist = require('@npmcli/arborist') const npa = require('npm-package-arg') const rpj = require('read-package-json-fast') const semver = require('semver') -const log = require('../utils/log-shim.js') const reifyFinish = require('../utils/reify-finish.js') @@ -16,16 +15,16 @@ class Link extends ArboristWorkspaceCmd { static description = 'Symlink a package folder' static name = 'link' static usage = [ - '(in package dir)', - '[<@scope>/]<pkg>[@<version>]', + '[<package-spec>]', ] static params = [ 'save', 'save-exact', 'global', - 'global-style', + 'install-strategy', 'legacy-bundling', + 'global-style', 'strict-peer-deps', 'package-lock', 'omit', @@ -44,7 +43,7 @@ class Link extends ArboristWorkspaceCmd { } async exec (args) { - if (this.npm.config.get('global')) { + if (this.npm.global) { throw Object.assign( new Error( 'link should never be --global.\n' + @@ -53,6 +52,8 @@ class Link extends ArboristWorkspaceCmd { { code: 'ELINKGLOBAL' } ) } + // install-links is implicitely false when running `npm link` + this.npm.config.set('install-links', false) // link with no args: symlink the folder to the global location // link with package arg: symlink the global to the local @@ -69,7 +70,6 @@ class Link extends ArboristWorkspaceCmd { const globalOpts = { ...this.npm.flatOptions, path: globalTop, - log, global: true, prune: false, } @@ -118,7 +118,6 @@ class Link extends ArboristWorkspaceCmd { const localArb = new Arborist({ ...this.npm.flatOptions, prune: false, - log, path: this.npm.prefix, save, }) @@ -126,8 +125,7 @@ class Link extends ArboristWorkspaceCmd { ...this.npm.flatOptions, prune: false, path: this.npm.prefix, - log, - add: names.map(l => `file:${resolve(globalTop, 'node_modules', l)}`), + add: names.map(l => `file:${resolve(globalTop, 'node_modules', l).replace(/#/g, '%23')}`), save, workspaces: this.workspaceNames, }) @@ -138,17 +136,15 @@ class Link extends ArboristWorkspaceCmd { async linkPkg () { const wsp = this.workspacePaths const paths = wsp && wsp.length ? wsp : [this.npm.prefix] - const add = paths.map(path => `file:${path}`) + const add = paths.map(path => `file:${path.replace(/#/g, '%23')}`) const globalTop = resolve(this.npm.globalDir, '..') const arb = new Arborist({ ...this.npm.flatOptions, path: globalTop, - log, global: true, }) await arb.reify({ add, - log, }) await reifyFinish(this.npm, arb) } diff --git a/lib/commands/login.js b/lib/commands/login.js new file mode 100644 index 0000000..7f6898d --- /dev/null +++ b/lib/commands/login.js @@ -0,0 +1,53 @@ +const log = require('../utils/log-shim.js') +const replaceInfo = require('../utils/replace-info.js') +const auth = require('../utils/auth.js') + +const BaseCommand = require('../base-command.js') + +class Login extends BaseCommand { + static description = 'Login to a registry user account' + static name = 'login' + static params = [ + 'registry', + 'scope', + 'auth-type', + ] + + static ignoreImplicitWorkspace = true + + async exec (args) { + const scope = this.npm.config.get('scope') + let registry = this.npm.config.get('registry') + + if (scope) { + const scopedRegistry = this.npm.config.get(`${scope}:registry`) + const cliRegistry = this.npm.config.get('registry', 'cli') + if (scopedRegistry && !cliRegistry) { + registry = scopedRegistry + } + } + + const creds = this.npm.config.getCredentialsByURI(registry) + + log.disableProgress() + log.notice('', `Log in on ${replaceInfo(registry)}`) + + const { message, newCreds } = await auth.login(this.npm, { + ...this.npm.flatOptions, + creds, + registry, + }) + + this.npm.config.delete('_token', 'user') // prevent legacy pollution + this.npm.config.setCredentialsByURI(registry, newCreds) + + if (scope) { + this.npm.config.set(scope + ':registry', registry, 'user') + } + + await this.npm.config.save('user') + + this.npm.output(message) + } +} +module.exports = Login diff --git a/lib/commands/logout.js b/lib/commands/logout.js index 34fbace..7c2a7f0 100644 --- a/lib/commands/logout.js +++ b/lib/commands/logout.js @@ -11,6 +11,8 @@ class Logout extends BaseCommand { 'scope', ] + static ignoreImplicitWorkspace = true + async exec (args) { const registry = this.npm.config.get('registry') const scope = this.npm.config.get('scope') @@ -25,7 +27,6 @@ class Logout extends BaseCommand { ...this.npm.flatOptions, method: 'DELETE', ignoreBody: true, - log, }) } else if (auth.isBasicAuth) { log.verbose('logout', `clearing user credentials for ${reg}`) diff --git a/lib/commands/ls.js b/lib/commands/ls.js index 8c338c0..7eebdf6 100644 --- a/lib/commands/ls.js +++ b/lib/commands/ls.js @@ -27,7 +27,7 @@ const localeCompare = require('@isaacs/string-locale-compare')('en') class LS extends ArboristWorkspaceCmd { static description = 'List installed packages' static name = 'ls' - static usage = ['[[<@scope>/]<pkg> ...]'] + static usage = ['<package-spec>'] static params = [ 'all', 'json', @@ -52,16 +52,12 @@ class LS extends ArboristWorkspaceCmd { const all = this.npm.config.get('all') const color = this.npm.color const depth = this.npm.config.get('depth') - const dev = this.npm.config.get('dev') - const development = this.npm.config.get('development') - const global = this.npm.config.get('global') + const global = this.npm.global const json = this.npm.config.get('json') const link = this.npm.config.get('link') const long = this.npm.config.get('long') - const only = this.npm.config.get('only') + const omit = this.npm.flatOptions.omit const parseable = this.npm.config.get('parseable') - const prod = this.npm.config.get('prod') - const production = this.npm.config.get('production') const unicode = this.npm.config.get('unicode') const packageLockOnly = this.npm.config.get('package-lock-only') const workspacesEnabled = this.npm.flatOptions.workspacesEnabled @@ -95,10 +91,15 @@ class LS extends ArboristWorkspaceCmd { return true } + if (this.npm.flatOptions.includeWorkspaceRoot + && edge.to && !edge.to.isWorkspace) { + return true + } + if (edge.from.isProjectRoot) { - return edge.to && - edge.to.isWorkspace && - wsNodes.includes(edge.to.target) + return (edge.to + && edge.to.isWorkspace + && wsNodes.includes(edge.to.target)) } return true @@ -133,15 +134,10 @@ class LS extends ArboristWorkspaceCmd { ? [] : [...(node.target).edgesOut.values()] .filter(filterBySelectedWorkspaces) - .filter(filterByEdgesTypes({ - currentDepth, - dev, - development, + .filter(currentDepth === 0 ? filterByEdgesTypes({ link, - prod, - production, - only, - })) + omit, + }) : () => true) .map(mapEdgesToNodes({ seenPaths })) .concat(appendExtraneousChildren({ node, seenPaths })) .sort(sortAlphabetically) @@ -181,7 +177,7 @@ class LS extends ArboristWorkspaceCmd { const [rootError] = tree.errors.filter(e => e.code === 'EJSONPARSE' && e.path === resolve(path, 'package.json')) - this.npm.output( + this.npm.outputBuffer( json ? jsonOutput({ path, problems, result, rootError, seenItems }) : parseable @@ -333,6 +329,11 @@ const getHumanOutputItem = (node, { args, color, global, long }) => { ? ' ' + (color ? chalk.green.bgBlack('extraneous') : 'extraneous') : '' ) + + ( + node.overridden + ? ' ' + (color ? chalk.gray('overridden') : 'overridden') + : '' + ) + (isGitNode(node) ? ` (${node.resolved})` : '') + (node.isLink ? ` -> ${relativePrefix}${targetLocation}` : '') + (long ? `${EOL}${node.package.description || ''}` : '') @@ -351,6 +352,13 @@ const getJsonOutputItem = (node, { global, long }) => { item.resolved = node.resolved } + // if the node is the project root, do not add the overridden flag. the project root can't be + // overridden anyway, and if we add the flag it causes undesirable behavior when `npm ls --json` + // is ran in an empty directory since we end up printing an object with only an overridden prop + if (!node.isProjectRoot) { + item.overridden = node.overridden + } + item[_name] = node.name // special formatting for top-level package name @@ -394,27 +402,13 @@ const getJsonOutputItem = (node, { global, long }) => { return augmentItemWithIncludeMetadata(node, item) } -const filterByEdgesTypes = ({ - currentDepth, - dev, - development, - link, - prod, - production, - only, -}) => { - // filter deps by type, allows for: `npm ls --dev`, `npm ls --prod`, - // `npm ls --link`, `npm ls --only=dev`, etc - const filterDev = currentDepth === 0 && - (dev || development || /^dev(elopment)?$/.test(only)) - const filterProd = currentDepth === 0 && - (prod || production || /^prod(uction)?$/.test(only)) - const filterLink = currentDepth === 0 && link - - return (edge) => - (filterDev ? edge.dev : true) && - (filterProd ? (!edge.dev && !edge.peer && !edge.peerOptional) : true) && - (filterLink ? (edge.to && edge.to.isLink) : true) +const filterByEdgesTypes = ({ link, omit = [] }) => (edge) => { + for (const omitType of omit) { + if (edge[omitType]) { + return false + } + } + return link ? edge.to && edge.to.isLink : true } const appendExtraneousChildren = ({ node, seenPaths }) => @@ -573,6 +567,7 @@ const parseableOutput = ({ global, long, seenNodes }) => { out += node.path !== node.realpath ? `:${node.realpath}` : '' out += isExtraneous(node, { global }) ? ':EXTRANEOUS' : '' out += node[_invalid] ? ':INVALID' : '' + out += node.overridden ? ':OVERRIDDEN' : '' } out += EOL } diff --git a/lib/commands/org.js b/lib/commands/org.js index 8985920..f49556c 100644 --- a/lib/commands/org.js +++ b/lib/commands/org.js @@ -2,7 +2,6 @@ const liborg = require('libnpmorg') const otplease = require('../utils/otplease.js') const Table = require('cli-table3') const BaseCommand = require('../base-command.js') -const log = require('../utils/log-shim.js') class Org extends BaseCommand { static description = 'Manage orgs' @@ -14,6 +13,7 @@ class Org extends BaseCommand { ] static params = ['registry', 'otp', 'json', 'parseable'] + static ignoreImplicitWorkspace = true async completion (opts) { const argv = opts.conf.argv.remain @@ -33,9 +33,8 @@ class Org extends BaseCommand { } async exec ([cmd, orgname, username, role], cb) { - return otplease({ + return otplease(this.npm, { ...this.npm.flatOptions, - log, }, opts => { switch (cmd) { case 'add': @@ -51,7 +50,7 @@ class Org extends BaseCommand { }) } - set (org, user, role, opts) { + async set (org, user, role, opts) { role = role || 'developer' if (!org) { throw new Error('First argument `orgname` is required.') @@ -68,27 +67,26 @@ class Org extends BaseCommand { ) } - return liborg.set(org, user, role, opts).then(memDeets => { - if (opts.json) { - this.npm.output(JSON.stringify(memDeets, null, 2)) - } else if (opts.parseable) { - this.npm.output(['org', 'orgsize', 'user', 'role'].join('\t')) - this.npm.output( - [memDeets.org.name, memDeets.org.size, memDeets.user, memDeets.role].join('\t') - ) - } else if (!opts.silent && opts.loglevel !== 'silent') { - this.npm.output( - `Added ${memDeets.user} as ${memDeets.role} to ${memDeets.org.name}. You now have ${ + const memDeets = await liborg.set(org, user, role, opts) + if (opts.json) { + this.npm.output(JSON.stringify(memDeets, null, 2)) + } else if (opts.parseable) { + this.npm.output(['org', 'orgsize', 'user', 'role'].join('\t')) + this.npm.output( + [memDeets.org.name, memDeets.org.size, memDeets.user, memDeets.role].join('\t') + ) + } else if (!this.npm.silent) { + this.npm.output( + `Added ${memDeets.user} as ${memDeets.role} to ${memDeets.org.name}. You now have ${ memDeets.org.size } member${memDeets.org.size === 1 ? '' : 's'} in this org.` - ) - } + ) + } - return memDeets - }) + return memDeets } - rm (org, user, opts) { + async rm (org, user, opts) { if (!org) { throw new Error('First argument `orgname` is required.') } @@ -97,68 +95,62 @@ class Org extends BaseCommand { throw new Error('Second argument `username` is required.') } - return liborg - .rm(org, user, opts) - .then(() => { - return liborg.ls(org, opts) - }) - .then(roster => { - user = user.replace(/^[~@]?/, '') - org = org.replace(/^[~@]?/, '') - const userCount = Object.keys(roster).length - if (opts.json) { - this.npm.output( - JSON.stringify({ - user, - org, - userCount, - deleted: true, - }) - ) - } else if (opts.parseable) { - this.npm.output(['user', 'org', 'userCount', 'deleted'].join('\t')) - this.npm.output([user, org, userCount, true].join('\t')) - } else if (!opts.silent && opts.loglevel !== 'silent') { - this.npm.output( - `Successfully removed ${user} from ${org}. You now have ${userCount} member${ - userCount === 1 ? '' : 's' - } in this org.` - ) - } - }) + await liborg.rm(org, user, opts) + const roster = await liborg.ls(org, opts) + user = user.replace(/^[~@]?/, '') + org = org.replace(/^[~@]?/, '') + const userCount = Object.keys(roster).length + if (opts.json) { + this.npm.output( + JSON.stringify({ + user, + org, + userCount, + deleted: true, + }) + ) + } else if (opts.parseable) { + this.npm.output(['user', 'org', 'userCount', 'deleted'].join('\t')) + this.npm.output([user, org, userCount, true].join('\t')) + } else if (!this.npm.silent) { + this.npm.output( + `Successfully removed ${user} from ${org}. You now have ${userCount} member${ + userCount === 1 ? '' : 's' + } in this org.` + ) + } } - ls (org, user, opts) { + async ls (org, user, opts) { if (!org) { throw new Error('First argument `orgname` is required.') } - return liborg.ls(org, opts).then(roster => { - if (user) { - const newRoster = {} - if (roster[user]) { - newRoster[user] = roster[user] - } + let roster = await liborg.ls(org, opts) + if (user) { + const newRoster = {} + if (roster[user]) { + newRoster[user] = roster[user] + } - roster = newRoster - } - if (opts.json) { - this.npm.output(JSON.stringify(roster, null, 2)) - } else if (opts.parseable) { - this.npm.output(['user', 'role'].join('\t')) - Object.keys(roster).forEach(user => { - this.npm.output([user, roster[user]].join('\t')) + roster = newRoster + } + if (opts.json) { + this.npm.output(JSON.stringify(roster, null, 2)) + } else if (opts.parseable) { + this.npm.output(['user', 'role'].join('\t')) + Object.keys(roster).forEach(user => { + this.npm.output([user, roster[user]].join('\t')) + }) + } else if (!this.npm.silent) { + const table = new Table({ head: ['user', 'role'] }) + Object.keys(roster) + .sort() + .forEach(user => { + table.push([user, roster[user]]) }) - } else if (!opts.silent && opts.loglevel !== 'silent') { - const table = new Table({ head: ['user', 'role'] }) - Object.keys(roster) - .sort() - .forEach(user => { - table.push([user, roster[user]]) - }) - this.npm.output(table.toString()) - } - }) + this.npm.output(table.toString()) + } } } module.exports = Org diff --git a/lib/commands/outdated.js b/lib/commands/outdated.js index 0cb5b42..9e20606 100644 --- a/lib/commands/outdated.js +++ b/lib/commands/outdated.js @@ -2,8 +2,7 @@ const os = require('os') const path = require('path') const pacote = require('pacote') const table = require('text-table') -const color = require('chalk') -const styles = require('ansistyles') +const chalk = require('chalk') const npa = require('npm-package-arg') const pickManifest = require('npm-pick-manifest') const localeCompare = require('@isaacs/string-locale-compare')('en') @@ -16,7 +15,7 @@ const ArboristWorkspaceCmd = require('../arborist-cmd.js') class Outdated extends ArboristWorkspaceCmd { static description = 'Check for outdated packages' static name = 'outdated' - static usage = ['[[<@scope>/]<pkg> ...]'] + static usage = ['[<package-spec> ...]'] static params = [ 'all', 'json', @@ -28,7 +27,7 @@ class Outdated extends ArboristWorkspaceCmd { async exec (args) { const global = path.resolve(this.npm.globalDir, '..') - const where = this.npm.config.get('global') + const where = this.npm.global ? global : this.npm.prefix @@ -106,7 +105,7 @@ class Outdated extends ArboristWorkspaceCmd { const outTable = [outHead].concat(outList) if (this.npm.color) { - outTable[0] = outTable[0].map(heading => styles.underline(heading)) + outTable[0] = outTable[0].map(heading => chalk.underline(heading)) } const tableOpts = { @@ -141,7 +140,7 @@ class Outdated extends ArboristWorkspaceCmd { getEdgesOut (node) { // TODO: normalize usage of edges and avoid looping through nodes here - if (this.npm.config.get('global')) { + if (this.npm.global) { for (const child of node.children.values()) { this.trackEdge(child) } @@ -167,7 +166,7 @@ class Outdated extends ArboristWorkspaceCmd { } getWorkspacesEdges (node) { - if (this.npm.config.get('global')) { + if (this.npm.global) { return } @@ -197,6 +196,7 @@ class Outdated extends ArboristWorkspaceCmd { try { alias = npa(edge.spec).subSpec } catch (err) { + // ignore errors, no alias } const spec = npa(alias ? alias.name : edge.name) const node = edge.to || edge @@ -208,7 +208,7 @@ class Outdated extends ArboristWorkspaceCmd { : edge.dev ? 'devDependencies' : 'dependencies' - for (const omitType of this.npm.config.get('omit')) { + for (const omitType of this.npm.flatOptions.omit) { if (node[omitType]) { return } @@ -282,7 +282,7 @@ class Outdated extends ArboristWorkspaceCmd { : node.name return this.npm.color && humanOutput - ? color.green(workspaceName) + ? chalk.green(workspaceName) : workspaceName } @@ -307,9 +307,9 @@ class Outdated extends ArboristWorkspaceCmd { } if (this.npm.color) { - columns[0] = color[current === wanted ? 'yellow' : 'red'](columns[0]) // current - columns[2] = color.green(columns[2]) // wanted - columns[3] = color.magenta(columns[3]) // latest + columns[0] = chalk[current === wanted ? 'yellow' : 'red'](columns[0]) // current + columns[2] = chalk.green(columns[2]) // wanted + columns[3] = chalk.magenta(columns[3]) // latest } return columns diff --git a/lib/commands/owner.js b/lib/commands/owner.js index 7b76b7b..824b64e 100644 --- a/lib/commands/owner.js +++ b/lib/commands/owner.js @@ -3,8 +3,18 @@ const npmFetch = require('npm-registry-fetch') const pacote = require('pacote') const log = require('../utils/log-shim') const otplease = require('../utils/otplease.js') -const readLocalPkgName = require('../utils/read-package-name.js') +const readPackageJsonFast = require('read-package-json-fast') const BaseCommand = require('../base-command.js') +const { resolve } = require('path') + +const readJson = async (pkg) => { + try { + const json = await readPackageJsonFast(pkg) + return json + } catch { + return {} + } +} class Owner extends BaseCommand { static description = 'Manage package owners' @@ -12,14 +22,18 @@ class Owner extends BaseCommand { static params = [ 'registry', 'otp', + 'workspace', + 'workspaces', ] static usage = [ - 'add <user> [<@scope>/]<pkg>', - 'rm <user> [<@scope>/]<pkg>', - 'ls [<@scope>/]<pkg>', + 'add <user> <package-spec>', + 'rm <user> <package-spec>', + 'ls <package-spec>', ] + static ignoreImplicitWorkspace = false + async completion (opts) { const argv = opts.conf.argv.remain if (argv.length > 3) { @@ -36,15 +50,15 @@ class Owner extends BaseCommand { // reaches registry in order to autocomplete rm if (argv[2] === 'rm') { - if (this.npm.config.get('global')) { + if (this.npm.global) { return [] } - const pkgName = await readLocalPkgName(this.npm.prefix) - if (!pkgName) { + const { name } = await readJson(resolve(this.npm.prefix, 'package.json')) + if (!name) { return [] } - const spec = npa(pkgName) + const spec = npa(name) const data = await pacote.packument(spec, { ...this.npm.flatOptions, fullMetadata: true, @@ -57,206 +71,162 @@ class Owner extends BaseCommand { } async exec ([action, ...args]) { - const opts = { - ...this.npm.flatOptions, - log, - } - switch (action) { - case 'ls': - case 'list': - return this.ls(args[0], opts) - case 'add': - return this.add(args[0], args[1], opts) - case 'rm': - case 'remove': - return this.rm(args[0], args[1], opts) - default: - throw this.usageError() + if (action === 'ls' || action === 'list') { + await this.ls(args[0]) + } else if (action === 'add') { + await this.changeOwners(args[0], args[1], 'add') + } else if (action === 'rm' || action === 'remove') { + await this.changeOwners(args[0], args[1], 'rm') + } else { + throw this.usageError() } } - async ls (pkg, opts) { - if (!pkg) { - if (this.npm.config.get('global')) { - throw this.usageError() + async execWorkspaces ([action, ...args], filters) { + await this.setWorkspaces(filters) + // ls pkg or owner add/rm package + if ((action === 'ls' && args.length > 0) || args.length > 1) { + const implicitWorkspaces = this.npm.config.get('workspace', 'default') + if (implicitWorkspaces.length === 0) { + log.warn(`Ignoring specified workspace(s)`) } - - const pkgName = await readLocalPkgName(this.npm.prefix) - if (!pkgName) { - throw this.usageError() - } - - pkg = pkgName + return this.exec([action, ...args]) } + for (const [name] of this.workspaces) { + if (action === 'ls' || action === 'list') { + await this.ls(name) + } else if (action === 'add') { + await this.changeOwners(args[0], name, 'add') + } else if (action === 'rm' || action === 'remove') { + await this.changeOwners(args[0], name, 'rm') + } else { + throw this.usageError() + } + } + } + + async ls (pkg) { + pkg = await this.getPkg(this.npm.prefix, pkg) const spec = npa(pkg) try { - const packumentOpts = { ...opts, fullMetadata: true } + const packumentOpts = { ...this.npm.flatOptions, fullMetadata: true, preferOnline: true } const { maintainers } = await pacote.packument(spec, packumentOpts) if (!maintainers || !maintainers.length) { this.npm.output('no admin found') } else { - this.npm.output(maintainers.map(o => `${o.name} <${o.email}>`).join('\n')) + this.npm.output(maintainers.map(m => `${m.name} <${m.email}>`).join('\n')) } - - return maintainers } catch (err) { log.error('owner ls', "Couldn't get owner data", pkg) throw err } } - async add (user, pkg, opts) { + async getPkg (prefix, pkg) { + if (!pkg) { + if (this.npm.global) { + throw this.usageError() + } + const { name } = await readJson(resolve(prefix, 'package.json')) + if (!name) { + throw this.usageError() + } + + return name + } + return pkg + } + + async changeOwners (user, pkg, addOrRm) { if (!user) { throw this.usageError() } - if (!pkg) { - if (this.npm.config.get('global')) { - throw this.usageError() - } - const pkgName = await readLocalPkgName(this.npm.prefix) - if (!pkgName) { - throw this.usageError() - } - - pkg = pkgName - } - log.verbose('owner add', '%s to %s', user, pkg) + pkg = await this.getPkg(this.npm.prefix, pkg) + log.verbose(`owner ${addOrRm}`, '%s to %s', user, pkg) const spec = npa(pkg) - return this.putOwners(spec, user, opts, - (newOwner, owners) => this.validateAddOwner(newOwner, owners)) - } - - async rm (user, pkg, opts) { - if (!user) { - throw this.usageError() - } - - if (!pkg) { - if (this.npm.config.get('global')) { - throw this.usageError() - } - const pkgName = await readLocalPkgName(this.npm.prefix) - if (!pkgName) { - throw this.usageError() - } - - pkg = pkgName - } - log.verbose('owner rm', '%s from %s', user, pkg) - - const spec = npa(pkg) - return this.putOwners(spec, user, opts, - (rmOwner, owners) => this.validateRmOwner(rmOwner, owners)) - } - - async putOwners (spec, user, opts, validation) { const uri = `/-/user/org.couchdb.user:${encodeURIComponent(user)}` - let u = '' + let u try { - u = await npmFetch.json(uri, opts) + u = await npmFetch.json(uri, this.npm.flatOptions) } catch (err) { log.error('owner mutate', `Error getting user data for ${user}`) throw err } - if (user && (!u || !u.name || u.error)) { - throw Object.assign( - new Error( - "Couldn't get user data for " + user + ': ' + JSON.stringify(u) - ), - { code: 'EOWNERUSER' } - ) - } - // normalize user data u = { name: u.name, email: u.email } - const data = await pacote.packument(spec, { ...opts, fullMetadata: true }) - - // save the number of maintainers before validation for comparison - const before = data.maintainers ? data.maintainers.length : 0 - - const m = validation(u, data.maintainers) - if (!m) { - return - } // invalid owners - - const body = { - _id: data._id, - _rev: data._rev, - maintainers: m, - } - const dataPath = `/${spec.escapedName}/-rev/${encodeURIComponent(data._rev)}` - const res = await otplease(opts, opts => { - return npmFetch.json(dataPath, { - ...opts, - method: 'PUT', - body, - spec, - log, - }) + const data = await pacote.packument(spec, { + ...this.npm.flatOptions, + fullMetadata: true, + preferOnline: true, }) - if (!res.error) { - if (m.length < before) { - this.npm.output(`- ${user} (${spec.name})`) - } else { - this.npm.output(`+ ${user} (${spec.name})`) + const owners = data.maintainers || [] + let maintainers + if (addOrRm === 'add') { + const existing = owners.find(o => o.name === u.name) + if (existing) { + log.info( + 'owner add', + `Already a package owner: ${existing.name} <${existing.email}>` + ) + return } + maintainers = [ + ...owners, + u, + ] } else { + maintainers = owners.filter(o => o.name !== u.name) + + if (maintainers.length === owners.length) { + log.info('owner rm', 'Not a package owner: ' + u.name) + return false + } + + if (!maintainers.length) { + throw Object.assign( + new Error( + 'Cannot remove all owners of a package. Add someone else first.' + ), + { code: 'EOWNERRM' } + ) + } + } + + const dataPath = `/${spec.escapedName}/-rev/${encodeURIComponent(data._rev)}` + try { + const res = await otplease(this.npm, this.npm.flatOptions, opts => { + return npmFetch.json(dataPath, { + ...opts, + method: 'PUT', + body: { + _id: data._id, + _rev: data._rev, + maintainers, + }, + spec, + }) + }) + if (addOrRm === 'add') { + this.npm.output(`+ ${user} (${spec.name})`) + } else { + this.npm.output(`- ${user} (${spec.name})`) + } + return res + } catch (err) { throw Object.assign( - new Error('Failed to update package: ' + JSON.stringify(res)), + new Error('Failed to update package: ' + JSON.stringify(err.message)), { code: 'EOWNERMUTATE' } ) } - return res - } - - validateAddOwner (newOwner, owners) { - owners = owners || [] - for (const o of owners) { - if (o.name === newOwner.name) { - log.info( - 'owner add', - 'Already a package owner: ' + o.name + ' <' + o.email + '>' - ) - return false - } - } - return [ - ...owners, - newOwner, - ] - } - - validateRmOwner (rmOwner, owners) { - let found = false - const m = owners.filter(function (o) { - var match = (o.name === rmOwner.name) - found = found || match - return !match - }) - - if (!found) { - log.info('owner rm', 'Not a package owner: ' + rmOwner.name) - return false - } - - if (!m.length) { - throw Object.assign( - new Error( - 'Cannot remove all owners of a package. Add someone else first.' - ), - { code: 'EOWNERRM' } - ) - } - - return m } } + module.exports = Owner diff --git a/lib/commands/pack.js b/lib/commands/pack.js index 74c2969..c6a7480 100644 --- a/lib/commands/pack.js +++ b/lib/commands/pack.js @@ -17,7 +17,8 @@ class Pack extends BaseCommand { 'include-workspace-root', ] - static usage = ['[[<@scope>/]<pkg>...]'] + static usage = ['<package-spec>'] + static ignoreImplicitWorkspace = false async exec (args) { if (args.length === 0) { @@ -43,7 +44,11 @@ class Pack extends BaseCommand { // noise generated during packing const tarballs = [] for (const { arg, manifest } of manifests) { - const tarballData = await libpack(arg, this.npm.flatOptions) + const tarballData = await libpack(arg, { + ...this.npm.flatOptions, + prefix: this.npm.localPrefix, + workspaces: this.workspacePaths, + }) const pkgContents = await getContents(manifest, tarballData) tarballs.push(pkgContents) } diff --git a/lib/commands/ping.js b/lib/commands/ping.js index 27089be..2203921 100644 --- a/lib/commands/ping.js +++ b/lib/commands/ping.js @@ -6,11 +6,12 @@ class Ping extends BaseCommand { static description = 'Ping npm registry' static params = ['registry'] static name = 'ping' + static ignoreImplicitWorkspace = true async exec (args) { log.notice('PING', this.npm.config.get('registry')) const start = Date.now() - const details = await pingUtil({ ...this.npm.flatOptions, log }) + const details = await pingUtil({ ...this.npm.flatOptions }) const time = Date.now() - start log.notice('PONG', `${time}ms`) if (this.npm.config.get('json')) { diff --git a/lib/commands/pkg.js b/lib/commands/pkg.js index 6ca8922..5fac9bf 100644 --- a/lib/commands/pkg.js +++ b/lib/commands/pkg.js @@ -20,6 +20,8 @@ class Pkg extends BaseCommand { 'workspaces', ] + static ignoreImplicitWorkspace = false + async exec (args, { prefix } = {}) { if (!prefix) { this.prefix = this.npm.localPrefix @@ -27,7 +29,7 @@ class Pkg extends BaseCommand { this.prefix = prefix } - if (this.npm.config.get('global')) { + if (this.npm.global) { throw Object.assign( new Error(`There's no package.json file to manage on global mode`), { code: 'EPKGGLOBAL' } diff --git a/lib/commands/prefix.js b/lib/commands/prefix.js index 264b819..dd0e34c 100644 --- a/lib/commands/prefix.js +++ b/lib/commands/prefix.js @@ -5,6 +5,7 @@ class Prefix extends BaseCommand { static name = 'prefix' static params = ['global'] static usage = ['[-g]'] + static ignoreImplicitWorkspace = true async exec (args) { return this.npm.output(this.npm.prefix) diff --git a/lib/commands/profile.js b/lib/commands/profile.js index 9786e9b..27060cf 100644 --- a/lib/commands/profile.js +++ b/lib/commands/profile.js @@ -1,6 +1,6 @@ const inspect = require('util').inspect const { URL } = require('url') -const ansistyles = require('ansistyles') +const chalk = require('chalk') const log = require('../utils/log-shim.js') const npmProfile = require('npm-profile') const qrcodeTerminal = require('qrcode-terminal') @@ -54,6 +54,8 @@ class Profile extends BaseCommand { 'otp', ] + static ignoreImplicitWorkspace = true + async completion (opts) { var argv = opts.conf.argv.remain @@ -108,7 +110,7 @@ class Profile extends BaseCommand { async get (args) { const tfa = 'two-factor auth' const info = await pulseTillDone.withPromise( - npmProfile.get({ ...this.npm.flatOptions, log }) + npmProfile.get({ ...this.npm.flatOptions }) ) if (!info.cidr_whitelist) { @@ -161,7 +163,7 @@ class Profile extends BaseCommand { } else { const table = new Table() for (const key of Object.keys(cleaned)) { - table.push({ [ansistyles.bright(key)]: cleaned[key] }) + table.push({ [chalk.bold(key)]: cleaned[key] }) } this.npm.output(table.toString()) @@ -170,7 +172,7 @@ class Profile extends BaseCommand { } async set (args) { - const conf = { ...this.npm.flatOptions, log } + const conf = { ...this.npm.flatOptions } const prop = (args[0] || '').toLowerCase().trim() let value = args.length > 1 ? args.slice(1).join(' ') : null @@ -219,7 +221,7 @@ class Profile extends BaseCommand { newUser[prop] = value - const result = await otplease(conf, conf => npmProfile.set(newUser, conf)) + const result = await otplease(this.npm, conf, conf => npmProfile.set(newUser, conf)) if (this.npm.config.get('json')) { this.npm.output(JSON.stringify({ [prop]: result[prop] }, null, 2)) @@ -285,7 +287,7 @@ class Profile extends BaseCommand { if (auth.basic) { log.info('profile', 'Updating authentication to bearer token') const result = await npmProfile.createToken( - auth.basic.password, false, [], { ...this.npm.flatOptions, log } + auth.basic.password, false, [], { ...this.npm.flatOptions } ) if (!result.token) { @@ -309,7 +311,7 @@ class Profile extends BaseCommand { log.info('profile', 'Determine if tfa is pending') const userInfo = await pulseTillDone.withPromise( - npmProfile.get({ ...this.npm.flatOptions, log }) + npmProfile.get({ ...this.npm.flatOptions }) ) const conf = { ...this.npm.flatOptions } diff --git a/lib/commands/prune.js b/lib/commands/prune.js index 5831df6..ee2c305 100644 --- a/lib/commands/prune.js +++ b/lib/commands/prune.js @@ -1,13 +1,20 @@ // prune extraneous packages const Arborist = require('@npmcli/arborist') -const log = require('../utils/log-shim.js') const reifyFinish = require('../utils/reify-finish.js') const ArboristWorkspaceCmd = require('../arborist-cmd.js') class Prune extends ArboristWorkspaceCmd { static description = 'Remove extraneous packages' static name = 'prune' - static params = ['omit', 'dry-run', 'json', ...super.params] + static params = [ + 'omit', + 'dry-run', + 'json', + 'foreground-scripts', + 'ignore-scripts', + ...super.params, + ] + static usage = ['[[<@scope>/]<pkg>...]'] async exec () { @@ -15,7 +22,6 @@ class Prune extends ArboristWorkspaceCmd { const opts = { ...this.npm.flatOptions, path: where, - log, workspaces: this.workspaceNames, } const arb = new Arborist(opts) diff --git a/lib/commands/publish.js b/lib/commands/publish.js index 63106c5..23323a1 100644 --- a/lib/commands/publish.js +++ b/lib/commands/publish.js @@ -7,7 +7,6 @@ const runScript = require('@npmcli/run-script') const pacote = require('pacote') const npa = require('npm-package-arg') const npmFetch = require('npm-registry-fetch') -const chalk = require('chalk') const replaceInfo = require('../utils/replace-info.js') const otplease = require('../utils/otplease.js') @@ -17,7 +16,7 @@ const { getContents, logTar } = require('../utils/tar.js') // keys that npm supports in .npmrc files and elsewhere. We *may* want to // revisit this at some point, and have a minimal set that's a SemVer-major // change that ought to get a RFC written on it. -const flatten = require('../utils/config/flatten.js') +const { flatten } = require('../utils/config/index.js') // this is the only case in the CLI where we want to use the old full slow // 'read-package-json' module, because we want to pull in all the defaults and @@ -38,7 +37,8 @@ class Publish extends BaseCommand { 'include-workspace-root', ] - static usage = ['[<folder>]'] + static usage = ['<package-spec>'] + static ignoreImplicitWorkspace = false async exec (args) { if (args.length === 0) { @@ -55,23 +55,20 @@ class Publish extends BaseCommand { const json = this.npm.config.get('json') const defaultTag = this.npm.config.get('tag') const ignoreScripts = this.npm.config.get('ignore-scripts') - const silent = log.level === 'silent' + const { silent } = this.npm if (semver.validRange(defaultTag)) { throw new Error('Tag name must not be a valid SemVer range: ' + defaultTag.trim()) } - const opts = { ...this.npm.flatOptions, log } + const opts = { ...this.npm.flatOptions, progress: false } + log.disableProgress() // you can publish name@version, ./foo.tgz, etc. // even though the default is the 'file:.' cwd. const spec = npa(args[0]) let manifest = await this.getManifest(spec, opts) - if (manifest.publishConfig) { - flatten(manifest.publishConfig, opts) - } - // only run scripts for directory type publishes if (spec.type === 'directory' && !ignoreScripts) { await runScript({ @@ -84,37 +81,49 @@ class Publish extends BaseCommand { } // we pass dryRun: true to libnpmpack so it doesn't write the file to disk - const tarballData = await pack(spec, { ...opts, dryRun: true }) + const tarballData = await pack(spec, { + ...opts, + dryRun: true, + prefix: this.npm.localPrefix, + workspaces: this.workspacePaths, + }) const pkgContents = await getContents(manifest, tarballData) // The purpose of re-reading the manifest is in case it changed, // so that we send the latest and greatest thing to the registry // note that publishConfig might have changed as well! manifest = await this.getManifest(spec, opts) - if (manifest.publishConfig) { - flatten(manifest.publishConfig, opts) - } - // note that logTar calls log.notice(), so if we ARE in silent mode, - // this will do nothing, but we still want it in the debuglog if it fails. + // JSON already has the package contents if (!json) { logTar(pkgContents, { unicode }) } - if (!dryRun) { - const resolved = npa.resolve(manifest.name, manifest.version) - const registry = npmFetch.pickRegistry(resolved, opts) - const creds = this.npm.config.getCredentialsByURI(registry) - const outputRegistry = replaceInfo(registry) - if (!creds.token && !creds.username) { - throw Object.assign( - new Error(`This command requires you to be logged in to ${outputRegistry}`), { - code: 'ENEEDAUTH', - } - ) + const resolved = npa.resolve(manifest.name, manifest.version) + const registry = npmFetch.pickRegistry(resolved, opts) + const creds = this.npm.config.getCredentialsByURI(registry) + const noCreds = !(creds.token || creds.username || creds.certfile && creds.keyfile) + const outputRegistry = replaceInfo(registry) + + if (noCreds) { + const msg = `This command requires you to be logged in to ${outputRegistry}` + if (dryRun) { + log.warn('', `${msg} (dry-run)`) + } else { + throw Object.assign(new Error(msg), { code: 'ENEEDAUTH' }) } - log.notice('', `Publishing to ${outputRegistry}`) - await otplease(opts, opts => libpub(manifest, tarballData, opts)) + } + + const access = opts.access === null ? 'default' : opts.access + let msg = `Publishing to ${outputRegistry} with tag ${defaultTag} and ${access} access` + if (dryRun) { + msg = `${msg} (dry-run)` + } + + log.notice('', msg) + + if (!dryRun) { + await otplease(this.npm, opts, opts => libpub(manifest, tarballData, opts)) } if (spec.type === 'directory' && !ignoreScripts) { @@ -152,9 +161,7 @@ class Publish extends BaseCommand { const results = {} const json = this.npm.config.get('json') - const silent = log.level === 'silent' - const noop = a => a - const color = this.npm.color ? chalk : { green: noop, bold: noop } + const { silent } = this.npm await this.setWorkspaces(filters) for (const [name, workspace] of this.workspaces.entries()) { @@ -166,9 +173,9 @@ class Publish extends BaseCommand { log.warn( 'publish', `Skipping workspace ${ - color.green(name) + this.npm.chalk.green(name) }, marked as ${ - color.bold('private') + this.npm.chalk.bold('private') }` ) continue @@ -191,11 +198,22 @@ class Publish extends BaseCommand { // if it's a directory, read it from the file system // otherwise, get the full metadata from whatever it is - getManifest (spec, opts) { + // XXX can't pacote read the manifest from a directory? + async getManifest (spec, opts) { + let manifest if (spec.type === 'directory') { - return readJson(`${spec.fetchSpec}/package.json`) + manifest = await readJson(`${spec.fetchSpec}/package.json`) + } else { + manifest = await pacote.manifest(spec, { + ...opts, + fullmetadata: true, + fullReadJson: true, + }) } - return pacote.manifest(spec, { ...opts, fullMetadata: true }) + if (manifest.publishConfig) { + flatten(manifest.publishConfig, opts) + } + return manifest } } module.exports = Publish diff --git a/lib/commands/query.js b/lib/commands/query.js new file mode 100644 index 0000000..5f05ab3 --- /dev/null +++ b/lib/commands/query.js @@ -0,0 +1,107 @@ +'use strict' + +const { resolve } = require('path') +const Arborist = require('@npmcli/arborist') +const BaseCommand = require('../base-command.js') + +class QuerySelectorItem { + constructor (node) { + // all enumerable properties from the target + Object.assign(this, node.target.package) + + // append extra info + this.pkgid = node.target.pkgid + this.location = node.target.location + this.path = node.target.path + this.realpath = node.target.realpath + this.resolved = node.target.resolved + this.from = [] + this.to = [] + this.dev = node.target.dev + this.inBundle = node.target.inBundle + this.deduped = this.from.length > 1 + this.overridden = node.overridden + this.queryContext = node.queryContext + for (const edge of node.target.edgesIn) { + this.from.push(edge.from.location) + } + for (const [, edge] of node.target.edgesOut) { + if (edge.to) { + this.to.push(edge.to.location) + } + } + } +} + +class Query extends BaseCommand { + #response = [] // response is the query response + #seen = new Set() // paths we've seen so we can keep response deduped + + static description = 'Retrieve a filtered list of packages' + static name = 'query' + static usage = ['<selector>'] + + static ignoreImplicitWorkspace = false + + static params = [ + 'global', + 'workspace', + 'workspaces', + 'include-workspace-root', + ] + + get parsedResponse () { + return JSON.stringify(this.#response, null, 2) + } + + async exec (args) { + // one dir up from wherever node_modules lives + const where = resolve(this.npm.dir, '..') + const opts = { + ...this.npm.flatOptions, + path: where, + forceActual: true, + } + const arb = new Arborist(opts) + const tree = await arb.loadActual(opts) + const items = await tree.querySelectorAll(args[0], this.npm.flatOptions) + this.buildResponse(items) + + this.npm.output(this.parsedResponse) + } + + async execWorkspaces (args, filters) { + await this.setWorkspaces(filters) + const opts = { + ...this.npm.flatOptions, + path: this.npm.prefix, + } + const arb = new Arborist(opts) + const tree = await arb.loadActual(opts) + for (const workspacePath of this.workspacePaths) { + let items + if (workspacePath === tree.root.path) { + // include-workspace-root + items = await tree.querySelectorAll(args[0]) + } else { + const [workspace] = await tree.querySelectorAll(`.workspace:path(${workspacePath})`) + items = await workspace.target.querySelectorAll(args[0], this.npm.flatOptions) + } + this.buildResponse(items) + } + this.npm.output(this.parsedResponse) + } + + // builds a normalized inventory + buildResponse (items) { + for (const node of items) { + if (!this.#seen.has(node.target.location)) { + const item = new QuerySelectorItem(node) + this.#response.push(item) + this.#seen.add(item.location) + } + } + } +} + +module.exports = Query diff --git a/lib/commands/rebuild.js b/lib/commands/rebuild.js index 471d60b..df79110 100644 --- a/lib/commands/rebuild.js +++ b/lib/commands/rebuild.js @@ -11,11 +11,12 @@ class Rebuild extends ArboristWorkspaceCmd { static params = [ 'global', 'bin-links', + 'foreground-scripts', 'ignore-scripts', ...super.params, ] - static usage = ['[[<@scope>/]<name>[@<version>] ...]'] + static usage = ['[<package-spec>] ...]'] // TODO /* istanbul ignore next */ @@ -25,7 +26,7 @@ class Rebuild extends ArboristWorkspaceCmd { async exec (args) { const globalTop = resolve(this.npm.globalDir, '..') - const where = this.npm.config.get('global') ? globalTop : this.npm.prefix + const where = this.npm.global ? globalTop : this.npm.prefix const arb = new Arborist({ ...this.npm.flatOptions, path: where, @@ -38,7 +39,7 @@ class Rebuild extends ArboristWorkspaceCmd { const tree = await arb.loadActual() const specs = args.map(arg => { const spec = npa(arg) - if (spec.type === 'tag' && spec.rawSpec === '') { + if (spec.rawSpec === '*') { return spec } diff --git a/lib/commands/repo.js b/lib/commands/repo.js index 8ac4178..b89b74c 100644 --- a/lib/commands/repo.js +++ b/lib/commands/repo.js @@ -1,39 +1,11 @@ -const pacote = require('pacote') const { URL } = require('url') -const log = require('../utils/log-shim') -const hostedFromMani = require('../utils/hosted-git-info-from-manifest.js') -const openUrl = require('../utils/open-url.js') -const BaseCommand = require('../base-command.js') -class Repo extends BaseCommand { +const PackageUrlCmd = require('../package-url-cmd.js') +class Repo extends PackageUrlCmd { static description = 'Open package repository page in the browser' static name = 'repo' - static params = ['browser', 'workspace', 'workspaces', 'include-workspace-root'] - static usage = ['[<pkgname> [<pkgname> ...]]'] - - async exec (args) { - if (!args || !args.length) { - args = ['.'] - } - - await Promise.all(args.map(pkg => this.get(pkg))) - } - - async execWorkspaces (args, filters) { - await this.setWorkspaces(filters) - return this.exec(this.workspacePaths) - } - - async get (pkg) { - // XXX It is very odd that `where` is how pacote knows to look anywhere - // other than the cwd. - const opts = { - ...this.npm.flatOptions, - where: this.npm.localPrefix, - fullMetadata: true, - } - const mani = await pacote.manifest(pkg, opts) + getUrl (spec, mani) { const r = mani.repository const rurl = !r ? null : typeof r === 'string' ? r @@ -42,22 +14,20 @@ class Repo extends BaseCommand { if (!rurl) { throw Object.assign(new Error('no repository'), { - pkgid: pkg, + pkgid: spec, }) } - const info = hostedFromMani(mani) + const info = this.hostedFromMani(mani) const url = info ? info.browse(mani.repository.directory) : unknownHostedUrl(rurl) if (!url) { throw Object.assign(new Error('no repository: could not get url'), { - pkgid: pkg, + pkgid: spec, }) } - - log.silly('docs', 'url', url) - await openUrl(this.npm, url, `${mani.name} repo available at the following URL`) + return url } } module.exports = Repo diff --git a/lib/commands/restart.js b/lib/commands/restart.js index a123686..575928b 100644 --- a/lib/commands/restart.js +++ b/lib/commands/restart.js @@ -8,5 +8,7 @@ class Restart extends LifecycleCmd { 'ignore-scripts', 'script-shell', ] + + static ignoreImplicitWorkspace = false } module.exports = Restart diff --git a/lib/commands/root.js b/lib/commands/root.js index 7749c60..b814034 100644 --- a/lib/commands/root.js +++ b/lib/commands/root.js @@ -3,6 +3,7 @@ class Root extends BaseCommand { static description = 'Display npm root' static name = 'root' static params = ['global'] + static ignoreImplicitWorkspace = true async exec () { this.npm.output(this.npm.dir) diff --git a/lib/commands/run-script.js b/lib/commands/run-script.js index cd877e0..3852f7b 100644 --- a/lib/commands/run-script.js +++ b/lib/commands/run-script.js @@ -5,7 +5,7 @@ const { isServerPackage } = runScript const rpj = require('read-package-json-fast') const log = require('../utils/log-shim.js') const didYouMean = require('../utils/did-you-mean.js') -const isWindowsShell = require('../utils/is-windows-shell.js') +const { isWindowsShell } = require('../utils/is-windows.js') const cmdList = [ 'publish', @@ -35,11 +35,14 @@ class RunScript extends BaseCommand { 'include-workspace-root', 'if-present', 'ignore-scripts', + 'foreground-scripts', 'script-shell', ] static name = 'run-script' static usage = ['<command> [-- <args>]'] + static ignoreImplicitWorkspace = false + static isShellout = true async completion (opts) { const argv = opts.conf.argv.remain @@ -114,9 +117,8 @@ class RunScript extends BaseCommand { args, scriptShell, stdio: 'inherit', - stdioString: true, pkg, - banner: log.level !== 'silent', + banner: !this.npm.silent, } for (const [event, args] of events) { @@ -139,7 +141,7 @@ class RunScript extends BaseCommand { } const allScripts = Object.keys(scripts) - if (log.level === 'silent') { + if (this.npm.silent) { return allScripts } @@ -233,7 +235,7 @@ class RunScript extends BaseCommand { async listWorkspaces (args, filters) { await this.setWorkspaces(filters) - if (log.level === 'silent') { + if (this.npm.silent) { return } diff --git a/lib/commands/search.js b/lib/commands/search.js index bdeeffe..8751e9e 100644 --- a/lib/commands/search.js +++ b/lib/commands/search.js @@ -3,26 +3,33 @@ const Pipeline = require('minipass-pipeline') const libSearch = require('libnpmsearch') const log = require('../utils/log-shim.js') -const formatPackageStream = require('../search/format-package-stream.js') -const packageFilter = require('../search/package-filter.js') +const formatSearchStream = require('../utils/format-search-stream.js') -function prepareIncludes (args) { - return args - .map(s => s.toLowerCase()) - .filter(s => s) -} +function filter (data, include, exclude) { + const words = [data.name] + .concat(data.maintainers.map(m => `=${m.username}`)) + .concat(data.keywords || []) + .map(f => f && f.trim && f.trim()) + .filter(f => f) + .join(' ') + .toLowerCase() -function prepareExcludes (searchexclude) { - var exclude - if (typeof searchexclude === 'string') { - exclude = searchexclude.split(/\s+/) - } else { - exclude = [] + if (exclude.find(e => match(words, e))) { + return false } - return exclude - .map(s => s.toLowerCase()) - .filter(s => s) + return true +} + +function match (words, pattern) { + if (pattern.startsWith('/')) { + if (pattern.endsWith('/')) { + pattern = pattern.slice(0, -1) + } + pattern = new RegExp(pattern.slice(1)) + return words.match(pattern) + } + return words.indexOf(pattern) !== -1 } const BaseCommand = require('../base-command.js') @@ -44,13 +51,14 @@ class Search extends BaseCommand { ] static usage = ['[search terms ...]'] + static ignoreImplicitWorkspace = true async exec (args) { const opts = { ...this.npm.flatOptions, ...this.npm.flatOptions.search, - include: prepareIncludes(args), - exclude: prepareExcludes(this.npm.flatOptions.search.exclude), + include: args.map(s => s.toLowerCase()).filter(s => s), + exclude: this.npm.flatOptions.search.exclude.split(/\s+/), } if (opts.include.length === 0) { @@ -62,7 +70,7 @@ class Search extends BaseCommand { class FilterStream extends Minipass { write (pkg) { - if (packageFilter(pkg, opts.include, opts.exclude)) { + if (filter(pkg, opts.include, opts.exclude)) { super.write(pkg) } } @@ -72,7 +80,7 @@ class Search extends BaseCommand { // Grab a configured output stream that will spit out packages in the // desired format. - const outputStream = formatPackageStream({ + const outputStream = formatSearchStream({ args, // --searchinclude options are not highlighted ...opts, }) diff --git a/lib/commands/set-script.js b/lib/commands/set-script.js deleted file mode 100644 index 7c73ff0..0000000 --- a/lib/commands/set-script.js +++ /dev/null @@ -1,93 +0,0 @@ -const { resolve } = require('path') -const rpj = require('read-package-json-fast') -const PackageJson = require('@npmcli/package-json') -const log = require('../utils/log-shim') - -const BaseCommand = require('../base-command.js') -class SetScript extends BaseCommand { - static description = 'Set tasks in the scripts section of package.json' - static params = ['workspace', 'workspaces', 'include-workspace-root'] - static name = 'set-script' - static usage = ['[<script>] [<command>]'] - - async completion (opts) { - const argv = opts.conf.argv.remain - if (argv.length === 2) { - // find the script name - const json = resolve(this.npm.localPrefix, 'package.json') - const { scripts = {} } = await rpj(json).catch(er => ({})) - return Object.keys(scripts) - } - } - - validate (args) { - if (process.env.npm_lifecycle_event === 'postinstall') { - throw new Error('Scripts can’t set from the postinstall script') - } - - // Parse arguments - if (args.length !== 2) { - throw new Error(`Expected 2 arguments: got ${args.length}`) - } - } - - async exec (args) { - this.validate(args) - const warn = await this.doSetScript(this.npm.localPrefix, args[0], args[1]) - if (warn) { - log.warn('set-script', `Script "${args[0]}" was overwritten`) - } - } - - async execWorkspaces (args, filters) { - this.validate(args) - await this.setWorkspaces(filters) - - for (const [name, path] of this.workspaces) { - try { - const warn = await this.doSetScript(path, args[0], args[1]) - if (warn) { - log.warn('set-script', `Script "${args[0]}" was overwritten`) - log.warn(` in workspace: ${name}`) - log.warn(` at location: ${path}`) - } - } catch (err) { - log.error('set-script', err.message) - log.error(` in workspace: ${name}`) - log.error(` at location: ${path}`) - process.exitCode = 1 - } - } - } - - // returns a Boolean that will be true if - // the requested script was overwritten - // and false if it was set as a new script - async doSetScript (path, name, value) { - let warn = false - - const pkgJson = await PackageJson.load(path) - const { scripts } = pkgJson.content - - const overwriting = - scripts - && scripts[name] - && scripts[name] !== value - - if (overwriting) { - warn = true - } - - pkgJson.update({ - scripts: { - ...scripts, - [name]: value, - }, - }) - - await pkgJson.save() - - return warn - } -} -module.exports = SetScript diff --git a/lib/commands/set.js b/lib/commands/set.js index 1dc90e8..b650026 100644 --- a/lib/commands/set.js +++ b/lib/commands/set.js @@ -4,6 +4,7 @@ class Set extends BaseCommand { static description = 'Set a value in the npm configuration' static name = 'set' static usage = ['<key>=<value> [<key>=<value> ...] (See `npm config`)'] + static ignoreImplicitWorkspace = false // TODO /* istanbul ignore next */ diff --git a/lib/commands/shrinkwrap.js b/lib/commands/shrinkwrap.js index 05e3f6d..a240f03 100644 --- a/lib/commands/shrinkwrap.js +++ b/lib/commands/shrinkwrap.js @@ -6,6 +6,7 @@ const BaseCommand = require('../base-command.js') class Shrinkwrap extends BaseCommand { static description = 'Lock down dependency versions for publication' static name = 'shrinkwrap' + static ignoreImplicitWorkspace = false async exec () { // if has a npm-shrinkwrap.json, nothing to do @@ -14,7 +15,7 @@ class Shrinkwrap extends BaseCommand { // // loadVirtual, fall back to loadActual // rename shrinkwrap file type, and tree.meta.save() - if (this.npm.config.get('global')) { + if (this.npm.global) { const er = new Error('`npm shrinkwrap` does not work for global packages') er.code = 'ESHRINKWRAPGLOBAL' throw er diff --git a/lib/commands/star.js b/lib/commands/star.js index 4974c39..20039bf 100644 --- a/lib/commands/star.js +++ b/lib/commands/star.js @@ -7,12 +7,15 @@ const BaseCommand = require('../base-command.js') class Star extends BaseCommand { static description = 'Mark your favorite packages' static name = 'star' - static usage = ['[<pkg>...]'] + static usage = ['[<package-spec>...]'] static params = [ 'registry', 'unicode', + 'otp', ] + static ignoreImplicitWorkspace = false + async exec (args) { if (!args.length) { throw this.usageError() @@ -21,27 +24,20 @@ class Star extends BaseCommand { // if we're unstarring, then show an empty star image // otherwise, show the full star image const unicode = this.npm.config.get('unicode') - const unstar = this.npm.config.get('star.unstar') const full = unicode ? '\u2605 ' : '(*)' const empty = unicode ? '\u2606 ' : '( )' - const show = unstar ? empty : full + const show = this.name === 'star' ? full : empty const pkgs = args.map(npa) - for (const pkg of pkgs) { - const [username, fullData] = await Promise.all([ - getIdentity(this.npm, { ...this.npm.flatOptions, log }), - fetch.json(pkg.escapedName, { - ...this.npm.flatOptions, - spec: pkg, - query: { write: true }, - preferOnline: true, - log, - }), - ]) + const username = await getIdentity(this.npm, this.npm.flatOptions) - if (!username) { - throw new Error('You need to be logged in!') - } + for (const pkg of pkgs) { + const fullData = await fetch.json(pkg.escapedName, { + ...this.npm.flatOptions, + spec: pkg, + query: { write: true }, + preferOnline: true, + }) const body = { _id: fullData._id, @@ -49,7 +45,7 @@ class Star extends BaseCommand { users: fullData.users || {}, } - if (!unstar) { + if (this.name === 'star') { log.info('star', 'starring', body._id) body.users[username] = true log.verbose('star', 'starring', body) @@ -64,7 +60,6 @@ class Star extends BaseCommand { spec: pkg, method: 'PUT', body, - log, }) this.npm.output(show + ' ' + pkg.name) diff --git a/lib/commands/stars.js b/lib/commands/stars.js index f45ec84..4214134 100644 --- a/lib/commands/stars.js +++ b/lib/commands/stars.js @@ -8,6 +8,7 @@ class Stars extends BaseCommand { static name = 'stars' static usage = ['[<user>]'] static params = ['registry'] + static ignoreImplicitWorkspace = false async exec ([user]) { try { diff --git a/lib/commands/start.js b/lib/commands/start.js index 1731e48..d84ad23 100644 --- a/lib/commands/start.js +++ b/lib/commands/start.js @@ -8,5 +8,7 @@ class Start extends LifecycleCmd { 'ignore-scripts', 'script-shell', ] + + static ignoreImplicitWorkspace = false } module.exports = Start diff --git a/lib/commands/stop.js b/lib/commands/stop.js index 2442a94..db49767 100644 --- a/lib/commands/stop.js +++ b/lib/commands/stop.js @@ -8,5 +8,7 @@ class Stop extends LifecycleCmd { 'ignore-scripts', 'script-shell', ] + + static ignoreImplicitWorkspace = false } module.exports = Stop diff --git a/lib/commands/team.js b/lib/commands/team.js index e3fb9b8..2d4fc66 100644 --- a/lib/commands/team.js +++ b/lib/commands/team.js @@ -1,7 +1,6 @@ const columns = require('cli-columns') const libteam = require('libnpmteam') -const log = require('../utils/log-shim.js') const otplease = require('../utils/otplease.js') const BaseCommand = require('../base-command.js') @@ -23,6 +22,8 @@ class Team extends BaseCommand { 'json', ] + static ignoreImplicitWorkspace = false + async completion (opts) { const { conf: { argv: { remain: argv } } } = opts const subcommands = ['create', 'destroy', 'add', 'rm', 'ls'] @@ -43,7 +44,7 @@ class Team extends BaseCommand { // XXX: "description" option to libnpmteam is used as a description of the // team, but in npm's options, this is a boolean meaning "show the // description in npm search output". Hence its being set to null here. - await otplease({ ...this.npm.flatOptions, log }, opts => { + await otplease(this.npm, { ...this.npm.flatOptions }, opts => { entity = entity.replace(/^@/, '') switch (cmd) { case 'create': return this.create(entity, opts) @@ -73,7 +74,7 @@ class Team extends BaseCommand { })) } else if (opts.parseable) { this.npm.output(`${entity}\tcreated`) - } else if (!opts.silent && opts.loglevel !== 'silent') { + } else if (!this.npm.silent) { this.npm.output(`+@${entity}`) } } @@ -87,7 +88,7 @@ class Team extends BaseCommand { })) } else if (opts.parseable) { this.npm.output(`${entity}\tdeleted`) - } else if (!opts.silent && opts.loglevel !== 'silent') { + } else if (!this.npm.silent) { this.npm.output(`-@${entity}`) } } @@ -102,7 +103,7 @@ class Team extends BaseCommand { })) } else if (opts.parseable) { this.npm.output(`${user}\t${entity}\tadded`) - } else if (!opts.silent && opts.loglevel !== 'silent') { + } else if (!this.npm.silent) { this.npm.output(`${user} added to @${entity}`) } } @@ -117,7 +118,7 @@ class Team extends BaseCommand { })) } else if (opts.parseable) { this.npm.output(`${user}\t${entity}\tremoved`) - } else if (!opts.silent && opts.loglevel !== 'silent') { + } else if (!this.npm.silent) { this.npm.output(`${user} removed from @${entity}`) } } @@ -128,7 +129,7 @@ class Team extends BaseCommand { this.npm.output(JSON.stringify(users, null, 2)) } else if (opts.parseable) { this.npm.output(users.join('\n')) - } else if (!opts.silent && opts.loglevel !== 'silent') { + } else if (!this.npm.silent) { const plural = users.length === 1 ? '' : 's' const more = users.length === 0 ? '' : ':\n' this.npm.output(`\n@${entity} has ${users.length} user${plural}${more}`) @@ -142,7 +143,7 @@ class Team extends BaseCommand { this.npm.output(JSON.stringify(teams, null, 2)) } else if (opts.parseable) { this.npm.output(teams.join('\n')) - } else if (!opts.silent && opts.loglevel !== 'silent') { + } else if (!this.npm.silent) { const plural = teams.length === 1 ? '' : 's' const more = teams.length === 0 ? '' : ':\n' this.npm.output(`\n@${entity} has ${teams.length} team${plural}${more}`) diff --git a/lib/commands/test.js b/lib/commands/test.js index 2cea8f7..43be934 100644 --- a/lib/commands/test.js +++ b/lib/commands/test.js @@ -8,5 +8,7 @@ class Test extends LifecycleCmd { 'ignore-scripts', 'script-shell', ] + + static ignoreImplicitWorkspace = false } module.exports = Test diff --git a/lib/commands/token.js b/lib/commands/token.js index cfb5ab6..de8e611 100644 --- a/lib/commands/token.js +++ b/lib/commands/token.js @@ -1,5 +1,5 @@ const Table = require('cli-table3') -const ansistyles = require('ansistyles') +const chalk = require('chalk') const { v4: isCidrV4, v6: isCidrV6 } = require('is-cidr') const log = require('../utils/log-shim.js') const profile = require('npm-profile') @@ -14,6 +14,7 @@ class Token extends BaseCommand { static name = 'token' static usage = ['list', 'revoke <id|token>', 'create [--read-only] [--cidr=list]'] static params = ['read-only', 'cidr', 'registry', 'otp'] + static ignoreImplicitWorkspace = true async completion (opts) { const argv = opts.conf.argv.remain @@ -120,7 +121,7 @@ class Token extends BaseCommand { }) await Promise.all( toRemove.map(key => { - return otplease(conf, conf => { + return otplease(this.npm, conf, conf => { return profile.removeToken(key, conf) }) }) @@ -139,36 +140,31 @@ class Token extends BaseCommand { const cidr = conf.cidr const readonly = conf.readOnly - return readUserInfo - .password() - .then(password => { - const validCIDR = this.validateCIDRList(cidr) - log.info('token', 'creating') - return pulseTillDone.withPromise( - otplease(conf, conf => { - return profile.createToken(password, readonly, validCIDR, conf) - }) - ) - }) - .then(result => { - delete result.key - delete result.updated - if (conf.json) { - this.npm.output(JSON.stringify(result)) - } else if (conf.parseable) { - Object.keys(result).forEach(k => this.npm.output(k + '\t' + result[k])) - } else { - const table = new Table() - for (const k of Object.keys(result)) { - table.push({ [ansistyles.bright(k)]: String(result[k]) }) - } - this.npm.output(table.toString()) - } + const password = await readUserInfo.password() + const validCIDR = this.validateCIDRList(cidr) + log.info('token', 'creating') + const result = await pulseTillDone.withPromise( + otplease(this.npm, conf, conf => { + return profile.createToken(password, readonly, validCIDR, conf) }) + ) + delete result.key + delete result.updated + if (conf.json) { + this.npm.output(JSON.stringify(result)) + } else if (conf.parseable) { + Object.keys(result).forEach(k => this.npm.output(k + '\t' + result[k])) + } else { + const table = new Table() + for (const k of Object.keys(result)) { + table.push({ [chalk.bold(k)]: String(result[k]) }) + } + this.npm.output(table.toString()) + } } config () { - const conf = { ...this.npm.flatOptions, log } + const conf = { ...this.npm.flatOptions } const creds = this.npm.config.getCredentialsByURI(conf.registry) if (creds.token) { conf.auth = { token: creds.token } diff --git a/lib/commands/uninstall.js b/lib/commands/uninstall.js index b40c59b..e4a193c 100644 --- a/lib/commands/uninstall.js +++ b/lib/commands/uninstall.js @@ -1,5 +1,4 @@ const { resolve } = require('path') -const log = require('../utils/log-shim.js') const Arborist = require('@npmcli/arborist') const rpj = require('read-package-json-fast') @@ -12,6 +11,7 @@ class Uninstall extends ArboristWorkspaceCmd { static name = 'uninstall' static params = ['save', ...super.params] static usage = ['[<@scope>/]<pkg>...'] + static ignoreImplicitWorkspace = false // TODO /* istanbul ignore next */ @@ -21,13 +21,12 @@ class Uninstall extends ArboristWorkspaceCmd { async exec (args) { // the /path/to/node_modules/.. - const global = this.npm.config.get('global') - const path = global + const path = this.npm.global ? resolve(this.npm.globalDir, '..') : this.npm.localPrefix if (!args.length) { - if (!global) { + if (!this.npm.global) { throw new Error('Must provide a package name to remove') } else { let pkg @@ -49,7 +48,6 @@ class Uninstall extends ArboristWorkspaceCmd { const opts = { ...this.npm.flatOptions, path, - log, rm: args, workspaces: this.workspaceNames, } diff --git a/lib/commands/unpublish.js b/lib/commands/unpublish.js index d8410cc..268c8c3 100644 --- a/lib/commands/unpublish.js +++ b/lib/commands/unpublish.js @@ -1,13 +1,15 @@ +const libaccess = require('libnpmaccess') +const libunpub = require('libnpmpublish').unpublish +const npa = require('npm-package-arg') +const npmFetch = require('npm-registry-fetch') const path = require('path') const util = require('util') -const npa = require('npm-package-arg') -const libaccess = require('libnpmaccess') -const npmFetch = require('npm-registry-fetch') -const libunpub = require('libnpmpublish').unpublish const readJson = util.promisify(require('read-package-json')) + +const { flatten } = require('../utils/config/index.js') +const getIdentity = require('../utils/get-identity.js') const log = require('../utils/log-shim') const otplease = require('../utils/otplease.js') -const getIdentity = require('../utils/get-identity.js') const LAST_REMAINING_VERSION_ERROR = 'Refusing to delete the last version of the package. ' + 'It will block from republishing a new version for 24 hours.\n' + @@ -18,10 +20,12 @@ class Unpublish extends BaseCommand { static description = 'Remove a package from the registry' static name = 'unpublish' static params = ['dry-run', 'force', 'workspace', 'workspaces'] - static usage = ['[<@scope>/]<pkg>[@<version>]'] + static usage = ['[<package-spec>]'] + static ignoreImplicitWorkspace = false async getKeysOfVersions (name, opts) { - const json = await npmFetch.json(npa(name).escapedName, opts) + const pkgUri = npa(name).escapedName + const json = await npmFetch.json(`${pkgUri}?write=true`, opts) return Object.keys(json.versions) } @@ -32,17 +36,17 @@ class Unpublish extends BaseCommand { return [] } - const opts = { ...this.npm.flatOptions, log } + const opts = { ...this.npm.flatOptions } const username = await getIdentity(this.npm, { ...opts }).catch(() => null) if (!username) { return [] } - const access = await libaccess.lsPackages(username, opts) + const access = await libaccess.getPackages(username, opts) // do a bit of filtering at this point, so that we don't need // to fetch versions for more than one thing, but also don't // accidentally unpublish a whole project - let pkgs = Object.keys(access || {}) + let pkgs = Object.keys(access) if (!partialWord || !pkgs.length) { return pkgs } @@ -66,13 +70,10 @@ class Unpublish extends BaseCommand { throw this.usageError() } - const spec = args.length && npa(args[0]) + let spec = args.length && npa(args[0]) const force = this.npm.config.get('force') - const loglevel = this.npm.config.get('loglevel') - const silent = loglevel === 'silent' + const { silent } = this.npm const dryRun = this.npm.config.get('dry-run') - let pkgName - let pkgVersion log.silly('unpublish', 'args[0]', args[0]) log.silly('unpublish', 'spec', spec) @@ -84,54 +85,53 @@ class Unpublish extends BaseCommand { ) } - const opts = { ...this.npm.flatOptions, log } - if (!spec || path.resolve(spec.name) === this.npm.localPrefix) { - // if there's a package.json in the current folder, then - // read the package name and version out of that. + const opts = { ...this.npm.flatOptions } + + let pkgName + let pkgVersion + let manifest + let manifestErr + try { const pkgJson = path.join(this.npm.localPrefix, 'package.json') - let manifest - try { - manifest = await readJson(pkgJson) - } catch (err) { - if (err && err.code !== 'ENOENT' && err.code !== 'ENOTDIR') { - throw err - } else { + manifest = await readJson(pkgJson) + } catch (err) { + manifestErr = err + } + if (spec) { + // If cwd has a package.json with a name that matches the package being + // unpublished, load up the publishConfig + if (manifest && manifest.name === spec.name && manifest.publishConfig) { + flatten(manifest.publishConfig, opts) + } + const versions = await this.getKeysOfVersions(spec.name, opts) + if (versions.length === 1 && !force) { + throw this.usageError(LAST_REMAINING_VERSION_ERROR) + } + pkgName = spec.name + pkgVersion = spec.type === 'version' ? `@${spec.rawSpec}` : '' + } else { + if (manifestErr) { + if (manifestErr.code === 'ENOENT' || manifestErr.code === 'ENOTDIR') { throw this.usageError() + } else { + throw manifestErr } } log.verbose('unpublish', manifest) - const { name, version, publishConfig } = manifest - const pkgJsonSpec = npa.resolve(name, version) - const optsWithPub = { ...opts, publishConfig } - - const versions = await this.getKeysOfVersions(name, optsWithPub) - if (versions.length === 1 && !force) { - throw this.usageError( - LAST_REMAINING_VERSION_ERROR - ) + spec = npa.resolve(manifest.name, manifest.version) + if (manifest.publishConfig) { + flatten(manifest.publishConfig, opts) } - if (!dryRun) { - await otplease(opts, opts => libunpub(pkgJsonSpec, optsWithPub)) - } - pkgName = name - pkgVersion = version ? `@${version}` : '' - } else { - const versions = await this.getKeysOfVersions(spec.name, opts) - if (versions.length === 1 && !force) { - throw this.usageError( - LAST_REMAINING_VERSION_ERROR - ) - } - if (!dryRun) { - await otplease(opts, opts => libunpub(spec, opts)) - } - pkgName = spec.name - pkgVersion = spec.type === 'version' ? `@${spec.rawSpec}` : '' + pkgName = manifest.name + pkgVersion = manifest.version ? `@${manifest.version}` : '' } + if (!dryRun) { + await otplease(this.npm, opts, opts => libunpub(spec, opts)) + } if (!silent) { this.npm.output(`- ${pkgName}${pkgVersion}`) } diff --git a/lib/commands/unstar.js b/lib/commands/unstar.js index 9a64c84..cbcb736 100644 --- a/lib/commands/unstar.js +++ b/lib/commands/unstar.js @@ -3,15 +3,5 @@ const Star = require('./star.js') class Unstar extends Star { static description = 'Remove an item from your favorite packages' static name = 'unstar' - static params = [ - 'registry', - 'unicode', - 'otp', - ] - - async exec (args) { - this.npm.config.set('star.unstar', true) - return super.exec(args) - } } module.exports = Unstar diff --git a/lib/commands/update.js b/lib/commands/update.js index c55d7cf..be9d350 100644 --- a/lib/commands/update.js +++ b/lib/commands/update.js @@ -10,14 +10,17 @@ const ArboristWorkspaceCmd = require('../arborist-cmd.js') class Update extends ArboristWorkspaceCmd { static description = 'Update packages' static name = 'update' + static params = [ + 'save', 'global', - 'global-style', + 'install-strategy', 'legacy-bundling', + 'global-style', + 'omit', 'strict-peer-deps', 'package-lock', - 'save', - 'omit', + 'foreground-scripts', 'ignore-scripts', 'audit', 'bin-links', @@ -37,7 +40,7 @@ class Update extends ArboristWorkspaceCmd { async exec (args) { const update = args.length === 0 ? true : args const global = path.resolve(this.npm.globalDir, '..') - const where = this.npm.config.get('global') + const where = this.npm.global ? global : this.npm.prefix @@ -54,7 +57,6 @@ class Update extends ArboristWorkspaceCmd { const opts = { ...this.npm.flatOptions, - log, path: where, save, workspaces: this.workspaceNames, diff --git a/lib/commands/version.js b/lib/commands/version.js index 8c676b3..ab59fff 100644 --- a/lib/commands/version.js +++ b/lib/commands/version.js @@ -3,6 +3,7 @@ const { resolve } = require('path') const { promisify } = require('util') const readFile = promisify(require('fs').readFile) +const updateWorkspaces = require('../workspaces/update-workspaces.js') const BaseCommand = require('../base-command.js') class Version extends BaseCommand { @@ -17,9 +18,12 @@ class Version extends BaseCommand { 'sign-git-tag', 'workspace', 'workspaces', + 'workspaces-update', 'include-workspace-root', ] + static ignoreImplicitWorkspace = false + /* eslint-disable-next-line max-len */ static usage = ['[<newversion> | major | minor | patch | premajor | preminor | prepatch | prerelease | from-git]'] @@ -79,6 +83,7 @@ class Version extends BaseCommand { async changeWorkspaces (args, filters) { const prefix = this.npm.config.get('tag-version-prefix') await this.setWorkspaces(filters) + const updatedWorkspaces = [] for (const [name, path] of this.workspaces) { this.npm.output(name) const version = await libnpmversion(args[0], { @@ -86,8 +91,10 @@ class Version extends BaseCommand { 'git-tag-version': false, path, }) + updatedWorkspaces.push(name) this.npm.output(`${prefix}${version}`) } + return this.update(updatedWorkspaces) } async list (results = {}) { @@ -127,6 +134,22 @@ class Version extends BaseCommand { } return this.list(results) } + + async update (workspaces) { + const { + config, + flatOptions, + localPrefix, + } = this.npm + + await updateWorkspaces({ + config, + flatOptions, + localPrefix, + npm: this.npm, + workspaces, + }) + } } module.exports = Version diff --git a/lib/commands/view.js b/lib/commands/view.js index 4f7464d..32b2d0f 100644 --- a/lib/commands/view.js +++ b/lib/commands/view.js @@ -1,6 +1,9 @@ +/* eslint-disable no-console */ +// XXX: remove console.log later + // npm view [pkg [pkg ...]] -const color = require('ansicolors') +const chalk = require('chalk') const columns = require('cli-columns') const fs = require('fs') const jsonParse = require('json-parse-even-better-errors') @@ -10,7 +13,6 @@ const { resolve } = require('path') const formatBytes = require('../utils/format-bytes.js') const relativeDate = require('tiny-relative-date') const semver = require('semver') -const style = require('ansistyles') const { inspect, promisify } = require('util') const { packument } = require('pacote') @@ -29,7 +31,9 @@ class View extends BaseCommand { 'include-workspace-root', ] - static usage = ['[<@scope>/]<pkg>[@<version>] [<field>[.subfield]...]'] + static ignoreImplicitWorkspace = false + + static usage = ['[<package-spec>] [<field>[.subfield]...]'] async completion (opts) { if (opts.conf.argv.remain.length <= 2) { @@ -53,9 +57,6 @@ class View extends BaseCommand { function getFields (d, f, pref) { f = f || [] - if (!d) { - return f - } pref = pref || [] Object.keys(d).forEach((k) => { if (k.charAt(0) === '_' || k.indexOf('.') !== -1) { @@ -90,7 +91,7 @@ class View extends BaseCommand { const local = /^\.@/.test(pkg) || pkg === '.' if (local) { - if (this.npm.config.get('global')) { + if (this.npm.global) { throw new Error('Cannot use view command in global mode.') } const dir = this.npm.prefix @@ -101,6 +102,7 @@ class View extends BaseCommand { // put the version back if it existed pkg = `${manifest.name}${pkg.slice(1)}` } + let wholePackument = false if (!args.length) { args = [''] @@ -194,19 +196,19 @@ class View extends BaseCommand { // get the data about this package let version = this.npm.config.get('tag') // rawSpec is the git url if this is from git - if (spec.type !== 'git' && spec.rawSpec) { + if (spec.type !== 'git' && spec.type !== 'directory' && spec.rawSpec !== '*') { version = spec.rawSpec } const pckmnt = await packument(spec, opts) - if (pckmnt['dist-tags'] && pckmnt['dist-tags'][version]) { + if (pckmnt['dist-tags']?.[version]) { version = pckmnt['dist-tags'][version] } if (pckmnt.time && pckmnt.time.unpublished) { const u = pckmnt.time.unpublished - const er = new Error('Unpublished by ' + u.name + ' on ' + u.time) + const er = new Error(`Unpublished on ${u.time}`) er.statusCode = 404 er.code = 'E404' er.pkgid = pckmnt._id @@ -235,6 +237,15 @@ class View extends BaseCommand { } }) + // No data has been pushed because no data is matching the specified version + if (data.length === 0 && version !== 'latest') { + const er = new Error(`No match found for version ${version}`) + er.statusCode = 404 + er.code = 'E404' + er.pkgid = `${pckmnt._id}@${version}` + throw er + } + if ( !this.npm.config.get('json') && args.length === 1 && @@ -313,34 +324,34 @@ class View extends BaseCommand { Object.keys(packument['dist-tags']).forEach((t) => { const version = packument['dist-tags'][t] - tags.push(`${style.bright(color.green(t))}: ${version}`) + tags.push(`${chalk.bold.green(t)}: ${version}`) }) const unpackedSize = manifest.dist.unpackedSize && formatBytes(manifest.dist.unpackedSize, true) const licenseField = manifest.license || 'Proprietary' const info = { - name: color.green(manifest.name), - version: color.green(manifest.version), - bins: Object.keys(manifest.bin || {}).map(color.yellow), - versions: color.yellow(packument.versions.length + ''), + name: chalk.green(manifest.name), + version: chalk.green(manifest.version), + bins: Object.keys(manifest.bin || {}), + versions: chalk.yellow(packument.versions.length + ''), description: manifest.description, deprecated: manifest.deprecated, - keywords: (packument.keywords || []).map(color.yellow), + keywords: packument.keywords || [], license: typeof licenseField === 'string' ? licenseField : (licenseField.type || 'Proprietary'), deps: Object.keys(manifest.dependencies || {}).map((dep) => { - return `${color.yellow(dep)}: ${manifest.dependencies[dep]}` + return `${chalk.yellow(dep)}: ${manifest.dependencies[dep]}` }), publisher: manifest._npmUser && unparsePerson({ - name: color.yellow(manifest._npmUser.name), - email: color.cyan(manifest._npmUser.email), + name: chalk.yellow(manifest._npmUser.name), + email: chalk.cyan(manifest._npmUser.email), }), modified: !packument.time ? undefined - : color.yellow(relativeDate(packument.time[manifest.version])), + : chalk.yellow(relativeDate(packument.time[manifest.version])), maintainers: (packument.maintainers || []).map((u) => unparsePerson({ - name: color.yellow(u.name), - email: color.cyan(u.email), + name: chalk.yellow(u.name), + email: chalk.cyan(u.email), })), repo: ( manifest.bugs && (manifest.bugs.url || manifest.bugs) @@ -351,47 +362,47 @@ class View extends BaseCommand { manifest.homepage && (manifest.homepage.url || manifest.homepage) ), tags, - tarball: color.cyan(manifest.dist.tarball), - shasum: color.yellow(manifest.dist.shasum), + tarball: chalk.cyan(manifest.dist.tarball), + shasum: chalk.yellow(manifest.dist.shasum), integrity: - manifest.dist.integrity && color.yellow(manifest.dist.integrity), + manifest.dist.integrity && chalk.yellow(manifest.dist.integrity), fileCount: - manifest.dist.fileCount && color.yellow(manifest.dist.fileCount), - unpackedSize: unpackedSize && color.yellow(unpackedSize), + manifest.dist.fileCount && chalk.yellow(manifest.dist.fileCount), + unpackedSize: unpackedSize && chalk.yellow(unpackedSize), } if (info.license.toLowerCase().trim() === 'proprietary') { - info.license = style.bright(color.red(info.license)) + info.license = chalk.bold.red(info.license) } else { - info.license = color.green(info.license) + info.license = chalk.green(info.license) } console.log('') console.log( - style.underline(style.bright(`${info.name}@${info.version}`)) + + chalk.underline.bold(`${info.name}@${info.version}`) + ' | ' + info.license + - ' | deps: ' + (info.deps.length ? color.cyan(info.deps.length) : color.green('none')) + + ' | deps: ' + (info.deps.length ? chalk.cyan(info.deps.length) : chalk.green('none')) + ' | versions: ' + info.versions ) info.description && console.log(info.description) if (info.repo || info.site) { - info.site && console.log(color.cyan(info.site)) + info.site && console.log(chalk.cyan(info.site)) } const warningSign = unicode ? ' ⚠️ ' : '!!' info.deprecated && console.log( - `\n${style.bright(color.red('DEPRECATED'))}${ + `\n${chalk.bold.red('DEPRECATED')}${ warningSign } - ${info.deprecated}` ) if (info.keywords.length) { console.log('') - console.log('keywords:', info.keywords.join(', ')) + console.log('keywords:', chalk.yellow(info.keywords.join(', '))) } if (info.bins.length) { console.log('') - console.log('bin:', info.bins.join(', ')) + console.log('bin:', chalk.yellow(info.bins.join(', '))) } console.log('') diff --git a/lib/commands/whoami.js b/lib/commands/whoami.js index 07ebe2e..4497f9b 100644 --- a/lib/commands/whoami.js +++ b/lib/commands/whoami.js @@ -1,14 +1,14 @@ const getIdentity = require('../utils/get-identity.js') -const log = require('../utils/log-shim.js') const BaseCommand = require('../base-command.js') class Whoami extends BaseCommand { static description = 'Display npm username' static name = 'whoami' static params = ['registry'] + static ignoreImplicitWorkspace = true async exec (args) { - const username = await getIdentity(this.npm, { ...this.npm.flatOptions, log }) + const username = await getIdentity(this.npm, { ...this.npm.flatOptions }) this.npm.output( this.npm.config.get('json') ? JSON.stringify(username) : username ) diff --git a/lib/exec/get-workspace-location-msg.js b/lib/exec/get-workspace-location-msg.js deleted file mode 100644 index 813b11e..0000000 --- a/lib/exec/get-workspace-location-msg.js +++ /dev/null @@ -1,25 +0,0 @@ -const chalk = require('chalk') -const readPackageJson = require('read-package-json-fast') - -const nocolor = { - dim: s => s, - green: s => s, -} - -const getLocationMsg = async ({ color, path }) => { - const colorize = color ? chalk : nocolor - const { _id } = - await readPackageJson(`${path}/package.json`) - .catch(() => ({})) - - const workspaceMsg = _id - ? ` in workspace ${colorize.green(_id)}` - : ` in a ${colorize.green('new')} workspace` - const locationMsg = ` at location:\n${ - colorize.dim(path) - }` - - return `${workspaceMsg}${locationMsg}` -} - -module.exports = getLocationMsg diff --git a/lib/lifecycle-cmd.js b/lib/lifecycle-cmd.js index e2190c2..41633a4 100644 --- a/lib/lifecycle-cmd.js +++ b/lib/lifecycle-cmd.js @@ -4,6 +4,7 @@ const BaseCommand = require('./base-command.js') class LifecycleCmd extends BaseCommand { static usage = ['[-- <args>]'] + static isShellout = true async exec (args, cb) { return this.npm.exec('run-script', [this.constructor.name, ...args]) diff --git a/lib/npm.js b/lib/npm.js index 4d22b53..0bdbcdb 100644 --- a/lib/npm.js +++ b/lib/npm.js @@ -1,73 +1,86 @@ +const Arborist = require('@npmcli/arborist') const EventEmitter = require('events') -const { resolve, dirname } = require('path') +const { resolve, dirname, join } = require('path') const Config = require('@npmcli/config') +const chalk = require('chalk') +const which = require('which') +const fs = require('fs/promises') // Patch the global fs module here at the app level require('graceful-fs').gracefulify(require('fs')) const { definitions, flatten, shorthands } = require('./utils/config/index.js') -const { shellouts } = require('./utils/cmd-list.js') const usage = require('./utils/npm-usage.js') - -const which = require('which') - -const deref = require('./utils/deref-command.js') const LogFile = require('./utils/log-file.js') const Timers = require('./utils/timers.js') const Display = require('./utils/display.js') const log = require('./utils/log-shim') const replaceInfo = require('./utils/replace-info.js') +const updateNotifier = require('./utils/update-notifier.js') +const pkg = require('../package.json') +const cmdList = require('./utils/cmd-list.js') let warnedNonDashArg = false const _load = Symbol('_load') -const _tmpFolder = Symbol('_tmpFolder') -const _title = Symbol('_title') -const pkg = require('../package.json') class Npm extends EventEmitter { static get version () { return pkg.version } - #unloaded = false - #timers = null - #logFile = null - #display = null + command = null + updateNotification = null + loadErr = null + argv = [] - constructor () { - super() - this.command = null - this.#logFile = new LogFile() - this.#display = new Display() - this.#timers = new Timers({ - start: 'npm', - listener: (name, ms) => { - const args = ['timing', name, `Completed in ${ms}ms`] - this.#logFile.log(...args) - this.#display.log(...args) - }, - }) - this.config = new Config({ - npmPath: dirname(__dirname), - definitions, - flatten, - shorthands, - log, - }) - this[_title] = process.title - this.updateNotification = null - } + #runId = new Date().toISOString().replace(/[.:]/g, '_') + #loadPromise = null + #tmpFolder = null + #title = 'npm' + #argvClean = [] + #chalk = null + + #outputBuffer = [] + #logFile = new LogFile() + #display = new Display() + #timers = new Timers({ + start: 'npm', + listener: (name, ms) => { + const args = ['timing', name, `Completed in ${ms}ms`] + this.#logFile.log(...args) + this.#display.log(...args) + }, + }) + + config = new Config({ + npmPath: dirname(__dirname), + definitions, + flatten, + shorthands, + }) get version () { return this.constructor.version } - get shelloutCommands () { - return shellouts - } - deref (c) { - return deref(c) + if (!c) { + return + } + if (c.match(/[A-Z]/)) { + c = c.replace(/([A-Z])/g, m => '-' + m.toLowerCase()) + } + if (cmdList.plumbing.indexOf(c) !== -1) { + return c + } + // first deref the abbrev, if there is one + // then resolve any aliases + // so `npm install-cl` will resolve to `install-clean` then to `ci` + let a = cmdList.abbrevs[c] + while (cmdList.aliases[a]) { + a = cmdList.aliases[a] + } + return a } // Get an instantiated npm command @@ -75,6 +88,21 @@ class Npm extends EventEmitter { // would be needed to change this async cmd (cmd) { await this.load() + + // when location isn't set and global isn't true + // check for a package.json at the localPrefix + // and set the location to project if found + // TODO: this logic can move to the config module loadLocalPrefix to + // avoid double stat calls and consolidate logic + if (this.config.isDefault('location') && !this.config.get('global')) { + const hasPackageJson = await fs.stat(resolve(this.config.localPrefix, 'package.json')) + .then((st) => st.isFile()) + .catch(() => false) + if (hasPackageJson) { + this.config.set('location', 'project') + } + } + const command = this.deref(cmd) if (!command) { throw Object.assign(new Error(`Unknown command ${cmd}`), { @@ -89,15 +117,22 @@ class Npm extends EventEmitter { // Call an npm command async exec (cmd, args) { const command = await this.cmd(cmd) - process.emit('time', `command:${cmd}`) + const timeEnd = this.time(`command:${cmd}`) // since 'test', 'start', 'stop', etc. commands re-enter this function // to call the run-script command, we need to only set it one time. if (!this.command) { process.env.npm_command = command.name this.command = command.name + this.commandInstance = command } + // this is async but we dont await it, since its ok if it doesnt + // finish before the command finishes running. it uses command and argv + // so it must be initiated here, after the command name is set + // eslint-disable-next-line promise/catch-or-return + updateNotifier(this).then((msg) => (this.updateNotification = msg)) + // Options are prefixed by a hyphen-minus (-, \u2d). // Other dash-type chars look similar but are invalid. if (!warnedNonDashArg) { @@ -114,62 +149,60 @@ class Npm extends EventEmitter { } const workspacesEnabled = this.config.get('workspaces') + // if cwd is a workspace, the default is set to [that workspace] + const implicitWorkspace = this.config.get('workspace', 'default').length > 0 const workspacesFilters = this.config.get('workspace') - if (workspacesEnabled === false && workspacesFilters.length > 0) { - throw new Error('Can not use --no-workspaces and --workspace at the same time') - } + const includeWorkspaceRoot = this.config.get('include-workspace-root') + // only call execWorkspaces when we have workspaces explicitly set + // or when it is implicit and not in our ignore list + const hasWorkspaceFilters = workspacesFilters.length > 0 + const invalidWorkspaceConfig = workspacesEnabled === false && hasWorkspaceFilters - const filterByWorkspaces = workspacesEnabled || workspacesFilters.length > 0 + // (-ws || -w foo) && (cwd is not a workspace || command is not ignoring implicit workspaces) + const filterByWorkspaces = (workspacesEnabled || hasWorkspaceFilters) && + (!implicitWorkspace || !command.ignoreImplicitWorkspace) // normally this would go in the constructor, but our tests don't // actually use a real npm object so this.npm.config isn't always // populated. this is the compromise until we can make that a reality // and then move this into the constructor. - command.workspaces = this.config.get('workspaces') + command.workspaces = workspacesEnabled command.workspacePaths = null // normally this would be evaluated in base-command#setWorkspaces, see // above for explanation - command.includeWorkspaceRoot = this.config.get('include-workspace-root') + command.includeWorkspaceRoot = includeWorkspaceRoot + let execPromise = Promise.resolve() if (this.config.get('usage')) { this.output(command.usage) - return - } - if (filterByWorkspaces) { - if (this.config.get('global')) { - throw new Error('Workspaces not supported for global packages') + } else if (invalidWorkspaceConfig) { + execPromise = Promise.reject( + new Error('Can not use --no-workspaces and --workspace at the same time')) + } else if (filterByWorkspaces) { + if (this.global) { + execPromise = Promise.reject(new Error('Workspaces not supported for global packages')) + } else { + execPromise = command.execWorkspaces(args, workspacesFilters) } - - return command.execWorkspaces(args, this.config.get('workspace')).finally(() => { - process.emit('timeEnd', `command:${cmd}`) - }) } else { - return command.exec(args).finally(() => { - process.emit('timeEnd', `command:${cmd}`) - }) + execPromise = command.exec(args) } + + return execPromise.finally(timeEnd) } async load () { - if (!this.loadPromise) { - process.emit('time', 'npm:load') - this.loadPromise = new Promise((resolve, reject) => { - this[_load]() - .catch(er => er) - .then(er => { - this.loadErr = er - if (!er && this.config.get('force')) { - log.warn('using --force', 'Recommended protections disabled.') - } - - process.emit('timeEnd', 'npm:load') - if (er) { - return reject(er) - } - resolve() - }) + if (!this.#loadPromise) { + this.#loadPromise = this.time('npm:load', async () => { + await this[_load]().catch((er) => { + this.loadErr = er + throw er + }) + if (this.config.get('force')) { + log.warn('using --force', 'Recommended protections disabled.') + } }) } - return this.loadPromise + return this.#loadPromise } get loaded () { @@ -180,109 +213,126 @@ class Npm extends EventEmitter { // during any tests to cleanup all of our listeners // Everything in here should be synchronous unload () { - // Track if we've already unloaded so we dont - // write multiple timing files. This is only an - // issue in tests right now since we unload - // in both tap teardowns and the exit handler - if (this.#unloaded) { - return - } this.#timers.off() this.#display.off() this.#logFile.off() - if (this.loaded && this.config.get('timing')) { - this.#timers.writeFile({ - command: process.argv.slice(2), - // We used to only ever report a single log file - // so to be backwards compatible report the last logfile - // XXX: remove this in npm 9 or just keep it forever - logfile: this.logFiles[this.logFiles.length - 1], - logfiles: this.logFiles, - version: this.version, - }) - } - this.#unloaded = true + } + + time (name, fn) { + return this.#timers.time(name, fn) + } + + writeTimingFile () { + this.#timers.writeFile({ + id: this.#runId, + command: this.#argvClean, + logfiles: this.logFiles, + version: this.version, + }) } get title () { - return this[_title] + return this.#title } set title (t) { process.title = t - this[_title] = t + this.#title = t } async [_load] () { - process.emit('time', 'npm:load:whichnode') - let node - try { - node = which.sync(process.argv[0]) - } catch { - // TODO should we throw here? - } - process.emit('timeEnd', 'npm:load:whichnode') + const node = this.time('npm:load:whichnode', () => { + try { + return which.sync(process.argv[0]) + } catch { + // TODO should we throw here? + } + }) + if (node && node.toUpperCase() !== process.execPath.toUpperCase()) { log.verbose('node symlink', node) process.execPath = node this.config.execPath = node } - process.emit('time', 'npm:load:configload') - await this.config.load() - process.emit('timeEnd', 'npm:load:configload') + await this.time('npm:load:configload', () => this.config.load()) + + // mkdir this separately since the logs dir can be set to + // a different location. if this fails, then we don't have + // a cache dir, but we don't want to fail immediately since + // the command might not need a cache dir (like `npm --version`) + await this.time('npm:load:mkdirpcache', () => + fs.mkdir(this.cache, { recursive: true }) + .catch((e) => log.verbose('cache', `could not create cache: ${e}`))) + + // its ok if this fails. user might have specified an invalid dir + // which we will tell them about at the end + await this.time('npm:load:mkdirplogs', () => + fs.mkdir(this.logsDir, { recursive: true }) + .catch((e) => log.verbose('logfile', `could not create logs-dir: ${e}`))) - this.argv = this.config.parsedArgv.remain // note: this MUST be shorter than the actual argv length, because it // uses the same memory, so node will truncate it if it's too long. - // if it's a token revocation, then the argv contains a secret, so - // don't show that. (Regrettable historical choice to put it there.) - // Any other secrets are configs only, so showing only the positional - // args keeps those from being leaked. - process.emit('time', 'npm:load:setTitle') - const tokrev = deref(this.argv[0]) === 'token' && this.argv[1] === 'revoke' - this.title = tokrev - ? 'npm token revoke' + (this.argv[2] ? ' ***' : '') - : replaceInfo(['npm', ...this.argv].join(' ')) - process.emit('timeEnd', 'npm:load:setTitle') - - process.emit('time', 'npm:load:display') - this.#display.load({ - // Use logColor since that is based on stderr - color: this.logColor, - progress: this.flatOptions.progress, - timing: this.config.get('timing'), - loglevel: this.config.get('loglevel'), - unicode: this.config.get('unicode'), - heading: this.config.get('heading'), + this.time('npm:load:setTitle', () => { + const { parsedArgv: { cooked, remain } } = this.config + this.argv = remain + // Secrets are mostly in configs, so title is set using only the positional args + // to keep those from being leaked. + this.title = ['npm'].concat(replaceInfo(remain)).join(' ').trim() + // The cooked argv is also logged separately for debugging purposes. It is + // cleaned as a best effort by replacing known secrets like basic auth + // password and strings that look like npm tokens. XXX: for this to be + // safer the config should create a sanitized version of the argv as it + // has the full context of what each option contains. + this.#argvClean = replaceInfo(cooked) + log.verbose('title', this.title) + log.verbose('argv', this.#argvClean.map(JSON.stringify).join(' ')) }) - process.emit('timeEnd', 'npm:load:display') - process.env.COLOR = this.color ? '1' : '0' - process.emit('time', 'npm:load:logFile') - this.#logFile.load({ - dir: resolve(this.cache, '_logs'), - logsMax: this.config.get('logs-max'), + this.time('npm:load:display', () => { + this.#display.load({ + // Use logColor since that is based on stderr + color: this.logColor, + progress: this.flatOptions.progress, + silent: this.silent, + timing: this.config.get('timing'), + loglevel: this.config.get('loglevel'), + unicode: this.config.get('unicode'), + heading: this.config.get('heading'), + }) + process.env.COLOR = this.color ? '1' : '0' }) - log.verbose('logfile', this.#logFile.files[0]) - process.emit('timeEnd', 'npm:load:logFile') - process.emit('time', 'npm:load:timers') - this.#timers.load({ - dir: this.cache, + this.time('npm:load:logFile', () => { + this.#logFile.load({ + path: this.logPath, + logsMax: this.config.get('logs-max'), + }) + log.verbose('logfile', this.#logFile.files[0] || 'no logfile created') }) - process.emit('timeEnd', 'npm:load:timers') - process.emit('time', 'npm:load:configScope') - const configScope = this.config.get('scope') - if (configScope && !/^@/.test(configScope)) { - this.config.set('scope', `@${configScope}`, this.config.find('scope')) - } - process.emit('timeEnd', 'npm:load:configScope') + this.time('npm:load:timers', () => + this.#timers.load({ + path: this.config.get('timing') ? this.logPath : null, + }) + ) + + this.time('npm:load:configScope', () => { + const configScope = this.config.get('scope') + if (configScope && !/^@/.test(configScope)) { + this.config.set('scope', `@${configScope}`, this.config.find('scope')) + } + }) } get flatOptions () { const { flat } = this.config + // the Arborist constructor is used almost everywhere we call pacote, it's + // easiest to attach it to flatOptions so it goes everywhere without having + // to touch every call + flat.Arborist = Arborist + flat.nodeVersion = process.version + flat.npmVersion = pkg.version if (this.command) { flat.npmCommand = this.command } @@ -296,10 +346,29 @@ class Npm extends EventEmitter { return this.flatOptions.color } + get chalk () { + if (!this.#chalk) { + let level = chalk.level + if (!this.color) { + level = 0 + } + this.#chalk = new chalk.Instance({ level }) + } + return this.#chalk + } + + get global () { + return this.config.get('global') || this.config.get('location') === 'global' + } + get logColor () { return this.flatOptions.logColor } + get silent () { + return this.flatOptions.silent + } + get lockfileVersion () { return 2 } @@ -320,6 +389,18 @@ class Npm extends EventEmitter { return this.#logFile.files } + get logsDir () { + return this.config.get('logs-dir') || join(this.cache, '_logs') + } + + get logPath () { + return resolve(this.logsDir, `${this.#runId}-`) + } + + get timingFile () { + return this.#timers.file + } + get cache () { return this.config.get('cache') } @@ -355,7 +436,7 @@ class Npm extends EventEmitter { } get dir () { - return this.config.get('global') ? this.globalDir : this.localDir + return this.global ? this.globalDir : this.localDir } get globalBin () { @@ -368,15 +449,15 @@ class Npm extends EventEmitter { } get bin () { - return this.config.get('global') ? this.globalBin : this.localBin + return this.global ? this.globalBin : this.localBin } get prefix () { - return this.config.get('global') ? this.globalPrefix : this.localPrefix + return this.global ? this.globalPrefix : this.localPrefix } set prefix (r) { - const k = this.config.get('global') ? 'globalPrefix' : 'localPrefix' + const k = this.global ? 'globalPrefix' : 'localPrefix' this[k] = r } @@ -386,11 +467,11 @@ class Npm extends EventEmitter { // XXX add logging to see if we actually use this get tmp () { - if (!this[_tmpFolder]) { + if (!this.#tmpFolder) { const rand = require('crypto').randomBytes(4).toString('hex') - this[_tmpFolder] = `npm-${process.pid}-${rand}` + this.#tmpFolder = `npm-${process.pid}-${rand}` } - return resolve(this.config.get('tmp'), this[_tmpFolder]) + return resolve(this.config.get('tmp'), this.#tmpFolder) } // output to stdout in a progress bar compatible way @@ -400,5 +481,43 @@ class Npm extends EventEmitter { console.log(...msg) log.showProgress() } + + outputBuffer (item) { + this.#outputBuffer.push(item) + } + + flushOutput (jsonError) { + if (!jsonError && !this.#outputBuffer.length) { + return + } + + if (this.config.get('json')) { + const jsonOutput = this.#outputBuffer.reduce((acc, item) => { + if (typeof item === 'string') { + // try to parse it as json in case its a string + try { + item = JSON.parse(item) + } catch { + return acc + } + } + return { ...acc, ...item } + }, {}) + this.output(JSON.stringify({ ...jsonOutput, ...jsonError }, null, 2)) + } else { + for (const item of this.#outputBuffer) { + this.output(item) + } + } + + this.#outputBuffer.length = 0 + } + + outputError (...msg) { + log.clearProgress() + // eslint-disable-next-line no-console + console.error(...msg) + log.showProgress() + } } module.exports = Npm diff --git a/lib/package-url-cmd.js b/lib/package-url-cmd.js new file mode 100644 index 0000000..eac2bbe --- /dev/null +++ b/lib/package-url-cmd.js @@ -0,0 +1,66 @@ +// Base command for opening urls from a package manifest (bugs, docs, repo) + +const pacote = require('pacote') +const hostedGitInfo = require('hosted-git-info') +const Arborist = require('@npmcli/arborist') + +const openUrl = require('./utils/open-url.js') +const log = require('./utils/log-shim') + +const BaseCommand = require('./base-command.js') +class PackageUrlCommand extends BaseCommand { + static ignoreImplicitWorkspace = false + static params = [ + 'browser', + 'registry', + 'workspace', + 'workspaces', + 'include-workspace-root', + ] + + static usage = ['[<pkgname> [<pkgname> ...]]'] + + async exec (args) { + if (!args || !args.length) { + args = ['.'] + } + + for (const arg of args) { + // XXX It is very odd that `where` is how pacote knows to look anywhere + // other than the cwd. + const opts = { + ...this.npm.flatOptions, + where: this.npm.localPrefix, + fullMetadata: true, + Arborist, + } + const mani = await pacote.manifest(arg, opts) + const url = this.getUrl(arg, mani) + log.silly(this.name, 'url', url) + await openUrl(this.npm, url, `${mani.name} ${this.name} available at the following URL`) + } + } + + async execWorkspaces (args, filters) { + if (args && args.length) { + return this.exec(args) + } + await this.setWorkspaces(filters) + return this.exec(this.workspacePaths) + } + + // given a manifest, try to get the hosted git info from it based on + // repository (if a string) or repository.url (if an object) returns null + // if it's not a valid repo, or not a known hosted repo + hostedFromMani (mani) { + const r = mani.repository + const rurl = !r ? null + : typeof r === 'string' ? r + : typeof r === 'object' && typeof r.url === 'string' ? r.url + : null + + // hgi returns undefined sometimes, but let's always return null here + return (rurl && hostedGitInfo.fromUrl(rurl.replace(/^git\+/, ''))) || null + } +} +module.exports = PackageUrlCommand diff --git a/lib/search/package-filter.js b/lib/search/package-filter.js deleted file mode 100644 index 45a6783..0000000 --- a/lib/search/package-filter.js +++ /dev/null @@ -1,43 +0,0 @@ -module.exports = filter -function filter (data, include, exclude, opts) { - return typeof data === 'object' && - filterWords(data, include, exclude, opts) -} - -function getWords (data, opts) { - return [data.name] - .concat((opts && opts.description) ? data.description : []) - .concat((data.maintainers || []).map(m => `=${m.name}`)) - .concat(data.versions && data.versions.length && data.url && ('<' + data.url + '>')) - .concat(data.keywords || []) - .map(f => f && f.trim && f.trim()) - .filter(f => f) - .join(' ') - .toLowerCase() -} - -function filterWords (data, include, exclude, opts) { - var words = getWords(data, opts) - for (var i = 0, l = include.length; i < l; i++) { - if (!match(words, include[i])) { - return false - } - } - - for (i = 0, l = exclude.length; i < l; i++) { - if (match(words, exclude[i])) { - return false - } - } - - return true -} - -function match (words, pattern) { - if (pattern.charAt(0) === '/') { - pattern = pattern.replace(/\/$/, '') - pattern = new RegExp(pattern.substr(1, pattern.length - 1)) - return words.match(pattern) - } - return words.indexOf(pattern) !== -1 -} diff --git a/lib/utils/auth.js b/lib/utils/auth.js new file mode 100644 index 0000000..8b9125a --- /dev/null +++ b/lib/utils/auth.js @@ -0,0 +1,78 @@ +const profile = require('npm-profile') +const log = require('../utils/log-shim') +const openUrlPrompt = require('../utils/open-url-prompt.js') +const read = require('../utils/read-user-info.js') +const otplease = require('../utils/otplease.js') + +const adduser = async (npm, { creds, ...opts }) => { + const authType = npm.config.get('auth-type') + let res + if (authType === 'web') { + res = await profile.adduserWeb((url, emitter) => { + openUrlPrompt( + npm, + url, + 'Create your account at', + 'Press ENTER to open in the browser...', + emitter + ) + }, opts) + } else { + const username = await read.username('Username:', creds.username) + const password = await read.password('Password:', creds.password) + const email = await read.email('Email: (this IS public) ', creds.email) + // npm registry quirk: If you "add" an existing user with their current + // password, it's effectively a login, and if that account has otp you'll + // be prompted for it. + res = await otplease(npm, opts, (reqOpts) => + profile.adduserCouch(username, email, password, opts) + ) + } + + // We don't know the username if it was a web login, all we can reliably log is scope and registry + const message = `Logged in${opts.scope ? ` to scope ${opts.scope}` : ''} on ${opts.registry}.` + + log.info('adduser', message) + + return { + message, + newCreds: { token: res.token }, + } +} + +const login = async (npm, { creds, ...opts }) => { + const authType = npm.config.get('auth-type') + let res + if (authType === 'web') { + res = await profile.loginWeb((url, emitter) => { + openUrlPrompt( + npm, + url, + 'Login at', + 'Press ENTER to open in the browser...', + emitter + ) + }, opts) + } else { + const username = await read.username('Username:', creds.username) + const password = await read.password('Password:', creds.password) + res = await otplease(npm, opts, (reqOpts) => + profile.loginCouch(username, password, reqOpts) + ) + } + + // We don't know the username if it was a web login, all we can reliably log is scope and registry + const message = `Logged in${opts.scope ? ` to scope ${opts.scope}` : ''} on ${opts.registry}.` + + log.info('login', message) + + return { + message, + newCreds: { token: res.token }, + } +} + +module.exports = { + adduser, + login, +} diff --git a/lib/utils/cmd-list.js b/lib/utils/cmd-list.js index 26da539..03fe8ed 100644 --- a/lib/utils/cmd-list.js +++ b/lib/utils/cmd-list.js @@ -1,5 +1,23 @@ -// short names for common things -const shorthands = { +const abbrev = require('abbrev') +const localeCompare = require('@isaacs/string-locale-compare')('en') + +// plumbing should not have any aliases +const aliases = { + + // aliases + author: 'owner', + home: 'docs', + issues: 'bugs', + info: 'view', + show: 'view', + find: 'search', + add: 'install', + unlink: 'uninstall', + remove: 'uninstall', + rm: 'uninstall', + r: 'uninstall', + + // short names for common things un: 'uninstall', rb: 'rebuild', list: 'ls', @@ -21,12 +39,11 @@ const shorthands = { 'clean-install-test': 'cit', x: 'exec', why: 'explain', -} - -const affordances = { la: 'll', verison: 'version', ic: 'ci', + + // typos innit: 'init', // manually abbrev so that install-test doesn't make insta stop working in: 'install', @@ -37,125 +54,97 @@ const affordances = { isnt: 'install', isnta: 'install', isntal: 'install', + isntall: 'install', 'install-clean': 'ci', 'isntall-clean': 'ci', hlep: 'help', 'dist-tags': 'dist-tag', upgrade: 'update', udpate: 'update', - login: 'adduser', - 'add-user': 'adduser', - author: 'owner', - home: 'docs', - issues: 'bugs', - info: 'view', - show: 'view', - find: 'search', - add: 'install', - unlink: 'uninstall', - remove: 'uninstall', - rm: 'uninstall', - r: 'uninstall', rum: 'run-script', sit: 'cit', urn: 'run-script', ogr: 'org', + 'add-user': 'adduser', } // these are filenames in . -const cmdList = [ - 'ci', - 'install-ci-test', - 'install', - 'install-test', - 'uninstall', - 'cache', - 'config', - 'set', - 'get', - 'update', - 'outdated', - 'prune', - 'pack', - 'find-dupes', - 'dedupe', - 'hook', - - 'rebuild', - 'link', - - 'publish', - 'star', - 'stars', - 'unstar', - 'adduser', - 'login', // This is an alias for `adduser` but it can be confusing - 'logout', - 'unpublish', - 'owner', +const commands = [ 'access', - 'team', - 'deprecate', - 'shrinkwrap', - 'token', - 'profile', + 'adduser', 'audit', - 'fund', - 'org', - - 'help', - 'ls', - 'll', - 'search', - 'view', - 'init', - 'version', - 'edit', - 'explore', - 'docs', - 'repo', 'bugs', - 'root', - 'prefix', - 'bin', - 'whoami', + 'cache', + 'ci', + 'completion', + 'config', + 'dedupe', + 'deprecate', 'diff', 'dist-tag', - 'ping', - 'pkg', - - 'test', - 'stop', - 'start', - 'restart', - 'run-script', - 'set-script', - 'completion', + 'docs', 'doctor', + 'edit', 'exec', 'explain', -] - -const plumbing = ['birthday', 'help-search'] - -// these commands just shell out to something else or handle the -// error themselves, so it's confusing and weird to write out -// our full error log banner when they exit non-zero -const shellouts = [ - 'exec', + 'explore', + 'find-dupes', + 'fund', + 'get', + 'help', + 'hook', + 'init', + 'install', + 'install-ci-test', + 'install-test', + 'link', + 'll', + 'login', // This is an alias for `adduser` but it can be confusing + 'logout', + 'ls', + 'org', + 'outdated', + 'owner', + 'pack', + 'ping', + 'pkg', + 'prefix', + 'profile', + 'prune', + 'publish', + 'query', + 'rebuild', + 'repo', + 'restart', + 'root', 'run-script', - 'test', + 'search', + 'set', + 'shrinkwrap', + 'star', + 'stars', 'start', 'stop', - 'restart', - 'birthday', -] + 'team', + 'test', + 'token', + 'uninstall', + 'unpublish', + 'unstar', + 'update', + 'version', + 'view', + 'whoami', +].sort(localeCompare) + +const plumbing = ['help-search'] +const allCommands = [...commands, ...plumbing].sort(localeCompare) +const abbrevs = abbrev(commands.concat(Object.keys(aliases))) module.exports = { - aliases: Object.assign({}, shorthands, affordances), - shorthands, - affordances, - cmdList, + abbrevs, + aliases, + commands, plumbing, - shellouts, + allCommands, } diff --git a/lib/utils/completion.sh b/lib/utils/completion.sh index 4245007..a3e5143 100755 --- a/lib/utils/completion.sh +++ b/lib/utils/completion.sh @@ -1,3 +1,4 @@ +#!/bin/bash ###-begin-npm-completion-### # # npm command completion script diff --git a/lib/utils/completion/installed-shallow.js b/lib/utils/completion/installed-shallow.js index 686c95e..d59318f 100644 --- a/lib/utils/completion/installed-shallow.js +++ b/lib/utils/completion/installed-shallow.js @@ -1,8 +1,10 @@ -const { promisify } = require('util') -const readdir = promisify(require('readdir-scoped-modules')) +const { readdirScoped } = require('@npmcli/fs') const installedShallow = async (npm, opts) => { - const names = global => readdir(global ? npm.globalDir : npm.localDir) + const names = async global => { + const paths = await readdirScoped(global ? npm.globalDir : npm.localDir) + return paths.map(p => p.replace(/\\/g, '/')) + } const { conf: { argv: { remain } } } = opts if (remain.length > 3) { return null diff --git a/lib/utils/config/definition.js b/lib/utils/config/definition.js index fc46bc3..f88d833 100644 --- a/lib/utils/config/definition.js +++ b/lib/utils/config/definition.js @@ -233,7 +233,7 @@ const wrapAll = s => { return ( '* ' + block - .substr(1) + .slice(1) .trim() .split('\n* ') .map(li => { diff --git a/lib/utils/config/definitions.js b/lib/utils/config/definitions.js index 79e686c..0f401d6 100644 --- a/lib/utils/config/definitions.js +++ b/lib/utils/config/definitions.js @@ -4,10 +4,9 @@ module.exports = definitions const Definition = require('./definition.js') const { version: npmVersion } = require('../../../package.json') -const ciDetect = require('@npmcli/ci-detect') -const ciName = ciDetect() +const ciInfo = require('ci-info') const querystring = require('querystring') -const isWindows = require('../is-windows.js') +const { isWindows } = require('../is-windows.js') const { join } = require('path') // used by cafile flattening to flatOptions.ca @@ -60,7 +59,7 @@ const buildOmitList = obj => { const editor = process.env.EDITOR || process.env.VISUAL || - (isWindows ? 'notepad.exe' : 'vi') + (isWindows ? `${process.env.SYSTEMROOT}\\notepad.exe` : 'vi') const shell = isWindows ? process.env.ComSpec || 'cmd' : process.env.SHELL || 'sh' @@ -147,6 +146,8 @@ define('_auth', { type: [null, String], description: ` A basic-auth string to use when authenticating against the npm registry. + This will ONLY be used to authenticate against the npm registry. For other + registries you will need to scope it like "//other-registry.tld/:_auth" Warning: This should generally not be set via a command-line option. It is safer to use a registry-provided authentication bearer token stored in @@ -158,21 +159,19 @@ define('_auth', { define('access', { default: null, defaultDescription: ` - 'restricted' for scoped packages, 'public' for unscoped packages + 'public' for new packages, existing packages it will not change the current level `, type: [null, 'restricted', 'public'], description: ` - When publishing scoped packages, the access level defaults to - \`restricted\`. If you want your scoped package to be publicly viewable - (and installable) set \`--access=public\`. The only valid values for - \`access\` are \`public\` and \`restricted\`. Unscoped packages _always_ - have an access level of \`public\`. + If do not want your scoped package to be publicly viewable (and + installable) set \`--access=restricted\`. - Note: Using the \`--access\` flag on the \`npm publish\` command will only - set the package access level on the initial publish of the package. Any - subsequent \`npm publish\` commands using the \`--access\` flag will not - have an effect to the access level. To make changes to the access level - after the initial publish use \`npm access\`. + Unscoped packages can not be set to \`restricted\`. + + Note: This defaults to not changing the current access level for existing + packages. Specifying a value of \`restricted\` or \`public\` during + publish will change the access for an existing package the same way that + \`npm access set status\` would. `, flatten, }) @@ -235,14 +234,10 @@ define('audit-level', { }) define('auth-type', { - default: 'legacy', - type: ['legacy', 'sso', 'saml', 'oauth'], - deprecated: ` - This method of SSO/SAML/OAuth is deprecated and will be removed in - a future version of npm in favor of web-based login. - `, + default: 'web', + type: ['legacy', 'web'], description: ` - What authentication strategy to use with \`adduser\`/\`login\`. + What authentication strategy to use with \`login\`. `, flatten, }) @@ -330,8 +325,7 @@ define('cache', { `, type: path, description: ` - The location of npm's cache directory. See [\`npm - cache\`](/commands/npm-cache) + The location of npm's cache directory. `, flatten (key, obj, flatOptions) { flatOptions.cache = join(obj.cache, '_cacache') @@ -424,14 +418,21 @@ define('cert', { cert="-----BEGIN CERTIFICATE-----\\nXXXX\\nXXXX\\n-----END CERTIFICATE-----" \`\`\` - It is _not_ the path to a certificate file (and there is no "certfile" - option). + It is _not_ the path to a certificate file, though you can set a registry-scoped + "certfile" path like "//other-registry.tld/:certfile=/path/to/cert.pem". + `, + deprecated: ` + \`key\` and \`cert\` are no longer used for most registry operations. + Use registry scoped \`keyfile\` and \`certfile\` instead. + Example: + //other-registry.tld/:keyfile=/path/to/key.pem + //other-registry.tld/:certfile=/path/to/cert.crt `, flatten, }) define('ci-name', { - default: ciName || null, + default: ciInfo.name ? ciInfo.name.toLowerCase().split(' ').join('-') : null, defaultDescription: ` The name of the current CI system, or \`null\` when not on a known CI platform. @@ -440,7 +441,7 @@ define('ci-name', { description: ` The name of a continuous integration system. If not set explicitly, npm will detect the current CI environment using the - [\`@npmcli/ci-detect\`](http://npm.im/@npmcli/ci-detect) module. + [\`ci-info\`](http://npm.im/ci-info) module. `, flatten, }) @@ -531,7 +532,7 @@ define('dev', { define('diff', { default: [], - hint: '<pkg-name|spec|version>', + hint: '<package-spec>', type: [String, Array], description: ` Define arguments to compare in \`npm diff\`. @@ -626,8 +627,8 @@ define('dry-run', { define('editor', { default: editor, defaultDescription: ` - The EDITOR or VISUAL environment variables, or 'notepad.exe' on Windows, - or 'vim' on Unix systems + The EDITOR or VISUAL environment variables, or '%SYSTEMROOT%\\notepad.exe' on Windows, + or 'vi' on Unix systems `, type: String, description: ` @@ -740,6 +741,7 @@ define('force', { * Allow conflicting peerDependencies to be installed in the root project. * Implicitly set \`--yes\` during \`npm init\`. * Allow clobbering existing values in \`npm pkg\` + * Allow unpublishing of entire packages (not just a single version). If you don't have a clear idea of what you want to do, it is strongly recommended that you do not use this option! @@ -798,7 +800,8 @@ define('git-tag-version', { default: true, type: Boolean, description: ` - Tag the commit when using the \`npm version\` command. + Tag the commit when using the \`npm version\` command. Setting this to + false results in no commit being made at all. `, flatten, }) @@ -826,20 +829,6 @@ define('global', { }, }) -define('global-style', { - default: false, - type: Boolean, - description: ` - Causes npm to install the package into your local \`node_modules\` folder - with the same layout it uses with the global \`node_modules\` folder. - Only your direct dependencies will show in \`node_modules\` and - everything they depend on will be flattened in their \`node_modules\` - folders. This obviously will eliminate some deduping. If used with - \`legacy-bundling\`, \`legacy-bundling\` will be preferred. - `, - flatten, -}) - // the globalconfig has its default defined outside of this module define('globalconfig', { type: path, @@ -854,6 +843,25 @@ define('globalconfig', { flatten, }) +define('global-style', { + default: false, + type: Boolean, + description: ` + Only install direct dependencies in the top level \`node_modules\`, + but hoist on deeper dependendencies. + Sets \`--install-strategy=shallow\`. + `, + deprecated: ` + This option has been deprecated in favor of \`--install-strategy=shallow\` + `, + flatten (key, obj, flatOptions) { + if (obj[key]) { + obj['install-strategy'] = 'shallow' + flatOptions.installStrategy = 'shallow' + } + }, +}) + define('heading', { default: 'npm', type: String, @@ -878,6 +886,7 @@ define('https-proxy', { define('if-present', { default: false, type: Boolean, + envExport: false, description: ` 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 @@ -936,6 +945,7 @@ define('include-staged', { define('include-workspace-root', { default: false, type: Boolean, + envExport: false, description: ` Include the workspace root when workspaces are enabled for a command. @@ -1066,6 +1076,32 @@ define('init.version', { `, }) +define('install-links', { + default: true, + type: Boolean, + description: ` + When set file: protocol dependencies will be packed and installed as + regular dependencies instead of creating a symlink. This option has + no effect on workspaces. + `, + flatten, +}) + +define('install-strategy', { + default: 'hoisted', + type: ['hoisted', 'nested', 'shallow'], + description: ` + Sets the strategy for installing packages in node_modules. + hoisted (default): Install non-duplicated in top-level, and duplicated as + necessary within directory structure. + nested: (formerly --legacy-bundling) install in place, no hoisting. + shallow (formerly --global-style) only install direct deps at top-level. + linked: (coming soon) install in node_modules/.store, link in place, + unhoisted. + `, + flatten, +}) + define('json', { default: false, type: Boolean, @@ -1091,7 +1127,15 @@ define('key', { key="-----BEGIN PRIVATE KEY-----\\nXXXX\\nXXXX\\n-----END PRIVATE KEY-----" \`\`\` - It is _not_ the path to a key file (and there is no "keyfile" option). + It is _not_ the path to a key file, though you can set a registry-scoped + "keyfile" path like "//other-registry.tld/:keyfile=/path/to/key.pem". + `, + deprecated: ` + \`key\` and \`cert\` are no longer used for most registry operations. + Use registry scoped \`keyfile\` and \`certfile\` instead. + Example: + //other-registry.tld/:keyfile=/path/to/key.pem + //other-registry.tld/:certfile=/path/to/cert.crt `, flatten, }) @@ -1100,12 +1144,21 @@ define('legacy-bundling', { default: false, type: Boolean, description: ` - Causes npm to install the package such that versions of npm prior to 1.4, - such as the one included with node 0.8, can install the package. This - eliminates all automatic deduping. If used with \`global-style\` this - option will be preferred. + Instead of hoisting package installs in \`node_modules\`, install packages + in the same manner that they are depended on. This may cause very deep + directory structures and duplicate package installs as there is no + de-duplicating. + Sets \`--install-strategy=nested\`. `, - flatten, + deprecated: ` + This option has been deprecated in favor of \`--install-strategy=nested\` + `, + flatten (key, obj, flatOptions) { + if (obj[key]) { + obj['install-strategy'] = 'nested' + flatOptions.installStrategy = 'nested' + } + }, }) define('legacy-peer-deps', { @@ -1162,12 +1215,24 @@ define('location', { `, description: ` When passed to \`npm config\` this refers to which config file to use. + + When set to "global" mode, packages are installed into the \`prefix\` folder + instead of the current working directory. See + [folders](/configuring-npm/folders) for more on the differences in behavior. + + * packages are installed into the \`{prefix}/lib/node_modules\` folder, + instead of the current working directory. + * bin files are linked to \`{prefix}/bin\` + * man pages are linked to \`{prefix}/share/man\` `, flatten: (key, obj, flatOptions) => { flatten(key, obj, flatOptions) if (flatOptions.global) { flatOptions.location = 'global' } + if (obj.location === 'global') { + flatOptions.global = true + } }, }) @@ -1175,9 +1240,8 @@ define('lockfile-version', { default: null, type: [null, 1, 2, 3, '1', '2', '3'], defaultDescription: ` - Version 2 if no lockfile or current lockfile version less than or equal to - 2, otherwise maintain current lockfile version - `, + Version 3 if no lockfile, auto-converting v1 lockfiles to v3, otherwise + maintain current lockfile version.`, description: ` Set the lockfile format version to be used in package-lock.json and npm-shrinkwrap-json files. Possible options are: @@ -1187,8 +1251,8 @@ define('lockfile-version', { deterministic installs. Prevents lockfile churn when interoperating with older npm versions. - 2: The default lockfile version used by npm version 7. Includes both the - version 1 lockfile data and version 3 lockfile data, for maximum + 2: The default lockfile version used by npm version 7 and 8. Includes both + the version 1 lockfile data and version 3 lockfile data, for maximum determinism and interoperability, at the expense of more bytes on disk. 3: Only the new lockfile information introduced in npm version 7. Smaller @@ -1208,7 +1272,6 @@ define('loglevel', { 'warn', 'notice', 'http', - 'timing', 'info', 'verbose', 'silly', @@ -1222,6 +1285,21 @@ define('loglevel', { See also the \`foreground-scripts\` config. `, + flatten (key, obj, flatOptions) { + flatOptions.silent = obj[key] === 'silent' + }, +}) + +define('logs-dir', { + default: null, + type: [null, path], + defaultDescription: ` + A directory named \`_logs\` inside the cache +`, + description: ` + The location of npm's log directory. See [\`npm + logging\`](/using-npm/logging) for more information. + `, }) define('logs-max', { @@ -1229,6 +1307,8 @@ define('logs-max', { type: Number, description: ` The maximum number of log files to store. + + If set to 0, no log files will be written for the current run. `, }) @@ -1275,16 +1355,6 @@ define('node-options', { `, }) -define('node-version', { - default: process.version, - defaultDescription: 'Node.js `process.version` value', - type: semver, - description: ` - The node version to use when checking a package's \`engines\` setting. - `, - flatten, -}) - define('noproxy', { default: '', defaultDescription: ` @@ -1305,16 +1375,6 @@ define('noproxy', { }, }) -define('npm-version', { - default: npmVersion, - defaultDescription: 'Output of `npm --version`', - type: semver, - description: ` - The npm version to use when checking a package's \`engines\` setting. - `, - flatten, -}) - define('offline', { default: false, type: Boolean, @@ -1351,6 +1411,18 @@ define('omit', { }, }) +define('omit-lockfile-registry-resolved', { + default: false, + type: Boolean, + description: ` + This option causes npm to create lock files without a \`resolved\` key for + registry dependencies. Subsequent installs will need to resolve tarball + endpoints with the configured registry, likely resulting in a longer install + time. + `, + flatten, +}) + define('only', { default: null, type: [null, 'prod', 'production'], @@ -1398,10 +1470,10 @@ define('otp', { define('package', { default: [], - hint: '<pkg>[@<version>]', + hint: '<package-spec>', type: [String, Array], description: ` - The package to install for [\`npm exec\`](/commands/npm-exec) + The package or packages to install for [\`npm exec\`](/commands/npm-exec) `, flatten, }) @@ -1414,10 +1486,6 @@ define('package-lock', { This will also prevent _writing_ \`package-lock.json\` if \`save\` is true. - When package package-locks are disabled, automatic pruning of extraneous - modules will also be disabled. To remove extraneous modules with - package-locks disabled use \`npm prune\`. - This configuration does not affect \`npm ci\`. `, flatten: (key, obj, flatOptions) => { @@ -1496,8 +1564,8 @@ define('prefix', { short: 'C', default: '', defaultDescription: ` - In global mode, the folder where the node executable is installed. In - local mode, the nearest parent folder containing either a package.json + In global mode, the folder where the node executable is installed. + Otherwise, the nearest parent folder containing either a package.json file or a node_modules folder. `, description: ` @@ -1528,7 +1596,7 @@ define('production', { }) define('progress', { - default: !ciName, + default: !ciInfo.isCI, defaultDescription: ` \`true\` unless running in a known CI system `, @@ -1584,10 +1652,28 @@ define('registry', { flatten, }) +define('replace-registry-host', { + default: 'npmjs', + hint: '<npmjs|never|always> | hostname', + type: ['npmjs', 'never', 'always', String], + description: ` + Defines behavior for replacing the registry host in a lockfile with the + configured registry. + + The default behavior is to replace package dist URLs from the default + registry (https://registry.npmjs.org) to the configured registry. If set to + "never", then use the registry value. If set to "always", then replace the + registry host with the configured host every time. + + You may also specify a bare hostname (e.g., "registry.npmjs.org"). + `, + flatten, +}) + define('save', { default: true, - defaultDescription: `\`true\` unless when using \`npm update\` or - \`npm dedupe\` where it defaults to \`false\``, + defaultDescription: `\`true\` unless when using \`npm update\` where it + defaults to \`false\``, usage: '-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle', type: Boolean, short: 'S', @@ -1811,7 +1897,7 @@ define('script-shell', { type: [null, String], description: ` The shell to use for scripts run with the \`npm exec\`, - \`npm run\` and \`npm init <pkg>\` commands. + \`npm run\` and \`npm init <package-spec>\` commands. `, flatten (key, obj, flatOptions) { flatOptions.scriptShell = obj[key] || undefined @@ -1826,7 +1912,7 @@ define('searchexclude', { `, flatten (key, obj, flatOptions) { flatOptions.search = flatOptions.search || { limit: 20 } - flatOptions.search.exclude = obj[key] + flatOptions.search.exclude = obj[key].toLowerCase() }, }) @@ -1921,33 +2007,6 @@ define('sign-git-tag', { flatten, }) -define('sso-poll-frequency', { - default: 500, - type: Number, - deprecated: ` - The --auth-type method of SSO/SAML/OAuth will be removed in a future - version of npm in favor of web-based login. - `, - description: ` - When used with SSO-enabled \`auth-type\`s, configures how regularly the - registry should be polled while the user is completing authentication. - `, - flatten, -}) - -define('sso-type', { - default: 'oauth', - type: [null, 'oauth', 'saml'], - deprecated: ` - The --auth-type method of SSO/SAML/OAuth will be removed in a future - version of npm in favor of web-based login. - `, - description: ` - If \`--auth-type=sso\`, the type of SSO type to use. - `, - flatten, -}) - define('strict-peer-deps', { default: false, type: Boolean, @@ -2006,7 +2065,7 @@ define('tag-version-prefix', { type: String, description: ` If set, alters the prefix used when tagging a new version when performing - a version increment using \`npm-version\`. To remove the prefix + a version increment using \`npm version\`. To remove the prefix altogether, set it to the empty string: \`""\`. Because other tools may rely on the convention that npm version tags look @@ -2020,13 +2079,14 @@ define('timing', { default: false, type: Boolean, description: ` - If true, writes an \`npm-debug\` log to \`_logs\` and timing information - to \`_timing.json\`, both in your cache, even if the command completes - successfully. \`_timing.json\` is a newline delimited list of JSON - objects. + If true, writes timing information to a process specific json file in + the cache or \`logs-dir\`. The file name ends with \`-timing.json\`. You can quickly view it with this [json](https://npm.im/json) command - line: \`npm exec -- json -g < ~/.npm/_timing.json\`. + line: \`cat ~/.npm/_logs/*-timing.json | npm exec -- json -g\`. + + Timing information will also be reported in the terminal. To suppress this + while still writing the timing file, use \`--silent\`. `, }) @@ -2130,8 +2190,8 @@ define('user-agent', { inWorkspaces = true } flatOptions.userAgent = - value.replace(/\{node-version\}/gi, obj['node-version']) - .replace(/\{npm-version\}/gi, obj['npm-version']) + value.replace(/\{node-version\}/gi, process.version) + .replace(/\{npm-version\}/gi, npmVersion) .replace(/\{platform\}/gi, process.platform) .replace(/\{arch\}/gi, process.arch) .replace(/\{workspaces\}/gi, inWorkspaces) @@ -2265,6 +2325,16 @@ define('workspaces', { }, }) +define('workspaces-update', { + default: true, + type: Boolean, + description: ` + If set to true, the npm cli will run an update after operations that may + possibly change the workspaces installed to the \`node_modules\` folder. + `, + flatten, +}) + define('yes', { default: null, type: [null, Boolean], diff --git a/lib/utils/config/describe-all.js b/lib/utils/config/describe-all.js deleted file mode 100644 index 39f8d5f..0000000 --- a/lib/utils/config/describe-all.js +++ /dev/null @@ -1,20 +0,0 @@ -const definitions = require('./definitions.js') -const localeCompare = require('@isaacs/string-locale-compare')('en') -const describeAll = () => { - // sort not-deprecated ones to the top - /* istanbul ignore next - typically already sorted in the definitions file, - * but this is here so that our help doc will stay consistent if we decide - * to move them around. */ - const sort = ([keya, { deprecated: depa }], [keyb, { deprecated: depb }]) => { - return depa && !depb ? 1 - : !depa && depb ? -1 - : localeCompare(keya, keyb) - } - return Object.entries(definitions).sort(sort) - .map(([key, def]) => def.describe()) - .join( - '\n\n<!-- automatically generated, do not edit manually -->\n' + - '<!-- see lib/utils/config/definitions.js -->\n\n' - ) -} -module.exports = describeAll diff --git a/lib/utils/config/index.js b/lib/utils/config/index.js index d8706d5..d393aec 100644 --- a/lib/utils/config/index.js +++ b/lib/utils/config/index.js @@ -1,6 +1,35 @@ -const flatten = require('./flatten.js') const definitions = require('./definitions.js') -const describeAll = require('./describe-all.js') + +// use the defined flattening function, and copy over any scoped +// registries and registry-specific "nerfdart" configs verbatim +// +// TODO: make these getters so that we only have to make dirty +// the thing that changed, and then flatten the fields that +// could have changed when a config.set is called. +// +// TODO: move nerfdart auth stuff into a nested object that +// is only passed along to paths that end up calling npm-registry-fetch. +const flatten = (obj, flat = {}) => { + for (const [key, val] of Object.entries(obj)) { + const def = definitions[key] + if (def && def.flatten) { + def.flatten(key, obj, flat) + } else if (/@.*:registry$/i.test(key) || /^\/\//.test(key)) { + flat[key] = val + } + } + + // XXX make this the bin/npm-cli.js file explicitly instead + // otherwise using npm programmatically is a bit of a pain. + flat.npmBin = require.main ? require.main.filename + : /* istanbul ignore next - not configurable property */ undefined + flat.nodeBin = process.env.NODE || process.execPath + + // XXX should this be sha512? is it even relevant? + flat.hashAlgorithm = 'sha1' + + return flat +} // aliases where they get expanded into a completely different thing // these are NOT supported in the environment or npmrc files, only @@ -25,30 +54,25 @@ const shorthands = { porcelain: ['--parseable'], readonly: ['--read-only'], reg: ['--registry'], -} - -for (const [key, { short }] of Object.entries(definitions)) { - if (!short) { - continue - } - // can be either an array or string - for (const s of [].concat(short)) { - shorthands[s] = [`--${key}`] - } + iwr: ['--include-workspace-root'], + ...Object.entries(definitions).reduce((acc, [key, { short = [] }]) => { + // can be either an array or string + for (const s of [].concat(short)) { + acc[s] = [`--${key}`] + } + return acc + }, {}), } module.exports = { get defaults () { // NB: 'default' is a reserved word - return Object.entries(definitions).map(([key, { default: def }]) => { - return [key, def] - }).reduce((defaults, [key, def]) => { - defaults[key] = def - return defaults + return Object.entries(definitions).reduce((acc, [key, { default: d }]) => { + acc[key] = d + return acc }, {}) }, definitions, flatten, shorthands, - describeAll, } diff --git a/lib/utils/deref-command.js b/lib/utils/deref-command.js deleted file mode 100644 index 0a3c8c9..0000000 --- a/lib/utils/deref-command.js +++ /dev/null @@ -1,31 +0,0 @@ -// de-reference abbreviations and shorthands into canonical command name - -const { aliases, cmdList, plumbing } = require('./cmd-list.js') -const aliasNames = Object.keys(aliases) -const fullList = cmdList.concat(aliasNames).filter(c => !plumbing.includes(c)) -const abbrev = require('abbrev') -const abbrevs = abbrev(fullList) - -module.exports = c => { - if (!c || typeof c !== 'string') { - return '' - } - - if (c.match(/[A-Z]/)) { - c = c.replace(/([A-Z])/g, m => '-' + m.toLowerCase()) - } - - if (plumbing.indexOf(c) !== -1) { - return c - } - - // first deref the abbrev, if there is one - // then resolve any aliases - // so `npm install-cl` will resolve to `install-clean` then to `ci` - let a = abbrevs[c] - while (aliases[a]) { - a = aliases[a] - } - - return a || '' -} diff --git a/lib/utils/did-you-mean.js b/lib/utils/did-you-mean.js index b859aba..10b33d5 100644 --- a/lib/utils/did-you-mean.js +++ b/lib/utils/did-you-mean.js @@ -1,10 +1,10 @@ const { distance } = require('fastest-levenshtein') const readJson = require('read-package-json-fast') -const { cmdList } = require('./cmd-list.js') +const { commands } = require('./cmd-list.js') const didYouMean = async (npm, path, scmd) => { // const cmd = await npm.cmd(str) - const close = cmdList.filter(cmd => distance(scmd, cmd) < scmd.length * 0.4 && scmd !== cmd) + const close = commands.filter(cmd => distance(scmd, cmd) < scmd.length * 0.4 && scmd !== cmd) let best = [] for (const str of close) { const cmd = await npm.cmd(str) diff --git a/lib/utils/display.js b/lib/utils/display.js index aae51e8..35d221c 100644 --- a/lib/utils/display.js +++ b/lib/utils/display.js @@ -3,11 +3,6 @@ const npmlog = require('npmlog') const log = require('./log-shim.js') const { explain } = require('./explain-eresolve.js') -const _logHandler = Symbol('logHandler') -const _eresolveWarn = Symbol('eresolveWarn') -const _log = Symbol('log') -const _npmlog = Symbol('npmlog') - class Display { constructor () { // pause by default until config is loaded @@ -16,11 +11,11 @@ class Display { } on () { - process.on('log', this[_logHandler]) + process.on('log', this.#logHandler) } off () { - process.off('log', this[_logHandler]) + process.off('log', this.#logHandler) // Unbalanced calls to enable/disable progress // will leave change listeners on the tracker // This pretty much only happens in tests but @@ -35,16 +30,24 @@ class Display { loglevel, unicode, progress, + silent, heading = 'npm', } = config - // XXX: decouple timing from loglevel - if (timing && loglevel === 'notice') { - log.level = 'timing' - } else { - log.level = loglevel - } + // npmlog is still going away someday, so this is a hack to dynamically + // set the loglevel of timing based on the timing flag, instead of making + // a breaking change to npmlog. The result is that timing logs are never + // shown except when the --timing flag is set. We also need to change + // the index of the silly level since otherwise it is set to -Infinity + // and we can't go any lower than that. silent is still set to Infinify + // because we DO want silent to hide timing levels. This allows for the + // special case of getting timing information while hiding all CLI output + // in order to get perf information that might be affected by writing to + // a terminal. XXX(npmlog): this will be removed along with npmlog + log.levels.silly = -10000 + log.levels.timing = log.levels[loglevel] + (timing ? 1 : -1) + log.level = loglevel log.heading = heading if (color) { @@ -59,8 +62,7 @@ class Display { log.disableUnicode() } - // if it's more than error, don't show progress - const silent = log.levels[log.level] > log.levels.error + // if it's silent, don't show progress if (progress && !silent) { log.enableProgress() } else { @@ -72,16 +74,16 @@ class Display { } log (...args) { - this[_logHandler](...args) + this.#logHandler(...args) } - [_logHandler] = (level, ...args) => { + #logHandler = (level, ...args) => { try { - this[_log](level, ...args) + this.#log(level, ...args) } catch (ex) { try { // if it crashed once, it might again! - this[_npmlog]('verbose', `attempt to log ${inspect(args)} crashed`, ex) + this.#npmlog('verbose', `attempt to log ${inspect(args)} crashed`, ex) } catch (ex2) { // eslint-disable-next-line no-console console.error(`attempt to log ${inspect(args)} crashed`, ex, ex2) @@ -89,13 +91,13 @@ class Display { } } - [_log] (...args) { - return this[_eresolveWarn](...args) || this[_npmlog](...args) + #log (...args) { + return this.#eresolveWarn(...args) || this.#npmlog(...args) } // Explicitly call these on npmlog and not log shim // This is the final place we should call npmlog before removing it. - [_npmlog] (level, ...args) { + #npmlog (level, ...args) { npmlog[level](...args) } @@ -103,13 +105,13 @@ class Display { // log.warn() method so that when we see a peerDep override // explanation from Arborist, we can replace the object with a // highly abbreviated explanation of what's being overridden. - [_eresolveWarn] (level, heading, message, expl) { + #eresolveWarn (level, heading, message, expl) { if (level === 'warn' && heading === 'ERESOLVE' && expl && typeof expl === 'object' ) { - this[_npmlog](level, heading, message) - this[_npmlog](level, '', explain(expl, log.useColor(), 2)) + this.#npmlog(level, heading, message) + this.#npmlog(level, '', explain(expl, log.useColor(), 2)) // Return true to short circuit other log in chain return true } diff --git a/lib/utils/error-message.js b/lib/utils/error-message.js index 4d58434..aee3761 100644 --- a/lib/utils/error-message.js +++ b/lib/utils/error-message.js @@ -8,6 +8,7 @@ const log = require('./log-shim') module.exports = (er, npm) => { const short = [] const detail = [] + const files = [] if (er.message) { er.message = replaceInfo(er.message) @@ -17,14 +18,17 @@ module.exports = (er, npm) => { } switch (er.code) { - case 'ERESOLVE': + case 'ERESOLVE': { short.push(['ERESOLVE', er.message]) detail.push(['', '']) // XXX(display): error messages are logged so we use the logColor since that is based // on stderr. This should be handled solely by the display layer so it could also be // printed to stdout if necessary. - detail.push(['', report(er, !!npm.logColor, resolve(npm.cache, 'eresolve-report.txt'))]) + const { explanation, file } = report(er, !!npm.logColor) + detail.push(['', explanation]) + files.push(['eresolve-report.txt', file]) break + } case 'ENOLOCK': { const cmd = npm.command || '' @@ -60,7 +64,7 @@ module.exports = (er, npm) => { npm.config.loaded && er.dest.startsWith(npm.config.get('cache')) - const isWindows = require('./is-windows.js') + const { isWindows } = require('./is-windows.js') if (!isWindows && (isCachePath || isCacheDest)) { // user probably doesn't need this, but still add it to the debug log @@ -199,12 +203,7 @@ module.exports = (er, npm) => { const valResult = nameValidator(pkg) - if (valResult.validForNewPackages) { - detail.push([ - '404', - 'You should bug the author to publish it (or use the name yourself!)', - ]) - } else { + if (!valResult.validForNewPackages) { detail.push(['404', 'This package name is not valid, because', '']) const errorsArray = [...(valResult.errors || []), ...(valResult.warnings || [])] @@ -403,5 +402,5 @@ module.exports = (er, npm) => { break } - return { summary: short, detail: detail } + return { summary: short, detail, files } } diff --git a/lib/utils/exit-handler.js b/lib/utils/exit-handler.js index 22c7741..a9e061d 100644 --- a/lib/utils/exit-handler.js +++ b/lib/utils/exit-handler.js @@ -1,14 +1,16 @@ const os = require('os') -const log = require('./log-shim.js') +const fs = require('fs') +const log = require('./log-shim.js') const errorMessage = require('./error-message.js') const replaceInfo = require('./replace-info.js') const messageText = msg => msg.map(line => line.slice(1).join(' ')).join('\n') +const indent = (val) => Array.isArray(val) ? val.map(v => indent(v)) : ` ${val}` let npm = null // set by the cli let exitHandlerCalled = false -let showLogFileMessage = false +let showLogFileError = false process.on('exit', code => { log.disableProgress() @@ -17,11 +19,10 @@ process.on('exit', code => { // unfinished timer check below process.emit('timeEnd', 'npm') - const hasNpm = !!npm - const hasLoadedNpm = hasNpm && npm.config.loaded + const hasLoadedNpm = npm?.config.loaded // Unfinished timers can be read before config load - if (hasNpm) { + if (npm) { for (const [name, timer] of npm.unfinishedTimers) { log.verbose('unfinished npm timer', name, timer) } @@ -36,42 +37,73 @@ process.on('exit', code => { if (!exitHandlerCalled) { process.exitCode = code || 1 log.error('', 'Exit handler never called!') + // eslint-disable-next-line no-console console.error('') log.error('', 'This is an error with npm itself. Please report this error at:') log.error('', ' <https://github.com/npm/cli/issues>') - showLogFileMessage = true - } - - // In timing mode we always show the log file message - if (hasLoadedNpm && npm.config.get('timing')) { - showLogFileMessage = true + showLogFileError = true } // npm must be loaded to know where the log file was written - if (showLogFileMessage && hasLoadedNpm) { - // just a line break - if (log.levels[log.level] <= log.levels.error) { - console.error('') + if (hasLoadedNpm) { + // write the timing file now, this might do nothing based on the configs set. + // we need to call it here in case it errors so we dont tell the user + // about a timing file that doesn't exist + npm.writeTimingFile() + + const logsDir = npm.logsDir + const logFiles = npm.logFiles + + const timingDir = npm.timingDir + const timingFile = npm.timingFile + + const timing = npm.config.get('timing') + const logsMax = npm.config.get('logs-max') + + // Determine whether to show log file message and why it is + // being shown since in timing mode we always show the log file message + const logMethod = showLogFileError ? 'error' : timing ? 'info' : null + + if (logMethod) { + if (!npm.silent) { + // just a line break if not in silent mode + // eslint-disable-next-line no-console + console.error('') + } + + const message = [] + + if (timingFile) { + message.push('Timing info written to:', indent(timingFile)) + } else if (timing) { + message.push( + `The timing file was not written due to an error writing to the directory: ${timingDir}` + ) + } + + if (logFiles.length) { + message.push('A complete log of this run can be found in:', ...indent(logFiles)) + } else if (logsMax <= 0) { + // user specified no log file + message.push(`Log files were not written due to the config logs-max=${logsMax}`) + } else { + // could be an error writing to the directory + message.push( + `Log files were not written due to an error writing to the directory: ${logsDir}`, + 'You can rerun the command with `--loglevel=verbose` to see the logs in your terminal' + ) + } + + log[logMethod]('', message.join('\n')) } - log.error( - '', - [ - 'A complete log of this run can be found in:', - ...npm.logFiles.map(f => ' ' + f), - ].join('\n') - ) - } - - // This removes any listeners npm setup and writes files if necessary - // This is mostly used for tests to avoid max listener warnings - if (hasLoadedNpm) { + // This removes any listeners npm setup, mostly for tests to avoid max listener warnings npm.unload() } // these are needed for the tests to have a clean slate in each test case exitHandlerCalled = false - showLogFileMessage = false + showLogFileError = false }) const exitHandler = err => { @@ -79,17 +111,18 @@ const exitHandler = err => { log.disableProgress() - const hasNpm = !!npm - const hasLoadedNpm = hasNpm && npm.config.loaded + const hasLoadedNpm = npm?.config.loaded - if (!hasNpm) { + if (!npm) { err = err || new Error('Exit prior to setting npm in exit handler') + // eslint-disable-next-line no-console console.error(err.stack || err.message) return process.exit(1) } if (!hasLoadedNpm) { err = err || new Error('Exit prior to config file resolving.') + // eslint-disable-next-line no-console console.error(err.stack || err.message) } @@ -103,6 +136,7 @@ const exitHandler = err => { let exitCode let noLogMessage + let jsonError if (err) { exitCode = 1 @@ -110,7 +144,7 @@ const exitHandler = err => { // will presumably print its own errors and exit with a proper status // code if there's a problem. If we got an error with a code=0, then... // something else went wrong along the way, so maybe an npm problem? - const isShellout = npm.shelloutCommands.includes(npm.command) + const isShellout = npm.commandInstance && npm.commandInstance.constructor.isShellout const quietShellout = isShellout && typeof err.code === 'number' && err.code if (quietShellout) { exitCode = err.code @@ -135,10 +169,8 @@ const exitHandler = err => { } } - const args = replaceInfo(process.argv) log.verbose('cwd', process.cwd()) log.verbose('', os.type() + ' ' + os.release()) - log.verbose('argv', args.map(JSON.stringify).join(' ')) log.verbose('node', process.version) log.verbose('npm ', 'v' + npm.version) @@ -149,20 +181,31 @@ const exitHandler = err => { } } - const msg = errorMessage(err, npm) - for (const errline of [...msg.summary, ...msg.detail]) { + const { summary, detail, files = [] } = errorMessage(err, npm) + + for (let [file, content] of files) { + file = `${npm.logPath}${file}` + content = `'Log files:\n${npm.logFiles.join('\n')}\n\n${content.trim()}\n` + try { + fs.writeFileSync(file, content) + detail.push(['', `\n\nFor a full report see:\n${file}`]) + } catch (err) { + log.warn('', `Could not write error message to ${file} due to ${err}`) + } + } + + for (const errline of [...summary, ...detail]) { log.error(...errline) } if (hasLoadedNpm && npm.config.get('json')) { - const error = { + jsonError = { error: { code: err.code, - summary: messageText(msg.summary), - detail: messageText(msg.detail), + summary: messageText(summary), + detail: messageText(detail), }, } - console.error(JSON.stringify(error, null, 2)) } if (typeof err.errno === 'number') { @@ -173,19 +216,24 @@ const exitHandler = err => { } } + if (hasLoadedNpm) { + npm.flushOutput(jsonError) + } + log.verbose('exit', exitCode || 0) - showLogFileMessage = log.level === 'silent' || noLogMessage + showLogFileError = (hasLoadedNpm && npm.silent) || noLogMessage ? false : !!exitCode // explicitly call process.exit now so we don't hang on things like the - // update notifier, also flush stdout beforehand because process.exit doesn't + // update notifier, also flush stdout/err beforehand because process.exit doesn't // wait for that to happen. - process.stdout.write('', () => process.exit(exitCode)) + let flushed = 0 + const flush = [process.stderr, process.stdout] + const exit = () => ++flushed === flush.length && process.exit(exitCode) + flush.forEach((f) => f.write('', exit)) } module.exports = exitHandler -module.exports.setNpm = n => { - npm = n -} +module.exports.setNpm = n => (npm = n) diff --git a/lib/utils/explain-dep.js b/lib/utils/explain-dep.js index 107f685..cd53a22 100644 --- a/lib/utils/explain-dep.js +++ b/lib/utils/explain-dep.js @@ -8,6 +8,7 @@ const nocolor = { magenta: s => s, blue: s => s, green: s => s, + gray: s => s, } const { relative } = require('path') @@ -18,13 +19,14 @@ const explainNode = (node, depth, color) => explainLinksIn(node, depth, color) const colorType = (type, color) => { - const { red, yellow, cyan, magenta, blue, green } = color ? chalk : nocolor + const { red, yellow, cyan, magenta, blue, green, gray } = color ? chalk : nocolor const style = type === 'extraneous' ? red : type === 'dev' ? yellow : type === 'optional' ? cyan : type === 'peer' ? magenta : type === 'bundled' ? blue : type === 'workspace' ? green + : type === 'overridden' ? gray : /* istanbul ignore next */ s => s return style(type) } @@ -40,6 +42,7 @@ const printNode = (node, color) => { peer, bundled, isWorkspace, + overridden, } = node const { bold, dim, green } = color ? chalk : nocolor const extra = [] @@ -63,6 +66,10 @@ const printNode = (node, color) => { extra.push(' ' + bold(colorType('bundled', color))) } + if (overridden) { + extra.push(' ' + bold(colorType('overridden', color))) + } + const pkgid = isWorkspace ? green(`${name}@${version}`) : `${bold(name)}@${bold(version)}` @@ -112,11 +119,15 @@ const explainDependents = ({ name, dependents }, depth, color) => { return str.split('\n').join('\n ') } -const explainEdge = ({ name, type, bundled, from, spec }, depth, color) => { +const explainEdge = ({ name, type, bundled, from, spec, rawSpec, overridden }, depth, color) => { const { bold } = color ? chalk : nocolor - const dep = type === 'workspace' + let dep = type === 'workspace' ? bold(relative(from.location, spec.slice('file:'.length))) : `${bold(name)}@"${bold(spec)}"` + if (overridden) { + dep = `${colorType('overridden', color)} ${dep} (was "${rawSpec}")` + } + const fromMsg = ` from ${explainFrom(from, depth, color)}` return (type === 'prod' ? '' : `${colorType(type, color)} `) + diff --git a/lib/utils/explain-eresolve.js b/lib/utils/explain-eresolve.js index 7f6a108..480cd8e 100644 --- a/lib/utils/explain-eresolve.js +++ b/lib/utils/explain-eresolve.js @@ -1,7 +1,6 @@ // this is called when an ERESOLVE error is caught in the exit-handler, // or when there's a log.warn('eresolve', msg, explanation), to turn it // into a human-intelligible explanation of what's wrong and how to fix. -const { writeFileSync } = require('fs') const { explainEdge, explainNode, printNode } = require('./explain-dep.js') // expl is an explanation object that comes from Arborist. It looks like: @@ -45,27 +44,25 @@ const explain = (expl, color, depth) => { } // generate a full verbose report and tell the user how to fix it -const report = (expl, color, fullReport) => { - const orNoStrict = expl.strictPeerDeps ? '--no-strict-peer-deps, ' : '' +const report = (expl, color) => { + const flags = [ + expl.strictPeerDeps ? '--no-strict-peer-deps' : '', + '--force', + '--legacy-peer-deps', + ].filter(Boolean) + + const or = (arr) => arr.length <= 2 + ? arr.join(' or ') : + arr.map((v, i, l) => i + 1 === l.length ? `or ${v}` : v).join(', ') + const fix = `Fix the upstream dependency conflict, or retry -this command with ${orNoStrict}--force, or --legacy-peer-deps +this command with ${or(flags)} to accept an incorrect (and potentially broken) dependency resolution.` - writeFileSync(fullReport, `# npm resolution error report - -${new Date().toISOString()} - -${explain(expl, false, Infinity)} - -${fix} - -Raw JSON explanation object: - -${JSON.stringify(expl, null, 2)} -`, 'utf8') - - return explain(expl, color, 4) + - `\n\n${fix}\n\nSee ${fullReport} for a full report.` + return { + explanation: `${explain(expl, color, 4)}\n\n${fix}`, + file: `# npm resolution error report\n\n${explain(expl, false, Infinity)}\n\n${fix}`, + } } module.exports = { diff --git a/lib/utils/file-exists.js b/lib/utils/file-exists.js deleted file mode 100644 index 6054725..0000000 --- a/lib/utils/file-exists.js +++ /dev/null @@ -1,10 +0,0 @@ -const fs = require('fs') -const util = require('util') - -const stat = util.promisify(fs.stat) - -const fileExists = (file) => stat(file) - .then((stat) => stat.isFile()) - .catch(() => false) - -module.exports = fileExists diff --git a/lib/utils/format-bytes.js b/lib/utils/format-bytes.js index d7cf6d1..d293001 100644 --- a/lib/utils/format-bytes.js +++ b/lib/utils/format-bytes.js @@ -23,6 +23,7 @@ const formatBytes = (bytes, space = true) => { return `${(bytes / 1000000).toFixed(1)}${spacer}MB` } + // GB return `${(bytes / 1000000000).toFixed(1)}${spacer}GB` } diff --git a/lib/search/format-package-stream.js b/lib/utils/format-search-stream.js similarity index 67% rename from lib/search/format-package-stream.js rename to lib/utils/format-search-stream.js index 7ff44e9..2a2dadd 100644 --- a/lib/search/format-package-stream.js +++ b/lib/utils/format-search-stream.js @@ -1,6 +1,3 @@ -// XXX these output classes should not live in here forever. it'd be good to -// split them out, perhaps to libnpmsearch - const Minipass = require('minipass') const columnify = require('columnify') @@ -18,32 +15,26 @@ const columnify = require('columnify') // The returned stream will format this package data // into a byte stream of formatted, displayable output. -module.exports = (opts = {}) => - opts.json ? new JSONOutputStream() : new TextOutputStream(opts) +module.exports = (opts) => { + return opts.json ? new JSONOutputStream() : new TextOutputStream(opts) +} class JSONOutputStream extends Minipass { - constructor () { - super() - this._didFirst = false - } + #didFirst = false write (obj) { - if (!this._didFirst) { + if (!this.#didFirst) { super.write('[\n') - this._didFirst = true + this.#didFirst = true } else { super.write('\n,\n') } - try { - return super.write(JSON.stringify(obj)) - } catch (er) { - return this.emit('error', er) - } + return super.write(JSON.stringify(obj)) } end () { - super.write(this._didFirst ? ']\n' : '\n[]\n') + super.write(this.#didFirst ? ']\n' : '\n[]\n') super.end() } } @@ -61,14 +52,11 @@ class TextOutputStream extends Minipass { } function prettify (data, num, opts) { - opts = opts || {} var truncate = !opts.long var pkg = normalizePackage(data, opts) - var columns = opts.description - ? ['name', 'description', 'author', 'date', 'version', 'keywords'] - : ['name', 'author', 'date', 'version', 'keywords'] + var columns = ['name', 'description', 'author', 'date', 'version', 'keywords'] if (opts.parseable) { return columns.map(function (col) { @@ -76,7 +64,10 @@ function prettify (data, num, opts) { }).join('\t') } - var output = columnify( + // stdout in tap is never a tty + /* istanbul ignore next */ + const maxWidth = process.stdout.isTTY ? process.stdout.getWindowSize()[0] : Infinity + let output = columnify( [pkg], { include: columns, @@ -92,8 +83,8 @@ function prettify (data, num, opts) { keywords: { maxWidth: Infinity }, }, } - ) - output = trimToMaxWidth(output) + ).split('\n').map(line => line.slice(0, maxWidth)).join('\n') + if (opts.color) { output = highlightSearchTerms(output, opts.args) } @@ -111,7 +102,7 @@ function addColorMarker (str, arg, i) { if (arg.charAt(0) === '/') { return str.replace( - new RegExp(arg.substr(1, arg.length - 2), 'gi'), + new RegExp(arg.slice(1, -1), 'gi'), bit => markStart + bit + markEnd ) } @@ -121,9 +112,9 @@ function addColorMarker (str, arg, i) { var p = 0 return pieces.map(function (piece) { - piece = str.substr(p, piece.length) + piece = str.slice(p, p + piece.length) var mark = markStart + - str.substr(p + piece.length, arg.length) + + str.slice(p + piece.length, p + piece.length + arg.length) + markEnd p += piece.length + arg.length return piece + mark @@ -140,26 +131,6 @@ function colorize (line) { return line.split('\u0000').join(uncolor) } -function getMaxWidth () { - var cols - try { - var tty = require('tty') - var stdout = process.stdout - cols = !tty.isatty(stdout.fd) ? Infinity : process.stdout.getWindowSize()[0] - cols = (cols === 0) ? Infinity : cols - } catch (ex) { - cols = Infinity - } - return cols -} - -function trimToMaxWidth (str) { - var maxWidth = getMaxWidth() - return str.split('\n').map(function (line) { - return line.slice(0, maxWidth) - }).join('\n') -} - function highlightSearchTerms (str, terms) { terms.forEach(function (arg, i) { str = addColorMarker(str, arg, i) @@ -169,13 +140,10 @@ function highlightSearchTerms (str, terms) { } function normalizePackage (data, opts) { - opts = opts || {} return { name: data.name, - description: opts.description ? data.description : '', - author: (data.maintainers || []).map(function (m) { - return '=' + m.username - }).join(' '), + description: data.description, + author: data.maintainers.map((m) => `=${m.username}`).join(' '), keywords: Array.isArray(data.keywords) ? data.keywords.join(' ') : typeof data.keywords === 'string' diff --git a/lib/utils/get-identity.js b/lib/utils/get-identity.js index e77c2ee..d8f59da 100644 --- a/lib/utils/get-identity.js +++ b/lib/utils/get-identity.js @@ -1,39 +1,26 @@ const npmFetch = require('npm-registry-fetch') -const needsAuthError = (msg) => - Object.assign(new Error(msg), { code: 'ENEEDAUTH' }) - -module.exports = async (npm, opts = {}) => { +module.exports = async (npm, opts) => { const { registry } = opts - if (!registry) { - throw Object.assign(new Error('No registry specified.'), { code: 'ENOREGISTRY' }) - } // First, check if we have a user/pass-based auth const creds = npm.config.getCredentialsByURI(registry) - const { username: usernameFromURI, token } = creds - - if (usernameFromURI) { - // Found username; return it - return usernameFromURI - } else if (token) { - // No username, but we have a token; fetch the username from registry - const registryData = await npmFetch.json('/-/whoami', { - ...opts, - }) - const { username: usernameFromRegistry } = registryData - // Retrieved username from registry; return it - if (usernameFromRegistry) { - return usernameFromRegistry - } else { - // Didn't get username from registry; bad token - throw needsAuthError( - 'Your auth token is no longer valid. Please login again.' - ) - } - } else { - // At this point, if they have a credentials object, it doesn't have a - // token or auth in it. Probably just the default registry. - throw needsAuthError('This command requires you to be logged in.') + if (creds.username) { + return creds.username } + + // No username, but we have other credentials; fetch the username from registry + if (creds.token || creds.certfile && creds.keyfile) { + const registryData = await npmFetch.json('/-/whoami', { ...opts }) + if (typeof registryData?.username === 'string') { + return registryData.username + } + } + + // At this point, even if they have a credentials object, it doesn't have a + // valid token. + throw Object.assign( + new Error('This command requires you to be logged in.'), + { code: 'ENEEDAUTH' } + ) } diff --git a/lib/utils/hosted-git-info-from-manifest.js b/lib/utils/hosted-git-info-from-manifest.js deleted file mode 100644 index 9592b0b..0000000 --- a/lib/utils/hosted-git-info-from-manifest.js +++ /dev/null @@ -1,14 +0,0 @@ -// given a manifest, try to get the hosted git info from it based on -// repository (if a string) or repository.url (if an object) -// returns null if it's not a valid repo, or not a known hosted repo -const hostedGitInfo = require('hosted-git-info') -module.exports = mani => { - const r = mani.repository - const rurl = !r ? null - : typeof r === 'string' ? r - : typeof r === 'object' && typeof r.url === 'string' ? r.url - : null - - // hgi returns undefined sometimes, but let's always return null here - return (rurl && hostedGitInfo.fromUrl(rurl.replace(/^git\+/, ''))) || null -} diff --git a/lib/utils/is-windows-bash.js b/lib/utils/is-windows-bash.js deleted file mode 100644 index 0ae99e2..0000000 --- a/lib/utils/is-windows-bash.js +++ /dev/null @@ -1,3 +0,0 @@ -const isWindows = require('./is-windows.js') -module.exports = isWindows && - (/^MINGW(32|64)$/.test(process.env.MSYSTEM) || process.env.TERM === 'cygwin') diff --git a/lib/utils/is-windows-shell.js b/lib/utils/is-windows-shell.js deleted file mode 100644 index 477bd43..0000000 --- a/lib/utils/is-windows-shell.js +++ /dev/null @@ -1,3 +0,0 @@ -const isWindows = require('./is-windows.js') -const isWindowsBash = require('./is-windows-bash.js') -module.exports = isWindows && !isWindowsBash diff --git a/lib/utils/is-windows.js b/lib/utils/is-windows.js index fbece90..57f6599 100644 --- a/lib/utils/is-windows.js +++ b/lib/utils/is-windows.js @@ -1 +1,6 @@ -module.exports = process.platform === 'win32' +const isWindows = process.platform === 'win32' +const isWindowsShell = isWindows && + !/^MINGW(32|64)$/.test(process.env.MSYSTEM) && process.env.TERM !== 'cygwin' + +exports.isWindows = isWindows +exports.isWindowsShell = isWindowsShell diff --git a/lib/utils/log-file.js b/lib/utils/log-file.js index 0bf1e00..2935697 100644 --- a/lib/utils/log-file.js +++ b/lib/utils/log-file.js @@ -6,23 +6,11 @@ const glob = promisify(require('glob')) const MiniPass = require('minipass') const fsMiniPass = require('fs-minipass') const log = require('./log-shim') -const withChownSync = require('./with-chown-sync') const padZero = (n, length) => n.toString().padStart(length.toString().length, '0') - -const _logHandler = Symbol('logHandler') -const _formatLogItem = Symbol('formatLogItem') -const _getLogFilePath = Symbol('getLogFilePath') -const _openLogFile = Symbol('openLogFile') -const _cleanLogs = Symbol('cleanlogs') -const _endStream = Symbol('endStream') -const _isBuffered = Symbol('isBuffered') +const globify = pattern => pattern.split('\\').join('/') class LogFiles { - // If we write multiple log files we want them all to have the same - // identifier for sorting and matching purposes - #logId = null - // Default to a plain minipass stream so we can buffer // initial writes before we know the cache location #logStream = null @@ -40,7 +28,7 @@ class LogFiles { #fileLogCount = 0 #totalLogCount = 0 - #dir = null + #path = null #logsMax = null #files = [] @@ -48,16 +36,11 @@ class LogFiles { maxLogsPerFile = 50_000, maxFilesPerProcess = 5, } = {}) { - this.#logId = LogFiles.logId(new Date()) this.#MAX_LOGS_PER_FILE = maxLogsPerFile this.#MAX_FILES_PER_PROCESS = maxFilesPerProcess this.on() } - static logId (d) { - return d.toISOString().replace(/[.:]/g, '_') - } - static format (count, level, title, ...args) { let prefix = `${count} ${level}` if (title) { @@ -74,55 +57,63 @@ class LogFiles { on () { this.#logStream = new MiniPass() - process.on('log', this[_logHandler]) + process.on('log', this.#logHandler) } off () { - process.off('log', this[_logHandler]) - this[_endStream]() + process.off('log', this.#logHandler) + this.#endStream() } - load ({ dir, logsMax } = {}) { - this.#dir = dir + load ({ path, logsMax = Infinity } = {}) { + // dir is user configurable and is required to exist so + // this can error if the dir is missing or not configured correctly + this.#path = path this.#logsMax = logsMax // Log stream has already ended if (!this.#logStream) { return } + + log.verbose('logfile', `logs-max:${logsMax} dir:${this.#path}`) + // Pipe our initial stream to our new file stream and // set that as the new log logstream for future writes - const initialFile = this[_openLogFile]() - if (initialFile) { - this.#logStream = this.#logStream.pipe(initialFile) + // if logs max is 0 then the user does not want a log file + if (this.#logsMax > 0) { + const initialFile = this.#openLogFile() + if (initialFile) { + this.#logStream = this.#logStream.pipe(initialFile) + } } - // Kickoff cleaning process. This is async but it wont delete - // our next log file since it deletes oldest first. Return the - // result so it can be awaited in tests - return this[_cleanLogs]() + // Kickoff cleaning process, even if we aren't writing a logfile. + // This is async but it will always ignore the current logfile + // Return the result so it can be awaited in tests + return this.#cleanLogs() } log (...args) { - this[_logHandler](...args) + this.#logHandler(...args) } get files () { return this.#files } - get [_isBuffered] () { + get #isBuffered () { return this.#logStream instanceof MiniPass } - [_endStream] (output) { + #endStream (output) { if (this.#logStream) { this.#logStream.end(output) this.#logStream = null } } - [_logHandler] = (level, ...args) => { + #logHandler = (level, ...args) => { // Ignore pause and resume events since we // write everything to the log file if (level === 'pause' || level === 'resume') { @@ -134,9 +125,9 @@ class LogFiles { return } - const logOutput = this[_formatLogItem](level, ...args) + const logOutput = this.#formatLogItem(level, ...args) - if (this[_isBuffered]) { + if (this.#isBuffered) { // Cant do anything but buffer the output if we dont // have a file stream yet this.#logStream.write(logOutput) @@ -146,45 +137,43 @@ class LogFiles { // Open a new log file if we've written too many logs to this one if (this.#fileLogCount >= this.#MAX_LOGS_PER_FILE) { // Write last chunk to the file and close it - this[_endStream](logOutput) + this.#endStream(logOutput) if (this.#files.length >= this.#MAX_FILES_PER_PROCESS) { // but if its way too many then we just stop listening this.off() } else { // otherwise we are ready for a new file for the next event - this.#logStream = this[_openLogFile]() + this.#logStream = this.#openLogFile() } } else { this.#logStream.write(logOutput) } } - [_formatLogItem] (...args) { + #formatLogItem (...args) { this.#fileLogCount += 1 return LogFiles.format(this.#totalLogCount++, ...args) } - [_getLogFilePath] (prefix, suffix, sep = '-') { - return path.resolve(this.#dir, prefix + sep + 'debug' + sep + suffix + '.log') + #getLogFilePath (count = '') { + return `${this.#path}debug-${count}.log` } - [_openLogFile] () { + #openLogFile () { // Count in filename will be 0 indexed const count = this.#files.length try { - const logStream = withChownSync( - // Pad with zeros so that our log files are always sorted properly - // We never want to write files ending in `-9.log` and `-10.log` because - // log file cleaning is done by deleting the oldest so in this example - // `-10.log` would be deleted next - this[_getLogFilePath](this.#logId, padZero(count, this.#MAX_FILES_PER_PROCESS)), - // Some effort was made to make the async, but we need to write logs - // during process.on('exit') which has to be synchronous. So in order - // to never drop log messages, it is easiest to make it sync all the time - // and this was measured to be about 1.5% slower for 40k lines of output - (f) => new fsMiniPass.WriteStreamSync(f, { flags: 'a' }) - ) + // Pad with zeros so that our log files are always sorted properly + // We never want to write files ending in `-9.log` and `-10.log` because + // log file cleaning is done by deleting the oldest so in this example + // `-10.log` would be deleted next + const f = this.#getLogFilePath(padZero(count, this.#MAX_FILES_PER_PROCESS)) + // Some effort was made to make the async, but we need to write logs + // during process.on('exit') which has to be synchronous. So in order + // to never drop log messages, it is easiest to make it sync all the time + // and this was measured to be about 1.5% slower for 40k lines of output + const logStream = new fsMiniPass.WriteStreamSync(f, { flags: 'a' }) if (count > 0) { // Reset file log count if we are opening // after our first file @@ -193,29 +182,31 @@ class LogFiles { this.#files.push(logStream.path) return logStream } catch (e) { - // XXX: do something here for errors? - // log to display only? - return null + // If the user has a readonly logdir then we don't want to + // warn this on every command so it should be verbose + log.verbose('logfile', `could not be created: ${e}`) } } - async [_cleanLogs] () { + async #cleanLogs () { // module to clean out the old log files // this is a best-effort attempt. if a rm fails, we just // log a message about it and move on. We do return a // Promise that succeeds when we've tried to delete everything, // just for the benefit of testing this function properly. - if (typeof this.#logsMax !== 'number') { - return - } - try { - // Handle the old (prior to 8.2.0) log file names which did not have an counter suffix - // so match by anything after `-debug` and before `.log` (including nothing) - const logGlob = this[_getLogFilePath]('*-', '*', '') + const logPath = this.#getLogFilePath() + const logGlob = path.join(path.dirname(logPath), path.basename(logPath) + // tell glob to only match digits + .replace(/\d/g, '[0123456789]') + // Handle the old (prior to 8.2.0) log file names which did not have a + // counter suffix + .replace(/-\.log$/, '*.log') + ) + // Always ignore the currently written files - const files = await glob(logGlob, { ignore: this.#files }) + const files = await glob(globify(logGlob), { ignore: this.#files.map(globify), silent: true }) const toDelete = files.length - this.#logsMax if (toDelete <= 0) { @@ -226,13 +217,15 @@ class LogFiles { for (const file of files.slice(0, toDelete)) { try { - await rimraf(file) + await rimraf(file, { glob: false }) } catch (e) { log.silly('logfile', 'error removing log file', file, e) } } } catch (e) { log.warn('logfile', 'error cleaning log files', e) + } finally { + log.silly('logfile', 'done cleaning log files') } } } diff --git a/lib/utils/npm-usage.js b/lib/utils/npm-usage.js index b0c98b2..947a307 100644 --- a/lib/utils/npm-usage.js +++ b/lib/utils/npm-usage.js @@ -1,10 +1,18 @@ const { dirname } = require('path') -const { cmdList } = require('./cmd-list') -const localeCompare = require('@isaacs/string-locale-compare')('en') +const { commands } = require('./cmd-list') + +const COL_MAX = 60 +const COL_MIN = 24 +const COL_GUTTER = 16 +const INDENT = 4 + +const indent = (repeat = INDENT) => ' '.repeat(repeat) +const indentNewline = (repeat) => `\n${indent(repeat)}` module.exports = async (npm) => { - const usesBrowser = npm.config.get('viewer') === 'browser' - ? ' (in a browser)' : '' + const browser = npm.config.get('viewer') === 'browser' ? ' (in a browser)' : '' + const allCommands = npm.config.get('long') ? await cmdUsages(npm) : cmdNames() + return `npm <command> Usage: @@ -15,14 +23,14 @@ npm test run this project's tests npm run <foo> run the script named <foo> npm <command> -h quick help on <command> npm -l display usage info for all commands -npm help <term> search for help on <term>${usesBrowser} -npm help npm more involved overview${usesBrowser} +npm help <term> search for help on <term>${browser} +npm help npm more involved overview${browser} All commands: -${await allCommands(npm)} +${allCommands} Specify configs in the ini-formatted file: - ${npm.config.get('userconfig')} +${indent() + npm.config.get('userconfig')} or on the command line via: npm <command> --key=value More configuration info: npm help config @@ -31,21 +39,14 @@ Configuration fields: npm help 7 config npm@${npm.version} ${dirname(dirname(__dirname))}` } -const allCommands = async (npm) => { - if (npm.config.get('long')) { - return usages(npm) - } - return ('\n ' + wrap(cmdList)) -} - -const wrap = (arr) => { +const cmdNames = () => { const out = [''] - const line = !process.stdout.columns ? 60 - : Math.min(60, Math.max(process.stdout.columns - 16, 24)) + const line = !process.stdout.columns ? COL_MAX + : Math.min(COL_MAX, Math.max(process.stdout.columns - COL_GUTTER, COL_MIN)) let l = 0 - for (const c of arr.sort((a, b) => a < b ? -1 : 1)) { + for (const c of commands) { if (out[l].length + c.length + 2 < line) { out[l] += ', ' + c } else { @@ -53,20 +54,23 @@ const wrap = (arr) => { out[l] = c } } - return out.join('\n ').substr(2) + + return indentNewline() + out.join(indentNewline()).slice(2) } -const usages = async (npm) => { +const cmdUsages = async (npm) => { // return a string of <command>: <usage> let maxLen = 0 const set = [] - for (const c of cmdList) { - const cmd = await npm.cmd(c) - set.push([c, cmd.usage]) + for (const c of commands) { + const { usage } = await npm.cmd(c) + set.push([c, usage.split('\n')]) maxLen = Math.max(maxLen, c.length) } - return set.sort(([a], [b]) => localeCompare(a, b)) - .map(([c, usage]) => `\n ${c}${' '.repeat(maxLen - c.length + 1)}${ - (usage.split('\n').join('\n' + ' '.repeat(maxLen + 5)))}`) - .join('\n') + + return set.map(([name, usageLines]) => { + const gutter = indent(maxLen - name.length + 1) + const usage = usageLines.join(indentNewline(INDENT + maxLen + 1)) + return indentNewline() + name + gutter + usage + }).join('\n') } diff --git a/lib/utils/open-url-prompt.js b/lib/utils/open-url-prompt.js new file mode 100644 index 0000000..df0c970 --- /dev/null +++ b/lib/utils/open-url-prompt.js @@ -0,0 +1,70 @@ +const readline = require('readline') +const promiseSpawn = require('@npmcli/promise-spawn') + +function print (npm, title, url) { + const json = npm.config.get('json') + + const message = json ? JSON.stringify({ title, url }) : `${title}:\n${url}` + + npm.output(message) +} + +// Prompt to open URL in browser if possible +const promptOpen = async (npm, url, title, prompt, emitter) => { + const browser = npm.config.get('browser') + const isInteractive = process.stdin.isTTY === true && process.stdout.isTTY === true + + try { + if (!/^https?:$/.test(new URL(url).protocol)) { + throw new Error() + } + } catch (_) { + throw new Error('Invalid URL: ' + url) + } + + print(npm, title, url) + + if (browser === false || !isInteractive) { + return + } + + const rl = readline.createInterface({ + input: process.stdin, + output: process.stdout, + }) + + const tryOpen = await new Promise(resolve => { + rl.on('SIGINT', () => { + rl.close() + resolve('SIGINT') + }) + + rl.question(prompt, () => { + resolve(true) + }) + + if (emitter && emitter.addListener) { + emitter.addListener('abort', () => { + rl.close() + + // clear the prompt line + npm.output('') + + resolve(false) + }) + } + }) + + if (tryOpen === 'SIGINT') { + throw new Error('canceled') + } + + if (!tryOpen) { + return + } + + const command = browser === true ? null : browser + await promiseSpawn.open(url, { command }) +} + +module.exports = promptOpen diff --git a/lib/utils/open-url.js b/lib/utils/open-url.js index eed2449..3796407 100644 --- a/lib/utils/open-url.js +++ b/lib/utils/open-url.js @@ -1,4 +1,4 @@ -const opener = require('opener') +const promiseSpawn = require('@npmcli/promise-spawn') const { URL } = require('url') @@ -37,18 +37,14 @@ const open = async (npm, url, errMsg, isFile) => { } const command = browser === true ? null : browser - await new Promise((resolve, reject) => { - opener(url, { command }, (err) => { - if (err) { - if (err.code === 'ENOENT') { - printAlternateMsg() - } else { - return reject(err) - } + await promiseSpawn.open(url, { command }) + .catch((err) => { + if (err.code !== 'ENOENT') { + throw err } - return resolve() + + printAlternateMsg() }) - }) } module.exports = open diff --git a/lib/utils/otplease.js b/lib/utils/otplease.js index 0e32493..b4aa167 100644 --- a/lib/utils/otplease.js +++ b/lib/utils/otplease.js @@ -1,20 +1,48 @@ -const prompt = 'This operation requires a one-time password.\nEnter OTP:' -const readUserInfo = require('./read-user-info.js') +const log = require('./log-shim') +async function otplease (npm, opts, fn) { + try { + return await fn(opts) + } catch (err) { + if (!process.stdin.isTTY || !process.stdout.isTTY) { + throw err + } -const isOtpError = err => - err.code === 'EOTP' || (err.code === 'E401' && /one-time pass/.test(err.body)) + if (isWebOTP(err)) { + log.disableProgress() + const webAuth = require('./web-auth') + const openUrlPrompt = require('./open-url-prompt') + + const openerPromise = (url, emitter) => + openUrlPrompt( + npm, + url, + 'Authenticate your account at', + 'Press ENTER to open in the browser...', + emitter + ) + const otp = await webAuth(openerPromise, err.body.authUrl, err.body.doneUrl, opts) + return await fn({ ...opts, otp }) + } + + if (isClassicOTP(err)) { + const readUserInfo = require('./read-user-info.js') + const otp = await readUserInfo.otp('This operation requires a one-time password.\nEnter OTP:') + return await fn({ ...opts, otp }) + } + + throw err + } +} + +function isWebOTP (err) { + if (err.code === 'EOTP' && err.body) { + return err.body.authUrl && err.body.doneUrl + } + return false +} + +function isClassicOTP (err) { + return err.code === 'EOTP' || (err.code === 'E401' && /one-time pass/.test(err.body)) +} module.exports = otplease -function otplease (opts, fn) { - opts = { prompt, ...opts } - return Promise.resolve().then(() => fn(opts)).catch(err => { - if (!isOtpError(err)) { - throw err - } else if (!process.stdin.isTTY || !process.stdout.isTTY) { - throw err - } else { - return readUserInfo.otp(opts.prompt) - .then(otp => fn({ ...opts, otp })) - } - }) -} diff --git a/lib/utils/path.js b/lib/utils/path.js deleted file mode 100644 index ad0065a..0000000 --- a/lib/utils/path.js +++ /dev/null @@ -1,4 +0,0 @@ -// return the PATH array in a cross-platform way -const PATH = process.env.PATH || process.env.Path || process.env.path -const { delimiter } = require('path') -module.exports = PATH.split(delimiter) diff --git a/lib/utils/queryable.js b/lib/utils/queryable.js index ceb06bd..7c5bb7f 100644 --- a/lib/utils/queryable.js +++ b/lib/utils/queryable.js @@ -148,7 +148,9 @@ const setter = ({ data, key, value, force }) => { let maybeIndex = Number.NaN try { maybeIndex = Number(_key) - } catch (err) {} + } catch { + // leave it NaN + } if (!Number.isNaN(maybeIndex)) { _key = maybeIndex } diff --git a/lib/utils/read-package-name.js b/lib/utils/read-package-name.js deleted file mode 100644 index 7ed1598..0000000 --- a/lib/utils/read-package-name.js +++ /dev/null @@ -1,9 +0,0 @@ -const { resolve } = require('path') -const readJson = require('read-package-json-fast') -async function readLocalPackageName (prefix) { - const filepath = resolve(prefix, 'package.json') - const json = await readJson(filepath) - return json.name -} - -module.exports = readLocalPackageName diff --git a/lib/utils/reify-output.js b/lib/utils/reify-output.js index b4114c1..b5c3a59 100644 --- a/lib/utils/reify-output.js +++ b/lib/utils/reify-output.js @@ -27,7 +27,7 @@ const reifyOutput = (npm, arb) => { // don't print any info in --silent mode, but we still need to // set the exitCode properly from the audit report, if we have one. - if (log.levels[log.level] > log.levels.error) { + if (npm.silent) { getAuditReport(npm, auditReport) return } @@ -88,7 +88,7 @@ const reifyOutput = (npm, arb) => { // at the end if there's still stuff, because it's silly for `npm audit` // to tell you to run `npm audit` for details. otherwise, use the summary // report. if we get here, we know it's not quiet or json. -// If the loglevel is set higher than 'error', then we just run the report +// If the loglevel is silent, then we just run the report // to get the exitCode set appropriately. const printAuditReport = (npm, report) => { const res = getAuditReport(npm, report) @@ -105,7 +105,7 @@ const getAuditReport = (npm, report) => { // when in silent mode, we print nothing. the JSON output is // going to just JSON.stringify() the report object. - const reporter = log.levels[log.level] > log.levels.error ? 'quiet' + const reporter = npm.silent ? 'quiet' : npm.flatOptions.json ? 'quiet' : npm.command !== 'audit' ? 'install' : 'detail' diff --git a/lib/utils/replace-info.js b/lib/utils/replace-info.js index e9d19ef..b9ce619 100644 --- a/lib/utils/replace-info.js +++ b/lib/utils/replace-info.js @@ -1,33 +1,31 @@ -const URL = require('url').URL +const { cleanUrl } = require('npm-registry-fetch') +const isString = (v) => typeof v === 'string' + +// split on \s|= similar to how nopt parses options +const splitAndReplace = (str) => { + // stateful regex, don't move out of this scope + const splitChars = /[\s=]/g + + let match = null + let result = '' + let index = 0 + while (match = splitChars.exec(str)) { + result += cleanUrl(str.slice(index, match.index)) + match[0] + index = splitChars.lastIndex + } + + return result + cleanUrl(str.slice(index)) +} // replaces auth info in an array of arguments or in a strings function replaceInfo (arg) { - const isArray = Array.isArray(arg) - const isString = str => typeof str === 'string' - - if (!isArray && !isString(arg)) { - return arg + if (isString(arg)) { + return splitAndReplace(arg) + } else if (Array.isArray(arg)) { + return arg.map((a) => isString(a) ? splitAndReplace(a) : a) } - const testUrlAndReplace = str => { - try { - const url = new URL(str) - return url.password === '' ? str : str.replace(url.password, '***') - } catch (e) { - return str - } - } - - const args = isString(arg) ? arg.split(' ') : arg - const info = args.map(a => { - if (isString(a) && a.indexOf(' ') > -1) { - return a.split(' ').map(testUrlAndReplace).join(' ') - } - - return testUrlAndReplace(a) - }) - - return isString(arg) ? info.join(' ') : info + return arg } module.exports = replaceInfo diff --git a/lib/utils/split-package-names.js b/lib/utils/split-package-names.js deleted file mode 100644 index 395c251..0000000 --- a/lib/utils/split-package-names.js +++ /dev/null @@ -1,25 +0,0 @@ -'use strict' - -const splitPackageNames = (path) => { - return path.split('/') - // combine scoped parts - .reduce((parts, part) => { - if (parts.length === 0) { - return [part] - } - - const lastPart = parts[parts.length - 1] - // check if previous part is the first part of a scoped package - if (lastPart[0] === '@' && !lastPart.includes('/')) { - parts[parts.length - 1] += '/' + part - } else { - parts.push(part) - } - - return parts - }, []) - .join('/node_modules/') - .replace(/(\/node_modules)+/, '/node_modules') -} - -module.exports = splitPackageNames diff --git a/lib/utils/tar.js b/lib/utils/tar.js index 2f2773c..c25fe71 100644 --- a/lib/utils/tar.js +++ b/lib/utils/tar.js @@ -48,9 +48,9 @@ const logTar = (tarball, opts = {}) => { { name: 'integrity:', value: - tarball.integrity.toString().substr(0, 20) + + tarball.integrity.toString().slice(0, 20) + '[...]' + - tarball.integrity.toString().substr(80), + tarball.integrity.toString().slice(80), }, tarball.bundled.length && { name: 'bundled deps:', value: tarball.bundled.length }, tarball.bundled.length && { @@ -120,7 +120,9 @@ const getContents = async (manifest, tarball) => { unpackedSize: totalEntrySize, shasum, integrity: ssri.parse(integrity.sha512[0]), - filename: `${manifest.name}-${manifest.version}.tgz`, + // @scope/packagename.tgz => scope-packagename.tgz + // we can safely use these global replace rules due to npm package naming rules + filename: `${manifest.name.replace('@', '').replace('/', '-')}-${manifest.version}.tgz`, files: uppers.concat(others), entryCount: totalEntries, bundled: Array.from(bundled), diff --git a/lib/utils/timers.js b/lib/utils/timers.js index acff29e..c215fe9 100644 --- a/lib/utils/timers.js +++ b/lib/utils/timers.js @@ -1,21 +1,16 @@ const EE = require('events') -const path = require('path') -const fs = require('graceful-fs') +const fs = require('fs') const log = require('./log-shim') -const withChownSync = require('./with-chown-sync.js') - -const _timeListener = Symbol('timeListener') -const _timeEndListener = Symbol('timeEndListener') -const _init = Symbol('init') // This is an event emiiter but on/off // only listen on a single internal event that gets // emitted whenever a timer ends class Timers extends EE { + file = null + #unfinished = new Map() #finished = {} #onTimeEnd = Symbol('onTimeEnd') - #dir = null #initialListener = null #initialTimer = null @@ -23,7 +18,7 @@ class Timers extends EE { super() this.#initialListener = listener this.#initialTimer = start - this[_init]() + this.#init() } get unfinished () { @@ -34,7 +29,7 @@ class Timers extends EE { return this.#finished } - [_init] () { + #init () { this.on() if (this.#initialListener) { this.on(this.#initialListener) @@ -47,8 +42,8 @@ class Timers extends EE { if (listener) { super.on(this.#onTimeEnd, listener) } else { - process.on('time', this[_timeListener]) - process.on('timeEnd', this[_timeEndListener]) + process.on('time', this.#timeListener) + process.on('timeEnd', this.#timeEndListener) } } @@ -57,46 +52,56 @@ class Timers extends EE { super.off(this.#onTimeEnd, listener) } else { this.removeAllListeners(this.#onTimeEnd) - process.off('time', this[_timeListener]) - process.off('timeEnd', this[_timeEndListener]) + process.off('time', this.#timeListener) + process.off('timeEnd', this.#timeEndListener) } } - load ({ dir }) { - this.#dir = dir + time (name, fn) { + process.emit('time', name) + const end = () => process.emit('timeEnd', name) + if (typeof fn === 'function') { + const res = fn() + return res && res.finally ? res.finally(end) : (end(), res) + } + return end } - writeFile (fileData) { + load ({ path } = {}) { + if (path) { + this.file = `${path}timing.json` + } + } + + writeFile (metadata) { + if (!this.file) { + return + } + try { const globalStart = this.started const globalEnd = this.#finished.npm || Date.now() const content = { - ...fileData, - ...this.#finished, + metadata, + timers: this.#finished, // add any unfinished timers with their relative start/end - unfinished: [...this.#unfinished.entries()].reduce((acc, [name, start]) => { + unfinishedTimers: [...this.#unfinished.entries()].reduce((acc, [name, start]) => { acc[name] = [start - globalStart, globalEnd - globalStart] return acc }, {}), } - withChownSync( - path.resolve(this.#dir, '_timing.json'), - (f) => - // we append line delimited json to this file...forever - // XXX: should we also write a process specific timing file? - // with similar rules to the debug log (max files, etc) - fs.appendFileSync(f, JSON.stringify(content) + '\n') - ) + fs.writeFileSync(this.file, JSON.stringify(content) + '\n') } catch (e) { - log.warn('timing', 'could not write timing file', e) + this.file = null + log.warn('timing', `could not write timing file: ${e}`) } } - [_timeListener] = (name) => { + #timeListener = (name) => { this.#unfinished.set(name, Date.now()) } - [_timeEndListener] = (name) => { + #timeEndListener = (name) => { if (this.#unfinished.has(name)) { const ms = Date.now() - this.#unfinished.get(name) this.#finished[name] = ms diff --git a/lib/utils/unsupported.js b/lib/utils/unsupported.js deleted file mode 100644 index 75aad5e..0000000 --- a/lib/utils/unsupported.js +++ /dev/null @@ -1,39 +0,0 @@ -/* eslint-disable no-console */ -const semver = require('semver') -const supported = require('../../package.json').engines.node -const knownBroken = '<6.2.0 || 9 <9.3.0' - -// Keep this file compatible with all practical versions of node -// so we dont get syntax errors when trying to give the users -// a nice error message. Don't use our log handler because -// if we encounter a syntax error early on, that will never -// get displayed to the user. - -const checkVersion = exports.checkVersion = version => { - const versionNoPrerelease = version.replace(/-.*$/, '') - return { - version: versionNoPrerelease, - broken: semver.satisfies(versionNoPrerelease, knownBroken), - unsupported: !semver.satisfies(versionNoPrerelease, supported), - } -} - -exports.checkForBrokenNode = () => { - const nodejs = checkVersion(process.version) - if (nodejs.broken) { - console.error('ERROR: npm is known not to run on Node.js ' + process.version) - console.error("You'll need to upgrade to a newer Node.js version in order to use this") - console.error('version of npm. You can find the latest version at https://nodejs.org/') - process.exit(1) - } -} - -exports.checkForUnsupportedNode = () => { - const nodejs = checkVersion(process.version) - if (nodejs.unsupported) { - console.error('npm does not support Node.js ' + process.version) - console.error('You should probably upgrade to a newer version of node as we') - console.error("can't make any promises that npm will work with this version.") - console.error('You can find the latest version at https://nodejs.org/') - } -} diff --git a/lib/utils/update-notifier.js b/lib/utils/update-notifier.js index 0464561..a7eaaca 100644 --- a/lib/utils/update-notifier.js +++ b/lib/utils/update-notifier.js @@ -3,14 +3,15 @@ // Check daily for betas, and weekly otherwise. const pacote = require('pacote') -const ciDetect = require('@npmcli/ci-detect') +const ciInfo = require('ci-info') const semver = require('semver') const chalk = require('chalk') const { promisify } = require('util') const stat = promisify(require('fs').stat) const writeFile = promisify(require('fs').writeFile) const { resolve } = require('path') -const log = require('./log-shim.js') + +const SKIP = Symbol('SKIP') const isGlobalNpmUpdate = npm => { return npm.flatOptions.global && @@ -35,16 +36,99 @@ const checkTimeout = async (npm, duration) => { } const updateNotifier = async (npm, spec = 'latest') => { - // Maintained by Debian JS Team - return null + // never check for updates in CI, when updating npm already, or opted out + if (!npm.config.get('update-notifier') || + isGlobalNpmUpdate(npm) || + ciInfo.isCI) { + return SKIP + } + + // if we're on a prerelease train, then updates are coming fast + // check for a new one daily. otherwise, weekly. + const { version } = npm + const current = semver.parse(version) + + // if we're on a beta train, always get the next beta + if (current.prerelease.length) { + spec = `^${version}` + } + + // while on a beta train, get updates daily + const duration = spec !== 'latest' ? DAILY : WEEKLY + + // if we've already checked within the specified duration, don't check again + if (!(await checkTimeout(npm, duration))) { + return null + } + + // if they're currently using a prerelease, nudge to the next prerelease + // otherwise, nudge to latest. + const useColor = npm.logColor + + const mani = await pacote.manifest(`npm@${spec}`, { + // always prefer latest, even if doing --tag=whatever on the cmd + defaultTag: 'latest', + ...npm.flatOptions, + }).catch(() => null) + + // if pacote failed, give up + if (!mani) { + return null + } + + const latest = mani.version + + // if the current version is *greater* than latest, we're on a 'next' + // and should get the updates from that release train. + // Note that this isn't another http request over the network, because + // the packument will be cached by pacote from previous request. + if (semver.gt(version, latest) && spec === 'latest') { + return updateNotifier(npm, `^${version}`) + } + + // if we already have something >= the desired spec, then we're done + if (semver.gte(version, latest)) { + return null + } + + // ok! notify the user about this update they should get. + // The message is saved for printing at process exit so it will not get + // lost in any other messages being printed as part of the command. + const update = semver.parse(mani.version) + const type = update.major !== current.major ? 'major' + : update.minor !== current.minor ? 'minor' + : update.patch !== current.patch ? 'patch' + : 'prerelease' + const typec = !useColor ? type + : type === 'major' ? chalk.red(type) + : type === 'minor' ? chalk.yellow(type) + : chalk.green(type) + const oldc = !useColor ? current : chalk.red(current) + const latestc = !useColor ? latest : chalk.green(latest) + const changelog = `https://github.com/npm/cli/releases/tag/v${latest}` + const changelogc = !useColor ? `<${changelog}>` : chalk.cyan(changelog) + const cmd = `npm install -g npm@${latest}` + const cmdc = !useColor ? `\`${cmd}\`` : chalk.green(cmd) + const message = `\nNew ${typec} version of npm available! ` + + `${oldc} -> ${latestc}\n` + + `Changelog: ${changelogc}\n` + + `Run ${cmdc} to update!\n` + + return message } // only update the notification timeout if we actually finished checking module.exports = async npm => { const notification = await updateNotifier(npm) + + // dont write the file if we skipped checking altogether + if (notification === SKIP) { + return null + } + // intentional. do not await this. it's a best-effort update. if this // fails, it's ok. might be using /dev/null as the cache or something weird // like that. writeFile(lastCheckedFile(npm), '').catch(() => {}) - npm.updateNotification = notification + return notification } diff --git a/lib/utils/usage.js b/lib/utils/usage.js deleted file mode 100644 index 39eaa45..0000000 --- a/lib/utils/usage.js +++ /dev/null @@ -1,32 +0,0 @@ -const aliases = require('./cmd-list').aliases - -module.exports = function usage (cmd, txt, opt) { - const post = Object.keys(aliases).reduce(function (p, c) { - var val = aliases[c] - if (val !== cmd) { - return p - } - return p.concat(c) - }, []) - - if (opt || post.length > 0) { - txt += '\n\n' - } - - if (post.length === 1) { - txt += 'alias: ' - txt += post.join(', ') - } else if (post.length > 1) { - txt += 'aliases: ' - txt += post.join(', ') - } - - if (opt) { - if (post.length > 0) { - txt += '\n' - } - txt += 'common options: ' + opt - } - - return txt -} diff --git a/lib/utils/web-auth.js b/lib/utils/web-auth.js new file mode 100644 index 0000000..ce55168 --- /dev/null +++ b/lib/utils/web-auth.js @@ -0,0 +1,20 @@ +const EventEmitter = require('events') +const { webAuthCheckLogin } = require('npm-profile') + +async function webAuth (opener, initialUrl, doneUrl, opts) { + const doneEmitter = new EventEmitter() + + const openPromise = opener(initialUrl, doneEmitter) + const webAuthCheckPromise = webAuthCheckLogin(doneUrl, { ...opts, cache: false }) + .then(authResult => { + // cancel open prompt if it's present + doneEmitter.emit('abort') + + return authResult.token + }) + + await openPromise + return await webAuthCheckPromise +} + +module.exports = webAuth diff --git a/lib/utils/with-chown-sync.js b/lib/utils/with-chown-sync.js deleted file mode 100644 index 481b569..0000000 --- a/lib/utils/with-chown-sync.js +++ /dev/null @@ -1,13 +0,0 @@ -const mkdirp = require('mkdirp-infer-owner') -const fs = require('graceful-fs') -const path = require('path') - -module.exports = (file, method) => { - const dir = path.dirname(file) - mkdirp.sync(dir) - const result = method(file) - const st = fs.lstatSync(dir) - fs.chownSync(dir, st.uid, st.gid) - fs.chownSync(file, st.uid, st.gid) - return result -} diff --git a/lib/workspaces/get-workspaces.js b/lib/workspaces/get-workspaces.js index 0cddae2..373af1d 100644 --- a/lib/workspaces/get-workspaces.js +++ b/lib/workspaces/get-workspaces.js @@ -1,8 +1,11 @@ -const { resolve } = require('path') +const { resolve, relative } = require('path') const mapWorkspaces = require('@npmcli/map-workspaces') const minimatch = require('minimatch') const rpj = require('read-package-json-fast') +// minimatch wants forward slashes only for glob patterns +const globify = pattern => pattern.split('\\').join('/') + // Returns an Map of paths to workspaces indexed by workspace name // { foo => '/path/to/foo' } const getWorkspaces = async (filters, { path, includeWorkspaceRoot, relativeFrom }) => { @@ -20,9 +23,16 @@ const getWorkspaces = async (filters, { path, includeWorkspaceRoot, relativeFrom for (const filterArg of filters) { for (const [workspaceName, workspacePath] of workspaces.entries()) { + let relativePath = relative(relativeFrom, workspacePath) + if (filterArg.startsWith('./')) { + relativePath = `./${relativePath}` + } + const relativeFilter = relative(path, filterArg) if (filterArg === workspaceName - || resolve(relativeFrom || path, filterArg) === workspacePath - || minimatch(workspacePath, `${resolve(relativeFrom || path, filterArg)}/*`)) { + || resolve(relativeFrom, filterArg) === workspacePath + || minimatch(relativePath, `${globify(relativeFilter)}/*`) + || minimatch(relativePath, `${globify(filterArg)}/*`) + ) { res.set(workspaceName, workspacePath) } } diff --git a/lib/workspaces/update-workspaces.js b/lib/workspaces/update-workspaces.js new file mode 100644 index 0000000..4cba124 --- /dev/null +++ b/lib/workspaces/update-workspaces.js @@ -0,0 +1,40 @@ +'use strict' + +const Arborist = require('@npmcli/arborist') +const reifyFinish = require('../utils/reify-finish.js') + +async function updateWorkspaces ({ + config, + flatOptions, + localPrefix, + npm, + workspaces, +}) { + if (!flatOptions.workspacesUpdate || !workspaces.length) { + return + } + + // default behavior is to not save by default in order to avoid + // race condition problems when publishing multiple workspaces + // that have dependencies on one another, it might still be useful + // in some cases, which then need to set --save + const save = config.isDefault('save') + ? false + : config.get('save') + + // runs a minimalistic reify update, targetting only the workspaces + // that had version updates and skipping fund/audit/save + const opts = { + ...flatOptions, + audit: false, + fund: false, + path: localPrefix, + save, + } + const arb = new Arborist(opts) + + await arb.reify({ ...opts, update: workspaces }) + await reifyFinish(npm, arb) +} + +module.exports = updateWorkspaces diff --git a/make.bat b/make.bat deleted file mode 100644 index 7d71f0f..0000000 --- a/make.bat +++ /dev/null @@ -1,3 +0,0 @@ -:: The tests run "make doc" in the prepublish script, -:: so this file gives windows something that'll exit -:: successfully, without having to install make. diff --git a/mock-registry/.eslintrc.js b/mock-registry/.eslintrc.js new file mode 100644 index 0000000..5db9f81 --- /dev/null +++ b/mock-registry/.eslintrc.js @@ -0,0 +1,17 @@ +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' + +const { readdirSync: readdir } = require('fs') + +const localConfigs = readdir(__dirname) + .filter((file) => file.startsWith('.eslintrc.local.')) + .map((file) => `./${file}`) + +module.exports = { + root: true, + extends: [ + '@npmcli', + ...localConfigs, + ], +} diff --git a/mock-registry/.gitignore b/mock-registry/.gitignore new file mode 100644 index 0000000..79af2bf --- /dev/null +++ b/mock-registry/.gitignore @@ -0,0 +1,21 @@ +# This file is automatically added by @npmcli/template-oss. Do not edit. + +# ignore everything in the root +/* + +# keep these +!**/.gitignore +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ +!/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/mock-registry/lib/index.js b/mock-registry/lib/index.js new file mode 100644 index 0000000..fccfe6c --- /dev/null +++ b/mock-registry/lib/index.js @@ -0,0 +1,376 @@ +const pacote = require('pacote') +const Arborist = require('@npmcli/arborist') +const npa = require('npm-package-arg') +const Nock = require('nock') + +class MockRegistry { + #tap + #nock + #registry + #authorization + #basic + #debug + #strict + + constructor (opts) { + if (!opts.registry) { + throw new Error('mock registry requires a registry value') + } + this.#registry = (new URL(opts.registry)).origin + this.#authorization = opts.authorization + this.#basic = opts.basic + this.#debug = opts.debug + this.#strict = opts.strict + // Required for this.package + this.#tap = opts.tap + if (this.#tap) { + this.startNock() + } + } + + static tnock (t, host, opts, { debug = false, strict = false } = {}) { + const noMatch = (req) => { + if (strict) { + // There are network requests that get caught regardless of error code. + // Turning on strict mode requires that those requests get explicitly + // mocked with a 404, 500, etc. + // XXX: this is opt-in currently because it breaks some existing CLI + // tests. We should work towards making this the default for all tests. + t.fail(`Unmatched request: ${JSON.stringify(req.options, null, 2)}`) + } + if (debug) { + console.error('NO MATCH', t.name, req.options) + } + } + + Nock.emitter.on('no match', noMatch) + Nock.disableNetConnect() + const server = Nock(host, opts) + + if (strict) { + // this requires that mocks not be shared between sub tests but it helps + // find mistakes quicker instead of waiting for the entire test to end + t.afterEach((t) => { + t.strictSame(server.pendingMocks(), [], 'no pending mocks after each') + t.strictSame(server.activeMocks(), [], 'no active mocks after each') + }) + } + + t.teardown(() => { + Nock.enableNetConnect() + server.done() + Nock.emitter.off('no match', noMatch) + }) + + return server + } + + get origin () { + return this.#registry + } + + get nock () { + return this.#nock + } + + set nock (nock) { + this.#nock = nock + } + + startNock () { + if (this.nock) { + return + } + + if (!this.#tap) { + throw new Error('cannot mock packages without a tap fixture') + } + + const reqheaders = {} + if (this.#authorization) { + reqheaders.authorization = `Bearer ${this.#authorization}` + } + if (this.#basic) { + reqheaders.authorization = `Basic ${this.#basic}` + } + + this.nock = MockRegistry.tnock( + this.#tap, + this.#registry, + { reqheaders }, + { debug: this.#debug, strict: this.#strict } + ) + } + + search ({ responseCode = 200, results = [], error }) { + // the flags, score, and searchScore parts of the response are never used + // by npm, only package is used + const response = results.map(p => ({ package: p })) + this.nock = this.nock.get('/-/v1/search').query(true) + if (error) { + this.nock = this.nock.replyWithError(error) + } else { + this.nock = this.nock.reply(responseCode, { objects: response }) + } + return this.nock + } + + whoami ({ username, body, responseCode = 200, times = 1 }) { + if (username) { + this.nock = this.nock.get('/-/whoami').times(times).reply(responseCode, { username }) + } else { + this.nock = this.nock.get('/-/whoami').times(times).reply(responseCode, body) + } + } + + setAccess ({ spec, body = {} }) { + this.nock = this.nock.post( + `/-/package/${npa(spec).escapedName}/access`, + body + ).reply(200) + } + + getVisibility ({ spec, visibility }) { + this.nock = this.nock.get(`/-/package/${npa(spec).escapedName}/visibility`) + .reply(200, visibility) + } + + setPermissions ({ spec, team, permissions }) { + if (team.startsWith('@')) { + team = team.slice(1) + } + const [scope, teamName] = team.split(':') + this.nock = this.nock.put( + `/-/team/${encodeURIComponent(scope)}/${encodeURIComponent(teamName)}/package`, + { package: spec, permissions } + ).reply(200) + } + + removePermissions ({ spec, team }) { + if (team.startsWith('@')) { + team = team.slice(1) + } + const [scope, teamName] = team.split(':') + this.nock = this.nock.delete( + `/-/team/${encodeURIComponent(scope)}/${encodeURIComponent(teamName)}/package`, + { package: spec } + ).reply(200) + } + + couchuser ({ username, body, responseCode = 200 }) { + if (body) { + this.nock = this.nock.get(`/-/user/org.couchdb.user:${encodeURIComponent(username)}`) + .reply(responseCode, body) + } else { + this.nock = this.nock.get(`/-/user/org.couchdb.user:${encodeURIComponent(username)}`) + .reply(responseCode, { _id: `org.couchdb.user:${username}`, email: '', name: username }) + } + } + + couchadduser ({ username, email, password, token = 'npm_default-test-token' }) { + this.nock = this.nock.put(`/-/user/org.couchdb.user:${username}`, body => { + this.#tap.match(body, { + _id: `org.couchdb.user:${username}`, + name: username, + email, // Sole difference from couchlogin + password, + type: 'user', + roles: [], + }) + if (!body.date) { + return false + } + return true + }).reply(201, { + id: 'org.couchdb.user:undefined', + rev: '_we_dont_use_revs_any_more', + token, + }) + } + + couchlogin ({ username, password, token = 'npm_default-test-token' }) { + this.nock = this.nock.put(`/-/user/org.couchdb.user:${username}`, body => { + this.#tap.match(body, { + _id: `org.couchdb.user:${username}`, + name: username, + password, + type: 'user', + roles: [], + }) + if (!body.date) { + return false + } + return true + }).reply(201, { + id: 'org.couchdb.user:undefined', + rev: '_we_dont_use_revs_any_more', + token, + }) + } + + webadduser ({ username, password, token = 'npm_default-test-token' }) { + const doneUrl = new URL('/npm-cli-test/done', this.#registry).href + const loginUrl = new URL('/npm-cli-test/login', this.#registry).href + this.nock = this.nock + .post('/-/v1/login', body => { + this.#tap.ok(body.create) // Sole difference from weblogin + this.#tap.ok(body.hostname) + return true + }) + .reply(200, { doneUrl, loginUrl }) + .get('/npm-cli-test/done') + .reply(200, { token }) + } + + weblogin ({ token = 'npm_default-test-token' }) { + const doneUrl = new URL('/npm-cli-test/done', this.#registry).href + const loginUrl = new URL('/npm-cli-test/login', this.#registry).href + this.nock = this.nock + .post('/-/v1/login', body => { + this.#tap.ok(body.hostname) + return true + }) + .reply(200, { doneUrl, loginUrl }) + .get('/npm-cli-test/done') + .reply(200, { token }) + } + + // team can be a team or a username + getPackages ({ user, team, packages = {}, times = 1, responseCode = 200 }) { + let uri + if (user) { + uri = `/-/user/${user}/package` + } else { + if (team.startsWith('@')) { + team = team.slice(1) + } + const [scope, teamName] = team.split(':').map(encodeURIComponent) + if (teamName) { + uri = `/-/team/${scope}/${teamName}/package` + } else { + uri = `/-/org/${scope}/package` + } + } + this.nock = this.nock.get(uri).times(times).reply(responseCode, packages) + } + + getCollaborators ({ spec, collaborators = {} }) { + this.nock = this.nock.get(`/-/package/${npa(spec).escapedName}/collaborators`) + .reply(200, collaborators) + } + + advisory (advisory = {}) { + const id = advisory.id || parseInt(Math.random() * 1000000) + return { + id, + url: `https://github.com/advisories/GHSA-${id}`, + title: `Test advisory ${id}`, + severity: 'high', + vulnerable_versions: '*', + cwe: [ + 'cwe-0', + ], + cvss: { + score: 0, + }, + ...advisory, + } + } + + star (manifest, users) { + const spec = npa(manifest.name) + this.nock = this.nock.put(`/${spec.escapedName}`, { + _id: manifest._id, + _rev: manifest._rev, + users, + }).reply(200, { ...manifest, users }) + } + + ping ({ body = {}, responseCode = 200 } = {}) { + this.nock = this.nock.get('/-/ping?write=true').reply(responseCode, body) + } + + async package ({ manifest, times = 1, query, tarballs }) { + let nock = this.nock + const spec = npa(manifest.name) + nock = nock.get(`/${spec.escapedName}`).times(times) + if (query) { + nock = nock.query(query) + } + nock = nock.reply(200, manifest) + if (tarballs) { + for (const version in tarballs) { + const m = manifest.versions[version] + nock = await this.tarball({ manifest: m, tarball: tarballs[version] }) + } + } + this.nock = nock + } + + async tarball ({ manifest, tarball }) { + const nock = this.nock + const dist = new URL(manifest.dist.tarball) + const tar = await pacote.tarball(tarball, { Arborist }) + nock.get(dist.pathname).reply(200, tar) + return nock + } + + // either pass in packuments if you need to set specific attributes besides version, + // or an array of versions + // the last packument in the packuments or versions array will be tagged latest + manifest ({ name = 'test-package', users, packuments, versions } = {}) { + packuments = this.packuments(versions || packuments, name) + const latest = packuments.slice(-1)[0] + const manifest = { + _id: `${name}@${latest.version}`, + _rev: '00-testdeadbeef', + name, + description: 'test package mock manifest', + dependencies: {}, + versions: {}, + time: {}, + 'dist-tags': { latest: latest.version }, + ...latest, + } + if (users) { + manifest.users = users + } + for (const packument of packuments) { + const unscoped = name.includes('/') ? name.split('/')[1] : name + manifest.versions[packument.version] = { + _id: `${name}@${packument.version}`, + name, + description: 'test package mock manifest', + dependencies: {}, + dist: { + tarball: `${this.#registry}/${name}/-/${unscoped}-${packument.version}.tgz`, + }, + maintainers: [], + ...packument, + } + manifest.time[packument.version] = new Date() + } + + return manifest + } + + packuments (packuments = ['1.0.0'], name) { + return packuments.map(p => this.packument(p, name)) + } + + // Generate packument from shorthand + packument (packument, name = 'test-package') { + if (!packument.version) { + packument = { version: packument } + } + return { + name, + version: '1.0.0', + description: 'mocked test package', + dependencies: {}, + ...packument, + } + } +} + +module.exports = MockRegistry diff --git a/mock-registry/package.json b/mock-registry/package.json new file mode 100644 index 0000000..65bd081 --- /dev/null +++ b/mock-registry/package.json @@ -0,0 +1,55 @@ +{ + "name": "@npmcli/mock-registry", + "version": "1.0.0", + "description": "", + "main": "lib/index.js", + "private": true, + "scripts": { + "test": "tap", + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "node .. run lint -- --fix", + "snap": "tap", + "posttest": "node .. run lint" + }, + "repository": { + "type": "git", + "url": "https://github.com/npm/cli.git", + "directory": "mock-registry" + }, + "keywords": [], + "author": "GitHub Inc.", + "license": "ISC", + "bugs": { + "url": "https://github.com/npm/cli/issues" + }, + "homepage": "https://github.com/npm/cli#readme", + "files": [ + "bin/", + "lib/" + ], + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0" + }, + "tap": { + "no-coverage": true, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] + }, + "devDependencies": { + "@npmcli/arborist": "^6.1.1", + "@npmcli/eslint-config": "^4.0.1", + "@npmcli/template-oss": "4.11.0", + "nock": "^13.2.9", + "npm-package-arg": "^10.1.0", + "pacote": "^15.0.7", + "tap": "^16.3.2" + } +} diff --git a/mock-registry/test/index.js b/mock-registry/test/index.js new file mode 100644 index 0000000..45f9bc1 --- /dev/null +++ b/mock-registry/test/index.js @@ -0,0 +1,8 @@ +const t = require('tap') +const MockRegistry = require('..') + +t.test('it works', async t => { + t.ok(new MockRegistry({ + registry: 'http://registry.npmjs.org/', + })) +}) diff --git a/netlify.toml b/netlify.toml deleted file mode 100644 index 508b089..0000000 --- a/netlify.toml +++ /dev/null @@ -1,4 +0,0 @@ -[build] - base = "docs" - command = "npm run build" - publish = "output" diff --git a/node_modules/.gitignore b/node_modules/.gitignore index a14c4c9..c8b7125 100644 --- a/node_modules/.gitignore +++ b/node_modules/.gitignore @@ -1,10 +1,291 @@ -# Automatically generated to ignore dev deps -/.package-lock.json +# Automatically generated to ignore everything except bundled deps +# Ignore everything by default except this file +/* +!/.gitignore +# Allow all bundled deps +!/@colors/ +/@colors/* +!/@colors/colors +!/@gar/ +/@gar/* +!/@gar/promisify +!/@isaacs/ +/@isaacs/* +!/@isaacs/string-locale-compare +!/@npmcli/ +/@npmcli/* +!/@npmcli/arborist +!/@npmcli/config +!/@npmcli/disparity-colors +!/@npmcli/fs +!/@npmcli/git +!/@npmcli/installed-package-contents +!/@npmcli/map-workspaces +!/@npmcli/metavuln-calculator +!/@npmcli/name-from-folder +!/@npmcli/node-gyp +!/@npmcli/package-json +!/@npmcli/promise-spawn +!/@npmcli/query +!/@npmcli/run-script +!/@tootallnate/ +/@tootallnate/* +!/@tootallnate/once +!/abbrev +!/abort-controller +!/agent-base +!/agentkeepalive +!/aggregate-error +!/ansi-regex +!/ansi-styles +!/aproba +!/archy +!/are-we-there-yet +!/are-we-there-yet/node_modules/ +/are-we-there-yet/node_modules/* +!/are-we-there-yet/node_modules/buffer +!/are-we-there-yet/node_modules/readable-stream +!/balanced-match +!/base64-js +!/bin-links +!/binary-extensions +!/brace-expansion +!/builtins +!/cacache +!/chalk +!/chownr +!/ci-info +!/cidr-regex +!/clean-stack +!/cli-columns +!/cli-table3 +!/clone +!/cmd-shim +!/color-convert +!/color-name +!/color-support +!/columnify +!/common-ancestor-path +!/concat-map +!/console-control-strings +!/cssesc +!/debug +!/debug/node_modules/ +/debug/node_modules/* +!/debug/node_modules/ms +!/defaults +!/delegates +!/depd +!/diff +!/emoji-regex +!/encoding +!/env-paths +!/err-code +!/event-target-shim +!/events +!/fastest-levenshtein +!/fs-minipass +!/fs-minipass/node_modules/ +/fs-minipass/node_modules/* +!/fs-minipass/node_modules/minipass +!/fs.realpath +!/function-bind +!/gauge +!/glob +!/graceful-fs +!/has-flag +!/has-unicode +!/has +!/hosted-git-info +!/http-cache-semantics +!/http-proxy-agent +!/https-proxy-agent +!/humanize-ms +!/iconv-lite +!/ieee754 +!/ignore-walk +!/imurmurhash +!/indent-string +!/infer-owner +!/inflight +!/inherits +!/ini +!/init-package-json +!/ip-regex +!/ip +!/is-cidr +!/is-core-module +!/is-fullwidth-code-point +!/is-lambda +!/isexe +!/json-parse-even-better-errors +!/json-stringify-nice +!/jsonparse +!/just-diff-apply +!/just-diff +!/libnpmaccess +!/libnpmdiff +!/libnpmexec +!/libnpmfund +!/libnpmhook +!/libnpmorg +!/libnpmpack +!/libnpmpublish +!/libnpmsearch +!/libnpmteam +!/libnpmversion +!/lru-cache +!/make-fetch-happen +!/minimatch +!/minipass-collect +!/minipass-collect/node_modules/ +/minipass-collect/node_modules/* +!/minipass-collect/node_modules/minipass +!/minipass-fetch +!/minipass-fetch/node_modules/ +/minipass-fetch/node_modules/* +!/minipass-fetch/node_modules/minipass +!/minipass-flush +!/minipass-flush/node_modules/ +/minipass-flush/node_modules/* +!/minipass-flush/node_modules/minipass +!/minipass-json-stream +!/minipass-json-stream/node_modules/ +/minipass-json-stream/node_modules/* +!/minipass-json-stream/node_modules/minipass +!/minipass-pipeline +!/minipass-pipeline/node_modules/ +/minipass-pipeline/node_modules/* +!/minipass-pipeline/node_modules/minipass +!/minipass-sized +!/minipass-sized/node_modules/ +/minipass-sized/node_modules/* +!/minipass-sized/node_modules/minipass +!/minipass +!/minizlib +!/minizlib/node_modules/ +/minizlib/node_modules/* +!/minizlib/node_modules/minipass +!/mkdirp +!/ms +!/mute-stream +!/negotiator +!/node-gyp +!/node-gyp/node_modules/ +/node-gyp/node_modules/* +!/node-gyp/node_modules/@npmcli/ +/node-gyp/node_modules/@npmcli/* +!/node-gyp/node_modules/@npmcli/fs +!/node-gyp/node_modules/@npmcli/move-file +!/node-gyp/node_modules/abbrev +!/node-gyp/node_modules/are-we-there-yet +!/node-gyp/node_modules/brace-expansion +!/node-gyp/node_modules/cacache +!/node-gyp/node_modules/cacache/node_modules/ +/node-gyp/node_modules/cacache/node_modules/* +!/node-gyp/node_modules/cacache/node_modules/brace-expansion +!/node-gyp/node_modules/cacache/node_modules/glob +!/node-gyp/node_modules/cacache/node_modules/minimatch +!/node-gyp/node_modules/gauge +!/node-gyp/node_modules/glob +!/node-gyp/node_modules/make-fetch-happen +!/node-gyp/node_modules/minimatch +!/node-gyp/node_modules/minipass-fetch +!/node-gyp/node_modules/minipass +!/node-gyp/node_modules/nopt +!/node-gyp/node_modules/npmlog +!/node-gyp/node_modules/ssri +!/node-gyp/node_modules/unique-filename +!/node-gyp/node_modules/unique-slug +!/node-gyp/node_modules/which +!/nopt +!/normalize-package-data +!/npm-audit-report +!/npm-bundled +!/npm-install-checks +!/npm-normalize-package-bin +!/npm-package-arg +!/npm-packlist +!/npm-pick-manifest +!/npm-profile +!/npm-registry-fetch +!/npm-user-validate +!/npmlog +!/once +!/p-map +!/pacote +!/parse-conflict-json +!/path-is-absolute +!/postcss-selector-parser +!/proc-log +!/process +!/promise-all-reject-late +!/promise-call-limit +!/promise-inflight +!/promise-retry +!/promzard +!/qrcode-terminal +!/read-cmd-shim +!/read-package-json-fast +!/read-package-json +!/read +!/readable-stream +!/retry +!/rimraf +!/rimraf/node_modules/ +/rimraf/node_modules/* +!/rimraf/node_modules/brace-expansion +!/rimraf/node_modules/glob +!/rimraf/node_modules/minimatch +!/safe-buffer +!/safer-buffer +!/semver +!/semver/node_modules/ +/semver/node_modules/* +!/semver/node_modules/lru-cache +!/set-blocking +!/signal-exit +!/smart-buffer +!/socks-proxy-agent +!/socks +!/spdx-correct +!/spdx-exceptions +!/spdx-expression-parse +!/spdx-license-ids +!/ssri +!/string_decoder +!/string-width +!/strip-ansi +!/supports-color +!/tar +!/text-table +!/tiny-relative-date +!/treeverse +!/unique-filename +!/unique-slug +!/util-deprecate +!/validate-npm-package-license +!/validate-npm-package-name +!/walk-up-path +!/wcwidth +!/which +!/wide-align +!/wrappy +!/write-file-atomic +!/yallist +# Always ignore some specific patterns within any allowed package +.bin/ +.cache/ package-lock.json CHANGELOG* changelog* +ChangeLog* +Changelog* README* readme* +ReadMe* +Readme* +__pycache__ .editorconfig .idea/ .npmignore @@ -23,430 +304,3 @@ readme* .babelrc* .nyc_output .gitkeep - -/@babel/code-frame -/@babel/core -/@babel/generator -/@babel/helper-function-name -/@babel/helper-get-function-arity -/@babel/helper-member-expression-to-functions -/@babel/helper-module-imports -/@babel/helper-module-transforms -/@babel/helper-optimise-call-expression -/@babel/helper-plugin-utils -/@babel/helper-replace-supers -/@babel/helper-simple-access -/@babel/helper-split-export-declaration -/@babel/helper-validator-identifier -/@babel/helpers -/@babel/highlight -/@babel/parser -/@babel/plugin-proposal-object-rest-spread -/@babel/plugin-syntax-jsx -/@babel/plugin-syntax-object-rest-spread -/@babel/plugin-transform-parameters -/@babel/template -/@babel/traverse -/@babel/types -/@blueoak/list -/@eslint/eslintrc -/@humanwhocodes/config-array -/@humanwhocodes/object-schema -/@istanbuljs/load-nyc-config -/@istanbuljs/schema -/@mdx-js/mdx -/@mdx-js/util -/@npmcli/eslint-config -/@npmcli/template-oss -/@types/hast -/@types/mdast -/@types/parse5 -/@types/unist -/abab -/acorn -/acorn-globals -/acorn-jsx -/acorn-walk -/ajv -/ansi-colors -/anymatch -/append-transform -/arg -/argparse -/array-find-index -/asn1 -/assert-plus -/assertion-error -/async-hook-domain -/asynckit -/aws-sign2 -/aws4 -/babel-plugin-apply-mdx-type-prop -/babel-plugin-extract-import-names -/bail -/base64-js -/bcrypt-pbkdf -/benchmark -/bind-obj-methods -/bindings -/bl -/braces -/browser-process-hrtime -/buffer -/buffer-from -/caching-transform -/call-bind -/caller -/callsites -/camelcase -/camelcase-css -/caseless -/ccount -/chai -/character-entities -/character-entities-legacy -/character-reference-invalid -/check-error -/chokidar -/cliui -/cmark-gfm -/code-point-at -/collapse-white-space -/combined-stream -/comma-separated-tokens -/commondir -/convert-source-map -/core-util-is -/correct-license-metadata -/coveralls -/cross-spawn -/cssom -/cssstyle -/dashdash -/data-urls -/decamelize -/decimal.js -/decompress-response -/deep-eql -/deep-equal -/deep-extend -/deep-is -/default-require-extensions -/define-properties -/delayed-stream -/detab -/detect-libc -/docopt -/docs -/doctrine -/domexception -/ecc-jsbn -/end-of-stream -/enquirer -/es-abstract -/es-to-primitive -/es6-error -/escape-string-regexp -/escodegen -/eslint -/eslint-plugin-es -/eslint-plugin-node -/eslint-scope -/eslint-utils -/eslint-visitor-keys -/espree -/esprima -/esquery -/esrecurse -/estraverse -/esutils -/events-to-array -/expand-template -/extend -/extsprintf -/fast-deep-equal -/fast-json-stable-stringify -/fast-levenshtein -/file-entry-cache -/file-uri-to-path -/fill-range -/find-cache-dir -/findit -/flat-cache -/flatted -/flow-parser -/flow-remove-types -/foreground-child -/forever-agent -/form-data -/fromentries -/fs-access -/fs-constants -/fs-exists-cached -/fsevents -/function-loop -/functional-red-black-tree -/gensync -/get-caller-file -/get-func-name -/get-intrinsic -/get-package-type -/get-symbol-description -/getpass -/github-from-package -/glob-parent -/globals -/har-schema -/har-validator -/has-bigints -/has-symbols -/has-tostringtag -/hasha -/hast-to-hyperscript -/hast-util-from-parse5 -/hast-util-parse-selector -/hast-util-raw -/hast-util-to-parse5 -/hastscript -/html-encoding-sniffer -/html-escaper -/html-void-elements -/http-signature -/ieee754 -/ignore -/import-fresh -/inline-style-parser -/internal-slot -/is-alphabetical -/is-alphanumerical -/is-arguments -/is-bigint -/is-binary-path -/is-boolean-object -/is-buffer -/is-callable -/is-date-object -/is-decimal -/is-extglob -/is-glob -/is-hexadecimal -/is-negative-zero -/is-number -/is-number-object -/is-plain-obj -/is-potential-custom-element-name -/is-regex -/is-shared-array-buffer -/is-stream -/is-string -/is-symbol -/is-weakref -/is-whitespace-character -/is-windows -/is-word-character -/isarray -/isstream -/istanbul-lib-coverage -/istanbul-lib-hook -/istanbul-lib-instrument -/istanbul-lib-processinfo -/istanbul-lib-report -/istanbul-lib-source-maps -/istanbul-reports -/jackspeak -/js-tokens -/js-yaml -/jsbn -/jsdom -/jsesc -/json-parse-errback -/json-schema -/json-schema-traverse -/json-stable-stringify-without-jsonify -/json-stringify-safe -/json5 -/jsprim -/lcov-parse -/levn -/libtap -/licensee -/lodash -/lodash.clonedeep -/lodash.flattendeep -/lodash.merge -/lodash.set -/lodash.uniq -/log-driver -/make-dir -/make-error -/markdown-escapes -/marked -/marked-man -/mdast-squeeze-paragraphs -/mdast-util-definitions -/mdast-util-to-hast -/mdurl -/mime-db -/mime-types -/mimic-response -/minify-registry-metadata -/minimist -/mkdirp-classic -/napi-build-utils -/natural-compare -/nock -/node-abi -/node-addon-api -/node-modules-regexp -/node-preload -/noop-logger -/normalize-path -/npm-license-corrections -/null-check -/number-is-nan -/nwsapi -/nyc -/oauth-sign -/object-assign -/object-inspect -/object-is -/object-keys -/object.assign -/object.getownpropertydescriptors -/optionator -/own-or -/own-or-env -/package-hash -/parent-module -/parse-entities -/parse5 -/path-key -/path-parse -/pathval -/performance-now -/picomatch -/pirates -/platform -/prebuild-install -/prelude-ls -/process-nextick-args -/process-on-spawn -/progress -/propagate -/property-information -/psl -/pump -/punycode -/qs -/queue-microtask -/rc -/read-package-tree -/readdirp -/regexp.prototype.flags -/regexpp -/release-zalgo -/remark-footnotes -/remark-mdx -/remark-parse -/remark-squeeze-paragraphs -/repeat-string -/request -/require-directory -/require-inject -/require-main-filename -/resolve -/resolve-from -/run-parallel -/saxes -/shebang-command -/shebang-regex -/side-channel -/simple-concat -/simple-get -/source-map -/source-map-support -/space-separated-tokens -/spawk -/spawn-wrap -/spdx-compare -/spdx-expression-validate -/spdx-osi -/spdx-ranges -/spdx-whitelisted -/sprintf-js -/sshpk -/stack-utils -/state-toggle -/string.prototype.trimend -/string.prototype.trimstart -/strip-json-comments -/style-to-object -/symbol-tree -/tap -/tap-mocha-reporter -/tap-parser -/tap-yaml -/tar-fs -/tar-stream -/tcompare -/test-exclude -/to-fast-properties -/to-regex-range -/tough-cookie -/tr46 -/trim -/trim-trailing-lines -/trivial-deferred -/trough -/ts-node -/tunnel-agent -/tweetnacl -/type-check -/type-detect -/type-fest -/typescript -/unbox-primitive -/unherit -/unicode-length -/unified -/unist-builder -/unist-util-generated -/unist-util-is -/unist-util-position -/unist-util-remove -/unist-util-remove-position -/unist-util-stringify-position -/unist-util-visit -/unist-util-visit-parents -/universalify -/uri-js -/util-promisify -/uuid -/v8-compile-cache -/verror -/vfile -/vfile-location -/vfile-message -/vlq -/w3c-hr-time -/w3c-xmlserializer -/web-namespaces -/webidl-conversions -/whatwg-encoding -/whatwg-mimetype -/whatwg-url -/which-boxed-primitive -/which-module -/word-wrap -/wrap-ansi -/ws -/xml-name-validator -/xmlchars -/xtend -/y18n -/yaml -/yapool -/yargs -/yargs-parser -/yn -/zwitch diff --git a/node_modules/@colors/colors/LICENSE b/node_modules/@colors/colors/LICENSE new file mode 100644 index 0000000..6b86056 --- /dev/null +++ b/node_modules/@colors/colors/LICENSE @@ -0,0 +1,26 @@ +MIT License + +Original Library + - Copyright (c) Marak Squires + +Additional Functionality + - Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com) + - Copyright (c) DABH (https://github.com/DABH) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/@colors/colors/examples/normal-usage.js b/node_modules/@colors/colors/examples/normal-usage.js new file mode 100644 index 0000000..a4bfe7b --- /dev/null +++ b/node_modules/@colors/colors/examples/normal-usage.js @@ -0,0 +1,83 @@ +var colors = require('../lib/index'); + +console.log('First some yellow text'.yellow); + +console.log('Underline that text'.yellow.underline); + +console.log('Make it bold and red'.red.bold); + +console.log(('Double Raindows All Day Long').rainbow); + +console.log('Drop the bass'.trap); + +console.log('DROP THE RAINBOW BASS'.trap.rainbow); + +// styles not widely supported +console.log('Chains are also cool.'.bold.italic.underline.red); + +// styles not widely supported +console.log('So '.green + 'are'.underline + ' ' + 'inverse'.inverse + + ' styles! '.yellow.bold); +console.log('Zebras are so fun!'.zebra); + +// +// Remark: .strikethrough may not work with Mac OS Terminal App +// +console.log('This is ' + 'not'.strikethrough + ' fun.'); + +console.log('Background color attack!'.black.bgWhite); +console.log('Use random styles on everything!'.random); +console.log('America, Heck Yeah!'.america); + +// eslint-disable-next-line max-len +console.log('Blindingly '.brightCyan + 'bright? '.brightRed + 'Why '.brightYellow + 'not?!'.brightGreen); + +console.log('Setting themes is useful'); + +// +// Custom themes +// +console.log('Generic logging theme as JSON'.green.bold.underline); +// Load theme with JSON literal +colors.setTheme({ + silly: 'rainbow', + input: 'grey', + verbose: 'cyan', + prompt: 'grey', + info: 'green', + data: 'grey', + help: 'cyan', + warn: 'yellow', + debug: 'blue', + error: 'red', +}); + +// outputs red text +console.log('this is an error'.error); + +// outputs yellow text +console.log('this is a warning'.warn); + +// outputs grey text +console.log('this is an input'.input); + +console.log('Generic logging theme as file'.green.bold.underline); + +// Load a theme from file +try { + colors.setTheme(require(__dirname + '/../themes/generic-logging.js')); +} catch (err) { + console.log(err); +} + +// outputs red text +console.log('this is an error'.error); + +// outputs yellow text +console.log('this is a warning'.warn); + +// outputs grey text +console.log('this is an input'.input); + +// console.log("Don't summon".zalgo) + diff --git a/node_modules/@colors/colors/examples/safe-string.js b/node_modules/@colors/colors/examples/safe-string.js new file mode 100644 index 0000000..fc66474 --- /dev/null +++ b/node_modules/@colors/colors/examples/safe-string.js @@ -0,0 +1,80 @@ +var colors = require('../safe'); + +console.log(colors.yellow('First some yellow text')); + +console.log(colors.yellow.underline('Underline that text')); + +console.log(colors.red.bold('Make it bold and red')); + +console.log(colors.rainbow('Double Raindows All Day Long')); + +console.log(colors.trap('Drop the bass')); + +console.log(colors.rainbow(colors.trap('DROP THE RAINBOW BASS'))); + +// styles not widely supported +console.log(colors.bold.italic.underline.red('Chains are also cool.')); + +// styles not widely supported +console.log(colors.green('So ') + colors.underline('are') + ' ' + + colors.inverse('inverse') + colors.yellow.bold(' styles! ')); + +console.log(colors.zebra('Zebras are so fun!')); + +console.log('This is ' + colors.strikethrough('not') + ' fun.'); + + +console.log(colors.black.bgWhite('Background color attack!')); +console.log(colors.random('Use random styles on everything!')); +console.log(colors.america('America, Heck Yeah!')); + +// eslint-disable-next-line max-len +console.log(colors.brightCyan('Blindingly ') + colors.brightRed('bright? ') + colors.brightYellow('Why ') + colors.brightGreen('not?!')); + +console.log('Setting themes is useful'); + +// +// Custom themes +// +// console.log('Generic logging theme as JSON'.green.bold.underline); +// Load theme with JSON literal +colors.setTheme({ + silly: 'rainbow', + input: 'blue', + verbose: 'cyan', + prompt: 'grey', + info: 'green', + data: 'grey', + help: 'cyan', + warn: 'yellow', + debug: 'blue', + error: 'red', +}); + +// outputs red text +console.log(colors.error('this is an error')); + +// outputs yellow text +console.log(colors.warn('this is a warning')); + +// outputs blue text +console.log(colors.input('this is an input')); + + +// console.log('Generic logging theme as file'.green.bold.underline); + +// Load a theme from file +colors.setTheme(require(__dirname + '/../themes/generic-logging.js')); + +// outputs red text +console.log(colors.error('this is an error')); + +// outputs yellow text +console.log(colors.warn('this is a warning')); + +// outputs grey text +console.log(colors.input('this is an input')); + +// console.log(colors.zalgo("Don't summon him")) + + diff --git a/node_modules/@colors/colors/index.d.ts b/node_modules/@colors/colors/index.d.ts new file mode 100644 index 0000000..df3f2e6 --- /dev/null +++ b/node_modules/@colors/colors/index.d.ts @@ -0,0 +1,136 @@ +// Type definitions for @colors/colors 1.4+ +// Project: https://github.com/Marak/colors.js +// Definitions by: Bart van der Schoor <https://github.com/Bartvds>, Staffan Eketorp <https://github.com/staeke> +// Definitions: https://github.com/DABH/colors.js + +export interface Color { + (text: string): string; + + strip: Color; + stripColors: Color; + + black: Color; + red: Color; + green: Color; + yellow: Color; + blue: Color; + magenta: Color; + cyan: Color; + white: Color; + gray: Color; + grey: Color; + + bgBlack: Color; + bgRed: Color; + bgGreen: Color; + bgYellow: Color; + bgBlue: Color; + bgMagenta: Color; + bgCyan: Color; + bgWhite: Color; + + reset: Color; + bold: Color; + dim: Color; + italic: Color; + underline: Color; + inverse: Color; + hidden: Color; + strikethrough: Color; + + rainbow: Color; + zebra: Color; + america: Color; + trap: Color; + random: Color; + zalgo: Color; +} + +export function enable(): void; +export function disable(): void; +export function setTheme(theme: any): void; + +export let enabled: boolean; + +export const strip: Color; +export const stripColors: Color; + +export const black: Color; +export const red: Color; +export const green: Color; +export const yellow: Color; +export const blue: Color; +export const magenta: Color; +export const cyan: Color; +export const white: Color; +export const gray: Color; +export const grey: Color; + +export const bgBlack: Color; +export const bgRed: Color; +export const bgGreen: Color; +export const bgYellow: Color; +export const bgBlue: Color; +export const bgMagenta: Color; +export const bgCyan: Color; +export const bgWhite: Color; + +export const reset: Color; +export const bold: Color; +export const dim: Color; +export const italic: Color; +export const underline: Color; +export const inverse: Color; +export const hidden: Color; +export const strikethrough: Color; + +export const rainbow: Color; +export const zebra: Color; +export const america: Color; +export const trap: Color; +export const random: Color; +export const zalgo: Color; + +declare global { + interface String { + strip: string; + stripColors: string; + + black: string; + red: string; + green: string; + yellow: string; + blue: string; + magenta: string; + cyan: string; + white: string; + gray: string; + grey: string; + + bgBlack: string; + bgRed: string; + bgGreen: string; + bgYellow: string; + bgBlue: string; + bgMagenta: string; + bgCyan: string; + bgWhite: string; + + reset: string; + // @ts-ignore + bold: string; + dim: string; + italic: string; + underline: string; + inverse: string; + hidden: string; + strikethrough: string; + + rainbow: string; + zebra: string; + america: string; + trap: string; + random: string; + zalgo: string; + } +} diff --git a/node_modules/@colors/colors/lib/colors.js b/node_modules/@colors/colors/lib/colors.js new file mode 100644 index 0000000..d9fb087 --- /dev/null +++ b/node_modules/@colors/colors/lib/colors.js @@ -0,0 +1,211 @@ +/* + +The MIT License (MIT) + +Original Library + - Copyright (c) Marak Squires + +Additional functionality + - Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +*/ + +var colors = {}; +module['exports'] = colors; + +colors.themes = {}; + +var util = require('util'); +var ansiStyles = colors.styles = require('./styles'); +var defineProps = Object.defineProperties; +var newLineRegex = new RegExp(/[\r\n]+/g); + +colors.supportsColor = require('./system/supports-colors').supportsColor; + +if (typeof colors.enabled === 'undefined') { + colors.enabled = colors.supportsColor() !== false; +} + +colors.enable = function() { + colors.enabled = true; +}; + +colors.disable = function() { + colors.enabled = false; +}; + +colors.stripColors = colors.strip = function(str) { + return ('' + str).replace(/\x1B\[\d+m/g, ''); +}; + +// eslint-disable-next-line no-unused-vars +var stylize = colors.stylize = function stylize(str, style) { + if (!colors.enabled) { + return str+''; + } + + var styleMap = ansiStyles[style]; + + // Stylize should work for non-ANSI styles, too + if (!styleMap && style in colors) { + // Style maps like trap operate as functions on strings; + // they don't have properties like open or close. + return colors[style](str); + } + + return styleMap.open + str + styleMap.close; +}; + +var matchOperatorsRe = /[|\\{}()[\]^$+*?.]/g; +var escapeStringRegexp = function(str) { + if (typeof str !== 'string') { + throw new TypeError('Expected a string'); + } + return str.replace(matchOperatorsRe, '\\$&'); +}; + +function build(_styles) { + var builder = function builder() { + return applyStyle.apply(builder, arguments); + }; + builder._styles = _styles; + // __proto__ is used because we must return a function, but there is + // no way to create a function with a different prototype. + builder.__proto__ = proto; + return builder; +} + +var styles = (function() { + var ret = {}; + ansiStyles.grey = ansiStyles.gray; + Object.keys(ansiStyles).forEach(function(key) { + ansiStyles[key].closeRe = + new RegExp(escapeStringRegexp(ansiStyles[key].close), 'g'); + ret[key] = { + get: function() { + return build(this._styles.concat(key)); + }, + }; + }); + return ret; +})(); + +var proto = defineProps(function colors() {}, styles); + +function applyStyle() { + var args = Array.prototype.slice.call(arguments); + + var str = args.map(function(arg) { + // Use weak equality check so we can colorize null/undefined in safe mode + if (arg != null && arg.constructor === String) { + return arg; + } else { + return util.inspect(arg); + } + }).join(' '); + + if (!colors.enabled || !str) { + return str; + } + + var newLinesPresent = str.indexOf('\n') != -1; + + var nestedStyles = this._styles; + + var i = nestedStyles.length; + while (i--) { + var code = ansiStyles[nestedStyles[i]]; + str = code.open + str.replace(code.closeRe, code.open) + code.close; + if (newLinesPresent) { + str = str.replace(newLineRegex, function(match) { + return code.close + match + code.open; + }); + } + } + + return str; +} + +colors.setTheme = function(theme) { + if (typeof theme === 'string') { + console.log('colors.setTheme now only accepts an object, not a string. ' + + 'If you are trying to set a theme from a file, it is now your (the ' + + 'caller\'s) responsibility to require the file. The old syntax ' + + 'looked like colors.setTheme(__dirname + ' + + '\'/../themes/generic-logging.js\'); The new syntax looks like '+ + 'colors.setTheme(require(__dirname + ' + + '\'/../themes/generic-logging.js\'));'); + return; + } + for (var style in theme) { + (function(style) { + colors[style] = function(str) { + if (typeof theme[style] === 'object') { + var out = str; + for (var i in theme[style]) { + out = colors[theme[style][i]](out); + } + return out; + } + return colors[theme[style]](str); + }; + })(style); + } +}; + +function init() { + var ret = {}; + Object.keys(styles).forEach(function(name) { + ret[name] = { + get: function() { + return build([name]); + }, + }; + }); + return ret; +} + +var sequencer = function sequencer(map, str) { + var exploded = str.split(''); + exploded = exploded.map(map); + return exploded.join(''); +}; + +// custom formatter methods +colors.trap = require('./custom/trap'); +colors.zalgo = require('./custom/zalgo'); + +// maps +colors.maps = {}; +colors.maps.america = require('./maps/america')(colors); +colors.maps.zebra = require('./maps/zebra')(colors); +colors.maps.rainbow = require('./maps/rainbow')(colors); +colors.maps.random = require('./maps/random')(colors); + +for (var map in colors.maps) { + (function(map) { + colors[map] = function(str) { + return sequencer(colors.maps[map], str); + }; + })(map); +} + +defineProps(colors, init()); diff --git a/node_modules/@colors/colors/lib/custom/trap.js b/node_modules/@colors/colors/lib/custom/trap.js new file mode 100644 index 0000000..fbccf88 --- /dev/null +++ b/node_modules/@colors/colors/lib/custom/trap.js @@ -0,0 +1,46 @@ +module['exports'] = function runTheTrap(text, options) { + var result = ''; + text = text || 'Run the trap, drop the bass'; + text = text.split(''); + var trap = { + a: ['\u0040', '\u0104', '\u023a', '\u0245', '\u0394', '\u039b', '\u0414'], + b: ['\u00df', '\u0181', '\u0243', '\u026e', '\u03b2', '\u0e3f'], + c: ['\u00a9', '\u023b', '\u03fe'], + d: ['\u00d0', '\u018a', '\u0500', '\u0501', '\u0502', '\u0503'], + e: ['\u00cb', '\u0115', '\u018e', '\u0258', '\u03a3', '\u03be', '\u04bc', + '\u0a6c'], + f: ['\u04fa'], + g: ['\u0262'], + h: ['\u0126', '\u0195', '\u04a2', '\u04ba', '\u04c7', '\u050a'], + i: ['\u0f0f'], + j: ['\u0134'], + k: ['\u0138', '\u04a0', '\u04c3', '\u051e'], + l: ['\u0139'], + m: ['\u028d', '\u04cd', '\u04ce', '\u0520', '\u0521', '\u0d69'], + n: ['\u00d1', '\u014b', '\u019d', '\u0376', '\u03a0', '\u048a'], + o: ['\u00d8', '\u00f5', '\u00f8', '\u01fe', '\u0298', '\u047a', '\u05dd', + '\u06dd', '\u0e4f'], + p: ['\u01f7', '\u048e'], + q: ['\u09cd'], + r: ['\u00ae', '\u01a6', '\u0210', '\u024c', '\u0280', '\u042f'], + s: ['\u00a7', '\u03de', '\u03df', '\u03e8'], + t: ['\u0141', '\u0166', '\u0373'], + u: ['\u01b1', '\u054d'], + v: ['\u05d8'], + w: ['\u0428', '\u0460', '\u047c', '\u0d70'], + x: ['\u04b2', '\u04fe', '\u04fc', '\u04fd'], + y: ['\u00a5', '\u04b0', '\u04cb'], + z: ['\u01b5', '\u0240'], + }; + text.forEach(function(c) { + c = c.toLowerCase(); + var chars = trap[c] || [' ']; + var rand = Math.floor(Math.random() * chars.length); + if (typeof trap[c] !== 'undefined') { + result += trap[c][rand]; + } else { + result += c; + } + }); + return result; +}; diff --git a/node_modules/@colors/colors/lib/custom/zalgo.js b/node_modules/@colors/colors/lib/custom/zalgo.js new file mode 100644 index 0000000..0ef2b01 --- /dev/null +++ b/node_modules/@colors/colors/lib/custom/zalgo.js @@ -0,0 +1,110 @@ +// please no +module['exports'] = function zalgo(text, options) { + text = text || ' he is here '; + var soul = { + 'up': [ + '̍', '̎', '̄', '̅', + '̿', '̑', '̆', '̐', + '͒', '͗', '͑', '̇', + '̈', '̊', '͂', '̓', + '̈', '͊', '͋', '͌', + '̃', '̂', '̌', '͐', + '̀', '́', '̋', '̏', + '̒', '̓', '̔', '̽', + '̉', 'ͣ', 'ͤ', 'ͥ', + 'ͦ', 'ͧ', 'ͨ', 'ͩ', + 'ͪ', 'ͫ', 'ͬ', 'ͭ', + 'ͮ', 'ͯ', '̾', '͛', + '͆', '̚', + ], + 'down': [ + '̖', '̗', '̘', '̙', + '̜', '̝', '̞', '̟', + '̠', '̤', '̥', '̦', + '̩', '̪', '̫', '̬', + '̭', '̮', '̯', '̰', + '̱', '̲', '̳', '̹', + '̺', '̻', '̼', 'ͅ', + '͇', '͈', '͉', '͍', + '͎', '͓', '͔', '͕', + '͖', '͙', '͚', '̣', + ], + 'mid': [ + '̕', '̛', '̀', '́', + '͘', '̡', '̢', '̧', + '̨', '̴', '̵', '̶', + '͜', '͝', '͞', + '͟', '͠', '͢', '̸', + '̷', '͡', ' ҉', + ], + }; + var all = [].concat(soul.up, soul.down, soul.mid); + + function randomNumber(range) { + var r = Math.floor(Math.random() * range); + return r; + } + + function isChar(character) { + var bool = false; + all.filter(function(i) { + bool = (i === character); + }); + return bool; + } + + + function heComes(text, options) { + var result = ''; + var counts; + var l; + options = options || {}; + options['up'] = + typeof options['up'] !== 'undefined' ? options['up'] : true; + options['mid'] = + typeof options['mid'] !== 'undefined' ? options['mid'] : true; + options['down'] = + typeof options['down'] !== 'undefined' ? options['down'] : true; + options['size'] = + typeof options['size'] !== 'undefined' ? options['size'] : 'maxi'; + text = text.split(''); + for (l in text) { + if (isChar(l)) { + continue; + } + result = result + text[l]; + counts = {'up': 0, 'down': 0, 'mid': 0}; + switch (options.size) { + case 'mini': + counts.up = randomNumber(8); + counts.mid = randomNumber(2); + counts.down = randomNumber(8); + break; + case 'maxi': + counts.up = randomNumber(16) + 3; + counts.mid = randomNumber(4) + 1; + counts.down = randomNumber(64) + 3; + break; + default: + counts.up = randomNumber(8) + 1; + counts.mid = randomNumber(6) / 2; + counts.down = randomNumber(8) + 1; + break; + } + + var arr = ['up', 'mid', 'down']; + for (var d in arr) { + var index = arr[d]; + for (var i = 0; i <= counts[index]; i++) { + if (options[index]) { + result = result + soul[index][randomNumber(soul[index].length)]; + } + } + } + } + return result; + } + // don't summon him + return heComes(text, options); +}; + diff --git a/node_modules/@colors/colors/lib/extendStringPrototype.js b/node_modules/@colors/colors/lib/extendStringPrototype.js new file mode 100644 index 0000000..46fd386 --- /dev/null +++ b/node_modules/@colors/colors/lib/extendStringPrototype.js @@ -0,0 +1,110 @@ +var colors = require('./colors'); + +module['exports'] = function() { + // + // Extends prototype of native string object to allow for "foo".red syntax + // + var addProperty = function(color, func) { + String.prototype.__defineGetter__(color, func); + }; + + addProperty('strip', function() { + return colors.strip(this); + }); + + addProperty('stripColors', function() { + return colors.strip(this); + }); + + addProperty('trap', function() { + return colors.trap(this); + }); + + addProperty('zalgo', function() { + return colors.zalgo(this); + }); + + addProperty('zebra', function() { + return colors.zebra(this); + }); + + addProperty('rainbow', function() { + return colors.rainbow(this); + }); + + addProperty('random', function() { + return colors.random(this); + }); + + addProperty('america', function() { + return colors.america(this); + }); + + // + // Iterate through all default styles and colors + // + var x = Object.keys(colors.styles); + x.forEach(function(style) { + addProperty(style, function() { + return colors.stylize(this, style); + }); + }); + + function applyTheme(theme) { + // + // Remark: This is a list of methods that exist + // on String that you should not overwrite. + // + var stringPrototypeBlacklist = [ + '__defineGetter__', '__defineSetter__', '__lookupGetter__', + '__lookupSetter__', 'charAt', 'constructor', 'hasOwnProperty', + 'isPrototypeOf', 'propertyIsEnumerable', 'toLocaleString', 'toString', + 'valueOf', 'charCodeAt', 'indexOf', 'lastIndexOf', 'length', + 'localeCompare', 'match', 'repeat', 'replace', 'search', 'slice', + 'split', 'substring', 'toLocaleLowerCase', 'toLocaleUpperCase', + 'toLowerCase', 'toUpperCase', 'trim', 'trimLeft', 'trimRight', + ]; + + Object.keys(theme).forEach(function(prop) { + if (stringPrototypeBlacklist.indexOf(prop) !== -1) { + console.log('warn: '.red + ('String.prototype' + prop).magenta + + ' is probably something you don\'t want to override. ' + + 'Ignoring style name'); + } else { + if (typeof(theme[prop]) === 'string') { + colors[prop] = colors[theme[prop]]; + addProperty(prop, function() { + return colors[prop](this); + }); + } else { + var themePropApplicator = function(str) { + var ret = str || this; + for (var t = 0; t < theme[prop].length; t++) { + ret = colors[theme[prop][t]](ret); + } + return ret; + }; + addProperty(prop, themePropApplicator); + colors[prop] = function(str) { + return themePropApplicator(str); + }; + } + } + }); + } + + colors.setTheme = function(theme) { + if (typeof theme === 'string') { + console.log('colors.setTheme now only accepts an object, not a string. ' + + 'If you are trying to set a theme from a file, it is now your (the ' + + 'caller\'s) responsibility to require the file. The old syntax ' + + 'looked like colors.setTheme(__dirname + ' + + '\'/../themes/generic-logging.js\'); The new syntax looks like '+ + 'colors.setTheme(require(__dirname + ' + + '\'/../themes/generic-logging.js\'));'); + return; + } else { + applyTheme(theme); + } + }; +}; diff --git a/node_modules/@colors/colors/lib/index.js b/node_modules/@colors/colors/lib/index.js new file mode 100644 index 0000000..9df5ab7 --- /dev/null +++ b/node_modules/@colors/colors/lib/index.js @@ -0,0 +1,13 @@ +var colors = require('./colors'); +module['exports'] = colors; + +// Remark: By default, colors will add style properties to String.prototype. +// +// If you don't wish to extend String.prototype, you can do this instead and +// native String will not be touched: +// +// var colors = require('colors/safe); +// colors.red("foo") +// +// +require('./extendStringPrototype')(); diff --git a/node_modules/@colors/colors/lib/maps/america.js b/node_modules/@colors/colors/lib/maps/america.js new file mode 100644 index 0000000..dc96903 --- /dev/null +++ b/node_modules/@colors/colors/lib/maps/america.js @@ -0,0 +1,10 @@ +module['exports'] = function(colors) { + return function(letter, i, exploded) { + if (letter === ' ') return letter; + switch (i%3) { + case 0: return colors.red(letter); + case 1: return colors.white(letter); + case 2: return colors.blue(letter); + } + }; +}; diff --git a/node_modules/@colors/colors/lib/maps/rainbow.js b/node_modules/@colors/colors/lib/maps/rainbow.js new file mode 100644 index 0000000..2b00ac0 --- /dev/null +++ b/node_modules/@colors/colors/lib/maps/rainbow.js @@ -0,0 +1,12 @@ +module['exports'] = function(colors) { + // RoY G BiV + var rainbowColors = ['red', 'yellow', 'green', 'blue', 'magenta']; + return function(letter, i, exploded) { + if (letter === ' ') { + return letter; + } else { + return colors[rainbowColors[i++ % rainbowColors.length]](letter); + } + }; +}; + diff --git a/node_modules/@colors/colors/lib/maps/random.js b/node_modules/@colors/colors/lib/maps/random.js new file mode 100644 index 0000000..3d82a39 --- /dev/null +++ b/node_modules/@colors/colors/lib/maps/random.js @@ -0,0 +1,11 @@ +module['exports'] = function(colors) { + var available = ['underline', 'inverse', 'grey', 'yellow', 'red', 'green', + 'blue', 'white', 'cyan', 'magenta', 'brightYellow', 'brightRed', + 'brightGreen', 'brightBlue', 'brightWhite', 'brightCyan', 'brightMagenta']; + return function(letter, i, exploded) { + return letter === ' ' ? letter : + colors[ + available[Math.round(Math.random() * (available.length - 2))] + ](letter); + }; +}; diff --git a/node_modules/@colors/colors/lib/maps/zebra.js b/node_modules/@colors/colors/lib/maps/zebra.js new file mode 100644 index 0000000..fa73623 --- /dev/null +++ b/node_modules/@colors/colors/lib/maps/zebra.js @@ -0,0 +1,5 @@ +module['exports'] = function(colors) { + return function(letter, i, exploded) { + return i % 2 === 0 ? letter : colors.inverse(letter); + }; +}; diff --git a/node_modules/@colors/colors/lib/styles.js b/node_modules/@colors/colors/lib/styles.js new file mode 100644 index 0000000..011dafd --- /dev/null +++ b/node_modules/@colors/colors/lib/styles.js @@ -0,0 +1,95 @@ +/* +The MIT License (MIT) + +Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +*/ + +var styles = {}; +module['exports'] = styles; + +var codes = { + reset: [0, 0], + + bold: [1, 22], + dim: [2, 22], + italic: [3, 23], + underline: [4, 24], + inverse: [7, 27], + hidden: [8, 28], + strikethrough: [9, 29], + + black: [30, 39], + red: [31, 39], + green: [32, 39], + yellow: [33, 39], + blue: [34, 39], + magenta: [35, 39], + cyan: [36, 39], + white: [37, 39], + gray: [90, 39], + grey: [90, 39], + + brightRed: [91, 39], + brightGreen: [92, 39], + brightYellow: [93, 39], + brightBlue: [94, 39], + brightMagenta: [95, 39], + brightCyan: [96, 39], + brightWhite: [97, 39], + + bgBlack: [40, 49], + bgRed: [41, 49], + bgGreen: [42, 49], + bgYellow: [43, 49], + bgBlue: [44, 49], + bgMagenta: [45, 49], + bgCyan: [46, 49], + bgWhite: [47, 49], + bgGray: [100, 49], + bgGrey: [100, 49], + + bgBrightRed: [101, 49], + bgBrightGreen: [102, 49], + bgBrightYellow: [103, 49], + bgBrightBlue: [104, 49], + bgBrightMagenta: [105, 49], + bgBrightCyan: [106, 49], + bgBrightWhite: [107, 49], + + // legacy styles for colors pre v1.0.0 + blackBG: [40, 49], + redBG: [41, 49], + greenBG: [42, 49], + yellowBG: [43, 49], + blueBG: [44, 49], + magentaBG: [45, 49], + cyanBG: [46, 49], + whiteBG: [47, 49], + +}; + +Object.keys(codes).forEach(function(key) { + var val = codes[key]; + var style = styles[key] = []; + style.open = '\u001b[' + val[0] + 'm'; + style.close = '\u001b[' + val[1] + 'm'; +}); diff --git a/node_modules/@colors/colors/lib/system/has-flag.js b/node_modules/@colors/colors/lib/system/has-flag.js new file mode 100644 index 0000000..a347dd4 --- /dev/null +++ b/node_modules/@colors/colors/lib/system/has-flag.js @@ -0,0 +1,35 @@ +/* +MIT License + +Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ + +'use strict'; + +module.exports = function(flag, argv) { + argv = argv || process.argv; + + var terminatorPos = argv.indexOf('--'); + var prefix = /^-{1,2}/.test(flag) ? '' : '--'; + var pos = argv.indexOf(prefix + flag); + + return pos !== -1 && (terminatorPos === -1 ? true : pos < terminatorPos); +}; diff --git a/node_modules/@colors/colors/lib/system/supports-colors.js b/node_modules/@colors/colors/lib/system/supports-colors.js new file mode 100644 index 0000000..f1f9c8f --- /dev/null +++ b/node_modules/@colors/colors/lib/system/supports-colors.js @@ -0,0 +1,151 @@ +/* +The MIT License (MIT) + +Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +*/ + +'use strict'; + +var os = require('os'); +var hasFlag = require('./has-flag.js'); + +var env = process.env; + +var forceColor = void 0; +if (hasFlag('no-color') || hasFlag('no-colors') || hasFlag('color=false')) { + forceColor = false; +} else if (hasFlag('color') || hasFlag('colors') || hasFlag('color=true') + || hasFlag('color=always')) { + forceColor = true; +} +if ('FORCE_COLOR' in env) { + forceColor = env.FORCE_COLOR.length === 0 + || parseInt(env.FORCE_COLOR, 10) !== 0; +} + +function translateLevel(level) { + if (level === 0) { + return false; + } + + return { + level: level, + hasBasic: true, + has256: level >= 2, + has16m: level >= 3, + }; +} + +function supportsColor(stream) { + if (forceColor === false) { + return 0; + } + + if (hasFlag('color=16m') || hasFlag('color=full') + || hasFlag('color=truecolor')) { + return 3; + } + + if (hasFlag('color=256')) { + return 2; + } + + if (stream && !stream.isTTY && forceColor !== true) { + return 0; + } + + var min = forceColor ? 1 : 0; + + if (process.platform === 'win32') { + // Node.js 7.5.0 is the first version of Node.js to include a patch to + // libuv that enables 256 color output on Windows. Anything earlier and it + // won't work. However, here we target Node.js 8 at minimum as it is an LTS + // release, and Node.js 7 is not. Windows 10 build 10586 is the first + // Windows release that supports 256 colors. Windows 10 build 14931 is the + // first release that supports 16m/TrueColor. + var osRelease = os.release().split('.'); + if (Number(process.versions.node.split('.')[0]) >= 8 + && Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) { + return Number(osRelease[2]) >= 14931 ? 3 : 2; + } + + return 1; + } + + if ('CI' in env) { + if (['TRAVIS', 'CIRCLECI', 'APPVEYOR', 'GITLAB_CI'].some(function(sign) { + return sign in env; + }) || env.CI_NAME === 'codeship') { + return 1; + } + + return min; + } + + if ('TEAMCITY_VERSION' in env) { + return (/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(env.TEAMCITY_VERSION) ? 1 : 0 + ); + } + + if ('TERM_PROGRAM' in env) { + var version = parseInt((env.TERM_PROGRAM_VERSION || '').split('.')[0], 10); + + switch (env.TERM_PROGRAM) { + case 'iTerm.app': + return version >= 3 ? 3 : 2; + case 'Hyper': + return 3; + case 'Apple_Terminal': + return 2; + // No default + } + } + + if (/-256(color)?$/i.test(env.TERM)) { + return 2; + } + + if (/^screen|^xterm|^vt100|^rxvt|color|ansi|cygwin|linux/i.test(env.TERM)) { + return 1; + } + + if ('COLORTERM' in env) { + return 1; + } + + if (env.TERM === 'dumb') { + return min; + } + + return min; +} + +function getSupportLevel(stream) { + var level = supportsColor(stream); + return translateLevel(level); +} + +module.exports = { + supportsColor: getSupportLevel, + stdout: getSupportLevel(process.stdout), + stderr: getSupportLevel(process.stderr), +}; diff --git a/node_modules/@colors/colors/package.json b/node_modules/@colors/colors/package.json new file mode 100644 index 0000000..cb87f20 --- /dev/null +++ b/node_modules/@colors/colors/package.json @@ -0,0 +1,45 @@ +{ + "name": "@colors/colors", + "description": "get colors in your node.js console", + "version": "1.5.0", + "author": "DABH", + "contributors": [ + { + "name": "DABH", + "url": "https://github.com/DABH" + } + ], + "homepage": "https://github.com/DABH/colors.js", + "bugs": "https://github.com/DABH/colors.js/issues", + "keywords": [ + "ansi", + "terminal", + "colors" + ], + "repository": { + "type": "git", + "url": "http://github.com/DABH/colors.js.git" + }, + "license": "MIT", + "scripts": { + "lint": "eslint . --fix", + "test": "export FORCE_COLOR=1 && node tests/basic-test.js && node tests/safe-test.js" + }, + "engines": { + "node": ">=0.1.90" + }, + "main": "lib/index.js", + "files": [ + "examples", + "lib", + "LICENSE", + "safe.js", + "themes", + "index.d.ts", + "safe.d.ts" + ], + "devDependencies": { + "eslint": "^5.2.0", + "eslint-config-google": "^0.11.0" + } +} diff --git a/node_modules/@colors/colors/safe.d.ts b/node_modules/@colors/colors/safe.d.ts new file mode 100644 index 0000000..2bafc27 --- /dev/null +++ b/node_modules/@colors/colors/safe.d.ts @@ -0,0 +1,48 @@ +// Type definitions for Colors.js 1.2 +// Project: https://github.com/Marak/colors.js +// Definitions by: Bart van der Schoor <https://github.com/Bartvds>, Staffan Eketorp <https://github.com/staeke> +// Definitions: https://github.com/Marak/colors.js + +export const enabled: boolean; +export function enable(): void; +export function disable(): void; +export function setTheme(theme: any): void; + +export function strip(str: string): string; +export function stripColors(str: string): string; + +export function black(str: string): string; +export function red(str: string): string; +export function green(str: string): string; +export function yellow(str: string): string; +export function blue(str: string): string; +export function magenta(str: string): string; +export function cyan(str: string): string; +export function white(str: string): string; +export function gray(str: string): string; +export function grey(str: string): string; + +export function bgBlack(str: string): string; +export function bgRed(str: string): string; +export function bgGreen(str: string): string; +export function bgYellow(str: string): string; +export function bgBlue(str: string): string; +export function bgMagenta(str: string): string; +export function bgCyan(str: string): string; +export function bgWhite(str: string): string; + +export function reset(str: string): string; +export function bold(str: string): string; +export function dim(str: string): string; +export function italic(str: string): string; +export function underline(str: string): string; +export function inverse(str: string): string; +export function hidden(str: string): string; +export function strikethrough(str: string): string; + +export function rainbow(str: string): string; +export function zebra(str: string): string; +export function america(str: string): string; +export function trap(str: string): string; +export function random(str: string): string; +export function zalgo(str: string): string; diff --git a/node_modules/@colors/colors/safe.js b/node_modules/@colors/colors/safe.js new file mode 100644 index 0000000..a013d54 --- /dev/null +++ b/node_modules/@colors/colors/safe.js @@ -0,0 +1,10 @@ +// +// Remark: Requiring this file will use the "safe" colors API, +// which will not touch String.prototype. +// +// var colors = require('colors/safe'); +// colors.red("foo") +// +// +var colors = require('./lib/colors'); +module['exports'] = colors; diff --git a/node_modules/@colors/colors/themes/generic-logging.js b/node_modules/@colors/colors/themes/generic-logging.js new file mode 100644 index 0000000..63adfe4 --- /dev/null +++ b/node_modules/@colors/colors/themes/generic-logging.js @@ -0,0 +1,12 @@ +module['exports'] = { + silly: 'rainbow', + input: 'grey', + verbose: 'cyan', + prompt: 'grey', + info: 'green', + data: 'grey', + help: 'cyan', + warn: 'yellow', + debug: 'blue', + error: 'red', +}; diff --git a/node_modules/@gar/promisify/index.js b/node_modules/@gar/promisify/index.js deleted file mode 100644 index d0be95f..0000000 --- a/node_modules/@gar/promisify/index.js +++ /dev/null @@ -1,36 +0,0 @@ -'use strict' - -const { promisify } = require('util') - -const handler = { - get: function (target, prop, receiver) { - if (typeof target[prop] !== 'function') { - return target[prop] - } - if (target[prop][promisify.custom]) { - return function () { - return Reflect.get(target, prop, receiver)[promisify.custom].apply(target, arguments) - } - } - return function () { - return new Promise((resolve, reject) => { - Reflect.get(target, prop, receiver).apply(target, [...arguments, function (err, result) { - if (err) { - return reject(err) - } - resolve(result) - }]) - }) - } - } -} - -module.exports = function (thingToPromisify) { - if (typeof thingToPromisify === 'function') { - return promisify(thingToPromisify) - } - if (typeof thingToPromisify === 'object') { - return new Proxy(thingToPromisify, handler) - } - throw new TypeError('Can only promisify functions or objects') -} diff --git a/node_modules/@gar/promisify/package.json b/node_modules/@gar/promisify/package.json deleted file mode 100644 index b514087..0000000 --- a/node_modules/@gar/promisify/package.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "name": "@gar/promisify", - "version": "1.1.2", - "description": "Promisify an entire class or object", - "main": "index.js", - "repository": { - "type": "git", - "url": "https://github.com/wraithgar/gar-promisify.git" - }, - "scripts": { - "lint": "standard", - "lint:fix": "standard --fix", - "test": "lab -a @hapi/code -t 100", - "posttest": "npm run lint" - }, - "files": [ - "index.js" - ], - "keywords": [ - "promisify", - "all", - "class", - "object" - ], - "author": "Gar <gar+npm@danger.computer>", - "license": "MIT", - "devDependencies": { - "@hapi/code": "^8.0.1", - "@hapi/lab": "^24.1.0", - "standard": "^16.0.3" - } -} diff --git a/node_modules/@npmcli/ci-detect/lib/index.js b/node_modules/@npmcli/ci-detect/lib/index.js deleted file mode 100644 index 8be8fe2..0000000 --- a/node_modules/@npmcli/ci-detect/lib/index.js +++ /dev/null @@ -1,51 +0,0 @@ -module.exports = () => - process.env.GERRIT_PROJECT ? 'gerrit' - : process.env.SYSTEM_TEAMFOUNDATIONCOLLECTIONURI ? 'azure-pipelines' - : process.env.BITRISE_IO ? 'bitrise' - : process.env.BUDDY_WORKSPACE_ID ? 'buddy' - : process.env.BUILDKITE ? 'buildkite' - : process.env.CIRRUS_CI ? 'cirrus' - : process.env.GITLAB_CI ? 'gitlab' - : process.env.APPVEYOR ? 'appveyor' - : process.env.CIRCLECI ? 'circle-ci' - : process.env.SEMAPHORE ? 'semaphore' - : process.env.DRONE ? 'drone' - : process.env.DSARI ? 'dsari' - : process.env.GITHUB_ACTION ? 'github-actions' - : process.env.TDDIUM ? 'tddium' - : process.env.SCREWDRIVER ? 'screwdriver' - : process.env.STRIDER ? 'strider' - : process.env.TASKCLUSTER_ROOT_URL ? 'taskcluster' - : process.env.JENKINS_URL ? 'jenkins' - : process.env['bamboo.buildKey'] ? 'bamboo' - : process.env.GO_PIPELINE_NAME ? 'gocd' - : process.env.HUDSON_URL ? 'hudson' - : process.env.WERCKER ? 'wercker' - : process.env.NETLIFY ? 'netlify' - : process.env.NOW_GITHUB_DEPLOYMENT ? 'now-github' - : process.env.GITLAB_DEPLOYMENT ? 'now-gitlab' - : process.env.BITBUCKET_DEPLOYMENT ? 'now-bitbucket' - : process.env.BITBUCKET_BUILD_NUMBER ? 'bitbucket-pipelines' - : process.env.NOW_BUILDER ? 'now' - : process.env.VERCEL_GITHUB_DEPLOYMENT ? 'vercel-github' - : process.env.VERCEL_GITLAB_DEPLOYMENT ? 'vercel-gitlab' - : process.env.VERCEL_BITBUCKET_DEPLOYMENT ? 'vercel-bitbucket' - : process.env.VERCEL_URL ? 'vercel' - : process.env.MAGNUM ? 'magnum' - : process.env.NEVERCODE ? 'nevercode' - : process.env.RENDER ? 'render' - : process.env.SAIL_CI ? 'sail' - : process.env.SHIPPABLE ? 'shippable' - : process.env.TEAMCITY_VERSION ? 'teamcity' - // codeship and a few others - : process.env.CI_NAME ? process.env.CI_NAME - // heroku doesn't set envs other than node in a heroku-specific location - : /\/\.heroku\/node\/bin\/node$/.test(process.env.NODE || '') ? 'heroku' - // test travis after the others, since several CI systems mimic it - : process.env.TRAVIS ? 'travis-ci' - // aws CodeBuild/CodePipeline - : process.env.CODEBUILD_SRC_DIR ? 'aws-codebuild' - : process.env.CI === 'true' || process.env.CI === '1' ? 'custom' - // Google Cloud Build - it sets almost nothing - : process.env.BUILDER_OUTPUT ? 'builder' - : false diff --git a/node_modules/@npmcli/ci-detect/package.json b/node_modules/@npmcli/ci-detect/package.json deleted file mode 100644 index c1cf9dc..0000000 --- a/node_modules/@npmcli/ci-detect/package.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "name": "@npmcli/ci-detect", - "version": "2.0.0", - "description": "Detect what kind of CI environment the program is in", - "author": "GitHub Inc.", - "license": "ISC", - "main": "./lib", - "scripts": { - "test": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "lint": "eslint '**/*.js'", - "postlint": "npm-template-check", - "template-copy": "npm-template-copy --force", - "lintfix": "npm run lint -- --fix", - "snap": "tap", - "posttest": "npm run lint" - }, - "tap": { - "check-coverage": true - }, - "devDependencies": { - "@npmcli/template-oss": "^2.7.1", - "tap": "^15.1.6" - }, - "files": [ - "bin", - "lib" - ], - "repository": { - "type": "git", - "url": "git+https://github.com/npm/ci-detect.git" - }, - "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - }, - "templateOSS": { - "version": "2.7.1" - } -} diff --git a/node_modules/@npmcli/config b/node_modules/@npmcli/config new file mode 120000 index 0000000..bf09f37 --- /dev/null +++ b/node_modules/@npmcli/config @@ -0,0 +1 @@ +../../workspaces/config \ No newline at end of file diff --git a/node_modules/@npmcli/config/lib/proc-log.js b/node_modules/@npmcli/config/lib/proc-log.js deleted file mode 100644 index 0492a26..0000000 --- a/node_modules/@npmcli/config/lib/proc-log.js +++ /dev/null @@ -1,4 +0,0 @@ -const log = (level) => (...args) => process.emit('log', level, ...args) -for (const level of ['silly', 'verbose', 'warn', 'error']) { - exports[level] = log(level) -} diff --git a/node_modules/@npmcli/config/package.json b/node_modules/@npmcli/config/package.json deleted file mode 100644 index b0722db..0000000 --- a/node_modules/@npmcli/config/package.json +++ /dev/null @@ -1,51 +0,0 @@ -{ - "name": "@npmcli/config", - "version": "3.0.0", - "files": [ - "bin", - "lib" - ], - "main": "lib/index.js", - "description": "Configuration management for the npm cli", - "repository": { - "type": "git", - "url": "git+https://github.com/npm/config" - }, - "author": "GitHub Inc.", - "license": "ISC", - "scripts": { - "test": "tap", - "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "lint": "eslint '**/*.js'", - "postlint": "npm-template-check", - "lintfix": "npm run lint -- --fix", - "posttest": "npm run lint", - "template-copy": "npm-template-copy --force" - }, - "tap": { - "check-coverage": true, - "coverage-map": "map.js" - }, - "devDependencies": { - "@npmcli/template-oss": "^2.5.1", - "tap": "^15.0.4" - }, - "dependencies": { - "@npmcli/map-workspaces": "^2.0.0", - "ini": "^2.0.0", - "mkdirp-infer-owner": "^2.0.0", - "nopt": "^5.0.0", - "read-package-json-fast": "^2.0.3", - "semver": "^7.3.4", - "walk-up-path": "^1.0.0" - }, - "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - }, - "templateOSS": { - "version": "2.6.0" - } -} diff --git a/node_modules/@npmcli/disparity-colors/index.js b/node_modules/@npmcli/disparity-colors/lib/index.js similarity index 87% rename from node_modules/@npmcli/disparity-colors/index.js rename to node_modules/@npmcli/disparity-colors/lib/index.js index a02b8f8..3d2aa56 100644 --- a/node_modules/@npmcli/disparity-colors/index.js +++ b/node_modules/@npmcli/disparity-colors/lib/index.js @@ -4,7 +4,7 @@ const colors = { removed: ansi.red, added: ansi.green, header: ansi.yellow, - section: ansi.magenta + section: ansi.magenta, } function colorize (str, opts) { @@ -13,10 +13,10 @@ function colorize (str, opts) { headerLength = 2 } - const color = (str, colorId) => { + const color = (colorStr, colorId) => { const { open, close } = colors[colorId] // avoid highlighting the "\n" (would highlight till the end of the line) - return str.replace(/[^\n\r]+/g, open + '$&' + close) + return colorStr.replace(/[^\n\r]+/g, open + '$&' + close) } // this RegExp will include all the `\n` chars into the lines, easier to join diff --git a/node_modules/@npmcli/disparity-colors/package.json b/node_modules/@npmcli/disparity-colors/package.json index 3f389a4..17eb484 100644 --- a/node_modules/@npmcli/disparity-colors/package.json +++ b/node_modules/@npmcli/disparity-colors/package.json @@ -1,14 +1,19 @@ { "name": "@npmcli/disparity-colors", - "version": "1.0.1", + "version": "3.0.0", + "main": "lib/index.js", "files": [ - "index.js" + "bin/", + "lib/" ], "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "description": "Colorizes unified diff output", - "repository": "https://github.com/npm/disparity-colors", + "repository": { + "type": "git", + "url": "https://github.com/npm/disparity-colors.git" + }, "keywords": [ "disparity", "npm", @@ -24,7 +29,7 @@ "cli", "tty" ], - "author": "npm Inc. <support@npmjs.com>", + "author": "GitHub Inc.", "contributors": [ { "name": "Ruy Adorno", @@ -34,27 +39,32 @@ ], "license": "ISC", "scripts": { - "lint": "standard index.js", + "lint": "eslint \"**/*.js\"", "pretest": "npm run lint", "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags" + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "npm run lint -- --fix", + "posttest": "npm run lint" }, "tap": { - "check-coverage": true - }, - "standard": { - "ignore": [ - "/tap-snapshots/" + "check-coverage": true, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" ] }, "devDependencies": { - "standard": "^16.0.3", - "tap": "^14.11.0" + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", + "tap": "^16.0.1" }, "dependencies": { "ansi-styles": "^4.3.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" } } diff --git a/node_modules/@npmcli/fs/lib/common/file-url-to-path/index.js b/node_modules/@npmcli/fs/lib/common/file-url-to-path/index.js deleted file mode 100644 index 7755d1c..0000000 --- a/node_modules/@npmcli/fs/lib/common/file-url-to-path/index.js +++ /dev/null @@ -1,17 +0,0 @@ -const url = require('url') - -const node = require('../node.js') -const polyfill = require('./polyfill.js') - -const useNative = node.satisfies('>=10.12.0') - -const fileURLToPath = (path) => { - // the polyfill is tested separately from this module, no need to hack - // process.version to try to trigger it just for coverage - // istanbul ignore next - return useNative - ? url.fileURLToPath(path) - : polyfill(path) -} - -module.exports = fileURLToPath diff --git a/node_modules/@npmcli/fs/lib/common/file-url-to-path/polyfill.js b/node_modules/@npmcli/fs/lib/common/file-url-to-path/polyfill.js deleted file mode 100644 index 6cc90f0..0000000 --- a/node_modules/@npmcli/fs/lib/common/file-url-to-path/polyfill.js +++ /dev/null @@ -1,121 +0,0 @@ -const { URL, domainToUnicode } = require('url') - -const CHAR_LOWERCASE_A = 97 -const CHAR_LOWERCASE_Z = 122 - -const isWindows = process.platform === 'win32' - -class ERR_INVALID_FILE_URL_HOST extends TypeError { - constructor (platform) { - super(`File URL host must be "localhost" or empty on ${platform}`) - this.code = 'ERR_INVALID_FILE_URL_HOST' - } - - toString () { - return `${this.name} [${this.code}]: ${this.message}` - } -} - -class ERR_INVALID_FILE_URL_PATH extends TypeError { - constructor (msg) { - super(`File URL path ${msg}`) - this.code = 'ERR_INVALID_FILE_URL_PATH' - } - - toString () { - return `${this.name} [${this.code}]: ${this.message}` - } -} - -class ERR_INVALID_ARG_TYPE extends TypeError { - constructor (name, actual) { - super(`The "${name}" argument must be one of type string or an instance ` + - `of URL. Received type ${typeof actual} ${actual}`) - this.code = 'ERR_INVALID_ARG_TYPE' - } - - toString () { - return `${this.name} [${this.code}]: ${this.message}` - } -} - -class ERR_INVALID_URL_SCHEME extends TypeError { - constructor (expected) { - super(`The URL must be of scheme ${expected}`) - this.code = 'ERR_INVALID_URL_SCHEME' - } - - toString () { - return `${this.name} [${this.code}]: ${this.message}` - } -} - -const isURLInstance = (input) => { - return input != null && input.href && input.origin -} - -const getPathFromURLWin32 = (url) => { - const hostname = url.hostname - let pathname = url.pathname - for (let n = 0; n < pathname.length; n++) { - if (pathname[n] === '%') { - const third = pathname.codePointAt(n + 2) | 0x20 - if ((pathname[n + 1] === '2' && third === 102) || - (pathname[n + 1] === '5' && third === 99)) { - throw new ERR_INVALID_FILE_URL_PATH('must not include encoded \\ or / characters') - } - } - } - - pathname = pathname.replace(/\//g, '\\') - pathname = decodeURIComponent(pathname) - if (hostname !== '') { - return `\\\\${domainToUnicode(hostname)}${pathname}` - } - - const letter = pathname.codePointAt(1) | 0x20 - const sep = pathname[2] - if (letter < CHAR_LOWERCASE_A || letter > CHAR_LOWERCASE_Z || - (sep !== ':')) { - throw new ERR_INVALID_FILE_URL_PATH('must be absolute') - } - - return pathname.slice(1) -} - -const getPathFromURLPosix = (url) => { - if (url.hostname !== '') { - throw new ERR_INVALID_FILE_URL_HOST(process.platform) - } - - const pathname = url.pathname - - for (let n = 0; n < pathname.length; n++) { - if (pathname[n] === '%') { - const third = pathname.codePointAt(n + 2) | 0x20 - if (pathname[n + 1] === '2' && third === 102) { - throw new ERR_INVALID_FILE_URL_PATH('must not include encoded / characters') - } - } - } - - return decodeURIComponent(pathname) -} - -const fileURLToPath = (path) => { - if (typeof path === 'string') { - path = new URL(path) - } else if (!isURLInstance(path)) { - throw new ERR_INVALID_ARG_TYPE('path', ['string', 'URL'], path) - } - - if (path.protocol !== 'file:') { - throw new ERR_INVALID_URL_SCHEME('file') - } - - return isWindows - ? getPathFromURLWin32(path) - : getPathFromURLPosix(path) -} - -module.exports = fileURLToPath diff --git a/node_modules/@npmcli/fs/lib/common/get-options.js b/node_modules/@npmcli/fs/lib/common/get-options.js deleted file mode 100644 index cb5982f..0000000 --- a/node_modules/@npmcli/fs/lib/common/get-options.js +++ /dev/null @@ -1,20 +0,0 @@ -// given an input that may or may not be an object, return an object that has -// a copy of every defined property listed in 'copy'. if the input is not an -// object, assign it to the property named by 'wrap' -const getOptions = (input, { copy, wrap }) => { - const result = {} - - if (input && typeof input === 'object') { - for (const prop of copy) { - if (input[prop] !== undefined) { - result[prop] = input[prop] - } - } - } else { - result[wrap] = input - } - - return result -} - -module.exports = getOptions diff --git a/node_modules/@npmcli/fs/lib/common/node.js b/node_modules/@npmcli/fs/lib/common/node.js deleted file mode 100644 index 4d13bc0..0000000 --- a/node_modules/@npmcli/fs/lib/common/node.js +++ /dev/null @@ -1,9 +0,0 @@ -const semver = require('semver') - -const satisfies = (range) => { - return semver.satisfies(process.version, range, { includePrerelease: true }) -} - -module.exports = { - satisfies, -} diff --git a/node_modules/@npmcli/fs/lib/common/owner.js b/node_modules/@npmcli/fs/lib/common/owner.js deleted file mode 100644 index e3468b0..0000000 --- a/node_modules/@npmcli/fs/lib/common/owner.js +++ /dev/null @@ -1,92 +0,0 @@ -const { dirname, resolve } = require('path') - -const fileURLToPath = require('./file-url-to-path/index.js') -const fs = require('../fs.js') - -// given a path, find the owner of the nearest parent -const find = async (path) => { - // if we have no getuid, permissions are irrelevant on this platform - if (!process.getuid) { - return {} - } - - // fs methods accept URL objects with a scheme of file: so we need to unwrap - // those into an actual path string before we can resolve it - const resolved = path != null && path.href && path.origin - ? resolve(fileURLToPath(path)) - : resolve(path) - - let stat - - try { - stat = await fs.lstat(resolved) - } finally { - // if we got a stat, return its contents - if (stat) { - return { uid: stat.uid, gid: stat.gid } - } - - // try the parent directory - if (resolved !== dirname(resolved)) { - return find(dirname(resolved)) - } - - // no more parents, never got a stat, just return an empty object - return {} - } -} - -// given a path, uid, and gid update the ownership of the path if necessary -const update = async (path, uid, gid) => { - // nothing to update, just exit - if (uid === undefined && gid === undefined) { - return - } - - try { - // see if the permissions are already the same, if they are we don't - // need to do anything, so return early - const stat = await fs.stat(path) - if (uid === stat.uid && gid === stat.gid) { - return - } - } catch (err) {} - - try { - await fs.chown(path, uid, gid) - } catch (err) {} -} - -// accepts a `path` and the `owner` property of an options object and normalizes -// it into an object with numerical `uid` and `gid` -const validate = async (path, input) => { - let uid - let gid - - if (typeof input === 'string' || typeof input === 'number') { - uid = input - gid = input - } else if (input && typeof input === 'object') { - uid = input.uid - gid = input.gid - } - - if (uid === 'inherit' || gid === 'inherit') { - const owner = await find(path) - if (uid === 'inherit') { - uid = owner.uid - } - - if (gid === 'inherit') { - gid = owner.gid - } - } - - return { uid, gid } -} - -module.exports = { - find, - update, - validate, -} diff --git a/node_modules/@npmcli/fs/lib/copy-file.js b/node_modules/@npmcli/fs/lib/copy-file.js deleted file mode 100644 index d9875ab..0000000 --- a/node_modules/@npmcli/fs/lib/copy-file.js +++ /dev/null @@ -1,22 +0,0 @@ -const fs = require('./fs.js') -const getOptions = require('./common/get-options.js') -const owner = require('./common/owner.js') - -const copyFile = async (src, dest, opts) => { - const options = getOptions(opts, { - copy: ['mode', 'owner'], - wrap: 'mode', - }) - - const { uid, gid } = await owner.validate(dest, options.owner) - - // the node core method as of 16.5.0 does not support the mode being in an - // object, so we have to pass the mode value directly - const result = await fs.copyFile(src, dest, options.mode) - - await owner.update(dest, uid, gid) - - return result -} - -module.exports = copyFile diff --git a/node_modules/@npmcli/fs/lib/cp/LICENSE b/node_modules/@npmcli/fs/lib/cp/LICENSE deleted file mode 100644 index 93546df..0000000 --- a/node_modules/@npmcli/fs/lib/cp/LICENSE +++ /dev/null @@ -1,15 +0,0 @@ -(The MIT License) - -Copyright (c) 2011-2017 JP Richardson - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files -(the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, - merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE -WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS -OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, - ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/@npmcli/fs/lib/cp/index.js b/node_modules/@npmcli/fs/lib/cp/index.js deleted file mode 100644 index 5da4739..0000000 --- a/node_modules/@npmcli/fs/lib/cp/index.js +++ /dev/null @@ -1,22 +0,0 @@ -const fs = require('../fs.js') -const getOptions = require('../common/get-options.js') -const node = require('../common/node.js') -const polyfill = require('./polyfill.js') - -// node 16.7.0 added fs.cp -const useNative = node.satisfies('>=16.7.0') - -const cp = async (src, dest, opts) => { - const options = getOptions(opts, { - copy: ['dereference', 'errorOnExist', 'filter', 'force', 'preserveTimestamps', 'recursive'], - }) - - // the polyfill is tested separately from this module, no need to hack - // process.version to try to trigger it just for coverage - // istanbul ignore next - return useNative - ? fs.cp(src, dest, options) - : polyfill(src, dest, options) -} - -module.exports = cp diff --git a/node_modules/@npmcli/fs/lib/cp/polyfill.js b/node_modules/@npmcli/fs/lib/cp/polyfill.js deleted file mode 100644 index f83ccbf..0000000 --- a/node_modules/@npmcli/fs/lib/cp/polyfill.js +++ /dev/null @@ -1,428 +0,0 @@ -// this file is a modified version of the code in node 17.2.0 -// which is, in turn, a modified version of the fs-extra module on npm -// node core changes: -// - Use of the assert module has been replaced with core's error system. -// - All code related to the glob dependency has been removed. -// - Bring your own custom fs module is not currently supported. -// - Some basic code cleanup. -// changes here: -// - remove all callback related code -// - drop sync support -// - change assertions back to non-internal methods (see options.js) -// - throws ENOTDIR when rmdir gets an ENOENT for a path that exists in Windows -'use strict' - -const { - ERR_FS_CP_DIR_TO_NON_DIR, - ERR_FS_CP_EEXIST, - ERR_FS_CP_EINVAL, - ERR_FS_CP_FIFO_PIPE, - ERR_FS_CP_NON_DIR_TO_DIR, - ERR_FS_CP_SOCKET, - ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY, - ERR_FS_CP_UNKNOWN, - ERR_FS_EISDIR, - ERR_INVALID_ARG_TYPE, -} = require('../errors.js') -const { - constants: { - errno: { - EEXIST, - EISDIR, - EINVAL, - ENOTDIR, - }, - }, -} = require('os') -const { - chmod, - copyFile, - lstat, - mkdir, - readdir, - readlink, - stat, - symlink, - unlink, - utimes, -} = require('../fs.js') -const { - dirname, - isAbsolute, - join, - parse, - resolve, - sep, - toNamespacedPath, -} = require('path') -const { fileURLToPath } = require('url') - -const defaultOptions = { - dereference: false, - errorOnExist: false, - filter: undefined, - force: true, - preserveTimestamps: false, - recursive: false, -} - -async function cp (src, dest, opts) { - if (opts != null && typeof opts !== 'object') { - throw new ERR_INVALID_ARG_TYPE('options', ['Object'], opts) - } - return cpFn( - toNamespacedPath(getValidatedPath(src)), - toNamespacedPath(getValidatedPath(dest)), - { ...defaultOptions, ...opts }) -} - -function getValidatedPath (fileURLOrPath) { - const path = fileURLOrPath != null && fileURLOrPath.href - && fileURLOrPath.origin - ? fileURLToPath(fileURLOrPath) - : fileURLOrPath - return path -} - -async function cpFn (src, dest, opts) { - // Warn about using preserveTimestamps on 32-bit node - // istanbul ignore next - if (opts.preserveTimestamps && process.arch === 'ia32') { - const warning = 'Using the preserveTimestamps option in 32-bit ' + - 'node is not recommended' - process.emitWarning(warning, 'TimestampPrecisionWarning') - } - const stats = await checkPaths(src, dest, opts) - const { srcStat, destStat } = stats - await checkParentPaths(src, srcStat, dest) - if (opts.filter) { - return handleFilter(checkParentDir, destStat, src, dest, opts) - } - return checkParentDir(destStat, src, dest, opts) -} - -async function checkPaths (src, dest, opts) { - const { 0: srcStat, 1: destStat } = await getStats(src, dest, opts) - if (destStat) { - if (areIdentical(srcStat, destStat)) { - throw new ERR_FS_CP_EINVAL({ - message: 'src and dest cannot be the same', - path: dest, - syscall: 'cp', - errno: EINVAL, - }) - } - if (srcStat.isDirectory() && !destStat.isDirectory()) { - throw new ERR_FS_CP_DIR_TO_NON_DIR({ - message: `cannot overwrite directory ${src} ` + - `with non-directory ${dest}`, - path: dest, - syscall: 'cp', - errno: EISDIR, - }) - } - if (!srcStat.isDirectory() && destStat.isDirectory()) { - throw new ERR_FS_CP_NON_DIR_TO_DIR({ - message: `cannot overwrite non-directory ${src} ` + - `with directory ${dest}`, - path: dest, - syscall: 'cp', - errno: ENOTDIR, - }) - } - } - - if (srcStat.isDirectory() && isSrcSubdir(src, dest)) { - throw new ERR_FS_CP_EINVAL({ - message: `cannot copy ${src} to a subdirectory of self ${dest}`, - path: dest, - syscall: 'cp', - errno: EINVAL, - }) - } - return { srcStat, destStat } -} - -function areIdentical (srcStat, destStat) { - return destStat.ino && destStat.dev && destStat.ino === srcStat.ino && - destStat.dev === srcStat.dev -} - -function getStats (src, dest, opts) { - const statFunc = opts.dereference ? - (file) => stat(file, { bigint: true }) : - (file) => lstat(file, { bigint: true }) - return Promise.all([ - statFunc(src), - statFunc(dest).catch((err) => { - // istanbul ignore next: unsure how to cover. - if (err.code === 'ENOENT') { - return null - } - // istanbul ignore next: unsure how to cover. - throw err - }), - ]) -} - -async function checkParentDir (destStat, src, dest, opts) { - const destParent = dirname(dest) - const dirExists = await pathExists(destParent) - if (dirExists) { - return getStatsForCopy(destStat, src, dest, opts) - } - await mkdir(destParent, { recursive: true }) - return getStatsForCopy(destStat, src, dest, opts) -} - -function pathExists (dest) { - return stat(dest).then( - () => true, - // istanbul ignore next: not sure when this would occur - (err) => (err.code === 'ENOENT' ? false : Promise.reject(err))) -} - -// Recursively check if dest parent is a subdirectory of src. -// It works for all file types including symlinks since it -// checks the src and dest inodes. It starts from the deepest -// parent and stops once it reaches the src parent or the root path. -async function checkParentPaths (src, srcStat, dest) { - const srcParent = resolve(dirname(src)) - const destParent = resolve(dirname(dest)) - if (destParent === srcParent || destParent === parse(destParent).root) { - return - } - let destStat - try { - destStat = await stat(destParent, { bigint: true }) - } catch (err) { - // istanbul ignore else: not sure when this would occur - if (err.code === 'ENOENT') { - return - } - // istanbul ignore next: not sure when this would occur - throw err - } - if (areIdentical(srcStat, destStat)) { - throw new ERR_FS_CP_EINVAL({ - message: `cannot copy ${src} to a subdirectory of self ${dest}`, - path: dest, - syscall: 'cp', - errno: EINVAL, - }) - } - return checkParentPaths(src, srcStat, destParent) -} - -const normalizePathToArray = (path) => - resolve(path).split(sep).filter(Boolean) - -// Return true if dest is a subdir of src, otherwise false. -// It only checks the path strings. -function isSrcSubdir (src, dest) { - const srcArr = normalizePathToArray(src) - const destArr = normalizePathToArray(dest) - return srcArr.every((cur, i) => destArr[i] === cur) -} - -async function handleFilter (onInclude, destStat, src, dest, opts, cb) { - const include = await opts.filter(src, dest) - if (include) { - return onInclude(destStat, src, dest, opts, cb) - } -} - -function startCopy (destStat, src, dest, opts) { - if (opts.filter) { - return handleFilter(getStatsForCopy, destStat, src, dest, opts) - } - return getStatsForCopy(destStat, src, dest, opts) -} - -async function getStatsForCopy (destStat, src, dest, opts) { - const statFn = opts.dereference ? stat : lstat - const srcStat = await statFn(src) - // istanbul ignore else: can't portably test FIFO - if (srcStat.isDirectory() && opts.recursive) { - return onDir(srcStat, destStat, src, dest, opts) - } else if (srcStat.isDirectory()) { - throw new ERR_FS_EISDIR({ - message: `${src} is a directory (not copied)`, - path: src, - syscall: 'cp', - errno: EINVAL, - }) - } else if (srcStat.isFile() || - srcStat.isCharacterDevice() || - srcStat.isBlockDevice()) { - return onFile(srcStat, destStat, src, dest, opts) - } else if (srcStat.isSymbolicLink()) { - return onLink(destStat, src, dest) - } else if (srcStat.isSocket()) { - throw new ERR_FS_CP_SOCKET({ - message: `cannot copy a socket file: ${dest}`, - path: dest, - syscall: 'cp', - errno: EINVAL, - }) - } else if (srcStat.isFIFO()) { - throw new ERR_FS_CP_FIFO_PIPE({ - message: `cannot copy a FIFO pipe: ${dest}`, - path: dest, - syscall: 'cp', - errno: EINVAL, - }) - } - // istanbul ignore next: should be unreachable - throw new ERR_FS_CP_UNKNOWN({ - message: `cannot copy an unknown file type: ${dest}`, - path: dest, - syscall: 'cp', - errno: EINVAL, - }) -} - -function onFile (srcStat, destStat, src, dest, opts) { - if (!destStat) { - return _copyFile(srcStat, src, dest, opts) - } - return mayCopyFile(srcStat, src, dest, opts) -} - -async function mayCopyFile (srcStat, src, dest, opts) { - if (opts.force) { - await unlink(dest) - return _copyFile(srcStat, src, dest, opts) - } else if (opts.errorOnExist) { - throw new ERR_FS_CP_EEXIST({ - message: `${dest} already exists`, - path: dest, - syscall: 'cp', - errno: EEXIST, - }) - } -} - -async function _copyFile (srcStat, src, dest, opts) { - await copyFile(src, dest) - if (opts.preserveTimestamps) { - return handleTimestampsAndMode(srcStat.mode, src, dest) - } - return setDestMode(dest, srcStat.mode) -} - -async function handleTimestampsAndMode (srcMode, src, dest) { - // Make sure the file is writable before setting the timestamp - // otherwise open fails with EPERM when invoked with 'r+' - // (through utimes call) - if (fileIsNotWritable(srcMode)) { - await makeFileWritable(dest, srcMode) - return setDestTimestampsAndMode(srcMode, src, dest) - } - return setDestTimestampsAndMode(srcMode, src, dest) -} - -function fileIsNotWritable (srcMode) { - return (srcMode & 0o200) === 0 -} - -function makeFileWritable (dest, srcMode) { - return setDestMode(dest, srcMode | 0o200) -} - -async function setDestTimestampsAndMode (srcMode, src, dest) { - await setDestTimestamps(src, dest) - return setDestMode(dest, srcMode) -} - -function setDestMode (dest, srcMode) { - return chmod(dest, srcMode) -} - -async function setDestTimestamps (src, dest) { - // The initial srcStat.atime cannot be trusted - // because it is modified by the read(2) system call - // (See https://nodejs.org/api/fs.html#fs_stat_time_values) - const updatedSrcStat = await stat(src) - return utimes(dest, updatedSrcStat.atime, updatedSrcStat.mtime) -} - -function onDir (srcStat, destStat, src, dest, opts) { - if (!destStat) { - return mkDirAndCopy(srcStat.mode, src, dest, opts) - } - return copyDir(src, dest, opts) -} - -async function mkDirAndCopy (srcMode, src, dest, opts) { - await mkdir(dest) - await copyDir(src, dest, opts) - return setDestMode(dest, srcMode) -} - -async function copyDir (src, dest, opts) { - const dir = await readdir(src) - for (let i = 0; i < dir.length; i++) { - const item = dir[i] - const srcItem = join(src, item) - const destItem = join(dest, item) - const { destStat } = await checkPaths(srcItem, destItem, opts) - await startCopy(destStat, srcItem, destItem, opts) - } -} - -async function onLink (destStat, src, dest) { - let resolvedSrc = await readlink(src) - if (!isAbsolute(resolvedSrc)) { - resolvedSrc = resolve(dirname(src), resolvedSrc) - } - if (!destStat) { - return symlink(resolvedSrc, dest) - } - let resolvedDest - try { - resolvedDest = await readlink(dest) - } catch (err) { - // Dest exists and is a regular file or directory, - // Windows may throw UNKNOWN error. If dest already exists, - // fs throws error anyway, so no need to guard against it here. - // istanbul ignore next: can only test on windows - if (err.code === 'EINVAL' || err.code === 'UNKNOWN') { - return symlink(resolvedSrc, dest) - } - // istanbul ignore next: should not be possible - throw err - } - if (!isAbsolute(resolvedDest)) { - resolvedDest = resolve(dirname(dest), resolvedDest) - } - if (isSrcSubdir(resolvedSrc, resolvedDest)) { - throw new ERR_FS_CP_EINVAL({ - message: `cannot copy ${resolvedSrc} to a subdirectory of self ` + - `${resolvedDest}`, - path: dest, - syscall: 'cp', - errno: EINVAL, - }) - } - // Do not copy if src is a subdir of dest since unlinking - // dest in this case would result in removing src contents - // and therefore a broken symlink would be created. - const srcStat = await stat(src) - if (srcStat.isDirectory() && isSrcSubdir(resolvedDest, resolvedSrc)) { - throw new ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY({ - message: `cannot overwrite ${resolvedDest} with ${resolvedSrc}`, - path: dest, - syscall: 'cp', - errno: EINVAL, - }) - } - return copyLink(resolvedSrc, dest) -} - -async function copyLink (resolvedSrc, dest) { - await unlink(dest) - return symlink(resolvedSrc, dest) -} - -module.exports = cp diff --git a/node_modules/@npmcli/fs/lib/errors.js b/node_modules/@npmcli/fs/lib/errors.js deleted file mode 100644 index 1cd1e05..0000000 --- a/node_modules/@npmcli/fs/lib/errors.js +++ /dev/null @@ -1,129 +0,0 @@ -'use strict' -const { inspect } = require('util') - -// adapted from node's internal/errors -// https://github.com/nodejs/node/blob/c8a04049/lib/internal/errors.js - -// close copy of node's internal SystemError class. -class SystemError { - constructor (code, prefix, context) { - // XXX context.code is undefined in all constructors used in cp/polyfill - // that may be a bug copied from node, maybe the constructor should use - // `code` not `errno`? nodejs/node#41104 - let message = `${prefix}: ${context.syscall} returned ` + - `${context.code} (${context.message})` - - if (context.path !== undefined) { - message += ` ${context.path}` - } - if (context.dest !== undefined) { - message += ` => ${context.dest}` - } - - this.code = code - Object.defineProperties(this, { - name: { - value: 'SystemError', - enumerable: false, - writable: true, - configurable: true, - }, - message: { - value: message, - enumerable: false, - writable: true, - configurable: true, - }, - info: { - value: context, - enumerable: true, - configurable: true, - writable: false, - }, - errno: { - get () { - return context.errno - }, - set (value) { - context.errno = value - }, - enumerable: true, - configurable: true, - }, - syscall: { - get () { - return context.syscall - }, - set (value) { - context.syscall = value - }, - enumerable: true, - configurable: true, - }, - }) - - if (context.path !== undefined) { - Object.defineProperty(this, 'path', { - get () { - return context.path - }, - set (value) { - context.path = value - }, - enumerable: true, - configurable: true, - }) - } - - if (context.dest !== undefined) { - Object.defineProperty(this, 'dest', { - get () { - return context.dest - }, - set (value) { - context.dest = value - }, - enumerable: true, - configurable: true, - }) - } - } - - toString () { - return `${this.name} [${this.code}]: ${this.message}` - } - - [Symbol.for('nodejs.util.inspect.custom')] (_recurseTimes, ctx) { - return inspect(this, { - ...ctx, - getters: true, - customInspect: false, - }) - } -} - -function E (code, message) { - module.exports[code] = class NodeError extends SystemError { - constructor (ctx) { - super(code, message, ctx) - } - } -} - -E('ERR_FS_CP_DIR_TO_NON_DIR', 'Cannot overwrite directory with non-directory') -E('ERR_FS_CP_EEXIST', 'Target already exists') -E('ERR_FS_CP_EINVAL', 'Invalid src or dest') -E('ERR_FS_CP_FIFO_PIPE', 'Cannot copy a FIFO pipe') -E('ERR_FS_CP_NON_DIR_TO_DIR', 'Cannot overwrite non-directory with directory') -E('ERR_FS_CP_SOCKET', 'Cannot copy a socket file') -E('ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY', 'Cannot overwrite symlink in subdirectory of self') -E('ERR_FS_CP_UNKNOWN', 'Cannot copy an unknown file type') -E('ERR_FS_EISDIR', 'Path is a directory') - -module.exports.ERR_INVALID_ARG_TYPE = class ERR_INVALID_ARG_TYPE extends Error { - constructor (name, expected, actual) { - super() - this.code = 'ERR_INVALID_ARG_TYPE' - this.message = `The ${name} argument must be ${expected}. Received ${typeof actual}` - } -} diff --git a/node_modules/@npmcli/fs/lib/fs.js b/node_modules/@npmcli/fs/lib/fs.js deleted file mode 100644 index 29e5fb5..0000000 --- a/node_modules/@npmcli/fs/lib/fs.js +++ /dev/null @@ -1,8 +0,0 @@ -const fs = require('fs') -const promisify = require('@gar/promisify') - -// this module returns the core fs module wrapped in a proxy that promisifies -// method calls within the getter. we keep it in a separate module so that the -// overridden methods have a consistent way to get to promisified fs methods -// without creating a circular dependency -module.exports = promisify(fs) diff --git a/node_modules/@npmcli/fs/lib/index.js b/node_modules/@npmcli/fs/lib/index.js deleted file mode 100644 index e40d748..0000000 --- a/node_modules/@npmcli/fs/lib/index.js +++ /dev/null @@ -1,10 +0,0 @@ -module.exports = { - ...require('./fs.js'), - copyFile: require('./copy-file.js'), - cp: require('./cp/index.js'), - mkdir: require('./mkdir/index.js'), - mkdtemp: require('./mkdtemp.js'), - rm: require('./rm/index.js'), - withTempDir: require('./with-temp-dir.js'), - writeFile: require('./write-file.js'), -} diff --git a/node_modules/@npmcli/fs/lib/mkdir/index.js b/node_modules/@npmcli/fs/lib/mkdir/index.js deleted file mode 100644 index 04ff447..0000000 --- a/node_modules/@npmcli/fs/lib/mkdir/index.js +++ /dev/null @@ -1,32 +0,0 @@ -const fs = require('../fs.js') -const getOptions = require('../common/get-options.js') -const node = require('../common/node.js') -const owner = require('../common/owner.js') - -const polyfill = require('./polyfill.js') - -// node 10.12.0 added the options parameter, which allows recursive and mode -// properties to be passed -const useNative = node.satisfies('>=10.12.0') - -// extends mkdir with the ability to specify an owner of the new dir -const mkdir = async (path, opts) => { - const options = getOptions(opts, { - copy: ['mode', 'recursive', 'owner'], - wrap: 'mode', - }) - const { uid, gid } = await owner.validate(path, options.owner) - - // the polyfill is tested separately from this module, no need to hack - // process.version to try to trigger it just for coverage - // istanbul ignore next - const result = useNative - ? await fs.mkdir(path, options) - : await polyfill(path, options) - - await owner.update(path, uid, gid) - - return result -} - -module.exports = mkdir diff --git a/node_modules/@npmcli/fs/lib/mkdir/polyfill.js b/node_modules/@npmcli/fs/lib/mkdir/polyfill.js deleted file mode 100644 index 4f8e6f0..0000000 --- a/node_modules/@npmcli/fs/lib/mkdir/polyfill.js +++ /dev/null @@ -1,81 +0,0 @@ -const { dirname } = require('path') - -const fileURLToPath = require('../common/file-url-to-path/index.js') -const fs = require('../fs.js') - -const defaultOptions = { - mode: 0o777, - recursive: false, -} - -const mkdir = async (path, opts) => { - const options = { ...defaultOptions, ...opts } - - // if we're not in recursive mode, just call the real mkdir with the path and - // the mode option only - if (!options.recursive) { - return fs.mkdir(path, options.mode) - } - - const makeDirectory = async (dir, mode) => { - // we can't use dirname directly since these functions support URL - // objects with the file: protocol as the path input, so first we get a - // string path, then we can call dirname on that - const parent = dir != null && dir.href && dir.origin - ? dirname(fileURLToPath(dir)) - : dirname(dir) - - // if the parent is the dir itself, try to create it. anything but EISDIR - // should be rethrown - if (parent === dir) { - try { - await fs.mkdir(dir, opts) - } catch (err) { - if (err.code !== 'EISDIR') { - throw err - } - } - return undefined - } - - try { - await fs.mkdir(dir, mode) - return dir - } catch (err) { - // ENOENT means the parent wasn't there, so create that - if (err.code === 'ENOENT') { - const made = await makeDirectory(parent, mode) - await makeDirectory(dir, mode) - // return the shallowest path we created, i.e. the result of creating - // the parent - return made - } - - // an EEXIST means there's already something there - // an EROFS means we have a read-only filesystem and can't create a dir - // any other error is fatal and we should give up now - if (err.code !== 'EEXIST' && err.code !== 'EROFS') { - throw err - } - - // stat the directory, if the result is a directory, then we successfully - // created this one so return its path. otherwise, we reject with the - // original error by ignoring the error in the catch - try { - const stat = await fs.stat(dir) - if (stat.isDirectory()) { - // if it already existed, we didn't create anything so return - // undefined - return undefined - } - } catch (_) {} - - // if the thing that's there isn't a directory, then just re-throw - throw err - } - } - - return makeDirectory(path, options.mode) -} - -module.exports = mkdir diff --git a/node_modules/@npmcli/fs/lib/mkdtemp.js b/node_modules/@npmcli/fs/lib/mkdtemp.js deleted file mode 100644 index b7f0780..0000000 --- a/node_modules/@npmcli/fs/lib/mkdtemp.js +++ /dev/null @@ -1,28 +0,0 @@ -const { dirname, sep } = require('path') - -const fs = require('./fs.js') -const getOptions = require('./common/get-options.js') -const owner = require('./common/owner.js') - -const mkdtemp = async (prefix, opts) => { - const options = getOptions(opts, { - copy: ['encoding', 'owner'], - wrap: 'encoding', - }) - - // mkdtemp relies on the trailing path separator to indicate if it should - // create a directory inside of the prefix. if that's the case then the root - // we infer ownership from is the prefix itself, otherwise it's the dirname - // /tmp -> /tmpABCDEF, infers from / - // /tmp/ -> /tmp/ABCDEF, infers from /tmp - const root = prefix.endsWith(sep) ? prefix : dirname(prefix) - const { uid, gid } = await owner.validate(root, options.owner) - - const result = await fs.mkdtemp(prefix, options) - - await owner.update(result, uid, gid) - - return result -} - -module.exports = mkdtemp diff --git a/node_modules/@npmcli/fs/lib/rm/index.js b/node_modules/@npmcli/fs/lib/rm/index.js deleted file mode 100644 index cb81fbd..0000000 --- a/node_modules/@npmcli/fs/lib/rm/index.js +++ /dev/null @@ -1,22 +0,0 @@ -const fs = require('../fs.js') -const getOptions = require('../common/get-options.js') -const node = require('../common/node.js') -const polyfill = require('./polyfill.js') - -// node 14.14.0 added fs.rm, which allows both the force and recursive options -const useNative = node.satisfies('>=14.14.0') - -const rm = async (path, opts) => { - const options = getOptions(opts, { - copy: ['retryDelay', 'maxRetries', 'recursive', 'force'], - }) - - // the polyfill is tested separately from this module, no need to hack - // process.version to try to trigger it just for coverage - // istanbul ignore next - return useNative - ? fs.rm(path, options) - : polyfill(path, options) -} - -module.exports = rm diff --git a/node_modules/@npmcli/fs/lib/rm/polyfill.js b/node_modules/@npmcli/fs/lib/rm/polyfill.js deleted file mode 100644 index a25c174..0000000 --- a/node_modules/@npmcli/fs/lib/rm/polyfill.js +++ /dev/null @@ -1,239 +0,0 @@ -// this file is a modified version of the code in node core >=14.14.0 -// which is, in turn, a modified version of the rimraf module on npm -// node core changes: -// - Use of the assert module has been replaced with core's error system. -// - All code related to the glob dependency has been removed. -// - Bring your own custom fs module is not currently supported. -// - Some basic code cleanup. -// changes here: -// - remove all callback related code -// - drop sync support -// - change assertions back to non-internal methods (see options.js) -// - throws ENOTDIR when rmdir gets an ENOENT for a path that exists in Windows -const errnos = require('os').constants.errno -const { join } = require('path') -const fs = require('../fs.js') - -// error codes that mean we need to remove contents -const notEmptyCodes = new Set([ - 'ENOTEMPTY', - 'EEXIST', - 'EPERM', -]) - -// error codes we can retry later -const retryCodes = new Set([ - 'EBUSY', - 'EMFILE', - 'ENFILE', - 'ENOTEMPTY', - 'EPERM', -]) - -const isWindows = process.platform === 'win32' - -const defaultOptions = { - retryDelay: 100, - maxRetries: 0, - recursive: false, - force: false, -} - -// this is drastically simplified, but should be roughly equivalent to what -// node core throws -class ERR_FS_EISDIR extends Error { - constructor (path) { - super() - this.info = { - code: 'EISDIR', - message: 'is a directory', - path, - syscall: 'rm', - errno: errnos.EISDIR, - } - this.name = 'SystemError' - this.code = 'ERR_FS_EISDIR' - this.errno = errnos.EISDIR - this.syscall = 'rm' - this.path = path - this.message = `Path is a directory: ${this.syscall} returned ` + - `${this.info.code} (is a directory) ${path}` - } - - toString () { - return `${this.name} [${this.code}]: ${this.message}` - } -} - -class ENOTDIR extends Error { - constructor (path) { - super() - this.name = 'Error' - this.code = 'ENOTDIR' - this.errno = errnos.ENOTDIR - this.syscall = 'rmdir' - this.path = path - this.message = `not a directory, ${this.syscall} '${this.path}'` - } - - toString () { - return `${this.name}: ${this.code}: ${this.message}` - } -} - -// force is passed separately here because we respect it for the first entry -// into rimraf only, any further calls that are spawned as a result (i.e. to -// delete content within the target) will ignore ENOENT errors -const rimraf = async (path, options, isTop = false) => { - const force = isTop ? options.force : true - const stat = await fs.lstat(path) - .catch((err) => { - // we only ignore ENOENT if we're forcing this call - if (err.code === 'ENOENT' && force) { - return - } - - if (isWindows && err.code === 'EPERM') { - return fixEPERM(path, options, err, isTop) - } - - throw err - }) - - // no stat object here means either lstat threw an ENOENT, or lstat threw - // an EPERM and the fixPERM function took care of things. either way, we're - // already done, so return early - if (!stat) { - return - } - - if (stat.isDirectory()) { - return rmdir(path, options, null, isTop) - } - - return fs.unlink(path) - .catch((err) => { - if (err.code === 'ENOENT' && force) { - return - } - - if (err.code === 'EISDIR') { - return rmdir(path, options, err, isTop) - } - - if (err.code === 'EPERM') { - // in windows, we handle this through fixEPERM which will also try to - // delete things again. everywhere else since deleting the target as a - // file didn't work we go ahead and try to delete it as a directory - return isWindows - ? fixEPERM(path, options, err, isTop) - : rmdir(path, options, err, isTop) - } - - throw err - }) -} - -const fixEPERM = async (path, options, originalErr, isTop) => { - const force = isTop ? options.force : true - const targetMissing = await fs.chmod(path, 0o666) - .catch((err) => { - if (err.code === 'ENOENT' && force) { - return true - } - - throw originalErr - }) - - // got an ENOENT above, return now. no file = no problem - if (targetMissing) { - return - } - - // this function does its own lstat rather than calling rimraf again to avoid - // infinite recursion for a repeating EPERM - const stat = await fs.lstat(path) - .catch((err) => { - if (err.code === 'ENOENT' && force) { - return - } - - throw originalErr - }) - - if (!stat) { - return - } - - if (stat.isDirectory()) { - return rmdir(path, options, originalErr, isTop) - } - - return fs.unlink(path) -} - -const rmdir = async (path, options, originalErr, isTop) => { - if (!options.recursive && isTop) { - throw originalErr || new ERR_FS_EISDIR(path) - } - const force = isTop ? options.force : true - - return fs.rmdir(path) - .catch(async (err) => { - // in Windows, calling rmdir on a file path will fail with ENOENT rather - // than ENOTDIR. to determine if that's what happened, we have to do - // another lstat on the path. if the path isn't actually gone, we throw - // away the ENOENT and replace it with our own ENOTDIR - if (isWindows && err.code === 'ENOENT') { - const stillExists = await fs.lstat(path).then(() => true, () => false) - if (stillExists) { - err = new ENOTDIR(path) - } - } - - // not there, not a problem - if (err.code === 'ENOENT' && force) { - return - } - - // we may not have originalErr if lstat tells us our target is a - // directory but that changes before we actually remove it, so - // only throw it here if it's set - if (originalErr && err.code === 'ENOTDIR') { - throw originalErr - } - - // the directory isn't empty, remove the contents and try again - if (notEmptyCodes.has(err.code)) { - const files = await fs.readdir(path) - await Promise.all(files.map((file) => { - const target = join(path, file) - return rimraf(target, options) - })) - return fs.rmdir(path) - } - - throw err - }) -} - -const rm = async (path, opts) => { - const options = { ...defaultOptions, ...opts } - let retries = 0 - - const errHandler = async (err) => { - if (retryCodes.has(err.code) && ++retries < options.maxRetries) { - const delay = retries * options.retryDelay - await promiseTimeout(delay) - return rimraf(path, options, true).catch(errHandler) - } - - throw err - } - - return rimraf(path, options, true).catch(errHandler) -} - -const promiseTimeout = (ms) => new Promise((r) => setTimeout(r, ms)) - -module.exports = rm diff --git a/node_modules/@npmcli/fs/lib/with-temp-dir.js b/node_modules/@npmcli/fs/lib/with-temp-dir.js deleted file mode 100644 index 353d555..0000000 --- a/node_modules/@npmcli/fs/lib/with-temp-dir.js +++ /dev/null @@ -1,39 +0,0 @@ -const { join, sep } = require('path') - -const getOptions = require('./common/get-options.js') -const mkdir = require('./mkdir/index.js') -const mkdtemp = require('./mkdtemp.js') -const rm = require('./rm/index.js') - -// create a temp directory, ensure its permissions match its parent, then call -// the supplied function passing it the path to the directory. clean up after -// the function finishes, whether it throws or not -const withTempDir = async (root, fn, opts) => { - const options = getOptions(opts, { - copy: ['tmpPrefix'], - }) - // create the directory, and fix its ownership - await mkdir(root, { recursive: true, owner: 'inherit' }) - - const target = await mkdtemp(join(`${root}${sep}`, options.tmpPrefix || ''), { owner: 'inherit' }) - let err - let result - - try { - result = await fn(target) - } catch (_err) { - err = _err - } - - try { - await rm(target, { force: true, recursive: true }) - } catch (err) {} - - if (err) { - throw err - } - - return result -} - -module.exports = withTempDir diff --git a/node_modules/@npmcli/fs/lib/write-file.js b/node_modules/@npmcli/fs/lib/write-file.js deleted file mode 100644 index 01de531..0000000 --- a/node_modules/@npmcli/fs/lib/write-file.js +++ /dev/null @@ -1,19 +0,0 @@ -const fs = require('./fs.js') -const getOptions = require('./common/get-options.js') -const owner = require('./common/owner.js') - -const writeFile = async (file, data, opts) => { - const options = getOptions(opts, { - copy: ['encoding', 'mode', 'flag', 'signal', 'owner'], - wrap: 'encoding', - }) - const { uid, gid } = await owner.validate(file, options.owner) - - const result = await fs.writeFile(file, data, options) - - await owner.update(file, uid, gid) - - return result -} - -module.exports = writeFile diff --git a/node_modules/@npmcli/fs/package.json b/node_modules/@npmcli/fs/package.json deleted file mode 100644 index cb64ac8..0000000 --- a/node_modules/@npmcli/fs/package.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "name": "@npmcli/fs", - "version": "1.1.0", - "description": "filesystem utilities for the npm cli", - "main": "lib/index.js", - "files": [ - "bin", - "lib" - ], - "scripts": { - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "snap": "tap", - "test": "tap", - "npmclilint": "npmcli-lint", - "lint": "eslint '**/*.js'", - "lintfix": "npm run lint -- --fix", - "posttest": "npm run lint", - "postsnap": "npm run lintfix --", - "postlint": "npm-template-check" - }, - "keywords": [ - "npm", - "oss" - ], - "author": "GitHub Inc.", - "license": "ISC", - "devDependencies": { - "@npmcli/template-oss": "^2.3.1", - "tap": "^15.0.9" - }, - "dependencies": { - "@gar/promisify": "^1.0.1", - "semver": "^7.3.5" - }, - "templateVersion": "2.3.1", - "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - } -} diff --git a/node_modules/@npmcli/git/lib/clone.js b/node_modules/@npmcli/git/lib/clone.js index 6754fd7..3f165dd 100644 --- a/node_modules/@npmcli/git/lib/clone.js +++ b/node_modules/@npmcli/git/lib/clone.js @@ -15,14 +15,14 @@ const shallowHosts = new Set([ 'gist.github.com', 'gitlab.com', 'bitbucket.com', - 'bitbucket.org' + 'bitbucket.org', ]) // we have to use url.parse until we add the same shim that hosted-git-info has // to handle scp:// urls const { parse } = require('url') // eslint-disable-line node/no-deprecated-api -const { basename, resolve } = require('path') +const path = require('path') -const revs = require('./revs.js') +const getRevs = require('./revs.js') const spawn = require('./spawn.js') const { isWindows } = require('./utils.js') @@ -31,7 +31,7 @@ const fs = require('fs') const mkdirp = require('mkdirp') module.exports = (repo, ref = 'HEAD', target = null, opts = {}) => - revs(repo, opts).then(revs => clone( + getRevs(repo, opts).then(revs => clone( repo, revs, ref, @@ -48,7 +48,7 @@ const maybeShallow = (repo, opts) => { } const defaultTarget = (repo, /* istanbul ignore next */ cwd = process.cwd()) => - resolve(cwd, basename(repo.replace(/[/\\]?\.git$/, ''))) + path.resolve(cwd, path.basename(repo.replace(/[/\\]?\.git$/, ''))) const clone = (repo, revs, ref, revDoc, target, opts) => { if (!revDoc) { @@ -113,10 +113,14 @@ const branch = (repo, revDoc, target, opts) => { revDoc.ref, repo, target, - '--recurse-submodules' + '--recurse-submodules', ] - if (maybeShallow(repo, opts)) { args.push('--depth=1') } - if (isWindows(opts)) { args.push('--config', 'core.longpaths=true') } + if (maybeShallow(repo, opts)) { + args.push('--depth=1') + } + if (isWindows(opts)) { + args.push('--config', 'core.longpaths=true') + } return spawn(args, opts).then(() => revDoc.sha) } @@ -126,10 +130,14 @@ const plain = (repo, revDoc, target, opts) => { 'clone', repo, target, - '--recurse-submodules' + '--recurse-submodules', ] - if (maybeShallow(repo, opts)) { args.push('--depth=1') } - if (isWindows(opts)) { args.push('--config', 'core.longpaths=true') } + if (maybeShallow(repo, opts)) { + args.push('--depth=1') + } + if (isWindows(opts)) { + args.push('--config', 'core.longpaths=true') + } return spawn(args, opts).then(() => revDoc.sha) } @@ -143,7 +151,7 @@ const updateSubmodules = (target, opts) => new Promise(resolve => 'update', '-q', '--init', - '--recursive' + '--recursive', ], { ...opts, cwd: target })) })) diff --git a/node_modules/@npmcli/git/lib/errors.js b/node_modules/@npmcli/git/lib/errors.js index 25b2b9f..7aeac47 100644 --- a/node_modules/@npmcli/git/lib/errors.js +++ b/node_modules/@npmcli/git/lib/errors.js @@ -32,5 +32,5 @@ class GitUnknownError extends GitError { module.exports = { GitConnectionError, GitPathspecError, - GitUnknownError + GitUnknownError, } diff --git a/node_modules/@npmcli/git/lib/index.js b/node_modules/@npmcli/git/lib/index.js index 20d7cfd..10a65f7 100644 --- a/node_modules/@npmcli/git/lib/index.js +++ b/node_modules/@npmcli/git/lib/index.js @@ -5,5 +5,5 @@ module.exports = { is: require('./is.js'), find: require('./find.js'), isClean: require('./is-clean.js'), - errors: require('./errors.js') + errors: require('./errors.js'), } diff --git a/node_modules/@npmcli/git/lib/lines-to-revs.js b/node_modules/@npmcli/git/lib/lines-to-revs.js index 9f879ca..6bd7e7a 100644 --- a/node_modules/@npmcli/git/lib/lines-to-revs.js +++ b/node_modules/@npmcli/git/lib/lines-to-revs.js @@ -7,7 +7,7 @@ module.exports = lines => finish(lines.reduce(linesToRevsReducer, { versions: {}, 'dist-tags': {}, refs: {}, - shas: {} + shas: {}, })) const finish = revs => distTags(shaList(peelTags(revs))) @@ -52,7 +52,9 @@ const distTags = revs => { revs['dist-tags'].latest = v } else if (ver.sha === HEAD.sha) { revs['dist-tags'].HEAD = v - if (!revs.refs.latest) { revs['dist-tags'].latest = v } + if (!revs.refs.latest) { + revs['dist-tags'].latest = v + } } }) return revs @@ -79,7 +81,9 @@ const refType = ref => { // return the doc, or null if we should ignore it. const lineToRevDoc = line => { const split = line.trim().split(/\s+/, 2) - if (split.length < 2) { return null } + if (split.length < 2) { + return null + } const sha = split[0].trim() const rawRef = split[1].trim() @@ -94,19 +98,19 @@ const lineToRevDoc = line => { // ignore the pointer. // For now, though, we have to save both, because some tags // don't have peels, if they were not annotated. - const ref = rawRef.substr('refs/tags/'.length) + const ref = rawRef.slice('refs/tags/'.length) return { sha, ref, rawRef, type } } if (type === 'branch') { - const ref = rawRef.substr('refs/heads/'.length) + const ref = rawRef.slice('refs/heads/'.length) return { sha, ref, rawRef, type } } if (type === 'pull') { // NB: merged pull requests installable with #pull/123/merge // for the merged pr, or #pull/123 for the PR head - const ref = rawRef.substr('refs/'.length).replace(/\/head$/, '') + const ref = rawRef.slice('refs/'.length).replace(/\/head$/, '') return { sha, ref, rawRef, type } } @@ -122,7 +126,9 @@ const lineToRevDoc = line => { const linesToRevsReducer = (revs, line) => { const doc = lineToRevDoc(line) - if (!doc) { return revs } + if (!doc) { + return revs + } revs.refs[doc.ref] = doc revs.refs[doc.rawRef] = doc diff --git a/node_modules/@npmcli/git/lib/make-error.js b/node_modules/@npmcli/git/lib/make-error.js index 043a8e6..7540ec7 100644 --- a/node_modules/@npmcli/git/lib/make-error.js +++ b/node_modules/@npmcli/git/lib/make-error.js @@ -1,7 +1,7 @@ const { GitConnectionError, GitPathspecError, - GitUnknownError + GitUnknownError, } = require('./errors.js') const connectionErrorRe = new RegExp([ @@ -12,7 +12,7 @@ const connectionErrorRe = new RegExp([ 'Failed to connect to .* Timed out', 'Connection reset by peer', 'SSL_ERROR_SYSCALL', - 'The requested URL returned error: 503' + 'The requested URL returned error: 503', ].join('|')) const missingPathspecRe = /pathspec .* did not match any file\(s\) known to git/ diff --git a/node_modules/@npmcli/git/lib/opts.js b/node_modules/@npmcli/git/lib/opts.js index 144e0a3..3119af1 100644 --- a/node_modules/@npmcli/git/lib/opts.js +++ b/node_modules/@npmcli/git/lib/opts.js @@ -2,11 +2,11 @@ // This defaults to accepting new ssh host key fingerprints const gitEnv = { GIT_ASKPASS: 'echo', - GIT_SSH_COMMAND: 'ssh -oStrictHostKeyChecking=accept-new' + GIT_SSH_COMMAND: 'ssh -oStrictHostKeyChecking=accept-new', } module.exports = (opts = {}) => ({ stdioString: true, ...opts, shell: false, - env: opts.env || { ...gitEnv, ...process.env } + env: opts.env || { ...gitEnv, ...process.env }, }) diff --git a/node_modules/@npmcli/git/lib/proc-log.js b/node_modules/@npmcli/git/lib/proc-log.js deleted file mode 100644 index b2bdd9d..0000000 --- a/node_modules/@npmcli/git/lib/proc-log.js +++ /dev/null @@ -1,21 +0,0 @@ -// default logger. -// emits 'log' events on the process -const LEVELS = [ - 'notice', - 'error', - 'warn', - 'info', - 'verbose', - 'http', - 'silly', - 'pause', - 'resume' -] - -const log = level => (...args) => process.emit('log', level, ...args) - -const logger = {} -for (const level of LEVELS) { - logger[level] = log(level) -} -module.exports = logger diff --git a/node_modules/@npmcli/git/lib/revs.js b/node_modules/@npmcli/git/lib/revs.js index 8105959..ee72370 100644 --- a/node_modules/@npmcli/git/lib/revs.js +++ b/node_modules/@npmcli/git/lib/revs.js @@ -4,7 +4,7 @@ const LRU = require('lru-cache') const revsCache = new LRU({ max: 100, - maxAge: 5 * 60 * 1000 + ttl: 5 * 60 * 1000, }) const linesToRevs = require('./lines-to-revs.js') diff --git a/node_modules/@npmcli/git/lib/spawn.js b/node_modules/@npmcli/git/lib/spawn.js index 1c89a4c..7098d7b 100644 --- a/node_modules/@npmcli/git/lib/spawn.js +++ b/node_modules/@npmcli/git/lib/spawn.js @@ -1,31 +1,32 @@ const spawn = require('@npmcli/promise-spawn') const promiseRetry = require('promise-retry') +const log = require('proc-log') const makeError = require('./make-error.js') const whichGit = require('./which.js') const makeOpts = require('./opts.js') -const procLog = require('./proc-log.js') module.exports = (gitArgs, opts = {}) => { const gitPath = whichGit(opts) - if (gitPath instanceof Error) { return Promise.reject(gitPath) } + if (gitPath instanceof Error) { + return Promise.reject(gitPath) + } // undocumented option, mostly only here for tests const args = opts.allowReplace || gitArgs[0] === '--no-replace-objects' ? gitArgs : ['--no-replace-objects', ...gitArgs] - const log = opts.log || procLog - let retry = opts.retry - if (retry === null || retry === undefined) { - retry = { + let retryOpts = opts.retry + if (retryOpts === null || retryOpts === undefined) { + retryOpts = { retries: opts.fetchRetries || 2, factor: opts.fetchRetryFactor || 10, maxTimeout: opts.fetchRetryMaxtimeout || 60000, - minTimeout: opts.fetchRetryMintimeout || 1000 + minTimeout: opts.fetchRetryMintimeout || 1000, } } - return promiseRetry((retry, number) => { + return promiseRetry((retryFn, number) => { if (number !== 1) { log.silly('git', `Retrying git command: ${ args.join(' ')} attempt # ${number}`) @@ -37,7 +38,7 @@ module.exports = (gitArgs, opts = {}) => { if (!gitError.shouldRetry(number)) { throw gitError } - retry(gitError) + retryFn(gitError) }) - }, retry) + }, retryOpts) } diff --git a/node_modules/@npmcli/git/lib/which.js b/node_modules/@npmcli/git/lib/which.js index a2f690e..dc2a1ad 100644 --- a/node_modules/@npmcli/git/lib/which.js +++ b/node_modules/@npmcli/git/lib/which.js @@ -3,7 +3,9 @@ const which = require('which') let gitPath try { gitPath = which.sync('git') -} catch (e) {} +} catch { + // ignore errors +} module.exports = (opts = {}) => { if (opts.git) { diff --git a/node_modules/@npmcli/git/package.json b/node_modules/@npmcli/git/package.json index 9475da5..f3ce2fc 100644 --- a/node_modules/@npmcli/git/package.json +++ b/node_modules/@npmcli/git/package.json @@ -1,44 +1,60 @@ { "name": "@npmcli/git", - "version": "2.1.0", + "version": "4.0.3", "main": "lib/index.js", "files": [ - "lib/*.js" + "bin/", + "lib/" ], "description": "a util for spawning git from npm CLI contexts", "repository": { "type": "git", - "url": "git+https://github.com/npm/git" + "url": "https://github.com/npm/git.git" }, - "author": "Isaac Z. Schlueter <i@izs.me> (https://izs.me)", + "author": "GitHub Inc.", "license": "ISC", "scripts": { - "lint": "standard", - "lint:fix": "standard --fix", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "preversion": "npm test", + "lint": "eslint \"**/*.js\"", "snap": "tap", "test": "tap", - "posttest": "npm run lint" + "posttest": "npm run lint", + "postlint": "template-oss-check", + "lintfix": "npm run lint -- --fix", + "template-oss-apply": "template-oss-apply --force" }, "tap": { "check-coverage": true, - "coverage-map": "map.js" + "coverage-map": "map.js", + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "devDependencies": { + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.8.0", + "npm-package-arg": "^10.0.0", + "rimraf": "^3.0.2", "slash": "^3.0.0", - "standard": "^16.0.3", - "tap": "^15.0.6" + "tap": "^16.0.1" }, "dependencies": { - "@npmcli/promise-spawn": "^1.3.2", - "lru-cache": "^6.0.0", + "@npmcli/promise-spawn": "^6.0.0", + "lru-cache": "^7.4.4", "mkdirp": "^1.0.4", - "npm-pick-manifest": "^6.1.1", + "npm-pick-manifest": "^8.0.0", + "proc-log": "^3.0.0", "promise-inflight": "^1.0.1", "promise-retry": "^2.0.1", "semver": "^7.3.5", - "which": "^2.0.2" + "which": "^3.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "windowsCI": false, + "version": "4.8.0" } } diff --git a/node_modules/@npmcli/installed-package-contents/index.js b/node_modules/@npmcli/installed-package-contents/lib/index.js similarity index 81% rename from node_modules/@npmcli/installed-package-contents/index.js rename to node_modules/@npmcli/installed-package-contents/lib/index.js index 30427fe..e2c545b 100755 --- a/node_modules/@npmcli/installed-package-contents/index.js +++ b/node_modules/@npmcli/installed-package-contents/lib/index.js @@ -17,49 +17,49 @@ // - add GET CONTENTS of bundled deps, PACKAGE=true, depth + 1 const bundled = require('npm-bundled') -const {promisify} = require('util') +const { promisify } = require('util') const fs = require('fs') const readFile = promisify(fs.readFile) const readdir = promisify(fs.readdir) const stat = promisify(fs.stat) const lstat = promisify(fs.lstat) -const {relative, resolve, basename, dirname} = require('path') +const { relative, resolve, basename, dirname } = require('path') const normalizePackageBin = require('npm-normalize-package-bin') const readPackage = ({ path, packageJsonCache }) => packageJsonCache.has(path) ? Promise.resolve(packageJsonCache.get(path)) : readFile(path).then(json => { - const pkg = normalizePackageBin(JSON.parse(json)) - packageJsonCache.set(path, pkg) - return pkg - }) + const pkg = normalizePackageBin(JSON.parse(json)) + packageJsonCache.set(path, pkg) + return pkg + }) .catch(er => null) // just normalize bundle deps and bin, that's all we care about here. const normalized = Symbol('package data has been normalized') const rpj = ({ path, packageJsonCache }) => - readPackage({path, packageJsonCache}) - .then(pkg => { - if (!pkg || pkg[normalized]) + readPackage({ path, packageJsonCache }) + .then(pkg => { + if (!pkg || pkg[normalized]) { + return pkg + } + if (pkg.bundledDependencies && !pkg.bundleDependencies) { + pkg.bundleDependencies = pkg.bundledDependencies + delete pkg.bundledDependencies + } + const bd = pkg.bundleDependencies + if (bd === true) { + pkg.bundleDependencies = [ + ...Object.keys(pkg.dependencies || {}), + ...Object.keys(pkg.optionalDependencies || {}), + ] + } + if (typeof bd === 'object' && !Array.isArray(bd)) { + pkg.bundleDependencies = Object.keys(bd) + } + pkg[normalized] = true return pkg - if (pkg.bundledDependencies && !pkg.bundleDependencies) { - pkg.bundleDependencies = pkg.bundledDependencies - delete pkg.bundledDependencies - } - const bd = pkg.bundleDependencies - if (bd === true) { - pkg.bundleDependencies = [ - ...Object.keys(pkg.dependencies || {}), - ...Object.keys(pkg.optionalDependencies || {}), - ] - } - if (typeof bd === 'object' && !Array.isArray(bd)) { - pkg.bundleDependencies = Object.keys(bd) - } - pkg[normalized] = true - return pkg - }) - + }) const pkgContents = async ({ path, @@ -69,19 +69,21 @@ const pkgContents = async ({ result = null, packageJsonCache = null, }) => { - if (!result) + if (!result) { result = new Set() + } - if (!packageJsonCache) + if (!packageJsonCache) { packageJsonCache = new Map() + } if (pkg === true) { return rpj({ path: path + '/package.json', packageJsonCache }) - .then(pkg => pkgContents({ + .then(p => pkgContents({ path, depth, currentDepth, - pkg, + pkg: p, result, packageJsonCache, })) @@ -91,7 +93,6 @@ const pkgContents = async ({ // add all bins to result if they exist if (pkg.bin) { const dir = dirname(path) - const base = basename(path) const scope = basename(dir) const nm = /^@.+/.test(scope) ? dirname(dir) : dir @@ -121,8 +122,9 @@ const pkgContents = async ({ ]).catch(() => []) // not a thing, probably a missing folder - if (!dirEntries) + if (!dirEntries) { return result + } // empty folder, just add the folder itself to the result if (!dirEntries.length && !bundleDeps && currentDepth !== 0) { @@ -140,7 +142,7 @@ const pkgContents = async ({ await Promise.all(dirEntries.map(async (name, index) => { const p = resolve(path, name) const st = await lstat(p) - dirEntries[index] = Object.assign(st, {name}) + dirEntries[index] = Object.assign(st, { name }) })) } @@ -184,20 +186,20 @@ const pkgContents = async ({ })) } - if (recursePromises.length) + if (recursePromises.length) { await Promise.all(recursePromises) + } return result } -module.exports = ({path, depth = 1, packageJsonCache}) => pkgContents({ +module.exports = ({ path, depth = 1, packageJsonCache }) => pkgContents({ path: resolve(path), depth, pkg: true, packageJsonCache, }).then(results => [...results]) - if (require.main === module) { const options = { path: null, depth: 1 } const usage = `Usage: @@ -214,15 +216,16 @@ Options: process.argv.slice(2).forEach(arg => { let match if ((match = arg.match(/^--depth=([0-9]+|Infinity)/)) || - (match = arg.match(/^-d([0-9]+|Infinity)/))) + (match = arg.match(/^-d([0-9]+|Infinity)/))) { options.depth = +match[1] - else if (arg === '-h' || arg === '--help') { + } else if (arg === '-h' || arg === '--help') { console.log(usage) process.exit(0) - } else + } else { options.path = arg + } }) - if (!options.path) { + if (!options.path) { console.error('ERROR: no path provided') console.error(usage) process.exit(1) diff --git a/node_modules/@npmcli/installed-package-contents/package.json b/node_modules/@npmcli/installed-package-contents/package.json index 1391630..aac2de1 100644 --- a/node_modules/@npmcli/installed-package-contents/package.json +++ b/node_modules/@npmcli/installed-package-contents/package.json @@ -1,37 +1,52 @@ { "name": "@npmcli/installed-package-contents", - "version": "1.0.7", + "version": "2.0.1", "description": "Get the list of files installed in a package in node_modules, including bundled dependencies", - "author": "Isaac Z. Schlueter <i@izs.me> (https://izs.me)", - "main": "index.js", + "author": "GitHub Inc.", + "main": "lib/index.js", "bin": { - "installed-package-contents": "index.js" + "installed-package-contents": "lib/index.js" }, "license": "ISC", "scripts": { "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "postpublish": "git push origin --follow-tags" - }, - "tap": { - "check-coverage": true, - "color": true + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "npm run lint -- --fix", + "posttest": "npm run lint" }, "devDependencies": { + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.6.2", + "mkdirp": "^1.0.4", "require-inject": "^1.4.4", - "tap": "^14.11.0" + "tap": "^16.3.0" }, "dependencies": { - "npm-bundled": "^1.1.1", - "npm-normalize-package-bin": "^1.0.1" + "npm-bundled": "^3.0.0", + "npm-normalize-package-bin": "^3.0.0" + }, + "repository": { + "type": "git", + "url": "https://github.com/npm/installed-package-contents.git" }, - "repository": "git+https://github.com/npm/installed-package-contents", "files": [ - "index.js" + "bin/", + "lib/" ], "engines": { - "node": ">= 10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.6.2" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/node_modules/@npmcli/map-workspaces/lib/index.js b/node_modules/@npmcli/map-workspaces/lib/index.js index 26e597a..f93bc29 100644 --- a/node_modules/@npmcli/map-workspaces/lib/index.js +++ b/node_modules/@npmcli/map-workspaces/lib/index.js @@ -12,7 +12,7 @@ function appendNegatedPatterns (patterns) { for (let pattern of patterns) { const excl = pattern.match(/^!+/) if (excl) { - pattern = pattern.substr(excl[0].length) + pattern = pattern.slice(excl[0].length) } // strip off any / from the start of the pattern. /foo => foo @@ -56,6 +56,7 @@ function pkgPathmame (opts) { // make sure glob pattern only matches folders function getGlobPattern (pattern) { + pattern = pattern.replace(/\\/g, '/') return pattern.endsWith('/') ? pattern : `${pattern}/` @@ -116,28 +117,52 @@ async function mapWorkspaces (opts = {}) { const name = getPackageName(pkg, packagePathname) + let seenPackagePathnames = seen.get(name) + if (!seenPackagePathnames) { + seenPackagePathnames = new Set() + seen.set(name, seenPackagePathnames) + } if (item.negate) { - results.delete(packagePathname, name) + seenPackagePathnames.delete(packagePathname) } else { - if (seen.has(name) && seen.get(name) !== packagePathname) { - throw getError({ - Type: Error, - message: [ - 'must not have multiple workspaces with the same name', - `package '${name}' has conflicts in the following paths:`, - ' ' + seen.get(name), - ' ' + packagePathname, - ].join('\n'), - code: 'EDUPLICATEWORKSPACE', - }) - } - - seen.set(name, packagePathname) - results.set(packagePathname, name) + seenPackagePathnames.add(packagePathname) } } } - return reverseResultMap(results) + + const errorMessageArray = ['must not have multiple workspaces with the same name'] + for (const [packageName, seenPackagePathnames] of seen) { + if (seenPackagePathnames.size === 0) { + continue + } + if (seenPackagePathnames.size > 1) { + addDuplicateErrorMessages(errorMessageArray, packageName, seenPackagePathnames) + } else { + results.set(packageName, seenPackagePathnames.values().next().value) + } + } + + if (errorMessageArray.length > 1) { + throw getError({ + Type: Error, + message: errorMessageArray.join('\n'), + code: 'EDUPLICATEWORKSPACE', + }) + } + + return results +} + +function addDuplicateErrorMessages (messageArray, packageName, packagePathnames) { + messageArray.push( + `package '${packageName}' has conflicts in the following paths:` + ) + + for (const packagePathname of packagePathnames) { + messageArray.push( + ' ' + packagePathname + ) + } } mapWorkspaces.virtual = function (opts = {}) { diff --git a/node_modules/@npmcli/map-workspaces/package.json b/node_modules/@npmcli/map-workspaces/package.json index 987298c..c8113cb 100644 --- a/node_modules/@npmcli/map-workspaces/package.json +++ b/node_modules/@npmcli/map-workspaces/package.json @@ -1,16 +1,19 @@ { "name": "@npmcli/map-workspaces", - "version": "2.0.0", + "version": "3.0.0", "main": "lib/index.js", "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "description": "Retrieves a name:pathname Map for a given workspaces config", - "repository": "https://github.com/npm/map-workspaces", + "repository": { + "type": "git", + "url": "https://github.com/npm/map-workspaces.git" + }, "keywords": [ "npm", "npmcli", @@ -22,36 +25,35 @@ "author": "GitHub Inc.", "license": "ISC", "scripts": { - "lint": "eslint '**/*.js'", + "lint": "eslint \"**/*.js\"", "pretest": "npm run lint", "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "postlint": "npm-template-check", + "postlint": "template-oss-check", "lintfix": "npm run lint -- --fix", - "posttest": "npm run lint" + "posttest": "npm run lint", + "template-oss-apply": "template-oss-apply --force" }, "tap": { - "check-coverage": true - }, - "standard": { - "ignore": [ - "/tap-snapshots/" + "check-coverage": true, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" ] }, "devDependencies": { - "eslint": "^8.0.0", - "require-inject": "^1.4.4", - "@npmcli/template-oss": "^2.0.0", - "tap": "^15.0.10" + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", + "tap": "^16.0.1" }, "dependencies": { "@npmcli/name-from-folder": "^1.0.1", - "glob": "^7.1.6", - "minimatch": "^3.0.4", - "read-package-json-fast": "^2.0.1" + "glob": "^8.0.1", + "minimatch": "^5.0.1", + "read-package-json-fast": "^3.0.0" }, - "templateVersion": "2.0.0" + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" + } } diff --git a/node_modules/@npmcli/metavuln-calculator/lib/advisory.js b/node_modules/@npmcli/metavuln-calculator/lib/advisory.js index d0900e3..1f479a9 100644 --- a/node_modules/@npmcli/metavuln-calculator/lib/advisory.js +++ b/node_modules/@npmcli/metavuln-calculator/lib/advisory.js @@ -22,8 +22,9 @@ class Advisory { this[_source] = source this[_options] = options this.name = name - if (!source.name) + if (!source.name) { source.name = name + } this.dependency = source.name @@ -38,6 +39,8 @@ class Advisory { this.severity = source.severity || 'high' this.versions = [] this.vulnerableVersions = [] + this.cwe = source.cwe + this.cvss = source.cvss // advisories have the range, metavulns do not // if an advisory doesn't specify range, assume all are vulnerable @@ -70,11 +73,13 @@ class Advisory { // load up the data from a cache entry and a fetched packument load (cached, packument) { // basic data integrity gutcheck - if (!cached || typeof cached !== 'object') + if (!cached || typeof cached !== 'object') { throw new TypeError('invalid cached data, expected object') + } - if (!packument || typeof packument !== 'object') + if (!packument || typeof packument !== 'object') { throw new TypeError('invalid packument data, expected object') + } if (cached.id && cached.id !== this.id) { throw Object.assign(new Error('loading from incorrect cache entry'), { @@ -88,14 +93,16 @@ class Advisory { actual: packument.name, }) } - if (this[_packument]) + if (this[_packument]) { throw new Error('advisory object already loaded') + } // if we have a range from the initialization, and the cached // data has a *different* range, then we know we have to recalc. // just don't use the cached data, so we will definitely not match later - if (!this.range || cached.range && cached.range === this.range) + if (!this.range || cached.range && cached.range === this.range) { Object.assign(this, cached) + } this[_packument] = packument @@ -107,8 +114,9 @@ class Advisory { if (!this.versions.includes(v)) { versionsAdded.push(v) this.versions.push(v) - } else if (!pakuVersions.includes(v)) + } else if (!pakuVersions.includes(v)) { versionsRemoved.push(v) + } } // strip out any removed versions from our lists, and sort by semver @@ -138,14 +146,16 @@ class Advisory { this[_updated] = true // test any versions newly added - if (!unchanged || versionsAdded.length) + if (!unchanged || versionsAdded.length) { this[_testVersions](unchanged ? versionsAdded : this.versions) + } this.vulnerableVersions = semver.sort(this.vulnerableVersions, semverOpt) // metavulns have to calculate their range, since cache is invalidated // advisories just get their range from the advisory above - if (this.type === 'metavuln') + if (this.type === 'metavuln') { this[_calculateRange]() + } return this } @@ -156,8 +166,8 @@ class Advisory { // we can try to be a *little* smarter up front by doing x-y for all // contiguous version sets in the list const ranges = [] - this.versions = semver.sort(this.versions) - this.vulnerableVersions = semver.sort(this.vulnerableVersions) + this.versions = semver.sort(this.versions, semverOpt) + this.vulnerableVersions = semver.sort(this.vulnerableVersions, semverOpt) for (let v = 0, vulnVer = 0; v < this.versions.length; v++) { // figure out the vulnerable subrange const vr = [this.versions[v]] @@ -170,10 +180,11 @@ class Advisory { } break } - if (vr.length > 1) + if (vr.length > 1) { vr[1] = this.versions[v] - else + } else { vr.push(this.versions[v]) + } v++ vulnVer++ } @@ -198,26 +209,30 @@ class Advisory { // we use the dependency version from the manifest. testVersion (version, spec = null) { const sv = String(version) - if (this[_versionVulnMemo].has(sv)) + if (this[_versionVulnMemo].has(sv)) { return this[_versionVulnMemo].get(sv) + } const result = this[_testVersion](version, spec) - if (result) + if (result) { this[_markVulnerable](version) + } this[_versionVulnMemo].set(sv, !!result) return result } [_markVulnerable] (version) { const sv = String(version) - if (!this.vulnerableVersions.includes(sv)) + if (!this.vulnerableVersions.includes(sv)) { this.vulnerableVersions.push(sv) + } } [_testVersion] (version, spec) { const sv = String(version) - if (this.vulnerableVersions.includes(sv)) + if (this.vulnerableVersions.includes(sv)) { return true + } if (this.type === 'advisory') { // advisory, just test range @@ -233,12 +248,14 @@ class Advisory { }, } - if (!spec) + if (!spec) { spec = getDepSpec(mani, this.dependency) + } // no dep, no vuln - if (spec === null) + if (spec === null) { return false + } if (!semver.validRange(spec, semverOpt)) { // not a semver range, nothing we can hope to do about it @@ -252,8 +269,9 @@ class Advisory { // try to pick a version of the dep that isn't vulnerable const avoid = this[_source].range - if (bundled) + if (bundled) { return semver.intersects(spec, avoid, semverOpt) + } return this[_source].testSpec(spec) } @@ -263,8 +281,9 @@ class Advisory { // consistent across multiple versions, so memoize this as well, in case // we're testing lots of versions. const memo = this[_specVulnMemo] - if (memo.has(spec)) + if (memo.has(spec)) { return memo.get(spec) + } const res = this[_testSpec](spec) memo.set(spec, res) @@ -274,10 +293,12 @@ class Advisory { [_testSpec] (spec) { for (const v of this.versions) { const satisfies = semver.satisfies(v, spec) - if (!satisfies) + if (!satisfies) { continue - if (!this.testVersion(v)) + } + if (!this.testVersion(v)) { return false + } } // either vulnerable, or not installable because nothing satisfied // either way, best avoided. @@ -285,8 +306,9 @@ class Advisory { } [_testVersions] (versions) { - if (!versions.length) + if (!versions.length) { return + } // set of lists of versions const versionSets = new Set() @@ -306,7 +328,7 @@ class Advisory { list.push(v) } - for (const list of versionSets) { + for (const set of versionSets) { // it's common to have version lists like: // 1.0.0 // 1.0.1-alpha.0 @@ -320,60 +342,66 @@ class Advisory { // 1.0.2 // with a huge number of prerelease versions that are not installable // anyway. - // If mid has a prerelease tag, and list[0] does not, then walk it + // If mid has a prerelease tag, and set[0] does not, then walk it // back until we hit a non-prerelease version - // If mid has a prerelease tag, and list[list.length-1] does not, + // If mid has a prerelease tag, and set[set.length-1] does not, // then walk it forward until we hit a version without a prerelease tag // Similarly, if the head/tail is a prerelease, but there is a non-pr - // version in the list, then start there instead. + // version in the set, then start there instead. let h = 0 - const origHeadVuln = this.testVersion(list[h]) - while (h < list.length && /-/.test(String(list[h]))) + const origHeadVuln = this.testVersion(set[h]) + while (h < set.length && /-/.test(String(set[h]))) { h++ - - // don't filter out the whole list! they might all be pr's - if (h === list.length) - h = 0 - else if (origHeadVuln) { - // if the original was vulnerable, assume so are all of these - for (let hh = 0; hh < h; hh++) - this[_markVulnerable](list[hh]) } - let t = list.length - 1 - const origTailVuln = this.testVersion(list[t]) - while (t > h && /-/.test(String(list[t]))) + // don't filter out the whole list! they might all be pr's + if (h === set.length) { + h = 0 + } else if (origHeadVuln) { + // if the original was vulnerable, assume so are all of these + for (let hh = 0; hh < h; hh++) { + this[_markVulnerable](set[hh]) + } + } + + let t = set.length - 1 + const origTailVuln = this.testVersion(set[t]) + while (t > h && /-/.test(String(set[t]))) { t-- + } // don't filter out the whole list! might all be pr's - if (t === h) - t = list.length - 1 - else if (origTailVuln) { + if (t === h) { + t = set.length - 1 + } else if (origTailVuln) { // if original tail was vulnerable, assume these are as well - for (let tt = list.length - 1; tt > t; tt--) - this[_markVulnerable](list[tt]) + for (let tt = set.length - 1; tt > t; tt--) { + this[_markVulnerable](set[tt]) + } } const headVuln = h === 0 ? origHeadVuln - : this.testVersion(list[h]) + : this.testVersion(set[h]) - const tailVuln = t === list.length - 1 ? origTailVuln - : this.testVersion(list[t]) + const tailVuln = t === set.length - 1 ? origTailVuln + : this.testVersion(set[t]) // if head and tail both vulnerable, whole list is thrown out if (headVuln && tailVuln) { - for (let v = h; v < t; v++) - this[_markVulnerable](list[v]) + for (let v = h; v < t; v++) { + this[_markVulnerable](set[v]) + } continue } // if length is 2 or 1, then we marked them all already - if (t < h + 2) + if (t < h + 2) { continue + } - const mid = Math.floor(list.length / 2) - const pre = list.slice(0, mid) - const post = list.slice(mid) + const mid = Math.floor(set.length / 2) + const pre = set.slice(0, mid) + const post = set.slice(mid) // if the parent list wasn't prereleases, then drop pr tags // from end of the pre list, and beginning of the post list, @@ -382,8 +410,9 @@ class Advisory { const midVuln = this.testVersion(pre[pre.length - 1]) while (/-/.test(String(pre[pre.length - 1]))) { const v = pre.pop() - if (midVuln) + if (midVuln) { this[_markVulnerable](v) + } } } @@ -391,8 +420,9 @@ class Advisory { const midVuln = this.testVersion(post[0]) while (/-/.test(String(post[0]))) { const v = post.shift() - if (midVuln) + if (midVuln) { this[_markVulnerable](v) + } } } diff --git a/node_modules/@npmcli/metavuln-calculator/lib/hash.js b/node_modules/@npmcli/metavuln-calculator/lib/hash.js index 79c0678..634bf99 100644 --- a/node_modules/@npmcli/metavuln-calculator/lib/hash.js +++ b/node_modules/@npmcli/metavuln-calculator/lib/hash.js @@ -1,5 +1,5 @@ -const {createHash} = require('crypto') +const { createHash } = require('crypto') -module.exports = ({name, source}) => createHash('sha512') +module.exports = ({ name, source }) => createHash('sha512') .update(JSON.stringify([name, source])) .digest('base64') diff --git a/node_modules/@npmcli/metavuln-calculator/lib/index.js b/node_modules/@npmcli/metavuln-calculator/lib/index.js index 02c1ed0..668f559 100644 --- a/node_modules/@npmcli/metavuln-calculator/lib/index.js +++ b/node_modules/@npmcli/metavuln-calculator/lib/index.js @@ -4,7 +4,7 @@ const pacote = require('pacote') const cacache = require('cacache') const Advisory = require('./advisory.js') -const {homedir} = require('os') +const { homedir } = require('os') const jsonParse = require('json-parse-even-better-errors') const _packument = Symbol('packument') @@ -37,8 +37,9 @@ class Calculator { async calculate (name, source) { const k = `security-advisory:${name}:${source.id}` - if (this[_advisories].has(k)) + if (this[_advisories].has(k)) { return this[_advisories].get(k) + } const p = this[_calculate](name, source) this[_advisories].set(k, p) @@ -58,8 +59,9 @@ class Calculator { process.emit('time', `metavuln:load:${k}`) advisory.load(cached, packument) process.emit('timeEnd', `metavuln:load:${k}`) - if (advisory.updated) + if (advisory.updated) { await this[_cachePut](advisory) + } this[_advisories].set(k, advisory) process.emit('timeEnd', t) return advisory @@ -81,8 +83,9 @@ class Calculator { const key = `security-advisory:${name}:${id}` /* istanbul ignore if - should be impossible, since we memoize the * advisory object itself using the same key, just being cautious */ - if (this[_cacheData].has(key)) + if (this[_cacheData].has(key)) { return this[_cacheData].get(key) + } process.emit('time', `metavuln:cache:get:${key}`) const p = cacache.get(this[_cache], key, { ...this[_options] }) @@ -98,8 +101,9 @@ class Calculator { } async [_packument] (name) { - if (this[_packuments].has(name)) + if (this[_packuments].has(name)) { return this[_packuments].get(name) + } process.emit('time', `metavuln:packument:${name}`) const p = pacote.packument(name, { ...this[_options] }) diff --git a/node_modules/@npmcli/metavuln-calculator/package.json b/node_modules/@npmcli/metavuln-calculator/package.json index 131cff6..baf59c4 100644 --- a/node_modules/@npmcli/metavuln-calculator/package.json +++ b/node_modules/@npmcli/metavuln-calculator/package.json @@ -1,46 +1,54 @@ { "name": "@npmcli/metavuln-calculator", - "version": "2.0.0", + "version": "5.0.0", "main": "lib/index.js", "files": [ - "lib" + "bin/", + "lib/" ], "description": "Calculate meta-vulnerabilities from package security advisories", - "repository": "https://github.com/npm/metavuln-calculator", - "author": "Isaac Z. Schlueter <i@izs.me> (https://izs.me)", + "repository": { + "type": "git", + "url": "https://github.com/npm/metavuln-calculator.git" + }, + "author": "GitHub Inc.", "license": "ISC", "scripts": { "test": "tap", "posttest": "npm run lint", "snap": "tap", "postsnap": "npm run lint", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", "eslint": "eslint", - "lint": "npm run eslint -- \"lib/**/*.js\" \"test/**/*.js\"", - "lintfix": "npm run lint -- --fix" + "lint": "eslint \"**/*.js\"", + "lintfix": "npm run lint -- --fix", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force" }, "tap": { "check-coverage": true, - "coverage-map": "map.js" + "coverage-map": "map.js", + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "devDependencies": { - "eslint": "^7.20.0", - "eslint-plugin-import": "^2.22.1", - "eslint-plugin-node": "^11.1.0", - "eslint-plugin-promise": "^4.3.1", - "eslint-plugin-standard": "^4.1.0", + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", "require-inject": "^1.4.4", - "tap": "^14.10.8" + "tap": "^16.0.1" }, "dependencies": { - "cacache": "^15.0.5", - "json-parse-even-better-errors": "^2.3.1", - "pacote": "^12.0.0", - "semver": "^7.3.2" + "cacache": "^17.0.0", + "json-parse-even-better-errors": "^3.0.0", + "pacote": "^15.0.0", + "semver": "^7.3.5" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" } } diff --git a/node_modules/@npmcli/node-gyp/lib/index.js b/node_modules/@npmcli/node-gyp/lib/index.js index d4ebf14..cdf1856 100644 --- a/node_modules/@npmcli/node-gyp/lib/index.js +++ b/node_modules/@npmcli/node-gyp/lib/index.js @@ -1,8 +1,8 @@ const util = require('util') const fs = require('fs') -const {stat} = fs.promises || { stat: util.promisify(fs.stat) }; +const { stat } = fs.promises || { stat: util.promisify(fs.stat) } -async function isNodeGypPackage(path) { +async function isNodeGypPackage (path) { return await stat(`${path}/binding.gyp`) .then(st => st.isFile()) .catch(() => false) @@ -10,5 +10,5 @@ async function isNodeGypPackage(path) { module.exports = { isNodeGypPackage, - defaultGypInstallScript: 'node-gyp rebuild' + defaultGypInstallScript: 'node-gyp rebuild', } diff --git a/node_modules/@npmcli/node-gyp/package.json b/node_modules/@npmcli/node-gyp/package.json index 299a453..999572b 100644 --- a/node_modules/@npmcli/node-gyp/package.json +++ b/node_modules/@npmcli/node-gyp/package.json @@ -1,12 +1,15 @@ { "name": "@npmcli/node-gyp", - "version": "1.0.3", + "version": "3.0.0", "description": "Tools for dealing with node-gyp packages", "scripts": { "test": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags" + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "npm run lint -- --fix", + "snap": "tap", + "posttest": "npm run lint" }, "repository": { "type": "git", @@ -18,18 +21,28 @@ "node-gyp" ], "files": [ - "lib/**/*.js" + "bin/", + "lib/" ], "main": "lib/index.js", - "author": "Brian Jenkins <bonkydog@bonkydog.com>", + "author": "GitHub Inc.", "license": "ISC", - "tap": { - "check-coverage": true, - "coverage-map": "map.js" - }, "devDependencies": { - "require-inject": "^1.4.4", - "tap": "^14.10.6", - "tmp": "^0.2.1" + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", + "tap": "^16.0.1" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/node_modules/@npmcli/package-json/lib/index.js b/node_modules/@npmcli/package-json/lib/index.js index 87c3a63..e98308f 100644 --- a/node_modules/@npmcli/package-json/lib/index.js +++ b/node_modules/@npmcli/package-json/lib/index.js @@ -73,13 +73,15 @@ class PackageJson { ) } - for (const step of knownSteps) + for (const step of knownSteps) { this[_manifest] = step({ content, originalContent: this[_manifest] }) + } // unknown properties will just be overwitten for (const [key, value] of Object.entries(content)) { - if (!knownKeys.has(key)) + if (!knownKeys.has(key)) { this[_manifest][key] = value + } } return this @@ -98,8 +100,9 @@ class PackageJson { }\n` .replace(/\n/g, eol) - if (fileContent.trim() !== this[_readFileContent].trim()) + if (fileContent.trim() !== this[_readFileContent].trim()) { return await writeFile(this[_filename], fileContent) + } } } diff --git a/node_modules/@npmcli/package-json/lib/update-dependencies.js b/node_modules/@npmcli/package-json/lib/update-dependencies.js index dac45a8..7259949 100644 --- a/node_modules/@npmcli/package-json/lib/update-dependencies.js +++ b/node_modules/@npmcli/package-json/lib/update-dependencies.js @@ -28,8 +28,9 @@ const updateDependencies = ({ content, originalContent }) => { // optionalDependencies don't need to be repeated in two places if (pkg.dependencies) { if (pkg.optionalDependencies) { - for (const name of Object.keys(pkg.optionalDependencies)) + for (const name of Object.keys(pkg.optionalDependencies)) { delete pkg.dependencies[name] + } } } @@ -37,16 +38,18 @@ const updateDependencies = ({ content, originalContent }) => { // loop through all types of dependencies and update package json pkg for (const type of depTypes) { - if (pkg[type]) + if (pkg[type]) { result[type] = pkg[type] + } // prune empty type props from resulting object const emptyDepType = pkg[type] && typeof pkg === 'object' && Object.keys(pkg[type]).length === 0 - if (emptyDepType) + if (emptyDepType) { delete result[type] + } } // if original package.json had dep in peerDeps AND deps, preserve that. diff --git a/node_modules/@npmcli/package-json/lib/update-scripts.js b/node_modules/@npmcli/package-json/lib/update-scripts.js index 3a88d3e..30495e5 100644 --- a/node_modules/@npmcli/package-json/lib/update-scripts.js +++ b/node_modules/@npmcli/package-json/lib/update-scripts.js @@ -1,8 +1,9 @@ const updateScripts = ({ content, originalContent = {} }) => { const newScripts = content.scripts - if (!newScripts) + if (!newScripts) { return originalContent + } // validate scripts content being appended const hasInvalidScripts = () => diff --git a/node_modules/@npmcli/package-json/lib/update-workspaces.js b/node_modules/@npmcli/package-json/lib/update-workspaces.js index 207dd94..04bf632 100644 --- a/node_modules/@npmcli/package-json/lib/update-workspaces.js +++ b/node_modules/@npmcli/package-json/lib/update-workspaces.js @@ -1,8 +1,9 @@ const updateWorkspaces = ({ content, originalContent = {} }) => { const newWorkspaces = content.workspaces - if (!newWorkspaces) + if (!newWorkspaces) { return originalContent + } // validate workspaces content being appended const hasInvalidWorkspaces = () => diff --git a/node_modules/@npmcli/package-json/package.json b/node_modules/@npmcli/package-json/package.json index 8708ec5..faae789 100644 --- a/node_modules/@npmcli/package-json/package.json +++ b/node_modules/@npmcli/package-json/package.json @@ -1,22 +1,21 @@ { "name": "@npmcli/package-json", - "version": "1.0.1", + "version": "3.0.0", "description": "Programmatic API to update package.json", "main": "lib/index.js", "files": [ - "lib" + "bin/", + "lib/" ], "scripts": { - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", "snap": "tap", "test": "tap", - "npmclilint": "npmcli-lint", - "lint": "npm run npmclilint -- \"lib/*.*js\" \"test/*.*js\"", + "lint": "eslint \"**/*.js\"", "lintfix": "npm run lint -- --fix", - "posttest": "npm run lint --", - "postsnap": "npm run lintfix --" + "posttest": "npm run lint", + "postsnap": "npm run lintfix --", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force" }, "keywords": [ "npm", @@ -25,10 +24,28 @@ "author": "GitHub Inc.", "license": "ISC", "devDependencies": { - "@npmcli/lint": "^1.0.1", - "tap": "^15.0.9" + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", + "tap": "^16.0.1" }, "dependencies": { - "json-parse-even-better-errors": "^2.3.1" + "json-parse-even-better-errors": "^3.0.0" + }, + "repository": { + "type": "git", + "url": "https://github.com/npm/package-json.git" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/node_modules/@npmcli/promise-spawn/index.js b/node_modules/@npmcli/promise-spawn/index.js deleted file mode 100644 index 6ad51b8..0000000 --- a/node_modules/@npmcli/promise-spawn/index.js +++ /dev/null @@ -1,75 +0,0 @@ -const {spawn} = require('child_process') - -const inferOwner = require('infer-owner') - -const isPipe = (stdio = 'pipe', fd) => - stdio === 'pipe' || stdio === null ? true - : Array.isArray(stdio) ? isPipe(stdio[fd], fd) - : false - -// 'extra' object is for decorating the error a bit more -const promiseSpawn = (cmd, args, opts, extra = {}) => { - const cwd = opts.cwd || process.cwd() - const isRoot = process.getuid && process.getuid() === 0 - const { uid, gid } = isRoot ? inferOwner.sync(cwd) : {} - return promiseSpawnUid(cmd, args, { - ...opts, - cwd, - uid, - gid - }, extra) -} - -const stdioResult = (stdout, stderr, {stdioString, stdio}) => - stdioString ? { - stdout: isPipe(stdio, 1) ? Buffer.concat(stdout).toString() : null, - stderr: isPipe(stdio, 2) ? Buffer.concat(stderr).toString() : null, - } - : { - stdout: isPipe(stdio, 1) ? Buffer.concat(stdout) : null, - stderr: isPipe(stdio, 2) ? Buffer.concat(stderr) : null, - } - -const promiseSpawnUid = (cmd, args, opts, extra) => { - let proc - const p = new Promise((res, rej) => { - proc = spawn(cmd, args, opts) - const stdout = [] - const stderr = [] - const reject = er => rej(Object.assign(er, { - cmd, - args, - ...stdioResult(stdout, stderr, opts), - ...extra, - })) - proc.on('error', reject) - if (proc.stdout) { - proc.stdout.on('data', c => stdout.push(c)).on('error', reject) - proc.stdout.on('error', er => reject(er)) - } - if (proc.stderr) { - proc.stderr.on('data', c => stderr.push(c)).on('error', reject) - proc.stderr.on('error', er => reject(er)) - } - proc.on('close', (code, signal) => { - const result = { - cmd, - args, - code, - signal, - ...stdioResult(stdout, stderr, opts), - ...extra - } - if (code || signal) - rej(Object.assign(new Error('command failed'), result)) - else - res(result) - }) - }) - - p.stdin = proc.stdin - p.process = proc - return p -} - -module.exports = promiseSpawn diff --git a/node_modules/@npmcli/promise-spawn/lib/escape.js b/node_modules/@npmcli/promise-spawn/lib/escape.js new file mode 100644 index 0000000..9aca8bd --- /dev/null +++ b/node_modules/@npmcli/promise-spawn/lib/escape.js @@ -0,0 +1,68 @@ +'use strict' + +// eslint-disable-next-line max-len +// this code adapted from: https://blogs.msdn.microsoft.com/twistylittlepassagesallalike/2011/04/23/everyone-quotes-command-line-arguments-the-wrong-way/ +const cmd = (input, doubleEscape) => { + if (!input.length) { + return '""' + } + + let result + if (!/[ \t\n\v"]/.test(input)) { + result = input + } else { + result = '"' + for (let i = 0; i <= input.length; ++i) { + let slashCount = 0 + while (input[i] === '\\') { + ++i + ++slashCount + } + + if (i === input.length) { + result += '\\'.repeat(slashCount * 2) + break + } + + if (input[i] === '"') { + result += '\\'.repeat(slashCount * 2 + 1) + result += input[i] + } else { + result += '\\'.repeat(slashCount) + result += input[i] + } + } + result += '"' + } + + // and finally, prefix shell meta chars with a ^ + result = result.replace(/[ !%^&()<>|"]/g, '^$&') + if (doubleEscape) { + result = result.replace(/[ !%^&()<>|"]/g, '^$&') + } + + return result +} + +const sh = (input) => { + if (!input.length) { + return `''` + } + + if (!/[\t\n\r "#$&'()*;<>?\\`|~]/.test(input)) { + return input + } + + // replace single quotes with '\'' and wrap the whole result in a fresh set of quotes + const result = `'${input.replace(/'/g, `'\\''`)}'` + // if the input string already had single quotes around it, clean those up + .replace(/^(?:'')+(?!$)/, '') + .replace(/\\'''/g, `\\'`) + + return result +} + +module.exports = { + cmd, + sh, +} diff --git a/node_modules/@npmcli/promise-spawn/lib/index.js b/node_modules/@npmcli/promise-spawn/lib/index.js new file mode 100644 index 0000000..1d42204 --- /dev/null +++ b/node_modules/@npmcli/promise-spawn/lib/index.js @@ -0,0 +1,195 @@ +'use strict' + +const { spawn } = require('child_process') +const os = require('os') +const which = require('which') + +const escape = require('./escape.js') + +// 'extra' object is for decorating the error a bit more +const promiseSpawn = (cmd, args, opts = {}, extra = {}) => { + if (opts.shell) { + return spawnWithShell(cmd, args, opts, extra) + } + + let proc + + const p = new Promise((res, rej) => { + proc = spawn(cmd, args, opts) + + const stdout = [] + const stderr = [] + + const reject = er => rej(Object.assign(er, { + cmd, + args, + ...stdioResult(stdout, stderr, opts), + ...extra, + })) + + proc.on('error', reject) + + if (proc.stdout) { + proc.stdout.on('data', c => stdout.push(c)).on('error', reject) + proc.stdout.on('error', er => reject(er)) + } + + if (proc.stderr) { + proc.stderr.on('data', c => stderr.push(c)).on('error', reject) + proc.stderr.on('error', er => reject(er)) + } + + proc.on('close', (code, signal) => { + const result = { + cmd, + args, + code, + signal, + ...stdioResult(stdout, stderr, opts), + ...extra, + } + + if (code || signal) { + rej(Object.assign(new Error('command failed'), result)) + } else { + res(result) + } + }) + }) + + p.stdin = proc.stdin + p.process = proc + return p +} + +const spawnWithShell = (cmd, args, opts, extra) => { + let command = opts.shell + // if shell is set to true, we use a platform default. we can't let the core + // spawn method decide this for us because we need to know what shell is in use + // ahead of time so that we can escape arguments properly. we don't need coverage here. + if (command === true) { + // istanbul ignore next + command = process.platform === 'win32' ? process.env.ComSpec : 'sh' + } + + const options = { ...opts, shell: false } + const realArgs = [] + let script = cmd + + // first, determine if we're in windows because if we are we need to know if we're + // running an .exe or a .cmd/.bat since the latter requires extra escaping + const isCmd = /(?:^|\\)cmd(?:\.exe)?$/i.test(command) + if (isCmd) { + let doubleEscape = false + + // find the actual command we're running + let initialCmd = '' + let insideQuotes = false + for (let i = 0; i < cmd.length; ++i) { + const char = cmd.charAt(i) + if (char === ' ' && !insideQuotes) { + break + } + + initialCmd += char + if (char === '"' || char === "'") { + insideQuotes = !insideQuotes + } + } + + let pathToInitial + try { + pathToInitial = which.sync(initialCmd, { + path: (options.env && options.env.PATH) || process.env.PATH, + pathext: (options.env && options.env.PATHEXT) || process.env.PATHEXT, + }).toLowerCase() + } catch (err) { + pathToInitial = initialCmd.toLowerCase() + } + + doubleEscape = pathToInitial.endsWith('.cmd') || pathToInitial.endsWith('.bat') + for (const arg of args) { + script += ` ${escape.cmd(arg, doubleEscape)}` + } + realArgs.push('/d', '/s', '/c', script) + options.windowsVerbatimArguments = true + } else { + for (const arg of args) { + script += ` ${escape.sh(arg)}` + } + realArgs.push('-c', script) + } + + return promiseSpawn(command, realArgs, options, extra) +} + +// open a file with the default application as defined by the user's OS +const open = (_args, opts = {}, extra = {}) => { + const options = { ...opts, shell: true } + const args = [].concat(_args) + + let platform = process.platform + // process.platform === 'linux' may actually indicate WSL, if that's the case + // we want to treat things as win32 anyway so the host can open the argument + if (platform === 'linux' && os.release().includes('Microsoft')) { + platform = 'win32' + } + + let command = options.command + if (!command) { + if (platform === 'win32') { + // spawnWithShell does not do the additional os.release() check, so we + // have to force the shell here to make sure we treat WSL as windows. + options.shell = process.env.ComSpec + // also, the start command accepts a title so to make sure that we don't + // accidentally interpret the first arg as the title, we stick an empty + // string immediately after the start command + command = 'start ""' + } else if (platform === 'darwin') { + command = 'open' + } else { + command = 'xdg-open' + } + } + + return spawnWithShell(command, args, options, extra) +} +promiseSpawn.open = open + +const isPipe = (stdio = 'pipe', fd) => { + if (stdio === 'pipe' || stdio === null) { + return true + } + + if (Array.isArray(stdio)) { + return isPipe(stdio[fd], fd) + } + + return false +} + +const stdioResult = (stdout, stderr, { stdioString = true, stdio }) => { + const result = { + stdout: null, + stderr: null, + } + + // stdio is [stdin, stdout, stderr] + if (isPipe(stdio, 1)) { + result.stdout = Buffer.concat(stdout) + if (stdioString) { + result.stdout = result.stdout.toString().trim() + } + } + + if (isPipe(stdio, 2)) { + result.stderr = Buffer.concat(stderr) + if (stdioString) { + result.stderr = result.stderr.toString().trim() + } + } + + return result +} + +module.exports = promiseSpawn diff --git a/node_modules/@npmcli/promise-spawn/package.json b/node_modules/@npmcli/promise-spawn/package.json index be7342f..c21e84f 100644 --- a/node_modules/@npmcli/promise-spawn/package.json +++ b/node_modules/@npmcli/promise-spawn/package.json @@ -1,32 +1,50 @@ { "name": "@npmcli/promise-spawn", - "version": "1.3.2", + "version": "6.0.1", "files": [ - "index.js" + "bin/", + "lib/" ], + "main": "./lib/index.js", "description": "spawn processes the way the npm cli likes to do", "repository": { "type": "git", - "url": "git+https://github.com/npm/promise-spawn" + "url": "https://github.com/npm/promise-spawn.git" }, - "author": "Isaac Z. Schlueter <i@izs.me> (https://izs.me)", + "author": "GitHub Inc.", "license": "ISC", "scripts": { "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags" + "lint": "eslint \"**/*.js\"", + "lintfix": "npm run lint -- --fix", + "posttest": "npm run lint", + "postsnap": "npm run lintfix --", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force" }, "tap": { - "check-coverage": true + "check-coverage": true, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "devDependencies": { + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.8.0", "minipass": "^3.1.1", - "require-inject": "^1.4.4", - "tap": "^14.10.6" + "spawk": "^1.7.1", + "tap": "^16.0.1" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.8.0" }, "dependencies": { - "infer-owner": "^1.0.4" + "which": "^3.0.0" } } diff --git a/node_modules/@npmcli/fs/LICENSE.md b/node_modules/@npmcli/query/LICENSE similarity index 100% rename from node_modules/@npmcli/fs/LICENSE.md rename to node_modules/@npmcli/query/LICENSE diff --git a/node_modules/@npmcli/query/lib/index.js b/node_modules/@npmcli/query/lib/index.js new file mode 100644 index 0000000..9373a4f --- /dev/null +++ b/node_modules/@npmcli/query/lib/index.js @@ -0,0 +1,189 @@ +'use strict' + +const parser = require('postcss-selector-parser') + +const arrayDelimiter = Symbol('arrayDelimiter') + +const escapeSlashes = str => + str.replace(/\//g, '\\/') + +const unescapeSlashes = str => + str.replace(/\\\//g, '/') + +// recursively fixes up any :attr pseudo-class found +const fixupAttr = astNode => { + const properties = [] + const matcher = {} + for (const selectorAstNode of astNode.nodes) { + const [firstAstNode] = selectorAstNode.nodes + if (firstAstNode.type === 'tag') { + properties.push(firstAstNode.value) + } + } + + const lastSelectorAstNode = astNode.nodes.pop() + const [attributeAstNode] = lastSelectorAstNode.nodes + + if (attributeAstNode.value === ':attr') { + const appendParts = fixupAttr(attributeAstNode) + properties.push(arrayDelimiter, ...appendParts.lookupProperties) + matcher.qualifiedAttribute = appendParts.attributeMatcher.qualifiedAttribute + matcher.operator = appendParts.attributeMatcher.operator + matcher.value = appendParts.attributeMatcher.value + + // backwards compatibility + matcher.attribute = appendParts.attributeMatcher.attribute + + if (appendParts.attributeMatcher.insensitive) { + matcher.insensitive = true + } + } else { + if (attributeAstNode.type !== 'attribute') { + throw Object.assign( + new Error('`:attr` pseudo-class expects an attribute matcher as the last value'), + { code: 'EQUERYATTR' } + ) + } + + matcher.qualifiedAttribute = unescapeSlashes(attributeAstNode.qualifiedAttribute) + matcher.operator = attributeAstNode.operator + matcher.value = attributeAstNode.value + + // backwards compatibility + matcher.attribute = matcher.qualifiedAttribute + + if (attributeAstNode.insensitive) { + matcher.insensitive = true + } + } + + astNode.lookupProperties = properties + astNode.attributeMatcher = matcher + astNode.nodes.length = 0 + return astNode +} + +// fixed up nested pseudo nodes will have their internal selectors moved +// to a new root node that will be referenced by the `nestedNode` property, +// this tweak makes it simpler to reuse `retrieveNodesFromParsedAst` to +// recursively parse and extract results from the internal selectors +const fixupNestedPseudo = astNode => { + // create a new ast root node and relocate any children + // selectors of the current ast node to this new root + const newRootNode = parser.root() + astNode.nestedNode = newRootNode + newRootNode.nodes = [...astNode.nodes] + + // clean up the ast by removing the children nodes from the + // current ast node while also cleaning up their `parent` refs + astNode.nodes.length = 0 + for (const currAstNode of newRootNode.nodes) { + currAstNode.parent = newRootNode + } + + // recursively fixup nodes of any nested selector + transformAst(newRootNode) +} + +// :semver(<version|range>, [selector], [function]) +const fixupSemverSpecs = astNode => { + // the first child node contains the version or range, most likely as a tag and a series of + // classes. we combine them into a single string here. this is the only required input. + const children = astNode.nodes.shift().nodes + const value = children.reduce((res, i) => `${res}${String(i)}`, '') + + // next, if we have 2 nodes left then the user called us with a total of 3. that means the + // last one tells us what specific semver function the user is requesting, so we pull that out + let semverFunc + if (astNode.nodes.length === 2) { + const funcNode = astNode.nodes.pop().nodes[0] + if (funcNode.type === 'tag') { + semverFunc = funcNode.value + } + } + + // now if there's a node left, that node is our selector. since that is the last remaining + // child node, we call fixupAttr on ourselves so that the attribute selectors get parsed + if (astNode.nodes.length === 1) { + fixupAttr(astNode) + } else { + // we weren't provided a selector, so we default to `[version]`. note, there's no default + // operator here. that's because we don't know yet if the user has provided us a version + // or range to assert against + astNode.attributeMatcher = { + insensitive: false, + attribute: 'version', + qualifiedAttribute: 'version', + } + astNode.lookupProperties = [] + } + + astNode.semverFunc = semverFunc + astNode.semverValue = value + astNode.nodes.length = 0 +} + +const fixupTypes = astNode => { + const [valueAstNode] = astNode.nodes[0].nodes + const { value } = valueAstNode || {} + astNode.typeValue = value + astNode.nodes.length = 0 +} + +const fixupPaths = astNode => { + astNode.pathValue = unescapeSlashes(String(astNode.nodes[0])) + astNode.nodes.length = 0 +} + +const fixupOutdated = astNode => { + if (astNode.nodes.length) { + astNode.outdatedKind = String(astNode.nodes[0]) + astNode.nodes.length = 0 + } +} + +// a few of the supported ast nodes need to be tweaked in order to properly be +// interpreted as proper arborist query selectors, namely semver ranges from +// both ids and :semver pseudo-class selectors need to be translated from what +// are usually multiple ast nodes, such as: tag:1, class:.0, class:.0 to a +// single `1.0.0` value, other pseudo-class selectors also get preprocessed in +// order to make it simpler to execute later when traversing each ast node +// using rootNode.walk(), such as :path, :type, etc. transformAst handles all +// these modifications to the parsed ast by doing an extra, initial traversal +// of the parsed ast from the query and modifying the parsed nodes accordingly +const transformAst = selector => { + selector.walk((nextAstNode) => { + switch (nextAstNode.value) { + case ':attr': + return fixupAttr(nextAstNode) + case ':is': + case ':has': + case ':not': + return fixupNestedPseudo(nextAstNode) + case ':path': + return fixupPaths(nextAstNode) + case ':semver': + return fixupSemverSpecs(nextAstNode) + case ':type': + return fixupTypes(nextAstNode) + case ':outdated': + return fixupOutdated(nextAstNode) + } + }) +} + +const queryParser = (query) => { + // if query is an empty string or any falsy + // value, just returns an empty result + if (!query) { + return [] + } + + return parser(transformAst) + .astSync(escapeSlashes(query), { lossless: false }) +} + +module.exports = { + parser: queryParser, + arrayDelimiter, +} diff --git a/node_modules/@npmcli/query/package.json b/node_modules/@npmcli/query/package.json new file mode 100644 index 0000000..1e4abd3 --- /dev/null +++ b/node_modules/@npmcli/query/package.json @@ -0,0 +1,62 @@ +{ + "name": "@npmcli/query", + "version": "3.0.0", + "description": "npm query parser and tools", + "main": "lib/index.js", + "scripts": { + "test": "tap", + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "npm run lint -- --fix", + "snap": "tap", + "posttest": "npm run lint" + }, + "contributors": [ + { + "name": "Ruy Adorno", + "url": "https://ruyadorno.com", + "twitter": "ruyadorno" + } + ], + "keywords": [ + "ast", + "npm", + "npmcli", + "parser", + "postcss", + "postcss-selector-parser", + "query" + ], + "author": "GitHub Inc.", + "license": "ISC", + "files": [ + "bin/", + "lib/" + ], + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" + }, + "devDependencies": { + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", + "tap": "^16.2.0" + }, + "dependencies": { + "postcss-selector-parser": "^6.0.10" + }, + "repository": { + "type": "git", + "url": "https://github.com/npm/query.git" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] + } +} diff --git a/node_modules/@npmcli/run-script/lib/make-spawn-args.js b/node_modules/@npmcli/run-script/lib/make-spawn-args.js index 8f29995..2b2f96a 100644 --- a/node_modules/@npmcli/run-script/lib/make-spawn-args.js +++ b/node_modules/@npmcli/run-script/lib/make-spawn-args.js @@ -1,40 +1,40 @@ /* eslint camelcase: "off" */ -const isWindows = require('./is-windows.js') const setPATH = require('./set-path.js') -const {resolve} = require('path') +const { resolve } = require('path') const npm_config_node_gyp = require.resolve('node-gyp/bin/node-gyp.js') const makeSpawnArgs = options => { const { event, path, - scriptShell = isWindows ? process.env.ComSpec || 'cmd' : 'sh', + scriptShell = true, + binPaths, env = {}, stdio, cmd, - stdioString = false, + args = [], + stdioString, } = options - const isCmd = /(?:^|\\)cmd(?:\.exe)?$/i.test(scriptShell) - const args = isCmd ? ['/d', '/s', '/c', cmd] : ['-c', cmd] + const spawnEnv = setPATH(path, binPaths, { + // we need to at least save the PATH environment var + ...process.env, + ...env, + npm_package_json: resolve(path, 'package.json'), + npm_lifecycle_event: event, + npm_lifecycle_script: cmd, + npm_config_node_gyp, + }) const spawnOpts = { - env: setPATH(path, { - // we need to at least save the PATH environment var - ...process.env, - ...env, - npm_package_json: resolve(path, 'package.json'), - npm_lifecycle_event: event, - npm_lifecycle_script: cmd, - npm_config_node_gyp, - }), + env: spawnEnv, stdioString, stdio, cwd: path, - ...(isCmd ? { windowsVerbatimArguments: true } : {}), + shell: scriptShell, } - return [scriptShell, args, spawnOpts] + return [cmd, args, spawnOpts] } module.exports = makeSpawnArgs diff --git a/node_modules/@npmcli/run-script/lib/package-envs.js b/node_modules/@npmcli/run-script/lib/package-envs.js index 47791fb..6b538e5 100644 --- a/node_modules/@npmcli/run-script/lib/package-envs.js +++ b/node_modules/@npmcli/run-script/lib/package-envs.js @@ -6,12 +6,13 @@ const envVal = val => Array.isArray(val) ? val.map(v => envVal(v)).join('\n\n') const packageEnvs = (env, vals, prefix) => { for (const [key, val] of Object.entries(vals)) { - if (val === undefined) + if (val === undefined) { continue - else if (val && !Array.isArray(val) && typeof val === 'object') + } else if (val && !Array.isArray(val) && typeof val === 'object') { packageEnvs(env, val, `${prefix}${key}_`) - else + } else { env[`${prefix}${key}`] = envVal(val) + } } return env } diff --git a/node_modules/@npmcli/run-script/lib/run-script-pkg.js b/node_modules/@npmcli/run-script/lib/run-script-pkg.js index ccde173..cbb0a0b 100644 --- a/node_modules/@npmcli/run-script/lib/run-script-pkg.js +++ b/node_modules/@npmcli/run-script/lib/run-script-pkg.js @@ -6,19 +6,29 @@ const signalManager = require('./signal-manager.js') const isServerPackage = require('./is-server-package.js') // you wouldn't like me when I'm angry... -const bruce = (id, event, cmd) => - `\n> ${id ? id + ' ' : ''}${event}\n> ${cmd.trim().replace(/\n/g, '\n> ')}\n` +const bruce = (id, event, cmd, args) => { + let banner = id + ? `\n> ${id} ${event}\n` + : `\n> ${event}\n` + banner += `> ${cmd.trim().replace(/\n/g, '\n> ')}` + if (args.length) { + banner += ` ${args.join(' ')}` + } + banner += '\n' + return banner +} const runScriptPkg = async options => { const { event, path, scriptShell, + binPaths = false, env = {}, stdio = 'pipe', pkg, args = [], - stdioString = false, + stdioString, // note: only used when stdio:inherit banner = true, // how long to wait for a process.kill signal @@ -26,51 +36,60 @@ const runScriptPkg = async options => { signalTimeout = 500, } = options - const {scripts = {}, gypfile} = pkg + const { scripts = {}, gypfile } = pkg let cmd = null - if (options.cmd) + if (options.cmd) { cmd = options.cmd - else if (pkg.scripts && pkg.scripts[event]) - cmd = pkg.scripts[event] + args.map(a => ` ${JSON.stringify(a)}`).join('') - else if ( // If there is no preinstall or install script, default to rebuilding node-gyp packages. + } else if (pkg.scripts && pkg.scripts[event]) { + cmd = pkg.scripts[event] + } else if ( + // If there is no preinstall or install script, default to rebuilding node-gyp packages. event === 'install' && !scripts.install && !scripts.preinstall && gypfile !== false && await isNodeGypPackage(path) - ) + ) { cmd = defaultGypInstallScript - else if (event === 'start' && await isServerPackage(path)) - cmd = 'node server.js' + args.map(a => ` ${JSON.stringify(a)}`).join('') + } else if (event === 'start' && await isServerPackage(path)) { + cmd = 'node server.js' + } - if (!cmd) + if (!cmd) { return { code: 0, signal: null } + } if (stdio === 'inherit' && banner !== false) { // we're dumping to the parent's stdout, so print the banner - console.log(bruce(pkg._id, event, cmd)) + console.log(bruce(pkg._id, event, cmd, args)) } - const p = promiseSpawn(...makeSpawnArgs({ + const [spawnShell, spawnArgs, spawnOpts] = makeSpawnArgs({ event, path, scriptShell, + binPaths, env: packageEnvs(env, pkg), stdio, cmd, + args, stdioString, - }), { + }) + + const p = promiseSpawn(spawnShell, spawnArgs, spawnOpts, { event, script: cmd, pkgid: pkg._id, path, }) - if (stdio === 'inherit') + if (stdio === 'inherit') { signalManager.add(p.process) + } - if (p.stdin) + if (p.stdin) { p.stdin.end() + } return p.catch(er => { const { signal } = er @@ -80,8 +99,9 @@ const runScriptPkg = async options => { // this also keeps the node process open long enough to actually // get the signal, rather than terminating gracefully. return new Promise((res, rej) => setTimeout(() => rej(er), signalTimeout)) - } else + } else { throw er + } }) } diff --git a/node_modules/@npmcli/run-script/lib/run-script.js b/node_modules/@npmcli/run-script/lib/run-script.js index af33d21..e9d1826 100644 --- a/node_modules/@npmcli/run-script/lib/run-script.js +++ b/node_modules/@npmcli/run-script/lib/run-script.js @@ -5,9 +5,10 @@ const isServerPackage = require('./is-server-package.js') const runScript = options => { validateOptions(options) - const {pkg, path} = options + const { pkg, path } = options return pkg ? runScriptPkg(options) - : rpj(path + '/package.json').then(pkg => runScriptPkg({...options, pkg})) + : rpj(path + '/package.json') + .then(readPackage => runScriptPkg({ ...options, pkg: readPackage })) } module.exports = Object.assign(runScript, { isServerPackage }) diff --git a/node_modules/@npmcli/run-script/lib/set-path.js b/node_modules/@npmcli/run-script/lib/set-path.js index d7bd2c2..c59c270 100644 --- a/node_modules/@npmcli/run-script/lib/set-path.js +++ b/node_modules/@npmcli/run-script/lib/set-path.js @@ -1,5 +1,4 @@ -const {resolve, dirname} = require('path') -const isWindows = require('./is-windows.js') +const { resolve, dirname, delimiter } = require('path') // the path here is relative, even though it does not need to be // in order to make the posix tests pass in windows const nodeGypPath = resolve(__dirname, '../lib/node-gyp-bin') @@ -7,18 +6,19 @@ const nodeGypPath = resolve(__dirname, '../lib/node-gyp-bin') // Windows typically calls its PATH environ 'Path', but this is not // guaranteed, nor is it guaranteed to be the only one. Merge them // all together in the order they appear in the object. -const setPATH = (projectPath, env) => { - // not require('path').delimiter, because we fake this for testing - const delimiter = isWindows ? ';' : ':' +const setPATH = (projectPath, binPaths, env) => { const PATH = Object.keys(env).filter(p => /^path$/i.test(p) && env[p]) .map(p => env[p].split(delimiter)) - .reduce((set, p) => set.concat(p.filter(p => !set.includes(p))), []) + .reduce((set, p) => set.concat(p.filter(concatted => !set.includes(concatted))), []) .join(delimiter) const pathArr = [] + if (binPaths) { + pathArr.push(...binPaths) + } // unshift the ./node_modules/.bin from every folder // walk up until dirname() does nothing, at the root - // XXX should we specify a cwd that we don't go above? + // XXX we should specify a cwd that we don't go above let p = projectPath let pp do { @@ -34,8 +34,9 @@ const setPATH = (projectPath, env) => { // npm or arborist or whoever to just provide that by putting it in // the PATH environ, since that's preserved anyway. for (const key of Object.keys(env)) { - if (/^path$/i.test(key)) + if (/^path$/i.test(key)) { env[key] = pathVal + } } return env diff --git a/node_modules/@npmcli/run-script/lib/signal-manager.js b/node_modules/@npmcli/run-script/lib/signal-manager.js index 556e758..7e10f85 100644 --- a/node_modules/@npmcli/run-script/lib/signal-manager.js +++ b/node_modules/@npmcli/run-script/lib/signal-manager.js @@ -3,7 +3,7 @@ let handlersInstalled = false const forwardedSignals = [ 'SIGINT', - 'SIGTERM' + 'SIGTERM', ] const handleSignal = signal => { @@ -30,8 +30,9 @@ const cleanupListeners = () => { const add = proc => { runningProcs.add(proc) - if (!handlersInstalled) + if (!handlersInstalled) { setupListeners() + } proc.once('exit', () => { runningProcs.delete(proc) @@ -42,5 +43,5 @@ const add = proc => { module.exports = { add, handleSignal, - forwardedSignals + forwardedSignals, } diff --git a/node_modules/@npmcli/run-script/lib/validate-options.js b/node_modules/@npmcli/run-script/lib/validate-options.js index 48ac5c5..8d85591 100644 --- a/node_modules/@npmcli/run-script/lib/validate-options.js +++ b/node_modules/@npmcli/run-script/lib/validate-options.js @@ -1,6 +1,7 @@ const validateOptions = options => { - if (typeof options !== 'object' || !options) + if (typeof options !== 'object' || !options) { throw new TypeError('invalid options object provided to runScript') + } const { event, @@ -12,20 +13,27 @@ const validateOptions = options => { cmd, } = options - if (!event || typeof event !== 'string') + if (!event || typeof event !== 'string') { throw new TypeError('valid event not provided to runScript') - if (!path || typeof path !== 'string') + } + if (!path || typeof path !== 'string') { throw new TypeError('valid path not provided to runScript') - if (scriptShell !== undefined && typeof scriptShell !== 'string') + } + if (scriptShell !== undefined && typeof scriptShell !== 'string') { throw new TypeError('invalid scriptShell option provided to runScript') - if (typeof env !== 'object' || !env) + } + if (typeof env !== 'object' || !env) { throw new TypeError('invalid env option provided to runScript') - if (typeof stdio !== 'string' && !Array.isArray(stdio)) + } + if (typeof stdio !== 'string' && !Array.isArray(stdio)) { throw new TypeError('invalid stdio option provided to runScript') - if (!Array.isArray(args) || args.some(a => typeof a !== 'string')) + } + if (!Array.isArray(args) || args.some(a => typeof a !== 'string')) { throw new TypeError('invalid args option provided to runScript') - if (cmd !== undefined && typeof cmd !== 'string') + } + if (cmd !== undefined && typeof cmd !== 'string') { throw new TypeError('invalid cmd option provided to runScript') + } } module.exports = validateOptions diff --git a/node_modules/@npmcli/run-script/package.json b/node_modules/@npmcli/run-script/package.json index 9e744e6..dbae573 100644 --- a/node_modules/@npmcli/run-script/package.json +++ b/node_modules/@npmcli/run-script/package.json @@ -1,45 +1,53 @@ { "name": "@npmcli/run-script", - "version": "2.0.0", + "version": "6.0.0", "description": "Run a lifecycle script for a package (descendant of npm-lifecycle)", - "author": "Isaac Z. Schlueter <i@izs.me> (https://izs.me)", + "author": "GitHub Inc.", "license": "ISC", "scripts": { "test": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", "eslint": "eslint", - "lint": "npm run eslint -- \"lib/**/*.js\"", - "lintfix": "npm run lint -- --fix" - }, - "tap": { - "check-coverage": true, - "coverage-map": "map.js" + "lint": "eslint \"**/*.js\"", + "lintfix": "npm run lint -- --fix", + "postlint": "template-oss-check", + "snap": "tap", + "posttest": "npm run lint", + "template-oss-apply": "template-oss-apply --force" }, "devDependencies": { - "eslint": "^7.19.0", - "eslint-plugin-import": "^2.22.1", - "eslint-plugin-node": "^11.1.0", - "eslint-plugin-promise": "^4.2.1", - "eslint-plugin-standard": "^5.0.0", - "minipass": "^3.1.1", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.8.0", + "minipass": "^3.1.6", "require-inject": "^1.4.4", - "tap": "^15.0.4" + "tap": "^16.0.1" }, "dependencies": { - "@npmcli/node-gyp": "^1.0.2", - "@npmcli/promise-spawn": "^1.3.2", - "node-gyp": "^8.2.0", - "read-package-json-fast": "^2.0.1" + "@npmcli/node-gyp": "^3.0.0", + "@npmcli/promise-spawn": "^6.0.0", + "node-gyp": "^9.0.0", + "read-package-json-fast": "^3.0.0", + "which": "^3.0.0" }, "files": [ - "lib/**/*.js", - "lib/node-gyp-bin" + "bin/", + "lib/" ], "main": "lib/run-script.js", "repository": { "type": "git", - "url": "git+https://github.com/npm/run-script.git" + "url": "https://github.com/npm/run-script.git" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.8.0" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/node_modules/debuglog/LICENSE b/node_modules/abort-controller/LICENSE similarity index 56% rename from node_modules/debuglog/LICENSE rename to node_modules/abort-controller/LICENSE index a3187cc..c914149 100644 --- a/node_modules/debuglog/LICENSE +++ b/node_modules/abort-controller/LICENSE @@ -1,19 +1,21 @@ -Copyright Joyent, Inc. and other Node contributors. All rights reserved. +MIT License + +Copyright (c) 2017 Toru Nagashima Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to -deal in the Software without restriction, including without limitation the -rights to use, copy, modify, merge, publish, distribute, sublicense, and/or -sell copies of the Software, and to permit persons to whom the Software is +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS -IN THE SOFTWARE. +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/node_modules/abort-controller/browser.js b/node_modules/abort-controller/browser.js new file mode 100644 index 0000000..b0c5ec3 --- /dev/null +++ b/node_modules/abort-controller/browser.js @@ -0,0 +1,13 @@ +/*globals self, window */ +"use strict" + +/*eslint-disable @mysticatea/prettier */ +const { AbortController, AbortSignal } = + typeof self !== "undefined" ? self : + typeof window !== "undefined" ? window : + /* otherwise */ undefined +/*eslint-enable @mysticatea/prettier */ + +module.exports = AbortController +module.exports.AbortSignal = AbortSignal +module.exports.default = AbortController diff --git a/node_modules/abort-controller/browser.mjs b/node_modules/abort-controller/browser.mjs new file mode 100644 index 0000000..a8f321a --- /dev/null +++ b/node_modules/abort-controller/browser.mjs @@ -0,0 +1,11 @@ +/*globals self, window */ + +/*eslint-disable @mysticatea/prettier */ +const { AbortController, AbortSignal } = + typeof self !== "undefined" ? self : + typeof window !== "undefined" ? window : + /* otherwise */ undefined +/*eslint-enable @mysticatea/prettier */ + +export default AbortController +export { AbortController, AbortSignal } diff --git a/node_modules/abort-controller/dist/abort-controller.d.ts b/node_modules/abort-controller/dist/abort-controller.d.ts new file mode 100644 index 0000000..75852fb --- /dev/null +++ b/node_modules/abort-controller/dist/abort-controller.d.ts @@ -0,0 +1,43 @@ +import { EventTarget } from "event-target-shim" + +type Events = { + abort: any +} +type EventAttributes = { + onabort: any +} +/** + * The signal class. + * @see https://dom.spec.whatwg.org/#abortsignal + */ +declare class AbortSignal extends EventTarget<Events, EventAttributes> { + /** + * AbortSignal cannot be constructed directly. + */ + constructor() + /** + * Returns `true` if this `AbortSignal`"s `AbortController` has signaled to abort, and `false` otherwise. + */ + readonly aborted: boolean +} +/** + * The AbortController. + * @see https://dom.spec.whatwg.org/#abortcontroller + */ +declare class AbortController { + /** + * Initialize this controller. + */ + constructor() + /** + * Returns the `AbortSignal` object associated with this object. + */ + readonly signal: AbortSignal + /** + * Abort and signal to any observers that the associated activity is to be aborted. + */ + abort(): void +} + +export default AbortController +export { AbortController, AbortSignal } diff --git a/node_modules/abort-controller/dist/abort-controller.js b/node_modules/abort-controller/dist/abort-controller.js new file mode 100644 index 0000000..49af739 --- /dev/null +++ b/node_modules/abort-controller/dist/abort-controller.js @@ -0,0 +1,127 @@ +/** + * @author Toru Nagashima <https://github.com/mysticatea> + * See LICENSE file in root directory for full license. + */ +'use strict'; + +Object.defineProperty(exports, '__esModule', { value: true }); + +var eventTargetShim = require('event-target-shim'); + +/** + * The signal class. + * @see https://dom.spec.whatwg.org/#abortsignal + */ +class AbortSignal extends eventTargetShim.EventTarget { + /** + * AbortSignal cannot be constructed directly. + */ + constructor() { + super(); + throw new TypeError("AbortSignal cannot be constructed directly"); + } + /** + * Returns `true` if this `AbortSignal`'s `AbortController` has signaled to abort, and `false` otherwise. + */ + get aborted() { + const aborted = abortedFlags.get(this); + if (typeof aborted !== "boolean") { + throw new TypeError(`Expected 'this' to be an 'AbortSignal' object, but got ${this === null ? "null" : typeof this}`); + } + return aborted; + } +} +eventTargetShim.defineEventAttribute(AbortSignal.prototype, "abort"); +/** + * Create an AbortSignal object. + */ +function createAbortSignal() { + const signal = Object.create(AbortSignal.prototype); + eventTargetShim.EventTarget.call(signal); + abortedFlags.set(signal, false); + return signal; +} +/** + * Abort a given signal. + */ +function abortSignal(signal) { + if (abortedFlags.get(signal) !== false) { + return; + } + abortedFlags.set(signal, true); + signal.dispatchEvent({ type: "abort" }); +} +/** + * Aborted flag for each instances. + */ +const abortedFlags = new WeakMap(); +// Properties should be enumerable. +Object.defineProperties(AbortSignal.prototype, { + aborted: { enumerable: true }, +}); +// `toString()` should return `"[object AbortSignal]"` +if (typeof Symbol === "function" && typeof Symbol.toStringTag === "symbol") { + Object.defineProperty(AbortSignal.prototype, Symbol.toStringTag, { + configurable: true, + value: "AbortSignal", + }); +} + +/** + * The AbortController. + * @see https://dom.spec.whatwg.org/#abortcontroller + */ +class AbortController { + /** + * Initialize this controller. + */ + constructor() { + signals.set(this, createAbortSignal()); + } + /** + * Returns the `AbortSignal` object associated with this object. + */ + get signal() { + return getSignal(this); + } + /** + * Abort and signal to any observers that the associated activity is to be aborted. + */ + abort() { + abortSignal(getSignal(this)); + } +} +/** + * Associated signals. + */ +const signals = new WeakMap(); +/** + * Get the associated signal of a given controller. + */ +function getSignal(controller) { + const signal = signals.get(controller); + if (signal == null) { + throw new TypeError(`Expected 'this' to be an 'AbortController' object, but got ${controller === null ? "null" : typeof controller}`); + } + return signal; +} +// Properties should be enumerable. +Object.defineProperties(AbortController.prototype, { + signal: { enumerable: true }, + abort: { enumerable: true }, +}); +if (typeof Symbol === "function" && typeof Symbol.toStringTag === "symbol") { + Object.defineProperty(AbortController.prototype, Symbol.toStringTag, { + configurable: true, + value: "AbortController", + }); +} + +exports.AbortController = AbortController; +exports.AbortSignal = AbortSignal; +exports.default = AbortController; + +module.exports = AbortController +module.exports.AbortController = module.exports["default"] = AbortController +module.exports.AbortSignal = AbortSignal +//# sourceMappingURL=abort-controller.js.map diff --git a/node_modules/abort-controller/dist/abort-controller.js.map b/node_modules/abort-controller/dist/abort-controller.js.map new file mode 100644 index 0000000..cfdcafd --- /dev/null +++ b/node_modules/abort-controller/dist/abort-controller.js.map @@ -0,0 +1 @@ +{"version":3,"file":"abort-controller.js","sources":["../src/abort-signal.ts","../src/abort-controller.ts"],"sourcesContent":["import {\n // Event,\n EventTarget,\n // Type,\n defineEventAttribute,\n} from \"event-target-shim\"\n\n// Known Limitation\n// Use `any` because the type of `AbortSignal` in `lib.dom.d.ts` is wrong and\n// to make assignable our `AbortSignal` into that.\n// https://github.com/Microsoft/TSJS-lib-generator/pull/623\ntype Events = {\n abort: any // Event & Type<\"abort\">\n}\ntype EventAttributes = {\n onabort: any // Event & Type<\"abort\">\n}\n\n/**\n * The signal class.\n * @see https://dom.spec.whatwg.org/#abortsignal\n */\nexport default class AbortSignal extends EventTarget<Events, EventAttributes> {\n /**\n * AbortSignal cannot be constructed directly.\n */\n public constructor() {\n super()\n throw new TypeError(\"AbortSignal cannot be constructed directly\")\n }\n\n /**\n * Returns `true` if this `AbortSignal`'s `AbortController` has signaled to abort, and `false` otherwise.\n */\n public get aborted(): boolean {\n const aborted = abortedFlags.get(this)\n if (typeof aborted !== \"boolean\") {\n throw new TypeError(\n `Expected 'this' to be an 'AbortSignal' object, but got ${\n this === null ? \"null\" : typeof this\n }`,\n )\n }\n return aborted\n }\n}\ndefineEventAttribute(AbortSignal.prototype, \"abort\")\n\n/**\n * Create an AbortSignal object.\n */\nexport function createAbortSignal(): AbortSignal {\n const signal = Object.create(AbortSignal.prototype)\n EventTarget.call(signal)\n abortedFlags.set(signal, false)\n return signal\n}\n\n/**\n * Abort a given signal.\n */\nexport function abortSignal(signal: AbortSignal): void {\n if (abortedFlags.get(signal) !== false) {\n return\n }\n\n abortedFlags.set(signal, true)\n signal.dispatchEvent<\"abort\">({ type: \"abort\" })\n}\n\n/**\n * Aborted flag for each instances.\n */\nconst abortedFlags = new WeakMap<AbortSignal, boolean>()\n\n// Properties should be enumerable.\nObject.defineProperties(AbortSignal.prototype, {\n aborted: { enumerable: true },\n})\n\n// `toString()` should return `\"[object AbortSignal]\"`\nif (typeof Symbol === \"function\" && typeof Symbol.toStringTag === \"symbol\") {\n Object.defineProperty(AbortSignal.prototype, Symbol.toStringTag, {\n configurable: true,\n value: \"AbortSignal\",\n })\n}\n","import AbortSignal, { abortSignal, createAbortSignal } from \"./abort-signal\"\n\n/**\n * The AbortController.\n * @see https://dom.spec.whatwg.org/#abortcontroller\n */\nexport default class AbortController {\n /**\n * Initialize this controller.\n */\n public constructor() {\n signals.set(this, createAbortSignal())\n }\n\n /**\n * Returns the `AbortSignal` object associated with this object.\n */\n public get signal(): AbortSignal {\n return getSignal(this)\n }\n\n /**\n * Abort and signal to any observers that the associated activity is to be aborted.\n */\n public abort(): void {\n abortSignal(getSignal(this))\n }\n}\n\n/**\n * Associated signals.\n */\nconst signals = new WeakMap<AbortController, AbortSignal>()\n\n/**\n * Get the associated signal of a given controller.\n */\nfunction getSignal(controller: AbortController): AbortSignal {\n const signal = signals.get(controller)\n if (signal == null) {\n throw new TypeError(\n `Expected 'this' to be an 'AbortController' object, but got ${\n controller === null ? \"null\" : typeof controller\n }`,\n )\n }\n return signal\n}\n\n// Properties should be enumerable.\nObject.defineProperties(AbortController.prototype, {\n signal: { enumerable: true },\n abort: { enumerable: true },\n})\n\nif (typeof Symbol === \"function\" && typeof Symbol.toStringTag === \"symbol\") {\n Object.defineProperty(AbortController.prototype, Symbol.toStringTag, {\n configurable: true,\n value: \"AbortController\",\n })\n}\n\nexport { AbortController, AbortSignal }\n"],"names":["EventTarget","defineEventAttribute"],"mappings":";;;;;;;;;;AAkBA;;;;AAIA,MAAqB,WAAY,SAAQA,2BAAoC;;;;IAIzE;QACI,KAAK,EAAE,CAAA;QACP,MAAM,IAAI,SAAS,CAAC,4CAA4C,CAAC,CAAA;KACpE;;;;IAKD,IAAW,OAAO;QACd,MAAM,OAAO,GAAG,YAAY,CAAC,GAAG,CAAC,IAAI,CAAC,CAAA;QACtC,IAAI,OAAO,OAAO,KAAK,SAAS,EAAE;YAC9B,MAAM,IAAI,SAAS,CACf,0DACI,IAAI,KAAK,IAAI,GAAG,MAAM,GAAG,OAAO,IACpC,EAAE,CACL,CAAA;SACJ;QACD,OAAO,OAAO,CAAA;KACjB;CACJ;AACDC,oCAAoB,CAAC,WAAW,CAAC,SAAS,EAAE,OAAO,CAAC,CAAA;;;;AAKpD,SAAgB,iBAAiB;IAC7B,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC,WAAW,CAAC,SAAS,CAAC,CAAA;IACnDD,2BAAW,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;IACxB,YAAY,CAAC,GAAG,CAAC,MAAM,EAAE,KAAK,CAAC,CAAA;IAC/B,OAAO,MAAM,CAAA;CAChB;;;;AAKD,SAAgB,WAAW,CAAC,MAAmB;IAC3C,IAAI,YAAY,CAAC,GAAG,CAAC,MAAM,CAAC,KAAK,KAAK,EAAE;QACpC,OAAM;KACT;IAED,YAAY,CAAC,GAAG,CAAC,MAAM,EAAE,IAAI,CAAC,CAAA;IAC9B,MAAM,CAAC,aAAa,CAAU,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC,CAAA;CACnD;;;;AAKD,MAAM,YAAY,GAAG,IAAI,OAAO,EAAwB,CAAA;;AAGxD,MAAM,CAAC,gBAAgB,CAAC,WAAW,CAAC,SAAS,EAAE;IAC3C,OAAO,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE;CAChC,CAAC,CAAA;;AAGF,IAAI,OAAO,MAAM,KAAK,UAAU,IAAI,OAAO,MAAM,CAAC,WAAW,KAAK,QAAQ,EAAE;IACxE,MAAM,CAAC,cAAc,CAAC,WAAW,CAAC,SAAS,EAAE,MAAM,CAAC,WAAW,EAAE;QAC7D,YAAY,EAAE,IAAI;QAClB,KAAK,EAAE,aAAa;KACvB,CAAC,CAAA;CACL;;ACpFD;;;;AAIA,MAAqB,eAAe;;;;IAIhC;QACI,OAAO,CAAC,GAAG,CAAC,IAAI,EAAE,iBAAiB,EAAE,CAAC,CAAA;KACzC;;;;IAKD,IAAW,MAAM;QACb,OAAO,SAAS,CAAC,IAAI,CAAC,CAAA;KACzB;;;;IAKM,KAAK;QACR,WAAW,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAA;KAC/B;CACJ;;;;AAKD,MAAM,OAAO,GAAG,IAAI,OAAO,EAAgC,CAAA;;;;AAK3D,SAAS,SAAS,CAAC,UAA2B;IAC1C,MAAM,MAAM,GAAG,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,CAAA;IACtC,IAAI,MAAM,IAAI,IAAI,EAAE;QAChB,MAAM,IAAI,SAAS,CACf,8DACI,UAAU,KAAK,IAAI,GAAG,MAAM,GAAG,OAAO,UAC1C,EAAE,CACL,CAAA;KACJ;IACD,OAAO,MAAM,CAAA;CAChB;;AAGD,MAAM,CAAC,gBAAgB,CAAC,eAAe,CAAC,SAAS,EAAE;IAC/C,MAAM,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE;IAC5B,KAAK,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE;CAC9B,CAAC,CAAA;AAEF,IAAI,OAAO,MAAM,KAAK,UAAU,IAAI,OAAO,MAAM,CAAC,WAAW,KAAK,QAAQ,EAAE;IACxE,MAAM,CAAC,cAAc,CAAC,eAAe,CAAC,SAAS,EAAE,MAAM,CAAC,WAAW,EAAE;QACjE,YAAY,EAAE,IAAI;QAClB,KAAK,EAAE,iBAAiB;KAC3B,CAAC,CAAA;CACL;;;;;;;;;;;;;"} \ No newline at end of file diff --git a/node_modules/abort-controller/dist/abort-controller.mjs b/node_modules/abort-controller/dist/abort-controller.mjs new file mode 100644 index 0000000..88ba22d --- /dev/null +++ b/node_modules/abort-controller/dist/abort-controller.mjs @@ -0,0 +1,118 @@ +/** + * @author Toru Nagashima <https://github.com/mysticatea> + * See LICENSE file in root directory for full license. + */ +import { EventTarget, defineEventAttribute } from 'event-target-shim'; + +/** + * The signal class. + * @see https://dom.spec.whatwg.org/#abortsignal + */ +class AbortSignal extends EventTarget { + /** + * AbortSignal cannot be constructed directly. + */ + constructor() { + super(); + throw new TypeError("AbortSignal cannot be constructed directly"); + } + /** + * Returns `true` if this `AbortSignal`'s `AbortController` has signaled to abort, and `false` otherwise. + */ + get aborted() { + const aborted = abortedFlags.get(this); + if (typeof aborted !== "boolean") { + throw new TypeError(`Expected 'this' to be an 'AbortSignal' object, but got ${this === null ? "null" : typeof this}`); + } + return aborted; + } +} +defineEventAttribute(AbortSignal.prototype, "abort"); +/** + * Create an AbortSignal object. + */ +function createAbortSignal() { + const signal = Object.create(AbortSignal.prototype); + EventTarget.call(signal); + abortedFlags.set(signal, false); + return signal; +} +/** + * Abort a given signal. + */ +function abortSignal(signal) { + if (abortedFlags.get(signal) !== false) { + return; + } + abortedFlags.set(signal, true); + signal.dispatchEvent({ type: "abort" }); +} +/** + * Aborted flag for each instances. + */ +const abortedFlags = new WeakMap(); +// Properties should be enumerable. +Object.defineProperties(AbortSignal.prototype, { + aborted: { enumerable: true }, +}); +// `toString()` should return `"[object AbortSignal]"` +if (typeof Symbol === "function" && typeof Symbol.toStringTag === "symbol") { + Object.defineProperty(AbortSignal.prototype, Symbol.toStringTag, { + configurable: true, + value: "AbortSignal", + }); +} + +/** + * The AbortController. + * @see https://dom.spec.whatwg.org/#abortcontroller + */ +class AbortController { + /** + * Initialize this controller. + */ + constructor() { + signals.set(this, createAbortSignal()); + } + /** + * Returns the `AbortSignal` object associated with this object. + */ + get signal() { + return getSignal(this); + } + /** + * Abort and signal to any observers that the associated activity is to be aborted. + */ + abort() { + abortSignal(getSignal(this)); + } +} +/** + * Associated signals. + */ +const signals = new WeakMap(); +/** + * Get the associated signal of a given controller. + */ +function getSignal(controller) { + const signal = signals.get(controller); + if (signal == null) { + throw new TypeError(`Expected 'this' to be an 'AbortController' object, but got ${controller === null ? "null" : typeof controller}`); + } + return signal; +} +// Properties should be enumerable. +Object.defineProperties(AbortController.prototype, { + signal: { enumerable: true }, + abort: { enumerable: true }, +}); +if (typeof Symbol === "function" && typeof Symbol.toStringTag === "symbol") { + Object.defineProperty(AbortController.prototype, Symbol.toStringTag, { + configurable: true, + value: "AbortController", + }); +} + +export default AbortController; +export { AbortController, AbortSignal }; +//# sourceMappingURL=abort-controller.mjs.map diff --git a/node_modules/abort-controller/dist/abort-controller.mjs.map b/node_modules/abort-controller/dist/abort-controller.mjs.map new file mode 100644 index 0000000..1e8fa6b --- /dev/null +++ b/node_modules/abort-controller/dist/abort-controller.mjs.map @@ -0,0 +1 @@ +{"version":3,"file":"abort-controller.mjs","sources":["../src/abort-signal.ts","../src/abort-controller.ts"],"sourcesContent":["import {\n // Event,\n EventTarget,\n // Type,\n defineEventAttribute,\n} from \"event-target-shim\"\n\n// Known Limitation\n// Use `any` because the type of `AbortSignal` in `lib.dom.d.ts` is wrong and\n// to make assignable our `AbortSignal` into that.\n// https://github.com/Microsoft/TSJS-lib-generator/pull/623\ntype Events = {\n abort: any // Event & Type<\"abort\">\n}\ntype EventAttributes = {\n onabort: any // Event & Type<\"abort\">\n}\n\n/**\n * The signal class.\n * @see https://dom.spec.whatwg.org/#abortsignal\n */\nexport default class AbortSignal extends EventTarget<Events, EventAttributes> {\n /**\n * AbortSignal cannot be constructed directly.\n */\n public constructor() {\n super()\n throw new TypeError(\"AbortSignal cannot be constructed directly\")\n }\n\n /**\n * Returns `true` if this `AbortSignal`'s `AbortController` has signaled to abort, and `false` otherwise.\n */\n public get aborted(): boolean {\n const aborted = abortedFlags.get(this)\n if (typeof aborted !== \"boolean\") {\n throw new TypeError(\n `Expected 'this' to be an 'AbortSignal' object, but got ${\n this === null ? \"null\" : typeof this\n }`,\n )\n }\n return aborted\n }\n}\ndefineEventAttribute(AbortSignal.prototype, \"abort\")\n\n/**\n * Create an AbortSignal object.\n */\nexport function createAbortSignal(): AbortSignal {\n const signal = Object.create(AbortSignal.prototype)\n EventTarget.call(signal)\n abortedFlags.set(signal, false)\n return signal\n}\n\n/**\n * Abort a given signal.\n */\nexport function abortSignal(signal: AbortSignal): void {\n if (abortedFlags.get(signal) !== false) {\n return\n }\n\n abortedFlags.set(signal, true)\n signal.dispatchEvent<\"abort\">({ type: \"abort\" })\n}\n\n/**\n * Aborted flag for each instances.\n */\nconst abortedFlags = new WeakMap<AbortSignal, boolean>()\n\n// Properties should be enumerable.\nObject.defineProperties(AbortSignal.prototype, {\n aborted: { enumerable: true },\n})\n\n// `toString()` should return `\"[object AbortSignal]\"`\nif (typeof Symbol === \"function\" && typeof Symbol.toStringTag === \"symbol\") {\n Object.defineProperty(AbortSignal.prototype, Symbol.toStringTag, {\n configurable: true,\n value: \"AbortSignal\",\n })\n}\n","import AbortSignal, { abortSignal, createAbortSignal } from \"./abort-signal\"\n\n/**\n * The AbortController.\n * @see https://dom.spec.whatwg.org/#abortcontroller\n */\nexport default class AbortController {\n /**\n * Initialize this controller.\n */\n public constructor() {\n signals.set(this, createAbortSignal())\n }\n\n /**\n * Returns the `AbortSignal` object associated with this object.\n */\n public get signal(): AbortSignal {\n return getSignal(this)\n }\n\n /**\n * Abort and signal to any observers that the associated activity is to be aborted.\n */\n public abort(): void {\n abortSignal(getSignal(this))\n }\n}\n\n/**\n * Associated signals.\n */\nconst signals = new WeakMap<AbortController, AbortSignal>()\n\n/**\n * Get the associated signal of a given controller.\n */\nfunction getSignal(controller: AbortController): AbortSignal {\n const signal = signals.get(controller)\n if (signal == null) {\n throw new TypeError(\n `Expected 'this' to be an 'AbortController' object, but got ${\n controller === null ? \"null\" : typeof controller\n }`,\n )\n }\n return signal\n}\n\n// Properties should be enumerable.\nObject.defineProperties(AbortController.prototype, {\n signal: { enumerable: true },\n abort: { enumerable: true },\n})\n\nif (typeof Symbol === \"function\" && typeof Symbol.toStringTag === \"symbol\") {\n Object.defineProperty(AbortController.prototype, Symbol.toStringTag, {\n configurable: true,\n value: \"AbortController\",\n })\n}\n\nexport { AbortController, AbortSignal }\n"],"names":[],"mappings":";;;;;;AAkBA;;;;AAIA,MAAqB,WAAY,SAAQ,WAAoC;;;;IAIzE;QACI,KAAK,EAAE,CAAA;QACP,MAAM,IAAI,SAAS,CAAC,4CAA4C,CAAC,CAAA;KACpE;;;;IAKD,IAAW,OAAO;QACd,MAAM,OAAO,GAAG,YAAY,CAAC,GAAG,CAAC,IAAI,CAAC,CAAA;QACtC,IAAI,OAAO,OAAO,KAAK,SAAS,EAAE;YAC9B,MAAM,IAAI,SAAS,CACf,0DACI,IAAI,KAAK,IAAI,GAAG,MAAM,GAAG,OAAO,IACpC,EAAE,CACL,CAAA;SACJ;QACD,OAAO,OAAO,CAAA;KACjB;CACJ;AACD,oBAAoB,CAAC,WAAW,CAAC,SAAS,EAAE,OAAO,CAAC,CAAA;;;;AAKpD,SAAgB,iBAAiB;IAC7B,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC,WAAW,CAAC,SAAS,CAAC,CAAA;IACnD,WAAW,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;IACxB,YAAY,CAAC,GAAG,CAAC,MAAM,EAAE,KAAK,CAAC,CAAA;IAC/B,OAAO,MAAM,CAAA;CAChB;;;;AAKD,SAAgB,WAAW,CAAC,MAAmB;IAC3C,IAAI,YAAY,CAAC,GAAG,CAAC,MAAM,CAAC,KAAK,KAAK,EAAE;QACpC,OAAM;KACT;IAED,YAAY,CAAC,GAAG,CAAC,MAAM,EAAE,IAAI,CAAC,CAAA;IAC9B,MAAM,CAAC,aAAa,CAAU,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC,CAAA;CACnD;;;;AAKD,MAAM,YAAY,GAAG,IAAI,OAAO,EAAwB,CAAA;;AAGxD,MAAM,CAAC,gBAAgB,CAAC,WAAW,CAAC,SAAS,EAAE;IAC3C,OAAO,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE;CAChC,CAAC,CAAA;;AAGF,IAAI,OAAO,MAAM,KAAK,UAAU,IAAI,OAAO,MAAM,CAAC,WAAW,KAAK,QAAQ,EAAE;IACxE,MAAM,CAAC,cAAc,CAAC,WAAW,CAAC,SAAS,EAAE,MAAM,CAAC,WAAW,EAAE;QAC7D,YAAY,EAAE,IAAI;QAClB,KAAK,EAAE,aAAa;KACvB,CAAC,CAAA;CACL;;ACpFD;;;;AAIA,MAAqB,eAAe;;;;IAIhC;QACI,OAAO,CAAC,GAAG,CAAC,IAAI,EAAE,iBAAiB,EAAE,CAAC,CAAA;KACzC;;;;IAKD,IAAW,MAAM;QACb,OAAO,SAAS,CAAC,IAAI,CAAC,CAAA;KACzB;;;;IAKM,KAAK;QACR,WAAW,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAA;KAC/B;CACJ;;;;AAKD,MAAM,OAAO,GAAG,IAAI,OAAO,EAAgC,CAAA;;;;AAK3D,SAAS,SAAS,CAAC,UAA2B;IAC1C,MAAM,MAAM,GAAG,OAAO,CAAC,GAAG,CAAC,UAAU,CAAC,CAAA;IACtC,IAAI,MAAM,IAAI,IAAI,EAAE;QAChB,MAAM,IAAI,SAAS,CACf,8DACI,UAAU,KAAK,IAAI,GAAG,MAAM,GAAG,OAAO,UAC1C,EAAE,CACL,CAAA;KACJ;IACD,OAAO,MAAM,CAAA;CAChB;;AAGD,MAAM,CAAC,gBAAgB,CAAC,eAAe,CAAC,SAAS,EAAE;IAC/C,MAAM,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE;IAC5B,KAAK,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE;CAC9B,CAAC,CAAA;AAEF,IAAI,OAAO,MAAM,KAAK,UAAU,IAAI,OAAO,MAAM,CAAC,WAAW,KAAK,QAAQ,EAAE;IACxE,MAAM,CAAC,cAAc,CAAC,eAAe,CAAC,SAAS,EAAE,MAAM,CAAC,WAAW,EAAE;QACjE,YAAY,EAAE,IAAI;QAClB,KAAK,EAAE,iBAAiB;KAC3B,CAAC,CAAA;CACL;;;;;"} \ No newline at end of file diff --git a/node_modules/abort-controller/dist/abort-controller.umd.js b/node_modules/abort-controller/dist/abort-controller.umd.js new file mode 100644 index 0000000..f643cfd --- /dev/null +++ b/node_modules/abort-controller/dist/abort-controller.umd.js @@ -0,0 +1,5 @@ +/** + * @author Toru Nagashima <https://github.com/mysticatea> + * See LICENSE file in root directory for full license. + */(function(a,b){"object"==typeof exports&&"undefined"!=typeof module?b(exports):"function"==typeof define&&define.amd?define(["exports"],b):(a=a||self,b(a.AbortControllerShim={}))})(this,function(a){'use strict';function b(a){return b="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},b(a)}function c(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function")}function d(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)}function e(a,b,c){return b&&d(a.prototype,b),c&&d(a,c),a}function f(a,b){if("function"!=typeof b&&null!==b)throw new TypeError("Super expression must either be null or a function");a.prototype=Object.create(b&&b.prototype,{constructor:{value:a,writable:!0,configurable:!0}}),b&&h(a,b)}function g(a){return g=Object.setPrototypeOf?Object.getPrototypeOf:function(a){return a.__proto__||Object.getPrototypeOf(a)},g(a)}function h(a,b){return h=Object.setPrototypeOf||function(a,b){return a.__proto__=b,a},h(a,b)}function i(a){if(void 0===a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return a}function j(a,b){return b&&("object"==typeof b||"function"==typeof b)?b:i(a)}function k(a){var b=F.get(a);return console.assert(null!=b,"'this' is expected an Event object, but got",a),b}function l(a){return null==a.passiveListener?void(!a.event.cancelable||(a.canceled=!0,"function"==typeof a.event.preventDefault&&a.event.preventDefault())):void("undefined"!=typeof console&&"function"==typeof console.error&&console.error("Unable to preventDefault inside passive event listener invocation.",a.passiveListener))}function m(a,b){F.set(this,{eventTarget:a,event:b,eventPhase:2,currentTarget:a,canceled:!1,stopped:!1,immediateStopped:!1,passiveListener:null,timeStamp:b.timeStamp||Date.now()}),Object.defineProperty(this,"isTrusted",{value:!1,enumerable:!0});for(var c,d=Object.keys(b),e=0;e<d.length;++e)c=d[e],c in this||Object.defineProperty(this,c,n(c))}function n(a){return{get:function(){return k(this).event[a]},set:function(b){k(this).event[a]=b},configurable:!0,enumerable:!0}}function o(a){return{value:function(){var b=k(this).event;return b[a].apply(b,arguments)},configurable:!0,enumerable:!0}}function p(a,b){function c(b,c){a.call(this,b,c)}var d=Object.keys(b);if(0===d.length)return a;c.prototype=Object.create(a.prototype,{constructor:{value:c,configurable:!0,writable:!0}});for(var e,f=0;f<d.length;++f)if(e=d[f],!(e in a.prototype)){var g=Object.getOwnPropertyDescriptor(b,e),h="function"==typeof g.value;Object.defineProperty(c.prototype,e,h?o(e):n(e))}return c}function q(a){if(null==a||a===Object.prototype)return m;var b=G.get(a);return null==b&&(b=p(q(Object.getPrototypeOf(a)),a),G.set(a,b)),b}function r(a,b){var c=q(Object.getPrototypeOf(b));return new c(a,b)}function s(a){return k(a).immediateStopped}function t(a,b){k(a).eventPhase=b}function u(a,b){k(a).currentTarget=b}function v(a,b){k(a).passiveListener=b}function w(a){return null!==a&&"object"===b(a)}function x(a){var b=H.get(a);if(null==b)throw new TypeError("'this' is expected an EventTarget object, but got another value.");return b}function y(a){return{get:function(){for(var b=x(this),c=b.get(a);null!=c;){if(3===c.listenerType)return c.listener;c=c.next}return null},set:function(b){"function"==typeof b||w(b)||(b=null);for(var c=x(this),d=null,e=c.get(a);null!=e;)3===e.listenerType?null===d?null===e.next?c.delete(a):c.set(a,e.next):d.next=e.next:d=e,e=e.next;if(null!==b){var f={listener:b,listenerType:3,passive:!1,once:!1,next:null};null===d?c.set(a,f):d.next=f}},configurable:!0,enumerable:!0}}function z(a,b){Object.defineProperty(a,"on".concat(b),y(b))}function A(a){function b(){B.call(this)}b.prototype=Object.create(B.prototype,{constructor:{value:b,configurable:!0,writable:!0}});for(var c=0;c<a.length;++c)z(b.prototype,a[c]);return b}function B(){if(this instanceof B)return void H.set(this,new Map);if(1===arguments.length&&Array.isArray(arguments[0]))return A(arguments[0]);if(0<arguments.length){for(var a=Array(arguments.length),b=0;b<arguments.length;++b)a[b]=arguments[b];return A(a)}throw new TypeError("Cannot call a class as a function")}function C(){var a=Object.create(K.prototype);return B.call(a),L.set(a,!1),a}function D(a){!1!==L.get(a)||(L.set(a,!0),a.dispatchEvent({type:"abort"}))}function E(a){var c=N.get(a);if(null==c)throw new TypeError("Expected 'this' to be an 'AbortController' object, but got ".concat(null===a?"null":b(a)));return c}var F=new WeakMap,G=new WeakMap;m.prototype={get type(){return k(this).event.type},get target(){return k(this).eventTarget},get currentTarget(){return k(this).currentTarget},composedPath:function(){var a=k(this).currentTarget;return null==a?[]:[a]},get NONE(){return 0},get CAPTURING_PHASE(){return 1},get AT_TARGET(){return 2},get BUBBLING_PHASE(){return 3},get eventPhase(){return k(this).eventPhase},stopPropagation:function(){var a=k(this);a.stopped=!0,"function"==typeof a.event.stopPropagation&&a.event.stopPropagation()},stopImmediatePropagation:function(){var a=k(this);a.stopped=!0,a.immediateStopped=!0,"function"==typeof a.event.stopImmediatePropagation&&a.event.stopImmediatePropagation()},get bubbles(){return!!k(this).event.bubbles},get cancelable(){return!!k(this).event.cancelable},preventDefault:function(){l(k(this))},get defaultPrevented(){return k(this).canceled},get composed(){return!!k(this).event.composed},get timeStamp(){return k(this).timeStamp},get srcElement(){return k(this).eventTarget},get cancelBubble(){return k(this).stopped},set cancelBubble(a){if(a){var b=k(this);b.stopped=!0,"boolean"==typeof b.event.cancelBubble&&(b.event.cancelBubble=!0)}},get returnValue(){return!k(this).canceled},set returnValue(a){a||l(k(this))},initEvent:function(){}},Object.defineProperty(m.prototype,"constructor",{value:m,configurable:!0,writable:!0}),"undefined"!=typeof window&&"undefined"!=typeof window.Event&&(Object.setPrototypeOf(m.prototype,window.Event.prototype),G.set(window.Event.prototype,m));var H=new WeakMap,I=1,J=2;B.prototype={addEventListener:function(a,b,c){if(null!=b){if("function"!=typeof b&&!w(b))throw new TypeError("'listener' should be a function or an object.");var d=x(this),e=w(c),f=e?!!c.capture:!!c,g=f?I:J,h={listener:b,listenerType:g,passive:e&&!!c.passive,once:e&&!!c.once,next:null},i=d.get(a);if(void 0===i)return void d.set(a,h);for(var j=null;null!=i;){if(i.listener===b&&i.listenerType===g)return;j=i,i=i.next}j.next=h}},removeEventListener:function(a,b,c){if(null!=b)for(var d=x(this),e=w(c)?!!c.capture:!!c,f=e?I:J,g=null,h=d.get(a);null!=h;){if(h.listener===b&&h.listenerType===f)return void(null===g?null===h.next?d.delete(a):d.set(a,h.next):g.next=h.next);g=h,h=h.next}},dispatchEvent:function(a){if(null==a||"string"!=typeof a.type)throw new TypeError("\"event.type\" should be a string.");var b=x(this),c=a.type,d=b.get(c);if(null==d)return!0;for(var e=r(this,a),f=null;null!=d;){if(d.once?null===f?null===d.next?b.delete(c):b.set(c,d.next):f.next=d.next:f=d,v(e,d.passive?d.listener:null),"function"==typeof d.listener)try{d.listener.call(this,e)}catch(a){"undefined"!=typeof console&&"function"==typeof console.error&&console.error(a)}else d.listenerType!==3&&"function"==typeof d.listener.handleEvent&&d.listener.handleEvent(e);if(s(e))break;d=d.next}return v(e,null),t(e,0),u(e,null),!e.defaultPrevented}},Object.defineProperty(B.prototype,"constructor",{value:B,configurable:!0,writable:!0}),"undefined"!=typeof window&&"undefined"!=typeof window.EventTarget&&Object.setPrototypeOf(B.prototype,window.EventTarget.prototype);var K=function(a){function d(){var a;throw c(this,d),a=j(this,g(d).call(this)),new TypeError("AbortSignal cannot be constructed directly")}return f(d,a),e(d,[{key:"aborted",get:function(){var a=L.get(this);if("boolean"!=typeof a)throw new TypeError("Expected 'this' to be an 'AbortSignal' object, but got ".concat(null===this?"null":b(this)));return a}}]),d}(B);z(K.prototype,"abort");var L=new WeakMap;Object.defineProperties(K.prototype,{aborted:{enumerable:!0}}),"function"==typeof Symbol&&"symbol"===b(Symbol.toStringTag)&&Object.defineProperty(K.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortSignal"});var M=function(){function a(){c(this,a),N.set(this,C())}return e(a,[{key:"abort",value:function(){D(E(this))}},{key:"signal",get:function(){return E(this)}}]),a}(),N=new WeakMap;if(Object.defineProperties(M.prototype,{signal:{enumerable:!0},abort:{enumerable:!0}}),"function"==typeof Symbol&&"symbol"===b(Symbol.toStringTag)&&Object.defineProperty(M.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortController"}),a.AbortController=M,a.AbortSignal=K,a.default=M,Object.defineProperty(a,"__esModule",{value:!0}),"undefined"==typeof module&&"undefined"==typeof define){var O=Function("return this")();"undefined"==typeof O.AbortController&&(O.AbortController=M,O.AbortSignal=K)}}); +//# sourceMappingURL=abort-controller.umd.js.map diff --git a/node_modules/abort-controller/dist/abort-controller.umd.js.map b/node_modules/abort-controller/dist/abort-controller.umd.js.map new file mode 100644 index 0000000..875ab02 --- /dev/null +++ b/node_modules/abort-controller/dist/abort-controller.umd.js.map @@ -0,0 +1 @@ +{"version":3,"file":"abort-controller.umd.js","sources":["../node_modules/event-target-shim/dist/event-target-shim.mjs","../src/abort-signal.ts","../src/abort-controller.ts"],"sourcesContent":["/**\n * @author Toru Nagashima <https://github.com/mysticatea>\n * @copyright 2015 Toru Nagashima. All rights reserved.\n * See LICENSE file in root directory for full license.\n */\n/**\n * @typedef {object} PrivateData\n * @property {EventTarget} eventTarget The event target.\n * @property {{type:string}} event The original event object.\n * @property {number} eventPhase The current event phase.\n * @property {EventTarget|null} currentTarget The current event target.\n * @property {boolean} canceled The flag to prevent default.\n * @property {boolean} stopped The flag to stop propagation.\n * @property {boolean} immediateStopped The flag to stop propagation immediately.\n * @property {Function|null} passiveListener The listener if the current listener is passive. Otherwise this is null.\n * @property {number} timeStamp The unix time.\n * @private\n */\n\n/**\n * Private data for event wrappers.\n * @type {WeakMap<Event, PrivateData>}\n * @private\n */\nconst privateData = new WeakMap();\n\n/**\n * Cache for wrapper classes.\n * @type {WeakMap<Object, Function>}\n * @private\n */\nconst wrappers = new WeakMap();\n\n/**\n * Get private data.\n * @param {Event} event The event object to get private data.\n * @returns {PrivateData} The private data of the event.\n * @private\n */\nfunction pd(event) {\n const retv = privateData.get(event);\n console.assert(\n retv != null,\n \"'this' is expected an Event object, but got\",\n event\n );\n return retv\n}\n\n/**\n * https://dom.spec.whatwg.org/#set-the-canceled-flag\n * @param data {PrivateData} private data.\n */\nfunction setCancelFlag(data) {\n if (data.passiveListener != null) {\n if (\n typeof console !== \"undefined\" &&\n typeof console.error === \"function\"\n ) {\n console.error(\n \"Unable to preventDefault inside passive event listener invocation.\",\n data.passiveListener\n );\n }\n return\n }\n if (!data.event.cancelable) {\n return\n }\n\n data.canceled = true;\n if (typeof data.event.preventDefault === \"function\") {\n data.event.preventDefault();\n }\n}\n\n/**\n * @see https://dom.spec.whatwg.org/#interface-event\n * @private\n */\n/**\n * The event wrapper.\n * @constructor\n * @param {EventTarget} eventTarget The event target of this dispatching.\n * @param {Event|{type:string}} event The original event to wrap.\n */\nfunction Event(eventTarget, event) {\n privateData.set(this, {\n eventTarget,\n event,\n eventPhase: 2,\n currentTarget: eventTarget,\n canceled: false,\n stopped: false,\n immediateStopped: false,\n passiveListener: null,\n timeStamp: event.timeStamp || Date.now(),\n });\n\n // https://heycam.github.io/webidl/#Unforgeable\n Object.defineProperty(this, \"isTrusted\", { value: false, enumerable: true });\n\n // Define accessors\n const keys = Object.keys(event);\n for (let i = 0; i < keys.length; ++i) {\n const key = keys[i];\n if (!(key in this)) {\n Object.defineProperty(this, key, defineRedirectDescriptor(key));\n }\n }\n}\n\n// Should be enumerable, but class methods are not enumerable.\nEvent.prototype = {\n /**\n * The type of this event.\n * @type {string}\n */\n get type() {\n return pd(this).event.type\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n */\n get target() {\n return pd(this).eventTarget\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n */\n get currentTarget() {\n return pd(this).currentTarget\n },\n\n /**\n * @returns {EventTarget[]} The composed path of this event.\n */\n composedPath() {\n const currentTarget = pd(this).currentTarget;\n if (currentTarget == null) {\n return []\n }\n return [currentTarget]\n },\n\n /**\n * Constant of NONE.\n * @type {number}\n */\n get NONE() {\n return 0\n },\n\n /**\n * Constant of CAPTURING_PHASE.\n * @type {number}\n */\n get CAPTURING_PHASE() {\n return 1\n },\n\n /**\n * Constant of AT_TARGET.\n * @type {number}\n */\n get AT_TARGET() {\n return 2\n },\n\n /**\n * Constant of BUBBLING_PHASE.\n * @type {number}\n */\n get BUBBLING_PHASE() {\n return 3\n },\n\n /**\n * The target of this event.\n * @type {number}\n */\n get eventPhase() {\n return pd(this).eventPhase\n },\n\n /**\n * Stop event bubbling.\n * @returns {void}\n */\n stopPropagation() {\n const data = pd(this);\n\n data.stopped = true;\n if (typeof data.event.stopPropagation === \"function\") {\n data.event.stopPropagation();\n }\n },\n\n /**\n * Stop event bubbling.\n * @returns {void}\n */\n stopImmediatePropagation() {\n const data = pd(this);\n\n data.stopped = true;\n data.immediateStopped = true;\n if (typeof data.event.stopImmediatePropagation === \"function\") {\n data.event.stopImmediatePropagation();\n }\n },\n\n /**\n * The flag to be bubbling.\n * @type {boolean}\n */\n get bubbles() {\n return Boolean(pd(this).event.bubbles)\n },\n\n /**\n * The flag to be cancelable.\n * @type {boolean}\n */\n get cancelable() {\n return Boolean(pd(this).event.cancelable)\n },\n\n /**\n * Cancel this event.\n * @returns {void}\n */\n preventDefault() {\n setCancelFlag(pd(this));\n },\n\n /**\n * The flag to indicate cancellation state.\n * @type {boolean}\n */\n get defaultPrevented() {\n return pd(this).canceled\n },\n\n /**\n * The flag to be composed.\n * @type {boolean}\n */\n get composed() {\n return Boolean(pd(this).event.composed)\n },\n\n /**\n * The unix time of this event.\n * @type {number}\n */\n get timeStamp() {\n return pd(this).timeStamp\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n * @deprecated\n */\n get srcElement() {\n return pd(this).eventTarget\n },\n\n /**\n * The flag to stop event bubbling.\n * @type {boolean}\n * @deprecated\n */\n get cancelBubble() {\n return pd(this).stopped\n },\n set cancelBubble(value) {\n if (!value) {\n return\n }\n const data = pd(this);\n\n data.stopped = true;\n if (typeof data.event.cancelBubble === \"boolean\") {\n data.event.cancelBubble = true;\n }\n },\n\n /**\n * The flag to indicate cancellation state.\n * @type {boolean}\n * @deprecated\n */\n get returnValue() {\n return !pd(this).canceled\n },\n set returnValue(value) {\n if (!value) {\n setCancelFlag(pd(this));\n }\n },\n\n /**\n * Initialize this event object. But do nothing under event dispatching.\n * @param {string} type The event type.\n * @param {boolean} [bubbles=false] The flag to be possible to bubble up.\n * @param {boolean} [cancelable=false] The flag to be possible to cancel.\n * @deprecated\n */\n initEvent() {\n // Do nothing.\n },\n};\n\n// `constructor` is not enumerable.\nObject.defineProperty(Event.prototype, \"constructor\", {\n value: Event,\n configurable: true,\n writable: true,\n});\n\n// Ensure `event instanceof window.Event` is `true`.\nif (typeof window !== \"undefined\" && typeof window.Event !== \"undefined\") {\n Object.setPrototypeOf(Event.prototype, window.Event.prototype);\n\n // Make association for wrappers.\n wrappers.set(window.Event.prototype, Event);\n}\n\n/**\n * Get the property descriptor to redirect a given property.\n * @param {string} key Property name to define property descriptor.\n * @returns {PropertyDescriptor} The property descriptor to redirect the property.\n * @private\n */\nfunction defineRedirectDescriptor(key) {\n return {\n get() {\n return pd(this).event[key]\n },\n set(value) {\n pd(this).event[key] = value;\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Get the property descriptor to call a given method property.\n * @param {string} key Property name to define property descriptor.\n * @returns {PropertyDescriptor} The property descriptor to call the method property.\n * @private\n */\nfunction defineCallDescriptor(key) {\n return {\n value() {\n const event = pd(this).event;\n return event[key].apply(event, arguments)\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Define new wrapper class.\n * @param {Function} BaseEvent The base wrapper class.\n * @param {Object} proto The prototype of the original event.\n * @returns {Function} The defined wrapper class.\n * @private\n */\nfunction defineWrapper(BaseEvent, proto) {\n const keys = Object.keys(proto);\n if (keys.length === 0) {\n return BaseEvent\n }\n\n /** CustomEvent */\n function CustomEvent(eventTarget, event) {\n BaseEvent.call(this, eventTarget, event);\n }\n\n CustomEvent.prototype = Object.create(BaseEvent.prototype, {\n constructor: { value: CustomEvent, configurable: true, writable: true },\n });\n\n // Define accessors.\n for (let i = 0; i < keys.length; ++i) {\n const key = keys[i];\n if (!(key in BaseEvent.prototype)) {\n const descriptor = Object.getOwnPropertyDescriptor(proto, key);\n const isFunc = typeof descriptor.value === \"function\";\n Object.defineProperty(\n CustomEvent.prototype,\n key,\n isFunc\n ? defineCallDescriptor(key)\n : defineRedirectDescriptor(key)\n );\n }\n }\n\n return CustomEvent\n}\n\n/**\n * Get the wrapper class of a given prototype.\n * @param {Object} proto The prototype of the original event to get its wrapper.\n * @returns {Function} The wrapper class.\n * @private\n */\nfunction getWrapper(proto) {\n if (proto == null || proto === Object.prototype) {\n return Event\n }\n\n let wrapper = wrappers.get(proto);\n if (wrapper == null) {\n wrapper = defineWrapper(getWrapper(Object.getPrototypeOf(proto)), proto);\n wrappers.set(proto, wrapper);\n }\n return wrapper\n}\n\n/**\n * Wrap a given event to management a dispatching.\n * @param {EventTarget} eventTarget The event target of this dispatching.\n * @param {Object} event The event to wrap.\n * @returns {Event} The wrapper instance.\n * @private\n */\nfunction wrapEvent(eventTarget, event) {\n const Wrapper = getWrapper(Object.getPrototypeOf(event));\n return new Wrapper(eventTarget, event)\n}\n\n/**\n * Get the immediateStopped flag of a given event.\n * @param {Event} event The event to get.\n * @returns {boolean} The flag to stop propagation immediately.\n * @private\n */\nfunction isStopped(event) {\n return pd(event).immediateStopped\n}\n\n/**\n * Set the current event phase of a given event.\n * @param {Event} event The event to set current target.\n * @param {number} eventPhase New event phase.\n * @returns {void}\n * @private\n */\nfunction setEventPhase(event, eventPhase) {\n pd(event).eventPhase = eventPhase;\n}\n\n/**\n * Set the current target of a given event.\n * @param {Event} event The event to set current target.\n * @param {EventTarget|null} currentTarget New current target.\n * @returns {void}\n * @private\n */\nfunction setCurrentTarget(event, currentTarget) {\n pd(event).currentTarget = currentTarget;\n}\n\n/**\n * Set a passive listener of a given event.\n * @param {Event} event The event to set current target.\n * @param {Function|null} passiveListener New passive listener.\n * @returns {void}\n * @private\n */\nfunction setPassiveListener(event, passiveListener) {\n pd(event).passiveListener = passiveListener;\n}\n\n/**\n * @typedef {object} ListenerNode\n * @property {Function} listener\n * @property {1|2|3} listenerType\n * @property {boolean} passive\n * @property {boolean} once\n * @property {ListenerNode|null} next\n * @private\n */\n\n/**\n * @type {WeakMap<object, Map<string, ListenerNode>>}\n * @private\n */\nconst listenersMap = new WeakMap();\n\n// Listener types\nconst CAPTURE = 1;\nconst BUBBLE = 2;\nconst ATTRIBUTE = 3;\n\n/**\n * Check whether a given value is an object or not.\n * @param {any} x The value to check.\n * @returns {boolean} `true` if the value is an object.\n */\nfunction isObject(x) {\n return x !== null && typeof x === \"object\" //eslint-disable-line no-restricted-syntax\n}\n\n/**\n * Get listeners.\n * @param {EventTarget} eventTarget The event target to get.\n * @returns {Map<string, ListenerNode>} The listeners.\n * @private\n */\nfunction getListeners(eventTarget) {\n const listeners = listenersMap.get(eventTarget);\n if (listeners == null) {\n throw new TypeError(\n \"'this' is expected an EventTarget object, but got another value.\"\n )\n }\n return listeners\n}\n\n/**\n * Get the property descriptor for the event attribute of a given event.\n * @param {string} eventName The event name to get property descriptor.\n * @returns {PropertyDescriptor} The property descriptor.\n * @private\n */\nfunction defineEventAttributeDescriptor(eventName) {\n return {\n get() {\n const listeners = getListeners(this);\n let node = listeners.get(eventName);\n while (node != null) {\n if (node.listenerType === ATTRIBUTE) {\n return node.listener\n }\n node = node.next;\n }\n return null\n },\n\n set(listener) {\n if (typeof listener !== \"function\" && !isObject(listener)) {\n listener = null; // eslint-disable-line no-param-reassign\n }\n const listeners = getListeners(this);\n\n // Traverse to the tail while removing old value.\n let prev = null;\n let node = listeners.get(eventName);\n while (node != null) {\n if (node.listenerType === ATTRIBUTE) {\n // Remove old value.\n if (prev !== null) {\n prev.next = node.next;\n } else if (node.next !== null) {\n listeners.set(eventName, node.next);\n } else {\n listeners.delete(eventName);\n }\n } else {\n prev = node;\n }\n\n node = node.next;\n }\n\n // Add new value.\n if (listener !== null) {\n const newNode = {\n listener,\n listenerType: ATTRIBUTE,\n passive: false,\n once: false,\n next: null,\n };\n if (prev === null) {\n listeners.set(eventName, newNode);\n } else {\n prev.next = newNode;\n }\n }\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Define an event attribute (e.g. `eventTarget.onclick`).\n * @param {Object} eventTargetPrototype The event target prototype to define an event attrbite.\n * @param {string} eventName The event name to define.\n * @returns {void}\n */\nfunction defineEventAttribute(eventTargetPrototype, eventName) {\n Object.defineProperty(\n eventTargetPrototype,\n `on${eventName}`,\n defineEventAttributeDescriptor(eventName)\n );\n}\n\n/**\n * Define a custom EventTarget with event attributes.\n * @param {string[]} eventNames Event names for event attributes.\n * @returns {EventTarget} The custom EventTarget.\n * @private\n */\nfunction defineCustomEventTarget(eventNames) {\n /** CustomEventTarget */\n function CustomEventTarget() {\n EventTarget.call(this);\n }\n\n CustomEventTarget.prototype = Object.create(EventTarget.prototype, {\n constructor: {\n value: CustomEventTarget,\n configurable: true,\n writable: true,\n },\n });\n\n for (let i = 0; i < eventNames.length; ++i) {\n defineEventAttribute(CustomEventTarget.prototype, eventNames[i]);\n }\n\n return CustomEventTarget\n}\n\n/**\n * EventTarget.\n *\n * - This is constructor if no arguments.\n * - This is a function which returns a CustomEventTarget constructor if there are arguments.\n *\n * For example:\n *\n * class A extends EventTarget {}\n * class B extends EventTarget(\"message\") {}\n * class C extends EventTarget(\"message\", \"error\") {}\n * class D extends EventTarget([\"message\", \"error\"]) {}\n */\nfunction EventTarget() {\n /*eslint-disable consistent-return */\n if (this instanceof EventTarget) {\n listenersMap.set(this, new Map());\n return\n }\n if (arguments.length === 1 && Array.isArray(arguments[0])) {\n return defineCustomEventTarget(arguments[0])\n }\n if (arguments.length > 0) {\n const types = new Array(arguments.length);\n for (let i = 0; i < arguments.length; ++i) {\n types[i] = arguments[i];\n }\n return defineCustomEventTarget(types)\n }\n throw new TypeError(\"Cannot call a class as a function\")\n /*eslint-enable consistent-return */\n}\n\n// Should be enumerable, but class methods are not enumerable.\nEventTarget.prototype = {\n /**\n * Add a given listener to this event target.\n * @param {string} eventName The event name to add.\n * @param {Function} listener The listener to add.\n * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener.\n * @returns {void}\n */\n addEventListener(eventName, listener, options) {\n if (listener == null) {\n return\n }\n if (typeof listener !== \"function\" && !isObject(listener)) {\n throw new TypeError(\"'listener' should be a function or an object.\")\n }\n\n const listeners = getListeners(this);\n const optionsIsObj = isObject(options);\n const capture = optionsIsObj\n ? Boolean(options.capture)\n : Boolean(options);\n const listenerType = capture ? CAPTURE : BUBBLE;\n const newNode = {\n listener,\n listenerType,\n passive: optionsIsObj && Boolean(options.passive),\n once: optionsIsObj && Boolean(options.once),\n next: null,\n };\n\n // Set it as the first node if the first node is null.\n let node = listeners.get(eventName);\n if (node === undefined) {\n listeners.set(eventName, newNode);\n return\n }\n\n // Traverse to the tail while checking duplication..\n let prev = null;\n while (node != null) {\n if (\n node.listener === listener &&\n node.listenerType === listenerType\n ) {\n // Should ignore duplication.\n return\n }\n prev = node;\n node = node.next;\n }\n\n // Add it.\n prev.next = newNode;\n },\n\n /**\n * Remove a given listener from this event target.\n * @param {string} eventName The event name to remove.\n * @param {Function} listener The listener to remove.\n * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener.\n * @returns {void}\n */\n removeEventListener(eventName, listener, options) {\n if (listener == null) {\n return\n }\n\n const listeners = getListeners(this);\n const capture = isObject(options)\n ? Boolean(options.capture)\n : Boolean(options);\n const listenerType = capture ? CAPTURE : BUBBLE;\n\n let prev = null;\n let node = listeners.get(eventName);\n while (node != null) {\n if (\n node.listener === listener &&\n node.listenerType === listenerType\n ) {\n if (prev !== null) {\n prev.next = node.next;\n } else if (node.next !== null) {\n listeners.set(eventName, node.next);\n } else {\n listeners.delete(eventName);\n }\n return\n }\n\n prev = node;\n node = node.next;\n }\n },\n\n /**\n * Dispatch a given event.\n * @param {Event|{type:string}} event The event to dispatch.\n * @returns {boolean} `false` if canceled.\n */\n dispatchEvent(event) {\n if (event == null || typeof event.type !== \"string\") {\n throw new TypeError('\"event.type\" should be a string.')\n }\n\n // If listeners aren't registered, terminate.\n const listeners = getListeners(this);\n const eventName = event.type;\n let node = listeners.get(eventName);\n if (node == null) {\n return true\n }\n\n // Since we cannot rewrite several properties, so wrap object.\n const wrappedEvent = wrapEvent(this, event);\n\n // This doesn't process capturing phase and bubbling phase.\n // This isn't participating in a tree.\n let prev = null;\n while (node != null) {\n // Remove this listener if it's once\n if (node.once) {\n if (prev !== null) {\n prev.next = node.next;\n } else if (node.next !== null) {\n listeners.set(eventName, node.next);\n } else {\n listeners.delete(eventName);\n }\n } else {\n prev = node;\n }\n\n // Call this listener\n setPassiveListener(\n wrappedEvent,\n node.passive ? node.listener : null\n );\n if (typeof node.listener === \"function\") {\n try {\n node.listener.call(this, wrappedEvent);\n } catch (err) {\n if (\n typeof console !== \"undefined\" &&\n typeof console.error === \"function\"\n ) {\n console.error(err);\n }\n }\n } else if (\n node.listenerType !== ATTRIBUTE &&\n typeof node.listener.handleEvent === \"function\"\n ) {\n node.listener.handleEvent(wrappedEvent);\n }\n\n // Break if `event.stopImmediatePropagation` was called.\n if (isStopped(wrappedEvent)) {\n break\n }\n\n node = node.next;\n }\n setPassiveListener(wrappedEvent, null);\n setEventPhase(wrappedEvent, 0);\n setCurrentTarget(wrappedEvent, null);\n\n return !wrappedEvent.defaultPrevented\n },\n};\n\n// `constructor` is not enumerable.\nObject.defineProperty(EventTarget.prototype, \"constructor\", {\n value: EventTarget,\n configurable: true,\n writable: true,\n});\n\n// Ensure `eventTarget instanceof window.EventTarget` is `true`.\nif (\n typeof window !== \"undefined\" &&\n typeof window.EventTarget !== \"undefined\"\n) {\n Object.setPrototypeOf(EventTarget.prototype, window.EventTarget.prototype);\n}\n\nexport default EventTarget;\nexport { defineEventAttribute, EventTarget };\n//# sourceMappingURL=event-target-shim.mjs.map\n","import {\n // Event,\n EventTarget,\n // Type,\n defineEventAttribute,\n} from \"event-target-shim\"\n\n// Known Limitation\n// Use `any` because the type of `AbortSignal` in `lib.dom.d.ts` is wrong and\n// to make assignable our `AbortSignal` into that.\n// https://github.com/Microsoft/TSJS-lib-generator/pull/623\ntype Events = {\n abort: any // Event & Type<\"abort\">\n}\ntype EventAttributes = {\n onabort: any // Event & Type<\"abort\">\n}\n\n/**\n * The signal class.\n * @see https://dom.spec.whatwg.org/#abortsignal\n */\nexport default class AbortSignal extends EventTarget<Events, EventAttributes> {\n /**\n * AbortSignal cannot be constructed directly.\n */\n public constructor() {\n super()\n throw new TypeError(\"AbortSignal cannot be constructed directly\")\n }\n\n /**\n * Returns `true` if this `AbortSignal`'s `AbortController` has signaled to abort, and `false` otherwise.\n */\n public get aborted(): boolean {\n const aborted = abortedFlags.get(this)\n if (typeof aborted !== \"boolean\") {\n throw new TypeError(\n `Expected 'this' to be an 'AbortSignal' object, but got ${\n this === null ? \"null\" : typeof this\n }`,\n )\n }\n return aborted\n }\n}\ndefineEventAttribute(AbortSignal.prototype, \"abort\")\n\n/**\n * Create an AbortSignal object.\n */\nexport function createAbortSignal(): AbortSignal {\n const signal = Object.create(AbortSignal.prototype)\n EventTarget.call(signal)\n abortedFlags.set(signal, false)\n return signal\n}\n\n/**\n * Abort a given signal.\n */\nexport function abortSignal(signal: AbortSignal): void {\n if (abortedFlags.get(signal) !== false) {\n return\n }\n\n abortedFlags.set(signal, true)\n signal.dispatchEvent<\"abort\">({ type: \"abort\" })\n}\n\n/**\n * Aborted flag for each instances.\n */\nconst abortedFlags = new WeakMap<AbortSignal, boolean>()\n\n// Properties should be enumerable.\nObject.defineProperties(AbortSignal.prototype, {\n aborted: { enumerable: true },\n})\n\n// `toString()` should return `\"[object AbortSignal]\"`\nif (typeof Symbol === \"function\" && typeof Symbol.toStringTag === \"symbol\") {\n Object.defineProperty(AbortSignal.prototype, Symbol.toStringTag, {\n configurable: true,\n value: \"AbortSignal\",\n })\n}\n","import AbortSignal, { abortSignal, createAbortSignal } from \"./abort-signal\"\n\n/**\n * The AbortController.\n * @see https://dom.spec.whatwg.org/#abortcontroller\n */\nexport default class AbortController {\n /**\n * Initialize this controller.\n */\n public constructor() {\n signals.set(this, createAbortSignal())\n }\n\n /**\n * Returns the `AbortSignal` object associated with this object.\n */\n public get signal(): AbortSignal {\n return getSignal(this)\n }\n\n /**\n * Abort and signal to any observers that the associated activity is to be aborted.\n */\n public abort(): void {\n abortSignal(getSignal(this))\n }\n}\n\n/**\n * Associated signals.\n */\nconst signals = new WeakMap<AbortController, AbortSignal>()\n\n/**\n * Get the associated signal of a given controller.\n */\nfunction getSignal(controller: AbortController): AbortSignal {\n const signal = signals.get(controller)\n if (signal == null) {\n throw new TypeError(\n `Expected 'this' to be an 'AbortController' object, but got ${\n controller === null ? \"null\" : typeof controller\n }`,\n )\n }\n return signal\n}\n\n// Properties should be enumerable.\nObject.defineProperties(AbortController.prototype, {\n signal: { enumerable: true },\n abort: { enumerable: true },\n})\n\nif (typeof Symbol === \"function\" && typeof Symbol.toStringTag === \"symbol\") {\n Object.defineProperty(AbortController.prototype, Symbol.toStringTag, {\n configurable: true,\n value: \"AbortController\",\n })\n}\n\nexport { AbortController, AbortSignal }\n"],"names":["pd","event","retv","privateData","get","console","assert","setCancelFlag","data","passiveListener","cancelable","canceled","preventDefault","error","Event","eventTarget","set","eventPhase","currentTarget","stopped","immediateStopped","timeStamp","Date","now","Object","defineProperty","value","enumerable","key","keys","i","length","defineRedirectDescriptor","configurable","defineCallDescriptor","apply","arguments","defineWrapper","BaseEvent","proto","CustomEvent","call","prototype","create","constructor","writable","descriptor","getOwnPropertyDescriptor","isFunc","getWrapper","wrapper","wrappers","getPrototypeOf","wrapEvent","Wrapper","isStopped","setEventPhase","setCurrentTarget","setPassiveListener","createAbortSignal","signal","AbortSignal","EventTarget","abortedFlags","abortSignal","dispatchEvent","type","getSignal","controller","signals","TypeError","WeakMap","target","composedPath","NONE","CAPTURING_PHASE","AT_TARGET","BUBBLING_PHASE","stopPropagation","stopImmediatePropagation","bubbles","defaultPrevented","composed","srcElement","cancelBubble","returnValue","initEvent","window","setPrototypeOf","aborted","defineEventAttribute","defineProperties","Symbol","_typeof","toStringTag","AbortController","abort"],"mappings":";;;+3CAkCA,QAASA,CAAAA,CAAT,CAAYC,CAAZ,CAAmB,IACTC,CAAAA,CAAI,CAAGC,CAAW,CAACC,GAAZ,CAAgBH,CAAhB,QACbI,CAAAA,OAAO,CAACC,MAAR,CACY,IAAR,EAAAJ,CADJ,CAEI,6CAFJ,CAGID,CAHJ,EAKOC,EAOX,QAASK,CAAAA,CAAT,CAAuBC,CAAvB,CAA6B,OACG,KAAxB,EAAAA,CAAI,CAACC,eADgB,MAarB,CAACD,CAAI,CAACP,KAAL,CAAWS,UAbS,GAiBzBF,CAAI,CAACG,QAAL,GAjByB,CAkBgB,UAArC,QAAOH,CAAAA,CAAI,CAACP,KAAL,CAAWW,cAlBG,EAmBrBJ,CAAI,CAACP,KAAL,CAAWW,cAAX,EAnBqB,QAGE,WAAnB,QAAOP,CAAAA,OAAP,EACyB,UAAzB,QAAOA,CAAAA,OAAO,CAACQ,KAJE,EAMjBR,OAAO,CAACQ,KAAR,CACI,oEADJ,CAEIL,CAAI,CAACC,eAFT,CANiB,EAiC7B,QAASK,CAAAA,CAAT,CAAeC,CAAf,CAA4Bd,CAA5B,CAAmC,CAC/BE,CAAW,CAACa,GAAZ,CAAgB,IAAhB,CAAsB,CAClBD,WAAW,CAAXA,CADkB,CAElBd,KAAK,CAALA,CAFkB,CAGlBgB,UAAU,CAAE,CAHM,CAIlBC,aAAa,CAAEH,CAJG,CAKlBJ,QAAQ,GALU,CAMlBQ,OAAO,GANW,CAOlBC,gBAAgB,GAPE,CAQlBX,eAAe,CAAE,IARC,CASlBY,SAAS,CAAEpB,CAAK,CAACoB,SAAN,EAAmBC,IAAI,CAACC,GAAL,EATZ,CAAtB,CAD+B,CAc/BC,MAAM,CAACC,cAAP,CAAsB,IAAtB,CAA4B,WAA5B,CAAyC,CAAEC,KAAK,GAAP,CAAgBC,UAAU,GAA1B,CAAzC,CAd+B,QAmBrBC,CAAAA,EAFJC,CAAI,CAAGL,MAAM,CAACK,IAAP,CAAY5B,CAAZ,EACJ6B,CAAC,CAAG,EAAGA,CAAC,CAAGD,CAAI,CAACE,OAAQ,EAAED,EACzBF,EAAMC,CAAI,CAACC,CAAD,EACVF,CAAG,GAAI,OACTJ,MAAM,CAACC,cAAP,CAAsB,IAAtB,CAA4BG,CAA5B,CAAiCI,CAAwB,CAACJ,CAAD,CAAzD,EAyOZ,QAASI,CAAAA,CAAT,CAAkCJ,CAAlC,CAAuC,OAC5B,CACHxB,GADG,WACG,OACKJ,CAAAA,CAAE,CAAC,IAAD,CAAF,CAASC,KAAT,CAAe2B,CAAf,CAFR,CAAA,CAIHZ,GAJG,UAICU,EAAO,CACP1B,CAAE,CAAC,IAAD,CAAF,CAASC,KAAT,CAAe2B,CAAf,EAAsBF,CALvB,CAAA,CAOHO,YAAY,GAPT,CAQHN,UAAU,GARP,EAkBX,QAASO,CAAAA,CAAT,CAA8BN,CAA9B,CAAmC,OACxB,CACHF,KADG,WACK,IACEzB,CAAAA,CAAK,CAAGD,CAAE,CAAC,IAAD,CAAF,CAASC,YAChBA,CAAAA,CAAK,CAAC2B,CAAD,CAAL,CAAWO,KAAX,CAAiBlC,CAAjB,CAAwBmC,SAAxB,CAHR,CAAA,CAKHH,YAAY,GALT,CAMHN,UAAU,GANP,EAiBX,QAASU,CAAAA,CAAT,CAAuBC,CAAvB,CAAkCC,CAAlC,CAAyC,SAO5BC,CAAAA,EAAYzB,EAAad,EAAO,CACrCqC,CAAS,CAACG,IAAV,CAAe,IAAf,CAAqB1B,CAArB,CAAkCd,CAAlC,KAPE4B,CAAAA,CAAI,CAAGL,MAAM,CAACK,IAAP,CAAYU,CAAZ,KACO,CAAhB,GAAAV,CAAI,CAACE,aACEO,CAAAA,EAQXE,CAAW,CAACE,SAAZ,CAAwBlB,MAAM,CAACmB,MAAP,CAAcL,CAAS,CAACI,SAAxB,CAAmC,CACvDE,WAAW,CAAE,CAAElB,KAAK,CAAEc,CAAT,CAAsBP,YAAY,GAAlC,CAA0CY,QAAQ,GAAlD,CAD0C,CAAnC,CAXa,KAgBhC,GACKjB,CAAAA,CADL,CAAIE,CAAC,CAAG,EAAGA,CAAC,CAAGD,CAAI,CAACE,OAAQ,EAAED,KACzBF,EAAMC,CAAI,CAACC,CAAD,EACZ,EAAEF,CAAG,GAAIU,CAAAA,CAAS,CAACI,SAAnB,EAA+B,IACzBI,CAAAA,CAAU,CAAGtB,MAAM,CAACuB,wBAAP,CAAgCR,CAAhC,CAAuCX,CAAvC,CADY,CAEzBoB,CAAM,CAA+B,UAA5B,QAAOF,CAAAA,CAAU,CAACpB,KAFF,CAG/BF,MAAM,CAACC,cAAP,CACIe,CAAW,CAACE,SADhB,CAEId,CAFJ,CAGIoB,CAAM,CACAd,CAAoB,CAACN,CAAD,CADpB,CAEAI,CAAwB,CAACJ,CAAD,CALlC,QAUDY,CAAAA,EASX,QAASS,CAAAA,CAAT,CAAoBV,CAApB,CAA2B,IACV,IAAT,EAAAA,CAAK,EAAYA,CAAK,GAAKf,MAAM,CAACkB,gBAC3B5B,CAAAA,KAGPoC,CAAAA,CAAO,CAAGC,CAAQ,CAAC/C,GAAT,CAAamC,CAAb,QACC,KAAX,EAAAW,IACAA,CAAO,CAAGb,CAAa,CAACY,CAAU,CAACzB,MAAM,CAAC4B,cAAP,CAAsBb,CAAtB,CAAD,CAAX,CAA2CA,CAA3C,EACvBY,CAAQ,CAACnC,GAAT,CAAauB,CAAb,CAAoBW,CAApB,GAEGA,EAUJ,QAASG,CAAAA,CAAT,CAAmBtC,CAAnB,CAAgCd,CAAhC,CAAuC,IACpCqD,CAAAA,CAAO,CAAGL,CAAU,CAACzB,MAAM,CAAC4B,cAAP,CAAsBnD,CAAtB,CAAD,QACnB,IAAIqD,CAAAA,CAAJ,CAAYvC,CAAZ,CAAyBd,CAAzB,EASJ,QAASsD,CAAAA,CAAT,CAAmBtD,CAAnB,CAA0B,OACtBD,CAAAA,CAAE,CAACC,CAAD,CAAF,CAAUmB,iBAUd,QAASoC,CAAAA,CAAT,CAAuBvD,CAAvB,CAA8BgB,CAA9B,CAA0C,CAC7CjB,CAAE,CAACC,CAAD,CAAF,CAAUgB,UAAV,CAAuBA,EAUpB,QAASwC,CAAAA,CAAT,CAA0BxD,CAA1B,CAAiCiB,CAAjC,CAAgD,CACnDlB,CAAE,CAACC,CAAD,CAAF,CAAUiB,aAAV,CAA0BA,EAUvB,QAASwC,CAAAA,CAAT,CAA4BzD,CAA5B,CAAmCQ,CAAnC,CAAoD,CACvDT,CAAE,CAACC,CAAD,CAAF,CAAUQ,eAAV,CAA4BA,ysCC1ahBkD,CAAAA,OACNC,CAAAA,CAAM,CAAGpC,MAAM,CAACmB,MAAPnB,CAAcqC,CAAW,CAACnB,SAA1BlB,QACfsC,CAAAA,CAAW,CAACrB,IAAZqB,CAAiBF,CAAjBE,EACAC,CAAY,CAAC/C,GAAb+C,CAAiBH,CAAjBG,KACOH,UAMKI,CAAAA,EAAYJ,GACpBG,KAAAA,CAAY,CAAC3D,GAAb2D,CAAiBH,CAAjBG,IAIJA,CAAY,CAAC/C,GAAb+C,CAAiBH,CAAjBG,KACAH,CAAM,CAACK,aAAPL,CAA8B,CAAEM,IAAI,CAAE,OAAR,CAA9BN,GC9BJ,QAASO,CAAAA,CAAT,CAAmBC,CAAnB,KACUR,CAAAA,CAAM,CAAGS,CAAO,CAACjE,GAARiE,CAAYD,CAAZC,KACD,IAAVT,EAAAA,OACM,IAAIU,CAAAA,SAAJ,sEAEiB,IAAfF,GAAAA,CAAU,CAAY,MAAZ,GAA4BA,GAFxC,QAMHR,CAAAA,KF3BLzD,CAAAA,CAAW,CAAG,GAAIoE,CAAAA,QAOlBpB,CAAQ,CAAG,GAAIoB,CAAAA,QAkFrBzD,CAAK,CAAC4B,SAAN,CAAkB,IAKVwB,CAAAA,MAAO,OACAlE,CAAAA,CAAE,CAAC,IAAD,CAAF,CAASC,KAAT,CAAeiE,IANZ,CAAA,IAaVM,CAAAA,QAAS,OACFxE,CAAAA,CAAE,CAAC,IAAD,CAAF,CAASe,WAdN,CAAA,IAqBVG,CAAAA,eAAgB,OACTlB,CAAAA,CAAE,CAAC,IAAD,CAAF,CAASkB,aAtBN,CAAA,CA4BduD,YA5Bc,WA4BC,IACLvD,CAAAA,CAAa,CAAGlB,CAAE,CAAC,IAAD,CAAF,CAASkB,cADpB,MAEU,KAAjB,EAAAA,CAFO,CAGA,EAHA,CAKJ,CAACA,CAAD,CAjCG,CAAA,IAwCVwD,CAAAA,MAAO,OACA,EAzCG,CAAA,IAgDVC,CAAAA,iBAAkB,OACX,EAjDG,CAAA,IAwDVC,CAAAA,WAAY,OACL,EAzDG,CAAA,IAgEVC,CAAAA,gBAAiB,OACV,EAjEG,CAAA,IAwEV5D,CAAAA,YAAa,OACNjB,CAAAA,CAAE,CAAC,IAAD,CAAF,CAASiB,UAzEN,CAAA,CAgFd6D,eAhFc,WAgFI,IACRtE,CAAAA,CAAI,CAAGR,CAAE,CAAC,IAAD,EAEfQ,CAAI,CAACW,OAAL,GAHc,CAI4B,UAAtC,QAAOX,CAAAA,CAAI,CAACP,KAAL,CAAW6E,eAJR,EAKVtE,CAAI,CAACP,KAAL,CAAW6E,eAAX,EArFM,CAAA,CA6FdC,wBA7Fc,WA6Fa,IACjBvE,CAAAA,CAAI,CAAGR,CAAE,CAAC,IAAD,EAEfQ,CAAI,CAACW,OAAL,GAHuB,CAIvBX,CAAI,CAACY,gBAAL,GAJuB,CAK4B,UAA/C,QAAOZ,CAAAA,CAAI,CAACP,KAAL,CAAW8E,wBALC,EAMnBvE,CAAI,CAACP,KAAL,CAAW8E,wBAAX,EAnGM,CAAA,IA2GVC,CAAAA,SAAU,SACKhF,CAAE,CAAC,IAAD,CAAF,CAASC,KAAT,CAAe+E,OA5GpB,CAAA,IAmHVtE,CAAAA,YAAa,SACEV,CAAE,CAAC,IAAD,CAAF,CAASC,KAAT,CAAeS,UApHpB,CAAA,CA2HdE,cA3Hc,WA2HG,CACbL,CAAa,CAACP,CAAE,CAAC,IAAD,CAAH,CA5HH,CAAA,IAmIViF,CAAAA,kBAAmB,OACZjF,CAAAA,CAAE,CAAC,IAAD,CAAF,CAASW,QApIN,CAAA,IA2IVuE,CAAAA,UAAW,SACIlF,CAAE,CAAC,IAAD,CAAF,CAASC,KAAT,CAAeiF,QA5IpB,CAAA,IAmJV7D,CAAAA,WAAY,OACLrB,CAAAA,CAAE,CAAC,IAAD,CAAF,CAASqB,SApJN,CAAA,IA4JV8D,CAAAA,YAAa,OACNnF,CAAAA,CAAE,CAAC,IAAD,CAAF,CAASe,WA7JN,CAAA,IAqKVqE,CAAAA,cAAe,OACRpF,CAAAA,CAAE,CAAC,IAAD,CAAF,CAASmB,OAtKN,CAAA,IAwKViE,CAAAA,aAAa1D,EAAO,IACfA,MAGClB,CAAAA,CAAI,CAAGR,CAAE,CAAC,IAAD,EAEfQ,CAAI,CAACW,OAAL,IACuC,SAAnC,QAAOX,CAAAA,CAAI,CAACP,KAAL,CAAWmF,eAClB5E,CAAI,CAACP,KAAL,CAAWmF,YAAX,KAhLM,CAAA,IAyLVC,CAAAA,aAAc,OACP,CAACrF,CAAE,CAAC,IAAD,CAAF,CAASW,QA1LP,CAAA,IA4LV0E,CAAAA,YAAY3D,EAAO,CACdA,CADc,EAEfnB,CAAa,CAACP,CAAE,CAAC,IAAD,CAAH,CA9LP,CAAA,CAyMdsF,SAzMc,WAyMF,EAzME,EA+MlB9D,MAAM,CAACC,cAAP,CAAsBX,CAAK,CAAC4B,SAA5B,CAAuC,aAAvC,CAAsD,CAClDhB,KAAK,CAAEZ,CAD2C,CAElDmB,YAAY,GAFsC,CAGlDY,QAAQ,GAH0C,CAAtD,EAOsB,WAAlB,QAAO0C,CAAAA,MAAP,EAAyD,WAAxB,QAAOA,CAAAA,MAAM,CAACzE,QAC/CU,MAAM,CAACgE,cAAP,CAAsB1E,CAAK,CAAC4B,SAA5B,CAAuC6C,MAAM,CAACzE,KAAP,CAAa4B,SAApD,EAGAS,CAAQ,CAACnC,GAAT,CAAauE,MAAM,CAACzE,KAAP,CAAa4B,SAA1B,CAAqC5B,CAArC,wiDChTiB+C,CAAAA,2EAMP,GAAIS,CAAAA,SAAJ,CAAc,4CAAd,sDAOAmB,CAAAA,CAAO,CAAG1B,CAAY,CAAC3D,GAAb2D,CAAiB,IAAjBA,KACO,SAAnB,QAAO0B,CAAAA,OACD,IAAInB,CAAAA,SAAJ,kEAEW,IAAT,QAAgB,MAAhB,GAAgC,MAFlC,QAMHmB,CAAAA,SArB0B3B,GAwBzC4B,CAAoB,CAAC7B,CAAW,CAACnB,SAAb,CAAwB,OAAxB,EA2BpB,GAAMqB,CAAAA,CAAY,CAAG,GAAIQ,CAAAA,OAAzB,CAGA/C,MAAM,CAACmE,gBAAPnE,CAAwBqC,CAAW,CAACnB,SAApClB,CAA+C,CAC3CiE,OAAO,CAAE,CAAE9D,UAAU,GAAZ,CADkC,CAA/CH,EAKsB,UAAlB,QAAOoE,CAAAA,MAAP,EAA8D,QAA9B,GAAAC,EAAOD,MAAM,CAACE,cAC9CtE,MAAM,CAACC,cAAPD,CAAsBqC,CAAW,CAACnB,SAAlClB,CAA6CoE,MAAM,CAACE,WAApDtE,CAAiE,CAC7DS,YAAY,GADiD,CAE7DP,KAAK,CAAE,aAFsD,CAAjEF,KC5EiBuE,CAAAA,oCAKb1B,CAAO,CAACrD,GAARqD,CAAY,IAAZA,CAAkBV,CAAiB,EAAnCU,4CAcAL,CAAW,CAACG,CAAS,CAAC,IAAD,CAAV,uCAPJA,CAAAA,CAAS,CAAC,IAAD,WAclBE,CAAO,CAAG,GAAIE,CAAAA,WAkBpB/C,MAAM,CAACmE,gBAAPnE,CAAwBuE,CAAe,CAACrD,SAAxClB,CAAmD,CAC/CoC,MAAM,CAAE,CAAEjC,UAAU,GAAZ,CADuC,CAE/CqE,KAAK,CAAE,CAAErE,UAAU,GAAZ,CAFwC,CAAnDH,EAKsB,UAAlB,QAAOoE,CAAAA,MAAP,EAA8D,QAA9B,GAAAC,EAAOD,MAAM,CAACE,cAC9CtE,MAAM,CAACC,cAAPD,CAAsBuE,CAAe,CAACrD,SAAtClB,CAAiDoE,MAAM,CAACE,WAAxDtE,CAAqE,CACjES,YAAY,GADqD,CAEjEP,KAAK,CAAE,iBAF0D,CAArEF"} \ No newline at end of file diff --git a/node_modules/abort-controller/package.json b/node_modules/abort-controller/package.json new file mode 100644 index 0000000..fc705e0 --- /dev/null +++ b/node_modules/abort-controller/package.json @@ -0,0 +1,97 @@ +{ + "name": "abort-controller", + "version": "3.0.0", + "description": "An implementation of WHATWG AbortController interface.", + "main": "dist/abort-controller", + "files": [ + "dist", + "polyfill.*", + "browser.*" + ], + "engines": { + "node": ">=6.5" + }, + "dependencies": { + "event-target-shim": "^5.0.0" + }, + "browser": "./browser.js", + "devDependencies": { + "@babel/core": "^7.2.2", + "@babel/plugin-transform-modules-commonjs": "^7.2.0", + "@babel/preset-env": "^7.3.0", + "@babel/register": "^7.0.0", + "@mysticatea/eslint-plugin": "^8.0.1", + "@mysticatea/spy": "^0.1.2", + "@types/mocha": "^5.2.5", + "@types/node": "^10.12.18", + "assert": "^1.4.1", + "codecov": "^3.1.0", + "dts-bundle-generator": "^2.0.0", + "eslint": "^5.12.1", + "karma": "^3.1.4", + "karma-chrome-launcher": "^2.2.0", + "karma-coverage": "^1.1.2", + "karma-firefox-launcher": "^1.1.0", + "karma-growl-reporter": "^1.0.0", + "karma-ie-launcher": "^1.0.0", + "karma-mocha": "^1.3.0", + "karma-rollup-preprocessor": "^7.0.0-rc.2", + "mocha": "^5.2.0", + "npm-run-all": "^4.1.5", + "nyc": "^13.1.0", + "opener": "^1.5.1", + "rimraf": "^2.6.3", + "rollup": "^1.1.2", + "rollup-plugin-babel": "^4.3.2", + "rollup-plugin-babel-minify": "^7.0.0", + "rollup-plugin-commonjs": "^9.2.0", + "rollup-plugin-node-resolve": "^4.0.0", + "rollup-plugin-sourcemaps": "^0.4.2", + "rollup-plugin-typescript": "^1.0.0", + "rollup-watch": "^4.3.1", + "ts-node": "^8.0.1", + "type-tester": "^1.0.0", + "typescript": "^3.2.4" + }, + "scripts": { + "preversion": "npm test", + "version": "npm run -s build && git add dist/*", + "postversion": "git push && git push --tags", + "clean": "rimraf .nyc_output coverage", + "coverage": "opener coverage/lcov-report/index.html", + "lint": "eslint . --ext .ts", + "build": "run-s -s build:*", + "build:rollup": "rollup -c", + "build:dts": "dts-bundle-generator -o dist/abort-controller.d.ts src/abort-controller.ts && ts-node scripts/fix-dts", + "test": "run-s -s lint test:*", + "test:mocha": "nyc mocha test/*.ts", + "test:karma": "karma start --single-run", + "watch": "run-p -s watch:*", + "watch:mocha": "mocha test/*.ts --require ts-node/register --watch-extensions ts --watch --growl", + "watch:karma": "karma start --watch", + "codecov": "codecov" + }, + "repository": { + "type": "git", + "url": "git+https://github.com/mysticatea/abort-controller.git" + }, + "keywords": [ + "w3c", + "whatwg", + "event", + "events", + "abort", + "cancel", + "abortcontroller", + "abortsignal", + "controller", + "signal", + "shim" + ], + "author": "Toru Nagashima (https://github.com/mysticatea)", + "license": "MIT", + "bugs": { + "url": "https://github.com/mysticatea/abort-controller/issues" + }, + "homepage": "https://github.com/mysticatea/abort-controller#readme" +} diff --git a/node_modules/abort-controller/polyfill.js b/node_modules/abort-controller/polyfill.js new file mode 100644 index 0000000..3ca8923 --- /dev/null +++ b/node_modules/abort-controller/polyfill.js @@ -0,0 +1,21 @@ +/*globals require, self, window */ +"use strict" + +const ac = require("./dist/abort-controller") + +/*eslint-disable @mysticatea/prettier */ +const g = + typeof self !== "undefined" ? self : + typeof window !== "undefined" ? window : + typeof global !== "undefined" ? global : + /* otherwise */ undefined +/*eslint-enable @mysticatea/prettier */ + +if (g) { + if (typeof g.AbortController === "undefined") { + g.AbortController = ac.AbortController + } + if (typeof g.AbortSignal === "undefined") { + g.AbortSignal = ac.AbortSignal + } +} diff --git a/node_modules/abort-controller/polyfill.mjs b/node_modules/abort-controller/polyfill.mjs new file mode 100644 index 0000000..0602a64 --- /dev/null +++ b/node_modules/abort-controller/polyfill.mjs @@ -0,0 +1,19 @@ +/*globals self, window */ +import * as ac from "./dist/abort-controller" + +/*eslint-disable @mysticatea/prettier */ +const g = + typeof self !== "undefined" ? self : + typeof window !== "undefined" ? window : + typeof global !== "undefined" ? global : + /* otherwise */ undefined +/*eslint-enable @mysticatea/prettier */ + +if (g) { + if (typeof g.AbortController === "undefined") { + g.AbortController = ac.AbortController + } + if (typeof g.AbortSignal === "undefined") { + g.AbortSignal = ac.AbortSignal + } +} diff --git a/node_modules/agentkeepalive/History.md b/node_modules/agentkeepalive/History.md index 00cb65f..9db6e55 100644 --- a/node_modules/agentkeepalive/History.md +++ b/node_modules/agentkeepalive/History.md @@ -1,4 +1,10 @@ +4.2.1 / 2022-02-21 +================== + +**fixes** + * [[`8b13b5c`](http://github.com/node-modules/agentkeepalive/commit/8b13b5ca797f4779a0a8d393ad8ecb622cd27987)] - fix: explicitly set `| undefined` in type definitions (#99) (Benoit Lemoine <<lemoine.benoit@gmail.com>>) + 4.2.0 / 2021-12-31 ================== diff --git a/node_modules/agentkeepalive/index.d.ts b/node_modules/agentkeepalive/index.d.ts index 7840f9a..c2ce7d2 100644 --- a/node_modules/agentkeepalive/index.d.ts +++ b/node_modules/agentkeepalive/index.d.ts @@ -39,11 +39,11 @@ declare namespace AgentKeepAlive { } interface CommonHttpOption { - keepAlive?: boolean; - freeSocketTimeout?: number; - freeSocketKeepAliveTimeout?: number; - timeout?: number; - socketActiveTTL?: number; + keepAlive?: boolean | undefined; + freeSocketTimeout?: number | undefined; + freeSocketKeepAliveTimeout?: number | undefined; + timeout?: number | undefined; + socketActiveTTL?: number | undefined; } export interface HttpOptions extends http.AgentOptions, CommonHttpOption { } diff --git a/node_modules/agentkeepalive/package.json b/node_modules/agentkeepalive/package.json index aba00ea..efa561d 100644 --- a/node_modules/agentkeepalive/package.json +++ b/node_modules/agentkeepalive/package.json @@ -1,6 +1,6 @@ { "name": "agentkeepalive", - "version": "4.2.0", + "version": "4.2.1", "description": "Missing keepalive http.Agent", "main": "index.js", "browser": "browser.js", diff --git a/node_modules/ansicolors/LICENSE b/node_modules/ansicolors/LICENSE deleted file mode 100644 index 41702c5..0000000 --- a/node_modules/ansicolors/LICENSE +++ /dev/null @@ -1,23 +0,0 @@ -Copyright 2013 Thorsten Lorenz. -All rights reserved. - -Permission is hereby granted, free of charge, to any person -obtaining a copy of this software and associated documentation -files (the "Software"), to deal in the Software without -restriction, including without limitation the rights to use, -copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the -Software is furnished to do so, subject to the following -conditions: - -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES -OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT -HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, -WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR -OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/ansicolors/ansicolors.js b/node_modules/ansicolors/ansicolors.js deleted file mode 100644 index 16b2586..0000000 --- a/node_modules/ansicolors/ansicolors.js +++ /dev/null @@ -1,65 +0,0 @@ -// ColorCodes explained: http://www.termsys.demon.co.uk/vtansi.htm -'use strict'; - -var colorNums = { - white : 37 - , black : 30 - , blue : 34 - , cyan : 36 - , green : 32 - , magenta : 35 - , red : 31 - , yellow : 33 - , brightBlack : 90 - , brightRed : 91 - , brightGreen : 92 - , brightYellow : 93 - , brightBlue : 94 - , brightMagenta : 95 - , brightCyan : 96 - , brightWhite : 97 - } - , backgroundColorNums = { - bgBlack : 40 - , bgRed : 41 - , bgGreen : 42 - , bgYellow : 43 - , bgBlue : 44 - , bgMagenta : 45 - , bgCyan : 46 - , bgWhite : 47 - , bgBrightBlack : 100 - , bgBrightRed : 101 - , bgBrightGreen : 102 - , bgBrightYellow : 103 - , bgBrightBlue : 104 - , bgBrightMagenta : 105 - , bgBrightCyan : 106 - , bgBrightWhite : 107 - } - , open = {} - , close = {} - , colors = {} - ; - -Object.keys(colorNums).forEach(function (k) { - var o = open[k] = '\u001b[' + colorNums[k] + 'm'; - var c = close[k] = '\u001b[39m'; - - colors[k] = function (s) { - return o + s + c; - }; -}); - -Object.keys(backgroundColorNums).forEach(function (k) { - var o = open[k] = '\u001b[' + backgroundColorNums[k] + 'm'; - var c = close[k] = '\u001b[49m'; - - colors[k] = function (s) { - return o + s + c; - }; -}); - -module.exports = colors; -colors.open = open; -colors.close = close; diff --git a/node_modules/ansicolors/package.json b/node_modules/ansicolors/package.json deleted file mode 100644 index cda0c75..0000000 --- a/node_modules/ansicolors/package.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "name": "ansicolors", - "version": "0.3.2", - "description": "Functions that surround a string with ansicolor codes so it prints in color.", - "main": "ansicolors.js", - "scripts": { - "test": "node test/*.js" - }, - "repository": { - "type": "git", - "url": "git://github.com/thlorenz/ansicolors.git" - }, - "keywords": [ - "ansi", - "colors", - "highlight", - "string" - ], - "author": "Thorsten Lorenz <thlorenz@gmx.de> (thlorenz.com)", - "license": "MIT", - "readmeFilename": "README.md", - "gitHead": "858847ca28e8b360d9b70eee0592700fa2ab087d" -} diff --git a/node_modules/ansicolors/test/ansicolors.js b/node_modules/ansicolors/test/ansicolors.js deleted file mode 100644 index 4945393..0000000 --- a/node_modules/ansicolors/test/ansicolors.js +++ /dev/null @@ -1,71 +0,0 @@ -'use strict'; - -var assert = require('assert') - , colors = require('..') - , open = colors.open - , close = colors.close - -console.log('Foreground colors ..'); - -assert.equal(colors.white('printed in white'), '\u001b[37mprinted in white\u001b[39m'); - -assert.equal(colors.black('printed in black'), '\u001b[30mprinted in black\u001b[39m'); -assert.equal(colors.brightBlack('printed in bright black'), '\u001b[90mprinted in bright black\u001b[39m'); - -assert.equal(colors.green('printed in green'), '\u001b[32mprinted in green\u001b[39m'); -assert.equal(colors.brightGreen('printed in bright green'), '\u001b[92mprinted in bright green\u001b[39m'); - -assert.equal(colors.red('printed in red'), '\u001b[31mprinted in red\u001b[39m'); -assert.equal(colors.brightRed('printed in bright red'), '\u001b[91mprinted in bright red\u001b[39m'); - -console.log('OK'); - -console.log('Background colors ..'); - -assert.equal( - colors.bgBlack('printed with black background') - , '\u001b[40mprinted with black background\u001b[49m' -); - -assert.equal( - colors.bgYellow('printed with yellow background') - , '\u001b[43mprinted with yellow background\u001b[49m' -); -assert.equal( - colors.bgBrightYellow('printed with bright yellow background') - , '\u001b[103mprinted with bright yellow background\u001b[49m' -); - -assert.equal( - colors.bgWhite('printed with white background') - , '\u001b[47mprinted with white background\u001b[49m' -); - -console.log('OK'); - -console.log('Mixing background and foreground colors ..'); - -assert.equal( - colors.blue(colors.bgYellow('printed in blue with yellow background')) - , '\u001b[34m\u001b[43mprinted in blue with yellow background\u001b[49m\u001b[39m' -); -assert.equal( - colors.bgYellow(colors.blue('printed in blue with yellow background again')) - , '\u001b[43m\u001b[34mprinted in blue with yellow background again\u001b[39m\u001b[49m' -); - -console.log('OK'); - -console.log('Open ...'); - -assert.equal(open.black, '\u001b[30m'); -assert.equal(open.bgYellow, '\u001b[43m'); - -console.log('OK'); - -console.log('Close ...'); - -assert.equal(close.black, '\u001b[39m'); -assert.equal(close.bgYellow, '\u001b[49m'); - -console.log('OK'); diff --git a/node_modules/bin-links/lib/check-bin.js b/node_modules/bin-links/lib/check-bin.js index 8bbe451..c5b997b 100644 --- a/node_modules/bin-links/lib/check-bin.js +++ b/node_modules/bin-links/lib/check-bin.js @@ -4,9 +4,7 @@ const isWindows = require('./is-windows.js') const binTarget = require('./bin-target.js') const { resolve, dirname } = require('path') const readCmdShim = require('read-cmd-shim') -const fs = require('fs') -const { promisify } = require('util') -const readlink = promisify(fs.readlink) +const { readlink } = require('fs/promises') const checkBin = async ({ bin, path, top, global, force }) => { // always ok to clobber when forced @@ -57,18 +55,18 @@ const checkShim = async ({ target, path }) => { target + '.cmd', target + '.ps1', ] - await Promise.all(shims.map(async target => { - const current = await readCmdShim(target) - .catch(er => handleReadCmdShimError({ er, target })) + await Promise.all(shims.map(async shim => { + const current = await readCmdShim(shim) + .catch(er => handleReadCmdShimError({ er, target: shim })) if (!current) { return } - const resolved = resolve(dirname(target), current.replace(/\\/g, '/')) + const resolved = resolve(dirname(shim), current.replace(/\\/g, '/')) if (resolved.toLowerCase().indexOf(path.toLowerCase()) !== 0) { - return failEEXIST({ target }) + return failEEXIST({ target: shim }) } })) } diff --git a/node_modules/bin-links/lib/fix-bin.js b/node_modules/bin-links/lib/fix-bin.js index d1f513a..453bd4f 100644 --- a/node_modules/bin-links/lib/fix-bin.js +++ b/node_modules/bin-links/lib/fix-bin.js @@ -1,16 +1,14 @@ // make sure that bins are executable, and that they don't have // windows line-endings on the hashbang line. -const fs = require('fs') -const { promisify } = require('util') +const { + chmod, + open, + readFile, +} = require('fs/promises') const execMode = 0o777 & (~process.umask()) const writeFileAtomic = require('write-file-atomic') -const open = promisify(fs.open) -const close = promisify(fs.close) -const read = promisify(fs.read) -const chmod = promisify(fs.chmod) -const readFile = promisify(fs.readFile) const isWindowsHashBang = buf => buf[0] === '#'.charCodeAt(0) && @@ -19,16 +17,16 @@ const isWindowsHashBang = buf => const isWindowsHashbangFile = file => { const FALSE = () => false - return open(file, 'r').then(fd => { + return open(file, 'r').then(fh => { const buf = Buffer.alloc(2048) - return read(fd, buf, 0, 2048, 0) + return fh.read(buf, 0, 2048, 0) .then( () => { const isWHB = isWindowsHashBang(buf) - return close(fd).then(() => isWHB, () => isWHB) + return fh.close().then(() => isWHB, () => isWHB) }, // don't leak FD if read() fails - () => close(fd).then(FALSE, FALSE) + () => fh.close().then(FALSE, FALSE) ) }, FALSE) } diff --git a/node_modules/bin-links/lib/get-paths.js b/node_modules/bin-links/lib/get-paths.js index 631aef9..b93e698 100644 --- a/node_modules/bin-links/lib/get-paths.js +++ b/node_modules/bin-links/lib/get-paths.js @@ -3,7 +3,7 @@ // are present, then we can assume that they're associated. const binTarget = require('./bin-target.js') const manTarget = require('./man-target.js') -const { resolve, basename } = require('path') +const { resolve, basename, extname } = require('path') const isWindows = require('./is-windows.js') module.exports = ({ path, pkg, global, top }) => { if (top && !global) { @@ -27,23 +27,14 @@ module.exports = ({ path, pkg, global, top }) => { const manSet = [] if (manTarg && pkg.man && Array.isArray(pkg.man) && pkg.man.length) { for (const man of pkg.man) { - const parseMan = man.match(/(.*\.([0-9]+)(\.gz)?)$/) - // invalid entries invalidate the entire man set - if (!parseMan) { + if (!/.\.[0-9]+(\.gz)?$/.test(man)) { return binSet } - const stem = parseMan[1] - const sxn = parseMan[2] - const base = basename(stem) - const absFrom = resolve(path, man) + const section = extname(basename(man, '.gz')).slice(1) + const base = basename(man) - /* istanbul ignore if - should be impossible */ - if (absFrom.indexOf(path) !== 0) { - return binSet - } - - manSet.push(resolve(manTarg, 'man' + sxn, base)) + manSet.push(resolve(manTarg, 'man' + section, base)) } } diff --git a/node_modules/bin-links/lib/link-gently.js b/node_modules/bin-links/lib/link-gently.js index 671ce38..89ca0f6 100644 --- a/node_modules/bin-links/lib/link-gently.js +++ b/node_modules/bin-links/lib/link-gently.js @@ -4,29 +4,25 @@ // if there's a symlink already, pointing into our pkg, remove it first // then create the symlink -const { promisify } = require('util') const { resolve, dirname } = require('path') -const mkdirp = require('mkdirp-infer-owner') -const fs = require('fs') -const symlink = promisify(fs.symlink) -const readlink = promisify(fs.readlink) -const lstat = promisify(fs.lstat) +const { lstat, mkdir, readlink, rm, symlink } = require('fs/promises') const throwNonEnoent = er => { if (er.code !== 'ENOENT') { throw er } } +const rmOpts = { + recursive: true, + force: true, +} + // even in --force mode, we never create a link over a link we've // already created. you can have multiple packages in a tree trying // to contend for the same bin, or the same manpage listed multiple times, // which creates a race condition and nondeterminism. const seen = new Set() -// disable glob in our rimraf calls -const rimraf = promisify(require('rimraf')) -const rm = path => rimraf(path, { glob: false }) - const SKIP = Symbol('skip - missing or already installed') const CLOBBER = Symbol('clobber - ours or in forceful mode') @@ -52,7 +48,7 @@ const linkGently = async ({ path, to, from, absFrom, force }) => { // exists! maybe clobber if we can if (stTo) { if (!stTo.isSymbolicLink()) { - return force && rm(to).then(() => CLOBBER) + return force && rm(to, rmOpts).then(() => CLOBBER) } return readlink(to).then(target => { @@ -62,12 +58,14 @@ const linkGently = async ({ path, to, from, absFrom, force }) => { target = resolve(dirname(to), target) if (target.indexOf(path) === 0 || force) { - return rm(to).then(() => CLOBBER) + return rm(to, rmOpts).then(() => CLOBBER) } + // neither skip nor clobber + return false }) } else { // doesn't exist, dir might not either - return mkdirp(dirname(to)) + return mkdir(dirname(to), { recursive: true }) } }) .then(skipOrClobber => { @@ -76,7 +74,7 @@ const linkGently = async ({ path, to, from, absFrom, force }) => { } return symlink(from, to, 'file').catch(er => { if (skipOrClobber === CLOBBER || force) { - return rm(to).then(() => symlink(from, to, 'file')) + return rm(to, rmOpts).then(() => symlink(from, to, 'file')) } throw er }).then(() => true) diff --git a/node_modules/bin-links/lib/link-mans.js b/node_modules/bin-links/lib/link-mans.js index 54b17d1..656e179 100644 --- a/node_modules/bin-links/lib/link-mans.js +++ b/node_modules/bin-links/lib/link-mans.js @@ -11,7 +11,7 @@ const linkMans = ({ path, pkg, top, force }) => { // break any links to c:\\blah or /foo/blah or ../blah // and filter out duplicates const set = [...new Set(pkg.man.map(man => - man ? join('/', man).replace(/\\|:/g, '/').substr(1) : null) + man ? join('/', man).replace(/\\|:/g, '/').slice(1) : null) .filter(man => typeof man === 'string'))] return Promise.all(set.map(man => { diff --git a/node_modules/bin-links/lib/shim-bin.js b/node_modules/bin-links/lib/shim-bin.js index 70259a4..d5e19c0 100644 --- a/node_modules/bin-links/lib/shim-bin.js +++ b/node_modules/bin-links/lib/shim-bin.js @@ -1,7 +1,5 @@ -const { promisify } = require('util') const { resolve, dirname } = require('path') -const fs = require('fs') -const lstat = promisify(fs.lstat) +const { lstat } = require('fs/promises') const throwNonEnoent = er => { if (er.code !== 'ENOENT') { throw er @@ -56,12 +54,12 @@ const shimBin = ({ path, to, from, absFrom, force }) => { } if (force) { - return + return false } return Promise.all(shims.map((s, i) => [s, stats[i]]).map(([s, st]) => { if (!st) { - return + return false } return readCmdShim(s) .then(target => { @@ -69,6 +67,7 @@ const shimBin = ({ path, to, from, absFrom, force }) => { if (target.indexOf(resolve(path)) !== 0) { return failEEXIST({ from, to, path }) } + return false }, er => handleReadCmdShimError({ er, from, to })) })) }) diff --git a/node_modules/bin-links/package.json b/node_modules/bin-links/package.json index 0325ab4..589245a 100644 --- a/node_modules/bin-links/package.json +++ b/node_modules/bin-links/package.json @@ -1,22 +1,20 @@ { "name": "bin-links", - "version": "3.0.0", + "version": "4.0.1", "description": "JavaScript package binary linker", "main": "./lib/index.js", "scripts": { - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", "snap": "tap", "test": "tap", - "lint": "eslint '**/*.js'", - "postlint": "npm-template-check", + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", "lintfix": "npm run lint -- --fix", - "posttest": "npm run lint" + "posttest": "npm run lint", + "template-oss-apply": "template-oss-apply --force" }, "repository": { "type": "git", - "url": "git://github.com/npm/bin-links.git" + "url": "https://github.com/npm/bin-links.git" }, "keywords": [ "npm", @@ -25,33 +23,36 @@ ], "license": "ISC", "dependencies": { - "cmd-shim": "^4.0.1", - "mkdirp-infer-owner": "^2.0.0", - "npm-normalize-package-bin": "^1.0.0", - "read-cmd-shim": "^2.0.0", - "rimraf": "^3.0.0", - "write-file-atomic": "^4.0.0" + "cmd-shim": "^6.0.0", + "npm-normalize-package-bin": "^3.0.0", + "read-cmd-shim": "^4.0.0", + "write-file-atomic": "^5.0.0" }, "devDependencies": { - "@npmcli/template-oss": "^2.5.0", - "mkdirp": "^1.0.3", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.5.1", "require-inject": "^1.4.4", - "tap": "^15.0.10" + "tap": "^16.0.1" }, "tap": { "check-coverage": true, - "coverage-map": "map.js" + "coverage-map": "map.js", + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "author": "GitHub Inc.", "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", "windowsCI": false, - "version": "2.5.0" + "version": "4.5.1" } } diff --git a/node_modules/cli-columns/LICENSE b/node_modules/cli-columns/license similarity index 100% rename from node_modules/cli-columns/LICENSE rename to node_modules/cli-columns/license diff --git a/node_modules/cli-columns/node_modules/ansi-regex/index.d.ts b/node_modules/cli-columns/node_modules/ansi-regex/index.d.ts deleted file mode 100644 index 2dbf6af..0000000 --- a/node_modules/cli-columns/node_modules/ansi-regex/index.d.ts +++ /dev/null @@ -1,37 +0,0 @@ -declare namespace ansiRegex { - interface Options { - /** - Match only the first ANSI escape. - - @default false - */ - onlyFirst: boolean; - } -} - -/** -Regular expression for matching ANSI escape codes. - -@example -``` -import ansiRegex = require('ansi-regex'); - -ansiRegex().test('\u001B[4mcake\u001B[0m'); -//=> true - -ansiRegex().test('cake'); -//=> false - -'\u001B[4mcake\u001B[0m'.match(ansiRegex()); -//=> ['\u001B[4m', '\u001B[0m'] - -'\u001B[4mcake\u001B[0m'.match(ansiRegex({onlyFirst: true})); -//=> ['\u001B[4m'] - -'\u001B]8;;https://github.com\u0007click\u001B]8;;\u0007'.match(ansiRegex()); -//=> ['\u001B]8;;https://github.com\u0007', '\u001B]8;;\u0007'] -``` -*/ -declare function ansiRegex(options?: ansiRegex.Options): RegExp; - -export = ansiRegex; diff --git a/node_modules/cli-columns/node_modules/ansi-regex/index.js b/node_modules/cli-columns/node_modules/ansi-regex/index.js deleted file mode 100644 index 616ff83..0000000 --- a/node_modules/cli-columns/node_modules/ansi-regex/index.js +++ /dev/null @@ -1,10 +0,0 @@ -'use strict'; - -module.exports = ({onlyFirst = false} = {}) => { - const pattern = [ - '[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)', - '(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))' - ].join('|'); - - return new RegExp(pattern, onlyFirst ? undefined : 'g'); -}; diff --git a/node_modules/cli-columns/node_modules/ansi-regex/license b/node_modules/cli-columns/node_modules/ansi-regex/license deleted file mode 100644 index e7af2f7..0000000 --- a/node_modules/cli-columns/node_modules/ansi-regex/license +++ /dev/null @@ -1,9 +0,0 @@ -MIT License - -Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com) - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/cli-columns/node_modules/ansi-regex/package.json b/node_modules/cli-columns/node_modules/ansi-regex/package.json deleted file mode 100644 index 017f531..0000000 --- a/node_modules/cli-columns/node_modules/ansi-regex/package.json +++ /dev/null @@ -1,55 +0,0 @@ -{ - "name": "ansi-regex", - "version": "5.0.1", - "description": "Regular expression for matching ANSI escape codes", - "license": "MIT", - "repository": "chalk/ansi-regex", - "author": { - "name": "Sindre Sorhus", - "email": "sindresorhus@gmail.com", - "url": "sindresorhus.com" - }, - "engines": { - "node": ">=8" - }, - "scripts": { - "test": "xo && ava && tsd", - "view-supported": "node fixtures/view-codes.js" - }, - "files": [ - "index.js", - "index.d.ts" - ], - "keywords": [ - "ansi", - "styles", - "color", - "colour", - "colors", - "terminal", - "console", - "cli", - "string", - "tty", - "escape", - "formatting", - "rgb", - "256", - "shell", - "xterm", - "command-line", - "text", - "regex", - "regexp", - "re", - "match", - "test", - "find", - "pattern" - ], - "devDependencies": { - "ava": "^2.4.0", - "tsd": "^0.9.0", - "xo": "^0.25.3" - } -} diff --git a/node_modules/cli-columns/node_modules/is-fullwidth-code-point/index.d.ts b/node_modules/cli-columns/node_modules/is-fullwidth-code-point/index.d.ts deleted file mode 100644 index 729d202..0000000 --- a/node_modules/cli-columns/node_modules/is-fullwidth-code-point/index.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** -Check if the character represented by a given [Unicode code point](https://en.wikipedia.org/wiki/Code_point) is [fullwidth](https://en.wikipedia.org/wiki/Halfwidth_and_fullwidth_forms). - -@param codePoint - The [code point](https://en.wikipedia.org/wiki/Code_point) of a character. - -@example -``` -import isFullwidthCodePoint from 'is-fullwidth-code-point'; - -isFullwidthCodePoint('谢'.codePointAt(0)); -//=> true - -isFullwidthCodePoint('a'.codePointAt(0)); -//=> false -``` -*/ -export default function isFullwidthCodePoint(codePoint: number): boolean; diff --git a/node_modules/cli-columns/node_modules/is-fullwidth-code-point/index.js b/node_modules/cli-columns/node_modules/is-fullwidth-code-point/index.js deleted file mode 100644 index 671f97f..0000000 --- a/node_modules/cli-columns/node_modules/is-fullwidth-code-point/index.js +++ /dev/null @@ -1,50 +0,0 @@ -/* eslint-disable yoda */ -'use strict'; - -const isFullwidthCodePoint = codePoint => { - if (Number.isNaN(codePoint)) { - return false; - } - - // Code points are derived from: - // http://www.unix.org/Public/UNIDATA/EastAsianWidth.txt - if ( - codePoint >= 0x1100 && ( - codePoint <= 0x115F || // Hangul Jamo - codePoint === 0x2329 || // LEFT-POINTING ANGLE BRACKET - codePoint === 0x232A || // RIGHT-POINTING ANGLE BRACKET - // CJK Radicals Supplement .. Enclosed CJK Letters and Months - (0x2E80 <= codePoint && codePoint <= 0x3247 && codePoint !== 0x303F) || - // Enclosed CJK Letters and Months .. CJK Unified Ideographs Extension A - (0x3250 <= codePoint && codePoint <= 0x4DBF) || - // CJK Unified Ideographs .. Yi Radicals - (0x4E00 <= codePoint && codePoint <= 0xA4C6) || - // Hangul Jamo Extended-A - (0xA960 <= codePoint && codePoint <= 0xA97C) || - // Hangul Syllables - (0xAC00 <= codePoint && codePoint <= 0xD7A3) || - // CJK Compatibility Ideographs - (0xF900 <= codePoint && codePoint <= 0xFAFF) || - // Vertical Forms - (0xFE10 <= codePoint && codePoint <= 0xFE19) || - // CJK Compatibility Forms .. Small Form Variants - (0xFE30 <= codePoint && codePoint <= 0xFE6B) || - // Halfwidth and Fullwidth Forms - (0xFF01 <= codePoint && codePoint <= 0xFF60) || - (0xFFE0 <= codePoint && codePoint <= 0xFFE6) || - // Kana Supplement - (0x1B000 <= codePoint && codePoint <= 0x1B001) || - // Enclosed Ideographic Supplement - (0x1F200 <= codePoint && codePoint <= 0x1F251) || - // CJK Unified Ideographs Extension B .. Tertiary Ideographic Plane - (0x20000 <= codePoint && codePoint <= 0x3FFFD) - ) - ) { - return true; - } - - return false; -}; - -module.exports = isFullwidthCodePoint; -module.exports.default = isFullwidthCodePoint; diff --git a/node_modules/cli-columns/node_modules/is-fullwidth-code-point/license b/node_modules/cli-columns/node_modules/is-fullwidth-code-point/license deleted file mode 100644 index e7af2f7..0000000 --- a/node_modules/cli-columns/node_modules/is-fullwidth-code-point/license +++ /dev/null @@ -1,9 +0,0 @@ -MIT License - -Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com) - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/cli-columns/node_modules/is-fullwidth-code-point/package.json b/node_modules/cli-columns/node_modules/is-fullwidth-code-point/package.json deleted file mode 100644 index 2137e88..0000000 --- a/node_modules/cli-columns/node_modules/is-fullwidth-code-point/package.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "name": "is-fullwidth-code-point", - "version": "3.0.0", - "description": "Check if the character represented by a given Unicode code point is fullwidth", - "license": "MIT", - "repository": "sindresorhus/is-fullwidth-code-point", - "author": { - "name": "Sindre Sorhus", - "email": "sindresorhus@gmail.com", - "url": "sindresorhus.com" - }, - "engines": { - "node": ">=8" - }, - "scripts": { - "test": "xo && ava && tsd-check" - }, - "files": [ - "index.js", - "index.d.ts" - ], - "keywords": [ - "fullwidth", - "full-width", - "full", - "width", - "unicode", - "character", - "string", - "codepoint", - "code", - "point", - "is", - "detect", - "check" - ], - "devDependencies": { - "ava": "^1.3.1", - "tsd-check": "^0.5.0", - "xo": "^0.24.0" - } -} diff --git a/node_modules/cli-columns/node_modules/string-width/index.d.ts b/node_modules/cli-columns/node_modules/string-width/index.d.ts deleted file mode 100644 index 12b5309..0000000 --- a/node_modules/cli-columns/node_modules/string-width/index.d.ts +++ /dev/null @@ -1,29 +0,0 @@ -declare const stringWidth: { - /** - Get the visual width of a string - the number of columns required to display it. - - Some Unicode characters are [fullwidth](https://en.wikipedia.org/wiki/Halfwidth_and_fullwidth_forms) and use double the normal width. [ANSI escape codes](https://en.wikipedia.org/wiki/ANSI_escape_code) are stripped and doesn't affect the width. - - @example - ``` - import stringWidth = require('string-width'); - - stringWidth('a'); - //=> 1 - - stringWidth('古'); - //=> 2 - - stringWidth('\u001B[1m古\u001B[22m'); - //=> 2 - ``` - */ - (string: string): number; - - // TODO: remove this in the next major version, refactor the whole definition to: - // declare function stringWidth(string: string): number; - // export = stringWidth; - default: typeof stringWidth; -} - -export = stringWidth; diff --git a/node_modules/cli-columns/node_modules/string-width/index.js b/node_modules/cli-columns/node_modules/string-width/index.js deleted file mode 100644 index f4d261a..0000000 --- a/node_modules/cli-columns/node_modules/string-width/index.js +++ /dev/null @@ -1,47 +0,0 @@ -'use strict'; -const stripAnsi = require('strip-ansi'); -const isFullwidthCodePoint = require('is-fullwidth-code-point'); -const emojiRegex = require('emoji-regex'); - -const stringWidth = string => { - if (typeof string !== 'string' || string.length === 0) { - return 0; - } - - string = stripAnsi(string); - - if (string.length === 0) { - return 0; - } - - string = string.replace(emojiRegex(), ' '); - - let width = 0; - - for (let i = 0; i < string.length; i++) { - const code = string.codePointAt(i); - - // Ignore control characters - if (code <= 0x1F || (code >= 0x7F && code <= 0x9F)) { - continue; - } - - // Ignore combining characters - if (code >= 0x300 && code <= 0x36F) { - continue; - } - - // Surrogates - if (code > 0xFFFF) { - i++; - } - - width += isFullwidthCodePoint(code) ? 2 : 1; - } - - return width; -}; - -module.exports = stringWidth; -// TODO: remove this in the next major version -module.exports.default = stringWidth; diff --git a/node_modules/cli-columns/node_modules/string-width/license b/node_modules/cli-columns/node_modules/string-width/license deleted file mode 100644 index e7af2f7..0000000 --- a/node_modules/cli-columns/node_modules/string-width/license +++ /dev/null @@ -1,9 +0,0 @@ -MIT License - -Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com) - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/cli-columns/node_modules/string-width/package.json b/node_modules/cli-columns/node_modules/string-width/package.json deleted file mode 100644 index 28ba7b4..0000000 --- a/node_modules/cli-columns/node_modules/string-width/package.json +++ /dev/null @@ -1,56 +0,0 @@ -{ - "name": "string-width", - "version": "4.2.3", - "description": "Get the visual width of a string - the number of columns required to display it", - "license": "MIT", - "repository": "sindresorhus/string-width", - "author": { - "name": "Sindre Sorhus", - "email": "sindresorhus@gmail.com", - "url": "sindresorhus.com" - }, - "engines": { - "node": ">=8" - }, - "scripts": { - "test": "xo && ava && tsd" - }, - "files": [ - "index.js", - "index.d.ts" - ], - "keywords": [ - "string", - "character", - "unicode", - "width", - "visual", - "column", - "columns", - "fullwidth", - "full-width", - "full", - "ansi", - "escape", - "codes", - "cli", - "command-line", - "terminal", - "console", - "cjk", - "chinese", - "japanese", - "korean", - "fixed-width" - ], - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "devDependencies": { - "ava": "^1.4.1", - "tsd": "^0.7.1", - "xo": "^0.24.0" - } -} diff --git a/node_modules/cli-columns/node_modules/strip-ansi/index.d.ts b/node_modules/cli-columns/node_modules/strip-ansi/index.d.ts deleted file mode 100644 index 907fccc..0000000 --- a/node_modules/cli-columns/node_modules/strip-ansi/index.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** -Strip [ANSI escape codes](https://en.wikipedia.org/wiki/ANSI_escape_code) from a string. - -@example -``` -import stripAnsi = require('strip-ansi'); - -stripAnsi('\u001B[4mUnicorn\u001B[0m'); -//=> 'Unicorn' - -stripAnsi('\u001B]8;;https://github.com\u0007Click\u001B]8;;\u0007'); -//=> 'Click' -``` -*/ -declare function stripAnsi(string: string): string; - -export = stripAnsi; diff --git a/node_modules/cli-columns/node_modules/strip-ansi/index.js b/node_modules/cli-columns/node_modules/strip-ansi/index.js deleted file mode 100644 index 9a593df..0000000 --- a/node_modules/cli-columns/node_modules/strip-ansi/index.js +++ /dev/null @@ -1,4 +0,0 @@ -'use strict'; -const ansiRegex = require('ansi-regex'); - -module.exports = string => typeof string === 'string' ? string.replace(ansiRegex(), '') : string; diff --git a/node_modules/cli-columns/node_modules/strip-ansi/license b/node_modules/cli-columns/node_modules/strip-ansi/license deleted file mode 100644 index e7af2f7..0000000 --- a/node_modules/cli-columns/node_modules/strip-ansi/license +++ /dev/null @@ -1,9 +0,0 @@ -MIT License - -Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com) - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/cli-columns/node_modules/strip-ansi/package.json b/node_modules/cli-columns/node_modules/strip-ansi/package.json deleted file mode 100644 index 1a41108..0000000 --- a/node_modules/cli-columns/node_modules/strip-ansi/package.json +++ /dev/null @@ -1,54 +0,0 @@ -{ - "name": "strip-ansi", - "version": "6.0.1", - "description": "Strip ANSI escape codes from a string", - "license": "MIT", - "repository": "chalk/strip-ansi", - "author": { - "name": "Sindre Sorhus", - "email": "sindresorhus@gmail.com", - "url": "sindresorhus.com" - }, - "engines": { - "node": ">=8" - }, - "scripts": { - "test": "xo && ava && tsd" - }, - "files": [ - "index.js", - "index.d.ts" - ], - "keywords": [ - "strip", - "trim", - "remove", - "ansi", - "styles", - "color", - "colour", - "colors", - "terminal", - "console", - "string", - "tty", - "escape", - "formatting", - "rgb", - "256", - "shell", - "xterm", - "log", - "logging", - "command-line", - "text" - ], - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "devDependencies": { - "ava": "^2.4.0", - "tsd": "^0.10.0", - "xo": "^0.25.3" - } -} diff --git a/node_modules/cmd-shim/index.js b/node_modules/cmd-shim/lib/index.js similarity index 89% rename from node_modules/cmd-shim/index.js rename to node_modules/cmd-shim/lib/index.js index 4a7614b..cf223fe 100644 --- a/node_modules/cmd-shim/index.js +++ b/node_modules/cmd-shim/lib/index.js @@ -8,18 +8,18 @@ // Write a binroot/pkg.bin + ".cmd" file that has this line in it: // @<prog> <args...> %dp0%<target> %* -const {promisify} = require('util') -const fs = require('fs') -const writeFile = promisify(fs.writeFile) -const readFile = promisify(fs.readFile) -const chmod = promisify(fs.chmod) -const stat = promisify(fs.stat) -const unlink = promisify(fs.unlink) +const { + chmod, + mkdir, + readFile, + stat, + unlink, + writeFile, +} = require('fs/promises') -const {dirname, relative} = require('path') -const mkdir = require('mkdirp-infer-owner') -const toBatchSyntax = require('./lib/to-batch-syntax') -const shebangExpr = /^#\!\s*(?:\/usr\/bin\/env)?\s*([^ \t]+=[^ \t]+\s+)*\s*([^ \t]+)(.*)$/ +const { dirname, relative } = require('path') +const toBatchSyntax = require('./to-batch-syntax') +const shebangExpr = /^#!\s*(?:\/usr\/bin\/env\s*((?:[^ \t=]+=[^ \t=]+\s+)*))?([^ \t]+)(.*)$/ const cmdShimIfExists = (from, to) => stat(from).then(() => cmdShim(from, to), () => {}) @@ -42,19 +42,20 @@ const writeShim = (from, to) => // First, check if the bin is a #! of some sort. // If not, then assume it's something that'll be compiled, or some other // sort of script, and just call it directly. - mkdir(dirname(to)) + mkdir(dirname(to), { recursive: true }) .then(() => readFile(from, 'utf8')) .then(data => { const firstLine = data.trim().split(/\r*\n/)[0] const shebang = firstLine.match(shebangExpr) - if (!shebang) return writeShim_(from, to) + if (!shebang) { + return writeShim_(from, to) + } const vars = shebang[1] || '' const prog = shebang[2] const args = shebang[3] || '' return writeShim_(from, to, prog, args, vars) }, er => writeShim_(from, to)) - const writeShim_ = (from, to, prog, args, variables) => { let shTarget = relative(dirname(to), from) let target = shTarget.split('/').join('\\') @@ -94,8 +95,8 @@ const writeShim_ = (from, to, prog, args, variables) => { let cmd if (longProg) { - shLongProg = shLongProg.trim(); - args = args.trim(); + shLongProg = shLongProg.trim() + args = args.trim() const variablesBatch = toBatchSyntax.convertToSetCommands(variables) cmd = head + variablesBatch @@ -110,7 +111,7 @@ const writeShim_ = (from, to, prog, args, variables) => { // prevent "Terminate Batch Job? (Y/n)" message // https://github.com/npm/cli/issues/969#issuecomment-737496588 + 'endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & ' - + `"%_prog%" ${args} ${target} %*\r\n` + + `"%_prog%" ${args} ${target} %*\r\n` } else { cmd = `${head}${prog} ${args} ${target} %*\r\n` } @@ -128,7 +129,7 @@ const writeShim_ = (from, to, prog, args, variables) => { // exec node "$basedir/node_modules/npm/bin/npm-cli.js" "$@" // fi - let sh = "#!/bin/sh\n" + let sh = '#!/bin/sh\n' sh = sh + `basedir=$(dirname "$(echo "$0" | sed -e 's,\\\\,/,g')")\n` @@ -182,7 +183,7 @@ const writeShim_ = (from, to, prog, args, variables) => { + '$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent\n' + '\n' + '$exe=""\n' - + 'if ($PSVersionTable.PSVersion -lt \"6.0\" -or $IsWindows) {\n' + + 'if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {\n' + ' # Fix case when both the Windows and Linux builds of Node\n' + ' # are installed in the same directory\n' + ' $exe=".exe"\n' diff --git a/node_modules/cmd-shim/lib/to-batch-syntax.js b/node_modules/cmd-shim/lib/to-batch-syntax.js index f3f5ffa..86a3f01 100644 --- a/node_modules/cmd-shim/lib/to-batch-syntax.js +++ b/node_modules/cmd-shim/lib/to-batch-syntax.js @@ -2,50 +2,48 @@ exports.replaceDollarWithPercentPair = replaceDollarWithPercentPair exports.convertToSetCommand = convertToSetCommand exports.convertToSetCommands = convertToSetCommands -function convertToSetCommand(key, value) { - var line = "" - key = key || "" - key = key.trim() - value = value || "" - value = value.trim() - if(key && value && value.length > 0) { - line = "@SET " + key + "=" + replaceDollarWithPercentPair(value) + "\r\n" +function convertToSetCommand (key, value) { + var line = '' + key = key || '' + key = key.trim() + value = value || '' + value = value.trim() + if (key && value && value.length > 0) { + line = '@SET ' + key + '=' + replaceDollarWithPercentPair(value) + '\r\n' + } + return line +} + +function extractVariableValuePairs (declarations) { + var pairs = {} + declarations.map(function (declaration) { + var split = declaration.split('=') + pairs[split[0]] = split[1] + }) + return pairs +} + +function convertToSetCommands (variableString) { + var variableValuePairs = extractVariableValuePairs(variableString.split(' ')) + var variableDeclarationsAsBatch = '' + Object.keys(variableValuePairs).forEach(function (key) { + variableDeclarationsAsBatch += convertToSetCommand(key, variableValuePairs[key]) + }) + return variableDeclarationsAsBatch +} + +function replaceDollarWithPercentPair (value) { + var dollarExpressions = /\$\{?([^$@#?\- \t{}:]+)\}?/g + var result = '' + var startIndex = 0 + do { + var match = dollarExpressions.exec(value) + if (match) { + var betweenMatches = value.substring(startIndex, match.index) || '' + result += betweenMatches + '%' + match[1] + '%' + startIndex = dollarExpressions.lastIndex } - return line + } while (dollarExpressions.lastIndex > 0) + result += value.slice(startIndex) + return result } - -function extractVariableValuePairs(declarations) { - var pairs = {} - declarations.map(function(declaration) { - var split = declaration.split("=") - pairs[split[0]]=split[1] - }) - return pairs -} - -function convertToSetCommands(variableString) { - var variableValuePairs = extractVariableValuePairs(variableString.split(" ")) - var variableDeclarationsAsBatch = "" - Object.keys(variableValuePairs).forEach(function (key) { - variableDeclarationsAsBatch += convertToSetCommand(key, variableValuePairs[key]) - }) - return variableDeclarationsAsBatch -} - -function replaceDollarWithPercentPair(value) { - var dollarExpressions = /\$\{?([^\$@#\?\- \t{}:]+)\}?/g - var result = "" - var startIndex = 0 - do { - var match = dollarExpressions.exec(value) - if(match) { - var betweenMatches = value.substring(startIndex, match.index) || "" - result += betweenMatches + "%" + match[1] + "%" - startIndex = dollarExpressions.lastIndex - } - } while (dollarExpressions.lastIndex > 0) - result += value.substr(startIndex) - return result -} - - diff --git a/node_modules/cmd-shim/package.json b/node_modules/cmd-shim/package.json index 11e17c8..80cbec8 100644 --- a/node_modules/cmd-shim/package.json +++ b/node_modules/cmd-shim/package.json @@ -1,36 +1,46 @@ { "name": "cmd-shim", - "version": "4.1.0", + "version": "6.0.0", "description": "Used in npm for command line application support", "scripts": { "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "postpublish": "git push origin --follow-tags" + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "npm run lint -- --fix", + "posttest": "npm run lint" }, "repository": { "type": "git", "url": "https://github.com/npm/cmd-shim.git" }, "license": "ISC", - "dependencies": { - "mkdirp-infer-owner": "^2.0.0" - }, "devDependencies": { - "rimraf": "~2.2.8", - "tap": "^14.10.6" + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", + "tap": "^16.0.1" }, "files": [ - "index.js", - "lib" + "bin/", + "lib/" ], + "main": "lib/index.js", "tap": { "before": "test/00-setup.js", "after": "test/zz-cleanup.js", - "check-coverage": true + "check-coverage": true, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "author": "GitHub Inc.", + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" } } diff --git a/node_modules/debuglog/debuglog.js b/node_modules/debuglog/debuglog.js deleted file mode 100644 index 748fd72..0000000 --- a/node_modules/debuglog/debuglog.js +++ /dev/null @@ -1,22 +0,0 @@ -var util = require('util'); - -module.exports = (util && util.debuglog) || debuglog; - -var debugs = {}; -var debugEnviron = process.env.NODE_DEBUG || ''; - -function debuglog(set) { - set = set.toUpperCase(); - if (!debugs[set]) { - if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) { - var pid = process.pid; - debugs[set] = function() { - var msg = util.format.apply(exports, arguments); - console.error('%s %d: %s', set, pid, msg); - }; - } else { - debugs[set] = function() {}; - } - } - return debugs[set]; -}; diff --git a/node_modules/debuglog/package.json b/node_modules/debuglog/package.json deleted file mode 100644 index e51ecc9..0000000 --- a/node_modules/debuglog/package.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "name": "debuglog", - "version": "1.0.1", - "description": "backport of util.debuglog from node v0.11", - "license": "MIT", - "main": "debuglog.js", - "repository": { - "type": "git", - "url": "https://github.com/sam-github/node-debuglog.git" - }, - "author": { - "name": "Sam Roberts", - "email": "sam@strongloop.com" - }, - "engines": { - "node": "*" - }, - "browser": { - "util": false - } -} diff --git a/node_modules/dezalgo/LICENSE b/node_modules/dezalgo/LICENSE deleted file mode 100644 index 19129e3..0000000 --- a/node_modules/dezalgo/LICENSE +++ /dev/null @@ -1,15 +0,0 @@ -The ISC License - -Copyright (c) Isaac Z. Schlueter and Contributors - -Permission to use, copy, modify, and/or distribute this software for any -purpose with or without fee is hereby granted, provided that the above -copyright notice and this permission notice appear in all copies. - -THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR -IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/node_modules/dezalgo/dezalgo.js b/node_modules/dezalgo/dezalgo.js deleted file mode 100644 index 04fd3ba..0000000 --- a/node_modules/dezalgo/dezalgo.js +++ /dev/null @@ -1,22 +0,0 @@ -var wrappy = require('wrappy') -module.exports = wrappy(dezalgo) - -var asap = require('asap') - -function dezalgo (cb) { - var sync = true - asap(function () { - sync = false - }) - - return function zalgoSafe() { - var args = arguments - var me = this - if (sync) - asap(function() { - cb.apply(me, args) - }) - else - cb.apply(me, args) - } -} diff --git a/node_modules/dezalgo/package.json b/node_modules/dezalgo/package.json deleted file mode 100644 index 634dd0d..0000000 --- a/node_modules/dezalgo/package.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "name": "dezalgo", - "version": "1.0.3", - "description": "Contain async insanity so that the dark pony lord doesn't eat souls", - "main": "dezalgo.js", - "directories": { - "test": "test" - }, - "dependencies": { - "asap": "^2.0.0", - "wrappy": "1" - }, - "devDependencies": { - "tap": "^1.2.0" - }, - "scripts": { - "test": "tap test/*.js" - }, - "repository": { - "type": "git", - "url": "https://github.com/npm/dezalgo" - }, - "keywords": [ - "async", - "zalgo", - "the dark pony", - "he comes", - "asynchrony of all holy and good", - "T̯̪ͅo̯͖̹ ̻̮̖̲͢i̥̖n̢͈͇̝͍v͏͉ok̭̬̝ͅe̞͍̩̫͍̩͝ ̩̮̖̟͇͉́t͔͔͎̗h͏̗̟e̘͉̰̦̠̞͓ ͕h͉̟͎̪̠̱͠ḭ̮̩v̺͉͇̩e̵͖-̺̪m͍i̜n̪̲̲̲̮d̷ ̢r̠̼̯̹̦̦͘ͅe͓̳͓̙p̺̗̫͙͘ͅr͔̰͜e̴͓̞s͉̩̩͟ͅe͏̣n͚͇̗̭̺͍tì͙̣n͏̖̥̗͎̰̪g̞͓̭̱̯̫̕ ̣̱͜ͅc̦̰̰̠̮͎͙̀hao̺̜̻͍͙ͅs͉͓̘.͎̼̺̼͕̹͘", - "̠̞̱̰I͖͇̝̻n̦̰͍̰̟v̤̺̫̳̭̼̗͘ò̹̟̩̩͚k̢̥̠͍͉̦̬i̖͓͔̮̱̻͘n̶̳͙̫͎g̖̯̣̲̪͉ ̞͎̗͕͚ͅt̲͕̘̺̯̗̦h̘̦̲̜̻e̳͎͉̬͙ ̴̞̪̲̥f̜̯͓͓̭̭͢e̱̘͔̮e̜̤l̺̱͖̯͓͙͈͢i̵̦̬͉͔̫͚͕n͉g̨͖̙̙̹̹̟̤ ͉̪o̞̠͍̪̰͙ͅf̬̲̺ ͔͕̲͕͕̲̕c̙͉h̝͔̩̙̕ͅa̲͖̻̗̹o̥̼̫s̝̖̜̝͚̫̟.̺͚ ̸̱̲W̶̥̣͖̦i͏̤̬̱̳̣ͅt͉h̗̪̪ ̷̱͚̹̪ǫ͕̗̣̳̦͎u̼̦͔̥̮̕ţ͖͎̻͔͉ ̴͎̩òr̹̰̖͉͈͝d̷̲̦̖͓e̲͓̠r", - "̧͚̜͓̰̭̭Ṯ̫̹̜̮̟̮͝h͚̘̩̘̖̰́e ̥̘͓͉͔͙̼N̟̜̣̘͔̪e̞̞̤͢z̰̖̘͇p̠͟e̺̱̣͍͙̝ṛ̘̬͔̙͇̠d͝ḭ̯̱̥̗̩a̛ͅn͏̦ ̷̥hi̥v̖̳̹͉̮̱͝e̹̪̘̖̰̟-̴͙͓͚̜̻mi̗̺̻͙̺ͅn̪̯͈d ͏̘͓̫̳ͅơ̹͔̳̖̣͓f͈̹̘ ͕ͅc̗̤̠̜̮̥̥h̡͍̩̭̫͚̱a̤͉̤͔͜os͕̤̼͍̲̀ͅ.̡̱ ̦Za̯̱̗̭͍̣͚l̗͉̰̤g͏̣̭̬̗̲͖ͅo̶̭̩̳̟͈.̪̦̰̳", - "H̴̱̦̗̬̣͓̺e̮ ͉̠̰̞͎̖͟ẁh̛̺̯ͅo̖̫͡ ̢Ẁa̡̗i̸t͖̣͉̀ş͔̯̩ ̤̦̮͇̞̦̲B͎̭͇̦̼e̢hin͏͙̟̪d̴̰͓̻̣̮͕ͅ T͖̮̕h͖e̘̺̰̙͘ ̥Ẁ̦͔̻͚a̞͖̪͉l̪̠̻̰̣̠l̲͎͞", - "Z̘͍̼͎̣͔͝Ą̲̜̱̱̹̤͇L̶̝̰̭͔G͍̖͍O̫͜ͅ!̼̤ͅ", - "H̝̪̜͓̀̌̂̒E̢̙̠̣ ̴̳͇̥̟̠͍̐C̹̓̑̐̆͝Ó̶̭͓̚M̬̼Ĕ̖̤͔͔̟̹̽̿̊ͥ̍ͫS̻̰̦̻̖̘̱̒ͪ͌̅͟" - ], - "author": "Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me/)", - "license": "ISC", - "bugs": { - "url": "https://github.com/npm/dezalgo/issues" - }, - "homepage": "https://github.com/npm/dezalgo" -} diff --git a/node_modules/dezalgo/test/basic.js b/node_modules/dezalgo/test/basic.js deleted file mode 100644 index da09e72..0000000 --- a/node_modules/dezalgo/test/basic.js +++ /dev/null @@ -1,29 +0,0 @@ -var test = require('tap').test -var dz = require('../dezalgo.js') - -test('the dark pony', function(t) { - - var n = 0 - function foo(i, cb) { - cb = dz(cb) - if (++n % 2) cb(true, i) - else process.nextTick(cb.bind(null, false, i)) - } - - var called = 0 - var order = [0, 2, 4, 6, 8, 1, 3, 5, 7, 9] - var o = 0 - for (var i = 0; i < 10; i++) { - foo(i, function(cached, i) { - t.equal(i, order[o++]) - t.equal(i % 2, cached ? 0 : 1) - called++ - }) - t.equal(called, 0) - } - - setTimeout(function() { - t.equal(called, 10) - t.end() - }) -}) diff --git a/node_modules/env-paths/readme.md b/node_modules/env-paths/readme.md deleted file mode 100644 index b66d571..0000000 --- a/node_modules/env-paths/readme.md +++ /dev/null @@ -1,115 +0,0 @@ -# env-paths - -> Get paths for storing things like data, config, cache, etc - -Uses the correct OS-specific paths. Most developers get this wrong. - - -## Install - -``` -$ npm install env-paths -``` - - -## Usage - -```js -const envPaths = require('env-paths'); - -const paths = envPaths('MyApp'); - -paths.data; -//=> '/home/sindresorhus/.local/share/MyApp-nodejs' - -paths.config -//=> '/home/sindresorhus/.config/MyApp-nodejs' -``` - - -## API - -### paths = envPaths(name, options?) - -Note: It only generates the path strings. It doesn't create the directories for you. You could use [`make-dir`](https://github.com/sindresorhus/make-dir) to create the directories. - -#### name - -Type: `string` - -Name of your project. Used to generate the paths. - -#### options - -Type: `object` - -##### suffix - -Type: `string`<br> -Default: `'nodejs'` - -**Don't use this option unless you really have to!**<br> -Suffix appended to the project name to avoid name conflicts with native -apps. Pass an empty string to disable it. - -### paths.data - -Directory for data files. - -Example locations (with the default `nodejs` [suffix](#suffix)): - -- macOS: `~/Library/Application Support/MyApp-nodejs` -- Windows: `%LOCALAPPDATA%\MyApp-nodejs\Data` (for example, `C:\Users\USERNAME\AppData\Local\MyApp-nodejs\Data`) -- Linux: `~/.local/share/MyApp-nodejs` (or `$XDG_DATA_HOME/MyApp-nodejs`) - -### paths.config - -Directory for config files. - -Example locations (with the default `nodejs` [suffix](#suffix)): - -- macOS: `~/Library/Preferences/MyApp-nodejs` -- Windows: `%APPDATA%\MyApp-nodejs\Config` (for example, `C:\Users\USERNAME\AppData\Roaming\MyApp-nodejs\Config`) -- Linux: `~/.config/MyApp-nodejs` (or `$XDG_CONFIG_HOME/MyApp-nodejs`) - -### paths.cache - -Directory for non-essential data files. - -Example locations (with the default `nodejs` [suffix](#suffix)): - -- macOS: `~/Library/Caches/MyApp-nodejs` -- Windows: `%LOCALAPPDATA%\MyApp-nodejs\Cache` (for example, `C:\Users\USERNAME\AppData\Local\MyApp-nodejs\Cache`) -- Linux: `~/.cache/MyApp-nodejs` (or `$XDG_CACHE_HOME/MyApp-nodejs`) - -### paths.log - -Directory for log files. - -Example locations (with the default `nodejs` [suffix](#suffix)): - -- macOS: `~/Library/Logs/MyApp-nodejs` -- Windows: `%LOCALAPPDATA%\MyApp-nodejs\Log` (for example, `C:\Users\USERNAME\AppData\Local\MyApp-nodejs\Log`) -- Linux: `~/.local/state/MyApp-nodejs` (or `$XDG_STATE_HOME/MyApp-nodejs`) - -### paths.temp - -Directory for temporary files. - -Example locations (with the default `nodejs` [suffix](#suffix)): - -- macOS: `/var/folders/jf/f2twvvvs5jl_m49tf034ffpw0000gn/T/MyApp-nodejs` -- Windows: `%LOCALAPPDATA%\Temp\MyApp-nodejs` (for example, `C:\Users\USERNAME\AppData\Local\Temp\MyApp-nodejs`) -- Linux: `/tmp/USERNAME/MyApp-nodejs` - ---- - -<div align="center"> - <b> - <a href="https://tidelift.com/subscription/pkg/npm-env-paths?utm_source=npm-env-paths&utm_medium=referral&utm_campaign=readme">Get professional support for this package with a Tidelift subscription</a> - </b> - <br> - <sub> - Tidelift helps make open source sustainable for maintainers while giving companies<br>assurances about security, maintenance, and licensing for their dependencies. - </sub> -</div> diff --git a/node_modules/event-target-shim/LICENSE b/node_modules/event-target-shim/LICENSE new file mode 100644 index 0000000..c39e694 --- /dev/null +++ b/node_modules/event-target-shim/LICENSE @@ -0,0 +1,22 @@ +The MIT License (MIT) + +Copyright (c) 2015 Toru Nagashima + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + diff --git a/node_modules/event-target-shim/dist/event-target-shim.js b/node_modules/event-target-shim/dist/event-target-shim.js new file mode 100644 index 0000000..53ce220 --- /dev/null +++ b/node_modules/event-target-shim/dist/event-target-shim.js @@ -0,0 +1,871 @@ +/** + * @author Toru Nagashima <https://github.com/mysticatea> + * @copyright 2015 Toru Nagashima. All rights reserved. + * See LICENSE file in root directory for full license. + */ +'use strict'; + +Object.defineProperty(exports, '__esModule', { value: true }); + +/** + * @typedef {object} PrivateData + * @property {EventTarget} eventTarget The event target. + * @property {{type:string}} event The original event object. + * @property {number} eventPhase The current event phase. + * @property {EventTarget|null} currentTarget The current event target. + * @property {boolean} canceled The flag to prevent default. + * @property {boolean} stopped The flag to stop propagation. + * @property {boolean} immediateStopped The flag to stop propagation immediately. + * @property {Function|null} passiveListener The listener if the current listener is passive. Otherwise this is null. + * @property {number} timeStamp The unix time. + * @private + */ + +/** + * Private data for event wrappers. + * @type {WeakMap<Event, PrivateData>} + * @private + */ +const privateData = new WeakMap(); + +/** + * Cache for wrapper classes. + * @type {WeakMap<Object, Function>} + * @private + */ +const wrappers = new WeakMap(); + +/** + * Get private data. + * @param {Event} event The event object to get private data. + * @returns {PrivateData} The private data of the event. + * @private + */ +function pd(event) { + const retv = privateData.get(event); + console.assert( + retv != null, + "'this' is expected an Event object, but got", + event + ); + return retv +} + +/** + * https://dom.spec.whatwg.org/#set-the-canceled-flag + * @param data {PrivateData} private data. + */ +function setCancelFlag(data) { + if (data.passiveListener != null) { + if ( + typeof console !== "undefined" && + typeof console.error === "function" + ) { + console.error( + "Unable to preventDefault inside passive event listener invocation.", + data.passiveListener + ); + } + return + } + if (!data.event.cancelable) { + return + } + + data.canceled = true; + if (typeof data.event.preventDefault === "function") { + data.event.preventDefault(); + } +} + +/** + * @see https://dom.spec.whatwg.org/#interface-event + * @private + */ +/** + * The event wrapper. + * @constructor + * @param {EventTarget} eventTarget The event target of this dispatching. + * @param {Event|{type:string}} event The original event to wrap. + */ +function Event(eventTarget, event) { + privateData.set(this, { + eventTarget, + event, + eventPhase: 2, + currentTarget: eventTarget, + canceled: false, + stopped: false, + immediateStopped: false, + passiveListener: null, + timeStamp: event.timeStamp || Date.now(), + }); + + // https://heycam.github.io/webidl/#Unforgeable + Object.defineProperty(this, "isTrusted", { value: false, enumerable: true }); + + // Define accessors + const keys = Object.keys(event); + for (let i = 0; i < keys.length; ++i) { + const key = keys[i]; + if (!(key in this)) { + Object.defineProperty(this, key, defineRedirectDescriptor(key)); + } + } +} + +// Should be enumerable, but class methods are not enumerable. +Event.prototype = { + /** + * The type of this event. + * @type {string} + */ + get type() { + return pd(this).event.type + }, + + /** + * The target of this event. + * @type {EventTarget} + */ + get target() { + return pd(this).eventTarget + }, + + /** + * The target of this event. + * @type {EventTarget} + */ + get currentTarget() { + return pd(this).currentTarget + }, + + /** + * @returns {EventTarget[]} The composed path of this event. + */ + composedPath() { + const currentTarget = pd(this).currentTarget; + if (currentTarget == null) { + return [] + } + return [currentTarget] + }, + + /** + * Constant of NONE. + * @type {number} + */ + get NONE() { + return 0 + }, + + /** + * Constant of CAPTURING_PHASE. + * @type {number} + */ + get CAPTURING_PHASE() { + return 1 + }, + + /** + * Constant of AT_TARGET. + * @type {number} + */ + get AT_TARGET() { + return 2 + }, + + /** + * Constant of BUBBLING_PHASE. + * @type {number} + */ + get BUBBLING_PHASE() { + return 3 + }, + + /** + * The target of this event. + * @type {number} + */ + get eventPhase() { + return pd(this).eventPhase + }, + + /** + * Stop event bubbling. + * @returns {void} + */ + stopPropagation() { + const data = pd(this); + + data.stopped = true; + if (typeof data.event.stopPropagation === "function") { + data.event.stopPropagation(); + } + }, + + /** + * Stop event bubbling. + * @returns {void} + */ + stopImmediatePropagation() { + const data = pd(this); + + data.stopped = true; + data.immediateStopped = true; + if (typeof data.event.stopImmediatePropagation === "function") { + data.event.stopImmediatePropagation(); + } + }, + + /** + * The flag to be bubbling. + * @type {boolean} + */ + get bubbles() { + return Boolean(pd(this).event.bubbles) + }, + + /** + * The flag to be cancelable. + * @type {boolean} + */ + get cancelable() { + return Boolean(pd(this).event.cancelable) + }, + + /** + * Cancel this event. + * @returns {void} + */ + preventDefault() { + setCancelFlag(pd(this)); + }, + + /** + * The flag to indicate cancellation state. + * @type {boolean} + */ + get defaultPrevented() { + return pd(this).canceled + }, + + /** + * The flag to be composed. + * @type {boolean} + */ + get composed() { + return Boolean(pd(this).event.composed) + }, + + /** + * The unix time of this event. + * @type {number} + */ + get timeStamp() { + return pd(this).timeStamp + }, + + /** + * The target of this event. + * @type {EventTarget} + * @deprecated + */ + get srcElement() { + return pd(this).eventTarget + }, + + /** + * The flag to stop event bubbling. + * @type {boolean} + * @deprecated + */ + get cancelBubble() { + return pd(this).stopped + }, + set cancelBubble(value) { + if (!value) { + return + } + const data = pd(this); + + data.stopped = true; + if (typeof data.event.cancelBubble === "boolean") { + data.event.cancelBubble = true; + } + }, + + /** + * The flag to indicate cancellation state. + * @type {boolean} + * @deprecated + */ + get returnValue() { + return !pd(this).canceled + }, + set returnValue(value) { + if (!value) { + setCancelFlag(pd(this)); + } + }, + + /** + * Initialize this event object. But do nothing under event dispatching. + * @param {string} type The event type. + * @param {boolean} [bubbles=false] The flag to be possible to bubble up. + * @param {boolean} [cancelable=false] The flag to be possible to cancel. + * @deprecated + */ + initEvent() { + // Do nothing. + }, +}; + +// `constructor` is not enumerable. +Object.defineProperty(Event.prototype, "constructor", { + value: Event, + configurable: true, + writable: true, +}); + +// Ensure `event instanceof window.Event` is `true`. +if (typeof window !== "undefined" && typeof window.Event !== "undefined") { + Object.setPrototypeOf(Event.prototype, window.Event.prototype); + + // Make association for wrappers. + wrappers.set(window.Event.prototype, Event); +} + +/** + * Get the property descriptor to redirect a given property. + * @param {string} key Property name to define property descriptor. + * @returns {PropertyDescriptor} The property descriptor to redirect the property. + * @private + */ +function defineRedirectDescriptor(key) { + return { + get() { + return pd(this).event[key] + }, + set(value) { + pd(this).event[key] = value; + }, + configurable: true, + enumerable: true, + } +} + +/** + * Get the property descriptor to call a given method property. + * @param {string} key Property name to define property descriptor. + * @returns {PropertyDescriptor} The property descriptor to call the method property. + * @private + */ +function defineCallDescriptor(key) { + return { + value() { + const event = pd(this).event; + return event[key].apply(event, arguments) + }, + configurable: true, + enumerable: true, + } +} + +/** + * Define new wrapper class. + * @param {Function} BaseEvent The base wrapper class. + * @param {Object} proto The prototype of the original event. + * @returns {Function} The defined wrapper class. + * @private + */ +function defineWrapper(BaseEvent, proto) { + const keys = Object.keys(proto); + if (keys.length === 0) { + return BaseEvent + } + + /** CustomEvent */ + function CustomEvent(eventTarget, event) { + BaseEvent.call(this, eventTarget, event); + } + + CustomEvent.prototype = Object.create(BaseEvent.prototype, { + constructor: { value: CustomEvent, configurable: true, writable: true }, + }); + + // Define accessors. + for (let i = 0; i < keys.length; ++i) { + const key = keys[i]; + if (!(key in BaseEvent.prototype)) { + const descriptor = Object.getOwnPropertyDescriptor(proto, key); + const isFunc = typeof descriptor.value === "function"; + Object.defineProperty( + CustomEvent.prototype, + key, + isFunc + ? defineCallDescriptor(key) + : defineRedirectDescriptor(key) + ); + } + } + + return CustomEvent +} + +/** + * Get the wrapper class of a given prototype. + * @param {Object} proto The prototype of the original event to get its wrapper. + * @returns {Function} The wrapper class. + * @private + */ +function getWrapper(proto) { + if (proto == null || proto === Object.prototype) { + return Event + } + + let wrapper = wrappers.get(proto); + if (wrapper == null) { + wrapper = defineWrapper(getWrapper(Object.getPrototypeOf(proto)), proto); + wrappers.set(proto, wrapper); + } + return wrapper +} + +/** + * Wrap a given event to management a dispatching. + * @param {EventTarget} eventTarget The event target of this dispatching. + * @param {Object} event The event to wrap. + * @returns {Event} The wrapper instance. + * @private + */ +function wrapEvent(eventTarget, event) { + const Wrapper = getWrapper(Object.getPrototypeOf(event)); + return new Wrapper(eventTarget, event) +} + +/** + * Get the immediateStopped flag of a given event. + * @param {Event} event The event to get. + * @returns {boolean} The flag to stop propagation immediately. + * @private + */ +function isStopped(event) { + return pd(event).immediateStopped +} + +/** + * Set the current event phase of a given event. + * @param {Event} event The event to set current target. + * @param {number} eventPhase New event phase. + * @returns {void} + * @private + */ +function setEventPhase(event, eventPhase) { + pd(event).eventPhase = eventPhase; +} + +/** + * Set the current target of a given event. + * @param {Event} event The event to set current target. + * @param {EventTarget|null} currentTarget New current target. + * @returns {void} + * @private + */ +function setCurrentTarget(event, currentTarget) { + pd(event).currentTarget = currentTarget; +} + +/** + * Set a passive listener of a given event. + * @param {Event} event The event to set current target. + * @param {Function|null} passiveListener New passive listener. + * @returns {void} + * @private + */ +function setPassiveListener(event, passiveListener) { + pd(event).passiveListener = passiveListener; +} + +/** + * @typedef {object} ListenerNode + * @property {Function} listener + * @property {1|2|3} listenerType + * @property {boolean} passive + * @property {boolean} once + * @property {ListenerNode|null} next + * @private + */ + +/** + * @type {WeakMap<object, Map<string, ListenerNode>>} + * @private + */ +const listenersMap = new WeakMap(); + +// Listener types +const CAPTURE = 1; +const BUBBLE = 2; +const ATTRIBUTE = 3; + +/** + * Check whether a given value is an object or not. + * @param {any} x The value to check. + * @returns {boolean} `true` if the value is an object. + */ +function isObject(x) { + return x !== null && typeof x === "object" //eslint-disable-line no-restricted-syntax +} + +/** + * Get listeners. + * @param {EventTarget} eventTarget The event target to get. + * @returns {Map<string, ListenerNode>} The listeners. + * @private + */ +function getListeners(eventTarget) { + const listeners = listenersMap.get(eventTarget); + if (listeners == null) { + throw new TypeError( + "'this' is expected an EventTarget object, but got another value." + ) + } + return listeners +} + +/** + * Get the property descriptor for the event attribute of a given event. + * @param {string} eventName The event name to get property descriptor. + * @returns {PropertyDescriptor} The property descriptor. + * @private + */ +function defineEventAttributeDescriptor(eventName) { + return { + get() { + const listeners = getListeners(this); + let node = listeners.get(eventName); + while (node != null) { + if (node.listenerType === ATTRIBUTE) { + return node.listener + } + node = node.next; + } + return null + }, + + set(listener) { + if (typeof listener !== "function" && !isObject(listener)) { + listener = null; // eslint-disable-line no-param-reassign + } + const listeners = getListeners(this); + + // Traverse to the tail while removing old value. + let prev = null; + let node = listeners.get(eventName); + while (node != null) { + if (node.listenerType === ATTRIBUTE) { + // Remove old value. + if (prev !== null) { + prev.next = node.next; + } else if (node.next !== null) { + listeners.set(eventName, node.next); + } else { + listeners.delete(eventName); + } + } else { + prev = node; + } + + node = node.next; + } + + // Add new value. + if (listener !== null) { + const newNode = { + listener, + listenerType: ATTRIBUTE, + passive: false, + once: false, + next: null, + }; + if (prev === null) { + listeners.set(eventName, newNode); + } else { + prev.next = newNode; + } + } + }, + configurable: true, + enumerable: true, + } +} + +/** + * Define an event attribute (e.g. `eventTarget.onclick`). + * @param {Object} eventTargetPrototype The event target prototype to define an event attrbite. + * @param {string} eventName The event name to define. + * @returns {void} + */ +function defineEventAttribute(eventTargetPrototype, eventName) { + Object.defineProperty( + eventTargetPrototype, + `on${eventName}`, + defineEventAttributeDescriptor(eventName) + ); +} + +/** + * Define a custom EventTarget with event attributes. + * @param {string[]} eventNames Event names for event attributes. + * @returns {EventTarget} The custom EventTarget. + * @private + */ +function defineCustomEventTarget(eventNames) { + /** CustomEventTarget */ + function CustomEventTarget() { + EventTarget.call(this); + } + + CustomEventTarget.prototype = Object.create(EventTarget.prototype, { + constructor: { + value: CustomEventTarget, + configurable: true, + writable: true, + }, + }); + + for (let i = 0; i < eventNames.length; ++i) { + defineEventAttribute(CustomEventTarget.prototype, eventNames[i]); + } + + return CustomEventTarget +} + +/** + * EventTarget. + * + * - This is constructor if no arguments. + * - This is a function which returns a CustomEventTarget constructor if there are arguments. + * + * For example: + * + * class A extends EventTarget {} + * class B extends EventTarget("message") {} + * class C extends EventTarget("message", "error") {} + * class D extends EventTarget(["message", "error"]) {} + */ +function EventTarget() { + /*eslint-disable consistent-return */ + if (this instanceof EventTarget) { + listenersMap.set(this, new Map()); + return + } + if (arguments.length === 1 && Array.isArray(arguments[0])) { + return defineCustomEventTarget(arguments[0]) + } + if (arguments.length > 0) { + const types = new Array(arguments.length); + for (let i = 0; i < arguments.length; ++i) { + types[i] = arguments[i]; + } + return defineCustomEventTarget(types) + } + throw new TypeError("Cannot call a class as a function") + /*eslint-enable consistent-return */ +} + +// Should be enumerable, but class methods are not enumerable. +EventTarget.prototype = { + /** + * Add a given listener to this event target. + * @param {string} eventName The event name to add. + * @param {Function} listener The listener to add. + * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener. + * @returns {void} + */ + addEventListener(eventName, listener, options) { + if (listener == null) { + return + } + if (typeof listener !== "function" && !isObject(listener)) { + throw new TypeError("'listener' should be a function or an object.") + } + + const listeners = getListeners(this); + const optionsIsObj = isObject(options); + const capture = optionsIsObj + ? Boolean(options.capture) + : Boolean(options); + const listenerType = capture ? CAPTURE : BUBBLE; + const newNode = { + listener, + listenerType, + passive: optionsIsObj && Boolean(options.passive), + once: optionsIsObj && Boolean(options.once), + next: null, + }; + + // Set it as the first node if the first node is null. + let node = listeners.get(eventName); + if (node === undefined) { + listeners.set(eventName, newNode); + return + } + + // Traverse to the tail while checking duplication.. + let prev = null; + while (node != null) { + if ( + node.listener === listener && + node.listenerType === listenerType + ) { + // Should ignore duplication. + return + } + prev = node; + node = node.next; + } + + // Add it. + prev.next = newNode; + }, + + /** + * Remove a given listener from this event target. + * @param {string} eventName The event name to remove. + * @param {Function} listener The listener to remove. + * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener. + * @returns {void} + */ + removeEventListener(eventName, listener, options) { + if (listener == null) { + return + } + + const listeners = getListeners(this); + const capture = isObject(options) + ? Boolean(options.capture) + : Boolean(options); + const listenerType = capture ? CAPTURE : BUBBLE; + + let prev = null; + let node = listeners.get(eventName); + while (node != null) { + if ( + node.listener === listener && + node.listenerType === listenerType + ) { + if (prev !== null) { + prev.next = node.next; + } else if (node.next !== null) { + listeners.set(eventName, node.next); + } else { + listeners.delete(eventName); + } + return + } + + prev = node; + node = node.next; + } + }, + + /** + * Dispatch a given event. + * @param {Event|{type:string}} event The event to dispatch. + * @returns {boolean} `false` if canceled. + */ + dispatchEvent(event) { + if (event == null || typeof event.type !== "string") { + throw new TypeError('"event.type" should be a string.') + } + + // If listeners aren't registered, terminate. + const listeners = getListeners(this); + const eventName = event.type; + let node = listeners.get(eventName); + if (node == null) { + return true + } + + // Since we cannot rewrite several properties, so wrap object. + const wrappedEvent = wrapEvent(this, event); + + // This doesn't process capturing phase and bubbling phase. + // This isn't participating in a tree. + let prev = null; + while (node != null) { + // Remove this listener if it's once + if (node.once) { + if (prev !== null) { + prev.next = node.next; + } else if (node.next !== null) { + listeners.set(eventName, node.next); + } else { + listeners.delete(eventName); + } + } else { + prev = node; + } + + // Call this listener + setPassiveListener( + wrappedEvent, + node.passive ? node.listener : null + ); + if (typeof node.listener === "function") { + try { + node.listener.call(this, wrappedEvent); + } catch (err) { + if ( + typeof console !== "undefined" && + typeof console.error === "function" + ) { + console.error(err); + } + } + } else if ( + node.listenerType !== ATTRIBUTE && + typeof node.listener.handleEvent === "function" + ) { + node.listener.handleEvent(wrappedEvent); + } + + // Break if `event.stopImmediatePropagation` was called. + if (isStopped(wrappedEvent)) { + break + } + + node = node.next; + } + setPassiveListener(wrappedEvent, null); + setEventPhase(wrappedEvent, 0); + setCurrentTarget(wrappedEvent, null); + + return !wrappedEvent.defaultPrevented + }, +}; + +// `constructor` is not enumerable. +Object.defineProperty(EventTarget.prototype, "constructor", { + value: EventTarget, + configurable: true, + writable: true, +}); + +// Ensure `eventTarget instanceof window.EventTarget` is `true`. +if ( + typeof window !== "undefined" && + typeof window.EventTarget !== "undefined" +) { + Object.setPrototypeOf(EventTarget.prototype, window.EventTarget.prototype); +} + +exports.defineEventAttribute = defineEventAttribute; +exports.EventTarget = EventTarget; +exports.default = EventTarget; + +module.exports = EventTarget +module.exports.EventTarget = module.exports["default"] = EventTarget +module.exports.defineEventAttribute = defineEventAttribute +//# sourceMappingURL=event-target-shim.js.map diff --git a/node_modules/event-target-shim/dist/event-target-shim.js.map b/node_modules/event-target-shim/dist/event-target-shim.js.map new file mode 100644 index 0000000..83c5f62 --- /dev/null +++ b/node_modules/event-target-shim/dist/event-target-shim.js.map @@ -0,0 +1 @@ +{"version":3,"file":"event-target-shim.js","sources":["../src/event.mjs","../src/event-target.mjs"],"sourcesContent":["/**\n * @typedef {object} PrivateData\n * @property {EventTarget} eventTarget The event target.\n * @property {{type:string}} event The original event object.\n * @property {number} eventPhase The current event phase.\n * @property {EventTarget|null} currentTarget The current event target.\n * @property {boolean} canceled The flag to prevent default.\n * @property {boolean} stopped The flag to stop propagation.\n * @property {boolean} immediateStopped The flag to stop propagation immediately.\n * @property {Function|null} passiveListener The listener if the current listener is passive. Otherwise this is null.\n * @property {number} timeStamp The unix time.\n * @private\n */\n\n/**\n * Private data for event wrappers.\n * @type {WeakMap<Event, PrivateData>}\n * @private\n */\nconst privateData = new WeakMap()\n\n/**\n * Cache for wrapper classes.\n * @type {WeakMap<Object, Function>}\n * @private\n */\nconst wrappers = new WeakMap()\n\n/**\n * Get private data.\n * @param {Event} event The event object to get private data.\n * @returns {PrivateData} The private data of the event.\n * @private\n */\nfunction pd(event) {\n const retv = privateData.get(event)\n console.assert(\n retv != null,\n \"'this' is expected an Event object, but got\",\n event\n )\n return retv\n}\n\n/**\n * https://dom.spec.whatwg.org/#set-the-canceled-flag\n * @param data {PrivateData} private data.\n */\nfunction setCancelFlag(data) {\n if (data.passiveListener != null) {\n if (\n typeof console !== \"undefined\" &&\n typeof console.error === \"function\"\n ) {\n console.error(\n \"Unable to preventDefault inside passive event listener invocation.\",\n data.passiveListener\n )\n }\n return\n }\n if (!data.event.cancelable) {\n return\n }\n\n data.canceled = true\n if (typeof data.event.preventDefault === \"function\") {\n data.event.preventDefault()\n }\n}\n\n/**\n * @see https://dom.spec.whatwg.org/#interface-event\n * @private\n */\n/**\n * The event wrapper.\n * @constructor\n * @param {EventTarget} eventTarget The event target of this dispatching.\n * @param {Event|{type:string}} event The original event to wrap.\n */\nfunction Event(eventTarget, event) {\n privateData.set(this, {\n eventTarget,\n event,\n eventPhase: 2,\n currentTarget: eventTarget,\n canceled: false,\n stopped: false,\n immediateStopped: false,\n passiveListener: null,\n timeStamp: event.timeStamp || Date.now(),\n })\n\n // https://heycam.github.io/webidl/#Unforgeable\n Object.defineProperty(this, \"isTrusted\", { value: false, enumerable: true })\n\n // Define accessors\n const keys = Object.keys(event)\n for (let i = 0; i < keys.length; ++i) {\n const key = keys[i]\n if (!(key in this)) {\n Object.defineProperty(this, key, defineRedirectDescriptor(key))\n }\n }\n}\n\n// Should be enumerable, but class methods are not enumerable.\nEvent.prototype = {\n /**\n * The type of this event.\n * @type {string}\n */\n get type() {\n return pd(this).event.type\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n */\n get target() {\n return pd(this).eventTarget\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n */\n get currentTarget() {\n return pd(this).currentTarget\n },\n\n /**\n * @returns {EventTarget[]} The composed path of this event.\n */\n composedPath() {\n const currentTarget = pd(this).currentTarget\n if (currentTarget == null) {\n return []\n }\n return [currentTarget]\n },\n\n /**\n * Constant of NONE.\n * @type {number}\n */\n get NONE() {\n return 0\n },\n\n /**\n * Constant of CAPTURING_PHASE.\n * @type {number}\n */\n get CAPTURING_PHASE() {\n return 1\n },\n\n /**\n * Constant of AT_TARGET.\n * @type {number}\n */\n get AT_TARGET() {\n return 2\n },\n\n /**\n * Constant of BUBBLING_PHASE.\n * @type {number}\n */\n get BUBBLING_PHASE() {\n return 3\n },\n\n /**\n * The target of this event.\n * @type {number}\n */\n get eventPhase() {\n return pd(this).eventPhase\n },\n\n /**\n * Stop event bubbling.\n * @returns {void}\n */\n stopPropagation() {\n const data = pd(this)\n\n data.stopped = true\n if (typeof data.event.stopPropagation === \"function\") {\n data.event.stopPropagation()\n }\n },\n\n /**\n * Stop event bubbling.\n * @returns {void}\n */\n stopImmediatePropagation() {\n const data = pd(this)\n\n data.stopped = true\n data.immediateStopped = true\n if (typeof data.event.stopImmediatePropagation === \"function\") {\n data.event.stopImmediatePropagation()\n }\n },\n\n /**\n * The flag to be bubbling.\n * @type {boolean}\n */\n get bubbles() {\n return Boolean(pd(this).event.bubbles)\n },\n\n /**\n * The flag to be cancelable.\n * @type {boolean}\n */\n get cancelable() {\n return Boolean(pd(this).event.cancelable)\n },\n\n /**\n * Cancel this event.\n * @returns {void}\n */\n preventDefault() {\n setCancelFlag(pd(this))\n },\n\n /**\n * The flag to indicate cancellation state.\n * @type {boolean}\n */\n get defaultPrevented() {\n return pd(this).canceled\n },\n\n /**\n * The flag to be composed.\n * @type {boolean}\n */\n get composed() {\n return Boolean(pd(this).event.composed)\n },\n\n /**\n * The unix time of this event.\n * @type {number}\n */\n get timeStamp() {\n return pd(this).timeStamp\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n * @deprecated\n */\n get srcElement() {\n return pd(this).eventTarget\n },\n\n /**\n * The flag to stop event bubbling.\n * @type {boolean}\n * @deprecated\n */\n get cancelBubble() {\n return pd(this).stopped\n },\n set cancelBubble(value) {\n if (!value) {\n return\n }\n const data = pd(this)\n\n data.stopped = true\n if (typeof data.event.cancelBubble === \"boolean\") {\n data.event.cancelBubble = true\n }\n },\n\n /**\n * The flag to indicate cancellation state.\n * @type {boolean}\n * @deprecated\n */\n get returnValue() {\n return !pd(this).canceled\n },\n set returnValue(value) {\n if (!value) {\n setCancelFlag(pd(this))\n }\n },\n\n /**\n * Initialize this event object. But do nothing under event dispatching.\n * @param {string} type The event type.\n * @param {boolean} [bubbles=false] The flag to be possible to bubble up.\n * @param {boolean} [cancelable=false] The flag to be possible to cancel.\n * @deprecated\n */\n initEvent() {\n // Do nothing.\n },\n}\n\n// `constructor` is not enumerable.\nObject.defineProperty(Event.prototype, \"constructor\", {\n value: Event,\n configurable: true,\n writable: true,\n})\n\n// Ensure `event instanceof window.Event` is `true`.\nif (typeof window !== \"undefined\" && typeof window.Event !== \"undefined\") {\n Object.setPrototypeOf(Event.prototype, window.Event.prototype)\n\n // Make association for wrappers.\n wrappers.set(window.Event.prototype, Event)\n}\n\n/**\n * Get the property descriptor to redirect a given property.\n * @param {string} key Property name to define property descriptor.\n * @returns {PropertyDescriptor} The property descriptor to redirect the property.\n * @private\n */\nfunction defineRedirectDescriptor(key) {\n return {\n get() {\n return pd(this).event[key]\n },\n set(value) {\n pd(this).event[key] = value\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Get the property descriptor to call a given method property.\n * @param {string} key Property name to define property descriptor.\n * @returns {PropertyDescriptor} The property descriptor to call the method property.\n * @private\n */\nfunction defineCallDescriptor(key) {\n return {\n value() {\n const event = pd(this).event\n return event[key].apply(event, arguments)\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Define new wrapper class.\n * @param {Function} BaseEvent The base wrapper class.\n * @param {Object} proto The prototype of the original event.\n * @returns {Function} The defined wrapper class.\n * @private\n */\nfunction defineWrapper(BaseEvent, proto) {\n const keys = Object.keys(proto)\n if (keys.length === 0) {\n return BaseEvent\n }\n\n /** CustomEvent */\n function CustomEvent(eventTarget, event) {\n BaseEvent.call(this, eventTarget, event)\n }\n\n CustomEvent.prototype = Object.create(BaseEvent.prototype, {\n constructor: { value: CustomEvent, configurable: true, writable: true },\n })\n\n // Define accessors.\n for (let i = 0; i < keys.length; ++i) {\n const key = keys[i]\n if (!(key in BaseEvent.prototype)) {\n const descriptor = Object.getOwnPropertyDescriptor(proto, key)\n const isFunc = typeof descriptor.value === \"function\"\n Object.defineProperty(\n CustomEvent.prototype,\n key,\n isFunc\n ? defineCallDescriptor(key)\n : defineRedirectDescriptor(key)\n )\n }\n }\n\n return CustomEvent\n}\n\n/**\n * Get the wrapper class of a given prototype.\n * @param {Object} proto The prototype of the original event to get its wrapper.\n * @returns {Function} The wrapper class.\n * @private\n */\nfunction getWrapper(proto) {\n if (proto == null || proto === Object.prototype) {\n return Event\n }\n\n let wrapper = wrappers.get(proto)\n if (wrapper == null) {\n wrapper = defineWrapper(getWrapper(Object.getPrototypeOf(proto)), proto)\n wrappers.set(proto, wrapper)\n }\n return wrapper\n}\n\n/**\n * Wrap a given event to management a dispatching.\n * @param {EventTarget} eventTarget The event target of this dispatching.\n * @param {Object} event The event to wrap.\n * @returns {Event} The wrapper instance.\n * @private\n */\nexport function wrapEvent(eventTarget, event) {\n const Wrapper = getWrapper(Object.getPrototypeOf(event))\n return new Wrapper(eventTarget, event)\n}\n\n/**\n * Get the immediateStopped flag of a given event.\n * @param {Event} event The event to get.\n * @returns {boolean} The flag to stop propagation immediately.\n * @private\n */\nexport function isStopped(event) {\n return pd(event).immediateStopped\n}\n\n/**\n * Set the current event phase of a given event.\n * @param {Event} event The event to set current target.\n * @param {number} eventPhase New event phase.\n * @returns {void}\n * @private\n */\nexport function setEventPhase(event, eventPhase) {\n pd(event).eventPhase = eventPhase\n}\n\n/**\n * Set the current target of a given event.\n * @param {Event} event The event to set current target.\n * @param {EventTarget|null} currentTarget New current target.\n * @returns {void}\n * @private\n */\nexport function setCurrentTarget(event, currentTarget) {\n pd(event).currentTarget = currentTarget\n}\n\n/**\n * Set a passive listener of a given event.\n * @param {Event} event The event to set current target.\n * @param {Function|null} passiveListener New passive listener.\n * @returns {void}\n * @private\n */\nexport function setPassiveListener(event, passiveListener) {\n pd(event).passiveListener = passiveListener\n}\n","import {\n isStopped,\n setCurrentTarget,\n setEventPhase,\n setPassiveListener,\n wrapEvent,\n} from \"./event.mjs\"\n\n/**\n * @typedef {object} ListenerNode\n * @property {Function} listener\n * @property {1|2|3} listenerType\n * @property {boolean} passive\n * @property {boolean} once\n * @property {ListenerNode|null} next\n * @private\n */\n\n/**\n * @type {WeakMap<object, Map<string, ListenerNode>>}\n * @private\n */\nconst listenersMap = new WeakMap()\n\n// Listener types\nconst CAPTURE = 1\nconst BUBBLE = 2\nconst ATTRIBUTE = 3\n\n/**\n * Check whether a given value is an object or not.\n * @param {any} x The value to check.\n * @returns {boolean} `true` if the value is an object.\n */\nfunction isObject(x) {\n return x !== null && typeof x === \"object\" //eslint-disable-line no-restricted-syntax\n}\n\n/**\n * Get listeners.\n * @param {EventTarget} eventTarget The event target to get.\n * @returns {Map<string, ListenerNode>} The listeners.\n * @private\n */\nfunction getListeners(eventTarget) {\n const listeners = listenersMap.get(eventTarget)\n if (listeners == null) {\n throw new TypeError(\n \"'this' is expected an EventTarget object, but got another value.\"\n )\n }\n return listeners\n}\n\n/**\n * Get the property descriptor for the event attribute of a given event.\n * @param {string} eventName The event name to get property descriptor.\n * @returns {PropertyDescriptor} The property descriptor.\n * @private\n */\nfunction defineEventAttributeDescriptor(eventName) {\n return {\n get() {\n const listeners = getListeners(this)\n let node = listeners.get(eventName)\n while (node != null) {\n if (node.listenerType === ATTRIBUTE) {\n return node.listener\n }\n node = node.next\n }\n return null\n },\n\n set(listener) {\n if (typeof listener !== \"function\" && !isObject(listener)) {\n listener = null // eslint-disable-line no-param-reassign\n }\n const listeners = getListeners(this)\n\n // Traverse to the tail while removing old value.\n let prev = null\n let node = listeners.get(eventName)\n while (node != null) {\n if (node.listenerType === ATTRIBUTE) {\n // Remove old value.\n if (prev !== null) {\n prev.next = node.next\n } else if (node.next !== null) {\n listeners.set(eventName, node.next)\n } else {\n listeners.delete(eventName)\n }\n } else {\n prev = node\n }\n\n node = node.next\n }\n\n // Add new value.\n if (listener !== null) {\n const newNode = {\n listener,\n listenerType: ATTRIBUTE,\n passive: false,\n once: false,\n next: null,\n }\n if (prev === null) {\n listeners.set(eventName, newNode)\n } else {\n prev.next = newNode\n }\n }\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Define an event attribute (e.g. `eventTarget.onclick`).\n * @param {Object} eventTargetPrototype The event target prototype to define an event attrbite.\n * @param {string} eventName The event name to define.\n * @returns {void}\n */\nfunction defineEventAttribute(eventTargetPrototype, eventName) {\n Object.defineProperty(\n eventTargetPrototype,\n `on${eventName}`,\n defineEventAttributeDescriptor(eventName)\n )\n}\n\n/**\n * Define a custom EventTarget with event attributes.\n * @param {string[]} eventNames Event names for event attributes.\n * @returns {EventTarget} The custom EventTarget.\n * @private\n */\nfunction defineCustomEventTarget(eventNames) {\n /** CustomEventTarget */\n function CustomEventTarget() {\n EventTarget.call(this)\n }\n\n CustomEventTarget.prototype = Object.create(EventTarget.prototype, {\n constructor: {\n value: CustomEventTarget,\n configurable: true,\n writable: true,\n },\n })\n\n for (let i = 0; i < eventNames.length; ++i) {\n defineEventAttribute(CustomEventTarget.prototype, eventNames[i])\n }\n\n return CustomEventTarget\n}\n\n/**\n * EventTarget.\n *\n * - This is constructor if no arguments.\n * - This is a function which returns a CustomEventTarget constructor if there are arguments.\n *\n * For example:\n *\n * class A extends EventTarget {}\n * class B extends EventTarget(\"message\") {}\n * class C extends EventTarget(\"message\", \"error\") {}\n * class D extends EventTarget([\"message\", \"error\"]) {}\n */\nfunction EventTarget() {\n /*eslint-disable consistent-return */\n if (this instanceof EventTarget) {\n listenersMap.set(this, new Map())\n return\n }\n if (arguments.length === 1 && Array.isArray(arguments[0])) {\n return defineCustomEventTarget(arguments[0])\n }\n if (arguments.length > 0) {\n const types = new Array(arguments.length)\n for (let i = 0; i < arguments.length; ++i) {\n types[i] = arguments[i]\n }\n return defineCustomEventTarget(types)\n }\n throw new TypeError(\"Cannot call a class as a function\")\n /*eslint-enable consistent-return */\n}\n\n// Should be enumerable, but class methods are not enumerable.\nEventTarget.prototype = {\n /**\n * Add a given listener to this event target.\n * @param {string} eventName The event name to add.\n * @param {Function} listener The listener to add.\n * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener.\n * @returns {void}\n */\n addEventListener(eventName, listener, options) {\n if (listener == null) {\n return\n }\n if (typeof listener !== \"function\" && !isObject(listener)) {\n throw new TypeError(\"'listener' should be a function or an object.\")\n }\n\n const listeners = getListeners(this)\n const optionsIsObj = isObject(options)\n const capture = optionsIsObj\n ? Boolean(options.capture)\n : Boolean(options)\n const listenerType = capture ? CAPTURE : BUBBLE\n const newNode = {\n listener,\n listenerType,\n passive: optionsIsObj && Boolean(options.passive),\n once: optionsIsObj && Boolean(options.once),\n next: null,\n }\n\n // Set it as the first node if the first node is null.\n let node = listeners.get(eventName)\n if (node === undefined) {\n listeners.set(eventName, newNode)\n return\n }\n\n // Traverse to the tail while checking duplication..\n let prev = null\n while (node != null) {\n if (\n node.listener === listener &&\n node.listenerType === listenerType\n ) {\n // Should ignore duplication.\n return\n }\n prev = node\n node = node.next\n }\n\n // Add it.\n prev.next = newNode\n },\n\n /**\n * Remove a given listener from this event target.\n * @param {string} eventName The event name to remove.\n * @param {Function} listener The listener to remove.\n * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener.\n * @returns {void}\n */\n removeEventListener(eventName, listener, options) {\n if (listener == null) {\n return\n }\n\n const listeners = getListeners(this)\n const capture = isObject(options)\n ? Boolean(options.capture)\n : Boolean(options)\n const listenerType = capture ? CAPTURE : BUBBLE\n\n let prev = null\n let node = listeners.get(eventName)\n while (node != null) {\n if (\n node.listener === listener &&\n node.listenerType === listenerType\n ) {\n if (prev !== null) {\n prev.next = node.next\n } else if (node.next !== null) {\n listeners.set(eventName, node.next)\n } else {\n listeners.delete(eventName)\n }\n return\n }\n\n prev = node\n node = node.next\n }\n },\n\n /**\n * Dispatch a given event.\n * @param {Event|{type:string}} event The event to dispatch.\n * @returns {boolean} `false` if canceled.\n */\n dispatchEvent(event) {\n if (event == null || typeof event.type !== \"string\") {\n throw new TypeError('\"event.type\" should be a string.')\n }\n\n // If listeners aren't registered, terminate.\n const listeners = getListeners(this)\n const eventName = event.type\n let node = listeners.get(eventName)\n if (node == null) {\n return true\n }\n\n // Since we cannot rewrite several properties, so wrap object.\n const wrappedEvent = wrapEvent(this, event)\n\n // This doesn't process capturing phase and bubbling phase.\n // This isn't participating in a tree.\n let prev = null\n while (node != null) {\n // Remove this listener if it's once\n if (node.once) {\n if (prev !== null) {\n prev.next = node.next\n } else if (node.next !== null) {\n listeners.set(eventName, node.next)\n } else {\n listeners.delete(eventName)\n }\n } else {\n prev = node\n }\n\n // Call this listener\n setPassiveListener(\n wrappedEvent,\n node.passive ? node.listener : null\n )\n if (typeof node.listener === \"function\") {\n try {\n node.listener.call(this, wrappedEvent)\n } catch (err) {\n if (\n typeof console !== \"undefined\" &&\n typeof console.error === \"function\"\n ) {\n console.error(err)\n }\n }\n } else if (\n node.listenerType !== ATTRIBUTE &&\n typeof node.listener.handleEvent === \"function\"\n ) {\n node.listener.handleEvent(wrappedEvent)\n }\n\n // Break if `event.stopImmediatePropagation` was called.\n if (isStopped(wrappedEvent)) {\n break\n }\n\n node = node.next\n }\n setPassiveListener(wrappedEvent, null)\n setEventPhase(wrappedEvent, 0)\n setCurrentTarget(wrappedEvent, null)\n\n return !wrappedEvent.defaultPrevented\n },\n}\n\n// `constructor` is not enumerable.\nObject.defineProperty(EventTarget.prototype, \"constructor\", {\n value: EventTarget,\n configurable: true,\n writable: true,\n})\n\n// Ensure `eventTarget instanceof window.EventTarget` is `true`.\nif (\n typeof window !== \"undefined\" &&\n typeof window.EventTarget !== \"undefined\"\n) {\n Object.setPrototypeOf(EventTarget.prototype, window.EventTarget.prototype)\n}\n\nexport { defineEventAttribute, EventTarget }\nexport default EventTarget\n"],"names":[],"mappings":";;;;;;;;;AAAA;;;;;;;;;;;;;;;;;;;AAmBA,MAAM,WAAW,GAAG,IAAI,OAAO,GAAE;;;;;;;AAOjC,MAAM,QAAQ,GAAG,IAAI,OAAO,GAAE;;;;;;;;AAQ9B,SAAS,EAAE,CAAC,KAAK,EAAE;IACf,MAAM,IAAI,GAAG,WAAW,CAAC,GAAG,CAAC,KAAK,EAAC;IACnC,OAAO,CAAC,MAAM;QACV,IAAI,IAAI,IAAI;QACZ,6CAA6C;QAC7C,KAAK;MACR;IACD,OAAO,IAAI;CACd;;;;;;AAMD,SAAS,aAAa,CAAC,IAAI,EAAE;IACzB,IAAI,IAAI,CAAC,eAAe,IAAI,IAAI,EAAE;QAC9B;YACI,OAAO,OAAO,KAAK,WAAW;YAC9B,OAAO,OAAO,CAAC,KAAK,KAAK,UAAU;UACrC;YACE,OAAO,CAAC,KAAK;gBACT,oEAAoE;gBACpE,IAAI,CAAC,eAAe;cACvB;SACJ;QACD,MAAM;KACT;IACD,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,UAAU,EAAE;QACxB,MAAM;KACT;;IAED,IAAI,CAAC,QAAQ,GAAG,KAAI;IACpB,IAAI,OAAO,IAAI,CAAC,KAAK,CAAC,cAAc,KAAK,UAAU,EAAE;QACjD,IAAI,CAAC,KAAK,CAAC,cAAc,GAAE;KAC9B;CACJ;;;;;;;;;;;;AAYD,SAAS,KAAK,CAAC,WAAW,EAAE,KAAK,EAAE;IAC/B,WAAW,CAAC,GAAG,CAAC,IAAI,EAAE;QAClB,WAAW;QACX,KAAK;QACL,UAAU,EAAE,CAAC;QACb,aAAa,EAAE,WAAW;QAC1B,QAAQ,EAAE,KAAK;QACf,OAAO,EAAE,KAAK;QACd,gBAAgB,EAAE,KAAK;QACvB,eAAe,EAAE,IAAI;QACrB,SAAS,EAAE,KAAK,CAAC,SAAS,IAAI,IAAI,CAAC,GAAG,EAAE;KAC3C,EAAC;;;IAGF,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,WAAW,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE,EAAC;;;IAG5E,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC,KAAK,EAAC;IAC/B,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,MAAM,EAAE,EAAE,CAAC,EAAE;QAClC,MAAM,GAAG,GAAG,IAAI,CAAC,CAAC,EAAC;QACnB,IAAI,EAAE,GAAG,IAAI,IAAI,CAAC,EAAE;YAChB,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,GAAG,EAAE,wBAAwB,CAAC,GAAG,CAAC,EAAC;SAClE;KACJ;CACJ;;;AAGD,KAAK,CAAC,SAAS,GAAG;;;;;IAKd,IAAI,IAAI,GAAG;QACP,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,IAAI;KAC7B;;;;;;IAMD,IAAI,MAAM,GAAG;QACT,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,WAAW;KAC9B;;;;;;IAMD,IAAI,aAAa,GAAG;QAChB,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,aAAa;KAChC;;;;;IAKD,YAAY,GAAG;QACX,MAAM,aAAa,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC,cAAa;QAC5C,IAAI,aAAa,IAAI,IAAI,EAAE;YACvB,OAAO,EAAE;SACZ;QACD,OAAO,CAAC,aAAa,CAAC;KACzB;;;;;;IAMD,IAAI,IAAI,GAAG;QACP,OAAO,CAAC;KACX;;;;;;IAMD,IAAI,eAAe,GAAG;QAClB,OAAO,CAAC;KACX;;;;;;IAMD,IAAI,SAAS,GAAG;QACZ,OAAO,CAAC;KACX;;;;;;IAMD,IAAI,cAAc,GAAG;QACjB,OAAO,CAAC;KACX;;;;;;IAMD,IAAI,UAAU,GAAG;QACb,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,UAAU;KAC7B;;;;;;IAMD,eAAe,GAAG;QACd,MAAM,IAAI,GAAG,EAAE,CAAC,IAAI,EAAC;;QAErB,IAAI,CAAC,OAAO,GAAG,KAAI;QACnB,IAAI,OAAO,IAAI,CAAC,KAAK,CAAC,eAAe,KAAK,UAAU,EAAE;YAClD,IAAI,CAAC,KAAK,CAAC,eAAe,GAAE;SAC/B;KACJ;;;;;;IAMD,wBAAwB,GAAG;QACvB,MAAM,IAAI,GAAG,EAAE,CAAC,IAAI,EAAC;;QAErB,IAAI,CAAC,OAAO,GAAG,KAAI;QACnB,IAAI,CAAC,gBAAgB,GAAG,KAAI;QAC5B,IAAI,OAAO,IAAI,CAAC,KAAK,CAAC,wBAAwB,KAAK,UAAU,EAAE;YAC3D,IAAI,CAAC,KAAK,CAAC,wBAAwB,GAAE;SACxC;KACJ;;;;;;IAMD,IAAI,OAAO,GAAG;QACV,OAAO,OAAO,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC;KACzC;;;;;;IAMD,IAAI,UAAU,GAAG;QACb,OAAO,OAAO,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,UAAU,CAAC;KAC5C;;;;;;IAMD,cAAc,GAAG;QACb,aAAa,CAAC,EAAE,CAAC,IAAI,CAAC,EAAC;KAC1B;;;;;;IAMD,IAAI,gBAAgB,GAAG;QACnB,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,QAAQ;KAC3B;;;;;;IAMD,IAAI,QAAQ,GAAG;QACX,OAAO,OAAO,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,QAAQ,CAAC;KAC1C;;;;;;IAMD,IAAI,SAAS,GAAG;QACZ,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,SAAS;KAC5B;;;;;;;IAOD,IAAI,UAAU,GAAG;QACb,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,WAAW;KAC9B;;;;;;;IAOD,IAAI,YAAY,GAAG;QACf,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,OAAO;KAC1B;IACD,IAAI,YAAY,CAAC,KAAK,EAAE;QACpB,IAAI,CAAC,KAAK,EAAE;YACR,MAAM;SACT;QACD,MAAM,IAAI,GAAG,EAAE,CAAC,IAAI,EAAC;;QAErB,IAAI,CAAC,OAAO,GAAG,KAAI;QACnB,IAAI,OAAO,IAAI,CAAC,KAAK,CAAC,YAAY,KAAK,SAAS,EAAE;YAC9C,IAAI,CAAC,KAAK,CAAC,YAAY,GAAG,KAAI;SACjC;KACJ;;;;;;;IAOD,IAAI,WAAW,GAAG;QACd,OAAO,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,QAAQ;KAC5B;IACD,IAAI,WAAW,CAAC,KAAK,EAAE;QACnB,IAAI,CAAC,KAAK,EAAE;YACR,aAAa,CAAC,EAAE,CAAC,IAAI,CAAC,EAAC;SAC1B;KACJ;;;;;;;;;IASD,SAAS,GAAG;;KAEX;EACJ;;;AAGD,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,SAAS,EAAE,aAAa,EAAE;IAClD,KAAK,EAAE,KAAK;IACZ,YAAY,EAAE,IAAI;IAClB,QAAQ,EAAE,IAAI;CACjB,EAAC;;;AAGF,IAAI,OAAO,MAAM,KAAK,WAAW,IAAI,OAAO,MAAM,CAAC,KAAK,KAAK,WAAW,EAAE;IACtE,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,SAAS,EAAE,MAAM,CAAC,KAAK,CAAC,SAAS,EAAC;;;IAG9D,QAAQ,CAAC,GAAG,CAAC,MAAM,CAAC,KAAK,CAAC,SAAS,EAAE,KAAK,EAAC;CAC9C;;;;;;;;AAQD,SAAS,wBAAwB,CAAC,GAAG,EAAE;IACnC,OAAO;QACH,GAAG,GAAG;YACF,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC;SAC7B;QACD,GAAG,CAAC,KAAK,EAAE;YACP,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,MAAK;SAC9B;QACD,YAAY,EAAE,IAAI;QAClB,UAAU,EAAE,IAAI;KACnB;CACJ;;;;;;;;AAQD,SAAS,oBAAoB,CAAC,GAAG,EAAE;IAC/B,OAAO;QACH,KAAK,GAAG;YACJ,MAAM,KAAK,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC,MAAK;YAC5B,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,KAAK,EAAE,SAAS,CAAC;SAC5C;QACD,YAAY,EAAE,IAAI;QAClB,UAAU,EAAE,IAAI;KACnB;CACJ;;;;;;;;;AASD,SAAS,aAAa,CAAC,SAAS,EAAE,KAAK,EAAE;IACrC,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC,KAAK,EAAC;IAC/B,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE;QACnB,OAAO,SAAS;KACnB;;;IAGD,SAAS,WAAW,CAAC,WAAW,EAAE,KAAK,EAAE;QACrC,SAAS,CAAC,IAAI,CAAC,IAAI,EAAE,WAAW,EAAE,KAAK,EAAC;KAC3C;;IAED,WAAW,CAAC,SAAS,GAAG,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,SAAS,EAAE;QACvD,WAAW,EAAE,EAAE,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE;KAC1E,EAAC;;;IAGF,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,MAAM,EAAE,EAAE,CAAC,EAAE;QAClC,MAAM,GAAG,GAAG,IAAI,CAAC,CAAC,EAAC;QACnB,IAAI,EAAE,GAAG,IAAI,SAAS,CAAC,SAAS,CAAC,EAAE;YAC/B,MAAM,UAAU,GAAG,MAAM,CAAC,wBAAwB,CAAC,KAAK,EAAE,GAAG,EAAC;YAC9D,MAAM,MAAM,GAAG,OAAO,UAAU,CAAC,KAAK,KAAK,WAAU;YACrD,MAAM,CAAC,cAAc;gBACjB,WAAW,CAAC,SAAS;gBACrB,GAAG;gBACH,MAAM;sBACA,oBAAoB,CAAC,GAAG,CAAC;sBACzB,wBAAwB,CAAC,GAAG,CAAC;cACtC;SACJ;KACJ;;IAED,OAAO,WAAW;CACrB;;;;;;;;AAQD,SAAS,UAAU,CAAC,KAAK,EAAE;IACvB,IAAI,KAAK,IAAI,IAAI,IAAI,KAAK,KAAK,MAAM,CAAC,SAAS,EAAE;QAC7C,OAAO,KAAK;KACf;;IAED,IAAI,OAAO,GAAG,QAAQ,CAAC,GAAG,CAAC,KAAK,EAAC;IACjC,IAAI,OAAO,IAAI,IAAI,EAAE;QACjB,OAAO,GAAG,aAAa,CAAC,UAAU,CAAC,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,EAAC;QACxE,QAAQ,CAAC,GAAG,CAAC,KAAK,EAAE,OAAO,EAAC;KAC/B;IACD,OAAO,OAAO;CACjB;;;;;;;;;AASD,AAAO,SAAS,SAAS,CAAC,WAAW,EAAE,KAAK,EAAE;IAC1C,MAAM,OAAO,GAAG,UAAU,CAAC,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,EAAC;IACxD,OAAO,IAAI,OAAO,CAAC,WAAW,EAAE,KAAK,CAAC;CACzC;;;;;;;;AAQD,AAAO,SAAS,SAAS,CAAC,KAAK,EAAE;IAC7B,OAAO,EAAE,CAAC,KAAK,CAAC,CAAC,gBAAgB;CACpC;;;;;;;;;AASD,AAAO,SAAS,aAAa,CAAC,KAAK,EAAE,UAAU,EAAE;IAC7C,EAAE,CAAC,KAAK,CAAC,CAAC,UAAU,GAAG,WAAU;CACpC;;;;;;;;;AASD,AAAO,SAAS,gBAAgB,CAAC,KAAK,EAAE,aAAa,EAAE;IACnD,EAAE,CAAC,KAAK,CAAC,CAAC,aAAa,GAAG,cAAa;CAC1C;;;;;;;;;AASD,AAAO,SAAS,kBAAkB,CAAC,KAAK,EAAE,eAAe,EAAE;IACvD,EAAE,CAAC,KAAK,CAAC,CAAC,eAAe,GAAG,gBAAe;CAC9C;;ACtdD;;;;;;;;;;;;;;AAcA,MAAM,YAAY,GAAG,IAAI,OAAO,GAAE;;;AAGlC,MAAM,OAAO,GAAG,EAAC;AACjB,MAAM,MAAM,GAAG,EAAC;AAChB,MAAM,SAAS,GAAG,EAAC;;;;;;;AAOnB,SAAS,QAAQ,CAAC,CAAC,EAAE;IACjB,OAAO,CAAC,KAAK,IAAI,IAAI,OAAO,CAAC,KAAK,QAAQ;CAC7C;;;;;;;;AAQD,SAAS,YAAY,CAAC,WAAW,EAAE;IAC/B,MAAM,SAAS,GAAG,YAAY,CAAC,GAAG,CAAC,WAAW,EAAC;IAC/C,IAAI,SAAS,IAAI,IAAI,EAAE;QACnB,MAAM,IAAI,SAAS;YACf,kEAAkE;SACrE;KACJ;IACD,OAAO,SAAS;CACnB;;;;;;;;AAQD,SAAS,8BAA8B,CAAC,SAAS,EAAE;IAC/C,OAAO;QACH,GAAG,GAAG;YACF,MAAM,SAAS,GAAG,YAAY,CAAC,IAAI,EAAC;YACpC,IAAI,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,SAAS,EAAC;YACnC,OAAO,IAAI,IAAI,IAAI,EAAE;gBACjB,IAAI,IAAI,CAAC,YAAY,KAAK,SAAS,EAAE;oBACjC,OAAO,IAAI,CAAC,QAAQ;iBACvB;gBACD,IAAI,GAAG,IAAI,CAAC,KAAI;aACnB;YACD,OAAO,IAAI;SACd;;QAED,GAAG,CAAC,QAAQ,EAAE;YACV,IAAI,OAAO,QAAQ,KAAK,UAAU,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE;gBACvD,QAAQ,GAAG,KAAI;aAClB;YACD,MAAM,SAAS,GAAG,YAAY,CAAC,IAAI,EAAC;;;YAGpC,IAAI,IAAI,GAAG,KAAI;YACf,IAAI,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,SAAS,EAAC;YACnC,OAAO,IAAI,IAAI,IAAI,EAAE;gBACjB,IAAI,IAAI,CAAC,YAAY,KAAK,SAAS,EAAE;;oBAEjC,IAAI,IAAI,KAAK,IAAI,EAAE;wBACf,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,KAAI;qBACxB,MAAM,IAAI,IAAI,CAAC,IAAI,KAAK,IAAI,EAAE;wBAC3B,SAAS,CAAC,GAAG,CAAC,SAAS,EAAE,IAAI,CAAC,IAAI,EAAC;qBACtC,MAAM;wBACH,SAAS,CAAC,MAAM,CAAC,SAAS,EAAC;qBAC9B;iBACJ,MAAM;oBACH,IAAI,GAAG,KAAI;iBACd;;gBAED,IAAI,GAAG,IAAI,CAAC,KAAI;aACnB;;;YAGD,IAAI,QAAQ,KAAK,IAAI,EAAE;gBACnB,MAAM,OAAO,GAAG;oBACZ,QAAQ;oBACR,YAAY,EAAE,SAAS;oBACvB,OAAO,EAAE,KAAK;oBACd,IAAI,EAAE,KAAK;oBACX,IAAI,EAAE,IAAI;kBACb;gBACD,IAAI,IAAI,KAAK,IAAI,EAAE;oBACf,SAAS,CAAC,GAAG,CAAC,SAAS,EAAE,OAAO,EAAC;iBACpC,MAAM;oBACH,IAAI,CAAC,IAAI,GAAG,QAAO;iBACtB;aACJ;SACJ;QACD,YAAY,EAAE,IAAI;QAClB,UAAU,EAAE,IAAI;KACnB;CACJ;;;;;;;;AAQD,SAAS,oBAAoB,CAAC,oBAAoB,EAAE,SAAS,EAAE;IAC3D,MAAM,CAAC,cAAc;QACjB,oBAAoB;QACpB,CAAC,EAAE,EAAE,SAAS,CAAC,CAAC;QAChB,8BAA8B,CAAC,SAAS,CAAC;MAC5C;CACJ;;;;;;;;AAQD,SAAS,uBAAuB,CAAC,UAAU,EAAE;;IAEzC,SAAS,iBAAiB,GAAG;QACzB,WAAW,CAAC,IAAI,CAAC,IAAI,EAAC;KACzB;;IAED,iBAAiB,CAAC,SAAS,GAAG,MAAM,CAAC,MAAM,CAAC,WAAW,CAAC,SAAS,EAAE;QAC/D,WAAW,EAAE;YACT,KAAK,EAAE,iBAAiB;YACxB,YAAY,EAAE,IAAI;YAClB,QAAQ,EAAE,IAAI;SACjB;KACJ,EAAC;;IAEF,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,UAAU,CAAC,MAAM,EAAE,EAAE,CAAC,EAAE;QACxC,oBAAoB,CAAC,iBAAiB,CAAC,SAAS,EAAE,UAAU,CAAC,CAAC,CAAC,EAAC;KACnE;;IAED,OAAO,iBAAiB;CAC3B;;;;;;;;;;;;;;;AAeD,SAAS,WAAW,GAAG;;IAEnB,IAAI,IAAI,YAAY,WAAW,EAAE;QAC7B,YAAY,CAAC,GAAG,CAAC,IAAI,EAAE,IAAI,GAAG,EAAE,EAAC;QACjC,MAAM;KACT;IACD,IAAI,SAAS,CAAC,MAAM,KAAK,CAAC,IAAI,KAAK,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,EAAE;QACvD,OAAO,uBAAuB,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;KAC/C;IACD,IAAI,SAAS,CAAC,MAAM,GAAG,CAAC,EAAE;QACtB,MAAM,KAAK,GAAG,IAAI,KAAK,CAAC,SAAS,CAAC,MAAM,EAAC;QACzC,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,SAAS,CAAC,MAAM,EAAE,EAAE,CAAC,EAAE;YACvC,KAAK,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC,CAAC,EAAC;SAC1B;QACD,OAAO,uBAAuB,CAAC,KAAK,CAAC;KACxC;IACD,MAAM,IAAI,SAAS,CAAC,mCAAmC,CAAC;;CAE3D;;;AAGD,WAAW,CAAC,SAAS,GAAG;;;;;;;;IAQpB,gBAAgB,CAAC,SAAS,EAAE,QAAQ,EAAE,OAAO,EAAE;QAC3C,IAAI,QAAQ,IAAI,IAAI,EAAE;YAClB,MAAM;SACT;QACD,IAAI,OAAO,QAAQ,KAAK,UAAU,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE;YACvD,MAAM,IAAI,SAAS,CAAC,+CAA+C,CAAC;SACvE;;QAED,MAAM,SAAS,GAAG,YAAY,CAAC,IAAI,EAAC;QACpC,MAAM,YAAY,GAAG,QAAQ,CAAC,OAAO,EAAC;QACtC,MAAM,OAAO,GAAG,YAAY;cACtB,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC;cACxB,OAAO,CAAC,OAAO,EAAC;QACtB,MAAM,YAAY,GAAG,OAAO,GAAG,OAAO,GAAG,OAAM;QAC/C,MAAM,OAAO,GAAG;YACZ,QAAQ;YACR,YAAY;YACZ,OAAO,EAAE,YAAY,IAAI,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC;YACjD,IAAI,EAAE,YAAY,IAAI,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC;YAC3C,IAAI,EAAE,IAAI;UACb;;;QAGD,IAAI,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,SAAS,EAAC;QACnC,IAAI,IAAI,KAAK,SAAS,EAAE;YACpB,SAAS,CAAC,GAAG,CAAC,SAAS,EAAE,OAAO,EAAC;YACjC,MAAM;SACT;;;QAGD,IAAI,IAAI,GAAG,KAAI;QACf,OAAO,IAAI,IAAI,IAAI,EAAE;YACjB;gBACI,IAAI,CAAC,QAAQ,KAAK,QAAQ;gBAC1B,IAAI,CAAC,YAAY,KAAK,YAAY;cACpC;;gBAEE,MAAM;aACT;YACD,IAAI,GAAG,KAAI;YACX,IAAI,GAAG,IAAI,CAAC,KAAI;SACnB;;;QAGD,IAAI,CAAC,IAAI,GAAG,QAAO;KACtB;;;;;;;;;IASD,mBAAmB,CAAC,SAAS,EAAE,QAAQ,EAAE,OAAO,EAAE;QAC9C,IAAI,QAAQ,IAAI,IAAI,EAAE;YAClB,MAAM;SACT;;QAED,MAAM,SAAS,GAAG,YAAY,CAAC,IAAI,EAAC;QACpC,MAAM,OAAO,GAAG,QAAQ,CAAC,OAAO,CAAC;cAC3B,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC;cACxB,OAAO,CAAC,OAAO,EAAC;QACtB,MAAM,YAAY,GAAG,OAAO,GAAG,OAAO,GAAG,OAAM;;QAE/C,IAAI,IAAI,GAAG,KAAI;QACf,IAAI,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,SAAS,EAAC;QACnC,OAAO,IAAI,IAAI,IAAI,EAAE;YACjB;gBACI,IAAI,CAAC,QAAQ,KAAK,QAAQ;gBAC1B,IAAI,CAAC,YAAY,KAAK,YAAY;cACpC;gBACE,IAAI,IAAI,KAAK,IAAI,EAAE;oBACf,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,KAAI;iBACxB,MAAM,IAAI,IAAI,CAAC,IAAI,KAAK,IAAI,EAAE;oBAC3B,SAAS,CAAC,GAAG,CAAC,SAAS,EAAE,IAAI,CAAC,IAAI,EAAC;iBACtC,MAAM;oBACH,SAAS,CAAC,MAAM,CAAC,SAAS,EAAC;iBAC9B;gBACD,MAAM;aACT;;YAED,IAAI,GAAG,KAAI;YACX,IAAI,GAAG,IAAI,CAAC,KAAI;SACnB;KACJ;;;;;;;IAOD,aAAa,CAAC,KAAK,EAAE;QACjB,IAAI,KAAK,IAAI,IAAI,IAAI,OAAO,KAAK,CAAC,IAAI,KAAK,QAAQ,EAAE;YACjD,MAAM,IAAI,SAAS,CAAC,kCAAkC,CAAC;SAC1D;;;QAGD,MAAM,SAAS,GAAG,YAAY,CAAC,IAAI,EAAC;QACpC,MAAM,SAAS,GAAG,KAAK,CAAC,KAAI;QAC5B,IAAI,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,SAAS,EAAC;QACnC,IAAI,IAAI,IAAI,IAAI,EAAE;YACd,OAAO,IAAI;SACd;;;QAGD,MAAM,YAAY,GAAG,SAAS,CAAC,IAAI,EAAE,KAAK,EAAC;;;;QAI3C,IAAI,IAAI,GAAG,KAAI;QACf,OAAO,IAAI,IAAI,IAAI,EAAE;;YAEjB,IAAI,IAAI,CAAC,IAAI,EAAE;gBACX,IAAI,IAAI,KAAK,IAAI,EAAE;oBACf,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,KAAI;iBACxB,MAAM,IAAI,IAAI,CAAC,IAAI,KAAK,IAAI,EAAE;oBAC3B,SAAS,CAAC,GAAG,CAAC,SAAS,EAAE,IAAI,CAAC,IAAI,EAAC;iBACtC,MAAM;oBACH,SAAS,CAAC,MAAM,CAAC,SAAS,EAAC;iBAC9B;aACJ,MAAM;gBACH,IAAI,GAAG,KAAI;aACd;;;YAGD,kBAAkB;gBACd,YAAY;gBACZ,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,QAAQ,GAAG,IAAI;cACtC;YACD,IAAI,OAAO,IAAI,CAAC,QAAQ,KAAK,UAAU,EAAE;gBACrC,IAAI;oBACA,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,EAAE,YAAY,EAAC;iBACzC,CAAC,OAAO,GAAG,EAAE;oBACV;wBACI,OAAO,OAAO,KAAK,WAAW;wBAC9B,OAAO,OAAO,CAAC,KAAK,KAAK,UAAU;sBACrC;wBACE,OAAO,CAAC,KAAK,CAAC,GAAG,EAAC;qBACrB;iBACJ;aACJ,MAAM;gBACH,IAAI,CAAC,YAAY,KAAK,SAAS;gBAC/B,OAAO,IAAI,CAAC,QAAQ,CAAC,WAAW,KAAK,UAAU;cACjD;gBACE,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,YAAY,EAAC;aAC1C;;;YAGD,IAAI,SAAS,CAAC,YAAY,CAAC,EAAE;gBACzB,KAAK;aACR;;YAED,IAAI,GAAG,IAAI,CAAC,KAAI;SACnB;QACD,kBAAkB,CAAC,YAAY,EAAE,IAAI,EAAC;QACtC,aAAa,CAAC,YAAY,EAAE,CAAC,EAAC;QAC9B,gBAAgB,CAAC,YAAY,EAAE,IAAI,EAAC;;QAEpC,OAAO,CAAC,YAAY,CAAC,gBAAgB;KACxC;EACJ;;;AAGD,MAAM,CAAC,cAAc,CAAC,WAAW,CAAC,SAAS,EAAE,aAAa,EAAE;IACxD,KAAK,EAAE,WAAW;IAClB,YAAY,EAAE,IAAI;IAClB,QAAQ,EAAE,IAAI;CACjB,EAAC;;;AAGF;IACI,OAAO,MAAM,KAAK,WAAW;IAC7B,OAAO,MAAM,CAAC,WAAW,KAAK,WAAW;EAC3C;IACE,MAAM,CAAC,cAAc,CAAC,WAAW,CAAC,SAAS,EAAE,MAAM,CAAC,WAAW,CAAC,SAAS,EAAC;CAC7E;;;;;;;;;;;;;"} \ No newline at end of file diff --git a/node_modules/event-target-shim/dist/event-target-shim.mjs b/node_modules/event-target-shim/dist/event-target-shim.mjs new file mode 100644 index 0000000..114f3a1 --- /dev/null +++ b/node_modules/event-target-shim/dist/event-target-shim.mjs @@ -0,0 +1,862 @@ +/** + * @author Toru Nagashima <https://github.com/mysticatea> + * @copyright 2015 Toru Nagashima. All rights reserved. + * See LICENSE file in root directory for full license. + */ +/** + * @typedef {object} PrivateData + * @property {EventTarget} eventTarget The event target. + * @property {{type:string}} event The original event object. + * @property {number} eventPhase The current event phase. + * @property {EventTarget|null} currentTarget The current event target. + * @property {boolean} canceled The flag to prevent default. + * @property {boolean} stopped The flag to stop propagation. + * @property {boolean} immediateStopped The flag to stop propagation immediately. + * @property {Function|null} passiveListener The listener if the current listener is passive. Otherwise this is null. + * @property {number} timeStamp The unix time. + * @private + */ + +/** + * Private data for event wrappers. + * @type {WeakMap<Event, PrivateData>} + * @private + */ +const privateData = new WeakMap(); + +/** + * Cache for wrapper classes. + * @type {WeakMap<Object, Function>} + * @private + */ +const wrappers = new WeakMap(); + +/** + * Get private data. + * @param {Event} event The event object to get private data. + * @returns {PrivateData} The private data of the event. + * @private + */ +function pd(event) { + const retv = privateData.get(event); + console.assert( + retv != null, + "'this' is expected an Event object, but got", + event + ); + return retv +} + +/** + * https://dom.spec.whatwg.org/#set-the-canceled-flag + * @param data {PrivateData} private data. + */ +function setCancelFlag(data) { + if (data.passiveListener != null) { + if ( + typeof console !== "undefined" && + typeof console.error === "function" + ) { + console.error( + "Unable to preventDefault inside passive event listener invocation.", + data.passiveListener + ); + } + return + } + if (!data.event.cancelable) { + return + } + + data.canceled = true; + if (typeof data.event.preventDefault === "function") { + data.event.preventDefault(); + } +} + +/** + * @see https://dom.spec.whatwg.org/#interface-event + * @private + */ +/** + * The event wrapper. + * @constructor + * @param {EventTarget} eventTarget The event target of this dispatching. + * @param {Event|{type:string}} event The original event to wrap. + */ +function Event(eventTarget, event) { + privateData.set(this, { + eventTarget, + event, + eventPhase: 2, + currentTarget: eventTarget, + canceled: false, + stopped: false, + immediateStopped: false, + passiveListener: null, + timeStamp: event.timeStamp || Date.now(), + }); + + // https://heycam.github.io/webidl/#Unforgeable + Object.defineProperty(this, "isTrusted", { value: false, enumerable: true }); + + // Define accessors + const keys = Object.keys(event); + for (let i = 0; i < keys.length; ++i) { + const key = keys[i]; + if (!(key in this)) { + Object.defineProperty(this, key, defineRedirectDescriptor(key)); + } + } +} + +// Should be enumerable, but class methods are not enumerable. +Event.prototype = { + /** + * The type of this event. + * @type {string} + */ + get type() { + return pd(this).event.type + }, + + /** + * The target of this event. + * @type {EventTarget} + */ + get target() { + return pd(this).eventTarget + }, + + /** + * The target of this event. + * @type {EventTarget} + */ + get currentTarget() { + return pd(this).currentTarget + }, + + /** + * @returns {EventTarget[]} The composed path of this event. + */ + composedPath() { + const currentTarget = pd(this).currentTarget; + if (currentTarget == null) { + return [] + } + return [currentTarget] + }, + + /** + * Constant of NONE. + * @type {number} + */ + get NONE() { + return 0 + }, + + /** + * Constant of CAPTURING_PHASE. + * @type {number} + */ + get CAPTURING_PHASE() { + return 1 + }, + + /** + * Constant of AT_TARGET. + * @type {number} + */ + get AT_TARGET() { + return 2 + }, + + /** + * Constant of BUBBLING_PHASE. + * @type {number} + */ + get BUBBLING_PHASE() { + return 3 + }, + + /** + * The target of this event. + * @type {number} + */ + get eventPhase() { + return pd(this).eventPhase + }, + + /** + * Stop event bubbling. + * @returns {void} + */ + stopPropagation() { + const data = pd(this); + + data.stopped = true; + if (typeof data.event.stopPropagation === "function") { + data.event.stopPropagation(); + } + }, + + /** + * Stop event bubbling. + * @returns {void} + */ + stopImmediatePropagation() { + const data = pd(this); + + data.stopped = true; + data.immediateStopped = true; + if (typeof data.event.stopImmediatePropagation === "function") { + data.event.stopImmediatePropagation(); + } + }, + + /** + * The flag to be bubbling. + * @type {boolean} + */ + get bubbles() { + return Boolean(pd(this).event.bubbles) + }, + + /** + * The flag to be cancelable. + * @type {boolean} + */ + get cancelable() { + return Boolean(pd(this).event.cancelable) + }, + + /** + * Cancel this event. + * @returns {void} + */ + preventDefault() { + setCancelFlag(pd(this)); + }, + + /** + * The flag to indicate cancellation state. + * @type {boolean} + */ + get defaultPrevented() { + return pd(this).canceled + }, + + /** + * The flag to be composed. + * @type {boolean} + */ + get composed() { + return Boolean(pd(this).event.composed) + }, + + /** + * The unix time of this event. + * @type {number} + */ + get timeStamp() { + return pd(this).timeStamp + }, + + /** + * The target of this event. + * @type {EventTarget} + * @deprecated + */ + get srcElement() { + return pd(this).eventTarget + }, + + /** + * The flag to stop event bubbling. + * @type {boolean} + * @deprecated + */ + get cancelBubble() { + return pd(this).stopped + }, + set cancelBubble(value) { + if (!value) { + return + } + const data = pd(this); + + data.stopped = true; + if (typeof data.event.cancelBubble === "boolean") { + data.event.cancelBubble = true; + } + }, + + /** + * The flag to indicate cancellation state. + * @type {boolean} + * @deprecated + */ + get returnValue() { + return !pd(this).canceled + }, + set returnValue(value) { + if (!value) { + setCancelFlag(pd(this)); + } + }, + + /** + * Initialize this event object. But do nothing under event dispatching. + * @param {string} type The event type. + * @param {boolean} [bubbles=false] The flag to be possible to bubble up. + * @param {boolean} [cancelable=false] The flag to be possible to cancel. + * @deprecated + */ + initEvent() { + // Do nothing. + }, +}; + +// `constructor` is not enumerable. +Object.defineProperty(Event.prototype, "constructor", { + value: Event, + configurable: true, + writable: true, +}); + +// Ensure `event instanceof window.Event` is `true`. +if (typeof window !== "undefined" && typeof window.Event !== "undefined") { + Object.setPrototypeOf(Event.prototype, window.Event.prototype); + + // Make association for wrappers. + wrappers.set(window.Event.prototype, Event); +} + +/** + * Get the property descriptor to redirect a given property. + * @param {string} key Property name to define property descriptor. + * @returns {PropertyDescriptor} The property descriptor to redirect the property. + * @private + */ +function defineRedirectDescriptor(key) { + return { + get() { + return pd(this).event[key] + }, + set(value) { + pd(this).event[key] = value; + }, + configurable: true, + enumerable: true, + } +} + +/** + * Get the property descriptor to call a given method property. + * @param {string} key Property name to define property descriptor. + * @returns {PropertyDescriptor} The property descriptor to call the method property. + * @private + */ +function defineCallDescriptor(key) { + return { + value() { + const event = pd(this).event; + return event[key].apply(event, arguments) + }, + configurable: true, + enumerable: true, + } +} + +/** + * Define new wrapper class. + * @param {Function} BaseEvent The base wrapper class. + * @param {Object} proto The prototype of the original event. + * @returns {Function} The defined wrapper class. + * @private + */ +function defineWrapper(BaseEvent, proto) { + const keys = Object.keys(proto); + if (keys.length === 0) { + return BaseEvent + } + + /** CustomEvent */ + function CustomEvent(eventTarget, event) { + BaseEvent.call(this, eventTarget, event); + } + + CustomEvent.prototype = Object.create(BaseEvent.prototype, { + constructor: { value: CustomEvent, configurable: true, writable: true }, + }); + + // Define accessors. + for (let i = 0; i < keys.length; ++i) { + const key = keys[i]; + if (!(key in BaseEvent.prototype)) { + const descriptor = Object.getOwnPropertyDescriptor(proto, key); + const isFunc = typeof descriptor.value === "function"; + Object.defineProperty( + CustomEvent.prototype, + key, + isFunc + ? defineCallDescriptor(key) + : defineRedirectDescriptor(key) + ); + } + } + + return CustomEvent +} + +/** + * Get the wrapper class of a given prototype. + * @param {Object} proto The prototype of the original event to get its wrapper. + * @returns {Function} The wrapper class. + * @private + */ +function getWrapper(proto) { + if (proto == null || proto === Object.prototype) { + return Event + } + + let wrapper = wrappers.get(proto); + if (wrapper == null) { + wrapper = defineWrapper(getWrapper(Object.getPrototypeOf(proto)), proto); + wrappers.set(proto, wrapper); + } + return wrapper +} + +/** + * Wrap a given event to management a dispatching. + * @param {EventTarget} eventTarget The event target of this dispatching. + * @param {Object} event The event to wrap. + * @returns {Event} The wrapper instance. + * @private + */ +function wrapEvent(eventTarget, event) { + const Wrapper = getWrapper(Object.getPrototypeOf(event)); + return new Wrapper(eventTarget, event) +} + +/** + * Get the immediateStopped flag of a given event. + * @param {Event} event The event to get. + * @returns {boolean} The flag to stop propagation immediately. + * @private + */ +function isStopped(event) { + return pd(event).immediateStopped +} + +/** + * Set the current event phase of a given event. + * @param {Event} event The event to set current target. + * @param {number} eventPhase New event phase. + * @returns {void} + * @private + */ +function setEventPhase(event, eventPhase) { + pd(event).eventPhase = eventPhase; +} + +/** + * Set the current target of a given event. + * @param {Event} event The event to set current target. + * @param {EventTarget|null} currentTarget New current target. + * @returns {void} + * @private + */ +function setCurrentTarget(event, currentTarget) { + pd(event).currentTarget = currentTarget; +} + +/** + * Set a passive listener of a given event. + * @param {Event} event The event to set current target. + * @param {Function|null} passiveListener New passive listener. + * @returns {void} + * @private + */ +function setPassiveListener(event, passiveListener) { + pd(event).passiveListener = passiveListener; +} + +/** + * @typedef {object} ListenerNode + * @property {Function} listener + * @property {1|2|3} listenerType + * @property {boolean} passive + * @property {boolean} once + * @property {ListenerNode|null} next + * @private + */ + +/** + * @type {WeakMap<object, Map<string, ListenerNode>>} + * @private + */ +const listenersMap = new WeakMap(); + +// Listener types +const CAPTURE = 1; +const BUBBLE = 2; +const ATTRIBUTE = 3; + +/** + * Check whether a given value is an object or not. + * @param {any} x The value to check. + * @returns {boolean} `true` if the value is an object. + */ +function isObject(x) { + return x !== null && typeof x === "object" //eslint-disable-line no-restricted-syntax +} + +/** + * Get listeners. + * @param {EventTarget} eventTarget The event target to get. + * @returns {Map<string, ListenerNode>} The listeners. + * @private + */ +function getListeners(eventTarget) { + const listeners = listenersMap.get(eventTarget); + if (listeners == null) { + throw new TypeError( + "'this' is expected an EventTarget object, but got another value." + ) + } + return listeners +} + +/** + * Get the property descriptor for the event attribute of a given event. + * @param {string} eventName The event name to get property descriptor. + * @returns {PropertyDescriptor} The property descriptor. + * @private + */ +function defineEventAttributeDescriptor(eventName) { + return { + get() { + const listeners = getListeners(this); + let node = listeners.get(eventName); + while (node != null) { + if (node.listenerType === ATTRIBUTE) { + return node.listener + } + node = node.next; + } + return null + }, + + set(listener) { + if (typeof listener !== "function" && !isObject(listener)) { + listener = null; // eslint-disable-line no-param-reassign + } + const listeners = getListeners(this); + + // Traverse to the tail while removing old value. + let prev = null; + let node = listeners.get(eventName); + while (node != null) { + if (node.listenerType === ATTRIBUTE) { + // Remove old value. + if (prev !== null) { + prev.next = node.next; + } else if (node.next !== null) { + listeners.set(eventName, node.next); + } else { + listeners.delete(eventName); + } + } else { + prev = node; + } + + node = node.next; + } + + // Add new value. + if (listener !== null) { + const newNode = { + listener, + listenerType: ATTRIBUTE, + passive: false, + once: false, + next: null, + }; + if (prev === null) { + listeners.set(eventName, newNode); + } else { + prev.next = newNode; + } + } + }, + configurable: true, + enumerable: true, + } +} + +/** + * Define an event attribute (e.g. `eventTarget.onclick`). + * @param {Object} eventTargetPrototype The event target prototype to define an event attrbite. + * @param {string} eventName The event name to define. + * @returns {void} + */ +function defineEventAttribute(eventTargetPrototype, eventName) { + Object.defineProperty( + eventTargetPrototype, + `on${eventName}`, + defineEventAttributeDescriptor(eventName) + ); +} + +/** + * Define a custom EventTarget with event attributes. + * @param {string[]} eventNames Event names for event attributes. + * @returns {EventTarget} The custom EventTarget. + * @private + */ +function defineCustomEventTarget(eventNames) { + /** CustomEventTarget */ + function CustomEventTarget() { + EventTarget.call(this); + } + + CustomEventTarget.prototype = Object.create(EventTarget.prototype, { + constructor: { + value: CustomEventTarget, + configurable: true, + writable: true, + }, + }); + + for (let i = 0; i < eventNames.length; ++i) { + defineEventAttribute(CustomEventTarget.prototype, eventNames[i]); + } + + return CustomEventTarget +} + +/** + * EventTarget. + * + * - This is constructor if no arguments. + * - This is a function which returns a CustomEventTarget constructor if there are arguments. + * + * For example: + * + * class A extends EventTarget {} + * class B extends EventTarget("message") {} + * class C extends EventTarget("message", "error") {} + * class D extends EventTarget(["message", "error"]) {} + */ +function EventTarget() { + /*eslint-disable consistent-return */ + if (this instanceof EventTarget) { + listenersMap.set(this, new Map()); + return + } + if (arguments.length === 1 && Array.isArray(arguments[0])) { + return defineCustomEventTarget(arguments[0]) + } + if (arguments.length > 0) { + const types = new Array(arguments.length); + for (let i = 0; i < arguments.length; ++i) { + types[i] = arguments[i]; + } + return defineCustomEventTarget(types) + } + throw new TypeError("Cannot call a class as a function") + /*eslint-enable consistent-return */ +} + +// Should be enumerable, but class methods are not enumerable. +EventTarget.prototype = { + /** + * Add a given listener to this event target. + * @param {string} eventName The event name to add. + * @param {Function} listener The listener to add. + * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener. + * @returns {void} + */ + addEventListener(eventName, listener, options) { + if (listener == null) { + return + } + if (typeof listener !== "function" && !isObject(listener)) { + throw new TypeError("'listener' should be a function or an object.") + } + + const listeners = getListeners(this); + const optionsIsObj = isObject(options); + const capture = optionsIsObj + ? Boolean(options.capture) + : Boolean(options); + const listenerType = capture ? CAPTURE : BUBBLE; + const newNode = { + listener, + listenerType, + passive: optionsIsObj && Boolean(options.passive), + once: optionsIsObj && Boolean(options.once), + next: null, + }; + + // Set it as the first node if the first node is null. + let node = listeners.get(eventName); + if (node === undefined) { + listeners.set(eventName, newNode); + return + } + + // Traverse to the tail while checking duplication.. + let prev = null; + while (node != null) { + if ( + node.listener === listener && + node.listenerType === listenerType + ) { + // Should ignore duplication. + return + } + prev = node; + node = node.next; + } + + // Add it. + prev.next = newNode; + }, + + /** + * Remove a given listener from this event target. + * @param {string} eventName The event name to remove. + * @param {Function} listener The listener to remove. + * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener. + * @returns {void} + */ + removeEventListener(eventName, listener, options) { + if (listener == null) { + return + } + + const listeners = getListeners(this); + const capture = isObject(options) + ? Boolean(options.capture) + : Boolean(options); + const listenerType = capture ? CAPTURE : BUBBLE; + + let prev = null; + let node = listeners.get(eventName); + while (node != null) { + if ( + node.listener === listener && + node.listenerType === listenerType + ) { + if (prev !== null) { + prev.next = node.next; + } else if (node.next !== null) { + listeners.set(eventName, node.next); + } else { + listeners.delete(eventName); + } + return + } + + prev = node; + node = node.next; + } + }, + + /** + * Dispatch a given event. + * @param {Event|{type:string}} event The event to dispatch. + * @returns {boolean} `false` if canceled. + */ + dispatchEvent(event) { + if (event == null || typeof event.type !== "string") { + throw new TypeError('"event.type" should be a string.') + } + + // If listeners aren't registered, terminate. + const listeners = getListeners(this); + const eventName = event.type; + let node = listeners.get(eventName); + if (node == null) { + return true + } + + // Since we cannot rewrite several properties, so wrap object. + const wrappedEvent = wrapEvent(this, event); + + // This doesn't process capturing phase and bubbling phase. + // This isn't participating in a tree. + let prev = null; + while (node != null) { + // Remove this listener if it's once + if (node.once) { + if (prev !== null) { + prev.next = node.next; + } else if (node.next !== null) { + listeners.set(eventName, node.next); + } else { + listeners.delete(eventName); + } + } else { + prev = node; + } + + // Call this listener + setPassiveListener( + wrappedEvent, + node.passive ? node.listener : null + ); + if (typeof node.listener === "function") { + try { + node.listener.call(this, wrappedEvent); + } catch (err) { + if ( + typeof console !== "undefined" && + typeof console.error === "function" + ) { + console.error(err); + } + } + } else if ( + node.listenerType !== ATTRIBUTE && + typeof node.listener.handleEvent === "function" + ) { + node.listener.handleEvent(wrappedEvent); + } + + // Break if `event.stopImmediatePropagation` was called. + if (isStopped(wrappedEvent)) { + break + } + + node = node.next; + } + setPassiveListener(wrappedEvent, null); + setEventPhase(wrappedEvent, 0); + setCurrentTarget(wrappedEvent, null); + + return !wrappedEvent.defaultPrevented + }, +}; + +// `constructor` is not enumerable. +Object.defineProperty(EventTarget.prototype, "constructor", { + value: EventTarget, + configurable: true, + writable: true, +}); + +// Ensure `eventTarget instanceof window.EventTarget` is `true`. +if ( + typeof window !== "undefined" && + typeof window.EventTarget !== "undefined" +) { + Object.setPrototypeOf(EventTarget.prototype, window.EventTarget.prototype); +} + +export default EventTarget; +export { defineEventAttribute, EventTarget }; +//# sourceMappingURL=event-target-shim.mjs.map diff --git a/node_modules/event-target-shim/dist/event-target-shim.mjs.map b/node_modules/event-target-shim/dist/event-target-shim.mjs.map new file mode 100644 index 0000000..57b3e8f --- /dev/null +++ b/node_modules/event-target-shim/dist/event-target-shim.mjs.map @@ -0,0 +1 @@ +{"version":3,"file":"event-target-shim.mjs","sources":["../src/event.mjs","../src/event-target.mjs"],"sourcesContent":["/**\n * @typedef {object} PrivateData\n * @property {EventTarget} eventTarget The event target.\n * @property {{type:string}} event The original event object.\n * @property {number} eventPhase The current event phase.\n * @property {EventTarget|null} currentTarget The current event target.\n * @property {boolean} canceled The flag to prevent default.\n * @property {boolean} stopped The flag to stop propagation.\n * @property {boolean} immediateStopped The flag to stop propagation immediately.\n * @property {Function|null} passiveListener The listener if the current listener is passive. Otherwise this is null.\n * @property {number} timeStamp The unix time.\n * @private\n */\n\n/**\n * Private data for event wrappers.\n * @type {WeakMap<Event, PrivateData>}\n * @private\n */\nconst privateData = new WeakMap()\n\n/**\n * Cache for wrapper classes.\n * @type {WeakMap<Object, Function>}\n * @private\n */\nconst wrappers = new WeakMap()\n\n/**\n * Get private data.\n * @param {Event} event The event object to get private data.\n * @returns {PrivateData} The private data of the event.\n * @private\n */\nfunction pd(event) {\n const retv = privateData.get(event)\n console.assert(\n retv != null,\n \"'this' is expected an Event object, but got\",\n event\n )\n return retv\n}\n\n/**\n * https://dom.spec.whatwg.org/#set-the-canceled-flag\n * @param data {PrivateData} private data.\n */\nfunction setCancelFlag(data) {\n if (data.passiveListener != null) {\n if (\n typeof console !== \"undefined\" &&\n typeof console.error === \"function\"\n ) {\n console.error(\n \"Unable to preventDefault inside passive event listener invocation.\",\n data.passiveListener\n )\n }\n return\n }\n if (!data.event.cancelable) {\n return\n }\n\n data.canceled = true\n if (typeof data.event.preventDefault === \"function\") {\n data.event.preventDefault()\n }\n}\n\n/**\n * @see https://dom.spec.whatwg.org/#interface-event\n * @private\n */\n/**\n * The event wrapper.\n * @constructor\n * @param {EventTarget} eventTarget The event target of this dispatching.\n * @param {Event|{type:string}} event The original event to wrap.\n */\nfunction Event(eventTarget, event) {\n privateData.set(this, {\n eventTarget,\n event,\n eventPhase: 2,\n currentTarget: eventTarget,\n canceled: false,\n stopped: false,\n immediateStopped: false,\n passiveListener: null,\n timeStamp: event.timeStamp || Date.now(),\n })\n\n // https://heycam.github.io/webidl/#Unforgeable\n Object.defineProperty(this, \"isTrusted\", { value: false, enumerable: true })\n\n // Define accessors\n const keys = Object.keys(event)\n for (let i = 0; i < keys.length; ++i) {\n const key = keys[i]\n if (!(key in this)) {\n Object.defineProperty(this, key, defineRedirectDescriptor(key))\n }\n }\n}\n\n// Should be enumerable, but class methods are not enumerable.\nEvent.prototype = {\n /**\n * The type of this event.\n * @type {string}\n */\n get type() {\n return pd(this).event.type\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n */\n get target() {\n return pd(this).eventTarget\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n */\n get currentTarget() {\n return pd(this).currentTarget\n },\n\n /**\n * @returns {EventTarget[]} The composed path of this event.\n */\n composedPath() {\n const currentTarget = pd(this).currentTarget\n if (currentTarget == null) {\n return []\n }\n return [currentTarget]\n },\n\n /**\n * Constant of NONE.\n * @type {number}\n */\n get NONE() {\n return 0\n },\n\n /**\n * Constant of CAPTURING_PHASE.\n * @type {number}\n */\n get CAPTURING_PHASE() {\n return 1\n },\n\n /**\n * Constant of AT_TARGET.\n * @type {number}\n */\n get AT_TARGET() {\n return 2\n },\n\n /**\n * Constant of BUBBLING_PHASE.\n * @type {number}\n */\n get BUBBLING_PHASE() {\n return 3\n },\n\n /**\n * The target of this event.\n * @type {number}\n */\n get eventPhase() {\n return pd(this).eventPhase\n },\n\n /**\n * Stop event bubbling.\n * @returns {void}\n */\n stopPropagation() {\n const data = pd(this)\n\n data.stopped = true\n if (typeof data.event.stopPropagation === \"function\") {\n data.event.stopPropagation()\n }\n },\n\n /**\n * Stop event bubbling.\n * @returns {void}\n */\n stopImmediatePropagation() {\n const data = pd(this)\n\n data.stopped = true\n data.immediateStopped = true\n if (typeof data.event.stopImmediatePropagation === \"function\") {\n data.event.stopImmediatePropagation()\n }\n },\n\n /**\n * The flag to be bubbling.\n * @type {boolean}\n */\n get bubbles() {\n return Boolean(pd(this).event.bubbles)\n },\n\n /**\n * The flag to be cancelable.\n * @type {boolean}\n */\n get cancelable() {\n return Boolean(pd(this).event.cancelable)\n },\n\n /**\n * Cancel this event.\n * @returns {void}\n */\n preventDefault() {\n setCancelFlag(pd(this))\n },\n\n /**\n * The flag to indicate cancellation state.\n * @type {boolean}\n */\n get defaultPrevented() {\n return pd(this).canceled\n },\n\n /**\n * The flag to be composed.\n * @type {boolean}\n */\n get composed() {\n return Boolean(pd(this).event.composed)\n },\n\n /**\n * The unix time of this event.\n * @type {number}\n */\n get timeStamp() {\n return pd(this).timeStamp\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n * @deprecated\n */\n get srcElement() {\n return pd(this).eventTarget\n },\n\n /**\n * The flag to stop event bubbling.\n * @type {boolean}\n * @deprecated\n */\n get cancelBubble() {\n return pd(this).stopped\n },\n set cancelBubble(value) {\n if (!value) {\n return\n }\n const data = pd(this)\n\n data.stopped = true\n if (typeof data.event.cancelBubble === \"boolean\") {\n data.event.cancelBubble = true\n }\n },\n\n /**\n * The flag to indicate cancellation state.\n * @type {boolean}\n * @deprecated\n */\n get returnValue() {\n return !pd(this).canceled\n },\n set returnValue(value) {\n if (!value) {\n setCancelFlag(pd(this))\n }\n },\n\n /**\n * Initialize this event object. But do nothing under event dispatching.\n * @param {string} type The event type.\n * @param {boolean} [bubbles=false] The flag to be possible to bubble up.\n * @param {boolean} [cancelable=false] The flag to be possible to cancel.\n * @deprecated\n */\n initEvent() {\n // Do nothing.\n },\n}\n\n// `constructor` is not enumerable.\nObject.defineProperty(Event.prototype, \"constructor\", {\n value: Event,\n configurable: true,\n writable: true,\n})\n\n// Ensure `event instanceof window.Event` is `true`.\nif (typeof window !== \"undefined\" && typeof window.Event !== \"undefined\") {\n Object.setPrototypeOf(Event.prototype, window.Event.prototype)\n\n // Make association for wrappers.\n wrappers.set(window.Event.prototype, Event)\n}\n\n/**\n * Get the property descriptor to redirect a given property.\n * @param {string} key Property name to define property descriptor.\n * @returns {PropertyDescriptor} The property descriptor to redirect the property.\n * @private\n */\nfunction defineRedirectDescriptor(key) {\n return {\n get() {\n return pd(this).event[key]\n },\n set(value) {\n pd(this).event[key] = value\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Get the property descriptor to call a given method property.\n * @param {string} key Property name to define property descriptor.\n * @returns {PropertyDescriptor} The property descriptor to call the method property.\n * @private\n */\nfunction defineCallDescriptor(key) {\n return {\n value() {\n const event = pd(this).event\n return event[key].apply(event, arguments)\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Define new wrapper class.\n * @param {Function} BaseEvent The base wrapper class.\n * @param {Object} proto The prototype of the original event.\n * @returns {Function} The defined wrapper class.\n * @private\n */\nfunction defineWrapper(BaseEvent, proto) {\n const keys = Object.keys(proto)\n if (keys.length === 0) {\n return BaseEvent\n }\n\n /** CustomEvent */\n function CustomEvent(eventTarget, event) {\n BaseEvent.call(this, eventTarget, event)\n }\n\n CustomEvent.prototype = Object.create(BaseEvent.prototype, {\n constructor: { value: CustomEvent, configurable: true, writable: true },\n })\n\n // Define accessors.\n for (let i = 0; i < keys.length; ++i) {\n const key = keys[i]\n if (!(key in BaseEvent.prototype)) {\n const descriptor = Object.getOwnPropertyDescriptor(proto, key)\n const isFunc = typeof descriptor.value === \"function\"\n Object.defineProperty(\n CustomEvent.prototype,\n key,\n isFunc\n ? defineCallDescriptor(key)\n : defineRedirectDescriptor(key)\n )\n }\n }\n\n return CustomEvent\n}\n\n/**\n * Get the wrapper class of a given prototype.\n * @param {Object} proto The prototype of the original event to get its wrapper.\n * @returns {Function} The wrapper class.\n * @private\n */\nfunction getWrapper(proto) {\n if (proto == null || proto === Object.prototype) {\n return Event\n }\n\n let wrapper = wrappers.get(proto)\n if (wrapper == null) {\n wrapper = defineWrapper(getWrapper(Object.getPrototypeOf(proto)), proto)\n wrappers.set(proto, wrapper)\n }\n return wrapper\n}\n\n/**\n * Wrap a given event to management a dispatching.\n * @param {EventTarget} eventTarget The event target of this dispatching.\n * @param {Object} event The event to wrap.\n * @returns {Event} The wrapper instance.\n * @private\n */\nexport function wrapEvent(eventTarget, event) {\n const Wrapper = getWrapper(Object.getPrototypeOf(event))\n return new Wrapper(eventTarget, event)\n}\n\n/**\n * Get the immediateStopped flag of a given event.\n * @param {Event} event The event to get.\n * @returns {boolean} The flag to stop propagation immediately.\n * @private\n */\nexport function isStopped(event) {\n return pd(event).immediateStopped\n}\n\n/**\n * Set the current event phase of a given event.\n * @param {Event} event The event to set current target.\n * @param {number} eventPhase New event phase.\n * @returns {void}\n * @private\n */\nexport function setEventPhase(event, eventPhase) {\n pd(event).eventPhase = eventPhase\n}\n\n/**\n * Set the current target of a given event.\n * @param {Event} event The event to set current target.\n * @param {EventTarget|null} currentTarget New current target.\n * @returns {void}\n * @private\n */\nexport function setCurrentTarget(event, currentTarget) {\n pd(event).currentTarget = currentTarget\n}\n\n/**\n * Set a passive listener of a given event.\n * @param {Event} event The event to set current target.\n * @param {Function|null} passiveListener New passive listener.\n * @returns {void}\n * @private\n */\nexport function setPassiveListener(event, passiveListener) {\n pd(event).passiveListener = passiveListener\n}\n","import {\n isStopped,\n setCurrentTarget,\n setEventPhase,\n setPassiveListener,\n wrapEvent,\n} from \"./event.mjs\"\n\n/**\n * @typedef {object} ListenerNode\n * @property {Function} listener\n * @property {1|2|3} listenerType\n * @property {boolean} passive\n * @property {boolean} once\n * @property {ListenerNode|null} next\n * @private\n */\n\n/**\n * @type {WeakMap<object, Map<string, ListenerNode>>}\n * @private\n */\nconst listenersMap = new WeakMap()\n\n// Listener types\nconst CAPTURE = 1\nconst BUBBLE = 2\nconst ATTRIBUTE = 3\n\n/**\n * Check whether a given value is an object or not.\n * @param {any} x The value to check.\n * @returns {boolean} `true` if the value is an object.\n */\nfunction isObject(x) {\n return x !== null && typeof x === \"object\" //eslint-disable-line no-restricted-syntax\n}\n\n/**\n * Get listeners.\n * @param {EventTarget} eventTarget The event target to get.\n * @returns {Map<string, ListenerNode>} The listeners.\n * @private\n */\nfunction getListeners(eventTarget) {\n const listeners = listenersMap.get(eventTarget)\n if (listeners == null) {\n throw new TypeError(\n \"'this' is expected an EventTarget object, but got another value.\"\n )\n }\n return listeners\n}\n\n/**\n * Get the property descriptor for the event attribute of a given event.\n * @param {string} eventName The event name to get property descriptor.\n * @returns {PropertyDescriptor} The property descriptor.\n * @private\n */\nfunction defineEventAttributeDescriptor(eventName) {\n return {\n get() {\n const listeners = getListeners(this)\n let node = listeners.get(eventName)\n while (node != null) {\n if (node.listenerType === ATTRIBUTE) {\n return node.listener\n }\n node = node.next\n }\n return null\n },\n\n set(listener) {\n if (typeof listener !== \"function\" && !isObject(listener)) {\n listener = null // eslint-disable-line no-param-reassign\n }\n const listeners = getListeners(this)\n\n // Traverse to the tail while removing old value.\n let prev = null\n let node = listeners.get(eventName)\n while (node != null) {\n if (node.listenerType === ATTRIBUTE) {\n // Remove old value.\n if (prev !== null) {\n prev.next = node.next\n } else if (node.next !== null) {\n listeners.set(eventName, node.next)\n } else {\n listeners.delete(eventName)\n }\n } else {\n prev = node\n }\n\n node = node.next\n }\n\n // Add new value.\n if (listener !== null) {\n const newNode = {\n listener,\n listenerType: ATTRIBUTE,\n passive: false,\n once: false,\n next: null,\n }\n if (prev === null) {\n listeners.set(eventName, newNode)\n } else {\n prev.next = newNode\n }\n }\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Define an event attribute (e.g. `eventTarget.onclick`).\n * @param {Object} eventTargetPrototype The event target prototype to define an event attrbite.\n * @param {string} eventName The event name to define.\n * @returns {void}\n */\nfunction defineEventAttribute(eventTargetPrototype, eventName) {\n Object.defineProperty(\n eventTargetPrototype,\n `on${eventName}`,\n defineEventAttributeDescriptor(eventName)\n )\n}\n\n/**\n * Define a custom EventTarget with event attributes.\n * @param {string[]} eventNames Event names for event attributes.\n * @returns {EventTarget} The custom EventTarget.\n * @private\n */\nfunction defineCustomEventTarget(eventNames) {\n /** CustomEventTarget */\n function CustomEventTarget() {\n EventTarget.call(this)\n }\n\n CustomEventTarget.prototype = Object.create(EventTarget.prototype, {\n constructor: {\n value: CustomEventTarget,\n configurable: true,\n writable: true,\n },\n })\n\n for (let i = 0; i < eventNames.length; ++i) {\n defineEventAttribute(CustomEventTarget.prototype, eventNames[i])\n }\n\n return CustomEventTarget\n}\n\n/**\n * EventTarget.\n *\n * - This is constructor if no arguments.\n * - This is a function which returns a CustomEventTarget constructor if there are arguments.\n *\n * For example:\n *\n * class A extends EventTarget {}\n * class B extends EventTarget(\"message\") {}\n * class C extends EventTarget(\"message\", \"error\") {}\n * class D extends EventTarget([\"message\", \"error\"]) {}\n */\nfunction EventTarget() {\n /*eslint-disable consistent-return */\n if (this instanceof EventTarget) {\n listenersMap.set(this, new Map())\n return\n }\n if (arguments.length === 1 && Array.isArray(arguments[0])) {\n return defineCustomEventTarget(arguments[0])\n }\n if (arguments.length > 0) {\n const types = new Array(arguments.length)\n for (let i = 0; i < arguments.length; ++i) {\n types[i] = arguments[i]\n }\n return defineCustomEventTarget(types)\n }\n throw new TypeError(\"Cannot call a class as a function\")\n /*eslint-enable consistent-return */\n}\n\n// Should be enumerable, but class methods are not enumerable.\nEventTarget.prototype = {\n /**\n * Add a given listener to this event target.\n * @param {string} eventName The event name to add.\n * @param {Function} listener The listener to add.\n * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener.\n * @returns {void}\n */\n addEventListener(eventName, listener, options) {\n if (listener == null) {\n return\n }\n if (typeof listener !== \"function\" && !isObject(listener)) {\n throw new TypeError(\"'listener' should be a function or an object.\")\n }\n\n const listeners = getListeners(this)\n const optionsIsObj = isObject(options)\n const capture = optionsIsObj\n ? Boolean(options.capture)\n : Boolean(options)\n const listenerType = capture ? CAPTURE : BUBBLE\n const newNode = {\n listener,\n listenerType,\n passive: optionsIsObj && Boolean(options.passive),\n once: optionsIsObj && Boolean(options.once),\n next: null,\n }\n\n // Set it as the first node if the first node is null.\n let node = listeners.get(eventName)\n if (node === undefined) {\n listeners.set(eventName, newNode)\n return\n }\n\n // Traverse to the tail while checking duplication..\n let prev = null\n while (node != null) {\n if (\n node.listener === listener &&\n node.listenerType === listenerType\n ) {\n // Should ignore duplication.\n return\n }\n prev = node\n node = node.next\n }\n\n // Add it.\n prev.next = newNode\n },\n\n /**\n * Remove a given listener from this event target.\n * @param {string} eventName The event name to remove.\n * @param {Function} listener The listener to remove.\n * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener.\n * @returns {void}\n */\n removeEventListener(eventName, listener, options) {\n if (listener == null) {\n return\n }\n\n const listeners = getListeners(this)\n const capture = isObject(options)\n ? Boolean(options.capture)\n : Boolean(options)\n const listenerType = capture ? CAPTURE : BUBBLE\n\n let prev = null\n let node = listeners.get(eventName)\n while (node != null) {\n if (\n node.listener === listener &&\n node.listenerType === listenerType\n ) {\n if (prev !== null) {\n prev.next = node.next\n } else if (node.next !== null) {\n listeners.set(eventName, node.next)\n } else {\n listeners.delete(eventName)\n }\n return\n }\n\n prev = node\n node = node.next\n }\n },\n\n /**\n * Dispatch a given event.\n * @param {Event|{type:string}} event The event to dispatch.\n * @returns {boolean} `false` if canceled.\n */\n dispatchEvent(event) {\n if (event == null || typeof event.type !== \"string\") {\n throw new TypeError('\"event.type\" should be a string.')\n }\n\n // If listeners aren't registered, terminate.\n const listeners = getListeners(this)\n const eventName = event.type\n let node = listeners.get(eventName)\n if (node == null) {\n return true\n }\n\n // Since we cannot rewrite several properties, so wrap object.\n const wrappedEvent = wrapEvent(this, event)\n\n // This doesn't process capturing phase and bubbling phase.\n // This isn't participating in a tree.\n let prev = null\n while (node != null) {\n // Remove this listener if it's once\n if (node.once) {\n if (prev !== null) {\n prev.next = node.next\n } else if (node.next !== null) {\n listeners.set(eventName, node.next)\n } else {\n listeners.delete(eventName)\n }\n } else {\n prev = node\n }\n\n // Call this listener\n setPassiveListener(\n wrappedEvent,\n node.passive ? node.listener : null\n )\n if (typeof node.listener === \"function\") {\n try {\n node.listener.call(this, wrappedEvent)\n } catch (err) {\n if (\n typeof console !== \"undefined\" &&\n typeof console.error === \"function\"\n ) {\n console.error(err)\n }\n }\n } else if (\n node.listenerType !== ATTRIBUTE &&\n typeof node.listener.handleEvent === \"function\"\n ) {\n node.listener.handleEvent(wrappedEvent)\n }\n\n // Break if `event.stopImmediatePropagation` was called.\n if (isStopped(wrappedEvent)) {\n break\n }\n\n node = node.next\n }\n setPassiveListener(wrappedEvent, null)\n setEventPhase(wrappedEvent, 0)\n setCurrentTarget(wrappedEvent, null)\n\n return !wrappedEvent.defaultPrevented\n },\n}\n\n// `constructor` is not enumerable.\nObject.defineProperty(EventTarget.prototype, \"constructor\", {\n value: EventTarget,\n configurable: true,\n writable: true,\n})\n\n// Ensure `eventTarget instanceof window.EventTarget` is `true`.\nif (\n typeof window !== \"undefined\" &&\n typeof window.EventTarget !== \"undefined\"\n) {\n Object.setPrototypeOf(EventTarget.prototype, window.EventTarget.prototype)\n}\n\nexport { defineEventAttribute, EventTarget }\nexport default EventTarget\n"],"names":[],"mappings":";;;;;AAAA;;;;;;;;;;;;;;;;;;;AAmBA,MAAM,WAAW,GAAG,IAAI,OAAO,GAAE;;;;;;;AAOjC,MAAM,QAAQ,GAAG,IAAI,OAAO,GAAE;;;;;;;;AAQ9B,SAAS,EAAE,CAAC,KAAK,EAAE;IACf,MAAM,IAAI,GAAG,WAAW,CAAC,GAAG,CAAC,KAAK,EAAC;IACnC,OAAO,CAAC,MAAM;QACV,IAAI,IAAI,IAAI;QACZ,6CAA6C;QAC7C,KAAK;MACR;IACD,OAAO,IAAI;CACd;;;;;;AAMD,SAAS,aAAa,CAAC,IAAI,EAAE;IACzB,IAAI,IAAI,CAAC,eAAe,IAAI,IAAI,EAAE;QAC9B;YACI,OAAO,OAAO,KAAK,WAAW;YAC9B,OAAO,OAAO,CAAC,KAAK,KAAK,UAAU;UACrC;YACE,OAAO,CAAC,KAAK;gBACT,oEAAoE;gBACpE,IAAI,CAAC,eAAe;cACvB;SACJ;QACD,MAAM;KACT;IACD,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,UAAU,EAAE;QACxB,MAAM;KACT;;IAED,IAAI,CAAC,QAAQ,GAAG,KAAI;IACpB,IAAI,OAAO,IAAI,CAAC,KAAK,CAAC,cAAc,KAAK,UAAU,EAAE;QACjD,IAAI,CAAC,KAAK,CAAC,cAAc,GAAE;KAC9B;CACJ;;;;;;;;;;;;AAYD,SAAS,KAAK,CAAC,WAAW,EAAE,KAAK,EAAE;IAC/B,WAAW,CAAC,GAAG,CAAC,IAAI,EAAE;QAClB,WAAW;QACX,KAAK;QACL,UAAU,EAAE,CAAC;QACb,aAAa,EAAE,WAAW;QAC1B,QAAQ,EAAE,KAAK;QACf,OAAO,EAAE,KAAK;QACd,gBAAgB,EAAE,KAAK;QACvB,eAAe,EAAE,IAAI;QACrB,SAAS,EAAE,KAAK,CAAC,SAAS,IAAI,IAAI,CAAC,GAAG,EAAE;KAC3C,EAAC;;;IAGF,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,WAAW,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE,EAAC;;;IAG5E,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC,KAAK,EAAC;IAC/B,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,MAAM,EAAE,EAAE,CAAC,EAAE;QAClC,MAAM,GAAG,GAAG,IAAI,CAAC,CAAC,EAAC;QACnB,IAAI,EAAE,GAAG,IAAI,IAAI,CAAC,EAAE;YAChB,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,GAAG,EAAE,wBAAwB,CAAC,GAAG,CAAC,EAAC;SAClE;KACJ;CACJ;;;AAGD,KAAK,CAAC,SAAS,GAAG;;;;;IAKd,IAAI,IAAI,GAAG;QACP,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,IAAI;KAC7B;;;;;;IAMD,IAAI,MAAM,GAAG;QACT,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,WAAW;KAC9B;;;;;;IAMD,IAAI,aAAa,GAAG;QAChB,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,aAAa;KAChC;;;;;IAKD,YAAY,GAAG;QACX,MAAM,aAAa,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC,cAAa;QAC5C,IAAI,aAAa,IAAI,IAAI,EAAE;YACvB,OAAO,EAAE;SACZ;QACD,OAAO,CAAC,aAAa,CAAC;KACzB;;;;;;IAMD,IAAI,IAAI,GAAG;QACP,OAAO,CAAC;KACX;;;;;;IAMD,IAAI,eAAe,GAAG;QAClB,OAAO,CAAC;KACX;;;;;;IAMD,IAAI,SAAS,GAAG;QACZ,OAAO,CAAC;KACX;;;;;;IAMD,IAAI,cAAc,GAAG;QACjB,OAAO,CAAC;KACX;;;;;;IAMD,IAAI,UAAU,GAAG;QACb,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,UAAU;KAC7B;;;;;;IAMD,eAAe,GAAG;QACd,MAAM,IAAI,GAAG,EAAE,CAAC,IAAI,EAAC;;QAErB,IAAI,CAAC,OAAO,GAAG,KAAI;QACnB,IAAI,OAAO,IAAI,CAAC,KAAK,CAAC,eAAe,KAAK,UAAU,EAAE;YAClD,IAAI,CAAC,KAAK,CAAC,eAAe,GAAE;SAC/B;KACJ;;;;;;IAMD,wBAAwB,GAAG;QACvB,MAAM,IAAI,GAAG,EAAE,CAAC,IAAI,EAAC;;QAErB,IAAI,CAAC,OAAO,GAAG,KAAI;QACnB,IAAI,CAAC,gBAAgB,GAAG,KAAI;QAC5B,IAAI,OAAO,IAAI,CAAC,KAAK,CAAC,wBAAwB,KAAK,UAAU,EAAE;YAC3D,IAAI,CAAC,KAAK,CAAC,wBAAwB,GAAE;SACxC;KACJ;;;;;;IAMD,IAAI,OAAO,GAAG;QACV,OAAO,OAAO,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC;KACzC;;;;;;IAMD,IAAI,UAAU,GAAG;QACb,OAAO,OAAO,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,UAAU,CAAC;KAC5C;;;;;;IAMD,cAAc,GAAG;QACb,aAAa,CAAC,EAAE,CAAC,IAAI,CAAC,EAAC;KAC1B;;;;;;IAMD,IAAI,gBAAgB,GAAG;QACnB,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,QAAQ;KAC3B;;;;;;IAMD,IAAI,QAAQ,GAAG;QACX,OAAO,OAAO,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,QAAQ,CAAC;KAC1C;;;;;;IAMD,IAAI,SAAS,GAAG;QACZ,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,SAAS;KAC5B;;;;;;;IAOD,IAAI,UAAU,GAAG;QACb,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,WAAW;KAC9B;;;;;;;IAOD,IAAI,YAAY,GAAG;QACf,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,OAAO;KAC1B;IACD,IAAI,YAAY,CAAC,KAAK,EAAE;QACpB,IAAI,CAAC,KAAK,EAAE;YACR,MAAM;SACT;QACD,MAAM,IAAI,GAAG,EAAE,CAAC,IAAI,EAAC;;QAErB,IAAI,CAAC,OAAO,GAAG,KAAI;QACnB,IAAI,OAAO,IAAI,CAAC,KAAK,CAAC,YAAY,KAAK,SAAS,EAAE;YAC9C,IAAI,CAAC,KAAK,CAAC,YAAY,GAAG,KAAI;SACjC;KACJ;;;;;;;IAOD,IAAI,WAAW,GAAG;QACd,OAAO,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,QAAQ;KAC5B;IACD,IAAI,WAAW,CAAC,KAAK,EAAE;QACnB,IAAI,CAAC,KAAK,EAAE;YACR,aAAa,CAAC,EAAE,CAAC,IAAI,CAAC,EAAC;SAC1B;KACJ;;;;;;;;;IASD,SAAS,GAAG;;KAEX;EACJ;;;AAGD,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,SAAS,EAAE,aAAa,EAAE;IAClD,KAAK,EAAE,KAAK;IACZ,YAAY,EAAE,IAAI;IAClB,QAAQ,EAAE,IAAI;CACjB,EAAC;;;AAGF,IAAI,OAAO,MAAM,KAAK,WAAW,IAAI,OAAO,MAAM,CAAC,KAAK,KAAK,WAAW,EAAE;IACtE,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,SAAS,EAAE,MAAM,CAAC,KAAK,CAAC,SAAS,EAAC;;;IAG9D,QAAQ,CAAC,GAAG,CAAC,MAAM,CAAC,KAAK,CAAC,SAAS,EAAE,KAAK,EAAC;CAC9C;;;;;;;;AAQD,SAAS,wBAAwB,CAAC,GAAG,EAAE;IACnC,OAAO;QACH,GAAG,GAAG;YACF,OAAO,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC;SAC7B;QACD,GAAG,CAAC,KAAK,EAAE;YACP,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,MAAK;SAC9B;QACD,YAAY,EAAE,IAAI;QAClB,UAAU,EAAE,IAAI;KACnB;CACJ;;;;;;;;AAQD,SAAS,oBAAoB,CAAC,GAAG,EAAE;IAC/B,OAAO;QACH,KAAK,GAAG;YACJ,MAAM,KAAK,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC,MAAK;YAC5B,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,KAAK,EAAE,SAAS,CAAC;SAC5C;QACD,YAAY,EAAE,IAAI;QAClB,UAAU,EAAE,IAAI;KACnB;CACJ;;;;;;;;;AASD,SAAS,aAAa,CAAC,SAAS,EAAE,KAAK,EAAE;IACrC,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC,KAAK,EAAC;IAC/B,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE;QACnB,OAAO,SAAS;KACnB;;;IAGD,SAAS,WAAW,CAAC,WAAW,EAAE,KAAK,EAAE;QACrC,SAAS,CAAC,IAAI,CAAC,IAAI,EAAE,WAAW,EAAE,KAAK,EAAC;KAC3C;;IAED,WAAW,CAAC,SAAS,GAAG,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,SAAS,EAAE;QACvD,WAAW,EAAE,EAAE,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE;KAC1E,EAAC;;;IAGF,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,MAAM,EAAE,EAAE,CAAC,EAAE;QAClC,MAAM,GAAG,GAAG,IAAI,CAAC,CAAC,EAAC;QACnB,IAAI,EAAE,GAAG,IAAI,SAAS,CAAC,SAAS,CAAC,EAAE;YAC/B,MAAM,UAAU,GAAG,MAAM,CAAC,wBAAwB,CAAC,KAAK,EAAE,GAAG,EAAC;YAC9D,MAAM,MAAM,GAAG,OAAO,UAAU,CAAC,KAAK,KAAK,WAAU;YACrD,MAAM,CAAC,cAAc;gBACjB,WAAW,CAAC,SAAS;gBACrB,GAAG;gBACH,MAAM;sBACA,oBAAoB,CAAC,GAAG,CAAC;sBACzB,wBAAwB,CAAC,GAAG,CAAC;cACtC;SACJ;KACJ;;IAED,OAAO,WAAW;CACrB;;;;;;;;AAQD,SAAS,UAAU,CAAC,KAAK,EAAE;IACvB,IAAI,KAAK,IAAI,IAAI,IAAI,KAAK,KAAK,MAAM,CAAC,SAAS,EAAE;QAC7C,OAAO,KAAK;KACf;;IAED,IAAI,OAAO,GAAG,QAAQ,CAAC,GAAG,CAAC,KAAK,EAAC;IACjC,IAAI,OAAO,IAAI,IAAI,EAAE;QACjB,OAAO,GAAG,aAAa,CAAC,UAAU,CAAC,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,EAAC;QACxE,QAAQ,CAAC,GAAG,CAAC,KAAK,EAAE,OAAO,EAAC;KAC/B;IACD,OAAO,OAAO;CACjB;;;;;;;;;AASD,AAAO,SAAS,SAAS,CAAC,WAAW,EAAE,KAAK,EAAE;IAC1C,MAAM,OAAO,GAAG,UAAU,CAAC,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,EAAC;IACxD,OAAO,IAAI,OAAO,CAAC,WAAW,EAAE,KAAK,CAAC;CACzC;;;;;;;;AAQD,AAAO,SAAS,SAAS,CAAC,KAAK,EAAE;IAC7B,OAAO,EAAE,CAAC,KAAK,CAAC,CAAC,gBAAgB;CACpC;;;;;;;;;AASD,AAAO,SAAS,aAAa,CAAC,KAAK,EAAE,UAAU,EAAE;IAC7C,EAAE,CAAC,KAAK,CAAC,CAAC,UAAU,GAAG,WAAU;CACpC;;;;;;;;;AASD,AAAO,SAAS,gBAAgB,CAAC,KAAK,EAAE,aAAa,EAAE;IACnD,EAAE,CAAC,KAAK,CAAC,CAAC,aAAa,GAAG,cAAa;CAC1C;;;;;;;;;AASD,AAAO,SAAS,kBAAkB,CAAC,KAAK,EAAE,eAAe,EAAE;IACvD,EAAE,CAAC,KAAK,CAAC,CAAC,eAAe,GAAG,gBAAe;CAC9C;;ACtdD;;;;;;;;;;;;;;AAcA,MAAM,YAAY,GAAG,IAAI,OAAO,GAAE;;;AAGlC,MAAM,OAAO,GAAG,EAAC;AACjB,MAAM,MAAM,GAAG,EAAC;AAChB,MAAM,SAAS,GAAG,EAAC;;;;;;;AAOnB,SAAS,QAAQ,CAAC,CAAC,EAAE;IACjB,OAAO,CAAC,KAAK,IAAI,IAAI,OAAO,CAAC,KAAK,QAAQ;CAC7C;;;;;;;;AAQD,SAAS,YAAY,CAAC,WAAW,EAAE;IAC/B,MAAM,SAAS,GAAG,YAAY,CAAC,GAAG,CAAC,WAAW,EAAC;IAC/C,IAAI,SAAS,IAAI,IAAI,EAAE;QACnB,MAAM,IAAI,SAAS;YACf,kEAAkE;SACrE;KACJ;IACD,OAAO,SAAS;CACnB;;;;;;;;AAQD,SAAS,8BAA8B,CAAC,SAAS,EAAE;IAC/C,OAAO;QACH,GAAG,GAAG;YACF,MAAM,SAAS,GAAG,YAAY,CAAC,IAAI,EAAC;YACpC,IAAI,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,SAAS,EAAC;YACnC,OAAO,IAAI,IAAI,IAAI,EAAE;gBACjB,IAAI,IAAI,CAAC,YAAY,KAAK,SAAS,EAAE;oBACjC,OAAO,IAAI,CAAC,QAAQ;iBACvB;gBACD,IAAI,GAAG,IAAI,CAAC,KAAI;aACnB;YACD,OAAO,IAAI;SACd;;QAED,GAAG,CAAC,QAAQ,EAAE;YACV,IAAI,OAAO,QAAQ,KAAK,UAAU,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE;gBACvD,QAAQ,GAAG,KAAI;aAClB;YACD,MAAM,SAAS,GAAG,YAAY,CAAC,IAAI,EAAC;;;YAGpC,IAAI,IAAI,GAAG,KAAI;YACf,IAAI,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,SAAS,EAAC;YACnC,OAAO,IAAI,IAAI,IAAI,EAAE;gBACjB,IAAI,IAAI,CAAC,YAAY,KAAK,SAAS,EAAE;;oBAEjC,IAAI,IAAI,KAAK,IAAI,EAAE;wBACf,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,KAAI;qBACxB,MAAM,IAAI,IAAI,CAAC,IAAI,KAAK,IAAI,EAAE;wBAC3B,SAAS,CAAC,GAAG,CAAC,SAAS,EAAE,IAAI,CAAC,IAAI,EAAC;qBACtC,MAAM;wBACH,SAAS,CAAC,MAAM,CAAC,SAAS,EAAC;qBAC9B;iBACJ,MAAM;oBACH,IAAI,GAAG,KAAI;iBACd;;gBAED,IAAI,GAAG,IAAI,CAAC,KAAI;aACnB;;;YAGD,IAAI,QAAQ,KAAK,IAAI,EAAE;gBACnB,MAAM,OAAO,GAAG;oBACZ,QAAQ;oBACR,YAAY,EAAE,SAAS;oBACvB,OAAO,EAAE,KAAK;oBACd,IAAI,EAAE,KAAK;oBACX,IAAI,EAAE,IAAI;kBACb;gBACD,IAAI,IAAI,KAAK,IAAI,EAAE;oBACf,SAAS,CAAC,GAAG,CAAC,SAAS,EAAE,OAAO,EAAC;iBACpC,MAAM;oBACH,IAAI,CAAC,IAAI,GAAG,QAAO;iBACtB;aACJ;SACJ;QACD,YAAY,EAAE,IAAI;QAClB,UAAU,EAAE,IAAI;KACnB;CACJ;;;;;;;;AAQD,SAAS,oBAAoB,CAAC,oBAAoB,EAAE,SAAS,EAAE;IAC3D,MAAM,CAAC,cAAc;QACjB,oBAAoB;QACpB,CAAC,EAAE,EAAE,SAAS,CAAC,CAAC;QAChB,8BAA8B,CAAC,SAAS,CAAC;MAC5C;CACJ;;;;;;;;AAQD,SAAS,uBAAuB,CAAC,UAAU,EAAE;;IAEzC,SAAS,iBAAiB,GAAG;QACzB,WAAW,CAAC,IAAI,CAAC,IAAI,EAAC;KACzB;;IAED,iBAAiB,CAAC,SAAS,GAAG,MAAM,CAAC,MAAM,CAAC,WAAW,CAAC,SAAS,EAAE;QAC/D,WAAW,EAAE;YACT,KAAK,EAAE,iBAAiB;YACxB,YAAY,EAAE,IAAI;YAClB,QAAQ,EAAE,IAAI;SACjB;KACJ,EAAC;;IAEF,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,UAAU,CAAC,MAAM,EAAE,EAAE,CAAC,EAAE;QACxC,oBAAoB,CAAC,iBAAiB,CAAC,SAAS,EAAE,UAAU,CAAC,CAAC,CAAC,EAAC;KACnE;;IAED,OAAO,iBAAiB;CAC3B;;;;;;;;;;;;;;;AAeD,SAAS,WAAW,GAAG;;IAEnB,IAAI,IAAI,YAAY,WAAW,EAAE;QAC7B,YAAY,CAAC,GAAG,CAAC,IAAI,EAAE,IAAI,GAAG,EAAE,EAAC;QACjC,MAAM;KACT;IACD,IAAI,SAAS,CAAC,MAAM,KAAK,CAAC,IAAI,KAAK,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,EAAE;QACvD,OAAO,uBAAuB,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;KAC/C;IACD,IAAI,SAAS,CAAC,MAAM,GAAG,CAAC,EAAE;QACtB,MAAM,KAAK,GAAG,IAAI,KAAK,CAAC,SAAS,CAAC,MAAM,EAAC;QACzC,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,SAAS,CAAC,MAAM,EAAE,EAAE,CAAC,EAAE;YACvC,KAAK,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC,CAAC,EAAC;SAC1B;QACD,OAAO,uBAAuB,CAAC,KAAK,CAAC;KACxC;IACD,MAAM,IAAI,SAAS,CAAC,mCAAmC,CAAC;;CAE3D;;;AAGD,WAAW,CAAC,SAAS,GAAG;;;;;;;;IAQpB,gBAAgB,CAAC,SAAS,EAAE,QAAQ,EAAE,OAAO,EAAE;QAC3C,IAAI,QAAQ,IAAI,IAAI,EAAE;YAClB,MAAM;SACT;QACD,IAAI,OAAO,QAAQ,KAAK,UAAU,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE;YACvD,MAAM,IAAI,SAAS,CAAC,+CAA+C,CAAC;SACvE;;QAED,MAAM,SAAS,GAAG,YAAY,CAAC,IAAI,EAAC;QACpC,MAAM,YAAY,GAAG,QAAQ,CAAC,OAAO,EAAC;QACtC,MAAM,OAAO,GAAG,YAAY;cACtB,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC;cACxB,OAAO,CAAC,OAAO,EAAC;QACtB,MAAM,YAAY,GAAG,OAAO,GAAG,OAAO,GAAG,OAAM;QAC/C,MAAM,OAAO,GAAG;YACZ,QAAQ;YACR,YAAY;YACZ,OAAO,EAAE,YAAY,IAAI,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC;YACjD,IAAI,EAAE,YAAY,IAAI,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC;YAC3C,IAAI,EAAE,IAAI;UACb;;;QAGD,IAAI,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,SAAS,EAAC;QACnC,IAAI,IAAI,KAAK,SAAS,EAAE;YACpB,SAAS,CAAC,GAAG,CAAC,SAAS,EAAE,OAAO,EAAC;YACjC,MAAM;SACT;;;QAGD,IAAI,IAAI,GAAG,KAAI;QACf,OAAO,IAAI,IAAI,IAAI,EAAE;YACjB;gBACI,IAAI,CAAC,QAAQ,KAAK,QAAQ;gBAC1B,IAAI,CAAC,YAAY,KAAK,YAAY;cACpC;;gBAEE,MAAM;aACT;YACD,IAAI,GAAG,KAAI;YACX,IAAI,GAAG,IAAI,CAAC,KAAI;SACnB;;;QAGD,IAAI,CAAC,IAAI,GAAG,QAAO;KACtB;;;;;;;;;IASD,mBAAmB,CAAC,SAAS,EAAE,QAAQ,EAAE,OAAO,EAAE;QAC9C,IAAI,QAAQ,IAAI,IAAI,EAAE;YAClB,MAAM;SACT;;QAED,MAAM,SAAS,GAAG,YAAY,CAAC,IAAI,EAAC;QACpC,MAAM,OAAO,GAAG,QAAQ,CAAC,OAAO,CAAC;cAC3B,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC;cACxB,OAAO,CAAC,OAAO,EAAC;QACtB,MAAM,YAAY,GAAG,OAAO,GAAG,OAAO,GAAG,OAAM;;QAE/C,IAAI,IAAI,GAAG,KAAI;QACf,IAAI,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,SAAS,EAAC;QACnC,OAAO,IAAI,IAAI,IAAI,EAAE;YACjB;gBACI,IAAI,CAAC,QAAQ,KAAK,QAAQ;gBAC1B,IAAI,CAAC,YAAY,KAAK,YAAY;cACpC;gBACE,IAAI,IAAI,KAAK,IAAI,EAAE;oBACf,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,KAAI;iBACxB,MAAM,IAAI,IAAI,CAAC,IAAI,KAAK,IAAI,EAAE;oBAC3B,SAAS,CAAC,GAAG,CAAC,SAAS,EAAE,IAAI,CAAC,IAAI,EAAC;iBACtC,MAAM;oBACH,SAAS,CAAC,MAAM,CAAC,SAAS,EAAC;iBAC9B;gBACD,MAAM;aACT;;YAED,IAAI,GAAG,KAAI;YACX,IAAI,GAAG,IAAI,CAAC,KAAI;SACnB;KACJ;;;;;;;IAOD,aAAa,CAAC,KAAK,EAAE;QACjB,IAAI,KAAK,IAAI,IAAI,IAAI,OAAO,KAAK,CAAC,IAAI,KAAK,QAAQ,EAAE;YACjD,MAAM,IAAI,SAAS,CAAC,kCAAkC,CAAC;SAC1D;;;QAGD,MAAM,SAAS,GAAG,YAAY,CAAC,IAAI,EAAC;QACpC,MAAM,SAAS,GAAG,KAAK,CAAC,KAAI;QAC5B,IAAI,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,SAAS,EAAC;QACnC,IAAI,IAAI,IAAI,IAAI,EAAE;YACd,OAAO,IAAI;SACd;;;QAGD,MAAM,YAAY,GAAG,SAAS,CAAC,IAAI,EAAE,KAAK,EAAC;;;;QAI3C,IAAI,IAAI,GAAG,KAAI;QACf,OAAO,IAAI,IAAI,IAAI,EAAE;;YAEjB,IAAI,IAAI,CAAC,IAAI,EAAE;gBACX,IAAI,IAAI,KAAK,IAAI,EAAE;oBACf,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,KAAI;iBACxB,MAAM,IAAI,IAAI,CAAC,IAAI,KAAK,IAAI,EAAE;oBAC3B,SAAS,CAAC,GAAG,CAAC,SAAS,EAAE,IAAI,CAAC,IAAI,EAAC;iBACtC,MAAM;oBACH,SAAS,CAAC,MAAM,CAAC,SAAS,EAAC;iBAC9B;aACJ,MAAM;gBACH,IAAI,GAAG,KAAI;aACd;;;YAGD,kBAAkB;gBACd,YAAY;gBACZ,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,QAAQ,GAAG,IAAI;cACtC;YACD,IAAI,OAAO,IAAI,CAAC,QAAQ,KAAK,UAAU,EAAE;gBACrC,IAAI;oBACA,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,EAAE,YAAY,EAAC;iBACzC,CAAC,OAAO,GAAG,EAAE;oBACV;wBACI,OAAO,OAAO,KAAK,WAAW;wBAC9B,OAAO,OAAO,CAAC,KAAK,KAAK,UAAU;sBACrC;wBACE,OAAO,CAAC,KAAK,CAAC,GAAG,EAAC;qBACrB;iBACJ;aACJ,MAAM;gBACH,IAAI,CAAC,YAAY,KAAK,SAAS;gBAC/B,OAAO,IAAI,CAAC,QAAQ,CAAC,WAAW,KAAK,UAAU;cACjD;gBACE,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,YAAY,EAAC;aAC1C;;;YAGD,IAAI,SAAS,CAAC,YAAY,CAAC,EAAE;gBACzB,KAAK;aACR;;YAED,IAAI,GAAG,IAAI,CAAC,KAAI;SACnB;QACD,kBAAkB,CAAC,YAAY,EAAE,IAAI,EAAC;QACtC,aAAa,CAAC,YAAY,EAAE,CAAC,EAAC;QAC9B,gBAAgB,CAAC,YAAY,EAAE,IAAI,EAAC;;QAEpC,OAAO,CAAC,YAAY,CAAC,gBAAgB;KACxC;EACJ;;;AAGD,MAAM,CAAC,cAAc,CAAC,WAAW,CAAC,SAAS,EAAE,aAAa,EAAE;IACxD,KAAK,EAAE,WAAW;IAClB,YAAY,EAAE,IAAI;IAClB,QAAQ,EAAE,IAAI;CACjB,EAAC;;;AAGF;IACI,OAAO,MAAM,KAAK,WAAW;IAC7B,OAAO,MAAM,CAAC,WAAW,KAAK,WAAW;EAC3C;IACE,MAAM,CAAC,cAAc,CAAC,WAAW,CAAC,SAAS,EAAE,MAAM,CAAC,WAAW,CAAC,SAAS,EAAC;CAC7E;;;;;"} \ No newline at end of file diff --git a/node_modules/event-target-shim/dist/event-target-shim.umd.js b/node_modules/event-target-shim/dist/event-target-shim.umd.js new file mode 100644 index 0000000..e7cf5d4 --- /dev/null +++ b/node_modules/event-target-shim/dist/event-target-shim.umd.js @@ -0,0 +1,6 @@ +/** + * @author Toru Nagashima <https://github.com/mysticatea> + * @copyright 2015 Toru Nagashima. All rights reserved. + * See LICENSE file in root directory for full license. + */(function(a,b){"object"==typeof exports&&"undefined"!=typeof module?b(exports):"function"==typeof define&&define.amd?define(["exports"],b):(a=a||self,b(a.EventTargetShim={}))})(this,function(a){"use strict";function b(a){return b="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},b(a)}function c(a){var b=u.get(a);return console.assert(null!=b,"'this' is expected an Event object, but got",a),b}function d(a){return null==a.passiveListener?void(!a.event.cancelable||(a.canceled=!0,"function"==typeof a.event.preventDefault&&a.event.preventDefault())):void("undefined"!=typeof console&&"function"==typeof console.error&&console.error("Unable to preventDefault inside passive event listener invocation.",a.passiveListener))}function e(a,b){u.set(this,{eventTarget:a,event:b,eventPhase:2,currentTarget:a,canceled:!1,stopped:!1,immediateStopped:!1,passiveListener:null,timeStamp:b.timeStamp||Date.now()}),Object.defineProperty(this,"isTrusted",{value:!1,enumerable:!0});for(var c,d=Object.keys(b),e=0;e<d.length;++e)c=d[e],c in this||Object.defineProperty(this,c,f(c))}function f(a){return{get:function(){return c(this).event[a]},set:function(b){c(this).event[a]=b},configurable:!0,enumerable:!0}}function g(a){return{value:function(){var b=c(this).event;return b[a].apply(b,arguments)},configurable:!0,enumerable:!0}}function h(a,b){function c(b,c){a.call(this,b,c)}var d=Object.keys(b);if(0===d.length)return a;c.prototype=Object.create(a.prototype,{constructor:{value:c,configurable:!0,writable:!0}});for(var e,h=0;h<d.length;++h)if(e=d[h],!(e in a.prototype)){var j=Object.getOwnPropertyDescriptor(b,e),k="function"==typeof j.value;Object.defineProperty(c.prototype,e,k?g(e):f(e))}return c}function i(a){if(null==a||a===Object.prototype)return e;var b=v.get(a);return null==b&&(b=h(i(Object.getPrototypeOf(a)),a),v.set(a,b)),b}function j(a,b){var c=i(Object.getPrototypeOf(b));return new c(a,b)}function k(a){return c(a).immediateStopped}function l(a,b){c(a).eventPhase=b}function m(a,b){c(a).currentTarget=b}function n(a,b){c(a).passiveListener=b}function o(a){return null!==a&&"object"===b(a)}function p(a){var b=w.get(a);if(null==b)throw new TypeError("'this' is expected an EventTarget object, but got another value.");return b}function q(a){return{get:function(){for(var b=p(this),c=b.get(a);null!=c;){if(3===c.listenerType)return c.listener;c=c.next}return null},set:function(b){"function"==typeof b||o(b)||(b=null);for(var c=p(this),d=null,e=c.get(a);null!=e;)3===e.listenerType?null===d?null===e.next?c.delete(a):c.set(a,e.next):d.next=e.next:d=e,e=e.next;if(null!==b){var f={listener:b,listenerType:3,passive:!1,once:!1,next:null};null===d?c.set(a,f):d.next=f}},configurable:!0,enumerable:!0}}function r(a,b){Object.defineProperty(a,"on".concat(b),q(b))}function s(a){function b(){t.call(this)}b.prototype=Object.create(t.prototype,{constructor:{value:b,configurable:!0,writable:!0}});for(var c=0;c<a.length;++c)r(b.prototype,a[c]);return b}function t(){if(this instanceof t)return void w.set(this,new Map);if(1===arguments.length&&Array.isArray(arguments[0]))return s(arguments[0]);if(0<arguments.length){for(var a=Array(arguments.length),b=0;b<arguments.length;++b)a[b]=arguments[b];return s(a)}throw new TypeError("Cannot call a class as a function")}var u=new WeakMap,v=new WeakMap;e.prototype={get type(){return c(this).event.type},get target(){return c(this).eventTarget},get currentTarget(){return c(this).currentTarget},composedPath:function(){var a=c(this).currentTarget;return null==a?[]:[a]},get NONE(){return 0},get CAPTURING_PHASE(){return 1},get AT_TARGET(){return 2},get BUBBLING_PHASE(){return 3},get eventPhase(){return c(this).eventPhase},stopPropagation:function(){var a=c(this);a.stopped=!0,"function"==typeof a.event.stopPropagation&&a.event.stopPropagation()},stopImmediatePropagation:function(){var a=c(this);a.stopped=!0,a.immediateStopped=!0,"function"==typeof a.event.stopImmediatePropagation&&a.event.stopImmediatePropagation()},get bubbles(){return!!c(this).event.bubbles},get cancelable(){return!!c(this).event.cancelable},preventDefault:function(){d(c(this))},get defaultPrevented(){return c(this).canceled},get composed(){return!!c(this).event.composed},get timeStamp(){return c(this).timeStamp},get srcElement(){return c(this).eventTarget},get cancelBubble(){return c(this).stopped},set cancelBubble(a){if(a){var b=c(this);b.stopped=!0,"boolean"==typeof b.event.cancelBubble&&(b.event.cancelBubble=!0)}},get returnValue(){return!c(this).canceled},set returnValue(a){a||d(c(this))},initEvent:function(){}},Object.defineProperty(e.prototype,"constructor",{value:e,configurable:!0,writable:!0}),"undefined"!=typeof window&&"undefined"!=typeof window.Event&&(Object.setPrototypeOf(e.prototype,window.Event.prototype),v.set(window.Event.prototype,e));var w=new WeakMap,x=1,y=2;if(t.prototype={addEventListener:function(a,b,c){if(null!=b){if("function"!=typeof b&&!o(b))throw new TypeError("'listener' should be a function or an object.");var d=p(this),e=o(c),f=e?!!c.capture:!!c,g=f?x:y,h={listener:b,listenerType:g,passive:e&&!!c.passive,once:e&&!!c.once,next:null},i=d.get(a);if(void 0===i)return void d.set(a,h);for(var j=null;null!=i;){if(i.listener===b&&i.listenerType===g)return;j=i,i=i.next}j.next=h}},removeEventListener:function(a,b,c){if(null!=b)for(var d=p(this),e=o(c)?!!c.capture:!!c,f=e?x:y,g=null,h=d.get(a);null!=h;){if(h.listener===b&&h.listenerType===f)return void(null===g?null===h.next?d.delete(a):d.set(a,h.next):g.next=h.next);g=h,h=h.next}},dispatchEvent:function(a){if(null==a||"string"!=typeof a.type)throw new TypeError("\"event.type\" should be a string.");var b=p(this),c=a.type,d=b.get(c);if(null==d)return!0;for(var e=j(this,a),f=null;null!=d;){if(d.once?null===f?null===d.next?b.delete(c):b.set(c,d.next):f.next=d.next:f=d,n(e,d.passive?d.listener:null),"function"==typeof d.listener)try{d.listener.call(this,e)}catch(a){"undefined"!=typeof console&&"function"==typeof console.error&&console.error(a)}else d.listenerType!==3&&"function"==typeof d.listener.handleEvent&&d.listener.handleEvent(e);if(k(e))break;d=d.next}return n(e,null),l(e,0),m(e,null),!e.defaultPrevented}},Object.defineProperty(t.prototype,"constructor",{value:t,configurable:!0,writable:!0}),"undefined"!=typeof window&&"undefined"!=typeof window.EventTarget&&Object.setPrototypeOf(t.prototype,window.EventTarget.prototype),a.defineEventAttribute=r,a.EventTarget=t,a.default=t,Object.defineProperty(a,"__esModule",{value:!0}),"undefined"==typeof module&&"undefined"==typeof define){var z=Function("return this")();z.EventTargetShim=t,z.EventTargetShim.defineEventAttribute=r}}); +//# sourceMappingURL=event-target-shim.umd.js.map diff --git a/node_modules/event-target-shim/dist/event-target-shim.umd.js.map b/node_modules/event-target-shim/dist/event-target-shim.umd.js.map new file mode 100644 index 0000000..c5b2b60 --- /dev/null +++ b/node_modules/event-target-shim/dist/event-target-shim.umd.js.map @@ -0,0 +1 @@ +{"version":3,"file":"event-target-shim.umd.js","sources":["../src/event.mjs","../src/event-target.mjs"],"sourcesContent":["/**\n * @typedef {object} PrivateData\n * @property {EventTarget} eventTarget The event target.\n * @property {{type:string}} event The original event object.\n * @property {number} eventPhase The current event phase.\n * @property {EventTarget|null} currentTarget The current event target.\n * @property {boolean} canceled The flag to prevent default.\n * @property {boolean} stopped The flag to stop propagation.\n * @property {boolean} immediateStopped The flag to stop propagation immediately.\n * @property {Function|null} passiveListener The listener if the current listener is passive. Otherwise this is null.\n * @property {number} timeStamp The unix time.\n * @private\n */\n\n/**\n * Private data for event wrappers.\n * @type {WeakMap<Event, PrivateData>}\n * @private\n */\nconst privateData = new WeakMap()\n\n/**\n * Cache for wrapper classes.\n * @type {WeakMap<Object, Function>}\n * @private\n */\nconst wrappers = new WeakMap()\n\n/**\n * Get private data.\n * @param {Event} event The event object to get private data.\n * @returns {PrivateData} The private data of the event.\n * @private\n */\nfunction pd(event) {\n const retv = privateData.get(event)\n console.assert(\n retv != null,\n \"'this' is expected an Event object, but got\",\n event\n )\n return retv\n}\n\n/**\n * https://dom.spec.whatwg.org/#set-the-canceled-flag\n * @param data {PrivateData} private data.\n */\nfunction setCancelFlag(data) {\n if (data.passiveListener != null) {\n if (\n typeof console !== \"undefined\" &&\n typeof console.error === \"function\"\n ) {\n console.error(\n \"Unable to preventDefault inside passive event listener invocation.\",\n data.passiveListener\n )\n }\n return\n }\n if (!data.event.cancelable) {\n return\n }\n\n data.canceled = true\n if (typeof data.event.preventDefault === \"function\") {\n data.event.preventDefault()\n }\n}\n\n/**\n * @see https://dom.spec.whatwg.org/#interface-event\n * @private\n */\n/**\n * The event wrapper.\n * @constructor\n * @param {EventTarget} eventTarget The event target of this dispatching.\n * @param {Event|{type:string}} event The original event to wrap.\n */\nfunction Event(eventTarget, event) {\n privateData.set(this, {\n eventTarget,\n event,\n eventPhase: 2,\n currentTarget: eventTarget,\n canceled: false,\n stopped: false,\n immediateStopped: false,\n passiveListener: null,\n timeStamp: event.timeStamp || Date.now(),\n })\n\n // https://heycam.github.io/webidl/#Unforgeable\n Object.defineProperty(this, \"isTrusted\", { value: false, enumerable: true })\n\n // Define accessors\n const keys = Object.keys(event)\n for (let i = 0; i < keys.length; ++i) {\n const key = keys[i]\n if (!(key in this)) {\n Object.defineProperty(this, key, defineRedirectDescriptor(key))\n }\n }\n}\n\n// Should be enumerable, but class methods are not enumerable.\nEvent.prototype = {\n /**\n * The type of this event.\n * @type {string}\n */\n get type() {\n return pd(this).event.type\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n */\n get target() {\n return pd(this).eventTarget\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n */\n get currentTarget() {\n return pd(this).currentTarget\n },\n\n /**\n * @returns {EventTarget[]} The composed path of this event.\n */\n composedPath() {\n const currentTarget = pd(this).currentTarget\n if (currentTarget == null) {\n return []\n }\n return [currentTarget]\n },\n\n /**\n * Constant of NONE.\n * @type {number}\n */\n get NONE() {\n return 0\n },\n\n /**\n * Constant of CAPTURING_PHASE.\n * @type {number}\n */\n get CAPTURING_PHASE() {\n return 1\n },\n\n /**\n * Constant of AT_TARGET.\n * @type {number}\n */\n get AT_TARGET() {\n return 2\n },\n\n /**\n * Constant of BUBBLING_PHASE.\n * @type {number}\n */\n get BUBBLING_PHASE() {\n return 3\n },\n\n /**\n * The target of this event.\n * @type {number}\n */\n get eventPhase() {\n return pd(this).eventPhase\n },\n\n /**\n * Stop event bubbling.\n * @returns {void}\n */\n stopPropagation() {\n const data = pd(this)\n\n data.stopped = true\n if (typeof data.event.stopPropagation === \"function\") {\n data.event.stopPropagation()\n }\n },\n\n /**\n * Stop event bubbling.\n * @returns {void}\n */\n stopImmediatePropagation() {\n const data = pd(this)\n\n data.stopped = true\n data.immediateStopped = true\n if (typeof data.event.stopImmediatePropagation === \"function\") {\n data.event.stopImmediatePropagation()\n }\n },\n\n /**\n * The flag to be bubbling.\n * @type {boolean}\n */\n get bubbles() {\n return Boolean(pd(this).event.bubbles)\n },\n\n /**\n * The flag to be cancelable.\n * @type {boolean}\n */\n get cancelable() {\n return Boolean(pd(this).event.cancelable)\n },\n\n /**\n * Cancel this event.\n * @returns {void}\n */\n preventDefault() {\n setCancelFlag(pd(this))\n },\n\n /**\n * The flag to indicate cancellation state.\n * @type {boolean}\n */\n get defaultPrevented() {\n return pd(this).canceled\n },\n\n /**\n * The flag to be composed.\n * @type {boolean}\n */\n get composed() {\n return Boolean(pd(this).event.composed)\n },\n\n /**\n * The unix time of this event.\n * @type {number}\n */\n get timeStamp() {\n return pd(this).timeStamp\n },\n\n /**\n * The target of this event.\n * @type {EventTarget}\n * @deprecated\n */\n get srcElement() {\n return pd(this).eventTarget\n },\n\n /**\n * The flag to stop event bubbling.\n * @type {boolean}\n * @deprecated\n */\n get cancelBubble() {\n return pd(this).stopped\n },\n set cancelBubble(value) {\n if (!value) {\n return\n }\n const data = pd(this)\n\n data.stopped = true\n if (typeof data.event.cancelBubble === \"boolean\") {\n data.event.cancelBubble = true\n }\n },\n\n /**\n * The flag to indicate cancellation state.\n * @type {boolean}\n * @deprecated\n */\n get returnValue() {\n return !pd(this).canceled\n },\n set returnValue(value) {\n if (!value) {\n setCancelFlag(pd(this))\n }\n },\n\n /**\n * Initialize this event object. But do nothing under event dispatching.\n * @param {string} type The event type.\n * @param {boolean} [bubbles=false] The flag to be possible to bubble up.\n * @param {boolean} [cancelable=false] The flag to be possible to cancel.\n * @deprecated\n */\n initEvent() {\n // Do nothing.\n },\n}\n\n// `constructor` is not enumerable.\nObject.defineProperty(Event.prototype, \"constructor\", {\n value: Event,\n configurable: true,\n writable: true,\n})\n\n// Ensure `event instanceof window.Event` is `true`.\nif (typeof window !== \"undefined\" && typeof window.Event !== \"undefined\") {\n Object.setPrototypeOf(Event.prototype, window.Event.prototype)\n\n // Make association for wrappers.\n wrappers.set(window.Event.prototype, Event)\n}\n\n/**\n * Get the property descriptor to redirect a given property.\n * @param {string} key Property name to define property descriptor.\n * @returns {PropertyDescriptor} The property descriptor to redirect the property.\n * @private\n */\nfunction defineRedirectDescriptor(key) {\n return {\n get() {\n return pd(this).event[key]\n },\n set(value) {\n pd(this).event[key] = value\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Get the property descriptor to call a given method property.\n * @param {string} key Property name to define property descriptor.\n * @returns {PropertyDescriptor} The property descriptor to call the method property.\n * @private\n */\nfunction defineCallDescriptor(key) {\n return {\n value() {\n const event = pd(this).event\n return event[key].apply(event, arguments)\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Define new wrapper class.\n * @param {Function} BaseEvent The base wrapper class.\n * @param {Object} proto The prototype of the original event.\n * @returns {Function} The defined wrapper class.\n * @private\n */\nfunction defineWrapper(BaseEvent, proto) {\n const keys = Object.keys(proto)\n if (keys.length === 0) {\n return BaseEvent\n }\n\n /** CustomEvent */\n function CustomEvent(eventTarget, event) {\n BaseEvent.call(this, eventTarget, event)\n }\n\n CustomEvent.prototype = Object.create(BaseEvent.prototype, {\n constructor: { value: CustomEvent, configurable: true, writable: true },\n })\n\n // Define accessors.\n for (let i = 0; i < keys.length; ++i) {\n const key = keys[i]\n if (!(key in BaseEvent.prototype)) {\n const descriptor = Object.getOwnPropertyDescriptor(proto, key)\n const isFunc = typeof descriptor.value === \"function\"\n Object.defineProperty(\n CustomEvent.prototype,\n key,\n isFunc\n ? defineCallDescriptor(key)\n : defineRedirectDescriptor(key)\n )\n }\n }\n\n return CustomEvent\n}\n\n/**\n * Get the wrapper class of a given prototype.\n * @param {Object} proto The prototype of the original event to get its wrapper.\n * @returns {Function} The wrapper class.\n * @private\n */\nfunction getWrapper(proto) {\n if (proto == null || proto === Object.prototype) {\n return Event\n }\n\n let wrapper = wrappers.get(proto)\n if (wrapper == null) {\n wrapper = defineWrapper(getWrapper(Object.getPrototypeOf(proto)), proto)\n wrappers.set(proto, wrapper)\n }\n return wrapper\n}\n\n/**\n * Wrap a given event to management a dispatching.\n * @param {EventTarget} eventTarget The event target of this dispatching.\n * @param {Object} event The event to wrap.\n * @returns {Event} The wrapper instance.\n * @private\n */\nexport function wrapEvent(eventTarget, event) {\n const Wrapper = getWrapper(Object.getPrototypeOf(event))\n return new Wrapper(eventTarget, event)\n}\n\n/**\n * Get the immediateStopped flag of a given event.\n * @param {Event} event The event to get.\n * @returns {boolean} The flag to stop propagation immediately.\n * @private\n */\nexport function isStopped(event) {\n return pd(event).immediateStopped\n}\n\n/**\n * Set the current event phase of a given event.\n * @param {Event} event The event to set current target.\n * @param {number} eventPhase New event phase.\n * @returns {void}\n * @private\n */\nexport function setEventPhase(event, eventPhase) {\n pd(event).eventPhase = eventPhase\n}\n\n/**\n * Set the current target of a given event.\n * @param {Event} event The event to set current target.\n * @param {EventTarget|null} currentTarget New current target.\n * @returns {void}\n * @private\n */\nexport function setCurrentTarget(event, currentTarget) {\n pd(event).currentTarget = currentTarget\n}\n\n/**\n * Set a passive listener of a given event.\n * @param {Event} event The event to set current target.\n * @param {Function|null} passiveListener New passive listener.\n * @returns {void}\n * @private\n */\nexport function setPassiveListener(event, passiveListener) {\n pd(event).passiveListener = passiveListener\n}\n","import {\n isStopped,\n setCurrentTarget,\n setEventPhase,\n setPassiveListener,\n wrapEvent,\n} from \"./event.mjs\"\n\n/**\n * @typedef {object} ListenerNode\n * @property {Function} listener\n * @property {1|2|3} listenerType\n * @property {boolean} passive\n * @property {boolean} once\n * @property {ListenerNode|null} next\n * @private\n */\n\n/**\n * @type {WeakMap<object, Map<string, ListenerNode>>}\n * @private\n */\nconst listenersMap = new WeakMap()\n\n// Listener types\nconst CAPTURE = 1\nconst BUBBLE = 2\nconst ATTRIBUTE = 3\n\n/**\n * Check whether a given value is an object or not.\n * @param {any} x The value to check.\n * @returns {boolean} `true` if the value is an object.\n */\nfunction isObject(x) {\n return x !== null && typeof x === \"object\" //eslint-disable-line no-restricted-syntax\n}\n\n/**\n * Get listeners.\n * @param {EventTarget} eventTarget The event target to get.\n * @returns {Map<string, ListenerNode>} The listeners.\n * @private\n */\nfunction getListeners(eventTarget) {\n const listeners = listenersMap.get(eventTarget)\n if (listeners == null) {\n throw new TypeError(\n \"'this' is expected an EventTarget object, but got another value.\"\n )\n }\n return listeners\n}\n\n/**\n * Get the property descriptor for the event attribute of a given event.\n * @param {string} eventName The event name to get property descriptor.\n * @returns {PropertyDescriptor} The property descriptor.\n * @private\n */\nfunction defineEventAttributeDescriptor(eventName) {\n return {\n get() {\n const listeners = getListeners(this)\n let node = listeners.get(eventName)\n while (node != null) {\n if (node.listenerType === ATTRIBUTE) {\n return node.listener\n }\n node = node.next\n }\n return null\n },\n\n set(listener) {\n if (typeof listener !== \"function\" && !isObject(listener)) {\n listener = null // eslint-disable-line no-param-reassign\n }\n const listeners = getListeners(this)\n\n // Traverse to the tail while removing old value.\n let prev = null\n let node = listeners.get(eventName)\n while (node != null) {\n if (node.listenerType === ATTRIBUTE) {\n // Remove old value.\n if (prev !== null) {\n prev.next = node.next\n } else if (node.next !== null) {\n listeners.set(eventName, node.next)\n } else {\n listeners.delete(eventName)\n }\n } else {\n prev = node\n }\n\n node = node.next\n }\n\n // Add new value.\n if (listener !== null) {\n const newNode = {\n listener,\n listenerType: ATTRIBUTE,\n passive: false,\n once: false,\n next: null,\n }\n if (prev === null) {\n listeners.set(eventName, newNode)\n } else {\n prev.next = newNode\n }\n }\n },\n configurable: true,\n enumerable: true,\n }\n}\n\n/**\n * Define an event attribute (e.g. `eventTarget.onclick`).\n * @param {Object} eventTargetPrototype The event target prototype to define an event attrbite.\n * @param {string} eventName The event name to define.\n * @returns {void}\n */\nfunction defineEventAttribute(eventTargetPrototype, eventName) {\n Object.defineProperty(\n eventTargetPrototype,\n `on${eventName}`,\n defineEventAttributeDescriptor(eventName)\n )\n}\n\n/**\n * Define a custom EventTarget with event attributes.\n * @param {string[]} eventNames Event names for event attributes.\n * @returns {EventTarget} The custom EventTarget.\n * @private\n */\nfunction defineCustomEventTarget(eventNames) {\n /** CustomEventTarget */\n function CustomEventTarget() {\n EventTarget.call(this)\n }\n\n CustomEventTarget.prototype = Object.create(EventTarget.prototype, {\n constructor: {\n value: CustomEventTarget,\n configurable: true,\n writable: true,\n },\n })\n\n for (let i = 0; i < eventNames.length; ++i) {\n defineEventAttribute(CustomEventTarget.prototype, eventNames[i])\n }\n\n return CustomEventTarget\n}\n\n/**\n * EventTarget.\n *\n * - This is constructor if no arguments.\n * - This is a function which returns a CustomEventTarget constructor if there are arguments.\n *\n * For example:\n *\n * class A extends EventTarget {}\n * class B extends EventTarget(\"message\") {}\n * class C extends EventTarget(\"message\", \"error\") {}\n * class D extends EventTarget([\"message\", \"error\"]) {}\n */\nfunction EventTarget() {\n /*eslint-disable consistent-return */\n if (this instanceof EventTarget) {\n listenersMap.set(this, new Map())\n return\n }\n if (arguments.length === 1 && Array.isArray(arguments[0])) {\n return defineCustomEventTarget(arguments[0])\n }\n if (arguments.length > 0) {\n const types = new Array(arguments.length)\n for (let i = 0; i < arguments.length; ++i) {\n types[i] = arguments[i]\n }\n return defineCustomEventTarget(types)\n }\n throw new TypeError(\"Cannot call a class as a function\")\n /*eslint-enable consistent-return */\n}\n\n// Should be enumerable, but class methods are not enumerable.\nEventTarget.prototype = {\n /**\n * Add a given listener to this event target.\n * @param {string} eventName The event name to add.\n * @param {Function} listener The listener to add.\n * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener.\n * @returns {void}\n */\n addEventListener(eventName, listener, options) {\n if (listener == null) {\n return\n }\n if (typeof listener !== \"function\" && !isObject(listener)) {\n throw new TypeError(\"'listener' should be a function or an object.\")\n }\n\n const listeners = getListeners(this)\n const optionsIsObj = isObject(options)\n const capture = optionsIsObj\n ? Boolean(options.capture)\n : Boolean(options)\n const listenerType = capture ? CAPTURE : BUBBLE\n const newNode = {\n listener,\n listenerType,\n passive: optionsIsObj && Boolean(options.passive),\n once: optionsIsObj && Boolean(options.once),\n next: null,\n }\n\n // Set it as the first node if the first node is null.\n let node = listeners.get(eventName)\n if (node === undefined) {\n listeners.set(eventName, newNode)\n return\n }\n\n // Traverse to the tail while checking duplication..\n let prev = null\n while (node != null) {\n if (\n node.listener === listener &&\n node.listenerType === listenerType\n ) {\n // Should ignore duplication.\n return\n }\n prev = node\n node = node.next\n }\n\n // Add it.\n prev.next = newNode\n },\n\n /**\n * Remove a given listener from this event target.\n * @param {string} eventName The event name to remove.\n * @param {Function} listener The listener to remove.\n * @param {boolean|{capture?:boolean,passive?:boolean,once?:boolean}} [options] The options for this listener.\n * @returns {void}\n */\n removeEventListener(eventName, listener, options) {\n if (listener == null) {\n return\n }\n\n const listeners = getListeners(this)\n const capture = isObject(options)\n ? Boolean(options.capture)\n : Boolean(options)\n const listenerType = capture ? CAPTURE : BUBBLE\n\n let prev = null\n let node = listeners.get(eventName)\n while (node != null) {\n if (\n node.listener === listener &&\n node.listenerType === listenerType\n ) {\n if (prev !== null) {\n prev.next = node.next\n } else if (node.next !== null) {\n listeners.set(eventName, node.next)\n } else {\n listeners.delete(eventName)\n }\n return\n }\n\n prev = node\n node = node.next\n }\n },\n\n /**\n * Dispatch a given event.\n * @param {Event|{type:string}} event The event to dispatch.\n * @returns {boolean} `false` if canceled.\n */\n dispatchEvent(event) {\n if (event == null || typeof event.type !== \"string\") {\n throw new TypeError('\"event.type\" should be a string.')\n }\n\n // If listeners aren't registered, terminate.\n const listeners = getListeners(this)\n const eventName = event.type\n let node = listeners.get(eventName)\n if (node == null) {\n return true\n }\n\n // Since we cannot rewrite several properties, so wrap object.\n const wrappedEvent = wrapEvent(this, event)\n\n // This doesn't process capturing phase and bubbling phase.\n // This isn't participating in a tree.\n let prev = null\n while (node != null) {\n // Remove this listener if it's once\n if (node.once) {\n if (prev !== null) {\n prev.next = node.next\n } else if (node.next !== null) {\n listeners.set(eventName, node.next)\n } else {\n listeners.delete(eventName)\n }\n } else {\n prev = node\n }\n\n // Call this listener\n setPassiveListener(\n wrappedEvent,\n node.passive ? node.listener : null\n )\n if (typeof node.listener === \"function\") {\n try {\n node.listener.call(this, wrappedEvent)\n } catch (err) {\n if (\n typeof console !== \"undefined\" &&\n typeof console.error === \"function\"\n ) {\n console.error(err)\n }\n }\n } else if (\n node.listenerType !== ATTRIBUTE &&\n typeof node.listener.handleEvent === \"function\"\n ) {\n node.listener.handleEvent(wrappedEvent)\n }\n\n // Break if `event.stopImmediatePropagation` was called.\n if (isStopped(wrappedEvent)) {\n break\n }\n\n node = node.next\n }\n setPassiveListener(wrappedEvent, null)\n setEventPhase(wrappedEvent, 0)\n setCurrentTarget(wrappedEvent, null)\n\n return !wrappedEvent.defaultPrevented\n },\n}\n\n// `constructor` is not enumerable.\nObject.defineProperty(EventTarget.prototype, \"constructor\", {\n value: EventTarget,\n configurable: true,\n writable: true,\n})\n\n// Ensure `eventTarget instanceof window.EventTarget` is `true`.\nif (\n typeof window !== \"undefined\" &&\n typeof window.EventTarget !== \"undefined\"\n) {\n Object.setPrototypeOf(EventTarget.prototype, window.EventTarget.prototype)\n}\n\nexport { defineEventAttribute, EventTarget }\nexport default EventTarget\n"],"names":["pd","event","retv","privateData","get","console","assert","setCancelFlag","data","passiveListener","cancelable","canceled","preventDefault","error","Event","eventTarget","set","eventPhase","currentTarget","stopped","immediateStopped","timeStamp","Date","now","Object","defineProperty","value","enumerable","key","keys","i","length","defineRedirectDescriptor","configurable","defineCallDescriptor","apply","arguments","defineWrapper","BaseEvent","proto","CustomEvent","call","prototype","create","constructor","writable","descriptor","getOwnPropertyDescriptor","isFunc","getWrapper","wrapper","wrappers","getPrototypeOf","wrapEvent","Wrapper","isStopped","setEventPhase","setCurrentTarget","setPassiveListener","isObject","x","_typeof","getListeners","listeners","listenersMap","TypeError","defineEventAttributeDescriptor","eventName","node","listenerType","listener","next","prev","delete","newNode","passive","once","defineEventAttribute","eventTargetPrototype","defineCustomEventTarget","eventNames","CustomEventTarget","EventTarget","Map","Array","isArray","types","WeakMap","type","target","composedPath","NONE","CAPTURING_PHASE","AT_TARGET","BUBBLING_PHASE","stopPropagation","stopImmediatePropagation","bubbles","defaultPrevented","composed","srcElement","cancelBubble","returnValue","initEvent","window","setPrototypeOf","CAPTURE","BUBBLE","addEventListener","options","optionsIsObj","capture","removeEventListener","dispatchEvent","wrappedEvent","err","handleEvent"],"mappings":";;;;wbAkCA,QAASA,CAAAA,CAAT,CAAYC,CAAZ,CAAmB,IACTC,CAAAA,CAAI,CAAGC,CAAW,CAACC,GAAZD,CAAgBF,CAAhBE,QACbE,CAAAA,OAAO,CAACC,MAARD,CACY,IAARH,EAAAA,CADJG,CAEI,6CAFJA,CAGIJ,CAHJI,EAKOH,EAOX,QAASK,CAAAA,CAAT,CAAuBC,CAAvB,CAA6B,OACG,KAAxBA,EAAAA,CAAI,CAACC,eADgB,MAarB,CAACD,CAAI,CAACP,KAALO,CAAWE,UAbS,GAiBzBF,CAAI,CAACG,QAALH,GAjByB,CAkBgB,UAArC,QAAOA,CAAAA,CAAI,CAACP,KAALO,CAAWI,cAlBG,EAmBrBJ,CAAI,CAACP,KAALO,CAAWI,cAAXJ,EAnBqB,QAGE,WAAnB,QAAOH,CAAAA,OAAP,EACyB,UAAzB,QAAOA,CAAAA,OAAO,CAACQ,KAJE,EAMjBR,OAAO,CAACQ,KAARR,CACI,oEADJA,CAEIG,CAAI,CAACC,eAFTJ,CANiB,EAiC7B,QAASS,CAAAA,CAAT,CAAeC,CAAf,CAA4Bd,CAA5B,CAAmC,CAC/BE,CAAW,CAACa,GAAZb,CAAgB,IAAhBA,CAAsB,CAClBY,WAAW,CAAXA,CADkB,CAElBd,KAAK,CAALA,CAFkB,CAGlBgB,UAAU,CAAE,CAHM,CAIlBC,aAAa,CAAEH,CAJG,CAKlBJ,QAAQ,GALU,CAMlBQ,OAAO,GANW,CAOlBC,gBAAgB,GAPE,CAQlBX,eAAe,CAAE,IARC,CASlBY,SAAS,CAAEpB,CAAK,CAACoB,SAANpB,EAAmBqB,IAAI,CAACC,GAALD,EATZ,CAAtBnB,CAD+B,CAc/BqB,MAAM,CAACC,cAAPD,CAAsB,IAAtBA,CAA4B,WAA5BA,CAAyC,CAAEE,KAAK,GAAP,CAAgBC,UAAU,GAA1B,CAAzCH,CAd+B,QAmBrBI,CAAAA,EAFJC,CAAI,CAAGL,MAAM,CAACK,IAAPL,CAAYvB,CAAZuB,EACJM,CAAC,CAAG,EAAGA,CAAC,CAAGD,CAAI,CAACE,OAAQ,EAAED,EACzBF,EAAMC,CAAI,CAACC,CAAD,EACVF,CAAG,GAAI,OACTJ,MAAM,CAACC,cAAPD,CAAsB,IAAtBA,CAA4BI,CAA5BJ,CAAiCQ,CAAwB,CAACJ,CAAD,CAAzDJ,EAyOZ,QAASQ,CAAAA,CAAT,CAAkCJ,CAAlC,CAAuC,OAC5B,CACHxB,GADG,WACG,OACKJ,CAAAA,CAAE,CAAC,IAAD,CAAFA,CAASC,KAATD,CAAe4B,CAAf5B,CAFR,CAAA,CAIHgB,GAJG,UAICU,EAAO,CACP1B,CAAE,CAAC,IAAD,CAAFA,CAASC,KAATD,CAAe4B,CAAf5B,EAAsB0B,CALvB,CAAA,CAOHO,YAAY,GAPT,CAQHN,UAAU,GARP,EAkBX,QAASO,CAAAA,CAAT,CAA8BN,CAA9B,CAAmC,OACxB,CACHF,KADG,WACK,IACEzB,CAAAA,CAAK,CAAGD,CAAE,CAAC,IAAD,CAAFA,CAASC,YAChBA,CAAAA,CAAK,CAAC2B,CAAD,CAAL3B,CAAWkC,KAAXlC,CAAiBA,CAAjBA,CAAwBmC,SAAxBnC,CAHR,CAAA,CAKHgC,YAAY,GALT,CAMHN,UAAU,GANP,EAiBX,QAASU,CAAAA,CAAT,CAAuBC,CAAvB,CAAkCC,CAAlC,CAAyC,SAO5BC,CAAAA,EAAYzB,EAAad,EAAO,CACrCqC,CAAS,CAACG,IAAVH,CAAe,IAAfA,CAAqBvB,CAArBuB,CAAkCrC,CAAlCqC,KAPET,CAAAA,CAAI,CAAGL,MAAM,CAACK,IAAPL,CAAYe,CAAZf,KACO,CAAhBK,GAAAA,CAAI,CAACE,aACEO,CAAAA,EAQXE,CAAW,CAACE,SAAZF,CAAwBhB,MAAM,CAACmB,MAAPnB,CAAcc,CAAS,CAACI,SAAxBlB,CAAmC,CACvDoB,WAAW,CAAE,CAAElB,KAAK,CAAEc,CAAT,CAAsBP,YAAY,GAAlC,CAA0CY,QAAQ,GAAlD,CAD0C,CAAnCrB,CAXa,KAgBhC,GACKI,CAAAA,CADL,CAAIE,CAAC,CAAG,EAAGA,CAAC,CAAGD,CAAI,CAACE,OAAQ,EAAED,KACzBF,EAAMC,CAAI,CAACC,CAAD,EACZ,EAAEF,CAAG,GAAIU,CAAAA,CAAS,CAACI,SAAnB,EAA+B,IACzBI,CAAAA,CAAU,CAAGtB,MAAM,CAACuB,wBAAPvB,CAAgCe,CAAhCf,CAAuCI,CAAvCJ,CADY,CAEzBwB,CAAM,CAA+B,UAA5B,QAAOF,CAAAA,CAAU,CAACpB,KAFF,CAG/BF,MAAM,CAACC,cAAPD,CACIgB,CAAW,CAACE,SADhBlB,CAEII,CAFJJ,CAGIwB,CAAM,CACAd,CAAoB,CAACN,CAAD,CADpB,CAEAI,CAAwB,CAACJ,CAAD,CALlCJ,QAUDgB,CAAAA,EASX,QAASS,CAAAA,CAAT,CAAoBV,CAApB,CAA2B,IACV,IAATA,EAAAA,CAAK,EAAYA,CAAK,GAAKf,MAAM,CAACkB,gBAC3B5B,CAAAA,KAGPoC,CAAAA,CAAO,CAAGC,CAAQ,CAAC/C,GAAT+C,CAAaZ,CAAbY,QACC,KAAXD,EAAAA,IACAA,CAAO,CAAGb,CAAa,CAACY,CAAU,CAACzB,MAAM,CAAC4B,cAAP5B,CAAsBe,CAAtBf,CAAD,CAAX,CAA2Ce,CAA3C,EACvBY,CAAQ,CAACnC,GAATmC,CAAaZ,CAAbY,CAAoBD,CAApBC,GAEGD,EAUJ,QAASG,CAAAA,CAAT,CAAmBtC,CAAnB,CAAgCd,CAAhC,CAAuC,IACpCqD,CAAAA,CAAO,CAAGL,CAAU,CAACzB,MAAM,CAAC4B,cAAP5B,CAAsBvB,CAAtBuB,CAAD,QACnB,IAAI8B,CAAAA,CAAJ,CAAYvC,CAAZ,CAAyBd,CAAzB,EASJ,QAASsD,CAAAA,CAAT,CAAmBtD,CAAnB,CAA0B,OACtBD,CAAAA,CAAE,CAACC,CAAD,CAAFD,CAAUoB,iBAUd,QAASoC,CAAAA,CAAT,CAAuBvD,CAAvB,CAA8BgB,CAA9B,CAA0C,CAC7CjB,CAAE,CAACC,CAAD,CAAFD,CAAUiB,UAAVjB,CAAuBiB,EAUpB,QAASwC,CAAAA,CAAT,CAA0BxD,CAA1B,CAAiCiB,CAAjC,CAAgD,CACnDlB,CAAE,CAACC,CAAD,CAAFD,CAAUkB,aAAVlB,CAA0BkB,EAUvB,QAASwC,CAAAA,CAAT,CAA4BzD,CAA5B,CAAmCQ,CAAnC,CAAoD,CACvDT,CAAE,CAACC,CAAD,CAAFD,CAAUS,eAAVT,CAA4BS,EC3bhC,QAASkD,CAAAA,CAAT,CAAkBC,CAAlB,CAAqB,OACJ,KAANA,GAAAA,CAAC,EAA0B,QAAb,GAAAC,EAAOD,GAShC,QAASE,CAAAA,CAAT,CAAsB/C,CAAtB,CAAmC,IACzBgD,CAAAA,CAAS,CAAGC,CAAY,CAAC5D,GAAb4D,CAAiBjD,CAAjBiD,KACD,IAAbD,EAAAA,OACM,IAAIE,CAAAA,SAAJ,CACF,kEADE,QAIHF,CAAAA,EASX,QAASG,CAAAA,CAAT,CAAwCC,CAAxC,CAAmD,OACxC,CACH/D,GADG,WACG,QACI2D,CAAAA,CAAS,CAAGD,CAAY,CAAC,IAAD,CAD5B,CAEEM,CAAI,CAAGL,CAAS,CAAC3D,GAAV2D,CAAcI,CAAdJ,CAFT,CAGa,IAARK,EAAAA,CAHL,EAGmB,IACbA,IAAAA,CAAI,CAACC,mBACED,CAAAA,CAAI,CAACE,SAEhBF,CAAI,CAAGA,CAAI,CAACG,WAET,KAVR,CAAA,CAaHvD,GAbG,UAaCsD,EAAU,CACc,UAApB,QAAOA,CAAAA,CAAP,EAAmCX,CAAQ,CAACW,CAAD,CADrC,GAENA,CAAQ,CAAG,IAFL,SAIJP,CAAAA,CAAS,CAAGD,CAAY,CAAC,IAAD,CAJpB,CAONU,CAAI,CAAG,IAPD,CAQNJ,CAAI,CAAGL,CAAS,CAAC3D,GAAV2D,CAAcI,CAAdJ,CARD,CASK,IAARK,EAAAA,CATG,EAUFA,IAAAA,CAAI,CAACC,YAVH,CAYW,IAATG,GAAAA,CAZF,CAcuB,IAAdJ,GAAAA,CAAI,CAACG,IAdd,CAiBER,CAAS,CAACU,MAAVV,CAAiBI,CAAjBJ,CAjBF,CAeEA,CAAS,CAAC/C,GAAV+C,CAAcI,CAAdJ,CAAyBK,CAAI,CAACG,IAA9BR,CAfF,CAaES,CAAI,CAACD,IAALC,CAAYJ,CAAI,CAACG,IAbnB,CAoBFC,CAAI,CAAGJ,CApBL,CAuBNA,CAAI,CAAGA,CAAI,CAACG,IAvBN,IA2BO,IAAbD,GAAAA,EAAmB,IACbI,CAAAA,CAAO,CAAG,CACZJ,QAAQ,CAARA,CADY,CAEZD,YAAY,EAFA,CAGZM,OAAO,GAHK,CAIZC,IAAI,GAJQ,CAKZL,IAAI,CAAE,IALM,EAOH,IAATC,GAAAA,CARe,CASfT,CAAS,CAAC/C,GAAV+C,CAAcI,CAAdJ,CAAyBW,CAAzBX,CATe,CAWfS,CAAI,CAACD,IAALC,CAAYE,EAnDrB,CAAA,CAuDHzC,YAAY,GAvDT,CAwDHN,UAAU,GAxDP,EAkEX,QAASkD,CAAAA,CAAT,CAA8BC,CAA9B,CAAoDX,CAApD,CAA+D,CAC3D3C,MAAM,CAACC,cAAPD,CACIsD,CADJtD,aAES2C,EAFT3C,CAGI0C,CAA8B,CAACC,CAAD,CAHlC3C,EAaJ,QAASuD,CAAAA,CAAT,CAAiCC,CAAjC,CAA6C,SAEhCC,CAAAA,GAAoB,CACzBC,CAAW,CAACzC,IAAZyC,CAAiB,IAAjBA,EAGJD,CAAiB,CAACvC,SAAlBuC,CAA8BzD,MAAM,CAACmB,MAAPnB,CAAc0D,CAAW,CAACxC,SAA1BlB,CAAqC,CAC/DoB,WAAW,CAAE,CACTlB,KAAK,CAAEuD,CADE,CAEThD,YAAY,GAFH,CAGTY,QAAQ,GAHC,CADkD,CAArCrB,CANW,KAcpC,GAAIM,CAAAA,CAAC,CAAG,EAAGA,CAAC,CAAGkD,CAAU,CAACjD,OAAQ,EAAED,EACrC+C,CAAoB,CAACI,CAAiB,CAACvC,SAAnB,CAA8BsC,CAAU,CAAClD,CAAD,CAAxC,CAApB+C,OAGGI,CAAAA,EAgBX,QAASC,CAAAA,CAAT,EAAuB,IAEf,eAAgBA,CAAAA,aAChBlB,CAAAA,CAAY,CAAChD,GAAbgD,CAAiB,IAAjBA,CAAuB,GAAImB,CAAAA,GAA3BnB,KAGqB,CAArB5B,GAAAA,SAAS,CAACL,MAAVK,EAA0BgD,KAAK,CAACC,OAAND,CAAchD,SAAS,CAAC,CAAD,CAAvBgD,QACnBL,CAAAA,CAAuB,CAAC3C,SAAS,CAAC,CAAD,CAAV,KAEX,CAAnBA,CAAAA,SAAS,CAACL,OAAY,QAChBuD,CAAAA,CAAK,CAAOF,KAAP,CAAahD,SAAS,CAACL,MAAvB,EACFD,CAAC,CAAG,EAAGA,CAAC,CAAGM,SAAS,CAACL,OAAQ,EAAED,EACpCwD,CAAK,CAACxD,CAAD,CAALwD,CAAWlD,SAAS,CAACN,CAAD,CAApBwD,OAEGP,CAAAA,CAAuB,CAACO,CAAD,OAE5B,IAAIrB,CAAAA,SAAJ,CAAc,mCAAd,KD5KJ9D,CAAAA,CAAW,CAAG,GAAIoF,CAAAA,QAOlBpC,CAAQ,CAAG,GAAIoC,CAAAA,QAkFrBzE,CAAK,CAAC4B,SAAN5B,CAAkB,IAKV0E,CAAAA,MAAO,OACAxF,CAAAA,CAAE,CAAC,IAAD,CAAFA,CAASC,KAATD,CAAewF,IANZ,CAAA,IAaVC,CAAAA,QAAS,OACFzF,CAAAA,CAAE,CAAC,IAAD,CAAFA,CAASe,WAdN,CAAA,IAqBVG,CAAAA,eAAgB,OACTlB,CAAAA,CAAE,CAAC,IAAD,CAAFA,CAASkB,aAtBN,CAAA,CA4BdwE,YA5Bc,WA4BC,IACLxE,CAAAA,CAAa,CAAGlB,CAAE,CAAC,IAAD,CAAFA,CAASkB,cADpB,MAEU,KAAjBA,EAAAA,CAFO,CAGA,EAHA,CAKJ,CAACA,CAAD,CAjCG,CAAA,IAwCVyE,CAAAA,MAAO,OACA,EAzCG,CAAA,IAgDVC,CAAAA,iBAAkB,OACX,EAjDG,CAAA,IAwDVC,CAAAA,WAAY,OACL,EAzDG,CAAA,IAgEVC,CAAAA,gBAAiB,OACV,EAjEG,CAAA,IAwEV7E,CAAAA,YAAa,OACNjB,CAAAA,CAAE,CAAC,IAAD,CAAFA,CAASiB,UAzEN,CAAA,CAgFd8E,eAhFc,WAgFI,IACRvF,CAAAA,CAAI,CAAGR,CAAE,CAAC,IAAD,EAEfQ,CAAI,CAACW,OAALX,GAHc,CAI4B,UAAtC,QAAOA,CAAAA,CAAI,CAACP,KAALO,CAAWuF,eAJR,EAKVvF,CAAI,CAACP,KAALO,CAAWuF,eAAXvF,EArFM,CAAA,CA6FdwF,wBA7Fc,WA6Fa,IACjBxF,CAAAA,CAAI,CAAGR,CAAE,CAAC,IAAD,EAEfQ,CAAI,CAACW,OAALX,GAHuB,CAIvBA,CAAI,CAACY,gBAALZ,GAJuB,CAK4B,UAA/C,QAAOA,CAAAA,CAAI,CAACP,KAALO,CAAWwF,wBALC,EAMnBxF,CAAI,CAACP,KAALO,CAAWwF,wBAAXxF,EAnGM,CAAA,IA2GVyF,CAAAA,SAAU,SACKjG,CAAE,CAAC,IAAD,CAAFA,CAASC,KAATD,CAAeiG,OA5GpB,CAAA,IAmHVvF,CAAAA,YAAa,SACEV,CAAE,CAAC,IAAD,CAAFA,CAASC,KAATD,CAAeU,UApHpB,CAAA,CA2HdE,cA3Hc,WA2HG,CACbL,CAAa,CAACP,CAAE,CAAC,IAAD,CAAH,CA5HH,CAAA,IAmIVkG,CAAAA,kBAAmB,OACZlG,CAAAA,CAAE,CAAC,IAAD,CAAFA,CAASW,QApIN,CAAA,IA2IVwF,CAAAA,UAAW,SACInG,CAAE,CAAC,IAAD,CAAFA,CAASC,KAATD,CAAemG,QA5IpB,CAAA,IAmJV9E,CAAAA,WAAY,OACLrB,CAAAA,CAAE,CAAC,IAAD,CAAFA,CAASqB,SApJN,CAAA,IA4JV+E,CAAAA,YAAa,OACNpG,CAAAA,CAAE,CAAC,IAAD,CAAFA,CAASe,WA7JN,CAAA,IAqKVsF,CAAAA,cAAe,OACRrG,CAAAA,CAAE,CAAC,IAAD,CAAFA,CAASmB,OAtKN,CAAA,IAwKVkF,CAAAA,aAAa3E,EAAO,IACfA,MAGClB,CAAAA,CAAI,CAAGR,CAAE,CAAC,IAAD,EAEfQ,CAAI,CAACW,OAALX,IACuC,SAAnC,QAAOA,CAAAA,CAAI,CAACP,KAALO,CAAW6F,eAClB7F,CAAI,CAACP,KAALO,CAAW6F,YAAX7F,KAhLM,CAAA,IAyLV8F,CAAAA,aAAc,OACP,CAACtG,CAAE,CAAC,IAAD,CAAFA,CAASW,QA1LP,CAAA,IA4LV2F,CAAAA,YAAY5E,EAAO,CACdA,CADc,EAEfnB,CAAa,CAACP,CAAE,CAAC,IAAD,CAAH,CA9LP,CAAA,CAyMduG,SAzMc,WAyMF,EAzME,EA+MlB/E,MAAM,CAACC,cAAPD,CAAsBV,CAAK,CAAC4B,SAA5BlB,CAAuC,aAAvCA,CAAsD,CAClDE,KAAK,CAAEZ,CAD2C,CAElDmB,YAAY,GAFsC,CAGlDY,QAAQ,GAH0C,CAAtDrB,EAOsB,WAAlB,QAAOgF,CAAAA,MAAP,EAAyD,WAAxB,QAAOA,CAAAA,MAAM,CAAC1F,QAC/CU,MAAM,CAACiF,cAAPjF,CAAsBV,CAAK,CAAC4B,SAA5BlB,CAAuCgF,MAAM,CAAC1F,KAAP0F,CAAa9D,SAApDlB,EAGA2B,CAAQ,CAACnC,GAATmC,CAAaqD,MAAM,CAAC1F,KAAP0F,CAAa9D,SAA1BS,CAAqCrC,CAArCqC,MChTEa,CAAAA,CAAY,CAAG,GAAIuB,CAAAA,QAGnBmB,CAAO,CAAG,EACVC,CAAM,CAAG,KA0KfzB,CAAW,CAACxC,SAAZwC,CAAwB,CAQpB0B,gBARoB,UAQHzC,EAAWG,EAAUuC,EAAS,IAC3B,IAAZvC,EAAAA,MAGoB,UAApB,QAAOA,CAAAA,CAAP,EAAkC,CAACX,CAAQ,CAACW,CAAD,OACrC,IAAIL,CAAAA,SAAJ,CAAc,+CAAd,KAGJF,CAAAA,CAAS,CAAGD,CAAY,CAAC,IAAD,EACxBgD,CAAY,CAAGnD,CAAQ,CAACkD,CAAD,EACvBE,CAAO,CAAGD,CAAY,GACdD,CAAO,CAACE,OADM,GAEdF,EACRxC,CAAY,CAAG0C,CAAO,CAAGL,CAAH,CAAaC,EACnCjC,CAAO,CAAG,CACZJ,QAAQ,CAARA,CADY,CAEZD,YAAY,CAAZA,CAFY,CAGZM,OAAO,CAAEmC,CAAY,IAAYD,CAAO,CAAClC,OAH7B,CAIZC,IAAI,CAAEkC,CAAY,IAAYD,CAAO,CAACjC,IAJ1B,CAKZL,IAAI,CAAE,IALM,EASZH,CAAI,CAAGL,CAAS,CAAC3D,GAAV2D,CAAcI,CAAdJ,KACPK,SAAAA,aACAL,CAAAA,CAAS,CAAC/C,GAAV+C,CAAcI,CAAdJ,CAAyBW,CAAzBX,SAKAS,CAAAA,CAAI,CAAG,KACI,IAARJ,EAAAA,GAAc,IAEbA,CAAI,CAACE,QAALF,GAAkBE,CAAlBF,EACAA,CAAI,CAACC,YAALD,GAAsBC,SAK1BG,CAAI,CAAGJ,CARU,CASjBA,CAAI,CAAGA,CAAI,CAACG,IAxC2B,CA4C3CC,CAAI,CAACD,IAALC,CAAYE,EApDI,CAAA,CA8DpBsC,mBA9DoB,UA8DA7C,EAAWG,EAAUuC,EAAS,IAC9B,IAAZvC,EAAAA,SAIEP,CAAAA,CAAS,CAAGD,CAAY,CAAC,IAAD,EACxBiD,CAAO,CAAGpD,CAAQ,CAACkD,CAAD,CAARlD,GACFkD,CAAO,CAACE,OADNpD,GAEFkD,EACRxC,CAAY,CAAG0C,CAAO,CAAGL,CAAH,CAAaC,EAErCnC,CAAI,CAAG,KACPJ,CAAI,CAAGL,CAAS,CAAC3D,GAAV2D,CAAcI,CAAdJ,EACI,IAARK,EAAAA,GAAc,IAEbA,CAAI,CAACE,QAALF,GAAkBE,CAAlBF,EACAA,CAAI,CAACC,YAALD,GAAsBC,cAET,IAATG,GAAAA,EAEqB,IAAdJ,GAAAA,CAAI,CAACG,KAGZR,CAAS,CAACU,MAAVV,CAAiBI,CAAjBJ,EAFAA,CAAS,CAAC/C,GAAV+C,CAAcI,CAAdJ,CAAyBK,CAAI,CAACG,IAA9BR,EAFAS,CAAI,CAACD,IAALC,CAAYJ,CAAI,CAACG,MASzBC,CAAI,CAAGJ,CAfU,CAgBjBA,CAAI,CAAGA,CAAI,CAACG,KA3FA,CAAA,CAoGpB0C,aApGoB,UAoGNhH,EAAO,IACJ,IAATA,EAAAA,CAAK,EAAkC,QAAtB,QAAOA,CAAAA,CAAK,CAACuF,UACxB,IAAIvB,CAAAA,SAAJ,CAAc,oCAAd,EAFO,GAMXF,CAAAA,CAAS,CAAGD,CAAY,CAAC,IAAD,CANb,CAOXK,CAAS,CAAGlE,CAAK,CAACuF,IAPP,CAQbpB,CAAI,CAAGL,CAAS,CAAC3D,GAAV2D,CAAcI,CAAdJ,CARM,IASL,IAARK,EAAAA,WATa,OAcX8C,CAAAA,CAAY,CAAG7D,CAAS,CAAC,IAAD,CAAOpD,CAAP,CAdb,CAkBbuE,CAAI,CAAG,IAlBM,CAmBF,IAARJ,EAAAA,CAnBU,EAmBI,IAEbA,CAAI,CAACQ,KACQ,IAATJ,GAAAA,EAEqB,IAAdJ,GAAAA,CAAI,CAACG,KAGZR,CAAS,CAACU,MAAVV,CAAiBI,CAAjBJ,EAFAA,CAAS,CAAC/C,GAAV+C,CAAcI,CAAdJ,CAAyBK,CAAI,CAACG,IAA9BR,EAFAS,CAAI,CAACD,IAALC,CAAYJ,CAAI,CAACG,KAOrBC,CAAI,CAAGJ,EAIXV,CAAkB,CACdwD,CADc,CAEd9C,CAAI,CAACO,OAALP,CAAeA,CAAI,CAACE,QAApBF,CAA+B,IAFjB,EAIW,UAAzB,QAAOA,CAAAA,CAAI,CAACE,YACR,CACAF,CAAI,CAACE,QAALF,CAAc3B,IAAd2B,CAAmB,IAAnBA,CAAyB8C,CAAzB9C,CADJ,CAEE,MAAO+C,CAAP,CAAY,CAEa,WAAnB,QAAO9G,CAAAA,OAAP,EACyB,UAAzB,QAAOA,CAAAA,OAAO,CAACQ,KAHT,EAKNR,OAAO,CAACQ,KAARR,CAAc8G,CAAd9G,MAIR+D,CAAAA,CAAI,CAACC,YAALD,GA/TE,CA+TFA,EACqC,UAArC,QAAOA,CAAAA,CAAI,CAACE,QAALF,CAAcgD,aAErBhD,CAAI,CAACE,QAALF,CAAcgD,WAAdhD,CAA0B8C,CAA1B9C,KAIAb,CAAS,CAAC2D,CAAD,QAIb9C,CAAI,CAAGA,CAAI,CAACG,WAEhBb,CAAAA,CAAkB,CAACwD,CAAD,CAAe,IAAf,EAClB1D,CAAa,CAAC0D,CAAD,CAAe,CAAf,EACbzD,CAAgB,CAACyD,CAAD,CAAe,IAAf,EAET,CAACA,CAAY,CAAChB,iBAvKL,EA4KxB1E,MAAM,CAACC,cAAPD,CAAsB0D,CAAW,CAACxC,SAAlClB,CAA6C,aAA7CA,CAA4D,CACxDE,KAAK,CAAEwD,CADiD,CAExDjD,YAAY,GAF4C,CAGxDY,QAAQ,GAHgD,CAA5DrB,EAQsB,WAAlB,QAAOgF,CAAAA,MAAP,EAC8B,WAA9B,QAAOA,CAAAA,MAAM,CAACtB,aAEd1D,MAAM,CAACiF,cAAPjF,CAAsB0D,CAAW,CAACxC,SAAlClB,CAA6CgF,MAAM,CAACtB,WAAPsB,CAAmB9D,SAAhElB"} \ No newline at end of file diff --git a/node_modules/event-target-shim/index.d.ts b/node_modules/event-target-shim/index.d.ts new file mode 100644 index 0000000..a303097 --- /dev/null +++ b/node_modules/event-target-shim/index.d.ts @@ -0,0 +1,399 @@ +export as namespace EventTargetShim + +/** + * `Event` interface. + * @see https://dom.spec.whatwg.org/#event + */ +export interface Event { + /** + * The type of this event. + */ + readonly type: string + + /** + * The target of this event. + */ + readonly target: EventTarget<{}, {}, "standard"> | null + + /** + * The current target of this event. + */ + readonly currentTarget: EventTarget<{}, {}, "standard"> | null + + /** + * The target of this event. + * @deprecated + */ + readonly srcElement: any | null + + /** + * The composed path of this event. + */ + composedPath(): EventTarget<{}, {}, "standard">[] + + /** + * Constant of NONE. + */ + readonly NONE: number + + /** + * Constant of CAPTURING_PHASE. + */ + readonly CAPTURING_PHASE: number + + /** + * Constant of BUBBLING_PHASE. + */ + readonly BUBBLING_PHASE: number + + /** + * Constant of AT_TARGET. + */ + readonly AT_TARGET: number + + /** + * Indicates which phase of the event flow is currently being evaluated. + */ + readonly eventPhase: number + + /** + * Stop event bubbling. + */ + stopPropagation(): void + + /** + * Stop event bubbling. + */ + stopImmediatePropagation(): void + + /** + * Initialize event. + * @deprecated + */ + initEvent(type: string, bubbles?: boolean, cancelable?: boolean): void + + /** + * The flag indicating bubbling. + */ + readonly bubbles: boolean + + /** + * Stop event bubbling. + * @deprecated + */ + cancelBubble: boolean + + /** + * Set or get cancellation flag. + * @deprecated + */ + returnValue: boolean + + /** + * The flag indicating whether the event can be canceled. + */ + readonly cancelable: boolean + + /** + * Cancel this event. + */ + preventDefault(): void + + /** + * The flag to indicating whether the event was canceled. + */ + readonly defaultPrevented: boolean + + /** + * The flag to indicating if event is composed. + */ + readonly composed: boolean + + /** + * Indicates whether the event was dispatched by the user agent. + */ + readonly isTrusted: boolean + + /** + * The unix time of this event. + */ + readonly timeStamp: number +} + +/** + * The constructor of `EventTarget` interface. + */ +export type EventTargetConstructor< + TEvents extends EventTarget.EventDefinition = {}, + TEventAttributes extends EventTarget.EventDefinition = {}, + TMode extends EventTarget.Mode = "loose" +> = { + prototype: EventTarget<TEvents, TEventAttributes, TMode> + new(): EventTarget<TEvents, TEventAttributes, TMode> +} + +/** + * `EventTarget` interface. + * @see https://dom.spec.whatwg.org/#interface-eventtarget + */ +export type EventTarget< + TEvents extends EventTarget.EventDefinition = {}, + TEventAttributes extends EventTarget.EventDefinition = {}, + TMode extends EventTarget.Mode = "loose" +> = EventTarget.EventAttributes<TEventAttributes> & { + /** + * Add a given listener to this event target. + * @param eventName The event name to add. + * @param listener The listener to add. + * @param options The options for this listener. + */ + addEventListener<TEventType extends EventTarget.EventType<TEvents, TMode>>( + type: TEventType, + listener: + | EventTarget.Listener<EventTarget.PickEvent<TEvents, TEventType>> + | null, + options?: boolean | EventTarget.AddOptions + ): void + + /** + * Remove a given listener from this event target. + * @param eventName The event name to remove. + * @param listener The listener to remove. + * @param options The options for this listener. + */ + removeEventListener<TEventType extends EventTarget.EventType<TEvents, TMode>>( + type: TEventType, + listener: + | EventTarget.Listener<EventTarget.PickEvent<TEvents, TEventType>> + | null, + options?: boolean | EventTarget.RemoveOptions + ): void + + /** + * Dispatch a given event. + * @param event The event to dispatch. + * @returns `false` if canceled. + */ + dispatchEvent<TEventType extends EventTarget.EventType<TEvents, TMode>>( + event: EventTarget.EventData<TEvents, TEventType, TMode> + ): boolean +} + +export const EventTarget: EventTargetConstructor & { + /** + * Create an `EventTarget` instance with detailed event definition. + * + * The detailed event definition requires to use `defineEventAttribute()` + * function later. + * + * Unfortunately, the second type parameter `TEventAttributes` was needed + * because we cannot compute string literal types. + * + * @example + * const signal = new EventTarget<{ abort: Event }, { onabort: Event }>() + * defineEventAttribute(signal, "abort") + */ + new < + TEvents extends EventTarget.EventDefinition, + TEventAttributes extends EventTarget.EventDefinition, + TMode extends EventTarget.Mode = "loose" + >(): EventTarget<TEvents, TEventAttributes, TMode> + + /** + * Define an `EventTarget` constructor with attribute events and detailed event definition. + * + * Unfortunately, the second type parameter `TEventAttributes` was needed + * because we cannot compute string literal types. + * + * @example + * class AbortSignal extends EventTarget<{ abort: Event }, { onabort: Event }>("abort") { + * abort(): void {} + * } + * + * @param events Optional event attributes (e.g. passing in `"click"` adds `onclick` to prototype). + */ + < + TEvents extends EventTarget.EventDefinition = {}, + TEventAttributes extends EventTarget.EventDefinition = {}, + TMode extends EventTarget.Mode = "loose" + >(events: string[]): EventTargetConstructor< + TEvents, + TEventAttributes, + TMode + > + + /** + * Define an `EventTarget` constructor with attribute events and detailed event definition. + * + * Unfortunately, the second type parameter `TEventAttributes` was needed + * because we cannot compute string literal types. + * + * @example + * class AbortSignal extends EventTarget<{ abort: Event }, { onabort: Event }>("abort") { + * abort(): void {} + * } + * + * @param events Optional event attributes (e.g. passing in `"click"` adds `onclick` to prototype). + */ + < + TEvents extends EventTarget.EventDefinition = {}, + TEventAttributes extends EventTarget.EventDefinition = {}, + TMode extends EventTarget.Mode = "loose" + >(event0: string, ...events: string[]): EventTargetConstructor< + TEvents, + TEventAttributes, + TMode + > +} + +export namespace EventTarget { + /** + * Options of `removeEventListener()` method. + */ + export interface RemoveOptions { + /** + * The flag to indicate that the listener is for the capturing phase. + */ + capture?: boolean + } + + /** + * Options of `addEventListener()` method. + */ + export interface AddOptions extends RemoveOptions { + /** + * The flag to indicate that the listener doesn't support + * `event.preventDefault()` operation. + */ + passive?: boolean + /** + * The flag to indicate that the listener will be removed on the first + * event. + */ + once?: boolean + } + + /** + * The type of regular listeners. + */ + export interface FunctionListener<TEvent> { + (event: TEvent): void + } + + /** + * The type of object listeners. + */ + export interface ObjectListener<TEvent> { + handleEvent(event: TEvent): void + } + + /** + * The type of listeners. + */ + export type Listener<TEvent> = + | FunctionListener<TEvent> + | ObjectListener<TEvent> + + /** + * Event definition. + */ + export type EventDefinition = { + readonly [key: string]: Event + } + + /** + * Mapped type for event attributes. + */ + export type EventAttributes<TEventAttributes extends EventDefinition> = { + [P in keyof TEventAttributes]: + | FunctionListener<TEventAttributes[P]> + | null + } + + /** + * The type of event data for `dispatchEvent()` method. + */ + export type EventData< + TEvents extends EventDefinition, + TEventType extends keyof TEvents | string, + TMode extends Mode + > = + TEventType extends keyof TEvents + ? ( + // Require properties which are not generated automatically. + & Pick< + TEvents[TEventType], + Exclude<keyof TEvents[TEventType], OmittableEventKeys> + > + // Properties which are generated automatically are optional. + & Partial<Pick<Event, OmittableEventKeys>> + ) + : ( + TMode extends "standard" + ? Event + : Event | NonStandardEvent + ) + + /** + * The string literal types of the properties which are generated + * automatically in `dispatchEvent()` method. + */ + export type OmittableEventKeys = Exclude<keyof Event, "type"> + + /** + * The type of event data. + */ + export type NonStandardEvent = { + [key: string]: any + type: string + } + + /** + * The type of listeners. + */ + export type PickEvent< + TEvents extends EventDefinition, + TEventType extends keyof TEvents | string, + > = + TEventType extends keyof TEvents + ? TEvents[TEventType] + : Event + + /** + * Event type candidates. + */ + export type EventType< + TEvents extends EventDefinition, + TMode extends Mode + > = + TMode extends "strict" + ? keyof TEvents + : keyof TEvents | string + + /** + * - `"strict"` ..... Methods don't accept unknown events. + * `dispatchEvent()` accepts partial objects. + * - `"loose"` ...... Methods accept unknown events. + * `dispatchEvent()` accepts partial objects. + * - `"standard"` ... Methods accept unknown events. + * `dispatchEvent()` doesn't accept partial objects. + */ + export type Mode = "strict" | "standard" | "loose" +} + +/** + * Specialized `type` property. + */ +export type Type<T extends string> = { type: T } + +/** + * Define an event attribute (e.g. `eventTarget.onclick`). + * @param prototype The event target prototype to define an event attribute. + * @param eventName The event name to define. + */ +export function defineEventAttribute( + prototype: EventTarget, + eventName: string +): void + +export default EventTarget diff --git a/node_modules/event-target-shim/package.json b/node_modules/event-target-shim/package.json new file mode 100644 index 0000000..40326f3 --- /dev/null +++ b/node_modules/event-target-shim/package.json @@ -0,0 +1,82 @@ +{ + "name": "event-target-shim", + "version": "5.0.1", + "description": "An implementation of WHATWG EventTarget interface.", + "main": "dist/event-target-shim", + "types": "index.d.ts", + "files": [ + "dist", + "index.d.ts" + ], + "engines": { + "node": ">=6" + }, + "scripts": { + "preversion": "npm test", + "version": "npm run build && git add dist/*", + "postversion": "git push && git push --tags", + "clean": "rimraf .nyc_output coverage", + "coverage": "nyc report --reporter lcov && opener coverage/lcov-report/index.html", + "lint": "eslint src test scripts --ext .js,.mjs", + "build": "rollup -c scripts/rollup.config.js", + "pretest": "npm run lint", + "test": "run-s test:*", + "test:mocha": "nyc --require ./scripts/babel-register mocha test/*.mjs", + "test:karma": "karma start scripts/karma.conf.js --single-run", + "watch": "run-p watch:*", + "watch:mocha": "mocha test/*.mjs --require ./scripts/babel-register --watch --watch-extensions js,mjs --growl", + "watch:karma": "karma start scripts/karma.conf.js --watch", + "codecov": "codecov" + }, + "devDependencies": { + "@babel/core": "^7.2.2", + "@babel/plugin-transform-modules-commonjs": "^7.2.0", + "@babel/preset-env": "^7.2.3", + "@babel/register": "^7.0.0", + "@mysticatea/eslint-plugin": "^8.0.1", + "@mysticatea/spy": "^0.1.2", + "assert": "^1.4.1", + "codecov": "^3.1.0", + "eslint": "^5.12.1", + "karma": "^3.1.4", + "karma-chrome-launcher": "^2.2.0", + "karma-coverage": "^1.1.2", + "karma-firefox-launcher": "^1.0.0", + "karma-growl-reporter": "^1.0.0", + "karma-ie-launcher": "^1.0.0", + "karma-mocha": "^1.3.0", + "karma-rollup-preprocessor": "^7.0.0-rc.2", + "mocha": "^5.2.0", + "npm-run-all": "^4.1.5", + "nyc": "^13.1.0", + "opener": "^1.5.1", + "rimraf": "^2.6.3", + "rollup": "^1.1.1", + "rollup-plugin-babel": "^4.3.2", + "rollup-plugin-babel-minify": "^7.0.0", + "rollup-plugin-commonjs": "^9.2.0", + "rollup-plugin-json": "^3.1.0", + "rollup-plugin-node-resolve": "^4.0.0", + "rollup-watch": "^4.3.1", + "type-tester": "^1.0.0", + "typescript": "^3.2.4" + }, + "repository": { + "type": "git", + "url": "https://github.com/mysticatea/event-target-shim.git" + }, + "keywords": [ + "w3c", + "whatwg", + "eventtarget", + "event", + "events", + "shim" + ], + "author": "Toru Nagashima", + "license": "MIT", + "bugs": { + "url": "https://github.com/mysticatea/event-target-shim/issues" + }, + "homepage": "https://github.com/mysticatea/event-target-shim" +} diff --git a/node_modules/fastest-levenshtein/bench.js b/node_modules/fastest-levenshtein/bench.js new file mode 100644 index 0000000..1fd420b --- /dev/null +++ b/node_modules/fastest-levenshtein/bench.js @@ -0,0 +1,96 @@ +"use strict"; +exports.__esModule = true; +/* eslint-disable @typescript-eslint/no-var-requires */ +/* eslint-disable no-console */ +var Benchmark = require("benchmark"); +var mod_js_1 = require("./mod.js"); +var fast_levenshtein_1 = require("fast-levenshtein"); +var fs = require("fs"); +var jslevenshtein = require("js-levenshtein"); +var leven = require("leven"); +var levenshteinEditDistance = require("levenshtein-edit-distance"); +var suite = new Benchmark.Suite(); +var randomstring = function (length) { + var result = ""; + var characters = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; + var charactersLength = characters.length; + for (var i = 0; i < length; i++) { + result += characters.charAt(Math.floor(Math.random() * charactersLength)); + } + return result; +}; +var randomstringArr = function (stringSize, arraySize) { + var i = 0; + var arr = []; + for (i = 0; i < arraySize; i++) { + arr.push(randomstring(stringSize)); + } + return arr; +}; +var arrSize = 1000; +if (!fs.existsSync("data.json")) { + var data_1 = [ + randomstringArr(4, arrSize), + randomstringArr(8, arrSize), + randomstringArr(16, arrSize), + randomstringArr(32, arrSize), + randomstringArr(64, arrSize), + randomstringArr(128, arrSize), + randomstringArr(256, arrSize), + randomstringArr(512, arrSize), + randomstringArr(1024, arrSize), + ]; + fs.writeFileSync("data.json", JSON.stringify(data_1)); +} +var data = JSON.parse(fs.readFileSync("data.json", "utf8")); +var _loop_1 = function (i) { + var datapick = data[i]; + if (process.argv[2] !== "no") { + suite + .add("".concat(i, " - js-levenshtein"), function () { + for (var j = 0; j < arrSize - 1; j += 2) { + jslevenshtein(datapick[j], datapick[j + 1]); + } + }) + .add("".concat(i, " - leven"), function () { + for (var j = 0; j < arrSize - 1; j += 2) { + leven(datapick[j], datapick[j + 1]); + } + }) + .add("".concat(i, " - fast-levenshtein"), function () { + for (var j = 0; j < arrSize - 1; j += 2) { + (0, fast_levenshtein_1.get)(datapick[j], datapick[j + 1]); + } + }) + .add("".concat(i, " - levenshtein-edit-distance"), function () { + for (var j = 0; j < arrSize - 1; j += 2) { + levenshteinEditDistance(datapick[j], datapick[j + 1]); + } + }); + } + suite.add("".concat(i, " - fastest-levenshtein"), function () { + for (var j = 0; j < arrSize - 1; j += 2) { + (0, mod_js_1.distance)(datapick[j], datapick[j + 1]); + } + }); +}; +// BENCHMARKS +for (var i = 0; i < 9; i++) { + _loop_1(i); +} +var results = new Map(); +suite + .on("cycle", function (event) { + console.log(String(event.target)); + if (results.has(event.target.name[0])) { + results.get(event.target.name[0]).push(event.target.hz); + } + else { + results.set(event.target.name[0], [event.target.hz]); + } +}) + .on("complete", function () { + console.log(results); +}) + // run async + .run({ async: true }); diff --git a/node_modules/fastest-levenshtein/esm/mod.d.ts b/node_modules/fastest-levenshtein/esm/mod.d.ts new file mode 100644 index 0000000..50927ef --- /dev/null +++ b/node_modules/fastest-levenshtein/esm/mod.d.ts @@ -0,0 +1,4 @@ +declare const distance: (a: string, b: string) => number; +declare const closest: (str: string, arr: readonly string[]) => string; +export { closest, distance }; +//# sourceMappingURL=mod.d.ts.map \ No newline at end of file diff --git a/node_modules/fastest-levenshtein/esm/mod.d.ts.map b/node_modules/fastest-levenshtein/esm/mod.d.ts.map new file mode 100644 index 0000000..7fd5c17 --- /dev/null +++ b/node_modules/fastest-levenshtein/esm/mod.d.ts.map @@ -0,0 +1 @@ +{"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../mod.ts"],"names":[],"mappings":"AAiHA,QAAA,MAAM,QAAQ,MAAO,MAAM,KAAK,MAAM,KAAG,MAaxC,CAAC;AAEF,QAAA,MAAM,OAAO,QAAS,MAAM,OAAO,SAAS,MAAM,EAAE,KAAG,MAWtD,CAAC;AAEF,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC"} \ No newline at end of file diff --git a/node_modules/fastest-levenshtein/esm/mod.js b/node_modules/fastest-levenshtein/esm/mod.js new file mode 100644 index 0000000..719f2b8 --- /dev/null +++ b/node_modules/fastest-levenshtein/esm/mod.js @@ -0,0 +1,138 @@ +const peq = new Uint32Array(0x10000); +const myers_32 = (a, b) => { + const n = a.length; + const m = b.length; + const lst = 1 << (n - 1); + let pv = -1; + let mv = 0; + let sc = n; + let i = n; + while (i--) { + peq[a.charCodeAt(i)] |= 1 << i; + } + for (i = 0; i < m; i++) { + let eq = peq[b.charCodeAt(i)]; + const xv = eq | mv; + eq |= ((eq & pv) + pv) ^ pv; + mv |= ~(eq | pv); + pv &= eq; + if (mv & lst) { + sc++; + } + if (pv & lst) { + sc--; + } + mv = (mv << 1) | 1; + pv = (pv << 1) | ~(xv | mv); + mv &= xv; + } + i = n; + while (i--) { + peq[a.charCodeAt(i)] = 0; + } + return sc; +}; +const myers_x = (b, a) => { + const n = a.length; + const m = b.length; + const mhc = []; + const phc = []; + const hsize = Math.ceil(n / 32); + const vsize = Math.ceil(m / 32); + for (let i = 0; i < hsize; i++) { + phc[i] = -1; + mhc[i] = 0; + } + let j = 0; + for (; j < vsize - 1; j++) { + let mv = 0; + let pv = -1; + const start = j * 32; + const vlen = Math.min(32, m) + start; + for (let k = start; k < vlen; k++) { + peq[b.charCodeAt(k)] |= 1 << k; + } + for (let i = 0; i < n; i++) { + const eq = peq[a.charCodeAt(i)]; + const pb = (phc[(i / 32) | 0] >>> i) & 1; + const mb = (mhc[(i / 32) | 0] >>> i) & 1; + const xv = eq | mv; + const xh = ((((eq | mb) & pv) + pv) ^ pv) | eq | mb; + let ph = mv | ~(xh | pv); + let mh = pv & xh; + if ((ph >>> 31) ^ pb) { + phc[(i / 32) | 0] ^= 1 << i; + } + if ((mh >>> 31) ^ mb) { + mhc[(i / 32) | 0] ^= 1 << i; + } + ph = (ph << 1) | pb; + mh = (mh << 1) | mb; + pv = mh | ~(xv | ph); + mv = ph & xv; + } + for (let k = start; k < vlen; k++) { + peq[b.charCodeAt(k)] = 0; + } + } + let mv = 0; + let pv = -1; + const start = j * 32; + const vlen = Math.min(32, m - start) + start; + for (let k = start; k < vlen; k++) { + peq[b.charCodeAt(k)] |= 1 << k; + } + let score = m; + for (let i = 0; i < n; i++) { + const eq = peq[a.charCodeAt(i)]; + const pb = (phc[(i / 32) | 0] >>> i) & 1; + const mb = (mhc[(i / 32) | 0] >>> i) & 1; + const xv = eq | mv; + const xh = ((((eq | mb) & pv) + pv) ^ pv) | eq | mb; + let ph = mv | ~(xh | pv); + let mh = pv & xh; + score += (ph >>> (m - 1)) & 1; + score -= (mh >>> (m - 1)) & 1; + if ((ph >>> 31) ^ pb) { + phc[(i / 32) | 0] ^= 1 << i; + } + if ((mh >>> 31) ^ mb) { + mhc[(i / 32) | 0] ^= 1 << i; + } + ph = (ph << 1) | pb; + mh = (mh << 1) | mb; + pv = mh | ~(xv | ph); + mv = ph & xv; + } + for (let k = start; k < vlen; k++) { + peq[b.charCodeAt(k)] = 0; + } + return score; +}; +const distance = (a, b) => { + if (a.length < b.length) { + const tmp = b; + b = a; + a = tmp; + } + if (b.length === 0) { + return a.length; + } + if (a.length <= 32) { + return myers_32(a, b); + } + return myers_x(a, b); +}; +const closest = (str, arr) => { + let min_distance = Infinity; + let min_index = 0; + for (let i = 0; i < arr.length; i++) { + const dist = distance(str, arr[i]); + if (dist < min_distance) { + min_distance = dist; + min_index = i; + } + } + return arr[min_index]; +}; +export { closest, distance }; diff --git a/node_modules/fastest-levenshtein/index.d.ts b/node_modules/fastest-levenshtein/index.d.ts deleted file mode 100644 index bdc2bb1..0000000 --- a/node_modules/fastest-levenshtein/index.d.ts +++ /dev/null @@ -1,2 +0,0 @@ -export function distance(a: string, b: string): number; -export function closest(str: string, arr: string[]): string; \ No newline at end of file diff --git a/node_modules/fastest-levenshtein/index.js b/node_modules/fastest-levenshtein/index.js deleted file mode 100644 index 437bdeb..0000000 --- a/node_modules/fastest-levenshtein/index.js +++ /dev/null @@ -1,147 +0,0 @@ -"use strict"; -const peq = new Uint32Array(0x10000); -const myers_32 = (a, b) => { - const n = a.length; - const m = b.length; - const lst = 1 << (n - 1); - let pv = -1; - let mv = 0; - let sc = n; - let i = n; - while (i--) { - peq[a.charCodeAt(i)] |= 1 << i; - } - for (i = 0; i < m; i++) { - let eq = peq[b.charCodeAt(i)]; - const xv = eq | mv; - eq |= ((eq & pv) + pv) ^ pv; - mv |= ~(eq | pv); - pv &= eq; - if (mv & lst) { - sc++; - } - if (pv & lst) { - sc--; - } - mv = (mv << 1) | 1; - pv = (pv << 1) | ~(xv | mv); - mv &= xv; - } - i = n; - while (i--) { - peq[a.charCodeAt(i)] = 0; - } - return sc; -}; - -const myers_x = (a, b) => { - const n = a.length; - const m = b.length; - const mhc = []; - const phc = []; - const hsize = Math.ceil(n / 32); - const vsize = Math.ceil(m / 32); - let score = m; - for (let i = 0; i < hsize; i++) { - phc[i] = -1; - mhc[i] = 0; - } - let j = 0; - for (; j < vsize - 1; j++) { - let mv = 0; - let pv = -1; - const start = j * 32; - const end = Math.min(32, m) + start; - for (let k = start; k < end; k++) { - peq[b.charCodeAt(k)] |= 1 << k; - } - score = m; - for (let i = 0; i < n; i++) { - const eq = peq[a.charCodeAt(i)]; - const pb = (phc[(i / 32) | 0] >>> i) & 1; - const mb = (mhc[(i / 32) | 0] >>> i) & 1; - const xv = eq | mv; - const xh = ((((eq | mb) & pv) + pv) ^ pv) | eq | mb; - let ph = mv | ~(xh | pv); - let mh = pv & xh; - if ((ph >>> 31) ^ pb) { - phc[(i / 32) | 0] ^= 1 << i; - } - if ((mh >>> 31) ^ mb) { - mhc[(i / 32) | 0] ^= 1 << i; - } - ph = (ph << 1) | pb; - mh = (mh << 1) | mb; - pv = mh | ~(xv | ph); - mv = ph & xv; - } - for (let k = start; k < end; k++) { - peq[b.charCodeAt(k)] = 0; - } - } - let mv = 0; - let pv = -1; - const start = j * 32; - const end = Math.min(32, m - start) + start; - for (let k = start; k < end; k++) { - peq[b.charCodeAt(k)] |= 1 << k; - } - score = m; - for (let i = 0; i < n; i++) { - const eq = peq[a.charCodeAt(i)]; - const pb = (phc[(i / 32) | 0] >>> i) & 1; - const mb = (mhc[(i / 32) | 0] >>> i) & 1; - const xv = eq | mv; - const xh = ((((eq | mb) & pv) + pv) ^ pv) | eq | mb; - let ph = mv | ~(xh | pv); - let mh = pv & xh; - score += (ph >>> (m - 1)) & 1; - score -= (mh >>> (m - 1)) & 1; - if ((ph >>> 31) ^ pb) { - phc[(i / 32) | 0] ^= 1 << i; - } - if ((mh >>> 31) ^ mb) { - mhc[(i / 32) | 0] ^= 1 << i; - } - ph = (ph << 1) | pb; - mh = (mh << 1) | mb; - pv = mh | ~(xv | ph); - mv = ph & xv; - } - for (let k = start; k < end; k++) { - peq[b.charCodeAt(k)] = 0; - } - return score; -}; - -const distance = (a, b) => { - if (a.length > b.length) { - const tmp = b; - b = a; - a = tmp; - } - if (a.length === 0) { - return b.length; - } - if (a.length <= 32) { - return myers_32(a, b); - } - return myers_x(a, b); -}; - -const closest = (str, arr) => { - let min_distance = Infinity; - let min_index = 0; - for (let i = 0; i < arr.length; i++) { - const dist = distance(str, arr[i]); - if (dist < min_distance) { - min_distance = dist; - min_index = i; - } - } - return arr[min_index]; -}; - -module.exports = { - closest, distance -} diff --git a/node_modules/fastest-levenshtein/mod.d.ts b/node_modules/fastest-levenshtein/mod.d.ts new file mode 100644 index 0000000..b1b5ce7 --- /dev/null +++ b/node_modules/fastest-levenshtein/mod.d.ts @@ -0,0 +1,3 @@ +declare const distance: (a: string, b: string) => number; +declare const closest: (str: string, arr: readonly string[]) => string; +export { closest, distance }; diff --git a/node_modules/fastest-levenshtein/mod.js b/node_modules/fastest-levenshtein/mod.js new file mode 100644 index 0000000..6bc2745 --- /dev/null +++ b/node_modules/fastest-levenshtein/mod.js @@ -0,0 +1,142 @@ +"use strict"; +exports.__esModule = true; +exports.distance = exports.closest = void 0; +var peq = new Uint32Array(0x10000); +var myers_32 = function (a, b) { + var n = a.length; + var m = b.length; + var lst = 1 << (n - 1); + var pv = -1; + var mv = 0; + var sc = n; + var i = n; + while (i--) { + peq[a.charCodeAt(i)] |= 1 << i; + } + for (i = 0; i < m; i++) { + var eq = peq[b.charCodeAt(i)]; + var xv = eq | mv; + eq |= ((eq & pv) + pv) ^ pv; + mv |= ~(eq | pv); + pv &= eq; + if (mv & lst) { + sc++; + } + if (pv & lst) { + sc--; + } + mv = (mv << 1) | 1; + pv = (pv << 1) | ~(xv | mv); + mv &= xv; + } + i = n; + while (i--) { + peq[a.charCodeAt(i)] = 0; + } + return sc; +}; +var myers_x = function (b, a) { + var n = a.length; + var m = b.length; + var mhc = []; + var phc = []; + var hsize = Math.ceil(n / 32); + var vsize = Math.ceil(m / 32); + for (var i = 0; i < hsize; i++) { + phc[i] = -1; + mhc[i] = 0; + } + var j = 0; + for (; j < vsize - 1; j++) { + var mv_1 = 0; + var pv_1 = -1; + var start_1 = j * 32; + var vlen_1 = Math.min(32, m) + start_1; + for (var k = start_1; k < vlen_1; k++) { + peq[b.charCodeAt(k)] |= 1 << k; + } + for (var i = 0; i < n; i++) { + var eq = peq[a.charCodeAt(i)]; + var pb = (phc[(i / 32) | 0] >>> i) & 1; + var mb = (mhc[(i / 32) | 0] >>> i) & 1; + var xv = eq | mv_1; + var xh = ((((eq | mb) & pv_1) + pv_1) ^ pv_1) | eq | mb; + var ph = mv_1 | ~(xh | pv_1); + var mh = pv_1 & xh; + if ((ph >>> 31) ^ pb) { + phc[(i / 32) | 0] ^= 1 << i; + } + if ((mh >>> 31) ^ mb) { + mhc[(i / 32) | 0] ^= 1 << i; + } + ph = (ph << 1) | pb; + mh = (mh << 1) | mb; + pv_1 = mh | ~(xv | ph); + mv_1 = ph & xv; + } + for (var k = start_1; k < vlen_1; k++) { + peq[b.charCodeAt(k)] = 0; + } + } + var mv = 0; + var pv = -1; + var start = j * 32; + var vlen = Math.min(32, m - start) + start; + for (var k = start; k < vlen; k++) { + peq[b.charCodeAt(k)] |= 1 << k; + } + var score = m; + for (var i = 0; i < n; i++) { + var eq = peq[a.charCodeAt(i)]; + var pb = (phc[(i / 32) | 0] >>> i) & 1; + var mb = (mhc[(i / 32) | 0] >>> i) & 1; + var xv = eq | mv; + var xh = ((((eq | mb) & pv) + pv) ^ pv) | eq | mb; + var ph = mv | ~(xh | pv); + var mh = pv & xh; + score += (ph >>> (m - 1)) & 1; + score -= (mh >>> (m - 1)) & 1; + if ((ph >>> 31) ^ pb) { + phc[(i / 32) | 0] ^= 1 << i; + } + if ((mh >>> 31) ^ mb) { + mhc[(i / 32) | 0] ^= 1 << i; + } + ph = (ph << 1) | pb; + mh = (mh << 1) | mb; + pv = mh | ~(xv | ph); + mv = ph & xv; + } + for (var k = start; k < vlen; k++) { + peq[b.charCodeAt(k)] = 0; + } + return score; +}; +var distance = function (a, b) { + if (a.length < b.length) { + var tmp = b; + b = a; + a = tmp; + } + if (b.length === 0) { + return a.length; + } + if (a.length <= 32) { + return myers_32(a, b); + } + return myers_x(a, b); +}; +exports.distance = distance; +var closest = function (str, arr) { + var min_distance = Infinity; + var min_index = 0; + for (var i = 0; i < arr.length; i++) { + var dist = distance(str, arr[i]); + if (dist < min_distance) { + min_distance = dist; + min_index = i; + } + } + return arr[min_index]; +}; +exports.closest = closest; diff --git a/node_modules/fastest-levenshtein/package.json b/node_modules/fastest-levenshtein/package.json index 4d3ca34..c395b85 100644 --- a/node_modules/fastest-levenshtein/package.json +++ b/node_modules/fastest-levenshtein/package.json @@ -1,8 +1,10 @@ { "name": "fastest-levenshtein", - "version": "1.0.12", + "version": "1.0.16", "description": "Fastest Levenshtein distance implementation in JS.", - "main": "index.js", + "main": "mod.js", + "types": "mod.d.ts", + "module": "./esm/mod.js", "repository": { "type": "git", "url": "git+https://github.com/ka-weihe/fastest-levenshtein.git" @@ -33,31 +35,38 @@ }, "homepage": "https://github.com/ka-weihe/fastest-levenshtein#README", "scripts": { - "test": "jest", - "test:coverage": "jest --coverage", - "test:coveralls": "jest --coverage --coverageReporters=text-lcov | coveralls" + "build": "tsc mod.ts --declaration", + "build:esm": "tsc --declaration -p tsconfig.esm.json", + "prepare": "npm run build && npm run build:esm", + "bench": "npm run build && tsc bench.ts && node bench.js", + "test": "npm run build && tsc test.ts && jest test.js", + "test:coverage": "npm run build && jest --coverage", + "test:coveralls": "npm run build && jest --coverage --coverageReporters=text-lcov | coveralls" }, "devDependencies": { + "@types/benchmark": "^1.0.33", + "@types/jest": "^26.0.15", + "@typescript-eslint/eslint-plugin": "^4.7.0", + "@typescript-eslint/parser": "^4.7.0", "benchmark": "^2.1.4", "coveralls": "^3.1.0", - "eslint": "^7.5.0", - "eslint-config-airbnb": "^18.2.0", - "eslint-config-airbnb-base": "^14.2.0", + "eslint": "^7.13.0", "eslint-config-node": "^4.1.0", - "eslint-config-prettier": "^6.11.0", - "eslint-plugin-import": "^2.22.0", - "eslint-plugin-jsx-a11y": "^6.3.1", + "eslint-config-prettier": "^6.15.0", + "eslint-plugin-import": "^2.22.1", "eslint-plugin-node": "^11.1.0", "eslint-plugin-prettier": "^3.1.4", - "eslint-plugin-react": "^7.20.3", - "eslint-plugin-react-hooks": "^4.0.0", "fast-levenshtein": "^2.0.6", - "jest": "^26.1.0", + "jest": "^26.6.3", "js-levenshtein": "^1.1.6", "leven": "^3.1.0", + "levenshtein-edit-distance": "^2.0.5", "natural": "^2.1.5", - "prettier": "^2.0.5", - "talisman": "^1.1.2", - "levenshtein-edit-distance": "^2.0.5" + "prettier": "^2.1.2", + "talisman": "^1.1.3", + "typescript": "^4.0.5" + }, + "engines": { + "node": ">= 4.9.1" } } diff --git a/node_modules/fastest-levenshtein/test.js b/node_modules/fastest-levenshtein/test.js index 4b5d6ec..4750633 100644 --- a/node_modules/fastest-levenshtein/test.js +++ b/node_modules/fastest-levenshtein/test.js @@ -1,64 +1,55 @@ -const {distance, closest} = require("./index.js"); - -const levenshtein = (a, b) => { - if (a.length === 0) return b.length; - if (b.length === 0) return a.length; - - if (a.length > b.length) { - const tmp = a; - a = b; - b = tmp; - } - - const row = []; - for (let i = 0; i <= a.length; i++) { - row[i] = i; - } - - for (let i = 1; i <= b.length; i++) { - let prev = i; - for (let j = 1; j <= a.length; j++) { - let val; - if (b.charAt(i - 1) === a.charAt(j - 1)) { - val = row[j - 1]; - } else { - val = Math.min(row[j - 1] + 1, prev + 1, row[j] + 1); - } - row[j - 1] = prev; - prev = val; +var _a = require("./mod.js"), closest = _a.closest, distance = _a.distance; +var levenshtein = function (a, b) { + if (a.length === 0) { + return b.length; } - row[a.length] = prev; - } - - return row[a.length]; + if (b.length === 0) { + return a.length; + } + if (a.length > b.length) { + var tmp = a; + a = b; + b = tmp; + } + var row = []; + for (var i = 0; i <= a.length; i++) { + row[i] = i; + } + for (var i = 1; i <= b.length; i++) { + var prev = i; + for (var j = 1; j <= a.length; j++) { + var val = 0; + if (b.charAt(i - 1) === a.charAt(j - 1)) { + val = row[j - 1]; + } + else { + val = Math.min(row[j - 1] + 1, prev + 1, row[j] + 1); + } + row[j - 1] = prev; + prev = val; + } + row[a.length] = prev; + } + return row[a.length]; }; - -function makeid(length) { - let result = ""; - const characters = - "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; - const charactersLength = characters.length; - for (let i = 0; i < length; i++) { - result += characters.charAt(Math.floor(Math.random() * charactersLength)); - } - return result; +var makeid = function (length) { + var result = ""; + var characters = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; + var charactersLength = characters.length; + for (var i = 0; i < length; i++) { + result += characters.charAt(Math.floor(Math.random() * charactersLength)); + } + return result; +}; +for (var i = 0; i < 10000; i++) { + var rnd_num1 = (Math.random() * 1000) | 0; + var rnd_num2 = (Math.random() * 1000) | 0; + var rnd_string1 = makeid(rnd_num1); + var rnd_string2 = makeid(rnd_num2); + var actual = distance(rnd_string1, rnd_string2); + var expected = levenshtein(rnd_string1, rnd_string2); + console.log(i); + if (actual !== expected) { + console.log("fail"); + } } - -test("test compare", () => { - const errors = 0; - for (let i = 0; i < 1000; i++) { - const rnd_num1 = (Math.random() * 1000) | 0; - const rnd_num2 = (Math.random() * 1000) | 0; - const rnd_string1 = makeid(rnd_num1); - const rnd_string2 = makeid(rnd_num2); - const actual = distance(rnd_string1, rnd_string2); - const expected = levenshtein(rnd_string1, rnd_string2); - expect(actual).toBe(expected); - } -}); - -test("test find", () => { - const actual = closest("fast", ["slow", "faster", "fastest"]); - const expected = "faster"; - expect(actual).toBe(expected); -}); diff --git a/node_modules/fastest-levenshtein/test.ts b/node_modules/fastest-levenshtein/test.ts new file mode 100644 index 0000000..41939bc --- /dev/null +++ b/node_modules/fastest-levenshtein/test.ts @@ -0,0 +1,67 @@ +const { closest, distance } = require("./mod.js"); + +const levenshtein = (a, b) => { + if (a.length === 0) { + return b.length; + } + if (b.length === 0) { + return a.length; + } + + if (a.length > b.length) { + const tmp = a; + a = b; + b = tmp; + } + + const row = []; + for (let i = 0; i <= a.length; i++) { + row[i] = i; + } + + for (let i = 1; i <= b.length; i++) { + let prev = i; + for (let j = 1; j <= a.length; j++) { + let val = 0; + if (b.charAt(i - 1) === a.charAt(j - 1)) { + val = row[j - 1]; + } else { + val = Math.min(row[j - 1] + 1, prev + 1, row[j] + 1); + } + row[j - 1] = prev; + prev = val; + } + row[a.length] = prev; + } + + return row[a.length]; +}; + +const makeid = (length) => { + let result = ""; + const characters = + "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; + const charactersLength = characters.length; + for (let i = 0; i < length; i++) { + result += characters.charAt(Math.floor(Math.random() * charactersLength)); + } + return result; +}; + +test("test compare", () => { + for (let i = 0; i < 1000; i++) { + const rnd_num1 = (Math.random() * 1000) | 0; + const rnd_num2 = (Math.random() * 1000) | 0; + const rnd_string1 = makeid(rnd_num1); + const rnd_string2 = makeid(rnd_num2); + const actual = distance(rnd_string1, rnd_string2); + const expected = levenshtein(rnd_string1, rnd_string2); + expect(actual).toBe(expected); + } +}); + +test("test find", () => { + const actual = closest("fast", ["slow", "faster", "fastest"]); + const expected = "faster"; + expect(actual).toBe(expected); +}); diff --git a/node_modules/@npmcli/config/LICENSE b/node_modules/fs-minipass/node_modules/minipass/LICENSE similarity index 90% rename from node_modules/@npmcli/config/LICENSE rename to node_modules/fs-minipass/node_modules/minipass/LICENSE index 19cec97..bf1dece 100644 --- a/node_modules/@npmcli/config/LICENSE +++ b/node_modules/fs-minipass/node_modules/minipass/LICENSE @@ -1,6 +1,6 @@ The ISC License -Copyright (c) npm, Inc. +Copyright (c) 2017-2022 npm, Inc., Isaac Z. Schlueter, and Contributors Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above diff --git a/node_modules/fs-minipass/node_modules/minipass/index.d.ts b/node_modules/fs-minipass/node_modules/minipass/index.d.ts new file mode 100644 index 0000000..65faf63 --- /dev/null +++ b/node_modules/fs-minipass/node_modules/minipass/index.d.ts @@ -0,0 +1,155 @@ +/// <reference types="node" /> +import { EventEmitter } from 'events' +import { Stream } from 'stream' + +declare namespace Minipass { + type Encoding = BufferEncoding | 'buffer' | null + + interface Writable extends EventEmitter { + end(): any + write(chunk: any, ...args: any[]): any + } + + interface Readable extends EventEmitter { + pause(): any + resume(): any + pipe(): any + } + + interface Pipe<R, W> { + src: Minipass<R, W> + dest: Writable + opts: PipeOptions + } + + type DualIterable<T> = Iterable<T> & AsyncIterable<T> + + type ContiguousData = Buffer | ArrayBufferLike | ArrayBufferView | string + + type BufferOrString = Buffer | string + + interface StringOptions { + encoding: BufferEncoding + objectMode?: boolean + async?: boolean + } + + interface BufferOptions { + encoding?: null | 'buffer' + objectMode?: boolean + async?: boolean + } + + interface ObjectModeOptions { + objectMode: true + async?: boolean + } + + interface PipeOptions { + end?: boolean + proxyErrors?: boolean + } + + type Options<T> = T extends string + ? StringOptions + : T extends Buffer + ? BufferOptions + : ObjectModeOptions +} + +declare class Minipass< + RType extends any = Buffer, + WType extends any = RType extends Minipass.BufferOrString + ? Minipass.ContiguousData + : RType + > + extends Stream + implements Minipass.DualIterable<RType> +{ + static isStream(stream: any): stream is Minipass.Readable | Minipass.Writable + + readonly bufferLength: number + readonly flowing: boolean + readonly writable: boolean + readonly readable: boolean + readonly paused: boolean + readonly emittedEnd: boolean + readonly destroyed: boolean + + /** + * Not technically private or readonly, but not safe to mutate. + */ + private readonly buffer: RType[] + private readonly pipes: Minipass.Pipe<RType, WType>[] + + /** + * Technically writable, but mutating it can change the type, + * so is not safe to do in TypeScript. + */ + readonly objectMode: boolean + async: boolean + + /** + * Note: encoding is not actually read-only, and setEncoding(enc) + * exists. However, this type definition will insist that TypeScript + * programs declare the type of a Minipass stream up front, and if + * that type is string, then an encoding MUST be set in the ctor. If + * the type is Buffer, then the encoding must be missing, or set to + * 'buffer' or null. If the type is anything else, then objectMode + * must be set in the constructor options. So there is effectively + * no allowed way that a TS program can set the encoding after + * construction, as doing so will destroy any hope of type safety. + * TypeScript does not provide many options for changing the type of + * an object at run-time, which is what changing the encoding does. + */ + readonly encoding: Minipass.Encoding + // setEncoding(encoding: Encoding): void + + // Options required if not reading buffers + constructor( + ...args: RType extends Buffer + ? [] | [Minipass.Options<RType>] + : [Minipass.Options<RType>] + ) + + write(chunk: WType, cb?: () => void): boolean + write(chunk: WType, encoding?: Minipass.Encoding, cb?: () => void): boolean + read(size?: number): RType + end(cb?: () => void): this + end(chunk: any, cb?: () => void): this + end(chunk: any, encoding?: Minipass.Encoding, cb?: () => void): this + pause(): void + resume(): void + promise(): Promise<void> + collect(): Promise<RType[]> + + concat(): RType extends Minipass.BufferOrString ? Promise<RType> : never + destroy(er?: any): void + pipe<W extends Minipass.Writable>(dest: W, opts?: Minipass.PipeOptions): W + unpipe<W extends Minipass.Writable>(dest: W): void + + /** + * alias for on() + */ + addEventHandler(event: string, listener: (...args: any[]) => any): this + + on(event: string, listener: (...args: any[]) => any): this + on(event: 'data', listener: (chunk: RType) => any): this + on(event: 'error', listener: (error: any) => any): this + on( + event: + | 'readable' + | 'drain' + | 'resume' + | 'end' + | 'prefinish' + | 'finish' + | 'close', + listener: () => any + ): this + + [Symbol.iterator](): Iterator<RType> + [Symbol.asyncIterator](): AsyncIterator<RType> +} + +export = Minipass diff --git a/node_modules/fs-minipass/node_modules/minipass/index.js b/node_modules/fs-minipass/node_modules/minipass/index.js new file mode 100644 index 0000000..e8797aa --- /dev/null +++ b/node_modules/fs-minipass/node_modules/minipass/index.js @@ -0,0 +1,649 @@ +'use strict' +const proc = typeof process === 'object' && process ? process : { + stdout: null, + stderr: null, +} +const EE = require('events') +const Stream = require('stream') +const SD = require('string_decoder').StringDecoder + +const EOF = Symbol('EOF') +const MAYBE_EMIT_END = Symbol('maybeEmitEnd') +const EMITTED_END = Symbol('emittedEnd') +const EMITTING_END = Symbol('emittingEnd') +const EMITTED_ERROR = Symbol('emittedError') +const CLOSED = Symbol('closed') +const READ = Symbol('read') +const FLUSH = Symbol('flush') +const FLUSHCHUNK = Symbol('flushChunk') +const ENCODING = Symbol('encoding') +const DECODER = Symbol('decoder') +const FLOWING = Symbol('flowing') +const PAUSED = Symbol('paused') +const RESUME = Symbol('resume') +const BUFFERLENGTH = Symbol('bufferLength') +const BUFFERPUSH = Symbol('bufferPush') +const BUFFERSHIFT = Symbol('bufferShift') +const OBJECTMODE = Symbol('objectMode') +const DESTROYED = Symbol('destroyed') +const EMITDATA = Symbol('emitData') +const EMITEND = Symbol('emitEnd') +const EMITEND2 = Symbol('emitEnd2') +const ASYNC = Symbol('async') + +const defer = fn => Promise.resolve().then(fn) + +// TODO remove when Node v8 support drops +const doIter = global._MP_NO_ITERATOR_SYMBOLS_ !== '1' +const ASYNCITERATOR = doIter && Symbol.asyncIterator + || Symbol('asyncIterator not implemented') +const ITERATOR = doIter && Symbol.iterator + || Symbol('iterator not implemented') + +// events that mean 'the stream is over' +// these are treated specially, and re-emitted +// if they are listened for after emitting. +const isEndish = ev => + ev === 'end' || + ev === 'finish' || + ev === 'prefinish' + +const isArrayBuffer = b => b instanceof ArrayBuffer || + typeof b === 'object' && + b.constructor && + b.constructor.name === 'ArrayBuffer' && + b.byteLength >= 0 + +const isArrayBufferView = b => !Buffer.isBuffer(b) && ArrayBuffer.isView(b) + +class Pipe { + constructor (src, dest, opts) { + this.src = src + this.dest = dest + this.opts = opts + this.ondrain = () => src[RESUME]() + dest.on('drain', this.ondrain) + } + unpipe () { + this.dest.removeListener('drain', this.ondrain) + } + // istanbul ignore next - only here for the prototype + proxyErrors () {} + end () { + this.unpipe() + if (this.opts.end) + this.dest.end() + } +} + +class PipeProxyErrors extends Pipe { + unpipe () { + this.src.removeListener('error', this.proxyErrors) + super.unpipe() + } + constructor (src, dest, opts) { + super(src, dest, opts) + this.proxyErrors = er => dest.emit('error', er) + src.on('error', this.proxyErrors) + } +} + +module.exports = class Minipass extends Stream { + constructor (options) { + super() + this[FLOWING] = false + // whether we're explicitly paused + this[PAUSED] = false + this.pipes = [] + this.buffer = [] + this[OBJECTMODE] = options && options.objectMode || false + if (this[OBJECTMODE]) + this[ENCODING] = null + else + this[ENCODING] = options && options.encoding || null + if (this[ENCODING] === 'buffer') + this[ENCODING] = null + this[ASYNC] = options && !!options.async || false + this[DECODER] = this[ENCODING] ? new SD(this[ENCODING]) : null + this[EOF] = false + this[EMITTED_END] = false + this[EMITTING_END] = false + this[CLOSED] = false + this[EMITTED_ERROR] = null + this.writable = true + this.readable = true + this[BUFFERLENGTH] = 0 + this[DESTROYED] = false + } + + get bufferLength () { return this[BUFFERLENGTH] } + + get encoding () { return this[ENCODING] } + set encoding (enc) { + if (this[OBJECTMODE]) + throw new Error('cannot set encoding in objectMode') + + if (this[ENCODING] && enc !== this[ENCODING] && + (this[DECODER] && this[DECODER].lastNeed || this[BUFFERLENGTH])) + throw new Error('cannot change encoding') + + if (this[ENCODING] !== enc) { + this[DECODER] = enc ? new SD(enc) : null + if (this.buffer.length) + this.buffer = this.buffer.map(chunk => this[DECODER].write(chunk)) + } + + this[ENCODING] = enc + } + + setEncoding (enc) { + this.encoding = enc + } + + get objectMode () { return this[OBJECTMODE] } + set objectMode (om) { this[OBJECTMODE] = this[OBJECTMODE] || !!om } + + get ['async'] () { return this[ASYNC] } + set ['async'] (a) { this[ASYNC] = this[ASYNC] || !!a } + + write (chunk, encoding, cb) { + if (this[EOF]) + throw new Error('write after end') + + if (this[DESTROYED]) { + this.emit('error', Object.assign( + new Error('Cannot call write after a stream was destroyed'), + { code: 'ERR_STREAM_DESTROYED' } + )) + return true + } + + if (typeof encoding === 'function') + cb = encoding, encoding = 'utf8' + + if (!encoding) + encoding = 'utf8' + + const fn = this[ASYNC] ? defer : f => f() + + // convert array buffers and typed array views into buffers + // at some point in the future, we may want to do the opposite! + // leave strings and buffers as-is + // anything else switches us into object mode + if (!this[OBJECTMODE] && !Buffer.isBuffer(chunk)) { + if (isArrayBufferView(chunk)) + chunk = Buffer.from(chunk.buffer, chunk.byteOffset, chunk.byteLength) + else if (isArrayBuffer(chunk)) + chunk = Buffer.from(chunk) + else if (typeof chunk !== 'string') + // use the setter so we throw if we have encoding set + this.objectMode = true + } + + // handle object mode up front, since it's simpler + // this yields better performance, fewer checks later. + if (this[OBJECTMODE]) { + /* istanbul ignore if - maybe impossible? */ + if (this.flowing && this[BUFFERLENGTH] !== 0) + this[FLUSH](true) + + if (this.flowing) + this.emit('data', chunk) + else + this[BUFFERPUSH](chunk) + + if (this[BUFFERLENGTH] !== 0) + this.emit('readable') + + if (cb) + fn(cb) + + return this.flowing + } + + // at this point the chunk is a buffer or string + // don't buffer it up or send it to the decoder + if (!chunk.length) { + if (this[BUFFERLENGTH] !== 0) + this.emit('readable') + if (cb) + fn(cb) + return this.flowing + } + + // fast-path writing strings of same encoding to a stream with + // an empty buffer, skipping the buffer/decoder dance + if (typeof chunk === 'string' && + // unless it is a string already ready for us to use + !(encoding === this[ENCODING] && !this[DECODER].lastNeed)) { + chunk = Buffer.from(chunk, encoding) + } + + if (Buffer.isBuffer(chunk) && this[ENCODING]) + chunk = this[DECODER].write(chunk) + + // Note: flushing CAN potentially switch us into not-flowing mode + if (this.flowing && this[BUFFERLENGTH] !== 0) + this[FLUSH](true) + + if (this.flowing) + this.emit('data', chunk) + else + this[BUFFERPUSH](chunk) + + if (this[BUFFERLENGTH] !== 0) + this.emit('readable') + + if (cb) + fn(cb) + + return this.flowing + } + + read (n) { + if (this[DESTROYED]) + return null + + if (this[BUFFERLENGTH] === 0 || n === 0 || n > this[BUFFERLENGTH]) { + this[MAYBE_EMIT_END]() + return null + } + + if (this[OBJECTMODE]) + n = null + + if (this.buffer.length > 1 && !this[OBJECTMODE]) { + if (this.encoding) + this.buffer = [this.buffer.join('')] + else + this.buffer = [Buffer.concat(this.buffer, this[BUFFERLENGTH])] + } + + const ret = this[READ](n || null, this.buffer[0]) + this[MAYBE_EMIT_END]() + return ret + } + + [READ] (n, chunk) { + if (n === chunk.length || n === null) + this[BUFFERSHIFT]() + else { + this.buffer[0] = chunk.slice(n) + chunk = chunk.slice(0, n) + this[BUFFERLENGTH] -= n + } + + this.emit('data', chunk) + + if (!this.buffer.length && !this[EOF]) + this.emit('drain') + + return chunk + } + + end (chunk, encoding, cb) { + if (typeof chunk === 'function') + cb = chunk, chunk = null + if (typeof encoding === 'function') + cb = encoding, encoding = 'utf8' + if (chunk) + this.write(chunk, encoding) + if (cb) + this.once('end', cb) + this[EOF] = true + this.writable = false + + // if we haven't written anything, then go ahead and emit, + // even if we're not reading. + // we'll re-emit if a new 'end' listener is added anyway. + // This makes MP more suitable to write-only use cases. + if (this.flowing || !this[PAUSED]) + this[MAYBE_EMIT_END]() + return this + } + + // don't let the internal resume be overwritten + [RESUME] () { + if (this[DESTROYED]) + return + + this[PAUSED] = false + this[FLOWING] = true + this.emit('resume') + if (this.buffer.length) + this[FLUSH]() + else if (this[EOF]) + this[MAYBE_EMIT_END]() + else + this.emit('drain') + } + + resume () { + return this[RESUME]() + } + + pause () { + this[FLOWING] = false + this[PAUSED] = true + } + + get destroyed () { + return this[DESTROYED] + } + + get flowing () { + return this[FLOWING] + } + + get paused () { + return this[PAUSED] + } + + [BUFFERPUSH] (chunk) { + if (this[OBJECTMODE]) + this[BUFFERLENGTH] += 1 + else + this[BUFFERLENGTH] += chunk.length + this.buffer.push(chunk) + } + + [BUFFERSHIFT] () { + if (this.buffer.length) { + if (this[OBJECTMODE]) + this[BUFFERLENGTH] -= 1 + else + this[BUFFERLENGTH] -= this.buffer[0].length + } + return this.buffer.shift() + } + + [FLUSH] (noDrain) { + do {} while (this[FLUSHCHUNK](this[BUFFERSHIFT]())) + + if (!noDrain && !this.buffer.length && !this[EOF]) + this.emit('drain') + } + + [FLUSHCHUNK] (chunk) { + return chunk ? (this.emit('data', chunk), this.flowing) : false + } + + pipe (dest, opts) { + if (this[DESTROYED]) + return + + const ended = this[EMITTED_END] + opts = opts || {} + if (dest === proc.stdout || dest === proc.stderr) + opts.end = false + else + opts.end = opts.end !== false + opts.proxyErrors = !!opts.proxyErrors + + // piping an ended stream ends immediately + if (ended) { + if (opts.end) + dest.end() + } else { + this.pipes.push(!opts.proxyErrors ? new Pipe(this, dest, opts) + : new PipeProxyErrors(this, dest, opts)) + if (this[ASYNC]) + defer(() => this[RESUME]()) + else + this[RESUME]() + } + + return dest + } + + unpipe (dest) { + const p = this.pipes.find(p => p.dest === dest) + if (p) { + this.pipes.splice(this.pipes.indexOf(p), 1) + p.unpipe() + } + } + + addListener (ev, fn) { + return this.on(ev, fn) + } + + on (ev, fn) { + const ret = super.on(ev, fn) + if (ev === 'data' && !this.pipes.length && !this.flowing) + this[RESUME]() + else if (ev === 'readable' && this[BUFFERLENGTH] !== 0) + super.emit('readable') + else if (isEndish(ev) && this[EMITTED_END]) { + super.emit(ev) + this.removeAllListeners(ev) + } else if (ev === 'error' && this[EMITTED_ERROR]) { + if (this[ASYNC]) + defer(() => fn.call(this, this[EMITTED_ERROR])) + else + fn.call(this, this[EMITTED_ERROR]) + } + return ret + } + + get emittedEnd () { + return this[EMITTED_END] + } + + [MAYBE_EMIT_END] () { + if (!this[EMITTING_END] && + !this[EMITTED_END] && + !this[DESTROYED] && + this.buffer.length === 0 && + this[EOF]) { + this[EMITTING_END] = true + this.emit('end') + this.emit('prefinish') + this.emit('finish') + if (this[CLOSED]) + this.emit('close') + this[EMITTING_END] = false + } + } + + emit (ev, data, ...extra) { + // error and close are only events allowed after calling destroy() + if (ev !== 'error' && ev !== 'close' && ev !== DESTROYED && this[DESTROYED]) + return + else if (ev === 'data') { + return !data ? false + : this[ASYNC] ? defer(() => this[EMITDATA](data)) + : this[EMITDATA](data) + } else if (ev === 'end') { + return this[EMITEND]() + } else if (ev === 'close') { + this[CLOSED] = true + // don't emit close before 'end' and 'finish' + if (!this[EMITTED_END] && !this[DESTROYED]) + return + const ret = super.emit('close') + this.removeAllListeners('close') + return ret + } else if (ev === 'error') { + this[EMITTED_ERROR] = data + const ret = super.emit('error', data) + this[MAYBE_EMIT_END]() + return ret + } else if (ev === 'resume') { + const ret = super.emit('resume') + this[MAYBE_EMIT_END]() + return ret + } else if (ev === 'finish' || ev === 'prefinish') { + const ret = super.emit(ev) + this.removeAllListeners(ev) + return ret + } + + // Some other unknown event + const ret = super.emit(ev, data, ...extra) + this[MAYBE_EMIT_END]() + return ret + } + + [EMITDATA] (data) { + for (const p of this.pipes) { + if (p.dest.write(data) === false) + this.pause() + } + const ret = super.emit('data', data) + this[MAYBE_EMIT_END]() + return ret + } + + [EMITEND] () { + if (this[EMITTED_END]) + return + + this[EMITTED_END] = true + this.readable = false + if (this[ASYNC]) + defer(() => this[EMITEND2]()) + else + this[EMITEND2]() + } + + [EMITEND2] () { + if (this[DECODER]) { + const data = this[DECODER].end() + if (data) { + for (const p of this.pipes) { + p.dest.write(data) + } + super.emit('data', data) + } + } + + for (const p of this.pipes) { + p.end() + } + const ret = super.emit('end') + this.removeAllListeners('end') + return ret + } + + // const all = await stream.collect() + collect () { + const buf = [] + if (!this[OBJECTMODE]) + buf.dataLength = 0 + // set the promise first, in case an error is raised + // by triggering the flow here. + const p = this.promise() + this.on('data', c => { + buf.push(c) + if (!this[OBJECTMODE]) + buf.dataLength += c.length + }) + return p.then(() => buf) + } + + // const data = await stream.concat() + concat () { + return this[OBJECTMODE] + ? Promise.reject(new Error('cannot concat in objectMode')) + : this.collect().then(buf => + this[OBJECTMODE] + ? Promise.reject(new Error('cannot concat in objectMode')) + : this[ENCODING] ? buf.join('') : Buffer.concat(buf, buf.dataLength)) + } + + // stream.promise().then(() => done, er => emitted error) + promise () { + return new Promise((resolve, reject) => { + this.on(DESTROYED, () => reject(new Error('stream destroyed'))) + this.on('error', er => reject(er)) + this.on('end', () => resolve()) + }) + } + + // for await (let chunk of stream) + [ASYNCITERATOR] () { + const next = () => { + const res = this.read() + if (res !== null) + return Promise.resolve({ done: false, value: res }) + + if (this[EOF]) + return Promise.resolve({ done: true }) + + let resolve = null + let reject = null + const onerr = er => { + this.removeListener('data', ondata) + this.removeListener('end', onend) + reject(er) + } + const ondata = value => { + this.removeListener('error', onerr) + this.removeListener('end', onend) + this.pause() + resolve({ value: value, done: !!this[EOF] }) + } + const onend = () => { + this.removeListener('error', onerr) + this.removeListener('data', ondata) + resolve({ done: true }) + } + const ondestroy = () => onerr(new Error('stream destroyed')) + return new Promise((res, rej) => { + reject = rej + resolve = res + this.once(DESTROYED, ondestroy) + this.once('error', onerr) + this.once('end', onend) + this.once('data', ondata) + }) + } + + return { next } + } + + // for (let chunk of stream) + [ITERATOR] () { + const next = () => { + const value = this.read() + const done = value === null + return { value, done } + } + return { next } + } + + destroy (er) { + if (this[DESTROYED]) { + if (er) + this.emit('error', er) + else + this.emit(DESTROYED) + return this + } + + this[DESTROYED] = true + + // throw away all buffered data, it's never coming out + this.buffer.length = 0 + this[BUFFERLENGTH] = 0 + + if (typeof this.close === 'function' && !this[CLOSED]) + this.close() + + if (er) + this.emit('error', er) + else // if no error to emit, still reject pending promises + this.emit(DESTROYED) + + return this + } + + static isStream (s) { + return !!s && (s instanceof Minipass || s instanceof Stream || + s instanceof EE && ( + typeof s.pipe === 'function' || // readable + (typeof s.write === 'function' && typeof s.end === 'function') // writable + )) + } +} diff --git a/node_modules/fs-minipass/node_modules/minipass/package.json b/node_modules/fs-minipass/node_modules/minipass/package.json new file mode 100644 index 0000000..548d03f --- /dev/null +++ b/node_modules/fs-minipass/node_modules/minipass/package.json @@ -0,0 +1,56 @@ +{ + "name": "minipass", + "version": "3.3.6", + "description": "minimal implementation of a PassThrough stream", + "main": "index.js", + "types": "index.d.ts", + "dependencies": { + "yallist": "^4.0.0" + }, + "devDependencies": { + "@types/node": "^17.0.41", + "end-of-stream": "^1.4.0", + "prettier": "^2.6.2", + "tap": "^16.2.0", + "through2": "^2.0.3", + "ts-node": "^10.8.1", + "typescript": "^4.7.3" + }, + "scripts": { + "test": "tap", + "preversion": "npm test", + "postversion": "npm publish", + "postpublish": "git push origin --follow-tags" + }, + "repository": { + "type": "git", + "url": "git+https://github.com/isaacs/minipass.git" + }, + "keywords": [ + "passthrough", + "stream" + ], + "author": "Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me/)", + "license": "ISC", + "files": [ + "index.d.ts", + "index.js" + ], + "tap": { + "check-coverage": true + }, + "engines": { + "node": ">=8" + }, + "prettier": { + "semi": false, + "printWidth": 80, + "tabWidth": 2, + "useTabs": false, + "singleQuote": true, + "jsxSingleQuote": false, + "bracketSameLine": true, + "arrowParens": "avoid", + "endOfLine": "lf" + } +} diff --git a/node_modules/ignore-walk/index.js b/node_modules/ignore-walk/lib/index.js similarity index 91% rename from node_modules/ignore-walk/index.js rename to node_modules/ignore-walk/lib/index.js index 13fc954..40a0726 100644 --- a/node_modules/ignore-walk/index.js +++ b/node_modules/ignore-walk/lib/index.js @@ -64,7 +64,7 @@ class Walker extends EE { this.entries = entries if (entries.length === 0) { if (this.includeEmpty) { - this.result.add(this.path.substr(this.root.length + 1)) + this.result.add(this.path.slice(this.root.length + 1)) } this.emit('done', this.result) } else { @@ -108,7 +108,9 @@ class Walker extends EE { } const rules = data.split(/\r?\n/) .filter(line => !/^#|^$/.test(line.trim())) - .map(r => new Minimatch(r, mmopt)) + .map(rule => { + return new Minimatch(rule.trim(), mmopt) + }) this.ignoreRules[file] = rules @@ -156,7 +158,7 @@ class Walker extends EE { const abs = this.path + '/' + entry if (!st.isDirectory()) { if (file) { - this.result.add(abs.substr(this.root.length + 1)) + this.result.add(abs.slice(this.root.length + 1)) } then() } else { @@ -171,21 +173,21 @@ class Walker extends EE { stat ({ entry, file, dir }, then) { const abs = this.path + '/' + entry - fs.lstat(abs, (er, st) => { - if (er) { - this.emit('error', er) + fs.lstat(abs, (lstatErr, lstatResult) => { + if (lstatErr) { + this.emit('error', lstatErr) } else { - const isSymbolicLink = st.isSymbolicLink() + const isSymbolicLink = lstatResult.isSymbolicLink() if (this.follow && isSymbolicLink) { - fs.stat(abs, (er, st) => { - if (er) { - this.emit('error', er) + fs.stat(abs, (statErr, statResult) => { + if (statErr) { + this.emit('error', statErr) } else { - this.onstat({ st, entry, file, dir, isSymbolicLink }, then) + this.onstat({ st: statResult, entry, file, dir, isSymbolicLink }, then) } }) } else { - this.onstat({ st, entry, file, dir, isSymbolicLink }, then) + this.onstat({ st: lstatResult, entry, file, dir, isSymbolicLink }, then) } } }) diff --git a/node_modules/ignore-walk/package.json b/node_modules/ignore-walk/package.json index ec6923d..3d977ed 100644 --- a/node_modules/ignore-walk/package.json +++ b/node_modules/ignore-walk/package.json @@ -1,26 +1,27 @@ { "name": "ignore-walk", - "version": "4.0.1", + "version": "6.0.0", "description": "Nested/recursive `.gitignore`/`.npmignore` parsing and filtering.", - "main": "index.js", + "main": "lib/index.js", "devDependencies": { - "@npmcli/lint": "^1.0.2", - "mkdirp": "^0.5.1", - "mutate-fs": "^1.1.0", - "rimraf": "^2.6.1", - "tap": "^15.0.6" + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", + "mkdirp": "^1.0.4", + "mutate-fs": "^2.1.1", + "rimraf": "^3.0.2", + "tap": "^16.0.1" }, "scripts": { "test": "tap", - "posttest": "npm run lint --", - "lint": "npm run npmclilint -- \"*.*js\" \"test/**/*.*js\"", + "posttest": "npm run lint", + "lint": "eslint \"**/*.js\"", "eslint": "eslint", "lintfix": "npm run lint -- --fix", - "preversion": "npm test", - "postversion": "npm publish", - "postpublish": "git push origin --follow-tags", "npmclilint": "npmcli-lint", - "postsnap": "npm run lintfix --" + "postsnap": "npm run lintfix --", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "snap": "tap" }, "keywords": [ "ignorefile", @@ -30,25 +31,35 @@ ".npmignore", "glob" ], - "author": "Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me/)", + "author": "GitHub Inc.", "license": "ISC", "repository": { "type": "git", - "url": "git+https://github.com/isaacs/ignore-walk.git" + "url": "https://github.com/npm/ignore-walk.git" }, "files": [ - "index.js" + "bin/", + "lib/" ], "dependencies": { - "minimatch": "^3.0.4" + "minimatch": "^5.0.1" }, "tap": { "test-env": "LC_ALL=sk", "before": "test/00-setup.js", "after": "test/zz-cleanup.js", - "jobs": 1 + "jobs": 1, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1", + "windowsCI": false } } diff --git a/node_modules/init-package-json/lib/default-input.js b/node_modules/init-package-json/lib/default-input.js index 0003472..fe5abfd 100644 --- a/node_modules/init-package-json/lib/default-input.js +++ b/node_modules/init-package-json/lib/default-input.js @@ -17,8 +17,8 @@ function niceName (n) { function readDeps (test, excluded) { return function (cb) { - fs.readdir('node_modules', function (er, dir) { - if (er) { + fs.readdir('node_modules', function (readdirErr, dir) { + if (readdirErr) { return cb() } var deps = {} @@ -35,8 +35,8 @@ function readDeps (test, excluded) { } var dp = path.join(dirname, 'node_modules', d, 'package.json') - fs.readFile(dp, 'utf8', function (er, p) { - if (er) { + fs.readFile(dp, 'utf8', function (readFileErr, p) { + if (readFileErr) { return next() } try { @@ -108,11 +108,11 @@ var version = package.version || '1.0.0' exports.version = yes ? version : - prompt('version', version, function (version) { - if (semver.valid(version)) { - return version + prompt('version', version, function (promptedVersion) { + if (semver.valid(promptedVersion)) { + return promptedVersion } - var er = new Error('Invalid version: "' + version + '"') + var er = new Error('Invalid version: "' + promptedVersion + '"') er.notValid = true return er }) @@ -128,8 +128,8 @@ if (!package.main) { f = [] } - f = f.filter(function (f) { - return f.match(/\.js$/) + f = f.filter(function (filtered) { + return filtered.match(/\.js$/) }) if (f.indexOf('index.js') !== -1) { @@ -261,17 +261,17 @@ if (!package.repository) { } if (!package.keywords) { - exports.keywords = yes ? '' : prompt('keywords', function (s) { - if (!s) { + exports.keywords = yes ? '' : prompt('keywords', function (promptedKeywords) { + if (!promptedKeywords) { return undefined } - if (Array.isArray(s)) { - s = s.join(' ') + if (Array.isArray(promptedKeywords)) { + promptedKeywords = promptedKeywords.join(' ') } - if (typeof s !== 'string') { - return s + if (typeof promptedKeywords !== 'string') { + return promptedKeywords } - return s.split(/[\s,]+/) + return promptedKeywords.split(/[\s,]+/) }) } diff --git a/node_modules/init-package-json/lib/init-package-json.js b/node_modules/init-package-json/lib/init-package-json.js index bee7935..230bcd8 100644 --- a/node_modules/init-package-json/lib/init-package-json.js +++ b/node_modules/init-package-json/lib/init-package-json.js @@ -74,62 +74,62 @@ function init (dir, input, config, cb) { var pz = new PZ(input, ctx) pz.backupFile = def pz.on('error', cb) - pz.on('data', function (data) { - Object.keys(data).forEach(function (k) { - if (data[k] !== undefined && data[k] !== null) { - pkg[k] = data[k] + pz.on('data', function (pzData) { + Object.keys(pzData).forEach(function (k) { + if (pzData[k] !== undefined && pzData[k] !== null) { + pkg[k] = pzData[k] } }) // only do a few of these. // no need for mans or contributors if they're in the files - var es = readJson.extraSet + es = readJson.extraSet readJson.extraSet = es.filter(function (fn) { return fn.name !== 'authors' && fn.name !== 'mans' }) - readJson.extras(packageFile, pkg, function (er, pkg) { - if (er) { - return cb(er, pkg) + readJson.extras(packageFile, pkg, function (extrasErr, pkgWithExtras) { + if (extrasErr) { + return cb(extrasErr, pkgWithExtras) } readJson.extraSet = es - pkg = unParsePeople(pkg) + pkgWithExtras = unParsePeople(pkgWithExtras) // no need for the readme now. - delete pkg.readme - delete pkg.readmeFilename + delete pkgWithExtras.readme + delete pkgWithExtras.readmeFilename // really don't want to have this lying around in the file - delete pkg._id + delete pkgWithExtras._id // ditto - delete pkg.gitHead + delete pkgWithExtras.gitHead // if the repo is empty, remove it. - if (!pkg.repository) { - delete pkg.repository + if (!pkgWithExtras.repository) { + delete pkgWithExtras.repository } // readJson filters out empty descriptions, but init-package-json // traditionally leaves them alone - if (!pkg.description) { - pkg.description = data.description + if (!pkgWithExtras.description) { + pkgWithExtras.description = pzData.description } - var d = JSON.stringify(updateDeps(pkg), null, 2) + '\n' - function write (yes) { - fs.writeFile(packageFile, d, 'utf8', function (er) { - if (!er && yes && !config.get('silent')) { - console.log('Wrote to %s:\n\n%s\n', packageFile, d) + var stringified = JSON.stringify(updateDeps(pkgWithExtras), null, 2) + '\n' + function write (writeYes) { + fs.writeFile(packageFile, stringified, 'utf8', function (writeFileErr) { + if (!writeFileErr && writeYes && !config.get('silent')) { + console.log('Wrote to %s:\n\n%s\n', packageFile, stringified) } - return cb(er, pkg) + return cb(writeFileErr, pkgWithExtras) }) } if (ctx.yes) { return write(true) } - console.log('About to write to %s:\n\n%s\n', packageFile, d) - read({prompt: 'Is this OK? ', default: 'yes'}, function (er, ok) { - if (er) { - return cb(er) + console.log('About to write to %s:\n\n%s\n', packageFile, stringified) + read({ prompt: 'Is this OK? ', default: 'yes' }, function (promptErr, ok) { + if (promptErr) { + return cb(promptErr) } if (!ok || ok.toLowerCase().charAt(0) !== 'y') { console.log('Aborted.') diff --git a/node_modules/init-package-json/package.json b/node_modules/init-package-json/package.json index 6d642f6..6641323 100644 --- a/node_modules/init-package-json/package.json +++ b/node_modules/init-package-json/package.json @@ -1,17 +1,15 @@ { "name": "init-package-json", - "version": "2.0.5", + "version": "4.0.1", "main": "lib/init-package-json.js", "scripts": { "test": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "lint": "eslint '**/*.js'", - "postlint": "npm-template-check", + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", "lintfix": "npm run lint -- --fix", "snap": "tap", - "posttest": "npm run lint" + "posttest": "npm run lint", + "template-oss-apply": "template-oss-apply --force" }, "repository": { "type": "git", @@ -21,26 +19,31 @@ "license": "ISC", "description": "A node module to get your node module started", "dependencies": { - "npm-package-arg": "^8.1.5", + "npm-package-arg": "^10.0.0", "promzard": "^0.3.0", - "read": "~1.0.1", - "read-package-json": "^4.1.1", + "read": "^1.0.7", + "read-package-json": "^6.0.0", "semver": "^7.3.5", "validate-npm-package-license": "^3.0.4", - "validate-npm-package-name": "^3.0.0" + "validate-npm-package-name": "^5.0.0" }, "devDependencies": { - "@npmcli/config": "^2.1.0", - "@npmcli/template-oss": "^1.0.3", - "tap": "^15.0.9" + "@npmcli/config": "^6.0.0", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.6.1", + "tap": "^16.0.1" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "tap": { "statements": "94", "branches": "83", - "lines": "94" + "lines": "94", + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "keywords": [ "init", @@ -53,8 +56,11 @@ "start" ], "files": [ - "bin", - "lib" + "bin/", + "lib/" ], - "templateVersion": "1.0.3" + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.6.1" + } } diff --git a/node_modules/just-diff-apply/index.d.ts b/node_modules/just-diff-apply/index.d.ts new file mode 100644 index 0000000..7547b72 --- /dev/null +++ b/node_modules/just-diff-apply/index.d.ts @@ -0,0 +1,17 @@ +// Definitions by: Eddie Atkinson <https://github.com/eddie-atkinson> + +type Operation = "add" | "replace" | "remove" | "move"; + +type DiffOps = Array<{ + op: Operation; + path: Array<string | number>; + value?: any; +}>; +type PathConverter = (path: string) => string[]; + +export function diffApply<T extends object>( + obj: T, + diff: DiffOps, + pathConverter?: PathConverter +): T; +export const jsonPatchPathConverter: PathConverter; diff --git a/node_modules/just-diff-apply/index.js b/node_modules/just-diff-apply/index.js index ceb3268..c5d2c32 100644 --- a/node_modules/just-diff-apply/index.js +++ b/node_modules/just-diff-apply/index.js @@ -47,6 +47,7 @@ module.exports = { var REMOVE = 'remove'; var REPLACE = 'replace'; var ADD = 'add'; +var MOVE = 'move'; function diffApply(obj, diff, pathConverter) { if (!obj || typeof obj != 'object') { @@ -62,44 +63,99 @@ function diffApply(obj, diff, pathConverter) { var thisDiff = diff[i]; var subObject = obj; var thisOp = thisDiff.op; - var thisPath = thisDiff.path; - if (pathConverter) { - thisPath = pathConverter(thisPath); - if (!Array.isArray(thisPath)) { - throw new Error('pathConverter must return an array'); + + var thisPath = transformPath(pathConverter, thisDiff.path); + var thisFromPath = thisDiff.from && transformPath(pathConverter, thisDiff.from); + var toPath, toPathCopy, lastToProp, subToObject, valueToMove; + + if (thisFromPath) { + // MOVE only, "fromPath" is effectively path and "path" is toPath + toPath = thisPath; + thisPath = thisFromPath; + + toPathCopy = toPath.slice(); + lastToProp = toPathCopy.pop(); + prototypeCheck(lastToProp); + if (lastToProp == null) { + return false; } - } else { - if (!Array.isArray(thisPath)) { - throw new Error('diff path must be an array, consider supplying a path converter'); + + var thisToProp; + while (((thisToProp = toPathCopy.shift())) != null) { + prototypeCheck(thisToProp); + if (!(thisToProp in subToObject)) { + subToObject[thisToProp] = {}; + } + subToObject = subToObject[thisToProp]; } } + var pathCopy = thisPath.slice(); var lastProp = pathCopy.pop(); + prototypeCheck(lastProp); if (lastProp == null) { return false; } + var thisProp; while (((thisProp = pathCopy.shift())) != null) { + prototypeCheck(thisProp); if (!(thisProp in subObject)) { subObject[thisProp] = {}; } subObject = subObject[thisProp]; } - if (thisOp === REMOVE || thisOp === REPLACE) { + if (thisOp === REMOVE || thisOp === REPLACE || thisOp === MOVE) { + var path = thisOp === MOVE ? thisDiff.from : thisDiff.path; if (!subObject.hasOwnProperty(lastProp)) { - throw new Error(['expected to find property', thisDiff.path, 'in object', obj].join(' ')); + throw new Error(['expected to find property', path, 'in object', obj].join(' ')); } } - if (thisOp === REMOVE) { + if (thisOp === REMOVE || thisOp === MOVE) { + if (thisOp === MOVE) { + valueToMove = subObject[lastProp]; + } Array.isArray(subObject) ? subObject.splice(lastProp, 1) : delete subObject[lastProp]; } if (thisOp === REPLACE || thisOp === ADD) { subObject[lastProp] = thisDiff.value; } + + if (thisOp === MOVE) { + subObject[lastToProp] = valueToMove; + } } return subObject; } +function transformPath(pathConverter, thisPath) { + if(pathConverter) { + thisPath = pathConverter(thisPath); + if(!Array.isArray(thisPath)) { + throw new Error([ + 'pathConverter must return an array, returned:', + thisPath, + ].join(' ')); + } + } else { + if(!Array.isArray(thisPath)) { + throw new Error([ + 'diff path', + thisPath, + 'must be an array, consider supplying a path converter'] + .join(' ')); + } + } + return thisPath; +} + function jsonPatchPathConverter(stringPath) { return stringPath.split('/').slice(1); } + +function prototypeCheck(prop) { + // coercion is intentional to catch prop values like `['__proto__']` + if (prop == '__proto__' || prop == 'constructor' || prop == 'prototype') { + throw new Error('setting of prototype values not supported'); + } +} diff --git a/node_modules/just-diff-apply/index.mjs b/node_modules/just-diff-apply/index.mjs index fcd26c2..adc5f46 100644 --- a/node_modules/just-diff-apply/index.mjs +++ b/node_modules/just-diff-apply/index.mjs @@ -42,6 +42,7 @@ var REMOVE = 'remove'; var REPLACE = 'replace'; var ADD = 'add'; +var MOVE = 'move'; function diffApply(obj, diff, pathConverter) { if (!obj || typeof obj != 'object') { @@ -57,54 +58,101 @@ function diffApply(obj, diff, pathConverter) { var thisDiff = diff[i]; var subObject = obj; var thisOp = thisDiff.op; - var thisPath = thisDiff.path; - if (pathConverter) { - thisPath = pathConverter(thisPath); - if (!Array.isArray(thisPath)) { - throw new Error('pathConverter must return an array'); + + var thisPath = transformPath(pathConverter, thisDiff.path); + var thisFromPath = thisDiff.from && transformPath(pathConverter, thisDiff.from); + var toPath, toPathCopy, lastToProp, subToObject, valueToMove; + + if (thisFromPath) { + // MOVE only, "fromPath" is effectively path and "path" is toPath + toPath = thisPath; + thisPath = thisFromPath; + + toPathCopy = toPath.slice(); + lastToProp = toPathCopy.pop(); + prototypeCheck(lastToProp); + if (lastToProp == null) { + return false; } - } else { - if (!Array.isArray(thisPath)) { - throw new Error( - 'diff path must be an array, consider supplying a path converter' - ); + + var thisToProp; + while (((thisToProp = toPathCopy.shift())) != null) { + prototypeCheck(thisToProp); + if (!(thisToProp in subToObject)) { + subToObject[thisToProp] = {}; + } + subToObject = subToObject[thisToProp]; } } + var pathCopy = thisPath.slice(); var lastProp = pathCopy.pop(); + prototypeCheck(lastProp); if (lastProp == null) { return false; } + var thisProp; - while ((thisProp = pathCopy.shift()) != null) { + while (((thisProp = pathCopy.shift())) != null) { + prototypeCheck(thisProp); if (!(thisProp in subObject)) { subObject[thisProp] = {}; } subObject = subObject[thisProp]; } - if (thisOp === REMOVE || thisOp === REPLACE) { + if (thisOp === REMOVE || thisOp === REPLACE || thisOp === MOVE) { + var path = thisOp === MOVE ? thisDiff.from : thisDiff.path; if (!subObject.hasOwnProperty(lastProp)) { - throw new Error( - ['expected to find property', thisDiff.path, 'in object', obj].join( - ' ' - ) - ); + throw new Error(['expected to find property', path, 'in object', obj].join(' ')); } } - if (thisOp === REMOVE) { - Array.isArray(subObject) - ? subObject.splice(lastProp, 1) - : delete subObject[lastProp]; + if (thisOp === REMOVE || thisOp === MOVE) { + if (thisOp === MOVE) { + valueToMove = subObject[lastProp]; + } + Array.isArray(subObject) ? subObject.splice(lastProp, 1) : delete subObject[lastProp]; } if (thisOp === REPLACE || thisOp === ADD) { subObject[lastProp] = thisDiff.value; } + + if (thisOp === MOVE) { + subObject[lastToProp] = valueToMove; + } } return subObject; } +function transformPath(pathConverter, thisPath) { + if(pathConverter) { + thisPath = pathConverter(thisPath); + if(!Array.isArray(thisPath)) { + throw new Error([ + 'pathConverter must return an array, returned:', + thisPath, + ].join(' ')); + } + } else { + if(!Array.isArray(thisPath)) { + throw new Error([ + 'diff path', + thisPath, + 'must be an array, consider supplying a path converter'] + .join(' ')); + } + } + return thisPath; +} + function jsonPatchPathConverter(stringPath) { return stringPath.split('/').slice(1); } +function prototypeCheck(prop) { + // coercion is intentional to catch prop values like `['__proto__']` + if (prop == '__proto__' || prop == 'constructor' || prop == 'prototype') { + throw new Error('setting of prototype values not supported'); + } +} + export {diffApply, jsonPatchPathConverter}; diff --git a/node_modules/just-diff-apply/index.tests.ts b/node_modules/just-diff-apply/index.tests.ts new file mode 100644 index 0000000..d02ba89 --- /dev/null +++ b/node_modules/just-diff-apply/index.tests.ts @@ -0,0 +1,108 @@ +import * as diffObj from "./index"; + +const { diffApply, jsonPatchPathConverter } = diffObj; +const obj1 = { + a: 2, + b: 3, + c: { + d: 5 + } +}; +const arr1 = [1, "bee"]; + +const objOps: diffObj.DiffOps = [ + { + op: "replace", + path: ["a"], + value: 10 + }, + { + op: "remove", + path: ["b"] + }, + { + op: "add", + path: ["e"], + value: 15 + }, + { + op: "remove", + path: ["c", "d"] + } +]; + +const arrOps: diffObj.DiffOps = [ + { + op: "replace", + path: [1], + value: 10 + }, + { + op: "remove", + path: [2] + }, + { + op: "add", + path: [7], + value: 15 + } +]; + +//OK +diffApply(obj1, objOps); +diffApply(obj1, []); +diffApply(arr1, arrOps); +diffApply(arr1, []); +diffApply(obj1, objOps, jsonPatchPathConverter); +diffApply(arr1, arrOps, jsonPatchPathConverter); + +// not OK +// @ts-expect-error +diffApply(obj1); +// @ts-expect-error +diffApply(arr2); +// @ts-expect-error +diffApply("a"); +// @ts-expect-error +diffApply(true); + +// @ts-expect-error +diffApply(obj1, 1); +// @ts-expect-error +diffApply(3, arr2); +// @ts-expect-error +diffApply(obj1, "a"); +// @ts-expect-error +diffApply("b", arr2); + +// @ts-expect-error +diffApply(obj1, [{ op: "delete", path: ["a"] }]); +// @ts-expect-error +diffApply(obj1, [{ op: "delete", path: ["a"] }], jsonPatchPathConverter); +// @ts-expect-error +diffApply(obj1, "a", jsonPatchPathConverter); +// @ts-expect-error +diffApply(obj1, ["a", "b", "c"], jsonPatchPathConverter); + +// @ts-expect-error +diff("a", jsonPatchPathConverter); +// @ts-expect-error +diff(true, jsonPatchPathConverter); + +// @ts-expect-error +diff(obj1, 1, jsonPatchPathConverter); +// @ts-expect-error +diff(3, arr2, jsonPatchPathConverter); +// @ts-expect-error +diff(obj1, "a", jsonPatchPathConverter); +// @ts-expect-error +diff("b", arr2, jsonPatchPathConverter); + +// @ts-expect-error +diff(obj1, obj2, "a"); +// @ts-expect-error +diff(arr1, arr2, 1); +// @ts-expect-error +diff(obj1, arr1, "bee"); +// @ts-expect-error +diff(obj2, arr2, "nope"); diff --git a/node_modules/just-diff-apply/package.json b/node_modules/just-diff-apply/package.json index c38bd47..5317303 100644 --- a/node_modules/just-diff-apply/package.json +++ b/node_modules/just-diff-apply/package.json @@ -1,15 +1,18 @@ { "name": "just-diff-apply", - "version": "4.0.1", + "version": "5.4.1", "description": "Apply a diff to an object. Optionally supports jsonPatch protocol", "main": "index.js", "module": "index.mjs", "exports": { ".": { "require": "./index.js", + "types": "./index.d.ts", "default": "./index.mjs" - } + }, + "./package.json": "./package.json" }, + "types": "index.d.ts", "scripts": { "test": "echo \"Error: no test specified\" && exit 1", "build": "rollup -c" @@ -28,4 +31,4 @@ "bugs": { "url": "https://github.com/angus-c/just/issues" } -} +} \ No newline at end of file diff --git a/node_modules/just-diff/index.js b/node_modules/just-diff/index.js index b49bed1..11ad371 100644 --- a/node_modules/just-diff/index.js +++ b/node_modules/just-diff/index.js @@ -129,12 +129,13 @@ function diff(obj1, obj2, pathConverter) { } } - return diffs.remove - .reverse() - .concat(diffs.replace) - .concat(diffs.add); + return diffs; } - return getDiff(obj1, obj2, [], {remove: [], replace: [], add: []}); + const finalDiffs = getDiff(obj1, obj2, [], {remove: [], replace: [], add: []}); + return finalDiffs.remove + .reverse() + .concat(finalDiffs.replace) + .concat(finalDiffs.add); } function pushReplace(path, basePath, key, diffs, pathConverter, obj2) { diff --git a/node_modules/just-diff/index.mjs b/node_modules/just-diff/index.mjs index 8da5b5c..a0c5834 100644 --- a/node_modules/just-diff/index.mjs +++ b/node_modules/just-diff/index.mjs @@ -124,9 +124,13 @@ function diff(obj1, obj2, pathConverter) { } } - return diffs.remove.reverse().concat(diffs.replace).concat(diffs.add); + return diffs; } - return getDiff(obj1, obj2, [], {remove: [], replace: [], add: []}); + const finalDiffs = getDiff(obj1, obj2, [], {remove: [], replace: [], add: []}); + return finalDiffs.remove + .reverse() + .concat(finalDiffs.replace) + .concat(finalDiffs.add); } function pushReplace(path, basePath, key, diffs, pathConverter, obj2) { diff --git a/node_modules/just-diff/package.json b/node_modules/just-diff/package.json index bab8a29..035daf0 100644 --- a/node_modules/just-diff/package.json +++ b/node_modules/just-diff/package.json @@ -1,14 +1,16 @@ { "name": "just-diff", - "version": "5.0.1", + "version": "5.1.1", "description": "Return an object representing the diffs between two objects. Supports jsonPatch protocol", "main": "index.js", "module": "index.mjs", "exports": { ".": { "require": "./index.js", + "types": "./index.d.ts", "default": "./index.mjs" - } + }, + "./package.json": "./package.json" }, "types": "index.d.ts", "scripts": { @@ -28,4 +30,4 @@ "bugs": { "url": "https://github.com/angus-c/just/issues" } -} +} \ No newline at end of file diff --git a/node_modules/make-fetch-happen/lib/agent.js b/node_modules/make-fetch-happen/lib/agent.js index cc1d388..dd68492 100644 --- a/node_modules/make-fetch-happen/lib/agent.js +++ b/node_modules/make-fetch-happen/lib/agent.js @@ -2,6 +2,7 @@ const LRU = require('lru-cache') const url = require('url') const isLambda = require('is-lambda') +const dns = require('./dns.js') const AGENT_CACHE = new LRU({ max: 50 }) const HttpAgent = require('agentkeepalive') @@ -77,11 +78,13 @@ function getAgent (uri, opts) { rejectUnauthorized: opts.rejectUnauthorized, timeout: agentTimeout, freeSocketTimeout: 15000, + lookup: dns.getLookup(opts.dns), }) : new HttpAgent({ maxSockets: agentMaxSockets, localAddress: opts.localAddress, timeout: agentTimeout, freeSocketTimeout: 15000, + lookup: dns.getLookup(opts.dns), }) AGENT_CACHE.set(key, agent) return agent @@ -168,9 +171,11 @@ const getPath = u => u.pathname + u.search + u.hash const HttpProxyAgent = require('http-proxy-agent') const HttpsProxyAgent = require('https-proxy-agent') -const SocksProxyAgent = require('socks-proxy-agent') +const { SocksProxyAgent } = require('socks-proxy-agent') module.exports.getProxy = getProxy function getProxy (proxyUrl, opts, isHttps) { + // our current proxy agents do not support an overridden dns lookup method, so will not + // benefit from the dns cache const popts = { host: proxyUrl.hostname, port: proxyUrl.port, @@ -193,11 +198,15 @@ function getProxy (proxyUrl, opts, isHttps) { return new HttpsProxyAgent(popts) } } else if (proxyUrl.protocol.startsWith('socks')) { + // socks-proxy-agent uses hostname not host + popts.hostname = popts.host + delete popts.host return new SocksProxyAgent(popts) } else { throw Object.assign( new Error(`unsupported proxy protocol: '${proxyUrl.protocol}'`), { + code: 'EUNSUPPORTEDPROXY', url: proxyUrl.href, } ) diff --git a/node_modules/make-fetch-happen/lib/cache/entry.js b/node_modules/make-fetch-happen/lib/cache/entry.js index ae2ad8c..dba89d7 100644 --- a/node_modules/make-fetch-happen/lib/cache/entry.js +++ b/node_modules/make-fetch-happen/lib/cache/entry.js @@ -1,21 +1,16 @@ const { Request, Response } = require('minipass-fetch') const Minipass = require('minipass') -const MinipassCollect = require('minipass-collect') const MinipassFlush = require('minipass-flush') -const MinipassPipeline = require('minipass-pipeline') const cacache = require('cacache') const url = require('url') +const CachingMinipassPipeline = require('../pipeline.js') const CachePolicy = require('./policy.js') const cacheKey = require('./key.js') const remote = require('../remote.js') const hasOwnProperty = (obj, prop) => Object.prototype.hasOwnProperty.call(obj, prop) -// maximum amount of data we will buffer into memory -// if we'll exceed this, we switch to streaming -const MAX_MEM_SIZE = 5 * 1024 * 1024 // 5MB - // allow list for request headers that will be written to the cache index // note: we will also store any request headers // that are named in a response's vary header @@ -40,6 +35,7 @@ const KEEP_RESPONSE_HEADERS = [ 'etag', 'expires', 'last-modified', + 'link', 'location', 'pragma', 'vary', @@ -256,13 +252,12 @@ class CacheEntry { } const size = this.response.headers.get('content-length') - const fitsInMemory = !!size && Number(size) < MAX_MEM_SIZE - const shouldBuffer = this.options.memoize !== false && fitsInMemory const cacheOpts = { algorithms: this.options.algorithms, metadata: getMetadata(this.request, this.response, this.options), size, - memoize: fitsInMemory && this.options.memoize, + integrity: this.options.integrity, + integrityEmitter: this.response.body.hasIntegrityEmitter && this.response.body, } let body = null @@ -275,52 +270,32 @@ class CacheEntry { cacheWriteReject = reject }) - body = new MinipassPipeline(new MinipassFlush({ + body = new CachingMinipassPipeline({ events: ['integrity', 'size'] }, new MinipassFlush({ flush () { return cacheWritePromise }, })) + // this is always true since if we aren't reusing the one from the remote fetch, we + // are using the one from cacache + body.hasIntegrityEmitter = true - let abortStream, onResume - if (shouldBuffer) { - // if the result fits in memory, use a collect stream to gather - // the response and write it to cacache while also passing it through - // to the user - onResume = () => { - const collector = new MinipassCollect.PassThrough() - abortStream = collector - collector.on('collect', (data) => { - // TODO if the cache write fails, log a warning but return the response anyway - cacache.put(this.options.cachePath, this.key, data, cacheOpts) - .then(cacheWriteResolve, cacheWriteReject) - }) - body.unshift(collector) - body.unshift(this.response.body) - } - } else { - // if it does not fit in memory, create a tee stream and use - // that to pipe to both the cache and the user simultaneously - onResume = () => { - const tee = new Minipass() - const cacheStream = cacache.put.stream(this.options.cachePath, this.key, cacheOpts) - abortStream = cacheStream - tee.pipe(cacheStream) - // TODO if the cache write fails, log a warning but return the response anyway - cacheStream.promise().then(cacheWriteResolve, cacheWriteReject) - body.unshift(tee) - body.unshift(this.response.body) - } + const onResume = () => { + const tee = new Minipass() + const cacheStream = cacache.put.stream(this.options.cachePath, this.key, cacheOpts) + // re-emit the integrity and size events on our new response body so they can be reused + cacheStream.on('integrity', i => body.emit('integrity', i)) + cacheStream.on('size', s => body.emit('size', s)) + // stick a flag on here so downstream users will know if they can expect integrity events + tee.pipe(cacheStream) + // TODO if the cache write fails, log a warning but return the response anyway + // eslint-disable-next-line promise/catch-or-return + cacheStream.promise().then(cacheWriteResolve, cacheWriteReject) + body.unshift(tee) + body.unshift(this.response.body) } body.once('resume', onResume) body.once('end', () => body.removeListener('resume', onResume)) - this.response.body.on('error', (err) => { - // the abortStream will either be a MinipassCollect if we buffer - // or a cacache write stream, either way be sure to listen for - // errors from the actual response and avoid writing data that we - // know to be invalid to the cache - abortStream.destroy(err) - }) } else { await cacache.index.insert(this.options.cachePath, this.key, null, cacheOpts) } @@ -331,7 +306,7 @@ class CacheEntry { // the header anyway this.response.headers.set('x-local-cache', encodeURIComponent(this.options.cachePath)) this.response.headers.set('x-local-cache-key', encodeURIComponent(this.key)) - this.response.headers.set('x-local-cache-mode', shouldBuffer ? 'buffer' : 'stream') + this.response.headers.set('x-local-cache-mode', 'stream') this.response.headers.set('x-local-cache-status', status) this.response.headers.set('x-local-cache-time', new Date().toISOString()) const newResponse = new Response(body, { @@ -346,9 +321,6 @@ class CacheEntry { // use the cached data to create a response and return it async respond (method, options, status) { let response - const size = Number(this.response.headers.get('content-length')) - const fitsInMemory = !!size && size < MAX_MEM_SIZE - const shouldBuffer = this.options.memoize !== false && fitsInMemory if (method === 'HEAD' || [301, 308].includes(this.response.status)) { // if the request is a HEAD, or the response is a redirect, // then the metadata in the entry already includes everything @@ -358,66 +330,44 @@ class CacheEntry { // we're responding with a full cached response, so create a body // that reads from cacache and attach it to a new Response const body = new Minipass() - const removeOnResume = () => body.removeListener('resume', onResume) - let onResume - if (shouldBuffer) { - onResume = async () => { - removeOnResume() - try { - const content = await cacache.get.byDigest( + const headers = { ...this.policy.responseHeaders() } + const onResume = () => { + const cacheStream = cacache.get.stream.byDigest( + this.options.cachePath, this.entry.integrity, { memoize: this.options.memoize } + ) + cacheStream.on('error', async (err) => { + cacheStream.pause() + if (err.code === 'EINTEGRITY') { + await cacache.rm.content( this.options.cachePath, this.entry.integrity, { memoize: this.options.memoize } ) - body.end(content) - } catch (err) { - if (err.code === 'EINTEGRITY') { - await cacache.rm.content( - this.options.cachePath, this.entry.integrity, { memoize: this.options.memoize } - ) - } - if (err.code === 'ENOENT' || err.code === 'EINTEGRITY') { - await CacheEntry.invalidate(this.request, this.options) - } - body.emit('error', err) } - } - } else { - onResume = () => { - const cacheStream = cacache.get.stream.byDigest( - this.options.cachePath, this.entry.integrity, { memoize: this.options.memoize } - ) - cacheStream.on('error', async (err) => { - cacheStream.pause() - if (err.code === 'EINTEGRITY') { - await cacache.rm.content( - this.options.cachePath, this.entry.integrity, { memoize: this.options.memoize } - ) - } - if (err.code === 'ENOENT' || err.code === 'EINTEGRITY') { - await CacheEntry.invalidate(this.request, this.options) - } - body.emit('error', err) - cacheStream.resume() - }) - cacheStream.pipe(body) - } + if (err.code === 'ENOENT' || err.code === 'EINTEGRITY') { + await CacheEntry.invalidate(this.request, this.options) + } + body.emit('error', err) + cacheStream.resume() + }) + // emit the integrity and size events based on our metadata so we're consistent + body.emit('integrity', this.entry.integrity) + body.emit('size', Number(headers['content-length'])) + cacheStream.pipe(body) } body.once('resume', onResume) - body.once('end', removeOnResume) + body.once('end', () => body.removeListener('resume', onResume)) response = new Response(body, { url: this.entry.metadata.url, counter: options.counter, status: 200, - headers: { - ...this.policy.responseHeaders(), - }, + headers, }) } response.headers.set('x-local-cache', encodeURIComponent(this.options.cachePath)) response.headers.set('x-local-cache-hash', encodeURIComponent(this.entry.integrity)) response.headers.set('x-local-cache-key', encodeURIComponent(this.key)) - response.headers.set('x-local-cache-mode', shouldBuffer ? 'buffer' : 'stream') + response.headers.set('x-local-cache-mode', 'stream') response.headers.set('x-local-cache-status', status) response.headers.set('x-local-cache-time', new Date(this.entry.metadata.time).toUTCString()) return response diff --git a/node_modules/make-fetch-happen/lib/cache/index.js b/node_modules/make-fetch-happen/lib/cache/index.js index 17a6425..0de49d2 100644 --- a/node_modules/make-fetch-happen/lib/cache/index.js +++ b/node_modules/make-fetch-happen/lib/cache/index.js @@ -14,8 +14,8 @@ const cacheFetch = async (request, options) => { // otherwise, we make a request, store it and return it const response = await remote(request, options) - const entry = new CacheEntry({ request, response, options }) - return entry.store('miss') + const newEntry = new CacheEntry({ request, response, options }) + return newEntry.store('miss') } // we have a cached response that satisfies this request, however if the cache diff --git a/node_modules/make-fetch-happen/lib/dns.js b/node_modules/make-fetch-happen/lib/dns.js new file mode 100644 index 0000000..13102b5 --- /dev/null +++ b/node_modules/make-fetch-happen/lib/dns.js @@ -0,0 +1,49 @@ +const LRUCache = require('lru-cache') +const dns = require('dns') + +const defaultOptions = exports.defaultOptions = { + family: undefined, + hints: dns.ADDRCONFIG, + all: false, + verbatim: undefined, +} + +const lookupCache = exports.lookupCache = new LRUCache({ max: 50 }) + +// this is a factory so that each request can have its own opts (i.e. ttl) +// while still sharing the cache across all requests +exports.getLookup = (dnsOptions) => { + return (hostname, options, callback) => { + if (typeof options === 'function') { + callback = options + options = null + } else if (typeof options === 'number') { + options = { family: options } + } + + options = { ...defaultOptions, ...options } + + const key = JSON.stringify({ + hostname, + family: options.family, + hints: options.hints, + all: options.all, + verbatim: options.verbatim, + }) + + if (lookupCache.has(key)) { + const [address, family] = lookupCache.get(key) + process.nextTick(callback, null, address, family) + return + } + + dnsOptions.lookup(hostname, options, (err, address, family) => { + if (err) { + return callback(err) + } + + lookupCache.set(key, [address, family], { ttl: dnsOptions.ttl }) + return callback(null, address, family) + }) + } +} diff --git a/node_modules/make-fetch-happen/lib/index.js b/node_modules/make-fetch-happen/lib/index.js index 6028bc0..2f12e8e 100644 --- a/node_modules/make-fetch-happen/lib/index.js +++ b/node_modules/make-fetch-happen/lib/index.js @@ -10,7 +10,7 @@ const makeFetchHappen = (url, opts) => { return fetch(request, options) } -makeFetchHappen.defaults = (defaultUrl, defaultOptions = {}) => { +makeFetchHappen.defaults = (defaultUrl, defaultOptions = {}, wrappedFetch = makeFetchHappen) => { if (typeof defaultUrl === 'object') { defaultOptions = defaultUrl defaultUrl = null @@ -26,10 +26,11 @@ makeFetchHappen.defaults = (defaultUrl, defaultOptions = {}) => { ...options.headers, }, } - return makeFetchHappen(finalUrl, finalOptions) + return wrappedFetch(finalUrl, finalOptions) } - defaultedFetch.defaults = makeFetchHappen.defaults + defaultedFetch.defaults = (defaultUrl1, defaultOptions1 = {}) => + makeFetchHappen.defaults(defaultUrl1, defaultOptions1, defaultedFetch) return defaultedFetch } diff --git a/node_modules/make-fetch-happen/lib/options.js b/node_modules/make-fetch-happen/lib/options.js index a0c8664..daa9ecd 100644 --- a/node_modules/make-fetch-happen/lib/options.js +++ b/node_modules/make-fetch-happen/lib/options.js @@ -1,3 +1,5 @@ +const dns = require('dns') + const conditionalHeaders = [ 'if-modified-since', 'if-none-match', @@ -26,6 +28,8 @@ const configureOptions = (opts) => { options.retry = { retries: 0, ...options.retry } } + options.dns = { ttl: 5 * 60 * 1000, lookup: dns.lookup, ...options.dns } + options.cache = options.cache || 'default' if (options.cache === 'default') { const hasConditionalHeader = Object.keys(options.headers || {}).some((name) => { diff --git a/node_modules/make-fetch-happen/lib/pipeline.js b/node_modules/make-fetch-happen/lib/pipeline.js new file mode 100644 index 0000000..b1d221b --- /dev/null +++ b/node_modules/make-fetch-happen/lib/pipeline.js @@ -0,0 +1,41 @@ +'use strict' + +const MinipassPipeline = require('minipass-pipeline') + +class CachingMinipassPipeline extends MinipassPipeline { + #events = [] + #data = new Map() + + constructor (opts, ...streams) { + // CRITICAL: do NOT pass the streams to the call to super(), this will start + // the flow of data and potentially cause the events we need to catch to emit + // before we've finished our own setup. instead we call super() with no args, + // finish our setup, and then push the streams into ourselves to start the + // data flow + super() + this.#events = opts.events + + /* istanbul ignore next - coverage disabled because this is pointless to test here */ + if (streams.length) { + this.push(...streams) + } + } + + on (event, handler) { + if (this.#events.includes(event) && this.#data.has(event)) { + return handler(...this.#data.get(event)) + } + + return super.on(event, handler) + } + + emit (event, ...data) { + if (this.#events.includes(event)) { + this.#data.set(event, data) + } + + return super.emit(event, ...data) + } +} + +module.exports = CachingMinipassPipeline diff --git a/node_modules/make-fetch-happen/lib/remote.js b/node_modules/make-fetch-happen/lib/remote.js index a8b8d2a..068c73a 100644 --- a/node_modules/make-fetch-happen/lib/remote.js +++ b/node_modules/make-fetch-happen/lib/remote.js @@ -1,9 +1,9 @@ const Minipass = require('minipass') -const MinipassPipeline = require('minipass-pipeline') const fetch = require('minipass-fetch') const promiseRetry = require('promise-retry') const ssri = require('ssri') +const CachingMinipassPipeline = require('./pipeline.js') const getAgent = require('./agent.js') const pkg = require('../package.json') @@ -52,8 +52,21 @@ const remoteFetch = (request, options) => { if (_opts.integrity && res.status === 200) { // we got a 200 response and the user has specified an expected // integrity value, so wrap the response in an ssri stream to verify it - const integrityStream = ssri.integrityStream({ integrity: _opts.integrity }) - res = new fetch.Response(new MinipassPipeline(res.body, integrityStream), res) + const integrityStream = ssri.integrityStream({ + algorithms: _opts.algorithms, + integrity: _opts.integrity, + size: _opts.size, + }) + const pipeline = new CachingMinipassPipeline({ + events: ['integrity', 'size'], + }, res.body, integrityStream) + // we also propagate the integrity and size events out to the pipeline so we can use + // this new response body as an integrityEmitter for cacache + integrityStream.on('integrity', i => pipeline.emit('integrity', i)) + integrityStream.on('size', s => pipeline.emit('size', s)) + res = new fetch.Response(pipeline, res) + // set an explicit flag so we know if our response body will emit integrity and size + res.body.hasIntegrityEmitter = true } res.headers.set('x-fetch-attempts', attemptNum) diff --git a/node_modules/make-fetch-happen/node_modules/lru-cache/LICENSE b/node_modules/make-fetch-happen/node_modules/lru-cache/LICENSE deleted file mode 100644 index 9b58a3e..0000000 --- a/node_modules/make-fetch-happen/node_modules/lru-cache/LICENSE +++ /dev/null @@ -1,15 +0,0 @@ -The ISC License - -Copyright (c) 2010-2022 Isaac Z. Schlueter and Contributors - -Permission to use, copy, modify, and/or distribute this software for any -purpose with or without fee is hereby granted, provided that the above -copyright notice and this permission notice appear in all copies. - -THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR -IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/node_modules/make-fetch-happen/node_modules/lru-cache/index.js b/node_modules/make-fetch-happen/node_modules/lru-cache/index.js deleted file mode 100644 index ede2f30..0000000 --- a/node_modules/make-fetch-happen/node_modules/lru-cache/index.js +++ /dev/null @@ -1,581 +0,0 @@ -const perf = typeof performance === 'object' && performance && - typeof performance.now === 'function' ? performance : Date - -const warned = new Set() -const deprecatedOption = (opt, msg) => { - const code = `LRU_CACHE_OPTION_${opt}` - if (shouldWarn(code)) { - warn(code, `The ${opt} option is deprecated. ${msg}`, LRUCache) - } -} -const deprecatedMethod = (method, msg) => { - const code = `LRU_CACHE_METHOD_${method}` - if (shouldWarn(code)) { - const { prototype } = LRUCache - const { get } = Object.getOwnPropertyDescriptor(prototype, method) - warn(code, `The ${method} method is deprecated. ${msg}`, get) - } -} -const deprecatedProperty = (field, msg) => { - const code = `LRU_CACHE_PROPERTY_${field}` - if (shouldWarn(code)) { - const { prototype } = LRUCache - const { get } = Object.getOwnPropertyDescriptor(prototype, field) - warn(code, `The ${field} property is deprecated. ${msg}`, get) - } -} -const shouldWarn = (code) => !(process.noDeprecation || warned.has(code)) -const warn = (code, msg, fn) => { - warned.add(code) - process.emitWarning(msg, 'DeprecationWarning', code, fn) -} - -const isPosInt = n => n && n === Math.floor(n) && n > 0 && isFinite(n) - -/* istanbul ignore next - This is a little bit ridiculous, tbh. - * The maximum array length is 2^32-1 or thereabouts on most JS impls. - * And well before that point, you're caching the entire world, I mean, - * that's ~32GB of just integers for the next/prev links, plus whatever - * else to hold that many keys and values. Just filling the memory with - * zeroes at init time is brutal when you get that big. - * But why not be complete? - * Maybe in the future, these limits will have expanded. */ -const getUintArray = max => !isPosInt(max) ? null -: max <= Math.pow(2, 8) ? Uint8Array -: max <= Math.pow(2, 16) ? Uint16Array -: max <= Math.pow(2, 32) ? Uint32Array -: max <= Number.MAX_SAFE_INTEGER ? ZeroArray -: null - -class ZeroArray extends Array { - constructor (size) { - super(size) - this.fill(0) - } -} - -class Stack { - constructor (max) { - const UintArray = getUintArray(max) - this.heap = new UintArray(max) - this.length = 0 - } - push (n) { - this.heap[this.length++] = n - } - pop () { - return this.heap[--this.length] - } -} - -class LRUCache { - constructor (options = {}) { - const { - max, - ttl, - ttlResolution = 1, - ttlAutopurge, - updateAgeOnGet, - allowStale, - dispose, - disposeAfter, - noDisposeOnSet, - maxSize, - sizeCalculation, - } = options - - // deprecated options, don't trigger a warning for getting them if - // the thing being passed in is another LRUCache we're copying. - const { - length, - maxAge, - stale, - } = options instanceof LRUCache ? {} : options - - if (!isPosInt(max)) { - throw new TypeError('max option must be an integer') - } - - const UintArray = getUintArray(max) - if (!UintArray) { - throw new Error('invalid max value: ' + max) - } - - this.max = max - this.maxSize = maxSize || 0 - this.sizeCalculation = sizeCalculation || length - if (this.sizeCalculation) { - if (!this.maxSize) { - throw new TypeError('cannot set sizeCalculation without setting maxSize') - } - if (typeof this.sizeCalculation !== 'function') { - throw new TypeError('sizeCalculating set to non-function') - } - } - this.keyMap = new Map() - this.keyList = new Array(max).fill(null) - this.valList = new Array(max).fill(null) - this.next = new UintArray(max) - this.prev = new UintArray(max) - this.head = 0 - this.tail = 0 - this.free = new Stack(max) - this.initialFill = 1 - this.size = 0 - - if (typeof dispose === 'function') { - this.dispose = dispose - } - if (typeof disposeAfter === 'function') { - this.disposeAfter = disposeAfter - this.disposed = [] - } else { - this.disposeAfter = null - this.disposed = null - } - this.noDisposeOnSet = !!noDisposeOnSet - - if (this.maxSize) { - if (!isPosInt(this.maxSize)) { - throw new TypeError('maxSize must be a positive integer if specified') - } - this.initializeSizeTracking() - } - - this.allowStale = !!allowStale || !!stale - this.updateAgeOnGet = !!updateAgeOnGet - this.ttlResolution = isPosInt(ttlResolution) || ttlResolution === 0 - ? ttlResolution : 1 - this.ttlAutopurge = !!ttlAutopurge - this.ttl = ttl || maxAge || 0 - if (this.ttl) { - if (!isPosInt(this.ttl)) { - throw new TypeError('ttl must be a positive integer if specified') - } - this.initializeTTLTracking() - } - - if (stale) { - deprecatedOption('stale', 'please use options.allowStale instead') - } - if (maxAge) { - deprecatedOption('maxAge', 'please use options.ttl instead') - } - if (length) { - deprecatedOption('length', 'please use options.sizeCalculation instead') - } - } - - initializeTTLTracking () { - this.ttls = new ZeroArray(this.max) - this.starts = new ZeroArray(this.max) - this.setItemTTL = (index, ttl) => { - this.starts[index] = ttl !== 0 ? perf.now() : 0 - this.ttls[index] = ttl - if (ttl !== 0 && this.ttlAutopurge) { - const t = setTimeout(() => { - if (this.isStale(index)) { - this.delete(this.keyList[index]) - } - }, ttl + 1) - /* istanbul ignore else - unref() not supported on all platforms */ - if (t.unref) { - t.unref() - } - } - } - this.updateItemAge = (index) => { - this.starts[index] = this.ttls[index] !== 0 ? perf.now() : 0 - } - // debounce calls to perf.now() to 1s so we're not hitting - // that costly call repeatedly. - let cachedNow = 0 - const getNow = () => { - const n = perf.now() - if (this.ttlResolution > 0) { - cachedNow = n - const t = setTimeout(() => cachedNow = 0, this.ttlResolution) - /* istanbul ignore else - not available on all platforms */ - if (t.unref) { - t.unref() - } - } - return n - } - this.isStale = (index) => { - return this.ttls[index] !== 0 && this.starts[index] !== 0 && - ((cachedNow || getNow()) - this.starts[index] > this.ttls[index]) - } - } - updateItemAge (index) {} - setItemTTL (index, ttl) {} - isStale (index) { return false } - - initializeSizeTracking () { - this.calculatedSize = 0 - this.sizes = new ZeroArray(this.max) - this.removeItemSize = index => this.calculatedSize -= this.sizes[index] - this.addItemSize = (index, v, k, size, sizeCalculation) => { - const s = size || (sizeCalculation ? sizeCalculation(v, k) : 0) - this.sizes[index] = isPosInt(s) ? s : 0 - const maxSize = this.maxSize - this.sizes[index] - while (this.calculatedSize > maxSize) { - this.evict() - } - this.calculatedSize += this.sizes[index] - } - this.delete = k => { - if (this.size !== 0) { - const index = this.keyMap.get(k) - if (index !== undefined) { - this.calculatedSize -= this.sizes[index] - } - } - return LRUCache.prototype.delete.call(this, k) - } - } - removeItemSize (index) {} - addItemSize (index, v, k, size, sizeCalculation) {} - - *indexes () { - if (this.size) { - for (let i = this.tail; true; i = this.prev[i]) { - if (!this.isStale(i)) { - yield i - } - if (i === this.head) { - break - } - } - } - } - *rindexes () { - if (this.size) { - for (let i = this.head; true; i = this.next[i]) { - if (!this.isStale(i)) { - yield i - } - if (i === this.tail) { - break - } - } - } - } - - *entries () { - for (const i of this.indexes()) { - yield [this.keyList[i], this.valList[i]] - } - } - - *keys () { - for (const i of this.indexes()) { - yield this.keyList[i] - } - } - - *values () { - for (const i of this.indexes()) { - yield this.valList[i] - } - } - - [Symbol.iterator] () { - return this.entries() - } - - find (fn, getOptions = {}) { - for (const i of this.indexes()) { - if (fn(this.valList[i], this.keyList[i], this)) { - return this.get(this.keyList[i], getOptions) - } - } - } - - forEach (fn, thisp = this) { - for (const i of this.indexes()) { - fn.call(thisp, this.valList[i], this.keyList[i], this) - } - } - - rforEach (fn, thisp = this) { - for (const i of this.rindexes()) { - fn.call(thisp, this.valList[i], this.keyList[i], this) - } - } - - get prune () { - deprecatedMethod('prune', 'Please use cache.purgeStale() instead.') - return this.purgeStale - } - - purgeStale () { - let deleted = false - if (this.size) { - for (let i = this.head; true; i = this.next[i]) { - const b = i === this.tail - if (this.isStale(i)) { - this.delete(this.keyList[i]) - deleted = true - } - if (b) { - break - } - } - } - return deleted - } - - dump () { - const arr = [] - for (const i of this.indexes()) { - const key = this.keyList[i] - const value = this.valList[i] - const entry = { value } - if (this.ttls) { - entry.ttl = this.ttls[i] - } - if (this.sizes) { - entry.size = this.sizes[i] - } - arr.unshift([key, entry]) - } - return arr - } - - load (arr) { - this.clear() - for (const [key, entry] of arr) { - this.set(key, entry.value, entry) - } - } - - dispose (v, k, reason) {} - - set (k, v, { - ttl = this.ttl, - noDisposeOnSet = this.noDisposeOnSet, - size = 0, - sizeCalculation = this.sizeCalculation, - } = {}) { - let index = this.size === 0 ? undefined : this.keyMap.get(k) - if (index === undefined) { - // addition - index = this.newIndex() - this.keyList[index] = k - this.valList[index] = v - this.keyMap.set(k, index) - this.next[this.tail] = index - this.prev[index] = this.tail - this.tail = index - this.size ++ - this.addItemSize(index, v, k, size, sizeCalculation) - } else { - // update - const oldVal = this.valList[index] - if (v !== oldVal) { - if (!noDisposeOnSet) { - this.dispose(oldVal, k, 'set') - if (this.disposeAfter) { - this.disposed.push([oldVal, k, 'set']) - } - } - this.removeItemSize(index) - this.valList[index] = v - this.addItemSize(index, v, k, size, sizeCalculation) - } - this.moveToTail(index) - } - if (ttl !== 0 && this.ttl === 0 && !this.ttls) { - this.initializeTTLTracking() - } - this.setItemTTL(index, ttl) - if (this.disposeAfter) { - while (this.disposed.length) { - this.disposeAfter(...this.disposed.shift()) - } - } - return this - } - - newIndex () { - if (this.size === 0) { - return this.tail - } - if (this.size === this.max) { - return this.evict() - } - if (this.free.length !== 0) { - return this.free.pop() - } - // initial fill, just keep writing down the list - return this.initialFill++ - } - - pop () { - if (this.size) { - const val = this.valList[this.head] - this.evict() - return val - } - } - - evict () { - const head = this.head - const k = this.keyList[head] - const v = this.valList[head] - this.dispose(v, k, 'evict') - if (this.disposeAfter) { - this.disposed.push([v, k, 'evict']) - } - this.removeItemSize(head) - this.head = this.next[head] - this.keyMap.delete(k) - this.size -- - return head - } - - has (k) { - return this.keyMap.has(k) && !this.isStale(this.keyMap.get(k)) - } - - // like get(), but without any LRU updating or TTL expiration - peek (k, { allowStale = this.allowStale } = {}) { - const index = this.keyMap.get(k) - if (index !== undefined && (allowStale || !this.isStale(index))) { - return this.valList[index] - } - } - - get (k, { - allowStale = this.allowStale, - updateAgeOnGet = this.updateAgeOnGet, - } = {}) { - const index = this.keyMap.get(k) - if (index !== undefined) { - if (this.isStale(index)) { - const value = allowStale ? this.valList[index] : undefined - this.delete(k) - return value - } else { - this.moveToTail(index) - if (updateAgeOnGet) { - this.updateItemAge(index) - } - return this.valList[index] - } - } - } - - connect (p, n) { - this.prev[n] = p - this.next[p] = n - } - - moveToTail (index) { - // if tail already, nothing to do - // if head, move head to next[index] - // else - // move next[prev[index]] to next[index] (head has no prev) - // move prev[next[index]] to prev[index] - // prev[index] = tail - // next[tail] = index - // tail = index - if (index !== this.tail) { - if (index === this.head) { - this.head = this.next[index] - } else { - this.connect(this.prev[index], this.next[index]) - } - this.connect(this.tail, index) - this.tail = index - } - } - - get del () { - deprecatedMethod('del', 'Please use cache.delete() instead.') - return this.delete - } - delete (k) { - let deleted = false - if (this.size !== 0) { - const index = this.keyMap.get(k) - if (index !== undefined) { - deleted = true - if (this.size === 1) { - this.clear() - } else { - this.removeItemSize(index) - this.dispose(this.valList[index], k, 'delete') - if (this.disposeAfter) { - this.disposed.push([this.valList[index], k, 'delete']) - } - this.keyMap.delete(k) - this.keyList[index] = null - this.valList[index] = null - if (index === this.tail) { - this.tail = this.prev[index] - } else if (index === this.head) { - this.head = this.next[index] - } else { - this.next[this.prev[index]] = this.next[index] - this.prev[this.next[index]] = this.prev[index] - } - this.size -- - this.free.push(index) - } - } - } - if (this.disposed) { - while (this.disposed.length) { - this.disposeAfter(...this.disposed.shift()) - } - } - return deleted - } - - clear () { - if (this.dispose !== LRUCache.prototype.dispose) { - for (const index of this.rindexes()) { - this.dispose(this.valList[index], this.keyList[index], 'delete') - } - } - if (this.disposeAfter) { - for (const index of this.rindexes()) { - this.disposed.push([this.valList[index], this.keyList[index], 'delete']) - } - } - this.keyMap.clear() - this.valList.fill(null) - this.keyList.fill(null) - if (this.ttls) { - this.ttls.fill(0) - this.starts.fill(0) - } - if (this.sizes) { - this.sizes.fill(0) - } - this.head = 0 - this.tail = 0 - this.initialFill = 1 - this.free.length = 0 - this.calculatedSize = 0 - this.size = 0 - if (this.disposed) { - while (this.disposed.length) { - this.disposeAfter(...this.disposed.shift()) - } - } - } - get reset () { - deprecatedMethod('reset', 'Please use cache.clear() instead.') - return this.clear - } - - get length () { - deprecatedProperty('length', 'Please use cache.size instead.') - return this.size - } -} - -module.exports = LRUCache diff --git a/node_modules/make-fetch-happen/node_modules/lru-cache/package.json b/node_modules/make-fetch-happen/node_modules/lru-cache/package.json deleted file mode 100644 index 66dbbd9..0000000 --- a/node_modules/make-fetch-happen/node_modules/lru-cache/package.json +++ /dev/null @@ -1,34 +0,0 @@ -{ - "name": "lru-cache", - "description": "A cache object that deletes the least-recently-used items.", - "version": "7.3.1", - "author": "Isaac Z. Schlueter <i@izs.me>", - "keywords": [ - "mru", - "lru", - "cache" - ], - "scripts": { - "test": "tap", - "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags" - }, - "main": "index.js", - "repository": "git://github.com/isaacs/node-lru-cache.git", - "devDependencies": { - "benchmark": "^2.1.4", - "tap": "^15.1.6" - }, - "license": "ISC", - "files": [ - "index.js" - ], - "engines": { - "node": ">=12" - }, - "tap": { - "coverage-map": "map.js" - } -} diff --git a/node_modules/make-fetch-happen/package.json b/node_modules/make-fetch-happen/package.json index c01a09a..1690c93 100644 --- a/node_modules/make-fetch-happen/package.json +++ b/node_modules/make-fetch-happen/package.json @@ -1,26 +1,26 @@ { "name": "make-fetch-happen", - "version": "10.0.3", + "version": "11.0.2", "description": "Opinionated, caching, retrying fetch client", "main": "lib/index.js", "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "scripts": { - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", "test": "tap", "posttest": "npm run lint", "eslint": "eslint", - "lint": "eslint '**/*.js'", + "lint": "eslint \"**/*.js\"", "lintfix": "npm run lint -- --fix", - "postlint": "npm-template-check", + "postlint": "template-oss-check", "snap": "tap", - "template-copy": "npm-template-copy --force" + "template-oss-apply": "template-oss-apply --force" + }, + "repository": { + "type": "git", + "url": "https://github.com/npm/make-fetch-happen.git" }, - "repository": "https://github.com/npm/make-fetch-happen", "keywords": [ "http", "request", @@ -33,42 +33,48 @@ "author": "GitHub Inc.", "license": "ISC", "dependencies": { - "agentkeepalive": "^4.2.0", - "cacache": "^15.3.0", + "agentkeepalive": "^4.2.1", + "cacache": "^17.0.0", "http-cache-semantics": "^4.1.0", "http-proxy-agent": "^5.0.0", "https-proxy-agent": "^5.0.0", "is-lambda": "^1.0.1", - "lru-cache": "^7.3.1", - "minipass": "^3.1.6", + "lru-cache": "^7.7.1", + "minipass": "^4.0.0", "minipass-collect": "^1.0.2", - "minipass-fetch": "^1.4.1", + "minipass-fetch": "^3.0.0", "minipass-flush": "^1.0.5", "minipass-pipeline": "^1.2.4", "negotiator": "^0.6.3", "promise-retry": "^2.0.1", - "socks-proxy-agent": "^6.1.1", - "ssri": "^8.0.1" + "socks-proxy-agent": "^7.0.0", + "ssri": "^10.0.0" }, "devDependencies": { - "@npmcli/template-oss": "^2.7.1", - "eslint": "^8.9.0", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.10.0", "mkdirp": "^1.0.4", "nock": "^13.2.4", "rimraf": "^3.0.2", "safe-buffer": "^5.2.1", "standard-version": "^9.3.2", - "tap": "^15.1.6" + "tap": "^16.0.0" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "tap": { "color": 1, "files": "test/*.js", - "check-coverage": true + "check-coverage": true, + "timeout": 60, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "templateOSS": { - "version": "2.7.1" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.10.0" } } diff --git a/node_modules/mkdirp-infer-owner/LICENSE b/node_modules/mkdirp-infer-owner/LICENSE deleted file mode 100644 index 05eeeb8..0000000 --- a/node_modules/mkdirp-infer-owner/LICENSE +++ /dev/null @@ -1,15 +0,0 @@ -The ISC License - -Copyright (c) Isaac Z. Schlueter - -Permission to use, copy, modify, and/or distribute this software for any -purpose with or without fee is hereby granted, provided that the above -copyright notice and this permission notice appear in all copies. - -THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR -IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/node_modules/mkdirp-infer-owner/index.js b/node_modules/mkdirp-infer-owner/index.js deleted file mode 100644 index 750743f..0000000 --- a/node_modules/mkdirp-infer-owner/index.js +++ /dev/null @@ -1,26 +0,0 @@ -const inferOwner = require('infer-owner') -const mkdirp = require('mkdirp') -const {promisify} = require('util') -const chownr = promisify(require('chownr')) - -const platform = process.env.__TESTING_MKDIRP_INFER_OWNER_PLATFORM__ - || process.platform -const isWindows = platform === 'win32' -const isRoot = process.getuid && process.getuid() === 0 -const doChown = !isWindows && isRoot - -module.exports = !doChown ? (path, opts) => mkdirp(path, opts) - : (path, opts) => inferOwner(path).then(({uid, gid}) => - mkdirp(path, opts).then(made => - uid !== 0 || gid !== process.getgid() - ? chownr(made || path, uid, gid).then(() => made) - : made)) - -module.exports.sync = !doChown ? (path, opts) => mkdirp.sync(path, opts) - : (path, opts) => { - const {uid, gid} = inferOwner.sync(path) - const made = mkdirp.sync(path) - if (uid !== 0 || gid !== process.getgid()) - chownr.sync(made || path, uid, gid) - return made - } diff --git a/node_modules/mkdirp-infer-owner/package.json b/node_modules/mkdirp-infer-owner/package.json deleted file mode 100644 index 1f67ad0..0000000 --- a/node_modules/mkdirp-infer-owner/package.json +++ /dev/null @@ -1,36 +0,0 @@ -{ - "name": "mkdirp-infer-owner", - "version": "2.0.0", - "files": [ - "index.js" - ], - "description": "mkdirp, but chown to the owner of the containing folder if possible and necessary", - "author": "Isaac Z. Schlueter <i@izs.me> (https://izs.me)", - "license": "ISC", - "scripts": { - "test": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "snap": "tap" - }, - "tap": { - "check-coverage": true - }, - "devDependencies": { - "require-inject": "^1.4.4", - "tap": "^14.10.6" - }, - "dependencies": { - "chownr": "^2.0.0", - "infer-owner": "^1.0.4", - "mkdirp": "^1.0.3" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/isaacs/mkdirp-infer-owner" - }, - "engines": { - "node": ">=10" - } -} diff --git a/node_modules/npm-audit-report/lib/colors.js b/node_modules/npm-audit-report/lib/colors.js index ad76870..2fbf5c3 100644 --- a/node_modules/npm-audit-report/lib/colors.js +++ b/node_modules/npm-audit-report/lib/colors.js @@ -19,6 +19,6 @@ module.exports = color => { magenta, yellow, white, - severity + severity, } } diff --git a/node_modules/npm-audit-report/lib/exit-code.js b/node_modules/npm-audit-report/lib/exit-code.js index 7a32ac6..fcb580b 100644 --- a/node_modules/npm-audit-report/lib/exit-code.js +++ b/node_modules/npm-audit-report/lib/exit-code.js @@ -5,7 +5,7 @@ const severities = new Map(Object.entries([ 'moderate', 'high', 'critical', - 'none' + 'none', ]).map(s => s.reverse())) module.exports = (data, level) => diff --git a/node_modules/npm-audit-report/lib/index.js b/node_modules/npm-audit-report/lib/index.js index 9ee86be..63063f9 100644 --- a/node_modules/npm-audit-report/lib/index.js +++ b/node_modules/npm-audit-report/lib/index.js @@ -4,7 +4,7 @@ const reporters = { install: require('./reporters/install'), detail: require('./reporters/detail'), json: require('./reporters/json'), - quiet: require('./reporters/quiet') + quiet: require('./reporters/quiet'), } const exitCode = require('./exit-code.js') @@ -20,20 +20,22 @@ module.exports = Object.assign((data, options = {}) => { // CLI defaults this to `null` so the defaulting method above doesn't work const auditLevel = options.auditLevel || 'low' - if (!data) + if (!data) { throw Object.assign( new TypeError('ENOAUDITDATA'), { code: 'ENOAUDITDATA', - message: 'missing audit data' + message: 'missing audit data', } ) + } - if (typeof data.toJSON === 'function') + if (typeof data.toJSON === 'function') { data = data.toJSON() + } return { report: reporters[reporter](data, { color, unicode, indent }), - exitCode: exitCode(data, auditLevel) + exitCode: exitCode(data, auditLevel), } }, { reporters }) diff --git a/node_modules/npm-audit-report/lib/reporters/detail.js b/node_modules/npm-audit-report/lib/reporters/detail.js index 50451f0..ba2f013 100644 --- a/node_modules/npm-audit-report/lib/reporters/detail.js +++ b/node_modules/npm-audit-report/lib/reporters/detail.js @@ -6,7 +6,7 @@ const install = require('./install.js') module.exports = (data, { color }) => { const summary = install.summary(data, { color }) const none = data.metadata.vulnerabilities.total === 0 - return none ? summary : fullReport(data, {color, summary}) + return none ? summary : fullReport(data, { color, summary }) } const fullReport = (data, { color, summary }) => { @@ -14,10 +14,11 @@ const fullReport = (data, { color, summary }) => { const output = [c.white('# npm audit report'), ''] const printed = new Set() - for (const [name, vuln] of Object.entries(data.vulnerabilities)) { + for (const [, vuln] of Object.entries(data.vulnerabilities)) { // only print starting from the top-level advisories - if (vuln.via.filter(v => typeof v !== 'string').length !== 0) - output.push(printVuln(vuln, c, data.vulnerabilities)) + if (vuln.via.filter(v => typeof v !== 'string').length !== 0) { + output.push(printVuln(vuln, c, data.vulnerabilities, printed)) + } } output.push(summary) @@ -25,9 +26,10 @@ const fullReport = (data, { color, summary }) => { return output.join('\n') } -const printVuln = (vuln, c, vulnerabilities, printed = new Set(), indent = '') => { - if (printed.has(vuln)) +const printVuln = (vuln, c, vulnerabilities, printed, indent = '') => { + if (printed.has(vuln)) { return null + } printed.add(vuln) const output = [] @@ -59,7 +61,7 @@ const printVuln = (vuln, c, vulnerabilities, printed = new Set(), indent = '') = `${c.yellow('fix available')} via \`npm audit fix --force\``, `Will install ${fa.name}@${fa.version}` + `, which is ${fa.isSemVerMajor ? 'a breaking change' : - 'outside the stated dependency range' }` + 'outside the stated dependency range'}` ) } } @@ -70,10 +72,10 @@ const printVuln = (vuln, c, vulnerabilities, printed = new Set(), indent = '') = } for (const effect of vuln.effects) { - const vuln = vulnerabilities[effect] - const e = printVuln(vuln, c, vulnerabilities, printed, ' ') - if (e) + const e = printVuln(vulnerabilities[effect], c, vulnerabilities, printed, ' ') + if (e) { output.push(...e.split('\n')) + } } if (indent === '') { diff --git a/node_modules/npm-audit-report/lib/reporters/install.js b/node_modules/npm-audit-report/lib/reporters/install.js index fe53be3..cb8a249 100644 --- a/node_modules/npm-audit-report/lib/reporters/install.js +++ b/node_modules/npm-audit-report/lib/reporters/install.js @@ -3,7 +3,7 @@ const colors = require('../colors.js') const calculate = (data, { color }) => { const c = colors(color) const output = [] - const { metadata: { vulnerabilities }} = data + const { metadata: { vulnerabilities } } = data const vulnCount = vulnerabilities.total let someFixable = false @@ -14,7 +14,7 @@ const calculate = (data, { color }) => { if (vulnCount === 0) { output.push(`found ${c.green('0')} vulnerabilities`) } else { - for (const [name, vuln] of Object.entries(data.vulnerabilities)) { + for (const [, vuln] of Object.entries(data.vulnerabilities)) { const { fixAvailable } = vuln someFixable = someFixable || fixAvailable === true someUnfixable = someUnfixable || fixAvailable === false @@ -45,7 +45,7 @@ const calculate = (data, { color }) => { if (someFixable) { output.push('', 'To address ' + (someForceFixable || someUnfixable ? 'issues that do not require attention' - : 'all issues') + ', run:\n npm audit fix') + : 'all issues') + ', run:\n npm audit fix') } if (someForceFixable) { @@ -66,10 +66,10 @@ const calculate = (data, { color }) => { return { summary, report: vulnCount > 0 ? `${summary}\n\nRun \`npm audit\` for details.` - : summary + : summary, } } module.exports = Object.assign((data, opt) => calculate(data, opt).report, { - summary: (data, opt) => calculate(data, opt).summary + summary: (data, opt) => calculate(data, opt).summary, }) diff --git a/node_modules/npm-audit-report/package.json b/node_modules/npm-audit-report/package.json index c819b96..8779f4c 100644 --- a/node_modules/npm-audit-report/package.json +++ b/node_modules/npm-audit-report/package.json @@ -1,18 +1,24 @@ { "name": "npm-audit-report", - "version": "2.1.5", + "version": "4.0.0", "description": "Given a response from the npm security api, render it into a variety of security reports", "main": "lib/index.js", "scripts": { "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags" + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "npm run lint -- --fix", + "posttest": "npm run lint" }, "tap": { "check-coverage": true, - "coverage-map": "map.js" + "coverage-map": "map.js", + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "keywords": [ "npm", @@ -20,14 +26,16 @@ "report", "audit" ], - "author": "Adam Baldwin", + "author": "GitHub Inc.", "license": "ISC", "dependencies": { "chalk": "^4.0.0" }, "devDependencies": { + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", "require-inject": "^1.4.4", - "tap": "^14.10.7" + "tap": "^16.0.0" }, "directories": { "lib": "lib", @@ -35,18 +43,21 @@ }, "repository": { "type": "git", - "url": "git+https://github.com/npm/npm-audit-report.git" + "url": "https://github.com/npm/npm-audit-report.git" }, "bugs": { "url": "https://github.com/npm/npm-audit-report/issues" }, "homepage": "https://github.com/npm/npm-audit-report#readme", "files": [ - "index.js", - "lib", - "reporters" + "bin/", + "lib/" ], "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" } } diff --git a/node_modules/npm-install-checks/index.js b/node_modules/npm-install-checks/lib/index.js similarity index 91% rename from node_modules/npm-install-checks/index.js rename to node_modules/npm-install-checks/lib/index.js index 732888e..728e8cf 100644 --- a/node_modules/npm-install-checks/index.js +++ b/node_modules/npm-install-checks/lib/index.js @@ -1,4 +1,3 @@ -const {format} = require('util') const semver = require('semver') const checkEngine = (target, npmVer, nodeVer, force = false) => { @@ -16,7 +15,7 @@ const checkEngine = (target, npmVer, nodeVer, force = false) => { pkgid: target._id, current: { node: nodeVer, npm: npmVer }, required: eng, - code: 'EBADENGINE' + code: 'EBADENGINE', }) } } @@ -36,13 +35,13 @@ const checkPlatform = (target, force = false) => { pkgid: target._id, current: { os: platform, - cpu: arch + cpu: arch, }, required: { os: target.os, - cpu: target.cpu + cpu: target.cpu, }, - code: 'EBADPLATFORM' + code: 'EBADPLATFORM', }) } } @@ -62,7 +61,7 @@ const checkList = (value, list) => { const negate = entry.charAt(0) === '!' const test = negate ? entry.slice(1) : entry if (negate) { - negated ++ + negated++ if (value === test) { return false } @@ -75,5 +74,5 @@ const checkList = (value, list) => { module.exports = { checkEngine, - checkPlatform + checkPlatform, } diff --git a/node_modules/npm-install-checks/package.json b/node_modules/npm-install-checks/package.json index 0eb597a..1003b10 100644 --- a/node_modules/npm-install-checks/package.json +++ b/node_modules/npm-install-checks/package.json @@ -1,23 +1,28 @@ { "name": "npm-install-checks", - "version": "4.0.0", + "version": "6.0.0", "description": "Check the engines and platform fields in package.json", - "main": "index.js", + "main": "lib/index.js", "dependencies": { "semver": "^7.1.1" }, "devDependencies": { - "tap": "^14.10.6" + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", + "tap": "^16.0.1" }, "scripts": { "test": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "postpublish": "git push origin --follow-tags" + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "npm run lint -- --fix", + "snap": "tap", + "posttest": "npm run lint" }, "repository": { "type": "git", - "url": "git://github.com/npm/npm-install-checks.git" + "url": "https://github.com/npm/npm-install-checks.git" }, "keywords": [ "npm,", @@ -25,9 +30,21 @@ ], "license": "BSD-2-Clause", "files": [ - "index.js" + "bin/", + "lib/" ], "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "author": "GitHub Inc.", + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/node_modules/npm-normalize-package-bin/LICENSE b/node_modules/npm-normalize-package-bin/LICENSE deleted file mode 100644 index 19cec97..0000000 --- a/node_modules/npm-normalize-package-bin/LICENSE +++ /dev/null @@ -1,15 +0,0 @@ -The ISC License - -Copyright (c) npm, Inc. - -Permission to use, copy, modify, and/or distribute this software for any -purpose with or without fee is hereby granted, provided that the above -copyright notice and this permission notice appear in all copies. - -THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR -IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/node_modules/npm-normalize-package-bin/index.js b/node_modules/npm-normalize-package-bin/index.js deleted file mode 100644 index 5a738ff..0000000 --- a/node_modules/npm-normalize-package-bin/index.js +++ /dev/null @@ -1,60 +0,0 @@ -// pass in a manifest with a 'bin' field here, and it'll turn it -// into a properly santized bin object -const {join, basename} = require('path') - -const normalize = pkg => - !pkg.bin ? removeBin(pkg) - : typeof pkg.bin === 'string' ? normalizeString(pkg) - : Array.isArray(pkg.bin) ? normalizeArray(pkg) - : typeof pkg.bin === 'object' ? normalizeObject(pkg) - : removeBin(pkg) - -const normalizeString = pkg => { - if (!pkg.name) - return removeBin(pkg) - pkg.bin = { [pkg.name]: pkg.bin } - return normalizeObject(pkg) -} - -const normalizeArray = pkg => { - pkg.bin = pkg.bin.reduce((acc, k) => { - acc[basename(k)] = k - return acc - }, {}) - return normalizeObject(pkg) -} - -const removeBin = pkg => { - delete pkg.bin - return pkg -} - -const normalizeObject = pkg => { - const orig = pkg.bin - const clean = {} - let hasBins = false - Object.keys(orig).forEach(binKey => { - const base = join('/', basename(binKey.replace(/\\|:/g, '/'))).substr(1) - - if (typeof orig[binKey] !== 'string' || !base) - return - - const binTarget = join('/', orig[binKey]) - .replace(/\\/g, '/').substr(1) - - if (!binTarget) - return - - clean[base] = binTarget - hasBins = true - }) - - if (hasBins) - pkg.bin = clean - else - delete pkg.bin - - return pkg -} - -module.exports = normalize diff --git a/node_modules/npm-normalize-package-bin/package-lock.json b/node_modules/npm-normalize-package-bin/package-lock.json deleted file mode 100644 index 0d3390d..0000000 --- a/node_modules/npm-normalize-package-bin/package-lock.json +++ /dev/null @@ -1,3529 +0,0 @@ -{ - "name": "npm-normalize-package-bin", - "version": "1.0.1", - "lockfileVersion": 1, - "requires": true, - "dependencies": { - "@babel/code-frame": { - "version": "7.5.5", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.5.5.tgz", - "integrity": "sha512-27d4lZoomVyo51VegxI20xZPuSHusqbQag/ztrBC7wegWoQ1nLREPVSKSW8byhTlzTKyNE4ifaTA6lCp7JjpFw==", - "dev": true, - "requires": { - "@babel/highlight": "^7.0.0" - } - }, - "@babel/generator": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.7.4.tgz", - "integrity": "sha512-m5qo2WgdOJeyYngKImbkyQrnUN1mPceaG5BV+G0E3gWsa4l/jCSryWJdM2x8OuGAOyh+3d5pVYfZWCiNFtynxg==", - "dev": true, - "requires": { - "@babel/types": "^7.7.4", - "jsesc": "^2.5.1", - "lodash": "^4.17.13", - "source-map": "^0.5.0" - }, - "dependencies": { - "source-map": { - "version": "0.5.7", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", - "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", - "dev": true - } - } - }, - "@babel/helper-function-name": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.7.4.tgz", - "integrity": "sha512-AnkGIdiBhEuiwdoMnKm7jfPfqItZhgRaZfMg1XX3bS25INOnLPjPG1Ppnajh8eqgt5kPJnfqrRHqFqmjKDZLzQ==", - "dev": true, - "requires": { - "@babel/helper-get-function-arity": "^7.7.4", - "@babel/template": "^7.7.4", - "@babel/types": "^7.7.4" - } - }, - "@babel/helper-get-function-arity": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.7.4.tgz", - "integrity": "sha512-QTGKEdCkjgzgfJ3bAyRwF4yyT3pg+vDgan8DSivq1eS0gwi+KGKE5x8kRcbeFTb/673mkO5SN1IZfmCfA5o+EA==", - "dev": true, - "requires": { - "@babel/types": "^7.7.4" - } - }, - "@babel/helper-split-export-declaration": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.7.4.tgz", - "integrity": "sha512-guAg1SXFcVr04Guk9eq0S4/rWS++sbmyqosJzVs8+1fH5NI+ZcmkaSkc7dmtAFbHFva6yRJnjW3yAcGxjueDug==", - "dev": true, - "requires": { - "@babel/types": "^7.7.4" - } - }, - "@babel/highlight": { - "version": "7.5.0", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.5.0.tgz", - "integrity": "sha512-7dV4eu9gBxoM0dAnj/BCFDW9LFU0zvTrkq0ugM7pnHEgguOEeOz1so2ZghEdzviYzQEED0r4EAgpsBChKy1TRQ==", - "dev": true, - "requires": { - "chalk": "^2.0.0", - "esutils": "^2.0.2", - "js-tokens": "^4.0.0" - } - }, - "@babel/parser": { - "version": "7.7.5", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.7.5.tgz", - "integrity": "sha512-KNlOe9+/nk4i29g0VXgl8PEXIRms5xKLJeuZ6UptN0fHv+jDiriG+y94X6qAgWTR0h3KaoM1wK5G5h7MHFRSig==", - "dev": true - }, - "@babel/runtime": { - "version": "7.7.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.7.6.tgz", - "integrity": "sha512-BWAJxpNVa0QlE5gZdWjSxXtemZyZ9RmrmVozxt3NUXeZhVIJ5ANyqmMc0JDrivBZyxUuQvFxlvH4OWWOogGfUw==", - "dev": true, - "requires": { - "regenerator-runtime": "^0.13.2" - } - }, - "@babel/template": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.7.4.tgz", - "integrity": "sha512-qUzihgVPguAzXCK7WXw8pqs6cEwi54s3E+HrejlkuWO6ivMKx9hZl3Y2fSXp9i5HgyWmj7RKP+ulaYnKM4yYxw==", - "dev": true, - "requires": { - "@babel/code-frame": "^7.0.0", - "@babel/parser": "^7.7.4", - "@babel/types": "^7.7.4" - } - }, - "@babel/traverse": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.7.4.tgz", - "integrity": "sha512-P1L58hQyupn8+ezVA2z5KBm4/Zr4lCC8dwKCMYzsa5jFMDMQAzaBNy9W5VjB+KAmBjb40U7a/H6ao+Xo+9saIw==", - "dev": true, - "requires": { - "@babel/code-frame": "^7.5.5", - "@babel/generator": "^7.7.4", - "@babel/helper-function-name": "^7.7.4", - "@babel/helper-split-export-declaration": "^7.7.4", - "@babel/parser": "^7.7.4", - "@babel/types": "^7.7.4", - "debug": "^4.1.0", - "globals": "^11.1.0", - "lodash": "^4.17.13" - } - }, - "@babel/types": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.7.4.tgz", - "integrity": "sha512-cz5Ji23KCi4T+YIE/BolWosrJuSmoZeN1EFnRtBwF+KKLi8GG/Z2c2hOJJeCXPk4mwk4QFvTmwIodJowXgttRA==", - "dev": true, - "requires": { - "esutils": "^2.0.2", - "lodash": "^4.17.13", - "to-fast-properties": "^2.0.0" - } - }, - "ajv": { - "version": "6.10.2", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.10.2.tgz", - "integrity": "sha512-TXtUUEYHuaTEbLZWIKUr5pmBuhDLy+8KYtPYdcV8qC+pOZL+NKqYwvWSRrVXHn+ZmRRAu8vJTAznH7Oag6RVRw==", - "dev": true, - "requires": { - "fast-deep-equal": "^2.0.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" - } - }, - "ansi-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", - "dev": true - }, - "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "dev": true, - "requires": { - "color-convert": "^1.9.0" - } - }, - "anymatch": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", - "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", - "dev": true, - "requires": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" - } - }, - "append-transform": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/append-transform/-/append-transform-1.0.0.tgz", - "integrity": "sha512-P009oYkeHyU742iSZJzZZywj4QRJdnTWffaKuJQLablCZ1uz6/cW4yaRgcDaoQ+uwOxxnt0gRUcwfsNP2ri0gw==", - "dev": true, - "requires": { - "default-require-extensions": "^2.0.0" - } - }, - "archy": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz", - "integrity": "sha1-+cjBN1fMHde8N5rHeyxipcKGjEA=", - "dev": true - }, - "arg": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.2.tgz", - "integrity": "sha512-+ytCkGcBtHZ3V2r2Z06AncYO8jz46UEamcspGoU8lHcEbpn6J77QK0vdWvChsclg/tM5XIJC5tnjmPp7Eq6Obg==", - "dev": true - }, - "argparse": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", - "dev": true, - "requires": { - "sprintf-js": "~1.0.2" - } - }, - "asn1": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz", - "integrity": "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==", - "dev": true, - "requires": { - "safer-buffer": "~2.1.0" - } - }, - "assert-plus": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", - "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=", - "dev": true - }, - "async-hook-domain": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/async-hook-domain/-/async-hook-domain-1.1.3.tgz", - "integrity": "sha512-ZovMxSbADV3+biB7oR1GL5lGyptI24alp0LWHlmz1OFc5oL47pz3EiIF6nXOkDW7yLqih4NtsiYduzdDW0i+Wg==", - "dev": true, - "requires": { - "source-map-support": "^0.5.11" - } - }, - "asynckit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=", - "dev": true - }, - "aws-sign2": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", - "integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=", - "dev": true - }, - "aws4": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.9.0.tgz", - "integrity": "sha512-Uvq6hVe90D0B2WEnUqtdgY1bATGz3mw33nH9Y+dmA+w5DHvUmBgkr5rM/KCHpCsiFNRUfokW/szpPPgMK2hm4A==", - "dev": true - }, - "balanced-match": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", - "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", - "dev": true - }, - "bcrypt-pbkdf": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", - "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=", - "dev": true, - "requires": { - "tweetnacl": "^0.14.3" - } - }, - "binary-extensions": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.0.0.tgz", - "integrity": "sha512-Phlt0plgpIIBOGTT/ehfFnbNlfsDEiqmzE2KRXoX1bLIlir4X/MR+zSyBEkL05ffWgnRSf/DXv+WrUAVr93/ow==", - "dev": true - }, - "bind-obj-methods": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/bind-obj-methods/-/bind-obj-methods-2.0.0.tgz", - "integrity": "sha512-3/qRXczDi2Cdbz6jE+W3IflJOutRVica8frpBn14de1mBOkzDo+6tY33kNhvkw54Kn3PzRRD2VnGbGPcTAk4sw==", - "dev": true - }, - "brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, - "requires": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "braces": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", - "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", - "dev": true, - "requires": { - "fill-range": "^7.0.1" - } - }, - "browser-process-hrtime": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/browser-process-hrtime/-/browser-process-hrtime-1.0.0.tgz", - "integrity": "sha512-9o5UecI3GhkpM6DrXr69PblIuWxPKk9Y0jHBRhdocZ2y7YECBFCsHm79Pr3OyR2AvjhDkabFJaDJMYRazHgsow==", - "dev": true - }, - "buffer-from": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", - "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==", - "dev": true - }, - "caching-transform": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/caching-transform/-/caching-transform-3.0.2.tgz", - "integrity": "sha512-Mtgcv3lh3U0zRii/6qVgQODdPA4G3zhG+jtbCWj39RXuUFTMzH0vcdMtaJS1jPowd+It2Pqr6y3NJMQqOqCE2w==", - "dev": true, - "requires": { - "hasha": "^3.0.0", - "make-dir": "^2.0.0", - "package-hash": "^3.0.0", - "write-file-atomic": "^2.4.2" - }, - "dependencies": { - "write-file-atomic": { - "version": "2.4.3", - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.4.3.tgz", - "integrity": "sha512-GaETH5wwsX+GcnzhPgKcKjJ6M2Cq3/iZp1WyY/X1CSqrW+jVNM9Y7D8EC2sM4ZG/V8wZlSniJnCKWPmBYAucRQ==", - "dev": true, - "requires": { - "graceful-fs": "^4.1.11", - "imurmurhash": "^0.1.4", - "signal-exit": "^3.0.2" - } - } - } - }, - "camelcase": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", - "dev": true - }, - "caseless": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", - "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=", - "dev": true - }, - "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - } - }, - "chokidar": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.3.0.tgz", - "integrity": "sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A==", - "dev": true, - "requires": { - "anymatch": "~3.1.1", - "braces": "~3.0.2", - "fsevents": "~2.1.1", - "glob-parent": "~5.1.0", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.2.0" - } - }, - "cliui": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz", - "integrity": "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==", - "dev": true, - "requires": { - "string-width": "^2.1.1", - "strip-ansi": "^4.0.0", - "wrap-ansi": "^2.0.0" - } - }, - "code-point-at": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", - "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", - "dev": true - }, - "color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", - "dev": true, - "requires": { - "color-name": "1.1.3" - } - }, - "color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", - "dev": true - }, - "color-support": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz", - "integrity": "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg==", - "dev": true - }, - "combined-stream": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", - "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", - "dev": true, - "requires": { - "delayed-stream": "~1.0.0" - } - }, - "commander": { - "version": "2.20.3", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", - "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true, - "optional": true - }, - "commondir": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", - "integrity": "sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs=", - "dev": true - }, - "concat-map": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", - "dev": true - }, - "convert-source-map": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.7.0.tgz", - "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==", - "dev": true, - "requires": { - "safe-buffer": "~5.1.1" - }, - "dependencies": { - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true - } - } - }, - "core-util-is": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", - "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", - "dev": true - }, - "coveralls": { - "version": "3.0.9", - "resolved": "https://registry.npmjs.org/coveralls/-/coveralls-3.0.9.tgz", - "integrity": "sha512-nNBg3B1+4iDox5A5zqHKzUTiwl2ey4k2o0NEcVZYvl+GOSJdKBj4AJGKLv6h3SvWch7tABHePAQOSZWM9E2hMg==", - "dev": true, - "requires": { - "js-yaml": "^3.13.1", - "lcov-parse": "^1.0.0", - "log-driver": "^1.2.7", - "minimist": "^1.2.0", - "request": "^2.88.0" - } - }, - "cp-file": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/cp-file/-/cp-file-6.2.0.tgz", - "integrity": "sha512-fmvV4caBnofhPe8kOcitBwSn2f39QLjnAnGq3gO9dfd75mUytzKNZB1hde6QHunW2Rt+OwuBOMc3i1tNElbszA==", - "dev": true, - "requires": { - "graceful-fs": "^4.1.2", - "make-dir": "^2.0.0", - "nested-error-stacks": "^2.0.0", - "pify": "^4.0.1", - "safe-buffer": "^5.0.1" - } - }, - "cross-spawn": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-4.0.2.tgz", - "integrity": "sha1-e5JHYhwjrf3ThWAEqCPL45dCTUE=", - "dev": true, - "requires": { - "lru-cache": "^4.0.1", - "which": "^1.2.9" - }, - "dependencies": { - "which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - } - } - }, - "dashdash": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", - "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0" - } - }, - "debug": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", - "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", - "dev": true, - "requires": { - "ms": "^2.1.1" - } - }, - "decamelize": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", - "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", - "dev": true - }, - "default-require-extensions": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/default-require-extensions/-/default-require-extensions-2.0.0.tgz", - "integrity": "sha1-9fj7sYp9bVCyH2QfZJ67Uiz+JPc=", - "dev": true, - "requires": { - "strip-bom": "^3.0.0" - } - }, - "delayed-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=", - "dev": true - }, - "diff": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.1.tgz", - "integrity": "sha512-s2+XdvhPCOF01LRQBC8hf4vhbVmI2CGS5aZnxLJlT5FtdhPCDFq80q++zK2KlrVorVDdL5BOGZ/VfLrVtYNF+Q==", - "dev": true - }, - "diff-frag": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/diff-frag/-/diff-frag-1.0.1.tgz", - "integrity": "sha512-6/v2PC/6UTGcWPPetb9acL8foberUg/CtPdALeJUdD1B/weHNvzftoo00gYznqHGRhHEbykUGzqfG9RWOSr5yw==", - "dev": true - }, - "ecc-jsbn": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", - "integrity": "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=", - "dev": true, - "requires": { - "jsbn": "~0.1.0", - "safer-buffer": "^2.1.0" - } - }, - "emoji-regex": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", - "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", - "dev": true - }, - "error-ex": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", - "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", - "dev": true, - "requires": { - "is-arrayish": "^0.2.1" - } - }, - "es6-error": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/es6-error/-/es6-error-4.1.1.tgz", - "integrity": "sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg==", - "dev": true - }, - "escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", - "dev": true - }, - "esm": { - "version": "3.2.25", - "resolved": "https://registry.npmjs.org/esm/-/esm-3.2.25.tgz", - "integrity": "sha512-U1suiZ2oDVWv4zPO56S0NcR5QriEahGtdN2OR6FiOG4WJvcjBVFB0qI4+eKoWFH483PKGuLuu6V8Z4T5g63UVA==", - "dev": true - }, - "esprima": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", - "dev": true - }, - "esutils": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", - "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", - "dev": true - }, - "events-to-array": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/events-to-array/-/events-to-array-1.1.2.tgz", - "integrity": "sha1-LUH1Y+H+QA7Uli/hpNXGp1Od9/Y=", - "dev": true - }, - "extend": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", - "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==", - "dev": true - }, - "extsprintf": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", - "integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=", - "dev": true - }, - "fast-deep-equal": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz", - "integrity": "sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk=", - "dev": true - }, - "fast-json-stable-stringify": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz", - "integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=", - "dev": true - }, - "fill-range": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", - "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", - "dev": true, - "requires": { - "to-regex-range": "^5.0.1" - } - }, - "find-cache-dir": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-2.1.0.tgz", - "integrity": "sha512-Tq6PixE0w/VMFfCgbONnkiQIVol/JJL7nRMi20fqzA4NRs9AfeqMGeRdPi3wIhYkxjeBaWh2rxwapn5Tu3IqOQ==", - "dev": true, - "requires": { - "commondir": "^1.0.1", - "make-dir": "^2.0.0", - "pkg-dir": "^3.0.0" - } - }, - "find-up": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", - "dev": true, - "requires": { - "locate-path": "^3.0.0" - } - }, - "findit": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/findit/-/findit-2.0.0.tgz", - "integrity": "sha1-ZQnwEmr0wXhVHPqZOU4DLhOk1W4=", - "dev": true - }, - "flow-parser": { - "version": "0.113.0", - "resolved": "https://registry.npmjs.org/flow-parser/-/flow-parser-0.113.0.tgz", - "integrity": "sha512-+hRyEB1sVLNMTMniDdM1JIS8BJ3HUL7IFIJaxX+t/JUy0GNYdI0Tg1QLx8DJmOF8HeoCrUDcREpnDAc/pPta3w==", - "dev": true - }, - "flow-remove-types": { - "version": "2.113.0", - "resolved": "https://registry.npmjs.org/flow-remove-types/-/flow-remove-types-2.113.0.tgz", - "integrity": "sha512-Rp4hN/JlGmUjNxXuBXr6Or+MgDH9xKc+ZiUSRzl/fbpiH9RaCPAQKsgVEYNPcIE26q6RpAuMQfvzR0jQfuwUZQ==", - "dev": true, - "requires": { - "flow-parser": "^0.113.0", - "pirates": "^3.0.2", - "vlq": "^0.2.1" - } - }, - "foreground-child": { - "version": "1.5.6", - "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-1.5.6.tgz", - "integrity": "sha1-T9ca0t/elnibmApcCilZN8svXOk=", - "dev": true, - "requires": { - "cross-spawn": "^4", - "signal-exit": "^3.0.0" - } - }, - "forever-agent": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", - "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=", - "dev": true - }, - "form-data": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz", - "integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==", - "dev": true, - "requires": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.6", - "mime-types": "^2.1.12" - } - }, - "fs-exists-cached": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs-exists-cached/-/fs-exists-cached-1.0.0.tgz", - "integrity": "sha1-zyVVTKBQ3EmuZla0HeQiWJidy84=", - "dev": true - }, - "fs.realpath": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", - "dev": true - }, - "fsevents": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.2.tgz", - "integrity": "sha512-R4wDiBwZ0KzpgOWetKDug1FZcYhqYnUYKtfZYt4mD5SBz76q0KR4Q9o7GIPamsVPGmW3EYPPJ0dOOjvx32ldZA==", - "dev": true, - "optional": true - }, - "function-loop": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/function-loop/-/function-loop-1.0.2.tgz", - "integrity": "sha512-Iw4MzMfS3udk/rqxTiDDCllhGwlOrsr50zViTOO/W6lS/9y6B1J0BD2VZzrnWUYBJsl3aeqjgR5v7bWWhZSYbA==", - "dev": true - }, - "get-caller-file": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "dev": true - }, - "getpass": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", - "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0" - } - }, - "glob": { - "version": "7.1.6", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", - "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", - "dev": true, - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - } - }, - "glob-parent": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.0.tgz", - "integrity": "sha512-qjtRgnIVmOfnKUE3NJAQEdk+lKrxfw8t5ke7SXtfMTHcjsBfOfWXCQfdb30zfDoZQ2IRSIiidmjtbHZPZ++Ihw==", - "dev": true, - "requires": { - "is-glob": "^4.0.1" - } - }, - "globals": { - "version": "11.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", - "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", - "dev": true - }, - "graceful-fs": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.3.tgz", - "integrity": "sha512-a30VEBm4PEdx1dRB7MFK7BejejvCvBronbLjht+sHuGYj8PHs7M/5Z+rt5lw551vZ7yfTCj4Vuyy3mSJytDWRQ==", - "dev": true - }, - "handlebars": { - "version": "4.5.3", - "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.5.3.tgz", - "integrity": "sha512-3yPecJoJHK/4c6aZhSvxOyG4vJKDshV36VHp0iVCDVh7o9w2vwi3NSnL2MMPj3YdduqaBcu7cGbggJQM0br9xA==", - "dev": true, - "requires": { - "neo-async": "^2.6.0", - "optimist": "^0.6.1", - "source-map": "^0.6.1", - "uglify-js": "^3.1.4" - } - }, - "har-schema": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz", - "integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=", - "dev": true - }, - "har-validator": { - "version": "5.1.3", - "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz", - "integrity": "sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g==", - "dev": true, - "requires": { - "ajv": "^6.5.5", - "har-schema": "^2.0.0" - } - }, - "has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", - "dev": true - }, - "hasha": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/hasha/-/hasha-3.0.0.tgz", - "integrity": "sha1-UqMvq4Vp1BymmmH/GiFPjrfIvTk=", - "dev": true, - "requires": { - "is-stream": "^1.0.1" - } - }, - "hosted-git-info": { - "version": "2.8.5", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.5.tgz", - "integrity": "sha512-kssjab8CvdXfcXMXVcvsXum4Hwdq9XGtRD3TteMEvEbq0LXyiNQr6AprqKqfeaDXze7SxWvRxdpwE6ku7ikLkg==", - "dev": true - }, - "http-signature": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz", - "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0", - "jsprim": "^1.2.2", - "sshpk": "^1.7.0" - } - }, - "imurmurhash": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=", - "dev": true - }, - "inflight": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", - "dev": true, - "requires": { - "once": "^1.3.0", - "wrappy": "1" - } - }, - "inherits": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "dev": true - }, - "is-arrayish": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", - "integrity": "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=", - "dev": true - }, - "is-binary-path": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", - "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", - "dev": true, - "requires": { - "binary-extensions": "^2.0.0" - } - }, - "is-extglob": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", - "dev": true - }, - "is-fullwidth-code-point": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", - "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", - "dev": true - }, - "is-glob": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", - "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", - "dev": true, - "requires": { - "is-extglob": "^2.1.1" - } - }, - "is-number": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", - "dev": true - }, - "is-stream": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", - "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=", - "dev": true - }, - "is-typedarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", - "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=", - "dev": true - }, - "isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", - "dev": true, - "optional": true - }, - "isexe": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", - "dev": true - }, - "isstream": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", - "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=", - "dev": true - }, - "istanbul-lib-coverage": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.5.tgz", - "integrity": "sha512-8aXznuEPCJvGnMSRft4udDRDtb1V3pkQkMMI5LI+6HuQz5oQ4J2UFn1H82raA3qJtyOLkkwVqICBQkjnGtn5mA==", - "dev": true - }, - "istanbul-lib-hook": { - "version": "2.0.7", - "resolved": "https://registry.npmjs.org/istanbul-lib-hook/-/istanbul-lib-hook-2.0.7.tgz", - "integrity": "sha512-vrRztU9VRRFDyC+aklfLoeXyNdTfga2EI3udDGn4cZ6fpSXpHLV9X6CHvfoMCPtggg8zvDDmC4b9xfu0z6/llA==", - "dev": true, - "requires": { - "append-transform": "^1.0.0" - } - }, - "istanbul-lib-instrument": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-3.3.0.tgz", - "integrity": "sha512-5nnIN4vo5xQZHdXno/YDXJ0G+I3dAm4XgzfSVTPLQpj/zAV2dV6Juy0yaf10/zrJOJeHoN3fraFe+XRq2bFVZA==", - "dev": true, - "requires": { - "@babel/generator": "^7.4.0", - "@babel/parser": "^7.4.3", - "@babel/template": "^7.4.0", - "@babel/traverse": "^7.4.3", - "@babel/types": "^7.4.0", - "istanbul-lib-coverage": "^2.0.5", - "semver": "^6.0.0" - }, - "dependencies": { - "semver": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", - "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", - "dev": true - } - } - }, - "istanbul-lib-processinfo": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/istanbul-lib-processinfo/-/istanbul-lib-processinfo-1.0.0.tgz", - "integrity": "sha512-FY0cPmWa4WoQNlvB8VOcafiRoB5nB+l2Pz2xGuXHRSy1KM8QFOYfz/rN+bGMCAeejrY3mrpF5oJHcN0s/garCg==", - "dev": true, - "requires": { - "archy": "^1.0.0", - "cross-spawn": "^6.0.5", - "istanbul-lib-coverage": "^2.0.3", - "rimraf": "^2.6.3", - "uuid": "^3.3.2" - }, - "dependencies": { - "cross-spawn": { - "version": "6.0.5", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", - "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", - "dev": true, - "requires": { - "nice-try": "^1.0.4", - "path-key": "^2.0.1", - "semver": "^5.5.0", - "shebang-command": "^1.2.0", - "which": "^1.2.9" - } - }, - "which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - } - } - }, - "istanbul-lib-report": { - "version": "2.0.8", - "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-2.0.8.tgz", - "integrity": "sha512-fHBeG573EIihhAblwgxrSenp0Dby6tJMFR/HvlerBsrCTD5bkUuoNtn3gVh29ZCS824cGGBPn7Sg7cNk+2xUsQ==", - "dev": true, - "requires": { - "istanbul-lib-coverage": "^2.0.5", - "make-dir": "^2.1.0", - "supports-color": "^6.1.0" - }, - "dependencies": { - "supports-color": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.1.0.tgz", - "integrity": "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } - } - }, - "istanbul-lib-source-maps": { - "version": "3.0.6", - "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-3.0.6.tgz", - "integrity": "sha512-R47KzMtDJH6X4/YW9XTx+jrLnZnscW4VpNN+1PViSYTejLVPWv7oov+Duf8YQSPyVRUvueQqz1TcsC6mooZTXw==", - "dev": true, - "requires": { - "debug": "^4.1.1", - "istanbul-lib-coverage": "^2.0.5", - "make-dir": "^2.1.0", - "rimraf": "^2.6.3", - "source-map": "^0.6.1" - } - }, - "istanbul-reports": { - "version": "2.2.6", - "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-2.2.6.tgz", - "integrity": "sha512-SKi4rnMyLBKe0Jy2uUdx28h8oG7ph2PPuQPvIAh31d+Ci+lSiEu4C+h3oBPuJ9+mPKhOyW0M8gY4U5NM1WLeXA==", - "dev": true, - "requires": { - "handlebars": "^4.1.2" - } - }, - "jackspeak": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-1.4.0.tgz", - "integrity": "sha512-VDcSunT+wcccoG46FtzuBAyQKlzhHjli4q31e1fIHGOsRspqNUFjVzGb+7eIFDlTvqLygxapDHPHS0ouT2o/tw==", - "dev": true, - "requires": { - "cliui": "^4.1.0" - } - }, - "js-tokens": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true - }, - "js-yaml": { - "version": "3.13.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", - "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", - "dev": true, - "requires": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" - } - }, - "jsbn": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", - "integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=", - "dev": true - }, - "jsesc": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", - "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", - "dev": true - }, - "json-parse-better-errors": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz", - "integrity": "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==", - "dev": true - }, - "json-schema": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz", - "integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=", - "dev": true - }, - "json-schema-traverse": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", - "dev": true - }, - "json-stringify-safe": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", - "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=", - "dev": true - }, - "jsprim": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz", - "integrity": "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=", - "dev": true, - "requires": { - "assert-plus": "1.0.0", - "extsprintf": "1.3.0", - "json-schema": "0.2.3", - "verror": "1.10.0" - } - }, - "lcov-parse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/lcov-parse/-/lcov-parse-1.0.0.tgz", - "integrity": "sha1-6w1GtUER68VhrLTECO+TY73I9+A=", - "dev": true - }, - "load-json-file": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-4.0.0.tgz", - "integrity": "sha1-L19Fq5HjMhYjT9U62rZo607AmTs=", - "dev": true, - "requires": { - "graceful-fs": "^4.1.2", - "parse-json": "^4.0.0", - "pify": "^3.0.0", - "strip-bom": "^3.0.0" - }, - "dependencies": { - "pify": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", - "integrity": "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=", - "dev": true - } - } - }, - "locate-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", - "dev": true, - "requires": { - "p-locate": "^3.0.0", - "path-exists": "^3.0.0" - } - }, - "lodash": { - "version": "4.17.15", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.15.tgz", - "integrity": "sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A==", - "dev": true - }, - "lodash.flattendeep": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz", - "integrity": "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=", - "dev": true - }, - "log-driver": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/log-driver/-/log-driver-1.2.7.tgz", - "integrity": "sha512-U7KCmLdqsGHBLeWqYlFA0V0Sl6P08EE1ZrmA9cxjUE0WVqT9qnyVDPz1kzpFEP0jdJuFnasWIfSd7fsaNXkpbg==", - "dev": true - }, - "loose-envify": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", - "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", - "dev": true, - "requires": { - "js-tokens": "^3.0.0 || ^4.0.0" - } - }, - "lru-cache": { - "version": "4.1.5", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.5.tgz", - "integrity": "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==", - "dev": true, - "requires": { - "pseudomap": "^1.0.2", - "yallist": "^2.1.2" - } - }, - "make-dir": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-2.1.0.tgz", - "integrity": "sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA==", - "dev": true, - "requires": { - "pify": "^4.0.1", - "semver": "^5.6.0" - } - }, - "make-error": { - "version": "1.3.5", - "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.5.tgz", - "integrity": "sha512-c3sIjNUow0+8swNwVpqoH4YCShKNFkMaw6oH1mNS2haDZQqkeZFlHS3dhoeEbKKmJB4vXpJucU6oH75aDYeE9g==", - "dev": true - }, - "merge-source-map": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/merge-source-map/-/merge-source-map-1.1.0.tgz", - "integrity": "sha512-Qkcp7P2ygktpMPh2mCQZaf3jhN6D3Z/qVZHSdWvQ+2Ef5HgRAPBO57A77+ENm0CPx2+1Ce/MYKi3ymqdfuqibw==", - "dev": true, - "requires": { - "source-map": "^0.6.1" - } - }, - "mime-db": { - "version": "1.42.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.42.0.tgz", - "integrity": "sha512-UbfJCR4UAVRNgMpfImz05smAXK7+c+ZntjaA26ANtkXLlOe947Aag5zdIcKQULAiF9Cq4WxBi9jUs5zkA84bYQ==", - "dev": true - }, - "mime-types": { - "version": "2.1.25", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.25.tgz", - "integrity": "sha512-5KhStqB5xpTAeGqKBAMgwaYMnQik7teQN4IAzC7npDv6kzeU6prfkR67bc87J1kWMPGkoaZSq1npmexMgkmEVg==", - "dev": true, - "requires": { - "mime-db": "1.42.0" - } - }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "dev": true, - "requires": { - "brace-expansion": "^1.1.7" - } - }, - "minimist": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", - "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", - "dev": true - }, - "minipass": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.1.1.tgz", - "integrity": "sha512-UFqVihv6PQgwj8/yTGvl9kPz7xIAY+R5z6XYjRInD3Gk3qx6QGSD6zEcpeG4Dy/lQnv1J6zv8ejV90hyYIKf3w==", - "dev": true, - "requires": { - "yallist": "^4.0.0" - }, - "dependencies": { - "yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - } - } - }, - "mkdirp": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", - "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", - "dev": true, - "requires": { - "minimist": "0.0.8" - }, - "dependencies": { - "minimist": { - "version": "0.0.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", - "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", - "dev": true - } - } - }, - "ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "dev": true - }, - "neo-async": { - "version": "2.6.1", - "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.1.tgz", - "integrity": "sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw==", - "dev": true - }, - "nested-error-stacks": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/nested-error-stacks/-/nested-error-stacks-2.1.0.tgz", - "integrity": "sha512-AO81vsIO1k1sM4Zrd6Hu7regmJN1NSiAja10gc4bX3F0wd+9rQmcuHQaHVQCYIEC8iFXnE+mavh23GOt7wBgug==", - "dev": true - }, - "nice-try": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", - "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", - "dev": true - }, - "node-modules-regexp": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz", - "integrity": "sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA=", - "dev": true - }, - "normalize-package-data": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz", - "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", - "dev": true, - "requires": { - "hosted-git-info": "^2.1.4", - "resolve": "^1.10.0", - "semver": "2 || 3 || 4 || 5", - "validate-npm-package-license": "^3.0.1" - } - }, - "normalize-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", - "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", - "dev": true - }, - "number-is-nan": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", - "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", - "dev": true - }, - "nyc": { - "version": "14.1.1", - "resolved": "https://registry.npmjs.org/nyc/-/nyc-14.1.1.tgz", - "integrity": "sha512-OI0vm6ZGUnoGZv/tLdZ2esSVzDwUC88SNs+6JoSOMVxA+gKMB8Tk7jBwgemLx4O40lhhvZCVw1C+OYLOBOPXWw==", - "dev": true, - "requires": { - "archy": "^1.0.0", - "caching-transform": "^3.0.2", - "convert-source-map": "^1.6.0", - "cp-file": "^6.2.0", - "find-cache-dir": "^2.1.0", - "find-up": "^3.0.0", - "foreground-child": "^1.5.6", - "glob": "^7.1.3", - "istanbul-lib-coverage": "^2.0.5", - "istanbul-lib-hook": "^2.0.7", - "istanbul-lib-instrument": "^3.3.0", - "istanbul-lib-report": "^2.0.8", - "istanbul-lib-source-maps": "^3.0.6", - "istanbul-reports": "^2.2.4", - "js-yaml": "^3.13.1", - "make-dir": "^2.1.0", - "merge-source-map": "^1.1.0", - "resolve-from": "^4.0.0", - "rimraf": "^2.6.3", - "signal-exit": "^3.0.2", - "spawn-wrap": "^1.4.2", - "test-exclude": "^5.2.3", - "uuid": "^3.3.2", - "yargs": "^13.2.2", - "yargs-parser": "^13.0.0" - } - }, - "oauth-sign": { - "version": "0.9.0", - "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz", - "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==", - "dev": true - }, - "object-assign": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", - "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", - "dev": true - }, - "once": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", - "dev": true, - "requires": { - "wrappy": "1" - } - }, - "opener": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/opener/-/opener-1.5.1.tgz", - "integrity": "sha512-goYSy5c2UXE4Ra1xixabeVh1guIX/ZV/YokJksb6q2lubWu6UbvPQ20p542/sFIll1nl8JnCyK9oBaOcCWXwvA==", - "dev": true - }, - "optimist": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/optimist/-/optimist-0.6.1.tgz", - "integrity": "sha1-2j6nRob6IaGaERwybpDrFaAZZoY=", - "dev": true, - "requires": { - "minimist": "~0.0.1", - "wordwrap": "~0.0.2" - }, - "dependencies": { - "minimist": { - "version": "0.0.10", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.10.tgz", - "integrity": "sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8=", - "dev": true - } - } - }, - "os-homedir": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", - "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", - "dev": true - }, - "own-or": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/own-or/-/own-or-1.0.0.tgz", - "integrity": "sha1-Tod/vtqaLsgAD7wLyuOWRe6L+Nw=", - "dev": true - }, - "own-or-env": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/own-or-env/-/own-or-env-1.0.1.tgz", - "integrity": "sha512-y8qULRbRAlL6x2+M0vIe7jJbJx/kmUTzYonRAa2ayesR2qWLswninkVyeJe4x3IEXhdgoNodzjQRKAoEs6Fmrw==", - "dev": true, - "requires": { - "own-or": "^1.0.0" - } - }, - "p-limit": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.2.1.tgz", - "integrity": "sha512-85Tk+90UCVWvbDavCLKPOLC9vvY8OwEX/RtKF+/1OADJMVlFfEHOiMTPVyxg7mk/dKa+ipdHm0OUkTvCpMTuwg==", - "dev": true, - "requires": { - "p-try": "^2.0.0" - } - }, - "p-locate": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", - "dev": true, - "requires": { - "p-limit": "^2.0.0" - } - }, - "p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "dev": true - }, - "package-hash": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/package-hash/-/package-hash-3.0.0.tgz", - "integrity": "sha512-lOtmukMDVvtkL84rJHI7dpTYq+0rli8N2wlnqUcBuDWCfVhRUfOmnR9SsoHFMLpACvEV60dX7rd0rFaYDZI+FA==", - "dev": true, - "requires": { - "graceful-fs": "^4.1.15", - "hasha": "^3.0.0", - "lodash.flattendeep": "^4.4.0", - "release-zalgo": "^1.0.0" - } - }, - "parse-json": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz", - "integrity": "sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA=", - "dev": true, - "requires": { - "error-ex": "^1.3.1", - "json-parse-better-errors": "^1.0.1" - } - }, - "path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", - "dev": true - }, - "path-is-absolute": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", - "dev": true - }, - "path-key": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", - "integrity": "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=", - "dev": true - }, - "path-parse": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz", - "integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==", - "dev": true - }, - "path-type": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-type/-/path-type-3.0.0.tgz", - "integrity": "sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg==", - "dev": true, - "requires": { - "pify": "^3.0.0" - }, - "dependencies": { - "pify": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", - "integrity": "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=", - "dev": true - } - } - }, - "performance-now": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", - "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=", - "dev": true - }, - "picomatch": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.1.1.tgz", - "integrity": "sha512-OYMyqkKzK7blWO/+XZYP6w8hH0LDvkBvdvKukti+7kqYFCiEAk+gI3DWnryapc0Dau05ugGTy0foQ6mqn4AHYA==", - "dev": true - }, - "pify": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz", - "integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==", - "dev": true - }, - "pirates": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/pirates/-/pirates-3.0.2.tgz", - "integrity": "sha512-c5CgUJq6H2k6MJz72Ak1F5sN9n9wlSlJyEnwvpm9/y3WB4E3pHBDT2c6PEiS1vyJvq2bUxUAIu0EGf8Cx4Ic7Q==", - "dev": true, - "requires": { - "node-modules-regexp": "^1.0.0" - } - }, - "pkg-dir": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-3.0.0.tgz", - "integrity": "sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw==", - "dev": true, - "requires": { - "find-up": "^3.0.0" - } - }, - "process-nextick-args": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", - "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", - "dev": true, - "optional": true - }, - "prop-types": { - "version": "15.7.2", - "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.7.2.tgz", - "integrity": "sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ==", - "dev": true, - "requires": { - "loose-envify": "^1.4.0", - "object-assign": "^4.1.1", - "react-is": "^16.8.1" - } - }, - "pseudomap": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz", - "integrity": "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=", - "dev": true - }, - "psl": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/psl/-/psl-1.6.0.tgz", - "integrity": "sha512-SYKKmVel98NCOYXpkwUqZqh0ahZeeKfmisiLIcEZdsb+WbLv02g/dI5BUmZnIyOe7RzZtLax81nnb2HbvC2tzA==", - "dev": true - }, - "punycode": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", - "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", - "dev": true - }, - "qs": { - "version": "6.5.2", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", - "integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==", - "dev": true - }, - "react": { - "version": "16.12.0", - "resolved": "https://registry.npmjs.org/react/-/react-16.12.0.tgz", - "integrity": "sha512-fglqy3k5E+81pA8s+7K0/T3DBCF0ZDOher1elBFzF7O6arXJgzyu/FW+COxFvAWXJoJN9KIZbT2LXlukwphYTA==", - "dev": true, - "requires": { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1", - "prop-types": "^15.6.2" - } - }, - "react-is": { - "version": "16.12.0", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.12.0.tgz", - "integrity": "sha512-rPCkf/mWBtKc97aLL9/txD8DZdemK0vkA3JMLShjlJB3Pj3s+lpf1KaBzMfQrAmhMQB0n1cU/SUGgKKBCe837Q==", - "dev": true - }, - "read-pkg": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-3.0.0.tgz", - "integrity": "sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k=", - "dev": true, - "requires": { - "load-json-file": "^4.0.0", - "normalize-package-data": "^2.3.2", - "path-type": "^3.0.0" - } - }, - "read-pkg-up": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-4.0.0.tgz", - "integrity": "sha512-6etQSH7nJGsK0RbG/2TeDzZFa8shjQ1um+SwQQ5cwKy0dhSXdOncEhb1CPpvQG4h7FyOV6EB6YlV0yJvZQNAkA==", - "dev": true, - "requires": { - "find-up": "^3.0.0", - "read-pkg": "^3.0.0" - } - }, - "readable-stream": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", - "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", - "dev": true, - "optional": true, - "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" - }, - "dependencies": { - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true, - "optional": true - } - } - }, - "readdirp": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.2.0.tgz", - "integrity": "sha512-crk4Qu3pmXwgxdSgGhgA/eXiJAPQiX4GMOZZMXnqKxHX7TaoL+3gQVo/WeuAiogr07DpnfjIMpXXa+PAIvwPGQ==", - "dev": true, - "requires": { - "picomatch": "^2.0.4" - } - }, - "regenerator-runtime": { - "version": "0.13.3", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.3.tgz", - "integrity": "sha512-naKIZz2GQ8JWh///G7L3X6LaQUAMp2lvb1rvwwsURe/VXwD6VMfr+/1NuNw3ag8v2kY1aQ/go5SNn79O9JU7yw==", - "dev": true - }, - "release-zalgo": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/release-zalgo/-/release-zalgo-1.0.0.tgz", - "integrity": "sha1-CXALflB0Mpc5Mw5TXFqQ+2eFFzA=", - "dev": true, - "requires": { - "es6-error": "^4.0.1" - } - }, - "request": { - "version": "2.88.0", - "resolved": "https://registry.npmjs.org/request/-/request-2.88.0.tgz", - "integrity": "sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg==", - "dev": true, - "requires": { - "aws-sign2": "~0.7.0", - "aws4": "^1.8.0", - "caseless": "~0.12.0", - "combined-stream": "~1.0.6", - "extend": "~3.0.2", - "forever-agent": "~0.6.1", - "form-data": "~2.3.2", - "har-validator": "~5.1.0", - "http-signature": "~1.2.0", - "is-typedarray": "~1.0.0", - "isstream": "~0.1.2", - "json-stringify-safe": "~5.0.1", - "mime-types": "~2.1.19", - "oauth-sign": "~0.9.0", - "performance-now": "^2.1.0", - "qs": "~6.5.2", - "safe-buffer": "^5.1.2", - "tough-cookie": "~2.4.3", - "tunnel-agent": "^0.6.0", - "uuid": "^3.3.2" - } - }, - "require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", - "dev": true - }, - "require-main-filename": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", - "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", - "dev": true - }, - "resolve": { - "version": "1.13.1", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.13.1.tgz", - "integrity": "sha512-CxqObCX8K8YtAhOBRg+lrcdn+LK+WYOS8tSjqSFbjtrI5PnS63QPhZl4+yKfrU9tdsbMu9Anr/amegT87M9Z6w==", - "dev": true, - "requires": { - "path-parse": "^1.0.6" - } - }, - "resolve-from": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", - "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", - "dev": true - }, - "rimraf": { - "version": "2.7.1", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", - "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", - "dev": true, - "requires": { - "glob": "^7.1.3" - } - }, - "safe-buffer": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz", - "integrity": "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==", - "dev": true - }, - "safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "dev": true - }, - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", - "dev": true - }, - "set-blocking": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", - "dev": true - }, - "shebang-command": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", - "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", - "dev": true, - "requires": { - "shebang-regex": "^1.0.0" - } - }, - "shebang-regex": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", - "integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=", - "dev": true - }, - "signal-exit": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", - "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=", - "dev": true - }, - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - }, - "source-map-support": { - "version": "0.5.16", - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.16.tgz", - "integrity": "sha512-efyLRJDr68D9hBBNIPWFjhpFzURh+KJykQwvMyW5UiZzYwoF6l4YMMDIJJEyFWxWCqfyxLzz6tSfUFR+kXXsVQ==", - "dev": true, - "requires": { - "buffer-from": "^1.0.0", - "source-map": "^0.6.0" - } - }, - "spawn-wrap": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/spawn-wrap/-/spawn-wrap-1.4.3.tgz", - "integrity": "sha512-IgB8md0QW/+tWqcavuFgKYR/qIRvJkRLPJDFaoXtLLUaVcCDK0+HeFTkmQHj3eprcYhc+gOl0aEA1w7qZlYezw==", - "dev": true, - "requires": { - "foreground-child": "^1.5.6", - "mkdirp": "^0.5.0", - "os-homedir": "^1.0.1", - "rimraf": "^2.6.2", - "signal-exit": "^3.0.2", - "which": "^1.3.0" - }, - "dependencies": { - "which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - } - } - }, - "spdx-correct": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.0.tgz", - "integrity": "sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q==", - "dev": true, - "requires": { - "spdx-expression-parse": "^3.0.0", - "spdx-license-ids": "^3.0.0" - } - }, - "spdx-exceptions": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz", - "integrity": "sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA==", - "dev": true - }, - "spdx-expression-parse": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz", - "integrity": "sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg==", - "dev": true, - "requires": { - "spdx-exceptions": "^2.1.0", - "spdx-license-ids": "^3.0.0" - } - }, - "spdx-license-ids": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.5.tgz", - "integrity": "sha512-J+FWzZoynJEXGphVIS+XEh3kFSjZX/1i9gFBaWQcB+/tmpe2qUsSBABpcxqxnAxFdiUFEgAX1bjYGQvIZmoz9Q==", - "dev": true - }, - "sprintf-js": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", - "dev": true - }, - "sshpk": { - "version": "1.16.1", - "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz", - "integrity": "sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==", - "dev": true, - "requires": { - "asn1": "~0.2.3", - "assert-plus": "^1.0.0", - "bcrypt-pbkdf": "^1.0.0", - "dashdash": "^1.12.0", - "ecc-jsbn": "~0.1.1", - "getpass": "^0.1.1", - "jsbn": "~0.1.0", - "safer-buffer": "^2.0.2", - "tweetnacl": "~0.14.0" - } - }, - "stack-utils": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-1.0.2.tgz", - "integrity": "sha512-MTX+MeG5U994cazkjd/9KNAapsHnibjMLnfXodlkXw76JEea0UiNzrqidzo1emMwk7w5Qhc9jd4Bn9TBb1MFwA==", - "dev": true - }, - "string-width": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", - "dev": true, - "requires": { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0" - } - }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, - "optional": true, - "requires": { - "safe-buffer": "~5.1.0" - }, - "dependencies": { - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true, - "optional": true - } - } - }, - "strip-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "dev": true, - "requires": { - "ansi-regex": "^3.0.0" - } - }, - "strip-bom": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", - "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=", - "dev": true - }, - "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - }, - "tap": { - "version": "14.10.2", - "resolved": "https://registry.npmjs.org/tap/-/tap-14.10.2.tgz", - "integrity": "sha512-JeUDsVrMFmR6b3p9hO9yIT/jibrK6LI7nFza5cqDGsxJyCp7yU3enRgS5nekuoAOzewbrU7P+9QDRDT01urROA==", - "dev": true, - "requires": { - "async-hook-domain": "^1.1.3", - "bind-obj-methods": "^2.0.0", - "browser-process-hrtime": "^1.0.0", - "chokidar": "^3.3.0", - "color-support": "^1.1.0", - "coveralls": "^3.0.8", - "diff": "^4.0.1", - "esm": "^3.2.25", - "findit": "^2.0.0", - "flow-remove-types": "^2.112.0", - "foreground-child": "^1.3.3", - "fs-exists-cached": "^1.0.0", - "function-loop": "^1.0.2", - "glob": "^7.1.6", - "import-jsx": "^3.0.0", - "ink": "^2.5.0", - "isexe": "^2.0.0", - "istanbul-lib-processinfo": "^1.0.0", - "jackspeak": "^1.4.0", - "minipass": "^3.1.1", - "mkdirp": "^0.5.1", - "nyc": "^14.1.1", - "opener": "^1.5.1", - "own-or": "^1.0.0", - "own-or-env": "^1.0.1", - "react": "^16.12.0", - "rimraf": "^2.7.1", - "signal-exit": "^3.0.0", - "source-map-support": "^0.5.16", - "stack-utils": "^1.0.2", - "tap-mocha-reporter": "^5.0.0", - "tap-parser": "^10.0.1", - "tap-yaml": "^1.0.0", - "tcompare": "^3.0.0", - "treport": "^1.0.0", - "trivial-deferred": "^1.0.1", - "ts-node": "^8.5.2", - "typescript": "^3.7.2", - "which": "^2.0.2", - "write-file-atomic": "^3.0.1", - "yaml": "^1.7.2", - "yapool": "^1.0.0" - }, - "dependencies": { - "@babel/code-frame": { - "version": "7.5.5", - "bundled": true, - "requires": { - "@babel/highlight": "^7.0.0" - } - }, - "@babel/core": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/code-frame": "^7.5.5", - "@babel/generator": "^7.7.4", - "@babel/helpers": "^7.7.4", - "@babel/parser": "^7.7.4", - "@babel/template": "^7.7.4", - "@babel/traverse": "^7.7.4", - "@babel/types": "^7.7.4", - "convert-source-map": "^1.7.0", - "debug": "^4.1.0", - "json5": "^2.1.0", - "lodash": "^4.17.13", - "resolve": "^1.3.2", - "semver": "^5.4.1", - "source-map": "^0.5.0" - }, - "dependencies": { - "@babel/generator": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.7.4", - "jsesc": "^2.5.1", - "lodash": "^4.17.13", - "source-map": "^0.5.0" - } - }, - "@babel/helper-function-name": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-get-function-arity": "^7.7.4", - "@babel/template": "^7.7.4", - "@babel/types": "^7.7.4" - } - }, - "@babel/helper-get-function-arity": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.7.4" - } - }, - "@babel/helper-split-export-declaration": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.7.4" - } - }, - "@babel/parser": { - "version": "7.7.4", - "bundled": true, - "dev": true - }, - "@babel/template": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/code-frame": "^7.0.0", - "@babel/parser": "^7.7.4", - "@babel/types": "^7.7.4" - } - }, - "@babel/traverse": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/code-frame": "^7.5.5", - "@babel/generator": "^7.7.4", - "@babel/helper-function-name": "^7.7.4", - "@babel/helper-split-export-declaration": "^7.7.4", - "@babel/parser": "^7.7.4", - "@babel/types": "^7.7.4", - "debug": "^4.1.0", - "globals": "^11.1.0", - "lodash": "^4.17.13" - } - }, - "@babel/types": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "esutils": "^2.0.2", - "lodash": "^4.17.13", - "to-fast-properties": "^2.0.0" - } - }, - "convert-source-map": { - "version": "1.7.0", - "bundled": true, - "dev": true, - "requires": { - "safe-buffer": "~5.1.1" - } - }, - "debug": { - "version": "4.1.1", - "bundled": true, - "dev": true, - "requires": { - "ms": "^2.1.1" - } - }, - "ms": { - "version": "2.1.2", - "bundled": true, - "dev": true - }, - "safe-buffer": { - "version": "5.1.2", - "bundled": true, - "dev": true - }, - "source-map": { - "version": "0.5.7", - "bundled": true, - "dev": true - } - } - }, - "@babel/generator": { - "version": "7.7.2", - "bundled": true, - "requires": { - "@babel/types": "^7.7.2", - "jsesc": "^2.5.1", - "lodash": "^4.17.13", - "source-map": "^0.5.0" - }, - "dependencies": { - "source-map": { - "version": "0.5.7", - "bundled": true - } - } - }, - "@babel/helper-builder-react-jsx": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.7.4", - "esutils": "^2.0.0" - }, - "dependencies": { - "@babel/types": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "esutils": "^2.0.2", - "lodash": "^4.17.13", - "to-fast-properties": "^2.0.0" - } - } - } - }, - "@babel/helper-plugin-utils": { - "version": "7.0.0", - "bundled": true, - "dev": true - }, - "@babel/helpers": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/template": "^7.7.4", - "@babel/traverse": "^7.7.4", - "@babel/types": "^7.7.4" - }, - "dependencies": { - "@babel/generator": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.7.4", - "jsesc": "^2.5.1", - "lodash": "^4.17.13", - "source-map": "^0.5.0" - } - }, - "@babel/helper-function-name": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-get-function-arity": "^7.7.4", - "@babel/template": "^7.7.4", - "@babel/types": "^7.7.4" - } - }, - "@babel/helper-get-function-arity": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.7.4" - } - }, - "@babel/helper-split-export-declaration": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.7.4" - } - }, - "@babel/parser": { - "version": "7.7.4", - "bundled": true, - "dev": true - }, - "@babel/template": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/code-frame": "^7.0.0", - "@babel/parser": "^7.7.4", - "@babel/types": "^7.7.4" - } - }, - "@babel/traverse": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/code-frame": "^7.5.5", - "@babel/generator": "^7.7.4", - "@babel/helper-function-name": "^7.7.4", - "@babel/helper-split-export-declaration": "^7.7.4", - "@babel/parser": "^7.7.4", - "@babel/types": "^7.7.4", - "debug": "^4.1.0", - "globals": "^11.1.0", - "lodash": "^4.17.13" - } - }, - "@babel/types": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "esutils": "^2.0.2", - "lodash": "^4.17.13", - "to-fast-properties": "^2.0.0" - } - }, - "debug": { - "version": "4.1.1", - "bundled": true, - "dev": true, - "requires": { - "ms": "^2.1.1" - } - }, - "ms": { - "version": "2.1.2", - "bundled": true, - "dev": true - }, - "source-map": { - "version": "0.5.7", - "bundled": true, - "dev": true - } - } - }, - "@babel/highlight": { - "version": "7.5.0", - "bundled": true, - "requires": { - "chalk": "^2.0.0", - "esutils": "^2.0.2", - "js-tokens": "^4.0.0" - }, - "dependencies": { - "js-tokens": { - "version": "4.0.0", - "bundled": true - } - } - }, - "@babel/parser": { - "version": "7.7.3", - "bundled": true - }, - "@babel/plugin-proposal-object-rest-spread": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.0.0", - "@babel/plugin-syntax-object-rest-spread": "^7.7.4" - } - }, - "@babel/plugin-syntax-jsx": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.0.0" - } - }, - "@babel/plugin-syntax-object-rest-spread": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.0.0" - } - }, - "@babel/plugin-transform-destructuring": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.0.0" - } - }, - "@babel/plugin-transform-react-jsx": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-builder-react-jsx": "^7.7.4", - "@babel/helper-plugin-utils": "^7.0.0", - "@babel/plugin-syntax-jsx": "^7.7.4" - } - }, - "@babel/runtime": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "regenerator-runtime": "^0.13.2" - } - }, - "@babel/template": { - "version": "7.7.0", - "bundled": true, - "requires": { - "@babel/code-frame": "^7.0.0", - "@babel/parser": "^7.7.0", - "@babel/types": "^7.7.0" - } - }, - "@babel/types": { - "version": "7.7.2", - "bundled": true, - "requires": { - "esutils": "^2.0.2", - "lodash": "^4.17.13", - "to-fast-properties": "^2.0.0" - } - }, - "@types/color-name": { - "version": "1.1.1", - "bundled": true, - "dev": true - }, - "@types/prop-types": { - "version": "15.7.3", - "bundled": true, - "dev": true - }, - "@types/react": { - "version": "16.9.13", - "bundled": true, - "dev": true, - "requires": { - "@types/prop-types": "*", - "csstype": "^2.2.0" - } - }, - "ansi-escapes": { - "version": "4.3.0", - "bundled": true, - "dev": true, - "requires": { - "type-fest": "^0.8.1" - } - }, - "ansi-regex": { - "version": "2.1.1", - "bundled": true - }, - "ansi-styles": { - "version": "3.2.1", - "bundled": true, - "requires": { - "color-convert": "^1.9.0" - } - }, - "ansicolors": { - "version": "0.3.2", - "bundled": true, - "dev": true - }, - "arrify": { - "version": "1.0.1", - "bundled": true, - "dev": true - }, - "astral-regex": { - "version": "1.0.0", - "bundled": true, - "dev": true - }, - "auto-bind": { - "version": "2.1.1", - "bundled": true, - "dev": true, - "requires": { - "@types/react": "^16.8.12" - } - }, - "caller-callsite": { - "version": "2.0.0", - "bundled": true, - "dev": true, - "requires": { - "callsites": "^2.0.0" - } - }, - "caller-path": { - "version": "2.0.0", - "bundled": true, - "dev": true, - "requires": { - "caller-callsite": "^2.0.0" - } - }, - "callsites": { - "version": "2.0.0", - "bundled": true, - "dev": true - }, - "cardinal": { - "version": "2.1.1", - "bundled": true, - "dev": true, - "requires": { - "ansicolors": "~0.3.2", - "redeyed": "~2.1.0" - } - }, - "chalk": { - "version": "2.4.2", - "bundled": true, - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - } - }, - "ci-info": { - "version": "2.0.0", - "bundled": true, - "dev": true - }, - "cli-cursor": { - "version": "2.1.0", - "bundled": true, - "dev": true, - "requires": { - "restore-cursor": "^2.0.0" - } - }, - "cli-truncate": { - "version": "1.1.0", - "bundled": true, - "dev": true, - "requires": { - "slice-ansi": "^1.0.0", - "string-width": "^2.0.0" - } - }, - "color-convert": { - "version": "1.9.3", - "bundled": true, - "requires": { - "color-name": "1.1.3" - } - }, - "color-name": { - "version": "1.1.3", - "bundled": true - }, - "csstype": { - "version": "2.6.7", - "bundled": true, - "dev": true - }, - "debug": { - "version": "2.6.9", - "bundled": true, - "requires": { - "ms": "2.0.0" - } - }, - "emoji-regex": { - "version": "7.0.3", - "bundled": true, - "dev": true - }, - "escape-string-regexp": { - "version": "1.0.5", - "bundled": true - }, - "esprima": { - "version": "4.0.1", - "bundled": true, - "dev": true - }, - "esutils": { - "version": "2.0.3", - "bundled": true - }, - "events-to-array": { - "version": "1.1.2", - "bundled": true, - "dev": true - }, - "globals": { - "version": "11.12.0", - "bundled": true, - "dev": true - }, - "has-flag": { - "version": "3.0.0", - "bundled": true - }, - "import-jsx": { - "version": "3.0.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/core": "^7.5.5", - "@babel/plugin-proposal-object-rest-spread": "^7.5.5", - "@babel/plugin-transform-destructuring": "^7.5.0", - "@babel/plugin-transform-react-jsx": "^7.3.0", - "caller-path": "^2.0.0", - "resolve-from": "^3.0.0" - } - }, - "ink": { - "version": "2.5.0", - "bundled": true, - "dev": true, - "requires": { - "@types/react": "^16.8.6", - "ansi-escapes": "^4.2.1", - "arrify": "^1.0.1", - "auto-bind": "^2.0.0", - "chalk": "^2.4.1", - "cli-cursor": "^2.1.0", - "cli-truncate": "^1.1.0", - "is-ci": "^2.0.0", - "lodash.throttle": "^4.1.1", - "log-update": "^3.0.0", - "prop-types": "^15.6.2", - "react-reconciler": "^0.21.0", - "scheduler": "^0.15.0", - "signal-exit": "^3.0.2", - "slice-ansi": "^1.0.0", - "string-length": "^2.0.0", - "widest-line": "^2.0.0", - "wrap-ansi": "^5.0.0", - "yoga-layout-prebuilt": "^1.9.3" - } - }, - "is-ci": { - "version": "2.0.0", - "bundled": true, - "dev": true, - "requires": { - "ci-info": "^2.0.0" - } - }, - "is-fullwidth-code-point": { - "version": "2.0.0", - "bundled": true, - "dev": true - }, - "js-tokens": { - "version": "3.0.2", - "bundled": true, - "dev": true - }, - "jsesc": { - "version": "2.5.2", - "bundled": true - }, - "json5": { - "version": "2.1.1", - "bundled": true, - "dev": true, - "requires": { - "minimist": "^1.2.0" - } - }, - "lodash": { - "version": "4.17.15", - "bundled": true - }, - "lodash.throttle": { - "version": "4.1.1", - "bundled": true, - "dev": true - }, - "log-update": { - "version": "3.3.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-escapes": "^3.2.0", - "cli-cursor": "^2.1.0", - "wrap-ansi": "^5.0.0" - }, - "dependencies": { - "ansi-escapes": { - "version": "3.2.0", - "bundled": true, - "dev": true - } - } - }, - "loose-envify": { - "version": "1.4.0", - "bundled": true, - "dev": true, - "requires": { - "js-tokens": "^3.0.0 || ^4.0.0" - } - }, - "mimic-fn": { - "version": "1.2.0", - "bundled": true, - "dev": true - }, - "minimist": { - "version": "1.2.0", - "bundled": true, - "dev": true - }, - "minipass": { - "version": "3.1.1", - "bundled": true, - "dev": true, - "requires": { - "yallist": "^4.0.0" - }, - "dependencies": { - "yallist": { - "version": "4.0.0", - "bundled": true, - "dev": true - } - } - }, - "ms": { - "version": "2.0.0", - "bundled": true - }, - "object-assign": { - "version": "4.1.1", - "bundled": true, - "dev": true - }, - "onetime": { - "version": "2.0.1", - "bundled": true, - "dev": true, - "requires": { - "mimic-fn": "^1.0.0" - } - }, - "path-parse": { - "version": "1.0.6", - "bundled": true, - "dev": true - }, - "prop-types": { - "version": "15.7.2", - "bundled": true, - "dev": true, - "requires": { - "loose-envify": "^1.4.0", - "object-assign": "^4.1.1", - "react-is": "^16.8.1" - } - }, - "punycode": { - "version": "2.1.1", - "bundled": true, - "dev": true - }, - "react-is": { - "version": "16.10.2", - "bundled": true, - "dev": true - }, - "react-reconciler": { - "version": "0.21.0", - "bundled": true, - "dev": true, - "requires": { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1", - "prop-types": "^15.6.2", - "scheduler": "^0.15.0" - } - }, - "redeyed": { - "version": "2.1.1", - "bundled": true, - "dev": true, - "requires": { - "esprima": "~4.0.0" - } - }, - "regenerator-runtime": { - "version": "0.13.3", - "bundled": true, - "dev": true - }, - "resolve": { - "version": "1.12.0", - "bundled": true, - "dev": true, - "requires": { - "path-parse": "^1.0.6" - } - }, - "resolve-from": { - "version": "3.0.0", - "bundled": true, - "dev": true - }, - "restore-cursor": { - "version": "2.0.0", - "bundled": true, - "dev": true, - "requires": { - "onetime": "^2.0.0", - "signal-exit": "^3.0.2" - } - }, - "scheduler": { - "version": "0.15.0", - "bundled": true, - "dev": true, - "requires": { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1" - } - }, - "semver": { - "version": "5.7.1", - "bundled": true, - "dev": true - }, - "signal-exit": { - "version": "3.0.2", - "bundled": true, - "dev": true - }, - "slice-ansi": { - "version": "1.0.0", - "bundled": true, - "dev": true, - "requires": { - "is-fullwidth-code-point": "^2.0.0" - } - }, - "source-map": { - "version": "0.6.1", - "bundled": true - }, - "string-length": { - "version": "2.0.0", - "bundled": true, - "dev": true, - "requires": { - "astral-regex": "^1.0.0", - "strip-ansi": "^4.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "3.0.0", - "bundled": true, - "dev": true - }, - "strip-ansi": { - "version": "4.0.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-regex": "^3.0.0" - } - } - } - }, - "string-width": { - "version": "2.1.1", - "bundled": true, - "dev": true, - "requires": { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "3.0.0", - "bundled": true, - "dev": true - }, - "strip-ansi": { - "version": "4.0.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-regex": "^3.0.0" - } - } - } - }, - "strip-ansi": { - "version": "3.0.1", - "bundled": true, - "requires": { - "ansi-regex": "^2.0.0" - } - }, - "supports-color": { - "version": "5.5.0", - "bundled": true, - "requires": { - "has-flag": "^3.0.0" - } - }, - "tap-parser": { - "version": "10.0.1", - "bundled": true, - "dev": true, - "requires": { - "events-to-array": "^1.0.1", - "minipass": "^3.0.0", - "tap-yaml": "^1.0.0" - } - }, - "tap-yaml": { - "version": "1.0.0", - "bundled": true, - "dev": true, - "requires": { - "yaml": "^1.5.0" - } - }, - "to-fast-properties": { - "version": "2.0.0", - "bundled": true - }, - "treport": { - "version": "1.0.0", - "bundled": true, - "dev": true, - "requires": { - "cardinal": "^2.1.1", - "chalk": "^3.0.0", - "import-jsx": "^3.0.0", - "ink": "^2.5.0", - "ms": "^2.1.2", - "string-length": "^3.1.0", - "tap-parser": "^10.0.1", - "unicode-length": "^2.0.2" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "bundled": true, - "dev": true - }, - "ansi-styles": { - "version": "4.2.0", - "bundled": true, - "dev": true, - "requires": { - "@types/color-name": "^1.1.1", - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "3.0.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "bundled": true, - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "bundled": true, - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "bundled": true, - "dev": true - }, - "ms": { - "version": "2.1.2", - "bundled": true, - "dev": true - }, - "string-length": { - "version": "3.1.0", - "bundled": true, - "dev": true, - "requires": { - "astral-regex": "^1.0.0", - "strip-ansi": "^5.2.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - }, - "supports-color": { - "version": "7.1.0", - "bundled": true, - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - }, - "unicode-length": { - "version": "2.0.2", - "bundled": true, - "dev": true, - "requires": { - "punycode": "^2.0.0", - "strip-ansi": "^3.0.1" - }, - "dependencies": { - "ansi-regex": { - "version": "2.1.1", - "bundled": true, - "dev": true - }, - "strip-ansi": { - "version": "3.0.1", - "bundled": true, - "dev": true, - "requires": { - "ansi-regex": "^2.0.0" - } - } - } - } - } - }, - "type-fest": { - "version": "0.8.1", - "bundled": true, - "dev": true - }, - "widest-line": { - "version": "2.0.1", - "bundled": true, - "dev": true, - "requires": { - "string-width": "^2.1.1" - } - }, - "wrap-ansi": { - "version": "5.1.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^3.2.0", - "string-width": "^3.0.0", - "strip-ansi": "^5.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "bundled": true, - "dev": true - }, - "string-width": { - "version": "3.1.0", - "bundled": true, - "dev": true, - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - } - } - }, - "yaml": { - "version": "1.7.2", - "bundled": true, - "dev": true, - "requires": { - "@babel/runtime": "^7.6.3" - } - }, - "yoga-layout-prebuilt": { - "version": "1.9.3", - "bundled": true, - "dev": true - } - } - }, - "tap-mocha-reporter": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/tap-mocha-reporter/-/tap-mocha-reporter-5.0.0.tgz", - "integrity": "sha512-8HlAtdmYGlDZuW83QbF/dc46L7cN+AGhLZcanX3I9ILvxUAl+G2/mtucNPSXecTlG/4iP1hv6oMo0tMhkn3Tsw==", - "dev": true, - "requires": { - "color-support": "^1.1.0", - "debug": "^2.1.3", - "diff": "^1.3.2", - "escape-string-regexp": "^1.0.3", - "glob": "^7.0.5", - "readable-stream": "^2.1.5", - "tap-parser": "^10.0.0", - "tap-yaml": "^1.0.0", - "unicode-length": "^1.0.0" - }, - "dependencies": { - "debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", - "dev": true, - "requires": { - "ms": "2.0.0" - } - }, - "diff": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-1.4.0.tgz", - "integrity": "sha1-fyjS657nsVqX79ic5j3P2qPMur8=", - "dev": true - }, - "ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", - "dev": true - } - } - }, - "tap-parser": { - "version": "10.0.1", - "resolved": "https://registry.npmjs.org/tap-parser/-/tap-parser-10.0.1.tgz", - "integrity": "sha512-qdT15H0DoJIi7zOqVXDn9X0gSM68JjNy1w3VemwTJlDnETjbi6SutnqmBfjDJAwkFS79NJ97gZKqie00ZCGmzg==", - "dev": true, - "requires": { - "events-to-array": "^1.0.1", - "minipass": "^3.0.0", - "tap-yaml": "^1.0.0" - } - }, - "tap-yaml": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/tap-yaml/-/tap-yaml-1.0.0.tgz", - "integrity": "sha512-Rxbx4EnrWkYk0/ztcm5u3/VznbyFJpyXO12dDBHKWiDVxy7O2Qw6MRrwO5H6Ww0U5YhRY/4C/VzWmFPhBQc4qQ==", - "dev": true, - "requires": { - "yaml": "^1.5.0" - } - }, - "tcompare": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/tcompare/-/tcompare-3.0.4.tgz", - "integrity": "sha512-Q3TitMVK59NyKgQyFh+857wTAUE329IzLDehuPgU4nF5e8g+EUQ+yUbjUy1/6ugiNnXztphT+NnqlCXolv9P3A==", - "dev": true, - "requires": { - "diff-frag": "^1.0.1" - } - }, - "test-exclude": { - "version": "5.2.3", - "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-5.2.3.tgz", - "integrity": "sha512-M+oxtseCFO3EDtAaGH7iiej3CBkzXqFMbzqYAACdzKui4eZA+pq3tZEwChvOdNfa7xxy8BfbmgJSIr43cC/+2g==", - "dev": true, - "requires": { - "glob": "^7.1.3", - "minimatch": "^3.0.4", - "read-pkg-up": "^4.0.0", - "require-main-filename": "^2.0.0" - } - }, - "to-fast-properties": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", - "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", - "dev": true - }, - "to-regex-range": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", - "dev": true, - "requires": { - "is-number": "^7.0.0" - } - }, - "tough-cookie": { - "version": "2.4.3", - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.4.3.tgz", - "integrity": "sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ==", - "dev": true, - "requires": { - "psl": "^1.1.24", - "punycode": "^1.4.1" - }, - "dependencies": { - "punycode": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", - "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", - "dev": true - } - } - }, - "trivial-deferred": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/trivial-deferred/-/trivial-deferred-1.0.1.tgz", - "integrity": "sha1-N21NKdlR1jaKb3oK6FwvTV4GWPM=", - "dev": true - }, - "ts-node": { - "version": "8.5.4", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.5.4.tgz", - "integrity": "sha512-izbVCRV68EasEPQ8MSIGBNK9dc/4sYJJKYA+IarMQct1RtEot6Xp0bXuClsbUSnKpg50ho+aOAx8en5c+y4OFw==", - "dev": true, - "requires": { - "arg": "^4.1.0", - "diff": "^4.0.1", - "make-error": "^1.1.1", - "source-map-support": "^0.5.6", - "yn": "^3.0.0" - } - }, - "tunnel-agent": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", - "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", - "dev": true, - "requires": { - "safe-buffer": "^5.0.1" - } - }, - "tweetnacl": { - "version": "0.14.5", - "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", - "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=", - "dev": true - }, - "typedarray-to-buffer": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz", - "integrity": "sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==", - "dev": true, - "requires": { - "is-typedarray": "^1.0.0" - } - }, - "typescript": { - "version": "3.7.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.7.3.tgz", - "integrity": "sha512-Mcr/Qk7hXqFBXMN7p7Lusj1ktCBydylfQM/FZCk5glCNQJrCUKPkMHdo9R0MTFWsC/4kPFvDS0fDPvukfCkFsw==", - "dev": true - }, - "uglify-js": { - "version": "3.7.2", - "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.7.2.tgz", - "integrity": "sha512-uhRwZcANNWVLrxLfNFEdltoPNhECUR3lc+UdJoG9CBpMcSnKyWA94tc3eAujB1GcMY5Uwq8ZMp4qWpxWYDQmaA==", - "dev": true, - "optional": true, - "requires": { - "commander": "~2.20.3", - "source-map": "~0.6.1" - } - }, - "unicode-length": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/unicode-length/-/unicode-length-1.0.3.tgz", - "integrity": "sha1-Wtp6f+1RhBpBijKM8UlHisg1irs=", - "dev": true, - "requires": { - "punycode": "^1.3.2", - "strip-ansi": "^3.0.1" - }, - "dependencies": { - "ansi-regex": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", - "dev": true - }, - "punycode": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", - "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", - "dev": true - }, - "strip-ansi": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", - "dev": true, - "requires": { - "ansi-regex": "^2.0.0" - } - } - } - }, - "uri-js": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", - "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==", - "dev": true, - "requires": { - "punycode": "^2.1.0" - } - }, - "util-deprecate": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", - "dev": true, - "optional": true - }, - "uuid": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.3.3.tgz", - "integrity": "sha512-pW0No1RGHgzlpHJO1nsVrHKpOEIxkGg1xB+v0ZmdNH5OAeAwzAVrCnI2/6Mtx+Uys6iaylxa+D3g4j63IKKjSQ==", - "dev": true - }, - "validate-npm-package-license": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz", - "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==", - "dev": true, - "requires": { - "spdx-correct": "^3.0.0", - "spdx-expression-parse": "^3.0.0" - } - }, - "verror": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", - "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0", - "core-util-is": "1.0.2", - "extsprintf": "^1.2.0" - } - }, - "vlq": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/vlq/-/vlq-0.2.3.tgz", - "integrity": "sha512-DRibZL6DsNhIgYQ+wNdWDL2SL3bKPlVrRiBqV5yuMm++op8W4kGFtaQfCs4KEJn0wBZcHVHJ3eoywX8983k1ow==", - "dev": true - }, - "which": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", - "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - }, - "which-module": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", - "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", - "dev": true - }, - "wordwrap": { - "version": "0.0.3", - "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.3.tgz", - "integrity": "sha1-o9XabNXAvAAI03I0u68b7WMFkQc=", - "dev": true - }, - "wrap-ansi": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz", - "integrity": "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=", - "dev": true, - "requires": { - "string-width": "^1.0.1", - "strip-ansi": "^3.0.1" - }, - "dependencies": { - "ansi-regex": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", - "dev": true - }, - "is-fullwidth-code-point": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", - "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", - "dev": true, - "requires": { - "number-is-nan": "^1.0.0" - } - }, - "string-width": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", - "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", - "dev": true, - "requires": { - "code-point-at": "^1.0.0", - "is-fullwidth-code-point": "^1.0.0", - "strip-ansi": "^3.0.0" - } - }, - "strip-ansi": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", - "dev": true, - "requires": { - "ansi-regex": "^2.0.0" - } - } - } - }, - "wrappy": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", - "dev": true - }, - "write-file-atomic": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-3.0.1.tgz", - "integrity": "sha512-JPStrIyyVJ6oCSz/691fAjFtefZ6q+fP6tm+OS4Qw6o+TGQxNp1ziY2PgS+X/m0V8OWhZiO/m4xSj+Pr4RrZvw==", - "dev": true, - "requires": { - "imurmurhash": "^0.1.4", - "is-typedarray": "^1.0.0", - "signal-exit": "^3.0.2", - "typedarray-to-buffer": "^3.1.5" - } - }, - "y18n": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", - "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", - "dev": true - }, - "yallist": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz", - "integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=", - "dev": true - }, - "yaml": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.7.2.tgz", - "integrity": "sha512-qXROVp90sb83XtAoqE8bP9RwAkTTZbugRUTm5YeFCBfNRPEp2YzTeqWiz7m5OORHzEvrA/qcGS8hp/E+MMROYw==", - "dev": true, - "requires": { - "@babel/runtime": "^7.6.3" - } - }, - "yapool": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/yapool/-/yapool-1.0.0.tgz", - "integrity": "sha1-9pPymjFbUNmp2iZGp6ZkXJaYW2o=", - "dev": true - }, - "yargs": { - "version": "13.3.0", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.0.tgz", - "integrity": "sha512-2eehun/8ALW8TLoIl7MVaRUrg+yCnenu8B4kBlRxj3GJGDKU1Og7sMXPNm1BYyM1DOJmTZ4YeN/Nwxv+8XJsUA==", - "dev": true, - "requires": { - "cliui": "^5.0.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^13.1.1" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", - "dev": true - }, - "cliui": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", - "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", - "dev": true, - "requires": { - "string-width": "^3.1.0", - "strip-ansi": "^5.2.0", - "wrap-ansi": "^5.1.0" - } - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "dev": true, - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - }, - "wrap-ansi": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", - "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.0", - "string-width": "^3.0.0", - "strip-ansi": "^5.0.0" - } - } - } - }, - "yargs-parser": { - "version": "13.1.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.1.tgz", - "integrity": "sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ==", - "dev": true, - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } - }, - "yn": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", - "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", - "dev": true - } - } -} diff --git a/node_modules/npm-normalize-package-bin/package.json b/node_modules/npm-normalize-package-bin/package.json deleted file mode 100644 index a331a68..0000000 --- a/node_modules/npm-normalize-package-bin/package.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "name": "npm-normalize-package-bin", - "version": "1.0.1", - "description": "Turn any flavor of allowable package.json bin into a normalized object", - "repository": "git+https://github.com/npm/npm-normalize-package-bin", - "author": "Isaac Z. Schlueter <i@izs.me> (https://izs.me)", - "license": "ISC", - "scripts": { - "test": "tap", - "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "postpublish": "git push origin --follow-tags" - }, - "tap": { - "check-coverage": true - }, - "devDependencies": { - "tap": "^14.10.2" - } -} diff --git a/node_modules/npm-normalize-package-bin/test/array.js b/node_modules/npm-normalize-package-bin/test/array.js deleted file mode 100644 index 63dafa8..0000000 --- a/node_modules/npm-normalize-package-bin/test/array.js +++ /dev/null @@ -1,37 +0,0 @@ -const normalize = require('../') -const t = require('tap') - -t.test('benign array', async t => { - const pkg = { name: 'hello', version: 'world', bin: ['./x/y', 'y/z', './a'] } - const expect = { name: 'hello', version: 'world', bin: { - y: 'x/y', - z: 'y/z', - a: 'a', - } } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('conflicting array', async t => { - const pkg = { name: 'hello', version: 'world', bin: ['./x/y', 'z/y', './a'] } - const expect = { name: 'hello', version: 'world', bin: { - y: 'z/y', - a: 'a', - } } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('slashy array', async t => { - const pkg = { name: 'hello', version: 'world', bin: [ '/etc/passwd' ] } - const expect = { name: 'hello', version: 'world', bin: { passwd: 'etc/passwd' } } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('dotty array', async t => { - const pkg = { name: 'hello', version: 'world', bin: ['../../../../etc/passwd'] } - const expect = { name: 'hello', version: 'world', bin: { passwd: 'etc/passwd' } } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) diff --git a/node_modules/npm-normalize-package-bin/test/nobin.js b/node_modules/npm-normalize-package-bin/test/nobin.js deleted file mode 100644 index 536d7eb..0000000 --- a/node_modules/npm-normalize-package-bin/test/nobin.js +++ /dev/null @@ -1,35 +0,0 @@ -const normalize = require('../') -const t = require('tap') - -// all of these just delete the bins, so expect the same value -const expect = { name: 'hello', version: 'world' } - -t.test('no bin in object', async t => { - const pkg = { name: 'hello', version: 'world' } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('empty string bin in object', async t => { - const pkg = { name: 'hello', version: 'world', bin: '' } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('false bin in object', async t => { - const pkg = { name: 'hello', version: 'world', bin: false } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('null bin in object', async t => { - const pkg = { name: 'hello', version: 'world', bin: null } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('number bin', async t => { - const pkg = { name: 'hello', version: 'world', bin: 42069 } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) diff --git a/node_modules/npm-normalize-package-bin/test/object.js b/node_modules/npm-normalize-package-bin/test/object.js deleted file mode 100644 index 00d2368..0000000 --- a/node_modules/npm-normalize-package-bin/test/object.js +++ /dev/null @@ -1,141 +0,0 @@ -const normalize = require('../') -const t = require('tap') - -t.test('benign object', async t => { - // just clean up the ./ in the targets and remove anything weird - const pkg = { name: 'hello', version: 'world', bin: { - y: './x/y', - z: './y/z', - a: './a', - } } - const expect = { name: 'hello', version: 'world', bin: { - y: 'x/y', - z: 'y/z', - a: 'a', - } } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('empty and non-string targets', async t => { - // just clean up the ./ in the targets and remove anything weird - const pkg = { name: 'hello', version: 'world', bin: { - z: './././', - y: '', - './x': 'x.js', - re: /asdf/, - foo: { bar: 'baz' }, - false: false, - null: null, - array: [1,2,3], - func: function () {}, - } } - const expect = { name: 'hello', version: 'world', bin: { - x: 'x.js', - } } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('slashy object', async t => { - const pkg = { name: 'hello', version: 'world', bin: { - '/path/foo': '/etc/passwd', - 'bar': '/etc/passwd', - '/etc/glorb/baz': '/etc/passwd', - '/etc/passwd:/bin/usr/exec': '/etc/passwd', - } } - const expect = { - name: 'hello', - version: 'world', - bin: { - foo: 'etc/passwd', - bar: 'etc/passwd', - baz: 'etc/passwd', - exec: 'etc/passwd', - } - } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('dotty object', async t => { - const pkg = { - name: 'hello', - version: 'world', - bin: { - 'nodots': '../../../../etc/passwd', - '../../../../../../dots': '../../../../etc/passwd', - '.././../\\./..//C:\\./': 'this is removed', - '.././../\\./..//C:\\/': 'super safe programming language', - '.././../\\./..//C:\\x\\y\\z/': 'xyz', - } } - const expect = { name: 'hello', version: 'world', bin: { - nodots: 'etc/passwd', - dots: 'etc/passwd', - C: 'super safe programming language', - z: 'xyz', - } } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('weird object', async t => { - const pkg = { name: 'hello', version: 'world', bin: /asdf/ } - const expect = { name: 'hello', version: 'world' } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('oddball keys', async t => { - const pkg = { - bin: { - '~': 'target', - '£': 'target', - 'ζ': 'target', - 'ぎ': 'target', - '操': 'target', - '🎱': 'target', - '💎': 'target', - '💸': 'target', - '🦉': 'target', - 'сheck-dom': 'target', - 'Ωpm': 'target', - 'ζλ': 'target', - 'мга': 'target', - 'пше': 'target', - 'тзч': 'target', - 'тзь': 'target', - 'нфкт': 'target', - 'ссср': 'target', - '君の名は': 'target', - '君の名は': 'target', - } - } - - const expect = { - bin: { - '~': 'target', - '£': 'target', - 'ζ': 'target', - 'ぎ': 'target', - '操': 'target', - '🎱': 'target', - '💎': 'target', - '💸': 'target', - '🦉': 'target', - 'сheck-dom': 'target', - 'Ωpm': 'target', - 'ζλ': 'target', - 'мга': 'target', - 'пше': 'target', - 'тзч': 'target', - 'тзь': 'target', - 'нфкт': 'target', - 'ссср': 'target', - '君の名は': 'target', - }, - } - - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) diff --git a/node_modules/npm-normalize-package-bin/test/string.js b/node_modules/npm-normalize-package-bin/test/string.js deleted file mode 100644 index b6de8f8..0000000 --- a/node_modules/npm-normalize-package-bin/test/string.js +++ /dev/null @@ -1,37 +0,0 @@ -const normalize = require('../') -const t = require('tap') - -t.test('benign string', async t => { - const pkg = { name: 'hello', version: 'world', bin: 'hello.js' } - const expect = { name: 'hello', version: 'world', bin: { hello: 'hello.js' } } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('slashy string', async t => { - const pkg = { name: 'hello', version: 'world', bin: '/etc/passwd' } - const expect = { name: 'hello', version: 'world', bin: { hello: 'etc/passwd' } } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('dotty string', async t => { - const pkg = { name: 'hello', version: 'world', bin: '../../../../etc/passwd' } - const expect = { name: 'hello', version: 'world', bin: { hello: 'etc/passwd' } } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('double path', async t => { - const pkg = { name: 'hello', version: 'world', bin: '/etc/passwd:/bin/usr/exec' } - const expect = { name: 'hello', version: 'world', bin: { hello: 'etc/passwd:/bin/usr/exec' } } - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) - -t.test('string with no name', async t => { - const pkg = { bin: 'foobar.js' } - const expect = {} - t.strictSame(normalize(pkg), expect) - t.strictSame(normalize(normalize(pkg)), expect, 'double sanitize ok') -}) diff --git a/node_modules/npm-packlist/bin/index.js b/node_modules/npm-packlist/bin/index.js deleted file mode 100755 index 40811db..0000000 --- a/node_modules/npm-packlist/bin/index.js +++ /dev/null @@ -1,25 +0,0 @@ -#!/usr/bin/env node - -const dirs = [] -let doSort = false -process.argv.slice(2).forEach(arg => { - if (arg === '-h' || arg === '--help') { - console.log('usage: npm-packlist [-s --sort] [directory, directory, ...]') - process.exit(0) - } else if (arg === '-s' || arg === '--sort') - doSort = true - else - dirs.push(arg) -}) - -const sort = list => doSort ? list.sort((a, b) => a.localeCompare(b, 'en')) : list - -const packlist = require('../') -if (!dirs.length) - console.log(sort(packlist.sync({ path: process.cwd() })).join('\n')) -else { - dirs.forEach(path => { - console.log(`> ${path}`) - console.log(sort(packlist.sync({ path })).join('\n')) - }) -} diff --git a/node_modules/npm-packlist/index.js b/node_modules/npm-packlist/index.js deleted file mode 100644 index 7601855..0000000 --- a/node_modules/npm-packlist/index.js +++ /dev/null @@ -1,481 +0,0 @@ -'use strict' - -// Do a two-pass walk, first to get the list of packages that need to be -// bundled, then again to get the actual files and folders. -// Keep a cache of node_modules content and package.json data, so that the -// second walk doesn't have to re-do all the same work. - -const bundleWalk = require('npm-bundled') -const BundleWalker = bundleWalk.BundleWalker -const BundleWalkerSync = bundleWalk.BundleWalkerSync - -const ignoreWalk = require('ignore-walk') -const IgnoreWalker = ignoreWalk.Walker -const IgnoreWalkerSync = ignoreWalk.WalkerSync - -const rootBuiltinRules = Symbol('root-builtin-rules') -const packageNecessaryRules = Symbol('package-necessary-rules') -const path = require('path') - -const normalizePackageBin = require('npm-normalize-package-bin') - -// Weird side-effect of this: a readme (etc) file will be included -// if it exists anywhere within a folder with a package.json file. -// The original intent was only to include these files in the root, -// but now users in the wild are dependent on that behavior for -// localized documentation and other use cases. Adding a `/` to -// these rules, while tempting and arguably more "correct", is a -// significant change that will break existing use cases. -const packageMustHaveFileNames = 'readme|copying|license|licence' - -const packageMustHaves = `@(${packageMustHaveFileNames}){,.*[^~$]}` -const packageMustHavesRE = new RegExp(`^(${packageMustHaveFileNames})(\\..*[^~$])?$`, 'i') - -const fs = require('fs') -const glob = require('glob') - -const defaultRules = [ - '.npmignore', - '.gitignore', - '**/.git', - '**/.svn', - '**/.hg', - '**/CVS', - '**/.git/**', - '**/.svn/**', - '**/.hg/**', - '**/CVS/**', - '/.lock-wscript', - '/.wafpickle-*', - '/build/config.gypi', - 'npm-debug.log', - '**/.npmrc', - '.*.swp', - '.DS_Store', - '**/.DS_Store/**', - '._*', - '**/._*/**', - '*.orig', - '/package-lock.json', - '/yarn.lock', - '/archived-packages/**', -] - -// There may be others, but :?|<> are handled by node-tar -const nameIsBadForWindows = file => /\*/.test(file) - -// a decorator that applies our custom rules to an ignore walker -const npmWalker = Class => class Walker extends Class { - constructor (opt) { - opt = opt || {} - - // the order in which rules are applied. - opt.ignoreFiles = [ - rootBuiltinRules, - 'package.json', - '.npmignore', - '.gitignore', - packageNecessaryRules, - ] - - opt.includeEmpty = false - opt.path = opt.path || process.cwd() - - // only follow links in the root node_modules folder, because if those - // folders are included, it's because they're bundled, and bundles - // should include the contents, not the symlinks themselves. - // This regexp tests to see that we're either a node_modules folder, - // or a @scope within a node_modules folder, in the root's node_modules - // hierarchy (ie, not in test/foo/node_modules/ or something). - const followRe = /^(?:\/node_modules\/(?:@[^/]+\/[^/]+|[^/]+)\/)*\/node_modules(?:\/@[^/]+)?$/ - const rootPath = opt.parent ? opt.parent.root : opt.path - const followTestPath = opt.path.replace(/\\/g, '/').substr(rootPath.length) - opt.follow = followRe.test(followTestPath) - - super(opt) - - // ignore a bunch of things by default at the root level. - // also ignore anything in the main project node_modules hierarchy, - // except bundled dependencies - if (this.isProject) { - this.bundled = opt.bundled || [] - this.bundledScopes = Array.from(new Set( - this.bundled.filter(f => /^@/.test(f)) - .map(f => f.split('/')[0]))) - const rules = defaultRules.join('\n') + '\n' - this.packageJsonCache = this.parent ? this.parent.packageJsonCache - : (opt.packageJsonCache || new Map()) - super.onReadIgnoreFile(rootBuiltinRules, rules, _ => _) - } else { - this.bundled = [] - this.bundledScopes = [] - this.packageJsonCache = this.parent.packageJsonCache - } - } - - get isProject () { - return !this.parent || this.parent.follow && this.isSymbolicLink - } - - onReaddir (entries) { - if (this.isProject) { - entries = entries.filter(e => - e !== '.git' && - !(e === 'node_modules' && this.bundled.length === 0) - ) - } - - // if we have a package.json, then look in it for 'files' - // we _only_ do this in the root project, not bundled deps - // or other random folders. Bundled deps are always assumed - // to be in the state the user wants to include them, and - // a package.json somewhere else might be a template or - // test or something else entirely. - if (!this.isProject || !entries.includes('package.json')) { - return super.onReaddir(entries) - } - - // when the cache has been seeded with the root manifest, - // we must respect that (it may differ from the filesystem) - const ig = path.resolve(this.path, 'package.json') - - if (this.packageJsonCache.has(ig)) { - const pkg = this.packageJsonCache.get(ig) - - // fall back to filesystem when seeded manifest is invalid - if (!pkg || typeof pkg !== 'object') { - return this.readPackageJson(entries) - } - - // feels wonky, but this ensures package bin is _always_ - // normalized, as well as guarding against invalid JSON - return this.getPackageFiles(entries, JSON.stringify(pkg)) - } - - this.readPackageJson(entries) - } - - onReadPackageJson (entries, er, pkg) { - if (er) { - this.emit('error', er) - } else { - this.getPackageFiles(entries, pkg) - } - } - - mustHaveFilesFromPackage (pkg) { - const files = [] - if (pkg.browser) { - files.push('/' + pkg.browser) - } - if (pkg.main) { - files.push('/' + pkg.main) - } - if (pkg.bin) { - // always an object because normalized already - for (const key in pkg.bin) { - files.push('/' + pkg.bin[key]) - } - } - files.push( - '/package.json', - '/npm-shrinkwrap.json', - '!/package-lock.json', - packageMustHaves - ) - return files - } - - getPackageFiles (entries, pkg) { - try { - // XXX this could be changed to use read-package-json-fast - // which handles the normalizing of bins for us, and simplifies - // the test for bundleDependencies and bundledDependencies later. - // HOWEVER if we do this, we need to be sure that we're careful - // about what we write back out since rpj-fast removes some fields - // that the user likely wants to keep. it also would add a second - // file read that we would want to optimize away. - pkg = normalizePackageBin(JSON.parse(pkg.toString())) - } catch (er) { - // not actually a valid package.json - return super.onReaddir(entries) - } - - const ig = path.resolve(this.path, 'package.json') - this.packageJsonCache.set(ig, pkg) - - // no files list, just return the normal readdir() result - if (!Array.isArray(pkg.files)) { - return super.onReaddir(entries) - } - - pkg.files.push(...this.mustHaveFilesFromPackage(pkg)) - - // If the package has a files list, then it's unlikely to include - // node_modules, because why would you do that? but since we use - // the files list as the effective readdir result, that means it - // looks like we don't have a node_modules folder at all unless we - // include it here. - if ((pkg.bundleDependencies || pkg.bundledDependencies) && entries.includes('node_modules')) { - pkg.files.push('node_modules') - } - - const patterns = Array.from(new Set(pkg.files)).reduce((set, pattern) => { - const excl = pattern.match(/^!+/) - if (excl) { - pattern = pattern.substr(excl[0].length) - } - // strip off any / from the start of the pattern. /foo => foo - pattern = pattern.replace(/^\/+/, '') - // an odd number of ! means a negated pattern. !!foo ==> foo - const negate = excl && excl[0].length % 2 === 1 - set.push({ pattern, negate }) - return set - }, []) - - let n = patterns.length - const set = new Set() - const negates = new Set() - const results = [] - const then = (pattern, negate, er, fileList, i) => { - if (er) { - return this.emit('error', er) - } - - results[i] = { negate, fileList } - if (--n === 0) { - processResults(results) - } - } - const processResults = results => { - for (const {negate, fileList} of results) { - if (negate) { - fileList.forEach(f => { - f = f.replace(/\/+$/, '') - set.delete(f) - negates.add(f) - }) - } else { - fileList.forEach(f => { - f = f.replace(/\/+$/, '') - set.add(f) - negates.delete(f) - }) - } - } - - const list = Array.from(set) - // replace the files array with our computed explicit set - pkg.files = list.concat(Array.from(negates).map(f => '!' + f)) - const rdResult = Array.from(new Set( - list.map(f => f.replace(/^\/+/, '')) - )) - super.onReaddir(rdResult) - } - - // maintain the index so that we process them in-order only once all - // are completed, otherwise the parallelism messes things up, since a - // glob like **/*.js will always be slower than a subsequent !foo.js - patterns.forEach(({pattern, negate}, i) => - this.globFiles(pattern, (er, res) => then(pattern, negate, er, res, i))) - } - - filterEntry (entry, partial) { - // get the partial path from the root of the walk - const p = this.path.substr(this.root.length + 1) - const pkgre = /^node_modules\/(@[^/]+\/?[^/]+|[^/]+)(\/.*)?$/ - const { isProject } = this - const pkg = isProject && pkgre.test(entry) ? - entry.replace(pkgre, '$1') : null - const rootNM = isProject && entry === 'node_modules' - const rootPJ = isProject && entry === 'package.json' - - return ( - // if we're in a bundled package, check with the parent. - /^node_modules($|\/)/i.test(p) && !this.isProject ? this.parent.filterEntry( - this.basename + '/' + entry, partial) - - // if package is bundled, all files included - // also include @scope dirs for bundled scoped deps - // they'll be ignored if no files end up in them. - // However, this only matters if we're in the root. - // node_modules folders elsewhere, like lib/node_modules, - // should be included normally unless ignored. - : pkg ? this.bundled.indexOf(pkg) !== -1 || - this.bundledScopes.indexOf(pkg) !== -1 - - // only walk top node_modules if we want to bundle something - : rootNM ? !!this.bundled.length - - // always include package.json at the root. - : rootPJ ? true - - // always include readmes etc in any included dir - : packageMustHavesRE.test(entry) ? true - - // npm-shrinkwrap and package.json always included in the root pkg - : isProject && (entry === 'npm-shrinkwrap.json' || entry === 'package.json') - ? true - - // package-lock never included - : isProject && entry === 'package-lock.json' ? false - - // otherwise, follow ignore-walk's logic - : super.filterEntry(entry, partial) - ) - } - - filterEntries () { - if (this.ignoreRules['.npmignore']) { - this.ignoreRules['.gitignore'] = null - } - this.filterEntries = super.filterEntries - super.filterEntries() - } - - addIgnoreFile (file, then) { - const ig = path.resolve(this.path, file) - if (file === 'package.json' && !this.isProject) { - then() - } else if (this.packageJsonCache.has(ig)) { - this.onPackageJson(ig, this.packageJsonCache.get(ig), then) - } else { - super.addIgnoreFile(file, then) - } - } - - onPackageJson (ig, pkg, then) { - this.packageJsonCache.set(ig, pkg) - - if (Array.isArray(pkg.files)) { - // in this case we already included all the must-haves - super.onReadIgnoreFile('package.json', pkg.files.map( - f => '!' + f - ).join('\n') + '\n', then) - } else { - // if there's a bin, browser or main, make sure we don't ignore it - // also, don't ignore the package.json itself, or any files that - // must be included in the package. - const rules = this.mustHaveFilesFromPackage(pkg).map(f => `!${f}`) - const data = rules.join('\n') + '\n' - super.onReadIgnoreFile(packageNecessaryRules, data, then) - } - } - - // override parent stat function to completely skip any filenames - // that will break windows entirely. - // XXX(isaacs) Next major version should make this an error instead. - stat ({ entry, file, dir }, then) { - if (nameIsBadForWindows(entry)) { - then() - } else { - super.stat({ entry, file, dir }, then) - } - } - - // override parent onstat function to nix all symlinks, other than - // those coming out of the followed bundled symlink deps - onstat ({ st, entry, file, dir, isSymbolicLink }, then) { - if (st.isSymbolicLink()) { - then() - } else { - super.onstat({ st, entry, file, dir, isSymbolicLink }, then) - } - } - - onReadIgnoreFile (file, data, then) { - if (file === 'package.json') { - try { - const ig = path.resolve(this.path, file) - this.onPackageJson(ig, JSON.parse(data), then) - } catch (er) { - // ignore package.json files that are not json - then() - } - } else { - super.onReadIgnoreFile(file, data, then) - } - } - - sort (a, b) { - return sort(a, b) - } -} - -class Walker extends npmWalker(IgnoreWalker) { - globFiles (pattern, cb) { - glob(pattern, { dot: true, cwd: this.path, nocase: true }, cb) - } - - readPackageJson (entries) { - fs.readFile(this.path + '/package.json', (er, pkg) => - this.onReadPackageJson(entries, er, pkg)) - } - - walker (entry, opt, then) { - new Walker(this.walkerOpt(entry, opt)).on('done', then).start() - } -} - -class WalkerSync extends npmWalker(IgnoreWalkerSync) { - globFiles (pattern, cb) { - cb(null, glob.sync(pattern, { dot: true, cwd: this.path, nocase: true })) - } - - readPackageJson (entries) { - const p = this.path + '/package.json' - try { - this.onReadPackageJson(entries, null, fs.readFileSync(p)) - } catch (er) { - this.onReadPackageJson(entries, er) - } - } - - walker (entry, opt, then) { - new WalkerSync(this.walkerOpt(entry, opt)).start() - then() - } -} - -const walk = (options, callback) => { - options = options || {} - const p = new Promise((resolve, reject) => { - const bw = new BundleWalker(options) - bw.on('done', bundled => { - options.bundled = bundled - options.packageJsonCache = bw.packageJsonCache - new Walker(options).on('done', resolve).on('error', reject).start() - }) - bw.start() - }) - return callback ? p.then(res => callback(null, res), callback) : p -} - -const walkSync = options => { - options = options || {} - const bw = new BundleWalkerSync(options).start() - options.bundled = bw.result - options.packageJsonCache = bw.packageJsonCache - const walker = new WalkerSync(options) - walker.start() - return walker.result -} - -// optimize for compressibility -// extname, then basename, then locale alphabetically -// https://twitter.com/isntitvacant/status/1131094910923231232 -const sort = (a, b) => { - const exta = path.extname(a).toLowerCase() - const extb = path.extname(b).toLowerCase() - const basea = path.basename(a).toLowerCase() - const baseb = path.basename(b).toLowerCase() - - return exta.localeCompare(extb, 'en') || - basea.localeCompare(baseb, 'en') || - a.localeCompare(b, 'en') -} - -module.exports = walk -walk.sync = walkSync -walk.Walker = Walker -walk.WalkerSync = WalkerSync diff --git a/node_modules/npm-packlist/lib/index.js b/node_modules/npm-packlist/lib/index.js new file mode 100644 index 0000000..887018b --- /dev/null +++ b/node_modules/npm-packlist/lib/index.js @@ -0,0 +1,457 @@ +'use strict' + +const { Walker: IgnoreWalker } = require('ignore-walk') +const { lstatSync: lstat, readFileSync: readFile } = require('fs') +const { basename, dirname, extname, join, relative, resolve, sep } = require('path') + +// symbols used to represent synthetic rule sets +const defaultRules = Symbol('npm-packlist.rules.default') +const strictRules = Symbol('npm-packlist.rules.strict') + +// There may be others, but :?|<> are handled by node-tar +const nameIsBadForWindows = file => /\*/.test(file) + +// these are the default rules that are applied to everything except for non-link bundled deps +const defaults = [ + '.npmignore', + '.gitignore', + '**/.git', + '**/.svn', + '**/.hg', + '**/CVS', + '**/.git/**', + '**/.svn/**', + '**/.hg/**', + '**/CVS/**', + '/.lock-wscript', + '/.wafpickle-*', + '/build/config.gypi', + 'npm-debug.log', + '**/.npmrc', + '.*.swp', + '.DS_Store', + '**/.DS_Store/**', + '._*', + '**/._*/**', + '*.orig', + '/archived-packages/**', +] + +const strictDefaults = [ + // these are forcibly included at all levels + '!/readme{,.*[^~$]}', + '!/copying{,.*[^~$]}', + '!/license{,.*[^~$]}', + '!/licence{,.*[^~$]}', + // these are forcibly excluded + '/.git', +] + +const normalizePath = (path) => path.split('\\').join('/') + +const readOutOfTreeIgnoreFiles = (root, rel, result = []) => { + for (const file of ['.npmignore', '.gitignore']) { + try { + const ignoreContent = readFile(join(root, file), { encoding: 'utf8' }) + result.push(ignoreContent) + // break the loop immediately after reading, this allows us to prioritize + // the .npmignore and discard the .gitignore if one is present + break + } catch (err) { + // we ignore ENOENT errors completely because we don't care if the file doesn't exist + // but we throw everything else because failing to read a file that does exist is + // something that the user likely wants to know about + // istanbul ignore next -- we do not need to test a thrown error + if (err.code !== 'ENOENT') { + throw err + } + } + } + + if (!rel) { + return result + } + + const firstRel = rel.split(sep, 1)[0] + const newRoot = join(root, firstRel) + const newRel = relative(newRoot, join(root, rel)) + + return readOutOfTreeIgnoreFiles(newRoot, newRel, result) +} + +class PackWalker extends IgnoreWalker { + constructor (tree, opts) { + const options = { + ...opts, + includeEmpty: false, + follow: false, + // we path.resolve() here because ignore-walk doesn't do it and we want full paths + path: resolve(opts?.path || tree.path).replace(/\\/g, '/'), + ignoreFiles: opts?.ignoreFiles || [ + defaultRules, + 'package.json', + '.npmignore', + '.gitignore', + strictRules, + ], + } + + super(options) + this.isPackage = options.isPackage + this.seen = options.seen || new Set() + this.tree = tree + this.requiredFiles = options.requiredFiles || [] + + const additionalDefaults = [] + if (options.prefix && options.workspaces) { + const path = normalizePath(options.path) + const prefix = normalizePath(options.prefix) + const workspaces = options.workspaces.map((ws) => normalizePath(ws)) + + // istanbul ignore else - this does nothing unless we need it to + if (path !== prefix && workspaces.includes(path)) { + // if path and prefix are not the same directory, and workspaces has path in it + // then we know path is a workspace directory. in order to not drop ignore rules + // from directories between the workspaces root (prefix) and the workspace itself + // (path) we need to find and read those now + const relpath = relative(options.prefix, dirname(options.path)) + additionalDefaults.push(...readOutOfTreeIgnoreFiles(options.prefix, relpath)) + } else if (path === prefix) { + // on the other hand, if the path and prefix are the same, then we ignore workspaces + // so that we don't pack a workspace as part of the root project. append them as + // normalized relative paths from the root + additionalDefaults.push(...workspaces.map((w) => normalizePath(relative(options.path, w)))) + } + } + + // go ahead and inject the default rules now + this.injectRules(defaultRules, [...defaults, ...additionalDefaults]) + + if (!this.isPackage) { + // if this instance is not a package, then place some strict default rules, and append + // known required files for this directory + this.injectRules(strictRules, [ + ...strictDefaults, + ...this.requiredFiles.map((file) => `!${file}`), + ]) + } + } + + // overridden method: we intercept the reading of the package.json file here so that we can + // process it into both the package.json file rules as well as the strictRules synthetic rule set + addIgnoreFile (file, callback) { + // if we're adding anything other than package.json, then let ignore-walk handle it + if (file !== 'package.json' || !this.isPackage) { + return super.addIgnoreFile(file, callback) + } + + return this.processPackage(callback) + } + + // overridden method: if we're done, but we're a package, then we also need to evaluate bundles + // before we actually emit our done event + emit (ev, data) { + if (ev !== 'done' || !this.isPackage) { + return super.emit(ev, data) + } + + // we intentionally delay the done event while keeping the function sync here + // eslint-disable-next-line promise/catch-or-return, promise/always-return + this.gatherBundles().then(() => { + super.emit('done', this.result) + }) + return true + } + + // overridden method: before actually filtering, we make sure that we've removed the rules for + // files that should no longer take effect due to our order of precedence + filterEntries () { + if (this.ignoreRules['package.json']) { + // package.json means no .npmignore or .gitignore + this.ignoreRules['.npmignore'] = null + this.ignoreRules['.gitignore'] = null + } else if (this.ignoreRules['.npmignore']) { + // .npmignore means no .gitignore + this.ignoreRules['.gitignore'] = null + } + + return super.filterEntries() + } + + // overridden method: we never want to include anything that isn't a file or directory + onstat (opts, callback) { + if (!opts.st.isFile() && !opts.st.isDirectory()) { + return callback() + } + + return super.onstat(opts, callback) + } + + // overridden method: we want to refuse to pack files that are invalid, node-tar protects us from + // a lot of them but not all + stat (opts, callback) { + if (nameIsBadForWindows(opts.entry)) { + return callback() + } + + return super.stat(opts, callback) + } + + // overridden method: this is called to create options for a child walker when we step + // in to a normal child directory (this will never be a bundle). the default method here + // copies the root's `ignoreFiles` value, but we don't want to respect package.json for + // subdirectories, so we override it with a list that intentionally omits package.json + walkerOpt (entry, opts) { + let ignoreFiles = null + + // however, if we have a tree, and we have workspaces, and the directory we're about + // to step into is a workspace, then we _do_ want to respect its package.json + if (this.tree.workspaces) { + const workspaceDirs = [...this.tree.workspaces.values()] + .map((dir) => dir.replace(/\\/g, '/')) + + const entryPath = join(this.path, entry).replace(/\\/g, '/') + if (workspaceDirs.includes(entryPath)) { + ignoreFiles = [ + defaultRules, + 'package.json', + '.npmignore', + '.gitignore', + strictRules, + ] + } + } else { + ignoreFiles = [ + defaultRules, + '.npmignore', + '.gitignore', + strictRules, + ] + } + + return { + ...super.walkerOpt(entry, opts), + ignoreFiles, + // we map over our own requiredFiles and pass ones that are within this entry + requiredFiles: this.requiredFiles + .map((file) => { + if (relative(file, entry) === '..') { + return relative(entry, file).replace(/\\/g, '/') + } + return false + }) + .filter(Boolean), + } + } + + // overridden method: we want child walkers to be instances of this class, not ignore-walk + walker (entry, opts, callback) { + new PackWalker(this.tree, this.walkerOpt(entry, opts)).on('done', callback).start() + } + + // overridden method: we use a custom sort method to help compressibility + sort (a, b) { + // optimize for compressibility + // extname, then basename, then locale alphabetically + // https://twitter.com/isntitvacant/status/1131094910923231232 + const exta = extname(a).toLowerCase() + const extb = extname(b).toLowerCase() + const basea = basename(a).toLowerCase() + const baseb = basename(b).toLowerCase() + + return exta.localeCompare(extb, 'en') || + basea.localeCompare(baseb, 'en') || + a.localeCompare(b, 'en') + } + + // convenience method: this joins the given rules with newlines, appends a trailing newline, + // and calls the internal onReadIgnoreFile method + injectRules (filename, rules, callback = () => {}) { + this.onReadIgnoreFile(filename, `${rules.join('\n')}\n`, callback) + } + + // custom method: this is called by addIgnoreFile when we find a package.json, it uses the + // arborist tree to pull both default rules and strict rules for the package + processPackage (callback) { + const { + bin, + browser, + files, + main, + } = this.tree.package + + // rules in these arrays are inverted since they are patterns we want to _not_ ignore + const ignores = [] + const strict = [ + ...strictDefaults, + '!/package.json', + '/.git', + '/node_modules', + '/package-lock.json', + '/yarn.lock', + '/pnpm-lock.yaml', + ] + + // if we have a files array in our package, we need to pull rules from it + if (files) { + for (let file of files) { + // invert the rule because these are things we want to include + if (file.startsWith('/')) { + file = file.slice(1) + } else if (file.startsWith('./')) { + file = file.slice(2) + } else if (file.endsWith('/*')) { + file = file.slice(0, -2) + } + const inverse = `!${file}` + try { + // if an entry in the files array is a specific file, then we need to include it as a + // strict requirement for this package. if it's a directory or a pattern, it's a default + // pattern instead. this is ugly, but we have to stat to find out if it's a file + const stat = lstat(join(this.path, file.replace(/^!+/, '')).replace(/\\/g, '/')) + // if we have a file and we know that, it's strictly required + if (stat.isFile()) { + strict.unshift(inverse) + this.requiredFiles.push(file) + } else if (stat.isDirectory()) { + // otherwise, it's a default ignore, and since we got here we know it's not a pattern + // so we include the directory contents + ignores.push(inverse) + ignores.push(`${inverse}/**`) + } + // if the thing exists, but is neither a file or a directory, we don't want it at all + } catch (err) { + // if lstat throws, then we assume we're looking at a pattern and treat it as a default + ignores.push(inverse) + } + } + + // we prepend a '*' to exclude everything, followed by our inverted file rules + // which now mean to include those + this.injectRules('package.json', ['*', ...ignores]) + } + + // browser is required + if (browser) { + strict.push(`!/${browser}`) + } + + // main is required + if (main) { + strict.push(`!/${main}`) + } + + // each bin is required + if (bin) { + for (const key in bin) { + strict.push(`!/${bin[key]}`) + } + } + + // and now we add all of the strict rules to our synthetic file + this.injectRules(strictRules, strict, callback) + } + + // custom method: after we've finished gathering the files for the root package, we call this + // before emitting the 'done' event in order to gather all of the files for bundled deps + async gatherBundles () { + if (this.seen.has(this.tree)) { + return + } + + // add this node to our seen tracker + this.seen.add(this.tree) + + // if we're the project root, then we look at our bundleDependencies, otherwise we got here + // because we're a bundled dependency of the root, which means we need to include all prod + // and optional dependencies in the bundle + let toBundle + if (this.tree.isProjectRoot) { + const { bundleDependencies } = this.tree.package + toBundle = bundleDependencies || [] + } else { + const { dependencies, optionalDependencies } = this.tree.package + toBundle = Object.keys(dependencies || {}).concat(Object.keys(optionalDependencies || {})) + } + + for (const dep of toBundle) { + const edge = this.tree.edgesOut.get(dep) + // no edgeOut = missing node, so skip it. we can't pack it if it's not here + // we also refuse to pack peer dependencies and dev dependencies + if (!edge || edge.peer || edge.dev) { + continue + } + + // get a reference to the node we're bundling + const node = this.tree.edgesOut.get(dep).to + // if there's no node, this is most likely an optional dependency that hasn't been + // installed. just skip it. + if (!node) { + continue + } + // we use node.path for the path because we want the location the node was linked to, + // not where it actually lives on disk + const path = node.path + // but link nodes don't have edgesOut, so we need to pass in the target of the node + // in order to make sure we correctly traverse its dependencies + const tree = node.target + + // and start building options to be passed to the walker for this package + const walkerOpts = { + path, + isPackage: true, + ignoreFiles: [], + seen: this.seen, // pass through seen so we can prevent infinite circular loops + } + + // if our node is a link, we apply defaultRules. we don't do this for regular bundled + // deps because their .npmignore and .gitignore files are excluded by default and may + // override defaults + if (node.isLink) { + walkerOpts.ignoreFiles.push(defaultRules) + } + + // _all_ nodes will follow package.json rules from their package root + walkerOpts.ignoreFiles.push('package.json') + + // only link nodes will obey .npmignore or .gitignore + if (node.isLink) { + walkerOpts.ignoreFiles.push('.npmignore') + walkerOpts.ignoreFiles.push('.gitignore') + } + + // _all_ nodes follow strict rules + walkerOpts.ignoreFiles.push(strictRules) + + // create a walker for this dependency and gather its results + const walker = new PackWalker(tree, walkerOpts) + const bundled = await new Promise((pResolve, pReject) => { + walker.on('error', pReject) + walker.on('done', pResolve) + walker.start() + }) + + // now we make sure we have our paths correct from the root, and accumulate everything into + // our own result set to deduplicate + const relativeFrom = relative(this.root, walker.path) + for (const file of bundled) { + this.result.add(join(relativeFrom, file).replace(/\\/g, '/')) + } + } + } +} + +const walk = (tree, options, callback) => { + if (typeof options === 'function') { + callback = options + options = {} + } + const p = new Promise((pResolve, pReject) => { + new PackWalker(tree, { ...options, isPackage: true }) + .on('done', pResolve).on('error', pReject).start() + }) + return callback ? p.then(res => callback(null, res), callback) : p +} + +module.exports = walk +walk.Walker = PackWalker diff --git a/node_modules/npm-packlist/package.json b/node_modules/npm-packlist/package.json index 2fe493a..6023ad3 100644 --- a/node_modules/npm-packlist/package.json +++ b/node_modules/npm-packlist/package.json @@ -1,59 +1,60 @@ { "name": "npm-packlist", - "version": "3.0.0", + "version": "7.0.4", "description": "Get a list of the files to add from a folder into an npm package", "directories": { "test": "test" }, - "main": "index.js", + "main": "lib/index.js", "dependencies": { - "glob": "^7.1.6", - "ignore-walk": "^4.0.1", - "npm-bundled": "^1.1.1", - "npm-normalize-package-bin": "^1.0.1" + "ignore-walk": "^6.0.0" }, - "author": "Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me/)", + "author": "GitHub Inc.", "license": "ISC", "files": [ - "bin/index.js", - "index.js" + "bin/", + "lib/" ], "devDependencies": { - "@npmcli/lint": "^1.0.2", + "@npmcli/arborist": "^6.0.0 || ^6.0.0-pre.0", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.10.0", "mutate-fs": "^2.1.1", - "tap": "^15.0.6" + "tap": "^16.0.1" }, "scripts": { "test": "tap", - "posttest": "npm run lint --", + "posttest": "npm run lint", "snap": "tap", "postsnap": "npm run lintfix --", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", "eslint": "eslint", - "lint": "npm run npmclilint -- \"*.*js\" \"test/**/*.*js\"", + "lint": "eslint \"**/*.js\"", "lintfix": "npm run lint -- --fix", - "npmclilint": "npmcli-lint" + "npmclilint": "npmcli-lint", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force" }, "repository": { "type": "git", - "url": "git+https://github.com/npm/npm-packlist.git" + "url": "https://github.com/npm/npm-packlist.git" }, "tap": { "test-env": [ "LC_ALL=sk" ], - "check-coverage": true, "nyc-arg": [ - "--include=index.js", - "--include=bin/index.js" + "--exclude", + "tap-snapshots/**" + ], + "files": [ + "test/*.js" ] }, - "bin": { - "npm-packlist": "bin/index.js" - }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.10.0" } } diff --git a/node_modules/npm-pick-manifest/index.js b/node_modules/npm-pick-manifest/lib/index.js similarity index 96% rename from node_modules/npm-pick-manifest/index.js rename to node_modules/npm-pick-manifest/lib/index.js index 6954505..f2934e9 100644 --- a/node_modules/npm-pick-manifest/index.js +++ b/node_modules/npm-pick-manifest/lib/index.js @@ -34,7 +34,7 @@ const pickManifest = (packument, wanted, opts) => { npmVersion = null, includeStaged = false, avoid = null, - avoidStrict = false + avoidStrict = false, } = opts const { name, time: verTimes } = packument @@ -43,7 +43,7 @@ const pickManifest = (packument, wanted, opts) => { if (avoidStrict) { const looseOpts = { ...opts, - avoidStrict: false + avoidStrict: false, } const result = pickManifest(packument, wanted, looseOpts) @@ -56,7 +56,7 @@ const pickManifest = (packument, wanted, opts) => { return { ...caret, _outsideDependencyRange: true, - _isSemVerMajor: false + _isSemVerMajor: false, } } @@ -65,7 +65,7 @@ const pickManifest = (packument, wanted, opts) => { return { ...star, _outsideDependencyRange: true, - _isSemVerMajor: true + _isSemVerMajor: true, } } @@ -75,7 +75,7 @@ const pickManifest = (packument, wanted, opts) => { wanted, avoid, before, - versions: Object.keys(versions) + versions: Object.keys(versions), }) } @@ -143,7 +143,7 @@ const pickManifest = (packument, wanted, opts) => { type, wanted, before, - versions: Object.keys(versions) + versions: Object.keys(versions), }) } @@ -213,6 +213,6 @@ module.exports = (packument, wanted, opts = {}) => { versions: Object.keys(packument.versions), name, distTags: packument['dist-tags'], - defaultTag + defaultTag, }) } diff --git a/node_modules/npm-pick-manifest/package.json b/node_modules/npm-pick-manifest/package.json index 4b4866c..89ff896 100644 --- a/node_modules/npm-pick-manifest/package.json +++ b/node_modules/npm-pick-manifest/package.json @@ -1,43 +1,56 @@ { "name": "npm-pick-manifest", - "version": "6.1.1", + "version": "8.0.1", "description": "Resolves a matching manifest from a package metadata document according to standard npm semver resolution rules.", - "main": "index.js", + "main": "./lib", "files": [ - "*.js" + "bin/", + "lib/" ], "scripts": { "coverage": "tap", - "lint": "standard", + "lint": "eslint \"**/*.js\"", "test": "tap", "posttest": "npm run lint", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags" + "postlint": "template-oss-check", + "lintfix": "npm run lint -- --fix", + "snap": "tap", + "template-oss-apply": "template-oss-apply --force" + }, + "repository": { + "type": "git", + "url": "https://github.com/npm/npm-pick-manifest.git" }, - "repository": "https://github.com/npm/npm-pick-manifest", "keywords": [ "npm", "semver", "package manager" ], - "author": { - "name": "Kat Marchán", - "email": "kzm@sykosomatic.org", - "twitter": "maybekatz" - }, + "author": "GitHub Inc.", "license": "ISC", "dependencies": { - "npm-install-checks": "^4.0.0", - "npm-normalize-package-bin": "^1.0.1", - "npm-package-arg": "^8.1.2", - "semver": "^7.3.4" + "npm-install-checks": "^6.0.0", + "npm-normalize-package-bin": "^3.0.0", + "npm-package-arg": "^10.0.0", + "semver": "^7.3.5" }, "devDependencies": { - "standard": "^14.3.1", - "tap": "^14.11.0" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.6.1", + "tap": "^16.0.1" }, "tap": { - "check-coverage": true + "check-coverage": true, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.6.1" } } diff --git a/node_modules/npm-profile/lib/index.js b/node_modules/npm-profile/lib/index.js index aa322e3..ce78882 100644 --- a/node_modules/npm-profile/lib/index.js +++ b/node_modules/npm-profile/lib/index.js @@ -2,15 +2,17 @@ const fetch = require('npm-registry-fetch') const { HttpErrorBase } = require('npm-registry-fetch/lib/errors') +const EventEmitter = require('events') const os = require('os') const { URL } = require('url') +const log = require('proc-log') // try loginWeb, catch the "not supported" message and fall back to couch const login = (opener, prompter, opts = {}) => { const { creds } = opts return loginWeb(opener, opts).catch(er => { if (er instanceof WebLoginNotSupported) { - process.emit('log', 'verbose', 'web login not supported, trying couch') + log.verbose('web login not supported, trying couch') return prompter(creds) .then(data => loginCouch(data.username, data.password, opts)) } else { @@ -23,7 +25,7 @@ const adduser = (opener, prompter, opts = {}) => { const { creds } = opts return adduserWeb(opener, opts).catch(er => { if (er instanceof WebLoginNotSupported) { - process.emit('log', 'verbose', 'web adduser not supported, trying couch') + log.verbose('web adduser not supported, trying couch') return prompter(creds) .then(data => adduserCouch(data.username, data.email, data.password, opts)) } else { @@ -33,12 +35,12 @@ const adduser = (opener, prompter, opts = {}) => { } const adduserWeb = (opener, opts = {}) => { - process.emit('log', 'verbose', 'web adduser', 'before first POST') + log.verbose('web adduser', 'before first POST') return webAuth(opener, opts, { create: true }) } const loginWeb = (opener, opts = {}) => { - process.emit('log', 'verbose', 'web login', 'before first POST') + log.verbose('web login', 'before first POST') return webAuth(opener, opts, {}) } @@ -54,6 +56,7 @@ const webAuth = (opener, opts, body) => { const { hostname } = opts body.hostname = hostname || os.hostname() const target = '/-/v1/login' + const doneEmitter = new EventEmitter() return fetch(target, { ...opts, method: 'POST', @@ -62,17 +65,33 @@ const webAuth = (opener, opts, body) => { return Promise.all([res, res.json()]) }).then(([res, content]) => { const { doneUrl, loginUrl } = content - process.emit('log', 'verbose', 'web auth', 'got response', content) + log.verbose('web auth', 'got response', content) if (!isValidUrl(doneUrl) || !isValidUrl(loginUrl)) { throw new WebLoginInvalidResponse('POST', res, content) } return content }).then(({ doneUrl, loginUrl }) => { - process.emit('log', 'verbose', 'web auth', 'opening url pair') - return opener(loginUrl).then( - () => webAuthCheckLogin(doneUrl, { ...opts, cache: false }) + log.verbose('web auth', 'opening url pair') + + const openPromise = opener(loginUrl, doneEmitter) + const webAuthCheckPromise = webAuthCheckLogin(doneUrl, { ...opts, cache: false }) + .then(authResult => { + log.verbose('web auth', 'done-check finished') + + // cancel open prompt if it's present + doneEmitter.emit('abort') + + return authResult + }) + + return Promise.all([openPromise, webAuthCheckPromise]).then( + // pick the auth result and pass it along + ([, authResult]) => authResult ) }).catch(er => { + // cancel open prompt if it's present + doneEmitter.emit('abort') + if ((er.statusCode >= 400 && er.statusCode <= 499) || er.statusCode === 500) { throw new WebLoginNotSupported('POST', { status: er.statusCode, @@ -121,7 +140,7 @@ const adduserCouch = (username, email, password, opts = {}) => { ...body, password: 'XXXXX', } - process.emit('log', 'verbose', 'adduser', 'before first PUT', logObj) + log.verbose('adduser', 'before first PUT', logObj) const target = '/-/user/org.couchdb.user:' + encodeURIComponent(username) return fetch.json(target, { @@ -147,9 +166,9 @@ const loginCouch = (username, password, opts = {}) => { ...body, password: 'XXXXX', } - process.emit('log', 'verbose', 'login', 'before first PUT', logObj) + log.verbose('login', 'before first PUT', logObj) - const target = '-/user/org.couchdb.user:' + encodeURIComponent(username) + const target = '/-/user/org.couchdb.user:' + encodeURIComponent(username) return fetch.json(target, { ...opts, method: 'PUT', @@ -272,4 +291,5 @@ module.exports = { listTokens, removeToken, createToken, + webAuthCheckLogin, } diff --git a/node_modules/npm-profile/package.json b/node_modules/npm-profile/package.json index 8745c25..9c0b77b 100644 --- a/node_modules/npm-profile/package.json +++ b/node_modules/npm-profile/package.json @@ -1,45 +1,50 @@ { "name": "npm-profile", - "version": "6.0.0", + "version": "7.0.1", "description": "Library for updating an npmjs.com profile", "keywords": [], "author": "GitHub Inc.", "license": "ISC", "dependencies": { - "npm-registry-fetch": "^12.0.0" + "npm-registry-fetch": "^14.0.0", + "proc-log": "^3.0.0" }, "main": "./lib/index.js", "repository": { "type": "git", - "url": "git+https://github.com/npm/npm-profile.git" + "url": "https://github.com/npm/npm-profile.git" }, "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "devDependencies": { - "@npmcli/template-oss": "^2.5.1", - "nock": "^13.2.1", - "tap": "^15.1.5" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.5.1", + "nock": "^13.2.4", + "tap": "^16.0.1" }, "scripts": { - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", "posttest": "npm run lint", "test": "tap", "snap": "tap", - "lint": "eslint '**/*.js'", - "postlint": "npm-template-check", - "lintfix": "npm run lint -- --fix" + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "lintfix": "npm run lint -- --fix", + "template-oss-apply": "template-oss-apply --force" }, "tap": { - "check-coverage": true + "check-coverage": true, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "templateOSS": { - "version": "2.5.1" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" } } diff --git a/node_modules/npm-registry-fetch/lib/auth.js b/node_modules/npm-registry-fetch/lib/auth.js index 17da6a1..870ce0d 100644 --- a/node_modules/npm-registry-fetch/lib/auth.js +++ b/node_modules/npm-registry-fetch/lib/auth.js @@ -1,4 +1,5 @@ 'use strict' +const fs = require('fs') const npa = require('npm-package-arg') const { URL } = require('url') @@ -7,7 +8,8 @@ const { URL } = require('url') const regKeyFromURI = (uri, opts) => { const parsed = new URL(uri) // try to find a config key indicating we have auth for this registry - // can be one of :_authToken, :_auth, or :_password and :username + // can be one of :_authToken, :_auth, :_password and :username, or + // :certfile and :keyfile // We walk up the "path" until we're left with just //<host>[:<port>], // stopping when we reach '//'. let regKey = `//${parsed.host}${parsed.pathname}` @@ -26,7 +28,8 @@ const regKeyFromURI = (uri, opts) => { const hasAuth = (regKey, opts) => ( opts[`${regKey}:_authToken`] || opts[`${regKey}:_auth`] || - opts[`${regKey}:username`] && opts[`${regKey}:_password`] + opts[`${regKey}:username`] && opts[`${regKey}:_password`] || + opts[`${regKey}:certfile`] && opts[`${regKey}:keyfile`] ) const sameHost = (a, b) => { @@ -44,6 +47,17 @@ const getRegistry = opts => { return scopeReg || opts.registry } +const maybeReadFile = file => { + try { + return fs.readFileSync(file, 'utf8') + } catch (er) { + if (er.code !== 'ENOENT') { + throw er + } + return null + } +} + const getAuth = (uri, opts = {}) => { const { forceAuth } = opts if (!uri) { @@ -59,6 +73,8 @@ const getAuth = (uri, opts = {}) => { username: forceAuth.username, password: forceAuth._password || forceAuth.password, auth: forceAuth._auth || forceAuth.auth, + certfile: forceAuth.certfile, + keyfile: forceAuth.keyfile, }) } @@ -82,6 +98,8 @@ const getAuth = (uri, opts = {}) => { [`${regKey}:username`]: username, [`${regKey}:_password`]: password, [`${regKey}:_auth`]: auth, + [`${regKey}:certfile`]: certfile, + [`${regKey}:keyfile`]: keyfile, } = opts return new Auth({ @@ -90,15 +108,19 @@ const getAuth = (uri, opts = {}) => { auth, username, password, + certfile, + keyfile, }) } class Auth { - constructor ({ token, auth, username, password, scopeAuthKey }) { + constructor ({ token, auth, username, password, scopeAuthKey, certfile, keyfile }) { this.scopeAuthKey = scopeAuthKey this.token = null this.auth = null this.isBasicAuth = false + this.cert = null + this.key = null if (token) { this.token = token } else if (auth) { @@ -108,6 +130,15 @@ class Auth { this.auth = Buffer.from(`${username}:${p}`, 'utf8').toString('base64') this.isBasicAuth = true } + // mTLS may be used in conjunction with another auth method above + if (certfile && keyfile) { + const cert = maybeReadFile(certfile, 'utf-8') + const key = maybeReadFile(keyfile, 'utf-8') + if (cert && key) { + this.cert = cert + this.key = key + } + } } } diff --git a/node_modules/npm-registry-fetch/lib/check-response.js b/node_modules/npm-registry-fetch/lib/check-response.js index 26043a9..066ac3c 100644 --- a/node_modules/npm-registry-fetch/lib/check-response.js +++ b/node_modules/npm-registry-fetch/lib/check-response.js @@ -3,23 +3,25 @@ const errors = require('./errors.js') const { Response } = require('minipass-fetch') const defaultOpts = require('./default-opts.js') +const log = require('proc-log') +const cleanUrl = require('./clean-url.js') /* eslint-disable-next-line max-len */ const moreInfoUrl = 'https://github.com/npm/cli/wiki/No-auth-for-URI,-but-auth-present-for-scoped-registry' const checkResponse = - async ({ method, uri, res, registry, startTime, auth, opts }) => { + async ({ method, uri, res, startTime, auth, opts }) => { opts = { ...defaultOpts, ...opts } if (res.headers.has('npm-notice') && !res.headers.has('x-local-cache')) { - opts.log.notice('', res.headers.get('npm-notice')) + log.notice('', res.headers.get('npm-notice')) } if (res.status >= 400) { - logRequest(method, res, startTime, opts) + logRequest(method, res, startTime) if (auth && auth.scopeAuthKey && !auth.token && !auth.auth) { // we didn't have auth for THIS request, but we do have auth for // requests to the registry indicated by the spec's scope value. // Warn the user. - opts.log.warn('registry', `No auth for URI, but auth present for scoped registry. + log.warn('registry', `No auth for URI, but auth present for scoped registry. URI: ${uri} Scoped Registry Key: ${auth.scopeAuthKey} @@ -38,27 +40,15 @@ More info here: ${moreInfoUrl}`) } module.exports = checkResponse -function logRequest (method, res, startTime, opts) { +function logRequest (method, res, startTime) { const elapsedTime = Date.now() - startTime const attempt = res.headers.get('x-fetch-attempts') const attemptStr = attempt && attempt > 1 ? ` attempt #${attempt}` : '' const cacheStatus = res.headers.get('x-local-cache-status') const cacheStr = cacheStatus ? ` (cache ${cacheStatus})` : '' + const urlStr = cleanUrl(res.url) - let urlStr - try { - const { URL } = require('url') - const url = new URL(res.url) - if (url.password) { - url.password = '***' - } - - urlStr = url.toString() - } catch (er) { - urlStr = res.url - } - - opts.log.http( + log.http( 'fetch', `${method.toUpperCase()} ${res.status} ${urlStr} ${elapsedTime}ms${attemptStr}${cacheStr}` ) @@ -71,7 +61,9 @@ function checkErrors (method, res, startTime, opts) { let parsed = body try { parsed = JSON.parse(body.toString('utf8')) - } catch (e) {} + } catch { + // ignore errors + } if (res.status === 401 && res.headers.get('www-authenticate')) { const auth = res.headers.get('www-authenticate') .split(/,\s*/) diff --git a/node_modules/npm-registry-fetch/lib/clean-url.js b/node_modules/npm-registry-fetch/lib/clean-url.js new file mode 100644 index 0000000..a419b47 --- /dev/null +++ b/node_modules/npm-registry-fetch/lib/clean-url.js @@ -0,0 +1,26 @@ +const { URL } = require('url') + +const replace = '***' +const tokenRegex = /\bnpm_[a-zA-Z0-9]{36}\b/g +const guidRegex = /\b[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\b/g + +const cleanUrl = (str) => { + if (typeof str !== 'string' || !str) { + return str + } + + try { + const url = new URL(str) + if (url.password) { + str = str.replace(url.password, replace) + } + } catch { + // ignore errors + } + + return str + .replace(tokenRegex, `npm_${replace}`) + .replace(guidRegex, `npm_${replace}`) +} + +module.exports = cleanUrl diff --git a/node_modules/npm-registry-fetch/lib/default-opts.js b/node_modules/npm-registry-fetch/lib/default-opts.js index e8e8221..f0847f0 100644 --- a/node_modules/npm-registry-fetch/lib/default-opts.js +++ b/node_modules/npm-registry-fetch/lib/default-opts.js @@ -1,6 +1,5 @@ const pkg = require('../package.json') module.exports = { - log: require('./silentlog.js'), maxSockets: 12, method: 'GET', registry: 'https://registry.npmjs.org/', diff --git a/node_modules/npm-registry-fetch/lib/errors.js b/node_modules/npm-registry-fetch/lib/errors.js index 0efc923..cf5ddba 100644 --- a/node_modules/npm-registry-fetch/lib/errors.js +++ b/node_modules/npm-registry-fetch/lib/errors.js @@ -4,7 +4,7 @@ const url = require('url') function packageName (href) { try { - let basePath = new url.URL(href).pathname.substr(1) + let basePath = new url.URL(href).pathname.slice(1) if (!basePath.match(/^-/)) { basePath = basePath.split('/') var index = basePath.indexOf('_rewrite') diff --git a/node_modules/npm-registry-fetch/lib/index.js b/node_modules/npm-registry-fetch/lib/index.js index 19c9214..cc331a5 100644 --- a/node_modules/npm-registry-fetch/lib/index.js +++ b/node_modules/npm-registry-fetch/lib/index.js @@ -104,18 +104,18 @@ function regFetch (uri, /* istanbul ignore next */ opts_ = {}) { opts.preferOnline = true } - const doFetch = async body => { + const doFetch = async fetchBody => { const p = fetch(uri, { agent: opts.agent, algorithms: opts.algorithms, - body, + body: fetchBody, cache: getCacheMode(opts), cachePath: opts.cache, ca: opts.ca, - cert: opts.cert, + cert: auth.cert || opts.cert, headers, integrity: opts.integrity, - key: opts.key, + key: auth.key || opts.key, localAddress: opts.localAddress, maxSockets: opts.maxSockets, memoize: opts.memoize, @@ -213,6 +213,10 @@ function getHeaders (uri, auth, opts) { 'user-agent': opts.userAgent, }, opts.headers || {}) + if (opts.authType) { + headers['npm-auth-type'] = opts.authType + } + if (opts.scope) { headers['npm-scope'] = opts.scope } @@ -239,3 +243,5 @@ function getHeaders (uri, auth, opts) { return headers } + +module.exports.cleanUrl = require('./clean-url.js') diff --git a/node_modules/npm-registry-fetch/lib/silentlog.js b/node_modules/npm-registry-fetch/lib/silentlog.js deleted file mode 100644 index 483bd44..0000000 --- a/node_modules/npm-registry-fetch/lib/silentlog.js +++ /dev/null @@ -1,14 +0,0 @@ -'use strict' - -const noop = Function.prototype -module.exports = { - error: noop, - warn: noop, - notice: noop, - info: noop, - verbose: noop, - silly: noop, - http: noop, - pause: noop, - resume: noop, -} diff --git a/node_modules/npm-registry-fetch/package.json b/node_modules/npm-registry-fetch/package.json index f1aab5c..89550ce 100644 --- a/node_modules/npm-registry-fetch/package.json +++ b/node_modules/npm-registry-fetch/package.json @@ -1,28 +1,28 @@ { "name": "npm-registry-fetch", - "version": "12.0.2", + "version": "14.0.3", "description": "Fetch-based http client for use with npm registry APIs", "main": "lib", "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "scripts": { "eslint": "eslint", - "lint": "eslint '**/*.js'", + "lint": "eslint \"**/*.js\"", "lintfix": "npm run lint -- --fix", - "prepublishOnly": "git push origin --follow-tags", - "preversion": "npm test", - "postversion": "npm publish", "test": "tap", "posttest": "npm run lint", "npmclilint": "npmcli-lint", "postsnap": "npm run lintfix --", - "postlint": "npm-template-check", + "postlint": "template-oss-check", "snap": "tap", - "template-copy": "npm-template-copy --force" + "template-oss-apply": "template-oss-apply --force" + }, + "repository": { + "type": "git", + "url": "https://github.com/npm/npm-registry-fetch.git" }, - "repository": "https://github.com/npm/npm-registry-fetch", "keywords": [ "npm", "registry", @@ -31,30 +31,38 @@ "author": "GitHub Inc.", "license": "ISC", "dependencies": { - "make-fetch-happen": "^10.0.1", - "minipass": "^3.1.6", - "minipass-fetch": "^1.4.1", + "make-fetch-happen": "^11.0.0", + "minipass": "^4.0.0", + "minipass-fetch": "^3.0.0", "minipass-json-stream": "^1.0.1", "minizlib": "^2.1.2", - "npm-package-arg": "^8.1.5" + "npm-package-arg": "^10.0.0", + "proc-log": "^3.0.0" }, "devDependencies": { - "@npmcli/template-oss": "^2.7.1", - "cacache": "^15.3.0", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.10.0", + "cacache": "^17.0.0", + "mkdirp": "^1.0.4", "nock": "^13.2.4", - "npmlog": "^6.0.0", "require-inject": "^1.4.4", - "ssri": "^8.0.1", - "tap": "^15.1.6" + "rimraf": "^3.0.2", + "ssri": "^10.0.0", + "tap": "^16.0.1" }, "tap": { "check-coverage": true, - "test-ignore": "test[\\\\/](util|cache)[\\\\/]" + "test-ignore": "test[\\\\/](util|cache)[\\\\/]", + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "templateOSS": { - "version": "2.7.1" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.10.0" } } diff --git a/node_modules/pacote/lib/bin.js b/node_modules/pacote/lib/bin.js index c0409be..f35b62c 100755 --- a/node_modules/pacote/lib/bin.js +++ b/node_modules/pacote/lib/bin.js @@ -4,26 +4,33 @@ const run = conf => { const pacote = require('../') switch (conf._[0]) { case 'resolve': - if (conf.long) + case 'manifest': + case 'packument': + if (conf._[0] === 'resolve' && conf.long) { return pacote.manifest(conf._[1], conf).then(mani => ({ resolved: mani._resolved, integrity: mani._integrity, from: mani._from, })) - case 'manifest': - case 'packument': + } return pacote[conf._[0]](conf._[1], conf) case 'tarball': if (!conf._[2] || conf._[2] === '-') { return pacote.tarball.stream(conf._[1], stream => { - stream.pipe(conf.testStdout || - /* istanbul ignore next */ process.stdout) + stream.pipe( + conf.testStdout || + /* istanbul ignore next */ + process.stdout + ) // make sure it resolves something falsey - return stream.promise().then(() => {}) + return stream.promise().then(() => { + return false + }) }, conf) - } else + } else { return pacote.tarball.file(conf._[1], conf._[2], conf) + } case 'extract': return pacote.extract(conf._[1], conf._[2], conf) @@ -81,8 +88,9 @@ const pretty = (conf, result) => let addedLogListener = false const main = args => { const conf = parse(args) - if (conf.help || conf.h) + if (conf.help || conf.h) { return console.log(usage()) + } if (!addedLogListener) { process.on('log', console.error) @@ -107,7 +115,7 @@ const parseArg = arg => { const k = split.shift() const v = split.join('=') const no = /^no-/.test(k) && !v - const key = (no ? k.substr(3) : k) + const key = (no ? k.slice(3) : k) .replace(/^tag$/, 'defaultTag') .replace(/-([a-z])/g, (_, c) => c.toUpperCase()) const value = v ? v.replace(/^~/, process.env.HOME) : !no @@ -121,14 +129,14 @@ const parse = args => { } let dashdash = false args.forEach(arg => { - if (dashdash) + if (dashdash) { conf._.push(arg) - else if (arg === '--') + } else if (arg === '--') { dashdash = true - else if (arg === '-h') + } else if (arg === '-h') { conf.help = true - else if (/^--/.test(arg)) { - const {key, value} = parseArg(arg) + } else if (/^--/.test(arg)) { + const { key, value } = parseArg(arg) conf[key] = value } else { conf._.push(arg) @@ -137,9 +145,9 @@ const parse = args => { return conf } -if (module === require.main) +if (module === require.main) { main(process.argv.slice(2)) -else +} else { module.exports = { main, run, @@ -147,3 +155,4 @@ else parseArg, parse, } +} diff --git a/node_modules/pacote/lib/dir.js b/node_modules/pacote/lib/dir.js index 0d3a00d..923fdd6 100644 --- a/node_modules/pacote/lib/dir.js +++ b/node_modules/pacote/lib/dir.js @@ -1,14 +1,12 @@ const Fetcher = require('./fetcher.js') const FileFetcher = require('./file.js') -const cacache = require('cacache') const Minipass = require('minipass') -const { promisify } = require('util') -const readPackageJson = require('read-package-json-fast') const tarCreateOptions = require('./util/tar-create-options.js') const packlist = require('npm-packlist') const tar = require('tar') const _prepareDir = Symbol('_prepareDir') const { resolve } = require('path') +const _readPackageJson = Symbol.for('package.Fetcher._readPackageJson') const runScript = require('@npmcli/run-script') @@ -18,6 +16,9 @@ class DirFetcher extends Fetcher { super(spec, opts) // just the fully resolved filename this.resolved = this.spec.fetchSpec + + this.tree = opts.tree || null + this.Arborist = opts.Arborist || null } // exposes tarCreateOptions as public API @@ -31,24 +32,23 @@ class DirFetcher extends Fetcher { [_prepareDir] () { return this.manifest().then(mani => { - if (!mani.scripts || !mani.scripts.prepare) + if (!mani.scripts || !mani.scripts.prepare) { return + } // we *only* run prepare. // pre/post-pack is run by the npm CLI for publish and pack, // but this function is *also* run when installing git deps const stdio = this.opts.foregroundScripts ? 'inherit' : 'pipe' - // hide the banner if loglevel is silent, or if prepare running + // hide the banner if silent opt is passed in, or if prepare running // in the background. - const banner = this.opts.log && this.opts.log.level === 'silent' ? false - : stdio === 'inherit' + const banner = this.opts.silent ? false : stdio === 'inherit' return runScript({ pkg: mani, event: 'prepare', path: this.resolved, - stdioString: true, stdio, banner, env: { @@ -61,14 +61,26 @@ class DirFetcher extends Fetcher { } [_tarballFromResolved] () { + if (!this.tree && !this.Arborist) { + throw new Error('DirFetcher requires either a tree or an Arborist constructor to pack') + } + const stream = new Minipass() stream.resolved = this.resolved stream.integrity = this.integrity + const { prefix, workspaces } = this.opts + // run the prepare script, get the list of files, and tar it up // pipe to the stream, and proxy errors the chain. this[_prepareDir]() - .then(() => packlist({ path: this.resolved })) + .then(async () => { + if (!this.tree) { + const arb = new this.Arborist({ path: this.resolved }) + this.tree = await arb.loadActual() + } + return packlist(this.tree, { path: this.resolved, prefix, workspaces }) + }) .then(files => tar.c(tarCreateOptions(this.package), files) .on('error', er => stream.emit('error', er)).pipe(stream)) .catch(er => stream.emit('error', er)) @@ -76,10 +88,11 @@ class DirFetcher extends Fetcher { } manifest () { - if (this.package) + if (this.package) { return Promise.resolve(this.package) + } - return readPackageJson(this.resolved + '/package.json') + return this[_readPackageJson](this.resolved + '/package.json') .then(mani => this.package = { ...mani, _integrity: this.integrity && String(this.integrity), diff --git a/node_modules/pacote/lib/fetcher.js b/node_modules/pacote/lib/fetcher.js index 69dd025..fe5679f 100644 --- a/node_modules/pacote/lib/fetcher.js +++ b/node_modules/pacote/lib/fetcher.js @@ -7,29 +7,24 @@ const npa = require('npm-package-arg') const ssri = require('ssri') const { promisify } = require('util') const { basename, dirname } = require('path') -const rimraf = promisify(require('rimraf')) const tar = require('tar') -const procLog = require('./util/proc-log.js') +const log = require('proc-log') const retry = require('promise-retry') +const fs = require('fs/promises') const fsm = require('fs-minipass') const cacache = require('cacache') const isPackageBin = require('./util/is-package-bin.js') +const removeTrailingSlashes = require('./util/trailing-slashes.js') const getContents = require('@npmcli/installed-package-contents') +const readPackageJsonFast = require('read-package-json-fast') +const readPackageJson = promisify(require('read-package-json')) +const Minipass = require('minipass') -// we only change ownership on unix platforms, and only if uid is 0 -const selfOwner = process.getuid && process.getuid() === 0 ? { - uid: 0, - gid: process.getgid(), -} : null -const chownr = selfOwner ? promisify(require('chownr')) : null -const inferOwner = selfOwner ? require('infer-owner') : null -const mkdirp = require('mkdirp') const cacheDir = require('./util/cache-dir.js') // Private methods. // Child classes should not have to override these. // Users should never call them. -const _chown = Symbol('_chown') const _extract = Symbol('_extract') const _mkdir = Symbol('_mkdir') const _empty = Symbol('_empty') @@ -41,11 +36,13 @@ const _assertType = Symbol('_assertType') const _tarballFromCache = Symbol('_tarballFromCache') const _tarballFromResolved = Symbol.for('pacote.Fetcher._tarballFromResolved') const _cacheFetches = Symbol.for('pacote.Fetcher._cacheFetches') +const _readPackageJson = Symbol.for('package.Fetcher._readPackageJson') class FetcherBase { constructor (spec, opts) { - if (!opts || typeof opts !== 'object') + if (!opts || typeof opts !== 'object') { throw new TypeError('options object is required') + } this.spec = npa(spec, opts.where) this.allowGitIgnore = !!opts.allowGitIgnore @@ -62,7 +59,7 @@ class FetcherBase { this[_assertType]() // clone the opts object so that others aren't upset when we mutate it // by adding/modifying the integrity value. - this.opts = {...opts} + this.opts = { ...opts } this.cache = opts.cache || cacheDir() this.resolved = opts.resolved || null @@ -72,8 +69,9 @@ class FetcherBase { // is no longer strong enough. this.defaultIntegrityAlgorithm = opts.defaultIntegrityAlgorithm || 'sha512' - if (typeof opts.integrity === 'string') + if (typeof opts.integrity === 'string') { this.opts.integrity = ssri.parse(opts.integrity) + } this.package = null this.type = this.constructor.name @@ -85,7 +83,6 @@ class FetcherBase { // the process's umask setting do its job. but if configured, we do // respect it. this.umask = opts.umask || 0 - this.log = opts.log || procLog this.preferOnline = !!opts.preferOnline this.preferOffline = !!opts.preferOffline @@ -93,10 +90,20 @@ class FetcherBase { this.before = opts.before this.fullMetadata = this.before ? true : !!opts.fullMetadata + this.fullReadJson = !!opts.fullReadJson + if (this.fullReadJson) { + this[_readPackageJson] = readPackageJson + } else { + this[_readPackageJson] = readPackageJsonFast + } + + // rrh is a registry hostname or 'never' or 'always' + // defaults to registry.npmjs.org + this.replaceRegistryHost = (!opts.replaceRegistryHost || opts.replaceRegistryHost === 'npmjs') ? + 'registry.npmjs.org' : opts.replaceRegistryHost this.defaultTag = opts.defaultTag || 'latest' - this.registry = (opts.registry || 'https://registry.npmjs.org') - .replace(/\/+$/, '') + this.registry = removeTrailingSlashes(opts.registry || 'https://registry.npmjs.org') // command to run 'prepare' scripts on directories and git dirs // To use pacote with yarn, for example, set npmBin to 'yarn' @@ -104,7 +111,7 @@ class FetcherBase { this.npmBin = opts.npmBin || 'npm' // command to install deps for preparing - this.npmInstallCmd = opts.npmInstallCmd || [ 'install', '--force' ] + this.npmInstallCmd = opts.npmInstallCmd || ['install', '--force'] // XXX fill more of this in based on what we know from this.opts // we explicitly DO NOT fill in --tag, though, since we are often @@ -132,19 +139,22 @@ class FetcherBase { get integrity () { return this.opts.integrity || null } + set integrity (i) { - if (!i) + if (!i) { return + } i = ssri.parse(i) const current = this.opts.integrity // do not ever update an existing hash value, but do // merge in NEW algos and hashes that we don't already have. - if (current) + if (current) { current.merge(i) - else + } else { this.opts.integrity = i + } } get notImplementedError () { @@ -201,39 +211,43 @@ class FetcherBase { } [_istream] (stream) { - // everyone will need one of these, either for verifying or calculating - // We always set it, because we have might only have a weak legacy hex - // sha1 in the packument, and this MAY upgrade it to a stronger algo. - // If we had an integrity, and it doesn't match, then this does not - // override that error; the istream will raise the error before it - // gets to the point of re-setting the integrity. - const istream = ssri.integrityStream(this.opts) - istream.on('integrity', i => this.integrity = i) - stream.on('error', er => istream.emit('error', er)) + // if not caching this, just return it + if (!this.opts.cache || !this[_cacheFetches]) { + // instead of creating a new integrity stream, we only piggyback on the + // provided stream's events + if (stream.hasIntegrityEmitter) { + stream.on('integrity', i => this.integrity = i) + return stream + } - // if not caching this, just pipe through to the istream and return it - if (!this.opts.cache || !this[_cacheFetches]) + const istream = ssri.integrityStream(this.opts) + istream.on('integrity', i => this.integrity = i) + stream.on('error', err => istream.emit('error', err)) return stream.pipe(istream) + } // we have to return a stream that gets ALL the data, and proxies errors, // but then pipe from the original tarball stream into the cache as well. // To do this without losing any data, and since the cacache put stream // is not a passthrough, we have to pipe from the original stream into - // the cache AFTER we pipe into the istream. Since the cache stream + // the cache AFTER we pipe into the middleStream. Since the cache stream // has an asynchronous flush to write its contents to disk, we need to - // defer the istream end until the cache stream ends. - stream.pipe(istream, { end: false }) + // defer the middleStream end until the cache stream ends. + const middleStream = new Minipass() + stream.on('error', err => middleStream.emit('error', err)) + stream.pipe(middleStream, { end: false }) const cstream = cacache.put.stream( this.opts.cache, `pacote:tarball:${this.from}`, this.opts ) + cstream.on('integrity', i => this.integrity = i) + cstream.on('error', err => stream.emit('error', err)) stream.pipe(cstream) - // defer istream end until after cstream - // cache write errors should not crash the fetch, this is best-effort. - cstream.promise().catch(() => {}).then(() => istream.end()) - return istream + // eslint-disable-next-line promise/catch-or-return + cstream.promise().catch(() => {}).then(() => middleStream.end()) + return middleStream } pickIntegrityAlgorithm () { @@ -247,7 +261,10 @@ class FetcherBase { } // override the types getter - get types () {} + get types () { + return false + } + [_assertType] () { if (this.types && !this.types.includes(this.spec.type)) { throw new TypeError(`Wrong spec type (${ @@ -288,39 +305,42 @@ class FetcherBase { this.integrity && this.resolved ) ? streamHandler(this[_tarballFromCache]()).catch(er => { - if (this.isDataCorruptionError(er)) { - this.log.warn('tarball', `cached data for ${ + if (this.isDataCorruptionError(er)) { + log.warn('tarball', `cached data for ${ this.spec } (${this.integrity}) seems to be corrupted. Refreshing cache.`) - return this.cleanupCached().then(() => { throw er }) - } else { - throw er - } - }) : null + return this.cleanupCached().then(() => { + throw er + }) + } else { + throw er + } + }) : null const fromResolved = er => { if (er) { - if (!this.isRetriableError(er)) + if (!this.isRetriableError(er)) { throw er - this.log.silly('tarball', `no local data for ${ + } + log.silly('tarball', `no local data for ${ this.spec }. Extracting by manifest.`) } return this.resolve().then(() => retry(tryAgain => streamHandler(this[_istream](this[_tarballFromResolved]())) - .catch(er => { + .catch(streamErr => { // Most likely data integrity. A cache ENOENT error is unlikely // here, since we're definitely not reading from the cache, but it // IS possible that the fetch subsystem accessed the cache, and the // entry got blown away or something. Try one more time to be sure. - if (this.isRetriableError(er)) { - this.log.warn('tarball', `tarball data for ${ + if (this.isRetriableError(streamErr)) { + log.warn('tarball', `tarball data for ${ this.spec } (${this.integrity}) seems to be corrupted. Trying again.`) - return this.cleanupCached().then(() => tryAgain(er)) - } - throw er - }), { retries: 1, minTimeout: 0, maxTimeout: 0 })) + return this.cleanupCached().then(() => tryAgain(streamErr)) + } + throw streamErr + }), { retries: 1, minTimeout: 0, maxTimeout: 0 })) } return fromCache ? fromCache.catch(fromResolved) : fromResolved() @@ -330,44 +350,21 @@ class FetcherBase { return cacache.rm.content(this.cache, this.integrity, this.opts) } - async [_chown] (path, uid, gid) { - return selfOwner && (selfOwner.gid !== gid || selfOwner.uid !== uid) - ? chownr(path, uid, gid) - : /* istanbul ignore next - we don't test in root-owned folders */ null - } - [_empty] (path) { - return getContents({path, depth: 1}).then(contents => Promise.all( - contents.map(entry => rimraf(entry)))) + return getContents({ path, depth: 1 }).then(contents => Promise.all( + contents.map(entry => fs.rm(entry, { recursive: true, force: true })))) } - [_mkdir] (dest) { - // if we're bothering to do owner inference, then do it. - // otherwise just make the dir, and return an empty object. - // always empty the dir dir to start with, but do so - // _after_ inferring the owner, in case there's an existing folder - // there that we would want to preserve which differs from the - // parent folder (rare, but probably happens sometimes). - return !inferOwner - ? this[_empty](dest).then(() => mkdirp(dest)).then(() => ({})) - : inferOwner(dest).then(({uid, gid}) => - this[_empty](dest) - .then(() => mkdirp(dest)) - .then(made => { - // ignore the || dest part in coverage. It's there to handle - // race conditions where the dir may be made by someone else - // after being removed by us. - const dir = made || /* istanbul ignore next */ dest - return this[_chown](dir, uid, gid) - }) - .then(() => ({uid, gid}))) + async [_mkdir] (dest) { + await this[_empty](dest) + return await fs.mkdir(dest, { recursive: true }) } // extraction is always the same. the only difference is where // the tarball comes from. - extract (dest) { - return this[_mkdir](dest).then(({uid, gid}) => - this.tarballStream(tarball => this[_extract](dest, tarball, uid, gid))) + async extract (dest) { + await this[_mkdir](dest) + return this.tarballStream((tarball) => this[_extract](dest, tarball)) } [_toFile] (dest) { @@ -385,18 +382,14 @@ class FetcherBase { } // don't use this[_mkdir] because we don't want to rimraf anything - tarballFile (dest) { + async tarballFile (dest) { const dir = dirname(dest) - return !inferOwner - ? mkdirp(dir).then(() => this[_toFile](dest)) - : inferOwner(dest).then(({uid, gid}) => - mkdirp(dir).then(made => this[_toFile](dest) - .then(res => this[_chown](made || dir, uid, gid) - .then(() => res)))) + await fs.mkdir(dir, { recursive: true }) + return this[_toFile](dest) } - [_extract] (dest, tarball, uid, gid) { - const extractor = tar.x(this[_tarxOptions]({ cwd: dest, uid, gid })) + [_extract] (dest, tarball) { + const extractor = tar.x(this[_tarxOptions]({ cwd: dest })) const p = new Promise((resolve, reject) => { extractor.on('end', () => { resolve({ @@ -407,8 +400,8 @@ class FetcherBase { }) extractor.on('error', er => { - this.log.warn('tar', er.message) - this.log.silly('tar', er) + log.warn('tar', er.message) + log.silly('tar', er) reject(er) }) @@ -439,21 +432,23 @@ class FetcherBase { noChmod: true, noMtime: true, filter: (name, entry) => { - if (/Link$/.test(entry.type)) + if (/Link$/.test(entry.type)) { return false + } entry.mode = this[_entryMode](entry.path, entry.mode, entry.type) // this replicates the npm pack behavior where .gitignore files // are treated like .npmignore files, but only if a .npmignore // file is not present. if (/File$/.test(entry.type)) { const base = basename(entry.path) - if (base === '.npmignore') + if (base === '.npmignore') { sawIgnores.add(entry.path) - else if (base === '.gitignore' && !this.allowGitIgnore) { + } else if (base === '.gitignore' && !this.allowGitIgnore) { // rename, but only if there's not already a .npmignore const ni = entry.path.replace(/\.gitignore$/, '.npmignore') - if (sawIgnores.has(ni)) + if (sawIgnores.has(ni)) { return false + } entry.path = ni } return true @@ -462,8 +457,8 @@ class FetcherBase { strip: 1, onwarn: /* istanbul ignore next - we can trust that tar logs */ (code, msg, data) => { - this.log.warn('tar', code, msg) - this.log.silly('tar', code, msg, data) + log.warn('tar', code, msg) + log.silly('tar', code, msg, data) }, uid, gid, diff --git a/node_modules/pacote/lib/file.js b/node_modules/pacote/lib/file.js index d5c601a..bf99bb8 100644 --- a/node_modules/pacote/lib/file.js +++ b/node_modules/pacote/lib/file.js @@ -1,12 +1,11 @@ const Fetcher = require('./fetcher.js') const fsm = require('fs-minipass') const cacache = require('cacache') -const { promisify } = require('util') -const readPackageJson = require('read-package-json-fast') const _tarballFromResolved = Symbol.for('pacote.Fetcher._tarballFromResolved') const _exeBins = Symbol('_exeBins') const { resolve } = require('path') const fs = require('fs') +const _readPackageJson = Symbol.for('package.Fetcher._readPackageJson') class FileFetcher extends Fetcher { constructor (spec, opts) { @@ -20,24 +19,26 @@ class FileFetcher extends Fetcher { } manifest () { - if (this.package) + if (this.package) { return Promise.resolve(this.package) + } // have to unpack the tarball for this. return cacache.tmp.withTmp(this.cache, this.opts, dir => this.extract(dir) - .then(() => readPackageJson(dir + '/package.json')) - .then(mani => this.package = { - ...mani, - _integrity: this.integrity && String(this.integrity), - _resolved: this.resolved, - _from: this.from, - })) + .then(() => this[_readPackageJson](dir + '/package.json')) + .then(mani => this.package = { + ...mani, + _integrity: this.integrity && String(this.integrity), + _resolved: this.resolved, + _from: this.from, + })) } [_exeBins] (pkg, dest) { - if (!pkg.bin) + if (!pkg.bin) { return Promise.resolve() + } return Promise.all(Object.keys(pkg.bin).map(k => new Promise(res => { const script = resolve(dest, pkg.bin[k]) @@ -46,11 +47,13 @@ class FileFetcher extends Fetcher { // something, we just leave it for a later stage to trip over // when we can provide a more useful contextual error. fs.stat(script, (er, st) => { - if (er) + if (er) { return res() + } const mode = st.mode | 0o111 - if (mode === st.mode) + if (mode === st.mode) { return res() + } fs.chmod(script, mode, res) }) }))) @@ -61,8 +64,8 @@ class FileFetcher extends Fetcher { // but if not, read the unpacked manifest and chmod properly. return super.extract(dest) .then(result => this.package ? result - : readPackageJson(dest + '/package.json').then(pkg => - this[_exeBins](pkg, dest)).then(() => result)) + : this[_readPackageJson](dest + '/package.json').then(pkg => + this[_exeBins](pkg, dest)).then(() => result)) } [_tarballFromResolved] () { @@ -75,7 +78,7 @@ class FileFetcher extends Fetcher { return this.manifest().then(mani => ({ name: mani.name, 'dist-tags': { - [this.defaultTag]: mani.version + [this.defaultTag]: mani.version, }, versions: { [mani.version]: { @@ -83,9 +86,9 @@ class FileFetcher extends Fetcher { dist: { tarball: `file:${this.resolved}`, integrity: this.integrity && String(this.integrity), - } - } - } + }, + }, + }, })) } } diff --git a/node_modules/pacote/lib/git.js b/node_modules/pacote/lib/git.js index ab87d49..1fa8b1f 100644 --- a/node_modules/pacote/lib/git.js +++ b/node_modules/pacote/lib/git.js @@ -6,11 +6,9 @@ const hashre = /^[a-f0-9]{40}$/ const git = require('@npmcli/git') const pickManifest = require('npm-pick-manifest') const npa = require('npm-package-arg') -const url = require('url') const Minipass = require('minipass') const cacache = require('cacache') -const { promisify } = require('util') -const readPackageJson = require('read-package-json-fast') +const log = require('proc-log') const npm = require('./util/npm.js') const _resolvedFromRepo = Symbol('_resolvedFromRepo') @@ -24,6 +22,7 @@ const _cloneHosted = Symbol('_cloneHosted') const _cloneRepo = Symbol('_cloneRepo') const _setResolvedWithSha = Symbol('_setResolvedWithSha') const _prepareDir = Symbol('_prepareDir') +const _readPackageJson = Symbol.for('package.Fetcher._readPackageJson') // get the repository url. // prefer https if there's auth, since ssh will drop that. @@ -39,9 +38,17 @@ const addGitPlus = url => url && `git+${url}`.replace(/^(git\+)+/, 'git+') class GitFetcher extends Fetcher { constructor (spec, opts) { super(spec, opts) + + // we never want to compare integrity for git dependencies: npm/rfcs#525 + if (this.opts.integrity) { + delete this.opts.integrity + log.warn(`skipping integrity check for git dependency ${this.spec.fetchSpec}`) + } + this.resolvedRef = null - if (this.spec.hosted) + if (this.spec.hosted) { this.from = this.spec.hosted.shortcut({ noCommittish: false }) + } // shortcut: avoid full clone when we can go straight to the tgz // if we have the full sha and it's a hosted git platform @@ -51,8 +58,11 @@ class GitFetcher extends Fetcher { this.resolved = this.spec.hosted ? repoUrl(this.spec.hosted, { noCommittish: false }) : this.spec.rawSpec - } else + } else { this.resolvedSha = '' + } + + this.Arborist = opts.Arborist || null } // just exposed to make it easier to test all the combinations @@ -67,8 +77,9 @@ class GitFetcher extends Fetcher { resolve () { // likely a hosted git repo with a sha, so get the tarball url // but in general, no reason to resolve() more than necessary! - if (this.resolved) + if (this.resolved) { return super.resolve() + } // fetch the git repo and then look at the current hash const h = this.spec.hosted @@ -86,37 +97,41 @@ class GitFetcher extends Fetcher { return this[_resolvedFromRepo](hosted.https && hosted.https()) .catch(er => { // Throw early since we know pathspec errors will fail again if retried - if (er instanceof git.errors.GitPathspecError) + if (er instanceof git.errors.GitPathspecError) { throw er + } const ssh = hosted.sshurl && hosted.sshurl() // no fallthrough if we can't fall through or have https auth - if (!ssh || hosted.auth) + if (!ssh || hosted.auth) { throw er + } return this[_resolvedFromRepo](ssh) }) } [_resolvedFromRepo] (gitRemote) { // XXX make this a custom error class - if (!gitRemote) + if (!gitRemote) { return Promise.reject(new Error(`No git url for ${this.spec}`)) + } const gitRange = this.spec.gitRange const name = this.spec.name return git.revs(gitRemote, this.opts).then(remoteRefs => { return gitRange ? pickManifest({ - versions: remoteRefs.versions, - 'dist-tags': remoteRefs['dist-tags'], - name, - }, gitRange, this.opts) + versions: remoteRefs.versions, + 'dist-tags': remoteRefs['dist-tags'], + name, + }, gitRange, this.opts) : this.spec.gitCommittish ? remoteRefs.refs[this.spec.gitCommittish] || remoteRefs.refs[remoteRefs.shas[this.spec.gitCommittish]] - : remoteRefs.refs.HEAD // no git committish, get default head + : remoteRefs.refs.HEAD // no git committish, get default head }).then(revDoc => { // the committish provided isn't in the rev list // things like HEAD~3 or @yesterday can land here. - if (!revDoc || !revDoc.sha) + if (!revDoc || !revDoc.sha) { return this[_resolvedFromClone]() + } this.resolvedRef = revDoc this.resolvedSha = revDoc.sha @@ -145,16 +160,18 @@ class GitFetcher extends Fetcher { } [_prepareDir] (dir) { - return readPackageJson(dir + '/package.json').then(mani => { + return this[_readPackageJson](dir + '/package.json').then(mani => { // no need if we aren't going to do any preparation. const scripts = mani.scripts - if (!scripts || !( - scripts.postinstall || + if (!mani.workspaces && (!scripts || !( + scripts.postinstall || scripts.build || scripts.preinstall || scripts.install || - scripts.prepare)) + scripts.prepack || + scripts.prepare))) { return + } // to avoid cases where we have an cycle of git deps that depend // on one another, we only ever do preparation for one instance @@ -166,7 +183,7 @@ class GitFetcher extends Fetcher { const noPrepare = !process.env._PACOTE_NO_PREPARE_ ? [] : process.env._PACOTE_NO_PREPARE_.split('\n') if (noPrepare.includes(this.resolved)) { - this.log.info('prepare', 'skip prepare, already seen', this.resolved) + log.info('prepare', 'skip prepare, already seen', this.resolved) return } noPrepare.push(this.resolved) @@ -186,14 +203,17 @@ class GitFetcher extends Fetcher { [_tarballFromResolved] () { const stream = new Minipass() stream.resolved = this.resolved - stream.integrity = this.integrity stream.from = this.from // check it out and then shell out to the DirFetcher tarball packer this[_clone](dir => this[_prepareDir](dir) .then(() => new Promise((res, rej) => { + if (!this.Arborist) { + throw new Error('GitFetcher requires an Arborist constructor to pack a tarball') + } const df = new DirFetcher(`file:${dir}`, { ...this.opts, + Arborist: this.Arborist, resolved: null, integrity: null, }) @@ -202,9 +222,9 @@ class GitFetcher extends Fetcher { dirStream.on('end', res) dirStream.pipe(stream) }))).catch( - /* istanbul ignore next: very unlikely and hard to test */ - er => stream.emit('error', er) - ) + /* istanbul ignore next: very unlikely and hard to test */ + er => stream.emit('error', er) + ) return stream } @@ -225,7 +245,7 @@ class GitFetcher extends Fetcher { tarballOk = tarballOk && h && resolved === repoUrl(h, { noCommittish: false }) && h.tarball - return cacache.tmp.withTmp(this.cache, o, tmp => { + return cacache.tmp.withTmp(this.cache, o, async tmp => { // if we're resolved, and have a tarball url, shell out to RemoteFetcher if (tarballOk) { const nameat = this.spec.name ? `${this.spec.name}@` : '' @@ -237,22 +257,23 @@ class GitFetcher extends Fetcher { integrity: null, // it'll always be different, if we have one }).extract(tmp).then(() => handler(tmp), er => { // fall back to ssh download if tarball fails - if (er.constructor.name.match(/^Http/)) + if (er.constructor.name.match(/^Http/)) { return this[_clone](handler, false) - else + } else { throw er + } }) } - return ( + const sha = await ( h ? this[_cloneHosted](ref, tmp) : this[_cloneRepo](this.spec.fetchSpec, ref, tmp) - ).then(sha => { - this.resolvedSha = sha - if (!this.resolved) - this[_addGitSha](sha) - }) - .then(() => handler(tmp)) + ) + this.resolvedSha = sha + if (!this.resolved) { + await this[_addGitSha](sha) + } + return handler(tmp) }) } @@ -266,12 +287,14 @@ class GitFetcher extends Fetcher { return this[_cloneRepo](hosted.https({ noCommittish: true }), ref, tmp) .catch(er => { // Throw early since we know pathspec errors will fail again if retried - if (er instanceof git.errors.GitPathspecError) + if (er instanceof git.errors.GitPathspecError) { throw er + } const ssh = hosted.sshurl && hosted.sshurl({ noCommittish: true }) // no fallthrough if we can't fall through or have https auth - if (!ssh || hosted.auth) + if (!ssh || hosted.auth) { throw er + } return this[_cloneRepo](ssh, ref, tmp) }) } @@ -282,19 +305,19 @@ class GitFetcher extends Fetcher { } manifest () { - if (this.package) + if (this.package) { return Promise.resolve(this.package) + } return this.spec.hosted && this.resolved ? FileFetcher.prototype.manifest.apply(this) : this[_clone](dir => - readPackageJson(dir + '/package.json') - .then(mani => this.package = { - ...mani, - _integrity: this.integrity && String(this.integrity), - _resolved: this.resolved, - _from: this.from, - })) + this[_readPackageJson](dir + '/package.json') + .then(mani => this.package = { + ...mani, + _resolved: this.resolved, + _from: this.from, + })) } packument () { diff --git a/node_modules/pacote/lib/registry.js b/node_modules/pacote/lib/registry.js index e0a3107..c4c9df8 100644 --- a/node_modules/pacote/lib/registry.js +++ b/node_modules/pacote/lib/registry.js @@ -2,11 +2,11 @@ const Fetcher = require('./fetcher.js') const RemoteFetcher = require('./remote.js') const _tarballFromResolved = Symbol.for('pacote.Fetcher._tarballFromResolved') const pacoteVersion = require('../package.json').version -const npa = require('npm-package-arg') +const removeTrailingSlashes = require('./util/trailing-slashes.js') const rpj = require('read-package-json-fast') const pickManifest = require('npm-pick-manifest') const ssri = require('ssri') -const Minipass = require('minipass') +const crypto = require('crypto') // Corgis are cute. 🐕🐶 const corgiDoc = 'application/vnd.npm.install-v1+json; q=1.0, application/json; q=0.8, */*' @@ -14,8 +14,6 @@ const fullDoc = 'application/json' const fetch = require('npm-registry-fetch') -// TODO: memoize reg requests, so we don't even have to check cache - const _headers = Symbol('_headers') class RegistryFetcher extends Fetcher { constructor (spec, opts) { @@ -29,35 +27,34 @@ class RegistryFetcher extends Fetcher { // already. this.packumentCache = this.opts.packumentCache || null - // handle case when npm-package-arg guesses wrong. - if (this.spec.type === 'tag' && - this.spec.rawSpec === '' && - this.defaultTag !== 'latest') - this.spec = npa(`${this.spec.name}@${this.defaultTag}`) this.registry = fetch.pickRegistry(spec, opts) - this.packumentUrl = this.registry.replace(/\/*$/, '/') + + this.packumentUrl = removeTrailingSlashes(this.registry) + '/' + this.spec.escapedName + const parsed = new URL(this.registry) + const regKey = `//${parsed.host}${parsed.pathname}` + // unlike the nerf-darted auth keys, this one does *not* allow a mismatch + // of trailing slashes. It must match exactly. + if (this.opts[`${regKey}:_keys`]) { + this.registryKeys = this.opts[`${regKey}:_keys`] + } + // XXX pacote <=9 has some logic to ignore opts.resolved if // the resolved URL doesn't go to the same registry. // Consider reproducing that here, to throw away this.resolved // in that case. } - resolve () { - if (this.resolved) - return Promise.resolve(this.resolved) - - // fetching the manifest sets resolved and (usually) integrity - return this.manifest().then(() => { - if (this.resolved) - return this.resolved - + async resolve () { + // fetching the manifest sets resolved and (if present) integrity + await this.manifest() + if (!this.resolved) { throw Object.assign( new Error('Invalid package manifest: no `dist.tarball` field'), { package: this.spec.toString() } ) - }) + } + return this.resolved } [_headers] () { @@ -77,89 +74,138 @@ class RegistryFetcher extends Fetcher { // note this might be either an in-flight promise for a request, // or the actual packument, but we never want to make more than // one request at a time for the same thing regardless. - if (this.packumentCache && this.packumentCache.has(this.packumentUrl)) + if (this.packumentCache && this.packumentCache.has(this.packumentUrl)) { return this.packumentCache.get(this.packumentUrl) + } // npm-registry-fetch the packument // set the appropriate header for corgis if fullMetadata isn't set // return the res.json() promise - const p = fetch(this.packumentUrl, { - ...this.opts, - headers: this[_headers](), - spec: this.spec, - // never check integrity for packuments themselves - integrity: null, - }).then(res => res.json().then(packument => { - packument._cached = res.headers.has('x-local-cache') + try { + const res = await fetch(this.packumentUrl, { + ...this.opts, + headers: this[_headers](), + spec: this.spec, + // never check integrity for packuments themselves + integrity: null, + }) + const packument = await res.json() packument._contentLength = +res.headers.get('content-length') - if (this.packumentCache) + if (this.packumentCache) { this.packumentCache.set(this.packumentUrl, packument) - return packument - })).catch(er => { - if (this.packumentCache) - this.packumentCache.delete(this.packumentUrl) - if (er.code === 'E404' && !this.fullMetadata) { - // possible that corgis are not supported by this registry - this.fullMetadata = true - return this.packument() } - throw er - }) - if (this.packumentCache) - this.packumentCache.set(this.packumentUrl, p) - return p + return packument + } catch (err) { + if (this.packumentCache) { + this.packumentCache.delete(this.packumentUrl) + } + if (err.code !== 'E404' || this.fullMetadata) { + throw err + } + // possible that corgis are not supported by this registry + this.fullMetadata = true + return this.packument() + } } - manifest () { - if (this.package) - return Promise.resolve(this.package) + async manifest () { + if (this.package) { + return this.package + } - return this.packument() - .then(packument => pickManifest(packument, this.spec.fetchSpec, { - ...this.opts, - defaultTag: this.defaultTag, - before: this.before, - }) /* XXX add ETARGET and E403 revalidation of cached packuments here */) - .then(mani => { - // add _resolved and _integrity from dist object - const { dist } = mani - if (dist) { - this.resolved = mani._resolved = dist.tarball - mani._from = this.from - const distIntegrity = dist.integrity ? ssri.parse(dist.integrity) - : dist.shasum ? ssri.fromHex(dist.shasum, 'sha1', {...this.opts}) - : null - if (distIntegrity) { - if (!this.integrity) - this.integrity = distIntegrity - else if (!this.integrity.match(distIntegrity)) { - // only bork if they have algos in common. - // otherwise we end up breaking if we have saved a sha512 - // previously for the tarball, but the manifest only - // provides a sha1, which is possible for older publishes. - // Otherwise, this is almost certainly a case of holding it - // wrong, and will result in weird or insecure behavior - // later on when building package tree. - for (const algo of Object.keys(this.integrity)) { - if (distIntegrity[algo]) { - throw Object.assign(new Error( - `Integrity checksum failed when using ${algo}: `+ - `wanted ${this.integrity} but got ${distIntegrity}.` - ), { code: 'EINTEGRITY' }) - } - } - // made it this far, the integrity is worthwhile. accept it. - // the setter here will take care of merging it into what we - // already had. - this.integrity = distIntegrity + const packument = await this.packument() + let mani = await pickManifest(packument, this.spec.fetchSpec, { + ...this.opts, + defaultTag: this.defaultTag, + before: this.before, + }) + mani = rpj.normalize(mani) + /* XXX add ETARGET and E403 revalidation of cached packuments here */ + + // add _resolved and _integrity from dist object + const { dist } = mani + if (dist) { + this.resolved = mani._resolved = dist.tarball + mani._from = this.from + const distIntegrity = dist.integrity ? ssri.parse(dist.integrity) + : dist.shasum ? ssri.fromHex(dist.shasum, 'sha1', { ...this.opts }) + : null + if (distIntegrity) { + if (this.integrity && !this.integrity.match(distIntegrity)) { + // only bork if they have algos in common. + // otherwise we end up breaking if we have saved a sha512 + // previously for the tarball, but the manifest only + // provides a sha1, which is possible for older publishes. + // Otherwise, this is almost certainly a case of holding it + // wrong, and will result in weird or insecure behavior + // later on when building package tree. + for (const algo of Object.keys(this.integrity)) { + if (distIntegrity[algo]) { + throw Object.assign(new Error( + `Integrity checksum failed when using ${algo}: ` + + `wanted ${this.integrity} but got ${distIntegrity}.` + ), { code: 'EINTEGRITY' }) } } } - if (this.integrity) - mani._integrity = String(this.integrity) - this.package = rpj.normalize(mani) - return this.package - }) + // made it this far, the integrity is worthwhile. accept it. + // the setter here will take care of merging it into what we already + // had. + this.integrity = distIntegrity + } + } + if (this.integrity) { + mani._integrity = String(this.integrity) + if (dist.signatures) { + if (this.opts.verifySignatures) { + // validate and throw on error, then set _signatures + const message = `${mani._id}:${mani._integrity}` + for (const signature of dist.signatures) { + const publicKey = this.registryKeys && + this.registryKeys.filter(key => (key.keyid === signature.keyid))[0] + if (!publicKey) { + throw Object.assign(new Error( + `${mani._id} has a registry signature with keyid: ${signature.keyid} ` + + 'but no corresponding public key can be found' + ), { code: 'EMISSINGSIGNATUREKEY' }) + } + const validPublicKey = + !publicKey.expires || (Date.parse(publicKey.expires) > Date.now()) + if (!validPublicKey) { + throw Object.assign(new Error( + `${mani._id} has a registry signature with keyid: ${signature.keyid} ` + + `but the corresponding public key has expired ${publicKey.expires}` + ), { code: 'EEXPIREDSIGNATUREKEY' }) + } + const verifier = crypto.createVerify('SHA256') + verifier.write(message) + verifier.end() + const valid = verifier.verify( + publicKey.pemkey, + signature.sig, + 'base64' + ) + if (!valid) { + throw Object.assign(new Error( + `${mani._id} has an invalid registry signature with ` + + `keyid: ${publicKey.keyid} and signature: ${signature.sig}` + ), { + code: 'EINTEGRITYSIGNATURE', + keyid: publicKey.keyid, + signature: signature.sig, + resolved: mani._resolved, + integrity: mani._integrity, + }) + } + } + mani._signatures = dist.signatures + } else { + mani._signatures = dist.signatures + } + } + } + this.package = mani + return this.package } [_tarballFromResolved] () { diff --git a/node_modules/pacote/lib/remote.js b/node_modules/pacote/lib/remote.js index 727a8bf..a361a9e 100644 --- a/node_modules/pacote/lib/remote.js +++ b/node_modules/pacote/lib/remote.js @@ -3,10 +3,7 @@ const FileFetcher = require('./file.js') const _tarballFromResolved = Symbol.for('pacote.Fetcher._tarballFromResolved') const pacoteVersion = require('../package.json').version const fetch = require('npm-registry-fetch') -const ssri = require('ssri') const Minipass = require('minipass') -// The default registry URL is a string of great magic. -const magic = /^https?:\/\/registry\.npmjs\.org\// const _cacheFetches = Symbol.for('pacote.Fetcher._cacheFetches') const _headers = Symbol('_headers') @@ -14,8 +11,12 @@ class RemoteFetcher extends Fetcher { constructor (spec, opts) { super(spec, opts) this.resolved = this.spec.fetchSpec - if (magic.test(this.resolved) && !magic.test(this.registry + '/')) - this.resolved = this.resolved.replace(magic, this.registry + '/') + const resolvedURL = new URL(this.resolved) + if (this.replaceRegistryHost !== 'never' + && (this.replaceRegistryHost === 'always' + || this.replaceRegistryHost === resolvedURL.host)) { + this.resolved = new URL(resolvedURL.pathname, this.registry).href + } // nam is a fermented pork sausage that is good to eat const nameat = this.spec.name ? `${this.spec.name}@` : '' @@ -30,23 +31,29 @@ class RemoteFetcher extends Fetcher { [_tarballFromResolved] () { const stream = new Minipass() + stream.hasIntegrityEmitter = true + const fetchOpts = { ...this.opts, headers: this[_headers](), spec: this.spec, integrity: this.integrity, - algorithms: [ this.pickIntegrityAlgorithm() ], + algorithms: [this.pickIntegrityAlgorithm()], } - fetch(this.resolved, fetchOpts).then(res => { - const hash = res.headers.get('x-local-cache-hash') - if (hash) { - this.integrity = decodeURIComponent(hash) - } + // eslint-disable-next-line promise/always-return + fetch(this.resolved, fetchOpts).then(res => { res.body.on('error', /* istanbul ignore next - exceedingly rare and hard to simulate */ er => stream.emit('error', er) - ).pipe(stream) + ) + + res.body.on('integrity', i => { + this.integrity = i + stream.emit('integrity', i) + }) + + res.body.pipe(stream) }).catch(er => stream.emit('error', er)) return stream @@ -62,7 +69,7 @@ class RemoteFetcher extends Fetcher { 'pacote-req-type': 'tarball', 'pacote-pkg-id': this.pkgid, ...(this.integrity ? { 'pacote-integrity': String(this.integrity) } - : {}), + : {}), ...(this.opts.headers || {}), } } diff --git a/node_modules/pacote/lib/util/cache-dir.js b/node_modules/pacote/lib/util/cache-dir.js index abd2453..4236213 100644 --- a/node_modules/pacote/lib/util/cache-dir.js +++ b/node_modules/pacote/lib/util/cache-dir.js @@ -1,5 +1,5 @@ const os = require('os') -const {resolve} = require('path') +const { resolve } = require('path') module.exports = (fakePlatform = false) => { const temp = os.tmpdir() diff --git a/node_modules/pacote/lib/util/is-package-bin.js b/node_modules/pacote/lib/util/is-package-bin.js index 35cf064..49a3f73 100644 --- a/node_modules/pacote/lib/util/is-package-bin.js +++ b/node_modules/pacote/lib/util/is-package-bin.js @@ -12,10 +12,11 @@ const binObj = (name, bin) => const hasBin = (pkg, path) => { const bin = binObj(pkg.name, pkg.bin) - const p = path.replace(/^[^\\\/]*\//, '') - for (const [k, v] of Object.entries(bin)) { - if (v === p) + const p = path.replace(/^[^\\/]*\//, '') + for (const kv of Object.entries(bin)) { + if (kv[1] === p) { return true + } } return false } diff --git a/node_modules/pacote/lib/util/npm.js b/node_modules/pacote/lib/util/npm.js index f2f29bd..a3005c2 100644 --- a/node_modules/pacote/lib/util/npm.js +++ b/node_modules/pacote/lib/util/npm.js @@ -1,6 +1,5 @@ // run an npm command const spawn = require('@npmcli/promise-spawn') -const {dirname} = require('path') module.exports = (npmBin, npmCommand, cwd, env, extra) => { const isJS = npmBin.endsWith('.js') @@ -11,5 +10,5 @@ module.exports = (npmBin, npmCommand, cwd, env, extra) => { // in temp directories. this lets us link previously-seen repos that // are also being prepared. - return spawn(cmd, args, { cwd, stdioString: true, env }, extra) + return spawn(cmd, args, { cwd, env }, extra) } diff --git a/node_modules/pacote/lib/util/proc-log.js b/node_modules/pacote/lib/util/proc-log.js deleted file mode 100644 index b2bdd9d..0000000 --- a/node_modules/pacote/lib/util/proc-log.js +++ /dev/null @@ -1,21 +0,0 @@ -// default logger. -// emits 'log' events on the process -const LEVELS = [ - 'notice', - 'error', - 'warn', - 'info', - 'verbose', - 'http', - 'silly', - 'pause', - 'resume' -] - -const log = level => (...args) => process.emit('log', level, ...args) - -const logger = {} -for (const level of LEVELS) { - logger[level] = log(level) -} -module.exports = logger diff --git a/node_modules/pacote/lib/util/tar-create-options.js b/node_modules/pacote/lib/util/tar-create-options.js index 31ab34c..d070f0f 100644 --- a/node_modules/pacote/lib/util/tar-create-options.js +++ b/node_modules/pacote/lib/util/tar-create-options.js @@ -9,7 +9,7 @@ const tarCreateOptions = manifest => ({ // platform specific optimizations that cause // integrity mismatch errors due to differing // end results after compression - level: 9 + level: 9, }, // ensure that package bins are always executable @@ -17,8 +17,9 @@ const tarCreateOptions = manifest => ({ // anything that is not a regular file, ignored by // .npmignore or package.json "files", etc. filter: (path, stat) => { - if (isPackageBin(manifest, path)) + if (isPackageBin(manifest, path)) { stat.mode |= 0o111 + } return true }, diff --git a/node_modules/pacote/lib/util/trailing-slashes.js b/node_modules/pacote/lib/util/trailing-slashes.js new file mode 100644 index 0000000..c50cb61 --- /dev/null +++ b/node_modules/pacote/lib/util/trailing-slashes.js @@ -0,0 +1,10 @@ +const removeTrailingSlashes = (input) => { + // in order to avoid regexp redos detection + let output = input + while (output.endsWith('/')) { + output = output.slice(0, -1) + } + return output +} + +module.exports = removeTrailingSlashes diff --git a/node_modules/pacote/package.json b/node_modules/pacote/package.json index ffbc067..7767513 100644 --- a/node_modules/pacote/package.json +++ b/node_modules/pacote/package.json @@ -1,8 +1,8 @@ { "name": "pacote", - "version": "12.0.3", + "version": "15.0.7", "description": "JavaScript package downloader", - "author": "Isaac Z. Schlueter <i@izs.me> (https://izs.me)", + "author": "GitHub Inc.", "bin": { "pacote": "lib/bin.js" }, @@ -11,21 +11,32 @@ "scripts": { "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags" + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "lintfix": "npm run lint -- --fix", + "posttest": "npm run lint", + "template-oss-apply": "template-oss-apply --force" }, "tap": { "timeout": 300, - "coverage-map": "map.js" + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "devDependencies": { + "@npmcli/arborist": "^6.0.0 || ^6.0.0-pre.0", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.10.0", + "hosted-git-info": "^6.0.0", "mutate-fs": "^2.1.1", - "npm-registry-mock": "^1.3.1", - "tap": "^15.0.4" + "nock": "^13.2.4", + "npm-registry-mock": "^1.3.2", + "tap": "^16.0.1" }, "files": [ - "lib/**/*.js" + "bin/", + "lib/" ], "keywords": [ "packages", @@ -33,28 +44,34 @@ "git" ], "dependencies": { - "@npmcli/git": "^2.1.0", - "@npmcli/installed-package-contents": "^1.0.6", - "@npmcli/promise-spawn": "^1.2.0", - "@npmcli/run-script": "^2.0.0", - "cacache": "^15.0.5", - "chownr": "^2.0.0", + "@npmcli/git": "^4.0.0", + "@npmcli/installed-package-contents": "^2.0.1", + "@npmcli/promise-spawn": "^6.0.1", + "@npmcli/run-script": "^6.0.0", + "cacache": "^17.0.0", "fs-minipass": "^2.1.0", - "infer-owner": "^1.0.4", - "minipass": "^3.1.3", - "mkdirp": "^1.0.3", - "npm-package-arg": "^8.0.1", - "npm-packlist": "^3.0.0", - "npm-pick-manifest": "^6.0.0", - "npm-registry-fetch": "^12.0.0", + "minipass": "^4.0.0", + "npm-package-arg": "^10.0.0", + "npm-packlist": "^7.0.0", + "npm-pick-manifest": "^8.0.0", + "npm-registry-fetch": "^14.0.0", + "proc-log": "^3.0.0", "promise-retry": "^2.0.1", - "read-package-json-fast": "^2.0.1", - "rimraf": "^3.0.2", - "ssri": "^8.0.1", - "tar": "^6.1.0" + "read-package-json": "^6.0.0", + "read-package-json-fast": "^3.0.0", + "ssri": "^10.0.0", + "tar": "^6.1.11" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, - "repository": "git@github.com:npm/pacote" + "repository": { + "type": "git", + "url": "https://github.com/npm/pacote.git" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.10.0", + "windowsCI": false + } } diff --git a/node_modules/parse-conflict-json/package.json b/node_modules/parse-conflict-json/package.json index bb633e1..7b86df8 100644 --- a/node_modules/parse-conflict-json/package.json +++ b/node_modules/parse-conflict-json/package.json @@ -1,6 +1,6 @@ { "name": "parse-conflict-json", - "version": "2.0.1", + "version": "3.0.0", "description": "Parse a JSON string that has git merge conflicts, resolving if possible", "author": "GitHub Inc.", "license": "ISC", @@ -8,37 +8,42 @@ "scripts": { "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "postpublish": "git push origin --follow-tags", - "lint": "eslint '**/*.js'", - "postlint": "npm-template-check", + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", "lintfix": "npm run lint -- --fix", - "prepublishOnly": "git push origin --follow-tags", - "posttest": "npm run lint" + "posttest": "npm run lint", + "template-oss-apply": "template-oss-apply --force" }, "tap": { - "check-coverage": true + "check-coverage": true, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "devDependencies": { - "@npmcli/template-oss": "^2.3.1", - "tap": "^15.1.5" + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", + "tap": "^16.0.1" }, "dependencies": { - "json-parse-even-better-errors": "^2.3.1", + "json-parse-even-better-errors": "^3.0.0", "just-diff": "^5.0.1", - "just-diff-apply": "^4.0.1" + "just-diff-apply": "^5.2.0" }, "repository": { "type": "git", - "url": "git+https://github.com/npm/parse-conflict-json.git" + "url": "https://github.com/npm/parse-conflict-json.git" }, "files": [ - "bin", - "lib" + "bin/", + "lib/" ], - "templateVersion": "2.3.1", "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" } } diff --git a/node_modules/proc-log/LICENSE b/node_modules/proc-log/LICENSE deleted file mode 100644 index 8383779..0000000 --- a/node_modules/proc-log/LICENSE +++ /dev/null @@ -1,15 +0,0 @@ -The ISC License - -Copyright (c) GitHub, Inc. - -Permission to use, copy, modify, and/or distribute this software for any -purpose with or without fee is hereby granted, provided that the above -copyright notice and this permission notice appear in all copies. - -THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR -IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/node_modules/proc-log/index.js b/node_modules/proc-log/index.js deleted file mode 100644 index 9b58713..0000000 --- a/node_modules/proc-log/index.js +++ /dev/null @@ -1,22 +0,0 @@ -// emits 'log' events on the process -const LEVELS = [ - 'notice', - 'error', - 'warn', - 'info', - 'verbose', - 'http', - 'silly', - 'pause', - 'resume', -] - -const log = level => (...args) => process.emit('log', level, ...args) - -const logger = {} -for (const level of LEVELS) - logger[level] = log(level) - -logger.LEVELS = LEVELS - -module.exports = logger diff --git a/node_modules/proc-log/package.json b/node_modules/proc-log/package.json deleted file mode 100644 index 178009f..0000000 --- a/node_modules/proc-log/package.json +++ /dev/null @@ -1,28 +0,0 @@ -{ - "name": "proc-log", - "version": "1.0.0", - "files": [ - "index.js" - ], - "description": "just emit 'log' events on the process object", - "repository": "https://github.com/npm/proc-log", - "author": "Isaac Z. Schlueter <i@izs.me> (https://izs.me)", - "license": "ISC", - "scripts": { - "test": "tap", - "snap": "tap", - "posttest": "eslint index.js test/*.js", - "postsnap": "eslint index.js test/*.js --fix", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags" - }, - "devDependencies": { - "eslint": "^7.9.0", - "eslint-plugin-import": "^2.22.0", - "eslint-plugin-node": "^11.1.0", - "eslint-plugin-promise": "^4.2.1", - "eslint-plugin-standard": "^4.0.1", - "tap": "^15.0.2" - } -} diff --git a/node_modules/process/LICENSE b/node_modules/process/LICENSE new file mode 100644 index 0000000..b8c1246 --- /dev/null +++ b/node_modules/process/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2013 Roman Shtylman <shtylman@gmail.com> + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +'Software'), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/process/browser.js b/node_modules/process/browser.js new file mode 100644 index 0000000..d059362 --- /dev/null +++ b/node_modules/process/browser.js @@ -0,0 +1,184 @@ +// shim for using process in browser +var process = module.exports = {}; + +// cached from whatever global is present so that test runners that stub it +// don't break things. But we need to wrap it in a try catch in case it is +// wrapped in strict mode code which doesn't define any globals. It's inside a +// function because try/catches deoptimize in certain engines. + +var cachedSetTimeout; +var cachedClearTimeout; + +function defaultSetTimout() { + throw new Error('setTimeout has not been defined'); +} +function defaultClearTimeout () { + throw new Error('clearTimeout has not been defined'); +} +(function () { + try { + if (typeof setTimeout === 'function') { + cachedSetTimeout = setTimeout; + } else { + cachedSetTimeout = defaultSetTimout; + } + } catch (e) { + cachedSetTimeout = defaultSetTimout; + } + try { + if (typeof clearTimeout === 'function') { + cachedClearTimeout = clearTimeout; + } else { + cachedClearTimeout = defaultClearTimeout; + } + } catch (e) { + cachedClearTimeout = defaultClearTimeout; + } +} ()) +function runTimeout(fun) { + if (cachedSetTimeout === setTimeout) { + //normal enviroments in sane situations + return setTimeout(fun, 0); + } + // if setTimeout wasn't available but was latter defined + if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) { + cachedSetTimeout = setTimeout; + return setTimeout(fun, 0); + } + try { + // when when somebody has screwed with setTimeout but no I.E. maddness + return cachedSetTimeout(fun, 0); + } catch(e){ + try { + // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally + return cachedSetTimeout.call(null, fun, 0); + } catch(e){ + // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error + return cachedSetTimeout.call(this, fun, 0); + } + } + + +} +function runClearTimeout(marker) { + if (cachedClearTimeout === clearTimeout) { + //normal enviroments in sane situations + return clearTimeout(marker); + } + // if clearTimeout wasn't available but was latter defined + if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) { + cachedClearTimeout = clearTimeout; + return clearTimeout(marker); + } + try { + // when when somebody has screwed with setTimeout but no I.E. maddness + return cachedClearTimeout(marker); + } catch (e){ + try { + // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally + return cachedClearTimeout.call(null, marker); + } catch (e){ + // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error. + // Some versions of I.E. have different rules for clearTimeout vs setTimeout + return cachedClearTimeout.call(this, marker); + } + } + + + +} +var queue = []; +var draining = false; +var currentQueue; +var queueIndex = -1; + +function cleanUpNextTick() { + if (!draining || !currentQueue) { + return; + } + draining = false; + if (currentQueue.length) { + queue = currentQueue.concat(queue); + } else { + queueIndex = -1; + } + if (queue.length) { + drainQueue(); + } +} + +function drainQueue() { + if (draining) { + return; + } + var timeout = runTimeout(cleanUpNextTick); + draining = true; + + var len = queue.length; + while(len) { + currentQueue = queue; + queue = []; + while (++queueIndex < len) { + if (currentQueue) { + currentQueue[queueIndex].run(); + } + } + queueIndex = -1; + len = queue.length; + } + currentQueue = null; + draining = false; + runClearTimeout(timeout); +} + +process.nextTick = function (fun) { + var args = new Array(arguments.length - 1); + if (arguments.length > 1) { + for (var i = 1; i < arguments.length; i++) { + args[i - 1] = arguments[i]; + } + } + queue.push(new Item(fun, args)); + if (queue.length === 1 && !draining) { + runTimeout(drainQueue); + } +}; + +// v8 likes predictible objects +function Item(fun, array) { + this.fun = fun; + this.array = array; +} +Item.prototype.run = function () { + this.fun.apply(null, this.array); +}; +process.title = 'browser'; +process.browser = true; +process.env = {}; +process.argv = []; +process.version = ''; // empty string to avoid regexp issues +process.versions = {}; + +function noop() {} + +process.on = noop; +process.addListener = noop; +process.once = noop; +process.off = noop; +process.removeListener = noop; +process.removeAllListeners = noop; +process.emit = noop; +process.prependListener = noop; +process.prependOnceListener = noop; + +process.listeners = function (name) { return [] } + +process.binding = function (name) { + throw new Error('process.binding is not supported'); +}; + +process.cwd = function () { return '/' }; +process.chdir = function (dir) { + throw new Error('process.chdir is not supported'); +}; +process.umask = function() { return 0; }; diff --git a/node_modules/process/index.js b/node_modules/process/index.js new file mode 100644 index 0000000..8d8ed7d --- /dev/null +++ b/node_modules/process/index.js @@ -0,0 +1,2 @@ +// for now just expose the builtin process global from node.js +module.exports = global.process; diff --git a/node_modules/process/package.json b/node_modules/process/package.json new file mode 100644 index 0000000..d2cfaad --- /dev/null +++ b/node_modules/process/package.json @@ -0,0 +1,27 @@ +{ + "author": "Roman Shtylman <shtylman@gmail.com>", + "name": "process", + "description": "process information for node.js and browsers", + "keywords": [ + "process" + ], + "scripts": { + "test": "mocha test.js", + "browser": "zuul --no-coverage --ui mocha-bdd --local 8080 -- test.js" + }, + "version": "0.11.10", + "repository": { + "type": "git", + "url": "git://github.com/shtylman/node-process.git" + }, + "license": "MIT", + "browser": "./browser.js", + "main": "./index.js", + "engines": { + "node": ">= 0.6.0" + }, + "devDependencies": { + "mocha": "2.2.1", + "zuul": "^3.10.3" + } +} diff --git a/node_modules/process/test.js b/node_modules/process/test.js new file mode 100644 index 0000000..8ba579c --- /dev/null +++ b/node_modules/process/test.js @@ -0,0 +1,199 @@ +var assert = require('assert'); +var ourProcess = require('./browser'); +describe('test against our process', function () { + test(ourProcess); +}); +if (!process.browser) { + describe('test against node', function () { + test(process); + }); + vmtest(); +} +function test (ourProcess) { + describe('test arguments', function () { + it ('works', function (done) { + var order = 0; + + + ourProcess.nextTick(function (num) { + assert.equal(num, order++, 'first one works'); + ourProcess.nextTick(function (num) { + assert.equal(num, order++, 'recursive one is 4th'); + }, 3); + }, 0); + ourProcess.nextTick(function (num) { + assert.equal(num, order++, 'second one starts'); + ourProcess.nextTick(function (num) { + assert.equal(num, order++, 'this is third'); + ourProcess.nextTick(function (num) { + assert.equal(num, order++, 'this is last'); + done(); + }, 5); + }, 4); + }, 1); + ourProcess.nextTick(function (num) { + + assert.equal(num, order++, '3rd schedualed happens after the error'); + }, 2); + }); + }); +if (!process.browser) { + describe('test errors', function (t) { + it ('works', function (done) { + var order = 0; + process.removeAllListeners('uncaughtException'); + process.once('uncaughtException', function(err) { + assert.equal(2, order++, 'error is third'); + ourProcess.nextTick(function () { + assert.equal(5, order++, 'schedualed in error is last'); + done(); + }); + }); + ourProcess.nextTick(function () { + assert.equal(0, order++, 'first one works'); + ourProcess.nextTick(function () { + assert.equal(4, order++, 'recursive one is 4th'); + }); + }); + ourProcess.nextTick(function () { + assert.equal(1, order++, 'second one starts'); + throw(new Error('an error is thrown')); + }); + ourProcess.nextTick(function () { + assert.equal(3, order++, '3rd schedualed happens after the error'); + }); + }); + }); +} + describe('rename globals', function (t) { + var oldTimeout = setTimeout; + var oldClear = clearTimeout; + + it('clearTimeout', function (done){ + + var ok = true; + clearTimeout = function () { + ok = false; + } + var ran = false; + function cleanup() { + clearTimeout = oldClear; + var err; + try { + assert.ok(ok, 'fake clearTimeout ran'); + assert.ok(ran, 'should have run'); + } catch (e) { + err = e; + } + done(err); + } + setTimeout(cleanup, 1000); + ourProcess.nextTick(function () { + ran = true; + }); + }); + it('just setTimeout', function (done){ + + + setTimeout = function () { + setTimeout = oldTimeout; + try { + assert.ok(false, 'fake setTimeout called') + } catch (e) { + done(e); + } + + } + + ourProcess.nextTick(function () { + setTimeout = oldTimeout; + done(); + }); + }); + }); +} +function vmtest() { + var vm = require('vm'); + var fs = require('fs'); + var process = fs.readFileSync('./browser.js', {encoding: 'utf8'}); + + + describe('should work in vm in strict mode with no globals', function () { + it('should parse', function (done) { + var str = '"use strict";var module = {exports:{}};'; + str += process; + str += 'this.works = process.browser;'; + var script = new vm.Script(str); + var context = { + works: false + }; + script.runInNewContext(context); + assert.ok(context.works); + done(); + }); + it('setTimeout throws error', function (done) { + var str = '"use strict";var module = {exports:{}};'; + str += process; + str += 'try {process.nextTick(function () {})} catch (e){this.works = e;}'; + var script = new vm.Script(str); + var context = { + works: false + }; + script.runInNewContext(context); + assert.ok(context.works); + done(); + }); + it('should generally work', function (done) { + var str = '"use strict";var module = {exports:{}};'; + str += process; + str += 'process.nextTick(function () {assert.ok(true);done();})'; + var script = new vm.Script(str); + var context = { + clearTimeout: clearTimeout, + setTimeout: setTimeout, + done: done, + assert: assert + }; + script.runInNewContext(context); + }); + it('late defs setTimeout', function (done) { + var str = '"use strict";var module = {exports:{}};'; + str += process; + str += 'var setTimeout = hiddenSetTimeout;process.nextTick(function () {assert.ok(true);done();})'; + var script = new vm.Script(str); + var context = { + clearTimeout: clearTimeout, + hiddenSetTimeout: setTimeout, + done: done, + assert: assert + }; + script.runInNewContext(context); + }); + it('late defs clearTimeout', function (done) { + var str = '"use strict";var module = {exports:{}};'; + str += process; + str += 'var clearTimeout = hiddenClearTimeout;process.nextTick(function () {assert.ok(true);done();})'; + var script = new vm.Script(str); + var context = { + hiddenClearTimeout: clearTimeout, + setTimeout: setTimeout, + done: done, + assert: assert + }; + script.runInNewContext(context); + }); + it('late defs setTimeout and then redefine', function (done) { + var str = '"use strict";var module = {exports:{}};'; + str += process; + str += 'var setTimeout = hiddenSetTimeout;process.nextTick(function () {setTimeout = function (){throw new Error("foo")};hiddenSetTimeout(function(){process.nextTick(function (){assert.ok(true);done();});});});'; + var script = new vm.Script(str); + var context = { + clearTimeout: clearTimeout, + hiddenSetTimeout: setTimeout, + done: done, + assert: assert + }; + script.runInNewContext(context); + }); + }); +} diff --git a/node_modules/promise-all-reject-late/package-lock.json b/node_modules/promise-all-reject-late/package-lock.json deleted file mode 100644 index 4d485cd..0000000 --- a/node_modules/promise-all-reject-late/package-lock.json +++ /dev/null @@ -1,3447 +0,0 @@ -{ - "name": "promise-all-reject-late", - "version": "1.0.1", - "lockfileVersion": 1, - "requires": true, - "dependencies": { - "@babel/code-frame": { - "version": "7.5.5", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.5.5.tgz", - "integrity": "sha512-27d4lZoomVyo51VegxI20xZPuSHusqbQag/ztrBC7wegWoQ1nLREPVSKSW8byhTlzTKyNE4ifaTA6lCp7JjpFw==", - "dev": true, - "requires": { - "@babel/highlight": "^7.0.0" - } - }, - "@babel/generator": { - "version": "7.7.7", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.7.7.tgz", - "integrity": "sha512-/AOIBpHh/JU1l0ZFS4kiRCBnLi6OTHzh0RPk3h9isBxkkqELtQNFi1Vr/tiG9p1yfoUdKVwISuXWQR+hwwM4VQ==", - "dev": true, - "requires": { - "@babel/types": "^7.7.4", - "jsesc": "^2.5.1", - "lodash": "^4.17.13", - "source-map": "^0.5.0" - }, - "dependencies": { - "source-map": { - "version": "0.5.7", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", - "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", - "dev": true - } - } - }, - "@babel/helper-function-name": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.7.4.tgz", - "integrity": "sha512-AnkGIdiBhEuiwdoMnKm7jfPfqItZhgRaZfMg1XX3bS25INOnLPjPG1Ppnajh8eqgt5kPJnfqrRHqFqmjKDZLzQ==", - "dev": true, - "requires": { - "@babel/helper-get-function-arity": "^7.7.4", - "@babel/template": "^7.7.4", - "@babel/types": "^7.7.4" - } - }, - "@babel/helper-get-function-arity": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.7.4.tgz", - "integrity": "sha512-QTGKEdCkjgzgfJ3bAyRwF4yyT3pg+vDgan8DSivq1eS0gwi+KGKE5x8kRcbeFTb/673mkO5SN1IZfmCfA5o+EA==", - "dev": true, - "requires": { - "@babel/types": "^7.7.4" - } - }, - "@babel/helper-split-export-declaration": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.7.4.tgz", - "integrity": "sha512-guAg1SXFcVr04Guk9eq0S4/rWS++sbmyqosJzVs8+1fH5NI+ZcmkaSkc7dmtAFbHFva6yRJnjW3yAcGxjueDug==", - "dev": true, - "requires": { - "@babel/types": "^7.7.4" - } - }, - "@babel/highlight": { - "version": "7.5.0", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.5.0.tgz", - "integrity": "sha512-7dV4eu9gBxoM0dAnj/BCFDW9LFU0zvTrkq0ugM7pnHEgguOEeOz1so2ZghEdzviYzQEED0r4EAgpsBChKy1TRQ==", - "dev": true, - "requires": { - "chalk": "^2.0.0", - "esutils": "^2.0.2", - "js-tokens": "^4.0.0" - } - }, - "@babel/parser": { - "version": "7.7.7", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.7.7.tgz", - "integrity": "sha512-WtTZMZAZLbeymhkd/sEaPD8IQyGAhmuTuvTzLiCFM7iXiVdY0gc0IaI+cW0fh1BnSMbJSzXX6/fHllgHKwHhXw==", - "dev": true - }, - "@babel/runtime": { - "version": "7.7.7", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.7.7.tgz", - "integrity": "sha512-uCnC2JEVAu8AKB5do1WRIsvrdJ0flYx/A/9f/6chdacnEZ7LmavjdsDXr5ksYBegxtuTPR5Va9/+13QF/kFkCA==", - "dev": true, - "requires": { - "regenerator-runtime": "^0.13.2" - } - }, - "@babel/template": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.7.4.tgz", - "integrity": "sha512-qUzihgVPguAzXCK7WXw8pqs6cEwi54s3E+HrejlkuWO6ivMKx9hZl3Y2fSXp9i5HgyWmj7RKP+ulaYnKM4yYxw==", - "dev": true, - "requires": { - "@babel/code-frame": "^7.0.0", - "@babel/parser": "^7.7.4", - "@babel/types": "^7.7.4" - } - }, - "@babel/traverse": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.7.4.tgz", - "integrity": "sha512-P1L58hQyupn8+ezVA2z5KBm4/Zr4lCC8dwKCMYzsa5jFMDMQAzaBNy9W5VjB+KAmBjb40U7a/H6ao+Xo+9saIw==", - "dev": true, - "requires": { - "@babel/code-frame": "^7.5.5", - "@babel/generator": "^7.7.4", - "@babel/helper-function-name": "^7.7.4", - "@babel/helper-split-export-declaration": "^7.7.4", - "@babel/parser": "^7.7.4", - "@babel/types": "^7.7.4", - "debug": "^4.1.0", - "globals": "^11.1.0", - "lodash": "^4.17.13" - } - }, - "@babel/types": { - "version": "7.7.4", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.7.4.tgz", - "integrity": "sha512-cz5Ji23KCi4T+YIE/BolWosrJuSmoZeN1EFnRtBwF+KKLi8GG/Z2c2hOJJeCXPk4mwk4QFvTmwIodJowXgttRA==", - "dev": true, - "requires": { - "esutils": "^2.0.2", - "lodash": "^4.17.13", - "to-fast-properties": "^2.0.0" - } - }, - "ajv": { - "version": "6.10.2", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.10.2.tgz", - "integrity": "sha512-TXtUUEYHuaTEbLZWIKUr5pmBuhDLy+8KYtPYdcV8qC+pOZL+NKqYwvWSRrVXHn+ZmRRAu8vJTAznH7Oag6RVRw==", - "dev": true, - "requires": { - "fast-deep-equal": "^2.0.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" - } - }, - "ansi-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", - "dev": true - }, - "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "dev": true, - "requires": { - "color-convert": "^1.9.0" - } - }, - "anymatch": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", - "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", - "dev": true, - "requires": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" - } - }, - "append-transform": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/append-transform/-/append-transform-1.0.0.tgz", - "integrity": "sha512-P009oYkeHyU742iSZJzZZywj4QRJdnTWffaKuJQLablCZ1uz6/cW4yaRgcDaoQ+uwOxxnt0gRUcwfsNP2ri0gw==", - "dev": true, - "requires": { - "default-require-extensions": "^2.0.0" - } - }, - "archy": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz", - "integrity": "sha1-+cjBN1fMHde8N5rHeyxipcKGjEA=", - "dev": true - }, - "arg": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.2.tgz", - "integrity": "sha512-+ytCkGcBtHZ3V2r2Z06AncYO8jz46UEamcspGoU8lHcEbpn6J77QK0vdWvChsclg/tM5XIJC5tnjmPp7Eq6Obg==", - "dev": true - }, - "argparse": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", - "dev": true, - "requires": { - "sprintf-js": "~1.0.2" - } - }, - "asn1": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz", - "integrity": "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==", - "dev": true, - "requires": { - "safer-buffer": "~2.1.0" - } - }, - "assert-plus": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", - "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=", - "dev": true - }, - "async-hook-domain": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/async-hook-domain/-/async-hook-domain-1.1.3.tgz", - "integrity": "sha512-ZovMxSbADV3+biB7oR1GL5lGyptI24alp0LWHlmz1OFc5oL47pz3EiIF6nXOkDW7yLqih4NtsiYduzdDW0i+Wg==", - "dev": true, - "requires": { - "source-map-support": "^0.5.11" - } - }, - "asynckit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=", - "dev": true - }, - "aws-sign2": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", - "integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=", - "dev": true - }, - "aws4": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.9.0.tgz", - "integrity": "sha512-Uvq6hVe90D0B2WEnUqtdgY1bATGz3mw33nH9Y+dmA+w5DHvUmBgkr5rM/KCHpCsiFNRUfokW/szpPPgMK2hm4A==", - "dev": true - }, - "balanced-match": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", - "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", - "dev": true - }, - "bcrypt-pbkdf": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", - "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=", - "dev": true, - "requires": { - "tweetnacl": "^0.14.3" - } - }, - "binary-extensions": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.0.0.tgz", - "integrity": "sha512-Phlt0plgpIIBOGTT/ehfFnbNlfsDEiqmzE2KRXoX1bLIlir4X/MR+zSyBEkL05ffWgnRSf/DXv+WrUAVr93/ow==", - "dev": true - }, - "bind-obj-methods": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/bind-obj-methods/-/bind-obj-methods-2.0.0.tgz", - "integrity": "sha512-3/qRXczDi2Cdbz6jE+W3IflJOutRVica8frpBn14de1mBOkzDo+6tY33kNhvkw54Kn3PzRRD2VnGbGPcTAk4sw==", - "dev": true - }, - "brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, - "requires": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "braces": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", - "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", - "dev": true, - "requires": { - "fill-range": "^7.0.1" - } - }, - "browser-process-hrtime": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/browser-process-hrtime/-/browser-process-hrtime-1.0.0.tgz", - "integrity": "sha512-9o5UecI3GhkpM6DrXr69PblIuWxPKk9Y0jHBRhdocZ2y7YECBFCsHm79Pr3OyR2AvjhDkabFJaDJMYRazHgsow==", - "dev": true - }, - "buffer-from": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", - "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==", - "dev": true - }, - "caching-transform": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/caching-transform/-/caching-transform-3.0.2.tgz", - "integrity": "sha512-Mtgcv3lh3U0zRii/6qVgQODdPA4G3zhG+jtbCWj39RXuUFTMzH0vcdMtaJS1jPowd+It2Pqr6y3NJMQqOqCE2w==", - "dev": true, - "requires": { - "hasha": "^3.0.0", - "make-dir": "^2.0.0", - "package-hash": "^3.0.0", - "write-file-atomic": "^2.4.2" - }, - "dependencies": { - "write-file-atomic": { - "version": "2.4.3", - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.4.3.tgz", - "integrity": "sha512-GaETH5wwsX+GcnzhPgKcKjJ6M2Cq3/iZp1WyY/X1CSqrW+jVNM9Y7D8EC2sM4ZG/V8wZlSniJnCKWPmBYAucRQ==", - "dev": true, - "requires": { - "graceful-fs": "^4.1.11", - "imurmurhash": "^0.1.4", - "signal-exit": "^3.0.2" - } - } - } - }, - "camelcase": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", - "dev": true - }, - "caseless": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", - "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=", - "dev": true - }, - "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - } - }, - "chokidar": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.3.1.tgz", - "integrity": "sha512-4QYCEWOcK3OJrxwvyyAOxFuhpvOVCYkr33LPfFNBjAD/w3sEzWsp2BUOkI4l9bHvWioAd0rc6NlHUOEaWkTeqg==", - "dev": true, - "requires": { - "anymatch": "~3.1.1", - "braces": "~3.0.2", - "fsevents": "~2.1.2", - "glob-parent": "~5.1.0", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.3.0" - } - }, - "cliui": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz", - "integrity": "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==", - "dev": true, - "requires": { - "string-width": "^2.1.1", - "strip-ansi": "^4.0.0", - "wrap-ansi": "^2.0.0" - } - }, - "code-point-at": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", - "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", - "dev": true - }, - "color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", - "dev": true, - "requires": { - "color-name": "1.1.3" - } - }, - "color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", - "dev": true - }, - "color-support": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz", - "integrity": "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg==", - "dev": true - }, - "combined-stream": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", - "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", - "dev": true, - "requires": { - "delayed-stream": "~1.0.0" - } - }, - "commander": { - "version": "2.20.3", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", - "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true, - "optional": true - }, - "commondir": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", - "integrity": "sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs=", - "dev": true - }, - "concat-map": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", - "dev": true - }, - "convert-source-map": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.7.0.tgz", - "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==", - "dev": true, - "requires": { - "safe-buffer": "~5.1.1" - }, - "dependencies": { - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true - } - } - }, - "core-util-is": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", - "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", - "dev": true - }, - "coveralls": { - "version": "3.0.9", - "resolved": "https://registry.npmjs.org/coveralls/-/coveralls-3.0.9.tgz", - "integrity": "sha512-nNBg3B1+4iDox5A5zqHKzUTiwl2ey4k2o0NEcVZYvl+GOSJdKBj4AJGKLv6h3SvWch7tABHePAQOSZWM9E2hMg==", - "dev": true, - "requires": { - "js-yaml": "^3.13.1", - "lcov-parse": "^1.0.0", - "log-driver": "^1.2.7", - "minimist": "^1.2.0", - "request": "^2.88.0" - } - }, - "cp-file": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/cp-file/-/cp-file-6.2.0.tgz", - "integrity": "sha512-fmvV4caBnofhPe8kOcitBwSn2f39QLjnAnGq3gO9dfd75mUytzKNZB1hde6QHunW2Rt+OwuBOMc3i1tNElbszA==", - "dev": true, - "requires": { - "graceful-fs": "^4.1.2", - "make-dir": "^2.0.0", - "nested-error-stacks": "^2.0.0", - "pify": "^4.0.1", - "safe-buffer": "^5.0.1" - } - }, - "cross-spawn": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-4.0.2.tgz", - "integrity": "sha1-e5JHYhwjrf3ThWAEqCPL45dCTUE=", - "dev": true, - "requires": { - "lru-cache": "^4.0.1", - "which": "^1.2.9" - }, - "dependencies": { - "which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - } - } - }, - "dashdash": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", - "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0" - } - }, - "debug": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", - "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", - "dev": true, - "requires": { - "ms": "^2.1.1" - } - }, - "decamelize": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", - "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", - "dev": true - }, - "default-require-extensions": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/default-require-extensions/-/default-require-extensions-2.0.0.tgz", - "integrity": "sha1-9fj7sYp9bVCyH2QfZJ67Uiz+JPc=", - "dev": true, - "requires": { - "strip-bom": "^3.0.0" - } - }, - "delayed-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=", - "dev": true - }, - "diff": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.1.tgz", - "integrity": "sha512-s2+XdvhPCOF01LRQBC8hf4vhbVmI2CGS5aZnxLJlT5FtdhPCDFq80q++zK2KlrVorVDdL5BOGZ/VfLrVtYNF+Q==", - "dev": true - }, - "diff-frag": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/diff-frag/-/diff-frag-1.0.1.tgz", - "integrity": "sha512-6/v2PC/6UTGcWPPetb9acL8foberUg/CtPdALeJUdD1B/weHNvzftoo00gYznqHGRhHEbykUGzqfG9RWOSr5yw==", - "dev": true - }, - "ecc-jsbn": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", - "integrity": "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=", - "dev": true, - "requires": { - "jsbn": "~0.1.0", - "safer-buffer": "^2.1.0" - } - }, - "emoji-regex": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", - "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", - "dev": true - }, - "error-ex": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", - "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", - "dev": true, - "requires": { - "is-arrayish": "^0.2.1" - } - }, - "es6-error": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/es6-error/-/es6-error-4.1.1.tgz", - "integrity": "sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg==", - "dev": true - }, - "escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", - "dev": true - }, - "esm": { - "version": "3.2.25", - "resolved": "https://registry.npmjs.org/esm/-/esm-3.2.25.tgz", - "integrity": "sha512-U1suiZ2oDVWv4zPO56S0NcR5QriEahGtdN2OR6FiOG4WJvcjBVFB0qI4+eKoWFH483PKGuLuu6V8Z4T5g63UVA==", - "dev": true - }, - "esprima": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", - "dev": true - }, - "esutils": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", - "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", - "dev": true - }, - "events-to-array": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/events-to-array/-/events-to-array-1.1.2.tgz", - "integrity": "sha1-LUH1Y+H+QA7Uli/hpNXGp1Od9/Y=", - "dev": true - }, - "extend": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", - "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==", - "dev": true - }, - "extsprintf": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", - "integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=", - "dev": true - }, - "fast-deep-equal": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz", - "integrity": "sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk=", - "dev": true - }, - "fast-json-stable-stringify": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", - "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", - "dev": true - }, - "fill-range": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", - "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", - "dev": true, - "requires": { - "to-regex-range": "^5.0.1" - } - }, - "find-cache-dir": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-2.1.0.tgz", - "integrity": "sha512-Tq6PixE0w/VMFfCgbONnkiQIVol/JJL7nRMi20fqzA4NRs9AfeqMGeRdPi3wIhYkxjeBaWh2rxwapn5Tu3IqOQ==", - "dev": true, - "requires": { - "commondir": "^1.0.1", - "make-dir": "^2.0.0", - "pkg-dir": "^3.0.0" - } - }, - "find-up": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", - "dev": true, - "requires": { - "locate-path": "^3.0.0" - } - }, - "findit": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/findit/-/findit-2.0.0.tgz", - "integrity": "sha1-ZQnwEmr0wXhVHPqZOU4DLhOk1W4=", - "dev": true - }, - "flow-parser": { - "version": "0.114.0", - "resolved": "https://registry.npmjs.org/flow-parser/-/flow-parser-0.114.0.tgz", - "integrity": "sha512-Qt9HT3v507bCerJfp4FX4N5E7ysinBzxjpK1rL7bJ/Bw12puF6lva2MAIXYS1d83bV7BT/F7EDk+faJQY5MpRA==", - "dev": true - }, - "flow-remove-types": { - "version": "2.114.0", - "resolved": "https://registry.npmjs.org/flow-remove-types/-/flow-remove-types-2.114.0.tgz", - "integrity": "sha512-ckon8RO7tFcVGW3Ll0jAWgULVrNa/cEN0JXp2I7XmzWT/GCQghSb+0312NjtAb+y3W9iXpPxkVMI86+SDU0E0Q==", - "dev": true, - "requires": { - "flow-parser": "^0.114.0", - "pirates": "^3.0.2", - "vlq": "^0.2.1" - } - }, - "foreground-child": { - "version": "1.5.6", - "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-1.5.6.tgz", - "integrity": "sha1-T9ca0t/elnibmApcCilZN8svXOk=", - "dev": true, - "requires": { - "cross-spawn": "^4", - "signal-exit": "^3.0.0" - } - }, - "forever-agent": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", - "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=", - "dev": true - }, - "form-data": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz", - "integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==", - "dev": true, - "requires": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.6", - "mime-types": "^2.1.12" - } - }, - "fs-exists-cached": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs-exists-cached/-/fs-exists-cached-1.0.0.tgz", - "integrity": "sha1-zyVVTKBQ3EmuZla0HeQiWJidy84=", - "dev": true - }, - "fs.realpath": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", - "dev": true - }, - "fsevents": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.2.tgz", - "integrity": "sha512-R4wDiBwZ0KzpgOWetKDug1FZcYhqYnUYKtfZYt4mD5SBz76q0KR4Q9o7GIPamsVPGmW3EYPPJ0dOOjvx32ldZA==", - "dev": true, - "optional": true - }, - "function-loop": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/function-loop/-/function-loop-1.0.2.tgz", - "integrity": "sha512-Iw4MzMfS3udk/rqxTiDDCllhGwlOrsr50zViTOO/W6lS/9y6B1J0BD2VZzrnWUYBJsl3aeqjgR5v7bWWhZSYbA==", - "dev": true - }, - "get-caller-file": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "dev": true - }, - "getpass": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", - "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0" - } - }, - "glob": { - "version": "7.1.6", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", - "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", - "dev": true, - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - } - }, - "glob-parent": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.0.tgz", - "integrity": "sha512-qjtRgnIVmOfnKUE3NJAQEdk+lKrxfw8t5ke7SXtfMTHcjsBfOfWXCQfdb30zfDoZQ2IRSIiidmjtbHZPZ++Ihw==", - "dev": true, - "requires": { - "is-glob": "^4.0.1" - } - }, - "globals": { - "version": "11.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", - "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", - "dev": true - }, - "graceful-fs": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.3.tgz", - "integrity": "sha512-a30VEBm4PEdx1dRB7MFK7BejejvCvBronbLjht+sHuGYj8PHs7M/5Z+rt5lw551vZ7yfTCj4Vuyy3mSJytDWRQ==", - "dev": true - }, - "handlebars": { - "version": "4.5.3", - "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.5.3.tgz", - "integrity": "sha512-3yPecJoJHK/4c6aZhSvxOyG4vJKDshV36VHp0iVCDVh7o9w2vwi3NSnL2MMPj3YdduqaBcu7cGbggJQM0br9xA==", - "dev": true, - "requires": { - "neo-async": "^2.6.0", - "optimist": "^0.6.1", - "source-map": "^0.6.1", - "uglify-js": "^3.1.4" - } - }, - "har-schema": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz", - "integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=", - "dev": true - }, - "har-validator": { - "version": "5.1.3", - "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz", - "integrity": "sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g==", - "dev": true, - "requires": { - "ajv": "^6.5.5", - "har-schema": "^2.0.0" - } - }, - "has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", - "dev": true - }, - "hasha": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/hasha/-/hasha-3.0.0.tgz", - "integrity": "sha1-UqMvq4Vp1BymmmH/GiFPjrfIvTk=", - "dev": true, - "requires": { - "is-stream": "^1.0.1" - } - }, - "hosted-git-info": { - "version": "2.8.5", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.5.tgz", - "integrity": "sha512-kssjab8CvdXfcXMXVcvsXum4Hwdq9XGtRD3TteMEvEbq0LXyiNQr6AprqKqfeaDXze7SxWvRxdpwE6ku7ikLkg==", - "dev": true - }, - "http-signature": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz", - "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0", - "jsprim": "^1.2.2", - "sshpk": "^1.7.0" - } - }, - "imurmurhash": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=", - "dev": true - }, - "inflight": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", - "dev": true, - "requires": { - "once": "^1.3.0", - "wrappy": "1" - } - }, - "inherits": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "dev": true - }, - "is-arrayish": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", - "integrity": "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=", - "dev": true - }, - "is-binary-path": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", - "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", - "dev": true, - "requires": { - "binary-extensions": "^2.0.0" - } - }, - "is-extglob": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", - "dev": true - }, - "is-fullwidth-code-point": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", - "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", - "dev": true - }, - "is-glob": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", - "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", - "dev": true, - "requires": { - "is-extglob": "^2.1.1" - } - }, - "is-number": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", - "dev": true - }, - "is-stream": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", - "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=", - "dev": true - }, - "is-typedarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", - "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=", - "dev": true - }, - "isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", - "dev": true, - "optional": true - }, - "isexe": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", - "dev": true - }, - "isstream": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", - "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=", - "dev": true - }, - "istanbul-lib-coverage": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.5.tgz", - "integrity": "sha512-8aXznuEPCJvGnMSRft4udDRDtb1V3pkQkMMI5LI+6HuQz5oQ4J2UFn1H82raA3qJtyOLkkwVqICBQkjnGtn5mA==", - "dev": true - }, - "istanbul-lib-hook": { - "version": "2.0.7", - "resolved": "https://registry.npmjs.org/istanbul-lib-hook/-/istanbul-lib-hook-2.0.7.tgz", - "integrity": "sha512-vrRztU9VRRFDyC+aklfLoeXyNdTfga2EI3udDGn4cZ6fpSXpHLV9X6CHvfoMCPtggg8zvDDmC4b9xfu0z6/llA==", - "dev": true, - "requires": { - "append-transform": "^1.0.0" - } - }, - "istanbul-lib-instrument": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-3.3.0.tgz", - "integrity": "sha512-5nnIN4vo5xQZHdXno/YDXJ0G+I3dAm4XgzfSVTPLQpj/zAV2dV6Juy0yaf10/zrJOJeHoN3fraFe+XRq2bFVZA==", - "dev": true, - "requires": { - "@babel/generator": "^7.4.0", - "@babel/parser": "^7.4.3", - "@babel/template": "^7.4.0", - "@babel/traverse": "^7.4.3", - "@babel/types": "^7.4.0", - "istanbul-lib-coverage": "^2.0.5", - "semver": "^6.0.0" - }, - "dependencies": { - "semver": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", - "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", - "dev": true - } - } - }, - "istanbul-lib-processinfo": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/istanbul-lib-processinfo/-/istanbul-lib-processinfo-1.0.0.tgz", - "integrity": "sha512-FY0cPmWa4WoQNlvB8VOcafiRoB5nB+l2Pz2xGuXHRSy1KM8QFOYfz/rN+bGMCAeejrY3mrpF5oJHcN0s/garCg==", - "dev": true, - "requires": { - "archy": "^1.0.0", - "cross-spawn": "^6.0.5", - "istanbul-lib-coverage": "^2.0.3", - "rimraf": "^2.6.3", - "uuid": "^3.3.2" - }, - "dependencies": { - "cross-spawn": { - "version": "6.0.5", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", - "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", - "dev": true, - "requires": { - "nice-try": "^1.0.4", - "path-key": "^2.0.1", - "semver": "^5.5.0", - "shebang-command": "^1.2.0", - "which": "^1.2.9" - } - }, - "which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - } - } - }, - "istanbul-lib-report": { - "version": "2.0.8", - "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-2.0.8.tgz", - "integrity": "sha512-fHBeG573EIihhAblwgxrSenp0Dby6tJMFR/HvlerBsrCTD5bkUuoNtn3gVh29ZCS824cGGBPn7Sg7cNk+2xUsQ==", - "dev": true, - "requires": { - "istanbul-lib-coverage": "^2.0.5", - "make-dir": "^2.1.0", - "supports-color": "^6.1.0" - }, - "dependencies": { - "supports-color": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.1.0.tgz", - "integrity": "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } - } - }, - "istanbul-lib-source-maps": { - "version": "3.0.6", - "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-3.0.6.tgz", - "integrity": "sha512-R47KzMtDJH6X4/YW9XTx+jrLnZnscW4VpNN+1PViSYTejLVPWv7oov+Duf8YQSPyVRUvueQqz1TcsC6mooZTXw==", - "dev": true, - "requires": { - "debug": "^4.1.1", - "istanbul-lib-coverage": "^2.0.5", - "make-dir": "^2.1.0", - "rimraf": "^2.6.3", - "source-map": "^0.6.1" - } - }, - "istanbul-reports": { - "version": "2.2.6", - "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-2.2.6.tgz", - "integrity": "sha512-SKi4rnMyLBKe0Jy2uUdx28h8oG7ph2PPuQPvIAh31d+Ci+lSiEu4C+h3oBPuJ9+mPKhOyW0M8gY4U5NM1WLeXA==", - "dev": true, - "requires": { - "handlebars": "^4.1.2" - } - }, - "jackspeak": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-1.4.0.tgz", - "integrity": "sha512-VDcSunT+wcccoG46FtzuBAyQKlzhHjli4q31e1fIHGOsRspqNUFjVzGb+7eIFDlTvqLygxapDHPHS0ouT2o/tw==", - "dev": true, - "requires": { - "cliui": "^4.1.0" - } - }, - "js-tokens": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true - }, - "js-yaml": { - "version": "3.13.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", - "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", - "dev": true, - "requires": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" - } - }, - "jsbn": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", - "integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=", - "dev": true - }, - "jsesc": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", - "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", - "dev": true - }, - "json-parse-better-errors": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz", - "integrity": "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==", - "dev": true - }, - "json-schema": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz", - "integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=", - "dev": true - }, - "json-schema-traverse": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", - "dev": true - }, - "json-stringify-safe": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", - "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=", - "dev": true - }, - "jsprim": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz", - "integrity": "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=", - "dev": true, - "requires": { - "assert-plus": "1.0.0", - "extsprintf": "1.3.0", - "json-schema": "0.2.3", - "verror": "1.10.0" - } - }, - "lcov-parse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/lcov-parse/-/lcov-parse-1.0.0.tgz", - "integrity": "sha1-6w1GtUER68VhrLTECO+TY73I9+A=", - "dev": true - }, - "load-json-file": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-4.0.0.tgz", - "integrity": "sha1-L19Fq5HjMhYjT9U62rZo607AmTs=", - "dev": true, - "requires": { - "graceful-fs": "^4.1.2", - "parse-json": "^4.0.0", - "pify": "^3.0.0", - "strip-bom": "^3.0.0" - }, - "dependencies": { - "pify": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", - "integrity": "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=", - "dev": true - } - } - }, - "locate-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", - "dev": true, - "requires": { - "p-locate": "^3.0.0", - "path-exists": "^3.0.0" - } - }, - "lodash": { - "version": "4.17.15", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.15.tgz", - "integrity": "sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A==", - "dev": true - }, - "lodash.flattendeep": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz", - "integrity": "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=", - "dev": true - }, - "log-driver": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/log-driver/-/log-driver-1.2.7.tgz", - "integrity": "sha512-U7KCmLdqsGHBLeWqYlFA0V0Sl6P08EE1ZrmA9cxjUE0WVqT9qnyVDPz1kzpFEP0jdJuFnasWIfSd7fsaNXkpbg==", - "dev": true - }, - "loose-envify": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", - "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", - "dev": true, - "requires": { - "js-tokens": "^3.0.0 || ^4.0.0" - } - }, - "lru-cache": { - "version": "4.1.5", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.5.tgz", - "integrity": "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==", - "dev": true, - "requires": { - "pseudomap": "^1.0.2", - "yallist": "^2.1.2" - } - }, - "make-dir": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-2.1.0.tgz", - "integrity": "sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA==", - "dev": true, - "requires": { - "pify": "^4.0.1", - "semver": "^5.6.0" - } - }, - "make-error": { - "version": "1.3.5", - "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.5.tgz", - "integrity": "sha512-c3sIjNUow0+8swNwVpqoH4YCShKNFkMaw6oH1mNS2haDZQqkeZFlHS3dhoeEbKKmJB4vXpJucU6oH75aDYeE9g==", - "dev": true - }, - "merge-source-map": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/merge-source-map/-/merge-source-map-1.1.0.tgz", - "integrity": "sha512-Qkcp7P2ygktpMPh2mCQZaf3jhN6D3Z/qVZHSdWvQ+2Ef5HgRAPBO57A77+ENm0CPx2+1Ce/MYKi3ymqdfuqibw==", - "dev": true, - "requires": { - "source-map": "^0.6.1" - } - }, - "mime-db": { - "version": "1.42.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.42.0.tgz", - "integrity": "sha512-UbfJCR4UAVRNgMpfImz05smAXK7+c+ZntjaA26ANtkXLlOe947Aag5zdIcKQULAiF9Cq4WxBi9jUs5zkA84bYQ==", - "dev": true - }, - "mime-types": { - "version": "2.1.25", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.25.tgz", - "integrity": "sha512-5KhStqB5xpTAeGqKBAMgwaYMnQik7teQN4IAzC7npDv6kzeU6prfkR67bc87J1kWMPGkoaZSq1npmexMgkmEVg==", - "dev": true, - "requires": { - "mime-db": "1.42.0" - } - }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "dev": true, - "requires": { - "brace-expansion": "^1.1.7" - } - }, - "minimist": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", - "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", - "dev": true - }, - "minipass": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.1.1.tgz", - "integrity": "sha512-UFqVihv6PQgwj8/yTGvl9kPz7xIAY+R5z6XYjRInD3Gk3qx6QGSD6zEcpeG4Dy/lQnv1J6zv8ejV90hyYIKf3w==", - "dev": true, - "requires": { - "yallist": "^4.0.0" - }, - "dependencies": { - "yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - } - } - }, - "mkdirp": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", - "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", - "dev": true, - "requires": { - "minimist": "0.0.8" - }, - "dependencies": { - "minimist": { - "version": "0.0.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", - "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", - "dev": true - } - } - }, - "ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "dev": true - }, - "neo-async": { - "version": "2.6.1", - "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.1.tgz", - "integrity": "sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw==", - "dev": true - }, - "nested-error-stacks": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/nested-error-stacks/-/nested-error-stacks-2.1.0.tgz", - "integrity": "sha512-AO81vsIO1k1sM4Zrd6Hu7regmJN1NSiAja10gc4bX3F0wd+9rQmcuHQaHVQCYIEC8iFXnE+mavh23GOt7wBgug==", - "dev": true - }, - "nice-try": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", - "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", - "dev": true - }, - "node-modules-regexp": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz", - "integrity": "sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA=", - "dev": true - }, - "normalize-package-data": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz", - "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", - "dev": true, - "requires": { - "hosted-git-info": "^2.1.4", - "resolve": "^1.10.0", - "semver": "2 || 3 || 4 || 5", - "validate-npm-package-license": "^3.0.1" - } - }, - "normalize-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", - "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", - "dev": true - }, - "number-is-nan": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", - "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", - "dev": true - }, - "nyc": { - "version": "14.1.1", - "resolved": "https://registry.npmjs.org/nyc/-/nyc-14.1.1.tgz", - "integrity": "sha512-OI0vm6ZGUnoGZv/tLdZ2esSVzDwUC88SNs+6JoSOMVxA+gKMB8Tk7jBwgemLx4O40lhhvZCVw1C+OYLOBOPXWw==", - "dev": true, - "requires": { - "archy": "^1.0.0", - "caching-transform": "^3.0.2", - "convert-source-map": "^1.6.0", - "cp-file": "^6.2.0", - "find-cache-dir": "^2.1.0", - "find-up": "^3.0.0", - "foreground-child": "^1.5.6", - "glob": "^7.1.3", - "istanbul-lib-coverage": "^2.0.5", - "istanbul-lib-hook": "^2.0.7", - "istanbul-lib-instrument": "^3.3.0", - "istanbul-lib-report": "^2.0.8", - "istanbul-lib-source-maps": "^3.0.6", - "istanbul-reports": "^2.2.4", - "js-yaml": "^3.13.1", - "make-dir": "^2.1.0", - "merge-source-map": "^1.1.0", - "resolve-from": "^4.0.0", - "rimraf": "^2.6.3", - "signal-exit": "^3.0.2", - "spawn-wrap": "^1.4.2", - "test-exclude": "^5.2.3", - "uuid": "^3.3.2", - "yargs": "^13.2.2", - "yargs-parser": "^13.0.0" - } - }, - "oauth-sign": { - "version": "0.9.0", - "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz", - "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==", - "dev": true - }, - "object-assign": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", - "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", - "dev": true - }, - "once": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", - "dev": true, - "requires": { - "wrappy": "1" - } - }, - "opener": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/opener/-/opener-1.5.1.tgz", - "integrity": "sha512-goYSy5c2UXE4Ra1xixabeVh1guIX/ZV/YokJksb6q2lubWu6UbvPQ20p542/sFIll1nl8JnCyK9oBaOcCWXwvA==", - "dev": true - }, - "optimist": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/optimist/-/optimist-0.6.1.tgz", - "integrity": "sha1-2j6nRob6IaGaERwybpDrFaAZZoY=", - "dev": true, - "requires": { - "minimist": "~0.0.1", - "wordwrap": "~0.0.2" - }, - "dependencies": { - "minimist": { - "version": "0.0.10", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.10.tgz", - "integrity": "sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8=", - "dev": true - } - } - }, - "os-homedir": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", - "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", - "dev": true - }, - "own-or": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/own-or/-/own-or-1.0.0.tgz", - "integrity": "sha1-Tod/vtqaLsgAD7wLyuOWRe6L+Nw=", - "dev": true - }, - "own-or-env": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/own-or-env/-/own-or-env-1.0.1.tgz", - "integrity": "sha512-y8qULRbRAlL6x2+M0vIe7jJbJx/kmUTzYonRAa2ayesR2qWLswninkVyeJe4x3IEXhdgoNodzjQRKAoEs6Fmrw==", - "dev": true, - "requires": { - "own-or": "^1.0.0" - } - }, - "p-limit": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.2.1.tgz", - "integrity": "sha512-85Tk+90UCVWvbDavCLKPOLC9vvY8OwEX/RtKF+/1OADJMVlFfEHOiMTPVyxg7mk/dKa+ipdHm0OUkTvCpMTuwg==", - "dev": true, - "requires": { - "p-try": "^2.0.0" - } - }, - "p-locate": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", - "dev": true, - "requires": { - "p-limit": "^2.0.0" - } - }, - "p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "dev": true - }, - "package-hash": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/package-hash/-/package-hash-3.0.0.tgz", - "integrity": "sha512-lOtmukMDVvtkL84rJHI7dpTYq+0rli8N2wlnqUcBuDWCfVhRUfOmnR9SsoHFMLpACvEV60dX7rd0rFaYDZI+FA==", - "dev": true, - "requires": { - "graceful-fs": "^4.1.15", - "hasha": "^3.0.0", - "lodash.flattendeep": "^4.4.0", - "release-zalgo": "^1.0.0" - } - }, - "parse-json": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz", - "integrity": "sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA=", - "dev": true, - "requires": { - "error-ex": "^1.3.1", - "json-parse-better-errors": "^1.0.1" - } - }, - "path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", - "dev": true - }, - "path-is-absolute": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", - "dev": true - }, - "path-key": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", - "integrity": "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=", - "dev": true - }, - "path-parse": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz", - "integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==", - "dev": true - }, - "path-type": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-type/-/path-type-3.0.0.tgz", - "integrity": "sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg==", - "dev": true, - "requires": { - "pify": "^3.0.0" - }, - "dependencies": { - "pify": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", - "integrity": "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=", - "dev": true - } - } - }, - "performance-now": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", - "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=", - "dev": true - }, - "picomatch": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.1.1.tgz", - "integrity": "sha512-OYMyqkKzK7blWO/+XZYP6w8hH0LDvkBvdvKukti+7kqYFCiEAk+gI3DWnryapc0Dau05ugGTy0foQ6mqn4AHYA==", - "dev": true - }, - "pify": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz", - "integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==", - "dev": true - }, - "pirates": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/pirates/-/pirates-3.0.2.tgz", - "integrity": "sha512-c5CgUJq6H2k6MJz72Ak1F5sN9n9wlSlJyEnwvpm9/y3WB4E3pHBDT2c6PEiS1vyJvq2bUxUAIu0EGf8Cx4Ic7Q==", - "dev": true, - "requires": { - "node-modules-regexp": "^1.0.0" - } - }, - "pkg-dir": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-3.0.0.tgz", - "integrity": "sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw==", - "dev": true, - "requires": { - "find-up": "^3.0.0" - } - }, - "process-nextick-args": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", - "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", - "dev": true, - "optional": true - }, - "prop-types": { - "version": "15.7.2", - "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.7.2.tgz", - "integrity": "sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ==", - "dev": true, - "requires": { - "loose-envify": "^1.4.0", - "object-assign": "^4.1.1", - "react-is": "^16.8.1" - } - }, - "pseudomap": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz", - "integrity": "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=", - "dev": true - }, - "psl": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/psl/-/psl-1.6.0.tgz", - "integrity": "sha512-SYKKmVel98NCOYXpkwUqZqh0ahZeeKfmisiLIcEZdsb+WbLv02g/dI5BUmZnIyOe7RzZtLax81nnb2HbvC2tzA==", - "dev": true - }, - "punycode": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", - "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", - "dev": true - }, - "qs": { - "version": "6.5.2", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", - "integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==", - "dev": true - }, - "react": { - "version": "16.12.0", - "resolved": "https://registry.npmjs.org/react/-/react-16.12.0.tgz", - "integrity": "sha512-fglqy3k5E+81pA8s+7K0/T3DBCF0ZDOher1elBFzF7O6arXJgzyu/FW+COxFvAWXJoJN9KIZbT2LXlukwphYTA==", - "dev": true, - "requires": { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1", - "prop-types": "^15.6.2" - } - }, - "react-is": { - "version": "16.12.0", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.12.0.tgz", - "integrity": "sha512-rPCkf/mWBtKc97aLL9/txD8DZdemK0vkA3JMLShjlJB3Pj3s+lpf1KaBzMfQrAmhMQB0n1cU/SUGgKKBCe837Q==", - "dev": true - }, - "read-pkg": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-3.0.0.tgz", - "integrity": "sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k=", - "dev": true, - "requires": { - "load-json-file": "^4.0.0", - "normalize-package-data": "^2.3.2", - "path-type": "^3.0.0" - } - }, - "read-pkg-up": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-4.0.0.tgz", - "integrity": "sha512-6etQSH7nJGsK0RbG/2TeDzZFa8shjQ1um+SwQQ5cwKy0dhSXdOncEhb1CPpvQG4h7FyOV6EB6YlV0yJvZQNAkA==", - "dev": true, - "requires": { - "find-up": "^3.0.0", - "read-pkg": "^3.0.0" - } - }, - "readable-stream": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", - "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", - "dev": true, - "optional": true, - "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" - }, - "dependencies": { - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true, - "optional": true - } - } - }, - "readdirp": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.3.0.tgz", - "integrity": "sha512-zz0pAkSPOXXm1viEwygWIPSPkcBYjW1xU5j/JBh5t9bGCJwa6f9+BJa6VaB2g+b55yVrmXzqkyLf4xaWYM0IkQ==", - "dev": true, - "requires": { - "picomatch": "^2.0.7" - } - }, - "regenerator-runtime": { - "version": "0.13.3", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.3.tgz", - "integrity": "sha512-naKIZz2GQ8JWh///G7L3X6LaQUAMp2lvb1rvwwsURe/VXwD6VMfr+/1NuNw3ag8v2kY1aQ/go5SNn79O9JU7yw==", - "dev": true - }, - "release-zalgo": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/release-zalgo/-/release-zalgo-1.0.0.tgz", - "integrity": "sha1-CXALflB0Mpc5Mw5TXFqQ+2eFFzA=", - "dev": true, - "requires": { - "es6-error": "^4.0.1" - } - }, - "request": { - "version": "2.88.0", - "resolved": "https://registry.npmjs.org/request/-/request-2.88.0.tgz", - "integrity": "sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg==", - "dev": true, - "requires": { - "aws-sign2": "~0.7.0", - "aws4": "^1.8.0", - "caseless": "~0.12.0", - "combined-stream": "~1.0.6", - "extend": "~3.0.2", - "forever-agent": "~0.6.1", - "form-data": "~2.3.2", - "har-validator": "~5.1.0", - "http-signature": "~1.2.0", - "is-typedarray": "~1.0.0", - "isstream": "~0.1.2", - "json-stringify-safe": "~5.0.1", - "mime-types": "~2.1.19", - "oauth-sign": "~0.9.0", - "performance-now": "^2.1.0", - "qs": "~6.5.2", - "safe-buffer": "^5.1.2", - "tough-cookie": "~2.4.3", - "tunnel-agent": "^0.6.0", - "uuid": "^3.3.2" - } - }, - "require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", - "dev": true - }, - "require-main-filename": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", - "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", - "dev": true - }, - "resolve": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.14.1.tgz", - "integrity": "sha512-fn5Wobh4cxbLzuHaE+nphztHy43/b++4M6SsGFC2gB8uYwf0C8LcarfCz1un7UTW8OFQg9iNjZ4xpcFVGebDPg==", - "dev": true, - "requires": { - "path-parse": "^1.0.6" - } - }, - "resolve-from": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", - "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", - "dev": true - }, - "rimraf": { - "version": "2.7.1", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", - "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", - "dev": true, - "requires": { - "glob": "^7.1.3" - } - }, - "safe-buffer": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz", - "integrity": "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==", - "dev": true - }, - "safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "dev": true - }, - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", - "dev": true - }, - "set-blocking": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", - "dev": true - }, - "shebang-command": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", - "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", - "dev": true, - "requires": { - "shebang-regex": "^1.0.0" - } - }, - "shebang-regex": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", - "integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=", - "dev": true - }, - "signal-exit": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", - "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=", - "dev": true - }, - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - }, - "source-map-support": { - "version": "0.5.16", - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.16.tgz", - "integrity": "sha512-efyLRJDr68D9hBBNIPWFjhpFzURh+KJykQwvMyW5UiZzYwoF6l4YMMDIJJEyFWxWCqfyxLzz6tSfUFR+kXXsVQ==", - "dev": true, - "requires": { - "buffer-from": "^1.0.0", - "source-map": "^0.6.0" - } - }, - "spawn-wrap": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/spawn-wrap/-/spawn-wrap-1.4.3.tgz", - "integrity": "sha512-IgB8md0QW/+tWqcavuFgKYR/qIRvJkRLPJDFaoXtLLUaVcCDK0+HeFTkmQHj3eprcYhc+gOl0aEA1w7qZlYezw==", - "dev": true, - "requires": { - "foreground-child": "^1.5.6", - "mkdirp": "^0.5.0", - "os-homedir": "^1.0.1", - "rimraf": "^2.6.2", - "signal-exit": "^3.0.2", - "which": "^1.3.0" - }, - "dependencies": { - "which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - } - } - }, - "spdx-correct": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.0.tgz", - "integrity": "sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q==", - "dev": true, - "requires": { - "spdx-expression-parse": "^3.0.0", - "spdx-license-ids": "^3.0.0" - } - }, - "spdx-exceptions": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz", - "integrity": "sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA==", - "dev": true - }, - "spdx-expression-parse": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz", - "integrity": "sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg==", - "dev": true, - "requires": { - "spdx-exceptions": "^2.1.0", - "spdx-license-ids": "^3.0.0" - } - }, - "spdx-license-ids": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.5.tgz", - "integrity": "sha512-J+FWzZoynJEXGphVIS+XEh3kFSjZX/1i9gFBaWQcB+/tmpe2qUsSBABpcxqxnAxFdiUFEgAX1bjYGQvIZmoz9Q==", - "dev": true - }, - "sprintf-js": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", - "dev": true - }, - "sshpk": { - "version": "1.16.1", - "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz", - "integrity": "sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==", - "dev": true, - "requires": { - "asn1": "~0.2.3", - "assert-plus": "^1.0.0", - "bcrypt-pbkdf": "^1.0.0", - "dashdash": "^1.12.0", - "ecc-jsbn": "~0.1.1", - "getpass": "^0.1.1", - "jsbn": "~0.1.0", - "safer-buffer": "^2.0.2", - "tweetnacl": "~0.14.0" - } - }, - "stack-utils": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-1.0.2.tgz", - "integrity": "sha512-MTX+MeG5U994cazkjd/9KNAapsHnibjMLnfXodlkXw76JEea0UiNzrqidzo1emMwk7w5Qhc9jd4Bn9TBb1MFwA==", - "dev": true - }, - "string-width": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", - "dev": true, - "requires": { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0" - } - }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, - "optional": true, - "requires": { - "safe-buffer": "~5.1.0" - }, - "dependencies": { - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true, - "optional": true - } - } - }, - "strip-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "dev": true, - "requires": { - "ansi-regex": "^3.0.0" - } - }, - "strip-bom": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", - "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=", - "dev": true - }, - "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - }, - "tap": { - "version": "14.10.5", - "resolved": "https://registry.npmjs.org/tap/-/tap-14.10.5.tgz", - "integrity": "sha512-8I8zMFEVu7e7RVcjK1GUNf1vW+6B9TRCZWGgif5siMBfvwTE9/EPN/7aH6W2r+WR2H2YHXcrCJ3XhRitYEVKfQ==", - "dev": true, - "requires": { - "@types/react": "^16.9.16", - "async-hook-domain": "^1.1.3", - "bind-obj-methods": "^2.0.0", - "browser-process-hrtime": "^1.0.0", - "chokidar": "^3.3.0", - "color-support": "^1.1.0", - "coveralls": "^3.0.8", - "diff": "^4.0.1", - "esm": "^3.2.25", - "findit": "^2.0.0", - "flow-remove-types": "^2.112.0", - "foreground-child": "^1.3.3", - "fs-exists-cached": "^1.0.0", - "function-loop": "^1.0.2", - "glob": "^7.1.6", - "import-jsx": "^3.0.0", - "ink": "^2.5.0", - "isexe": "^2.0.0", - "istanbul-lib-processinfo": "^1.0.0", - "jackspeak": "^1.4.0", - "minipass": "^3.1.1", - "mkdirp": "^0.5.1", - "nyc": "^14.1.1", - "opener": "^1.5.1", - "own-or": "^1.0.0", - "own-or-env": "^1.0.1", - "react": "^16.12.0", - "rimraf": "^2.7.1", - "signal-exit": "^3.0.0", - "source-map-support": "^0.5.16", - "stack-utils": "^1.0.2", - "tap-mocha-reporter": "^5.0.0", - "tap-parser": "^10.0.1", - "tap-yaml": "^1.0.0", - "tcompare": "^3.0.0", - "treport": "^1.0.1", - "trivial-deferred": "^1.0.1", - "ts-node": "^8.5.2", - "typescript": "^3.7.2", - "which": "^2.0.2", - "write-file-atomic": "^3.0.1", - "yaml": "^1.7.2", - "yapool": "^1.0.0" - }, - "dependencies": { - "@babel/code-frame": { - "version": "7.5.5", - "bundled": true, - "dev": true, - "requires": { - "@babel/highlight": "^7.0.0" - } - }, - "@babel/core": { - "version": "7.7.5", - "bundled": true, - "dev": true, - "requires": { - "@babel/code-frame": "^7.5.5", - "@babel/generator": "^7.7.4", - "@babel/helpers": "^7.7.4", - "@babel/parser": "^7.7.5", - "@babel/template": "^7.7.4", - "@babel/traverse": "^7.7.4", - "@babel/types": "^7.7.4", - "convert-source-map": "^1.7.0", - "debug": "^4.1.0", - "json5": "^2.1.0", - "lodash": "^4.17.13", - "resolve": "^1.3.2", - "semver": "^5.4.1", - "source-map": "^0.5.0" - }, - "dependencies": { - "source-map": { - "version": "0.5.7", - "bundled": true, - "dev": true - } - } - }, - "@babel/generator": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.7.4", - "jsesc": "^2.5.1", - "lodash": "^4.17.13", - "source-map": "^0.5.0" - }, - "dependencies": { - "source-map": { - "version": "0.5.7", - "bundled": true, - "dev": true - } - } - }, - "@babel/helper-builder-react-jsx": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.7.4", - "esutils": "^2.0.0" - } - }, - "@babel/helper-function-name": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-get-function-arity": "^7.7.4", - "@babel/template": "^7.7.4", - "@babel/types": "^7.7.4" - } - }, - "@babel/helper-get-function-arity": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.7.4" - } - }, - "@babel/helper-plugin-utils": { - "version": "7.0.0", - "bundled": true, - "dev": true - }, - "@babel/helper-split-export-declaration": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.7.4" - } - }, - "@babel/helpers": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/template": "^7.7.4", - "@babel/traverse": "^7.7.4", - "@babel/types": "^7.7.4" - } - }, - "@babel/highlight": { - "version": "7.5.0", - "bundled": true, - "dev": true, - "requires": { - "chalk": "^2.0.0", - "esutils": "^2.0.2", - "js-tokens": "^4.0.0" - }, - "dependencies": { - "chalk": { - "version": "2.4.2", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - } - }, - "supports-color": { - "version": "5.5.0", - "bundled": true, - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } - } - }, - "@babel/parser": { - "version": "7.7.5", - "bundled": true, - "dev": true - }, - "@babel/plugin-proposal-object-rest-spread": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.0.0", - "@babel/plugin-syntax-object-rest-spread": "^7.7.4" - } - }, - "@babel/plugin-syntax-jsx": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.0.0" - } - }, - "@babel/plugin-syntax-object-rest-spread": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.0.0" - } - }, - "@babel/plugin-transform-destructuring": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.0.0" - } - }, - "@babel/plugin-transform-react-jsx": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-builder-react-jsx": "^7.7.4", - "@babel/helper-plugin-utils": "^7.0.0", - "@babel/plugin-syntax-jsx": "^7.7.4" - } - }, - "@babel/runtime": { - "version": "7.7.6", - "bundled": true, - "dev": true, - "requires": { - "regenerator-runtime": "^0.13.2" - } - }, - "@babel/template": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/code-frame": "^7.0.0", - "@babel/parser": "^7.7.4", - "@babel/types": "^7.7.4" - } - }, - "@babel/traverse": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "@babel/code-frame": "^7.5.5", - "@babel/generator": "^7.7.4", - "@babel/helper-function-name": "^7.7.4", - "@babel/helper-split-export-declaration": "^7.7.4", - "@babel/parser": "^7.7.4", - "@babel/types": "^7.7.4", - "debug": "^4.1.0", - "globals": "^11.1.0", - "lodash": "^4.17.13" - } - }, - "@babel/types": { - "version": "7.7.4", - "bundled": true, - "dev": true, - "requires": { - "esutils": "^2.0.2", - "lodash": "^4.17.13", - "to-fast-properties": "^2.0.0" - } - }, - "@types/color-name": { - "version": "1.1.1", - "bundled": true, - "dev": true - }, - "@types/prop-types": { - "version": "15.7.3", - "bundled": true, - "dev": true - }, - "@types/react": { - "version": "16.9.16", - "bundled": true, - "dev": true, - "requires": { - "@types/prop-types": "*", - "csstype": "^2.2.0" - } - }, - "ansi-escapes": { - "version": "4.3.0", - "bundled": true, - "dev": true, - "requires": { - "type-fest": "^0.8.1" - } - }, - "ansi-regex": { - "version": "5.0.0", - "bundled": true, - "dev": true - }, - "ansi-styles": { - "version": "3.2.1", - "bundled": true, - "dev": true, - "requires": { - "color-convert": "^1.9.0" - } - }, - "ansicolors": { - "version": "0.3.2", - "bundled": true, - "dev": true - }, - "arrify": { - "version": "2.0.1", - "bundled": true, - "dev": true - }, - "astral-regex": { - "version": "2.0.0", - "bundled": true, - "dev": true - }, - "auto-bind": { - "version": "3.0.0", - "bundled": true, - "dev": true - }, - "caller-callsite": { - "version": "2.0.0", - "bundled": true, - "dev": true, - "requires": { - "callsites": "^2.0.0" - } - }, - "caller-path": { - "version": "2.0.0", - "bundled": true, - "dev": true, - "requires": { - "caller-callsite": "^2.0.0" - } - }, - "callsites": { - "version": "2.0.0", - "bundled": true, - "dev": true - }, - "cardinal": { - "version": "2.1.1", - "bundled": true, - "dev": true, - "requires": { - "ansicolors": "~0.3.2", - "redeyed": "~2.1.0" - } - }, - "chalk": { - "version": "3.0.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.2.0", - "bundled": true, - "dev": true, - "requires": { - "@types/color-name": "^1.1.1", - "color-convert": "^2.0.1" - } - }, - "color-convert": { - "version": "2.0.1", - "bundled": true, - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "bundled": true, - "dev": true - } - } - }, - "ci-info": { - "version": "2.0.0", - "bundled": true, - "dev": true - }, - "cli-cursor": { - "version": "3.1.0", - "bundled": true, - "dev": true, - "requires": { - "restore-cursor": "^3.1.0" - } - }, - "cli-truncate": { - "version": "2.1.0", - "bundled": true, - "dev": true, - "requires": { - "slice-ansi": "^3.0.0", - "string-width": "^4.2.0" - } - }, - "color-convert": { - "version": "1.9.3", - "bundled": true, - "dev": true, - "requires": { - "color-name": "1.1.3" - } - }, - "color-name": { - "version": "1.1.3", - "bundled": true, - "dev": true - }, - "convert-source-map": { - "version": "1.7.0", - "bundled": true, - "dev": true, - "requires": { - "safe-buffer": "~5.1.1" - }, - "dependencies": { - "safe-buffer": { - "version": "5.1.2", - "bundled": true, - "dev": true - } - } - }, - "csstype": { - "version": "2.6.8", - "bundled": true, - "dev": true - }, - "debug": { - "version": "4.1.1", - "bundled": true, - "dev": true, - "requires": { - "ms": "^2.1.1" - } - }, - "emoji-regex": { - "version": "8.0.0", - "bundled": true, - "dev": true - }, - "escape-string-regexp": { - "version": "1.0.5", - "bundled": true, - "dev": true - }, - "esprima": { - "version": "4.0.1", - "bundled": true, - "dev": true - }, - "esutils": { - "version": "2.0.3", - "bundled": true, - "dev": true - }, - "events-to-array": { - "version": "1.1.2", - "bundled": true, - "dev": true - }, - "globals": { - "version": "11.12.0", - "bundled": true, - "dev": true - }, - "has-flag": { - "version": "3.0.0", - "bundled": true, - "dev": true - }, - "import-jsx": { - "version": "3.0.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/core": "^7.5.5", - "@babel/plugin-proposal-object-rest-spread": "^7.5.5", - "@babel/plugin-transform-destructuring": "^7.5.0", - "@babel/plugin-transform-react-jsx": "^7.3.0", - "caller-path": "^2.0.0", - "resolve-from": "^3.0.0" - } - }, - "ink": { - "version": "2.6.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-escapes": "^4.2.1", - "arrify": "^2.0.1", - "auto-bind": "^3.0.0", - "chalk": "^3.0.0", - "cli-cursor": "^3.1.0", - "cli-truncate": "^2.0.0", - "is-ci": "^2.0.0", - "lodash.throttle": "^4.1.1", - "log-update": "^3.0.0", - "prop-types": "^15.6.2", - "react-reconciler": "^0.24.0", - "scheduler": "^0.18.0", - "signal-exit": "^3.0.2", - "slice-ansi": "^3.0.0", - "string-length": "^3.1.0", - "widest-line": "^3.1.0", - "wrap-ansi": "^6.2.0", - "yoga-layout-prebuilt": "^1.9.3" - } - }, - "is-ci": { - "version": "2.0.0", - "bundled": true, - "dev": true, - "requires": { - "ci-info": "^2.0.0" - } - }, - "is-fullwidth-code-point": { - "version": "3.0.0", - "bundled": true, - "dev": true - }, - "js-tokens": { - "version": "4.0.0", - "bundled": true, - "dev": true - }, - "jsesc": { - "version": "2.5.2", - "bundled": true, - "dev": true - }, - "json5": { - "version": "2.1.1", - "bundled": true, - "dev": true, - "requires": { - "minimist": "^1.2.0" - } - }, - "lodash": { - "version": "4.17.15", - "bundled": true, - "dev": true - }, - "lodash.throttle": { - "version": "4.1.1", - "bundled": true, - "dev": true - }, - "log-update": { - "version": "3.3.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-escapes": "^3.2.0", - "cli-cursor": "^2.1.0", - "wrap-ansi": "^5.0.0" - }, - "dependencies": { - "ansi-escapes": { - "version": "3.2.0", - "bundled": true, - "dev": true - }, - "ansi-regex": { - "version": "4.1.0", - "bundled": true, - "dev": true - }, - "cli-cursor": { - "version": "2.1.0", - "bundled": true, - "dev": true, - "requires": { - "restore-cursor": "^2.0.0" - } - }, - "emoji-regex": { - "version": "7.0.3", - "bundled": true, - "dev": true - }, - "is-fullwidth-code-point": { - "version": "2.0.0", - "bundled": true, - "dev": true - }, - "mimic-fn": { - "version": "1.2.0", - "bundled": true, - "dev": true - }, - "onetime": { - "version": "2.0.1", - "bundled": true, - "dev": true, - "requires": { - "mimic-fn": "^1.0.0" - } - }, - "restore-cursor": { - "version": "2.0.0", - "bundled": true, - "dev": true, - "requires": { - "onetime": "^2.0.0", - "signal-exit": "^3.0.2" - } - }, - "string-width": { - "version": "3.1.0", - "bundled": true, - "dev": true, - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - }, - "wrap-ansi": { - "version": "5.1.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^3.2.0", - "string-width": "^3.0.0", - "strip-ansi": "^5.0.0" - } - } - } - }, - "loose-envify": { - "version": "1.4.0", - "bundled": true, - "dev": true, - "requires": { - "js-tokens": "^3.0.0 || ^4.0.0" - } - }, - "mimic-fn": { - "version": "2.1.0", - "bundled": true, - "dev": true - }, - "minimist": { - "version": "1.2.0", - "bundled": true, - "dev": true - }, - "minipass": { - "version": "3.1.1", - "bundled": true, - "dev": true, - "requires": { - "yallist": "^4.0.0" - }, - "dependencies": { - "yallist": { - "version": "4.0.0", - "bundled": true, - "dev": true - } - } - }, - "ms": { - "version": "2.1.2", - "bundled": true, - "dev": true - }, - "object-assign": { - "version": "4.1.1", - "bundled": true, - "dev": true - }, - "onetime": { - "version": "5.1.0", - "bundled": true, - "dev": true, - "requires": { - "mimic-fn": "^2.1.0" - } - }, - "path-parse": { - "version": "1.0.6", - "bundled": true, - "dev": true - }, - "prop-types": { - "version": "15.7.2", - "bundled": true, - "dev": true, - "requires": { - "loose-envify": "^1.4.0", - "object-assign": "^4.1.1", - "react-is": "^16.8.1" - } - }, - "punycode": { - "version": "2.1.1", - "bundled": true, - "dev": true - }, - "react-is": { - "version": "16.12.0", - "bundled": true, - "dev": true - }, - "react-reconciler": { - "version": "0.24.0", - "bundled": true, - "dev": true, - "requires": { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1", - "prop-types": "^15.6.2", - "scheduler": "^0.18.0" - } - }, - "redeyed": { - "version": "2.1.1", - "bundled": true, - "dev": true, - "requires": { - "esprima": "~4.0.0" - } - }, - "regenerator-runtime": { - "version": "0.13.3", - "bundled": true, - "dev": true - }, - "resolve": { - "version": "1.13.1", - "bundled": true, - "dev": true, - "requires": { - "path-parse": "^1.0.6" - } - }, - "resolve-from": { - "version": "3.0.0", - "bundled": true, - "dev": true - }, - "restore-cursor": { - "version": "3.1.0", - "bundled": true, - "dev": true, - "requires": { - "onetime": "^5.1.0", - "signal-exit": "^3.0.2" - } - }, - "scheduler": { - "version": "0.18.0", - "bundled": true, - "dev": true, - "requires": { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1" - } - }, - "semver": { - "version": "5.7.1", - "bundled": true, - "dev": true - }, - "signal-exit": { - "version": "3.0.2", - "bundled": true, - "dev": true - }, - "slice-ansi": { - "version": "3.0.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^4.0.0", - "astral-regex": "^2.0.0", - "is-fullwidth-code-point": "^3.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.2.0", - "bundled": true, - "dev": true, - "requires": { - "@types/color-name": "^1.1.1", - "color-convert": "^2.0.1" - } - }, - "color-convert": { - "version": "2.0.1", - "bundled": true, - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "bundled": true, - "dev": true - } - } - }, - "string-length": { - "version": "3.1.0", - "bundled": true, - "dev": true, - "requires": { - "astral-regex": "^1.0.0", - "strip-ansi": "^5.2.0" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "bundled": true, - "dev": true - }, - "astral-regex": { - "version": "1.0.0", - "bundled": true, - "dev": true - }, - "strip-ansi": { - "version": "5.2.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - } - } - }, - "string-width": { - "version": "4.2.0", - "bundled": true, - "dev": true, - "requires": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.0" - } - }, - "strip-ansi": { - "version": "6.0.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-regex": "^5.0.0" - } - }, - "supports-color": { - "version": "7.1.0", - "bundled": true, - "dev": true, - "requires": { - "has-flag": "^4.0.0" - }, - "dependencies": { - "has-flag": { - "version": "4.0.0", - "bundled": true, - "dev": true - } - } - }, - "tap-parser": { - "version": "10.0.1", - "bundled": true, - "dev": true, - "requires": { - "events-to-array": "^1.0.1", - "minipass": "^3.0.0", - "tap-yaml": "^1.0.0" - } - }, - "tap-yaml": { - "version": "1.0.0", - "bundled": true, - "dev": true, - "requires": { - "yaml": "^1.5.0" - } - }, - "to-fast-properties": { - "version": "2.0.0", - "bundled": true, - "dev": true - }, - "treport": { - "version": "1.0.1", - "bundled": true, - "dev": true, - "requires": { - "cardinal": "^2.1.1", - "chalk": "^3.0.0", - "import-jsx": "^3.0.0", - "ink": "^2.5.0", - "ms": "^2.1.2", - "string-length": "^3.1.0", - "tap-parser": "^10.0.1", - "unicode-length": "^2.0.2" - }, - "dependencies": { - "ansi-regex": { - "version": "2.1.1", - "bundled": true, - "dev": true - }, - "strip-ansi": { - "version": "3.0.1", - "bundled": true, - "dev": true, - "requires": { - "ansi-regex": "^2.0.0" - } - }, - "unicode-length": { - "version": "2.0.2", - "bundled": true, - "dev": true, - "requires": { - "punycode": "^2.0.0", - "strip-ansi": "^3.0.1" - } - } - } - }, - "type-fest": { - "version": "0.8.1", - "bundled": true, - "dev": true - }, - "widest-line": { - "version": "3.1.0", - "bundled": true, - "dev": true, - "requires": { - "string-width": "^4.0.0" - } - }, - "wrap-ansi": { - "version": "6.2.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.2.0", - "bundled": true, - "dev": true, - "requires": { - "@types/color-name": "^1.1.1", - "color-convert": "^2.0.1" - } - }, - "color-convert": { - "version": "2.0.1", - "bundled": true, - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "bundled": true, - "dev": true - } - } - }, - "yaml": { - "version": "1.7.2", - "bundled": true, - "dev": true, - "requires": { - "@babel/runtime": "^7.6.3" - } - }, - "yoga-layout-prebuilt": { - "version": "1.9.3", - "bundled": true, - "dev": true - } - } - }, - "tap-mocha-reporter": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/tap-mocha-reporter/-/tap-mocha-reporter-5.0.0.tgz", - "integrity": "sha512-8HlAtdmYGlDZuW83QbF/dc46L7cN+AGhLZcanX3I9ILvxUAl+G2/mtucNPSXecTlG/4iP1hv6oMo0tMhkn3Tsw==", - "dev": true, - "requires": { - "color-support": "^1.1.0", - "debug": "^2.1.3", - "diff": "^1.3.2", - "escape-string-regexp": "^1.0.3", - "glob": "^7.0.5", - "readable-stream": "^2.1.5", - "tap-parser": "^10.0.0", - "tap-yaml": "^1.0.0", - "unicode-length": "^1.0.0" - }, - "dependencies": { - "debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", - "dev": true, - "requires": { - "ms": "2.0.0" - } - }, - "diff": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-1.4.0.tgz", - "integrity": "sha1-fyjS657nsVqX79ic5j3P2qPMur8=", - "dev": true - }, - "ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", - "dev": true - } - } - }, - "tap-parser": { - "version": "10.0.1", - "resolved": "https://registry.npmjs.org/tap-parser/-/tap-parser-10.0.1.tgz", - "integrity": "sha512-qdT15H0DoJIi7zOqVXDn9X0gSM68JjNy1w3VemwTJlDnETjbi6SutnqmBfjDJAwkFS79NJ97gZKqie00ZCGmzg==", - "dev": true, - "requires": { - "events-to-array": "^1.0.1", - "minipass": "^3.0.0", - "tap-yaml": "^1.0.0" - } - }, - "tap-yaml": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/tap-yaml/-/tap-yaml-1.0.0.tgz", - "integrity": "sha512-Rxbx4EnrWkYk0/ztcm5u3/VznbyFJpyXO12dDBHKWiDVxy7O2Qw6MRrwO5H6Ww0U5YhRY/4C/VzWmFPhBQc4qQ==", - "dev": true, - "requires": { - "yaml": "^1.5.0" - } - }, - "tcompare": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/tcompare/-/tcompare-3.0.4.tgz", - "integrity": "sha512-Q3TitMVK59NyKgQyFh+857wTAUE329IzLDehuPgU4nF5e8g+EUQ+yUbjUy1/6ugiNnXztphT+NnqlCXolv9P3A==", - "dev": true, - "requires": { - "diff-frag": "^1.0.1" - } - }, - "test-exclude": { - "version": "5.2.3", - "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-5.2.3.tgz", - "integrity": "sha512-M+oxtseCFO3EDtAaGH7iiej3CBkzXqFMbzqYAACdzKui4eZA+pq3tZEwChvOdNfa7xxy8BfbmgJSIr43cC/+2g==", - "dev": true, - "requires": { - "glob": "^7.1.3", - "minimatch": "^3.0.4", - "read-pkg-up": "^4.0.0", - "require-main-filename": "^2.0.0" - } - }, - "to-fast-properties": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", - "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", - "dev": true - }, - "to-regex-range": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", - "dev": true, - "requires": { - "is-number": "^7.0.0" - } - }, - "tough-cookie": { - "version": "2.4.3", - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.4.3.tgz", - "integrity": "sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ==", - "dev": true, - "requires": { - "psl": "^1.1.24", - "punycode": "^1.4.1" - }, - "dependencies": { - "punycode": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", - "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", - "dev": true - } - } - }, - "trivial-deferred": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/trivial-deferred/-/trivial-deferred-1.0.1.tgz", - "integrity": "sha1-N21NKdlR1jaKb3oK6FwvTV4GWPM=", - "dev": true - }, - "ts-node": { - "version": "8.5.4", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.5.4.tgz", - "integrity": "sha512-izbVCRV68EasEPQ8MSIGBNK9dc/4sYJJKYA+IarMQct1RtEot6Xp0bXuClsbUSnKpg50ho+aOAx8en5c+y4OFw==", - "dev": true, - "requires": { - "arg": "^4.1.0", - "diff": "^4.0.1", - "make-error": "^1.1.1", - "source-map-support": "^0.5.6", - "yn": "^3.0.0" - } - }, - "tunnel-agent": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", - "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", - "dev": true, - "requires": { - "safe-buffer": "^5.0.1" - } - }, - "tweetnacl": { - "version": "0.14.5", - "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", - "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=", - "dev": true - }, - "typedarray-to-buffer": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz", - "integrity": "sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==", - "dev": true, - "requires": { - "is-typedarray": "^1.0.0" - } - }, - "typescript": { - "version": "3.7.4", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.7.4.tgz", - "integrity": "sha512-A25xv5XCtarLwXpcDNZzCGvW2D1S3/bACratYBx2sax8PefsFhlYmkQicKHvpYflFS8if4zne5zT5kpJ7pzuvw==", - "dev": true - }, - "uglify-js": { - "version": "3.7.3", - "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.7.3.tgz", - "integrity": "sha512-7tINm46/3puUA4hCkKYo4Xdts+JDaVC9ZPRcG8Xw9R4nhO/gZgUM3TENq8IF4Vatk8qCig4MzP/c8G4u2BkVQg==", - "dev": true, - "optional": true, - "requires": { - "commander": "~2.20.3", - "source-map": "~0.6.1" - } - }, - "unicode-length": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/unicode-length/-/unicode-length-1.0.3.tgz", - "integrity": "sha1-Wtp6f+1RhBpBijKM8UlHisg1irs=", - "dev": true, - "requires": { - "punycode": "^1.3.2", - "strip-ansi": "^3.0.1" - }, - "dependencies": { - "ansi-regex": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", - "dev": true - }, - "punycode": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", - "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", - "dev": true - }, - "strip-ansi": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", - "dev": true, - "requires": { - "ansi-regex": "^2.0.0" - } - } - } - }, - "uri-js": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", - "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==", - "dev": true, - "requires": { - "punycode": "^2.1.0" - } - }, - "util-deprecate": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", - "dev": true, - "optional": true - }, - "uuid": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.3.3.tgz", - "integrity": "sha512-pW0No1RGHgzlpHJO1nsVrHKpOEIxkGg1xB+v0ZmdNH5OAeAwzAVrCnI2/6Mtx+Uys6iaylxa+D3g4j63IKKjSQ==", - "dev": true - }, - "validate-npm-package-license": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz", - "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==", - "dev": true, - "requires": { - "spdx-correct": "^3.0.0", - "spdx-expression-parse": "^3.0.0" - } - }, - "verror": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", - "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0", - "core-util-is": "1.0.2", - "extsprintf": "^1.2.0" - } - }, - "vlq": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/vlq/-/vlq-0.2.3.tgz", - "integrity": "sha512-DRibZL6DsNhIgYQ+wNdWDL2SL3bKPlVrRiBqV5yuMm++op8W4kGFtaQfCs4KEJn0wBZcHVHJ3eoywX8983k1ow==", - "dev": true - }, - "which": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", - "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - }, - "which-module": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", - "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", - "dev": true - }, - "wordwrap": { - "version": "0.0.3", - "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.3.tgz", - "integrity": "sha1-o9XabNXAvAAI03I0u68b7WMFkQc=", - "dev": true - }, - "wrap-ansi": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz", - "integrity": "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=", - "dev": true, - "requires": { - "string-width": "^1.0.1", - "strip-ansi": "^3.0.1" - }, - "dependencies": { - "ansi-regex": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", - "dev": true - }, - "is-fullwidth-code-point": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", - "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", - "dev": true, - "requires": { - "number-is-nan": "^1.0.0" - } - }, - "string-width": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", - "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", - "dev": true, - "requires": { - "code-point-at": "^1.0.0", - "is-fullwidth-code-point": "^1.0.0", - "strip-ansi": "^3.0.0" - } - }, - "strip-ansi": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", - "dev": true, - "requires": { - "ansi-regex": "^2.0.0" - } - } - } - }, - "wrappy": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", - "dev": true - }, - "write-file-atomic": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-3.0.1.tgz", - "integrity": "sha512-JPStrIyyVJ6oCSz/691fAjFtefZ6q+fP6tm+OS4Qw6o+TGQxNp1ziY2PgS+X/m0V8OWhZiO/m4xSj+Pr4RrZvw==", - "dev": true, - "requires": { - "imurmurhash": "^0.1.4", - "is-typedarray": "^1.0.0", - "signal-exit": "^3.0.2", - "typedarray-to-buffer": "^3.1.5" - } - }, - "y18n": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", - "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", - "dev": true - }, - "yallist": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz", - "integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=", - "dev": true - }, - "yaml": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.7.2.tgz", - "integrity": "sha512-qXROVp90sb83XtAoqE8bP9RwAkTTZbugRUTm5YeFCBfNRPEp2YzTeqWiz7m5OORHzEvrA/qcGS8hp/E+MMROYw==", - "dev": true, - "requires": { - "@babel/runtime": "^7.6.3" - } - }, - "yapool": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/yapool/-/yapool-1.0.0.tgz", - "integrity": "sha1-9pPymjFbUNmp2iZGp6ZkXJaYW2o=", - "dev": true - }, - "yargs": { - "version": "13.3.0", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.0.tgz", - "integrity": "sha512-2eehun/8ALW8TLoIl7MVaRUrg+yCnenu8B4kBlRxj3GJGDKU1Og7sMXPNm1BYyM1DOJmTZ4YeN/Nwxv+8XJsUA==", - "dev": true, - "requires": { - "cliui": "^5.0.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^13.1.1" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", - "dev": true - }, - "cliui": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", - "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", - "dev": true, - "requires": { - "string-width": "^3.1.0", - "strip-ansi": "^5.2.0", - "wrap-ansi": "^5.1.0" - } - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "dev": true, - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - }, - "wrap-ansi": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", - "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.0", - "string-width": "^3.0.0", - "strip-ansi": "^5.0.0" - } - } - } - }, - "yargs-parser": { - "version": "13.1.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.1.tgz", - "integrity": "sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ==", - "dev": true, - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } - }, - "yn": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", - "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", - "dev": true - } - } -} diff --git a/node_modules/read-cmd-shim/index.js b/node_modules/read-cmd-shim/lib/index.js similarity index 87% rename from node_modules/read-cmd-shim/index.js rename to node_modules/read-cmd-shim/lib/index.js index 4ac050f..dafc874 100644 --- a/node_modules/read-cmd-shim/index.js +++ b/node_modules/read-cmd-shim/lib/index.js @@ -1,6 +1,6 @@ const fs = require('fs') -const {promisify} = require('util') -const {readFileSync} = fs +const { promisify } = require('util') +const { readFileSync } = fs const readFile = promisify(fs.readFile) const extractPath = (path, cmdshimContents) => { @@ -53,15 +53,21 @@ const readCmdShim = path => { Error.captureStackTrace(er, readCmdShim) return readFile(path).then(contents => { const destination = extractPath(path, contents.toString()) - if (destination) return destination - return Promise.reject(notaShim(path, er)) - }, readFileEr => Promise.reject(wrapError(readFileEr, er))) + if (destination) { + return destination + } + throw notaShim(path, er) + }, readFileEr => { + throw wrapError(readFileEr, er) + }) } const readCmdShimSync = path => { const contents = readFileSync(path) const destination = extractPath(path, contents.toString()) - if (!destination) throw notaShim(path) + if (!destination) { + throw notaShim(path) + } return destination } diff --git a/node_modules/read-cmd-shim/package.json b/node_modules/read-cmd-shim/package.json index 2a76dc3..401ee3d 100644 --- a/node_modules/read-cmd-shim/package.json +++ b/node_modules/read-cmd-shim/package.json @@ -1,29 +1,47 @@ { "name": "read-cmd-shim", - "version": "2.0.0", + "version": "4.0.0", "description": "Figure out what a cmd-shim is pointing at. This acts as the equivalent of fs.readlink.", - "main": "index.js", + "main": "lib/index.js", "devDependencies": { - "cmd-shim": "^4.0.0", + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", + "cmd-shim": "^5.0.0", "rimraf": "^3.0.0", - "tap": "^14.10.6" + "tap": "^16.0.1" }, "scripts": { - "preversion": "npm t", - "postversion": "npm publish", - "prepublishOnly": "git push --follow-tags", - "test": "tap" + "test": "tap", + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "npm run lint -- --fix", + "snap": "tap", + "posttest": "npm run lint" }, "tap": { - "check-coverage": true + "check-coverage": true, + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "repository": { "type": "git", - "url": "git+https://github.com/npm/read-cmd-shim.git" + "url": "https://github.com/npm/read-cmd-shim.git" }, "license": "ISC", "homepage": "https://github.com/npm/read-cmd-shim#readme", "files": [ - "index.js" - ] + "bin/", + "lib/" + ], + "author": "GitHub Inc.", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" + } } diff --git a/node_modules/read-package-json-fast/index.js b/node_modules/read-package-json-fast/lib/index.js similarity index 83% rename from node_modules/read-package-json-fast/index.js rename to node_modules/read-package-json-fast/lib/index.js index 646ff7d..c5c896f 100644 --- a/node_modules/read-package-json-fast/index.js +++ b/node_modules/read-package-json-fast/lib/index.js @@ -1,4 +1,4 @@ -const {promisify} = require('util') +const { promisify } = require('util') const fs = require('fs') const readFile = promisify(fs.readFile) const lstat = promisify(fs.lstat) @@ -18,12 +18,14 @@ const normalizePackageBin = require('npm-normalize-package-bin') // load the directories.bin folder as a 'bin' object const readBinDir = async (path, data) => { - if (data.bin) + if (data.bin) { return data + } const m = data.directories && data.directories.bin - if (!m || typeof m !== 'string') + if (!m || typeof m !== 'string') { return data + } // cut off any monkey business, like setting directories.bin // to ../../../etc/passwd or /etc/passwd or something like that. @@ -36,30 +38,33 @@ const readBinDir = async (path, data) => { const walkBinDir = async (root, dir, obj) => { const entries = await readdir(resolve(root, dir)).catch(() => []) for (const entry of entries) { - if (entry.charAt(0) === '.') + if (entry.charAt(0) === '.') { continue + } const f = resolve(root, dir, entry) // ignore stat errors, weird file types, symlinks, etc. const st = await lstat(f).catch(() => null) - if (!st) + if (!st) { continue - else if (st.isFile()) + } else if (st.isFile()) { obj[entry] = relative(root, f) - else if (st.isDirectory()) + } else if (st.isDirectory()) { await walkBinDir(root, join(dir, entry), obj) + } } return obj } // do not preserve _fields set in files, they are sus const stripUnderscores = data => { - for (const key of Object.keys(data).filter(k => /^_/.test(k))) + for (const key of Object.keys(data).filter(k => /^_/.test(k))) { delete data[key] + } return data } const normalize = data => { - add_id(data) + addId(data) fixBundled(data) pruneRepeatedOptionals(data) fixScripts(data) @@ -70,9 +75,10 @@ const normalize = data => { rpj.normalize = normalize -const add_id = data => { - if (data.name && data.version) +const addId = data => { + if (data.name && data.version) { data._id = `${data.name}@${data.version}` + } return data } @@ -88,8 +94,9 @@ const pruneRepeatedOptionals = data => { delete dd[name] } } - if (Object.keys(dd).length === 0) + if (Object.keys(dd).length === 0) { delete data.dependencies + } return data } @@ -98,17 +105,19 @@ const fixBundled = data => { const bd = data.bundleDependencies === undefined ? bdd : data.bundleDependencies - if (bd === false) + if (bd === false) { data.bundleDependencies = [] - else if (bd === true) + } else if (bd === true) { data.bundleDependencies = Object.keys(data.dependencies || {}) - else if (bd && typeof bd === 'object') { - if (!Array.isArray(bd)) + } else if (bd && typeof bd === 'object') { + if (!Array.isArray(bd)) { data.bundleDependencies = Object.keys(bd) - else + } else { data.bundleDependencies = bd - } else + } + } else { delete data.bundleDependencies + } delete data.bundledDependencies return data @@ -121,15 +130,17 @@ const fixScripts = data => { } for (const [name, script] of Object.entries(data.scripts)) { - if (typeof script !== 'string') + if (typeof script !== 'string') { delete data.scripts[name] + } } return data } const fixFunding = data => { - if (data.funding && typeof data.funding === 'string') + if (data.funding && typeof data.funding === 'string') { data.funding = { url: data.funding } + } return data } diff --git a/node_modules/read-package-json-fast/package.json b/node_modules/read-package-json-fast/package.json index c3a9f7d..7baa36c 100644 --- a/node_modules/read-package-json-fast/package.json +++ b/node_modules/read-package-json-fast/package.json @@ -1,34 +1,47 @@ { "name": "read-package-json-fast", - "version": "2.0.3", + "version": "3.0.1", "description": "Like read-package-json, but faster", - "author": "Isaac Z. Schlueter <i@izs.me> (https://izs.me)", + "main": "lib/index.js", + "author": "GitHub Inc.", "license": "ISC", "scripts": { "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "postpublish": "git push origin --follow-tags" + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "npm run lint -- --fix", + "posttest": "npm run lint" }, "engines": { - "node": ">=10" - }, - "tap": { - "check-coverage": true + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "devDependencies": { - "tap": "^15.0.9" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.5.1", + "tap": "^16.3.0" }, "dependencies": { - "json-parse-even-better-errors": "^2.3.0", - "npm-normalize-package-bin": "^1.0.1" + "json-parse-even-better-errors": "^3.0.0", + "npm-normalize-package-bin": "^3.0.0" }, "repository": { "type": "git", - "url": "git+https://github.com/npm/read-package-json-fast.git" + "url": "https://github.com/npm/read-package-json-fast.git" }, "files": [ - "index.js" - ] + "bin/", + "lib/" + ], + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] + } } diff --git a/node_modules/readdir-scoped-modules/LICENSE b/node_modules/readdir-scoped-modules/LICENSE deleted file mode 100644 index 19129e3..0000000 --- a/node_modules/readdir-scoped-modules/LICENSE +++ /dev/null @@ -1,15 +0,0 @@ -The ISC License - -Copyright (c) Isaac Z. Schlueter and Contributors - -Permission to use, copy, modify, and/or distribute this software for any -purpose with or without fee is hereby granted, provided that the above -copyright notice and this permission notice appear in all copies. - -THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR -IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/node_modules/readdir-scoped-modules/package.json b/node_modules/readdir-scoped-modules/package.json deleted file mode 100644 index d41b99c..0000000 --- a/node_modules/readdir-scoped-modules/package.json +++ /dev/null @@ -1,34 +0,0 @@ -{ - "name": "readdir-scoped-modules", - "version": "1.1.0", - "description": "Like `fs.readdir` but handling `@org/module` dirs as if they were a single entry.", - "main": "readdir.js", - "directories": { - "test": "test" - }, - "dependencies": { - "debuglog": "^1.0.1", - "dezalgo": "^1.0.0", - "graceful-fs": "^4.1.2", - "once": "^1.3.0" - }, - "devDependencies": { - "tap": "^1.2.0" - }, - "scripts": { - "test": "tap test/*.js" - }, - "repository": { - "type": "git", - "url": "https://github.com/npm/readdir-scoped-modules" - }, - "author": "Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me/)", - "license": "ISC", - "bugs": { - "url": "https://github.com/npm/readdir-scoped-modules/issues" - }, - "homepage": "https://github.com/npm/readdir-scoped-modules", - "files": [ - "readdir.js" - ] -} diff --git a/node_modules/readdir-scoped-modules/readdir.js b/node_modules/readdir-scoped-modules/readdir.js deleted file mode 100644 index 806d787..0000000 --- a/node_modules/readdir-scoped-modules/readdir.js +++ /dev/null @@ -1,121 +0,0 @@ -var fs = require ('graceful-fs') -var dz = require ('dezalgo') -var once = require ('once') -var path = require ('path') -var debug = require ('debuglog') ('rds') - -module . exports = readdir -readdir.sync = readdirSync - -function readdir (dir, cb) { - fs . readdir (dir, function (er, kids) { - if (er) - return cb (er) - - debug ('dir=%j, kids=%j', dir, kids) - readScopes (dir, kids, function (er, data) { - if (er) - return cb (er) - - // Sort for bonus consistency points - data = data . sort (function (a, b) { - return a > b ? 1 : -1 - }) - - return cb (null, data) - }) - }) -} - -function readdirSync (dir) { - var kids = fs . readdirSync (dir) - debug ('dir=%j, kids=%j', dir, kids) - var data = readScopesSync (dir, kids) - // Sort for bonus consistency points - data = data . sort (function (a, b) { - return a > b ? 1 : -1 - }) - - return data -} - -// Turn [ 'a', '@scope' ] into -// ['a', '@scope/foo', '@scope/bar'] -function readScopes (root, kids, cb) { - var scopes = kids . filter (function (kid) { - return kid . charAt (0) === '@' - }) - - kids = kids . filter (function (kid) { - return kid . charAt (0) !== '@' - }) - - debug ('scopes=%j', scopes) - - if (scopes . length === 0) - dz (cb) (null, kids) // prevent maybe-sync zalgo release - - cb = once (cb) - var l = scopes . length - scopes . forEach (function (scope) { - var scopedir = path . resolve (root, scope) - debug ('root=%j scope=%j scopedir=%j', root, scope, scopedir) - fs . readdir (scopedir, then . bind (null, scope)) - }) - - function then (scope, er, scopekids) { - if (er) - return cb (er) - - // XXX: Not sure how old this node bug is. Maybe superstition? - scopekids = scopekids . filter (function (scopekid) { - return !(scopekid === '.' || scopekid === '..' || !scopekid) - }) - - kids . push . apply (kids, scopekids . map (function (scopekid) { - return scope + '/' + scopekid - })) - - debug ('scope=%j scopekids=%j kids=%j', scope, scopekids, kids) - - if (--l === 0) - cb (null, kids) - } -} - -function readScopesSync (root, kids) { - var scopes = kids . filter (function (kid) { - return kid . charAt (0) === '@' - }) - - kids = kids . filter (function (kid) { - return kid . charAt (0) !== '@' - }) - - debug ('scopes=%j', scopes) - - if (scopes . length === 0) - return kids - - var l = scopes . length - scopes . forEach (function (scope) { - var scopedir = path . resolve (root, scope) - debug ('root=%j scope=%j scopedir=%j', root, scope, scopedir) - then (scope, fs . readdirSync (scopedir)) - }) - - function then (scope, scopekids) { - // XXX: Not sure how old this node bug is. Maybe superstition? - scopekids = scopekids . filter (function (scopekid) { - return !(scopekid === '.' || scopekid === '..' || !scopekid) - }) - - kids . push . apply (kids, scopekids . map (function (scopekid) { - return scope + '/' + scopekid - })) - - debug ('scope=%j scopekids=%j kids=%j', scope, scopekids, kids) - } - - return kids -} diff --git a/node_modules/socks-proxy-agent/dist/agent.d.ts b/node_modules/socks-proxy-agent/dist/agent.d.ts deleted file mode 100644 index 96f44af..0000000 --- a/node_modules/socks-proxy-agent/dist/agent.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -/// <reference types="node" /> -import net from 'net'; -import { Agent, ClientRequest, RequestOptions } from 'agent-base'; -import { SocksProxyAgentOptions } from '.'; -/** - * The `SocksProxyAgent`. - * - * @api public - */ -export default class SocksProxyAgent extends Agent { - private lookup; - private proxy; - private tlsConnectionOptions; - constructor(_opts: string | SocksProxyAgentOptions); - /** - * Initiates a SOCKS connection to the specified SOCKS proxy server, - * which in turn connects to the specified remote host and port. - * - * @api protected - */ - callback(req: ClientRequest, opts: RequestOptions): Promise<net.Socket>; -} diff --git a/node_modules/socks-proxy-agent/dist/agent.js b/node_modules/socks-proxy-agent/dist/agent.js deleted file mode 100644 index 1e4c529..0000000 --- a/node_modules/socks-proxy-agent/dist/agent.js +++ /dev/null @@ -1,181 +0,0 @@ -"use strict"; -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -var __importDefault = (this && this.__importDefault) || function (mod) { - return (mod && mod.__esModule) ? mod : { "default": mod }; -}; -Object.defineProperty(exports, "__esModule", { value: true }); -const dns_1 = __importDefault(require("dns")); -const tls_1 = __importDefault(require("tls")); -const url_1 = __importDefault(require("url")); -const debug_1 = __importDefault(require("debug")); -const agent_base_1 = require("agent-base"); -const socks_1 = require("socks"); -const debug = debug_1.default('socks-proxy-agent'); -function dnsLookup(host) { - return new Promise((resolve, reject) => { - dns_1.default.lookup(host, (err, res) => { - if (err) { - reject(err); - } - else { - resolve(res); - } - }); - }); -} -function parseSocksProxy(opts) { - let port = 0; - let lookup = false; - let type = 5; - // Prefer `hostname` over `host`, because of `url.parse()` - const host = opts.hostname || opts.host; - if (!host) { - throw new TypeError('No "host"'); - } - if (typeof opts.port === 'number') { - port = opts.port; - } - else if (typeof opts.port === 'string') { - port = parseInt(opts.port, 10); - } - // From RFC 1928, Section 3: https://tools.ietf.org/html/rfc1928#section-3 - // "The SOCKS service is conventionally located on TCP port 1080" - if (!port) { - port = 1080; - } - // figure out if we want socks v4 or v5, based on the "protocol" used. - // Defaults to 5. - if (opts.protocol) { - switch (opts.protocol.replace(':', '')) { - case 'socks4': - lookup = true; - // pass through - case 'socks4a': - type = 4; - break; - case 'socks5': - lookup = true; - // pass through - case 'socks': // no version specified, default to 5h - case 'socks5h': - type = 5; - break; - default: - throw new TypeError(`A "socks" protocol must be specified! Got: ${opts.protocol}`); - } - } - if (typeof opts.type !== 'undefined') { - if (opts.type === 4 || opts.type === 5) { - type = opts.type; - } - else { - throw new TypeError(`"type" must be 4 or 5, got: ${opts.type}`); - } - } - const proxy = { - host, - port, - type - }; - let userId = opts.userId || opts.username; - let password = opts.password; - if (opts.auth) { - const auth = opts.auth.split(':'); - userId = auth[0]; - password = auth[1]; - } - if (userId) { - Object.defineProperty(proxy, 'userId', { - value: userId, - enumerable: false - }); - } - if (password) { - Object.defineProperty(proxy, 'password', { - value: password, - enumerable: false - }); - } - return { lookup, proxy }; -} -/** - * The `SocksProxyAgent`. - * - * @api public - */ -class SocksProxyAgent extends agent_base_1.Agent { - constructor(_opts) { - let opts; - if (typeof _opts === 'string') { - opts = url_1.default.parse(_opts); - } - else { - opts = _opts; - } - if (!opts) { - throw new TypeError('a SOCKS proxy server `host` and `port` must be specified!'); - } - super(opts); - const parsedProxy = parseSocksProxy(opts); - this.lookup = parsedProxy.lookup; - this.proxy = parsedProxy.proxy; - this.tlsConnectionOptions = opts.tls || {}; - } - /** - * Initiates a SOCKS connection to the specified SOCKS proxy server, - * which in turn connects to the specified remote host and port. - * - * @api protected - */ - callback(req, opts) { - return __awaiter(this, void 0, void 0, function* () { - const { lookup, proxy } = this; - let { host, port, timeout } = opts; - if (!host) { - throw new Error('No `host` defined!'); - } - if (lookup) { - // Client-side DNS resolution for "4" and "5" socks proxy versions. - host = yield dnsLookup(host); - } - const socksOpts = { - proxy, - destination: { host, port }, - command: 'connect', - timeout - }; - debug('Creating socks proxy connection: %o', socksOpts); - const { socket } = yield socks_1.SocksClient.createConnection(socksOpts); - debug('Successfully created socks proxy connection'); - if (opts.secureEndpoint) { - // The proxy is connecting to a TLS server, so upgrade - // this socket connection to a TLS connection. - debug('Upgrading socket connection to TLS'); - const servername = opts.servername || opts.host; - return tls_1.default.connect(Object.assign(Object.assign(Object.assign({}, omit(opts, 'host', 'hostname', 'path', 'port')), { socket, - servername }), this.tlsConnectionOptions)); - } - return socket; - }); - } -} -exports.default = SocksProxyAgent; -function omit(obj, ...keys) { - const ret = {}; - let key; - for (key in obj) { - if (!keys.includes(key)) { - ret[key] = obj[key]; - } - } - return ret; -} -//# sourceMappingURL=agent.js.map \ No newline at end of file diff --git a/node_modules/socks-proxy-agent/dist/agent.js.map b/node_modules/socks-proxy-agent/dist/agent.js.map deleted file mode 100644 index 4efc168..0000000 --- a/node_modules/socks-proxy-agent/dist/agent.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"agent.js","sourceRoot":"","sources":["../src/agent.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,8CAAsB;AAEtB,8CAAsB;AACtB,8CAAsB;AACtB,kDAAgC;AAChC,2CAAkE;AAClE,iCAAoE;AAGpE,MAAM,KAAK,GAAG,eAAW,CAAC,mBAAmB,CAAC,CAAC;AAE/C,SAAS,SAAS,CAAC,IAAY;IAC9B,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;QACtC,aAAG,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE;YAC7B,IAAI,GAAG,EAAE;gBACR,MAAM,CAAC,GAAG,CAAC,CAAC;aACZ;iBAAM;gBACN,OAAO,CAAC,GAAG,CAAC,CAAC;aACb;QACF,CAAC,CAAC,CAAC;IACJ,CAAC,CAAC,CAAC;AACJ,CAAC;AAED,SAAS,eAAe,CACvB,IAA4B;IAE5B,IAAI,IAAI,GAAG,CAAC,CAAC;IACb,IAAI,MAAM,GAAG,KAAK,CAAC;IACnB,IAAI,IAAI,GAAuB,CAAC,CAAC;IAEjC,0DAA0D;IAC1D,MAAM,IAAI,GAAG,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,IAAI,CAAC;IACxC,IAAI,CAAC,IAAI,EAAE;QACV,MAAM,IAAI,SAAS,CAAC,WAAW,CAAC,CAAC;KACjC;IAED,IAAI,OAAO,IAAI,CAAC,IAAI,KAAK,QAAQ,EAAE;QAClC,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC;KACjB;SAAM,IAAI,OAAO,IAAI,CAAC,IAAI,KAAK,QAAQ,EAAE;QACzC,IAAI,GAAG,QAAQ,CAAC,IAAI,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;KAC/B;IAED,0EAA0E;IAC1E,iEAAiE;IACjE,IAAI,CAAC,IAAI,EAAE;QACV,IAAI,GAAG,IAAI,CAAC;KACZ;IAED,sEAAsE;IACtE,iBAAiB;IACjB,IAAI,IAAI,CAAC,QAAQ,EAAE;QAClB,QAAQ,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,EAAE;YACvC,KAAK,QAAQ;gBACZ,MAAM,GAAG,IAAI,CAAC;YACf,eAAe;YACf,KAAK,SAAS;gBACb,IAAI,GAAG,CAAC,CAAC;gBACT,MAAM;YACP,KAAK,QAAQ;gBACZ,MAAM,GAAG,IAAI,CAAC;YACf,eAAe;YACf,KAAK,OAAO,CAAC,CAAC,sCAAsC;YACpD,KAAK,SAAS;gBACb,IAAI,GAAG,CAAC,CAAC;gBACT,MAAM;YACP;gBACC,MAAM,IAAI,SAAS,CAClB,8CAA8C,IAAI,CAAC,QAAQ,EAAE,CAC7D,CAAC;SACH;KACD;IAED,IAAI,OAAO,IAAI,CAAC,IAAI,KAAK,WAAW,EAAE;QACrC,IAAI,IAAI,CAAC,IAAI,KAAK,CAAC,IAAI,IAAI,CAAC,IAAI,KAAK,CAAC,EAAE;YACvC,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC;SACjB;aAAM;YACN,MAAM,IAAI,SAAS,CAAC,+BAA+B,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;SAChE;KACD;IAED,MAAM,KAAK,GAAe;QACzB,IAAI;QACJ,IAAI;QACJ,IAAI;KACJ,CAAC;IAEF,IAAI,MAAM,GAAG,IAAI,CAAC,MAAM,IAAI,IAAI,CAAC,QAAQ,CAAC;IAC1C,IAAI,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC;IAC7B,IAAI,IAAI,CAAC,IAAI,EAAE;QACd,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QAClC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC;QACjB,QAAQ,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC;KACnB;IACD,IAAI,MAAM,EAAE;QACX,MAAM,CAAC,cAAc,CAAC,KAAK,EAAE,QAAQ,EAAE;YACtC,KAAK,EAAE,MAAM;YACb,UAAU,EAAE,KAAK;SACjB,CAAC,CAAC;KACH;IACD,IAAI,QAAQ,EAAE;QACb,MAAM,CAAC,cAAc,CAAC,KAAK,EAAE,UAAU,EAAE;YACxC,KAAK,EAAE,QAAQ;YACf,UAAU,EAAE,KAAK;SACjB,CAAC,CAAC;KACH;IAED,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;AAC1B,CAAC;AAED;;;;GAIG;AACH,MAAqB,eAAgB,SAAQ,kBAAK;IAKjD,YAAY,KAAsC;QACjD,IAAI,IAA4B,CAAC;QACjC,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;YAC9B,IAAI,GAAG,aAAG,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;SACxB;aAAM;YACN,IAAI,GAAG,KAAK,CAAC;SACb;QACD,IAAI,CAAC,IAAI,EAAE;YACV,MAAM,IAAI,SAAS,CAClB,2DAA2D,CAC3D,CAAC;SACF;QACD,KAAK,CAAC,IAAI,CAAC,CAAC;QAEZ,MAAM,WAAW,GAAG,eAAe,CAAC,IAAI,CAAC,CAAC;QAC1C,IAAI,CAAC,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC;QACjC,IAAI,CAAC,KAAK,GAAG,WAAW,CAAC,KAAK,CAAC;QAC/B,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC,GAAG,IAAI,EAAE,CAAC;IAC5C,CAAC;IAED;;;;;OAKG;IACG,QAAQ,CACb,GAAkB,EAClB,IAAoB;;YAEpB,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,IAAI,CAAC;YAC/B,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,GAAG,IAAI,CAAC;YAEnC,IAAI,CAAC,IAAI,EAAE;gBACV,MAAM,IAAI,KAAK,CAAC,oBAAoB,CAAC,CAAC;aACtC;YAED,IAAI,MAAM,EAAE;gBACX,mEAAmE;gBACnE,IAAI,GAAG,MAAM,SAAS,CAAC,IAAI,CAAC,CAAC;aAC7B;YAED,MAAM,SAAS,GAAuB;gBACrC,KAAK;gBACL,WAAW,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE;gBAC3B,OAAO,EAAE,SAAS;gBAClB,OAAO;aACP,CAAC;YACF,KAAK,CAAC,qCAAqC,EAAE,SAAS,CAAC,CAAC;YACxD,MAAM,EAAE,MAAM,EAAE,GAAG,MAAM,mBAAW,CAAC,gBAAgB,CAAC,SAAS,CAAC,CAAC;YACjE,KAAK,CAAC,6CAA6C,CAAC,CAAC;YAErD,IAAI,IAAI,CAAC,cAAc,EAAE;gBACxB,sDAAsD;gBACtD,8CAA8C;gBAC9C,KAAK,CAAC,oCAAoC,CAAC,CAAC;gBAC5C,MAAM,UAAU,GAAG,IAAI,CAAC,UAAU,IAAI,IAAI,CAAC,IAAI,CAAC;gBAChD,OAAO,aAAG,CAAC,OAAO,+CACd,IAAI,CAAC,IAAI,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,CAAC,KACjD,MAAM;oBACN,UAAU,KACP,IAAI,CAAC,oBAAoB,EAC3B,CAAC;aACH;YAED,OAAO,MAAM,CAAC;QACf,CAAC;KAAA;CACD;AAxED,kCAwEC;AAED,SAAS,IAAI,CACZ,GAAM,EACN,GAAG,IAAO;IAIV,MAAM,GAAG,GAAG,EAEX,CAAC;IACF,IAAI,GAAqB,CAAC;IAC1B,KAAK,GAAG,IAAI,GAAG,EAAE;QAChB,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE;YACxB,GAAG,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC,GAAG,CAAC,CAAC;SACpB;KACD;IACD,OAAO,GAAG,CAAC;AACZ,CAAC"} \ No newline at end of file diff --git a/node_modules/socks-proxy-agent/dist/index.d.ts b/node_modules/socks-proxy-agent/dist/index.d.ts index d031b95..4de33b1 100644 --- a/node_modules/socks-proxy-agent/dist/index.d.ts +++ b/node_modules/socks-proxy-agent/dist/index.d.ts @@ -1,21 +1,33 @@ /// <reference types="node" /> -import { Url } from 'url'; import { SocksProxy } from 'socks'; -import tls from 'tls'; +import { Agent, ClientRequest, RequestOptions } from 'agent-base'; import { AgentOptions } from 'agent-base'; -import _SocksProxyAgent from './agent'; -declare function createSocksProxyAgent(opts: string | createSocksProxyAgent.SocksProxyAgentOptions): _SocksProxyAgent; -declare namespace createSocksProxyAgent { - interface BaseSocksProxyAgentOptions { - host?: string | null; - port?: string | number | null; - username?: string | null; - tls?: tls.ConnectionOptions | null; - } - export interface SocksProxyAgentOptions extends AgentOptions, BaseSocksProxyAgentOptions, Partial<Omit<Url & SocksProxy, keyof BaseSocksProxyAgentOptions>> { - } - export type SocksProxyAgent = _SocksProxyAgent; - export const SocksProxyAgent: typeof _SocksProxyAgent; - export {}; +import { Url } from 'url'; +import net from 'net'; +import tls from 'tls'; +interface BaseSocksProxyAgentOptions { + host?: string | null; + port?: string | number | null; + username?: string | null; + tls?: tls.ConnectionOptions | null; } -export = createSocksProxyAgent; +interface SocksProxyAgentOptionsExtra { + timeout?: number; +} +export interface SocksProxyAgentOptions extends AgentOptions, BaseSocksProxyAgentOptions, Partial<Omit<Url & SocksProxy, keyof BaseSocksProxyAgentOptions>> { +} +export declare class SocksProxyAgent extends Agent { + private readonly shouldLookup; + private readonly proxy; + private readonly tlsConnectionOptions; + timeout: number | null; + constructor(input: string | SocksProxyAgentOptions, options?: SocksProxyAgentOptionsExtra); + /** + * Initiates a SOCKS connection to the specified SOCKS proxy server, + * which in turn connects to the specified remote host and port. + * + * @api protected + */ + callback(req: ClientRequest, opts: RequestOptions): Promise<net.Socket>; +} +export {}; diff --git a/node_modules/socks-proxy-agent/dist/index.js b/node_modules/socks-proxy-agent/dist/index.js index dd1e49a..55b598b 100644 --- a/node_modules/socks-proxy-agent/dist/index.js +++ b/node_modules/socks-proxy-agent/dist/index.js @@ -1,14 +1,197 @@ "use strict"; +var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { + function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } + return new (P || (P = Promise))(function (resolve, reject) { + function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } + function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } + function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + step((generator = generator.apply(thisArg, _arguments || [])).next()); + }); +}; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; -const agent_1 = __importDefault(require("./agent")); -function createSocksProxyAgent(opts) { - return new agent_1.default(opts); +Object.defineProperty(exports, "__esModule", { value: true }); +exports.SocksProxyAgent = void 0; +const socks_1 = require("socks"); +const agent_base_1 = require("agent-base"); +const debug_1 = __importDefault(require("debug")); +const dns_1 = __importDefault(require("dns")); +const tls_1 = __importDefault(require("tls")); +const debug = (0, debug_1.default)('socks-proxy-agent'); +function parseSocksProxy(opts) { + var _a; + let port = 0; + let lookup = false; + let type = 5; + const host = opts.hostname; + if (host == null) { + throw new TypeError('No "host"'); + } + if (typeof opts.port === 'number') { + port = opts.port; + } + else if (typeof opts.port === 'string') { + port = parseInt(opts.port, 10); + } + // From RFC 1928, Section 3: https://tools.ietf.org/html/rfc1928#section-3 + // "The SOCKS service is conventionally located on TCP port 1080" + if (port == null) { + port = 1080; + } + // figure out if we want socks v4 or v5, based on the "protocol" used. + // Defaults to 5. + if (opts.protocol != null) { + switch (opts.protocol.replace(':', '')) { + case 'socks4': + lookup = true; + // pass through + case 'socks4a': + type = 4; + break; + case 'socks5': + lookup = true; + // pass through + case 'socks': // no version specified, default to 5h + case 'socks5h': + type = 5; + break; + default: + throw new TypeError(`A "socks" protocol must be specified! Got: ${String(opts.protocol)}`); + } + } + if (typeof opts.type !== 'undefined') { + if (opts.type === 4 || opts.type === 5) { + type = opts.type; + } + else { + throw new TypeError(`"type" must be 4 or 5, got: ${String(opts.type)}`); + } + } + const proxy = { + host, + port, + type + }; + let userId = (_a = opts.userId) !== null && _a !== void 0 ? _a : opts.username; + let password = opts.password; + if (opts.auth != null) { + const auth = opts.auth.split(':'); + userId = auth[0]; + password = auth[1]; + } + if (userId != null) { + Object.defineProperty(proxy, 'userId', { + value: userId, + enumerable: false + }); + } + if (password != null) { + Object.defineProperty(proxy, 'password', { + value: password, + enumerable: false + }); + } + return { lookup, proxy }; +} +const normalizeProxyOptions = (input) => { + let proxyOptions; + if (typeof input === 'string') { + proxyOptions = new URL(input); + } + else { + proxyOptions = input; + } + if (proxyOptions == null) { + throw new TypeError('a SOCKS proxy server `host` and `port` must be specified!'); + } + return proxyOptions; +}; +class SocksProxyAgent extends agent_base_1.Agent { + constructor(input, options) { + var _a; + const proxyOptions = normalizeProxyOptions(input); + super(proxyOptions); + const parsedProxy = parseSocksProxy(proxyOptions); + this.shouldLookup = parsedProxy.lookup; + this.proxy = parsedProxy.proxy; + this.tlsConnectionOptions = proxyOptions.tls != null ? proxyOptions.tls : {}; + this.timeout = (_a = options === null || options === void 0 ? void 0 : options.timeout) !== null && _a !== void 0 ? _a : null; + } + /** + * Initiates a SOCKS connection to the specified SOCKS proxy server, + * which in turn connects to the specified remote host and port. + * + * @api protected + */ + callback(req, opts) { + var _a; + return __awaiter(this, void 0, void 0, function* () { + const { shouldLookup, proxy, timeout } = this; + let { host, port, lookup: lookupCallback } = opts; + if (host == null) { + throw new Error('No `host` defined!'); + } + if (shouldLookup) { + // Client-side DNS resolution for "4" and "5" socks proxy versions. + host = yield new Promise((resolve, reject) => { + // Use the request's custom lookup, if one was configured: + const lookupFn = lookupCallback !== null && lookupCallback !== void 0 ? lookupCallback : dns_1.default.lookup; + lookupFn(host, {}, (err, res) => { + if (err) { + reject(err); + } + else { + resolve(res); + } + }); + }); + } + const socksOpts = { + proxy, + destination: { host, port }, + command: 'connect', + timeout: timeout !== null && timeout !== void 0 ? timeout : undefined + }; + const cleanup = (tlsSocket) => { + req.destroy(); + socket.destroy(); + if (tlsSocket) + tlsSocket.destroy(); + }; + debug('Creating socks proxy connection: %o', socksOpts); + const { socket } = yield socks_1.SocksClient.createConnection(socksOpts); + debug('Successfully created socks proxy connection'); + if (timeout !== null) { + socket.setTimeout(timeout); + socket.on('timeout', () => cleanup()); + } + if (opts.secureEndpoint) { + // The proxy is connecting to a TLS server, so upgrade + // this socket connection to a TLS connection. + debug('Upgrading socket connection to TLS'); + const servername = (_a = opts.servername) !== null && _a !== void 0 ? _a : opts.host; + const tlsSocket = tls_1.default.connect(Object.assign(Object.assign(Object.assign({}, omit(opts, 'host', 'hostname', 'path', 'port')), { socket, + servername }), this.tlsConnectionOptions)); + tlsSocket.once('error', (error) => { + debug('socket TLS error', error.message); + cleanup(tlsSocket); + }); + return tlsSocket; + } + return socket; + }); + } +} +exports.SocksProxyAgent = SocksProxyAgent; +function omit(obj, ...keys) { + const ret = {}; + let key; + for (key in obj) { + if (!keys.includes(key)) { + ret[key] = obj[key]; + } + } + return ret; } -(function (createSocksProxyAgent) { - createSocksProxyAgent.SocksProxyAgent = agent_1.default; - createSocksProxyAgent.prototype = agent_1.default.prototype; -})(createSocksProxyAgent || (createSocksProxyAgent = {})); -module.exports = createSocksProxyAgent; //# sourceMappingURL=index.js.map \ No newline at end of file diff --git a/node_modules/socks-proxy-agent/dist/index.js.map b/node_modules/socks-proxy-agent/dist/index.js.map index 23f3d1c..e183e8e 100644 --- a/node_modules/socks-proxy-agent/dist/index.js.map +++ b/node_modules/socks-proxy-agent/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;AAIA,oDAAuC;AAEvC,SAAS,qBAAqB,CAC7B,IAA2D;IAE3D,OAAO,IAAI,eAAgB,CAAC,IAAI,CAAC,CAAC;AACnC,CAAC;AAED,WAAU,qBAAqB;IAcjB,qCAAe,GAAG,eAAgB,CAAC;IAEhD,qBAAqB,CAAC,SAAS,GAAG,eAAgB,CAAC,SAAS,CAAC;AAC9D,CAAC,EAjBS,qBAAqB,KAArB,qBAAqB,QAiB9B;AAED,iBAAS,qBAAqB,CAAC"} \ No newline at end of file +{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,iCAAmE;AACnE,2CAAiE;AAEjE,kDAA+B;AAE/B,8CAAqB;AAErB,8CAAqB;AAarB,MAAM,KAAK,GAAG,IAAA,eAAW,EAAC,mBAAmB,CAAC,CAAA;AAE9C,SAAS,eAAe,CAAE,IAA4B;;IACpD,IAAI,IAAI,GAAG,CAAC,CAAA;IACZ,IAAI,MAAM,GAAG,KAAK,CAAA;IAClB,IAAI,IAAI,GAAuB,CAAC,CAAA;IAEhC,MAAM,IAAI,GAAG,IAAI,CAAC,QAAQ,CAAA;IAE1B,IAAI,IAAI,IAAI,IAAI,EAAE;QAChB,MAAM,IAAI,SAAS,CAAC,WAAW,CAAC,CAAA;KACjC;IAED,IAAI,OAAO,IAAI,CAAC,IAAI,KAAK,QAAQ,EAAE;QACjC,IAAI,GAAG,IAAI,CAAC,IAAI,CAAA;KACjB;SAAM,IAAI,OAAO,IAAI,CAAC,IAAI,KAAK,QAAQ,EAAE;QACxC,IAAI,GAAG,QAAQ,CAAC,IAAI,CAAC,IAAI,EAAE,EAAE,CAAC,CAAA;KAC/B;IAED,0EAA0E;IAC1E,iEAAiE;IACjE,IAAI,IAAI,IAAI,IAAI,EAAE;QAChB,IAAI,GAAG,IAAI,CAAA;KACZ;IAED,sEAAsE;IACtE,iBAAiB;IACjB,IAAI,IAAI,CAAC,QAAQ,IAAI,IAAI,EAAE;QACzB,QAAQ,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,EAAE;YACtC,KAAK,QAAQ;gBACX,MAAM,GAAG,IAAI,CAAA;YACf,eAAe;YACf,KAAK,SAAS;gBACZ,IAAI,GAAG,CAAC,CAAA;gBACR,MAAK;YACP,KAAK,QAAQ;gBACX,MAAM,GAAG,IAAI,CAAA;YACf,eAAe;YACf,KAAK,OAAO,CAAC,CAAC,sCAAsC;YACpD,KAAK,SAAS;gBACZ,IAAI,GAAG,CAAC,CAAA;gBACR,MAAK;YACP;gBACE,MAAM,IAAI,SAAS,CAAC,8CAA8C,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAA;SAC7F;KACF;IAED,IAAI,OAAO,IAAI,CAAC,IAAI,KAAK,WAAW,EAAE;QACpC,IAAI,IAAI,CAAC,IAAI,KAAK,CAAC,IAAI,IAAI,CAAC,IAAI,KAAK,CAAC,EAAE;YACtC,IAAI,GAAG,IAAI,CAAC,IAAI,CAAA;SACjB;aAAM;YACL,MAAM,IAAI,SAAS,CAAC,+BAA+B,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;SACxE;KACF;IAED,MAAM,KAAK,GAAe;QACxB,IAAI;QACJ,IAAI;QACJ,IAAI;KACL,CAAA;IAED,IAAI,MAAM,GAAG,MAAA,IAAI,CAAC,MAAM,mCAAI,IAAI,CAAC,QAAQ,CAAA;IACzC,IAAI,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAA;IAC5B,IAAI,IAAI,CAAC,IAAI,IAAI,IAAI,EAAE;QACrB,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAA;QACjC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAA;QAChB,QAAQ,GAAG,IAAI,CAAC,CAAC,CAAC,CAAA;KACnB;IACD,IAAI,MAAM,IAAI,IAAI,EAAE;QAClB,MAAM,CAAC,cAAc,CAAC,KAAK,EAAE,QAAQ,EAAE;YACrC,KAAK,EAAE,MAAM;YACb,UAAU,EAAE,KAAK;SAClB,CAAC,CAAA;KACH;IACD,IAAI,QAAQ,IAAI,IAAI,EAAE;QACpB,MAAM,CAAC,cAAc,CAAC,KAAK,EAAE,UAAU,EAAE;YACvC,KAAK,EAAE,QAAQ;YACf,UAAU,EAAE,KAAK;SAClB,CAAC,CAAA;KACH;IAED,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,CAAA;AAC1B,CAAC;AAED,MAAM,qBAAqB,GAAG,CAAC,KAAsC,EAA0B,EAAE;IAC/F,IAAI,YAAoC,CAAA;IACxC,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;QAC7B,YAAY,GAAG,IAAI,GAAG,CAAC,KAAK,CAAC,CAAA;KAC9B;SAAM;QACL,YAAY,GAAG,KAAK,CAAA;KACrB;IACD,IAAI,YAAY,IAAI,IAAI,EAAE;QACxB,MAAM,IAAI,SAAS,CAAC,2DAA2D,CAAC,CAAA;KACjF;IAED,OAAO,YAAY,CAAA;AACrB,CAAC,CAAA;AAID,MAAa,eAAgB,SAAQ,kBAAK;IAMxC,YAAa,KAAsC,EAAE,OAAqC;;QACxF,MAAM,YAAY,GAAG,qBAAqB,CAAC,KAAK,CAAC,CAAA;QACjD,KAAK,CAAC,YAAY,CAAC,CAAA;QAEnB,MAAM,WAAW,GAAG,eAAe,CAAC,YAAY,CAAC,CAAA;QAEjD,IAAI,CAAC,YAAY,GAAG,WAAW,CAAC,MAAM,CAAA;QACtC,IAAI,CAAC,KAAK,GAAG,WAAW,CAAC,KAAK,CAAA;QAC9B,IAAI,CAAC,oBAAoB,GAAG,YAAY,CAAC,GAAG,IAAI,IAAI,CAAC,CAAC,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAA;QAC5E,IAAI,CAAC,OAAO,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,OAAO,mCAAI,IAAI,CAAA;IACzC,CAAC;IAED;;;;;OAKG;IACG,QAAQ,CAAE,GAAkB,EAAE,IAAoB;;;YACtD,MAAM,EAAE,YAAY,EAAE,KAAK,EAAE,OAAO,EAAE,GAAG,IAAI,CAAA;YAE7C,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,cAAc,EAAE,GAAG,IAAI,CAAA;YAEjD,IAAI,IAAI,IAAI,IAAI,EAAE;gBAChB,MAAM,IAAI,KAAK,CAAC,oBAAoB,CAAC,CAAA;aACtC;YAED,IAAI,YAAY,EAAE;gBAChB,mEAAmE;gBACnE,IAAI,GAAG,MAAM,IAAI,OAAO,CAAS,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;oBACnD,0DAA0D;oBAC1D,MAAM,QAAQ,GAAG,cAAc,aAAd,cAAc,cAAd,cAAc,GAAI,aAAG,CAAC,MAAM,CAAA;oBAC7C,QAAQ,CAAC,IAAK,EAAE,EAAE,EAAE,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE;wBAC/B,IAAI,GAAG,EAAE;4BACP,MAAM,CAAC,GAAG,CAAC,CAAA;yBACZ;6BAAM;4BACL,OAAO,CAAC,GAAG,CAAC,CAAA;yBACb;oBACH,CAAC,CAAC,CAAA;gBACJ,CAAC,CAAC,CAAA;aACH;YAED,MAAM,SAAS,GAAuB;gBACpC,KAAK;gBACL,WAAW,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE;gBAC3B,OAAO,EAAE,SAAS;gBAClB,OAAO,EAAE,OAAO,aAAP,OAAO,cAAP,OAAO,GAAI,SAAS;aAC9B,CAAA;YAED,MAAM,OAAO,GAAG,CAAC,SAAyB,EAAE,EAAE;gBAC5C,GAAG,CAAC,OAAO,EAAE,CAAA;gBACb,MAAM,CAAC,OAAO,EAAE,CAAA;gBAChB,IAAI,SAAS;oBAAE,SAAS,CAAC,OAAO,EAAE,CAAA;YACpC,CAAC,CAAA;YAED,KAAK,CAAC,qCAAqC,EAAE,SAAS,CAAC,CAAA;YACvD,MAAM,EAAE,MAAM,EAAE,GAAG,MAAM,mBAAW,CAAC,gBAAgB,CAAC,SAAS,CAAC,CAAA;YAChE,KAAK,CAAC,6CAA6C,CAAC,CAAA;YAEpD,IAAI,OAAO,KAAK,IAAI,EAAE;gBACpB,MAAM,CAAC,UAAU,CAAC,OAAO,CAAC,CAAA;gBAC1B,MAAM,CAAC,EAAE,CAAC,SAAS,EAAE,GAAG,EAAE,CAAC,OAAO,EAAE,CAAC,CAAA;aACtC;YAED,IAAI,IAAI,CAAC,cAAc,EAAE;gBACvB,sDAAsD;gBACtD,8CAA8C;gBAC9C,KAAK,CAAC,oCAAoC,CAAC,CAAA;gBAC3C,MAAM,UAAU,GAAG,MAAA,IAAI,CAAC,UAAU,mCAAI,IAAI,CAAC,IAAI,CAAA;gBAE/C,MAAM,SAAS,GAAG,aAAG,CAAC,OAAO,+CACxB,IAAI,CAAC,IAAI,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,CAAC,KACjD,MAAM;oBACN,UAAU,KACP,IAAI,CAAC,oBAAoB,EAC5B,CAAA;gBAEF,SAAS,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,KAAK,EAAE,EAAE;oBAChC,KAAK,CAAC,kBAAkB,EAAE,KAAK,CAAC,OAAO,CAAC,CAAA;oBACxC,OAAO,CAAC,SAAS,CAAC,CAAA;gBACpB,CAAC,CAAC,CAAA;gBAEF,OAAO,SAAS,CAAA;aACjB;YAED,OAAO,MAAM,CAAA;;KACd;CACF;AA7FD,0CA6FC;AAED,SAAS,IAAI,CACX,GAAM,EACN,GAAG,IAAO;IAIV,MAAM,GAAG,GAAG,EAAgD,CAAA;IAC5D,IAAI,GAAqB,CAAA;IACzB,KAAK,GAAG,IAAI,GAAG,EAAE;QACf,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE;YACvB,GAAG,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC,GAAG,CAAC,CAAA;SACpB;KACF;IACD,OAAO,GAAG,CAAA;AACZ,CAAC"} \ No newline at end of file diff --git a/node_modules/socks-proxy-agent/package.json b/node_modules/socks-proxy-agent/package.json index 4600431..aa29999 100644 --- a/node_modules/socks-proxy-agent/package.json +++ b/node_modules/socks-proxy-agent/package.json @@ -1,64 +1,181 @@ { "name": "socks-proxy-agent", - "version": "6.1.1", "description": "A SOCKS proxy `http.Agent` implementation for HTTP and HTTPS", - "main": "dist/index", - "typings": "dist/index.d.ts", - "files": [ - "dist" - ], - "scripts": { - "prebuild": "rimraf dist", - "build": "tsc", - "test": "mocha --reporter spec", - "test-lint": "eslint src --ext .js,.ts", - "prepublishOnly": "npm run build" + "homepage": "https://github.com/TooTallNate/node-socks-proxy-agent#readme", + "version": "7.0.0", + "main": "dist/index.js", + "author": { + "email": "nathan@tootallnate.net", + "name": "Nathan Rajlich", + "url": "http://n8.io/" }, + "contributors": [ + { + "name": "Kiko Beats", + "email": "josefrancisco.verdu@gmail.com" + }, + { + "name": "Josh Glazebrook", + "email": "josh@joshglazebrook.com" + }, + { + "name": "talmobi", + "email": "talmobi@users.noreply.github.com" + }, + { + "name": "Indospace.io", + "email": "justin@indospace.io" + }, + { + "name": "Kilian von Pflugk", + "email": "github@jumoog.io" + }, + { + "name": "Kyle", + "email": "admin@hk1229.cn" + }, + { + "name": "Matheus Fernandes", + "email": "matheus.frndes@gmail.com" + }, + { + "name": "Ricky Miller", + "email": "richardkazuomiller@gmail.com" + }, + { + "name": "Shantanu Sharma", + "email": "shantanu34@outlook.com" + }, + { + "name": "Tim Perry", + "email": "pimterry@gmail.com" + }, + { + "name": "Vadim Baryshev", + "email": "vadimbaryshev@gmail.com" + }, + { + "name": "jigu", + "email": "luo1257857309@gmail.com" + }, + { + "name": "Alba Mendez", + "email": "me@jmendeth.com" + }, + { + "name": "Дмитрий Гуденков", + "email": "Dimangud@rambler.ru" + }, + { + "name": "Andrei Bitca", + "email": "63638922+andrei-bitca-dc@users.noreply.github.com" + }, + { + "name": "Andrew Casey", + "email": "amcasey@users.noreply.github.com" + }, + { + "name": "Brandon Ros", + "email": "brandonros1@gmail.com" + }, + { + "name": "Dang Duy Thanh", + "email": "thanhdd.it@gmail.com" + }, + { + "name": "Dimitar Nestorov", + "email": "8790386+dimitarnestorov@users.noreply.github.com" + } + ], "repository": { "type": "git", "url": "git://github.com/TooTallNate/node-socks-proxy-agent.git" }, + "bugs": { + "url": "https://github.com/TooTallNate/node-socks-proxy-agent/issues" + }, "keywords": [ + "agent", + "http", + "https", + "proxy", "socks", "socks4", "socks4a", "socks5", - "socks5h", - "proxy", - "http", - "https", - "agent" + "socks5h" ], - "author": "Nathan Rajlich <nathan@tootallnate.net> (http://n8.io/)", - "license": "MIT", - "bugs": { - "url": "https://github.com/TooTallNate/node-socks-proxy-agent/issues" - }, "dependencies": { "agent-base": "^6.0.2", - "debug": "^4.3.1", - "socks": "^2.6.1" + "debug": "^4.3.3", + "socks": "^2.6.2" }, "devDependencies": { + "@commitlint/cli": "latest", + "@commitlint/config-conventional": "latest", "@types/debug": "latest", "@types/node": "latest", - "@typescript-eslint/eslint-plugin": "latest", - "@typescript-eslint/parser": "latest", - "eslint": "latest", - "eslint-config-airbnb": "latest", - "eslint-config-prettier": "latest", - "eslint-import-resolver-typescript": "latest", - "eslint-plugin-import": "latest", - "eslint-plugin-jsx-a11y": "latest", - "eslint-plugin-react": "latest", - "mocha": "latest", - "proxy": "latest", + "cacheable-lookup": "latest", + "conventional-github-releaser": "latest", + "dns2": "latest", + "finepack": "latest", + "git-authors-cli": "latest", + "mocha": "9", + "nano-staged": "latest", + "npm-check-updates": "latest", + "prettier-standard": "latest", "raw-body": "latest", "rimraf": "latest", - "socksv5": "TooTallNate/socksv5#fix/dstSock-close-event", + "simple-git-hooks": "latest", + "socksv5": "github:TooTallNate/socksv5#fix/dstSock-close-event", + "standard": "latest", + "standard-markdown": "latest", + "standard-version": "latest", + "ts-standard": "latest", "typescript": "latest" }, "engines": { "node": ">= 10" - } + }, + "files": [ + "dist" + ], + "scripts": { + "build": "tsc", + "clean": "rimraf node_modules", + "contributors": "(git-authors-cli && finepack && git add package.json && git commit -m 'build: contributors' --no-verify) || true", + "lint": "ts-standard", + "postrelease": "npm run release:tags && npm run release:github && (ci-publish || npm publish --access=public)", + "prebuild": "rimraf dist", + "prepublishOnly": "npm run build", + "prerelease": "npm run update:check && npm run contributors", + "release": "standard-version -a", + "release:github": "conventional-github-releaser -p angular", + "release:tags": "git push --follow-tags origin HEAD:master", + "test": "mocha --reporter spec", + "update": "ncu -u", + "update:check": "ncu -- --error-level 2" + }, + "license": "MIT", + "commitlint": { + "extends": [ + "@commitlint/config-conventional" + ] + }, + "nano-staged": { + "*.js": [ + "prettier-standard" + ], + "*.md": [ + "standard-markdown" + ], + "package.json": [ + "finepack" + ] + }, + "simple-git-hooks": { + "commit-msg": "npx commitlint --edit", + "pre-commit": "npx nano-staged" + }, + "typings": "dist/index.d.ts" } diff --git a/node_modules/socks/build/client/socksclient.js b/node_modules/socks/build/client/socksclient.js index 8bda6f7..05da4ba 100644 --- a/node_modules/socks/build/client/socksclient.js +++ b/node_modules/socks/build/client/socksclient.js @@ -24,7 +24,7 @@ class SocksClient extends events_1.EventEmitter { super(); this.options = Object.assign({}, options); // Validate SocksClientOptions - helpers_1.validateSocksClientOptions(options); + (0, helpers_1.validateSocksClientOptions)(options); // Default state this.setState(constants_1.SocksClientState.Created); } @@ -40,11 +40,12 @@ class SocksClient extends events_1.EventEmitter { return new Promise((resolve, reject) => { // Validate SocksClientOptions try { - helpers_1.validateSocksClientOptions(options, ['connect']); + (0, helpers_1.validateSocksClientOptions)(options, ['connect']); } catch (err) { if (typeof callback === 'function') { callback(err); + // eslint-disable-next-line @typescript-eslint/no-explicit-any return resolve(err); // Resolves pending promise (prevents memory leaks). } else { @@ -68,6 +69,7 @@ class SocksClient extends events_1.EventEmitter { client.removeAllListeners(); if (typeof callback === 'function') { callback(err); + // eslint-disable-next-line @typescript-eslint/no-explicit-any resolve(err); // Resolves pending promise (prevents memory leaks). } else { @@ -86,14 +88,16 @@ class SocksClient extends events_1.EventEmitter { * @returns { Promise } */ static createConnectionChain(options, callback) { + // eslint-disable-next-line no-async-promise-executor return new Promise((resolve, reject) => __awaiter(this, void 0, void 0, function* () { // Validate SocksClientChainOptions try { - helpers_1.validateSocksClientChainOptions(options); + (0, helpers_1.validateSocksClientChainOptions)(options); } catch (err) { if (typeof callback === 'function') { callback(err); + // eslint-disable-next-line @typescript-eslint/no-explicit-any return resolve(err); // Resolves pending promise (prevents memory leaks). } else { @@ -103,17 +107,17 @@ class SocksClient extends events_1.EventEmitter { let sock; // Shuffle proxies if (options.randomizeChain) { - util_1.shuffleArray(options.proxies); + (0, util_1.shuffleArray)(options.proxies); } try { - // tslint:disable-next-line:no-increment-decrement for (let i = 0; i < options.proxies.length; i++) { const nextProxy = options.proxies[i]; // If we've reached the last proxy in the chain, the destination is the actual destination, otherwise it's the next proxy. const nextDestination = i === options.proxies.length - 1 ? options.destination : { - host: options.proxies[i + 1].ipaddress, + host: options.proxies[i + 1].host || + options.proxies[i + 1].ipaddress, port: options.proxies[i + 1].port, }; // Creates the next connection in the chain. @@ -139,6 +143,7 @@ class SocksClient extends events_1.EventEmitter { catch (err) { if (typeof callback === 'function') { callback(err); + // eslint-disable-next-line @typescript-eslint/no-explicit-any resolve(err); // Resolves pending promise (prevents memory leaks). } else { @@ -549,7 +554,8 @@ class SocksClient extends events_1.EventEmitter { } sendSocks5CustomAuthentication() { return __awaiter(this, void 0, void 0, function* () { - this.nextRequiredPacketBufferSize = this.options.proxy.custom_auth_response_size; + this.nextRequiredPacketBufferSize = + this.options.proxy.custom_auth_response_size; this.socket.write(yield this.options.proxy.custom_auth_request_handler()); this.setState(constants_1.SocksClientState.SentAuthentication); }); @@ -581,7 +587,8 @@ class SocksClient extends events_1.EventEmitter { authResult = yield this.handleSocks5AuthenticationNoAuthHandshakeResponse(this.receiveBuffer.get(2)); } else if (this.socks5ChosenAuthType === constants_1.Socks5Auth.UserPass) { - authResult = yield this.handleSocks5AuthenticationUserPassHandshakeResponse(this.receiveBuffer.get(2)); + authResult = + yield this.handleSocks5AuthenticationUserPassHandshakeResponse(this.receiveBuffer.get(2)); } else if (this.socks5ChosenAuthType === this.options.proxy.custom_auth_method) { authResult = yield this.handleSocks5CustomAuthHandshakeResponse(this.receiveBuffer.get(this.options.proxy.custom_auth_response_size)); diff --git a/node_modules/socks/build/client/socksclient.js.map b/node_modules/socks/build/client/socksclient.js.map index 25843ac..b39f3ad 100644 --- a/node_modules/socks/build/client/socksclient.js.map +++ b/node_modules/socks/build/client/socksclient.js.map @@ -1 +1 @@ -{"version":3,"file":"socksclient.js","sourceRoot":"","sources":["../../src/client/socksclient.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,mCAAoC;AACpC,2BAA2B;AAC3B,yBAAyB;AACzB,+CAAyC;AACzC,mDAkB6B;AAC7B,+CAG2B;AAC3B,2DAAsD;AACtD,yCAA8D;AA86B5D,iGA96BM,uBAAgB,OA86BN;AAp5BlB,MAAM,WAAY,SAAQ,qBAAY;IAgBpC,YAAY,OAA2B;QACrC,KAAK,EAAE,CAAC;QACR,IAAI,CAAC,OAAO,qBACP,OAAO,CACX,CAAC;QAEF,8BAA8B;QAC9B,oCAA0B,CAAC,OAAO,CAAC,CAAC;QAEpC,gBAAgB;QAChB,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,OAAO,CAAC,CAAC;IAC1C,CAAC;IAED;;;;;;;OAOG;IACH,MAAM,CAAC,gBAAgB,CACrB,OAA2B,EAC3B,QAAmB;QAEnB,OAAO,IAAI,OAAO,CAA8B,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;YAClE,8BAA8B;YAC9B,IAAI;gBACF,oCAA0B,CAAC,OAAO,EAAE,CAAC,SAAS,CAAC,CAAC,CAAC;aAClD;YAAC,OAAO,GAAG,EAAE;gBACZ,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,GAAG,CAAC,CAAC;oBACd,OAAO,OAAO,CAAC,GAAU,CAAC,CAAC,CAAC,oDAAoD;iBACjF;qBAAM;oBACL,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;iBACpB;aACF;YAED,MAAM,MAAM,GAAG,IAAI,WAAW,CAAC,OAAO,CAAC,CAAC;YACxC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,eAAe,CAAC,CAAC;YACxC,MAAM,CAAC,IAAI,CAAC,aAAa,EAAE,CAAC,IAAiC,EAAE,EAAE;gBAC/D,MAAM,CAAC,kBAAkB,EAAE,CAAC;gBAC5B,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;oBACrB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,oDAAoD;iBACpE;qBAAM;oBACL,OAAO,CAAC,IAAI,CAAC,CAAC;iBACf;YACH,CAAC,CAAC,CAAC;YAEH,kDAAkD;YAClD,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,GAAU,EAAE,EAAE;gBAClC,MAAM,CAAC,kBAAkB,EAAE,CAAC;gBAC5B,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,GAAG,CAAC,CAAC;oBACd,OAAO,CAAC,GAAU,CAAC,CAAC,CAAC,oDAAoD;iBAC1E;qBAAM;oBACL,MAAM,CAAC,GAAG,CAAC,CAAC;iBACb;YACH,CAAC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;OAQG;IACH,MAAM,CAAC,qBAAqB,CAC1B,OAAgC,EAChC,QAAmB;QAEnB,OAAO,IAAI,OAAO,CAA8B,CAAO,OAAO,EAAE,MAAM,EAAE,EAAE;YACxE,mCAAmC;YACnC,IAAI;gBACF,yCAA+B,CAAC,OAAO,CAAC,CAAC;aAC1C;YAAC,OAAO,GAAG,EAAE;gBACZ,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,GAAG,CAAC,CAAC;oBACd,OAAO,OAAO,CAAC,GAAU,CAAC,CAAC,CAAC,oDAAoD;iBACjF;qBAAM;oBACL,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;iBACpB;aACF;YAED,IAAI,IAAgB,CAAC;YAErB,kBAAkB;YAClB,IAAI,OAAO,CAAC,cAAc,EAAE;gBAC1B,mBAAY,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;aAC/B;YAED,IAAI;gBACF,kDAAkD;gBAClD,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE;oBAC/C,MAAM,SAAS,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;oBAErC,0HAA0H;oBAC1H,MAAM,eAAe,GACnB,CAAC,KAAK,OAAO,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC;wBAC9B,CAAC,CAAC,OAAO,CAAC,WAAW;wBACrB,CAAC,CAAC;4BACE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,SAAS;4BACtC,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI;yBAClC,CAAC;oBAER,4CAA4C;oBAC5C,MAAM,MAAM,GAAG,MAAM,WAAW,CAAC,gBAAgB,CAAC;wBAChD,OAAO,EAAE,SAAS;wBAClB,KAAK,EAAE,SAAS;wBAChB,WAAW,EAAE,eAAe;wBAC5B,8HAA8H;qBAC/H,CAAC,CAAC;oBAEH,wCAAwC;oBACxC,IAAI,CAAC,IAAI,EAAE;wBACT,IAAI,GAAG,MAAM,CAAC,MAAM,CAAC;qBACtB;iBACF;gBAED,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,IAAI,EAAE,EAAC,MAAM,EAAE,IAAI,EAAC,CAAC,CAAC;oBAC/B,OAAO,CAAC,EAAC,MAAM,EAAE,IAAI,EAAC,CAAC,CAAC,CAAC,oDAAoD;iBAC9E;qBAAM;oBACL,OAAO,CAAC,EAAC,MAAM,EAAE,IAAI,EAAC,CAAC,CAAC;iBACzB;aACF;YAAC,OAAO,GAAG,EAAE;gBACZ,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,GAAG,CAAC,CAAC;oBACd,OAAO,CAAC,GAAU,CAAC,CAAC,CAAC,oDAAoD;iBAC1E;qBAAM;oBACL,MAAM,CAAC,GAAG,CAAC,CAAC;iBACb;aACF;QACH,CAAC,CAAA,CAAC,CAAC;IACL,CAAC;IAED;;;OAGG;IACH,MAAM,CAAC,cAAc,CAAC,OAA6B;QACjD,MAAM,IAAI,GAAG,IAAI,0BAAW,EAAE,CAAC;QAC/B,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC;QACtB,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,WAAW,IAAI,CAAC,CAAC,CAAC;QAE1C,qBAAqB;QACrB,IAAI,GAAG,CAAC,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,EAAE;YACvC,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,IAAI,CAAC,CAAC;YACrC,IAAI,CAAC,aAAa,CAAC,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC;SACxD;aAAM,IAAI,GAAG,CAAC,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,EAAE;YAC9C,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,IAAI,CAAC,CAAC;YACrC,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC,QAAQ,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC;SACxD;aAAM;YACL,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,QAAQ,CAAC,CAAC;YACzC,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC;YAC5D,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;SAC3C;QAED,OAAO;QACP,IAAI,CAAC,aAAa,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QAE5C,OAAO;QACP,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;QAE/B,OAAO,IAAI,CAAC,QAAQ,EAAE,CAAC;IACzB,CAAC;IAED;;;OAGG;IACH,MAAM,CAAC,aAAa,CAAC,IAAY;QAC/B,MAAM,IAAI,GAAG,0BAAW,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QAC1C,IAAI,CAAC,UAAU,GAAG,CAAC,CAAC;QAEpB,MAAM,WAAW,GAAG,IAAI,CAAC,SAAS,EAAE,CAAC;QACrC,MAAM,QAAQ,GAAmB,IAAI,CAAC,SAAS,EAAE,CAAC;QAClD,IAAI,UAAU,CAAC;QAEf,IAAI,QAAQ,KAAK,0BAAc,CAAC,IAAI,EAAE;YACpC,UAAU,GAAG,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE,CAAC,CAAC;SAC/C;aAAM,IAAI,QAAQ,KAAK,0BAAc,CAAC,IAAI,EAAE;YAC3C,UAAU,GAAG,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC,CAAC;SAC/C;aAAM;YACL,UAAU,GAAG,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,SAAS,EAAE,CAAC,CAAC;SAChD;QAED,MAAM,UAAU,GAAG,IAAI,CAAC,YAAY,EAAE,CAAC;QAEvC,OAAO;YACL,WAAW;YACX,UAAU,EAAE;gBACV,IAAI,EAAE,UAAU;gBAChB,IAAI,EAAE,UAAU;aACjB;YACD,IAAI,EAAE,IAAI,CAAC,UAAU,EAAE;SACxB,CAAC;IACJ,CAAC;IAED;;OAEG;IACK,QAAQ,CAAC,QAA0B;QACzC,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,KAAK,EAAE;YACzC,IAAI,CAAC,KAAK,GAAG,QAAQ,CAAC;SACvB;IACH,CAAC;IAED;;;OAGG;IACI,OAAO,CAAC,cAAuB;QACpC,IAAI,CAAC,cAAc,GAAG,CAAC,IAAY,EAAE,EAAE,CAAC,IAAI,CAAC,qBAAqB,CAAC,IAAI,CAAC,CAAC;QACzE,IAAI,CAAC,OAAO,GAAG,GAAG,EAAE,CAAC,IAAI,CAAC,cAAc,EAAE,CAAC;QAC3C,IAAI,CAAC,OAAO,GAAG,CAAC,GAAU,EAAE,EAAE,CAAC,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC;QACxD,IAAI,CAAC,SAAS,GAAG,GAAG,EAAE,CAAC,IAAI,CAAC,gBAAgB,EAAE,CAAC;QAE/C,+CAA+C;QAC/C,MAAM,KAAK,GAAG,UAAU,CACtB,GAAG,EAAE,CAAC,IAAI,CAAC,oBAAoB,EAAE,EACjC,IAAI,CAAC,OAAO,CAAC,OAAO,IAAI,2BAAe,CACxC,CAAC;QAEF,8EAA8E;QAC9E,IAAI,KAAK,CAAC,KAAK,IAAI,OAAO,KAAK,CAAC,KAAK,KAAK,UAAU,EAAE;YACpD,KAAK,CAAC,KAAK,EAAE,CAAC;SACf;QAED,yGAAyG;QACzG,IAAI,cAAc,EAAE;YAClB,IAAI,CAAC,MAAM,GAAG,cAAc,CAAC;SAC9B;aAAM;YACL,IAAI,CAAC,MAAM,GAAG,IAAI,GAAG,CAAC,MAAM,EAAE,CAAC;SAChC;QAED,gCAAgC;QAChC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;QACxC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;QACxC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,SAAS,CAAC,CAAC;QAC5C,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;QAE5C,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,UAAU,CAAC,CAAC;QAC3C,IAAI,CAAC,aAAa,GAAG,IAAI,6BAAa,EAAE,CAAC;QAEzC,IAAI,cAAc,EAAE;YAClB,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;SAC7B;aAAM;YACJ,IAAI,CAAC,MAAqB,CAAC,OAAO,CAAC,IAAI,CAAC,gBAAgB,EAAE,CAAC,CAAC;YAE7D,IACE,IAAI,CAAC,OAAO,CAAC,eAAe,KAAK,SAAS;gBAC1C,IAAI,CAAC,OAAO,CAAC,eAAe,KAAK,IAAI,EACrC;gBACC,IAAI,CAAC,MAAqB,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,eAAe,CAAC,CAAC;aACxE;SACF;QAED,6FAA6F;QAC7F,IAAI,CAAC,mBAAmB,CAAC,aAAa,EAAE,CAAC,IAAI,EAAE,EAAE;YAC/C,YAAY,CAAC,GAAG,EAAE;gBAChB,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,CAAC,EAAE;oBACjC,MAAM,UAAU,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;oBAErE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC;iBACtC;gBACD,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,CAAC;YACvB,CAAC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACL,CAAC;IAED,+EAA+E;IACvE,gBAAgB;QACtB,uCACK,IAAI,CAAC,OAAO,CAAC,cAAc,KAC9B,IAAI,EAAE,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,SAAS,EAC7D,IAAI,EAAE,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,IAC7B;IACJ,CAAC;IAED;;;OAGG;IACK,oBAAoB;QAC1B,IACE,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,WAAW;YAC3C,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,yBAAyB,EACzD;YACA,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,uBAAuB,CAAC,CAAC;SAClD;IACH,CAAC;IAED;;OAEG;IACK,gBAAgB;QACtB,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,SAAS,CAAC,CAAC;QAE1C,0BAA0B;QAC1B,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,EAAE;YACjC,IAAI,CAAC,0BAA0B,EAAE,CAAC;SACnC;aAAM;YACL,IAAI,CAAC,0BAA0B,EAAE,CAAC;SACnC;QAED,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,oBAAoB,CAAC,CAAC;IACvD,CAAC;IAED;;;OAGG;IACK,qBAAqB,CAAC,IAAY;QACxC;;;UAGE;QACF,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;QAEhC,6BAA6B;QAC7B,IAAI,CAAC,WAAW,EAAE,CAAC;IACrB,CAAC;IAED;;OAEG;IACK,WAAW;QACjB,mFAAmF;QACnF,OACE,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,WAAW;YAC3C,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,KAAK;YACrC,IAAI,CAAC,aAAa,CAAC,MAAM,IAAI,IAAI,CAAC,4BAA4B,EAC9D;YACA,gDAAgD;YAChD,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,oBAAoB,EAAE;gBACxD,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,EAAE;oBACjC,4CAA4C;oBAC5C,IAAI,CAAC,kCAAkC,EAAE,CAAC;iBAC3C;qBAAM;oBACL,wDAAwD;oBACxD,IAAI,CAAC,oCAAoC,EAAE,CAAC;iBAC7C;gBACD,wDAAwD;aACzD;iBAAM,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,kBAAkB,EAAE;gBAC7D,IAAI,CAAC,kDAAkD,EAAE,CAAC;gBAC1D,6DAA6D;aAC9D;iBAAM,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,kBAAkB,EAAE;gBAC7D,IAAI,CAAC,kCAAkC,EAAE,CAAC;gBAC1C,mEAAmE;aACpE;iBAAM,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,yBAAyB,EAAE;gBACpE,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,EAAE;oBACjC,IAAI,CAAC,sCAAsC,EAAE,CAAC;iBAC/C;qBAAM;oBACL,IAAI,CAAC,sCAAsC,EAAE,CAAC;iBAC/C;aACF;iBAAM;gBACL,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,aAAa,CAAC,CAAC;gBACvC,MAAM;aACP;SACF;IACH,CAAC;IAED;;;OAGG;IACK,cAAc;QACpB,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,YAAY,CAAC,CAAC;IACxC,CAAC;IAED;;;OAGG;IACK,cAAc,CAAC,GAAU;QAC/B,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;IAChC,CAAC;IAED;;OAEG;IACK,4BAA4B;QAClC,6FAA6F;QAC7F,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC;QACpB,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC,MAAM,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;QACxD,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;QAClD,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;QAClD,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC,SAAS,EAAE,IAAI,CAAC,SAAS,CAAC,CAAC;IACxD,CAAC;IAED;;;OAGG;IACK,WAAW,CAAC,GAAW;QAC7B,2FAA2F;QAC3F,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,KAAK,EAAE;YACzC,+BAA+B;YAC/B,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,KAAK,CAAC,CAAC;YAEtC,iBAAiB;YACjB,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE,CAAC;YAEtB,4BAA4B;YAC5B,IAAI,CAAC,4BAA4B,EAAE,CAAC;YAEpC,sBAAsB;YACtB,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,uBAAgB,CAAC,GAAG,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;SAC7D;IACH,CAAC;IAED;;OAEG;IACK,0BAA0B;QAChC,MAAM,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,MAAM,IAAI,EAAE,CAAC;QAE/C,MAAM,IAAI,GAAG,IAAI,0BAAW,EAAE,CAAC;QAC/B,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QACtB,IAAI,CAAC,UAAU,CAAC,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC;QACpD,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;QAElD,iBAAiB;QACjB,IAAI,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,EAAE;YAC7C,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC;YAC7D,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;YAC3B,sBAAsB;SACvB;aAAM;YACL,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;YACtB,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;YACtB,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;YACtB,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;YACtB,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;YAC3B,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;SACnD;QAED,IAAI,CAAC,4BAA4B;YAC/B,uCAA2B,CAAC,cAAc,CAAC;QAC7C,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;IACrC,CAAC;IAED;;;OAGG;IACK,kCAAkC;QACxC,MAAM,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QAEvC,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,0BAAc,CAAC,OAAO,EAAE;YACtC,IAAI,CAAC,WAAW,CACd,GAAG,kBAAM,CAAC,6BAA6B,OACrC,0BAAc,CAAC,IAAI,CAAC,CAAC,CAAC,CACxB,GAAG,CACJ,CAAC;SACH;aAAM;YACL,gBAAgB;YAChB,IAAI,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,wBAAY,CAAC,IAAI,EAAE;gBAC5D,MAAM,IAAI,GAAG,0BAAW,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;gBAC1C,IAAI,CAAC,UAAU,GAAG,CAAC,CAAC;gBAEpB,MAAM,UAAU,GAAoB;oBAClC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;oBACzB,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE,CAAC;iBACvC,CAAC;gBAEF,yCAAyC;gBACzC,IAAI,UAAU,CAAC,IAAI,KAAK,SAAS,EAAE;oBACjC,UAAU,CAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC;iBAChD;gBACD,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,yBAAyB,CAAC,CAAC;gBAC1D,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,EAAC,UAAU,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;gBAEtD,mBAAmB;aACpB;iBAAM;gBACL,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,WAAW,CAAC,CAAC;gBAC5C,IAAI,CAAC,4BAA4B,EAAE,CAAC;gBACpC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,EAAC,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;aACjD;SACF;IACH,CAAC;IAED;;;OAGG;IACK,sCAAsC;QAC5C,MAAM,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QAEvC,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,0BAAc,CAAC,OAAO,EAAE;YACtC,IAAI,CAAC,WAAW,CACd,GAAG,kBAAM,CAAC,0CAA0C,OAClD,0BAAc,CAAC,IAAI,CAAC,CAAC,CAAC,CACxB,GAAG,CACJ,CAAC;SACH;aAAM;YACL,MAAM,IAAI,GAAG,0BAAW,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;YAC1C,IAAI,CAAC,UAAU,GAAG,CAAC,CAAC;YAEpB,MAAM,UAAU,GAAoB;gBAClC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;gBACzB,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE,CAAC;aACvC,CAAC;YAEF,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,WAAW,CAAC,CAAC;YAC5C,IAAI,CAAC,4BAA4B,EAAE,CAAC;YACpC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,EAAC,UAAU,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;SAC7D;IACH,CAAC;IAED;;OAEG;IACK,0BAA0B;QAChC,MAAM,IAAI,GAAG,IAAI,0BAAW,EAAE,CAAC;QAE/B,wCAAwC;QACxC,MAAM,oBAAoB,GAAG,CAAC,sBAAU,CAAC,MAAM,CAAC,CAAC;QAEjD,6FAA6F;QAC7F,sHAAsH;QACtH,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,MAAM,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,QAAQ,EAAE;YAC5D,oBAAoB,CAAC,IAAI,CAAC,sBAAU,CAAC,QAAQ,CAAC,CAAC;SAChD;QAED,sBAAsB;QACtB,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,KAAK,SAAS,EAAE;YACvD,oBAAoB,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,CAAC,CAAC;SAClE;QAED,yBAAyB;QACzB,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QACtB,IAAI,CAAC,UAAU,CAAC,oBAAoB,CAAC,MAAM,CAAC,CAAC;QAC7C,KAAK,MAAM,UAAU,IAAI,oBAAoB,EAAE;YAC7C,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC;SAC7B;QAED,IAAI,CAAC,4BAA4B;YAC/B,uCAA2B,CAAC,8BAA8B,CAAC;QAC7D,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;QACnC,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,oBAAoB,CAAC,CAAC;IACvD,CAAC;IAED;;;OAGG;IACK,oCAAoC;QAC1C,MAAM,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QAEvC,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,EAAE;YACpB,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,yCAAyC,CAAC,CAAC;SACpE;aAAM,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,qCAAyB,EAAE;YAChD,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,+CAA+C,CAAC,CAAC;SAC1E;aAAM;YACL,6EAA6E;YAC7E,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,sBAAU,CAAC,MAAM,EAAE;gBACjC,IAAI,CAAC,oBAAoB,GAAG,sBAAU,CAAC,MAAM,CAAC;gBAC9C,IAAI,CAAC,wBAAwB,EAAE,CAAC;gBAChC,0EAA0E;aAC3E;iBAAM,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,sBAAU,CAAC,QAAQ,EAAE;gBAC1C,IAAI,CAAC,oBAAoB,GAAG,sBAAU,CAAC,QAAQ,CAAC;gBAChD,IAAI,CAAC,gCAAgC,EAAE,CAAC;gBACxC,qFAAqF;aACtF;iBAAM,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,EAAE;gBAC5D,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,CAAC;gBAClE,IAAI,CAAC,8BAA8B,EAAE,CAAC;aACvC;iBAAM;gBACL,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,4CAA4C,CAAC,CAAC;aACvE;SACF;IACH,CAAC;IAED;;;;OAIG;IACK,gCAAgC;QACtC,MAAM,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,MAAM,IAAI,EAAE,CAAC;QAC/C,MAAM,QAAQ,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,QAAQ,IAAI,EAAE,CAAC;QAEnD,MAAM,IAAI,GAAG,IAAI,0BAAW,EAAE,CAAC;QAC/B,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QACtB,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC;QAC3C,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC;QACzB,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC,CAAC;QAC7C,IAAI,CAAC,WAAW,CAAC,QAAQ,CAAC,CAAC;QAE3B,IAAI,CAAC,4BAA4B;YAC/B,uCAA2B,CAAC,oCAAoC,CAAC;QACnE,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;QACnC,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,kBAAkB,CAAC,CAAC;IACrD,CAAC;IAEa,8BAA8B;;YAC1C,IAAI,CAAC,4BAA4B,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,yBAAyB,CAAC;YACjF,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,2BAA2B,EAAE,CAAC,CAAC;YAC1E,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,kBAAkB,CAAC,CAAC;QACrD,CAAC;KAAA;IAEa,uCAAuC,CAAC,IAAY;;YAChE,OAAO,MAAM,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,4BAA4B,CAAC,IAAI,CAAC,CAAC;QACrE,CAAC;KAAA;IAEa,iDAAiD,CAC7D,IAAY;;YAEZ,OAAO,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC;QAC1B,CAAC;KAAA;IAEa,mDAAmD,CAC/D,IAAY;;YAEZ,OAAO,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC;QAC1B,CAAC;KAAA;IAED;;;OAGG;IACW,kDAAkD;;YAC9D,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,8BAA8B,CAAC,CAAC;YAE/D,IAAI,UAAU,GAAY,KAAK,CAAC;YAEhC,IAAI,IAAI,CAAC,oBAAoB,KAAK,sBAAU,CAAC,MAAM,EAAE;gBACnD,UAAU,GAAG,MAAM,IAAI,CAAC,iDAAiD,CACvE,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAC1B,CAAC;aACH;iBAAM,IAAI,IAAI,CAAC,oBAAoB,KAAK,sBAAU,CAAC,QAAQ,EAAE;gBAC5D,UAAU,GAAG,MAAM,IAAI,CAAC,mDAAmD,CACzE,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAC1B,CAAC;aACH;iBAAM,IACL,IAAI,CAAC,oBAAoB,KAAK,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,EACnE;gBACA,UAAU,GAAG,MAAM,IAAI,CAAC,uCAAuC,CAC7D,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,yBAAyB,CAAC,CACrE,CAAC;aACH;YAED,IAAI,CAAC,UAAU,EAAE;gBACf,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,0BAA0B,CAAC,CAAC;aACrD;iBAAM;gBACL,IAAI,CAAC,wBAAwB,EAAE,CAAC;aACjC;QACH,CAAC;KAAA;IAED;;OAEG;IACK,wBAAwB;QAC9B,MAAM,IAAI,GAAG,IAAI,0BAAW,EAAE,CAAC;QAE/B,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QACtB,IAAI,CAAC,UAAU,CAAC,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC;QACpD,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QAEtB,sBAAsB;QACtB,IAAI,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,EAAE;YAC7C,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,IAAI,CAAC,CAAC;YACrC,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC;SAC9D;aAAM,IAAI,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,EAAE;YACpD,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,IAAI,CAAC,CAAC;YACrC,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC;SAC9D;aAAM;YACL,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,QAAQ,CAAC,CAAC;YACzC,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;YACtD,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;SACjD;QACD,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;QAElD,IAAI,CAAC,4BAA4B;YAC/B,uCAA2B,CAAC,oBAAoB,CAAC;QACnD,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;QACnC,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,kBAAkB,CAAC,CAAC;IACrD,CAAC;IAED;;;OAGG;IACK,kCAAkC;QACxC,+EAA+E;QAC/E,MAAM,MAAM,GAAG,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QAE1C,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,IAAI,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,0BAAc,CAAC,OAAO,EAAE;YAC9D,IAAI,CAAC,WAAW,CACd,GAAG,kBAAM,CAAC,mCAAmC,MAC3C,0BAAc,CAAC,MAAM,CAAC,CAAC,CAAC,CAC1B,EAAE,CACH,CAAC;SACH;aAAM;YACL,oBAAoB;YACpB,MAAM,WAAW,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;YAE9B,IAAI,UAA2B,CAAC;YAChC,IAAI,IAAiB,CAAC;YAEtB,OAAO;YACP,IAAI,WAAW,KAAK,0BAAc,CAAC,IAAI,EAAE;gBACvC,8BAA8B;gBAC9B,MAAM,UAAU,GAAG,uCAA2B,CAAC,kBAAkB,CAAC;gBAClE,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE,CAAC;oBACtC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;gBAEF,4DAA4D;gBAC5D,IAAI,UAAU,CAAC,IAAI,KAAK,SAAS,EAAE;oBACjC,UAAU,CAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC;iBAChD;gBAED,WAAW;aACZ;iBAAM,IAAI,WAAW,KAAK,0BAAc,CAAC,QAAQ,EAAE;gBAClD,MAAM,UAAU,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;gBAC7B,MAAM,UAAU,GAAG,uCAA2B,CAAC,sBAAsB,CACnE,UAAU,CACX,CAAC,CAAC,qCAAqC;gBAExC,8BAA8B;gBAC9B,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC;oBACjC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;gBACF,OAAO;aACR;iBAAM,IAAI,WAAW,KAAK,0BAAc,CAAC,IAAI,EAAE;gBAC9C,8BAA8B;gBAC9B,MAAM,UAAU,GAAG,uCAA2B,CAAC,kBAAkB,CAAC;gBAClE,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;oBACtC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;aACH;YAED,6BAA6B;YAC7B,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,qBAAqB,CAAC,CAAC;YAEtD,gEAAgE;YAChE,IAAI,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,wBAAY,CAAC,OAAO,EAAE;gBAC/D,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,WAAW,CAAC,CAAC;gBAC5C,IAAI,CAAC,4BAA4B,EAAE,CAAC;gBACpC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,EAAC,UAAU,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;aAC7D;iBAAM,IAAI,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,wBAAY,CAAC,IAAI,EAAE;gBACnE;mHACmG;gBACnG,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,yBAAyB,CAAC,CAAC;gBAC1D,IAAI,CAAC,4BAA4B;oBAC/B,uCAA2B,CAAC,oBAAoB,CAAC;gBACnD,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,EAAC,UAAU,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;gBACtD;;;kBAGE;aACH;iBAAM,IACL,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,wBAAY,CAAC,SAAS,EAC7D;gBACA,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,WAAW,CAAC,CAAC;gBAC5C,IAAI,CAAC,4BAA4B,EAAE,CAAC;gBACpC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE;oBACvB,UAAU;oBACV,MAAM,EAAE,IAAI,CAAC,MAAM;iBACpB,CAAC,CAAC;aACJ;SACF;IACH,CAAC;IAED;;OAEG;IACK,sCAAsC;QAC5C,+EAA+E;QAC/E,MAAM,MAAM,GAAG,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QAE1C,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,IAAI,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,0BAAc,CAAC,OAAO,EAAE;YAC9D,IAAI,CAAC,WAAW,CACd,GAAG,kBAAM,CAAC,0CAA0C,MAClD,0BAAc,CAAC,MAAM,CAAC,CAAC,CAAC,CAC1B,EAAE,CACH,CAAC;SACH;aAAM;YACL,oBAAoB;YACpB,MAAM,WAAW,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;YAE9B,IAAI,UAA2B,CAAC;YAChC,IAAI,IAAiB,CAAC;YAEtB,OAAO;YACP,IAAI,WAAW,KAAK,0BAAc,CAAC,IAAI,EAAE;gBACvC,8BAA8B;gBAC9B,MAAM,UAAU,GAAG,uCAA2B,CAAC,kBAAkB,CAAC;gBAClE,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE,CAAC;oBACtC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;gBAEF,4DAA4D;gBAC5D,IAAI,UAAU,CAAC,IAAI,KAAK,SAAS,EAAE;oBACjC,UAAU,CAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC;iBAChD;gBAED,WAAW;aACZ;iBAAM,IAAI,WAAW,KAAK,0BAAc,CAAC,QAAQ,EAAE;gBAClD,MAAM,UAAU,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;gBAC7B,MAAM,UAAU,GAAG,uCAA2B,CAAC,sBAAsB,CACnE,UAAU,CACX,CAAC,CAAC,8BAA8B;gBAEjC,8BAA8B;gBAC9B,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC;oBACjC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;gBACF,OAAO;aACR;iBAAM,IAAI,WAAW,KAAK,0BAAc,CAAC,IAAI,EAAE;gBAC9C,8BAA8B;gBAC9B,MAAM,UAAU,GAAG,uCAA2B,CAAC,kBAAkB,CAAC;gBAClE,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;oBACtC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;aACH;YAED,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,WAAW,CAAC,CAAC;YAC5C,IAAI,CAAC,4BAA4B,EAAE,CAAC;YACpC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,EAAC,UAAU,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;SAC7D;IACH,CAAC;IAED,IAAI,kBAAkB;QACpB,yBACK,IAAI,CAAC,OAAO,EACf;IACJ,CAAC;CACF;AAGC,kCAAW"} \ No newline at end of file +{"version":3,"file":"socksclient.js","sourceRoot":"","sources":["../../src/client/socksclient.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,mCAAoC;AACpC,2BAA2B;AAC3B,yBAAyB;AACzB,+CAAyC;AACzC,mDAkB6B;AAC7B,+CAG2B;AAC3B,2DAAsD;AACtD,yCAA8D;AA07B5D,iGA17BM,uBAAgB,OA07BN;AAh6BlB,MAAM,WAAY,SAAQ,qBAAY;IAgBpC,YAAY,OAA2B;QACrC,KAAK,EAAE,CAAC;QACR,IAAI,CAAC,OAAO,qBACP,OAAO,CACX,CAAC;QAEF,8BAA8B;QAC9B,IAAA,oCAA0B,EAAC,OAAO,CAAC,CAAC;QAEpC,gBAAgB;QAChB,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,OAAO,CAAC,CAAC;IAC1C,CAAC;IAED;;;;;;;OAOG;IACH,MAAM,CAAC,gBAAgB,CACrB,OAA2B,EAC3B,QAGS;QAET,OAAO,IAAI,OAAO,CAA8B,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;YAClE,8BAA8B;YAC9B,IAAI;gBACF,IAAA,oCAA0B,EAAC,OAAO,EAAE,CAAC,SAAS,CAAC,CAAC,CAAC;aAClD;YAAC,OAAO,GAAG,EAAE;gBACZ,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,GAAG,CAAC,CAAC;oBACd,8DAA8D;oBAC9D,OAAO,OAAO,CAAC,GAAU,CAAC,CAAC,CAAC,oDAAoD;iBACjF;qBAAM;oBACL,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;iBACpB;aACF;YAED,MAAM,MAAM,GAAG,IAAI,WAAW,CAAC,OAAO,CAAC,CAAC;YACxC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,eAAe,CAAC,CAAC;YACxC,MAAM,CAAC,IAAI,CAAC,aAAa,EAAE,CAAC,IAAiC,EAAE,EAAE;gBAC/D,MAAM,CAAC,kBAAkB,EAAE,CAAC;gBAC5B,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;oBACrB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,oDAAoD;iBACpE;qBAAM;oBACL,OAAO,CAAC,IAAI,CAAC,CAAC;iBACf;YACH,CAAC,CAAC,CAAC;YAEH,kDAAkD;YAClD,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,GAAU,EAAE,EAAE;gBAClC,MAAM,CAAC,kBAAkB,EAAE,CAAC;gBAC5B,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,GAAG,CAAC,CAAC;oBACd,8DAA8D;oBAC9D,OAAO,CAAC,GAAU,CAAC,CAAC,CAAC,oDAAoD;iBAC1E;qBAAM;oBACL,MAAM,CAAC,GAAG,CAAC,CAAC;iBACb;YACH,CAAC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;OAQG;IACH,MAAM,CAAC,qBAAqB,CAC1B,OAAgC,EAChC,QAGS;QAET,qDAAqD;QACrD,OAAO,IAAI,OAAO,CAA8B,CAAO,OAAO,EAAE,MAAM,EAAE,EAAE;YACxE,mCAAmC;YACnC,IAAI;gBACF,IAAA,yCAA+B,EAAC,OAAO,CAAC,CAAC;aAC1C;YAAC,OAAO,GAAG,EAAE;gBACZ,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,GAAG,CAAC,CAAC;oBACd,8DAA8D;oBAC9D,OAAO,OAAO,CAAC,GAAU,CAAC,CAAC,CAAC,oDAAoD;iBACjF;qBAAM;oBACL,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;iBACpB;aACF;YAED,IAAI,IAAgB,CAAC;YAErB,kBAAkB;YAClB,IAAI,OAAO,CAAC,cAAc,EAAE;gBAC1B,IAAA,mBAAY,EAAC,OAAO,CAAC,OAAO,CAAC,CAAC;aAC/B;YAED,IAAI;gBACF,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE;oBAC/C,MAAM,SAAS,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;oBAErC,0HAA0H;oBAC1H,MAAM,eAAe,GACnB,CAAC,KAAK,OAAO,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC;wBAC9B,CAAC,CAAC,OAAO,CAAC,WAAW;wBACrB,CAAC,CAAC;4BACE,IAAI,EACF,OAAO,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI;gCAC3B,OAAO,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,SAAS;4BAClC,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI;yBAClC,CAAC;oBAER,4CAA4C;oBAC5C,MAAM,MAAM,GAAG,MAAM,WAAW,CAAC,gBAAgB,CAAC;wBAChD,OAAO,EAAE,SAAS;wBAClB,KAAK,EAAE,SAAS;wBAChB,WAAW,EAAE,eAAe;wBAC5B,8HAA8H;qBAC/H,CAAC,CAAC;oBAEH,wCAAwC;oBACxC,IAAI,CAAC,IAAI,EAAE;wBACT,IAAI,GAAG,MAAM,CAAC,MAAM,CAAC;qBACtB;iBACF;gBAED,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,IAAI,EAAE,EAAC,MAAM,EAAE,IAAI,EAAC,CAAC,CAAC;oBAC/B,OAAO,CAAC,EAAC,MAAM,EAAE,IAAI,EAAC,CAAC,CAAC,CAAC,oDAAoD;iBAC9E;qBAAM;oBACL,OAAO,CAAC,EAAC,MAAM,EAAE,IAAI,EAAC,CAAC,CAAC;iBACzB;aACF;YAAC,OAAO,GAAG,EAAE;gBACZ,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;oBAClC,QAAQ,CAAC,GAAG,CAAC,CAAC;oBACd,8DAA8D;oBAC9D,OAAO,CAAC,GAAU,CAAC,CAAC,CAAC,oDAAoD;iBAC1E;qBAAM;oBACL,MAAM,CAAC,GAAG,CAAC,CAAC;iBACb;aACF;QACH,CAAC,CAAA,CAAC,CAAC;IACL,CAAC;IAED;;;OAGG;IACH,MAAM,CAAC,cAAc,CAAC,OAA6B;QACjD,MAAM,IAAI,GAAG,IAAI,0BAAW,EAAE,CAAC;QAC/B,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC;QACtB,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,WAAW,IAAI,CAAC,CAAC,CAAC;QAE1C,qBAAqB;QACrB,IAAI,GAAG,CAAC,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,EAAE;YACvC,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,IAAI,CAAC,CAAC;YACrC,IAAI,CAAC,aAAa,CAAC,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC;SACxD;aAAM,IAAI,GAAG,CAAC,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,EAAE;YAC9C,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,IAAI,CAAC,CAAC;YACrC,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC,QAAQ,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC;SACxD;aAAM;YACL,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,QAAQ,CAAC,CAAC;YACzC,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC;YAC5D,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;SAC3C;QAED,OAAO;QACP,IAAI,CAAC,aAAa,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QAE5C,OAAO;QACP,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;QAE/B,OAAO,IAAI,CAAC,QAAQ,EAAE,CAAC;IACzB,CAAC;IAED;;;OAGG;IACH,MAAM,CAAC,aAAa,CAAC,IAAY;QAC/B,MAAM,IAAI,GAAG,0BAAW,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QAC1C,IAAI,CAAC,UAAU,GAAG,CAAC,CAAC;QAEpB,MAAM,WAAW,GAAG,IAAI,CAAC,SAAS,EAAE,CAAC;QACrC,MAAM,QAAQ,GAAmB,IAAI,CAAC,SAAS,EAAE,CAAC;QAClD,IAAI,UAAU,CAAC;QAEf,IAAI,QAAQ,KAAK,0BAAc,CAAC,IAAI,EAAE;YACpC,UAAU,GAAG,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE,CAAC,CAAC;SAC/C;aAAM,IAAI,QAAQ,KAAK,0BAAc,CAAC,IAAI,EAAE;YAC3C,UAAU,GAAG,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC,CAAC;SAC/C;aAAM;YACL,UAAU,GAAG,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,SAAS,EAAE,CAAC,CAAC;SAChD;QAED,MAAM,UAAU,GAAG,IAAI,CAAC,YAAY,EAAE,CAAC;QAEvC,OAAO;YACL,WAAW;YACX,UAAU,EAAE;gBACV,IAAI,EAAE,UAAU;gBAChB,IAAI,EAAE,UAAU;aACjB;YACD,IAAI,EAAE,IAAI,CAAC,UAAU,EAAE;SACxB,CAAC;IACJ,CAAC;IAED;;OAEG;IACK,QAAQ,CAAC,QAA0B;QACzC,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,KAAK,EAAE;YACzC,IAAI,CAAC,KAAK,GAAG,QAAQ,CAAC;SACvB;IACH,CAAC;IAED;;;OAGG;IACI,OAAO,CAAC,cAAuB;QACpC,IAAI,CAAC,cAAc,GAAG,CAAC,IAAY,EAAE,EAAE,CAAC,IAAI,CAAC,qBAAqB,CAAC,IAAI,CAAC,CAAC;QACzE,IAAI,CAAC,OAAO,GAAG,GAAG,EAAE,CAAC,IAAI,CAAC,cAAc,EAAE,CAAC;QAC3C,IAAI,CAAC,OAAO,GAAG,CAAC,GAAU,EAAE,EAAE,CAAC,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC;QACxD,IAAI,CAAC,SAAS,GAAG,GAAG,EAAE,CAAC,IAAI,CAAC,gBAAgB,EAAE,CAAC;QAE/C,+CAA+C;QAC/C,MAAM,KAAK,GAAG,UAAU,CACtB,GAAG,EAAE,CAAC,IAAI,CAAC,oBAAoB,EAAE,EACjC,IAAI,CAAC,OAAO,CAAC,OAAO,IAAI,2BAAe,CACxC,CAAC;QAEF,8EAA8E;QAC9E,IAAI,KAAK,CAAC,KAAK,IAAI,OAAO,KAAK,CAAC,KAAK,KAAK,UAAU,EAAE;YACpD,KAAK,CAAC,KAAK,EAAE,CAAC;SACf;QAED,yGAAyG;QACzG,IAAI,cAAc,EAAE;YAClB,IAAI,CAAC,MAAM,GAAG,cAAc,CAAC;SAC9B;aAAM;YACL,IAAI,CAAC,MAAM,GAAG,IAAI,GAAG,CAAC,MAAM,EAAE,CAAC;SAChC;QAED,gCAAgC;QAChC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;QACxC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;QACxC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,SAAS,CAAC,CAAC;QAC5C,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;QAE5C,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,UAAU,CAAC,CAAC;QAC3C,IAAI,CAAC,aAAa,GAAG,IAAI,6BAAa,EAAE,CAAC;QAEzC,IAAI,cAAc,EAAE;YAClB,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;SAC7B;aAAM;YACJ,IAAI,CAAC,MAAqB,CAAC,OAAO,CAAC,IAAI,CAAC,gBAAgB,EAAE,CAAC,CAAC;YAE7D,IACE,IAAI,CAAC,OAAO,CAAC,eAAe,KAAK,SAAS;gBAC1C,IAAI,CAAC,OAAO,CAAC,eAAe,KAAK,IAAI,EACrC;gBACC,IAAI,CAAC,MAAqB,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,eAAe,CAAC,CAAC;aACxE;SACF;QAED,6FAA6F;QAC7F,IAAI,CAAC,mBAAmB,CAAC,aAAa,EAAE,CAAC,IAAI,EAAE,EAAE;YAC/C,YAAY,CAAC,GAAG,EAAE;gBAChB,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,CAAC,EAAE;oBACjC,MAAM,UAAU,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;oBAErE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC;iBACtC;gBACD,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,CAAC;YACvB,CAAC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACL,CAAC;IAED,+EAA+E;IACvE,gBAAgB;QACtB,uCACK,IAAI,CAAC,OAAO,CAAC,cAAc,KAC9B,IAAI,EAAE,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,SAAS,EAC7D,IAAI,EAAE,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,IAC7B;IACJ,CAAC;IAED;;;OAGG;IACK,oBAAoB;QAC1B,IACE,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,WAAW;YAC3C,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,yBAAyB,EACzD;YACA,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,uBAAuB,CAAC,CAAC;SAClD;IACH,CAAC;IAED;;OAEG;IACK,gBAAgB;QACtB,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,SAAS,CAAC,CAAC;QAE1C,0BAA0B;QAC1B,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,EAAE;YACjC,IAAI,CAAC,0BAA0B,EAAE,CAAC;SACnC;aAAM;YACL,IAAI,CAAC,0BAA0B,EAAE,CAAC;SACnC;QAED,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,oBAAoB,CAAC,CAAC;IACvD,CAAC;IAED;;;OAGG;IACK,qBAAqB,CAAC,IAAY;QACxC;;;UAGE;QACF,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;QAEhC,6BAA6B;QAC7B,IAAI,CAAC,WAAW,EAAE,CAAC;IACrB,CAAC;IAED;;OAEG;IACK,WAAW;QACjB,mFAAmF;QACnF,OACE,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,WAAW;YAC3C,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,KAAK;YACrC,IAAI,CAAC,aAAa,CAAC,MAAM,IAAI,IAAI,CAAC,4BAA4B,EAC9D;YACA,gDAAgD;YAChD,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,oBAAoB,EAAE;gBACxD,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,EAAE;oBACjC,4CAA4C;oBAC5C,IAAI,CAAC,kCAAkC,EAAE,CAAC;iBAC3C;qBAAM;oBACL,wDAAwD;oBACxD,IAAI,CAAC,oCAAoC,EAAE,CAAC;iBAC7C;gBACD,wDAAwD;aACzD;iBAAM,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,kBAAkB,EAAE;gBAC7D,IAAI,CAAC,kDAAkD,EAAE,CAAC;gBAC1D,6DAA6D;aAC9D;iBAAM,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,kBAAkB,EAAE;gBAC7D,IAAI,CAAC,kCAAkC,EAAE,CAAC;gBAC1C,mEAAmE;aACpE;iBAAM,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,yBAAyB,EAAE;gBACpE,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,EAAE;oBACjC,IAAI,CAAC,sCAAsC,EAAE,CAAC;iBAC/C;qBAAM;oBACL,IAAI,CAAC,sCAAsC,EAAE,CAAC;iBAC/C;aACF;iBAAM;gBACL,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,aAAa,CAAC,CAAC;gBACvC,MAAM;aACP;SACF;IACH,CAAC;IAED;;;OAGG;IACK,cAAc;QACpB,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,YAAY,CAAC,CAAC;IACxC,CAAC;IAED;;;OAGG;IACK,cAAc,CAAC,GAAU;QAC/B,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;IAChC,CAAC;IAED;;OAEG;IACK,4BAA4B;QAClC,6FAA6F;QAC7F,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC;QACpB,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC,MAAM,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;QACxD,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;QAClD,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;QAClD,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC,SAAS,EAAE,IAAI,CAAC,SAAS,CAAC,CAAC;IACxD,CAAC;IAED;;;OAGG;IACK,WAAW,CAAC,GAAW;QAC7B,2FAA2F;QAC3F,IAAI,IAAI,CAAC,KAAK,KAAK,4BAAgB,CAAC,KAAK,EAAE;YACzC,+BAA+B;YAC/B,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,KAAK,CAAC,CAAC;YAEtC,iBAAiB;YACjB,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE,CAAC;YAEtB,4BAA4B;YAC5B,IAAI,CAAC,4BAA4B,EAAE,CAAC;YAEpC,sBAAsB;YACtB,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,uBAAgB,CAAC,GAAG,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;SAC7D;IACH,CAAC;IAED;;OAEG;IACK,0BAA0B;QAChC,MAAM,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,MAAM,IAAI,EAAE,CAAC;QAE/C,MAAM,IAAI,GAAG,IAAI,0BAAW,EAAE,CAAC;QAC/B,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QACtB,IAAI,CAAC,UAAU,CAAC,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC;QACpD,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;QAElD,iBAAiB;QACjB,IAAI,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,EAAE;YAC7C,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC;YAC7D,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;YAC3B,sBAAsB;SACvB;aAAM;YACL,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;YACtB,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;YACtB,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;YACtB,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;YACtB,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;YAC3B,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;SACnD;QAED,IAAI,CAAC,4BAA4B;YAC/B,uCAA2B,CAAC,cAAc,CAAC;QAC7C,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;IACrC,CAAC;IAED;;;OAGG;IACK,kCAAkC;QACxC,MAAM,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QAEvC,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,0BAAc,CAAC,OAAO,EAAE;YACtC,IAAI,CAAC,WAAW,CACd,GAAG,kBAAM,CAAC,6BAA6B,OACrC,0BAAc,CAAC,IAAI,CAAC,CAAC,CAAC,CACxB,GAAG,CACJ,CAAC;SACH;aAAM;YACL,gBAAgB;YAChB,IAAI,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,wBAAY,CAAC,IAAI,EAAE;gBAC5D,MAAM,IAAI,GAAG,0BAAW,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;gBAC1C,IAAI,CAAC,UAAU,GAAG,CAAC,CAAC;gBAEpB,MAAM,UAAU,GAAoB;oBAClC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;oBACzB,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE,CAAC;iBACvC,CAAC;gBAEF,yCAAyC;gBACzC,IAAI,UAAU,CAAC,IAAI,KAAK,SAAS,EAAE;oBACjC,UAAU,CAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC;iBAChD;gBACD,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,yBAAyB,CAAC,CAAC;gBAC1D,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,EAAC,UAAU,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;gBAEtD,mBAAmB;aACpB;iBAAM;gBACL,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,WAAW,CAAC,CAAC;gBAC5C,IAAI,CAAC,4BAA4B,EAAE,CAAC;gBACpC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,EAAC,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;aACjD;SACF;IACH,CAAC;IAED;;;OAGG;IACK,sCAAsC;QAC5C,MAAM,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QAEvC,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,0BAAc,CAAC,OAAO,EAAE;YACtC,IAAI,CAAC,WAAW,CACd,GAAG,kBAAM,CAAC,0CAA0C,OAClD,0BAAc,CAAC,IAAI,CAAC,CAAC,CAAC,CACxB,GAAG,CACJ,CAAC;SACH;aAAM;YACL,MAAM,IAAI,GAAG,0BAAW,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;YAC1C,IAAI,CAAC,UAAU,GAAG,CAAC,CAAC;YAEpB,MAAM,UAAU,GAAoB;gBAClC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;gBACzB,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE,CAAC;aACvC,CAAC;YAEF,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,WAAW,CAAC,CAAC;YAC5C,IAAI,CAAC,4BAA4B,EAAE,CAAC;YACpC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,EAAC,UAAU,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;SAC7D;IACH,CAAC;IAED;;OAEG;IACK,0BAA0B;QAChC,MAAM,IAAI,GAAG,IAAI,0BAAW,EAAE,CAAC;QAE/B,wCAAwC;QACxC,MAAM,oBAAoB,GAAG,CAAC,sBAAU,CAAC,MAAM,CAAC,CAAC;QAEjD,6FAA6F;QAC7F,sHAAsH;QACtH,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,MAAM,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,QAAQ,EAAE;YAC5D,oBAAoB,CAAC,IAAI,CAAC,sBAAU,CAAC,QAAQ,CAAC,CAAC;SAChD;QAED,sBAAsB;QACtB,IAAI,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,KAAK,SAAS,EAAE;YACvD,oBAAoB,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,CAAC,CAAC;SAClE;QAED,yBAAyB;QACzB,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QACtB,IAAI,CAAC,UAAU,CAAC,oBAAoB,CAAC,MAAM,CAAC,CAAC;QAC7C,KAAK,MAAM,UAAU,IAAI,oBAAoB,EAAE;YAC7C,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC;SAC7B;QAED,IAAI,CAAC,4BAA4B;YAC/B,uCAA2B,CAAC,8BAA8B,CAAC;QAC7D,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;QACnC,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,oBAAoB,CAAC,CAAC;IACvD,CAAC;IAED;;;OAGG;IACK,oCAAoC;QAC1C,MAAM,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QAEvC,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,EAAE;YACpB,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,yCAAyC,CAAC,CAAC;SACpE;aAAM,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,qCAAyB,EAAE;YAChD,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,+CAA+C,CAAC,CAAC;SAC1E;aAAM;YACL,6EAA6E;YAC7E,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,sBAAU,CAAC,MAAM,EAAE;gBACjC,IAAI,CAAC,oBAAoB,GAAG,sBAAU,CAAC,MAAM,CAAC;gBAC9C,IAAI,CAAC,wBAAwB,EAAE,CAAC;gBAChC,0EAA0E;aAC3E;iBAAM,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,sBAAU,CAAC,QAAQ,EAAE;gBAC1C,IAAI,CAAC,oBAAoB,GAAG,sBAAU,CAAC,QAAQ,CAAC;gBAChD,IAAI,CAAC,gCAAgC,EAAE,CAAC;gBACxC,qFAAqF;aACtF;iBAAM,IAAI,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,EAAE;gBAC5D,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,CAAC;gBAClE,IAAI,CAAC,8BAA8B,EAAE,CAAC;aACvC;iBAAM;gBACL,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,4CAA4C,CAAC,CAAC;aACvE;SACF;IACH,CAAC;IAED;;;;OAIG;IACK,gCAAgC;QACtC,MAAM,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,MAAM,IAAI,EAAE,CAAC;QAC/C,MAAM,QAAQ,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,QAAQ,IAAI,EAAE,CAAC;QAEnD,MAAM,IAAI,GAAG,IAAI,0BAAW,EAAE,CAAC;QAC/B,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QACtB,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC;QAC3C,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC;QACzB,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC,CAAC;QAC7C,IAAI,CAAC,WAAW,CAAC,QAAQ,CAAC,CAAC;QAE3B,IAAI,CAAC,4BAA4B;YAC/B,uCAA2B,CAAC,oCAAoC,CAAC;QACnE,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;QACnC,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,kBAAkB,CAAC,CAAC;IACrD,CAAC;IAEa,8BAA8B;;YAC1C,IAAI,CAAC,4BAA4B;gBAC/B,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,yBAAyB,CAAC;YAC/C,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,2BAA2B,EAAE,CAAC,CAAC;YAC1E,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,kBAAkB,CAAC,CAAC;QACrD,CAAC;KAAA;IAEa,uCAAuC,CAAC,IAAY;;YAChE,OAAO,MAAM,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,4BAA4B,CAAC,IAAI,CAAC,CAAC;QACrE,CAAC;KAAA;IAEa,iDAAiD,CAC7D,IAAY;;YAEZ,OAAO,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC;QAC1B,CAAC;KAAA;IAEa,mDAAmD,CAC/D,IAAY;;YAEZ,OAAO,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC;QAC1B,CAAC;KAAA;IAED;;;OAGG;IACW,kDAAkD;;YAC9D,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,8BAA8B,CAAC,CAAC;YAE/D,IAAI,UAAU,GAAG,KAAK,CAAC;YAEvB,IAAI,IAAI,CAAC,oBAAoB,KAAK,sBAAU,CAAC,MAAM,EAAE;gBACnD,UAAU,GAAG,MAAM,IAAI,CAAC,iDAAiD,CACvE,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAC1B,CAAC;aACH;iBAAM,IAAI,IAAI,CAAC,oBAAoB,KAAK,sBAAU,CAAC,QAAQ,EAAE;gBAC5D,UAAU;oBACR,MAAM,IAAI,CAAC,mDAAmD,CAC5D,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAC1B,CAAC;aACL;iBAAM,IACL,IAAI,CAAC,oBAAoB,KAAK,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,EACnE;gBACA,UAAU,GAAG,MAAM,IAAI,CAAC,uCAAuC,CAC7D,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,yBAAyB,CAAC,CACrE,CAAC;aACH;YAED,IAAI,CAAC,UAAU,EAAE;gBACf,IAAI,CAAC,WAAW,CAAC,kBAAM,CAAC,0BAA0B,CAAC,CAAC;aACrD;iBAAM;gBACL,IAAI,CAAC,wBAAwB,EAAE,CAAC;aACjC;QACH,CAAC;KAAA;IAED;;OAEG;IACK,wBAAwB;QAC9B,MAAM,IAAI,GAAG,IAAI,0BAAW,EAAE,CAAC;QAE/B,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QACtB,IAAI,CAAC,UAAU,CAAC,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC;QACpD,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QAEtB,sBAAsB;QACtB,IAAI,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,EAAE;YAC7C,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,IAAI,CAAC,CAAC;YACrC,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC;SAC9D;aAAM,IAAI,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,EAAE;YACpD,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,IAAI,CAAC,CAAC;YACrC,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC;SAC9D;aAAM;YACL,IAAI,CAAC,UAAU,CAAC,0BAAc,CAAC,QAAQ,CAAC,CAAC;YACzC,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;YACtD,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;SACjD;QACD,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;QAElD,IAAI,CAAC,4BAA4B;YAC/B,uCAA2B,CAAC,oBAAoB,CAAC;QACnD,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;QACnC,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,kBAAkB,CAAC,CAAC;IACrD,CAAC;IAED;;;OAGG;IACK,kCAAkC;QACxC,+EAA+E;QAC/E,MAAM,MAAM,GAAG,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QAE1C,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,IAAI,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,0BAAc,CAAC,OAAO,EAAE;YAC9D,IAAI,CAAC,WAAW,CACd,GAAG,kBAAM,CAAC,mCAAmC,MAC3C,0BAAc,CAAC,MAAM,CAAC,CAAC,CAAC,CAC1B,EAAE,CACH,CAAC;SACH;aAAM;YACL,oBAAoB;YACpB,MAAM,WAAW,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;YAE9B,IAAI,UAA2B,CAAC;YAChC,IAAI,IAAiB,CAAC;YAEtB,OAAO;YACP,IAAI,WAAW,KAAK,0BAAc,CAAC,IAAI,EAAE;gBACvC,8BAA8B;gBAC9B,MAAM,UAAU,GAAG,uCAA2B,CAAC,kBAAkB,CAAC;gBAClE,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE,CAAC;oBACtC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;gBAEF,4DAA4D;gBAC5D,IAAI,UAAU,CAAC,IAAI,KAAK,SAAS,EAAE;oBACjC,UAAU,CAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC;iBAChD;gBAED,WAAW;aACZ;iBAAM,IAAI,WAAW,KAAK,0BAAc,CAAC,QAAQ,EAAE;gBAClD,MAAM,UAAU,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;gBAC7B,MAAM,UAAU,GACd,uCAA2B,CAAC,sBAAsB,CAAC,UAAU,CAAC,CAAC,CAAC,qCAAqC;gBAEvG,8BAA8B;gBAC9B,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC;oBACjC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;gBACF,OAAO;aACR;iBAAM,IAAI,WAAW,KAAK,0BAAc,CAAC,IAAI,EAAE;gBAC9C,8BAA8B;gBAC9B,MAAM,UAAU,GAAG,uCAA2B,CAAC,kBAAkB,CAAC;gBAClE,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;oBACtC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;aACH;YAED,6BAA6B;YAC7B,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,qBAAqB,CAAC,CAAC;YAEtD,gEAAgE;YAChE,IAAI,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,wBAAY,CAAC,OAAO,EAAE;gBAC/D,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,WAAW,CAAC,CAAC;gBAC5C,IAAI,CAAC,4BAA4B,EAAE,CAAC;gBACpC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,EAAC,UAAU,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;aAC7D;iBAAM,IAAI,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,wBAAY,CAAC,IAAI,EAAE;gBACnE;mHACmG;gBACnG,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,yBAAyB,CAAC,CAAC;gBAC1D,IAAI,CAAC,4BAA4B;oBAC/B,uCAA2B,CAAC,oBAAoB,CAAC;gBACnD,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,EAAC,UAAU,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;gBACtD;;;kBAGE;aACH;iBAAM,IACL,wBAAY,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,wBAAY,CAAC,SAAS,EAC7D;gBACA,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,WAAW,CAAC,CAAC;gBAC5C,IAAI,CAAC,4BAA4B,EAAE,CAAC;gBACpC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE;oBACvB,UAAU;oBACV,MAAM,EAAE,IAAI,CAAC,MAAM;iBACpB,CAAC,CAAC;aACJ;SACF;IACH,CAAC;IAED;;OAEG;IACK,sCAAsC;QAC5C,+EAA+E;QAC/E,MAAM,MAAM,GAAG,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QAE1C,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,IAAI,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,0BAAc,CAAC,OAAO,EAAE;YAC9D,IAAI,CAAC,WAAW,CACd,GAAG,kBAAM,CAAC,0CAA0C,MAClD,0BAAc,CAAC,MAAM,CAAC,CAAC,CAAC,CAC1B,EAAE,CACH,CAAC;SACH;aAAM;YACL,oBAAoB;YACpB,MAAM,WAAW,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;YAE9B,IAAI,UAA2B,CAAC;YAChC,IAAI,IAAiB,CAAC;YAEtB,OAAO;YACP,IAAI,WAAW,KAAK,0BAAc,CAAC,IAAI,EAAE;gBACvC,8BAA8B;gBAC9B,MAAM,UAAU,GAAG,uCAA2B,CAAC,kBAAkB,CAAC;gBAClE,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE,CAAC;oBACtC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;gBAEF,4DAA4D;gBAC5D,IAAI,UAAU,CAAC,IAAI,KAAK,SAAS,EAAE;oBACjC,UAAU,CAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC;iBAChD;gBAED,WAAW;aACZ;iBAAM,IAAI,WAAW,KAAK,0BAAc,CAAC,QAAQ,EAAE;gBAClD,MAAM,UAAU,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;gBAC7B,MAAM,UAAU,GACd,uCAA2B,CAAC,sBAAsB,CAAC,UAAU,CAAC,CAAC,CAAC,8BAA8B;gBAEhG,8BAA8B;gBAC9B,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC;oBACjC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;gBACF,OAAO;aACR;iBAAM,IAAI,WAAW,KAAK,0BAAc,CAAC,IAAI,EAAE;gBAC9C,8BAA8B;gBAC9B,MAAM,UAAU,GAAG,uCAA2B,CAAC,kBAAkB,CAAC;gBAClE,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,UAAU,EAAE;oBAC1C,IAAI,CAAC,4BAA4B,GAAG,UAAU,CAAC;oBAC/C,OAAO;iBACR;gBAED,IAAI,GAAG,0BAAW,CAAC,UAAU,CAC3B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAC5C,CAAC;gBAEF,UAAU,GAAG;oBACX,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;oBACtC,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE;iBAC1B,CAAC;aACH;YAED,IAAI,CAAC,QAAQ,CAAC,4BAAgB,CAAC,WAAW,CAAC,CAAC;YAC5C,IAAI,CAAC,4BAA4B,EAAE,CAAC;YACpC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,EAAC,UAAU,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,EAAC,CAAC,CAAC;SAC7D;IACH,CAAC;IAED,IAAI,kBAAkB;QACpB,yBACK,IAAI,CAAC,OAAO,EACf;IACJ,CAAC;CACF;AAGC,kCAAW"} \ No newline at end of file diff --git a/node_modules/socks/build/common/receivebuffer.js.map b/node_modules/socks/build/common/receivebuffer.js.map index 144edb0..af5e220 100644 --- a/node_modules/socks/build/common/receivebuffer.js.map +++ b/node_modules/socks/build/common/receivebuffer.js.map @@ -1 +1 @@ -{"version":3,"file":"receivebuffer.js","sourceRoot":"","sources":["../../src/common/receivebuffer.ts"],"names":[],"mappings":";;;AAAA,MAAM,aAAa;IAKjB,YAAY,OAAe,IAAI;QAC7B,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;QACvC,IAAI,CAAC,MAAM,GAAG,CAAC,CAAC;QAChB,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC;IAC3B,CAAC;IAED,IAAI,MAAM;QACR,OAAO,IAAI,CAAC,MAAM,CAAC;IACrB,CAAC;IAED,MAAM,CAAC,IAAY;QACjB,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE;YAC1B,MAAM,IAAI,KAAK,CACb,6DAA6D,CAC9D,CAAC;SACH;QAED,IAAI,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,IAAI,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE;YACnD,MAAM,GAAG,GAAG,IAAI,CAAC,MAAM,CAAC;YACxB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC,WAAW,CAC9B,IAAI,CAAC,GAAG,CACN,IAAI,CAAC,MAAM,CAAC,MAAM,GAAG,IAAI,CAAC,YAAY,EACtC,IAAI,CAAC,MAAM,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,CACjC,CACF,CAAC;YACF,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;SACvB;QAED,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC;QACpC,OAAO,CAAC,IAAI,CAAC,MAAM,IAAI,IAAI,CAAC,MAAM,CAAC,CAAC;IACtC,CAAC;IAED,IAAI,CAAC,MAAc;QACjB,IAAI,MAAM,GAAG,IAAI,CAAC,MAAM,EAAE;YACxB,MAAM,IAAI,KAAK,CACb,mEAAmE,CACpE,CAAC;SACH;QACD,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;IACtC,CAAC;IAED,GAAG,CAAC,MAAc;QAChB,IAAI,MAAM,GAAG,IAAI,CAAC,MAAM,EAAE;YACxB,MAAM,IAAI,KAAK,CACb,mEAAmE,CACpE,CAAC;SACH;QAED,MAAM,KAAK,GAAG,MAAM,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC;QACzC,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QACzC,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC,CAAC;QACjE,IAAI,CAAC,MAAM,IAAI,MAAM,CAAC;QAEtB,OAAO,KAAK,CAAC;IACf,CAAC;CACF;AAEO,sCAAa"} \ No newline at end of file +{"version":3,"file":"receivebuffer.js","sourceRoot":"","sources":["../../src/common/receivebuffer.ts"],"names":[],"mappings":";;;AAAA,MAAM,aAAa;IAKjB,YAAY,IAAI,GAAG,IAAI;QACrB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;QACvC,IAAI,CAAC,MAAM,GAAG,CAAC,CAAC;QAChB,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC;IAC3B,CAAC;IAED,IAAI,MAAM;QACR,OAAO,IAAI,CAAC,MAAM,CAAC;IACrB,CAAC;IAED,MAAM,CAAC,IAAY;QACjB,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE;YAC1B,MAAM,IAAI,KAAK,CACb,6DAA6D,CAC9D,CAAC;SACH;QAED,IAAI,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,IAAI,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE;YACnD,MAAM,GAAG,GAAG,IAAI,CAAC,MAAM,CAAC;YACxB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC,WAAW,CAC9B,IAAI,CAAC,GAAG,CACN,IAAI,CAAC,MAAM,CAAC,MAAM,GAAG,IAAI,CAAC,YAAY,EACtC,IAAI,CAAC,MAAM,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,CACjC,CACF,CAAC;YACF,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;SACvB;QAED,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC;QACpC,OAAO,CAAC,IAAI,CAAC,MAAM,IAAI,IAAI,CAAC,MAAM,CAAC,CAAC;IACtC,CAAC;IAED,IAAI,CAAC,MAAc;QACjB,IAAI,MAAM,GAAG,IAAI,CAAC,MAAM,EAAE;YACxB,MAAM,IAAI,KAAK,CACb,mEAAmE,CACpE,CAAC;SACH;QACD,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;IACtC,CAAC;IAED,GAAG,CAAC,MAAc;QAChB,IAAI,MAAM,GAAG,IAAI,CAAC,MAAM,EAAE;YACxB,MAAM,IAAI,KAAK,CACb,mEAAmE,CACpE,CAAC;SACH;QAED,MAAM,KAAK,GAAG,MAAM,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC;QACzC,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QACzC,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC,CAAC;QACjE,IAAI,CAAC,MAAM,IAAI,MAAM,CAAC;QAEtB,OAAO,KAAK,CAAC;IACf,CAAC;CACF;AAEO,sCAAa"} \ No newline at end of file diff --git a/node_modules/socks/build/common/util.js b/node_modules/socks/build/common/util.js index 283314a..f66b72e 100644 --- a/node_modules/socks/build/common/util.js +++ b/node_modules/socks/build/common/util.js @@ -16,7 +16,6 @@ exports.SocksClientError = SocksClientError; * @param array The array to shuffle. */ function shuffleArray(array) { - // tslint:disable-next-line:no-increment-decrement for (let i = array.length - 1; i > 0; i--) { const j = Math.floor(Math.random() * (i + 1)); [array[i], array[j]] = [array[j], array[i]]; diff --git a/node_modules/socks/build/common/util.js.map b/node_modules/socks/build/common/util.js.map index 8d94a2a..f199323 100644 --- a/node_modules/socks/build/common/util.js.map +++ b/node_modules/socks/build/common/util.js.map @@ -1 +1 @@ -{"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/common/util.ts"],"names":[],"mappings":";;;AAEA;;GAEG;AACH,MAAM,gBAAiB,SAAQ,KAAK;IAClC,YACE,OAAe,EACR,OAAqD;QAE5D,KAAK,CAAC,OAAO,CAAC,CAAC;QAFR,YAAO,GAAP,OAAO,CAA8C;IAG9D,CAAC;CACF;AAwBuB,4CAAgB;AAtBxC;;;GAGG;AACH,SAAS,YAAY,CAAC,KAAY;IAChC,kDAAkD;IAClD,KAAK,IAAI,CAAC,GAAG,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,EAAE,EAAE;QACzC,MAAM,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QAC9C,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;KAC7C;AACH,CAAC;AAYyC,oCAAY"} \ No newline at end of file +{"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/common/util.ts"],"names":[],"mappings":";;;AAEA;;GAEG;AACH,MAAM,gBAAiB,SAAQ,KAAK;IAClC,YACE,OAAe,EACR,OAAqD;QAE5D,KAAK,CAAC,OAAO,CAAC,CAAC;QAFR,YAAO,GAAP,OAAO,CAA8C;IAG9D,CAAC;CACF;AAuBuB,4CAAgB;AArBxC;;;GAGG;AACH,SAAS,YAAY,CAAC,KAAgB;IACpC,KAAK,IAAI,CAAC,GAAG,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,EAAE,EAAE;QACzC,MAAM,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QAC9C,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;KAC7C;AACH,CAAC;AAYyC,oCAAY"} \ No newline at end of file diff --git a/node_modules/socks/build/index.js b/node_modules/socks/build/index.js index 17b6f42..05fbb1d 100644 --- a/node_modules/socks/build/index.js +++ b/node_modules/socks/build/index.js @@ -1,7 +1,11 @@ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); }) : (function(o, m, k, k2) { if (k2 === undefined) k2 = k; o[k2] = m[k]; diff --git a/node_modules/socks/build/index.js.map b/node_modules/socks/build/index.js.map index ff654a0..0e2bcb2 100644 --- a/node_modules/socks/build/index.js.map +++ b/node_modules/socks/build/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,uDAAqC"} \ No newline at end of file +{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,uDAAqC"} \ No newline at end of file diff --git a/node_modules/socks/package.json b/node_modules/socks/package.json index c518b1e..ac0b6d3 100644 --- a/node_modules/socks/package.json +++ b/node_modules/socks/package.json @@ -1,7 +1,7 @@ { "name": "socks", "private": false, - "version": "2.6.1", + "version": "2.7.0", "description": "Fully featured SOCKS proxy client supporting SOCKSv4, SOCKSv4a, and SOCKSv5. Includes Bind and Associate functionality.", "main": "build/index.js", "typings": "typings/index.d.ts", @@ -34,52 +34,25 @@ "readmeFilename": "README.md", "devDependencies": { "@types/ip": "1.1.0", - "@types/mocha": "^8.2.2", - "@types/node": "^14.14.41", - "coveralls": "3.1.0", - "mocha": "^8.3.2", - "nyc": "15.1.0", - "prettier": "^2.2.1", - "socks5-server": "^0.1.1", - "ts-node": "^9.1.1", - "tslint": "^6.1.3", - "tslint-config-airbnb": "^5.11.2", - "typescript": "^4.2.4" + "@types/mocha": "^9.1.1", + "@types/node": "^18.0.6", + "@typescript-eslint/eslint-plugin": "^5.30.6", + "@typescript-eslint/parser": "^5.30.6", + "eslint": "^8.20.0", + "mocha": "^10.0.0", + "prettier": "^2.7.1", + "ts-node": "^10.9.1", + "typescript": "^4.7.4" }, "dependencies": { - "ip": "^1.1.5", - "smart-buffer": "^4.1.0" + "ip": "^2.0.0", + "smart-buffer": "^4.2.0" }, "scripts": { "prepublish": "npm install -g typescript && npm run build", "test": "NODE_ENV=test mocha --recursive --require ts-node/register test/**/*.ts", "prettier": "prettier --write ./src/**/*.ts --config .prettierrc.yaml", - "coverage": "NODE_ENV=test nyc npm test", - "coveralls": "NODE_ENV=test nyc npm test && nyc report --reporter=text-lcov | coveralls", - "lint": "tslint --project tsconfig.json 'src/**/*.ts'", + "lint": "eslint 'src/**/*.ts'", "build": "rm -rf build typings && prettier --write ./src/**/*.ts --config .prettierrc.yaml && tsc -p ." - }, - "nyc": { - "extension": [ - ".ts", - ".tsx" - ], - "include": [ - "src/*.ts", - "src/**/*.ts" - ], - "exclude": [ - "**.*.d.ts", - "node_modules", - "typings" - ], - "require": [ - "ts-node/register" - ], - "reporter": [ - "json", - "html" - ], - "all": true } } diff --git a/node_modules/socks/typings/client/socksclient.d.ts b/node_modules/socks/typings/client/socksclient.d.ts index d8ce1b9..b886d95 100644 --- a/node_modules/socks/typings/client/socksclient.d.ts +++ b/node_modules/socks/typings/client/socksclient.d.ts @@ -1,4 +1,6 @@ /// <reference types="node" /> +/// <reference types="node" /> +/// <reference types="node" /> import { EventEmitter } from 'events'; import { SocksClientOptions, SocksClientChainOptions, SocksRemoteHost, SocksProxy, SocksClientBoundEvent, SocksClientEstablishedEvent, SocksUDPFrameDetails } from '../common/constants'; import { SocksClientError } from '../common/util'; @@ -7,11 +9,11 @@ declare interface SocksClient { on(event: 'error', listener: (err: SocksClientError) => void): this; on(event: 'bound', listener: (info: SocksClientBoundEvent) => void): this; on(event: 'established', listener: (info: SocksClientEstablishedEvent) => void): this; - once(event: string, listener: (...args: any[]) => void): this; + once(event: string, listener: (...args: unknown[]) => void): this; once(event: 'error', listener: (err: SocksClientError) => void): this; once(event: 'bound', listener: (info: SocksClientBoundEvent) => void): this; once(event: 'established', listener: (info: SocksClientEstablishedEvent) => void): this; - emit(event: string | symbol, ...args: any[]): boolean; + emit(event: string | symbol, ...args: unknown[]): boolean; emit(event: 'error', err: SocksClientError): boolean; emit(event: 'bound', info: SocksClientBoundEvent): boolean; emit(event: 'established', info: SocksClientEstablishedEvent): boolean; @@ -36,7 +38,7 @@ declare class SocksClient extends EventEmitter implements SocksClient { * @param callback { Function } An optional callback function. * @returns { Promise } */ - static createConnection(options: SocksClientOptions, callback?: Function): Promise<SocksClientEstablishedEvent>; + static createConnection(options: SocksClientOptions, callback?: (error: Error | null, info?: SocksClientEstablishedEvent) => void): Promise<SocksClientEstablishedEvent>; /** * Creates a new SOCKS connection chain to a destination host through 2 or more SOCKS proxies. * @@ -46,7 +48,7 @@ declare class SocksClient extends EventEmitter implements SocksClient { * @param callback { Function } An optional callback function. * @returns { Promise } */ - static createConnectionChain(options: SocksClientChainOptions, callback?: Function): Promise<SocksClientEstablishedEvent>; + static createConnectionChain(options: SocksClientChainOptions, callback?: (error: Error | null, socket?: SocksClientEstablishedEvent) => void): Promise<SocksClientEstablishedEvent>; /** * Creates a SOCKS UDP Frame. * @param options diff --git a/node_modules/socks/typings/common/constants.d.ts b/node_modules/socks/typings/common/constants.d.ts index 664795c..32a5705 100644 --- a/node_modules/socks/typings/common/constants.d.ts +++ b/node_modules/socks/typings/common/constants.d.ts @@ -1,4 +1,6 @@ /// <reference types="node" /> +/// <reference types="node" /> +/// <reference types="node" /> import { Duplex } from 'stream'; import { Socket, SocketConnectOpts } from 'net'; import { RequireOnlyOne } from './util'; diff --git a/node_modules/socks/typings/common/util.d.ts b/node_modules/socks/typings/common/util.d.ts index 29c539a..83f20e7 100644 --- a/node_modules/socks/typings/common/util.d.ts +++ b/node_modules/socks/typings/common/util.d.ts @@ -10,7 +10,7 @@ declare class SocksClientError extends Error { * Shuffles a given array. * @param array The array to shuffle. */ -declare function shuffleArray(array: any[]): void; +declare function shuffleArray(array: unknown[]): void; declare type RequireOnlyOne<T, Keys extends keyof T = keyof T> = Pick<T, Exclude<keyof T, Keys>> & { [K in Keys]?: Required<Pick<T, K>> & Partial<Record<Exclude<Keys, K>, undefined>>; }[Keys]; diff --git a/node_modules/stringify-package/LICENSE b/node_modules/stringify-package/LICENSE deleted file mode 100644 index 209e447..0000000 --- a/node_modules/stringify-package/LICENSE +++ /dev/null @@ -1,13 +0,0 @@ -Copyright npm, Inc - -Permission to use, copy, modify, and/or distribute this software for any -purpose with or without fee is hereby granted, provided that the above -copyright notice and this permission notice appear in all copies. - -THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF -OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/node_modules/stringify-package/index.js b/node_modules/stringify-package/index.js deleted file mode 100644 index cd291f2..0000000 --- a/node_modules/stringify-package/index.js +++ /dev/null @@ -1,18 +0,0 @@ -'use strict' - -module.exports = stringifyPackage - -const DEFAULT_INDENT = 2 -const CRLF = '\r\n' -const LF = '\n' - -function stringifyPackage (data, indent, newline) { - indent = indent || (indent === 0 ? 0 : DEFAULT_INDENT) - const json = JSON.stringify(data, null, indent) - - if (newline === CRLF) { - return json.replace(/\n/g, CRLF) + CRLF - } - - return json + LF -} diff --git a/node_modules/stringify-package/package.json b/node_modules/stringify-package/package.json deleted file mode 100644 index c0e5622..0000000 --- a/node_modules/stringify-package/package.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "name": "stringify-package", - "version": "1.0.1", - "description": "stringifies npm-written json files", - "main": "index.js", - "files": [ - "index.js" - ], - "repository": { - "type": "git", - "url": "git+https://github.com/npm/stringify-package.git" - }, - "keywords": [ - "npm", - "json", - "stringify", - "package.json" - ], - "author": "Kat Marchán <kzm@zkat.tech>", - "license": "ISC", - "bugs": { - "url": "https://github.com/npm/stringify-package/issues" - }, - "homepage": "https://github.com/npm/stringify-package", - "scripts": { - "prerelease": "npm t", - "release": "standard-version -s", - "postrelease": "npm publish", - "postpublish": "git push --follow-tags", - "pretest": "standard", - "test": "tap -J --coverage --100 test/*.js" - }, - "devDependencies": { - "standard": "11", - "standard-version": "4", - "tap": "12" - } -} diff --git a/node_modules/treeverse/index.js b/node_modules/treeverse/index.js deleted file mode 100644 index ca0229e..0000000 --- a/node_modules/treeverse/index.js +++ /dev/null @@ -1,4 +0,0 @@ -module.exports = { - breadth: require('./lib/breadth.js'), - depth: require('./lib/depth.js'), -} diff --git a/node_modules/treeverse/lib/breadth.js b/node_modules/treeverse/lib/breadth.js index 56c02ec..6681f8c 100644 --- a/node_modules/treeverse/lib/breadth.js +++ b/node_modules/treeverse/lib/breadth.js @@ -28,27 +28,28 @@ const breadth = ({ return seen.get(tree) } - const visitNode = (tree) => { - if (seen.has(tree)) - return seen.get(tree) + const visitNode = (visitTree) => { + if (seen.has(visitTree)) { + return seen.get(visitTree) + } - seen.set(tree, null) - const res = visit ? visit(tree) : tree + seen.set(visitTree, null) + const res = visit ? visit(visitTree) : visitTree if (isPromise(res)) { - const fullResult = res.then(res => { - seen.set(tree, res) - return kidNodes(tree) + const fullResult = res.then(resThen => { + seen.set(visitTree, resThen) + return kidNodes(visitTree) }) - seen.set(tree, fullResult) + seen.set(visitTree, fullResult) return fullResult } else { - seen.set(tree, res) - return kidNodes(tree) + seen.set(visitTree, res) + return kidNodes(visitTree) } } - const kidNodes = (tree) => { - const kids = getChildren(tree, seen.get(tree)) + const kidNodes = (kidTree) => { + const kids = getChildren(kidTree, seen.get(kidTree)) return isPromise(kids) ? kids.then(processKids) : processKids(kids) } diff --git a/node_modules/treeverse/lib/depth-descent.js b/node_modules/treeverse/lib/depth-descent.js index 8ac3af0..361d6bf 100644 --- a/node_modules/treeverse/lib/depth-descent.js +++ b/node_modules/treeverse/lib/depth-descent.js @@ -49,27 +49,28 @@ const depth = ({ return seen.get(tree) } - const visitNode = (tree) => { - if (seen.has(tree)) - return seen.get(tree) + const visitNode = (visitTree) => { + if (seen.has(visitTree)) { + return seen.get(visitTree) + } - seen.set(tree, null) - const res = visit ? visit(tree) : tree + seen.set(visitTree, null) + const res = visit ? visit(visitTree) : visitTree if (isPromise(res)) { - const fullResult = res.then(res => { - seen.set(tree, res) - return kidNodes(tree) + const fullResult = res.then(resThen => { + seen.set(visitTree, resThen) + return kidNodes(visitTree) }) - seen.set(tree, fullResult) + seen.set(visitTree, fullResult) return fullResult } else { - seen.set(tree, res) - return kidNodes(tree) + seen.set(visitTree, res) + return kidNodes(visitTree) } } - const kidNodes = (tree) => { - const kids = getChildren(tree, seen.get(tree)) + const kidNodes = (kidTree) => { + const kids = getChildren(kidTree, seen.get(kidTree)) return isPromise(kids) ? kids.then(processKids) : processKids(kids) } diff --git a/node_modules/treeverse/lib/depth.js b/node_modules/treeverse/lib/depth.js index dbab1c2..ecd1388 100644 --- a/node_modules/treeverse/lib/depth.js +++ b/node_modules/treeverse/lib/depth.js @@ -23,19 +23,21 @@ const depth = ({ getChildren, tree, }) => { - if (!leave) + if (!leave) { return depthDescent({ visit, filter, getChildren, tree }) + } - if (seen.has(tree)) + if (seen.has(tree)) { return seen.get(tree) + } seen.set(tree, null) const visitNode = () => { const res = visit ? visit(tree) : tree if (isPromise(res)) { - const fullResult = res.then(res => { - seen.set(tree, res) + const fullResult = res.then(resThen => { + seen.set(tree, resThen) return kidNodes() }) seen.set(tree, fullResult) @@ -51,9 +53,9 @@ const depth = ({ return isPromise(kids) ? kids.then(processKids) : processKids(kids) } - const processKids = kidNodes => { - const kids = (kidNodes || []).filter(filter).map(kid => - depth({visit, leave, filter, seen, getChildren, tree: kid})) + const processKids = nodes => { + const kids = (nodes || []).filter(filter).map(kid => + depth({ visit, leave, filter, seen, getChildren, tree: kid })) return kids.some(isPromise) ? Promise.all(kids).then(leaveNode) : leaveNode(kids) diff --git a/node_modules/treeverse/lib/index.js b/node_modules/treeverse/lib/index.js new file mode 100644 index 0000000..f8e6315 --- /dev/null +++ b/node_modules/treeverse/lib/index.js @@ -0,0 +1,4 @@ +module.exports = { + breadth: require('./breadth.js'), + depth: require('./depth.js'), +} diff --git a/node_modules/treeverse/package.json b/node_modules/treeverse/package.json index 337194c..b8de0b2 100644 --- a/node_modules/treeverse/package.json +++ b/node_modules/treeverse/package.json @@ -1,37 +1,51 @@ { "name": "treeverse", - "version": "1.0.4", + "version": "3.0.0", "description": "Walk any kind of tree structure depth- or breadth-first. Supports promises and advanced map-reduce operations with a very small API.", - "author": "Isaac Z. Schlueter <i@izs.me> (https://izs.me)", + "author": "GitHub Inc.", "license": "ISC", "repository": { "type": "git", - "url": "git+https://github.com/npm/treeverse.git" + "url": "https://github.com/npm/treeverse.git" }, "scripts": { "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "postpublish": "git push origin --follow-tags" + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "npm run lint -- --fix", + "posttest": "npm run lint" }, "tap": { "100": true, - "coverage-map": "map.js" + "coverage-map": "test/coverage-map.js", + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "devDependencies": { - "tap": "^14.10.6", - "tcompare": "^2.3.0" + "@npmcli/eslint-config": "^3.0.1", + "@npmcli/template-oss": "4.5.1", + "tap": "^16.0.1" }, "files": [ - "index.js", + "bin/", "lib/" ], - "main": "index.js", + "main": "lib/index.js", "keywords": [ "tree", "traversal", "depth first search", "breadth first search" - ] + ], + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" + } } diff --git a/node_modules/unique-slug/index.js b/node_modules/unique-slug/lib/index.js similarity index 55% rename from node_modules/unique-slug/index.js rename to node_modules/unique-slug/lib/index.js index fa4761a..1bac84d 100644 --- a/node_modules/unique-slug/index.js +++ b/node_modules/unique-slug/lib/index.js @@ -4,8 +4,8 @@ var MurmurHash3 = require('imurmurhash') module.exports = function (uniq) { if (uniq) { var hash = new MurmurHash3(uniq) - return ('00000000' + hash.result().toString(16)).substr(-8) + return ('00000000' + hash.result().toString(16)).slice(-8) } else { - return (Math.random().toString(16) + '0000000').substr(2, 8) + return (Math.random().toString(16) + '0000000').slice(2, 10) } } diff --git a/node_modules/unique-slug/package.json b/node_modules/unique-slug/package.json index 2142e68..33732cd 100644 --- a/node_modules/unique-slug/package.json +++ b/node_modules/unique-slug/package.json @@ -1,23 +1,47 @@ { "name": "unique-slug", - "version": "2.0.2", + "version": "4.0.0", "description": "Generate a unique character string suitible for use in files and URLs.", - "main": "index.js", + "main": "lib/index.js", "scripts": { - "test": "standard && tap --coverage test" + "test": "tap", + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "npm run lint -- --fix", + "snap": "tap", + "posttest": "npm run lint" }, "keywords": [], - "author": "Rebecca Turner <me@re-becca.org> (http://re-becca.org)", + "author": "GitHub Inc.", "license": "ISC", "devDependencies": { - "standard": "^12.0.1", - "tap": "^12.7.0" + "@npmcli/eslint-config": "^3.1.0", + "@npmcli/template-oss": "4.5.1", + "tap": "^16.3.0" }, "repository": { "type": "git", - "url": "git://github.com/iarna/unique-slug.git" + "url": "https://github.com/npm/unique-slug.git" }, "dependencies": { "imurmurhash": "^0.1.4" + }, + "files": [ + "bin/", + "lib/" + ], + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.5.1" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/node_modules/unique-slug/test/index.js b/node_modules/unique-slug/test/index.js deleted file mode 100644 index 0f4ccad..0000000 --- a/node_modules/unique-slug/test/index.js +++ /dev/null @@ -1,13 +0,0 @@ -'use strict' -var t = require('tap') -var uniqueSlug = require('../index.js') - -t.plan(5) -var slugA = uniqueSlug() -t.is(slugA.length, 8, 'random slugs are 8 chars') -t.notEqual(slugA, uniqueSlug(), "two slugs aren't the same") -var base = '/path/to/thingy' -var slugB = uniqueSlug(base) -t.is(slugB.length, 8, 'string based slugs are 8 chars') -t.is(slugB, uniqueSlug(base), 'two string based slugs, from the same string are the same') -t.notEqual(slugB, uniqueSlug(slugA), 'two string based slongs, from diff strings are different') diff --git a/package-lock.json b/package-lock.json index 0e6871d..189b915 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,31 +1,29 @@ { "name": "npm", - "version": "8.5.1", - "lockfileVersion": 2, + "version": "9.2.0", + "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "npm", - "version": "8.5.1", + "version": "9.2.0", "bundleDependencies": [ "@isaacs/string-locale-compare", "@npmcli/arborist", - "@npmcli/ci-detect", "@npmcli/config", "@npmcli/map-workspaces", "@npmcli/package-json", "@npmcli/run-script", "abbrev", - "ansicolors", - "ansistyles", "archy", "cacache", "chalk", - "chownr", + "ci-info", "cli-columns", "cli-table3", "columnify", "fastest-levenshtein", + "fs-minipass", "glob", "graceful-fs", "hosted-git-info", @@ -45,10 +43,10 @@ "libnpmteam", "libnpmversion", "make-fetch-happen", + "minimatch", "minipass", "minipass-pipeline", "mkdirp", - "mkdirp-infer-owner", "ms", "node-gyp", "nopt", @@ -60,7 +58,7 @@ "npm-registry-fetch", "npm-user-validate", "npmlog", - "opener", + "p-map", "pacote", "parse-conflict-json", "proc-log", @@ -68,7 +66,6 @@ "read", "read-package-json", "read-package-json-fast", - "readdir-scoped-modules", "rimraf", "semver", "ssri", @@ -83,138 +80,221 @@ "license": "Artistic-2.0", "workspaces": [ "docs", + "smoke-tests", + "mock-registry", "workspaces/*" ], "dependencies": { "@isaacs/string-locale-compare": "^1.1.0", - "@npmcli/arborist": "^4.3.1", - "@npmcli/ci-detect": "^2.0.0", - "@npmcli/config": "^3.0.0", - "@npmcli/map-workspaces": "^2.0.0", - "@npmcli/package-json": "^1.0.1", - "@npmcli/run-script": "^2.0.0", - "abbrev": "~1.1.1", - "ansicolors": "~0.3.2", - "ansistyles": "~0.1.3", + "@npmcli/arborist": "^6.1.5", + "@npmcli/config": "^6.1.0", + "@npmcli/map-workspaces": "^3.0.0", + "@npmcli/package-json": "^3.0.0", + "@npmcli/run-script": "^6.0.0", + "abbrev": "^2.0.0", "archy": "~1.0.0", - "cacache": "^15.3.0", + "cacache": "^17.0.3", "chalk": "^4.1.2", - "chownr": "^2.0.0", + "ci-info": "^3.7.0", "cli-columns": "^4.0.0", - "cli-table3": "^0.6.1", - "columnify": "~1.5.4", - "fastest-levenshtein": "^1.0.12", - "glob": "^7.2.0", - "graceful-fs": "^4.2.9", - "hosted-git-info": "^4.1.0", - "ini": "^2.0.0", - "init-package-json": "^2.0.5", + "cli-table3": "^0.6.3", + "columnify": "^1.6.0", + "fastest-levenshtein": "^1.0.16", + "fs-minipass": "^2.1.0", + "glob": "^8.0.1", + "graceful-fs": "^4.2.10", + "hosted-git-info": "^6.1.1", + "ini": "^3.0.1", + "init-package-json": "^4.0.1", "is-cidr": "^4.0.2", - "json-parse-even-better-errors": "^2.3.1", - "libnpmaccess": "^5.0.1", - "libnpmdiff": "^3.0.0", - "libnpmexec": "^3.0.3", - "libnpmfund": "^2.0.2", - "libnpmhook": "^7.0.1", - "libnpmorg": "^3.0.1", - "libnpmpack": "^3.1.0", - "libnpmpublish": "^5.0.1", - "libnpmsearch": "^4.0.1", - "libnpmteam": "^3.0.1", - "libnpmversion": "^2.0.2", - "make-fetch-happen": "^10.0.3", - "minipass": "^3.1.6", + "json-parse-even-better-errors": "^3.0.0", + "libnpmaccess": "^7.0.1", + "libnpmdiff": "^5.0.6", + "libnpmexec": "^5.0.6", + "libnpmfund": "^4.0.6", + "libnpmhook": "^9.0.1", + "libnpmorg": "^5.0.1", + "libnpmpack": "^5.0.6", + "libnpmpublish": "^7.0.6", + "libnpmsearch": "^6.0.1", + "libnpmteam": "^5.0.1", + "libnpmversion": "^4.0.1", + "make-fetch-happen": "^11.0.2", + "minimatch": "^5.1.1", + "minipass": "^4.0.0", "minipass-pipeline": "^1.2.4", "mkdirp": "^1.0.4", - "mkdirp-infer-owner": "^2.0.0", "ms": "^2.1.2", - "node-gyp": "^8.4.1", - "nopt": "^5.0.0", - "npm-audit-report": "^2.1.5", - "npm-install-checks": "^4.0.0", - "npm-package-arg": "^8.1.5", - "npm-pick-manifest": "^6.1.1", - "npm-profile": "^6.0.0", - "npm-registry-fetch": "^12.0.2", + "node-gyp": "^9.3.0", + "nopt": "^7.0.0", + "npm-audit-report": "^4.0.0", + "npm-install-checks": "^6.0.0", + "npm-package-arg": "^10.1.0", + "npm-pick-manifest": "^8.0.1", + "npm-profile": "^7.0.1", + "npm-registry-fetch": "^14.0.3", "npm-user-validate": "^1.0.1", - "npmlog": "^6.0.1", - "opener": "^1.5.2", - "pacote": "^12.0.3", - "parse-conflict-json": "^2.0.1", - "proc-log": "^1.0.0", + "npmlog": "^7.0.1", + "p-map": "^4.0.0", + "pacote": "^15.0.7", + "parse-conflict-json": "^3.0.0", + "proc-log": "^3.0.0", "qrcode-terminal": "^0.12.0", "read": "~1.0.7", - "read-package-json": "^4.1.1", - "read-package-json-fast": "^2.0.3", - "readdir-scoped-modules": "^1.1.0", + "read-package-json": "^6.0.0", + "read-package-json-fast": "^3.0.1", "rimraf": "^3.0.2", - "semver": "^7.3.5", - "ssri": "^8.0.1", - "tar": "^6.1.11", + "semver": "^7.3.8", + "ssri": "^10.0.1", + "tar": "^6.1.13", "text-table": "~0.2.0", "tiny-relative-date": "^1.3.0", - "treeverse": "^1.0.4", - "validate-npm-package-name": "~3.0.0", - "which": "^2.0.2", - "write-file-atomic": "^4.0.0" + "treeverse": "^3.0.0", + "validate-npm-package-name": "^5.0.0", + "which": "^3.0.0", + "write-file-atomic": "^5.0.0" }, "bin": { "npm": "bin/npm-cli.js", "npx": "bin/npx-cli.js" }, "devDependencies": { - "@npmcli/eslint-config": "^2.0.0", - "@npmcli/template-oss": "^2.4.3", - "eslint": "^8.3.0", - "licensee": "^8.2.0", + "@npmcli/docs": "^1.0.0", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/fs": "^3.1.0", + "@npmcli/git": "^4.0.1", + "@npmcli/mock-registry": "^1.0.0", + "@npmcli/promise-spawn": "^6.0.1", + "@npmcli/template-oss": "4.11.0", + "licensee": "^10.0.0", + "nock": "^13.2.4", + "npm-packlist": "^7.0.4", + "remark": "^14.0.2", + "remark-gfm": "^3.0.1", + "remark-github": "^11.2.4", "spawk": "^1.7.1", - "tap": "^15.1.6" + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "docs": { + "name": "@npmcli/docs", "version": "1.0.0", + "license": "ISC", "devDependencies": { - "@mdx-js/mdx": "^1.6.22", - "cmark-gfm": "^0.9.0", - "jsdom": "^18.1.0", - "marked-man": "^0.7.0", - "yaml": "^1.10.0" + "@isaacs/string-locale-compare": "^1.1.0", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "front-matter": "^4.0.2", + "ignore-walk": "^6.0.0", + "jsdom": "^20.0.3", + "mkdirp": "^1.0.4", + "rehype-stringify": "^9.0.3", + "remark-gfm": "^3.0.1", + "remark-man": "^8.0.1", + "remark-parse": "^10.0.1", + "remark-rehype": "^10.1.0", + "tap": "^16.3.2", + "unified": "^10.1.2", + "yaml": "^2.1.3" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "mock-registry": { + "name": "@npmcli/mock-registry", + "version": "1.0.0", + "license": "ISC", + "devDependencies": { + "@npmcli/arborist": "^6.1.1", + "@npmcli/eslint-config": "^4.0.1", + "@npmcli/template-oss": "4.11.0", + "nock": "^13.2.9", + "npm-package-arg": "^10.1.0", + "pacote": "^15.0.7", + "tap": "^16.3.2" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/@actions/core": { + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/@actions/core/-/core-1.10.0.tgz", + "integrity": "sha512-2aZDDa3zrrZbP5ZYg159sNoLRb61nQ7awl5pSvIq5Qpj81vwDzdMRKzkWJGJuwVvWpvZKx7vspJALyvaaIQyug==", + "dev": true, + "dependencies": { + "@actions/http-client": "^2.0.1", + "uuid": "^8.3.2" + } + }, + "node_modules/@actions/http-client": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/@actions/http-client/-/http-client-2.0.1.tgz", + "integrity": "sha512-PIXiMVtz6VvyaRsGY268qvj57hXQEpsYogYOu2nrQhlf+XCGmZstmuZBbAybUl1nQGnvS1k1eEsQ69ZoD7xlSw==", + "dev": true, + "dependencies": { + "tunnel": "^0.0.6" + } + }, + "node_modules/@ampproject/remapping": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.2.0.tgz", + "integrity": "sha512-qRmjj8nj9qmLTQXXmaR1cck3UXSRMPrbsLJAasZpF+t3riI71BXed5ebIOYwQntykeZuhjsdweEc9BxH5Jc26w==", + "dev": true, + "dependencies": { + "@jridgewell/gen-mapping": "^0.1.0", + "@jridgewell/trace-mapping": "^0.3.9" + }, + "engines": { + "node": ">=6.0.0" } }, "node_modules/@babel/code-frame": { - "version": "7.12.13", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.12.13.tgz", - "integrity": "sha512-HV1Cm0Q3ZrpCR93tkWOYiuYIgLxZXZFVG2VgK+MBWjUqZTundupbfx2aXarXuw5Ko5aMcjtJgbSs4vUGBS5v6g==", + "version": "7.18.6", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.18.6.tgz", + "integrity": "sha512-TDCmlK5eOvH+eH7cdAFlNXeVJqWIQ7gW9tY1GJIpUtFb6CmjVyq2VM3u71bOyR8CRihcCgMUYoDNyLXao3+70Q==", "dev": true, "dependencies": { - "@babel/highlight": "^7.12.13" + "@babel/highlight": "^7.18.6" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/compat-data": { + "version": "7.20.1", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.20.1.tgz", + "integrity": "sha512-EWZ4mE2diW3QALKvDMiXnbZpRvlj+nayZ112nK93SnhqOtpdsbVD4W+2tEoT3YNBAG9RBR0ISY758ZkOgsn6pQ==", + "dev": true, + "engines": { + "node": ">=6.9.0" } }, "node_modules/@babel/core": { - "version": "7.12.9", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.12.9.tgz", - "integrity": "sha512-gTXYh3M5wb7FRXQy+FErKFAv90BnlOuNn1QkCK2lREoPAjrQCO49+HVSrFoe5uakFAF5eenS75KbO2vQiLrTMQ==", + "version": "7.20.2", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.20.2.tgz", + "integrity": "sha512-w7DbG8DtMrJcFOi4VrLm+8QM4az8Mo+PuLBKLp2zrYRCow8W/f9xiXm5sN53C8HksCyDQwCKha9JiDoIyPjT2g==", "dev": true, "dependencies": { - "@babel/code-frame": "^7.10.4", - "@babel/generator": "^7.12.5", - "@babel/helper-module-transforms": "^7.12.1", - "@babel/helpers": "^7.12.5", - "@babel/parser": "^7.12.7", - "@babel/template": "^7.12.7", - "@babel/traverse": "^7.12.9", - "@babel/types": "^7.12.7", + "@ampproject/remapping": "^2.1.0", + "@babel/code-frame": "^7.18.6", + "@babel/generator": "^7.20.2", + "@babel/helper-compilation-targets": "^7.20.0", + "@babel/helper-module-transforms": "^7.20.2", + "@babel/helpers": "^7.20.1", + "@babel/parser": "^7.20.2", + "@babel/template": "^7.18.10", + "@babel/traverse": "^7.20.1", + "@babel/types": "^7.20.2", "convert-source-map": "^1.7.0", "debug": "^4.1.0", - "gensync": "^1.0.0-beta.1", - "json5": "^2.1.2", - "lodash": "^4.17.19", - "resolve": "^1.3.2", - "semver": "^5.4.1", - "source-map": "^0.5.0" + "gensync": "^1.0.0-beta.2", + "json5": "^2.2.1", + "semver": "^6.3.0" }, "engines": { "node": ">=6.9.0" @@ -225,159 +305,211 @@ } }, "node_modules/@babel/core/node_modules/semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", + "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", "dev": true, "bin": { - "semver": "bin/semver" + "semver": "bin/semver.js" } }, "node_modules/@babel/generator": { - "version": "7.14.3", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.14.3.tgz", - "integrity": "sha512-bn0S6flG/j0xtQdz3hsjJ624h3W0r3llttBMfyHX3YrZ/KtLYr15bjA0FXkgW7FpvrDuTuElXeVjiKlYRpnOFA==", + "version": "7.20.3", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.20.3.tgz", + "integrity": "sha512-Wl5ilw2UD1+ZYprHVprxHZJCFeBWlzZYOovE4SDYLZnqCOD11j+0QzNeEWKLLTWM7nixrZEh7vNIyb76MyJg3A==", "dev": true, "dependencies": { - "@babel/types": "^7.14.2", - "jsesc": "^2.5.1", - "source-map": "^0.5.0" + "@babel/types": "^7.20.2", + "@jridgewell/gen-mapping": "^0.3.2", + "jsesc": "^2.5.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/generator/node_modules/@jridgewell/gen-mapping": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz", + "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==", + "dev": true, + "dependencies": { + "@jridgewell/set-array": "^1.0.1", + "@jridgewell/sourcemap-codec": "^1.4.10", + "@jridgewell/trace-mapping": "^0.3.9" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/helper-compilation-targets": { + "version": "7.20.0", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.20.0.tgz", + "integrity": "sha512-0jp//vDGp9e8hZzBc6N/KwA5ZK3Wsm/pfm4CrY7vzegkVxc65SgSn6wYOnwHe9Js9HRQ1YTCKLGPzDtaS3RoLQ==", + "dev": true, + "dependencies": { + "@babel/compat-data": "^7.20.0", + "@babel/helper-validator-option": "^7.18.6", + "browserslist": "^4.21.3", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-compilation-targets/node_modules/semver": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", + "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/@babel/helper-environment-visitor": { + "version": "7.18.9", + "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.18.9.tgz", + "integrity": "sha512-3r/aACDJ3fhQ/EVgFy0hpj8oHyHpQc+LPtJoY9SzTThAsStm4Ptegq92vqKoE3vD706ZVFWITnMnxucw+S9Ipg==", + "dev": true, + "engines": { + "node": ">=6.9.0" } }, "node_modules/@babel/helper-function-name": { - "version": "7.14.2", - "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.14.2.tgz", - "integrity": "sha512-NYZlkZRydxw+YT56IlhIcS8PAhb+FEUiOzuhFTfqDyPmzAhRge6ua0dQYT/Uh0t/EDHq05/i+e5M2d4XvjgarQ==", + "version": "7.19.0", + "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.19.0.tgz", + "integrity": "sha512-WAwHBINyrpqywkUH0nTnNgI5ina5TFn85HKS0pbPDfxFfhyR/aNQEn4hGi1P1JyT//I0t4OgXUlofzWILRvS5w==", "dev": true, "dependencies": { - "@babel/helper-get-function-arity": "^7.12.13", - "@babel/template": "^7.12.13", - "@babel/types": "^7.14.2" + "@babel/template": "^7.18.10", + "@babel/types": "^7.19.0" + }, + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@babel/helper-get-function-arity": { - "version": "7.12.13", - "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.12.13.tgz", - "integrity": "sha512-DjEVzQNz5LICkzN0REdpD5prGoidvbdYk1BVgRUOINaWJP2t6avB27X1guXK1kXNrX0WMfsrm1A/ZBthYuIMQg==", + "node_modules/@babel/helper-hoist-variables": { + "version": "7.18.6", + "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.18.6.tgz", + "integrity": "sha512-UlJQPkFqFULIcyW5sbzgbkxn2FKRgwWiRexcuaR8RNJRy8+LLveqPjwZV/bwrLZCN0eUHD/x8D0heK1ozuoo6Q==", "dev": true, "dependencies": { - "@babel/types": "^7.12.13" - } - }, - "node_modules/@babel/helper-member-expression-to-functions": { - "version": "7.13.12", - "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.13.12.tgz", - "integrity": "sha512-48ql1CLL59aKbU94Y88Xgb2VFy7a95ykGRbJJaaVv+LX5U8wFpLfiGXJJGUozsmA1oEh/o5Bp60Voq7ACyA/Sw==", - "dev": true, - "dependencies": { - "@babel/types": "^7.13.12" + "@babel/types": "^7.18.6" + }, + "engines": { + "node": ">=6.9.0" } }, "node_modules/@babel/helper-module-imports": { - "version": "7.16.0", - "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.16.0.tgz", - "integrity": "sha512-kkH7sWzKPq0xt3H1n+ghb4xEMP8k0U7XV3kkB+ZGy69kDk2ySFW1qPi06sjKzFY3t1j6XbJSqr4mF9L7CYVyhg==", + "version": "7.18.6", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.18.6.tgz", + "integrity": "sha512-0NFvs3VkuSYbFi1x2Vd6tKrywq+z/cLeYC/RJNFrIX/30Bf5aiGYbtvGXolEktzJH8o5E5KJ3tT+nkxuuZFVlA==", "dev": true, "dependencies": { - "@babel/types": "^7.16.0" + "@babel/types": "^7.18.6" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-module-transforms": { - "version": "7.14.2", - "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.14.2.tgz", - "integrity": "sha512-OznJUda/soKXv0XhpvzGWDnml4Qnwp16GN+D/kZIdLsWoHj05kyu8Rm5kXmMef+rVJZ0+4pSGLkeixdqNUATDA==", + "version": "7.20.2", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.20.2.tgz", + "integrity": "sha512-zvBKyJXRbmK07XhMuujYoJ48B5yvvmM6+wcpv6Ivj4Yg6qO7NOZOSnvZN9CRl1zz1Z4cKf8YejmCMh8clOoOeA==", "dev": true, "dependencies": { - "@babel/helper-module-imports": "^7.13.12", - "@babel/helper-replace-supers": "^7.13.12", - "@babel/helper-simple-access": "^7.13.12", - "@babel/helper-split-export-declaration": "^7.12.13", - "@babel/helper-validator-identifier": "^7.14.0", - "@babel/template": "^7.12.13", - "@babel/traverse": "^7.14.2", - "@babel/types": "^7.14.2" + "@babel/helper-environment-visitor": "^7.18.9", + "@babel/helper-module-imports": "^7.18.6", + "@babel/helper-simple-access": "^7.20.2", + "@babel/helper-split-export-declaration": "^7.18.6", + "@babel/helper-validator-identifier": "^7.19.1", + "@babel/template": "^7.18.10", + "@babel/traverse": "^7.20.1", + "@babel/types": "^7.20.2" + }, + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@babel/helper-optimise-call-expression": { - "version": "7.12.13", - "resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.12.13.tgz", - "integrity": "sha512-BdWQhoVJkp6nVjB7nkFWcn43dkprYauqtk++Py2eaf/GRDFm5BxRqEIZCiHlZUGAVmtwKcsVL1dC68WmzeFmiA==", + "node_modules/@babel/helper-simple-access": { + "version": "7.20.2", + "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.20.2.tgz", + "integrity": "sha512-+0woI/WPq59IrqDYbVGfshjT5Dmk/nnbdpcF8SnMhhXObpTq2KNBdLFRFrkVdbDOyUmHBCxzm5FHV1rACIkIbA==", "dev": true, "dependencies": { - "@babel/types": "^7.12.13" + "@babel/types": "^7.20.2" + }, + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@babel/helper-plugin-utils": { - "version": "7.14.5", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.14.5.tgz", - "integrity": "sha512-/37qQCE3K0vvZKwoK4XU/irIJQdIfCJuhU5eKnNxpFDsOkgFaUAwbv+RYw6eYgsC0E4hS7r5KqGULUogqui0fQ==", + "node_modules/@babel/helper-split-export-declaration": { + "version": "7.18.6", + "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.18.6.tgz", + "integrity": "sha512-bde1etTx6ZyTmobl9LLMMQsaizFVZrquTEHOqKeQESMKo4PlObf+8+JA25ZsIpZhT/WEd39+vOdLXAFG/nELpA==", + "dev": true, + "dependencies": { + "@babel/types": "^7.18.6" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-string-parser": { + "version": "7.19.4", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.19.4.tgz", + "integrity": "sha512-nHtDoQcuqFmwYNYPz3Rah5ph2p8PFeFCsZk9A/48dPc/rGocJ5J3hAAZ7pb76VWX3fZKu+uEr/FhH5jLx7umrw==", "dev": true, "engines": { "node": ">=6.9.0" } }, - "node_modules/@babel/helper-replace-supers": { - "version": "7.14.4", - "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.14.4.tgz", - "integrity": "sha512-zZ7uHCWlxfEAAOVDYQpEf/uyi1dmeC7fX4nCf2iz9drnCwi1zvwXL3HwWWNXUQEJ1k23yVn3VbddiI9iJEXaTQ==", - "dev": true, - "dependencies": { - "@babel/helper-member-expression-to-functions": "^7.13.12", - "@babel/helper-optimise-call-expression": "^7.12.13", - "@babel/traverse": "^7.14.2", - "@babel/types": "^7.14.4" - } - }, - "node_modules/@babel/helper-simple-access": { - "version": "7.13.12", - "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.13.12.tgz", - "integrity": "sha512-7FEjbrx5SL9cWvXioDbnlYTppcZGuCY6ow3/D5vMggb2Ywgu4dMrpTJX0JdQAIcRRUElOIxF3yEooa9gUb9ZbA==", - "dev": true, - "dependencies": { - "@babel/types": "^7.13.12" - } - }, - "node_modules/@babel/helper-split-export-declaration": { - "version": "7.12.13", - "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.12.13.tgz", - "integrity": "sha512-tCJDltF83htUtXx5NLcaDqRmknv652ZWCHyoTETf1CXYJdPC7nohZohjUgieXhv0hTJdRf2FjDueFehdNucpzg==", - "dev": true, - "dependencies": { - "@babel/types": "^7.12.13" - } - }, "node_modules/@babel/helper-validator-identifier": { - "version": "7.15.7", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.15.7.tgz", - "integrity": "sha512-K4JvCtQqad9OY2+yTU8w+E82ywk/fe+ELNlt1G8z3bVGlZfn/hOcQQsUhGhW/N+tb3fxK800wLtKOE/aM0m72w==", + "version": "7.19.1", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz", + "integrity": "sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w==", + "dev": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-option": { + "version": "7.18.6", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.18.6.tgz", + "integrity": "sha512-XO7gESt5ouv/LRJdrVjkShckw6STTaB7l9BrpBaAHDeF5YZT+01PCwmR0SJHnkW6i8OwW/EVWRShfi4j2x+KQw==", "dev": true, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helpers": { - "version": "7.14.0", - "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.14.0.tgz", - "integrity": "sha512-+ufuXprtQ1D1iZTO/K9+EBRn+qPWMJjZSw/S0KlFrxCw4tkrzv9grgpDHkY9MeQTjTY8i2sp7Jep8DfU6tN9Mg==", + "version": "7.20.1", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.20.1.tgz", + "integrity": "sha512-J77mUVaDTUJFZ5BpP6mMn6OIl3rEWymk2ZxDBQJUG3P+PbmyMcF3bYWvz0ma69Af1oobDqT/iAsvzhB58xhQUg==", "dev": true, "dependencies": { - "@babel/template": "^7.12.13", - "@babel/traverse": "^7.14.0", - "@babel/types": "^7.14.0" + "@babel/template": "^7.18.10", + "@babel/traverse": "^7.20.1", + "@babel/types": "^7.20.0" + }, + "engines": { + "node": ">=6.9.0" } }, "node_modules/@babel/highlight": { - "version": "7.14.0", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.14.0.tgz", - "integrity": "sha512-YSCOwxvTYEIMSGaBQb5kDDsCopDdiUGsqpatp3fOlI4+2HQSkTmEVWnVuySdAC5EWCqSWWTv0ib63RjR7dTBdg==", + "version": "7.18.6", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.18.6.tgz", + "integrity": "sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g==", "dev": true, "dependencies": { - "@babel/helper-validator-identifier": "^7.14.0", + "@babel/helper-validator-identifier": "^7.18.6", "chalk": "^2.0.0", "js-tokens": "^4.0.0" + }, + "engines": { + "node": ">=6.9.0" } }, "node_modules/@babel/highlight/node_modules/ansi-styles": { @@ -418,13 +550,13 @@ "node_modules/@babel/highlight/node_modules/color-name": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", + "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", "dev": true }, "node_modules/@babel/highlight/node_modules/escape-string-regexp": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", + "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", "dev": true, "engines": { "node": ">=0.8.0" @@ -433,7 +565,7 @@ "node_modules/@babel/highlight/node_modules/has-flag": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", + "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", "dev": true, "engines": { "node": ">=4" @@ -452,9 +584,9 @@ } }, "node_modules/@babel/parser": { - "version": "7.14.4", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.14.4.tgz", - "integrity": "sha512-ArliyUsWDUqEGfWcmzpGUzNfLxTdTp6WU4IuP6QFSp9gGfWS6boxFCkJSJ/L4+RG8z/FnIU3WxCk6hPL9SSWeA==", + "version": "7.20.3", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.20.3.tgz", + "integrity": "sha512-OP/s5a94frIPXwjzEcv5S/tpQfc6XhxYUnmWpgdqMWGgYCuErA3SzozaRAMQgSZWKeTJxht9aWAkUY+0UzvOFg==", "dev": true, "bin": { "parser": "bin/babel-parser.js" @@ -463,90 +595,58 @@ "node": ">=6.0.0" } }, - "node_modules/@babel/plugin-proposal-object-rest-spread": { - "version": "7.12.1", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.12.1.tgz", - "integrity": "sha512-s6SowJIjzlhx8o7lsFx5zmY4At6CTtDvgNQDdPzkBQucle58A6b/TTeEBYtyDgmcXjUTM+vE8YOGHZzzbc/ioA==", - "dev": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-object-rest-spread": "^7.8.0", - "@babel/plugin-transform-parameters": "^7.12.1" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, - "node_modules/@babel/plugin-syntax-jsx": { - "version": "7.12.1", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.12.1.tgz", - "integrity": "sha512-1yRi7yAtB0ETgxdY9ti/p2TivUxJkTdhu/ZbF9MshVGqOx1TdB3b7xCXs49Fupgg50N45KcAsRP/ZqWjs9SRjg==", - "dev": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.10.4" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, - "node_modules/@babel/plugin-syntax-object-rest-spread": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", - "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", - "dev": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.8.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, - "node_modules/@babel/plugin-transform-parameters": { - "version": "7.14.2", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.14.2.tgz", - "integrity": "sha512-NxoVmA3APNCC1JdMXkdYXuQS+EMdqy0vIwyDHeKHiJKRxmp1qGSdb0JLEIoPRhkx6H/8Qi3RJ3uqOCYw8giy9A==", - "dev": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.13.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, "node_modules/@babel/template": { - "version": "7.12.13", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.12.13.tgz", - "integrity": "sha512-/7xxiGA57xMo/P2GVvdEumr8ONhFOhfgq2ihK3h1e6THqzTAkHbkXgB0xI9yeTfIUoH3+oAeHhqm/I43OTbbjA==", + "version": "7.18.10", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.18.10.tgz", + "integrity": "sha512-TI+rCtooWHr3QJ27kJxfjutghu44DLnasDMwpDqCXVTal9RLp3RSYNh4NdBrRP2cQAoG9A8juOQl6P6oZG4JxA==", "dev": true, "dependencies": { - "@babel/code-frame": "^7.12.13", - "@babel/parser": "^7.12.13", - "@babel/types": "^7.12.13" + "@babel/code-frame": "^7.18.6", + "@babel/parser": "^7.18.10", + "@babel/types": "^7.18.10" + }, + "engines": { + "node": ">=6.9.0" } }, "node_modules/@babel/traverse": { - "version": "7.14.2", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.14.2.tgz", - "integrity": "sha512-TsdRgvBFHMyHOOzcP9S6QU0QQtjxlRpEYOy3mcCO5RgmC305ki42aSAmfZEMSSYBla2oZ9BMqYlncBaKmD/7iA==", + "version": "7.20.1", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.20.1.tgz", + "integrity": "sha512-d3tN8fkVJwFLkHkBN479SOsw4DMZnz8cdbL/gvuDuzy3TS6Nfw80HuQqhw1pITbIruHyh7d1fMA47kWzmcUEGA==", "dev": true, "dependencies": { - "@babel/code-frame": "^7.12.13", - "@babel/generator": "^7.14.2", - "@babel/helper-function-name": "^7.14.2", - "@babel/helper-split-export-declaration": "^7.12.13", - "@babel/parser": "^7.14.2", - "@babel/types": "^7.14.2", + "@babel/code-frame": "^7.18.6", + "@babel/generator": "^7.20.1", + "@babel/helper-environment-visitor": "^7.18.9", + "@babel/helper-function-name": "^7.19.0", + "@babel/helper-hoist-variables": "^7.18.6", + "@babel/helper-split-export-declaration": "^7.18.6", + "@babel/parser": "^7.20.1", + "@babel/types": "^7.20.0", "debug": "^4.1.0", "globals": "^11.1.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/traverse/node_modules/globals": { + "version": "11.12.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", + "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", + "dev": true, + "engines": { + "node": ">=4" } }, "node_modules/@babel/types": { - "version": "7.16.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.16.0.tgz", - "integrity": "sha512-PJgg/k3SdLsGb3hhisFvtLOw5ts113klrpLuIPtCJIU+BB24fqq6lf8RWqKJEjzqXR9AEH1rIb5XTqwBHB+kQg==", + "version": "7.20.2", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.20.2.tgz", + "integrity": "sha512-FnnvsNWgZCr232sqtXggapvlkk/tuwR/qhGzcmxI0GXLCjmPYQPzio2FbdlWuY6y1sHFfQKk+rRbUZ9VStQMog==", "dev": true, "dependencies": { - "@babel/helper-validator-identifier": "^7.15.7", + "@babel/helper-string-parser": "^7.19.4", + "@babel/helper-validator-identifier": "^7.19.1", "to-fast-properties": "^2.0.0" }, "engines": { @@ -554,107 +654,495 @@ } }, "node_modules/@blueoak/list": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@blueoak/list/-/list-2.0.0.tgz", - "integrity": "sha512-yQ6/CTy6DYvmJOAIw/BJjKeNG2ZyF8uxgTN8Yvcv4L9YavoVp9xUgmoVUKN5l24NGPDQpswavNanHOqB00ZNXg==", + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/@blueoak/list/-/list-9.0.0.tgz", + "integrity": "sha512-ExvaAZaZEIhaCePVpqW4ZoFgixhuylQiukSSqaRNfqUtqSWKnlUMZpZWOlugRpfRLuazPkcquDVhPkeodQI5FQ==", "dev": true }, - "node_modules/@eslint/eslintrc": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.0.4.tgz", - "integrity": "sha512-h8Vx6MdxwWI2WM8/zREHMoqdgLNXEL4QX3MWSVMdyNJGvXVOs+6lp+m2hc3FnuMHDc4poxFNI20vCk0OmI4G0Q==", + "node_modules/@colors/colors": { + "version": "1.5.0", + "inBundle": true, + "license": "MIT", + "optional": true, + "engines": { + "node": ">=0.1.90" + } + }, + "node_modules/@commitlint/cli": { + "version": "17.2.0", + "resolved": "https://registry.npmjs.org/@commitlint/cli/-/cli-17.2.0.tgz", + "integrity": "sha512-kd1zykcrjIKyDRftWW1E1TJqkgzeosEkv1BiYPCdzkb/g/3BrfgwZUHR1vg+HO3qKUb/0dN+jNXArhGGAHpmaQ==", "dev": true, + "dependencies": { + "@commitlint/format": "^17.0.0", + "@commitlint/lint": "^17.2.0", + "@commitlint/load": "^17.2.0", + "@commitlint/read": "^17.2.0", + "@commitlint/types": "^17.0.0", + "execa": "^5.0.0", + "lodash": "^4.17.19", + "resolve-from": "5.0.0", + "resolve-global": "1.0.0", + "yargs": "^17.0.0" + }, + "bin": { + "commitlint": "cli.js" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/config-conventional": { + "version": "17.2.0", + "resolved": "https://registry.npmjs.org/@commitlint/config-conventional/-/config-conventional-17.2.0.tgz", + "integrity": "sha512-g5hQqRa80f++SYS233dbDSg16YdyounMTAhVcmqtInNeY/GF3aA4st9SVtJxpeGrGmueMrU4L+BBb+6Vs5wrcg==", + "dev": true, + "dependencies": { + "conventional-changelog-conventionalcommits": "^5.0.0" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/config-validator": { + "version": "17.1.0", + "resolved": "https://registry.npmjs.org/@commitlint/config-validator/-/config-validator-17.1.0.tgz", + "integrity": "sha512-Q1rRRSU09ngrTgeTXHq6ePJs2KrI+axPTgkNYDWSJIuS1Op4w3J30vUfSXjwn5YEJHklK3fSqWNHmBhmTR7Vdg==", + "dev": true, + "dependencies": { + "@commitlint/types": "^17.0.0", + "ajv": "^8.11.0" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/ensure": { + "version": "17.0.0", + "resolved": "https://registry.npmjs.org/@commitlint/ensure/-/ensure-17.0.0.tgz", + "integrity": "sha512-M2hkJnNXvEni59S0QPOnqCKIK52G1XyXBGw51mvh7OXDudCmZ9tZiIPpU882p475Mhx48Ien1MbWjCP1zlyC0A==", + "dev": true, + "dependencies": { + "@commitlint/types": "^17.0.0", + "lodash": "^4.17.19" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/execute-rule": { + "version": "17.0.0", + "resolved": "https://registry.npmjs.org/@commitlint/execute-rule/-/execute-rule-17.0.0.tgz", + "integrity": "sha512-nVjL/w/zuqjCqSJm8UfpNaw66V9WzuJtQvEnCrK4jDw6qKTmZB+1JQ8m6BQVZbNBcwfYdDNKnhIhqI0Rk7lgpQ==", + "dev": true, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/format": { + "version": "17.0.0", + "resolved": "https://registry.npmjs.org/@commitlint/format/-/format-17.0.0.tgz", + "integrity": "sha512-MZzJv7rBp/r6ZQJDEodoZvdRM0vXu1PfQvMTNWFb8jFraxnISMTnPBWMMjr2G/puoMashwaNM//fl7j8gGV5lA==", + "dev": true, + "dependencies": { + "@commitlint/types": "^17.0.0", + "chalk": "^4.1.0" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/is-ignored": { + "version": "17.2.0", + "resolved": "https://registry.npmjs.org/@commitlint/is-ignored/-/is-ignored-17.2.0.tgz", + "integrity": "sha512-rgUPUQraHxoMLxiE8GK430HA7/R2vXyLcOT4fQooNrZq9ERutNrP6dw3gdKLkq22Nede3+gEHQYUzL4Wu75ndg==", + "dev": true, + "dependencies": { + "@commitlint/types": "^17.0.0", + "semver": "7.3.7" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/is-ignored/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@commitlint/is-ignored/node_modules/semver": { + "version": "7.3.7", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.7.tgz", + "integrity": "sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g==", + "dev": true, + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@commitlint/lint": { + "version": "17.2.0", + "resolved": "https://registry.npmjs.org/@commitlint/lint/-/lint-17.2.0.tgz", + "integrity": "sha512-N2oLn4Dj672wKH5qJ4LGO+73UkYXGHO+NTVUusGw83SjEv7GjpqPGKU6KALW2kFQ/GsDefSvOjpSi3CzWHQBDg==", + "dev": true, + "dependencies": { + "@commitlint/is-ignored": "^17.2.0", + "@commitlint/parse": "^17.2.0", + "@commitlint/rules": "^17.2.0", + "@commitlint/types": "^17.0.0" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/load": { + "version": "17.2.0", + "resolved": "https://registry.npmjs.org/@commitlint/load/-/load-17.2.0.tgz", + "integrity": "sha512-HDD57qSqNrk399R4TIjw31AWBG8dBjNj1MrDKZKmC/wvimtnIFlqzcu1+sxfXIOHj/+M6tcMWDtvknGUd7SU+g==", + "dev": true, + "dependencies": { + "@commitlint/config-validator": "^17.1.0", + "@commitlint/execute-rule": "^17.0.0", + "@commitlint/resolve-extends": "^17.1.0", + "@commitlint/types": "^17.0.0", + "@types/node": "^14.0.0", + "chalk": "^4.1.0", + "cosmiconfig": "^7.0.0", + "cosmiconfig-typescript-loader": "^4.0.0", + "lodash": "^4.17.19", + "resolve-from": "^5.0.0", + "ts-node": "^10.8.1", + "typescript": "^4.6.4" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/message": { + "version": "17.2.0", + "resolved": "https://registry.npmjs.org/@commitlint/message/-/message-17.2.0.tgz", + "integrity": "sha512-/4l2KFKxBOuoEn1YAuuNNlAU05Zt7sNsC9H0mPdPm3chOrT4rcX0pOqrQcLtdMrMkJz0gC7b3SF80q2+LtdL9Q==", + "dev": true, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/parse": { + "version": "17.2.0", + "resolved": "https://registry.npmjs.org/@commitlint/parse/-/parse-17.2.0.tgz", + "integrity": "sha512-vLzLznK9Y21zQ6F9hf8D6kcIJRb2haAK5T/Vt1uW2CbHYOIfNsR/hJs0XnF/J9ctM20Tfsqv4zBitbYvVw7F6Q==", + "dev": true, + "dependencies": { + "@commitlint/types": "^17.0.0", + "conventional-changelog-angular": "^5.0.11", + "conventional-commits-parser": "^3.2.2" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/read": { + "version": "17.2.0", + "resolved": "https://registry.npmjs.org/@commitlint/read/-/read-17.2.0.tgz", + "integrity": "sha512-bbblBhrHkjxra3ptJNm0abxu7yeAaxumQ8ZtD6GIVqzURCETCP7Dm0tlVvGRDyXBuqX6lIJxh3W7oyKqllDsHQ==", + "dev": true, + "dependencies": { + "@commitlint/top-level": "^17.0.0", + "@commitlint/types": "^17.0.0", + "fs-extra": "^10.0.0", + "git-raw-commits": "^2.0.0", + "minimist": "^1.2.6" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/resolve-extends": { + "version": "17.1.0", + "resolved": "https://registry.npmjs.org/@commitlint/resolve-extends/-/resolve-extends-17.1.0.tgz", + "integrity": "sha512-jqKm00LJ59T0O8O4bH4oMa4XyJVEOK4GzH8Qye9XKji+Q1FxhZznxMV/bDLyYkzbTodBt9sL0WLql8wMtRTbqQ==", + "dev": true, + "dependencies": { + "@commitlint/config-validator": "^17.1.0", + "@commitlint/types": "^17.0.0", + "import-fresh": "^3.0.0", + "lodash": "^4.17.19", + "resolve-from": "^5.0.0", + "resolve-global": "^1.0.0" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/rules": { + "version": "17.2.0", + "resolved": "https://registry.npmjs.org/@commitlint/rules/-/rules-17.2.0.tgz", + "integrity": "sha512-1YynwD4Eh7HXZNpqG8mtUlL2pSX2jBy61EejYJv4ooZPcg50Ak7LPOyD3a9UZnsE76AXWFBz+yo9Hv4MIpAa0Q==", + "dev": true, + "dependencies": { + "@commitlint/ensure": "^17.0.0", + "@commitlint/message": "^17.2.0", + "@commitlint/to-lines": "^17.0.0", + "@commitlint/types": "^17.0.0", + "execa": "^5.0.0" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/to-lines": { + "version": "17.0.0", + "resolved": "https://registry.npmjs.org/@commitlint/to-lines/-/to-lines-17.0.0.tgz", + "integrity": "sha512-nEi4YEz04Rf2upFbpnEorG8iymyH7o9jYIVFBG1QdzebbIFET3ir+8kQvCZuBE5pKCtViE4XBUsRZz139uFrRQ==", + "dev": true, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/top-level": { + "version": "17.0.0", + "resolved": "https://registry.npmjs.org/@commitlint/top-level/-/top-level-17.0.0.tgz", + "integrity": "sha512-dZrEP1PBJvodNWYPOYiLWf6XZergdksKQaT6i1KSROLdjf5Ai0brLOv5/P+CPxBeoj3vBxK4Ax8H1Pg9t7sHIQ==", + "dev": true, + "dependencies": { + "find-up": "^5.0.0" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@commitlint/types": { + "version": "17.0.0", + "resolved": "https://registry.npmjs.org/@commitlint/types/-/types-17.0.0.tgz", + "integrity": "sha512-hBAw6U+SkAT5h47zDMeOu3HSiD0SODw4Aq7rRNh1ceUmL7GyLKYhPbUvlRWqZ65XjBLPHZhFyQlRaPNz8qvUyQ==", + "dev": true, + "dependencies": { + "chalk": "^4.1.0" + }, + "engines": { + "node": ">=v14" + } + }, + "node_modules/@conventional-commits/parser": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/@conventional-commits/parser/-/parser-0.4.1.tgz", + "integrity": "sha512-H2ZmUVt6q+KBccXfMBhbBF14NlANeqHTXL4qCL6QGbMzrc4HDXyzWuxPxPNbz71f/5UkR5DrycP5VO9u7crahg==", + "dev": true, + "dependencies": { + "unist-util-visit": "^2.0.3", + "unist-util-visit-parents": "^3.1.1" + } + }, + "node_modules/@cspotcode/source-map-support": { + "version": "0.8.1", + "resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz", + "integrity": "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==", + "dev": true, + "dependencies": { + "@jridgewell/trace-mapping": "0.3.9" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/@cspotcode/source-map-support/node_modules/@jridgewell/trace-mapping": { + "version": "0.3.9", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz", + "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.0.3", + "@jridgewell/sourcemap-codec": "^1.4.10" + } + }, + "node_modules/@eslint/eslintrc": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.3.3.tgz", + "integrity": "sha512-uj3pT6Mg+3t39fvLrj8iuCIJ38zKO9FpGtJ4BBJebJhEwjoT+KLVNCcHT5QC9NGRIEi7fZ0ZR8YRb884auB4Lg==", + "dev": true, + "peer": true, "dependencies": { "ajv": "^6.12.4", "debug": "^4.3.2", - "espree": "^9.0.0", - "globals": "^13.9.0", - "ignore": "^4.0.6", + "espree": "^9.4.0", + "globals": "^13.15.0", + "ignore": "^5.2.0", "import-fresh": "^3.2.1", "js-yaml": "^4.1.0", - "minimatch": "^3.0.4", + "minimatch": "^3.1.2", "strip-json-comments": "^3.1.1" }, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - } - }, - "node_modules/@eslint/eslintrc/node_modules/argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "dev": true - }, - "node_modules/@eslint/eslintrc/node_modules/globals": { - "version": "13.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.12.0.tgz", - "integrity": "sha512-uS8X6lSKN2JumVoXrbUz+uG4BYG+eiawqm3qFcT7ammfbUHeCBoJMlHcec/S3krSk73/AE/f0szYFmgAA3kYZg==", - "dev": true, - "dependencies": { - "type-fest": "^0.20.2" - }, - "engines": { - "node": ">=8" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://opencollective.com/eslint" } }, - "node_modules/@eslint/eslintrc/node_modules/js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", + "node_modules/@eslint/eslintrc/node_modules/ajv": { + "version": "6.12.6", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", + "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", "dev": true, + "peer": true, "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, - "node_modules/@eslint/eslintrc/node_modules/type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "dev": true, - "engines": { - "node": ">=10" + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/@eslint/eslintrc/node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "peer": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/@eslint/eslintrc/node_modules/json-schema-traverse": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", + "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", + "dev": true, + "peer": true + }, + "node_modules/@eslint/eslintrc/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "peer": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" } }, "node_modules/@gar/promisify": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@gar/promisify/-/promisify-1.1.2.tgz", - "integrity": "sha512-82cpyJyKRoQoRi+14ibCeGPu0CwypgtBAdBhq1WfvagpCZNKqwXbKwXllYSMG91DhmG4jt9gN8eP6lGOtozuaw==", - "inBundle": true + "version": "1.1.3", + "inBundle": true, + "license": "MIT" }, - "node_modules/@humanwhocodes/config-array": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.6.0.tgz", - "integrity": "sha512-JQlEKbcgEUjBFhLIF4iqM7u/9lwgHRBcpHrmUNCALK0Q3amXN6lxdoXLnF0sm11E9VqTmBALR87IlUg1bZ8A9A==", + "node_modules/@google-automations/git-file-utils": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/@google-automations/git-file-utils/-/git-file-utils-1.2.2.tgz", + "integrity": "sha512-UGZypVMDGFJjVCVHI5yqZsqZtaTJoYVyZJ9IJ1sF02Hh0QbDCJHPmPXUpKnPWt9NG51U4ws+K56c1d8s+omvFw==", "dev": true, "dependencies": { - "@humanwhocodes/object-schema": "^1.2.0", + "@octokit/rest": "19.0.5", + "@octokit/types": "^7.5.1", + "minimatch": "^5.1.0" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/@google-automations/git-file-utils/node_modules/@octokit/openapi-types": { + "version": "13.13.1", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-13.13.1.tgz", + "integrity": "sha512-4EuKSk3N95UBWFau3Bz9b3pheQ8jQYbKmBL5+GSuY8YDPDwu03J4BjI+66yNi8aaX/3h1qDpb0mbBkLdr+cfGQ==", + "dev": true + }, + "node_modules/@google-automations/git-file-utils/node_modules/@octokit/types": { + "version": "7.5.1", + "resolved": "https://registry.npmjs.org/@octokit/types/-/types-7.5.1.tgz", + "integrity": "sha512-Zk4OUMLCSpXNI8KZZn47lVLJSsgMyCimsWWQI5hyjZg7hdYm0kjotaIkbG0Pp8SfU2CofMBzonboTqvzn3FrJA==", + "dev": true, + "dependencies": { + "@octokit/openapi-types": "^13.11.0" + } + }, + "node_modules/@humanwhocodes/config-array": { + "version": "0.11.7", + "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.7.tgz", + "integrity": "sha512-kBbPWzN8oVMLb0hOUYXhmxggL/1cJE6ydvjDIGi9EnAGUyA7cLVKQg+d/Dsm+KZwx2czGHrCmMVLiyg8s5JPKw==", + "dev": true, + "peer": true, + "dependencies": { + "@humanwhocodes/object-schema": "^1.2.1", "debug": "^4.1.1", - "minimatch": "^3.0.4" + "minimatch": "^3.0.5" }, "engines": { "node": ">=10.10.0" } }, + "node_modules/@humanwhocodes/config-array/node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "peer": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/@humanwhocodes/config-array/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "peer": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/@humanwhocodes/module-importer": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", + "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==", + "dev": true, + "peer": true, + "engines": { + "node": ">=12.22" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/nzakas" + } + }, "node_modules/@humanwhocodes/object-schema": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz", "integrity": "sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==", + "dev": true, + "peer": true + }, + "node_modules/@iarna/toml": { + "version": "2.2.5", + "resolved": "https://registry.npmjs.org/@iarna/toml/-/toml-2.2.5.tgz", + "integrity": "sha512-trnsAYxU3xnS1gPHPyU961coFyLkh4gAD/0zQ5mymY4yOZ+CYvsPqUbOFSw0aDM4y0tV7tiFxL/1XfXPNC6IPg==", "dev": true }, "node_modules/@isaacs/string-locale-compare": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@isaacs/string-locale-compare/-/string-locale-compare-1.1.0.tgz", - "integrity": "sha512-SQ7Kzhh9+D+ZW9MA0zkYv3VXhIDNx+LzM6EJ+/65I3QY+enU6Itte7E5XX7EWrqLW2FN4n06GWzBnPoC3th2aQ==", - "inBundle": true + "inBundle": true, + "license": "ISC" }, "node_modules/@istanbuljs/load-nyc-config": { "version": "1.1.0", @@ -672,6 +1160,28 @@ "node": ">=8" } }, + "node_modules/@istanbuljs/load-nyc-config/node_modules/argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "dependencies": { + "sprintf-js": "~1.0.2" + } + }, + "node_modules/@istanbuljs/load-nyc-config/node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, "node_modules/@istanbuljs/load-nyc-config/node_modules/find-up": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", @@ -685,6 +1195,19 @@ "node": ">=8" } }, + "node_modules/@istanbuljs/load-nyc-config/node_modules/js-yaml": { + "version": "3.14.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", + "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", + "dev": true, + "dependencies": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, "node_modules/@istanbuljs/load-nyc-config/node_modules/locate-path": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", @@ -724,33 +1247,6 @@ "node": ">=8" } }, - "node_modules/@istanbuljs/load-nyc-config/node_modules/p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/@istanbuljs/load-nyc-config/node_modules/path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@istanbuljs/load-nyc-config/node_modules/resolve-from": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", - "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/@istanbuljs/schema": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/@istanbuljs/schema/-/schema-0.1.3.tgz", @@ -760,316 +1256,1370 @@ "node": ">=8" } }, - "node_modules/@mdx-js/mdx": { - "version": "1.6.22", - "resolved": "https://registry.npmjs.org/@mdx-js/mdx/-/mdx-1.6.22.tgz", - "integrity": "sha512-AMxuLxPz2j5/6TpF/XSdKpQP1NlG0z11dFOlq+2IP/lSgl11GY8ji6S/rgsViN/L0BDvHvUMruRb7ub+24LUYA==", + "node_modules/@jridgewell/gen-mapping": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.1.1.tgz", + "integrity": "sha512-sQXCasFk+U8lWYEe66WxRDOE9PjVz4vSM51fTu3Hw+ClTpUSQb718772vH3pyS5pShp6lvQM7SxgIDXXXmOX7w==", "dev": true, "dependencies": { - "@babel/core": "7.12.9", - "@babel/plugin-syntax-jsx": "7.12.1", - "@babel/plugin-syntax-object-rest-spread": "7.8.3", - "@mdx-js/util": "1.6.22", - "babel-plugin-apply-mdx-type-prop": "1.6.22", - "babel-plugin-extract-import-names": "1.6.22", - "camelcase-css": "2.0.1", - "detab": "2.0.4", - "hast-util-raw": "6.0.1", - "lodash.uniq": "4.5.0", - "mdast-util-to-hast": "10.0.1", - "remark-footnotes": "2.0.0", - "remark-mdx": "1.6.22", - "remark-parse": "8.0.3", - "remark-squeeze-paragraphs": "4.0.0", - "style-to-object": "0.3.0", - "unified": "9.2.0", - "unist-builder": "2.0.3", - "unist-util-visit": "2.0.3" + "@jridgewell/set-array": "^1.0.0", + "@jridgewell/sourcemap-codec": "^1.4.10" }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "engines": { + "node": ">=6.0.0" } }, - "node_modules/@mdx-js/util": { - "version": "1.6.22", - "resolved": "https://registry.npmjs.org/@mdx-js/util/-/util-1.6.22.tgz", - "integrity": "sha512-H1rQc1ZOHANWBvPcW+JpGwr+juXSxM8Q8YCkm3GhZd8REu1fHR3z99CErO1p9pkcfcxZnMdIZdIsXkOHY0NilA==", + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz", + "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==", "dev": true, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/set-array": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz", + "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==", + "dev": true, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.4.14", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz", + "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==", + "dev": true + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.17", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.17.tgz", + "integrity": "sha512-MCNzAp77qzKca9+W/+I0+sEpaUnZoeasnghNeVc41VZCEKaCH73Vq3BZZ/SzWIgrqE4H4ceI+p+b6C0mHf9T4g==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "3.1.0", + "@jridgewell/sourcemap-codec": "1.4.14" + } + }, + "node_modules/@lerna/child-process": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@lerna/child-process/-/child-process-4.0.0.tgz", + "integrity": "sha512-XtCnmCT9eyVsUUHx6y/CTBYdV9g2Cr/VxyseTWBgfIur92/YKClfEtJTbOh94jRT62hlKLqSvux/UhxXVh613Q==", + "dev": true, + "dependencies": { + "chalk": "^4.1.0", + "execa": "^5.0.0", + "strong-log-transformer": "^2.1.0" + }, + "engines": { + "node": ">= 10.18.0" + } + }, + "node_modules/@lerna/collect-updates": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@lerna/collect-updates/-/collect-updates-4.0.0.tgz", + "integrity": "sha512-bnNGpaj4zuxsEkyaCZLka9s7nMs58uZoxrRIPJ+nrmrZYp1V5rrd+7/NYTuunOhY2ug1sTBvTAxj3NZQ+JKnOw==", + "dev": true, + "dependencies": { + "@lerna/child-process": "4.0.0", + "@lerna/describe-ref": "4.0.0", + "minimatch": "^3.0.4", + "npmlog": "^4.1.2", + "slash": "^3.0.0" + }, + "engines": { + "node": ">= 10.18.0" + } + }, + "node_modules/@lerna/collect-updates/node_modules/ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/collect-updates/node_modules/aproba": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", + "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==", + "dev": true + }, + "node_modules/@lerna/collect-updates/node_modules/are-we-there-yet": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.7.tgz", + "integrity": "sha512-nxwy40TuMiUGqMyRHgCSWZ9FM4VAoRP4xUYSTv5ImRog+h9yISPbVH7H8fASCIzYn9wlEv4zvFL7uKDMCFQm3g==", + "dev": true, + "dependencies": { + "delegates": "^1.0.0", + "readable-stream": "^2.0.6" + } + }, + "node_modules/@lerna/collect-updates/node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/@lerna/collect-updates/node_modules/gauge": { + "version": "2.7.4", + "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", + "integrity": "sha512-14x4kjc6lkD3ltw589k0NrPD6cCNTD6CWoVUNpB85+DrtONoZn+Rug6xZU5RvSC4+TZPxA5AnBibQYAvZn41Hg==", + "dev": true, + "dependencies": { + "aproba": "^1.0.3", + "console-control-strings": "^1.0.0", + "has-unicode": "^2.0.0", + "object-assign": "^4.1.0", + "signal-exit": "^3.0.0", + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wide-align": "^1.1.0" + } + }, + "node_modules/@lerna/collect-updates/node_modules/is-fullwidth-code-point": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", + "integrity": "sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==", + "dev": true, + "dependencies": { + "number-is-nan": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/collect-updates/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/@lerna/collect-updates/node_modules/npmlog": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz", + "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==", + "dev": true, + "dependencies": { + "are-we-there-yet": "~1.1.2", + "console-control-strings": "~1.1.0", + "gauge": "~2.7.3", + "set-blocking": "~2.0.0" + } + }, + "node_modules/@lerna/collect-updates/node_modules/readable-stream": { + "version": "2.3.7", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", + "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", + "dev": true, + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/@lerna/collect-updates/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true + }, + "node_modules/@lerna/collect-updates/node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dev": true, + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/@lerna/collect-updates/node_modules/string-width": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "integrity": "sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==", + "dev": true, + "dependencies": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/collect-updates/node_modules/strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "dev": true, + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/describe-ref": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@lerna/describe-ref/-/describe-ref-4.0.0.tgz", + "integrity": "sha512-eTU5+xC4C5Gcgz+Ey4Qiw9nV2B4JJbMulsYJMW8QjGcGh8zudib7Sduj6urgZXUYNyhYpRs+teci9M2J8u+UvQ==", + "dev": true, + "dependencies": { + "@lerna/child-process": "4.0.0", + "npmlog": "^4.1.2" + }, + "engines": { + "node": ">= 10.18.0" + } + }, + "node_modules/@lerna/describe-ref/node_modules/ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/describe-ref/node_modules/aproba": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", + "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==", + "dev": true + }, + "node_modules/@lerna/describe-ref/node_modules/are-we-there-yet": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.7.tgz", + "integrity": "sha512-nxwy40TuMiUGqMyRHgCSWZ9FM4VAoRP4xUYSTv5ImRog+h9yISPbVH7H8fASCIzYn9wlEv4zvFL7uKDMCFQm3g==", + "dev": true, + "dependencies": { + "delegates": "^1.0.0", + "readable-stream": "^2.0.6" + } + }, + "node_modules/@lerna/describe-ref/node_modules/gauge": { + "version": "2.7.4", + "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", + "integrity": "sha512-14x4kjc6lkD3ltw589k0NrPD6cCNTD6CWoVUNpB85+DrtONoZn+Rug6xZU5RvSC4+TZPxA5AnBibQYAvZn41Hg==", + "dev": true, + "dependencies": { + "aproba": "^1.0.3", + "console-control-strings": "^1.0.0", + "has-unicode": "^2.0.0", + "object-assign": "^4.1.0", + "signal-exit": "^3.0.0", + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wide-align": "^1.1.0" + } + }, + "node_modules/@lerna/describe-ref/node_modules/is-fullwidth-code-point": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", + "integrity": "sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==", + "dev": true, + "dependencies": { + "number-is-nan": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/describe-ref/node_modules/npmlog": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz", + "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==", + "dev": true, + "dependencies": { + "are-we-there-yet": "~1.1.2", + "console-control-strings": "~1.1.0", + "gauge": "~2.7.3", + "set-blocking": "~2.0.0" + } + }, + "node_modules/@lerna/describe-ref/node_modules/readable-stream": { + "version": "2.3.7", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", + "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", + "dev": true, + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/@lerna/describe-ref/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true + }, + "node_modules/@lerna/describe-ref/node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dev": true, + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/@lerna/describe-ref/node_modules/string-width": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "integrity": "sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==", + "dev": true, + "dependencies": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/describe-ref/node_modules/strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "dev": true, + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/package": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@lerna/package/-/package-4.0.0.tgz", + "integrity": "sha512-l0M/izok6FlyyitxiQKr+gZLVFnvxRQdNhzmQ6nRnN9dvBJWn+IxxpM+cLqGACatTnyo9LDzNTOj2Db3+s0s8Q==", + "dev": true, + "dependencies": { + "load-json-file": "^6.2.0", + "npm-package-arg": "^8.1.0", + "write-pkg": "^4.0.0" + }, + "engines": { + "node": ">= 10.18.0" + } + }, + "node_modules/@lerna/package-graph": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@lerna/package-graph/-/package-graph-4.0.0.tgz", + "integrity": "sha512-QED2ZCTkfXMKFoTGoccwUzjHtZMSf3UKX14A4/kYyBms9xfFsesCZ6SLI5YeySEgcul8iuIWfQFZqRw+Qrjraw==", + "dev": true, + "dependencies": { + "@lerna/prerelease-id-from-version": "4.0.0", + "@lerna/validation-error": "4.0.0", + "npm-package-arg": "^8.1.0", + "npmlog": "^4.1.2", + "semver": "^7.3.4" + }, + "engines": { + "node": ">= 10.18.0" + } + }, + "node_modules/@lerna/package-graph/node_modules/ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/package-graph/node_modules/aproba": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", + "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==", + "dev": true + }, + "node_modules/@lerna/package-graph/node_modules/are-we-there-yet": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.7.tgz", + "integrity": "sha512-nxwy40TuMiUGqMyRHgCSWZ9FM4VAoRP4xUYSTv5ImRog+h9yISPbVH7H8fASCIzYn9wlEv4zvFL7uKDMCFQm3g==", + "dev": true, + "dependencies": { + "delegates": "^1.0.0", + "readable-stream": "^2.0.6" + } + }, + "node_modules/@lerna/package-graph/node_modules/builtins": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/builtins/-/builtins-1.0.3.tgz", + "integrity": "sha512-uYBjakWipfaO/bXI7E8rq6kpwHRZK5cNYrUv2OzZSI/FvmdMyXJ2tG9dKcjEC5YHmHpUAwsargWIZNWdxb/bnQ==", + "dev": true + }, + "node_modules/@lerna/package-graph/node_modules/gauge": { + "version": "2.7.4", + "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", + "integrity": "sha512-14x4kjc6lkD3ltw589k0NrPD6cCNTD6CWoVUNpB85+DrtONoZn+Rug6xZU5RvSC4+TZPxA5AnBibQYAvZn41Hg==", + "dev": true, + "dependencies": { + "aproba": "^1.0.3", + "console-control-strings": "^1.0.0", + "has-unicode": "^2.0.0", + "object-assign": "^4.1.0", + "signal-exit": "^3.0.0", + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wide-align": "^1.1.0" + } + }, + "node_modules/@lerna/package-graph/node_modules/hosted-git-info": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", + "integrity": "sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==", + "dev": true, + "dependencies": { + "lru-cache": "^6.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@lerna/package-graph/node_modules/is-fullwidth-code-point": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", + "integrity": "sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==", + "dev": true, + "dependencies": { + "number-is-nan": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/package-graph/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@lerna/package-graph/node_modules/npm-package-arg": { + "version": "8.1.5", + "resolved": "https://registry.npmjs.org/npm-package-arg/-/npm-package-arg-8.1.5.tgz", + "integrity": "sha512-LhgZrg0n0VgvzVdSm1oiZworPbTxYHUJCgtsJW8mGvlDpxTM1vSJc3m5QZeUkhAHIzbz3VCHd/R4osi1L1Tg/Q==", + "dev": true, + "dependencies": { + "hosted-git-info": "^4.0.1", + "semver": "^7.3.4", + "validate-npm-package-name": "^3.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@lerna/package-graph/node_modules/npmlog": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz", + "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==", + "dev": true, + "dependencies": { + "are-we-there-yet": "~1.1.2", + "console-control-strings": "~1.1.0", + "gauge": "~2.7.3", + "set-blocking": "~2.0.0" + } + }, + "node_modules/@lerna/package-graph/node_modules/readable-stream": { + "version": "2.3.7", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", + "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", + "dev": true, + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/@lerna/package-graph/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true + }, + "node_modules/@lerna/package-graph/node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dev": true, + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/@lerna/package-graph/node_modules/string-width": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "integrity": "sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==", + "dev": true, + "dependencies": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/package-graph/node_modules/strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "dev": true, + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/package-graph/node_modules/validate-npm-package-name": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/validate-npm-package-name/-/validate-npm-package-name-3.0.0.tgz", + "integrity": "sha512-M6w37eVCMMouJ9V/sdPGnC5H4uDr73/+xdq0FBLO3TFFX1+7wiUY6Es328NN+y43tmY+doUdN9g9J21vqB7iLw==", + "dev": true, + "dependencies": { + "builtins": "^1.0.3" + } + }, + "node_modules/@lerna/package/node_modules/builtins": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/builtins/-/builtins-1.0.3.tgz", + "integrity": "sha512-uYBjakWipfaO/bXI7E8rq6kpwHRZK5cNYrUv2OzZSI/FvmdMyXJ2tG9dKcjEC5YHmHpUAwsargWIZNWdxb/bnQ==", + "dev": true + }, + "node_modules/@lerna/package/node_modules/hosted-git-info": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", + "integrity": "sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==", + "dev": true, + "dependencies": { + "lru-cache": "^6.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@lerna/package/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@lerna/package/node_modules/npm-package-arg": { + "version": "8.1.5", + "resolved": "https://registry.npmjs.org/npm-package-arg/-/npm-package-arg-8.1.5.tgz", + "integrity": "sha512-LhgZrg0n0VgvzVdSm1oiZworPbTxYHUJCgtsJW8mGvlDpxTM1vSJc3m5QZeUkhAHIzbz3VCHd/R4osi1L1Tg/Q==", + "dev": true, + "dependencies": { + "hosted-git-info": "^4.0.1", + "semver": "^7.3.4", + "validate-npm-package-name": "^3.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@lerna/package/node_modules/validate-npm-package-name": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/validate-npm-package-name/-/validate-npm-package-name-3.0.0.tgz", + "integrity": "sha512-M6w37eVCMMouJ9V/sdPGnC5H4uDr73/+xdq0FBLO3TFFX1+7wiUY6Es328NN+y43tmY+doUdN9g9J21vqB7iLw==", + "dev": true, + "dependencies": { + "builtins": "^1.0.3" + } + }, + "node_modules/@lerna/prerelease-id-from-version": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@lerna/prerelease-id-from-version/-/prerelease-id-from-version-4.0.0.tgz", + "integrity": "sha512-GQqguzETdsYRxOSmdFZ6zDBXDErIETWOqomLERRY54f4p+tk4aJjoVdd9xKwehC9TBfIFvlRbL1V9uQGHh1opg==", + "dev": true, + "dependencies": { + "semver": "^7.3.4" + }, + "engines": { + "node": ">= 10.18.0" + } + }, + "node_modules/@lerna/query-graph": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@lerna/query-graph/-/query-graph-4.0.0.tgz", + "integrity": "sha512-YlP6yI3tM4WbBmL9GCmNDoeQyzcyg1e4W96y/PKMZa5GbyUvkS2+Jc2kwPD+5KcXou3wQZxSPzR3Te5OenaDdg==", + "dev": true, + "dependencies": { + "@lerna/package-graph": "4.0.0" + }, + "engines": { + "node": ">= 10.18.0" + } + }, + "node_modules/@lerna/run-topologically": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@lerna/run-topologically/-/run-topologically-4.0.0.tgz", + "integrity": "sha512-EVZw9hGwo+5yp+VL94+NXRYisqgAlj0jWKWtAIynDCpghRxCE5GMO3xrQLmQgqkpUl9ZxQFpICgYv5DW4DksQA==", + "dev": true, + "dependencies": { + "@lerna/query-graph": "4.0.0", + "p-queue": "^6.6.2" + }, + "engines": { + "node": ">= 10.18.0" + } + }, + "node_modules/@lerna/validation-error": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@lerna/validation-error/-/validation-error-4.0.0.tgz", + "integrity": "sha512-1rBOM5/koiVWlRi3V6dB863E1YzJS8v41UtsHgMr6gB2ncJ2LsQtMKlJpi3voqcgh41H8UsPXR58RrrpPpufyw==", + "dev": true, + "dependencies": { + "npmlog": "^4.1.2" + }, + "engines": { + "node": ">= 10.18.0" + } + }, + "node_modules/@lerna/validation-error/node_modules/ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/validation-error/node_modules/aproba": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", + "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==", + "dev": true + }, + "node_modules/@lerna/validation-error/node_modules/are-we-there-yet": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.7.tgz", + "integrity": "sha512-nxwy40TuMiUGqMyRHgCSWZ9FM4VAoRP4xUYSTv5ImRog+h9yISPbVH7H8fASCIzYn9wlEv4zvFL7uKDMCFQm3g==", + "dev": true, + "dependencies": { + "delegates": "^1.0.0", + "readable-stream": "^2.0.6" + } + }, + "node_modules/@lerna/validation-error/node_modules/gauge": { + "version": "2.7.4", + "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", + "integrity": "sha512-14x4kjc6lkD3ltw589k0NrPD6cCNTD6CWoVUNpB85+DrtONoZn+Rug6xZU5RvSC4+TZPxA5AnBibQYAvZn41Hg==", + "dev": true, + "dependencies": { + "aproba": "^1.0.3", + "console-control-strings": "^1.0.0", + "has-unicode": "^2.0.0", + "object-assign": "^4.1.0", + "signal-exit": "^3.0.0", + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wide-align": "^1.1.0" + } + }, + "node_modules/@lerna/validation-error/node_modules/is-fullwidth-code-point": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", + "integrity": "sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==", + "dev": true, + "dependencies": { + "number-is-nan": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/validation-error/node_modules/npmlog": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz", + "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==", + "dev": true, + "dependencies": { + "are-we-there-yet": "~1.1.2", + "console-control-strings": "~1.1.0", + "gauge": "~2.7.3", + "set-blocking": "~2.0.0" + } + }, + "node_modules/@lerna/validation-error/node_modules/readable-stream": { + "version": "2.3.7", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", + "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", + "dev": true, + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/@lerna/validation-error/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true + }, + "node_modules/@lerna/validation-error/node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dev": true, + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/@lerna/validation-error/node_modules/string-width": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "integrity": "sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==", + "dev": true, + "dependencies": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@lerna/validation-error/node_modules/strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "dev": true, + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/@nodelib/fs.scandir": { + "version": "2.1.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", + "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", + "dev": true, + "peer": true, + "dependencies": { + "@nodelib/fs.stat": "2.0.5", + "run-parallel": "^1.1.9" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.stat": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", + "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", + "dev": true, + "peer": true, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.walk": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", + "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", + "dev": true, + "peer": true, + "dependencies": { + "@nodelib/fs.scandir": "2.1.5", + "fastq": "^1.6.0" + }, + "engines": { + "node": ">= 8" } }, "node_modules/@npmcli/arborist": { "resolved": "workspaces/arborist", "link": true }, - "node_modules/@npmcli/ci-detect": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/ci-detect/-/ci-detect-2.0.0.tgz", - "integrity": "sha512-8yQtQ9ArHh/TzdUDKQwEvwCgpDuhSWTDAbiKMl3854PcT+Dk4UmWaiawuFTLy9n5twzXOBXVflWe+90/ffXQrA==", - "inBundle": true, - "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - } - }, "node_modules/@npmcli/config": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/config/-/config-3.0.0.tgz", - "integrity": "sha512-2cYe2MCGintq1s6izbLYO2gAHZwNFQ92lIb5QhtpRizwHwqrV9v4+xNpvx1EBaEaqTHFR4QuozgZLA1scao/5Q==", - "inBundle": true, - "dependencies": { - "@npmcli/map-workspaces": "^2.0.0", - "ini": "^2.0.0", - "mkdirp-infer-owner": "^2.0.0", - "nopt": "^5.0.0", - "read-package-json-fast": "^2.0.3", - "semver": "^7.3.4", - "walk-up-path": "^1.0.0" - }, - "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - } + "resolved": "workspaces/config", + "link": true }, "node_modules/@npmcli/disparity-colors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@npmcli/disparity-colors/-/disparity-colors-1.0.1.tgz", - "integrity": "sha512-kQ1aCTTU45mPXN+pdAaRxlxr3OunkyztjbbxDY/aIcPS5CnCUrx+1+NvA6pTcYR7wmLZe37+Mi5v3nfbwPxq3A==", + "version": "3.0.0", + "license": "ISC", "dependencies": { "ansi-styles": "^4.3.0" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, + "node_modules/@npmcli/docs": { + "resolved": "docs", + "link": true + }, "node_modules/@npmcli/eslint-config": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/eslint-config/-/eslint-config-2.0.0.tgz", - "integrity": "sha512-/QSD5YMsrRum8rqmq7gsna59mvFgtyUcoUawcOHS0hjCQ9kwHywFLG3cuXy98s4dpIukau08inkWX/JTeXy/1Q==", + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@npmcli/eslint-config/-/eslint-config-4.0.1.tgz", + "integrity": "sha512-bHsOOLO2UiMb8G4Q968VJjlO4QWXf3SivgN/rQKsbzcS37S7aFWwPph3PwBaTF6O0OlUvjLiM1mzXlz/1jGV9Q==", "dev": true, "dependencies": { - "which": "^2.0.2" + "which": "^3.0.0" }, "bin": { "lint": "bin/index.js" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "peerDependencies": { - "eslint": ">= 8", - "eslint-plugin-node": "^11.1.0" + "eslint": "^8.13.0", + "eslint-plugin-import": "^2.26.0", + "eslint-plugin-node": "^11.1.0", + "eslint-plugin-promise": "^6.0.0" } }, "node_modules/@npmcli/fs": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@npmcli/fs/-/fs-1.1.0.tgz", - "integrity": "sha512-VhP1qZLXcrXRIaPoqb4YA55JQxLNF3jNR4T55IdOJa3+IFJKNYHtPvtXx8slmeMavj37vCzCfrqQM1vWLsYKLA==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@npmcli/fs/-/fs-3.1.0.tgz", + "integrity": "sha512-7kZUAaLscfgbwBQRbvdMYaZOWyMEcPTH/tJjnyAWJ/dvvs9Ef+CERx/qJb9GExJpl1qipaDGn7KqHnFGGixd0w==", "inBundle": true, "dependencies": { - "@gar/promisify": "^1.0.1", "semver": "^7.3.5" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/@npmcli/git": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/@npmcli/git/-/git-2.1.0.tgz", - "integrity": "sha512-/hBFX/QG1b+N7PZBFs0bi+evgRZcK9nWBxQKZkGoXUT5hJSwl5c4d7y8/hm+NQZRPhQ67RzFaj5UM9YeyKoryw==", + "version": "4.0.3", "inBundle": true, + "license": "ISC", "dependencies": { - "@npmcli/promise-spawn": "^1.3.2", - "lru-cache": "^6.0.0", + "@npmcli/promise-spawn": "^6.0.0", + "lru-cache": "^7.4.4", "mkdirp": "^1.0.4", - "npm-pick-manifest": "^6.1.1", + "npm-pick-manifest": "^8.0.0", + "proc-log": "^3.0.0", "promise-inflight": "^1.0.1", "promise-retry": "^2.0.1", "semver": "^7.3.5", - "which": "^2.0.2" + "which": "^3.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/@npmcli/installed-package-contents": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/@npmcli/installed-package-contents/-/installed-package-contents-1.0.7.tgz", - "integrity": "sha512-9rufe0wnJusCQoLpV9ZPKIVP55itrM5BxOXs10DmdbRfgWtHy1LDyskbwRnBghuB0PrF7pNPOqREVtpz4HqzKw==", + "version": "2.0.1", "inBundle": true, + "license": "ISC", "dependencies": { - "npm-bundled": "^1.1.1", - "npm-normalize-package-bin": "^1.0.1" + "npm-bundled": "^3.0.0", + "npm-normalize-package-bin": "^3.0.0" }, "bin": { - "installed-package-contents": "index.js" + "installed-package-contents": "lib/index.js" }, "engines": { - "node": ">= 10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/@npmcli/map-workspaces": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/map-workspaces/-/map-workspaces-2.0.0.tgz", - "integrity": "sha512-QBJfpCY1NOAkkW3lFfru9VTdqvMB2TN0/vrevl5xBCv5Fi0XDVcA6rqqSau4Ysi4Iw3fBzyXV7hzyTBDfadf7g==", + "version": "3.0.0", "inBundle": true, + "license": "ISC", "dependencies": { "@npmcli/name-from-folder": "^1.0.1", - "glob": "^7.1.6", - "minimatch": "^3.0.4", - "read-package-json-fast": "^2.0.1" + "glob": "^8.0.1", + "minimatch": "^5.0.1", + "read-package-json-fast": "^3.0.0" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/@npmcli/metavuln-calculator": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/metavuln-calculator/-/metavuln-calculator-2.0.0.tgz", - "integrity": "sha512-VVW+JhWCKRwCTE+0xvD6p3uV4WpqocNYYtzyvenqL/u1Q3Xx6fGTJ+6UoIoii07fbuEO9U3IIyuGY0CYHDv1sg==", + "version": "5.0.0", + "license": "ISC", "dependencies": { - "cacache": "^15.0.5", - "json-parse-even-better-errors": "^2.3.1", - "pacote": "^12.0.0", - "semver": "^7.3.2" + "cacache": "^17.0.0", + "json-parse-even-better-errors": "^3.0.0", + "pacote": "^15.0.0", + "semver": "^7.3.5" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/@npmcli/move-file": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@npmcli/move-file/-/move-file-1.1.2.tgz", - "integrity": "sha512-1SUf/Cg2GzGDyaf15aR9St9TWlb+XvbZXWpDx8YKs7MLzMH/BCeopv+y9vzrzgkfykCGuWOlSu3mZhj2+FQcrg==", - "inBundle": true, - "dependencies": { - "mkdirp": "^1.0.4", - "rimraf": "^3.0.2" - }, - "engines": { - "node": ">=10" - } + "node_modules/@npmcli/mock-registry": { + "resolved": "mock-registry", + "link": true }, "node_modules/@npmcli/name-from-folder": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@npmcli/name-from-folder/-/name-from-folder-1.0.1.tgz", - "integrity": "sha512-qq3oEfcLFwNfEYOQ8HLimRGKlD8WSeGEdtUa7hmzpR8Sa7haL1KVQrvgO6wqMjhWFFVjgtrh1gIxDz+P8sjUaA==", - "inBundle": true + "inBundle": true, + "license": "ISC" }, "node_modules/@npmcli/node-gyp": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@npmcli/node-gyp/-/node-gyp-1.0.3.tgz", - "integrity": "sha512-fnkhw+fmX65kiLqk6E3BFLXNC26rUhK90zVwe2yncPliVT/Qos3xjhTLE59Df8KnPlcwIERXKVlU1bXoUQ+liA==", - "inBundle": true + "version": "3.0.0", + "inBundle": true, + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } }, "node_modules/@npmcli/package-json": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@npmcli/package-json/-/package-json-1.0.1.tgz", - "integrity": "sha512-y6jnu76E9C23osz8gEMBayZmaZ69vFOIk8vR1FJL/wbEJ54+9aVG9rLTjQKSXfgYZEr50nw1txBBFfBZZe+bYg==", + "version": "3.0.0", "inBundle": true, + "license": "ISC", "dependencies": { - "json-parse-even-better-errors": "^2.3.1" + "json-parse-even-better-errors": "^3.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/@npmcli/promise-spawn": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/@npmcli/promise-spawn/-/promise-spawn-1.3.2.tgz", - "integrity": "sha512-QyAGYo/Fbj4MXeGdJcFzZ+FkDkomfRBrPM+9QYJSg+PxgAUL+LU3FneQk37rKR2/zjqkCV1BLHccX98wRXG3Sg==", + "version": "6.0.1", "inBundle": true, + "license": "ISC", "dependencies": { - "infer-owner": "^1.0.4" + "which": "^3.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/@npmcli/query": { + "version": "3.0.0", + "license": "ISC", + "dependencies": { + "postcss-selector-parser": "^6.0.10" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/@npmcli/run-script": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/run-script/-/run-script-2.0.0.tgz", - "integrity": "sha512-fSan/Pu11xS/TdaTpTB0MRn9guwGU8dye+x56mEVgBEd/QsybBbYcAL0phPXi8SGWFEChkQd6M9qL4y6VOpFig==", + "version": "6.0.0", "inBundle": true, + "license": "ISC", "dependencies": { - "@npmcli/node-gyp": "^1.0.2", - "@npmcli/promise-spawn": "^1.3.2", - "node-gyp": "^8.2.0", - "read-package-json-fast": "^2.0.1" + "@npmcli/node-gyp": "^3.0.0", + "@npmcli/promise-spawn": "^6.0.0", + "node-gyp": "^9.0.0", + "read-package-json-fast": "^3.0.0", + "which": "^3.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, + "node_modules/@npmcli/smoke-tests": { + "resolved": "smoke-tests", + "link": true + }, "node_modules/@npmcli/template-oss": { - "version": "2.4.3", - "resolved": "https://registry.npmjs.org/@npmcli/template-oss/-/template-oss-2.4.3.tgz", - "integrity": "sha512-y+efKAT2WTw3c7ShDxpF9HOPH3XmruO0TPJlJrxMaJ7yPZ/vrrRcGCP00gOr4QHVFtbmfXVMU+kuVIkkKJt7xg==", + "version": "4.11.0", + "resolved": "https://registry.npmjs.org/@npmcli/template-oss/-/template-oss-4.11.0.tgz", + "integrity": "sha512-nvZqRxT9AFf56Fj07v1yG9AQVOTNn82ysMVI67IzpktunKFHmZ5Tp8P/al5pPik/nYQ4AieEyh7XC2dMro4moA==", "dev": true, "hasInstallScript": true, "dependencies": { - "@npmcli/fs": "^1.0.0", - "@npmcli/map-workspaces": "^2.0.0", - "@npmcli/package-json": "^1.0.1", - "json-parse-even-better-errors": "^2.3.1", - "which": "^2.0.2" + "@actions/core": "^1.9.1", + "@commitlint/cli": "^17.1.1", + "@commitlint/config-conventional": "^17.1.0", + "@isaacs/string-locale-compare": "^1.1.0", + "@npmcli/arborist": "^6.0.0", + "@npmcli/git": "^4.0.0", + "@npmcli/map-workspaces": "^3.0.0", + "@npmcli/package-json": "^3.0.0", + "@octokit/rest": "^19.0.4", + "diff": "^5.0.0", + "glob": "^8.0.1", + "handlebars": "^4.7.7", + "hosted-git-info": "^6.0.0", + "ini": "^3.0.1", + "json-parse-even-better-errors": "^3.0.0", + "just-deep-map-values": "^1.1.1", + "just-diff": "^5.0.1", + "lodash": "^4.17.21", + "npm-package-arg": "^10.0.0", + "proc-log": "^3.0.0", + "release-please": "npm:@npmcli/release-please@^14.2.6", + "semver": "^7.3.5", + "yaml": "^2.1.1" }, "bin": { - "npm-template-check": "bin/npm-template-check.js" + "template-oss-apply": "bin/apply.js", + "template-oss-check": "bin/check.js", + "template-oss-release-manager": "bin/release-manager.js", + "template-oss-release-please": "bin/release-please.js" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/@octokit/auth-token": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-3.0.2.tgz", + "integrity": "sha512-pq7CwIMV1kmzkFTimdwjAINCXKTajZErLB4wMLYapR2nuB/Jpr66+05wOTZMSCBXP6n4DdDWT2W19Bm17vU69Q==", + "dev": true, + "dependencies": { + "@octokit/types": "^8.0.0" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/@octokit/core": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/@octokit/core/-/core-4.1.0.tgz", + "integrity": "sha512-Czz/59VefU+kKDy+ZfDwtOIYIkFjExOKf+HA92aiTZJ6EfWpFzYQWw0l54ji8bVmyhc+mGaLUbSUmXazG7z5OQ==", + "dev": true, + "dependencies": { + "@octokit/auth-token": "^3.0.0", + "@octokit/graphql": "^5.0.0", + "@octokit/request": "^6.0.0", + "@octokit/request-error": "^3.0.0", + "@octokit/types": "^8.0.0", + "before-after-hook": "^2.2.0", + "universal-user-agent": "^6.0.0" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/@octokit/endpoint": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-7.0.3.tgz", + "integrity": "sha512-57gRlb28bwTsdNXq+O3JTQ7ERmBTuik9+LelgcLIVfYwf235VHbN9QNo4kXExtp/h8T423cR5iJThKtFYxC7Lw==", + "dev": true, + "dependencies": { + "@octokit/types": "^8.0.0", + "is-plain-object": "^5.0.0", + "universal-user-agent": "^6.0.0" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/@octokit/graphql": { + "version": "5.0.4", + "resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-5.0.4.tgz", + "integrity": "sha512-amO1M5QUQgYQo09aStR/XO7KAl13xpigcy/kI8/N1PnZYSS69fgte+xA4+c2DISKqUZfsh0wwjc2FaCt99L41A==", + "dev": true, + "dependencies": { + "@octokit/request": "^6.0.0", + "@octokit/types": "^8.0.0", + "universal-user-agent": "^6.0.0" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/@octokit/openapi-types": { + "version": "14.0.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-14.0.0.tgz", + "integrity": "sha512-HNWisMYlR8VCnNurDU6os2ikx0s0VyEjDYHNS/h4cgb8DeOxQ0n72HyinUtdDVxJhFy3FWLGl0DJhfEWk3P5Iw==", + "dev": true + }, + "node_modules/@octokit/plugin-paginate-rest": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-5.0.1.tgz", + "integrity": "sha512-7A+rEkS70pH36Z6JivSlR7Zqepz3KVucEFVDnSrgHXzG7WLAzYwcHZbKdfTXHwuTHbkT1vKvz7dHl1+HNf6Qyw==", + "dev": true, + "dependencies": { + "@octokit/types": "^8.0.0" + }, + "engines": { + "node": ">= 14" }, "peerDependencies": { - "@npmcli/eslint-config": "^2.0.0", - "tap": "^15.0.9" + "@octokit/core": ">=4" + } + }, + "node_modules/@octokit/plugin-request-log": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@octokit/plugin-request-log/-/plugin-request-log-1.0.4.tgz", + "integrity": "sha512-mLUsMkgP7K/cnFEw07kWqXGF5LKrOkD+lhCrKvPHXWDywAwuDUeDwWBpc69XK3pNX0uKiVt8g5z96PJ6z9xCFA==", + "dev": true, + "peerDependencies": { + "@octokit/core": ">=3" + } + }, + "node_modules/@octokit/plugin-rest-endpoint-methods": { + "version": "6.7.0", + "resolved": "https://registry.npmjs.org/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-6.7.0.tgz", + "integrity": "sha512-orxQ0fAHA7IpYhG2flD2AygztPlGYNAdlzYz8yrD8NDgelPfOYoRPROfEyIe035PlxvbYrgkfUZIhSBKju/Cvw==", + "dev": true, + "dependencies": { + "@octokit/types": "^8.0.0", + "deprecation": "^2.3.1" + }, + "engines": { + "node": ">= 14" + }, + "peerDependencies": { + "@octokit/core": ">=3" + } + }, + "node_modules/@octokit/request": { + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/@octokit/request/-/request-6.2.2.tgz", + "integrity": "sha512-6VDqgj0HMc2FUX2awIs+sM6OwLgwHvAi4KCK3mT2H2IKRt6oH9d0fej5LluF5mck1lRR/rFWN0YIDSYXYSylbw==", + "dev": true, + "dependencies": { + "@octokit/endpoint": "^7.0.0", + "@octokit/request-error": "^3.0.0", + "@octokit/types": "^8.0.0", + "is-plain-object": "^5.0.0", + "node-fetch": "^2.6.7", + "universal-user-agent": "^6.0.0" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/@octokit/request-error": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-3.0.2.tgz", + "integrity": "sha512-WMNOFYrSaX8zXWoJg9u/pKgWPo94JXilMLb2VManNOby9EZxrQaBe/QSC4a1TzpAlpxofg2X/jMnCyZgL6y7eg==", + "dev": true, + "dependencies": { + "@octokit/types": "^8.0.0", + "deprecation": "^2.0.0", + "once": "^1.4.0" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/@octokit/rest": { + "version": "19.0.5", + "resolved": "https://registry.npmjs.org/@octokit/rest/-/rest-19.0.5.tgz", + "integrity": "sha512-+4qdrUFq2lk7Va+Qff3ofREQWGBeoTKNqlJO+FGjFP35ZahP+nBenhZiGdu8USSgmq4Ky3IJ/i4u0xbLqHaeow==", + "dev": true, + "dependencies": { + "@octokit/core": "^4.1.0", + "@octokit/plugin-paginate-rest": "^5.0.0", + "@octokit/plugin-request-log": "^1.0.4", + "@octokit/plugin-rest-endpoint-methods": "^6.7.0" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/@octokit/types": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/@octokit/types/-/types-8.0.0.tgz", + "integrity": "sha512-65/TPpOJP1i3K4lBJMnWqPUJ6zuOtzhtagDvydAWbEXpbFYA0oMKKyLb95NFZZP0lSh/4b6K+DQlzvYQJQQePg==", + "dev": true, + "dependencies": { + "@octokit/openapi-types": "^14.0.0" } }, "node_modules/@tootallnate/once": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-2.0.0.tgz", - "integrity": "sha512-XCuKFP5PS55gnMVu3dty8KPatLqUoy/ZYzDzAGCQ8JNFCkLXzmI7vNHCR+XpbZaMWQK/vQubr7PkYq8g470J/A==", "inBundle": true, + "license": "MIT", "engines": { "node": ">= 10" } }, + "node_modules/@tsconfig/node10": { + "version": "1.0.9", + "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz", + "integrity": "sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==", + "dev": true + }, + "node_modules/@tsconfig/node12": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz", + "integrity": "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==", + "dev": true + }, + "node_modules/@tsconfig/node14": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz", + "integrity": "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==", + "dev": true + }, + "node_modules/@tsconfig/node16": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.3.tgz", + "integrity": "sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ==", + "dev": true + }, + "node_modules/@types/debug": { + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/@types/debug/-/debug-4.1.7.tgz", + "integrity": "sha512-9AonUzyTjXXhEOa0DnqpzZi6VHlqKMswga9EXjpXnnqxwLtdvPPtlO8evrI5D9S6asFRCQ6v+wpiUKbw+vKqyg==", + "dev": true, + "dependencies": { + "@types/ms": "*" + } + }, "node_modules/@types/hast": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/@types/hast/-/hast-2.3.1.tgz", - "integrity": "sha512-viwwrB+6xGzw+G1eWpF9geV3fnsDgXqHG+cqgiHrvQfDUW5hzhCyV7Sy3UJxhfRFBsgky2SSW33qi/YrIkjX5Q==", + "version": "2.3.4", + "resolved": "https://registry.npmjs.org/@types/hast/-/hast-2.3.4.tgz", + "integrity": "sha512-wLEm0QvaoawEDoTRwzTXp4b4jpwiJDvR5KMnFnVodm3scufTlBOWRD6N1OBf9TZMhjlNsSfcO5V+7AF4+Vy+9g==", "dev": true, "dependencies": { "@types/unist": "*" } }, + "node_modules/@types/json5": { + "version": "0.0.29", + "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz", + "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==", + "dev": true, + "peer": true + }, "node_modules/@types/mdast": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@types/mdast/-/mdast-3.0.3.tgz", - "integrity": "sha512-SXPBMnFVQg1s00dlMCc/jCdvPqdE4mXaMMCeRlxLDmTAEoegHT53xKtkDnzDTOcmMHUfcjyf36/YYZ6SxRdnsw==", + "version": "3.0.10", + "resolved": "https://registry.npmjs.org/@types/mdast/-/mdast-3.0.10.tgz", + "integrity": "sha512-W864tg/Osz1+9f4lrGTZpCSO5/z4608eUp19tbozkq2HJK6i3z1kT0H9tlADXuYIb1YYOBByU4Jsqkk75q48qA==", "dev": true, "dependencies": { "@types/unist": "*" } }, - "node_modules/@types/parse5": { - "version": "5.0.3", - "resolved": "https://registry.npmjs.org/@types/parse5/-/parse5-5.0.3.tgz", - "integrity": "sha512-kUNnecmtkunAoQ3CnjmMkzNU/gtxG8guhi+Fk2U/kOpIKjIMKnXGp4IJCgQJrXSgMsWYimYG4TGjz/UzbGEBTw==", + "node_modules/@types/minimist": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/@types/minimist/-/minimist-1.2.2.tgz", + "integrity": "sha512-jhuKLIRrhvCPLqwPcx6INqmKeiA5EWrsCOPhrlFSrbrmU4ZMPjj5Ul/oLCMDO98XRUIwVm78xICz4EPCektzeQ==", + "dev": true + }, + "node_modules/@types/ms": { + "version": "0.7.31", + "resolved": "https://registry.npmjs.org/@types/ms/-/ms-0.7.31.tgz", + "integrity": "sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA==", + "dev": true + }, + "node_modules/@types/node": { + "version": "14.18.33", + "resolved": "https://registry.npmjs.org/@types/node/-/node-14.18.33.tgz", + "integrity": "sha512-qelS/Ra6sacc4loe/3MSjXNL1dNQ/GjxNHVzuChwMfmk7HuycRLVQN2qNY3XahK+fZc5E2szqQSKUyAF0E+2bg==", + "dev": true + }, + "node_modules/@types/normalize-package-data": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/@types/normalize-package-data/-/normalize-package-data-2.4.1.tgz", + "integrity": "sha512-Gj7cI7z+98M282Tqmp2K5EIsoouUEzbBJhQQzDE3jSIRk6r9gsz0oUokqIUR4u1R3dMHo0pDHM7sNOHyhulypw==", + "dev": true + }, + "node_modules/@types/npm-package-arg": { + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/@types/npm-package-arg/-/npm-package-arg-6.1.1.tgz", + "integrity": "sha512-452/1Kp9IdM/oR10AyqAgZOxUt7eLbm+EMJ194L6oarMYdZNiFIFAOJ7IIr0OrZXTySgfHjJezh2oiyk2kc3ag==", + "dev": true + }, + "node_modules/@types/parse-json": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.0.tgz", + "integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==", "dev": true }, "node_modules/@types/unist": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@types/unist/-/unist-2.0.3.tgz", - "integrity": "sha512-FvUupuM3rlRsRtCN+fDudtmytGO6iHJuuRKS1Ss0pG5z8oX0diNEw94UEL7hgDbpN94rgaK5R7sWm6RrSkZuAQ==", + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/unist/-/unist-2.0.6.tgz", + "integrity": "sha512-PBjIUxZHOuj0R15/xuwJYjFi+KZdNFrehocChv4g5hu6aFroHue8m0lBP0POdK2nKzbw0cgV1mws8+V/JAcEkQ==", "dev": true }, + "node_modules/@types/yargs": { + "version": "16.0.4", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-16.0.4.tgz", + "integrity": "sha512-T8Yc9wt/5LbJyCaLiHPReJa0kApcIgJ7Bn735GjItUfh08Z1pJvu8QZqb9s+mMvKV6WUQRV7K2R46YbjMXTTJw==", + "dev": true, + "dependencies": { + "@types/yargs-parser": "*" + } + }, + "node_modules/@types/yargs-parser": { + "version": "21.0.0", + "resolved": "https://registry.npmjs.org/@types/yargs-parser/-/yargs-parser-21.0.0.tgz", + "integrity": "sha512-iO9ZQHkZxHn4mSakYV0vFHAVDyEOIJQrV2uZ06HxEPcx+mt8swXoZHIbaaJ2crJYFfErySgktuTZ3BeLz+XmFA==", + "dev": true + }, + "node_modules/@xmldom/xmldom": { + "version": "0.8.6", + "resolved": "https://registry.npmjs.org/@xmldom/xmldom/-/xmldom-0.8.6.tgz", + "integrity": "sha512-uRjjusqpoqfmRkTaNuLJ2VohVr67Q5YwDATW3VU7PfzTj6IRaihGrYI7zckGZjxQPBIp63nfvJbM+Yu5ICh0Bg==", + "dev": true, + "engines": { + "node": ">=10.0.0" + } + }, "node_modules/abab": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/abab/-/abab-2.0.5.tgz", - "integrity": "sha512-9IK9EadsbHo6jLWIpxpR6pL0sazTXV6+SQv25ZB+F7Bj9mJNaOc4nCRabwd5M/JwmUa8idz6Eci6eKfJryPs6Q==", + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/abab/-/abab-2.0.6.tgz", + "integrity": "sha512-j2afSsaIENvHZN2B8GOpF566vZ5WVk5opAiMTvWgaQT8DkbOqsTfvNAvHoRGU2zzP8cPoqys+xHTRDWW8L+/BA==", "dev": true }, "node_modules/abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", - "inBundle": true + "version": "2.0.0", + "inBundle": true, + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/abort-controller": { + "version": "3.0.0", + "inBundle": true, + "license": "MIT", + "dependencies": { + "event-target-shim": "^5.0.0" + }, + "engines": { + "node": ">=6.5" + } }, "node_modules/acorn": { - "version": "7.4.1", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-7.4.1.tgz", - "integrity": "sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A==", + "version": "8.8.1", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.1.tgz", + "integrity": "sha512-7zFpHzhnqYKrkYdUjF1HI1bzd0VygEGX8lFk4k5zVMqHEoES+P+7TKI+EvLO9WVMJ8eekdO0aDEK044xTXwPPA==", "dev": true, "bin": { "acorn": "bin/acorn" @@ -1079,13 +2629,13 @@ } }, "node_modules/acorn-globals": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/acorn-globals/-/acorn-globals-6.0.0.tgz", - "integrity": "sha512-ZQl7LOWaF5ePqqcX4hLuv/bLXYQNfNWw2c0/yX/TsPRKamzHcTGQnlCjHT3TsmkOUVEPS3crCxiPfdzE/Trlhg==", + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/acorn-globals/-/acorn-globals-7.0.1.tgz", + "integrity": "sha512-umOSDSDrfHbTNPuNpC2NSnnA3LUrqpevPb4T9jRx4MagXNS0rs+gwiTcAvqCRmsD6utzsrzNt+ebm00SNWiC3Q==", "dev": true, "dependencies": { - "acorn": "^7.1.1", - "acorn-walk": "^7.1.1" + "acorn": "^8.1.0", + "acorn-walk": "^8.0.2" } }, "node_modules/acorn-jsx": { @@ -1093,14 +2643,15 @@ "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", "dev": true, + "peer": true, "peerDependencies": { "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, "node_modules/acorn-walk": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-7.2.0.tgz", - "integrity": "sha512-OPdCF6GsMIP+Az+aWfAAOEt2/+iVDKE7oy6lJ098aoe59oAmK76qV6Gw60SbZ8jHuG2wH058GF4pLFbYamYrVA==", + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz", + "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==", "dev": true, "engines": { "node": ">=0.4.0" @@ -1108,9 +2659,8 @@ }, "node_modules/agent-base": { "version": "6.0.2", - "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz", - "integrity": "sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==", "inBundle": true, + "license": "MIT", "dependencies": { "debug": "4" }, @@ -1119,10 +2669,9 @@ } }, "node_modules/agentkeepalive": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/agentkeepalive/-/agentkeepalive-4.2.0.tgz", - "integrity": "sha512-0PhAp58jZNw13UJv7NVdTGb0ZcghHUb3DrZ046JiiJY/BOaTTpbwdHq2VObPCBV8M2GPh7sgrJ3AQ8Ey468LJw==", + "version": "4.2.1", "inBundle": true, + "license": "MIT", "dependencies": { "debug": "^4.1.0", "depd": "^1.1.2", @@ -1134,9 +2683,8 @@ }, "node_modules/aggregate-error": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.1.0.tgz", - "integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==", "inBundle": true, + "license": "MIT", "dependencies": { "clean-stack": "^2.0.0", "indent-string": "^4.0.0" @@ -1146,14 +2694,14 @@ } }, "node_modules/ajv": { - "version": "6.12.6", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", - "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", + "version": "8.11.0", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.11.0.tgz", + "integrity": "sha512-wGgprdCvMalC0BztXvitD2hC04YffAvtsUn93JbGXYLAtCUO4xd17mCCZQxUOItiBwZvJScWo8NIvQMQ71rdpg==", "dev": true, "dependencies": { "fast-deep-equal": "^3.1.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2", "uri-js": "^4.2.2" }, "funding": { @@ -1161,29 +2709,18 @@ "url": "https://github.com/sponsors/epoberezkin" } }, - "node_modules/ansi-colors": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", - "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==", - "dev": true, - "engines": { - "node": ">=6" - } - }, "node_modules/ansi-regex": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", + "version": "5.0.1", "inBundle": true, + "license": "MIT", "engines": { - "node": ">=0.10.0" + "node": ">=8" } }, "node_modules/ansi-styles": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "inBundle": true, + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -1194,18 +2731,6 @@ "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/ansicolors": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/ansicolors/-/ansicolors-0.3.2.tgz", - "integrity": "sha1-ZlWX3oap/+Oqm/vmyuXG6kJrSXk=", - "inBundle": true - }, - "node_modules/ansistyles": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/ansistyles/-/ansistyles-0.1.3.tgz", - "integrity": "sha1-XeYEFb2gcbs3EnhUyGT0GyMlRTk=", - "inBundle": true - }, "node_modules/anymatch": { "version": "3.1.2", "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.2.tgz", @@ -1233,301 +2758,28 @@ }, "node_modules/aproba": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/aproba/-/aproba-2.0.0.tgz", - "integrity": "sha512-lYe4Gx7QT+MKGbDsA+Z+he/Wtef0BiwDOlK/XkBrdfsh9J/jPPXbX0tE9x9cl27Tmu5gg3QUbUrQYa/y+KOHPQ==", - "inBundle": true + "inBundle": true, + "license": "ISC" }, "node_modules/archy": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz", - "integrity": "sha1-+cjBN1fMHde8N5rHeyxipcKGjEA=", - "inBundle": true + "inBundle": true, + "license": "MIT" }, "node_modules/are-we-there-yet": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-3.0.0.tgz", - "integrity": "sha512-0GWpv50YSOcLXaN6/FAKY3vfRbllXWV2xvfA/oKJF8pzFhWXPV+yjhJXDBbjscDYowv7Yw1A3uigpzn5iEGTyw==", + "version": "4.0.0", "inBundle": true, + "license": "ISC", "dependencies": { "delegates": "^1.0.0", - "readable-stream": "^3.6.0" + "readable-stream": "^4.1.0" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/arg": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", - "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", - "dev": true, - "optional": true, - "peer": true - }, - "node_modules/argparse": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", - "dev": true, - "dependencies": { - "sprintf-js": "~1.0.2" - } - }, - "node_modules/array-find-index": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/array-find-index/-/array-find-index-1.0.2.tgz", - "integrity": "sha1-3wEKoSh+Fku9pvlyOwqWoexBh6E=", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/asap": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/asap/-/asap-2.0.6.tgz", - "integrity": "sha1-5QNHYR1+aQlDIIu9r+vLwvuGbUY=", - "inBundle": true - }, - "node_modules/asn1": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz", - "integrity": "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==", - "dev": true, - "dependencies": { - "safer-buffer": "~2.1.0" - } - }, - "node_modules/assert-plus": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", - "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=", - "dev": true, - "engines": { - "node": ">=0.8" - } - }, - "node_modules/assertion-error": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", - "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==", - "dev": true, - "engines": { - "node": "*" - } - }, - "node_modules/async-hook-domain": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/async-hook-domain/-/async-hook-domain-2.0.4.tgz", - "integrity": "sha512-14LjCmlK1PK8eDtTezR6WX8TMaYNIzBIsd2D1sGoGjgx0BuNMMoSdk7i/drlbtamy0AWv9yv2tkB+ASdmeqFIw==", - "dev": true, - "engines": { - "node": ">=10" - } - }, - "node_modules/asynckit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=", - "dev": true - }, - "node_modules/aws-sign2": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", - "integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=", - "dev": true, - "engines": { - "node": "*" - } - }, - "node_modules/aws4": { - "version": "1.11.0", - "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.11.0.tgz", - "integrity": "sha512-xh1Rl34h6Fi1DC2WWKfxUTVqRsNnr6LsKz2+hfwDxQJWmrx8+c7ylaqBMcHfl1U1r2dsifOvKX3LQuLNZ+XSvA==", - "dev": true - }, - "node_modules/babel-plugin-apply-mdx-type-prop": { - "version": "1.6.22", - "resolved": "https://registry.npmjs.org/babel-plugin-apply-mdx-type-prop/-/babel-plugin-apply-mdx-type-prop-1.6.22.tgz", - "integrity": "sha512-VefL+8o+F/DfK24lPZMtJctrCVOfgbqLAGZSkxwhazQv4VxPg3Za/i40fu22KR2m8eEda+IfSOlPLUSIiLcnCQ==", - "dev": true, - "dependencies": { - "@babel/helper-plugin-utils": "7.10.4", - "@mdx-js/util": "1.6.22" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - }, - "peerDependencies": { - "@babel/core": "^7.11.6" - } - }, - "node_modules/babel-plugin-apply-mdx-type-prop/node_modules/@babel/helper-plugin-utils": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz", - "integrity": "sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg==", - "dev": true - }, - "node_modules/babel-plugin-extract-import-names": { - "version": "1.6.22", - "resolved": "https://registry.npmjs.org/babel-plugin-extract-import-names/-/babel-plugin-extract-import-names-1.6.22.tgz", - "integrity": "sha512-yJ9BsJaISua7d8zNT7oRG1ZLBJCIdZ4PZqmH8qa9N5AK01ifk3fnkc98AXhtzE7UkfCsEumvoQWgoYLhOnJ7jQ==", - "dev": true, - "dependencies": { - "@babel/helper-plugin-utils": "7.10.4" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/babel-plugin-extract-import-names/node_modules/@babel/helper-plugin-utils": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz", - "integrity": "sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg==", - "dev": true - }, - "node_modules/bail": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/bail/-/bail-1.0.5.tgz", - "integrity": "sha512-xFbRxM1tahm08yHBP16MMjVUAvDaBMD38zsM9EMAUN61omwLmKlOpB/Zku5QkjZ8TZ4vn53pj+t518cH0S03RQ==", - "dev": true, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/balanced-match": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "inBundle": true - }, - "node_modules/base64-js": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", - "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ] - }, - "node_modules/bcrypt-pbkdf": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", - "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=", - "dev": true, - "dependencies": { - "tweetnacl": "^0.14.3" - } - }, - "node_modules/benchmark": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/benchmark/-/benchmark-2.1.4.tgz", - "integrity": "sha1-CfPeMckWQl1JjMLuVloOvzwqVik=", - "dev": true, - "dependencies": { - "lodash": "^4.17.4", - "platform": "^1.3.3" - } - }, - "node_modules/bin-links": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/bin-links/-/bin-links-3.0.0.tgz", - "integrity": "sha512-fC7kPWcEkAWBgCKxmAMqZldlIeHsXwQy9JXzrppAVQiukGiDKxmYesJcBKWu6UMwx/5GOfo10wtK/4zy+Xt/mg==", - "dependencies": { - "cmd-shim": "^4.0.1", - "mkdirp-infer-owner": "^2.0.0", - "npm-normalize-package-bin": "^1.0.0", - "read-cmd-shim": "^2.0.0", - "rimraf": "^3.0.0", - "write-file-atomic": "^4.0.0" - }, - "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - } - }, - "node_modules/binary-extensions": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", - "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", - "engines": { - "node": ">=8" - } - }, - "node_modules/bind-obj-methods": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/bind-obj-methods/-/bind-obj-methods-3.0.0.tgz", - "integrity": "sha512-nLEaaz3/sEzNSyPWRsN9HNsqwk1AUyECtGj+XwGdIi3xABnEqecvXtIJ0wehQXuuER5uZ/5fTs2usONgYjG+iw==", - "dev": true, - "engines": { - "node": ">=10" - } - }, - "node_modules/bindings": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", - "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", - "dev": true, - "dependencies": { - "file-uri-to-path": "1.0.0" - } - }, - "node_modules/bl": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz", - "integrity": "sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==", - "dev": true, - "dependencies": { - "buffer": "^5.5.0", - "inherits": "^2.0.4", - "readable-stream": "^3.4.0" - } - }, - "node_modules/brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "inBundle": true, - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "node_modules/braces": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", - "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", - "dev": true, - "dependencies": { - "fill-range": "^7.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/browser-process-hrtime": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/browser-process-hrtime/-/browser-process-hrtime-1.0.0.tgz", - "integrity": "sha512-9o5UecI3GhkpM6DrXr69PblIuWxPKk9Y0jHBRhdocZ2y7YECBFCsHm79Pr3OyR2AvjhDkabFJaDJMYRazHgsow==", - "dev": true - }, - "node_modules/buffer": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", - "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", - "dev": true, + "node_modules/are-we-there-yet/node_modules/buffer": { + "version": "6.0.3", "funding": [ { "type": "github", @@ -1542,50 +2794,304 @@ "url": "https://feross.org/support" } ], + "inBundle": true, + "license": "MIT", "dependencies": { "base64-js": "^1.3.1", - "ieee754": "^1.1.13" + "ieee754": "^1.2.1" + } + }, + "node_modules/are-we-there-yet/node_modules/readable-stream": { + "version": "4.2.0", + "inBundle": true, + "license": "MIT", + "dependencies": { + "abort-controller": "^3.0.0", + "buffer": "^6.0.3", + "events": "^3.3.0", + "process": "^0.11.10" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + } + }, + "node_modules/arg": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", + "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", + "dev": true + }, + "node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", + "dev": true + }, + "node_modules/array-find-index": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/array-find-index/-/array-find-index-1.0.2.tgz", + "integrity": "sha512-M1HQyIXcBGtVywBt8WVdim+lrNaK7VHp99Qt5pSNziXznKHViIBbXWtfRTpEFpF/c4FdfxNAsCCwPp5phBYJtw==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/array-ify": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/array-ify/-/array-ify-1.0.0.tgz", + "integrity": "sha512-c5AMf34bKdvPhQ7tBGhqkgKNUzMr4WUs+WDtC2ZUGOUncbxKMTvqxYctiseW3+L4bA8ec+GcZ6/A/FW4m8ukng==", + "dev": true + }, + "node_modules/array-includes": { + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/array-includes/-/array-includes-3.1.5.tgz", + "integrity": "sha512-iSDYZMMyTPkiFasVqfuAQnWAYcvO/SeBSCGKePoEthjp4LEMTe4uLc7b025o4jAZpHhihh8xPo99TNWUWWkGDQ==", + "dev": true, + "peer": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.19.5", + "get-intrinsic": "^1.1.1", + "is-string": "^1.0.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.flat": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.3.1.tgz", + "integrity": "sha512-roTU0KWIOmJ4DRLmwKd19Otg0/mT3qPNt0Qb3GWW8iObuZXxrjB/pzn0R3hqpRSWg4HCwqx+0vwOnWnvlOyeIA==", + "dev": true, + "peer": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4", + "es-shim-unscopables": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/arrify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/arrify/-/arrify-1.0.1.tgz", + "integrity": "sha512-3CYzex9M9FGQjCGMGyi6/31c8GJbgb0qGyrx5HWxPd0aCwh4cB2YjMb2Xf9UuoogrMrlO9cTqnB5rI5GHZTcUA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/async-hook-domain": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/async-hook-domain/-/async-hook-domain-2.0.4.tgz", + "integrity": "sha512-14LjCmlK1PK8eDtTezR6WX8TMaYNIzBIsd2D1sGoGjgx0BuNMMoSdk7i/drlbtamy0AWv9yv2tkB+ASdmeqFIw==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/async-retry": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/async-retry/-/async-retry-1.3.3.tgz", + "integrity": "sha512-wfr/jstw9xNi/0teMHrRW7dsz3Lt5ARhYNZ2ewpadnhaIp5mbALhOAP+EAdsC7t4Z6wqsDVv9+W6gm1Dk9mEyw==", + "dev": true, + "dependencies": { + "retry": "0.13.1" + } + }, + "node_modules/async-retry/node_modules/retry": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.13.1.tgz", + "integrity": "sha512-XQBQ3I8W1Cge0Seh+6gjj03LbmRFWuoszgK9ooCpwYIrhhoO80pfq4cUkU5DkknwfOfFteRwlZ56PYOGYyFWdg==", + "dev": true, + "engines": { + "node": ">= 4" + } + }, + "node_modules/asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", + "dev": true + }, + "node_modules/bail": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/bail/-/bail-2.0.2.tgz", + "integrity": "sha512-0xO6mYd7JB2YesxDKplafRpsiOzPt9V02ddPCLbY1xYGPOX24NTyN50qnUxgCPcSoYMhKpAuBTjQoRZCAkUDRw==", + "dev": true, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } + }, + "node_modules/balanced-match": { + "version": "1.0.2", + "inBundle": true, + "license": "MIT" + }, + "node_modules/base64-js": { + "version": "1.5.1", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "inBundle": true, + "license": "MIT" + }, + "node_modules/before-after-hook": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-2.2.3.tgz", + "integrity": "sha512-NzUnlZexiaH/46WDhANlyR2bXRopNg4F/zuSA3OpZnllCUgRaOF2znDioDWrmbNVsuZk6l9pMquQB38cfBZwkQ==", + "dev": true + }, + "node_modules/benchmark": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/benchmark/-/benchmark-2.1.4.tgz", + "integrity": "sha512-l9MlfN4M1K/H2fbhfMy3B7vJd6AGKJVQn2h6Sg/Yx+KckoUA7ewS5Vv6TjSq18ooE1kS9hhAlQRH3AkXIh/aOQ==", + "dev": true, + "dependencies": { + "lodash": "^4.17.4", + "platform": "^1.3.3" + } + }, + "node_modules/bin-links": { + "version": "4.0.1", + "license": "ISC", + "dependencies": { + "cmd-shim": "^6.0.0", + "npm-normalize-package-bin": "^3.0.0", + "read-cmd-shim": "^4.0.0", + "write-file-atomic": "^5.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/binary-extensions": { + "version": "2.2.0", + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/bind-obj-methods": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/bind-obj-methods/-/bind-obj-methods-3.0.0.tgz", + "integrity": "sha512-nLEaaz3/sEzNSyPWRsN9HNsqwk1AUyECtGj+XwGdIi3xABnEqecvXtIJ0wehQXuuER5uZ/5fTs2usONgYjG+iw==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/boolbase": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", + "integrity": "sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==", + "dev": true + }, + "node_modules/brace-expansion": { + "version": "2.0.1", + "inBundle": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0" + } + }, + "node_modules/braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "dev": true, + "dependencies": { + "fill-range": "^7.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/browserslist": { + "version": "4.21.4", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.21.4.tgz", + "integrity": "sha512-CBHJJdDmgjl3daYjN5Cp5kbTf1mUhZoS+beLklHIvkOWscs83YAhLlF3Wsh/lciQYAcbBJgTOD44VtG31ZM4Hw==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + } + ], + "dependencies": { + "caniuse-lite": "^1.0.30001400", + "electron-to-chromium": "^1.4.251", + "node-releases": "^2.0.6", + "update-browserslist-db": "^1.0.9" + }, + "bin": { + "browserslist": "cli.js" + }, + "engines": { + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" } }, "node_modules/buffer-from": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", - "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==", + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", "dev": true }, "node_modules/builtins": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/builtins/-/builtins-1.0.3.tgz", - "integrity": "sha1-y5T662HIaWRR2zZTThQi+U8K7og=", - "inBundle": true + "version": "5.0.1", + "inBundle": true, + "license": "MIT", + "dependencies": { + "semver": "^7.0.0" + } }, "node_modules/cacache": { - "version": "15.3.0", - "resolved": "https://registry.npmjs.org/cacache/-/cacache-15.3.0.tgz", - "integrity": "sha512-VVdYzXEn+cnbXpFgWs5hTT7OScegHVmLhJIR8Ufqk3iFD6A6j5iSX1KuBTfNEv4tdJWE2PzA6IVFtcLC7fN9wQ==", + "version": "17.0.3", + "resolved": "https://registry.npmjs.org/cacache/-/cacache-17.0.3.tgz", + "integrity": "sha512-pwsIK/grdM0cHpfVaNFxMdzElBtLJGsVPE+JnxqXP1l40O01Z1mfDE8MbRTuwomGq/UwEtGisOylutOEVJxEqg==", "inBundle": true, "dependencies": { - "@npmcli/fs": "^1.0.0", - "@npmcli/move-file": "^1.0.1", - "chownr": "^2.0.0", - "fs-minipass": "^2.0.0", - "glob": "^7.1.4", - "infer-owner": "^1.0.4", - "lru-cache": "^6.0.0", - "minipass": "^3.1.1", + "@npmcli/fs": "^3.1.0", + "fs-minipass": "^2.1.0", + "glob": "^8.0.1", + "lru-cache": "^7.7.1", + "minipass": "^4.0.0", "minipass-collect": "^1.0.2", "minipass-flush": "^1.0.5", - "minipass-pipeline": "^1.2.2", - "mkdirp": "^1.0.3", + "minipass-pipeline": "^1.2.4", "p-map": "^4.0.0", "promise-inflight": "^1.0.1", - "rimraf": "^3.0.2", - "ssri": "^8.0.1", - "tar": "^6.0.2", - "unique-filename": "^1.1.1" + "ssri": "^10.0.0", + "tar": "^6.1.11", + "unique-filename": "^3.0.0" }, "engines": { - "node": ">= 10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/caching-transform": { @@ -1603,15 +3109,6 @@ "node": ">=8" } }, - "node_modules/caching-transform/node_modules/typedarray-to-buffer": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz", - "integrity": "sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==", - "dev": true, - "dependencies": { - "is-typedarray": "^1.0.0" - } - }, "node_modules/caching-transform/node_modules/write-file-atomic": { "version": "3.0.3", "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-3.0.3.tgz", @@ -1629,6 +3126,7 @@ "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", "dev": true, + "peer": true, "dependencies": { "function-bind": "^1.1.1", "get-intrinsic": "^1.0.2" @@ -1638,9 +3136,9 @@ } }, "node_modules/caller": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/caller/-/caller-1.0.1.tgz", - "integrity": "sha1-uFGGD3Dhlds9J3OVqhp+I+ow7PU=", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/caller/-/caller-1.1.0.tgz", + "integrity": "sha512-n+21IZC3j06YpCWaxmUy5AnVqhmCIM2bQtqQyy00HJlmStRt6kwDX5F9Z97pqwAB+G/tgSz6q/kUBbNyQzIubw==", "dev": true }, "node_modules/callsites": { @@ -1661,53 +3159,53 @@ "node": ">=6" } }, - "node_modules/camelcase-css": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/camelcase-css/-/camelcase-css-2.0.1.tgz", - "integrity": "sha512-QOSvevhslijgYwRx6Rv7zKdMF8lbRmx+uQGx2+vDc+KI/eBnsy9kit5aj23AgGu3pa4t9AgwbnXWqS+iOY+2aA==", + "node_modules/camelcase-keys": { + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/camelcase-keys/-/camelcase-keys-6.2.2.tgz", + "integrity": "sha512-YrwaA0vEKazPBkn0ipTiMpSajYDSe+KjQfrjhcBMxJt/znbvlHd8Pw/Vamaz5EB4Wfhs3SUR3Z9mwRu/P3s3Yg==", "dev": true, + "dependencies": { + "camelcase": "^5.3.1", + "map-obj": "^4.0.0", + "quick-lru": "^4.0.1" + }, "engines": { - "node": ">= 6" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/caseless": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", - "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=", - "dev": true + "node_modules/caniuse-lite": { + "version": "1.0.30001431", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001431.tgz", + "integrity": "sha512-zBUoFU0ZcxpvSt9IU66dXVT/3ctO1cy4y9cscs1szkPlcWb6pasYM144GqrUygUbT+k7cmUCW61cvskjcv0enQ==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + } + ] }, "node_modules/ccount": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/ccount/-/ccount-1.1.0.tgz", - "integrity": "sha512-vlNK021QdI7PNeiUh/lKkC/mNHHfV0m/Ad5JoI0TYtlBnJAslM/JIkm/tGC88bkLIwO6OQ5uV6ztS6kVAtCDlg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/ccount/-/ccount-2.0.1.tgz", + "integrity": "sha512-eyrF0jiFpY+3drT6383f1qhkbGsLSifNAjA61IUjZjmLCWjItY6LB9ft9YhoDgwfmclB2zhu51Lc7+95b8NRAg==", "dev": true, "funding": { "type": "github", "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/chai": { - "version": "4.3.4", - "resolved": "https://registry.npmjs.org/chai/-/chai-4.3.4.tgz", - "integrity": "sha512-yS5H68VYOCtN1cjfwumDSuzn/9c+yza4f3reKXlE5rUg7SFcCEy90gJvydNgOYtblyf4Zi6jIWRnXOgErta0KA==", - "dev": true, - "dependencies": { - "assertion-error": "^1.1.0", - "check-error": "^1.0.2", - "deep-eql": "^3.0.1", - "get-func-name": "^2.0.0", - "pathval": "^1.1.1", - "type-detect": "^4.0.5" - }, - "engines": { - "node": ">=4" - } - }, "node_modules/chalk": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "inBundle": true, + "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -1720,9 +3218,19 @@ } }, "node_modules/character-entities": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/character-entities/-/character-entities-1.2.4.tgz", - "integrity": "sha512-iBMyeEHxfVnIakwOuDXpVkc54HijNgCyQB2w0VfGQThle6NXn50zU6V/u+LDhxHcDUPojn6Kpga3PTAD8W1bQw==", + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/character-entities/-/character-entities-2.0.2.tgz", + "integrity": "sha512-shx7oQ0Awen/BRIdkjkvz54PnEEI/EjwXDSIZp86/KKdbafHh1Df/RYGBhn4hbe2+uKC9FnT5UCEdyPz3ai9hQ==", + "dev": true, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } + }, + "node_modules/character-entities-html4": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/character-entities-html4/-/character-entities-html4-2.1.0.tgz", + "integrity": "sha512-1v7fgQRj6hnSwFpq1Eu0ynr/CDEw0rXo2B61qXrLNdHZmPKgb7fqS1a2JwF0rISo9q77jDI8VMEHoApn8qDoZA==", "dev": true, "funding": { "type": "github", @@ -1730,69 +3238,75 @@ } }, "node_modules/character-entities-legacy": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/character-entities-legacy/-/character-entities-legacy-1.1.4.tgz", - "integrity": "sha512-3Xnr+7ZFS1uxeiUDvV02wQ+QDbc55o97tIV5zHScSPJpcLm/r0DFPcoY3tYRp+VZukxuMeKgXYmsXQHO05zQeA==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/character-entities-legacy/-/character-entities-legacy-3.0.0.tgz", + "integrity": "sha512-RpPp0asT/6ufRm//AJVwpViZbGM/MkjQFxJccQRHmISF/22NBtsHqAWmL+/pmkPWoIUJdWyeVleTl1wydHATVQ==", "dev": true, "funding": { "type": "github", "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/character-reference-invalid": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/character-reference-invalid/-/character-reference-invalid-1.1.4.tgz", - "integrity": "sha512-mKKUkUbhPpQlCOfIuZkvSEgktjPFIsZKRRbC6KWVEMvlzblj3i3asQv5ODsrwt0N3pHAEvjP8KTQPHkp0+6jOg==", - "dev": true, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/check-error": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", - "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=", - "dev": true, - "engines": { - "node": "*" - } - }, "node_modules/chokidar": { - "version": "3.5.1", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.1.tgz", - "integrity": "sha512-9+s+Od+W0VJJzawDma/gvBNQqkTiqYTWLuZoyAsivsI4AaWTCzHG06/TMjsf1cYe9Cb97UCEhjz7HvnPk2p/tw==", + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz", + "integrity": "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==", "dev": true, + "funding": [ + { + "type": "individual", + "url": "https://paulmillr.com/funding/" + } + ], "dependencies": { - "anymatch": "~3.1.1", + "anymatch": "~3.1.2", "braces": "~3.0.2", - "glob-parent": "~5.1.0", + "glob-parent": "~5.1.2", "is-binary-path": "~2.1.0", "is-glob": "~4.0.1", "normalize-path": "~3.0.0", - "readdirp": "~3.5.0" + "readdirp": "~3.6.0" }, "engines": { "node": ">= 8.10.0" }, "optionalDependencies": { - "fsevents": "~2.3.1" + "fsevents": "~2.3.2" + } + }, + "node_modules/chokidar/node_modules/glob-parent": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "dev": true, + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" } }, "node_modules/chownr": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz", - "integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==", "inBundle": true, + "license": "ISC", "engines": { "node": ">=10" } }, + "node_modules/ci-info": { + "version": "3.7.0", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.7.0.tgz", + "integrity": "sha512-2CpRNYmImPx+RXKLq6jko/L07phmS9I02TyqkcNU20GCF/GgaWvc58hPtjxDX8lPpkdwc9sNh72V9k00S7ezog==", + "inBundle": true, + "engines": { + "node": ">=8" + } + }, "node_modules/cidr-regex": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/cidr-regex/-/cidr-regex-3.1.1.tgz", - "integrity": "sha512-RBqYd32aDwbCMFJRL6wHOlDNYJsPNTt8vC82ErHF5vKt8QQzxm1FrkW8s/R5pVrXMf17sba09Uoy91PKiddAsw==", "inBundle": true, + "license": "BSD-2-Clause", "dependencies": { "ip-regex": "^4.1.0" }, @@ -1802,18 +3316,16 @@ }, "node_modules/clean-stack": { "version": "2.2.0", - "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz", - "integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==", "inBundle": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/cli-columns": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/cli-columns/-/cli-columns-4.0.0.tgz", - "integrity": "sha512-XW2Vg+w+L9on9wtwKpyzluIPCWXjaBahI7mTcYjx+BVIYD9c3yqcv/yKC7CmdCZat4rq2yiE1UMSJC5ivKfMtQ==", "inBundle": true, + "license": "MIT", "dependencies": { "string-width": "^4.2.3", "strip-ansi": "^6.0.1" @@ -1822,55 +3334,10 @@ "node": ">= 10" } }, - "node_modules/cli-columns/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "inBundle": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/cli-columns/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "inBundle": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/cli-columns/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "inBundle": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/cli-columns/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "inBundle": true, - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/cli-table3": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/cli-table3/-/cli-table3-0.6.1.tgz", - "integrity": "sha512-w0q/enDHhPLq44ovMGdQeeDLvwxwavsJX7oQGYt/LrBlYsyaxyDnp6z3QzFut/6kLLKnlcUVJLrpB7KBfgG/RA==", + "version": "0.6.3", "inBundle": true, + "license": "MIT", "dependencies": { "string-width": "^4.2.0" }, @@ -1878,51 +3345,7 @@ "node": "10.* || >= 12.*" }, "optionalDependencies": { - "colors": "1.4.0" - } - }, - "node_modules/cli-table3/node_modules/ansi-regex": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", - "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==", - "inBundle": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/cli-table3/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "inBundle": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/cli-table3/node_modules/string-width": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.2.tgz", - "integrity": "sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA==", - "inBundle": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/cli-table3/node_modules/strip-ansi": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", - "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", - "inBundle": true, - "dependencies": { - "ansi-regex": "^5.0.0" - }, - "engines": { - "node": ">=8" + "@colors/colors": "1.5.0" } }, "node_modules/cliui": { @@ -1936,109 +3359,115 @@ "wrap-ansi": "^7.0.0" } }, - "node_modules/cliui/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/cliui/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/cliui/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/cliui/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/clone": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", - "integrity": "sha1-2jCcwmPfFZlMaIypAheco8fNfH4=", "inBundle": true, + "license": "MIT", "engines": { "node": ">=0.8" } }, - "node_modules/cmark-gfm": { - "version": "0.9.0", - "resolved": "https://registry.npmjs.org/cmark-gfm/-/cmark-gfm-0.9.0.tgz", - "integrity": "sha512-zt++V303Zh+kqS3PERSq1knHT21TpKjbVUF/U63QhLktEH+eeZymv+mHz+6IhcTN5Hy85LdkgdKlroa/Jc6Wvg==", - "dev": true, - "hasInstallScript": true, - "dependencies": { - "bindings": "^1.5.0", - "node-addon-api": "^3.0.0", - "prebuild-install": "^6.0.0" - }, - "engines": { - "node": ">= 12" - } - }, "node_modules/cmd-shim": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/cmd-shim/-/cmd-shim-4.1.0.tgz", - "integrity": "sha512-lb9L7EM4I/ZRVuljLPEtUJOP+xiQVknZ4ZMpMgEp4JzNldPb27HU03hi6K1/6CoIuit/Zm/LQXySErFeXxDprw==", - "dependencies": { - "mkdirp-infer-owner": "^2.0.0" - }, + "version": "6.0.0", + "license": "ISC", "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/code-point-at": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", - "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", + "integrity": "sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==", "dev": true, "engines": { "node": ">=0.10.0" } }, - "node_modules/collapse-white-space": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/collapse-white-space/-/collapse-white-space-1.0.6.tgz", - "integrity": "sha512-jEovNnrhMuqyCcjfEJA56v0Xq8SkIoPKDyaHahwo3POf4qcSXqMYuwNcOTzp74vTsR9Tn08z4MxWqAhcekogkQ==", + "node_modules/code-suggester": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/code-suggester/-/code-suggester-4.1.0.tgz", + "integrity": "sha512-l3V0QvXL//d78Kxuanlb89r6AT6G3ZM+qmwvHw3NyP7SjKkt+6LZcgEC6yH5T8hwZGSfz/9dXSek0cMn9tMqpw==", "dev": true, + "dependencies": { + "@octokit/rest": "^19.0.0", + "@types/yargs": "^16.0.0", + "async-retry": "^1.3.1", + "diff": "^5.0.0", + "glob": "^7.1.6", + "parse-diff": "^0.9.0", + "yargs": "^16.0.0" + }, + "bin": { + "code-suggester": "build/src/bin/code-suggester.js" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/code-suggester/node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/code-suggester/node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "dev": true, + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/code-suggester/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/code-suggester/node_modules/yargs": { + "version": "16.2.0", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz", + "integrity": "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==", + "dev": true, + "dependencies": { + "cliui": "^7.0.2", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.0", + "y18n": "^5.0.5", + "yargs-parser": "^20.2.2" + }, + "engines": { + "node": ">=10" } }, "node_modules/color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "inBundle": true, + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -2048,37 +3477,27 @@ }, "node_modules/color-name": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "inBundle": true + "inBundle": true, + "license": "MIT" }, "node_modules/color-support": { "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz", - "integrity": "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg==", "inBundle": true, + "license": "ISC", "bin": { "color-support": "bin.js" } }, - "node_modules/colors": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/colors/-/colors-1.4.0.tgz", - "integrity": "sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==", - "inBundle": true, - "optional": true, - "engines": { - "node": ">=0.1.90" - } - }, "node_modules/columnify": { - "version": "1.5.4", - "resolved": "https://registry.npmjs.org/columnify/-/columnify-1.5.4.tgz", - "integrity": "sha1-Rzfd8ce2mop8NAVweC6UfuyOeLs=", + "version": "1.6.0", "inBundle": true, + "license": "MIT", "dependencies": { - "strip-ansi": "^3.0.0", + "strip-ansi": "^6.0.1", "wcwidth": "^1.0.0" + }, + "engines": { + "node": ">=8.0.0" } }, "node_modules/combined-stream": { @@ -2094,9 +3513,9 @@ } }, "node_modules/comma-separated-tokens": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/comma-separated-tokens/-/comma-separated-tokens-1.0.8.tgz", - "integrity": "sha512-GHuDRO12Sypu2cV70d1dkA2EUmXHgntrzbpvOB+Qy+49ypNfGgFQIC2fhhXbnyrJRynDCAARsT7Ou0M6hirpfw==", + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/comma-separated-tokens/-/comma-separated-tokens-2.0.2.tgz", + "integrity": "sha512-G5yTt3KQN4Yn7Yk4ed73hlZ1evrFKXeUW3086p3PRFNp7m2vIjI6Pg+Kgb+oyzhd9F2qdcoj67+y3SdxL5XWsg==", "dev": true, "funding": { "type": "github", @@ -2105,46 +3524,136 @@ }, "node_modules/common-ancestor-path": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/common-ancestor-path/-/common-ancestor-path-1.0.1.tgz", - "integrity": "sha512-L3sHRo1pXXEqX8VU28kfgUY+YGsk09hPqZiZmLacNib6XNTCM8ubYeT7ryXQw8asB1sKgcU5lkB7ONug08aB8w==" + "license": "ISC" }, "node_modules/commondir": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", - "integrity": "sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs=", + "integrity": "sha512-W9pAhw0ja1Edb5GVdIF1mjZw/ASI0AlShXM83UUGe2DVr5TdAPEA1OA8m/g8zWp9x6On7gqufY+FatDbC3MDQg==", "dev": true }, + "node_modules/compare-func": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/compare-func/-/compare-func-2.0.0.tgz", + "integrity": "sha512-zHig5N+tPWARooBnb0Zx1MFcdfpyJrfTJ3Y5L+IFvUm8rM74hHz66z0gw0x4tijh5CorKkKUCnW82R2vmpeCRA==", + "dev": true, + "dependencies": { + "array-ify": "^1.0.0", + "dot-prop": "^5.1.0" + } + }, "node_modules/concat-map": { "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", - "inBundle": true + "inBundle": true, + "license": "MIT" }, "node_modules/console-control-strings": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", - "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=", - "inBundle": true + "inBundle": true, + "license": "ISC" }, - "node_modules/convert-source-map": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.7.0.tgz", - "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==", + "node_modules/conventional-changelog-angular": { + "version": "5.0.13", + "resolved": "https://registry.npmjs.org/conventional-changelog-angular/-/conventional-changelog-angular-5.0.13.tgz", + "integrity": "sha512-i/gipMxs7s8L/QeuavPF2hLnJgH6pEZAttySB6aiQLWcX3puWDL3ACVmvBhJGxnAy52Qc15ua26BufY6KpmrVA==", "dev": true, "dependencies": { - "safe-buffer": "~5.1.1" + "compare-func": "^2.0.0", + "q": "^1.5.1" + }, + "engines": { + "node": ">=10" } }, - "node_modules/convert-source-map/node_modules/safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "node_modules/conventional-changelog-conventionalcommits": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/conventional-changelog-conventionalcommits/-/conventional-changelog-conventionalcommits-5.0.0.tgz", + "integrity": "sha512-lCDbA+ZqVFQGUj7h9QBKoIpLhl8iihkO0nCTyRNzuXtcd7ubODpYB04IFy31JloiJgG0Uovu8ot8oxRzn7Nwtw==", + "dev": true, + "dependencies": { + "compare-func": "^2.0.0", + "lodash": "^4.17.15", + "q": "^1.5.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/conventional-changelog-writer": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/conventional-changelog-writer/-/conventional-changelog-writer-5.0.1.tgz", + "integrity": "sha512-5WsuKUfxW7suLblAbFnxAcrvf6r+0b7GvNaWUwUIk0bXMnENP/PEieGKVUQrjPqwPT4o3EPAASBXiY6iHooLOQ==", + "dev": true, + "dependencies": { + "conventional-commits-filter": "^2.0.7", + "dateformat": "^3.0.0", + "handlebars": "^4.7.7", + "json-stringify-safe": "^5.0.1", + "lodash": "^4.17.15", + "meow": "^8.0.0", + "semver": "^6.0.0", + "split": "^1.0.0", + "through2": "^4.0.0" + }, + "bin": { + "conventional-changelog-writer": "cli.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/conventional-changelog-writer/node_modules/semver": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", + "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", + "dev": true, + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/conventional-commits-filter": { + "version": "2.0.7", + "resolved": "https://registry.npmjs.org/conventional-commits-filter/-/conventional-commits-filter-2.0.7.tgz", + "integrity": "sha512-ASS9SamOP4TbCClsRHxIHXRfcGCnIoQqkvAzCSbZzTFLfcTqJVugB0agRgsEELsqaeWgsXv513eS116wnlSSPA==", + "dev": true, + "dependencies": { + "lodash.ismatch": "^4.4.0", + "modify-values": "^1.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/conventional-commits-parser": { + "version": "3.2.4", + "resolved": "https://registry.npmjs.org/conventional-commits-parser/-/conventional-commits-parser-3.2.4.tgz", + "integrity": "sha512-nK7sAtfi+QXbxHCYfhpZsfRtaitZLIA6889kFIouLvz6repszQDgxBu7wf2WbU+Dco7sAnNCJYERCwt54WPC2Q==", + "dev": true, + "dependencies": { + "is-text-path": "^1.0.1", + "JSONStream": "^1.0.4", + "lodash": "^4.17.15", + "meow": "^8.0.0", + "split2": "^3.0.0", + "through2": "^4.0.0" + }, + "bin": { + "conventional-commits-parser": "cli.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/convert-source-map": { + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.9.0.tgz", + "integrity": "sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==", "dev": true }, "node_modules/core-util-is": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", - "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", "dev": true }, "node_modules/correct-license-metadata": { @@ -2156,25 +3665,53 @@ "spdx-expression-validate": "^2.0.0" } }, - "node_modules/coveralls": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/coveralls/-/coveralls-3.1.0.tgz", - "integrity": "sha512-sHxOu2ELzW8/NC1UP5XVLbZDzO4S3VxfFye3XYCznopHy02YjNkHcj5bKaVw2O7hVaBdBjEdQGpie4II1mWhuQ==", + "node_modules/cosmiconfig": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-7.0.1.tgz", + "integrity": "sha512-a1YWNUV2HwGimB7dU2s1wUMurNKjpx60HxBB6xUM8Re+2s1g1IIfJvFR0/iCF+XHdE0GMTKTuLR32UQff4TEyQ==", "dev": true, "dependencies": { - "js-yaml": "^3.13.1", - "lcov-parse": "^1.0.0", - "log-driver": "^1.2.7", - "minimist": "^1.2.5", - "request": "^2.88.2" - }, - "bin": { - "coveralls": "bin/coveralls.js" + "@types/parse-json": "^4.0.0", + "import-fresh": "^3.2.1", + "parse-json": "^5.0.0", + "path-type": "^4.0.0", + "yaml": "^1.10.0" }, "engines": { - "node": ">=6" + "node": ">=10" } }, + "node_modules/cosmiconfig-typescript-loader": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/cosmiconfig-typescript-loader/-/cosmiconfig-typescript-loader-4.2.0.tgz", + "integrity": "sha512-NkANeMnaHrlaSSlpKGyvn2R4rqUDeE/9E5YHx+b4nwo0R8dZyAqcih8/gxpCZvqWP9Vf6xuLpMSzSgdVEIM78g==", + "dev": true, + "engines": { + "node": ">=12", + "npm": ">=6" + }, + "peerDependencies": { + "@types/node": "*", + "cosmiconfig": ">=7", + "ts-node": ">=10", + "typescript": ">=3" + } + }, + "node_modules/cosmiconfig/node_modules/yaml": { + "version": "1.10.2", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", + "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", + "dev": true, + "engines": { + "node": ">= 6" + } + }, + "node_modules/create-require": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz", + "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", + "dev": true + }, "node_modules/cross-spawn": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", @@ -2189,6 +3726,59 @@ "node": ">= 8" } }, + "node_modules/cross-spawn/node_modules/which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/css-select": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.3.0.tgz", + "integrity": "sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==", + "dev": true, + "dependencies": { + "boolbase": "^1.0.0", + "css-what": "^6.0.1", + "domhandler": "^4.3.1", + "domutils": "^2.8.0", + "nth-check": "^2.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/css-what": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/css-what/-/css-what-6.1.0.tgz", + "integrity": "sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==", + "dev": true, + "engines": { + "node": ">= 6" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/cssesc": { + "version": "3.0.0", + "license": "MIT", + "bin": { + "cssesc": "bin/cssesc" + }, + "engines": { + "node": ">=4" + } + }, "node_modules/cssom": { "version": "0.5.0", "resolved": "https://registry.npmjs.org/cssom/-/cssom-0.5.0.tgz", @@ -2213,37 +3803,76 @@ "integrity": "sha512-b0tGHbfegbhPJpxpiBPU2sCkigAqtM9O121le6bbOlgyV+NyGyCmVfJ6QW9eRjz8CpNfWEOYBIMIGRYkLwsIYg==", "dev": true }, - "node_modules/dashdash": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", - "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", + "node_modules/dargs": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/dargs/-/dargs-7.0.0.tgz", + "integrity": "sha512-2iy1EkLdlBzQGvbweYRFxmFath8+K7+AKB0TlhHWkNuH+TmovaMH/Wp7V7R4u7f4SnX3OgLsU9t1NI9ioDnUpg==", "dev": true, - "dependencies": { - "assert-plus": "^1.0.0" - }, "engines": { - "node": ">=0.10" + "node": ">=8" } }, "node_modules/data-urls": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-3.0.1.tgz", - "integrity": "sha512-Ds554NeT5Gennfoo9KN50Vh6tpgtvYEwraYjejXnyTpu1C7oXKxdFk75REooENHE8ndTVOJuv+BEs4/J/xcozw==", + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-3.0.2.tgz", + "integrity": "sha512-Jy/tj3ldjZJo63sVAvg6LHt2mHvl4V6AgRAmNDtLdm7faqtsx+aJG42rsyCo9JCoRVKwPFzKlIPx3DIibwSIaQ==", "dev": true, "dependencies": { - "abab": "^2.0.3", + "abab": "^2.0.6", "whatwg-mimetype": "^3.0.0", - "whatwg-url": "^10.0.0" + "whatwg-url": "^11.0.0" }, "engines": { "node": ">=12" } }, + "node_modules/data-urls/node_modules/tr46": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-3.0.0.tgz", + "integrity": "sha512-l7FvfAHlcmulp8kr+flpQZmVwtu7nfRV7NZujtN0OqES8EL4O4e0qqzL0DC5gAvx/ZC/9lk6rhcUwYvkBnBnYA==", + "dev": true, + "dependencies": { + "punycode": "^2.1.1" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/data-urls/node_modules/webidl-conversions": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", + "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", + "dev": true, + "engines": { + "node": ">=12" + } + }, + "node_modules/data-urls/node_modules/whatwg-url": { + "version": "11.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-11.0.0.tgz", + "integrity": "sha512-RKT8HExMpoYx4igMiVMY83lN6UeITKJlBQ+vR/8ZJ8OCdSiN3RwCq+9gH0+Xzj0+5IrM6i4j/6LuvzbZIQgEcQ==", + "dev": true, + "dependencies": { + "tr46": "^3.0.0", + "webidl-conversions": "^7.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/dateformat": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-3.0.3.tgz", + "integrity": "sha512-jyCETtSl3VMZMWeRo7iY1FL19ges1t55hMo5yaam4Jrsm5EPL89UQkoQRyiI+Yf4k8r2ZpdngkV8hr1lIdjb3Q==", + "dev": true, + "engines": { + "node": "*" + } + }, "node_modules/debug": { - "version": "4.3.3", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.3.tgz", - "integrity": "sha512-/zxw5+vh1Tfv+4Qn7a5nsbcJKPaSvCDhojn6FEl9vupwK2VCSDtEiEtqr8DFtzYFOdz63LBkxec7DYuc2jon6Q==", + "version": "4.3.4", "inBundle": true, + "license": "MIT", "dependencies": { "ms": "2.1.2" }, @@ -2258,136 +3887,112 @@ }, "node_modules/debug/node_modules/ms": { "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "inBundle": true - }, - "node_modules/debuglog": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/debuglog/-/debuglog-1.0.1.tgz", - "integrity": "sha1-qiT/uaw9+aI1GDfPstJ5NgzXhJI=", "inBundle": true, - "engines": { - "node": "*" - } + "license": "MIT" }, "node_modules/decamelize": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", - "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", + "integrity": "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/decamelize-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/decamelize-keys/-/decamelize-keys-1.1.1.tgz", + "integrity": "sha512-WiPxgEirIV0/eIOMcnFBA3/IJZAZqKnwAwWyvvdi4lsr1WCN22nhdf/3db3DoZcUjTV2SqfzIwNyp6y2xs3nmg==", + "dev": true, + "dependencies": { + "decamelize": "^1.1.0", + "map-obj": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/decamelize-keys/node_modules/map-obj": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-1.0.1.tgz", + "integrity": "sha512-7N/q3lyZ+LVCp7PzuxrJr4KMbBE2hW7BT7YNia330OFxIf4d3r5zVpicP2650l7CPN6RM9zOJRl3NGpqSiw3Eg==", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/decimal.js": { - "version": "10.3.1", - "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.3.1.tgz", - "integrity": "sha512-V0pfhfr8suzyPGOx3nmq4aHqabehUZn6Ch9kyFpV79TGDTWFmHqUqXdabR7QHqxzrYolF4+tVmJhUG4OURg5dQ==", + "version": "10.4.2", + "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.4.2.tgz", + "integrity": "sha512-ic1yEvwT6GuvaYwBLLY6/aFFgjZdySKTE8en/fkU3QICTmRtgtSlFn0u0BXN06InZwtfCelR7j8LRiDI/02iGA==", "dev": true }, - "node_modules/decompress-response": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-4.2.1.tgz", - "integrity": "sha512-jOSne2qbyE+/r8G1VU+G/82LBs2Fs4LAsTiLSHOCOMZQl2OKZ6i8i4IyHemTe+/yIXOtTcRQMzPcgyhoFlqPkw==", + "node_modules/decode-named-character-reference": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/decode-named-character-reference/-/decode-named-character-reference-1.0.2.tgz", + "integrity": "sha512-O8x12RzrUF8xyVcY0KJowWsmaJxQbmy0/EtnNtHRpsOcT7dFk5W598coHqBVpmWo1oQQfsCqfCmkZN5DJrZVdg==", "dev": true, "dependencies": { - "mimic-response": "^2.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/deep-eql": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-3.0.1.tgz", - "integrity": "sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==", - "dev": true, - "dependencies": { - "type-detect": "^4.0.0" - }, - "engines": { - "node": ">=0.12" - } - }, - "node_modules/deep-equal": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-1.1.1.tgz", - "integrity": "sha512-yd9c5AdiqVcR+JjcwUQb9DkhJc8ngNr0MahEBGvDiJw8puWab2yZlh+nkasOnZP+EGTAP6rRp2JzJhJZzvNF8g==", - "dev": true, - "dependencies": { - "is-arguments": "^1.0.4", - "is-date-object": "^1.0.1", - "is-regex": "^1.0.4", - "object-is": "^1.0.1", - "object-keys": "^1.1.1", - "regexp.prototype.flags": "^1.2.0" + "character-entities": "^2.0.0" }, "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/deep-extend": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", - "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", - "dev": true, - "engines": { - "node": ">=4.0.0" + "type": "github", + "url": "https://github.com/sponsors/wooorm" } }, "node_modules/deep-is": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz", - "integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=", + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", + "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==", "dev": true }, "node_modules/default-require-extensions": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/default-require-extensions/-/default-require-extensions-3.0.0.tgz", - "integrity": "sha512-ek6DpXq/SCpvjhpFsLFRVtIxJCRw6fUR42lYMVZuUMK7n8eMz4Uh5clckdBjEpLhn/gEBZo7hDJnJcwdKLKQjg==", + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/default-require-extensions/-/default-require-extensions-3.0.1.tgz", + "integrity": "sha512-eXTJmRbm2TIt9MgWTsOH1wEuhew6XGZcMeGKCtLedIg/NCsg1iBePXkceTdK4Fii7pzmN9tGsZhKzZ4h7O/fxw==", "dev": true, "dependencies": { "strip-bom": "^4.0.0" }, "engines": { "node": ">=8" - } - }, - "node_modules/default-require-extensions/node_modules/strip-bom": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-4.0.0.tgz", - "integrity": "sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w==", - "dev": true, - "engines": { - "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/defaults": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/defaults/-/defaults-1.0.3.tgz", - "integrity": "sha1-xlYFHpgX2f8I7YgUd/P+QBnz730=", "inBundle": true, + "license": "MIT", "dependencies": { "clone": "^1.0.2" } }, "node_modules/define-properties": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", - "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.4.tgz", + "integrity": "sha512-uckOqKcfaVvtBdsVkdPv3XjveQJsNQqmhXgRi8uhvWWuPYZCNlzT8qAyblUgNoXdHdjMTzAqeGjAoli8f+bzPA==", "dev": true, + "peer": true, "dependencies": { - "object-keys": "^1.0.12" + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" }, "engines": { "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, "node_modules/delayed-stream": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", "dev": true, "engines": { "node": ">=0.4.0" @@ -2395,58 +4000,44 @@ }, "node_modules/delegates": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz", - "integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=", - "inBundle": true + "inBundle": true, + "license": "MIT" }, "node_modules/depd": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", - "integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak=", "inBundle": true, + "license": "MIT", "engines": { "node": ">= 0.6" } }, - "node_modules/detab": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/detab/-/detab-2.0.4.tgz", - "integrity": "sha512-8zdsQA5bIkoRECvCrNKPla84lyoR7DSAyf7p0YgXzBO9PDJx8KntPUay7NS6yp+KdxdVtiE5SpHKtbp2ZQyA9g==", - "dev": true, - "dependencies": { - "repeat-string": "^1.5.4" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } + "node_modules/deprecation": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/deprecation/-/deprecation-2.3.1.tgz", + "integrity": "sha512-xmHIy4F3scKVwMsQ4WnVaS8bHOx0DmVwRywosKhaILI0ywMDWPtBSku2HNxRvF7jtwDRsoEwYQSfbxj8b7RlJQ==", + "dev": true }, - "node_modules/detect-libc": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz", - "integrity": "sha1-+hN8S9aY7fVc1c0CrFWfkaTEups=", + "node_modules/dequal": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/dequal/-/dequal-2.0.3.tgz", + "integrity": "sha512-0je+qPKHEMohvfRTCEo3CrPG6cAzAYgmzKyxRiYSSDkS6eGJdyVJm7WaYA5ECaAD9wLB2T4EEeymA5aFVcYXCA==", "dev": true, - "bin": { - "detect-libc": "bin/detect-libc.js" - }, "engines": { - "node": ">=0.10" + "node": ">=6" } }, - "node_modules/dezalgo": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/dezalgo/-/dezalgo-1.0.3.tgz", - "integrity": "sha1-f3Qt4Gb8dIvI24IFad3c5Jvw1FY=", - "inBundle": true, - "dependencies": { - "asap": "^2.0.0", - "wrappy": "1" + "node_modules/detect-indent": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/detect-indent/-/detect-indent-6.1.0.tgz", + "integrity": "sha512-reYkTUJAZb9gUuZ2RvVCNhVHdg62RHnJ7WJl8ftMi4diZ6NWlciOzQN88pUhSELEwflJht4oQDv0F0BMlwaYtA==", + "dev": true, + "engines": { + "node": ">=8" } }, "node_modules/diff": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz", - "integrity": "sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w==", + "version": "5.1.0", + "license": "BSD-3-Clause", "engines": { "node": ">=0.3.1" } @@ -2454,21 +4045,18 @@ "node_modules/docopt": { "version": "0.6.2", "resolved": "https://registry.npmjs.org/docopt/-/docopt-0.6.2.tgz", - "integrity": "sha1-so6eIiDaXsSffqW7JKR3h0Be6xE=", + "integrity": "sha512-NqTbaYeE4gA/wU1hdKFdU+AFahpDOpgGLzHP42k6H6DKExJd0A55KEVWYhL9FEmHmgeLvEU2vuKXDuU+4yToOw==", "dev": true, "engines": { "node": ">=0.10.0" } }, - "node_modules/docs": { - "resolved": "docs", - "link": true - }, "node_modules/doctrine": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", "dev": true, + "peer": true, "dependencies": { "esutils": "^2.0.2" }, @@ -2476,6 +4064,32 @@ "node": ">=6.0.0" } }, + "node_modules/dom-serializer": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz", + "integrity": "sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==", + "dev": true, + "dependencies": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.0", + "entities": "^2.0.0" + }, + "funding": { + "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" + } + }, + "node_modules/domelementtype": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.3.0.tgz", + "integrity": "sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ] + }, "node_modules/domexception": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/domexception/-/domexception-4.0.0.tgz", @@ -2488,94 +4102,144 @@ "node": ">=12" } }, - "node_modules/ecc-jsbn": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", - "integrity": "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=", + "node_modules/domexception/node_modules/webidl-conversions": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", + "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", + "dev": true, + "engines": { + "node": ">=12" + } + }, + "node_modules/domhandler": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", + "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", "dev": true, "dependencies": { - "jsbn": "~0.1.0", - "safer-buffer": "^2.1.0" + "domelementtype": "^2.2.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" } }, + "node_modules/domutils": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", + "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", + "dev": true, + "dependencies": { + "dom-serializer": "^1.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0" + }, + "funding": { + "url": "https://github.com/fb55/domutils?sponsor=1" + } + }, + "node_modules/dot-prop": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/dot-prop/-/dot-prop-5.3.0.tgz", + "integrity": "sha512-QM8q3zDe58hqUqjraQOmzZ1LIH9SWQJTlEKCH4kJ2oQvLZk7RbQXvtDM2XEq3fwkV9CCvvH4LA0AV+ogFsBM2Q==", + "dev": true, + "dependencies": { + "is-obj": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==", + "dev": true + }, + "node_modules/electron-to-chromium": { + "version": "1.4.284", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.284.tgz", + "integrity": "sha512-M8WEXFuKXMYMVr45fo8mq0wUrrJHheiKZf6BArTKk9ZBYCKJEOU5H8cdWgDT+qCVZf7Na4lVUaZsA+h6uA9+PA==", + "dev": true + }, "node_modules/emoji-regex": { "version": "8.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", - "inBundle": true + "inBundle": true, + "license": "MIT" }, "node_modules/encoding": { "version": "0.1.13", - "resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.13.tgz", - "integrity": "sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==", "inBundle": true, + "license": "MIT", "optional": true, "dependencies": { "iconv-lite": "^0.6.2" } }, - "node_modules/end-of-stream": { - "version": "1.4.4", - "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", - "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", + "node_modules/entities": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", + "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==", "dev": true, - "dependencies": { - "once": "^1.4.0" - } - }, - "node_modules/enquirer": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.3.6.tgz", - "integrity": "sha512-yjNnPr315/FjS4zIsUxYguYUPP2e1NK4d7E7ZOLiyYCcbFBiTMyID+2wvm2w6+pZ/odMA7cRkjhsPbltwBOrLg==", - "dev": true, - "dependencies": { - "ansi-colors": "^4.1.1" - }, - "engines": { - "node": ">=8.6" + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" } }, "node_modules/env-paths": { "version": "2.2.1", - "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz", - "integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==", "inBundle": true, + "license": "MIT", "engines": { "node": ">=6" } }, "node_modules/err-code": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/err-code/-/err-code-2.0.3.tgz", - "integrity": "sha512-2bmlRpNKBxT/CRmPOlyISQpNj+qSeYvcym/uT0Jx2bMOlKLtSy1ZmLuVxSEKKyor/N5yhvp/ZiG1oE3DEYMSFA==", - "inBundle": true + "inBundle": true, + "license": "MIT" + }, + "node_modules/error-ex": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", + "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", + "dev": true, + "dependencies": { + "is-arrayish": "^0.2.1" + } }, "node_modules/es-abstract": { - "version": "1.19.1", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.19.1.tgz", - "integrity": "sha512-2vJ6tjA/UfqLm2MPs7jxVybLoB8i1t1Jd9R3kISld20sIxPcTbLuggQOUxeWeAvIUkduv/CfMjuh4WmiXr2v9w==", + "version": "1.20.4", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.20.4.tgz", + "integrity": "sha512-0UtvRN79eMe2L+UNEF1BwRe364sj/DXhQ/k5FmivgoSdpM90b8Jc0mDzKMGo7QS0BVbOP/bTwBKNnDc9rNzaPA==", "dev": true, + "peer": true, "dependencies": { "call-bind": "^1.0.2", "es-to-primitive": "^1.2.1", "function-bind": "^1.1.1", - "get-intrinsic": "^1.1.1", + "function.prototype.name": "^1.1.5", + "get-intrinsic": "^1.1.3", "get-symbol-description": "^1.0.0", "has": "^1.0.3", - "has-symbols": "^1.0.2", + "has-property-descriptors": "^1.0.0", + "has-symbols": "^1.0.3", "internal-slot": "^1.0.3", - "is-callable": "^1.2.4", - "is-negative-zero": "^2.0.1", + "is-callable": "^1.2.7", + "is-negative-zero": "^2.0.2", "is-regex": "^1.1.4", - "is-shared-array-buffer": "^1.0.1", + "is-shared-array-buffer": "^1.0.2", "is-string": "^1.0.7", - "is-weakref": "^1.0.1", - "object-inspect": "^1.11.0", + "is-weakref": "^1.0.2", + "object-inspect": "^1.12.2", "object-keys": "^1.1.1", - "object.assign": "^4.1.2", - "string.prototype.trimend": "^1.0.4", - "string.prototype.trimstart": "^1.0.4", - "unbox-primitive": "^1.0.1" + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.4.3", + "safe-regex-test": "^1.0.0", + "string.prototype.trimend": "^1.0.5", + "string.prototype.trimstart": "^1.0.5", + "unbox-primitive": "^1.0.2" }, "engines": { "node": ">= 0.4" @@ -2584,11 +4248,22 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/es-shim-unscopables": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-shim-unscopables/-/es-shim-unscopables-1.0.0.tgz", + "integrity": "sha512-Jm6GPcCdC30eMLbZ2x8z2WuRwAws3zTBBKuusffYVUrNj/GVSUAZ+xKMaUpfNDR5IbyNA5LJbaecoUVbmUcB1w==", + "dev": true, + "peer": true, + "dependencies": { + "has": "^1.0.3" + } + }, "node_modules/es-to-primitive": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", "dev": true, + "peer": true, "dependencies": { "is-callable": "^1.1.4", "is-date-object": "^1.0.1", @@ -2607,11 +4282,21 @@ "integrity": "sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg==", "dev": true }, + "node_modules/escalade": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", + "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", + "dev": true, + "engines": { + "node": ">=6" + } + }, "node_modules/escape-string-regexp": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", "dev": true, + "peer": true, "engines": { "node": ">=10" }, @@ -2620,13 +4305,13 @@ } }, "node_modules/escodegen": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-2.0.0.tgz", - "integrity": "sha512-mmHKys/C8BFUGI+MAWNcSYoORYLMdPzjrknd2Vc+bUsjN5bXcr8EhrNB+UTqfL1y3I9c4fw2ihgtMPQLBRiQxw==", + "version": "1.14.3", + "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.14.3.tgz", + "integrity": "sha512-qFcX0XJkdg+PB3xjZZG/wKSuT1PnQWx57+TVSjIMmILd2yC/6ByYElPwJnslDsuWuSAp4AwJGumarAAmJch5Kw==", "dev": true, "dependencies": { "esprima": "^4.0.1", - "estraverse": "^5.2.0", + "estraverse": "^4.2.0", "esutils": "^2.0.2", "optionator": "^0.8.1" }, @@ -2635,16 +4320,38 @@ "esgenerate": "bin/esgenerate.js" }, "engines": { - "node": ">=6.0" + "node": ">=4.0" }, "optionalDependencies": { "source-map": "~0.6.1" } }, + "node_modules/escodegen/node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/escodegen/node_modules/estraverse": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", + "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==", + "dev": true, + "engines": { + "node": ">=4.0" + } + }, "node_modules/escodegen/node_modules/levn": { "version": "0.3.0", "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", - "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=", + "integrity": "sha512-0OO4y2iOHix2W6ujICbKIaEQXvFQHue65vUG3pb5EUomzPI90z9hsA1VsO/dbIIpC53J8gxM9Q4Oho0jrCM/yA==", "dev": true, "dependencies": { "prelude-ls": "~1.1.2", @@ -2674,26 +4381,16 @@ "node_modules/escodegen/node_modules/prelude-ls": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", - "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=", + "integrity": "sha512-ESF23V4SKG6lVSGZgYNpbsiaAkdab6ZgOxe52p7+Kid3W3u3bxR4Vfd/o21dmN7jSt0IwgZ4v5MUd26FEtXE9w==", "dev": true, "engines": { "node": ">= 0.8.0" } }, - "node_modules/escodegen/node_modules/source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true, - "optional": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/escodegen/node_modules/type-check": { "version": "0.3.2", "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", - "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=", + "integrity": "sha512-ZCmOJdvOWDBYJlzAoFkC+Q0+bUyEOS1ltgp1MGU03fqHG+dbi9tBFU2Rd9QKiDZFAYrhPh2JUf7rZRIuHRKtOg==", "dev": true, "dependencies": { "prelude-ls": "~1.1.2" @@ -2703,49 +4400,51 @@ } }, "node_modules/eslint": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.3.0.tgz", - "integrity": "sha512-aIay56Ph6RxOTC7xyr59Kt3ewX185SaGnAr8eWukoPLeriCrvGjvAubxuvaXOfsxhtwV5g0uBOsyhAom4qJdww==", + "version": "8.27.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.27.0.tgz", + "integrity": "sha512-0y1bfG2ho7mty+SiILVf9PfuRA49ek4Nc60Wmmu62QlobNR+CeXa4xXIJgcuwSQgZiWaPH+5BDsctpIW0PR/wQ==", "dev": true, + "peer": true, "dependencies": { - "@eslint/eslintrc": "^1.0.4", - "@humanwhocodes/config-array": "^0.6.0", + "@eslint/eslintrc": "^1.3.3", + "@humanwhocodes/config-array": "^0.11.6", + "@humanwhocodes/module-importer": "^1.0.1", + "@nodelib/fs.walk": "^1.2.8", "ajv": "^6.10.0", "chalk": "^4.0.0", "cross-spawn": "^7.0.2", "debug": "^4.3.2", "doctrine": "^3.0.0", - "enquirer": "^2.3.5", "escape-string-regexp": "^4.0.0", - "eslint-scope": "^7.1.0", + "eslint-scope": "^7.1.1", "eslint-utils": "^3.0.0", - "eslint-visitor-keys": "^3.1.0", - "espree": "^9.1.0", + "eslint-visitor-keys": "^3.3.0", + "espree": "^9.4.0", "esquery": "^1.4.0", "esutils": "^2.0.2", "fast-deep-equal": "^3.1.3", "file-entry-cache": "^6.0.1", - "functional-red-black-tree": "^1.0.1", - "glob-parent": "^6.0.1", - "globals": "^13.6.0", - "ignore": "^4.0.6", + "find-up": "^5.0.0", + "glob-parent": "^6.0.2", + "globals": "^13.15.0", + "grapheme-splitter": "^1.0.4", + "ignore": "^5.2.0", "import-fresh": "^3.0.0", "imurmurhash": "^0.1.4", "is-glob": "^4.0.0", + "is-path-inside": "^3.0.3", + "js-sdsl": "^4.1.4", "js-yaml": "^4.1.0", "json-stable-stringify-without-jsonify": "^1.0.1", "levn": "^0.4.1", "lodash.merge": "^4.6.2", - "minimatch": "^3.0.4", + "minimatch": "^3.1.2", "natural-compare": "^1.4.0", "optionator": "^0.9.1", - "progress": "^2.0.0", "regexpp": "^3.2.0", - "semver": "^7.2.1", "strip-ansi": "^6.0.1", "strip-json-comments": "^3.1.0", - "text-table": "^0.2.0", - "v8-compile-cache": "^2.0.3" + "text-table": "^0.2.0" }, "bin": { "eslint": "bin/eslint.js" @@ -2757,6 +4456,55 @@ "url": "https://opencollective.com/eslint" } }, + "node_modules/eslint-import-resolver-node": { + "version": "0.3.6", + "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.6.tgz", + "integrity": "sha512-0En0w03NRVMn9Uiyn8YRPDKvWjxCWkslUEhGNTdGx15RvPJYQ+lbOlqrlNI2vEAs4pDYK4f/HN2TbDmk5TP0iw==", + "dev": true, + "peer": true, + "dependencies": { + "debug": "^3.2.7", + "resolve": "^1.20.0" + } + }, + "node_modules/eslint-import-resolver-node/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, + "peer": true, + "dependencies": { + "ms": "^2.1.1" + } + }, + "node_modules/eslint-module-utils": { + "version": "2.7.4", + "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.7.4.tgz", + "integrity": "sha512-j4GT+rqzCoRKHwURX7pddtIPGySnX9Si/cgMI5ztrcqOPtk5dDEeZ34CQVPphnqkJytlc97Vuk05Um2mJ3gEQA==", + "dev": true, + "peer": true, + "dependencies": { + "debug": "^3.2.7" + }, + "engines": { + "node": ">=4" + }, + "peerDependenciesMeta": { + "eslint": { + "optional": true + } + } + }, + "node_modules/eslint-module-utils/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, + "peer": true, + "dependencies": { + "ms": "^2.1.1" + } + }, "node_modules/eslint-plugin-es": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/eslint-plugin-es/-/eslint-plugin-es-3.0.1.tgz", @@ -2777,6 +4525,114 @@ "eslint": ">=4.19.1" } }, + "node_modules/eslint-plugin-es/node_modules/eslint-utils": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-2.1.0.tgz", + "integrity": "sha512-w94dQYoauyvlDc43XnGB8lU3Zt713vNChgt4EWwhXAP2XkBvndfxF0AgIqKOOasjPIPzj9JqgwkwbCYD0/V3Zg==", + "dev": true, + "peer": true, + "dependencies": { + "eslint-visitor-keys": "^1.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + } + }, + "node_modules/eslint-plugin-es/node_modules/eslint-visitor-keys": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz", + "integrity": "sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==", + "dev": true, + "peer": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/eslint-plugin-import": { + "version": "2.26.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.26.0.tgz", + "integrity": "sha512-hYfi3FXaM8WPLf4S1cikh/r4IxnO6zrhZbEGz2b660EJRbuxgpDS5gkCuYgGWg2xxh2rBuIr4Pvhve/7c31koA==", + "dev": true, + "peer": true, + "dependencies": { + "array-includes": "^3.1.4", + "array.prototype.flat": "^1.2.5", + "debug": "^2.6.9", + "doctrine": "^2.1.0", + "eslint-import-resolver-node": "^0.3.6", + "eslint-module-utils": "^2.7.3", + "has": "^1.0.3", + "is-core-module": "^2.8.1", + "is-glob": "^4.0.3", + "minimatch": "^3.1.2", + "object.values": "^1.1.5", + "resolve": "^1.22.0", + "tsconfig-paths": "^3.14.1" + }, + "engines": { + "node": ">=4" + }, + "peerDependencies": { + "eslint": "^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8" + } + }, + "node_modules/eslint-plugin-import/node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "peer": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/eslint-plugin-import/node_modules/debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, + "peer": true, + "dependencies": { + "ms": "2.0.0" + } + }, + "node_modules/eslint-plugin-import/node_modules/doctrine": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", + "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==", + "dev": true, + "peer": true, + "dependencies": { + "esutils": "^2.0.2" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/eslint-plugin-import/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "peer": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/eslint-plugin-import/node_modules/ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", + "dev": true, + "peer": true + }, "node_modules/eslint-plugin-node": { "version": "11.1.0", "resolved": "https://registry.npmjs.org/eslint-plugin-node/-/eslint-plugin-node-11.1.0.tgz", @@ -2798,40 +4654,18 @@ "eslint": ">=5.16.0" } }, - "node_modules/eslint-plugin-node/node_modules/ignore": { - "version": "5.1.8", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.1.8.tgz", - "integrity": "sha512-BMpfD7PpiETpBl/A6S498BaIJ6Y/ABT93ETbby2fP00v4EbvPBXWEoaR1UBPKs3iR53pJY7EtZk5KACI57i1Uw==", + "node_modules/eslint-plugin-node/node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "dev": true, "peer": true, - "engines": { - "node": ">= 4" - } - }, - "node_modules/eslint-plugin-node/node_modules/semver": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", - "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", - "dev": true, - "peer": true, - "bin": { - "semver": "bin/semver.js" - } - }, - "node_modules/eslint-scope": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.1.0.tgz", - "integrity": "sha512-aWwkhnS0qAXqNOgKOK0dJ2nvzEbhEvpy8OlJ9kZ0FeZnA6zpjv1/Vei+puGFFX7zkPCkHHXb7IDX3A+7yPrRWg==", - "dev": true, "dependencies": { - "esrecurse": "^4.3.0", - "estraverse": "^5.2.0" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" } }, - "node_modules/eslint-utils": { + "node_modules/eslint-plugin-node/node_modules/eslint-utils": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-2.1.0.tgz", "integrity": "sha512-w94dQYoauyvlDc43XnGB8lU3Zt713vNChgt4EWwhXAP2XkBvndfxF0AgIqKOOasjPIPzj9JqgwkwbCYD0/V3Zg==", @@ -2847,7 +4681,7 @@ "url": "https://github.com/sponsors/mysticatea" } }, - "node_modules/eslint-utils/node_modules/eslint-visitor-keys": { + "node_modules/eslint-plugin-node/node_modules/eslint-visitor-keys": { "version": "1.3.0", "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz", "integrity": "sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==", @@ -2857,35 +4691,62 @@ "node": ">=4" } }, - "node_modules/eslint-visitor-keys": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.1.0.tgz", - "integrity": "sha512-yWJFpu4DtjsWKkt5GeNBBuZMlNcYVs6vRCLoCVEJrTjaSB6LC98gFipNK/erM2Heg/E8mIK+hXG/pJMLK+eRZA==", + "node_modules/eslint-plugin-node/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", "dev": true, + "peer": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/eslint-plugin-node/node_modules/semver": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", + "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", + "dev": true, + "peer": true, + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/eslint-plugin-promise": { + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/eslint-plugin-promise/-/eslint-plugin-promise-6.1.1.tgz", + "integrity": "sha512-tjqWDwVZQo7UIPMeDReOpUgHCmCiH+ePnVT+5zVapL0uuHnegBUs2smM13CzOs2Xb5+MHMRFTs9v24yjba4Oig==", + "dev": true, + "peer": true, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "peerDependencies": { + "eslint": "^7.0.0 || ^8.0.0" + } + }, + "node_modules/eslint-scope": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.1.1.tgz", + "integrity": "sha512-QKQM/UXpIiHcLqJ5AOyIW7XZmzjkzQXYE54n1++wb0u9V/abW3l9uQnxX8Z5Xd18xyKIMTUAyQ0k1e8pz6LUrw==", + "dev": true, + "peer": true, + "dependencies": { + "esrecurse": "^4.3.0", + "estraverse": "^5.2.0" + }, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } }, - "node_modules/eslint/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/eslint/node_modules/argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "dev": true - }, - "node_modules/eslint/node_modules/eslint-utils": { + "node_modules/eslint-utils": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-3.0.0.tgz", "integrity": "sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA==", "dev": true, + "peer": true, "dependencies": { "eslint-visitor-keys": "^2.0.0" }, @@ -2899,115 +4760,103 @@ "eslint": ">=5" } }, - "node_modules/eslint/node_modules/eslint-utils/node_modules/eslint-visitor-keys": { + "node_modules/eslint-utils/node_modules/eslint-visitor-keys": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz", "integrity": "sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw==", "dev": true, + "peer": true, "engines": { "node": ">=10" } }, - "node_modules/eslint/node_modules/glob-parent": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", - "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", + "node_modules/eslint-visitor-keys": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.3.0.tgz", + "integrity": "sha512-mQ+suqKJVyeuwGYHAdjMFqjCyfl8+Ldnxuyp3ldiMBFKkvytrXUZWaiPCEav8qDHKty44bD+qV1IP4T+w+xXRA==", "dev": true, - "dependencies": { - "is-glob": "^4.0.3" - }, - "engines": { - "node": ">=10.13.0" - } - }, - "node_modules/eslint/node_modules/globals": { - "version": "13.9.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.9.0.tgz", - "integrity": "sha512-74/FduwI/JaIrr1H8e71UbDE+5x7pIPs1C2rrwC52SszOo043CsWOZEMW7o2Y58xwm9b+0RBKDxY5n2sUpEFxA==", - "dev": true, - "dependencies": { - "type-fest": "^0.20.2" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/eslint/node_modules/js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", - "dev": true, - "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, - "node_modules/eslint/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/eslint/node_modules/type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/espree": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/espree/-/espree-9.1.0.tgz", - "integrity": "sha512-ZgYLvCS1wxOczBYGcQT9DDWgicXwJ4dbocr9uYN+/eresBAUuBu+O4WzB21ufQ/JqQT8gyp7hJ3z8SHii32mTQ==", - "dev": true, - "dependencies": { - "acorn": "^8.6.0", - "acorn-jsx": "^5.3.1", - "eslint-visitor-keys": "^3.1.0" - }, + "peer": true, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } }, - "node_modules/espree/node_modules/acorn": { - "version": "8.6.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.6.0.tgz", - "integrity": "sha512-U1riIR+lBSNi3IbxtaHOIKdH8sLFv3NYfNv8sg7ZsNhcfl4HF2++BfqqrNAxoCLQW1iiylOj76ecnaUxz+z9yw==", + "node_modules/eslint/node_modules/ajv": { + "version": "6.12.6", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", + "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", "dev": true, - "bin": { - "acorn": "bin/acorn" + "peer": true, + "dependencies": { + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/eslint/node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "peer": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/eslint/node_modules/json-schema-traverse": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", + "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", + "dev": true, + "peer": true + }, + "node_modules/eslint/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "peer": true, + "dependencies": { + "brace-expansion": "^1.1.7" }, "engines": { - "node": ">=0.4.0" + "node": "*" + } + }, + "node_modules/espree": { + "version": "9.4.1", + "resolved": "https://registry.npmjs.org/espree/-/espree-9.4.1.tgz", + "integrity": "sha512-XwctdmTO6SIvCzd9810yyNzIrOrqNYV9Koizx4C/mRhf9uq0o4yHoCEU/670pOxOL/MSraektvSAji79kX90Vg==", + "dev": true, + "peer": true, + "dependencies": { + "acorn": "^8.8.0", + "acorn-jsx": "^5.3.2", + "eslint-visitor-keys": "^3.3.0" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, "node_modules/esprima": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-1.2.2.tgz", + "integrity": "sha512-+JpPZam9w5DuJ3Q67SqsMGtiHKENSMRVoxvArfJZK01/BfLEObtZ6orJa/MtoGNR/rfMgp5837T41PAmTwAv/A==", "dev": true, "bin": { "esparse": "bin/esparse.js", "esvalidate": "bin/esvalidate.js" }, "engines": { - "node": ">=4" + "node": ">=0.4.0" } }, "node_modules/esquery": { @@ -3015,6 +4864,7 @@ "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.4.0.tgz", "integrity": "sha512-cCDispWt5vHHtwMY2YrAQ4ibFkAL8RbH5YGBnZBc90MolvvfkkQcJro/aZiAQUlQ3qgrYS6D6v8Gc5G5CQsc9w==", "dev": true, + "peer": true, "dependencies": { "estraverse": "^5.1.0" }, @@ -3027,6 +4877,7 @@ "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", "dev": true, + "peer": true, "dependencies": { "estraverse": "^5.2.0" }, @@ -3052,19 +4903,55 @@ "node": ">=0.10.0" } }, + "node_modules/event-target-shim": { + "version": "5.0.1", + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/eventemitter3": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", + "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==", + "dev": true + }, + "node_modules/events": { + "version": "3.3.0", + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=0.8.x" + } + }, "node_modules/events-to-array": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/events-to-array/-/events-to-array-1.1.2.tgz", - "integrity": "sha1-LUH1Y+H+QA7Uli/hpNXGp1Od9/Y=", + "integrity": "sha512-inRWzRY7nG+aXZxBzEqYKB3HPgwflZRopAjDCHv0whhRx+MTUr1ei0ICZUypdyE0HRm4L2d5VEcIqLD6yl+BFA==", "dev": true }, - "node_modules/expand-template": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/expand-template/-/expand-template-2.0.3.tgz", - "integrity": "sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==", + "node_modules/execa": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", "dev": true, + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, "engines": { - "node": ">=6" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" } }, "node_modules/extend": { @@ -3073,15 +4960,6 @@ "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==", "dev": true }, - "node_modules/extsprintf": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", - "integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=", - "dev": true, - "engines": [ - "node >=0.6.0" - ] - }, "node_modules/fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", @@ -3092,25 +4970,63 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", - "dev": true + "dev": true, + "peer": true }, "node_modules/fast-levenshtein": { "version": "2.0.6", "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", - "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=", + "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==", "dev": true }, "node_modules/fastest-levenshtein": { - "version": "1.0.12", - "resolved": "https://registry.npmjs.org/fastest-levenshtein/-/fastest-levenshtein-1.0.12.tgz", - "integrity": "sha512-On2N+BpYJ15xIC974QNVuYGMOlEVt4s0EOI3wwMqOmK1fdDY+FN/zltPV8vosq4ad4c/gJ1KHScUn/6AWIgiow==", - "inBundle": true + "version": "1.0.16", + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">= 4.9.1" + } + }, + "node_modules/fastq": { + "version": "1.13.0", + "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.13.0.tgz", + "integrity": "sha512-YpkpUnK8od0o1hmeSc7UUs/eB/vIPWJYjKck2QKIzAf71Vm1AAQ3EbuZB3g2JIy+pg+ERD0vqI79KyZiB2e2Nw==", + "dev": true, + "peer": true, + "dependencies": { + "reusify": "^1.0.4" + } + }, + "node_modules/figures": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz", + "integrity": "sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==", + "dev": true, + "dependencies": { + "escape-string-regexp": "^1.0.5" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/figures/node_modules/escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", + "dev": true, + "engines": { + "node": ">=0.8.0" + } }, "node_modules/file-entry-cache": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz", "integrity": "sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==", "dev": true, + "peer": true, "dependencies": { "flat-cache": "^3.0.4" }, @@ -3118,12 +5034,6 @@ "node": "^10.12.0 || >=12.0.0" } }, - "node_modules/file-uri-to-path": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", - "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==", - "dev": true - }, "node_modules/fill-range": { "version": "7.0.1", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", @@ -3137,9 +5047,9 @@ } }, "node_modules/find-cache-dir": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-3.3.1.tgz", - "integrity": "sha512-t2GDMt3oGC/v+BMwzmllWDuJF/xcDtE5j/fCGbqDD7OLuJkj0cfh1YSA5VKPvwMeLFLNDBkwOKZ2X85jGLVftQ==", + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-3.3.2.tgz", + "integrity": "sha512-wXZV5emFEjrridIgED11OoUKLxiYjAcqot/NJdAkOhlJ+vGzwhOAfcG5OX1jP+S0PcjEn8bdMJv+g2jwQ3Onig==", "dev": true, "dependencies": { "commondir": "^1.0.1", @@ -3153,92 +5063,26 @@ "url": "https://github.com/avajs/find-cache-dir?sponsor=1" } }, - "node_modules/find-cache-dir/node_modules/find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "node_modules/find-up": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", "dev": true, "dependencies": { - "locate-path": "^5.0.0", + "locate-path": "^6.0.0", "path-exists": "^4.0.0" }, "engines": { - "node": ">=8" - } - }, - "node_modules/find-cache-dir/node_modules/locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", - "dev": true, - "dependencies": { - "p-locate": "^4.1.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/find-cache-dir/node_modules/p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "dev": true, - "dependencies": { - "p-try": "^2.0.0" - }, - "engines": { - "node": ">=6" + "node": ">=10" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/find-cache-dir/node_modules/p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", - "dev": true, - "dependencies": { - "p-limit": "^2.2.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/find-cache-dir/node_modules/p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/find-cache-dir/node_modules/path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/find-cache-dir/node_modules/pkg-dir": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz", - "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==", - "dev": true, - "dependencies": { - "find-up": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/findit": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/findit/-/findit-2.0.0.tgz", - "integrity": "sha1-ZQnwEmr0wXhVHPqZOU4DLhOk1W4=", + "integrity": "sha512-ENZS237/Hr8bjczn5eKuBohLgaD0JyUd0arxretR1f9RO46vZHA1b2y0VorgGV3WaOT3c+78P8h7v4JGJ1i/rg==", "dev": true }, "node_modules/flat-cache": { @@ -3246,6 +5090,7 @@ "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.0.4.tgz", "integrity": "sha512-dm9s5Pw7Jc0GvMYbshN6zchCA9RgQlzzEZX3vylR9IqFfS8XciblUXOKfW6SiuJ0e13eDYZoZV5wdrev7P3Nwg==", "dev": true, + "peer": true, "dependencies": { "flatted": "^3.1.0", "rimraf": "^3.0.2" @@ -3255,40 +5100,30 @@ } }, "node_modules/flatted": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.1.1.tgz", - "integrity": "sha512-zAoAQiudy+r5SvnSw3KJy5os/oRJYHzrzja/tBDqrZtNhUw8bt6y8OBzMWcjWr+8liV8Eb6yOhw8WZ7VFZ5ZzA==", - "dev": true - }, - "node_modules/flow-parser": { - "version": "0.166.1", - "resolved": "https://registry.npmjs.org/flow-parser/-/flow-parser-0.166.1.tgz", - "integrity": "sha512-7iJ1cPcOYL/eOPGpGPaxwW8MytKGeXSnfvJA0uIvymXI4MnjjhZLWz1qPIqj2hfYJ7p/yXssbv7k2H3C90cyDw==", + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.2.7.tgz", + "integrity": "sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==", "dev": true, - "optional": true, - "peer": true, - "engines": { - "node": ">=0.4.0" - } + "peer": true }, - "node_modules/flow-remove-types": { - "version": "2.166.1", - "resolved": "https://registry.npmjs.org/flow-remove-types/-/flow-remove-types-2.166.1.tgz", - "integrity": "sha512-PR3iOoNgEakzeHxEnem9TctSnLzkmpGByFUDKpY6N6MGx/Jft/irJREPTsCZ5SOZ//YVcwX0BbfjL3WeXhJdAg==", + "node_modules/follow-redirects": { + "version": "1.15.2", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz", + "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==", "dev": true, - "optional": true, - "peer": true, - "dependencies": { - "flow-parser": "^0.166.1", - "pirates": "^3.0.2", - "vlq": "^0.2.1" - }, - "bin": { - "flow-node": "flow-node", - "flow-remove-types": "flow-remove-types" - }, + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], "engines": { - "node": ">=4" + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } } }, "node_modules/foreground-child": { @@ -3304,15 +5139,6 @@ "node": ">=8.0.0" } }, - "node_modules/forever-agent": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", - "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=", - "dev": true, - "engines": { - "node": "*" - } - }, "node_modules/form-data": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", @@ -3347,36 +5173,74 @@ } ] }, - "node_modules/fs-access": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/fs-access/-/fs-access-2.0.0.tgz", - "integrity": "sha512-Vt45hBKJrYDQeAD9ja43liw8JfK75uB7XexIXWEtDKwFLQNmzmvuulh28hRxexxuFm0zsGGq7nISGQSK6KnGrA==", - "deprecated": "This package is no longer relevant as Node.js 0.12 is unmaintained.", + "node_modules/front-matter": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/front-matter/-/front-matter-4.0.2.tgz", + "integrity": "sha512-I8ZuJ/qG92NWX8i5x1Y8qyj3vizhXS31OxjKDu3LKP+7/qBgfIKValiZIEwoVoJKUHlhWtYrktkxV1XsX+pPlg==", "dev": true, "dependencies": { - "null-check": "^1.0.0" - }, - "engines": { - "node": ">=0.10.0" + "js-yaml": "^3.13.1" } }, - "node_modules/fs-constants": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz", - "integrity": "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==", - "dev": true + "node_modules/front-matter/node_modules/argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "dependencies": { + "sprintf-js": "~1.0.2" + } + }, + "node_modules/front-matter/node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/front-matter/node_modules/js-yaml": { + "version": "3.14.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", + "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", + "dev": true, + "dependencies": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } }, "node_modules/fs-exists-cached": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/fs-exists-cached/-/fs-exists-cached-1.0.0.tgz", - "integrity": "sha1-zyVVTKBQ3EmuZla0HeQiWJidy84=", + "integrity": "sha512-kSxoARUDn4F2RPXX48UXnaFKwVU7Ivd/6qpzZL29MCDmr9sTvybv4gFCp+qaI4fM9m0z9fgz/yJvi56GAz+BZg==", "dev": true }, + "node_modules/fs-extra": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz", + "integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==", + "dev": true, + "dependencies": { + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=12" + } + }, "node_modules/fs-minipass": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", - "integrity": "sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==", "inBundle": true, + "license": "ISC", "dependencies": { "minipass": "^3.0.0" }, @@ -3384,11 +5248,22 @@ "node": ">= 8" } }, + "node_modules/fs-minipass/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", + "inBundle": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/fs.realpath": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", - "inBundle": true + "inBundle": true, + "license": "ISC" }, "node_modules/fsevents": { "version": "2.3.2", @@ -3406,9 +5281,8 @@ }, "node_modules/function-bind": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", - "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", - "inBundle": true + "inBundle": true, + "license": "MIT" }, "node_modules/function-loop": { "version": "2.0.1", @@ -3416,74 +5290,51 @@ "integrity": "sha512-ktIR+O6i/4h+j/ZhZJNdzeI4i9lEPeEK6UPR2EVyTVBqOwcU3Za9xYKLH64ZR9HmcROyRrOkizNyjjtWJzDDkQ==", "dev": true }, - "node_modules/functional-red-black-tree": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz", - "integrity": "sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc=", - "dev": true + "node_modules/function.prototype.name": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.5.tgz", + "integrity": "sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA==", + "dev": true, + "peer": true, + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.3", + "es-abstract": "^1.19.0", + "functions-have-names": "^1.2.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", + "dev": true, + "peer": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } }, "node_modules/gauge": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/gauge/-/gauge-4.0.1.tgz", - "integrity": "sha512-zJ4jePUHR8cceduZ53b6temRalyGpkC2Kc2r3ecNphmL+uWNoJ3YcOcUjpbG6WwoE/Ef6/+aEZz63neI2WIa1Q==", + "version": "5.0.0", "inBundle": true, + "license": "ISC", "dependencies": { - "ansi-regex": "^5.0.1", "aproba": "^1.0.3 || ^2.0.0", - "color-support": "^1.1.2", - "console-control-strings": "^1.0.0", + "color-support": "^1.1.3", + "console-control-strings": "^1.1.0", "has-unicode": "^2.0.1", - "signal-exit": "^3.0.0", + "signal-exit": "^3.0.7", "string-width": "^4.2.3", "strip-ansi": "^6.0.1", - "wide-align": "^1.1.2" + "wide-align": "^1.1.5" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - } - }, - "node_modules/gauge/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "inBundle": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/gauge/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "inBundle": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/gauge/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "inBundle": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/gauge/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "inBundle": true, - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/gensync": { @@ -3504,24 +5355,16 @@ "node": "6.* || 8.* || >= 10.*" } }, - "node_modules/get-func-name": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", - "integrity": "sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=", - "dev": true, - "engines": { - "node": "*" - } - }, "node_modules/get-intrinsic": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz", - "integrity": "sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q==", + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.3.tgz", + "integrity": "sha512-QJVz1Tj7MS099PevUG5jvnt9tSkXN8K14dxQlikJuPt4uD9hHAHjLyLBiLR5zELelBdD9QNRAXZzsJx0WaDL9A==", "dev": true, + "peer": true, "dependencies": { "function-bind": "^1.1.1", "has": "^1.0.3", - "has-symbols": "^1.0.1" + "has-symbols": "^1.0.3" }, "funding": { "url": "https://github.com/sponsors/ljharb" @@ -3536,11 +5379,24 @@ "node": ">=8.0.0" } }, + "node_modules/get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/get-symbol-description": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", "dev": true, + "peer": true, "dependencies": { "call-bind": "^1.0.2", "get-intrinsic": "^1.1.1" @@ -3552,96 +5408,152 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/getpass": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", - "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", + "node_modules/git-raw-commits": { + "version": "2.0.11", + "resolved": "https://registry.npmjs.org/git-raw-commits/-/git-raw-commits-2.0.11.tgz", + "integrity": "sha512-VnctFhw+xfj8Va1xtfEqCUD2XDrbAPSJx+hSrE5K7fGdjZruW7XV+QOrN7LF/RJyvspRiD2I0asWsxFp0ya26A==", "dev": true, "dependencies": { - "assert-plus": "^1.0.0" + "dargs": "^7.0.0", + "lodash": "^4.17.15", + "meow": "^8.0.0", + "split2": "^3.0.0", + "through2": "^4.0.0" + }, + "bin": { + "git-raw-commits": "cli.js" + }, + "engines": { + "node": ">=10" } }, - "node_modules/github-from-package": { - "version": "0.0.0", - "resolved": "https://registry.npmjs.org/github-from-package/-/github-from-package-0.0.0.tgz", - "integrity": "sha1-l/tdlr/eiXMxPyDoKI75oWf6ZM4=", + "node_modules/github-slugger": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/github-slugger/-/github-slugger-1.5.0.tgz", + "integrity": "sha512-wIh+gKBI9Nshz2o46B0B3f5k/W+WI9ZAv6y5Dn5WJ5SK1t0TnDimB4WE5rmTD05ZAIn8HALCZVmCsvj0w0v0lw==", "dev": true }, "node_modules/glob": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", - "integrity": "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==", + "version": "8.0.3", "inBundle": true, + "license": "ISC", "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" + "minimatch": "^5.0.1", + "once": "^1.3.0" }, "engines": { - "node": "*" + "node": ">=12" }, "funding": { "url": "https://github.com/sponsors/isaacs" } }, "node_modules/glob-parent": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", + "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", "dev": true, + "peer": true, "dependencies": { - "is-glob": "^4.0.1" + "is-glob": "^4.0.3" }, "engines": { - "node": ">= 6" + "node": ">=10.13.0" } }, - "node_modules/globals": { - "version": "11.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", - "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", + "node_modules/global-dirs": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/global-dirs/-/global-dirs-0.1.1.tgz", + "integrity": "sha512-NknMLn7F2J7aflwFOlGdNIuCDpN3VGoSoB+aap3KABFWbHVn1TCgFC+np23J8W2BiZbjfEw3BFBycSMv1AFblg==", "dev": true, + "dependencies": { + "ini": "^1.3.4" + }, "engines": { "node": ">=4" } }, + "node_modules/global-dirs/node_modules/ini": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", + "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", + "dev": true + }, + "node_modules/globals": { + "version": "13.17.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.17.0.tgz", + "integrity": "sha512-1C+6nQRb1GwGMKm2dH/E7enFAMxGTmGI7/dEdhy/DNelv85w9B72t3uc5frtMNXIbzrarJJ/lTCjcaZwbLJmyw==", + "dev": true, + "peer": true, + "dependencies": { + "type-fest": "^0.20.2" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/graceful-fs": { - "version": "4.2.9", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.9.tgz", - "integrity": "sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ==", - "inBundle": true + "version": "4.2.10", + "inBundle": true, + "license": "ISC" }, - "node_modules/har-schema": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz", - "integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=", + "node_modules/grapheme-splitter": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/grapheme-splitter/-/grapheme-splitter-1.0.4.tgz", + "integrity": "sha512-bzh50DW9kTPM00T8y4o8vQg89Di9oLJVLW/KaOGIXJWP/iqCN6WKYkbNOF04vFLJhwcpYUh9ydh/+5vpOqV4YQ==", "dev": true, - "engines": { - "node": ">=4" + "peer": true + }, + "node_modules/groff-escape": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/groff-escape/-/groff-escape-2.0.1.tgz", + "integrity": "sha512-S0nG+mLFTu1buDKQsRlBtIxZU/dMvrdCURJg/zSLKpL333yi1Fs5bLUYk+v3pRYlc+qmHtukMAM2slB0AKFKAw==", + "dev": true, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/har-validator": { - "version": "5.1.5", - "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.5.tgz", - "integrity": "sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w==", - "deprecated": "this library is no longer supported", + "node_modules/handlebars": { + "version": "4.7.7", + "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.7.7.tgz", + "integrity": "sha512-aAcXm5OAfE/8IXkcZvCepKU3VzW1/39Fb5ZuqMtgI/hT8X2YgoMvBY5dLhq/cpOvw7Lk1nK/UF71aLG/ZnVYRA==", "dev": true, "dependencies": { - "ajv": "^6.12.3", - "har-schema": "^2.0.0" + "minimist": "^1.2.5", + "neo-async": "^2.6.0", + "source-map": "^0.6.1", + "wordwrap": "^1.0.0" }, + "bin": { + "handlebars": "bin/handlebars" + }, + "engines": { + "node": ">=0.4.7" + }, + "optionalDependencies": { + "uglify-js": "^3.1.4" + } + }, + "node_modules/hard-rejection": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/hard-rejection/-/hard-rejection-2.1.0.tgz", + "integrity": "sha512-VIZB+ibDhx7ObhAe7OVtoEbuP4h/MuOTHJ+J8h/eBXotJYl0fBgR72xDFCKgIh22OJZIOVNxBMWuhAr10r8HdA==", + "dev": true, "engines": { "node": ">=6" } }, "node_modules/has": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", - "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", "inBundle": true, + "license": "MIT", "dependencies": { "function-bind": "^1.1.1" }, @@ -3650,28 +5562,42 @@ } }, "node_modules/has-bigints": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.1.tgz", - "integrity": "sha512-LSBS2LjbNBTf6287JEbEzvJgftkF5qFkmCo9hDRpAzKhUOlJ+hx8dd4USs00SgsUNwc4617J9ki5YtEClM2ffA==", + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", "dev": true, + "peer": true, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/has-flag": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "inBundle": true, + "license": "MIT", "engines": { "node": ">=8" } }, - "node_modules/has-symbols": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.2.tgz", - "integrity": "sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw==", + "node_modules/has-property-descriptors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", + "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", "dev": true, + "peer": true, + "dependencies": { + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "dev": true, + "peer": true, "engines": { "node": ">= 0.4" }, @@ -3684,6 +5610,7 @@ "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", "dev": true, + "peer": true, "dependencies": { "has-symbols": "^1.0.2" }, @@ -3696,9 +5623,8 @@ }, "node_modules/has-unicode": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", - "integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk=", - "inBundle": true + "inBundle": true, + "license": "ISC" }, "node_modules/hasha": { "version": "5.2.2", @@ -3716,119 +5642,79 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/hast-to-hyperscript": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/hast-to-hyperscript/-/hast-to-hyperscript-9.0.1.tgz", - "integrity": "sha512-zQgLKqF+O2F72S1aa4y2ivxzSlko3MAvxkwG8ehGmNiqd98BIN3JM1rAJPmplEyLmGLO2QZYJtIneOSZ2YbJuA==", + "node_modules/hasha/node_modules/type-fest": { + "version": "0.8.1", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", + "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", "dev": true, - "dependencies": { - "@types/unist": "^2.0.3", - "comma-separated-tokens": "^1.0.0", - "property-information": "^5.3.0", - "space-separated-tokens": "^1.0.0", - "style-to-object": "^0.3.0", - "unist-util-is": "^4.0.0", - "web-namespaces": "^1.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "engines": { + "node": ">=8" } }, - "node_modules/hast-util-from-parse5": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/hast-util-from-parse5/-/hast-util-from-parse5-6.0.1.tgz", - "integrity": "sha512-jeJUWiN5pSxW12Rh01smtVkZgZr33wBokLzKLwinYOUfSzm1Nl/c3GUGebDyOKjdsRgMvoVbV0VpAcpjF4NrJA==", - "dev": true, - "dependencies": { - "@types/parse5": "^5.0.0", - "hastscript": "^6.0.0", - "property-information": "^5.0.0", - "vfile": "^4.0.0", - "vfile-location": "^3.2.0", - "web-namespaces": "^1.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-parse-selector": { - "version": "2.2.5", - "resolved": "https://registry.npmjs.org/hast-util-parse-selector/-/hast-util-parse-selector-2.2.5.tgz", - "integrity": "sha512-7j6mrk/qqkSehsM92wQjdIgWM2/BW61u/53G6xmC8i1OmEdKLHbk419QKQUjz6LglWsfqoiHmyMRkP1BGjecNQ==", - "dev": true, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hast-util-raw": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/hast-util-raw/-/hast-util-raw-6.0.1.tgz", - "integrity": "sha512-ZMuiYA+UF7BXBtsTBNcLBF5HzXzkyE6MLzJnL605LKE8GJylNjGc4jjxazAHUtcwT5/CEt6afRKViYB4X66dig==", + "node_modules/hast-util-is-element": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/hast-util-is-element/-/hast-util-is-element-2.1.2.tgz", + "integrity": "sha512-thjnlGAnwP8ef/GSO1Q8BfVk2gundnc2peGQqEg2kUt/IqesiGg/5mSwN2fE7nLzy61pg88NG6xV+UrGOrx9EA==", "dev": true, "dependencies": { "@types/hast": "^2.0.0", - "hast-util-from-parse5": "^6.0.0", - "hast-util-to-parse5": "^6.0.0", - "html-void-elements": "^1.0.0", - "parse5": "^6.0.0", - "unist-util-position": "^3.0.0", - "vfile": "^4.0.0", - "web-namespaces": "^1.0.0", - "xtend": "^4.0.0", - "zwitch": "^1.0.0" + "@types/unist": "^2.0.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/unified" } }, - "node_modules/hast-util-to-parse5": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/hast-util-to-parse5/-/hast-util-to-parse5-6.0.0.tgz", - "integrity": "sha512-Lu5m6Lgm/fWuz8eWnrKezHtVY83JeRGaNQ2kn9aJgqaxvVkFCZQBEhgodZUDUvoodgyROHDb3r5IxAEdl6suJQ==", - "dev": true, - "dependencies": { - "hast-to-hyperscript": "^9.0.0", - "property-information": "^5.0.0", - "web-namespaces": "^1.0.0", - "xtend": "^4.0.0", - "zwitch": "^1.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/hastscript": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/hastscript/-/hastscript-6.0.0.tgz", - "integrity": "sha512-nDM6bvd7lIqDUiYEiu5Sl/+6ReP0BMk/2f4U/Rooccxkj0P5nm+acM5PrGJ/t5I8qPGiqZSE6hVAwZEdZIvP4w==", + "node_modules/hast-util-to-html": { + "version": "8.0.3", + "resolved": "https://registry.npmjs.org/hast-util-to-html/-/hast-util-to-html-8.0.3.tgz", + "integrity": "sha512-/D/E5ymdPYhHpPkuTHOUkSatxr4w1ZKrZsG0Zv/3C2SRVT0JFJG53VS45AMrBtYk0wp5A7ksEhiC8QaOZM95+A==", "dev": true, "dependencies": { "@types/hast": "^2.0.0", - "comma-separated-tokens": "^1.0.0", - "hast-util-parse-selector": "^2.0.0", - "property-information": "^5.0.0", - "space-separated-tokens": "^1.0.0" + "ccount": "^2.0.0", + "comma-separated-tokens": "^2.0.0", + "hast-util-is-element": "^2.0.0", + "hast-util-whitespace": "^2.0.0", + "html-void-elements": "^2.0.0", + "property-information": "^6.0.0", + "space-separated-tokens": "^2.0.0", + "stringify-entities": "^4.0.2", + "unist-util-is": "^5.0.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/unified" } }, + "node_modules/hast-util-whitespace": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/hast-util-whitespace/-/hast-util-whitespace-2.0.0.tgz", + "integrity": "sha512-Pkw+xBHuV6xFeJprJe2BBEoDV+AvQySaz3pPDRUs5PNZEMQjpXJJueqrpcHIXxnWTcAGi/UOCgVShlkY6kLoqg==", + "dev": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/he": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", + "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", + "dev": true, + "bin": { + "he": "bin/he" + } + }, "node_modules/hosted-git-info": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", - "integrity": "sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==", + "version": "6.1.1", "inBundle": true, + "license": "ISC", "dependencies": { - "lru-cache": "^6.0.0" + "lru-cache": "^7.5.1" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/html-encoding-sniffer": { @@ -3850,9 +5736,9 @@ "dev": true }, "node_modules/html-void-elements": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/html-void-elements/-/html-void-elements-1.0.5.tgz", - "integrity": "sha512-uE/TxKuyNIcx44cIWnjr/rfIATDH7ZaOMmstu0CwhFG1Dunhlp4OC6/NMbhiwoq5BpW0ubi303qnEk/PZj614w==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/html-void-elements/-/html-void-elements-2.0.1.tgz", + "integrity": "sha512-0quDb7s97CfemeJAnW9wC0hw78MtW7NU3hqtCD75g2vFlDLt36llsYD7uB7SUzojLMP24N5IatXf7ylGXiGG9A==", "dev": true, "funding": { "type": "github", @@ -3861,15 +5747,27 @@ }, "node_modules/http-cache-semantics": { "version": "4.1.0", - "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.0.tgz", - "integrity": "sha512-carPklcUh7ROWRK7Cv27RPtdhYhUsela/ue5/jKzjegVvXDqM2ILE9Q2BGn9JZJh1g87cp56su/FgQSzcWS8cQ==", - "inBundle": true + "inBundle": true, + "license": "BSD-2-Clause" + }, + "node_modules/http-proxy": { + "version": "1.18.1", + "resolved": "https://registry.npmjs.org/http-proxy/-/http-proxy-1.18.1.tgz", + "integrity": "sha512-7mz/721AbnJwIVbnaSv1Cz3Am0ZLT/UBwkC92VlxhXv/k/BBQfM2fXElQNC27BVGr0uwUpplYPQM9LnaBMR5NQ==", + "dev": true, + "dependencies": { + "eventemitter3": "^4.0.0", + "follow-redirects": "^1.0.0", + "requires-port": "^1.0.0" + }, + "engines": { + "node": ">=8.0.0" + } }, "node_modules/http-proxy-agent": { "version": "5.0.0", - "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz", - "integrity": "sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==", "inBundle": true, + "license": "MIT", "dependencies": { "@tootallnate/once": "2", "agent-base": "6", @@ -3879,26 +5777,10 @@ "node": ">= 6" } }, - "node_modules/http-signature": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz", - "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=", - "dev": true, - "dependencies": { - "assert-plus": "^1.0.0", - "jsprim": "^1.2.2", - "sshpk": "^1.7.0" - }, - "engines": { - "node": ">=0.8", - "npm": ">=1.3.7" - } - }, "node_modules/https-proxy-agent": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.0.tgz", - "integrity": "sha512-EkYm5BcKUGiduxzSt3Eppko+PiNWNEpa4ySk9vTC6wDsQJW9rHSa+UhGNJoRYp7bz6Ht1eaRIa6QaJqO5rCFbA==", + "version": "5.0.1", "inBundle": true, + "license": "MIT", "dependencies": { "agent-base": "6", "debug": "4" @@ -3907,21 +5789,28 @@ "node": ">= 6" } }, + "node_modules/human-signals": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "dev": true, + "engines": { + "node": ">=10.17.0" + } + }, "node_modules/humanize-ms": { "version": "1.2.1", - "resolved": "https://registry.npmjs.org/humanize-ms/-/humanize-ms-1.2.1.tgz", - "integrity": "sha1-xG4xWaKT9riW2ikxbYtv6Lt5u+0=", "inBundle": true, + "license": "MIT", "dependencies": { "ms": "^2.0.0" } }, "node_modules/iconv-lite": { "version": "0.6.3", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", - "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", "devOptional": true, "inBundle": true, + "license": "MIT", "dependencies": { "safer-buffer": ">= 2.1.2 < 3.0.0" }, @@ -3931,9 +5820,6 @@ }, "node_modules/ieee754": { "version": "1.2.1", - "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", - "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", - "dev": true, "funding": [ { "type": "github", @@ -3947,27 +5833,29 @@ "type": "consulting", "url": "https://feross.org/support" } - ] + ], + "inBundle": true, + "license": "BSD-3-Clause" }, "node_modules/ignore": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz", - "integrity": "sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg==", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.2.0.tgz", + "integrity": "sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ==", "dev": true, + "peer": true, "engines": { "node": ">= 4" } }, "node_modules/ignore-walk": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/ignore-walk/-/ignore-walk-4.0.1.tgz", - "integrity": "sha512-rzDQLaW4jQbh2YrOFlJdCtX8qgJTehFRYiUB2r1osqTeDzV/3+Jh8fz1oAPzUThf3iku8Ds4IDqawI5d8mUiQw==", + "version": "6.0.0", "inBundle": true, + "license": "ISC", "dependencies": { - "minimatch": "^3.0.4" + "minimatch": "^5.0.1" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/import-fresh": { @@ -3986,35 +5874,40 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/import-fresh/node_modules/resolve-from": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", + "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", + "dev": true, + "engines": { + "node": ">=4" + } + }, "node_modules/imurmurhash": { "version": "0.1.4", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=", "inBundle": true, + "license": "MIT", "engines": { "node": ">=0.8.19" } }, "node_modules/indent-string": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz", - "integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==", "inBundle": true, + "license": "MIT", "engines": { "node": ">=8" } }, "node_modules/infer-owner": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/infer-owner/-/infer-owner-1.0.4.tgz", - "integrity": "sha512-IClj+Xz94+d7irH5qRyfJonOdfTzuDaifE6ZPWfx0N0+/ATZCbuTPq2prFl526urkQd90WyUKIh1DfBQ2hMz9A==", - "inBundle": true + "inBundle": true, + "license": "ISC" }, "node_modules/inflight": { "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", "inBundle": true, + "license": "ISC", "dependencies": { "once": "^1.3.0", "wrappy": "1" @@ -4022,48 +5915,40 @@ }, "node_modules/inherits": { "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "inBundle": true + "inBundle": true, + "license": "ISC" }, "node_modules/ini": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ini/-/ini-2.0.0.tgz", - "integrity": "sha512-7PnF4oN3CvZF23ADhA5wRaYEQpJ8qygSkbtTXWBeXWXmEVRXK+1ITciHWwHhsjv1TmW0MgacIv6hEi5pX5NQdA==", + "version": "3.0.1", "inBundle": true, + "license": "ISC", "engines": { - "node": ">=10" + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" } }, "node_modules/init-package-json": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/init-package-json/-/init-package-json-2.0.5.tgz", - "integrity": "sha512-u1uGAtEFu3VA6HNl/yUWw57jmKEMx8SKOxHhxjGnOFUiIlFnohKDFg4ZrPpv9wWqk44nDxGJAtqjdQFm+9XXQA==", + "version": "4.0.1", "inBundle": true, + "license": "ISC", "dependencies": { - "npm-package-arg": "^8.1.5", + "npm-package-arg": "^10.0.0", "promzard": "^0.3.0", - "read": "~1.0.1", - "read-package-json": "^4.1.1", + "read": "^1.0.7", + "read-package-json": "^6.0.0", "semver": "^7.3.5", "validate-npm-package-license": "^3.0.4", - "validate-npm-package-name": "^3.0.0" + "validate-npm-package-name": "^5.0.0" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/inline-style-parser": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/inline-style-parser/-/inline-style-parser-0.1.1.tgz", - "integrity": "sha512-7NXolsK4CAS5+xvdj5OMMbI962hU/wvwoxk+LWR9Ek9bVtyuuYScDN6eS0rUm6TxApFpw7CX1o4uJzcd4AyD3Q==", - "dev": true - }, "node_modules/internal-slot": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.3.tgz", "integrity": "sha512-O0DB1JC/sPyZl7cIo78n5dR7eUSwwpYPiXRhTzNxZVAMUuB8vlnRFyLxdrVToks6XPLVnFfbzaVd5WLjhgg+vA==", "dev": true, + "peer": true, "dependencies": { "get-intrinsic": "^1.1.0", "has": "^1.0.3", @@ -4074,65 +5959,33 @@ } }, "node_modules/ip": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/ip/-/ip-1.1.5.tgz", - "integrity": "sha1-vd7XARQpCCjAoDnnLvJfWq7ENUo=", - "inBundle": true + "version": "2.0.0", + "inBundle": true, + "license": "MIT" }, "node_modules/ip-regex": { "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ip-regex/-/ip-regex-4.3.0.tgz", - "integrity": "sha512-B9ZWJxHHOHUhUjCPrMpLD4xEq35bUTClHM1S6CBU5ixQnkZmwipwgc96vAd7AAGM9TGHvJR+Uss+/Ak6UphK+Q==", "inBundle": true, + "license": "MIT", "engines": { "node": ">=8" } }, - "node_modules/is-alphabetical": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-alphabetical/-/is-alphabetical-1.0.4.tgz", - "integrity": "sha512-DwzsA04LQ10FHTZuL0/grVDk4rFoVH1pjAToYwBrHSxcrBIGQuXrQMtD5U1b0U2XVgKZCTLLP8u2Qxqhy3l2Vg==", - "dev": true, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/is-alphanumerical": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-alphanumerical/-/is-alphanumerical-1.0.4.tgz", - "integrity": "sha512-UzoZUr+XfVz3t3v4KyGEniVL9BDRoQtY7tOyrRybkVNjDFWyo1yhXNGrrBTQxp3ib9BLAWs7k2YKBQsFRkZG9A==", - "dev": true, - "dependencies": { - "is-alphabetical": "^1.0.0", - "is-decimal": "^1.0.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/is-arguments": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", - "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } + "node_modules/is-arrayish": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", + "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", + "dev": true }, "node_modules/is-bigint": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.2.tgz", - "integrity": "sha512-0JV5+SOCQkIdzjBK9buARcV804Ddu7A0Qet6sHi3FimE9ne6m4BGQZfRn+NZiXbBk4F4XmHfDZIipLj9pX8dSA==", + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", "dev": true, + "peer": true, + "dependencies": { + "has-bigints": "^1.0.1" + }, "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -4150,12 +6003,14 @@ } }, "node_modules/is-boolean-object": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.1.tgz", - "integrity": "sha512-bXdQWkECBUIAcCkeH1unwJLIpZYaa5VvuygSyS/c2lf719mTKZDU5UdDRlpd01UjADgmW8RfqaP+mRaVPdr/Ng==", + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", "dev": true, + "peer": true, "dependencies": { - "call-bind": "^1.0.2" + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" }, "engines": { "node": ">= 0.4" @@ -4188,10 +6043,11 @@ } }, "node_modules/is-callable": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.4.tgz", - "integrity": "sha512-nsuwtxZfMX67Oryl9LCQ+upnC0Z0BgpwntpS89m1H/TLF0zNfzfLMV/9Wa/6MZsj0acpEjAO0KF1xT6ZdLl95w==", + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", "dev": true, + "peer": true, "engines": { "node": ">= 0.4" }, @@ -4201,9 +6057,8 @@ }, "node_modules/is-cidr": { "version": "4.0.2", - "resolved": "https://registry.npmjs.org/is-cidr/-/is-cidr-4.0.2.tgz", - "integrity": "sha512-z4a1ENUajDbEl/Q6/pVBpTR1nBjjEE1X7qb7bmWYanNnPoKAvUCPFKeXV6Fe4mgTkWKBqiHIcwsI3SndiO5FeA==", "inBundle": true, + "license": "BSD-2-Clause", "dependencies": { "cidr-regex": "^3.1.1" }, @@ -4212,10 +6067,9 @@ } }, "node_modules/is-core-module": { - "version": "2.8.1", - "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.8.1.tgz", - "integrity": "sha512-SdNCUs284hr40hFTFP6l0IfZ/RSrMXF3qgoRHd3/79unUTvrFO/JoXwkGm+5J/Oe3E/b5GsnG330uUNgRpu1PA==", + "version": "2.10.0", "inBundle": true, + "license": "MIT", "dependencies": { "has": "^1.0.3" }, @@ -4224,10 +6078,14 @@ } }, "node_modules/is-date-object": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.4.tgz", - "integrity": "sha512-/b4ZVsG7Z5XVtIxs/h9W8nvfLgSAyKYdtGWQLbqy6jA1icmgjf8WCoTKgeS4wy5tYaPePouzFMANbnj94c2Z+A==", + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", "dev": true, + "peer": true, + "dependencies": { + "has-tostringtag": "^1.0.0" + }, "engines": { "node": ">= 0.4" }, @@ -4235,32 +6093,21 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-decimal": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-decimal/-/is-decimal-1.0.4.tgz", - "integrity": "sha512-RGdriMmQQvZ2aqaQq3awNA6dCGtKpiDFcOzrTWrDAT2MiWrKQVPmxLGHl7Y2nNu6led0kEyoX0enY0qXYsv9zw==", - "dev": true, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, "node_modules/is-extglob": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", + "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/is-fullwidth-code-point": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", - "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", + "version": "3.0.0", "inBundle": true, + "license": "MIT", "engines": { - "node": ">=4" + "node": ">=8" } }, "node_modules/is-glob": { @@ -4275,27 +6122,17 @@ "node": ">=0.10.0" } }, - "node_modules/is-hexadecimal": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-hexadecimal/-/is-hexadecimal-1.0.4.tgz", - "integrity": "sha512-gyPJuv83bHMpocVYoqof5VDiZveEoGoFL8m3BXNb2VW8Xs+rz9kqO8LOQ5DH6EsuvilT1ApazU0pyl+ytbPtlw==", - "dev": true, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, "node_modules/is-lambda": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-lambda/-/is-lambda-1.0.1.tgz", - "integrity": "sha1-PZh3iZ5qU+/AFgUEzeFfgubwYdU=", - "inBundle": true + "inBundle": true, + "license": "MIT" }, "node_modules/is-negative-zero": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.1.tgz", - "integrity": "sha512-2z6JzQvZRa9A2Y7xC6dQQm4FSTSTNWjKIYYTt4246eMTJmIo0Q+ZyOsU66X8lxK1AbB92dFeglPLrhwpeRKO6w==", + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", + "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==", "dev": true, + "peer": true, "engines": { "node": ">= 0.4" }, @@ -4313,10 +6150,14 @@ } }, "node_modules/is-number-object": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.5.tgz", - "integrity": "sha512-RU0lI/n95pMoUKu9v1BZP5MBcZuNSVJkMkAG2dJqC4z2GlkGUNeH68SuHuBKBD/XFe+LHZ+f9BKkLET60Niedw==", + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", "dev": true, + "peer": true, + "dependencies": { + "has-tostringtag": "^1.0.0" + }, "engines": { "node": ">= 0.4" }, @@ -4324,15 +6165,43 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-plain-obj": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz", - "integrity": "sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==", + "node_modules/is-obj": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-obj/-/is-obj-2.0.0.tgz", + "integrity": "sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w==", "dev": true, "engines": { "node": ">=8" } }, + "node_modules/is-path-inside": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", + "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", + "dev": true, + "peer": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-plain-obj": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", + "integrity": "sha512-yvkRyxmFKEOQ4pNXCmJG5AEQNlXJS5LaONXo5/cLdTZdWvsZ1ioJEonLGAosKlMWE8lwUy/bJzMjcw8az73+Fg==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-plain-object": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-5.0.0.tgz", + "integrity": "sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/is-potential-custom-element-name": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz", @@ -4344,6 +6213,7 @@ "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", "dev": true, + "peer": true, "dependencies": { "call-bind": "^1.0.2", "has-tostringtag": "^1.0.0" @@ -4356,21 +6226,28 @@ } }, "node_modules/is-shared-array-buffer": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.1.tgz", - "integrity": "sha512-IU0NmyknYZN0rChcKhRO1X8LYz5Isj/Fsqh8NJOSf+N/hCOTwy29F32Ik7a+QszE63IdvmwdTPDd6cZ5pg4cwA==", + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", + "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", "dev": true, + "peer": true, + "dependencies": { + "call-bind": "^1.0.2" + }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/is-stream": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.0.tgz", - "integrity": "sha512-XCoy+WlUr7d1+Z8GgSuXmpuUFC9fOhRXglJMx+dwLKTkL44Cjd4W1Z5P+BQZpr+cR93aGP4S/s7Ftw6Nd/kiEw==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", "dev": true, "engines": { "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/is-string": { @@ -4378,6 +6255,7 @@ "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", "dev": true, + "peer": true, "dependencies": { "has-tostringtag": "^1.0.0" }, @@ -4393,6 +6271,7 @@ "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", "dev": true, + "peer": true, "dependencies": { "has-symbols": "^1.0.2" }, @@ -4403,34 +6282,37 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/is-text-path": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-text-path/-/is-text-path-1.0.1.tgz", + "integrity": "sha512-xFuJpne9oFz5qDaodwmmG08e3CawH/2ZV8Qqza1Ko7Sk8POWbkRdwIoAWVhqvq0XeUzANEhKo2n0IXUGBm7A/w==", + "dev": true, + "dependencies": { + "text-extensions": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/is-typedarray": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", - "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=", - "inBundle": true + "integrity": "sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA==", + "dev": true }, "node_modules/is-weakref": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.1.tgz", - "integrity": "sha512-b2jKc2pQZjaeFYWEf7ScFj+Be1I+PXmlu572Q8coTXZ+LD/QQZ7ShPMst8h16riVgyXTQwUsFEl74mDvc/3MHQ==", + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", + "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", "dev": true, + "peer": true, "dependencies": { - "call-bind": "^1.0.0" + "call-bind": "^1.0.2" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-whitespace-character": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-whitespace-character/-/is-whitespace-character-1.0.4.tgz", - "integrity": "sha512-SDweEzfIZM0SJV0EUga669UTKlmL0Pq8Lno0QDQsPnvECB3IM2aP0gdx5TrU0A01MAPfViaZiI2V1QMZLaKK5w==", - "dev": true, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, "node_modules/is-windows": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz", @@ -4440,38 +6322,21 @@ "node": ">=0.10.0" } }, - "node_modules/is-word-character": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-word-character/-/is-word-character-1.0.4.tgz", - "integrity": "sha512-5SMO8RVennx3nZrqtKwCGyyetPE9VDba5ugvKLaD4KopPG5kR4mQ7tNt/r7feL5yt5h3lpuBbIUmCOG2eSzXHA==", - "dev": true, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, "node_modules/isarray": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==", "dev": true }, "node_modules/isexe": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", - "inBundle": true - }, - "node_modules/isstream": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", - "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=", - "dev": true + "inBundle": true, + "license": "ISC" }, "node_modules/istanbul-lib-coverage": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.0.0.tgz", - "integrity": "sha512-UiUIqxMgRDET6eR+o5HbfRYP1l0hqkWOs7vNxC/mggutCMUIhWMm8gAHb8tHlyfD3/l6rlgNA5cKdDzEAf6hEg==", + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.0.tgz", + "integrity": "sha512-eOeJ5BHCmHYvQK7xt9GkdHuzuCGS1Y6g9Gvnx3Ym33fz/HpLRYxiS0wHNr+m/MBC8B647Xt608vCDEvhl9c6Mw==", "dev": true, "engines": { "node": ">=8" @@ -4514,18 +6379,17 @@ } }, "node_modules/istanbul-lib-processinfo": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/istanbul-lib-processinfo/-/istanbul-lib-processinfo-2.0.2.tgz", - "integrity": "sha512-kOwpa7z9hme+IBPZMzQ5vdQj8srYgAtaRqeI48NGmAQ+/5yKiHLV0QbYqQpxsdEF0+w14SoB8YbnHKcXE2KnYw==", + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/istanbul-lib-processinfo/-/istanbul-lib-processinfo-2.0.3.tgz", + "integrity": "sha512-NkwHbo3E00oybX6NGJi6ar0B29vxyvNwoC7eJ4G4Yq28UfY758Hgn/heV8VRFhevPED4LXfFz0DQ8z/0kw9zMg==", "dev": true, "dependencies": { "archy": "^1.0.0", - "cross-spawn": "^7.0.0", - "istanbul-lib-coverage": "^3.0.0-alpha.1", - "make-dir": "^3.0.0", + "cross-spawn": "^7.0.3", + "istanbul-lib-coverage": "^3.2.0", "p-map": "^3.0.0", "rimraf": "^3.0.0", - "uuid": "^3.3.3" + "uuid": "^8.3.2" }, "engines": { "node": ">=8" @@ -4558,9 +6422,9 @@ } }, "node_modules/istanbul-lib-source-maps": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.0.tgz", - "integrity": "sha512-c16LpFRkR8vQXyHZ5nLpY35JZtzj1PQY1iZmesUbf1FZHbIupcWfjgOXBY9YHkLEQ6puz1u4Dgj6qmU/DisrZg==", + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz", + "integrity": "sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw==", "dev": true, "dependencies": { "debug": "^4.1.1", @@ -4568,22 +6432,13 @@ "source-map": "^0.6.1" }, "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-lib-source-maps/node_modules/source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true, - "engines": { - "node": ">=0.10.0" + "node": ">=10" } }, "node_modules/istanbul-reports": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-3.0.2.tgz", - "integrity": "sha512-9tZvz7AiR3PEDNGiV9vIouQ/EAcqMXFmkcA1CDFTwOB98OZVDL0PH9glHotf5Ugp6GCOTypfzGWI/OqjWNCRUw==", + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-3.1.5.tgz", + "integrity": "sha512-nUsEMa9pBt/NOHqbcbeJEgqIlY/K7rVWUX6Lql2orY5e9roQOthbR3vtY4zzf2orPELg80fnxxk9zUyPlgwD1w==", "dev": true, "dependencies": { "html-escaper": "^2.0.0", @@ -4594,9 +6449,9 @@ } }, "node_modules/jackspeak": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-1.4.1.tgz", - "integrity": "sha512-npN8f+M4+IQ8xD3CcWi3U62VQwKlT3Tj4GxbdT/fYTmeogD9eBF9OFdpoFG/VPNoshRjPUijdkp/p2XrzUHaVg==", + "version": "1.4.2", + "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-1.4.2.tgz", + "integrity": "sha512-GHeGTmnuaHnvS+ZctRB01bfxARuu9wW83ENbuiweu07SFcVlZrJpcshSre/keGT7YGBhLHg/+rXCNSrsEHKU4Q==", "dev": true, "dependencies": { "cliui": "^7.0.4" @@ -4605,6 +6460,13 @@ "node": ">=8" } }, + "node_modules/js-sdsl": { + "version": "4.1.5", + "resolved": "https://registry.npmjs.org/js-sdsl/-/js-sdsl-4.1.5.tgz", + "integrity": "sha512-08bOAKweV2NUC1wqTtf3qZlnpOX/R2DU9ikpjOHs0H+ibQv3zpncVQg6um4uYtRtrwIX8M4Nh3ytK4HGlYAq7Q==", + "dev": true, + "peer": true + }, "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -4612,60 +6474,52 @@ "dev": true }, "node_modules/js-yaml": { - "version": "3.14.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", - "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", + "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", "dev": true, "dependencies": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" + "argparse": "^2.0.1" }, "bin": { "js-yaml": "bin/js-yaml.js" } }, - "node_modules/jsbn": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", - "integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=", - "dev": true - }, "node_modules/jsdom": { - "version": "18.1.1", - "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-18.1.1.tgz", - "integrity": "sha512-NmJQbjQ/gpS/1at/ce3nCx89HbXL/f5OcenBe8wU1Eik0ROhyUc3LtmG3567dEHAGXkN8rmILW/qtCOPxPHQJw==", + "version": "20.0.3", + "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-20.0.3.tgz", + "integrity": "sha512-SYhBvTh89tTfCD/CRdSOm13mOBa42iTaTyfyEWBdKcGdPxPtLFBXuHR8XHb33YNYaP+lLbmSvBTsnoesCNJEsQ==", "dev": true, "dependencies": { - "abab": "^2.0.5", - "acorn": "^8.5.0", - "acorn-globals": "^6.0.0", + "abab": "^2.0.6", + "acorn": "^8.8.1", + "acorn-globals": "^7.0.0", "cssom": "^0.5.0", "cssstyle": "^2.3.0", - "data-urls": "^3.0.1", - "decimal.js": "^10.3.1", + "data-urls": "^3.0.2", + "decimal.js": "^10.4.2", "domexception": "^4.0.0", "escodegen": "^2.0.0", "form-data": "^4.0.0", "html-encoding-sniffer": "^3.0.0", "http-proxy-agent": "^5.0.0", - "https-proxy-agent": "^5.0.0", + "https-proxy-agent": "^5.0.1", "is-potential-custom-element-name": "^1.0.1", - "nwsapi": "^2.2.0", - "parse5": "6.0.1", - "saxes": "^5.0.1", + "nwsapi": "^2.2.2", + "parse5": "^7.1.1", + "saxes": "^6.0.0", "symbol-tree": "^3.2.4", - "tough-cookie": "^4.0.0", - "w3c-hr-time": "^1.0.2", - "w3c-xmlserializer": "^3.0.0", + "tough-cookie": "^4.1.2", + "w3c-xmlserializer": "^4.0.0", "webidl-conversions": "^7.0.0", "whatwg-encoding": "^2.0.0", "whatwg-mimetype": "^3.0.0", - "whatwg-url": "^10.0.0", - "ws": "^8.2.3", + "whatwg-url": "^11.0.0", + "ws": "^8.11.0", "xml-name-validator": "^4.0.0" }, "engines": { - "node": ">=12" + "node": ">=14" }, "peerDependencies": { "canvas": "^2.5.0" @@ -4676,16 +6530,124 @@ } } }, - "node_modules/jsdom/node_modules/acorn": { - "version": "8.5.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.5.0.tgz", - "integrity": "sha512-yXbYeFy+jUuYd3/CDcg2NkIYE991XYX/bje7LmjJigUciaeO1JR4XxXgCIV1/Zc/dRuFEyw1L0pbA+qynJkW5Q==", + "node_modules/jsdom/node_modules/escodegen": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-2.0.0.tgz", + "integrity": "sha512-mmHKys/C8BFUGI+MAWNcSYoORYLMdPzjrknd2Vc+bUsjN5bXcr8EhrNB+UTqfL1y3I9c4fw2ihgtMPQLBRiQxw==", "dev": true, + "dependencies": { + "esprima": "^4.0.1", + "estraverse": "^5.2.0", + "esutils": "^2.0.2", + "optionator": "^0.8.1" + }, "bin": { - "acorn": "bin/acorn" + "escodegen": "bin/escodegen.js", + "esgenerate": "bin/esgenerate.js" }, "engines": { - "node": ">=0.4.0" + "node": ">=6.0" + }, + "optionalDependencies": { + "source-map": "~0.6.1" + } + }, + "node_modules/jsdom/node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/jsdom/node_modules/levn": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", + "integrity": "sha512-0OO4y2iOHix2W6ujICbKIaEQXvFQHue65vUG3pb5EUomzPI90z9hsA1VsO/dbIIpC53J8gxM9Q4Oho0jrCM/yA==", + "dev": true, + "dependencies": { + "prelude-ls": "~1.1.2", + "type-check": "~0.3.2" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/jsdom/node_modules/optionator": { + "version": "0.8.3", + "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz", + "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", + "dev": true, + "dependencies": { + "deep-is": "~0.1.3", + "fast-levenshtein": "~2.0.6", + "levn": "~0.3.0", + "prelude-ls": "~1.1.2", + "type-check": "~0.3.2", + "word-wrap": "~1.2.3" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/jsdom/node_modules/prelude-ls": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", + "integrity": "sha512-ESF23V4SKG6lVSGZgYNpbsiaAkdab6ZgOxe52p7+Kid3W3u3bxR4Vfd/o21dmN7jSt0IwgZ4v5MUd26FEtXE9w==", + "dev": true, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/jsdom/node_modules/tr46": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-3.0.0.tgz", + "integrity": "sha512-l7FvfAHlcmulp8kr+flpQZmVwtu7nfRV7NZujtN0OqES8EL4O4e0qqzL0DC5gAvx/ZC/9lk6rhcUwYvkBnBnYA==", + "dev": true, + "dependencies": { + "punycode": "^2.1.1" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/jsdom/node_modules/type-check": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", + "integrity": "sha512-ZCmOJdvOWDBYJlzAoFkC+Q0+bUyEOS1ltgp1MGU03fqHG+dbi9tBFU2Rd9QKiDZFAYrhPh2JUf7rZRIuHRKtOg==", + "dev": true, + "dependencies": { + "prelude-ls": "~1.1.2" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/jsdom/node_modules/webidl-conversions": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", + "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", + "dev": true, + "engines": { + "node": ">=12" + } + }, + "node_modules/jsdom/node_modules/whatwg-url": { + "version": "11.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-11.0.0.tgz", + "integrity": "sha512-RKT8HExMpoYx4igMiVMY83lN6UeITKJlBQ+vR/8ZJ8OCdSiN3RwCq+9gH0+Xzj0+5IrM6i4j/6LuvzbZIQgEcQ==", + "dev": true, + "dependencies": { + "tr46": "^3.0.0", + "webidl-conversions": "^7.0.0" + }, + "engines": { + "node": ">=12" } }, "node_modules/jsesc": { @@ -4700,40 +6662,30 @@ "node": ">=4" } }, - "node_modules/json-parse-errback": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/json-parse-errback/-/json-parse-errback-2.0.1.tgz", - "integrity": "sha1-x6nCvjqFWzQvgqv8ibyFk1tYhPo=", - "dev": true - }, "node_modules/json-parse-even-better-errors": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", - "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", - "inBundle": true - }, - "node_modules/json-schema": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz", - "integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=", - "dev": true + "version": "3.0.0", + "inBundle": true, + "license": "MIT", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } }, "node_modules/json-schema-traverse": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", + "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", "dev": true }, "node_modules/json-stable-stringify-without-jsonify": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", - "integrity": "sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE=", - "dev": true + "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", + "dev": true, + "peer": true }, "node_modules/json-stringify-nice": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/json-stringify-nice/-/json-stringify-nice-1.1.4.tgz", - "integrity": "sha512-5Z5RFW63yxReJ7vANgW6eZFGWaQvnPE3WNmZoOJrSkGju2etKA2L5rrOa1sm877TVTFt57A80BH1bArcmlLfPw==", + "license": "ISC", "funding": { "url": "https://github.com/sponsors/isaacs" } @@ -4741,17 +6693,14 @@ "node_modules/json-stringify-safe": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", - "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=", + "integrity": "sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==", "dev": true }, "node_modules/json5": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.0.tgz", - "integrity": "sha512-f+8cldu7X/y7RAJurMEJmdoKXGB/X550w2Nr3tTbezL6RwEE/iMcm+tZnXeoZtKuOq6ft8+CqzEkrIgx1fPoQA==", + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.1.tgz", + "integrity": "sha512-1hqLFMSrGHRHxav9q9gNjJ5EXznIxGVO09xQRrwplcS8qs28pZ8s8hupZAmqDwZUmVZ2Qb2jnyPOWcDH8m8dlA==", "dev": true, - "dependencies": { - "minimist": "^1.2.5" - }, "bin": { "json5": "lib/cli.js" }, @@ -4759,49 +6708,97 @@ "node": ">=6" } }, + "node_modules/jsonfile": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz", + "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", + "dev": true, + "dependencies": { + "universalify": "^2.0.0" + }, + "optionalDependencies": { + "graceful-fs": "^4.1.6" + } + }, "node_modules/jsonparse": { "version": "1.3.1", - "resolved": "https://registry.npmjs.org/jsonparse/-/jsonparse-1.3.1.tgz", - "integrity": "sha1-P02uSpH6wxX3EGL4UhzCOfE2YoA=", "engines": [ "node >= 0.2.0" ], - "inBundle": true + "inBundle": true, + "license": "MIT" }, - "node_modules/jsprim": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz", - "integrity": "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=", + "node_modules/jsonpath": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/jsonpath/-/jsonpath-1.1.1.tgz", + "integrity": "sha512-l6Cg7jRpixfbgoWgkrl77dgEj8RPvND0wMH6TwQmi9Qs4TFfS9u5cUFnbeKTwj5ga5Y3BTGGNI28k117LJ009w==", "dev": true, - "engines": [ - "node >=0.6.0" - ], "dependencies": { - "assert-plus": "1.0.0", - "extsprintf": "1.3.0", - "json-schema": "0.2.3", - "verror": "1.10.0" + "esprima": "1.2.2", + "static-eval": "2.0.2", + "underscore": "1.12.1" } }, + "node_modules/JSONStream": { + "version": "1.3.5", + "resolved": "https://registry.npmjs.org/JSONStream/-/JSONStream-1.3.5.tgz", + "integrity": "sha512-E+iruNOY8VV9s4JEbe1aNEm6MiszPRr/UfcHMz0TQh1BXSxHK+ASV1R6W4HpjBhSeS+54PIsAMCBmwD06LLsqQ==", + "dev": true, + "dependencies": { + "jsonparse": "^1.2.0", + "through": ">=2.2.7 <3" + }, + "bin": { + "JSONStream": "bin.js" + }, + "engines": { + "node": "*" + } + }, + "node_modules/just-deep-map-values": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/just-deep-map-values/-/just-deep-map-values-1.1.1.tgz", + "integrity": "sha512-hCMqPI0FjM2wpOWBYgvrdZlmFZF+7PeC/IzBxvt7dgUsK/OFeFOwJ1kv40Vx5I3RJiWv7ninPUxjk2Af0YiDAw==", + "dev": true + }, "node_modules/just-diff": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/just-diff/-/just-diff-5.0.1.tgz", - "integrity": "sha512-X00TokkRIDotUIf3EV4xUm6ELc/IkqhS/vPSHdWnsM5y0HoNMfEqrazizI7g78lpHvnRSRt/PFfKtRqJCOGIuQ==", - "inBundle": true + "version": "5.1.1", + "inBundle": true, + "license": "MIT" }, "node_modules/just-diff-apply": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/just-diff-apply/-/just-diff-apply-4.0.1.tgz", - "integrity": "sha512-AKOkzB5P6FkfP21UlZVX/OPXx/sC2GagpLX9cBxqHqDuRjwmZ/AJRKSNrB9jHPpRW1W1ONs6gly1gW46t055nQ==", - "inBundle": true + "version": "5.4.1", + "inBundle": true, + "license": "MIT" }, - "node_modules/lcov-parse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/lcov-parse/-/lcov-parse-1.0.0.tgz", - "integrity": "sha1-6w1GtUER68VhrLTECO+TY73I9+A=", + "node_modules/just-extend": { + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/just-extend/-/just-extend-6.1.1.tgz", + "integrity": "sha512-1UWaMWIB90HnIZAmXOTLobwWc9lc1ZMUBRKf8PaozCAiNUif6wv1fyeXpqccWZCu7L9zxIgXG55vARuZluyvqw==", + "dev": true + }, + "node_modules/just-safe-set": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/just-safe-set/-/just-safe-set-4.1.1.tgz", + "integrity": "sha512-3tQtDVCvZfWc64yEbh2D8R80Zlz+x9LJVpkQ4K3ppdiO7iI1Jzf6wYgsAs1o/EMSwucRbaNb6JHex/24TbSaKw==", + "dev": true + }, + "node_modules/kind-of": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", + "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==", "dev": true, - "bin": { - "lcov-parse": "bin/cli.js" + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/kleur": { + "version": "4.1.5", + "resolved": "https://registry.npmjs.org/kleur/-/kleur-4.1.5.tgz", + "integrity": "sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ==", + "dev": true, + "engines": { + "node": ">=6" } }, "node_modules/levn": { @@ -4809,6 +6806,7 @@ "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", "dev": true, + "peer": true, "dependencies": { "prelude-ls": "^1.2.1", "type-check": "~0.4.0" @@ -4862,9 +6860,9 @@ "link": true }, "node_modules/libtap": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/libtap/-/libtap-1.1.4.tgz", - "integrity": "sha512-jM+QyAeRdVs1bJrNpjlu+l8gRdDkAehqls31AwSnqXghVLUP6nbYeU2Xfs2svYS7ZdksvnHvrxCKRBFEz/BCjA==", + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/libtap/-/libtap-1.4.0.tgz", + "integrity": "sha512-STLFynswQ2A6W14JkabgGetBNk6INL1REgJ9UeNKw5llXroC2cGLgKTqavv0sl8OLVztLLipVKMcQ7yeUcqpmg==", "dev": true, "dependencies": { "async-hook-domain": "^2.0.4", @@ -4876,11 +6874,10 @@ "own-or-env": "^1.0.2", "signal-exit": "^3.0.4", "stack-utils": "^2.0.4", - "tap-parser": "^10.0.1", + "tap-parser": "^11.0.0", "tap-yaml": "^1.0.0", "tcompare": "^5.0.6", - "trivial-deferred": "^1.0.1", - "yapool": "^1.0.0" + "trivial-deferred": "^1.0.1" }, "engines": { "node": ">=10" @@ -4898,39 +6895,86 @@ "node": ">=0.3.1" } }, - "node_modules/licensee": { - "version": "8.2.0", - "resolved": "https://registry.npmjs.org/licensee/-/licensee-8.2.0.tgz", - "integrity": "sha512-Z5fQ+qP85N38klGijH0bXiWVlKqLKDMqsckKL+VcA+ZQ/DJK5cpIpvryGHtREaQ3Ah5jrgtXN8mHfII7UtlsJg==", + "node_modules/libtap/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", "dev": true, "dependencies": { - "@blueoak/list": "^2.0.0", - "correct-license-metadata": "^1.0.1", + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/licensee": { + "version": "10.0.0", + "resolved": "https://registry.npmjs.org/licensee/-/licensee-10.0.0.tgz", + "integrity": "sha512-gvn5JHCNuchGGjjIm6FsK4qSOTtHkbUfo8YKW61hhEIk3osEf3fKlCH9ma0j+HaVESrOt0YUOmsi/wusKSnneQ==", + "dev": true, + "dependencies": { + "@blueoak/list": "^9.0.0", + "@npmcli/arborist": "^6.1.2", + "correct-license-metadata": "^1.4.0", "docopt": "^0.6.2", - "fs-access": "^2.0.0", "has": "^1.0.3", - "json-parse-errback": "^2.0.1", - "npm-license-corrections": "^1.0.0", - "read-package-tree": "^5.3.1", - "run-parallel": "^1.1.9", - "semver": "^6.3.0", - "simple-concat": "^1.0.0", - "spdx-expression-parse": "^3.0.0", + "npm-license-corrections": "^1.6.2", + "semver": "^7.3.8", + "spdx-expression-parse": "^3.0.1", "spdx-expression-validate": "^2.0.0", "spdx-osi": "^3.0.0", "spdx-whitelisted": "^1.0.0" }, "bin": { "licensee": "licensee" + }, + "engines": { + "node": ">= 14.17" } }, - "node_modules/licensee/node_modules/semver": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", - "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", + "node_modules/lines-and-columns": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", + "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", + "dev": true + }, + "node_modules/load-json-file": { + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-6.2.0.tgz", + "integrity": "sha512-gUD/epcRms75Cw8RT1pUdHugZYM5ce64ucs2GEISABwkRsOQr0q2wm/MV2TKThycIe5e0ytRweW2RZxclogCdQ==", "dev": true, - "bin": { - "semver": "bin/semver.js" + "dependencies": { + "graceful-fs": "^4.1.15", + "parse-json": "^5.0.0", + "strip-bom": "^4.0.0", + "type-fest": "^0.6.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/load-json-file/node_modules/type-fest": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.6.0.tgz", + "integrity": "sha512-q+MB8nYR1KDLrgr4G5yemftpMC7/QLqVndBmEEdqzmNj5dcFOO4Oo8qlwZE3ULT3+Zim1F8Kq4cBnikNhlCMlg==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/locate-path": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", + "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "dev": true, + "dependencies": { + "p-locate": "^5.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/lodash": { @@ -4942,52 +6986,44 @@ "node_modules/lodash.clonedeep": { "version": "4.5.0", "resolved": "https://registry.npmjs.org/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz", - "integrity": "sha1-4j8/nE+Pvd6HJSnBBxhXoIblzO8=", + "integrity": "sha512-H5ZhCF25riFd9uB5UCkVKo61m3S/xZk1x4wA6yp/L3RFP6Z/eHH1ymQcGLo7J3GMPfm0V/7m1tryHuGVxpqEBQ==", "dev": true }, "node_modules/lodash.flattendeep": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz", - "integrity": "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=", + "integrity": "sha512-uHaJFihxmJcEX3kT4I23ABqKKalJ/zDrDg0lsFtc1h+3uw49SIJ5beyhx5ExVRti3AvKoOJngIj7xz3oylPdWQ==", + "dev": true + }, + "node_modules/lodash.ismatch": { + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/lodash.ismatch/-/lodash.ismatch-4.4.0.tgz", + "integrity": "sha512-fPMfXjGQEV9Xsq/8MTSgUf255gawYRbjwMyDbcvDhXgV7enSZA0hynz6vMPnpAb5iONEzBHBPsT+0zes5Z301g==", "dev": true }, "node_modules/lodash.merge": { "version": "4.6.2", "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==", - "dev": true - }, - "node_modules/lodash.set": { - "version": "4.3.2", - "resolved": "https://registry.npmjs.org/lodash.set/-/lodash.set-4.3.2.tgz", - "integrity": "sha1-2HV7HagH3eJIFrDWqEvqGnYjCyM=", - "dev": true - }, - "node_modules/lodash.uniq": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/lodash.uniq/-/lodash.uniq-4.5.0.tgz", - "integrity": "sha1-0CJTc662Uq3BvILklFM5qEJ1R3M=", - "dev": true - }, - "node_modules/log-driver": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/log-driver/-/log-driver-1.2.7.tgz", - "integrity": "sha512-U7KCmLdqsGHBLeWqYlFA0V0Sl6P08EE1ZrmA9cxjUE0WVqT9qnyVDPz1kzpFEP0jdJuFnasWIfSd7fsaNXkpbg==", "dev": true, - "engines": { - "node": ">=0.8.6" + "peer": true + }, + "node_modules/longest-streak": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/longest-streak/-/longest-streak-3.0.1.tgz", + "integrity": "sha512-cHlYSUpL2s7Fb3394mYxwTYj8niTaNHUCLr0qdiCXQfSjfuA7CKofpX2uSwEfFDQ0EB7JcnMnm+GjbqqoinYYg==", + "dev": true, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" } }, "node_modules/lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "version": "7.13.2", "inBundle": true, - "dependencies": { - "yallist": "^4.0.0" - }, + "license": "ISC", "engines": { - "node": ">=10" + "node": ">=12" } }, "node_modules/make-dir": { @@ -5018,158 +7054,39 @@ "version": "1.3.6", "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", - "dev": true, - "optional": true, - "peer": true + "dev": true }, "node_modules/make-fetch-happen": { - "version": "10.0.3", - "resolved": "https://registry.npmjs.org/make-fetch-happen/-/make-fetch-happen-10.0.3.tgz", - "integrity": "sha512-CzarPHynPpHjhF5in/YapnO44rSZeYX5VCMfdXa99+gLwpbfFLh20CWa6dP/taV9Net9PWJwXNKtp/4ZTCQnag==", + "version": "11.0.2", + "resolved": "https://registry.npmjs.org/make-fetch-happen/-/make-fetch-happen-11.0.2.tgz", + "integrity": "sha512-5n/Pq41w/uZghpdlXAY5kIM85RgJThtTH/NYBRAZ9VUOBWV90USaQjwGrw76fZP3Lj5hl/VZjpVvOaRBMoL/2w==", "inBundle": true, "dependencies": { - "agentkeepalive": "^4.2.0", - "cacache": "^15.3.0", + "agentkeepalive": "^4.2.1", + "cacache": "^17.0.0", "http-cache-semantics": "^4.1.0", "http-proxy-agent": "^5.0.0", "https-proxy-agent": "^5.0.0", "is-lambda": "^1.0.1", - "lru-cache": "^7.3.1", - "minipass": "^3.1.6", + "lru-cache": "^7.7.1", + "minipass": "^4.0.0", "minipass-collect": "^1.0.2", - "minipass-fetch": "^1.4.1", + "minipass-fetch": "^3.0.0", "minipass-flush": "^1.0.5", "minipass-pipeline": "^1.2.4", "negotiator": "^0.6.3", "promise-retry": "^2.0.1", - "socks-proxy-agent": "^6.1.1", - "ssri": "^8.0.1" + "socks-proxy-agent": "^7.0.0", + "ssri": "^10.0.0" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/make-fetch-happen/node_modules/lru-cache": { - "version": "7.3.1", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-7.3.1.tgz", - "integrity": "sha512-nX1x4qUrKqwbIAhv4s9et4FIUVzNOpeY07bsjGUy8gwJrXH/wScImSQqXErmo/b2jZY2r0mohbLA9zVj7u1cNw==", - "inBundle": true, - "engines": { - "node": ">=12" - } - }, - "node_modules/markdown-escapes": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/markdown-escapes/-/markdown-escapes-1.0.4.tgz", - "integrity": "sha512-8z4efJYk43E0upd0NbVXwgSTQs6cT3T06etieCMEg7dRbzCbxUCK/GHlX8mhHRDcp+OLlHkPKsvqQTCvsRl2cg==", - "dev": true, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/marked": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/marked/-/marked-0.7.0.tgz", - "integrity": "sha512-c+yYdCZJQrsRjTPhUx7VKkApw9bwDkNbHUKo1ovgcfDjb2kc8rLuRbIFyXL5WOEUwzSSKo3IXpph2K6DqB/KZg==", - "dev": true, - "peer": true, - "bin": { - "marked": "bin/marked" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/marked-man": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/marked-man/-/marked-man-0.7.0.tgz", - "integrity": "sha512-zxK5E4jbuARALc+fIUAanM2njVGnrd9YvKrqoDHUg2XwNLJijo39EzMIg59LecHBHsIHNtPqepqnJp4SmL/EVg==", - "dev": true, - "bin": { - "marked-man": "bin/marked-man" - }, - "peerDependencies": { - "marked": "^0.7.0" - } - }, - "node_modules/mdast-squeeze-paragraphs": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/mdast-squeeze-paragraphs/-/mdast-squeeze-paragraphs-4.0.0.tgz", - "integrity": "sha512-zxdPn69hkQ1rm4J+2Cs2j6wDEv7O17TfXTJ33tl/+JPIoEmtV9t2ZzBM5LPHE8QlHsmVD8t3vPKCyY3oH+H8MQ==", - "dev": true, - "dependencies": { - "unist-util-remove": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-definitions": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-definitions/-/mdast-util-definitions-4.0.0.tgz", - "integrity": "sha512-k8AJ6aNnUkB7IE+5azR9h81O5EQ/cTDXtWdMq9Kk5KcEW/8ritU5CeLg/9HhOC++nALHBlaogJ5jz0Ybk3kPMQ==", - "dev": true, - "dependencies": { - "unist-util-visit": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdast-util-to-hast": { - "version": "10.0.1", - "resolved": "https://registry.npmjs.org/mdast-util-to-hast/-/mdast-util-to-hast-10.0.1.tgz", - "integrity": "sha512-BW3LM9SEMnjf4HXXVApZMt8gLQWVNXc3jryK0nJu/rOXPOnlkUjmdkDlmxMirpbU9ILncGFIwLH/ubnWBbcdgA==", - "dev": true, - "dependencies": { - "@types/mdast": "^3.0.0", - "@types/unist": "^2.0.0", - "mdast-util-definitions": "^4.0.0", - "mdurl": "^1.0.0", - "unist-builder": "^2.0.0", - "unist-util-generated": "^1.0.0", - "unist-util-position": "^3.0.0", - "unist-util-visit": "^2.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/mdurl": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/mdurl/-/mdurl-1.0.1.tgz", - "integrity": "sha1-/oWy7HWlkDfyrf7BAP1sYBdhFS4=", - "dev": true - }, - "node_modules/mime-db": { - "version": "1.49.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.49.0.tgz", - "integrity": "sha512-CIc8j9URtOVApSFCQIF+VBkX1RwXp/oMMOrqdyXSBXq5RWNEsRfyj1kiRnQgmNXmHxPoFIxOroKA3zcU9P+nAA==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mime-types": { - "version": "2.1.32", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.32.tgz", - "integrity": "sha512-hJGaVS4G4c9TSMYh2n6SQAGrC4RnfU+daP8G7cSCmaqNjiOoUY0VHCMS42pxnQmVF1GWwFhbHWn3RIxCqTmZ9A==", - "dev": true, - "dependencies": { - "mime-db": "1.49.0" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mimic-response": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-2.1.0.tgz", - "integrity": "sha512-wXqjST+SLt7R009ySCglWBCFpjUygmCIfD790/kVbiGmUgfYGuB14PiTd5DwVxSV4NcYHjzMkoj5LjQZwTQLEA==", + "node_modules/map-obj": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/map-obj/-/map-obj-4.3.0.tgz", + "integrity": "sha512-hdN1wVrZbb29eBGiGjJbeP8JbKjq1urkHJ/LIP/NY48MZ1QVXUsQBV1G1zvYFHn1XE06cwjBsOI2K3Ulnj1YXQ==", "dev": true, "engines": { "node": ">=8" @@ -5178,34 +7095,1061 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/minify-registry-metadata": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/minify-registry-metadata/-/minify-registry-metadata-2.2.0.tgz", - "integrity": "sha512-kBVcTfDnYx9nL1U+6l6drCrZHPlkEoniLLud//nXxXvJAx0D7P4IHU2vkcCrLozoAPomiIX/CzaEXFm1CmT/8A==", - "dev": true + "node_modules/markdown-table": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/markdown-table/-/markdown-table-3.0.2.tgz", + "integrity": "sha512-y8j3a5/DkJCmS5x4dMCQL+OR0+2EAq3DOtio1COSHsmW2BGXnNCK3v12hJt1LrUz5iZH5g0LmuYOjDdI+czghA==", + "dev": true, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } }, - "node_modules/minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "inBundle": true, + "node_modules/mdast-util-definitions": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/mdast-util-definitions/-/mdast-util-definitions-5.1.1.tgz", + "integrity": "sha512-rQ+Gv7mHttxHOBx2dkF4HWTg+EE+UR78ptQWDylzPKaQuVGdG4HIoY3SrS/pCp80nZ04greFvXbVFHT+uf0JVQ==", + "dev": true, "dependencies": { - "brace-expansion": "^1.1.7" + "@types/mdast": "^3.0.0", + "@types/unist": "^2.0.0", + "unist-util-visit": "^4.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-definitions/node_modules/unist-util-visit": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-4.1.1.tgz", + "integrity": "sha512-n9KN3WV9k4h1DxYR1LoajgN93wpEi/7ZplVe02IoB4gH5ctI1AaF2670BLHQYbwj+pY83gFtyeySFiyMHJklrg==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^5.0.0", + "unist-util-visit-parents": "^5.1.1" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-definitions/node_modules/unist-util-visit-parents": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-5.1.1.tgz", + "integrity": "sha512-gks4baapT/kNRaWxuGkl5BIhoanZo7sC/cUT/JToSRNL1dYoXRFl75d++NkjYk4TAu2uv2Px+l8guMajogeuiw==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^5.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-find-and-replace": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/mdast-util-find-and-replace/-/mdast-util-find-and-replace-2.2.1.tgz", + "integrity": "sha512-SobxkQXFAdd4b5WmEakmkVoh18icjQRxGy5OWTCzgsLRm1Fu/KCtwD1HIQSsmq5ZRjVH0Ehwg6/Fn3xIUk+nKw==", + "dev": true, + "dependencies": { + "escape-string-regexp": "^5.0.0", + "unist-util-is": "^5.0.0", + "unist-util-visit-parents": "^5.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-find-and-replace/node_modules/escape-string-regexp": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-5.0.0.tgz", + "integrity": "sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/mdast-util-find-and-replace/node_modules/unist-util-visit-parents": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-5.1.1.tgz", + "integrity": "sha512-gks4baapT/kNRaWxuGkl5BIhoanZo7sC/cUT/JToSRNL1dYoXRFl75d++NkjYk4TAu2uv2Px+l8guMajogeuiw==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^5.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-from-markdown": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/mdast-util-from-markdown/-/mdast-util-from-markdown-1.2.0.tgz", + "integrity": "sha512-iZJyyvKD1+K7QX1b5jXdE7Sc5dtoTry1vzV28UZZe8Z1xVnB/czKntJ7ZAkG0tANqRnBF6p3p7GpU1y19DTf2Q==", + "dev": true, + "dependencies": { + "@types/mdast": "^3.0.0", + "@types/unist": "^2.0.0", + "decode-named-character-reference": "^1.0.0", + "mdast-util-to-string": "^3.1.0", + "micromark": "^3.0.0", + "micromark-util-decode-numeric-character-reference": "^1.0.0", + "micromark-util-decode-string": "^1.0.0", + "micromark-util-normalize-identifier": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0", + "unist-util-stringify-position": "^3.0.0", + "uvu": "^0.5.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-gfm": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/mdast-util-gfm/-/mdast-util-gfm-2.0.1.tgz", + "integrity": "sha512-42yHBbfWIFisaAfV1eixlabbsa6q7vHeSPY+cg+BBjX51M8xhgMacqH9g6TftB/9+YkcI0ooV4ncfrJslzm/RQ==", + "dev": true, + "dependencies": { + "mdast-util-from-markdown": "^1.0.0", + "mdast-util-gfm-autolink-literal": "^1.0.0", + "mdast-util-gfm-footnote": "^1.0.0", + "mdast-util-gfm-strikethrough": "^1.0.0", + "mdast-util-gfm-table": "^1.0.0", + "mdast-util-gfm-task-list-item": "^1.0.0", + "mdast-util-to-markdown": "^1.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-gfm-autolink-literal": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/mdast-util-gfm-autolink-literal/-/mdast-util-gfm-autolink-literal-1.0.2.tgz", + "integrity": "sha512-FzopkOd4xTTBeGXhXSBU0OCDDh5lUj2rd+HQqG92Ld+jL4lpUfgX2AT2OHAVP9aEeDKp7G92fuooSZcYJA3cRg==", + "dev": true, + "dependencies": { + "@types/mdast": "^3.0.0", + "ccount": "^2.0.0", + "mdast-util-find-and-replace": "^2.0.0", + "micromark-util-character": "^1.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-gfm-footnote": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/mdast-util-gfm-footnote/-/mdast-util-gfm-footnote-1.0.1.tgz", + "integrity": "sha512-p+PrYlkw9DeCRkTVw1duWqPRHX6Ywh2BNKJQcZbCwAuP/59B0Lk9kakuAd7KbQprVO4GzdW8eS5++A9PUSqIyw==", + "dev": true, + "dependencies": { + "@types/mdast": "^3.0.0", + "mdast-util-to-markdown": "^1.3.0", + "micromark-util-normalize-identifier": "^1.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-gfm-strikethrough": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/mdast-util-gfm-strikethrough/-/mdast-util-gfm-strikethrough-1.0.2.tgz", + "integrity": "sha512-T/4DVHXcujH6jx1yqpcAYYwd+z5lAYMw4Ls6yhTfbMMtCt0PHY4gEfhW9+lKsLBtyhUGKRIzcUA2FATVqnvPDA==", + "dev": true, + "dependencies": { + "@types/mdast": "^3.0.0", + "mdast-util-to-markdown": "^1.3.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-gfm-table": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/mdast-util-gfm-table/-/mdast-util-gfm-table-1.0.6.tgz", + "integrity": "sha512-uHR+fqFq3IvB3Rd4+kzXW8dmpxUhvgCQZep6KdjsLK4O6meK5dYZEayLtIxNus1XO3gfjfcIFe8a7L0HZRGgag==", + "dev": true, + "dependencies": { + "@types/mdast": "^3.0.0", + "markdown-table": "^3.0.0", + "mdast-util-from-markdown": "^1.0.0", + "mdast-util-to-markdown": "^1.3.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-gfm-task-list-item": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/mdast-util-gfm-task-list-item/-/mdast-util-gfm-task-list-item-1.0.1.tgz", + "integrity": "sha512-KZ4KLmPdABXOsfnM6JHUIjxEvcx2ulk656Z/4Balw071/5qgnhz+H1uGtf2zIGnrnvDC8xR4Fj9uKbjAFGNIeA==", + "dev": true, + "dependencies": { + "@types/mdast": "^3.0.0", + "mdast-util-to-markdown": "^1.3.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-to-hast": { + "version": "12.2.4", + "resolved": "https://registry.npmjs.org/mdast-util-to-hast/-/mdast-util-to-hast-12.2.4.tgz", + "integrity": "sha512-a21xoxSef1l8VhHxS1Dnyioz6grrJkoaCUgGzMD/7dWHvboYX3VW53esRUfB5tgTyz4Yos1n25SPcj35dJqmAg==", + "dev": true, + "dependencies": { + "@types/hast": "^2.0.0", + "@types/mdast": "^3.0.0", + "mdast-util-definitions": "^5.0.0", + "micromark-util-sanitize-uri": "^1.1.0", + "trim-lines": "^3.0.0", + "unist-builder": "^3.0.0", + "unist-util-generated": "^2.0.0", + "unist-util-position": "^4.0.0", + "unist-util-visit": "^4.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-to-hast/node_modules/unist-util-visit": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-4.1.1.tgz", + "integrity": "sha512-n9KN3WV9k4h1DxYR1LoajgN93wpEi/7ZplVe02IoB4gH5ctI1AaF2670BLHQYbwj+pY83gFtyeySFiyMHJklrg==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^5.0.0", + "unist-util-visit-parents": "^5.1.1" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-to-hast/node_modules/unist-util-visit-parents": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-5.1.1.tgz", + "integrity": "sha512-gks4baapT/kNRaWxuGkl5BIhoanZo7sC/cUT/JToSRNL1dYoXRFl75d++NkjYk4TAu2uv2Px+l8guMajogeuiw==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^5.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-to-markdown": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/mdast-util-to-markdown/-/mdast-util-to-markdown-1.3.0.tgz", + "integrity": "sha512-6tUSs4r+KK4JGTTiQ7FfHmVOaDrLQJPmpjD6wPMlHGUVXoG9Vjc3jIeP+uyBWRf8clwB2blM+W7+KrlMYQnftA==", + "dev": true, + "dependencies": { + "@types/mdast": "^3.0.0", + "@types/unist": "^2.0.0", + "longest-streak": "^3.0.0", + "mdast-util-to-string": "^3.0.0", + "micromark-util-decode-string": "^1.0.0", + "unist-util-visit": "^4.0.0", + "zwitch": "^2.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-to-markdown/node_modules/unist-util-visit": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-4.1.1.tgz", + "integrity": "sha512-n9KN3WV9k4h1DxYR1LoajgN93wpEi/7ZplVe02IoB4gH5ctI1AaF2670BLHQYbwj+pY83gFtyeySFiyMHJklrg==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^5.0.0", + "unist-util-visit-parents": "^5.1.1" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-to-markdown/node_modules/unist-util-visit-parents": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-5.1.1.tgz", + "integrity": "sha512-gks4baapT/kNRaWxuGkl5BIhoanZo7sC/cUT/JToSRNL1dYoXRFl75d++NkjYk4TAu2uv2Px+l8guMajogeuiw==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^5.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/mdast-util-to-string": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/mdast-util-to-string/-/mdast-util-to-string-3.1.0.tgz", + "integrity": "sha512-n4Vypz/DZgwo0iMHLQL49dJzlp7YtAJP+N07MZHpjPf/5XJuHUWstviF4Mn2jEiR/GNmtnRRqnwsXExk3igfFA==", + "dev": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/meow": { + "version": "8.1.2", + "resolved": "https://registry.npmjs.org/meow/-/meow-8.1.2.tgz", + "integrity": "sha512-r85E3NdZ+mpYk1C6RjPFEMSE+s1iZMuHtsHAqY0DT3jZczl0diWUZ8g6oU7h0M9cD2EL+PzaYghhCLzR0ZNn5Q==", + "dev": true, + "dependencies": { + "@types/minimist": "^1.2.0", + "camelcase-keys": "^6.2.2", + "decamelize-keys": "^1.1.0", + "hard-rejection": "^2.1.0", + "minimist-options": "4.1.0", + "normalize-package-data": "^3.0.0", + "read-pkg-up": "^7.0.1", + "redent": "^3.0.0", + "trim-newlines": "^3.0.0", + "type-fest": "^0.18.0", + "yargs-parser": "^20.2.3" }, "engines": { - "node": "*" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/meow/node_modules/hosted-git-info": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", + "integrity": "sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==", + "dev": true, + "dependencies": { + "lru-cache": "^6.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/meow/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/meow/node_modules/normalize-package-data": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-3.0.3.tgz", + "integrity": "sha512-p2W1sgqij3zMMyRC067Dg16bfzVH+w7hyegmpIvZ4JNjqtGOVAIvLmjBx3yP7YTe9vKJgkoNOPjwQGogDoMXFA==", + "dev": true, + "dependencies": { + "hosted-git-info": "^4.0.1", + "is-core-module": "^2.5.0", + "semver": "^7.3.4", + "validate-npm-package-license": "^3.0.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/meow/node_modules/type-fest": { + "version": "0.18.1", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.18.1.tgz", + "integrity": "sha512-OIAYXk8+ISY+qTOwkHtKqzAuxchoMiD9Udx+FSGQDuiRR+PJKJHc2NJAXlbhkGwTt/4/nKZxELY1w3ReWOL8mw==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/merge-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", + "dev": true + }, + "node_modules/micromark": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/micromark/-/micromark-3.1.0.tgz", + "integrity": "sha512-6Mj0yHLdUZjHnOPgr5xfWIMqMWS12zDN6iws9SLuSz76W8jTtAv24MN4/CL7gJrl5vtxGInkkqDv/JIoRsQOvA==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "@types/debug": "^4.0.0", + "debug": "^4.0.0", + "decode-named-character-reference": "^1.0.0", + "micromark-core-commonmark": "^1.0.1", + "micromark-factory-space": "^1.0.0", + "micromark-util-character": "^1.0.0", + "micromark-util-chunked": "^1.0.0", + "micromark-util-combine-extensions": "^1.0.0", + "micromark-util-decode-numeric-character-reference": "^1.0.0", + "micromark-util-encode": "^1.0.0", + "micromark-util-normalize-identifier": "^1.0.0", + "micromark-util-resolve-all": "^1.0.0", + "micromark-util-sanitize-uri": "^1.0.0", + "micromark-util-subtokenize": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.1", + "uvu": "^0.5.0" + } + }, + "node_modules/micromark-core-commonmark": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/micromark-core-commonmark/-/micromark-core-commonmark-1.0.6.tgz", + "integrity": "sha512-K+PkJTxqjFfSNkfAhp4GB+cZPfQd6dxtTXnf+RjZOV7T4EEXnvgzOcnp+eSTmpGk9d1S9sL6/lqrgSNn/s0HZA==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "decode-named-character-reference": "^1.0.0", + "micromark-factory-destination": "^1.0.0", + "micromark-factory-label": "^1.0.0", + "micromark-factory-space": "^1.0.0", + "micromark-factory-title": "^1.0.0", + "micromark-factory-whitespace": "^1.0.0", + "micromark-util-character": "^1.0.0", + "micromark-util-chunked": "^1.0.0", + "micromark-util-classify-character": "^1.0.0", + "micromark-util-html-tag-name": "^1.0.0", + "micromark-util-normalize-identifier": "^1.0.0", + "micromark-util-resolve-all": "^1.0.0", + "micromark-util-subtokenize": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.1", + "uvu": "^0.5.0" + } + }, + "node_modules/micromark-extension-gfm": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/micromark-extension-gfm/-/micromark-extension-gfm-2.0.1.tgz", + "integrity": "sha512-p2sGjajLa0iYiGQdT0oelahRYtMWvLjy8J9LOCxzIQsllMCGLbsLW+Nc+N4vi02jcRJvedVJ68cjelKIO6bpDA==", + "dev": true, + "dependencies": { + "micromark-extension-gfm-autolink-literal": "^1.0.0", + "micromark-extension-gfm-footnote": "^1.0.0", + "micromark-extension-gfm-strikethrough": "^1.0.0", + "micromark-extension-gfm-table": "^1.0.0", + "micromark-extension-gfm-tagfilter": "^1.0.0", + "micromark-extension-gfm-task-list-item": "^1.0.0", + "micromark-util-combine-extensions": "^1.0.0", + "micromark-util-types": "^1.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/micromark-extension-gfm-autolink-literal": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/micromark-extension-gfm-autolink-literal/-/micromark-extension-gfm-autolink-literal-1.0.3.tgz", + "integrity": "sha512-i3dmvU0htawfWED8aHMMAzAVp/F0Z+0bPh3YrbTPPL1v4YAlCZpy5rBO5p0LPYiZo0zFVkoYh7vDU7yQSiCMjg==", + "dev": true, + "dependencies": { + "micromark-util-character": "^1.0.0", + "micromark-util-sanitize-uri": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0", + "uvu": "^0.5.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/micromark-extension-gfm-footnote": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/micromark-extension-gfm-footnote/-/micromark-extension-gfm-footnote-1.0.4.tgz", + "integrity": "sha512-E/fmPmDqLiMUP8mLJ8NbJWJ4bTw6tS+FEQS8CcuDtZpILuOb2kjLqPEeAePF1djXROHXChM/wPJw0iS4kHCcIg==", + "dev": true, + "dependencies": { + "micromark-core-commonmark": "^1.0.0", + "micromark-factory-space": "^1.0.0", + "micromark-util-character": "^1.0.0", + "micromark-util-normalize-identifier": "^1.0.0", + "micromark-util-sanitize-uri": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0", + "uvu": "^0.5.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/micromark-extension-gfm-strikethrough": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/micromark-extension-gfm-strikethrough/-/micromark-extension-gfm-strikethrough-1.0.4.tgz", + "integrity": "sha512-/vjHU/lalmjZCT5xt7CcHVJGq8sYRm80z24qAKXzaHzem/xsDYb2yLL+NNVbYvmpLx3O7SYPuGL5pzusL9CLIQ==", + "dev": true, + "dependencies": { + "micromark-util-chunked": "^1.0.0", + "micromark-util-classify-character": "^1.0.0", + "micromark-util-resolve-all": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0", + "uvu": "^0.5.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/micromark-extension-gfm-table": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/micromark-extension-gfm-table/-/micromark-extension-gfm-table-1.0.5.tgz", + "integrity": "sha512-xAZ8J1X9W9K3JTJTUL7G6wSKhp2ZYHrFk5qJgY/4B33scJzE2kpfRL6oiw/veJTbt7jiM/1rngLlOKPWr1G+vg==", + "dev": true, + "dependencies": { + "micromark-factory-space": "^1.0.0", + "micromark-util-character": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0", + "uvu": "^0.5.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/micromark-extension-gfm-tagfilter": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/micromark-extension-gfm-tagfilter/-/micromark-extension-gfm-tagfilter-1.0.1.tgz", + "integrity": "sha512-Ty6psLAcAjboRa/UKUbbUcwjVAv5plxmpUTy2XC/3nJFL37eHej8jrHrRzkqcpipJliuBH30DTs7+3wqNcQUVA==", + "dev": true, + "dependencies": { + "micromark-util-types": "^1.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/micromark-extension-gfm-task-list-item": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/micromark-extension-gfm-task-list-item/-/micromark-extension-gfm-task-list-item-1.0.3.tgz", + "integrity": "sha512-PpysK2S1Q/5VXi72IIapbi/jliaiOFzv7THH4amwXeYXLq3l1uo8/2Be0Ac1rEwK20MQEsGH2ltAZLNY2KI/0Q==", + "dev": true, + "dependencies": { + "micromark-factory-space": "^1.0.0", + "micromark-util-character": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0", + "uvu": "^0.5.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/micromark-factory-destination": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/micromark-factory-destination/-/micromark-factory-destination-1.0.0.tgz", + "integrity": "sha512-eUBA7Rs1/xtTVun9TmV3gjfPz2wEwgK5R5xcbIM5ZYAtvGF6JkyaDsj0agx8urXnO31tEO6Ug83iVH3tdedLnw==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-character": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0" + } + }, + "node_modules/micromark-factory-label": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/micromark-factory-label/-/micromark-factory-label-1.0.2.tgz", + "integrity": "sha512-CTIwxlOnU7dEshXDQ+dsr2n+yxpP0+fn271pu0bwDIS8uqfFcumXpj5mLn3hSC8iw2MUr6Gx8EcKng1dD7i6hg==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-character": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0", + "uvu": "^0.5.0" + } + }, + "node_modules/micromark-factory-space": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/micromark-factory-space/-/micromark-factory-space-1.0.0.tgz", + "integrity": "sha512-qUmqs4kj9a5yBnk3JMLyjtWYN6Mzfcx8uJfi5XAveBniDevmZasdGBba5b4QsvRcAkmvGo5ACmSUmyGiKTLZew==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-character": "^1.0.0", + "micromark-util-types": "^1.0.0" + } + }, + "node_modules/micromark-factory-title": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/micromark-factory-title/-/micromark-factory-title-1.0.2.tgz", + "integrity": "sha512-zily+Nr4yFqgMGRKLpTVsNl5L4PMu485fGFDOQJQBl2NFpjGte1e86zC0da93wf97jrc4+2G2GQudFMHn3IX+A==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-factory-space": "^1.0.0", + "micromark-util-character": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0", + "uvu": "^0.5.0" + } + }, + "node_modules/micromark-factory-whitespace": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/micromark-factory-whitespace/-/micromark-factory-whitespace-1.0.0.tgz", + "integrity": "sha512-Qx7uEyahU1lt1RnsECBiuEbfr9INjQTGa6Err+gF3g0Tx4YEviPbqqGKNv/NrBaE7dVHdn1bVZKM/n5I/Bak7A==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-factory-space": "^1.0.0", + "micromark-util-character": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0" + } + }, + "node_modules/micromark-util-character": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/micromark-util-character/-/micromark-util-character-1.1.0.tgz", + "integrity": "sha512-agJ5B3unGNJ9rJvADMJ5ZiYjBRyDpzKAOk01Kpi1TKhlT1APx3XZk6eN7RtSz1erbWHC2L8T3xLZ81wdtGRZzg==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0" + } + }, + "node_modules/micromark-util-chunked": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/micromark-util-chunked/-/micromark-util-chunked-1.0.0.tgz", + "integrity": "sha512-5e8xTis5tEZKgesfbQMKRCyzvffRRUX+lK/y+DvsMFdabAicPkkZV6gO+FEWi9RfuKKoxxPwNL+dFF0SMImc1g==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-symbol": "^1.0.0" + } + }, + "node_modules/micromark-util-classify-character": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/micromark-util-classify-character/-/micromark-util-classify-character-1.0.0.tgz", + "integrity": "sha512-F8oW2KKrQRb3vS5ud5HIqBVkCqQi224Nm55o5wYLzY/9PwHGXC01tr3d7+TqHHz6zrKQ72Okwtvm/xQm6OVNZA==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-character": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0" + } + }, + "node_modules/micromark-util-combine-extensions": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/micromark-util-combine-extensions/-/micromark-util-combine-extensions-1.0.0.tgz", + "integrity": "sha512-J8H058vFBdo/6+AsjHp2NF7AJ02SZtWaVUjsayNFeAiydTxUwViQPxN0Hf8dp4FmCQi0UUFovFsEyRSUmFH3MA==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-chunked": "^1.0.0", + "micromark-util-types": "^1.0.0" + } + }, + "node_modules/micromark-util-decode-numeric-character-reference": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/micromark-util-decode-numeric-character-reference/-/micromark-util-decode-numeric-character-reference-1.0.0.tgz", + "integrity": "sha512-OzO9AI5VUtrTD7KSdagf4MWgHMtET17Ua1fIpXTpuhclCqD8egFWo85GxSGvxgkGS74bEahvtM0WP0HjvV0e4w==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-symbol": "^1.0.0" + } + }, + "node_modules/micromark-util-decode-string": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/micromark-util-decode-string/-/micromark-util-decode-string-1.0.2.tgz", + "integrity": "sha512-DLT5Ho02qr6QWVNYbRZ3RYOSSWWFuH3tJexd3dgN1odEuPNxCngTCXJum7+ViRAd9BbdxCvMToPOD/IvVhzG6Q==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "decode-named-character-reference": "^1.0.0", + "micromark-util-character": "^1.0.0", + "micromark-util-decode-numeric-character-reference": "^1.0.0", + "micromark-util-symbol": "^1.0.0" + } + }, + "node_modules/micromark-util-encode": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/micromark-util-encode/-/micromark-util-encode-1.0.1.tgz", + "integrity": "sha512-U2s5YdnAYexjKDel31SVMPbfi+eF8y1U4pfiRW/Y8EFVCy/vgxk/2wWTxzcqE71LHtCuCzlBDRU2a5CQ5j+mQA==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ] + }, + "node_modules/micromark-util-html-tag-name": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/micromark-util-html-tag-name/-/micromark-util-html-tag-name-1.1.0.tgz", + "integrity": "sha512-BKlClMmYROy9UiV03SwNmckkjn8QHVaWkqoAqzivabvdGcwNGMMMH/5szAnywmsTBUzDsU57/mFi0sp4BQO6dA==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ] + }, + "node_modules/micromark-util-normalize-identifier": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/micromark-util-normalize-identifier/-/micromark-util-normalize-identifier-1.0.0.tgz", + "integrity": "sha512-yg+zrL14bBTFrQ7n35CmByWUTFsgst5JhA4gJYoty4Dqzj4Z4Fr/DHekSS5aLfH9bdlfnSvKAWsAgJhIbogyBg==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-symbol": "^1.0.0" + } + }, + "node_modules/micromark-util-resolve-all": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/micromark-util-resolve-all/-/micromark-util-resolve-all-1.0.0.tgz", + "integrity": "sha512-CB/AGk98u50k42kvgaMM94wzBqozSzDDaonKU7P7jwQIuH2RU0TeBqGYJz2WY1UdihhjweivStrJ2JdkdEmcfw==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-types": "^1.0.0" + } + }, + "node_modules/micromark-util-sanitize-uri": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/micromark-util-sanitize-uri/-/micromark-util-sanitize-uri-1.1.0.tgz", + "integrity": "sha512-RoxtuSCX6sUNtxhbmsEFQfWzs8VN7cTctmBPvYivo98xb/kDEoTCtJQX5wyzIYEmk/lvNFTat4hL8oW0KndFpg==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-character": "^1.0.0", + "micromark-util-encode": "^1.0.0", + "micromark-util-symbol": "^1.0.0" + } + }, + "node_modules/micromark-util-subtokenize": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/micromark-util-subtokenize/-/micromark-util-subtokenize-1.0.2.tgz", + "integrity": "sha512-d90uqCnXp/cy4G881Ub4psE57Sf8YD0pim9QdjCRNjfas2M1u6Lbt+XZK9gnHL2XFhnozZiEdCa9CNfXSfQ6xA==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "dependencies": { + "micromark-util-chunked": "^1.0.0", + "micromark-util-symbol": "^1.0.0", + "micromark-util-types": "^1.0.0", + "uvu": "^0.5.0" + } + }, + "node_modules/micromark-util-symbol": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/micromark-util-symbol/-/micromark-util-symbol-1.0.1.tgz", + "integrity": "sha512-oKDEMK2u5qqAptasDAwWDXq0tG9AssVwAx3E9bBF3t/shRIGsWIRG+cGafs2p/SnDSOecnt6hZPCE2o6lHfFmQ==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ] + }, + "node_modules/micromark-util-types": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/micromark-util-types/-/micromark-util-types-1.0.2.tgz", + "integrity": "sha512-DCfg/T8fcrhrRKTPjRrw/5LLvdGV7BHySf/1LOZx7TzWZdYRjogNtyNq885z3nNallwr3QUKARjqvHqX1/7t+w==", + "dev": true, + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ] + }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "dev": true, + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/min-indent": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/min-indent/-/min-indent-1.0.1.tgz", + "integrity": "sha512-I9jwMn07Sy/IwOj3zVkVik2JTvgpaykDZEigL6Rx6N9LbMywwUSMtxET+7lVoDLLd3O3IXwJwvuuns8UB/HeAg==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/minify-registry-metadata": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/minify-registry-metadata/-/minify-registry-metadata-3.0.0.tgz", + "integrity": "sha512-EvM09tT0saeVP2Tlu9WEUDUgTYi684LsBbC+nbU3XEENgnzz+aEskigZR+OYG8LJPat1FdSIKMkJLMojg0FIiQ==", + "dev": true, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/minimatch": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.1.tgz", + "integrity": "sha512-362NP+zlprccbEt/SkxKfRMHnNY85V74mVnpUpNyr3F35covl09Kec7/sEFLt3RA4oXmewtoaanoIf67SE5Y5g==", + "inBundle": true, + "dependencies": { + "brace-expansion": "^2.0.1" + }, + "engines": { + "node": ">=10" } }, "node_modules/minimist": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", - "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", - "dev": true + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.7.tgz", + "integrity": "sha512-bzfL1YUZsP41gmu/qjrEk0Q6i2ix/cVeAhbCbqH9u3zYutS1cLg00qhrD0M2MVdCcx4Sc0UpP2eBWo9rotpq6g==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/minimist-options": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/minimist-options/-/minimist-options-4.1.0.tgz", + "integrity": "sha512-Q4r8ghd80yhO/0j1O3B2BjweX3fiHg9cdOwjJd2J76Q135c+NDxGCqdYKQ1SKBuFfgWbAUzBfvYjPUEeNgqN1A==", + "dev": true, + "dependencies": { + "arrify": "^1.0.1", + "is-plain-obj": "^1.1.0", + "kind-of": "^6.0.3" + }, + "engines": { + "node": ">= 6" + } }, "node_modules/minipass": { - "version": "3.1.6", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.1.6.tgz", - "integrity": "sha512-rty5kpw9/z8SX9dmxblFA6edItUmwJgMeYDZRrwlIVN27i8gysGbznJwUggw2V/FVqFSDdWy040ZPS811DYAqQ==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-4.0.0.tgz", + "integrity": "sha512-g2Uuh2jEKoht+zvO6vJqXmYpflPqzRBT+Th2h01DKh5z7wbY/AZ2gCQ78cP70YoHPyFdY30YBV5WxgLOEwOykw==", "inBundle": true, "dependencies": { "yallist": "^4.0.0" @@ -5216,9 +8160,8 @@ }, "node_modules/minipass-collect": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/minipass-collect/-/minipass-collect-1.0.2.tgz", - "integrity": "sha512-6T6lH0H8OG9kITm/Jm6tdooIbogG9e0tLgpY6mphXSm/A9u8Nq1ryBG+Qspiub9LjWlBPsPS3tWQ/Botq4FdxA==", "inBundle": true, + "license": "ISC", "dependencies": { "minipass": "^3.0.0" }, @@ -5226,28 +8169,50 @@ "node": ">= 8" } }, - "node_modules/minipass-fetch": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/minipass-fetch/-/minipass-fetch-1.4.1.tgz", - "integrity": "sha512-CGH1eblLq26Y15+Azk7ey4xh0J/XfJfrCox5LDJiKqI2Q2iwOLOKrlmIaODiSQS8d18jalF6y2K2ePUm0CmShw==", + "node_modules/minipass-collect/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", "inBundle": true, "dependencies": { - "minipass": "^3.1.0", - "minipass-sized": "^1.0.3", - "minizlib": "^2.0.0" + "yallist": "^4.0.0" }, "engines": { "node": ">=8" + } + }, + "node_modules/minipass-fetch": { + "version": "3.0.0", + "inBundle": true, + "license": "MIT", + "dependencies": { + "minipass": "^3.1.6", + "minipass-sized": "^1.0.3", + "minizlib": "^2.1.2" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "optionalDependencies": { - "encoding": "^0.1.12" + "encoding": "^0.1.13" + } + }, + "node_modules/minipass-fetch/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", + "inBundle": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" } }, "node_modules/minipass-flush": { "version": "1.0.5", - "resolved": "https://registry.npmjs.org/minipass-flush/-/minipass-flush-1.0.5.tgz", - "integrity": "sha512-JmQSYYpPUqX5Jyn1mXaRwOda1uQ8HP5KAT/oDSLCzt1BYRhQU0/hDtsB1ufZfEEzMZ9aAVmsBw8+FWsIXlClWw==", "inBundle": true, + "license": "ISC", "dependencies": { "minipass": "^3.0.0" }, @@ -5255,21 +8220,43 @@ "node": ">= 8" } }, + "node_modules/minipass-flush/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", + "inBundle": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/minipass-json-stream": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/minipass-json-stream/-/minipass-json-stream-1.0.1.tgz", - "integrity": "sha512-ODqY18UZt/I8k+b7rl2AENgbWE8IDYam+undIJONvigAz8KR5GWblsFTEfQs0WODsjbSXWlm+JHEv8Gr6Tfdbg==", "inBundle": true, + "license": "MIT", "dependencies": { "jsonparse": "^1.3.1", "minipass": "^3.0.0" } }, - "node_modules/minipass-pipeline": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/minipass-pipeline/-/minipass-pipeline-1.2.4.tgz", - "integrity": "sha512-xuIq7cIOt09RPRJ19gdi4b+RiNvDFYe5JH+ggNvBqGqpQXcru3PcRmOZuHBKWK1Txf9+cQ+HMVN4d6z46LZP7A==", + "node_modules/minipass-json-stream/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", "inBundle": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/minipass-pipeline": { + "version": "1.2.4", + "inBundle": true, + "license": "ISC", "dependencies": { "minipass": "^3.0.0" }, @@ -5277,11 +8264,22 @@ "node": ">=8" } }, + "node_modules/minipass-pipeline/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", + "inBundle": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/minipass-sized": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/minipass-sized/-/minipass-sized-1.0.3.tgz", - "integrity": "sha512-MbkQQ2CTiBMlA2Dm/5cY+9SWFEN8pzzOXi6rlM5Xxq0Yqbda5ZQy9sU75a673FE9ZK0Zsbr6Y5iP6u9nktfg2g==", "inBundle": true, + "license": "ISC", "dependencies": { "minipass": "^3.0.0" }, @@ -5289,11 +8287,22 @@ "node": ">=8" } }, + "node_modules/minipass-sized/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", + "inBundle": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/minizlib": { "version": "2.1.2", - "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-2.1.2.tgz", - "integrity": "sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==", "inBundle": true, + "license": "MIT", "dependencies": { "minipass": "^3.0.0", "yallist": "^4.0.0" @@ -5302,11 +8311,22 @@ "node": ">= 8" } }, + "node_modules/minizlib/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", + "inBundle": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/mkdirp": { "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", "inBundle": true, + "license": "MIT", "bin": { "mkdirp": "bin/cmd.js" }, @@ -5314,109 +8334,109 @@ "node": ">=10" } }, - "node_modules/mkdirp-classic": { - "version": "0.5.3", - "resolved": "https://registry.npmjs.org/mkdirp-classic/-/mkdirp-classic-0.5.3.tgz", - "integrity": "sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==", - "dev": true - }, - "node_modules/mkdirp-infer-owner": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mkdirp-infer-owner/-/mkdirp-infer-owner-2.0.0.tgz", - "integrity": "sha512-sdqtiFt3lkOaYvTXSRIUjkIdPTcxgv5+fgqYE/5qgwdw12cOrAuzzgzvVExIkH/ul1oeHN3bCLOWSG3XOqbKKw==", - "inBundle": true, - "dependencies": { - "chownr": "^2.0.0", - "infer-owner": "^1.0.4", - "mkdirp": "^1.0.3" - }, + "node_modules/modify-values": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/modify-values/-/modify-values-1.0.1.tgz", + "integrity": "sha512-xV2bxeN6F7oYjZWTe/YPAy6MN2M+sL4u/Rlm2AHCIVGfo2p1yGmBHQ6vHehl4bRTZBdHu3TSkWdYgkwpYzAGSw==", + "dev": true, "engines": { - "node": ">=10" + "node": ">=0.10.0" + } + }, + "node_modules/months": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/months/-/months-2.1.0.tgz", + "integrity": "sha512-2M9gdDB/uVt304/hJ3k2UIquJhOV5dRjp9BovHmZSINaRp7pdJuHXxOcuSjmJaKNomFyYyu0y3LBigdWiAUEmQ==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/mri": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/mri/-/mri-1.2.0.tgz", + "integrity": "sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==", + "dev": true, + "engines": { + "node": ">=4" } }, "node_modules/ms": { "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", - "inBundle": true + "inBundle": true, + "license": "MIT" }, "node_modules/mute-stream": { "version": "0.0.8", - "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.8.tgz", - "integrity": "sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==", - "inBundle": true - }, - "node_modules/napi-build-utils": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/napi-build-utils/-/napi-build-utils-1.0.2.tgz", - "integrity": "sha512-ONmRUqK7zj7DWX0D9ADe03wbwOBZxNAfF20PlGfCWQcD3+/MakShIHrMqx9YwPTfxDdF1zLeL+RGZiR9kGMLdg==", - "dev": true + "inBundle": true, + "license": "ISC" }, "node_modules/natural-compare": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", - "integrity": "sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=", - "dev": true + "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", + "dev": true, + "peer": true }, "node_modules/negotiator": { "version": "0.6.3", - "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.3.tgz", - "integrity": "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==", "inBundle": true, + "license": "MIT", "engines": { "node": ">= 0.6" } }, + "node_modules/neo-async": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", + "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==", + "dev": true + }, "node_modules/nock": { - "version": "12.0.3", - "resolved": "https://registry.npmjs.org/nock/-/nock-12.0.3.tgz", - "integrity": "sha512-QNb/j8kbFnKCiyqi9C5DD0jH/FubFGj5rt9NQFONXwQm3IPB0CULECg/eS3AU1KgZb/6SwUa4/DTRKhVxkGABw==", + "version": "13.2.9", + "resolved": "https://registry.npmjs.org/nock/-/nock-13.2.9.tgz", + "integrity": "sha512-1+XfJNYF1cjGB+TKMWi29eZ0b82QOvQs2YoLNzbpWGqFMtRQHTa57osqdGj4FrFPgkO4D4AZinzUJR9VvW3QUA==", "dev": true, "dependencies": { "debug": "^4.1.0", "json-stringify-safe": "^5.0.1", - "lodash": "^4.17.13", + "lodash": "^4.17.21", "propagate": "^2.0.0" }, "engines": { "node": ">= 10.13" } }, - "node_modules/node-abi": { - "version": "2.30.0", - "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-2.30.0.tgz", - "integrity": "sha512-g6bZh3YCKQRdwuO/tSZZYJAw622SjsRfJ2X0Iy4sSOHZ34/sPPdVBn8fev2tj7njzLwuqPw9uMtGsGkO5kIQvg==", + "node_modules/node-fetch": { + "version": "2.6.7", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.7.tgz", + "integrity": "sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==", "dev": true, "dependencies": { - "semver": "^5.4.1" + "whatwg-url": "^5.0.0" + }, + "engines": { + "node": "4.x || >=6.0.0" + }, + "peerDependencies": { + "encoding": "^0.1.0" + }, + "peerDependenciesMeta": { + "encoding": { + "optional": true + } } }, - "node_modules/node-abi/node_modules/semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", - "dev": true, - "bin": { - "semver": "bin/semver" - } - }, - "node_modules/node-addon-api": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-3.2.1.tgz", - "integrity": "sha512-mmcei9JghVNDYydghQmeDX8KoAm0FAiYyIcUt/N4nhyAipB17pllZQDOJD2fotxABnt4Mdz+dKTO7eftLg4d0A==", - "dev": true - }, "node_modules/node-gyp": { - "version": "8.4.1", - "resolved": "https://registry.npmjs.org/node-gyp/-/node-gyp-8.4.1.tgz", - "integrity": "sha512-olTJRgUtAb/hOXG0E93wZDs5YiJlgbXxTwQAFHyNlRsXQnYzUaF2aGgujZbw+hR8aF4ZG/rST57bWMWD16jr9w==", + "version": "9.3.0", "inBundle": true, + "license": "MIT", "dependencies": { "env-paths": "^2.2.0", "glob": "^7.1.4", "graceful-fs": "^4.2.6", - "make-fetch-happen": "^9.1.0", - "nopt": "^5.0.0", + "make-fetch-happen": "^10.0.3", + "nopt": "^6.0.0", "npmlog": "^6.0.0", "rimraf": "^3.0.2", "semver": "^7.3.5", @@ -5427,68 +8447,309 @@ "node-gyp": "bin/node-gyp.js" }, "engines": { - "node": ">= 10.12.0" + "node": "^12.22 || ^14.13 || >=16" } }, - "node_modules/node-gyp/node_modules/@tootallnate/once": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-1.1.2.tgz", - "integrity": "sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==", - "inBundle": true, - "engines": { - "node": ">= 6" - } - }, - "node_modules/node-gyp/node_modules/http-proxy-agent": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-4.0.1.tgz", - "integrity": "sha512-k0zdNgqWTGA6aeIRVpvfVob4fL52dTfaehylg0Y4UvSySvOq/Y+BOyPrgpUrA7HylqvU8vIZGsRuXmspskV0Tg==", + "node_modules/node-gyp/node_modules/@npmcli/fs": { + "version": "2.1.2", "inBundle": true, + "license": "ISC", "dependencies": { - "@tootallnate/once": "1", - "agent-base": "6", - "debug": "4" + "@gar/promisify": "^1.1.3", + "semver": "^7.3.5" }, "engines": { - "node": ">= 6" + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/node-gyp/node_modules/@npmcli/move-file": { + "version": "2.0.1", + "inBundle": true, + "license": "MIT", + "dependencies": { + "mkdirp": "^1.0.4", + "rimraf": "^3.0.2" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/node-gyp/node_modules/abbrev": { + "version": "1.1.1", + "inBundle": true, + "license": "ISC" + }, + "node_modules/node-gyp/node_modules/are-we-there-yet": { + "version": "3.0.1", + "inBundle": true, + "license": "ISC", + "dependencies": { + "delegates": "^1.0.0", + "readable-stream": "^3.6.0" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/node-gyp/node_modules/brace-expansion": { + "version": "1.1.11", + "inBundle": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/node-gyp/node_modules/cacache": { + "version": "16.1.3", + "inBundle": true, + "license": "ISC", + "dependencies": { + "@npmcli/fs": "^2.1.0", + "@npmcli/move-file": "^2.0.0", + "chownr": "^2.0.0", + "fs-minipass": "^2.1.0", + "glob": "^8.0.1", + "infer-owner": "^1.0.4", + "lru-cache": "^7.7.1", + "minipass": "^3.1.6", + "minipass-collect": "^1.0.2", + "minipass-flush": "^1.0.5", + "minipass-pipeline": "^1.2.4", + "mkdirp": "^1.0.4", + "p-map": "^4.0.0", + "promise-inflight": "^1.0.1", + "rimraf": "^3.0.2", + "ssri": "^9.0.0", + "tar": "^6.1.11", + "unique-filename": "^2.0.0" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/node-gyp/node_modules/cacache/node_modules/brace-expansion": { + "version": "2.0.1", + "inBundle": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0" + } + }, + "node_modules/node-gyp/node_modules/cacache/node_modules/glob": { + "version": "8.0.3", + "inBundle": true, + "license": "ISC", + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^5.0.1", + "once": "^1.3.0" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/node-gyp/node_modules/cacache/node_modules/minimatch": { + "version": "5.1.0", + "inBundle": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^2.0.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/node-gyp/node_modules/gauge": { + "version": "4.0.4", + "inBundle": true, + "license": "ISC", + "dependencies": { + "aproba": "^1.0.3 || ^2.0.0", + "color-support": "^1.1.3", + "console-control-strings": "^1.1.0", + "has-unicode": "^2.0.1", + "signal-exit": "^3.0.7", + "string-width": "^4.2.3", + "strip-ansi": "^6.0.1", + "wide-align": "^1.1.5" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/node-gyp/node_modules/glob": { + "version": "7.2.3", + "inBundle": true, + "license": "ISC", + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, "node_modules/node-gyp/node_modules/make-fetch-happen": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/make-fetch-happen/-/make-fetch-happen-9.1.0.tgz", - "integrity": "sha512-+zopwDy7DNknmwPQplem5lAZX/eCOzSvSNNcSKm5eVwTkOBzoktEfXsa9L23J/GIRhxRsaxzkPEhrJEpE2F4Gg==", + "version": "10.2.1", "inBundle": true, + "license": "ISC", "dependencies": { - "agentkeepalive": "^4.1.3", - "cacache": "^15.2.0", + "agentkeepalive": "^4.2.1", + "cacache": "^16.1.0", "http-cache-semantics": "^4.1.0", - "http-proxy-agent": "^4.0.1", + "http-proxy-agent": "^5.0.0", "https-proxy-agent": "^5.0.0", "is-lambda": "^1.0.1", - "lru-cache": "^6.0.0", - "minipass": "^3.1.3", + "lru-cache": "^7.7.1", + "minipass": "^3.1.6", "minipass-collect": "^1.0.2", - "minipass-fetch": "^1.3.2", + "minipass-fetch": "^2.0.3", "minipass-flush": "^1.0.5", "minipass-pipeline": "^1.2.4", - "negotiator": "^0.6.2", + "negotiator": "^0.6.3", "promise-retry": "^2.0.1", - "socks-proxy-agent": "^6.0.0", - "ssri": "^8.0.0" + "socks-proxy-agent": "^7.0.0", + "ssri": "^9.0.0" }, "engines": { - "node": ">= 10" + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" } }, - "node_modules/node-modules-regexp": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz", - "integrity": "sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA=", - "dev": true, - "optional": true, - "peer": true, + "node_modules/node-gyp/node_modules/minimatch": { + "version": "3.1.2", + "inBundle": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" + }, "engines": { - "node": ">=0.10.0" + "node": "*" + } + }, + "node_modules/node-gyp/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", + "inBundle": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/node-gyp/node_modules/minipass-fetch": { + "version": "2.1.2", + "inBundle": true, + "license": "MIT", + "dependencies": { + "minipass": "^3.1.6", + "minipass-sized": "^1.0.3", + "minizlib": "^2.1.2" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + }, + "optionalDependencies": { + "encoding": "^0.1.13" + } + }, + "node_modules/node-gyp/node_modules/nopt": { + "version": "6.0.0", + "inBundle": true, + "license": "ISC", + "dependencies": { + "abbrev": "^1.0.0" + }, + "bin": { + "nopt": "bin/nopt.js" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/node-gyp/node_modules/npmlog": { + "version": "6.0.2", + "inBundle": true, + "license": "ISC", + "dependencies": { + "are-we-there-yet": "^3.0.0", + "console-control-strings": "^1.1.0", + "gauge": "^4.0.3", + "set-blocking": "^2.0.0" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/node-gyp/node_modules/ssri": { + "version": "9.0.1", + "inBundle": true, + "license": "ISC", + "dependencies": { + "minipass": "^3.1.1" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/node-gyp/node_modules/unique-filename": { + "version": "2.0.1", + "inBundle": true, + "license": "ISC", + "dependencies": { + "unique-slug": "^3.0.0" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/node-gyp/node_modules/unique-slug": { + "version": "3.0.0", + "inBundle": true, + "license": "ISC", + "dependencies": { + "imurmurhash": "^0.1.4" + }, + "engines": { + "node": "^12.13.0 || ^14.15.0 || >=16.0.0" + } + }, + "node_modules/node-gyp/node_modules/which": { + "version": "2.0.2", + "inBundle": true, + "license": "ISC", + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/node-html-parser": { + "version": "5.4.2", + "resolved": "https://registry.npmjs.org/node-html-parser/-/node-html-parser-5.4.2.tgz", + "integrity": "sha512-RaBPP3+51hPne/OolXxcz89iYvQvKOydaqoePpOgXcrOKZhjVIzmpKZz+Hd/RBO2/zN2q6CNJhQzucVz+u3Jyw==", + "dev": true, + "dependencies": { + "css-select": "^4.2.1", + "he": "1.2.0" } }, "node_modules/node-preload": { @@ -5503,40 +8764,38 @@ "node": ">=8" } }, - "node_modules/noop-logger": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/noop-logger/-/noop-logger-0.1.1.tgz", - "integrity": "sha1-lKKxYzxPExdVMAfYlm/Q6EG2pMI=", + "node_modules/node-releases": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.6.tgz", + "integrity": "sha512-PiVXnNuFm5+iYkLBNeq5211hvO38y63T0i2KKh2KnUs3RpzJ+JtODFjkD8yjLwnDkTYF1eKXheUwdssR+NRZdg==", "dev": true }, "node_modules/nopt": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/nopt/-/nopt-5.0.0.tgz", - "integrity": "sha512-Tbj67rffqceeLpcRXrT7vKAN8CwfPeIBgM7E6iBkmKLV7bEMwpGgYLGv0jACUsECaa/vuxP0IjEont6umdMgtQ==", + "version": "7.0.0", "inBundle": true, + "license": "ISC", "dependencies": { - "abbrev": "1" + "abbrev": "^2.0.0" }, "bin": { "nopt": "bin/nopt.js" }, "engines": { - "node": ">=6" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/normalize-package-data": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-3.0.3.tgz", - "integrity": "sha512-p2W1sgqij3zMMyRC067Dg16bfzVH+w7hyegmpIvZ4JNjqtGOVAIvLmjBx3yP7YTe9vKJgkoNOPjwQGogDoMXFA==", + "version": "5.0.0", "inBundle": true, + "license": "BSD-2-Clause", "dependencies": { - "hosted-git-info": "^4.0.1", - "is-core-module": "^2.5.0", - "semver": "^7.3.4", - "validate-npm-package-license": "^3.0.1" + "hosted-git-info": "^6.0.0", + "is-core-module": "^2.8.1", + "semver": "^7.3.5", + "validate-npm-package-license": "^3.0.4" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/normalize-path": { @@ -5549,166 +8808,179 @@ } }, "node_modules/npm-audit-report": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/npm-audit-report/-/npm-audit-report-2.1.5.tgz", - "integrity": "sha512-YB8qOoEmBhUH1UJgh1xFAv7Jg1d+xoNhsDYiFQlEFThEBui0W1vIz2ZK6FVg4WZjwEdl7uBQlm1jy3MUfyHeEw==", + "version": "4.0.0", "inBundle": true, + "license": "ISC", "dependencies": { "chalk": "^4.0.0" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm-bundled": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/npm-bundled/-/npm-bundled-1.1.2.tgz", - "integrity": "sha512-x5DHup0SuyQcmL3s7Rx/YQ8sbw/Hzg0rj48eN0dV7hf5cmQq5PXIeioroH3raV1QC1yh3uTYuMThvEQF3iKgGQ==", + "version": "3.0.0", "inBundle": true, + "license": "ISC", "dependencies": { - "npm-normalize-package-bin": "^1.0.1" + "npm-normalize-package-bin": "^3.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm-install-checks": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/npm-install-checks/-/npm-install-checks-4.0.0.tgz", - "integrity": "sha512-09OmyDkNLYwqKPOnbI8exiOZU2GVVmQp7tgez2BPi5OZC8M82elDAps7sxC4l//uSUtotWqoEIDwjRvWH4qz8w==", + "version": "6.0.0", "inBundle": true, + "license": "BSD-2-Clause", "dependencies": { "semver": "^7.1.1" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm-license-corrections": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/npm-license-corrections/-/npm-license-corrections-1.4.0.tgz", - "integrity": "sha512-elrOuaygiK9SDD1Rzl6gxbRSJgcClcNER5RvdilSwlHWurD2GTlTt8RHZDMKkwgfkDHTg2F7n10IrPqCzdCCcw==", + "version": "1.6.2", + "resolved": "https://registry.npmjs.org/npm-license-corrections/-/npm-license-corrections-1.6.2.tgz", + "integrity": "sha512-U66tDCdutNSdzbbPu3IWpgUwcrekT3XW+5fPdRleQmW2kiDqCnurRJnI2kQswRYng1dg/GpgxXE8mT6r6s40rg==", "dev": true }, "node_modules/npm-normalize-package-bin": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/npm-normalize-package-bin/-/npm-normalize-package-bin-1.0.1.tgz", - "integrity": "sha512-EPfafl6JL5/rU+ot6P3gRSCpPDW5VmIzX959Ob1+ySFUuuYHWHekXpwdUZcKP5C+DS4GEtdJluwBjnsNDl+fSA==", - "inBundle": true + "version": "3.0.0", + "inBundle": true, + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } }, "node_modules/npm-package-arg": { - "version": "8.1.5", - "resolved": "https://registry.npmjs.org/npm-package-arg/-/npm-package-arg-8.1.5.tgz", - "integrity": "sha512-LhgZrg0n0VgvzVdSm1oiZworPbTxYHUJCgtsJW8mGvlDpxTM1vSJc3m5QZeUkhAHIzbz3VCHd/R4osi1L1Tg/Q==", + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/npm-package-arg/-/npm-package-arg-10.1.0.tgz", + "integrity": "sha512-uFyyCEmgBfZTtrKk/5xDfHp6+MdrqGotX/VoOyEEl3mBwiEE5FlBaePanazJSVMPT7vKepcjYBY2ztg9A3yPIA==", "inBundle": true, "dependencies": { - "hosted-git-info": "^4.0.1", - "semver": "^7.3.4", - "validate-npm-package-name": "^3.0.0" + "hosted-git-info": "^6.0.0", + "proc-log": "^3.0.0", + "semver": "^7.3.5", + "validate-npm-package-name": "^5.0.0" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm-packlist": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-3.0.0.tgz", - "integrity": "sha512-L/cbzmutAwII5glUcf2DBRNY/d0TFd4e/FnaZigJV6JD85RHZXJFGwCndjMWiiViiWSsWt3tiOLpI3ByTnIdFQ==", + "version": "7.0.4", + "resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-7.0.4.tgz", + "integrity": "sha512-d6RGEuRrNS5/N84iglPivjaJPxhDbZmlbTwTDX2IbcRHG5bZCdtysYMhwiPvcF4GisXHGn7xsxv+GQ7T/02M5Q==", "inBundle": true, "dependencies": { - "glob": "^7.1.6", - "ignore-walk": "^4.0.1", - "npm-bundled": "^1.1.1", - "npm-normalize-package-bin": "^1.0.1" - }, - "bin": { - "npm-packlist": "bin/index.js" + "ignore-walk": "^6.0.0" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm-pick-manifest": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/npm-pick-manifest/-/npm-pick-manifest-6.1.1.tgz", - "integrity": "sha512-dBsdBtORT84S8V8UTad1WlUyKIY9iMsAmqxHbLdeEeBNMLQDlDWWra3wYUx9EBEIiG/YwAy0XyNHDd2goAsfuA==", + "version": "8.0.1", "inBundle": true, + "license": "ISC", "dependencies": { - "npm-install-checks": "^4.0.0", - "npm-normalize-package-bin": "^1.0.1", - "npm-package-arg": "^8.1.2", - "semver": "^7.3.4" + "npm-install-checks": "^6.0.0", + "npm-normalize-package-bin": "^3.0.0", + "npm-package-arg": "^10.0.0", + "semver": "^7.3.5" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm-profile": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/npm-profile/-/npm-profile-6.0.0.tgz", - "integrity": "sha512-ZiwXx3Fq3wNqJMz+d4AVZ9X4xAw/0TqsvdiyDF5Y+h9lQ7AjYDOxY06lj7AP5vUBqB/7k/0oNFQOx03Ay0iHPw==", + "version": "7.0.1", "inBundle": true, + "license": "ISC", "dependencies": { - "npm-registry-fetch": "^12.0.0" + "npm-registry-fetch": "^14.0.0", + "proc-log": "^3.0.0" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/npm-registry-fetch": { - "version": "12.0.2", - "resolved": "https://registry.npmjs.org/npm-registry-fetch/-/npm-registry-fetch-12.0.2.tgz", - "integrity": "sha512-Df5QT3RaJnXYuOwtXBXS9BWs+tHH2olvkCLh6jcR/b/u3DvPMlp3J0TvvYwplPKxHMOwfg287PYih9QqaVFoKA==", + "version": "14.0.3", + "resolved": "https://registry.npmjs.org/npm-registry-fetch/-/npm-registry-fetch-14.0.3.tgz", + "integrity": "sha512-YaeRbVNpnWvsGOjX2wk5s85XJ7l1qQBGAp724h8e2CZFFhMSuw9enom7K1mWVUtvXO1uUSFIAPofQK0pPN0ZcA==", "inBundle": true, "dependencies": { - "make-fetch-happen": "^10.0.1", - "minipass": "^3.1.6", - "minipass-fetch": "^1.4.1", + "make-fetch-happen": "^11.0.0", + "minipass": "^4.0.0", + "minipass-fetch": "^3.0.0", "minipass-json-stream": "^1.0.1", "minizlib": "^2.1.2", - "npm-package-arg": "^8.1.5" + "npm-package-arg": "^10.0.0", + "proc-log": "^3.0.0" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/npm-run-path": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", + "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", + "dev": true, + "dependencies": { + "path-key": "^3.0.0" + }, + "engines": { + "node": ">=8" } }, "node_modules/npm-user-validate": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/npm-user-validate/-/npm-user-validate-1.0.1.tgz", - "integrity": "sha512-uQwcd/tY+h1jnEaze6cdX/LrhWhoBxfSknxentoqmIuStxUExxjWd3ULMLFPiFUrZKbOVMowH6Jq2FRWfmhcEw==", - "inBundle": true + "inBundle": true, + "license": "BSD-2-Clause" }, "node_modules/npmlog": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-6.0.1.tgz", - "integrity": "sha512-BTHDvY6nrRHuRfyjt1MAufLxYdVXZfd099H4+i1f0lPywNQyI4foeNXJRObB/uy+TYqUW0vAD9gbdSOXPst7Eg==", + "version": "7.0.1", "inBundle": true, + "license": "ISC", "dependencies": { - "are-we-there-yet": "^3.0.0", + "are-we-there-yet": "^4.0.0", "console-control-strings": "^1.1.0", - "gauge": "^4.0.0", + "gauge": "^5.0.0", "set-blocking": "^2.0.0" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/null-check": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/null-check/-/null-check-1.0.0.tgz", - "integrity": "sha1-l33/1xdgErnsMNKjnbXPcqBDnt0=", + "node_modules/nth-check": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.1.1.tgz", + "integrity": "sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==", "dev": true, - "engines": { - "node": ">=0.10.0" + "dependencies": { + "boolbase": "^1.0.0" + }, + "funding": { + "url": "https://github.com/fb55/nth-check?sponsor=1" } }, "node_modules/number-is-nan": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", - "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", + "integrity": "sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/nwsapi": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.0.tgz", - "integrity": "sha512-h2AatdwYH+JHiZpv7pt/gSX1XoRGb7L/qSIeuqA6GwYoF9w1vP1cw42TO0aI2pNyshRK5893hNSl+1//vHK7hQ==", + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.2.tgz", + "integrity": "sha512-90yv+6538zuvUMnN+zCr8LuV6bPFdq50304114vJYJ8RDyK8D5O9Phpbd6SZWgI7PwzmmfN1upeOJlvybDSgCw==", "dev": true }, "node_modules/nyc": { @@ -5752,6 +9024,27 @@ "node": ">=8.9" } }, + "node_modules/nyc/node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/nyc/node_modules/cliui": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-6.0.0.tgz", + "integrity": "sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ==", + "dev": true, + "dependencies": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.0", + "wrap-ansi": "^6.2.0" + } + }, "node_modules/nyc/node_modules/find-up": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", @@ -5765,6 +9058,26 @@ "node": ">=8" } }, + "node_modules/nyc/node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "dev": true, + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, "node_modules/nyc/node_modules/locate-path": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", @@ -5777,6 +9090,18 @@ "node": ">=8" } }, + "node_modules/nyc/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, "node_modules/nyc/node_modules/p-limit": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", @@ -5816,72 +9141,76 @@ "node": ">=8" } }, - "node_modules/nyc/node_modules/p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "node_modules/nyc/node_modules/wrap-ansi": { + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", + "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", "dev": true, + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/nyc/node_modules/y18n": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.3.tgz", + "integrity": "sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ==", + "dev": true + }, + "node_modules/nyc/node_modules/yargs": { + "version": "15.4.1", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-15.4.1.tgz", + "integrity": "sha512-aePbxDmcYW++PaqBsJ+HYUFwCdv4LVvdnhBy78E57PIor8/OVvhMrADFFEDh8DHDFRv/O9i3lPhsENjO7QX0+A==", + "dev": true, + "dependencies": { + "cliui": "^6.0.0", + "decamelize": "^1.2.0", + "find-up": "^4.1.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^4.2.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^18.1.2" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/nyc/node_modules/yargs-parser": { + "version": "18.1.3", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-18.1.3.tgz", + "integrity": "sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==", + "dev": true, + "dependencies": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + }, "engines": { "node": ">=6" } }, - "node_modules/nyc/node_modules/path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/nyc/node_modules/resolve-from": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", - "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/oauth-sign": { - "version": "0.9.0", - "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz", - "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==", - "dev": true, - "engines": { - "node": "*" - } - }, "node_modules/object-assign": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", - "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", "dev": true, "engines": { "node": ">=0.10.0" } }, "node_modules/object-inspect": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.11.1.tgz", - "integrity": "sha512-If7BjFlpkzzBeV1cqgT3OSWT3azyoxDGajR+iGnFBfVV2EWyDyWaZZW2ERDjUaY2QM8i5jI3Sj7mhsM4DDAqWA==", + "version": "1.12.2", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.2.tgz", + "integrity": "sha512-z+cPxW0QGUp0mcqcsgQyLVRDoXFQbXOwBaqyF7VIgI4TWNQsDHrBpUQslRmIfAoYWdYzs6UlKJtB2XJpTaNSpQ==", "dev": true, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/object-is": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.1.5.tgz", - "integrity": "sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.1.3" - }, - "engines": { - "node": ">= 0.4" - }, + "peer": true, "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -5891,19 +9220,21 @@ "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", "dev": true, + "peer": true, "engines": { "node": ">= 0.4" } }, "node_modules/object.assign": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.2.tgz", - "integrity": "sha512-ixT2L5THXsApyiUPYKmW+2EHpXXe5Ii3M+f4e+aJFAHao5amFRW6J0OO6c/LU8Be47utCx2GL89hxGB6XSmKuQ==", + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", + "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", "dev": true, + "peer": true, "dependencies": { - "call-bind": "^1.0.0", - "define-properties": "^1.1.3", - "has-symbols": "^1.0.1", + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "has-symbols": "^1.0.3", "object-keys": "^1.1.1" }, "engines": { @@ -5913,18 +9244,19 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/object.getownpropertydescriptors": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.2.tgz", - "integrity": "sha512-WtxeKSzfBjlzL+F9b7M7hewDzMwy+C8NRssHd1YrNlzHzIDrXcXiNOMrezdAEM4UXixgV+vvnyBeN7Rygl2ttQ==", + "node_modules/object.values": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/object.values/-/object.values-1.1.6.tgz", + "integrity": "sha512-FVVTkD1vENCsAcwNs9k6jea2uHC/X0+JcjG8YA60FN5CMaJmG95wT9jek/xX9nornqGRrBkKtzuAu2wuHpKqvw==", "dev": true, + "peer": true, "dependencies": { "call-bind": "^1.0.2", - "define-properties": "^1.1.3", - "es-abstract": "^1.18.0-next.2" + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4" }, "engines": { - "node": ">= 0.8" + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" @@ -5932,18 +9264,32 @@ }, "node_modules/once": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", "inBundle": true, + "license": "ISC", "dependencies": { "wrappy": "1" } }, + "node_modules/onetime": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", + "dev": true, + "dependencies": { + "mimic-fn": "^2.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/opener": { "version": "1.5.2", "resolved": "https://registry.npmjs.org/opener/-/opener-1.5.2.tgz", "integrity": "sha512-ur5UIdyw5Y7yEj9wLzhqXiy6GZ3Mwx0yGI+5sMn2r0N0v3cKJvUmFH5yPP+WXh9e0xfyzyJX95D8l088DNFj7A==", - "inBundle": true, + "dev": true, "bin": { "opener": "bin/opener-bin.js" } @@ -5953,6 +9299,7 @@ "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.1.tgz", "integrity": "sha512-74RlY5FCnhq4jRxVUPKDaRwrVNXMqsGsiW6AJw4XK8hmtm10wC0ypZBLw5IIp85NZMr91+qd1RvvENwg7jjRFw==", "dev": true, + "peer": true, "dependencies": { "deep-is": "^0.1.3", "fast-levenshtein": "^2.0.6", @@ -5968,7 +9315,7 @@ "node_modules/own-or": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/own-or/-/own-or-1.0.0.tgz", - "integrity": "sha1-Tod/vtqaLsgAD7wLyuOWRe6L+Nw=", + "integrity": "sha512-NfZr5+Tdf6MB8UI9GLvKRs4cXY8/yB0w3xtt84xFdWy8hkGjn+JFc60VhzS/hFRfbyxFcGYMTjnF4Me+RbbqrA==", "dev": true }, "node_modules/own-or-env": { @@ -5980,11 +9327,49 @@ "own-or": "^1.0.0" } }, + "node_modules/p-finally": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", + "integrity": "sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/p-limit": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", + "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", + "dev": true, + "dependencies": { + "yocto-queue": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-locate": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", + "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", + "dev": true, + "dependencies": { + "p-limit": "^3.0.2" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/p-map": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-4.0.0.tgz", - "integrity": "sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==", "inBundle": true, + "license": "MIT", "dependencies": { "aggregate-error": "^3.0.0" }, @@ -5995,6 +9380,43 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/p-queue": { + "version": "6.6.2", + "resolved": "https://registry.npmjs.org/p-queue/-/p-queue-6.6.2.tgz", + "integrity": "sha512-RwFpb72c/BhQLEXIZ5K2e+AhgNVmIejGlTgiB9MzZ0e93GRvqZ7uSi0dvRF7/XIXDeNkra2fNHBxTyPDGySpjQ==", + "dev": true, + "dependencies": { + "eventemitter3": "^4.0.4", + "p-timeout": "^3.2.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-timeout": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/p-timeout/-/p-timeout-3.2.0.tgz", + "integrity": "sha512-rhIwUycgwwKcP9yTOOFK/AKsAopjjCakVqLHePO3CC6Mir1Z99xT+R63jZxAT5lFZLa2inS5h+ZS2GvR99/FBg==", + "dev": true, + "dependencies": { + "p-finally": "^1.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, "node_modules/package-hash": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/package-hash/-/package-hash-4.0.0.tgz", @@ -6011,36 +9433,34 @@ } }, "node_modules/pacote": { - "version": "12.0.3", - "resolved": "https://registry.npmjs.org/pacote/-/pacote-12.0.3.tgz", - "integrity": "sha512-CdYEl03JDrRO3x18uHjBYA9TyoW8gy+ThVcypcDkxPtKlw76e4ejhYB6i9lJ+/cebbjpqPW/CijjqxwDTts8Ow==", + "version": "15.0.7", + "resolved": "https://registry.npmjs.org/pacote/-/pacote-15.0.7.tgz", + "integrity": "sha512-OFf4dl3SM1PpsZvi1zk4vvMA0EplnyO0Ajbrtoyx6E3dXOWBoPnMapnLgQdInEfqPkNT8mrd2bY6c5t8JZ69sQ==", "inBundle": true, "dependencies": { - "@npmcli/git": "^2.1.0", - "@npmcli/installed-package-contents": "^1.0.6", - "@npmcli/promise-spawn": "^1.2.0", - "@npmcli/run-script": "^2.0.0", - "cacache": "^15.0.5", - "chownr": "^2.0.0", + "@npmcli/git": "^4.0.0", + "@npmcli/installed-package-contents": "^2.0.1", + "@npmcli/promise-spawn": "^6.0.1", + "@npmcli/run-script": "^6.0.0", + "cacache": "^17.0.0", "fs-minipass": "^2.1.0", - "infer-owner": "^1.0.4", - "minipass": "^3.1.3", - "mkdirp": "^1.0.3", - "npm-package-arg": "^8.0.1", - "npm-packlist": "^3.0.0", - "npm-pick-manifest": "^6.0.0", - "npm-registry-fetch": "^12.0.0", + "minipass": "^4.0.0", + "npm-package-arg": "^10.0.0", + "npm-packlist": "^7.0.0", + "npm-pick-manifest": "^8.0.0", + "npm-registry-fetch": "^14.0.0", + "proc-log": "^3.0.0", "promise-retry": "^2.0.1", - "read-package-json-fast": "^2.0.1", - "rimraf": "^3.0.2", - "ssri": "^8.0.1", - "tar": "^6.1.0" + "read-package-json": "^6.0.0", + "read-package-json-fast": "^3.0.0", + "ssri": "^10.0.0", + "tar": "^6.1.11" }, "bin": { "pacote": "lib/bin.js" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/parent-module": { @@ -6056,48 +9476,91 @@ } }, "node_modules/parse-conflict-json": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/parse-conflict-json/-/parse-conflict-json-2.0.1.tgz", - "integrity": "sha512-Y7nYw+QaSGBto1LB9lgwOR05Rtz5SbuTf+Oe7HJ6SYQ/DHsvRjQ8O03oWdJbvkt6GzDWospgyZbGmjDYL0sDgA==", + "version": "3.0.0", "inBundle": true, + "license": "ISC", "dependencies": { - "json-parse-even-better-errors": "^2.3.1", + "json-parse-even-better-errors": "^3.0.0", "just-diff": "^5.0.1", - "just-diff-apply": "^4.0.1" + "just-diff-apply": "^5.2.0" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/parse-entities": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/parse-entities/-/parse-entities-2.0.0.tgz", - "integrity": "sha512-kkywGpCcRYhqQIchaWqZ875wzpS/bMKhz5HnN3p7wveJTkTtyAB/AlnS0f8DFSqYW1T82t6yEAkEcB+A1I3MbQ==", + "node_modules/parse-diff": { + "version": "0.9.0", + "resolved": "https://registry.npmjs.org/parse-diff/-/parse-diff-0.9.0.tgz", + "integrity": "sha512-Jn+VZORAezkfOXR6B40EZcXxdJBamtgBpfeoFH6hxD+p0e74nVaCL9SWlQj1ggc8b6AexgPKlDiiE0CMMZDSbQ==", + "dev": true + }, + "node_modules/parse-github-repo-url": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/parse-github-repo-url/-/parse-github-repo-url-1.4.1.tgz", + "integrity": "sha512-bSWyzBKqcSL4RrncTpGsEKoJ7H8a4L3++ifTAbTFeMHyq2wRV+42DGmQcHIrJIvdcacjIOxEuKH/w4tthF17gg==", + "dev": true + }, + "node_modules/parse-json": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", + "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", "dev": true, "dependencies": { - "character-entities": "^1.0.0", - "character-entities-legacy": "^1.0.0", - "character-reference-invalid": "^1.0.0", - "is-alphanumerical": "^1.0.0", - "is-decimal": "^1.0.0", - "is-hexadecimal": "^1.0.0" + "@babel/code-frame": "^7.0.0", + "error-ex": "^1.3.1", + "json-parse-even-better-errors": "^2.3.0", + "lines-and-columns": "^1.1.6" + }, + "engines": { + "node": ">=8" }, "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/parse5": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/parse5/-/parse5-6.0.1.tgz", - "integrity": "sha512-Ofn/CTFzRGTTxwpNEs9PP93gXShHcTq255nzRYSKe8AkVpZY7e1fpmTfOyoIvjP5HG7Z2ZM7VS9PPhQGW2pOpw==", + "node_modules/parse-json/node_modules/json-parse-even-better-errors": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", + "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", "dev": true }, + "node_modules/parse5": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.1.1.tgz", + "integrity": "sha512-kwpuwzB+px5WUg9pyK0IcK/shltJN5/OVhQagxhCQNtT9Y9QRZqNY2e1cmbu/paRh5LMnz/oVTVLBpjFmMZhSg==", + "dev": true, + "dependencies": { + "entities": "^4.4.0" + }, + "funding": { + "url": "https://github.com/inikulin/parse5?sponsor=1" + } + }, + "node_modules/parse5/node_modules/entities": { + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-4.4.0.tgz", + "integrity": "sha512-oYp7156SP8LkeGD0GF85ad1X9Ai79WtRsZ2gxJqtBuzH+98YUV6jkHEKlZkMbcrjJjIVJNIDP/3WL9wQkoPbWA==", + "dev": true, + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true, + "engines": { + "node": ">=8" + } + }, "node_modules/path-is-absolute": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", "inBundle": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } @@ -6117,25 +9580,25 @@ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", "dev": true }, - "node_modules/pathval": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz", - "integrity": "sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ==", + "node_modules/path-type": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", + "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==", "dev": true, "engines": { - "node": "*" + "node": ">=8" } }, - "node_modules/performance-now": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", - "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=", + "node_modules/picocolors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", + "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", "dev": true }, "node_modules/picomatch": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.0.tgz", - "integrity": "sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw==", + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", "dev": true, "engines": { "node": ">=8.6" @@ -6144,18 +9607,77 @@ "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/pirates": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/pirates/-/pirates-3.0.2.tgz", - "integrity": "sha512-c5CgUJq6H2k6MJz72Ak1F5sN9n9wlSlJyEnwvpm9/y3WB4E3pHBDT2c6PEiS1vyJvq2bUxUAIu0EGf8Cx4Ic7Q==", + "node_modules/pify": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz", + "integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/pkg-dir": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz", + "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==", "dev": true, - "optional": true, - "peer": true, "dependencies": { - "node-modules-regexp": "^1.0.0" + "find-up": "^4.0.0" }, "engines": { - "node": ">= 4" + "node": ">=8" + } + }, + "node_modules/pkg-dir/node_modules/find-up": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", + "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "dev": true, + "dependencies": { + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/pkg-dir/node_modules/locate-path": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", + "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "dev": true, + "dependencies": { + "p-locate": "^4.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/pkg-dir/node_modules/p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "dependencies": { + "p-try": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/pkg-dir/node_modules/p-locate": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", + "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "dev": true, + "dependencies": { + "p-limit": "^2.2.0" + }, + "engines": { + "node": ">=8" } }, "node_modules/platform": { @@ -6164,132 +9686,15 @@ "integrity": "sha512-fnWVljUchTro6RiCFvCXBbNhJc2NijN7oIQxbwsyL0buWJPG85v81ehlHI9fXrJsMNgTofEoWIQeClKpgxFLrg==", "dev": true }, - "node_modules/prebuild-install": { - "version": "6.1.2", - "resolved": "https://registry.npmjs.org/prebuild-install/-/prebuild-install-6.1.2.tgz", - "integrity": "sha512-PzYWIKZeP+967WuKYXlTOhYBgGOvTRSfaKI89XnfJ0ansRAH7hDU45X+K+FZeI1Wb/7p/NnuctPH3g0IqKUuSQ==", - "dev": true, + "node_modules/postcss-selector-parser": { + "version": "6.0.10", + "license": "MIT", "dependencies": { - "detect-libc": "^1.0.3", - "expand-template": "^2.0.3", - "github-from-package": "0.0.0", - "minimist": "^1.2.3", - "mkdirp-classic": "^0.5.3", - "napi-build-utils": "^1.0.1", - "node-abi": "^2.21.0", - "noop-logger": "^0.1.1", - "npmlog": "^4.0.1", - "pump": "^3.0.0", - "rc": "^1.2.7", - "simple-get": "^3.0.3", - "tar-fs": "^2.0.0", - "tunnel-agent": "^0.6.0" - }, - "bin": { - "prebuild-install": "bin.js" + "cssesc": "^3.0.0", + "util-deprecate": "^1.0.2" }, "engines": { - "node": ">=6" - } - }, - "node_modules/prebuild-install/node_modules/aproba": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", - "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==", - "dev": true - }, - "node_modules/prebuild-install/node_modules/are-we-there-yet": { - "version": "1.1.7", - "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.7.tgz", - "integrity": "sha512-nxwy40TuMiUGqMyRHgCSWZ9FM4VAoRP4xUYSTv5ImRog+h9yISPbVH7H8fASCIzYn9wlEv4zvFL7uKDMCFQm3g==", - "dev": true, - "dependencies": { - "delegates": "^1.0.0", - "readable-stream": "^2.0.6" - } - }, - "node_modules/prebuild-install/node_modules/gauge": { - "version": "2.7.4", - "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", - "integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=", - "dev": true, - "dependencies": { - "aproba": "^1.0.3", - "console-control-strings": "^1.0.0", - "has-unicode": "^2.0.0", - "object-assign": "^4.1.0", - "signal-exit": "^3.0.0", - "string-width": "^1.0.1", - "strip-ansi": "^3.0.1", - "wide-align": "^1.1.0" - } - }, - "node_modules/prebuild-install/node_modules/is-fullwidth-code-point": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", - "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", - "dev": true, - "dependencies": { - "number-is-nan": "^1.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/prebuild-install/node_modules/npmlog": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz", - "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==", - "dev": true, - "dependencies": { - "are-we-there-yet": "~1.1.2", - "console-control-strings": "~1.1.0", - "gauge": "~2.7.3", - "set-blocking": "~2.0.0" - } - }, - "node_modules/prebuild-install/node_modules/readable-stream": { - "version": "2.3.7", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", - "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", - "dev": true, - "dependencies": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" - } - }, - "node_modules/prebuild-install/node_modules/safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true - }, - "node_modules/prebuild-install/node_modules/string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, - "dependencies": { - "safe-buffer": "~5.1.0" - } - }, - "node_modules/prebuild-install/node_modules/string-width": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", - "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", - "dev": true, - "dependencies": { - "code-point-at": "^1.0.0", - "is-fullwidth-code-point": "^1.0.0", - "strip-ansi": "^3.0.0" - }, - "engines": { - "node": ">=0.10.0" + "node": ">=4" } }, "node_modules/prelude-ls": { @@ -6297,15 +9702,26 @@ "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==", "dev": true, + "peer": true, "engines": { "node": ">= 0.8.0" } }, "node_modules/proc-log": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/proc-log/-/proc-log-1.0.0.tgz", - "integrity": "sha512-aCk8AO51s+4JyuYGg3Q/a6gnrlDO09NpVWePtjp7xwphcoQ04x5WAfCyugcsbLooWcMJ87CLkD4+604IckEdhg==", - "inBundle": true + "version": "3.0.0", + "inBundle": true, + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/process": { + "version": "0.11.10", + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">= 0.6.0" + } }, "node_modules/process-nextick-args": { "version": "2.0.1", @@ -6325,42 +9741,29 @@ "node": ">=8" } }, - "node_modules/progress": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz", - "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==", - "dev": true, - "engines": { - "node": ">=0.4.0" - } - }, "node_modules/promise-all-reject-late": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz", - "integrity": "sha512-vuf0Lf0lOxyQREH7GDIOUMLS7kz+gs8i6B+Yi8dC68a2sychGrHTJYghMBD6k7eUcH0H5P73EckCA48xijWqXw==", + "license": "ISC", "funding": { "url": "https://github.com/sponsors/isaacs" } }, "node_modules/promise-call-limit": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-call-limit/-/promise-call-limit-1.0.1.tgz", - "integrity": "sha512-3+hgaa19jzCGLuSCbieeRsu5C2joKfYn8pY6JAuXFRVfF4IO+L7UPpFWNTeWT9pM7uhskvbPPd/oEOktCn317Q==", + "license": "ISC", "funding": { "url": "https://github.com/sponsors/isaacs" } }, "node_modules/promise-inflight": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-inflight/-/promise-inflight-1.0.1.tgz", - "integrity": "sha1-mEcocL8igTL8vdhoEputEsPAKeM=", - "inBundle": true + "inBundle": true, + "license": "ISC" }, "node_modules/promise-retry": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/promise-retry/-/promise-retry-2.0.1.tgz", - "integrity": "sha512-y+WKFlBR8BGXnsNlIHFGPZmyDf3DFMoLhaflAnyZgV6rG6xu+JwesTo2Q9R6XwYmtmwAFCkAk3e35jEdoeh/3g==", "inBundle": true, + "license": "MIT", "dependencies": { "err-code": "^2.0.2", "retry": "^0.12.0" @@ -6371,9 +9774,8 @@ }, "node_modules/promzard": { "version": "0.3.0", - "resolved": "https://registry.npmjs.org/promzard/-/promzard-0.3.0.tgz", - "integrity": "sha1-JqXW7ox97kyxIggwWs+5O6OCqe4=", "inBundle": true, + "license": "ISC", "dependencies": { "read": "1" } @@ -6388,34 +9790,21 @@ } }, "node_modules/property-information": { - "version": "5.6.0", - "resolved": "https://registry.npmjs.org/property-information/-/property-information-5.6.0.tgz", - "integrity": "sha512-YUHSPk+A30YPv+0Qf8i9Mbfe/C0hdPXk1s1jPVToV8pk8BQtpw10ct89Eo7OWkutrwqvT0eicAxlOg3dOAu8JA==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/property-information/-/property-information-6.1.1.tgz", + "integrity": "sha512-hrzC564QIl0r0vy4l6MvRLhafmUowhO/O3KgVSoXIbbA2Sz4j8HGpJc6T2cubRVwMwpdiG/vKGfhT4IixmKN9w==", "dev": true, - "dependencies": { - "xtend": "^4.0.0" - }, "funding": { "type": "github", "url": "https://github.com/sponsors/wooorm" } }, "node_modules/psl": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/psl/-/psl-1.8.0.tgz", - "integrity": "sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ==", + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/psl/-/psl-1.9.0.tgz", + "integrity": "sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag==", "dev": true }, - "node_modules/pump": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", - "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", - "dev": true, - "dependencies": { - "end-of-stream": "^1.1.0", - "once": "^1.3.1" - } - }, "node_modules/punycode": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", @@ -6425,23 +9814,28 @@ "node": ">=6" } }, + "node_modules/q": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz", + "integrity": "sha512-kV/CThkXo6xyFEZUugw/+pIOywXcDbFYgSct5cT3gqlbkBE1SJdwy6UQoZvodiWF/ckQLZyDE/Bu1M6gVu5lVw==", + "dev": true, + "engines": { + "node": ">=0.6.0", + "teleport": ">=0.2.0" + } + }, "node_modules/qrcode-terminal": { "version": "0.12.0", - "resolved": "https://registry.npmjs.org/qrcode-terminal/-/qrcode-terminal-0.12.0.tgz", - "integrity": "sha512-EXtzRZmC+YGmGlDFbXKxQiMZNwCLEO6BANKXG4iCtSIM0yqc/pappSx3RIKr4r0uh5JsBckOXeKrB3Iz7mdQpQ==", "inBundle": true, "bin": { "qrcode-terminal": "bin/qrcode-terminal.js" } }, - "node_modules/qs": { - "version": "6.5.2", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", - "integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==", - "dev": true, - "engines": { - "node": ">=0.6" - } + "node_modules/querystringify": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==", + "dev": true }, "node_modules/queue-microtask": { "version": "1.2.3", @@ -6461,43 +9855,22 @@ "type": "consulting", "url": "https://feross.org/support" } - ] + ], + "peer": true }, - "node_modules/rc": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", - "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", - "dev": true, - "dependencies": { - "deep-extend": "^0.6.0", - "ini": "~1.3.0", - "minimist": "^1.2.0", - "strip-json-comments": "~2.0.1" - }, - "bin": { - "rc": "cli.js" - } - }, - "node_modules/rc/node_modules/ini": { - "version": "1.3.8", - "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", - "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", - "dev": true - }, - "node_modules/rc/node_modules/strip-json-comments": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", - "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", + "node_modules/quick-lru": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-4.0.1.tgz", + "integrity": "sha512-ARhCpm70fzdcvNQfPoy49IaanKkTlRWF2JMzqhcJbhSFRZv7nPTvZJdcY7301IPmvW+/p0RgIWnQDLJxifsQ7g==", "dev": true, "engines": { - "node": ">=0.10.0" + "node": ">=8" } }, "node_modules/read": { "version": "1.0.7", - "resolved": "https://registry.npmjs.org/read/-/read-1.0.7.tgz", - "integrity": "sha1-s9oZvQUkMal2cdRKQmNK33ELQMQ=", "inBundle": true, + "license": "ISC", "dependencies": { "mute-stream": "~0.0.4" }, @@ -6506,56 +9879,138 @@ } }, "node_modules/read-cmd-shim": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/read-cmd-shim/-/read-cmd-shim-2.0.0.tgz", - "integrity": "sha512-HJpV9bQpkl6KwjxlJcBoqu9Ba0PQg8TqSNIOrulGt54a0uup0HtevreFHzYzkm0lpnleRdNBzXznKrgxglEHQw==" + "version": "4.0.0", + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } }, "node_modules/read-package-json": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/read-package-json/-/read-package-json-4.1.1.tgz", - "integrity": "sha512-P82sbZJ3ldDrWCOSKxJT0r/CXMWR0OR3KRh55SgKo3p91GSIEEC32v3lSHAvO/UcH3/IoL7uqhOFBduAnwdldw==", + "version": "6.0.0", "inBundle": true, + "license": "ISC", "dependencies": { - "glob": "^7.1.1", - "json-parse-even-better-errors": "^2.3.0", - "normalize-package-data": "^3.0.0", - "npm-normalize-package-bin": "^1.0.0" + "glob": "^8.0.1", + "json-parse-even-better-errors": "^3.0.0", + "normalize-package-data": "^5.0.0", + "npm-normalize-package-bin": "^3.0.0" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/read-package-json-fast": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/read-package-json-fast/-/read-package-json-fast-2.0.3.tgz", - "integrity": "sha512-W/BKtbL+dUjTuRL2vziuYhp76s5HZ9qQhd/dKfWIZveD0O40453QNyZhC0e63lqZrAQ4jiOapVoeJ7JrszenQQ==", + "version": "3.0.1", "inBundle": true, + "license": "ISC", "dependencies": { - "json-parse-even-better-errors": "^2.3.0", - "npm-normalize-package-bin": "^1.0.1" + "json-parse-even-better-errors": "^3.0.0", + "npm-normalize-package-bin": "^3.0.0" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/read-package-tree": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/read-package-tree/-/read-package-tree-5.3.1.tgz", - "integrity": "sha512-mLUDsD5JVtlZxjSlPPx1RETkNjjvQYuweKwNVt1Sn8kP5Jh44pvYuUHCp6xSVDZWbNxVxG5lyZJ921aJH61sTw==", + "node_modules/read-pkg": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-5.2.0.tgz", + "integrity": "sha512-Ug69mNOpfvKDAc2Q8DRpMjjzdtrnv9HcSMX+4VsZxD1aZ6ZzrIE7rlzXBtWTyhULSMKg076AW6WR5iZpD0JiOg==", "dev": true, "dependencies": { - "read-package-json": "^2.0.0", - "readdir-scoped-modules": "^1.0.0", - "util-promisify": "^2.1.0" + "@types/normalize-package-data": "^2.4.0", + "normalize-package-data": "^2.5.0", + "parse-json": "^5.0.0", + "type-fest": "^0.6.0" + }, + "engines": { + "node": ">=8" } }, - "node_modules/read-package-tree/node_modules/hosted-git-info": { + "node_modules/read-pkg-up": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-7.0.1.tgz", + "integrity": "sha512-zK0TB7Xd6JpCLmlLmufqykGE+/TlOePD6qKClNW7hHDKFh/J7/7gCWGR7joEQEW1bKq3a3yUZSObOoWLFQ4ohg==", + "dev": true, + "dependencies": { + "find-up": "^4.1.0", + "read-pkg": "^5.2.0", + "type-fest": "^0.8.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/read-pkg-up/node_modules/find-up": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", + "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "dev": true, + "dependencies": { + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/read-pkg-up/node_modules/locate-path": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", + "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "dev": true, + "dependencies": { + "p-locate": "^4.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/read-pkg-up/node_modules/p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "dependencies": { + "p-try": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/read-pkg-up/node_modules/p-locate": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", + "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "dev": true, + "dependencies": { + "p-limit": "^2.2.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/read-pkg-up/node_modules/type-fest": { + "version": "0.8.1", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", + "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/read-pkg/node_modules/hosted-git-info": { "version": "2.8.9", "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.9.tgz", "integrity": "sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==", "dev": true }, - "node_modules/read-package-tree/node_modules/normalize-package-data": { + "node_modules/read-pkg/node_modules/normalize-package-data": { "version": "2.5.0", "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz", "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", @@ -6567,19 +10022,7 @@ "validate-npm-package-license": "^3.0.1" } }, - "node_modules/read-package-tree/node_modules/read-package-json": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/read-package-json/-/read-package-json-2.1.2.tgz", - "integrity": "sha512-D1KmuLQr6ZSJS0tW8hf3WGpRlwszJOXZ3E8Yd/DNRaM5d+1wVRZdHlpGBLAuovjr28LbWvjpWkBHMxpRGGjzNA==", - "dev": true, - "dependencies": { - "glob": "^7.1.1", - "json-parse-even-better-errors": "^2.3.0", - "normalize-package-data": "^2.0.0", - "npm-normalize-package-bin": "^1.0.0" - } - }, - "node_modules/read-package-tree/node_modules/semver": { + "node_modules/read-pkg/node_modules/semver": { "version": "5.7.1", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", @@ -6588,11 +10031,19 @@ "semver": "bin/semver" } }, + "node_modules/read-pkg/node_modules/type-fest": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.6.0.tgz", + "integrity": "sha512-q+MB8nYR1KDLrgr4G5yemftpMC7/QLqVndBmEEdqzmNj5dcFOO4Oo8qlwZE3ULT3+Zim1F8Kq4cBnikNhlCMlg==", + "dev": true, + "engines": { + "node": ">=8" + } + }, "node_modules/readable-stream": { "version": "3.6.0", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.0.tgz", - "integrity": "sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA==", "inBundle": true, + "license": "MIT", "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -6602,22 +10053,10 @@ "node": ">= 6" } }, - "node_modules/readdir-scoped-modules": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/readdir-scoped-modules/-/readdir-scoped-modules-1.1.0.tgz", - "integrity": "sha512-asaikDeqAQg7JifRsZn1NJZXo9E+VwlyCfbkZhwyISinqk5zNS6266HS5kah6P0SaQKGF6SkNnZVHUzHFYxYDw==", - "inBundle": true, - "dependencies": { - "debuglog": "^1.0.1", - "dezalgo": "^1.0.0", - "graceful-fs": "^4.1.2", - "once": "^1.3.0" - } - }, "node_modules/readdirp": { - "version": "3.5.0", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.5.0.tgz", - "integrity": "sha512-cMhu7c/8rdhkHXWsY+osBhfSy0JikwpHK/5+imo+LpeasTF8ouErHrlYkwT0++njiyuDvc7OFY5T3ukvZ8qmFQ==", + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", + "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", "dev": true, "dependencies": { "picomatch": "^2.2.1" @@ -6626,14 +10065,29 @@ "node": ">=8.10.0" } }, - "node_modules/regexp.prototype.flags": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.3.1.tgz", - "integrity": "sha512-JiBdRBq91WlY7uRJ0ds7R+dU02i6LKi8r3BuQhNXn+kmeLN+EfHhfjqMRis1zJxnlu88hq/4dx0P2OP3APRTOA==", + "node_modules/redent": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/redent/-/redent-3.0.0.tgz", + "integrity": "sha512-6tDA8g98We0zd0GvVeMT9arEOnTw9qM03L9cJXaCjrip1OO764RDBLBfrB4cwzNGDj5OA5ioymC9GkizgWJDUg==", "dev": true, + "dependencies": { + "indent-string": "^4.0.0", + "strip-indent": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/regexp.prototype.flags": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.4.3.tgz", + "integrity": "sha512-fjggEOO3slI6Wvgjwflkc4NFRCTZAu5CnNfBd5qOMYhWdn67nJBBu34/TkD++eeFmd8C9r9jfXJ27+nSiRkSUA==", + "dev": true, + "peer": true, "dependencies": { "call-bind": "^1.0.2", - "define-properties": "^1.1.3" + "define-properties": "^1.1.3", + "functions-have-names": "^1.2.2" }, "engines": { "node": ">= 0.4" @@ -6647,6 +10101,7 @@ "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-3.2.0.tgz", "integrity": "sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg==", "dev": true, + "peer": true, "engines": { "node": ">=8" }, @@ -6654,10 +10109,84 @@ "url": "https://github.com/sponsors/mysticatea" } }, + "node_modules/rehype-stringify": { + "version": "9.0.3", + "resolved": "https://registry.npmjs.org/rehype-stringify/-/rehype-stringify-9.0.3.tgz", + "integrity": "sha512-kWiZ1bgyWlgOxpqD5HnxShKAdXtb2IUljn3hQAhySeak6IOQPPt6DeGnsIh4ixm7yKJWzm8TXFuC/lPfcWHJqw==", + "dev": true, + "dependencies": { + "@types/hast": "^2.0.0", + "hast-util-to-html": "^8.0.0", + "unified": "^10.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/release-please": { + "name": "@npmcli/release-please", + "version": "14.2.6", + "resolved": "https://registry.npmjs.org/@npmcli/release-please/-/release-please-14.2.6.tgz", + "integrity": "sha512-KvkP3KZsJCeJJpyPK2QMkUCPsOoTbMarrCTFg4QIHXVV9US+UjJZLs6wvHrJbTg4vnCliRgGj9A2qIW3g32zLw==", + "dev": true, + "dependencies": { + "@conventional-commits/parser": "^0.4.1", + "@google-automations/git-file-utils": "^1.1.0", + "@iarna/toml": "^2.2.5", + "@lerna/collect-updates": "^4.0.0", + "@lerna/package": "^4.0.0", + "@lerna/package-graph": "^4.0.0", + "@lerna/run-topologically": "^4.0.0", + "@octokit/graphql": "^5.0.0", + "@octokit/request": "^6.0.0", + "@octokit/request-error": "^3.0.0", + "@octokit/rest": "^19.0.0", + "@types/npm-package-arg": "^6.1.0", + "@xmldom/xmldom": "^0.8.2", + "chalk": "^4.0.0", + "code-suggester": "^4.1.0", + "conventional-changelog-conventionalcommits": "^5.0.0", + "conventional-changelog-writer": "^5.0.0", + "conventional-commits-filter": "^2.0.2", + "detect-indent": "^6.1.0", + "diff": "^5.0.0", + "figures": "^3.0.0", + "js-yaml": "^4.0.0", + "jsonpath": "^1.1.1", + "node-html-parser": "^5.0.0", + "parse-github-repo-url": "^1.4.1", + "semver": "^7.0.0", + "type-fest": "^2.0.0", + "typescript": "^4.6.4", + "unist-util-visit": "^2.0.3", + "unist-util-visit-parents": "^3.1.1", + "xpath": "^0.0.32", + "yargs": "^17.0.0" + }, + "bin": { + "release-please": "build/src/bin/release-please.js" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/release-please/node_modules/type-fest": { + "version": "2.19.0", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-2.19.0.tgz", + "integrity": "sha512-RAH822pAdBgcNMAfWnCBU3CFZcfZ/i1eZjwFU/dsLKumyuuP3niueg2UAukXYF0E2AAoc82ZSSf9J0WQBinzHA==", + "dev": true, + "engines": { + "node": ">=12.20" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/release-zalgo": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/release-zalgo/-/release-zalgo-1.0.0.tgz", - "integrity": "sha1-CXALflB0Mpc5Mw5TXFqQ+2eFFzA=", + "integrity": "sha512-gUAyHVHPPC5wdqX/LG4LWtRYtgjxyX78oanFNTMMyFEfOqdC54s3eE82imuWKbOeqYht2CrNf64Qb8vgmmtZGA==", "dev": true, "dependencies": { "es6-error": "^4.0.1" @@ -6666,155 +10195,194 @@ "node": ">=4" } }, - "node_modules/remark-footnotes": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/remark-footnotes/-/remark-footnotes-2.0.0.tgz", - "integrity": "sha512-3Clt8ZMH75Ayjp9q4CorNeyjwIxHFcTkaektplKGl2A1jNGEUey8cKL0ZC5vJwfcD5GFGsNLImLG/NGzWIzoMQ==", - "dev": true, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/remark-mdx": { - "version": "1.6.22", - "resolved": "https://registry.npmjs.org/remark-mdx/-/remark-mdx-1.6.22.tgz", - "integrity": "sha512-phMHBJgeV76uyFkH4rvzCftLfKCr2RZuF+/gmVcaKrpsihyzmhXjA0BEMDaPTXG5y8qZOKPVo83NAOX01LPnOQ==", + "node_modules/remark": { + "version": "14.0.2", + "resolved": "https://registry.npmjs.org/remark/-/remark-14.0.2.tgz", + "integrity": "sha512-A3ARm2V4BgiRXaUo5K0dRvJ1lbogrbXnhkJRmD0yw092/Yl0kOCZt1k9ZeElEwkZsWGsMumz6qL5MfNJH9nOBA==", "dev": true, "dependencies": { - "@babel/core": "7.12.9", - "@babel/helper-plugin-utils": "7.10.4", - "@babel/plugin-proposal-object-rest-spread": "7.12.1", - "@babel/plugin-syntax-jsx": "7.12.1", - "@mdx-js/util": "1.6.22", - "is-alphabetical": "1.0.4", - "remark-parse": "8.0.3", - "unified": "9.2.0" + "@types/mdast": "^3.0.0", + "remark-parse": "^10.0.0", + "remark-stringify": "^10.0.0", + "unified": "^10.0.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/unified" } }, - "node_modules/remark-mdx/node_modules/@babel/helper-plugin-utils": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz", - "integrity": "sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg==", - "dev": true + "node_modules/remark-gfm": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/remark-gfm/-/remark-gfm-3.0.1.tgz", + "integrity": "sha512-lEFDoi2PICJyNrACFOfDD3JlLkuSbOa5Wd8EPt06HUdptv8Gn0bxYTdbU/XXQ3swAPkEaGxxPN9cbnMHvVu1Ig==", + "dev": true, + "dependencies": { + "@types/mdast": "^3.0.0", + "mdast-util-gfm": "^2.0.0", + "micromark-extension-gfm": "^2.0.0", + "unified": "^10.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/remark-github": { + "version": "11.2.4", + "resolved": "https://registry.npmjs.org/remark-github/-/remark-github-11.2.4.tgz", + "integrity": "sha512-GJjWFpwqdrHHhPWqMbb8+lqFLiHQ9pCzUmXmRrhMFXGpYov5n2ljsZzuWgXlfzArfQYkiKIZczA2I8IHYMHqCA==", + "dev": true, + "dependencies": { + "@types/mdast": "^3.0.0", + "mdast-util-find-and-replace": "^2.0.0", + "mdast-util-to-string": "^3.0.0", + "unified": "^10.0.0", + "unist-util-visit": "^4.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/remark-github/node_modules/unist-util-visit": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-4.1.1.tgz", + "integrity": "sha512-n9KN3WV9k4h1DxYR1LoajgN93wpEi/7ZplVe02IoB4gH5ctI1AaF2670BLHQYbwj+pY83gFtyeySFiyMHJklrg==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^5.0.0", + "unist-util-visit-parents": "^5.1.1" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/remark-github/node_modules/unist-util-visit-parents": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-5.1.1.tgz", + "integrity": "sha512-gks4baapT/kNRaWxuGkl5BIhoanZo7sC/cUT/JToSRNL1dYoXRFl75d++NkjYk4TAu2uv2Px+l8guMajogeuiw==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^5.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/remark-man": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/remark-man/-/remark-man-8.0.1.tgz", + "integrity": "sha512-F/BbNaEF/QiZXoMiC43/qb8kAgGBKIS3yA+Br4CObgyoD+9Bioq1v+LmrLVbkwy9BErircQQ4J8yR2vFD34fBA==", + "dev": true, + "dependencies": { + "@types/mdast": "^3.0.0", + "@types/unist": "^2.0.0", + "github-slugger": "^1.0.0", + "groff-escape": "^2.0.0", + "mdast-util-definitions": "^5.0.0", + "mdast-util-to-string": "^3.0.0", + "months": "^2.0.0", + "unified": "^10.0.0", + "unist-util-visit": "^4.0.0", + "zwitch": "^2.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/remark-man/node_modules/unist-util-visit": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-4.1.1.tgz", + "integrity": "sha512-n9KN3WV9k4h1DxYR1LoajgN93wpEi/7ZplVe02IoB4gH5ctI1AaF2670BLHQYbwj+pY83gFtyeySFiyMHJklrg==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^5.0.0", + "unist-util-visit-parents": "^5.1.1" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/remark-man/node_modules/unist-util-visit-parents": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-5.1.1.tgz", + "integrity": "sha512-gks4baapT/kNRaWxuGkl5BIhoanZo7sC/cUT/JToSRNL1dYoXRFl75d++NkjYk4TAu2uv2Px+l8guMajogeuiw==", + "dev": true, + "dependencies": { + "@types/unist": "^2.0.0", + "unist-util-is": "^5.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } }, "node_modules/remark-parse": { - "version": "8.0.3", - "resolved": "https://registry.npmjs.org/remark-parse/-/remark-parse-8.0.3.tgz", - "integrity": "sha512-E1K9+QLGgggHxCQtLt++uXltxEprmWzNfg+MxpfHsZlrddKzZ/hZyWHDbK3/Ap8HJQqYJRXP+jHczdL6q6i85Q==", + "version": "10.0.1", + "resolved": "https://registry.npmjs.org/remark-parse/-/remark-parse-10.0.1.tgz", + "integrity": "sha512-1fUyHr2jLsVOkhbvPRBJ5zTKZZyD6yZzYaWCS6BPBdQ8vEMBCH+9zNCDA6tET/zHCi/jLqjCWtlJZUPk+DbnFw==", "dev": true, "dependencies": { - "ccount": "^1.0.0", - "collapse-white-space": "^1.0.2", - "is-alphabetical": "^1.0.0", - "is-decimal": "^1.0.0", - "is-whitespace-character": "^1.0.0", - "is-word-character": "^1.0.0", - "markdown-escapes": "^1.0.0", - "parse-entities": "^2.0.0", - "repeat-string": "^1.5.4", - "state-toggle": "^1.0.0", - "trim": "0.0.1", - "trim-trailing-lines": "^1.0.0", - "unherit": "^1.0.4", - "unist-util-remove-position": "^2.0.0", - "vfile-location": "^3.0.0", - "xtend": "^4.0.1" + "@types/mdast": "^3.0.0", + "mdast-util-from-markdown": "^1.0.0", + "unified": "^10.0.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/unified" } }, - "node_modules/remark-squeeze-paragraphs": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/remark-squeeze-paragraphs/-/remark-squeeze-paragraphs-4.0.0.tgz", - "integrity": "sha512-8qRqmL9F4nuLPIgl92XUuxI3pFxize+F1H0e/W3llTk0UsjJaj01+RrirkMw7P21RKe4X6goQhYRSvNWX+70Rw==", + "node_modules/remark-rehype": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/remark-rehype/-/remark-rehype-10.1.0.tgz", + "integrity": "sha512-EFmR5zppdBp0WQeDVZ/b66CWJipB2q2VLNFMabzDSGR66Z2fQii83G5gTBbgGEnEEA0QRussvrFHxk1HWGJskw==", "dev": true, "dependencies": { - "mdast-squeeze-paragraphs": "^4.0.0" + "@types/hast": "^2.0.0", + "@types/mdast": "^3.0.0", + "mdast-util-to-hast": "^12.1.0", + "unified": "^10.0.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/unified" } }, - "node_modules/repeat-string": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", - "integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc=", - "dev": true, - "engines": { - "node": ">=0.10" - } - }, - "node_modules/request": { - "version": "2.88.2", - "resolved": "https://registry.npmjs.org/request/-/request-2.88.2.tgz", - "integrity": "sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw==", - "deprecated": "request has been deprecated, see https://github.com/request/request/issues/3142", + "node_modules/remark-stringify": { + "version": "10.0.2", + "resolved": "https://registry.npmjs.org/remark-stringify/-/remark-stringify-10.0.2.tgz", + "integrity": "sha512-6wV3pvbPvHkbNnWB0wdDvVFHOe1hBRAx1Q/5g/EpH4RppAII6J8Gnwe7VbHuXaoKIF6LAg6ExTel/+kNqSQ7lw==", "dev": true, "dependencies": { - "aws-sign2": "~0.7.0", - "aws4": "^1.8.0", - "caseless": "~0.12.0", - "combined-stream": "~1.0.6", - "extend": "~3.0.2", - "forever-agent": "~0.6.1", - "form-data": "~2.3.2", - "har-validator": "~5.1.3", - "http-signature": "~1.2.0", - "is-typedarray": "~1.0.0", - "isstream": "~0.1.2", - "json-stringify-safe": "~5.0.1", - "mime-types": "~2.1.19", - "oauth-sign": "~0.9.0", - "performance-now": "^2.1.0", - "qs": "~6.5.2", - "safe-buffer": "^5.1.2", - "tough-cookie": "~2.5.0", - "tunnel-agent": "^0.6.0", - "uuid": "^3.3.2" + "@types/mdast": "^3.0.0", + "mdast-util-to-markdown": "^1.0.0", + "unified": "^10.0.0" }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/request/node_modules/form-data": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz", - "integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==", - "dev": true, - "dependencies": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.6", - "mime-types": "^2.1.12" - }, - "engines": { - "node": ">= 0.12" - } - }, - "node_modules/request/node_modules/tough-cookie": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.5.0.tgz", - "integrity": "sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g==", - "dev": true, - "dependencies": { - "psl": "^1.1.28", - "punycode": "^2.1.1" - }, - "engines": { - "node": ">=0.8" + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, "node_modules/require-directory": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", + "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/require-from-string": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", + "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", "dev": true, "engines": { "node": ">=0.10.0" @@ -6835,42 +10403,73 @@ "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", "dev": true }, + "node_modules/requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==", + "dev": true + }, "node_modules/resolve": { - "version": "1.20.0", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.20.0.tgz", - "integrity": "sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A==", + "version": "1.22.1", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.1.tgz", + "integrity": "sha512-nBpuuYuY5jFsli/JIs1oldw6fOQCBioohqWZg/2hiaOybXOft4lonv85uDOKXdf8rhyK159cxU5cDcK/NKk8zw==", "dev": true, "dependencies": { - "is-core-module": "^2.2.0", - "path-parse": "^1.0.6" + "is-core-module": "^2.9.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/resolve-from": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", - "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", + "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", "dev": true, "engines": { - "node": ">=4" + "node": ">=8" + } + }, + "node_modules/resolve-global": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/resolve-global/-/resolve-global-1.0.0.tgz", + "integrity": "sha512-zFa12V4OLtT5XUX/Q4VLvTfBf+Ok0SPc1FNGM/z9ctUdiU618qwKpWnd0CHs3+RqROfyEg/DhuHbMWYqcgljEw==", + "dev": true, + "dependencies": { + "global-dirs": "^0.1.1" + }, + "engines": { + "node": ">=8" } }, "node_modules/retry": { "version": "0.12.0", - "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", - "integrity": "sha1-G0KmJmoh8HQh0bC1S33BZ7AcATs=", "inBundle": true, + "license": "MIT", "engines": { "node": ">= 4" } }, + "node_modules/reusify": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", + "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", + "dev": true, + "peer": true, + "engines": { + "iojs": ">=1.0.0", + "node": ">=0.10.0" + } + }, "node_modules/rimraf": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", - "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", "inBundle": true, + "license": "ISC", "dependencies": { "glob": "^7.1.3" }, @@ -6881,6 +10480,45 @@ "url": "https://github.com/sponsors/isaacs" } }, + "node_modules/rimraf/node_modules/brace-expansion": { + "version": "1.1.11", + "inBundle": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/rimraf/node_modules/glob": { + "version": "7.2.3", + "inBundle": true, + "license": "ISC", + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/rimraf/node_modules/minimatch": { + "version": "3.1.2", + "inBundle": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, "node_modules/run-parallel": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", @@ -6900,14 +10538,25 @@ "url": "https://feross.org/support" } ], + "peer": true, "dependencies": { "queue-microtask": "^1.2.2" } }, + "node_modules/sade": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/sade/-/sade-1.8.1.tgz", + "integrity": "sha512-xal3CZX1Xlo/k4ApwCFrHVACi9fBqJ7V+mwhBsuf/1IOKbBy098Fex+Wa/5QMubw09pSZ/u8EY8PWgevJsXp1A==", + "dev": true, + "dependencies": { + "mri": "^1.1.0" + }, + "engines": { + "node": ">=6" + } + }, "node_modules/safe-buffer": { "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", "funding": [ { "type": "github", @@ -6922,32 +10571,46 @@ "url": "https://feross.org/support" } ], - "inBundle": true + "inBundle": true, + "license": "MIT" + }, + "node_modules/safe-regex-test": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", + "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", + "dev": true, + "peer": true, + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "is-regex": "^1.1.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } }, "node_modules/safer-buffer": { "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", "devOptional": true, - "inBundle": true + "inBundle": true, + "license": "MIT" }, "node_modules/saxes": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/saxes/-/saxes-5.0.1.tgz", - "integrity": "sha512-5LBh1Tls8c9xgGjw3QrMwETmTMVk0oFgvrFSvWx62llR2hcEInrKNZ2GZCCuuy2lvWrdl5jhbpeqc5hRYKFOcw==", + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/saxes/-/saxes-6.0.0.tgz", + "integrity": "sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA==", "dev": true, "dependencies": { "xmlchars": "^2.2.0" }, "engines": { - "node": ">=10" + "node": ">=v12.22.7" } }, "node_modules/semver": { - "version": "7.3.5", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.5.tgz", - "integrity": "sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ==", + "version": "7.3.8", "inBundle": true, + "license": "ISC", "dependencies": { "lru-cache": "^6.0.0" }, @@ -6958,11 +10621,21 @@ "node": ">=10" } }, + "node_modules/semver/node_modules/lru-cache": { + "version": "6.0.0", + "inBundle": true, + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/set-blocking": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", - "inBundle": true + "inBundle": true, + "license": "ISC" }, "node_modules/shebang-command": { "version": "2.0.0", @@ -6990,6 +10663,7 @@ "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", "dev": true, + "peer": true, "dependencies": { "call-bind": "^1.0.0", "get-intrinsic": "^1.0.2", @@ -7000,60 +10674,35 @@ } }, "node_modules/signal-exit": { - "version": "3.0.6", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.6.tgz", - "integrity": "sha512-sDl4qMFpijcGw22U5w63KmD3cZJfBuFlVNbVMKje2keoKML7X2UzWbc4XrmEbDwg0NXJc3yv4/ox7b+JWb57kQ==", - "inBundle": true + "version": "3.0.7", + "inBundle": true, + "license": "ISC" }, - "node_modules/simple-concat": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/simple-concat/-/simple-concat-1.0.1.tgz", - "integrity": "sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==", + "node_modules/slash": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", + "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ] - }, - "node_modules/simple-get": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/simple-get/-/simple-get-3.1.1.tgz", - "integrity": "sha512-CQ5LTKGfCpvE1K0n2us+kuMPbk/q0EKl82s4aheV9oXjFEz6W/Y7oQFVJuU6QG77hRT4Ghb5RURteF5vnWjupA==", - "dev": true, - "dependencies": { - "decompress-response": "^4.2.0", - "once": "^1.3.1", - "simple-concat": "^1.0.0" + "engines": { + "node": ">=8" } }, "node_modules/smart-buffer": { "version": "4.2.0", - "resolved": "https://registry.npmjs.org/smart-buffer/-/smart-buffer-4.2.0.tgz", - "integrity": "sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg==", "inBundle": true, + "license": "MIT", "engines": { "node": ">= 6.0.0", "npm": ">= 3.0.0" } }, "node_modules/socks": { - "version": "2.6.1", - "resolved": "https://registry.npmjs.org/socks/-/socks-2.6.1.tgz", - "integrity": "sha512-kLQ9N5ucj8uIcxrDwjm0Jsqk06xdpBjGNQtpXy4Q8/QY2k+fY7nZH8CARy+hkbG+SGAovmzzuauCpBlb8FrnBA==", + "version": "2.7.0", "inBundle": true, + "license": "MIT", "dependencies": { - "ip": "^1.1.5", - "smart-buffer": "^4.1.0" + "ip": "^2.0.0", + "smart-buffer": "^4.2.0" }, "engines": { "node": ">= 10.13.0", @@ -7061,39 +10710,31 @@ } }, "node_modules/socks-proxy-agent": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/socks-proxy-agent/-/socks-proxy-agent-6.1.1.tgz", - "integrity": "sha512-t8J0kG3csjA4g6FTbsMOWws+7R7vuRC8aQ/wy3/1OWmsgwA68zs/+cExQ0koSitUDXqhufF/YJr9wtNMZHw5Ew==", + "version": "7.0.0", "inBundle": true, + "license": "MIT", "dependencies": { "agent-base": "^6.0.2", - "debug": "^4.3.1", - "socks": "^2.6.1" + "debug": "^4.3.3", + "socks": "^2.6.2" }, "engines": { "node": ">= 10" } }, - "node_modules/source-map": { - "version": "0.5.7", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", - "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/source-map-support": { - "version": "0.5.19", - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", - "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", + "node_modules/sort-keys": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/sort-keys/-/sort-keys-2.0.0.tgz", + "integrity": "sha512-/dPCrG1s3ePpWm6yBbxZq5Be1dXGLyLn9Z791chDC3NFrpkVbWGzkBwPN1knaciexFXgRJ7hzdnwZ4stHSDmjg==", "dev": true, "dependencies": { - "buffer-from": "^1.0.0", - "source-map": "^0.6.0" + "is-plain-obj": "^1.0.0" + }, + "engines": { + "node": ">=4" } }, - "node_modules/source-map-support/node_modules/source-map": { + "node_modules/source-map": { "version": "0.6.1", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", @@ -7102,10 +10743,20 @@ "node": ">=0.10.0" } }, + "node_modules/source-map-support": { + "version": "0.5.21", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.21.tgz", + "integrity": "sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==", + "dev": true, + "dependencies": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, "node_modules/space-separated-tokens": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/space-separated-tokens/-/space-separated-tokens-1.1.5.tgz", - "integrity": "sha512-q/JSVd1Lptzhf5bkYm4ob4iWPjx0KiRe3sRFBNrVqbJkFaBm5vbbowy1mymoPNLRa52+oadOhJ+K49wsSeSjTA==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/space-separated-tokens/-/space-separated-tokens-2.0.1.tgz", + "integrity": "sha512-ekwEbFp5aqSPKaqeY1PGrlGQxPNaq+Cnx4+bE2D8sciBQrHpbwoBbawqTN2+6jPs9IdWxxiUcN0K2pkczD3zmw==", "dev": true, "funding": { "type": "github", @@ -7113,9 +10764,9 @@ } }, "node_modules/spawk": { - "version": "1.7.1", - "resolved": "https://registry.npmjs.org/spawk/-/spawk-1.7.1.tgz", - "integrity": "sha512-qkPqVdPp5ICEeSYKB/qCkwIBB0IWQuouEvYenQvpTq15fqSQgutpH453NjEImrpCWTwQwj2bQjGp8YGHapEiWw==", + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/spawk/-/spawk-1.8.0.tgz", + "integrity": "sha512-/bqxBMj+ldGl/p/hjHW8VRL9DulNQV0bjvB2v6knpG6gq2Y+teLtjpjqpBXQq02o6CCVCeiFP4VjCs0CVlG8Jg==", "dev": true, "engines": { "node": ">=12.0.0" @@ -7138,6 +10789,21 @@ "node": ">=8" } }, + "node_modules/spawn-wrap/node_modules/which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, "node_modules/spdx-compare": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/spdx-compare/-/spdx-compare-1.0.0.tgz", @@ -7151,9 +10817,8 @@ }, "node_modules/spdx-correct": { "version": "3.1.1", - "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.1.tgz", - "integrity": "sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w==", "inBundle": true, + "license": "Apache-2.0", "dependencies": { "spdx-expression-parse": "^3.0.0", "spdx-license-ids": "^3.0.0" @@ -7161,15 +10826,13 @@ }, "node_modules/spdx-exceptions": { "version": "2.3.0", - "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz", - "integrity": "sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A==", - "inBundle": true + "inBundle": true, + "license": "CC-BY-3.0" }, "node_modules/spdx-expression-parse": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz", - "integrity": "sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==", "inBundle": true, + "license": "MIT", "dependencies": { "spdx-exceptions": "^2.1.0", "spdx-license-ids": "^3.0.0" @@ -7186,9 +10849,8 @@ }, "node_modules/spdx-license-ids": { "version": "3.0.11", - "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.11.tgz", - "integrity": "sha512-Ctl2BrFiM0X3MANYgj3CkygxhRmr9mi6xhejbdO960nF6EDJApTYpn0BQnDKlnNBULKiCN1n3w9EBkHK8ZWg+g==", - "inBundle": true + "inBundle": true, + "license": "CC0-1.0" }, "node_modules/spdx-osi": { "version": "3.0.0", @@ -7212,42 +10874,43 @@ "spdx-ranges": "^2.0.0" } }, + "node_modules/split": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/split/-/split-1.0.1.tgz", + "integrity": "sha512-mTyOoPbrivtXnwnIxZRFYRrPNtEFKlpB2fvjSnCQUiAA6qAZzqwna5envK4uk6OIeP17CsdF3rSBGYVBsU0Tkg==", + "dev": true, + "dependencies": { + "through": "2" + }, + "engines": { + "node": "*" + } + }, + "node_modules/split2": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/split2/-/split2-3.2.2.tgz", + "integrity": "sha512-9NThjpgZnifTkJpzTZ7Eue85S49QwpNhZTq6GRJwObb6jnLFNGB7Qm73V5HewTROPyxD0C29xqmaI68bQtV+hg==", + "dev": true, + "dependencies": { + "readable-stream": "^3.0.0" + } + }, "node_modules/sprintf-js": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", + "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", "dev": true }, - "node_modules/sshpk": { - "version": "1.16.1", - "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz", - "integrity": "sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==", - "dev": true, - "dependencies": { - "asn1": "~0.2.3", - "assert-plus": "^1.0.0", - "bcrypt-pbkdf": "^1.0.0", - "dashdash": "^1.12.0", - "ecc-jsbn": "~0.1.1", - "getpass": "^0.1.1", - "jsbn": "~0.1.0", - "safer-buffer": "^2.0.2", - "tweetnacl": "~0.14.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/ssri": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/ssri/-/ssri-8.0.1.tgz", - "integrity": "sha512-97qShzy1AiyxvPNIkLWoGua7xoQzzPjQ0HAH4B0rWKo7SZ6USuPcrUiAFrws0UH8RrbWmgq3LMTObhPIHbbBeQ==", + "version": "10.0.1", + "resolved": "https://registry.npmjs.org/ssri/-/ssri-10.0.1.tgz", + "integrity": "sha512-WVy6di9DlPOeBWEjMScpNipeSX2jIZBGEn5Uuo8Q7aIuFEuDX0pw8RxcOjlD1TWP4obi24ki7m/13+nFpcbXrw==", "inBundle": true, "dependencies": { - "minipass": "^3.1.1" + "minipass": "^4.0.0" }, "engines": { - "node": ">= 8" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/stack-utils": { @@ -7271,100 +10934,119 @@ "node": ">=8" } }, - "node_modules/state-toggle": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/state-toggle/-/state-toggle-1.0.3.tgz", - "integrity": "sha512-d/5Z4/2iiCnHw6Xzghyhb+GcmF89bxwgXG60wjIiZaxnymbyOmI8Hk4VqHXiVVp6u2ysaskFfXg3ekCj4WNftQ==", + "node_modules/static-eval": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/static-eval/-/static-eval-2.0.2.tgz", + "integrity": "sha512-N/D219Hcr2bPjLxPiV+TQE++Tsmrady7TqAJugLy7Xk1EumfDWS/f5dtBbkRCGE7wKKXuYockQoj8Rm2/pVKyg==", "dev": true, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" + "dependencies": { + "escodegen": "^1.8.1" } }, "node_modules/string_decoder": { "version": "1.3.0", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", - "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", "inBundle": true, + "license": "MIT", "dependencies": { "safe-buffer": "~5.2.0" } }, "node_modules/string-width": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "version": "4.2.3", "inBundle": true, + "license": "MIT", "dependencies": { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0" + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" }, "engines": { - "node": ">=4" - } - }, - "node_modules/string-width/node_modules/ansi-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", - "inBundle": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/string-width/node_modules/strip-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "inBundle": true, - "dependencies": { - "ansi-regex": "^3.0.0" - }, - "engines": { - "node": ">=4" + "node": ">=8" } }, "node_modules/string.prototype.trimend": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.4.tgz", - "integrity": "sha512-y9xCjw1P23Awk8EvTpcyL2NIr1j7wJ39f+k6lvRnSMz+mz9CGz9NYPelDk42kOz6+ql8xjfK8oYzy3jAP5QU5A==", + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.6.tgz", + "integrity": "sha512-JySq+4mrPf9EsDBEDYMOb/lM7XQLulwg5R/m1r0PXEFqrV0qHvl58sdTilSXtKOflCsK2E8jxf+GKC0T07RWwQ==", "dev": true, + "peer": true, "dependencies": { "call-bind": "^1.0.2", - "define-properties": "^1.1.3" + "define-properties": "^1.1.4", + "es-abstract": "^1.20.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, "node_modules/string.prototype.trimstart": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.4.tgz", - "integrity": "sha512-jh6e984OBfvxS50tdY2nRZnoC5/mLFKOREQfw8t5yytkoUsJRNxvI/E39qu1sD0OtWI3OC0XgKSmcWwziwYuZw==", + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.5.tgz", + "integrity": "sha512-THx16TJCGlsN0o6dl2o6ncWUsdgnLRSA23rRE5pyGBw/mLr3Ej/R2LaqCtgP8VNMGZsvMWnf9ooZPyY2bHvUFg==", "dev": true, + "peer": true, "dependencies": { "call-bind": "^1.0.2", - "define-properties": "^1.1.3" + "define-properties": "^1.1.4", + "es-abstract": "^1.19.5" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/stringify-package": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/stringify-package/-/stringify-package-1.0.1.tgz", - "integrity": "sha512-sa4DUQsYciMP1xhKWGuFM04fB0LG/9DlluZoSVywUMRNvzid6XucHK0/90xGxRoHrAaROrcHK1aPKaijCtSrhg==" + "node_modules/stringify-entities": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/stringify-entities/-/stringify-entities-4.0.3.tgz", + "integrity": "sha512-BP9nNHMhhfcMbiuQKCqMjhDP5yBCAxsPu4pHFFzJ6Alo9dZgY4VLDPutXqIjpRiMoKdp7Av85Gr73Q5uH9k7+g==", + "dev": true, + "dependencies": { + "character-entities-html4": "^2.0.0", + "character-entities-legacy": "^3.0.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } }, "node_modules/strip-ansi": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "version": "6.0.1", "inBundle": true, + "license": "MIT", "dependencies": { - "ansi-regex": "^2.0.0" + "ansi-regex": "^5.0.1" }, "engines": { - "node": ">=0.10.0" + "node": ">=8" + } + }, + "node_modules/strip-bom": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-4.0.0.tgz", + "integrity": "sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-final-newline": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", + "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/strip-indent": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-3.0.0.tgz", + "integrity": "sha512-laJTa3Jb+VQpaC6DseHhF7dXVqHTfJPCRDaEbid/drOhgitgYku/letMUqOXFoWV0zIIUbjpdH2t+tYj4bQMRQ==", + "dev": true, + "dependencies": { + "min-indent": "^1.0.0" + }, + "engines": { + "node": ">=8" } }, "node_modules/strip-json-comments": { @@ -7372,6 +11054,7 @@ "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", "dev": true, + "peer": true, "engines": { "node": ">=8" }, @@ -7379,20 +11062,27 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/style-to-object": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/style-to-object/-/style-to-object-0.3.0.tgz", - "integrity": "sha512-CzFnRRXhzWIdItT3OmF8SQfWyahHhjq3HwcMNCNLn+N7klOOqPjMeG/4JSu77D7ypZdGvSzvkrbyeTMizz2VrA==", + "node_modules/strong-log-transformer": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/strong-log-transformer/-/strong-log-transformer-2.1.0.tgz", + "integrity": "sha512-B3Hgul+z0L9a236FAUC9iZsL+nVHgoCJnqCbN588DjYxvGXaXaaFbfmQ/JhvKjZwsOukuR72XbHv71Qkug0HxA==", "dev": true, "dependencies": { - "inline-style-parser": "0.1.1" + "duplexer": "^0.1.1", + "minimist": "^1.2.0", + "through": "^2.3.4" + }, + "bin": { + "sl-log-transformer": "bin/sl-log-transformer.js" + }, + "engines": { + "node": ">=4" } }, "node_modules/supports-color": { "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "inBundle": true, + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -7400,6 +11090,18 @@ "node": ">=8" } }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/symbol-tree": { "version": "3.2.4", "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz", @@ -7407,9 +11109,9 @@ "dev": true }, "node_modules/tap": { - "version": "15.1.6", - "resolved": "https://registry.npmjs.org/tap/-/tap-15.1.6.tgz", - "integrity": "sha512-TN7xH6Q2tUPTd6qwmkhuFJcx1vUR8e4dDUpBKc61G0krOzne7Ia6aKIFb8O/0kVazachSSuVME1V8nQ2xwWL8w==", + "version": "16.3.2", + "resolved": "https://registry.npmjs.org/tap/-/tap-16.3.2.tgz", + "integrity": "sha512-4MWMObR8unbv5gAHHVW9F0MNk3opQMnLusSWvt4KBAnKmkwpBRKIfNF64fimQbcR4y9a7U9ISV7pCldlV3J8Pw==", "bundleDependencies": [ "ink", "treport", @@ -7419,49 +11121,52 @@ ], "dev": true, "dependencies": { - "@isaacs/import-jsx": "*", - "@types/react": "*", + "@isaacs/import-jsx": "^4.0.1", + "@types/react": "^17.0.52", "chokidar": "^3.3.0", - "coveralls": "^3.0.11", "findit": "^2.0.0", "foreground-child": "^2.0.0", "fs-exists-cached": "^1.0.0", - "glob": "^7.1.6", - "ink": "*", + "glob": "^7.2.3", + "ink": "^3.2.0", "isexe": "^2.0.0", - "istanbul-lib-processinfo": "^2.0.2", - "jackspeak": "^1.4.1", - "libtap": "^1.1.4", - "minipass": "^3.1.1", + "istanbul-lib-processinfo": "^2.0.3", + "jackspeak": "^1.4.2", + "libtap": "^1.4.0", + "minipass": "^3.3.4", "mkdirp": "^1.0.4", "nyc": "^15.1.0", "opener": "^1.5.1", - "react": "*", + "react": "^17.0.2", "rimraf": "^3.0.0", "signal-exit": "^3.0.6", "source-map-support": "^0.5.16", - "tap-mocha-reporter": "^5.0.0", - "tap-parser": "^10.0.1", - "tap-yaml": "^1.0.0", + "tap-mocha-reporter": "^5.0.3", + "tap-parser": "^11.0.2", + "tap-yaml": "^1.0.2", "tcompare": "^5.0.7", - "treport": "*", + "treport": "^3.0.4", "which": "^2.0.2" }, "bin": { "tap": "bin/run.js" }, "engines": { - "node": ">=10" + "node": ">=12" }, "funding": { "url": "https://github.com/sponsors/isaacs" }, "peerDependencies": { + "coveralls": "^3.1.1", "flow-remove-types": ">=2.112.0", "ts-node": ">=8.5.2", "typescript": ">=3.7.2" }, "peerDependenciesMeta": { + "coveralls": { + "optional": true + }, "flow-remove-types": { "optional": true }, @@ -7474,9 +11179,9 @@ } }, "node_modules/tap-mocha-reporter": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/tap-mocha-reporter/-/tap-mocha-reporter-5.0.1.tgz", - "integrity": "sha512-1knFWOwd4khx/7uSEnUeaP9IPW3w+sqTgJMhrwah6t46nZ8P25atOKAjSvVDsT67lOPu0nfdOqUwoyKn+3E5pA==", + "version": "5.0.3", + "resolved": "https://registry.npmjs.org/tap-mocha-reporter/-/tap-mocha-reporter-5.0.3.tgz", + "integrity": "sha512-6zlGkaV4J+XMRFkN0X+yuw6xHbE9jyCZ3WUKfw4KxMyRGOpYSRuuQTRJyWX88WWuLdVTuFbxzwXhXuS2XE6o0g==", "dev": true, "dependencies": { "color-support": "^1.1.0", @@ -7484,7 +11189,7 @@ "diff": "^4.0.1", "escape-string-regexp": "^2.0.0", "glob": "^7.0.5", - "tap-parser": "^10.0.0", + "tap-parser": "^11.0.0", "tap-yaml": "^1.0.0", "unicode-length": "^2.0.2" }, @@ -7495,6 +11200,16 @@ "node": ">= 8" } }, + "node_modules/tap-mocha-reporter/node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, "node_modules/tap-mocha-reporter/node_modules/diff": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", @@ -7513,14 +11228,46 @@ "node": ">=8" } }, + "node_modules/tap-mocha-reporter/node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "dev": true, + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/tap-mocha-reporter/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, "node_modules/tap-parser": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/tap-parser/-/tap-parser-10.1.0.tgz", - "integrity": "sha512-FujQeciDaOiOvaIVGS1Rpb0v4R6XkOjvWCWowlz5oKuhPkEJ8U6pxgqt38xuzYhPt8dWEnfHn2jqpZdJEkW7pA==", + "version": "11.0.2", + "resolved": "https://registry.npmjs.org/tap-parser/-/tap-parser-11.0.2.tgz", + "integrity": "sha512-6qGlC956rcORw+fg7Fv1iCRAY8/bU9UabUAhs3mXRH6eRmVZcNPLheSXCYaVaYeSwx5xa/1HXZb1537YSvwDZg==", "dev": true, "dependencies": { "events-to-array": "^1.0.1", - "minipass": "^3.0.0", + "minipass": "^3.1.6", "tap-yaml": "^1.0.0" }, "bin": { @@ -7530,29 +11277,62 @@ "node": ">= 8" } }, - "node_modules/tap-yaml": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/tap-yaml/-/tap-yaml-1.0.0.tgz", - "integrity": "sha512-Rxbx4EnrWkYk0/ztcm5u3/VznbyFJpyXO12dDBHKWiDVxy7O2Qw6MRrwO5H6Ww0U5YhRY/4C/VzWmFPhBQc4qQ==", + "node_modules/tap-parser/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", "dev": true, "dependencies": { - "yaml": "^1.5.0" + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/tap-yaml": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/tap-yaml/-/tap-yaml-1.0.2.tgz", + "integrity": "sha512-GegASpuqBnRNdT1U+yuUPZ8rEU64pL35WPBpCISWwff4dErS2/438barz7WFJl4Nzh3Y05tfPidZnH+GaV1wMg==", + "dev": true, + "dependencies": { + "yaml": "^1.10.2" + } + }, + "node_modules/tap-yaml/node_modules/yaml": { + "version": "1.10.2", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", + "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", + "dev": true, + "engines": { + "node": ">= 6" + } + }, + "node_modules/tap/node_modules/@ampproject/remapping": { + "version": "2.1.2", + "dev": true, + "inBundle": true, + "license": "Apache-2.0", + "dependencies": { + "@jridgewell/trace-mapping": "^0.3.0" + }, + "engines": { + "node": ">=6.0.0" } }, "node_modules/tap/node_modules/@babel/code-frame": { - "version": "7.16.0", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/highlight": "^7.16.0" + "@babel/highlight": "^7.16.7" }, "engines": { "node": ">=6.9.0" } }, "node_modules/tap/node_modules/@babel/compat-data": { - "version": "7.16.0", + "version": "7.17.7", "dev": true, "inBundle": true, "license": "MIT", @@ -7561,26 +11341,26 @@ } }, "node_modules/tap/node_modules/@babel/core": { - "version": "7.16.0", + "version": "7.17.8", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/code-frame": "^7.16.0", - "@babel/generator": "^7.16.0", - "@babel/helper-compilation-targets": "^7.16.0", - "@babel/helper-module-transforms": "^7.16.0", - "@babel/helpers": "^7.16.0", - "@babel/parser": "^7.16.0", - "@babel/template": "^7.16.0", - "@babel/traverse": "^7.16.0", - "@babel/types": "^7.16.0", + "@ampproject/remapping": "^2.1.0", + "@babel/code-frame": "^7.16.7", + "@babel/generator": "^7.17.7", + "@babel/helper-compilation-targets": "^7.17.7", + "@babel/helper-module-transforms": "^7.17.7", + "@babel/helpers": "^7.17.8", + "@babel/parser": "^7.17.8", + "@babel/template": "^7.16.7", + "@babel/traverse": "^7.17.3", + "@babel/types": "^7.17.0", "convert-source-map": "^1.7.0", "debug": "^4.1.0", "gensync": "^1.0.0-beta.2", "json5": "^2.1.2", - "semver": "^6.3.0", - "source-map": "^0.5.0" + "semver": "^6.3.0" }, "engines": { "node": ">=6.9.0" @@ -7591,12 +11371,12 @@ } }, "node_modules/tap/node_modules/@babel/generator": { - "version": "7.16.0", + "version": "7.17.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/types": "^7.16.0", + "@babel/types": "^7.17.0", "jsesc": "^2.5.1", "source-map": "^0.5.0" }, @@ -7605,25 +11385,25 @@ } }, "node_modules/tap/node_modules/@babel/helper-annotate-as-pure": { - "version": "7.16.0", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/types": "^7.16.0" + "@babel/types": "^7.16.7" }, "engines": { "node": ">=6.9.0" } }, "node_modules/tap/node_modules/@babel/helper-compilation-targets": { - "version": "7.16.3", + "version": "7.17.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/compat-data": "^7.16.0", - "@babel/helper-validator-option": "^7.14.5", + "@babel/compat-data": "^7.17.7", + "@babel/helper-validator-option": "^7.16.7", "browserslist": "^4.17.5", "semver": "^6.3.0" }, @@ -7634,101 +11414,89 @@ "@babel/core": "^7.0.0" } }, - "node_modules/tap/node_modules/@babel/helper-function-name": { - "version": "7.16.0", + "node_modules/tap/node_modules/@babel/helper-environment-visitor": { + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/helper-get-function-arity": "^7.16.0", - "@babel/template": "^7.16.0", - "@babel/types": "^7.16.0" + "@babel/types": "^7.16.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/tap/node_modules/@babel/helper-function-name": { + "version": "7.16.7", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "@babel/helper-get-function-arity": "^7.16.7", + "@babel/template": "^7.16.7", + "@babel/types": "^7.16.7" }, "engines": { "node": ">=6.9.0" } }, "node_modules/tap/node_modules/@babel/helper-get-function-arity": { - "version": "7.16.0", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/types": "^7.16.0" + "@babel/types": "^7.16.7" }, "engines": { "node": ">=6.9.0" } }, "node_modules/tap/node_modules/@babel/helper-hoist-variables": { - "version": "7.16.0", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/types": "^7.16.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/tap/node_modules/@babel/helper-member-expression-to-functions": { - "version": "7.16.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "@babel/types": "^7.16.0" + "@babel/types": "^7.16.7" }, "engines": { "node": ">=6.9.0" } }, "node_modules/tap/node_modules/@babel/helper-module-imports": { - "version": "7.16.0", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/types": "^7.16.0" + "@babel/types": "^7.16.7" }, "engines": { "node": ">=6.9.0" } }, "node_modules/tap/node_modules/@babel/helper-module-transforms": { - "version": "7.16.0", + "version": "7.17.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/helper-module-imports": "^7.16.0", - "@babel/helper-replace-supers": "^7.16.0", - "@babel/helper-simple-access": "^7.16.0", - "@babel/helper-split-export-declaration": "^7.16.0", - "@babel/helper-validator-identifier": "^7.15.7", - "@babel/template": "^7.16.0", - "@babel/traverse": "^7.16.0", - "@babel/types": "^7.16.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/tap/node_modules/@babel/helper-optimise-call-expression": { - "version": "7.16.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "@babel/types": "^7.16.0" + "@babel/helper-environment-visitor": "^7.16.7", + "@babel/helper-module-imports": "^7.16.7", + "@babel/helper-simple-access": "^7.17.7", + "@babel/helper-split-export-declaration": "^7.16.7", + "@babel/helper-validator-identifier": "^7.16.7", + "@babel/template": "^7.16.7", + "@babel/traverse": "^7.17.3", + "@babel/types": "^7.17.0" }, "engines": { "node": ">=6.9.0" } }, "node_modules/tap/node_modules/@babel/helper-plugin-utils": { - "version": "7.14.5", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", @@ -7736,47 +11504,32 @@ "node": ">=6.9.0" } }, - "node_modules/tap/node_modules/@babel/helper-replace-supers": { - "version": "7.16.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "@babel/helper-member-expression-to-functions": "^7.16.0", - "@babel/helper-optimise-call-expression": "^7.16.0", - "@babel/traverse": "^7.16.0", - "@babel/types": "^7.16.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, "node_modules/tap/node_modules/@babel/helper-simple-access": { - "version": "7.16.0", + "version": "7.17.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/types": "^7.16.0" + "@babel/types": "^7.17.0" }, "engines": { "node": ">=6.9.0" } }, "node_modules/tap/node_modules/@babel/helper-split-export-declaration": { - "version": "7.16.0", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/types": "^7.16.0" + "@babel/types": "^7.16.7" }, "engines": { "node": ">=6.9.0" } }, "node_modules/tap/node_modules/@babel/helper-validator-identifier": { - "version": "7.15.7", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", @@ -7785,7 +11538,7 @@ } }, "node_modules/tap/node_modules/@babel/helper-validator-option": { - "version": "7.14.5", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", @@ -7794,26 +11547,26 @@ } }, "node_modules/tap/node_modules/@babel/helpers": { - "version": "7.16.3", + "version": "7.17.8", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/template": "^7.16.0", - "@babel/traverse": "^7.16.3", - "@babel/types": "^7.16.0" + "@babel/template": "^7.16.7", + "@babel/traverse": "^7.17.3", + "@babel/types": "^7.17.0" }, "engines": { "node": ">=6.9.0" } }, "node_modules/tap/node_modules/@babel/highlight": { - "version": "7.16.0", + "version": "7.16.10", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/helper-validator-identifier": "^7.15.7", + "@babel/helper-validator-identifier": "^7.16.7", "chalk": "^2.0.0", "js-tokens": "^4.0.0" }, @@ -7822,7 +11575,7 @@ } }, "node_modules/tap/node_modules/@babel/parser": { - "version": "7.16.3", + "version": "7.17.8", "dev": true, "inBundle": true, "license": "MIT", @@ -7834,16 +11587,16 @@ } }, "node_modules/tap/node_modules/@babel/plugin-proposal-object-rest-spread": { - "version": "7.16.0", + "version": "7.17.3", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/compat-data": "^7.16.0", - "@babel/helper-compilation-targets": "^7.16.0", - "@babel/helper-plugin-utils": "^7.14.5", + "@babel/compat-data": "^7.17.0", + "@babel/helper-compilation-targets": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", "@babel/plugin-syntax-object-rest-spread": "^7.8.3", - "@babel/plugin-transform-parameters": "^7.16.0" + "@babel/plugin-transform-parameters": "^7.16.7" }, "engines": { "node": ">=6.9.0" @@ -7853,12 +11606,12 @@ } }, "node_modules/tap/node_modules/@babel/plugin-syntax-jsx": { - "version": "7.16.0", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/helper-plugin-utils": "^7.14.5" + "@babel/helper-plugin-utils": "^7.16.7" }, "engines": { "node": ">=6.9.0" @@ -7880,12 +11633,12 @@ } }, "node_modules/tap/node_modules/@babel/plugin-transform-destructuring": { - "version": "7.16.0", + "version": "7.17.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/helper-plugin-utils": "^7.14.5" + "@babel/helper-plugin-utils": "^7.16.7" }, "engines": { "node": ">=6.9.0" @@ -7895,12 +11648,12 @@ } }, "node_modules/tap/node_modules/@babel/plugin-transform-parameters": { - "version": "7.16.3", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/helper-plugin-utils": "^7.14.5" + "@babel/helper-plugin-utils": "^7.16.7" }, "engines": { "node": ">=6.9.0" @@ -7910,16 +11663,16 @@ } }, "node_modules/tap/node_modules/@babel/plugin-transform-react-jsx": { - "version": "7.16.0", + "version": "7.17.3", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/helper-annotate-as-pure": "^7.16.0", - "@babel/helper-module-imports": "^7.16.0", - "@babel/helper-plugin-utils": "^7.14.5", - "@babel/plugin-syntax-jsx": "^7.16.0", - "@babel/types": "^7.16.0" + "@babel/helper-annotate-as-pure": "^7.16.7", + "@babel/helper-module-imports": "^7.16.7", + "@babel/helper-plugin-utils": "^7.16.7", + "@babel/plugin-syntax-jsx": "^7.16.7", + "@babel/types": "^7.17.0" }, "engines": { "node": ">=6.9.0" @@ -7929,32 +11682,33 @@ } }, "node_modules/tap/node_modules/@babel/template": { - "version": "7.16.0", + "version": "7.16.7", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/code-frame": "^7.16.0", - "@babel/parser": "^7.16.0", - "@babel/types": "^7.16.0" + "@babel/code-frame": "^7.16.7", + "@babel/parser": "^7.16.7", + "@babel/types": "^7.16.7" }, "engines": { "node": ">=6.9.0" } }, "node_modules/tap/node_modules/@babel/traverse": { - "version": "7.16.3", + "version": "7.17.3", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/code-frame": "^7.16.0", - "@babel/generator": "^7.16.0", - "@babel/helper-function-name": "^7.16.0", - "@babel/helper-hoist-variables": "^7.16.0", - "@babel/helper-split-export-declaration": "^7.16.0", - "@babel/parser": "^7.16.3", - "@babel/types": "^7.16.0", + "@babel/code-frame": "^7.16.7", + "@babel/generator": "^7.17.3", + "@babel/helper-environment-visitor": "^7.16.7", + "@babel/helper-function-name": "^7.16.7", + "@babel/helper-hoist-variables": "^7.16.7", + "@babel/helper-split-export-declaration": "^7.16.7", + "@babel/parser": "^7.17.3", + "@babel/types": "^7.17.0", "debug": "^4.1.0", "globals": "^11.1.0" }, @@ -7963,12 +11717,12 @@ } }, "node_modules/tap/node_modules/@babel/types": { - "version": "7.16.0", + "version": "7.17.0", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@babel/helper-validator-identifier": "^7.15.7", + "@babel/helper-validator-identifier": "^7.16.7", "to-fast-properties": "^2.0.0" }, "engines": { @@ -7995,37 +11749,29 @@ "node": ">=10" } }, - "node_modules/tap/node_modules/@isaacs/import-jsx/node_modules/caller-callsite": { - "version": "4.1.0", + "node_modules/tap/node_modules/@jridgewell/resolve-uri": { + "version": "3.0.5", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/tap/node_modules/@jridgewell/sourcemap-codec": { + "version": "1.4.11", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/tap/node_modules/@jridgewell/trace-mapping": { + "version": "0.3.4", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "callsites": "^3.1.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/tap/node_modules/@isaacs/import-jsx/node_modules/caller-path": { - "version": "3.0.1", - "dev": true, - "inBundle": true, - "license": "MIT", - "dependencies": { - "caller-callsite": "^4.1.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/tap/node_modules/@isaacs/import-jsx/node_modules/callsites": { - "version": "3.1.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=6" + "@jridgewell/resolve-uri": "^3.0.3", + "@jridgewell/sourcemap-codec": "^1.4.10" } }, "node_modules/tap/node_modules/@types/prop-types": { @@ -8035,7 +11781,7 @@ "license": "MIT" }, "node_modules/tap/node_modules/@types/react": { - "version": "17.0.34", + "version": "17.0.52", "dev": true, "inBundle": true, "license": "MIT", @@ -8149,15 +11895,25 @@ } }, "node_modules/tap/node_modules/browserslist": { - "version": "4.17.6", + "version": "4.20.2", "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + } + ], "inBundle": true, "license": "MIT", "dependencies": { - "caniuse-lite": "^1.0.30001274", - "electron-to-chromium": "^1.3.886", + "caniuse-lite": "^1.0.30001317", + "electron-to-chromium": "^1.4.84", "escalade": "^3.1.1", - "node-releases": "^2.0.1", + "node-releases": "^2.0.2", "picocolors": "^1.0.0" }, "bin": { @@ -8165,21 +11921,56 @@ }, "engines": { "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + } + }, + "node_modules/tap/node_modules/caller-callsite": { + "version": "4.1.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "callsites": "^3.1.0" }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/browserslist" + "engines": { + "node": ">=8" + } + }, + "node_modules/tap/node_modules/caller-path": { + "version": "3.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "caller-callsite": "^4.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/tap/node_modules/callsites": { + "version": "3.1.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=6" } }, "node_modules/tap/node_modules/caniuse-lite": { - "version": "1.0.30001279", + "version": "1.0.30001319", "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + } + ], "inBundle": true, - "license": "CC-BY-4.0", - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/browserslist" - } + "license": "CC-BY-4.0" }, "node_modules/tap/node_modules/cardinal": { "version": "2.1.1", @@ -8312,13 +12103,13 @@ } }, "node_modules/tap/node_modules/csstype": { - "version": "3.0.9", + "version": "3.0.11", "dev": true, "inBundle": true, "license": "MIT" }, "node_modules/tap/node_modules/debug": { - "version": "4.3.2", + "version": "4.3.4", "dev": true, "inBundle": true, "license": "MIT", @@ -8335,7 +12126,7 @@ } }, "node_modules/tap/node_modules/electron-to-chromium": { - "version": "1.3.893", + "version": "1.4.89", "dev": true, "inBundle": true, "license": "ISC" @@ -8429,7 +12220,7 @@ } }, "node_modules/tap/node_modules/glob": { - "version": "7.2.0", + "version": "7.2.3", "dev": true, "inBundle": true, "license": "ISC", @@ -8437,7 +12228,7 @@ "fs.realpath": "^1.0.0", "inflight": "^1.0.4", "inherits": "2", - "minimatch": "^3.0.4", + "minimatch": "^3.1.1", "once": "^1.3.0", "path-is-absolute": "^1.0.0" }, @@ -8644,13 +12435,10 @@ } }, "node_modules/tap/node_modules/json5": { - "version": "2.2.0", + "version": "2.2.1", "dev": true, "inBundle": true, "license": "MIT", - "dependencies": { - "minimist": "^1.2.5" - }, "bin": { "json5": "lib/cli.js" }, @@ -8713,7 +12501,7 @@ } }, "node_modules/tap/node_modules/minimatch": { - "version": "3.0.4", + "version": "3.1.2", "dev": true, "inBundle": true, "license": "ISC", @@ -8724,14 +12512,8 @@ "node": "*" } }, - "node_modules/tap/node_modules/minimist": { - "version": "1.2.5", - "dev": true, - "inBundle": true, - "license": "MIT" - }, "node_modules/tap/node_modules/minipass": { - "version": "3.1.5", + "version": "3.3.4", "dev": true, "inBundle": true, "license": "ISC", @@ -8749,7 +12531,7 @@ "license": "MIT" }, "node_modules/tap/node_modules/node-releases": { - "version": "2.0.1", + "version": "2.0.2", "dev": true, "inBundle": true, "license": "MIT" @@ -8891,7 +12673,7 @@ } }, "node_modules/tap/node_modules/react-devtools-core": { - "version": "4.21.0", + "version": "4.24.1", "dev": true, "inBundle": true, "license": "MIT", @@ -8995,7 +12777,7 @@ "license": "MIT" }, "node_modules/tap/node_modules/signal-exit": { - "version": "3.0.6", + "version": "3.0.7", "dev": true, "inBundle": true, "license": "ISC" @@ -9116,13 +12898,13 @@ } }, "node_modules/tap/node_modules/tap-parser": { - "version": "10.1.0", + "version": "11.0.2", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { "events-to-array": "^1.0.1", - "minipass": "^3.0.0", + "minipass": "^3.1.6", "tap-yaml": "^1.0.0" }, "bin": { @@ -9133,12 +12915,12 @@ } }, "node_modules/tap/node_modules/tap-yaml": { - "version": "1.0.0", + "version": "1.0.2", "dev": true, "inBundle": true, "license": "ISC", "dependencies": { - "yaml": "^1.5.0" + "yaml": "^1.10.2" } }, "node_modules/tap/node_modules/to-fast-properties": { @@ -9151,7 +12933,7 @@ } }, "node_modules/tap/node_modules/treport": { - "version": "3.0.2", + "version": "3.0.4", "dev": true, "inBundle": true, "license": "ISC", @@ -9161,7 +12943,8 @@ "chalk": "^3.0.0", "ink": "^3.2.0", "ms": "^2.1.2", - "tap-parser": "^10.0.1", + "tap-parser": "^11.0.0", + "tap-yaml": "^1.0.0", "unicode-length": "^2.0.2" }, "peerDependencies": { @@ -9278,6 +13061,21 @@ "node": ">=0.10.0" } }, + "node_modules/tap/node_modules/which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, "node_modules/tap/node_modules/widest-line": { "version": "3.1.0", "dev": true, @@ -9344,7 +13142,7 @@ "license": "ISC" }, "node_modules/tap/node_modules/ws": { - "version": "7.5.5", + "version": "7.5.7", "dev": true, "inBundle": true, "license": "MIT", @@ -9392,54 +13190,20 @@ } }, "node_modules/tar": { - "version": "6.1.11", - "resolved": "https://registry.npmjs.org/tar/-/tar-6.1.11.tgz", - "integrity": "sha512-an/KZQzQUkZCkuoAA64hM92X0Urb6VpRhAFllDzz44U2mcD5scmT3zBc4VgVpkugF580+DQn8eAFSyoQt0tznA==", + "version": "6.1.13", + "resolved": "https://registry.npmjs.org/tar/-/tar-6.1.13.tgz", + "integrity": "sha512-jdIBIN6LTIe2jqzay/2vtYLlBHa3JF42ot3h1dW8Q0PaAG4v8rm0cvpVePtau5C6OKXGGcgO9q2AMNSWxiLqKw==", "inBundle": true, "dependencies": { "chownr": "^2.0.0", "fs-minipass": "^2.0.0", - "minipass": "^3.0.0", + "minipass": "^4.0.0", "minizlib": "^2.1.1", "mkdirp": "^1.0.3", "yallist": "^4.0.0" }, "engines": { - "node": ">= 10" - } - }, - "node_modules/tar-fs": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.1.tgz", - "integrity": "sha512-V0r2Y9scmbDRLCNex/+hYzvp/zyYjvFbHPNgVTKfQvVrb6guiE/fxP+XblDNR011utopbkex2nM4dHNV6GDsng==", - "dev": true, - "dependencies": { - "chownr": "^1.1.1", - "mkdirp-classic": "^0.5.2", - "pump": "^3.0.0", - "tar-stream": "^2.1.4" - } - }, - "node_modules/tar-fs/node_modules/chownr": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.4.tgz", - "integrity": "sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==", - "dev": true - }, - "node_modules/tar-stream": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-2.2.0.tgz", - "integrity": "sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==", - "dev": true, - "dependencies": { - "bl": "^4.0.3", - "end-of-stream": "^1.4.1", - "fs-constants": "^1.0.0", - "inherits": "^2.0.3", - "readable-stream": "^3.1.1" - }, - "engines": { - "node": ">=6" + "node": ">=10" } }, "node_modules/tcompare": { @@ -9477,22 +13241,86 @@ "node": ">=8" } }, + "node_modules/test-exclude/node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/test-exclude/node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "dev": true, + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/test-exclude/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/text-extensions": { + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/text-extensions/-/text-extensions-1.9.0.tgz", + "integrity": "sha512-wiBrwC1EhBelW12Zy26JeOUkQ5mRu+5o8rpsJk5+2t+Y5vE7e842qtZDQ2g1NpX/29HdyFeJ4nSIhI47ENSxlQ==", + "dev": true, + "engines": { + "node": ">=0.10" + } + }, "node_modules/text-table": { "version": "0.2.0", - "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", - "integrity": "sha1-f17oI66AUgfACvLfSoTsP8+lcLQ=", - "inBundle": true + "inBundle": true, + "license": "MIT" + }, + "node_modules/through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==", + "dev": true + }, + "node_modules/through2": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/through2/-/through2-4.0.2.tgz", + "integrity": "sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==", + "dev": true, + "dependencies": { + "readable-stream": "3" + } }, "node_modules/tiny-relative-date": { "version": "1.3.0", - "resolved": "https://registry.npmjs.org/tiny-relative-date/-/tiny-relative-date-1.3.0.tgz", - "integrity": "sha512-MOQHpzllWxDCHHaDno30hhLfbouoYlOI8YlMNtvKe1zXbjEVhbcEovQxvZrPvtiYW630GQDoMMarCnjfyfHA+A==", - "inBundle": true + "inBundle": true, + "license": "MIT" }, "node_modules/to-fast-properties": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", - "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", + "integrity": "sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==", "dev": true, "engines": { "node": ">=4" @@ -9511,63 +13339,72 @@ } }, "node_modules/tough-cookie": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-4.0.0.tgz", - "integrity": "sha512-tHdtEpQCMrc1YLrMaqXXcj6AxhYi/xgit6mZu1+EDWUn+qhUf8wMQoFIy9NXuq23zAwtcB0t/MjACGR18pcRbg==", + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-4.1.2.tgz", + "integrity": "sha512-G9fqXWoYFZgTc2z8Q5zaHy/vJMjm+WV0AkAeHxVCQiEB1b+dGvWzFW6QV07cY5jQ5gRkeid2qIkzkxUnmoQZUQ==", "dev": true, "dependencies": { "psl": "^1.1.33", "punycode": "^2.1.1", - "universalify": "^0.1.2" + "universalify": "^0.2.0", + "url-parse": "^1.5.3" }, "engines": { "node": ">=6" } }, - "node_modules/tr46": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/tr46/-/tr46-3.0.0.tgz", - "integrity": "sha512-l7FvfAHlcmulp8kr+flpQZmVwtu7nfRV7NZujtN0OqES8EL4O4e0qqzL0DC5gAvx/ZC/9lk6rhcUwYvkBnBnYA==", + "node_modules/tough-cookie/node_modules/universalify": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.2.0.tgz", + "integrity": "sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg==", "dev": true, - "dependencies": { - "punycode": "^2.1.1" - }, "engines": { - "node": ">=12" + "node": ">= 4.0.0" } }, - "node_modules/treeverse": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/treeverse/-/treeverse-1.0.4.tgz", - "integrity": "sha512-whw60l7r+8ZU8Tu/Uc2yxtc4ZTZbR/PF3u1IPNKGQ6p8EICLb3Z2lAgoqw9bqYd8IkgnsaOcLzYHFckjqNsf0g==", - "inBundle": true - }, - "node_modules/trim": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/trim/-/trim-0.0.1.tgz", - "integrity": "sha1-WFhUf2spB1fulczMZm+1AITEYN0=", + "node_modules/tr46": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==", "dev": true }, - "node_modules/trim-trailing-lines": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/trim-trailing-lines/-/trim-trailing-lines-1.1.4.tgz", - "integrity": "sha512-rjUWSqnfTNrjbB9NQWfPMH/xRK1deHeGsHoVfpxJ++XeYXE0d6B1En37AHfw3jtfTU7dzMzZL2jjpe8Qb5gLIQ==", + "node_modules/treeverse": { + "version": "3.0.0", + "inBundle": true, + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/trim-lines": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/trim-lines/-/trim-lines-3.0.1.tgz", + "integrity": "sha512-kRj8B+YHZCc9kQYdWfJB2/oUl9rA99qbowYYBtr4ui4mZyAQ2JpvVBd/6U2YloATfqBhBTSMhTpgBHtU0Mf3Rg==", "dev": true, "funding": { "type": "github", "url": "https://github.com/sponsors/wooorm" } }, + "node_modules/trim-newlines": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/trim-newlines/-/trim-newlines-3.0.1.tgz", + "integrity": "sha512-c1PTsA3tYrIsLGkJkzHF+w9F2EyxfXGo4UyJc4pFL++FMjnq0HJS69T3M7d//gKrFKwy429bouPescbjecU+Zw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, "node_modules/trivial-deferred": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/trivial-deferred/-/trivial-deferred-1.0.1.tgz", - "integrity": "sha1-N21NKdlR1jaKb3oK6FwvTV4GWPM=", + "integrity": "sha512-dagAKX7vaesNNAwOc9Np9C2mJ+7YopF4lk+jE2JML9ta4kZ91Y6UruJNH65bLRYoUROD8EY+Pmi44qQWwXR7sw==", "dev": true }, "node_modules/trough": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/trough/-/trough-1.0.5.tgz", - "integrity": "sha512-rvuRbTarPXmMb79SmzEp8aqXNKcK+y0XaB298IXueQ8I2PsrATcPBCSPyK/dDNa2iWOhKlfNnOjdAOTBU/nkFA==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/trough/-/trough-2.1.0.tgz", + "integrity": "sha512-AqTiAOLcj85xS7vQ8QkAV41hPDIJ71XJB4RCUrzo/1GM2CQwhkJGaf9Hgr7BOugMRpgGUrqRg/DrBDl4H40+8g==", "dev": true, "funding": { "type": "github", @@ -9575,30 +13412,46 @@ } }, "node_modules/ts-node": { - "version": "8.10.2", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", - "integrity": "sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA==", + "version": "10.9.1", + "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz", + "integrity": "sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==", "dev": true, - "optional": true, - "peer": true, "dependencies": { + "@cspotcode/source-map-support": "^0.8.0", + "@tsconfig/node10": "^1.0.7", + "@tsconfig/node12": "^1.0.7", + "@tsconfig/node14": "^1.0.0", + "@tsconfig/node16": "^1.0.2", + "acorn": "^8.4.1", + "acorn-walk": "^8.1.1", "arg": "^4.1.0", + "create-require": "^1.1.0", "diff": "^4.0.1", "make-error": "^1.1.1", - "source-map-support": "^0.5.17", + "v8-compile-cache-lib": "^3.0.1", "yn": "3.1.1" }, "bin": { "ts-node": "dist/bin.js", + "ts-node-cwd": "dist/bin-cwd.js", + "ts-node-esm": "dist/bin-esm.js", "ts-node-script": "dist/bin-script.js", "ts-node-transpile-only": "dist/bin-transpile.js", "ts-script": "dist/bin-script-deprecated.js" }, - "engines": { - "node": ">=6.0.0" - }, "peerDependencies": { + "@swc/core": ">=1.2.50", + "@swc/wasm": ">=1.2.50", + "@types/node": "*", "typescript": ">=2.7" + }, + "peerDependenciesMeta": { + "@swc/core": { + "optional": true + }, + "@swc/wasm": { + "optional": true + } } }, "node_modules/ts-node/node_modules/diff": { @@ -9606,35 +13459,61 @@ "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", "dev": true, - "optional": true, - "peer": true, "engines": { "node": ">=0.3.1" } }, - "node_modules/tunnel-agent": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", - "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", + "node_modules/tsconfig-paths": { + "version": "3.14.1", + "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.14.1.tgz", + "integrity": "sha512-fxDhWnFSLt3VuTwtvJt5fpwxBHg5AdKWMsgcPOOIilyjymcYVZoCQF8fvFRezCNfblEXmi+PcM1eYHeOAgXCOQ==", "dev": true, + "peer": true, "dependencies": { - "safe-buffer": "^5.0.1" - }, - "engines": { - "node": "*" + "@types/json5": "^0.0.29", + "json5": "^1.0.1", + "minimist": "^1.2.6", + "strip-bom": "^3.0.0" } }, - "node_modules/tweetnacl": { - "version": "0.14.5", - "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", - "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=", - "dev": true + "node_modules/tsconfig-paths/node_modules/json5": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz", + "integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==", + "dev": true, + "peer": true, + "dependencies": { + "minimist": "^1.2.0" + }, + "bin": { + "json5": "lib/cli.js" + } + }, + "node_modules/tsconfig-paths/node_modules/strip-bom": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", + "integrity": "sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==", + "dev": true, + "peer": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/tunnel": { + "version": "0.0.6", + "resolved": "https://registry.npmjs.org/tunnel/-/tunnel-0.0.6.tgz", + "integrity": "sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg==", + "dev": true, + "engines": { + "node": ">=0.6.11 <=0.7.0 || >=0.7.3" + } }, "node_modules/type-check": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==", "dev": true, + "peer": true, "dependencies": { "prelude-ls": "^1.2.1" }, @@ -9642,51 +13521,33 @@ "node": ">= 0.8.0" } }, - "node_modules/type-detect": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", - "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", - "dev": true, - "engines": { - "node": ">=4" - } - }, "node_modules/type-fest": { - "version": "0.8.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", - "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", + "version": "0.20.2", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", + "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", "dev": true, + "peer": true, "engines": { - "node": ">=8" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/typedarray-to-buffer": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-4.0.0.tgz", - "integrity": "sha512-6dOYeZfS3O9RtRD1caom0sMxgK59b27+IwoNy8RDPsmslSGOyU+mpTamlaIW7aNKi90ZQZ9DFaZL3YRoiSCULQ==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "inBundle": true + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz", + "integrity": "sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==", + "dev": true, + "dependencies": { + "is-typedarray": "^1.0.0" + } }, "node_modules/typescript": { - "version": "3.9.10", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.10.tgz", - "integrity": "sha512-w6fIxVE/H1PkLKcCPsFqKE7Kv7QUwhU8qQY2MueZXWx5cPZdwFupLgKK3vntcK98BtNHZtAF4LA/yl2a7k8R6Q==", + "version": "4.8.4", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.4.tgz", + "integrity": "sha512-QCh+85mCy+h0IGff8r5XWzOVSbBO+KfeYrMQh7NJ58QujwcE22u+NUSmUxqF+un70P9GXKxa2HCNiTTMJknyjQ==", "dev": true, - "optional": true, - "peer": true, "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -9695,95 +13556,120 @@ "node": ">=4.2.0" } }, - "node_modules/unbox-primitive": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.1.tgz", - "integrity": "sha512-tZU/3NqK3dA5gpE1KtyiJUrEB0lxnGkMFHptJ7q6ewdZ8s12QrODwNbhIJStmJkd1QDXa1NRA8aF2A1zk/Ypyw==", + "node_modules/uglify-js": { + "version": "3.17.4", + "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.17.4.tgz", + "integrity": "sha512-T9q82TJI9e/C1TAxYvfb16xO120tMVFZrGA3f9/P4424DNu6ypK103y0GPFVa17yotwSyZW5iYXgjYHkGrJW/g==", "dev": true, + "optional": true, + "bin": { + "uglifyjs": "bin/uglifyjs" + }, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/unbox-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", + "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "dev": true, + "peer": true, "dependencies": { - "function-bind": "^1.1.1", - "has-bigints": "^1.0.1", - "has-symbols": "^1.0.2", + "call-bind": "^1.0.2", + "has-bigints": "^1.0.2", + "has-symbols": "^1.0.3", "which-boxed-primitive": "^1.0.2" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/unherit": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/unherit/-/unherit-1.1.3.tgz", - "integrity": "sha512-Ft16BJcnapDKp0+J/rqFC3Rrk6Y/Ng4nzsC028k2jdDII/rdZ7Wd3pPT/6+vIIxRagwRc9K0IUX0Ra4fKvw+WQ==", - "dev": true, - "dependencies": { - "inherits": "^2.0.0", - "xtend": "^4.0.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } + "node_modules/underscore": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.12.1.tgz", + "integrity": "sha512-hEQt0+ZLDVUMhebKxL4x1BTtDY7bavVofhZ9KZ4aI26X9SRaE+Y3m83XUL1UP2jn8ynjndwCCpEHdUG+9pP1Tw==", + "dev": true }, "node_modules/unicode-length": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/unicode-length/-/unicode-length-2.0.2.tgz", - "integrity": "sha512-Ph/j1VbS3/r77nhoY2WU0GWGjVYOHL3xpKp0y/Eq2e5r0mT/6b649vm7KFO6RdAdrZkYLdxphYVgvODxPB+Ebg==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/unicode-length/-/unicode-length-2.1.0.tgz", + "integrity": "sha512-4bV582zTV9Q02RXBxSUMiuN/KHo5w4aTojuKTNT96DIKps/SIawFp7cS5Mu25VuY1AioGXrmYyzKZUzh8OqoUw==", "dev": true, "dependencies": { - "punycode": "^2.0.0", - "strip-ansi": "^3.0.1" + "punycode": "^2.0.0" } }, "node_modules/unified": { - "version": "9.2.0", - "resolved": "https://registry.npmjs.org/unified/-/unified-9.2.0.tgz", - "integrity": "sha512-vx2Z0vY+a3YoTj8+pttM3tiJHCwY5UFbYdiWrwBEbHmK8pvsPj2rtAX2BFfgXen8T39CJWblWRDT4L5WGXtDdg==", + "version": "10.1.2", + "resolved": "https://registry.npmjs.org/unified/-/unified-10.1.2.tgz", + "integrity": "sha512-pUSWAi/RAnVy1Pif2kAoeWNBa3JVrx0MId2LASj8G+7AiHWoKZNTomq6LG326T68U7/e263X6fTdcXIy7XnF7Q==", "dev": true, "dependencies": { - "bail": "^1.0.0", + "@types/unist": "^2.0.0", + "bail": "^2.0.0", "extend": "^3.0.0", "is-buffer": "^2.0.0", - "is-plain-obj": "^2.0.0", - "trough": "^1.0.0", - "vfile": "^4.0.0" + "is-plain-obj": "^4.0.0", + "trough": "^2.0.0", + "vfile": "^5.0.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/unified" } }, + "node_modules/unified/node_modules/is-plain-obj": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-4.1.0.tgz", + "integrity": "sha512-+Pgi+vMuUNkJyExiMBt5IlFoMyKnr5zhJ4Uspz58WOhBF5QoIZkFyNHIbBAtHwzVAgk5RtndVNsDRN61/mmDqg==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/unique-filename": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/unique-filename/-/unique-filename-1.1.1.tgz", - "integrity": "sha512-Vmp0jIp2ln35UTXuryvjzkjGdRyf9b2lTXuSYUiPmzRcl3FDtYqAwOnTJkAngD9SWhnoJzDbTKwaOrZ+STtxNQ==", + "version": "3.0.0", "inBundle": true, + "license": "ISC", "dependencies": { - "unique-slug": "^2.0.0" + "unique-slug": "^4.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/unique-slug": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/unique-slug/-/unique-slug-2.0.2.tgz", - "integrity": "sha512-zoWr9ObaxALD3DOPfjPSqxt4fnZiWblxHIgeWqW8x7UqDzEtHEQLzji2cuJYQFCU6KmoJikOYAZlrTHHebjx2w==", + "version": "4.0.0", "inBundle": true, + "license": "ISC", "dependencies": { "imurmurhash": "^0.1.4" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/unist-builder": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/unist-builder/-/unist-builder-2.0.3.tgz", - "integrity": "sha512-f98yt5pnlMWlzP539tPc4grGMsFaQQlP/vM396b00jngsiINumNmsY8rkXjfoi1c6QaM8nQ3vaGDuoKWbe/1Uw==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/unist-builder/-/unist-builder-3.0.0.tgz", + "integrity": "sha512-GFxmfEAa0vi9i5sd0R2kcrI9ks0r82NasRq5QHh2ysGngrc6GiqD5CDf1FjPenY4vApmFASBIIlk/jj5J5YbmQ==", "dev": true, + "dependencies": { + "@types/unist": "^2.0.0" + }, "funding": { "type": "opencollective", "url": "https://opencollective.com/unified" } }, "node_modules/unist-util-generated": { - "version": "1.1.6", - "resolved": "https://registry.npmjs.org/unist-util-generated/-/unist-util-generated-1.1.6.tgz", - "integrity": "sha512-cln2Mm1/CZzN5ttGK7vkoGw+RZ8VcUH6BtGbq98DDtRGquAAOXig1mrBQYelOwMXYS8rK+vZDyyojSjp7JX+Lg==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/unist-util-generated/-/unist-util-generated-2.0.0.tgz", + "integrity": "sha512-TiWE6DVtVe7Ye2QxOVW9kqybs6cZexNwTwSMVgkfjEReqy/xwGpAXb99OxktoWwmL+Z+Epb0Dn8/GNDYP1wnUw==", "dev": true, "funding": { "type": "opencollective", @@ -9791,9 +13677,9 @@ } }, "node_modules/unist-util-is": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-4.1.0.tgz", - "integrity": "sha512-ZOQSsnce92GrxSqlnEEseX0gi7GH9zTJZ0p9dtu87WRb/37mMPO2Ilx1s/t9vBHrFhbgweUwb+t7cIn5dxPhZg==", + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-5.1.1.tgz", + "integrity": "sha512-F5CZ68eYzuSvJjGhCLPL3cYx45IxkqXSetCcRgUXtbcm50X2L9oOWQlfUfDdAf+6Pd27YDblBfdtmsThXmwpbQ==", "dev": true, "funding": { "type": "opencollective", @@ -9801,35 +13687,12 @@ } }, "node_modules/unist-util-position": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/unist-util-position/-/unist-util-position-3.1.0.tgz", - "integrity": "sha512-w+PkwCbYSFw8vpgWD0v7zRCl1FpY3fjDSQ3/N/wNd9Ffa4gPi8+4keqt99N3XW6F99t/mUzp2xAhNmfKWp95QA==", - "dev": true, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unist-util-remove": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/unist-util-remove/-/unist-util-remove-2.1.0.tgz", - "integrity": "sha512-J8NYPyBm4baYLdCbjmf1bhPu45Cr1MWTm77qd9istEkzWpnN6O9tMsEbB2JhNnBCqGENRqEWomQ+He6au0B27Q==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/unist-util-position/-/unist-util-position-4.0.3.tgz", + "integrity": "sha512-p/5EMGIa1qwbXjA+QgcBXaPWjSnZfQ2Sc3yBEEfgPwsEmJd8Qh+DSk3LGnmOM4S1bY2C0AjmMnB8RuEYxpPwXQ==", "dev": true, "dependencies": { - "unist-util-is": "^4.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, - "node_modules/unist-util-remove-position": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/unist-util-remove-position/-/unist-util-remove-position-2.0.1.tgz", - "integrity": "sha512-fDZsLYIe2uT+oGFnuZmy73K6ZxOPG/Qcm+w7jbEjaFcJgbQ6cqjs/eSPzXhsmGpAsWPkqZM9pYjww5QTn3LHMA==", - "dev": true, - "dependencies": { - "unist-util-visit": "^2.0.0" + "@types/unist": "^2.0.0" }, "funding": { "type": "opencollective", @@ -9837,12 +13700,12 @@ } }, "node_modules/unist-util-stringify-position": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/unist-util-stringify-position/-/unist-util-stringify-position-2.0.3.tgz", - "integrity": "sha512-3faScn5I+hy9VleOq/qNbAd6pAx7iH5jYBMS9I1HgQVijz/4mv5Bvw5iw1sC/90CODiKo81G/ps8AJrISn687g==", + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/unist-util-stringify-position/-/unist-util-stringify-position-3.0.2.tgz", + "integrity": "sha512-7A6eiDCs9UtjcwZOcCpM4aPII3bAAGv13E96IkawkOAW0OhH+yRxtY0lzo8KiHpzEMfH7Q+FizUmwp8Iqy5EWg==", "dev": true, "dependencies": { - "@types/unist": "^2.0.2" + "@types/unist": "^2.0.0" }, "funding": { "type": "opencollective", @@ -9878,13 +13741,65 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/unist-util-visit-parents/node_modules/unist-util-is": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-4.1.0.tgz", + "integrity": "sha512-ZOQSsnce92GrxSqlnEEseX0gi7GH9zTJZ0p9dtu87WRb/37mMPO2Ilx1s/t9vBHrFhbgweUwb+t7cIn5dxPhZg==", + "dev": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/unist-util-visit/node_modules/unist-util-is": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-4.1.0.tgz", + "integrity": "sha512-ZOQSsnce92GrxSqlnEEseX0gi7GH9zTJZ0p9dtu87WRb/37mMPO2Ilx1s/t9vBHrFhbgweUwb+t7cIn5dxPhZg==", + "dev": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" + } + }, + "node_modules/universal-user-agent": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-6.0.0.tgz", + "integrity": "sha512-isyNax3wXoKaulPDZWHQqbmIx1k2tb9fb3GGDBRxCscfYV2Ch7WxPArBsFEG8s/safwXTT7H4QGhaIkTp9447w==", + "dev": true + }, "node_modules/universalify": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz", - "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.0.tgz", + "integrity": "sha512-hAZsKq7Yy11Zu1DE0OzWjw7nnLZmJZYTDZZyEFHZdUhV8FkH5MCfoU1XMaxXovpyW5nq5scPqq0ZDP9Zyl04oQ==", "dev": true, "engines": { - "node": ">= 4.0.0" + "node": ">= 10.0.0" + } + }, + "node_modules/update-browserslist-db": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.10.tgz", + "integrity": "sha512-OztqDenkfFkbSG+tRxBeAnCVPckDBcvibKd35yDONx6OU8N7sqgwc7rCbkJ/WcYtVRZ4ba68d6byhC21GFh7sQ==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + } + ], + "dependencies": { + "escalade": "^3.1.1", + "picocolors": "^1.0.0" + }, + "bin": { + "browserslist-lint": "cli.js" + }, + "peerDependencies": { + "browserslist": ">= 4.21.0" } }, "node_modules/uri-js": { @@ -9896,172 +13811,133 @@ "punycode": "^2.1.0" } }, - "node_modules/util-deprecate": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", - "inBundle": true - }, - "node_modules/util-promisify": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/util-promisify/-/util-promisify-2.1.0.tgz", - "integrity": "sha1-PCI2R2xNMsX/PEcAKt18E7moKlM=", + "node_modules/url-parse": { + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", + "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==", "dev": true, "dependencies": { - "object.getownpropertydescriptors": "^2.0.3" + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" } }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "inBundle": true, + "license": "MIT" + }, "node_modules/uuid": { - "version": "3.4.0", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz", - "integrity": "sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==", - "deprecated": "Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.", + "version": "8.3.2", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", + "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==", "dev": true, "bin": { - "uuid": "bin/uuid" + "uuid": "dist/bin/uuid" } }, - "node_modules/v8-compile-cache": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz", - "integrity": "sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA==", + "node_modules/uvu": { + "version": "0.5.6", + "resolved": "https://registry.npmjs.org/uvu/-/uvu-0.5.6.tgz", + "integrity": "sha512-+g8ENReyr8YsOc6fv/NVJs2vFdHBnBNdfE49rshrTzDWOlUx4Gq7KOS2GD8eqhy2j+Ejq29+SbKH8yjkAqXqoA==", + "dev": true, + "dependencies": { + "dequal": "^2.0.0", + "diff": "^5.0.0", + "kleur": "^4.0.3", + "sade": "^1.7.3" + }, + "bin": { + "uvu": "bin.js" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/v8-compile-cache-lib": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz", + "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==", "dev": true }, "node_modules/validate-npm-package-license": { "version": "3.0.4", - "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz", - "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==", "inBundle": true, + "license": "Apache-2.0", "dependencies": { "spdx-correct": "^3.0.0", "spdx-expression-parse": "^3.0.0" } }, "node_modules/validate-npm-package-name": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/validate-npm-package-name/-/validate-npm-package-name-3.0.0.tgz", - "integrity": "sha1-X6kS2B630MdK/BQN5zF/DKffQ34=", + "version": "5.0.0", "inBundle": true, + "license": "ISC", "dependencies": { - "builtins": "^1.0.3" - } - }, - "node_modules/verror": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", - "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=", - "dev": true, - "engines": [ - "node >=0.6.0" - ], - "dependencies": { - "assert-plus": "^1.0.0", - "core-util-is": "1.0.2", - "extsprintf": "^1.2.0" + "builtins": "^5.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/vfile": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/vfile/-/vfile-4.2.1.tgz", - "integrity": "sha512-O6AE4OskCG5S1emQ/4gl8zK586RqA3srz3nfK/Viy0UPToBc5Trp9BVFb1u0CjsKrAWwnpr4ifM/KBXPWwJbCA==", + "version": "5.3.5", + "resolved": "https://registry.npmjs.org/vfile/-/vfile-5.3.5.tgz", + "integrity": "sha512-U1ho2ga33eZ8y8pkbQLH54uKqGhFJ6GYIHnnG5AhRpAh3OWjkrRHKa/KogbmQn8We+c0KVV3rTOgR9V/WowbXQ==", "dev": true, "dependencies": { "@types/unist": "^2.0.0", "is-buffer": "^2.0.0", - "unist-util-stringify-position": "^2.0.0", - "vfile-message": "^2.0.0" + "unist-util-stringify-position": "^3.0.0", + "vfile-message": "^3.0.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/unified" } }, - "node_modules/vfile-location": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/vfile-location/-/vfile-location-3.2.0.tgz", - "integrity": "sha512-aLEIZKv/oxuCDZ8lkJGhuhztf/BW4M+iHdCwglA/eWc+vtuRFJj8EtgceYFX4LRjOhCAAiNHsKGssC6onJ+jbA==", - "dev": true, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" - } - }, "node_modules/vfile-message": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/vfile-message/-/vfile-message-2.0.4.tgz", - "integrity": "sha512-DjssxRGkMvifUOJre00juHoP9DPWuzjxKuMDrhNbk2TdaYYBNMStsNhEOt3idrtI12VQYM/1+iM0KOzXi4pxwQ==", + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/vfile-message/-/vfile-message-3.1.2.tgz", + "integrity": "sha512-QjSNP6Yxzyycd4SVOtmKKyTsSvClqBPJcd00Z0zuPj3hOIjg0rUPG6DbFGPvUKRgYyaIWLPKpuEclcuvb3H8qA==", "dev": true, "dependencies": { "@types/unist": "^2.0.0", - "unist-util-stringify-position": "^2.0.0" + "unist-util-stringify-position": "^3.0.0" }, "funding": { "type": "opencollective", "url": "https://opencollective.com/unified" } }, - "node_modules/vlq": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/vlq/-/vlq-0.2.3.tgz", - "integrity": "sha512-DRibZL6DsNhIgYQ+wNdWDL2SL3bKPlVrRiBqV5yuMm++op8W4kGFtaQfCs4KEJn0wBZcHVHJ3eoywX8983k1ow==", - "dev": true, - "optional": true, - "peer": true - }, - "node_modules/w3c-hr-time": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/w3c-hr-time/-/w3c-hr-time-1.0.2.tgz", - "integrity": "sha512-z8P5DvDNjKDoFIHK7q8r8lackT6l+jo/Ye3HOle7l9nICP9lf1Ci25fy9vHd0JOWewkIFzXIEig3TdKT7JQ5fQ==", - "dev": true, - "dependencies": { - "browser-process-hrtime": "^1.0.0" - } - }, "node_modules/w3c-xmlserializer": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-3.0.0.tgz", - "integrity": "sha512-3WFqGEgSXIyGhOmAFtlicJNMjEps8b1MG31NCA0/vOF9+nKMUW1ckhi9cnNHmf88Rzw5V+dwIwsm2C7X8k9aQg==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-4.0.0.tgz", + "integrity": "sha512-d+BFHzbiCx6zGfz0HyQ6Rg69w9k19nviJspaj4yNscGjrHu94sVP+aRm75yEbCh+r2/yR+7q6hux9LVtbuTGBw==", "dev": true, "dependencies": { "xml-name-validator": "^4.0.0" }, "engines": { - "node": ">=12" + "node": ">=14" } }, "node_modules/walk-up-path": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/walk-up-path/-/walk-up-path-1.0.0.tgz", - "integrity": "sha512-hwj/qMDUEjCU5h0xr90KGCf0tg0/LgJbmOWgrWKYlcJZM7XvquvUJZ0G/HMGr7F7OQMOUuPHWP9JpriinkAlkg==", - "inBundle": true + "license": "ISC" }, "node_modules/wcwidth": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/wcwidth/-/wcwidth-1.0.1.tgz", - "integrity": "sha1-8LDc+RW8X/FSivrbLA4XtTLaL+g=", "inBundle": true, + "license": "MIT", "dependencies": { "defaults": "^1.0.3" } }, - "node_modules/web-namespaces": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/web-namespaces/-/web-namespaces-1.1.4.tgz", - "integrity": "sha512-wYxSGajtmoP4WxfejAPIr4l0fVh+jeMXZb08wNc0tMg6xsfZXj3cECqIK0G7ZAqUq0PP8WlMDtaOGVBTAWztNw==", - "dev": true, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, "node_modules/webidl-conversions": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", - "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", - "dev": true, - "engines": { - "node": ">=12" - } + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==", + "dev": true }, "node_modules/whatwg-encoding": { "version": "2.0.0", @@ -10085,31 +13961,27 @@ } }, "node_modules/whatwg-url": { - "version": "10.0.0", - "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-10.0.0.tgz", - "integrity": "sha512-CLxxCmdUby142H5FZzn4D8ikO1cmypvXVQktsgosNy4a4BHrDHeciBBGZhb0bNoR5/MltoCatso+vFjjGx8t0w==", + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", + "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", "dev": true, "dependencies": { - "tr46": "^3.0.0", - "webidl-conversions": "^7.0.0" - }, - "engines": { - "node": ">=12" + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" } }, "node_modules/which": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", - "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "version": "3.0.0", "inBundle": true, + "license": "ISC", "dependencies": { "isexe": "^2.0.0" }, "bin": { - "node-which": "bin/node-which" + "node-which": "bin/which.js" }, "engines": { - "node": ">= 8" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "node_modules/which-boxed-primitive": { @@ -10117,6 +13989,7 @@ "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", "dev": true, + "peer": true, "dependencies": { "is-bigint": "^1.0.1", "is-boolean-object": "^1.1.0", @@ -10131,14 +14004,13 @@ "node_modules/which-module": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", - "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", + "integrity": "sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==", "dev": true }, "node_modules/wide-align": { "version": "1.1.5", - "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.5.tgz", - "integrity": "sha512-eDMORYaPNZ4sQIuuYPDHdQvf4gyCF9rEEV/yPxGfwPkRodwEgiMUUXTx/dex+Me0wxx53S+NgUHaP7y3MGlDmg==", "inBundle": true, + "license": "ISC", "dependencies": { "string-width": "^1.0.2 || 2 || 3 || 4" } @@ -10152,6 +14024,12 @@ "node": ">=0.10.0" } }, + "node_modules/wordwrap": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", + "integrity": "sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==", + "dev": true + }, "node_modules/wrap-ansi": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", @@ -10169,75 +14047,109 @@ "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "node_modules/wrap-ansi/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/wrap-ansi/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/wrap-ansi/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/wrap-ansi/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/wrappy": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", - "inBundle": true + "inBundle": true, + "license": "ISC" }, "node_modules/write-file-atomic": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-4.0.0.tgz", - "integrity": "sha512-JhcWoKffJNF7ivO9yflBhc7tn3wKnokMUfWpBriM9yCXj4ePQnRPcWglBkkg1AHC8nsW/EfxwwhqsLtOy59djA==", + "version": "5.0.0", "inBundle": true, + "license": "ISC", "dependencies": { "imurmurhash": "^0.1.4", - "is-typedarray": "^1.0.0", - "signal-exit": "^3.0.2", - "typedarray-to-buffer": "^4.0.0" + "signal-exit": "^3.0.7" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/write-json-file": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/write-json-file/-/write-json-file-3.2.0.tgz", + "integrity": "sha512-3xZqT7Byc2uORAatYiP3DHUUAVEkNOswEWNs9H5KXiicRTvzYzYqKjYc4G7p+8pltvAw641lVByKVtMpf+4sYQ==", + "dev": true, + "dependencies": { + "detect-indent": "^5.0.0", + "graceful-fs": "^4.1.15", + "make-dir": "^2.1.0", + "pify": "^4.0.1", + "sort-keys": "^2.0.0", + "write-file-atomic": "^2.4.2" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/write-json-file/node_modules/detect-indent": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/detect-indent/-/detect-indent-5.0.0.tgz", + "integrity": "sha512-rlpvsxUtM0PQvy9iZe640/IWwWYyBsTApREbA1pHOpmOUIl9MkP/U4z7vTtg4Oaojvqhxt7sdufnT0EzGaR31g==", + "dev": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/write-json-file/node_modules/make-dir": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-2.1.0.tgz", + "integrity": "sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA==", + "dev": true, + "dependencies": { + "pify": "^4.0.1", + "semver": "^5.6.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/write-json-file/node_modules/semver": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", + "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", + "dev": true, + "bin": { + "semver": "bin/semver" + } + }, + "node_modules/write-json-file/node_modules/write-file-atomic": { + "version": "2.4.3", + "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.4.3.tgz", + "integrity": "sha512-GaETH5wwsX+GcnzhPgKcKjJ6M2Cq3/iZp1WyY/X1CSqrW+jVNM9Y7D8EC2sM4ZG/V8wZlSniJnCKWPmBYAucRQ==", + "dev": true, + "dependencies": { + "graceful-fs": "^4.1.11", + "imurmurhash": "^0.1.4", + "signal-exit": "^3.0.2" + } + }, + "node_modules/write-pkg": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/write-pkg/-/write-pkg-4.0.0.tgz", + "integrity": "sha512-v2UQ+50TNf2rNHJ8NyWttfm/EJUBWMJcx6ZTYZr6Qp52uuegWw/lBkCtCbnYZEmPRNL61m+u67dAmGxo+HTULA==", + "dev": true, + "dependencies": { + "sort-keys": "^2.0.0", + "type-fest": "^0.4.1", + "write-json-file": "^3.2.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/write-pkg/node_modules/type-fest": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.4.1.tgz", + "integrity": "sha512-IwzA/LSfD2vC1/YDYMv/zHP4rDF1usCwllsDpbolT3D4fUepIO7f9K70jjmUewU/LmGUKJcwcVtDCpnKk4BPMw==", + "dev": true, + "engines": { + "node": ">=6" } }, "node_modules/ws": { - "version": "8.2.3", - "resolved": "https://registry.npmjs.org/ws/-/ws-8.2.3.tgz", - "integrity": "sha512-wBuoj1BDpC6ZQ1B7DWQBYVLphPWkm8i9Y0/3YdHjHKHiohOJ1ws+3OccDWtH+PoC9DZD5WOTrJvNbWvjS6JWaA==", + "version": "8.11.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", + "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", "dev": true, "engines": { "node": ">=10.0.0" @@ -10270,214 +14182,86 @@ "integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==", "dev": true }, - "node_modules/xtend": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", - "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", + "node_modules/xpath": { + "version": "0.0.32", + "resolved": "https://registry.npmjs.org/xpath/-/xpath-0.0.32.tgz", + "integrity": "sha512-rxMJhSIoiO8vXcWvSifKqhvV96GjiD5wYb8/QHdoRyQvraTpp4IEv944nhGausZZ3u7dhQXteZuZbaqfpB7uYw==", "dev": true, "engines": { - "node": ">=0.4" + "node": ">=0.6.0" } }, "node_modules/y18n": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.3.tgz", - "integrity": "sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ==", - "dev": true + "version": "5.0.8", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", + "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", + "dev": true, + "engines": { + "node": ">=10" + } }, "node_modules/yallist": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "inBundle": true + "inBundle": true, + "license": "ISC" }, "node_modules/yaml": { - "version": "1.10.2", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", - "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.1.3.tgz", + "integrity": "sha512-AacA8nRULjKMX2DvWvOAdBZMOfQlypSFkjcOcu9FalllIDJ1kvlREzcdIZmidQUqqeMv7jorHjq2HlLv/+c2lg==", "dev": true, "engines": { - "node": ">= 6" + "node": ">= 14" } }, - "node_modules/yapool": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/yapool/-/yapool-1.0.0.tgz", - "integrity": "sha1-9pPymjFbUNmp2iZGp6ZkXJaYW2o=", - "dev": true - }, "node_modules/yargs": { - "version": "15.4.1", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-15.4.1.tgz", - "integrity": "sha512-aePbxDmcYW++PaqBsJ+HYUFwCdv4LVvdnhBy78E57PIor8/OVvhMrADFFEDh8DHDFRv/O9i3lPhsENjO7QX0+A==", + "version": "17.6.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.6.2.tgz", + "integrity": "sha512-1/9UrdHjDZc0eOU0HxOHoS78C69UD3JRMvzlJ7S79S2nTaWRA/whGCTV8o9e/N/1Va9YIV7Q4sOxD8VV4pCWOw==", "dev": true, "dependencies": { - "cliui": "^6.0.0", - "decamelize": "^1.2.0", - "find-up": "^4.1.0", - "get-caller-file": "^2.0.1", + "cliui": "^8.0.1", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^4.2.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^18.1.2" + "string-width": "^4.2.3", + "y18n": "^5.0.5", + "yargs-parser": "^21.1.1" }, "engines": { - "node": ">=8" + "node": ">=12" } }, "node_modules/yargs-parser": { - "version": "18.1.3", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-18.1.3.tgz", - "integrity": "sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==", - "dev": true, - "dependencies": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/yargs/node_modules/ansi-regex": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", - "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==", + "version": "20.2.9", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", + "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==", "dev": true, "engines": { - "node": ">=8" + "node": ">=10" } }, "node_modules/yargs/node_modules/cliui": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-6.0.0.tgz", - "integrity": "sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ==", + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", + "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", "dev": true, "dependencies": { "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", - "wrap-ansi": "^6.2.0" - } - }, - "node_modules/yargs/node_modules/find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", - "dev": true, - "dependencies": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" + "strip-ansi": "^6.0.1", + "wrap-ansi": "^7.0.0" }, "engines": { - "node": ">=8" + "node": ">=12" } }, - "node_modules/yargs/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "node_modules/yargs/node_modules/yargs-parser": { + "version": "21.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", + "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", "dev": true, "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", - "dev": true, - "dependencies": { - "p-locate": "^4.1.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "dev": true, - "dependencies": { - "p-try": "^2.0.0" - }, - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/yargs/node_modules/p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", - "dev": true, - "dependencies": { - "p-limit": "^2.2.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/yargs/node_modules/path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/string-width": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.2.tgz", - "integrity": "sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/strip-ansi": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", - "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", - "dev": true, - "dependencies": { - "ansi-regex": "^5.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/wrap-ansi": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", - "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=8" + "node": ">=12" } }, "node_modules/yn": { @@ -10485,8270 +14269,369 @@ "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", "dev": true, - "optional": true, - "peer": true, "engines": { "node": ">=6" } }, + "node_modules/yocto-queue": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", + "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/zwitch": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/zwitch/-/zwitch-1.0.5.tgz", - "integrity": "sha512-V50KMwwzqJV0NpZIZFwfOD5/lyny3WlSzRiXgA0G7VUnRlqttta1L6UQIHzd6EuBY/cHGfwTIck7w1yH6Q5zUw==", + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/zwitch/-/zwitch-2.0.2.tgz", + "integrity": "sha512-JZxotl7SxAJH0j7dN4pxsTV6ZLXoLdGME+PsjkL/DaBrVryK9kTGq06GfKrwcSOqypP+fdXGoCHE36b99fWVoA==", "dev": true, "funding": { "type": "github", "url": "https://github.com/sponsors/wooorm" } }, - "packages/libnpmdiff": { - "version": "2.0.4", - "extraneous": true, + "smoke-tests": { + "name": "@npmcli/smoke-tests", + "version": "1.0.0", "license": "ISC", - "dependencies": { - "@npmcli/disparity-colors": "^1.0.1", - "@npmcli/installed-package-contents": "^1.0.7", - "binary-extensions": "^2.2.0", - "diff": "^5.0.0", - "minimatch": "^3.0.4", - "npm-package-arg": "^8.1.4", - "pacote": "^12.0.0", - "tar": "^6.1.0" - }, "devDependencies": { - "eslint": "^8.1.0", - "tap": "^15.0.9" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/mock-registry": "^1.0.0", + "@npmcli/promise-spawn": "^6.0.1", + "@npmcli/template-oss": "4.11.0", + "http-proxy": "^1.18.1", + "just-extend": "^6.1.1", + "just-safe-set": "^4.1.1", + "tap": "^16.3.2", + "which": "^3.0.0" }, "engines": { - "node": ">=10" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/arborist": { "name": "@npmcli/arborist", - "version": "4.3.1", + "version": "6.1.5", "license": "ISC", "dependencies": { "@isaacs/string-locale-compare": "^1.1.0", - "@npmcli/installed-package-contents": "^1.0.7", - "@npmcli/map-workspaces": "^2.0.0", - "@npmcli/metavuln-calculator": "^2.0.0", - "@npmcli/move-file": "^1.1.0", + "@npmcli/fs": "^3.1.0", + "@npmcli/installed-package-contents": "^2.0.0", + "@npmcli/map-workspaces": "^3.0.0", + "@npmcli/metavuln-calculator": "^5.0.0", "@npmcli/name-from-folder": "^1.0.1", - "@npmcli/node-gyp": "^1.0.3", - "@npmcli/package-json": "^1.0.1", - "@npmcli/run-script": "^2.0.0", - "bin-links": "^3.0.0", - "cacache": "^15.0.3", + "@npmcli/node-gyp": "^3.0.0", + "@npmcli/package-json": "^3.0.0", + "@npmcli/query": "^3.0.0", + "@npmcli/run-script": "^6.0.0", + "bin-links": "^4.0.1", + "cacache": "^17.0.3", "common-ancestor-path": "^1.0.1", - "json-parse-even-better-errors": "^2.3.1", + "hosted-git-info": "^6.1.1", + "json-parse-even-better-errors": "^3.0.0", "json-stringify-nice": "^1.1.4", - "mkdirp": "^1.0.4", - "mkdirp-infer-owner": "^2.0.0", - "npm-install-checks": "^4.0.0", - "npm-package-arg": "^8.1.5", - "npm-pick-manifest": "^6.1.0", - "npm-registry-fetch": "^12.0.1", - "pacote": "^12.0.2", - "parse-conflict-json": "^2.0.1", - "proc-log": "^1.0.0", + "minimatch": "^5.1.1", + "nopt": "^7.0.0", + "npm-install-checks": "^6.0.0", + "npm-package-arg": "^10.1.0", + "npm-pick-manifest": "^8.0.1", + "npm-registry-fetch": "^14.0.3", + "npmlog": "^7.0.1", + "pacote": "^15.0.7", + "parse-conflict-json": "^3.0.0", + "proc-log": "^3.0.0", "promise-all-reject-late": "^1.0.0", "promise-call-limit": "^1.0.1", - "read-package-json-fast": "^2.0.2", - "readdir-scoped-modules": "^1.1.0", - "rimraf": "^3.0.2", - "semver": "^7.3.5", - "ssri": "^8.0.1", - "treeverse": "^1.0.4", + "read-package-json-fast": "^3.0.1", + "semver": "^7.3.7", + "ssri": "^10.0.1", + "treeverse": "^3.0.0", "walk-up-path": "^1.0.0" }, "bin": { "arborist": "bin/index.js" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", "benchmark": "^2.1.4", "chalk": "^4.1.0", - "minify-registry-metadata": "^2.1.0", + "minify-registry-metadata": "^3.0.0", "nock": "^13.2.0", - "tap": "^15.1.2", + "tap": "^16.3.2", "tcompare": "^5.0.6" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "workspaces/arborist/node_modules/nock": { - "version": "13.2.1", - "resolved": "https://registry.npmjs.org/nock/-/nock-13.2.1.tgz", - "integrity": "sha512-CoHAabbqq/xZEknubuyQMjq6Lfi5b7RtK6SoNK6m40lebGp3yiMagWtIoYaw2s9sISD7wPuCfwFpivVHX/35RA==", - "dev": true, + "workspaces/config": { + "name": "@npmcli/config", + "version": "6.1.0", + "license": "ISC", "dependencies": { - "debug": "^4.1.0", - "json-stringify-safe": "^5.0.1", - "lodash.set": "^4.3.2", - "propagate": "^2.0.0" + "@npmcli/map-workspaces": "^3.0.0", + "ini": "^3.0.0", + "nopt": "^7.0.0", + "proc-log": "^3.0.0", + "read-package-json-fast": "^3.0.0", + "semver": "^7.3.5", + "walk-up-path": "^1.0.0" + }, + "devDependencies": { + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "tap": "^16.3.2" }, "engines": { - "node": ">= 10.13" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/libnpmaccess": { - "version": "5.0.1", + "version": "7.0.1", "license": "ISC", "dependencies": { - "aproba": "^2.0.0", - "minipass": "^3.1.1", - "npm-package-arg": "^8.1.2", - "npm-registry-fetch": "^12.0.1" + "npm-package-arg": "^10.1.0", + "npm-registry-fetch": "^14.0.3" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "nock": "^12.0.1", - "tap": "^15.1.0" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/mock-registry": "^1.0.0", + "@npmcli/template-oss": "4.11.0", + "nock": "^13.2.4", + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/libnpmdiff": { - "version": "3.0.0", + "version": "5.0.6", "license": "ISC", "dependencies": { - "@npmcli/disparity-colors": "^1.0.1", - "@npmcli/installed-package-contents": "^1.0.7", + "@npmcli/arborist": "^6.1.5", + "@npmcli/disparity-colors": "^3.0.0", + "@npmcli/installed-package-contents": "^2.0.0", "binary-extensions": "^2.2.0", - "diff": "^5.0.0", - "minimatch": "^3.0.4", - "npm-package-arg": "^8.1.4", - "pacote": "^12.0.0", - "tar": "^6.1.0" + "diff": "^5.1.0", + "minimatch": "^5.1.1", + "npm-package-arg": "^10.1.0", + "pacote": "^15.0.7", + "tar": "^6.1.13" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "eslint": "^8.1.0", - "tap": "^15.0.9" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/libnpmexec": { - "version": "3.0.3", + "version": "5.0.6", "license": "ISC", "dependencies": { - "@npmcli/arborist": "^4.0.0", - "@npmcli/ci-detect": "^2.0.0", - "@npmcli/run-script": "^2.0.0", + "@npmcli/arborist": "^6.1.5", + "@npmcli/run-script": "^6.0.0", "chalk": "^4.1.0", - "mkdirp-infer-owner": "^2.0.0", - "npm-package-arg": "^8.1.2", - "pacote": "^12.0.0", - "proc-log": "^1.0.0", + "ci-info": "^3.7.0", + "npm-package-arg": "^10.1.0", + "npmlog": "^7.0.1", + "pacote": "^15.0.7", + "proc-log": "^3.0.0", "read": "^1.0.7", - "read-package-json-fast": "^2.0.2", + "read-package-json-fast": "^3.0.1", + "semver": "^7.3.7", "walk-up-path": "^1.0.0" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "bin-links": "^3.0.0", - "tap": "^15.0.6" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/mock-registry": "^1.0.0", + "@npmcli/template-oss": "4.11.0", + "bin-links": "^4.0.1", + "just-extend": "^6.1.1", + "just-safe-set": "^4.1.1", + "minify-registry-metadata": "^3.0.0", + "mkdirp": "^1.0.4", + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/libnpmfund": { - "version": "2.0.2", + "version": "4.0.6", "license": "ISC", "dependencies": { - "@npmcli/arborist": "^4.0.0" + "@npmcli/arborist": "^6.1.5" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "tap": "^15.0.9" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/libnpmhook": { - "version": "7.0.1", + "version": "9.0.1", "license": "ISC", "dependencies": { "aproba": "^2.0.0", - "npm-registry-fetch": "^12.0.1" + "npm-registry-fetch": "^14.0.3" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "nock": "^9.6.1", - "tap": "^15.1.0" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "nock": "^13.2.4", + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - } - }, - "workspaces/libnpmhook/node_modules/debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", - "dev": true, - "dependencies": { - "ms": "^2.1.1" - } - }, - "workspaces/libnpmhook/node_modules/mkdirp": { - "version": "0.5.5", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", - "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", - "dev": true, - "dependencies": { - "minimist": "^1.2.5" - }, - "bin": { - "mkdirp": "bin/cmd.js" - } - }, - "workspaces/libnpmhook/node_modules/nock": { - "version": "9.6.1", - "resolved": "https://registry.npmjs.org/nock/-/nock-9.6.1.tgz", - "integrity": "sha512-EDgl/WgNQ0C1BZZlASOQkQdE6tAWXJi8QQlugqzN64JJkvZ7ILijZuG24r4vCC7yOfnm6HKpne5AGExLGCeBWg==", - "dev": true, - "engines": [ - "node >= 4.0" - ], - "dependencies": { - "chai": "^4.1.2", - "debug": "^3.1.0", - "deep-equal": "^1.0.0", - "json-stringify-safe": "^5.0.1", - "lodash": "^4.17.5", - "mkdirp": "^0.5.0", - "propagate": "^1.0.0", - "qs": "^6.5.1", - "semver": "^5.5.0" - } - }, - "workspaces/libnpmhook/node_modules/propagate": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/propagate/-/propagate-1.0.0.tgz", - "integrity": "sha1-AMLa7t2iDofjeCs0Stuhzd1q1wk=", - "dev": true, - "engines": [ - "node >= 0.8.1" - ] - }, - "workspaces/libnpmhook/node_modules/semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", - "dev": true, - "bin": { - "semver": "bin/semver" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/libnpmorg": { - "version": "3.0.1", + "version": "5.0.1", "license": "ISC", "dependencies": { "aproba": "^2.0.0", - "npm-registry-fetch": "^12.0.1" + "npm-registry-fetch": "^14.0.3" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "minipass": "^3.1.1", - "nock": "^12.0.1", - "tap": "^15.0.0" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "minipass": "^4.0.0", + "nock": "^13.2.4", + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/libnpmpack": { - "version": "3.1.0", + "version": "5.0.6", "license": "ISC", "dependencies": { - "@npmcli/run-script": "^2.0.0", - "npm-package-arg": "^8.1.0", - "pacote": "^12.0.0" + "@npmcli/arborist": "^6.1.5", + "@npmcli/run-script": "^6.0.0", + "npm-package-arg": "^10.1.0", + "pacote": "^15.0.7" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", "nock": "^13.0.7", - "tap": "^15.0.0" + "spawk": "^1.7.1", + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - } - }, - "workspaces/libnpmpack/node_modules/nock": { - "version": "13.2.1", - "resolved": "https://registry.npmjs.org/nock/-/nock-13.2.1.tgz", - "integrity": "sha512-CoHAabbqq/xZEknubuyQMjq6Lfi5b7RtK6SoNK6m40lebGp3yiMagWtIoYaw2s9sISD7wPuCfwFpivVHX/35RA==", - "dev": true, - "dependencies": { - "debug": "^4.1.0", - "json-stringify-safe": "^5.0.1", - "lodash.set": "^4.3.2", - "propagate": "^2.0.0" - }, - "engines": { - "node": ">= 10.13" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/libnpmpublish": { - "version": "5.0.1", + "version": "7.0.6", "license": "ISC", "dependencies": { - "normalize-package-data": "^3.0.2", - "npm-package-arg": "^8.1.2", - "npm-registry-fetch": "^12.0.1", - "semver": "^7.1.3", - "ssri": "^8.0.1" + "normalize-package-data": "^5.0.0", + "npm-package-arg": "^10.1.0", + "npm-registry-fetch": "^14.0.3", + "semver": "^7.3.7", + "ssri": "^10.0.1" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "libnpmpack": "^3.0.0", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "libnpmpack": "^5.0.6", "lodash.clonedeep": "^4.5.0", - "nock": "^12.0.2", - "tap": "^15" + "nock": "^13.2.4", + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/libnpmsearch": { - "version": "4.0.1", + "version": "6.0.1", "license": "ISC", "dependencies": { - "npm-registry-fetch": "^12.0.1" + "npm-registry-fetch": "^14.0.3" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "nock": "^9.6.1", - "tap": "^15" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "nock": "^13.2.4", + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - } - }, - "workspaces/libnpmsearch/node_modules/debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", - "dev": true, - "dependencies": { - "ms": "^2.1.1" - } - }, - "workspaces/libnpmsearch/node_modules/mkdirp": { - "version": "0.5.5", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", - "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", - "dev": true, - "dependencies": { - "minimist": "^1.2.5" - }, - "bin": { - "mkdirp": "bin/cmd.js" - } - }, - "workspaces/libnpmsearch/node_modules/nock": { - "version": "9.6.1", - "resolved": "https://registry.npmjs.org/nock/-/nock-9.6.1.tgz", - "integrity": "sha512-EDgl/WgNQ0C1BZZlASOQkQdE6tAWXJi8QQlugqzN64JJkvZ7ILijZuG24r4vCC7yOfnm6HKpne5AGExLGCeBWg==", - "dev": true, - "engines": [ - "node >= 4.0" - ], - "dependencies": { - "chai": "^4.1.2", - "debug": "^3.1.0", - "deep-equal": "^1.0.0", - "json-stringify-safe": "^5.0.1", - "lodash": "^4.17.5", - "mkdirp": "^0.5.0", - "propagate": "^1.0.0", - "qs": "^6.5.1", - "semver": "^5.5.0" - } - }, - "workspaces/libnpmsearch/node_modules/propagate": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/propagate/-/propagate-1.0.0.tgz", - "integrity": "sha1-AMLa7t2iDofjeCs0Stuhzd1q1wk=", - "dev": true, - "engines": [ - "node >= 0.8.1" - ] - }, - "workspaces/libnpmsearch/node_modules/semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", - "dev": true, - "bin": { - "semver": "bin/semver" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/libnpmteam": { - "version": "3.0.1", + "version": "5.0.1", "license": "ISC", "dependencies": { "aproba": "^2.0.0", - "npm-registry-fetch": "^12.0.1" + "npm-registry-fetch": "^14.0.3" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "nock": "^12.0.1", - "tap": "^15" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "nock": "^13.2.4", + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, "workspaces/libnpmversion": { - "version": "2.0.2", + "version": "4.0.1", "license": "ISC", "dependencies": { - "@npmcli/git": "^2.0.7", - "@npmcli/run-script": "^2.0.0", - "json-parse-even-better-errors": "^2.3.1", - "semver": "^7.3.5", - "stringify-package": "^1.0.1" + "@npmcli/git": "^4.0.1", + "@npmcli/run-script": "^6.0.0", + "json-parse-even-better-errors": "^3.0.0", + "proc-log": "^3.0.0", + "semver": "^7.3.7" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", "require-inject": "^1.4.4", - "tap": "^15" + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - } - } - }, - "dependencies": { - "@babel/code-frame": { - "version": "7.12.13", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.12.13.tgz", - "integrity": "sha512-HV1Cm0Q3ZrpCR93tkWOYiuYIgLxZXZFVG2VgK+MBWjUqZTundupbfx2aXarXuw5Ko5aMcjtJgbSs4vUGBS5v6g==", - "dev": true, - "requires": { - "@babel/highlight": "^7.12.13" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "@babel/core": { - "version": "7.12.9", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.12.9.tgz", - "integrity": "sha512-gTXYh3M5wb7FRXQy+FErKFAv90BnlOuNn1QkCK2lREoPAjrQCO49+HVSrFoe5uakFAF5eenS75KbO2vQiLrTMQ==", - "dev": true, - "requires": { - "@babel/code-frame": "^7.10.4", - "@babel/generator": "^7.12.5", - "@babel/helper-module-transforms": "^7.12.1", - "@babel/helpers": "^7.12.5", - "@babel/parser": "^7.12.7", - "@babel/template": "^7.12.7", - "@babel/traverse": "^7.12.9", - "@babel/types": "^7.12.7", - "convert-source-map": "^1.7.0", - "debug": "^4.1.0", - "gensync": "^1.0.0-beta.1", - "json5": "^2.1.2", - "lodash": "^4.17.19", - "resolve": "^1.3.2", - "semver": "^5.4.1", - "source-map": "^0.5.0" - }, - "dependencies": { - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", - "dev": true - } - } - }, - "@babel/generator": { - "version": "7.14.3", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.14.3.tgz", - "integrity": "sha512-bn0S6flG/j0xtQdz3hsjJ624h3W0r3llttBMfyHX3YrZ/KtLYr15bjA0FXkgW7FpvrDuTuElXeVjiKlYRpnOFA==", - "dev": true, - "requires": { - "@babel/types": "^7.14.2", - "jsesc": "^2.5.1", - "source-map": "^0.5.0" - } - }, - "@babel/helper-function-name": { - "version": "7.14.2", - "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.14.2.tgz", - "integrity": "sha512-NYZlkZRydxw+YT56IlhIcS8PAhb+FEUiOzuhFTfqDyPmzAhRge6ua0dQYT/Uh0t/EDHq05/i+e5M2d4XvjgarQ==", - "dev": true, - "requires": { - "@babel/helper-get-function-arity": "^7.12.13", - "@babel/template": "^7.12.13", - "@babel/types": "^7.14.2" - } - }, - "@babel/helper-get-function-arity": { - "version": "7.12.13", - "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.12.13.tgz", - "integrity": "sha512-DjEVzQNz5LICkzN0REdpD5prGoidvbdYk1BVgRUOINaWJP2t6avB27X1guXK1kXNrX0WMfsrm1A/ZBthYuIMQg==", - "dev": true, - "requires": { - "@babel/types": "^7.12.13" - } - }, - "@babel/helper-member-expression-to-functions": { - "version": "7.13.12", - "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.13.12.tgz", - "integrity": "sha512-48ql1CLL59aKbU94Y88Xgb2VFy7a95ykGRbJJaaVv+LX5U8wFpLfiGXJJGUozsmA1oEh/o5Bp60Voq7ACyA/Sw==", - "dev": true, - "requires": { - "@babel/types": "^7.13.12" - } - }, - "@babel/helper-module-imports": { - "version": "7.16.0", - "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.16.0.tgz", - "integrity": "sha512-kkH7sWzKPq0xt3H1n+ghb4xEMP8k0U7XV3kkB+ZGy69kDk2ySFW1qPi06sjKzFY3t1j6XbJSqr4mF9L7CYVyhg==", - "dev": true, - "requires": { - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-module-transforms": { - "version": "7.14.2", - "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.14.2.tgz", - "integrity": "sha512-OznJUda/soKXv0XhpvzGWDnml4Qnwp16GN+D/kZIdLsWoHj05kyu8Rm5kXmMef+rVJZ0+4pSGLkeixdqNUATDA==", - "dev": true, - "requires": { - "@babel/helper-module-imports": "^7.13.12", - "@babel/helper-replace-supers": "^7.13.12", - "@babel/helper-simple-access": "^7.13.12", - "@babel/helper-split-export-declaration": "^7.12.13", - "@babel/helper-validator-identifier": "^7.14.0", - "@babel/template": "^7.12.13", - "@babel/traverse": "^7.14.2", - "@babel/types": "^7.14.2" - } - }, - "@babel/helper-optimise-call-expression": { - "version": "7.12.13", - "resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.12.13.tgz", - "integrity": "sha512-BdWQhoVJkp6nVjB7nkFWcn43dkprYauqtk++Py2eaf/GRDFm5BxRqEIZCiHlZUGAVmtwKcsVL1dC68WmzeFmiA==", - "dev": true, - "requires": { - "@babel/types": "^7.12.13" - } - }, - "@babel/helper-plugin-utils": { - "version": "7.14.5", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.14.5.tgz", - "integrity": "sha512-/37qQCE3K0vvZKwoK4XU/irIJQdIfCJuhU5eKnNxpFDsOkgFaUAwbv+RYw6eYgsC0E4hS7r5KqGULUogqui0fQ==", - "dev": true - }, - "@babel/helper-replace-supers": { - "version": "7.14.4", - "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.14.4.tgz", - "integrity": "sha512-zZ7uHCWlxfEAAOVDYQpEf/uyi1dmeC7fX4nCf2iz9drnCwi1zvwXL3HwWWNXUQEJ1k23yVn3VbddiI9iJEXaTQ==", - "dev": true, - "requires": { - "@babel/helper-member-expression-to-functions": "^7.13.12", - "@babel/helper-optimise-call-expression": "^7.12.13", - "@babel/traverse": "^7.14.2", - "@babel/types": "^7.14.4" - } - }, - "@babel/helper-simple-access": { - "version": "7.13.12", - "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.13.12.tgz", - "integrity": "sha512-7FEjbrx5SL9cWvXioDbnlYTppcZGuCY6ow3/D5vMggb2Ywgu4dMrpTJX0JdQAIcRRUElOIxF3yEooa9gUb9ZbA==", - "dev": true, - "requires": { - "@babel/types": "^7.13.12" - } - }, - "@babel/helper-split-export-declaration": { - "version": "7.12.13", - "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.12.13.tgz", - "integrity": "sha512-tCJDltF83htUtXx5NLcaDqRmknv652ZWCHyoTETf1CXYJdPC7nohZohjUgieXhv0hTJdRf2FjDueFehdNucpzg==", - "dev": true, - "requires": { - "@babel/types": "^7.12.13" - } - }, - "@babel/helper-validator-identifier": { - "version": "7.15.7", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.15.7.tgz", - "integrity": "sha512-K4JvCtQqad9OY2+yTU8w+E82ywk/fe+ELNlt1G8z3bVGlZfn/hOcQQsUhGhW/N+tb3fxK800wLtKOE/aM0m72w==", - "dev": true - }, - "@babel/helpers": { - "version": "7.14.0", - "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.14.0.tgz", - "integrity": "sha512-+ufuXprtQ1D1iZTO/K9+EBRn+qPWMJjZSw/S0KlFrxCw4tkrzv9grgpDHkY9MeQTjTY8i2sp7Jep8DfU6tN9Mg==", - "dev": true, - "requires": { - "@babel/template": "^7.12.13", - "@babel/traverse": "^7.14.0", - "@babel/types": "^7.14.0" - } - }, - "@babel/highlight": { - "version": "7.14.0", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.14.0.tgz", - "integrity": "sha512-YSCOwxvTYEIMSGaBQb5kDDsCopDdiUGsqpatp3fOlI4+2HQSkTmEVWnVuySdAC5EWCqSWWTv0ib63RjR7dTBdg==", - "dev": true, - "requires": { - "@babel/helper-validator-identifier": "^7.14.0", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "dev": true, - "requires": { - "color-convert": "^1.9.0" - } - }, - "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - } - }, - "color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", - "dev": true, - "requires": { - "color-name": "1.1.3" - } - }, - "color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", - "dev": true - }, - "escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", - "dev": true - }, - "has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", - "dev": true - }, - "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } - } - }, - "@babel/parser": { - "version": "7.14.4", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.14.4.tgz", - "integrity": "sha512-ArliyUsWDUqEGfWcmzpGUzNfLxTdTp6WU4IuP6QFSp9gGfWS6boxFCkJSJ/L4+RG8z/FnIU3WxCk6hPL9SSWeA==", - "dev": true - }, - "@babel/plugin-proposal-object-rest-spread": { - "version": "7.12.1", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.12.1.tgz", - "integrity": "sha512-s6SowJIjzlhx8o7lsFx5zmY4At6CTtDvgNQDdPzkBQucle58A6b/TTeEBYtyDgmcXjUTM+vE8YOGHZzzbc/ioA==", - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-object-rest-spread": "^7.8.0", - "@babel/plugin-transform-parameters": "^7.12.1" - } - }, - "@babel/plugin-syntax-jsx": { - "version": "7.12.1", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.12.1.tgz", - "integrity": "sha512-1yRi7yAtB0ETgxdY9ti/p2TivUxJkTdhu/ZbF9MshVGqOx1TdB3b7xCXs49Fupgg50N45KcAsRP/ZqWjs9SRjg==", - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-syntax-object-rest-spread": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", - "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } - }, - "@babel/plugin-transform-parameters": { - "version": "7.14.2", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.14.2.tgz", - "integrity": "sha512-NxoVmA3APNCC1JdMXkdYXuQS+EMdqy0vIwyDHeKHiJKRxmp1qGSdb0JLEIoPRhkx6H/8Qi3RJ3uqOCYw8giy9A==", - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.13.0" - } - }, - "@babel/template": { - "version": "7.12.13", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.12.13.tgz", - "integrity": "sha512-/7xxiGA57xMo/P2GVvdEumr8ONhFOhfgq2ihK3h1e6THqzTAkHbkXgB0xI9yeTfIUoH3+oAeHhqm/I43OTbbjA==", - "dev": true, - "requires": { - "@babel/code-frame": "^7.12.13", - "@babel/parser": "^7.12.13", - "@babel/types": "^7.12.13" - } - }, - "@babel/traverse": { - "version": "7.14.2", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.14.2.tgz", - "integrity": "sha512-TsdRgvBFHMyHOOzcP9S6QU0QQtjxlRpEYOy3mcCO5RgmC305ki42aSAmfZEMSSYBla2oZ9BMqYlncBaKmD/7iA==", - "dev": true, - "requires": { - "@babel/code-frame": "^7.12.13", - "@babel/generator": "^7.14.2", - "@babel/helper-function-name": "^7.14.2", - "@babel/helper-split-export-declaration": "^7.12.13", - "@babel/parser": "^7.14.2", - "@babel/types": "^7.14.2", - "debug": "^4.1.0", - "globals": "^11.1.0" - } - }, - "@babel/types": { - "version": "7.16.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.16.0.tgz", - "integrity": "sha512-PJgg/k3SdLsGb3hhisFvtLOw5ts113klrpLuIPtCJIU+BB24fqq6lf8RWqKJEjzqXR9AEH1rIb5XTqwBHB+kQg==", - "dev": true, - "requires": { - "@babel/helper-validator-identifier": "^7.15.7", - "to-fast-properties": "^2.0.0" - } - }, - "@blueoak/list": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@blueoak/list/-/list-2.0.0.tgz", - "integrity": "sha512-yQ6/CTy6DYvmJOAIw/BJjKeNG2ZyF8uxgTN8Yvcv4L9YavoVp9xUgmoVUKN5l24NGPDQpswavNanHOqB00ZNXg==", - "dev": true - }, - "@eslint/eslintrc": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.0.4.tgz", - "integrity": "sha512-h8Vx6MdxwWI2WM8/zREHMoqdgLNXEL4QX3MWSVMdyNJGvXVOs+6lp+m2hc3FnuMHDc4poxFNI20vCk0OmI4G0Q==", - "dev": true, - "requires": { - "ajv": "^6.12.4", - "debug": "^4.3.2", - "espree": "^9.0.0", - "globals": "^13.9.0", - "ignore": "^4.0.6", - "import-fresh": "^3.2.1", - "js-yaml": "^4.1.0", - "minimatch": "^3.0.4", - "strip-json-comments": "^3.1.1" - }, - "dependencies": { - "argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "dev": true - }, - "globals": { - "version": "13.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.12.0.tgz", - "integrity": "sha512-uS8X6lSKN2JumVoXrbUz+uG4BYG+eiawqm3qFcT7ammfbUHeCBoJMlHcec/S3krSk73/AE/f0szYFmgAA3kYZg==", - "dev": true, - "requires": { - "type-fest": "^0.20.2" - } - }, - "js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", - "dev": true, - "requires": { - "argparse": "^2.0.1" - } - }, - "type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "dev": true - } - } - }, - "@gar/promisify": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@gar/promisify/-/promisify-1.1.2.tgz", - "integrity": "sha512-82cpyJyKRoQoRi+14ibCeGPu0CwypgtBAdBhq1WfvagpCZNKqwXbKwXllYSMG91DhmG4jt9gN8eP6lGOtozuaw==" - }, - "@humanwhocodes/config-array": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.6.0.tgz", - "integrity": "sha512-JQlEKbcgEUjBFhLIF4iqM7u/9lwgHRBcpHrmUNCALK0Q3amXN6lxdoXLnF0sm11E9VqTmBALR87IlUg1bZ8A9A==", - "dev": true, - "requires": { - "@humanwhocodes/object-schema": "^1.2.0", - "debug": "^4.1.1", - "minimatch": "^3.0.4" - } - }, - "@humanwhocodes/object-schema": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz", - "integrity": "sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==", - "dev": true - }, - "@isaacs/string-locale-compare": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@isaacs/string-locale-compare/-/string-locale-compare-1.1.0.tgz", - "integrity": "sha512-SQ7Kzhh9+D+ZW9MA0zkYv3VXhIDNx+LzM6EJ+/65I3QY+enU6Itte7E5XX7EWrqLW2FN4n06GWzBnPoC3th2aQ==" - }, - "@istanbuljs/load-nyc-config": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz", - "integrity": "sha512-VjeHSlIzpv/NyD3N0YuHfXOPDIixcA1q2ZV98wsMqcYlPmv2n3Yb2lYP9XMElnaFVXg5A7YLTeLu6V84uQDjmQ==", - "dev": true, - "requires": { - "camelcase": "^5.3.1", - "find-up": "^4.1.0", - "get-package-type": "^0.1.0", - "js-yaml": "^3.13.1", - "resolve-from": "^5.0.0" - }, - "dependencies": { - "find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", - "dev": true, - "requires": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" - } - }, - "locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", - "dev": true, - "requires": { - "p-locate": "^4.1.0" - } - }, - "p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "dev": true, - "requires": { - "p-try": "^2.0.0" - } - }, - "p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", - "dev": true, - "requires": { - "p-limit": "^2.2.0" - } - }, - "p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "dev": true - }, - "path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true - }, - "resolve-from": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", - "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", - "dev": true - } - } - }, - "@istanbuljs/schema": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/@istanbuljs/schema/-/schema-0.1.3.tgz", - "integrity": "sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA==", - "dev": true - }, - "@mdx-js/mdx": { - "version": "1.6.22", - "resolved": "https://registry.npmjs.org/@mdx-js/mdx/-/mdx-1.6.22.tgz", - "integrity": "sha512-AMxuLxPz2j5/6TpF/XSdKpQP1NlG0z11dFOlq+2IP/lSgl11GY8ji6S/rgsViN/L0BDvHvUMruRb7ub+24LUYA==", - "dev": true, - "requires": { - "@babel/core": "7.12.9", - "@babel/plugin-syntax-jsx": "7.12.1", - "@babel/plugin-syntax-object-rest-spread": "7.8.3", - "@mdx-js/util": "1.6.22", - "babel-plugin-apply-mdx-type-prop": "1.6.22", - "babel-plugin-extract-import-names": "1.6.22", - "camelcase-css": "2.0.1", - "detab": "2.0.4", - "hast-util-raw": "6.0.1", - "lodash.uniq": "4.5.0", - "mdast-util-to-hast": "10.0.1", - "remark-footnotes": "2.0.0", - "remark-mdx": "1.6.22", - "remark-parse": "8.0.3", - "remark-squeeze-paragraphs": "4.0.0", - "style-to-object": "0.3.0", - "unified": "9.2.0", - "unist-builder": "2.0.3", - "unist-util-visit": "2.0.3" - } - }, - "@mdx-js/util": { - "version": "1.6.22", - "resolved": "https://registry.npmjs.org/@mdx-js/util/-/util-1.6.22.tgz", - "integrity": "sha512-H1rQc1ZOHANWBvPcW+JpGwr+juXSxM8Q8YCkm3GhZd8REu1fHR3z99CErO1p9pkcfcxZnMdIZdIsXkOHY0NilA==", - "dev": true - }, - "@npmcli/arborist": { - "version": "file:workspaces/arborist", - "requires": { - "@isaacs/string-locale-compare": "^1.1.0", - "@npmcli/installed-package-contents": "^1.0.7", - "@npmcli/map-workspaces": "^2.0.0", - "@npmcli/metavuln-calculator": "^2.0.0", - "@npmcli/move-file": "^1.1.0", - "@npmcli/name-from-folder": "^1.0.1", - "@npmcli/node-gyp": "^1.0.3", - "@npmcli/package-json": "^1.0.1", - "@npmcli/run-script": "^2.0.0", - "@npmcli/template-oss": "^2.4.2", - "benchmark": "^2.1.4", - "bin-links": "^3.0.0", - "cacache": "^15.0.3", - "chalk": "^4.1.0", - "common-ancestor-path": "^1.0.1", - "json-parse-even-better-errors": "^2.3.1", - "json-stringify-nice": "^1.1.4", - "minify-registry-metadata": "^2.1.0", - "mkdirp": "^1.0.4", - "mkdirp-infer-owner": "^2.0.0", - "nock": "^13.2.0", - "npm-install-checks": "^4.0.0", - "npm-package-arg": "^8.1.5", - "npm-pick-manifest": "^6.1.0", - "npm-registry-fetch": "^12.0.1", - "pacote": "^12.0.2", - "parse-conflict-json": "^2.0.1", - "proc-log": "^1.0.0", - "promise-all-reject-late": "^1.0.0", - "promise-call-limit": "^1.0.1", - "read-package-json-fast": "^2.0.2", - "readdir-scoped-modules": "^1.1.0", - "rimraf": "^3.0.2", - "semver": "^7.3.5", - "ssri": "^8.0.1", - "tap": "^15.1.2", - "tcompare": "^5.0.6", - "treeverse": "^1.0.4", - "walk-up-path": "^1.0.0" - }, - "dependencies": { - "nock": { - "version": "13.2.1", - "resolved": "https://registry.npmjs.org/nock/-/nock-13.2.1.tgz", - "integrity": "sha512-CoHAabbqq/xZEknubuyQMjq6Lfi5b7RtK6SoNK6m40lebGp3yiMagWtIoYaw2s9sISD7wPuCfwFpivVHX/35RA==", - "dev": true, - "requires": { - "debug": "^4.1.0", - "json-stringify-safe": "^5.0.1", - "lodash.set": "^4.3.2", - "propagate": "^2.0.0" - } - } - } - }, - "@npmcli/ci-detect": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/ci-detect/-/ci-detect-2.0.0.tgz", - "integrity": "sha512-8yQtQ9ArHh/TzdUDKQwEvwCgpDuhSWTDAbiKMl3854PcT+Dk4UmWaiawuFTLy9n5twzXOBXVflWe+90/ffXQrA==" - }, - "@npmcli/config": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/config/-/config-3.0.0.tgz", - "integrity": "sha512-2cYe2MCGintq1s6izbLYO2gAHZwNFQ92lIb5QhtpRizwHwqrV9v4+xNpvx1EBaEaqTHFR4QuozgZLA1scao/5Q==", - "requires": { - "@npmcli/map-workspaces": "^2.0.0", - "ini": "^2.0.0", - "mkdirp-infer-owner": "^2.0.0", - "nopt": "^5.0.0", - "read-package-json-fast": "^2.0.3", - "semver": "^7.3.4", - "walk-up-path": "^1.0.0" - } - }, - "@npmcli/disparity-colors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@npmcli/disparity-colors/-/disparity-colors-1.0.1.tgz", - "integrity": "sha512-kQ1aCTTU45mPXN+pdAaRxlxr3OunkyztjbbxDY/aIcPS5CnCUrx+1+NvA6pTcYR7wmLZe37+Mi5v3nfbwPxq3A==", - "requires": { - "ansi-styles": "^4.3.0" - } - }, - "@npmcli/eslint-config": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/eslint-config/-/eslint-config-2.0.0.tgz", - "integrity": "sha512-/QSD5YMsrRum8rqmq7gsna59mvFgtyUcoUawcOHS0hjCQ9kwHywFLG3cuXy98s4dpIukau08inkWX/JTeXy/1Q==", - "dev": true, - "requires": { - "which": "^2.0.2" - } - }, - "@npmcli/fs": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@npmcli/fs/-/fs-1.1.0.tgz", - "integrity": "sha512-VhP1qZLXcrXRIaPoqb4YA55JQxLNF3jNR4T55IdOJa3+IFJKNYHtPvtXx8slmeMavj37vCzCfrqQM1vWLsYKLA==", - "requires": { - "@gar/promisify": "^1.0.1", - "semver": "^7.3.5" - } - }, - "@npmcli/git": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/@npmcli/git/-/git-2.1.0.tgz", - "integrity": "sha512-/hBFX/QG1b+N7PZBFs0bi+evgRZcK9nWBxQKZkGoXUT5hJSwl5c4d7y8/hm+NQZRPhQ67RzFaj5UM9YeyKoryw==", - "requires": { - "@npmcli/promise-spawn": "^1.3.2", - "lru-cache": "^6.0.0", - "mkdirp": "^1.0.4", - "npm-pick-manifest": "^6.1.1", - "promise-inflight": "^1.0.1", - "promise-retry": "^2.0.1", - "semver": "^7.3.5", - "which": "^2.0.2" - } - }, - "@npmcli/installed-package-contents": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/@npmcli/installed-package-contents/-/installed-package-contents-1.0.7.tgz", - "integrity": "sha512-9rufe0wnJusCQoLpV9ZPKIVP55itrM5BxOXs10DmdbRfgWtHy1LDyskbwRnBghuB0PrF7pNPOqREVtpz4HqzKw==", - "requires": { - "npm-bundled": "^1.1.1", - "npm-normalize-package-bin": "^1.0.1" - } - }, - "@npmcli/map-workspaces": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/map-workspaces/-/map-workspaces-2.0.0.tgz", - "integrity": "sha512-QBJfpCY1NOAkkW3lFfru9VTdqvMB2TN0/vrevl5xBCv5Fi0XDVcA6rqqSau4Ysi4Iw3fBzyXV7hzyTBDfadf7g==", - "requires": { - "@npmcli/name-from-folder": "^1.0.1", - "glob": "^7.1.6", - "minimatch": "^3.0.4", - "read-package-json-fast": "^2.0.1" - } - }, - "@npmcli/metavuln-calculator": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/metavuln-calculator/-/metavuln-calculator-2.0.0.tgz", - "integrity": "sha512-VVW+JhWCKRwCTE+0xvD6p3uV4WpqocNYYtzyvenqL/u1Q3Xx6fGTJ+6UoIoii07fbuEO9U3IIyuGY0CYHDv1sg==", - "requires": { - "cacache": "^15.0.5", - "json-parse-even-better-errors": "^2.3.1", - "pacote": "^12.0.0", - "semver": "^7.3.2" - } - }, - "@npmcli/move-file": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@npmcli/move-file/-/move-file-1.1.2.tgz", - "integrity": "sha512-1SUf/Cg2GzGDyaf15aR9St9TWlb+XvbZXWpDx8YKs7MLzMH/BCeopv+y9vzrzgkfykCGuWOlSu3mZhj2+FQcrg==", - "requires": { - "mkdirp": "^1.0.4", - "rimraf": "^3.0.2" - } - }, - "@npmcli/name-from-folder": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@npmcli/name-from-folder/-/name-from-folder-1.0.1.tgz", - "integrity": "sha512-qq3oEfcLFwNfEYOQ8HLimRGKlD8WSeGEdtUa7hmzpR8Sa7haL1KVQrvgO6wqMjhWFFVjgtrh1gIxDz+P8sjUaA==" - }, - "@npmcli/node-gyp": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@npmcli/node-gyp/-/node-gyp-1.0.3.tgz", - "integrity": "sha512-fnkhw+fmX65kiLqk6E3BFLXNC26rUhK90zVwe2yncPliVT/Qos3xjhTLE59Df8KnPlcwIERXKVlU1bXoUQ+liA==" - }, - "@npmcli/package-json": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@npmcli/package-json/-/package-json-1.0.1.tgz", - "integrity": "sha512-y6jnu76E9C23osz8gEMBayZmaZ69vFOIk8vR1FJL/wbEJ54+9aVG9rLTjQKSXfgYZEr50nw1txBBFfBZZe+bYg==", - "requires": { - "json-parse-even-better-errors": "^2.3.1" - } - }, - "@npmcli/promise-spawn": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/@npmcli/promise-spawn/-/promise-spawn-1.3.2.tgz", - "integrity": "sha512-QyAGYo/Fbj4MXeGdJcFzZ+FkDkomfRBrPM+9QYJSg+PxgAUL+LU3FneQk37rKR2/zjqkCV1BLHccX98wRXG3Sg==", - "requires": { - "infer-owner": "^1.0.4" - } - }, - "@npmcli/run-script": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/run-script/-/run-script-2.0.0.tgz", - "integrity": "sha512-fSan/Pu11xS/TdaTpTB0MRn9guwGU8dye+x56mEVgBEd/QsybBbYcAL0phPXi8SGWFEChkQd6M9qL4y6VOpFig==", - "requires": { - "@npmcli/node-gyp": "^1.0.2", - "@npmcli/promise-spawn": "^1.3.2", - "node-gyp": "^8.2.0", - "read-package-json-fast": "^2.0.1" - } - }, - "@npmcli/template-oss": { - "version": "2.4.3", - "resolved": "https://registry.npmjs.org/@npmcli/template-oss/-/template-oss-2.4.3.tgz", - "integrity": "sha512-y+efKAT2WTw3c7ShDxpF9HOPH3XmruO0TPJlJrxMaJ7yPZ/vrrRcGCP00gOr4QHVFtbmfXVMU+kuVIkkKJt7xg==", - "dev": true, - "requires": { - "@npmcli/fs": "^1.0.0", - "@npmcli/map-workspaces": "^2.0.0", - "@npmcli/package-json": "^1.0.1", - "json-parse-even-better-errors": "^2.3.1", - "which": "^2.0.2" - } - }, - "@tootallnate/once": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-2.0.0.tgz", - "integrity": "sha512-XCuKFP5PS55gnMVu3dty8KPatLqUoy/ZYzDzAGCQ8JNFCkLXzmI7vNHCR+XpbZaMWQK/vQubr7PkYq8g470J/A==" - }, - "@types/hast": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/@types/hast/-/hast-2.3.1.tgz", - "integrity": "sha512-viwwrB+6xGzw+G1eWpF9geV3fnsDgXqHG+cqgiHrvQfDUW5hzhCyV7Sy3UJxhfRFBsgky2SSW33qi/YrIkjX5Q==", - "dev": true, - "requires": { - "@types/unist": "*" - } - }, - "@types/mdast": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@types/mdast/-/mdast-3.0.3.tgz", - "integrity": "sha512-SXPBMnFVQg1s00dlMCc/jCdvPqdE4mXaMMCeRlxLDmTAEoegHT53xKtkDnzDTOcmMHUfcjyf36/YYZ6SxRdnsw==", - "dev": true, - "requires": { - "@types/unist": "*" - } - }, - "@types/parse5": { - "version": "5.0.3", - "resolved": "https://registry.npmjs.org/@types/parse5/-/parse5-5.0.3.tgz", - "integrity": "sha512-kUNnecmtkunAoQ3CnjmMkzNU/gtxG8guhi+Fk2U/kOpIKjIMKnXGp4IJCgQJrXSgMsWYimYG4TGjz/UzbGEBTw==", - "dev": true - }, - "@types/unist": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@types/unist/-/unist-2.0.3.tgz", - "integrity": "sha512-FvUupuM3rlRsRtCN+fDudtmytGO6iHJuuRKS1Ss0pG5z8oX0diNEw94UEL7hgDbpN94rgaK5R7sWm6RrSkZuAQ==", - "dev": true - }, - "abab": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/abab/-/abab-2.0.5.tgz", - "integrity": "sha512-9IK9EadsbHo6jLWIpxpR6pL0sazTXV6+SQv25ZB+F7Bj9mJNaOc4nCRabwd5M/JwmUa8idz6Eci6eKfJryPs6Q==", - "dev": true - }, - "abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - }, - "acorn": { - "version": "7.4.1", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-7.4.1.tgz", - "integrity": "sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A==", - "dev": true - }, - "acorn-globals": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/acorn-globals/-/acorn-globals-6.0.0.tgz", - "integrity": "sha512-ZQl7LOWaF5ePqqcX4hLuv/bLXYQNfNWw2c0/yX/TsPRKamzHcTGQnlCjHT3TsmkOUVEPS3crCxiPfdzE/Trlhg==", - "dev": true, - "requires": { - "acorn": "^7.1.1", - "acorn-walk": "^7.1.1" - } - }, - "acorn-jsx": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", - "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", - "dev": true, - "requires": {} - }, - "acorn-walk": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-7.2.0.tgz", - "integrity": "sha512-OPdCF6GsMIP+Az+aWfAAOEt2/+iVDKE7oy6lJ098aoe59oAmK76qV6Gw60SbZ8jHuG2wH058GF4pLFbYamYrVA==", - "dev": true - }, - "agent-base": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz", - "integrity": "sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==", - "requires": { - "debug": "4" - } - }, - "agentkeepalive": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/agentkeepalive/-/agentkeepalive-4.2.0.tgz", - "integrity": "sha512-0PhAp58jZNw13UJv7NVdTGb0ZcghHUb3DrZ046JiiJY/BOaTTpbwdHq2VObPCBV8M2GPh7sgrJ3AQ8Ey468LJw==", - "requires": { - "debug": "^4.1.0", - "depd": "^1.1.2", - "humanize-ms": "^1.2.1" - } - }, - "aggregate-error": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.1.0.tgz", - "integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==", - "requires": { - "clean-stack": "^2.0.0", - "indent-string": "^4.0.0" - } - }, - "ajv": { - "version": "6.12.6", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", - "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", - "dev": true, - "requires": { - "fast-deep-equal": "^3.1.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" - } - }, - "ansi-colors": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", - "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==", - "dev": true - }, - "ansi-regex": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=" - }, - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "requires": { - "color-convert": "^2.0.1" - } - }, - "ansicolors": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/ansicolors/-/ansicolors-0.3.2.tgz", - "integrity": "sha1-ZlWX3oap/+Oqm/vmyuXG6kJrSXk=" - }, - "ansistyles": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/ansistyles/-/ansistyles-0.1.3.tgz", - "integrity": "sha1-XeYEFb2gcbs3EnhUyGT0GyMlRTk=" - }, - "anymatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.2.tgz", - "integrity": "sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==", - "dev": true, - "requires": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" - } - }, - "append-transform": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/append-transform/-/append-transform-2.0.0.tgz", - "integrity": "sha512-7yeyCEurROLQJFv5Xj4lEGTy0borxepjFv1g22oAdqFu//SrAlDl1O1Nxx15SH1RoliUml6p8dwJW9jvZughhg==", - "dev": true, - "requires": { - "default-require-extensions": "^3.0.0" - } - }, - "aproba": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/aproba/-/aproba-2.0.0.tgz", - "integrity": "sha512-lYe4Gx7QT+MKGbDsA+Z+he/Wtef0BiwDOlK/XkBrdfsh9J/jPPXbX0tE9x9cl27Tmu5gg3QUbUrQYa/y+KOHPQ==" - }, - "archy": { + "workspaces/ws-a": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz", - "integrity": "sha1-+cjBN1fMHde8N5rHeyxipcKGjEA=" - }, - "are-we-there-yet": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-3.0.0.tgz", - "integrity": "sha512-0GWpv50YSOcLXaN6/FAKY3vfRbllXWV2xvfA/oKJF8pzFhWXPV+yjhJXDBbjscDYowv7Yw1A3uigpzn5iEGTyw==", - "requires": { - "delegates": "^1.0.0", - "readable-stream": "^3.6.0" + "extraneous": true, + "license": "ISC", + "dependencies": { + "abbrev": "1.0.5", + "ws-b": "1.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "arg": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", - "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", - "dev": true, - "optional": true, - "peer": true - }, - "argparse": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", - "dev": true, - "requires": { - "sprintf-js": "~1.0.2" - } - }, - "array-find-index": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/array-find-index/-/array-find-index-1.0.2.tgz", - "integrity": "sha1-3wEKoSh+Fku9pvlyOwqWoexBh6E=", - "dev": true - }, - "asap": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/asap/-/asap-2.0.6.tgz", - "integrity": "sha1-5QNHYR1+aQlDIIu9r+vLwvuGbUY=" - }, - "asn1": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz", - "integrity": "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==", - "dev": true, - "requires": { - "safer-buffer": "~2.1.0" - } - }, - "assert-plus": { + "workspaces/ws-b": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", - "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=", - "dev": true - }, - "assertion-error": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", - "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==", - "dev": true - }, - "async-hook-domain": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/async-hook-domain/-/async-hook-domain-2.0.4.tgz", - "integrity": "sha512-14LjCmlK1PK8eDtTezR6WX8TMaYNIzBIsd2D1sGoGjgx0BuNMMoSdk7i/drlbtamy0AWv9yv2tkB+ASdmeqFIw==", - "dev": true - }, - "asynckit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=", - "dev": true - }, - "aws-sign2": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", - "integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=", - "dev": true - }, - "aws4": { - "version": "1.11.0", - "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.11.0.tgz", - "integrity": "sha512-xh1Rl34h6Fi1DC2WWKfxUTVqRsNnr6LsKz2+hfwDxQJWmrx8+c7ylaqBMcHfl1U1r2dsifOvKX3LQuLNZ+XSvA==", - "dev": true - }, - "babel-plugin-apply-mdx-type-prop": { - "version": "1.6.22", - "resolved": "https://registry.npmjs.org/babel-plugin-apply-mdx-type-prop/-/babel-plugin-apply-mdx-type-prop-1.6.22.tgz", - "integrity": "sha512-VefL+8o+F/DfK24lPZMtJctrCVOfgbqLAGZSkxwhazQv4VxPg3Za/i40fu22KR2m8eEda+IfSOlPLUSIiLcnCQ==", - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "7.10.4", - "@mdx-js/util": "1.6.22" - }, + "extraneous": true, + "license": "ISC", "dependencies": { - "@babel/helper-plugin-utils": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz", - "integrity": "sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg==", - "dev": true - } - } - }, - "babel-plugin-extract-import-names": { - "version": "1.6.22", - "resolved": "https://registry.npmjs.org/babel-plugin-extract-import-names/-/babel-plugin-extract-import-names-1.6.22.tgz", - "integrity": "sha512-yJ9BsJaISua7d8zNT7oRG1ZLBJCIdZ4PZqmH8qa9N5AK01ifk3fnkc98AXhtzE7UkfCsEumvoQWgoYLhOnJ7jQ==", - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "7.10.4" + "abbrev": "1.0.6" }, - "dependencies": { - "@babel/helper-plugin-utils": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz", - "integrity": "sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg==", - "dev": true - } + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } - }, - "bail": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/bail/-/bail-1.0.5.tgz", - "integrity": "sha512-xFbRxM1tahm08yHBP16MMjVUAvDaBMD38zsM9EMAUN61omwLmKlOpB/Zku5QkjZ8TZ4vn53pj+t518cH0S03RQ==", - "dev": true - }, - "balanced-match": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" - }, - "base64-js": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", - "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", - "dev": true - }, - "bcrypt-pbkdf": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", - "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=", - "dev": true, - "requires": { - "tweetnacl": "^0.14.3" - } - }, - "benchmark": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/benchmark/-/benchmark-2.1.4.tgz", - "integrity": "sha1-CfPeMckWQl1JjMLuVloOvzwqVik=", - "dev": true, - "requires": { - "lodash": "^4.17.4", - "platform": "^1.3.3" - } - }, - "bin-links": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/bin-links/-/bin-links-3.0.0.tgz", - "integrity": "sha512-fC7kPWcEkAWBgCKxmAMqZldlIeHsXwQy9JXzrppAVQiukGiDKxmYesJcBKWu6UMwx/5GOfo10wtK/4zy+Xt/mg==", - "requires": { - "cmd-shim": "^4.0.1", - "mkdirp-infer-owner": "^2.0.0", - "npm-normalize-package-bin": "^1.0.0", - "read-cmd-shim": "^2.0.0", - "rimraf": "^3.0.0", - "write-file-atomic": "^4.0.0" - } - }, - "binary-extensions": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", - "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==" - }, - "bind-obj-methods": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/bind-obj-methods/-/bind-obj-methods-3.0.0.tgz", - "integrity": "sha512-nLEaaz3/sEzNSyPWRsN9HNsqwk1AUyECtGj+XwGdIi3xABnEqecvXtIJ0wehQXuuER5uZ/5fTs2usONgYjG+iw==", - "dev": true - }, - "bindings": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", - "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", - "dev": true, - "requires": { - "file-uri-to-path": "1.0.0" - } - }, - "bl": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz", - "integrity": "sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==", - "dev": true, - "requires": { - "buffer": "^5.5.0", - "inherits": "^2.0.4", - "readable-stream": "^3.4.0" - } - }, - "brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "requires": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "braces": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", - "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", - "dev": true, - "requires": { - "fill-range": "^7.0.1" - } - }, - "browser-process-hrtime": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/browser-process-hrtime/-/browser-process-hrtime-1.0.0.tgz", - "integrity": "sha512-9o5UecI3GhkpM6DrXr69PblIuWxPKk9Y0jHBRhdocZ2y7YECBFCsHm79Pr3OyR2AvjhDkabFJaDJMYRazHgsow==", - "dev": true - }, - "buffer": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", - "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", - "dev": true, - "requires": { - "base64-js": "^1.3.1", - "ieee754": "^1.1.13" - } - }, - "buffer-from": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", - "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==", - "dev": true - }, - "builtins": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/builtins/-/builtins-1.0.3.tgz", - "integrity": "sha1-y5T662HIaWRR2zZTThQi+U8K7og=" - }, - "cacache": { - "version": "15.3.0", - "resolved": "https://registry.npmjs.org/cacache/-/cacache-15.3.0.tgz", - "integrity": "sha512-VVdYzXEn+cnbXpFgWs5hTT7OScegHVmLhJIR8Ufqk3iFD6A6j5iSX1KuBTfNEv4tdJWE2PzA6IVFtcLC7fN9wQ==", - "requires": { - "@npmcli/fs": "^1.0.0", - "@npmcli/move-file": "^1.0.1", - "chownr": "^2.0.0", - "fs-minipass": "^2.0.0", - "glob": "^7.1.4", - "infer-owner": "^1.0.4", - "lru-cache": "^6.0.0", - "minipass": "^3.1.1", - "minipass-collect": "^1.0.2", - "minipass-flush": "^1.0.5", - "minipass-pipeline": "^1.2.2", - "mkdirp": "^1.0.3", - "p-map": "^4.0.0", - "promise-inflight": "^1.0.1", - "rimraf": "^3.0.2", - "ssri": "^8.0.1", - "tar": "^6.0.2", - "unique-filename": "^1.1.1" - } - }, - "caching-transform": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/caching-transform/-/caching-transform-4.0.0.tgz", - "integrity": "sha512-kpqOvwXnjjN44D89K5ccQC+RUrsy7jB/XLlRrx0D7/2HNcTPqzsb6XgYoErwko6QsV184CA2YgS1fxDiiDZMWA==", - "dev": true, - "requires": { - "hasha": "^5.0.0", - "make-dir": "^3.0.0", - "package-hash": "^4.0.0", - "write-file-atomic": "^3.0.0" - }, - "dependencies": { - "typedarray-to-buffer": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz", - "integrity": "sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==", - "dev": true, - "requires": { - "is-typedarray": "^1.0.0" - } - }, - "write-file-atomic": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-3.0.3.tgz", - "integrity": "sha512-AvHcyZ5JnSfq3ioSyjrBkH9yW4m7Ayk8/9My/DD9onKeu/94fwrMocemO2QAJFAlnnDN+ZDS+ZjAR5ua1/PV/Q==", - "dev": true, - "requires": { - "imurmurhash": "^0.1.4", - "is-typedarray": "^1.0.0", - "signal-exit": "^3.0.2", - "typedarray-to-buffer": "^3.1.5" - } - } - } - }, - "call-bind": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", - "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", - "dev": true, - "requires": { - "function-bind": "^1.1.1", - "get-intrinsic": "^1.0.2" - } - }, - "caller": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/caller/-/caller-1.0.1.tgz", - "integrity": "sha1-uFGGD3Dhlds9J3OVqhp+I+ow7PU=", - "dev": true - }, - "callsites": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", - "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", - "dev": true - }, - "camelcase": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", - "dev": true - }, - "camelcase-css": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/camelcase-css/-/camelcase-css-2.0.1.tgz", - "integrity": "sha512-QOSvevhslijgYwRx6Rv7zKdMF8lbRmx+uQGx2+vDc+KI/eBnsy9kit5aj23AgGu3pa4t9AgwbnXWqS+iOY+2aA==", - "dev": true - }, - "caseless": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", - "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=", - "dev": true - }, - "ccount": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/ccount/-/ccount-1.1.0.tgz", - "integrity": "sha512-vlNK021QdI7PNeiUh/lKkC/mNHHfV0m/Ad5JoI0TYtlBnJAslM/JIkm/tGC88bkLIwO6OQ5uV6ztS6kVAtCDlg==", - "dev": true - }, - "chai": { - "version": "4.3.4", - "resolved": "https://registry.npmjs.org/chai/-/chai-4.3.4.tgz", - "integrity": "sha512-yS5H68VYOCtN1cjfwumDSuzn/9c+yza4f3reKXlE5rUg7SFcCEy90gJvydNgOYtblyf4Zi6jIWRnXOgErta0KA==", - "dev": true, - "requires": { - "assertion-error": "^1.1.0", - "check-error": "^1.0.2", - "deep-eql": "^3.0.1", - "get-func-name": "^2.0.0", - "pathval": "^1.1.1", - "type-detect": "^4.0.5" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "character-entities": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/character-entities/-/character-entities-1.2.4.tgz", - "integrity": "sha512-iBMyeEHxfVnIakwOuDXpVkc54HijNgCyQB2w0VfGQThle6NXn50zU6V/u+LDhxHcDUPojn6Kpga3PTAD8W1bQw==", - "dev": true - }, - "character-entities-legacy": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/character-entities-legacy/-/character-entities-legacy-1.1.4.tgz", - "integrity": "sha512-3Xnr+7ZFS1uxeiUDvV02wQ+QDbc55o97tIV5zHScSPJpcLm/r0DFPcoY3tYRp+VZukxuMeKgXYmsXQHO05zQeA==", - "dev": true - }, - "character-reference-invalid": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/character-reference-invalid/-/character-reference-invalid-1.1.4.tgz", - "integrity": "sha512-mKKUkUbhPpQlCOfIuZkvSEgktjPFIsZKRRbC6KWVEMvlzblj3i3asQv5ODsrwt0N3pHAEvjP8KTQPHkp0+6jOg==", - "dev": true - }, - "check-error": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", - "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=", - "dev": true - }, - "chokidar": { - "version": "3.5.1", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.1.tgz", - "integrity": "sha512-9+s+Od+W0VJJzawDma/gvBNQqkTiqYTWLuZoyAsivsI4AaWTCzHG06/TMjsf1cYe9Cb97UCEhjz7HvnPk2p/tw==", - "dev": true, - "requires": { - "anymatch": "~3.1.1", - "braces": "~3.0.2", - "fsevents": "~2.3.1", - "glob-parent": "~5.1.0", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.5.0" - } - }, - "chownr": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz", - "integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==" - }, - "cidr-regex": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/cidr-regex/-/cidr-regex-3.1.1.tgz", - "integrity": "sha512-RBqYd32aDwbCMFJRL6wHOlDNYJsPNTt8vC82ErHF5vKt8QQzxm1FrkW8s/R5pVrXMf17sba09Uoy91PKiddAsw==", - "requires": { - "ip-regex": "^4.1.0" - } - }, - "clean-stack": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz", - "integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==" - }, - "cli-columns": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/cli-columns/-/cli-columns-4.0.0.tgz", - "integrity": "sha512-XW2Vg+w+L9on9wtwKpyzluIPCWXjaBahI7mTcYjx+BVIYD9c3yqcv/yKC7CmdCZat4rq2yiE1UMSJC5ivKfMtQ==", - "requires": { - "string-width": "^4.2.3", - "strip-ansi": "^6.0.1" - }, - "dependencies": { - "ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==" - }, - "is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==" - }, - "string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "requires": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - } - }, - "strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "requires": { - "ansi-regex": "^5.0.1" - } - } - } - }, - "cli-table3": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/cli-table3/-/cli-table3-0.6.1.tgz", - "integrity": "sha512-w0q/enDHhPLq44ovMGdQeeDLvwxwavsJX7oQGYt/LrBlYsyaxyDnp6z3QzFut/6kLLKnlcUVJLrpB7KBfgG/RA==", - "requires": { - "colors": "1.4.0", - "string-width": "^4.2.0" - }, - "dependencies": { - "ansi-regex": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", - "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==" - }, - "is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==" - }, - "string-width": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.2.tgz", - "integrity": "sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA==", - "requires": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.0" - } - }, - "strip-ansi": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", - "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", - "requires": { - "ansi-regex": "^5.0.0" - } - } - } - }, - "cliui": { - "version": "7.0.4", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", - "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", - "dev": true, - "requires": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", - "wrap-ansi": "^7.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true - }, - "is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true - }, - "string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "requires": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - } - }, - "strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, - "requires": { - "ansi-regex": "^5.0.1" - } - } - } - }, - "clone": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", - "integrity": "sha1-2jCcwmPfFZlMaIypAheco8fNfH4=" - }, - "cmark-gfm": { - "version": "0.9.0", - "resolved": "https://registry.npmjs.org/cmark-gfm/-/cmark-gfm-0.9.0.tgz", - "integrity": "sha512-zt++V303Zh+kqS3PERSq1knHT21TpKjbVUF/U63QhLktEH+eeZymv+mHz+6IhcTN5Hy85LdkgdKlroa/Jc6Wvg==", - "dev": true, - "requires": { - "bindings": "^1.5.0", - "node-addon-api": "^3.0.0", - "prebuild-install": "^6.0.0" - } - }, - "cmd-shim": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/cmd-shim/-/cmd-shim-4.1.0.tgz", - "integrity": "sha512-lb9L7EM4I/ZRVuljLPEtUJOP+xiQVknZ4ZMpMgEp4JzNldPb27HU03hi6K1/6CoIuit/Zm/LQXySErFeXxDprw==", - "requires": { - "mkdirp-infer-owner": "^2.0.0" - } - }, - "code-point-at": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", - "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", - "dev": true - }, - "collapse-white-space": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/collapse-white-space/-/collapse-white-space-1.0.6.tgz", - "integrity": "sha512-jEovNnrhMuqyCcjfEJA56v0Xq8SkIoPKDyaHahwo3POf4qcSXqMYuwNcOTzp74vTsR9Tn08z4MxWqAhcekogkQ==", - "dev": true - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" - }, - "color-support": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz", - "integrity": "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg==" - }, - "colors": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/colors/-/colors-1.4.0.tgz", - "integrity": "sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==", - "optional": true - }, - "columnify": { - "version": "1.5.4", - "resolved": "https://registry.npmjs.org/columnify/-/columnify-1.5.4.tgz", - "integrity": "sha1-Rzfd8ce2mop8NAVweC6UfuyOeLs=", - "requires": { - "strip-ansi": "^3.0.0", - "wcwidth": "^1.0.0" - } - }, - "combined-stream": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", - "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", - "dev": true, - "requires": { - "delayed-stream": "~1.0.0" - } - }, - "comma-separated-tokens": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/comma-separated-tokens/-/comma-separated-tokens-1.0.8.tgz", - "integrity": "sha512-GHuDRO12Sypu2cV70d1dkA2EUmXHgntrzbpvOB+Qy+49ypNfGgFQIC2fhhXbnyrJRynDCAARsT7Ou0M6hirpfw==", - "dev": true - }, - "common-ancestor-path": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/common-ancestor-path/-/common-ancestor-path-1.0.1.tgz", - "integrity": "sha512-L3sHRo1pXXEqX8VU28kfgUY+YGsk09hPqZiZmLacNib6XNTCM8ubYeT7ryXQw8asB1sKgcU5lkB7ONug08aB8w==" - }, - "commondir": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", - "integrity": "sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs=", - "dev": true - }, - "concat-map": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" - }, - "console-control-strings": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", - "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=" - }, - "convert-source-map": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.7.0.tgz", - "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==", - "dev": true, - "requires": { - "safe-buffer": "~5.1.1" - }, - "dependencies": { - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true - } - } - }, - "core-util-is": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", - "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", - "dev": true - }, - "correct-license-metadata": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/correct-license-metadata/-/correct-license-metadata-1.4.0.tgz", - "integrity": "sha512-nvbNpK/aYCbztZWGi9adIPqR+ZcQmZTWNT7eMYLvkaVGroN1nTHiVuuNPl7pK6ZNx1mvDztlRBJtfUdrVwKJ5A==", - "dev": true, - "requires": { - "spdx-expression-validate": "^2.0.0" - } - }, - "coveralls": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/coveralls/-/coveralls-3.1.0.tgz", - "integrity": "sha512-sHxOu2ELzW8/NC1UP5XVLbZDzO4S3VxfFye3XYCznopHy02YjNkHcj5bKaVw2O7hVaBdBjEdQGpie4II1mWhuQ==", - "dev": true, - "requires": { - "js-yaml": "^3.13.1", - "lcov-parse": "^1.0.0", - "log-driver": "^1.2.7", - "minimist": "^1.2.5", - "request": "^2.88.2" - } - }, - "cross-spawn": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", - "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", - "dev": true, - "requires": { - "path-key": "^3.1.0", - "shebang-command": "^2.0.0", - "which": "^2.0.1" - } - }, - "cssom": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cssom/-/cssom-0.5.0.tgz", - "integrity": "sha512-iKuQcq+NdHqlAcwUY0o/HL69XQrUaQdMjmStJ8JFmUaiiQErlhrmuigkg/CU4E2J0IyUKUrMAgl36TvN67MqTw==", - "dev": true - }, - "cssstyle": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-2.3.0.tgz", - "integrity": "sha512-AZL67abkUzIuvcHqk7c09cezpGNcxUxU4Ioi/05xHk4DQeTkWmGYftIE6ctU6AEt+Gn4n1lDStOtj7FKycP71A==", - "dev": true, - "requires": { - "cssom": "~0.3.6" - }, - "dependencies": { - "cssom": { - "version": "0.3.8", - "resolved": "https://registry.npmjs.org/cssom/-/cssom-0.3.8.tgz", - "integrity": "sha512-b0tGHbfegbhPJpxpiBPU2sCkigAqtM9O121le6bbOlgyV+NyGyCmVfJ6QW9eRjz8CpNfWEOYBIMIGRYkLwsIYg==", - "dev": true - } - } - }, - "dashdash": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", - "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0" - } - }, - "data-urls": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-3.0.1.tgz", - "integrity": "sha512-Ds554NeT5Gennfoo9KN50Vh6tpgtvYEwraYjejXnyTpu1C7oXKxdFk75REooENHE8ndTVOJuv+BEs4/J/xcozw==", - "dev": true, - "requires": { - "abab": "^2.0.3", - "whatwg-mimetype": "^3.0.0", - "whatwg-url": "^10.0.0" - } - }, - "debug": { - "version": "4.3.3", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.3.tgz", - "integrity": "sha512-/zxw5+vh1Tfv+4Qn7a5nsbcJKPaSvCDhojn6FEl9vupwK2VCSDtEiEtqr8DFtzYFOdz63LBkxec7DYuc2jon6Q==", - "requires": { - "ms": "2.1.2" - }, - "dependencies": { - "ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" - } - } - }, - "debuglog": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/debuglog/-/debuglog-1.0.1.tgz", - "integrity": "sha1-qiT/uaw9+aI1GDfPstJ5NgzXhJI=" - }, - "decamelize": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", - "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", - "dev": true - }, - "decimal.js": { - "version": "10.3.1", - "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.3.1.tgz", - "integrity": "sha512-V0pfhfr8suzyPGOx3nmq4aHqabehUZn6Ch9kyFpV79TGDTWFmHqUqXdabR7QHqxzrYolF4+tVmJhUG4OURg5dQ==", - "dev": true - }, - "decompress-response": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-4.2.1.tgz", - "integrity": "sha512-jOSne2qbyE+/r8G1VU+G/82LBs2Fs4LAsTiLSHOCOMZQl2OKZ6i8i4IyHemTe+/yIXOtTcRQMzPcgyhoFlqPkw==", - "dev": true, - "requires": { - "mimic-response": "^2.0.0" - } - }, - "deep-eql": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-3.0.1.tgz", - "integrity": "sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==", - "dev": true, - "requires": { - "type-detect": "^4.0.0" - } - }, - "deep-equal": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-1.1.1.tgz", - "integrity": "sha512-yd9c5AdiqVcR+JjcwUQb9DkhJc8ngNr0MahEBGvDiJw8puWab2yZlh+nkasOnZP+EGTAP6rRp2JzJhJZzvNF8g==", - "dev": true, - "requires": { - "is-arguments": "^1.0.4", - "is-date-object": "^1.0.1", - "is-regex": "^1.0.4", - "object-is": "^1.0.1", - "object-keys": "^1.1.1", - "regexp.prototype.flags": "^1.2.0" - } - }, - "deep-extend": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", - "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", - "dev": true - }, - "deep-is": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz", - "integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=", - "dev": true - }, - "default-require-extensions": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/default-require-extensions/-/default-require-extensions-3.0.0.tgz", - "integrity": "sha512-ek6DpXq/SCpvjhpFsLFRVtIxJCRw6fUR42lYMVZuUMK7n8eMz4Uh5clckdBjEpLhn/gEBZo7hDJnJcwdKLKQjg==", - "dev": true, - "requires": { - "strip-bom": "^4.0.0" - }, - "dependencies": { - "strip-bom": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-4.0.0.tgz", - "integrity": "sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w==", - "dev": true - } - } - }, - "defaults": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/defaults/-/defaults-1.0.3.tgz", - "integrity": "sha1-xlYFHpgX2f8I7YgUd/P+QBnz730=", - "requires": { - "clone": "^1.0.2" - } - }, - "define-properties": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", - "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", - "dev": true, - "requires": { - "object-keys": "^1.0.12" - } - }, - "delayed-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=", - "dev": true - }, - "delegates": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz", - "integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=" - }, - "depd": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", - "integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak=" - }, - "detab": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/detab/-/detab-2.0.4.tgz", - "integrity": "sha512-8zdsQA5bIkoRECvCrNKPla84lyoR7DSAyf7p0YgXzBO9PDJx8KntPUay7NS6yp+KdxdVtiE5SpHKtbp2ZQyA9g==", - "dev": true, - "requires": { - "repeat-string": "^1.5.4" - } - }, - "detect-libc": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz", - "integrity": "sha1-+hN8S9aY7fVc1c0CrFWfkaTEups=", - "dev": true - }, - "dezalgo": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/dezalgo/-/dezalgo-1.0.3.tgz", - "integrity": "sha1-f3Qt4Gb8dIvI24IFad3c5Jvw1FY=", - "requires": { - "asap": "^2.0.0", - "wrappy": "1" - } - }, - "diff": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz", - "integrity": "sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w==" - }, - "docopt": { - "version": "0.6.2", - "resolved": "https://registry.npmjs.org/docopt/-/docopt-0.6.2.tgz", - "integrity": "sha1-so6eIiDaXsSffqW7JKR3h0Be6xE=", - "dev": true - }, - "docs": { - "version": "file:docs", - "requires": { - "@mdx-js/mdx": "^1.6.22", - "cmark-gfm": "^0.9.0", - "jsdom": "^18.1.0", - "marked-man": "^0.7.0", - "yaml": "^1.10.0" - } - }, - "doctrine": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", - "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", - "dev": true, - "requires": { - "esutils": "^2.0.2" - } - }, - "domexception": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/domexception/-/domexception-4.0.0.tgz", - "integrity": "sha512-A2is4PLG+eeSfoTMA95/s4pvAoSo2mKtiM5jlHkAVewmiO8ISFTFKZjH7UAM1Atli/OT/7JHOrJRJiMKUZKYBw==", - "dev": true, - "requires": { - "webidl-conversions": "^7.0.0" - } - }, - "ecc-jsbn": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", - "integrity": "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=", - "dev": true, - "requires": { - "jsbn": "~0.1.0", - "safer-buffer": "^2.1.0" - } - }, - "emoji-regex": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" - }, - "encoding": { - "version": "0.1.13", - "resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.13.tgz", - "integrity": "sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==", - "optional": true, - "requires": { - "iconv-lite": "^0.6.2" - } - }, - "end-of-stream": { - "version": "1.4.4", - "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", - "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", - "dev": true, - "requires": { - "once": "^1.4.0" - } - }, - "enquirer": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.3.6.tgz", - "integrity": "sha512-yjNnPr315/FjS4zIsUxYguYUPP2e1NK4d7E7ZOLiyYCcbFBiTMyID+2wvm2w6+pZ/odMA7cRkjhsPbltwBOrLg==", - "dev": true, - "requires": { - "ansi-colors": "^4.1.1" - } - }, - "env-paths": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz", - "integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==" - }, - "err-code": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/err-code/-/err-code-2.0.3.tgz", - "integrity": "sha512-2bmlRpNKBxT/CRmPOlyISQpNj+qSeYvcym/uT0Jx2bMOlKLtSy1ZmLuVxSEKKyor/N5yhvp/ZiG1oE3DEYMSFA==" - }, - "es-abstract": { - "version": "1.19.1", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.19.1.tgz", - "integrity": "sha512-2vJ6tjA/UfqLm2MPs7jxVybLoB8i1t1Jd9R3kISld20sIxPcTbLuggQOUxeWeAvIUkduv/CfMjuh4WmiXr2v9w==", - "dev": true, - "requires": { - "call-bind": "^1.0.2", - "es-to-primitive": "^1.2.1", - "function-bind": "^1.1.1", - "get-intrinsic": "^1.1.1", - "get-symbol-description": "^1.0.0", - "has": "^1.0.3", - "has-symbols": "^1.0.2", - "internal-slot": "^1.0.3", - "is-callable": "^1.2.4", - "is-negative-zero": "^2.0.1", - "is-regex": "^1.1.4", - "is-shared-array-buffer": "^1.0.1", - "is-string": "^1.0.7", - "is-weakref": "^1.0.1", - "object-inspect": "^1.11.0", - "object-keys": "^1.1.1", - "object.assign": "^4.1.2", - "string.prototype.trimend": "^1.0.4", - "string.prototype.trimstart": "^1.0.4", - "unbox-primitive": "^1.0.1" - } - }, - "es-to-primitive": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", - "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", - "dev": true, - "requires": { - "is-callable": "^1.1.4", - "is-date-object": "^1.0.1", - "is-symbol": "^1.0.2" - } - }, - "es6-error": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/es6-error/-/es6-error-4.1.1.tgz", - "integrity": "sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg==", - "dev": true - }, - "escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", - "dev": true - }, - "escodegen": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-2.0.0.tgz", - "integrity": "sha512-mmHKys/C8BFUGI+MAWNcSYoORYLMdPzjrknd2Vc+bUsjN5bXcr8EhrNB+UTqfL1y3I9c4fw2ihgtMPQLBRiQxw==", - "dev": true, - "requires": { - "esprima": "^4.0.1", - "estraverse": "^5.2.0", - "esutils": "^2.0.2", - "optionator": "^0.8.1", - "source-map": "~0.6.1" - }, - "dependencies": { - "levn": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", - "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=", - "dev": true, - "requires": { - "prelude-ls": "~1.1.2", - "type-check": "~0.3.2" - } - }, - "optionator": { - "version": "0.8.3", - "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz", - "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", - "dev": true, - "requires": { - "deep-is": "~0.1.3", - "fast-levenshtein": "~2.0.6", - "levn": "~0.3.0", - "prelude-ls": "~1.1.2", - "type-check": "~0.3.2", - "word-wrap": "~1.2.3" - } - }, - "prelude-ls": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", - "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=", - "dev": true - }, - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true, - "optional": true - }, - "type-check": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", - "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=", - "dev": true, - "requires": { - "prelude-ls": "~1.1.2" - } - } - } - }, - "eslint": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.3.0.tgz", - "integrity": "sha512-aIay56Ph6RxOTC7xyr59Kt3ewX185SaGnAr8eWukoPLeriCrvGjvAubxuvaXOfsxhtwV5g0uBOsyhAom4qJdww==", - "dev": true, - "requires": { - "@eslint/eslintrc": "^1.0.4", - "@humanwhocodes/config-array": "^0.6.0", - "ajv": "^6.10.0", - "chalk": "^4.0.0", - "cross-spawn": "^7.0.2", - "debug": "^4.3.2", - "doctrine": "^3.0.0", - "enquirer": "^2.3.5", - "escape-string-regexp": "^4.0.0", - "eslint-scope": "^7.1.0", - "eslint-utils": "^3.0.0", - "eslint-visitor-keys": "^3.1.0", - "espree": "^9.1.0", - "esquery": "^1.4.0", - "esutils": "^2.0.2", - "fast-deep-equal": "^3.1.3", - "file-entry-cache": "^6.0.1", - "functional-red-black-tree": "^1.0.1", - "glob-parent": "^6.0.1", - "globals": "^13.6.0", - "ignore": "^4.0.6", - "import-fresh": "^3.0.0", - "imurmurhash": "^0.1.4", - "is-glob": "^4.0.0", - "js-yaml": "^4.1.0", - "json-stable-stringify-without-jsonify": "^1.0.1", - "levn": "^0.4.1", - "lodash.merge": "^4.6.2", - "minimatch": "^3.0.4", - "natural-compare": "^1.4.0", - "optionator": "^0.9.1", - "progress": "^2.0.0", - "regexpp": "^3.2.0", - "semver": "^7.2.1", - "strip-ansi": "^6.0.1", - "strip-json-comments": "^3.1.0", - "text-table": "^0.2.0", - "v8-compile-cache": "^2.0.3" - }, - "dependencies": { - "ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true - }, - "argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "dev": true - }, - "eslint-utils": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-3.0.0.tgz", - "integrity": "sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA==", - "dev": true, - "requires": { - "eslint-visitor-keys": "^2.0.0" - }, - "dependencies": { - "eslint-visitor-keys": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz", - "integrity": "sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw==", - "dev": true - } - } - }, - "glob-parent": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", - "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", - "dev": true, - "requires": { - "is-glob": "^4.0.3" - } - }, - "globals": { - "version": "13.9.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.9.0.tgz", - "integrity": "sha512-74/FduwI/JaIrr1H8e71UbDE+5x7pIPs1C2rrwC52SszOo043CsWOZEMW7o2Y58xwm9b+0RBKDxY5n2sUpEFxA==", - "dev": true, - "requires": { - "type-fest": "^0.20.2" - } - }, - "js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", - "dev": true, - "requires": { - "argparse": "^2.0.1" - } - }, - "strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, - "requires": { - "ansi-regex": "^5.0.1" - } - }, - "type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "dev": true - } - } - }, - "eslint-plugin-es": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-es/-/eslint-plugin-es-3.0.1.tgz", - "integrity": "sha512-GUmAsJaN4Fc7Gbtl8uOBlayo2DqhwWvEzykMHSCZHU3XdJ+NSzzZcVhXh3VxX5icqQ+oQdIEawXX8xkR3mIFmQ==", - "dev": true, - "peer": true, - "requires": { - "eslint-utils": "^2.0.0", - "regexpp": "^3.0.0" - } - }, - "eslint-plugin-node": { - "version": "11.1.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-node/-/eslint-plugin-node-11.1.0.tgz", - "integrity": "sha512-oUwtPJ1W0SKD0Tr+wqu92c5xuCeQqB3hSCHasn/ZgjFdA9iDGNkNf2Zi9ztY7X+hNuMib23LNGRm6+uN+KLE3g==", - "dev": true, - "peer": true, - "requires": { - "eslint-plugin-es": "^3.0.0", - "eslint-utils": "^2.0.0", - "ignore": "^5.1.1", - "minimatch": "^3.0.4", - "resolve": "^1.10.1", - "semver": "^6.1.0" - }, - "dependencies": { - "ignore": { - "version": "5.1.8", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.1.8.tgz", - "integrity": "sha512-BMpfD7PpiETpBl/A6S498BaIJ6Y/ABT93ETbby2fP00v4EbvPBXWEoaR1UBPKs3iR53pJY7EtZk5KACI57i1Uw==", - "dev": true, - "peer": true - }, - "semver": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", - "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", - "dev": true, - "peer": true - } - } - }, - "eslint-scope": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.1.0.tgz", - "integrity": "sha512-aWwkhnS0qAXqNOgKOK0dJ2nvzEbhEvpy8OlJ9kZ0FeZnA6zpjv1/Vei+puGFFX7zkPCkHHXb7IDX3A+7yPrRWg==", - "dev": true, - "requires": { - "esrecurse": "^4.3.0", - "estraverse": "^5.2.0" - } - }, - "eslint-utils": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-2.1.0.tgz", - "integrity": "sha512-w94dQYoauyvlDc43XnGB8lU3Zt713vNChgt4EWwhXAP2XkBvndfxF0AgIqKOOasjPIPzj9JqgwkwbCYD0/V3Zg==", - "dev": true, - "peer": true, - "requires": { - "eslint-visitor-keys": "^1.1.0" - }, - "dependencies": { - "eslint-visitor-keys": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz", - "integrity": "sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==", - "dev": true, - "peer": true - } - } - }, - "eslint-visitor-keys": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.1.0.tgz", - "integrity": "sha512-yWJFpu4DtjsWKkt5GeNBBuZMlNcYVs6vRCLoCVEJrTjaSB6LC98gFipNK/erM2Heg/E8mIK+hXG/pJMLK+eRZA==", - "dev": true - }, - "espree": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/espree/-/espree-9.1.0.tgz", - "integrity": "sha512-ZgYLvCS1wxOczBYGcQT9DDWgicXwJ4dbocr9uYN+/eresBAUuBu+O4WzB21ufQ/JqQT8gyp7hJ3z8SHii32mTQ==", - "dev": true, - "requires": { - "acorn": "^8.6.0", - "acorn-jsx": "^5.3.1", - "eslint-visitor-keys": "^3.1.0" - }, - "dependencies": { - "acorn": { - "version": "8.6.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.6.0.tgz", - "integrity": "sha512-U1riIR+lBSNi3IbxtaHOIKdH8sLFv3NYfNv8sg7ZsNhcfl4HF2++BfqqrNAxoCLQW1iiylOj76ecnaUxz+z9yw==", - "dev": true - } - } - }, - "esprima": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", - "dev": true - }, - "esquery": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.4.0.tgz", - "integrity": "sha512-cCDispWt5vHHtwMY2YrAQ4ibFkAL8RbH5YGBnZBc90MolvvfkkQcJro/aZiAQUlQ3qgrYS6D6v8Gc5G5CQsc9w==", - "dev": true, - "requires": { - "estraverse": "^5.1.0" - } - }, - "esrecurse": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", - "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", - "dev": true, - "requires": { - "estraverse": "^5.2.0" - } - }, - "estraverse": { - "version": "5.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", - "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", - "dev": true - }, - "esutils": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", - "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", - "dev": true - }, - "events-to-array": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/events-to-array/-/events-to-array-1.1.2.tgz", - "integrity": "sha1-LUH1Y+H+QA7Uli/hpNXGp1Od9/Y=", - "dev": true - }, - "expand-template": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/expand-template/-/expand-template-2.0.3.tgz", - "integrity": "sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==", - "dev": true - }, - "extend": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", - "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==", - "dev": true - }, - "extsprintf": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", - "integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=", - "dev": true - }, - "fast-deep-equal": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", - "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", - "dev": true - }, - "fast-json-stable-stringify": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", - "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", - "dev": true - }, - "fast-levenshtein": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", - "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=", - "dev": true - }, - "fastest-levenshtein": { - "version": "1.0.12", - "resolved": "https://registry.npmjs.org/fastest-levenshtein/-/fastest-levenshtein-1.0.12.tgz", - "integrity": "sha512-On2N+BpYJ15xIC974QNVuYGMOlEVt4s0EOI3wwMqOmK1fdDY+FN/zltPV8vosq4ad4c/gJ1KHScUn/6AWIgiow==" - }, - "file-entry-cache": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz", - "integrity": "sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==", - "dev": true, - "requires": { - "flat-cache": "^3.0.4" - } - }, - "file-uri-to-path": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", - "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==", - "dev": true - }, - "fill-range": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", - "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", - "dev": true, - "requires": { - "to-regex-range": "^5.0.1" - } - }, - "find-cache-dir": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-3.3.1.tgz", - "integrity": "sha512-t2GDMt3oGC/v+BMwzmllWDuJF/xcDtE5j/fCGbqDD7OLuJkj0cfh1YSA5VKPvwMeLFLNDBkwOKZ2X85jGLVftQ==", - "dev": true, - "requires": { - "commondir": "^1.0.1", - "make-dir": "^3.0.2", - "pkg-dir": "^4.1.0" - }, - "dependencies": { - "find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", - "dev": true, - "requires": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" - } - }, - "locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", - "dev": true, - "requires": { - "p-locate": "^4.1.0" - } - }, - "p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "dev": true, - "requires": { - "p-try": "^2.0.0" - } - }, - "p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", - "dev": true, - "requires": { - "p-limit": "^2.2.0" - } - }, - "p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "dev": true - }, - "path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true - }, - "pkg-dir": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz", - "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==", - "dev": true, - "requires": { - "find-up": "^4.0.0" - } - } - } - }, - "findit": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/findit/-/findit-2.0.0.tgz", - "integrity": "sha1-ZQnwEmr0wXhVHPqZOU4DLhOk1W4=", - "dev": true - }, - "flat-cache": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.0.4.tgz", - "integrity": "sha512-dm9s5Pw7Jc0GvMYbshN6zchCA9RgQlzzEZX3vylR9IqFfS8XciblUXOKfW6SiuJ0e13eDYZoZV5wdrev7P3Nwg==", - "dev": true, - "requires": { - "flatted": "^3.1.0", - "rimraf": "^3.0.2" - } - }, - "flatted": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.1.1.tgz", - "integrity": "sha512-zAoAQiudy+r5SvnSw3KJy5os/oRJYHzrzja/tBDqrZtNhUw8bt6y8OBzMWcjWr+8liV8Eb6yOhw8WZ7VFZ5ZzA==", - "dev": true - }, - "flow-parser": { - "version": "0.166.1", - "resolved": "https://registry.npmjs.org/flow-parser/-/flow-parser-0.166.1.tgz", - "integrity": "sha512-7iJ1cPcOYL/eOPGpGPaxwW8MytKGeXSnfvJA0uIvymXI4MnjjhZLWz1qPIqj2hfYJ7p/yXssbv7k2H3C90cyDw==", - "dev": true, - "optional": true, - "peer": true - }, - "flow-remove-types": { - "version": "2.166.1", - "resolved": "https://registry.npmjs.org/flow-remove-types/-/flow-remove-types-2.166.1.tgz", - "integrity": "sha512-PR3iOoNgEakzeHxEnem9TctSnLzkmpGByFUDKpY6N6MGx/Jft/irJREPTsCZ5SOZ//YVcwX0BbfjL3WeXhJdAg==", - "dev": true, - "optional": true, - "peer": true, - "requires": { - "flow-parser": "^0.166.1", - "pirates": "^3.0.2", - "vlq": "^0.2.1" - } - }, - "foreground-child": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-2.0.0.tgz", - "integrity": "sha512-dCIq9FpEcyQyXKCkyzmlPTFNgrCzPudOe+mhvJU5zAtlBnGVy2yKxtfsxK2tQBThwq225jcvBjpw1Gr40uzZCA==", - "dev": true, - "requires": { - "cross-spawn": "^7.0.0", - "signal-exit": "^3.0.2" - } - }, - "forever-agent": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", - "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=", - "dev": true - }, - "form-data": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", - "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", - "dev": true, - "requires": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.8", - "mime-types": "^2.1.12" - } - }, - "fromentries": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/fromentries/-/fromentries-1.3.2.tgz", - "integrity": "sha512-cHEpEQHUg0f8XdtZCc2ZAhrHzKzT0MrFUTcvx+hfxYu7rGMDc5SKoXFh+n4YigxsHXRzc6OrCshdR1bWH6HHyg==", - "dev": true - }, - "fs-access": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/fs-access/-/fs-access-2.0.0.tgz", - "integrity": "sha512-Vt45hBKJrYDQeAD9ja43liw8JfK75uB7XexIXWEtDKwFLQNmzmvuulh28hRxexxuFm0zsGGq7nISGQSK6KnGrA==", - "dev": true, - "requires": { - "null-check": "^1.0.0" - } - }, - "fs-constants": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz", - "integrity": "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==", - "dev": true - }, - "fs-exists-cached": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs-exists-cached/-/fs-exists-cached-1.0.0.tgz", - "integrity": "sha1-zyVVTKBQ3EmuZla0HeQiWJidy84=", - "dev": true - }, - "fs-minipass": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", - "integrity": "sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==", - "requires": { - "minipass": "^3.0.0" - } - }, - "fs.realpath": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" - }, - "fsevents": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", - "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", - "dev": true, - "optional": true - }, - "function-bind": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", - "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" - }, - "function-loop": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/function-loop/-/function-loop-2.0.1.tgz", - "integrity": "sha512-ktIR+O6i/4h+j/ZhZJNdzeI4i9lEPeEK6UPR2EVyTVBqOwcU3Za9xYKLH64ZR9HmcROyRrOkizNyjjtWJzDDkQ==", - "dev": true - }, - "functional-red-black-tree": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz", - "integrity": "sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc=", - "dev": true - }, - "gauge": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/gauge/-/gauge-4.0.1.tgz", - "integrity": "sha512-zJ4jePUHR8cceduZ53b6temRalyGpkC2Kc2r3ecNphmL+uWNoJ3YcOcUjpbG6WwoE/Ef6/+aEZz63neI2WIa1Q==", - "requires": { - "ansi-regex": "^5.0.1", - "aproba": "^1.0.3 || ^2.0.0", - "color-support": "^1.1.2", - "console-control-strings": "^1.0.0", - "has-unicode": "^2.0.1", - "signal-exit": "^3.0.0", - "string-width": "^4.2.3", - "strip-ansi": "^6.0.1", - "wide-align": "^1.1.2" - }, - "dependencies": { - "ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==" - }, - "is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==" - }, - "string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "requires": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - } - }, - "strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "requires": { - "ansi-regex": "^5.0.1" - } - } - } - }, - "gensync": { - "version": "1.0.0-beta.2", - "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", - "integrity": "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==", - "dev": true - }, - "get-caller-file": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "dev": true - }, - "get-func-name": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", - "integrity": "sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=", - "dev": true - }, - "get-intrinsic": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz", - "integrity": "sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q==", - "dev": true, - "requires": { - "function-bind": "^1.1.1", - "has": "^1.0.3", - "has-symbols": "^1.0.1" - } - }, - "get-package-type": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", - "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==", - "dev": true - }, - "get-symbol-description": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", - "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", - "dev": true, - "requires": { - "call-bind": "^1.0.2", - "get-intrinsic": "^1.1.1" - } - }, - "getpass": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", - "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0" - } - }, - "github-from-package": { - "version": "0.0.0", - "resolved": "https://registry.npmjs.org/github-from-package/-/github-from-package-0.0.0.tgz", - "integrity": "sha1-l/tdlr/eiXMxPyDoKI75oWf6ZM4=", - "dev": true - }, - "glob": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", - "integrity": "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==", - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - } - }, - "glob-parent": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", - "dev": true, - "requires": { - "is-glob": "^4.0.1" - } - }, - "globals": { - "version": "11.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", - "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", - "dev": true - }, - "graceful-fs": { - "version": "4.2.9", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.9.tgz", - "integrity": "sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ==" - }, - "har-schema": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz", - "integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=", - "dev": true - }, - "har-validator": { - "version": "5.1.5", - "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.5.tgz", - "integrity": "sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w==", - "dev": true, - "requires": { - "ajv": "^6.12.3", - "har-schema": "^2.0.0" - } - }, - "has": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", - "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", - "requires": { - "function-bind": "^1.1.1" - } - }, - "has-bigints": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.1.tgz", - "integrity": "sha512-LSBS2LjbNBTf6287JEbEzvJgftkF5qFkmCo9hDRpAzKhUOlJ+hx8dd4USs00SgsUNwc4617J9ki5YtEClM2ffA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" - }, - "has-symbols": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.2.tgz", - "integrity": "sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw==", - "dev": true - }, - "has-tostringtag": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", - "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", - "dev": true, - "requires": { - "has-symbols": "^1.0.2" - } - }, - "has-unicode": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", - "integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk=" - }, - "hasha": { - "version": "5.2.2", - "resolved": "https://registry.npmjs.org/hasha/-/hasha-5.2.2.tgz", - "integrity": "sha512-Hrp5vIK/xr5SkeN2onO32H0MgNZ0f17HRNH39WfL0SYUNOTZ5Lz1TJ8Pajo/87dYGEFlLMm7mIc/k/s6Bvz9HQ==", - "dev": true, - "requires": { - "is-stream": "^2.0.0", - "type-fest": "^0.8.0" - } - }, - "hast-to-hyperscript": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/hast-to-hyperscript/-/hast-to-hyperscript-9.0.1.tgz", - "integrity": "sha512-zQgLKqF+O2F72S1aa4y2ivxzSlko3MAvxkwG8ehGmNiqd98BIN3JM1rAJPmplEyLmGLO2QZYJtIneOSZ2YbJuA==", - "dev": true, - "requires": { - "@types/unist": "^2.0.3", - "comma-separated-tokens": "^1.0.0", - "property-information": "^5.3.0", - "space-separated-tokens": "^1.0.0", - "style-to-object": "^0.3.0", - "unist-util-is": "^4.0.0", - "web-namespaces": "^1.0.0" - } - }, - "hast-util-from-parse5": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/hast-util-from-parse5/-/hast-util-from-parse5-6.0.1.tgz", - "integrity": "sha512-jeJUWiN5pSxW12Rh01smtVkZgZr33wBokLzKLwinYOUfSzm1Nl/c3GUGebDyOKjdsRgMvoVbV0VpAcpjF4NrJA==", - "dev": true, - "requires": { - "@types/parse5": "^5.0.0", - "hastscript": "^6.0.0", - "property-information": "^5.0.0", - "vfile": "^4.0.0", - "vfile-location": "^3.2.0", - "web-namespaces": "^1.0.0" - } - }, - "hast-util-parse-selector": { - "version": "2.2.5", - "resolved": "https://registry.npmjs.org/hast-util-parse-selector/-/hast-util-parse-selector-2.2.5.tgz", - "integrity": "sha512-7j6mrk/qqkSehsM92wQjdIgWM2/BW61u/53G6xmC8i1OmEdKLHbk419QKQUjz6LglWsfqoiHmyMRkP1BGjecNQ==", - "dev": true - }, - "hast-util-raw": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/hast-util-raw/-/hast-util-raw-6.0.1.tgz", - "integrity": "sha512-ZMuiYA+UF7BXBtsTBNcLBF5HzXzkyE6MLzJnL605LKE8GJylNjGc4jjxazAHUtcwT5/CEt6afRKViYB4X66dig==", - "dev": true, - "requires": { - "@types/hast": "^2.0.0", - "hast-util-from-parse5": "^6.0.0", - "hast-util-to-parse5": "^6.0.0", - "html-void-elements": "^1.0.0", - "parse5": "^6.0.0", - "unist-util-position": "^3.0.0", - "vfile": "^4.0.0", - "web-namespaces": "^1.0.0", - "xtend": "^4.0.0", - "zwitch": "^1.0.0" - } - }, - "hast-util-to-parse5": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/hast-util-to-parse5/-/hast-util-to-parse5-6.0.0.tgz", - "integrity": "sha512-Lu5m6Lgm/fWuz8eWnrKezHtVY83JeRGaNQ2kn9aJgqaxvVkFCZQBEhgodZUDUvoodgyROHDb3r5IxAEdl6suJQ==", - "dev": true, - "requires": { - "hast-to-hyperscript": "^9.0.0", - "property-information": "^5.0.0", - "web-namespaces": "^1.0.0", - "xtend": "^4.0.0", - "zwitch": "^1.0.0" - } - }, - "hastscript": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/hastscript/-/hastscript-6.0.0.tgz", - "integrity": "sha512-nDM6bvd7lIqDUiYEiu5Sl/+6ReP0BMk/2f4U/Rooccxkj0P5nm+acM5PrGJ/t5I8qPGiqZSE6hVAwZEdZIvP4w==", - "dev": true, - "requires": { - "@types/hast": "^2.0.0", - "comma-separated-tokens": "^1.0.0", - "hast-util-parse-selector": "^2.0.0", - "property-information": "^5.0.0", - "space-separated-tokens": "^1.0.0" - } - }, - "hosted-git-info": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", - "integrity": "sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==", - "requires": { - "lru-cache": "^6.0.0" - } - }, - "html-encoding-sniffer": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/html-encoding-sniffer/-/html-encoding-sniffer-3.0.0.tgz", - "integrity": "sha512-oWv4T4yJ52iKrufjnyZPkrN0CH3QnrUqdB6In1g5Fe1mia8GmF36gnfNySxoZtxD5+NmYw1EElVXiBk93UeskA==", - "dev": true, - "requires": { - "whatwg-encoding": "^2.0.0" - } - }, - "html-escaper": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz", - "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", - "dev": true - }, - "html-void-elements": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/html-void-elements/-/html-void-elements-1.0.5.tgz", - "integrity": "sha512-uE/TxKuyNIcx44cIWnjr/rfIATDH7ZaOMmstu0CwhFG1Dunhlp4OC6/NMbhiwoq5BpW0ubi303qnEk/PZj614w==", - "dev": true - }, - "http-cache-semantics": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.0.tgz", - "integrity": "sha512-carPklcUh7ROWRK7Cv27RPtdhYhUsela/ue5/jKzjegVvXDqM2ILE9Q2BGn9JZJh1g87cp56su/FgQSzcWS8cQ==" - }, - "http-proxy-agent": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz", - "integrity": "sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==", - "requires": { - "@tootallnate/once": "2", - "agent-base": "6", - "debug": "4" - } - }, - "http-signature": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz", - "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0", - "jsprim": "^1.2.2", - "sshpk": "^1.7.0" - } - }, - "https-proxy-agent": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.0.tgz", - "integrity": "sha512-EkYm5BcKUGiduxzSt3Eppko+PiNWNEpa4ySk9vTC6wDsQJW9rHSa+UhGNJoRYp7bz6Ht1eaRIa6QaJqO5rCFbA==", - "requires": { - "agent-base": "6", - "debug": "4" - } - }, - "humanize-ms": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/humanize-ms/-/humanize-ms-1.2.1.tgz", - "integrity": "sha1-xG4xWaKT9riW2ikxbYtv6Lt5u+0=", - "requires": { - "ms": "^2.0.0" - } - }, - "iconv-lite": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", - "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", - "devOptional": true, - "requires": { - "safer-buffer": ">= 2.1.2 < 3.0.0" - } - }, - "ieee754": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", - "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", - "dev": true - }, - "ignore": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz", - "integrity": "sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg==", - "dev": true - }, - "ignore-walk": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/ignore-walk/-/ignore-walk-4.0.1.tgz", - "integrity": "sha512-rzDQLaW4jQbh2YrOFlJdCtX8qgJTehFRYiUB2r1osqTeDzV/3+Jh8fz1oAPzUThf3iku8Ds4IDqawI5d8mUiQw==", - "requires": { - "minimatch": "^3.0.4" - } - }, - "import-fresh": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", - "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", - "dev": true, - "requires": { - "parent-module": "^1.0.0", - "resolve-from": "^4.0.0" - } - }, - "imurmurhash": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=" - }, - "indent-string": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz", - "integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==" - }, - "infer-owner": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/infer-owner/-/infer-owner-1.0.4.tgz", - "integrity": "sha512-IClj+Xz94+d7irH5qRyfJonOdfTzuDaifE6ZPWfx0N0+/ATZCbuTPq2prFl526urkQd90WyUKIh1DfBQ2hMz9A==" - }, - "inflight": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", - "requires": { - "once": "^1.3.0", - "wrappy": "1" - } - }, - "inherits": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" - }, - "ini": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ini/-/ini-2.0.0.tgz", - "integrity": "sha512-7PnF4oN3CvZF23ADhA5wRaYEQpJ8qygSkbtTXWBeXWXmEVRXK+1ITciHWwHhsjv1TmW0MgacIv6hEi5pX5NQdA==" - }, - "init-package-json": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/init-package-json/-/init-package-json-2.0.5.tgz", - "integrity": "sha512-u1uGAtEFu3VA6HNl/yUWw57jmKEMx8SKOxHhxjGnOFUiIlFnohKDFg4ZrPpv9wWqk44nDxGJAtqjdQFm+9XXQA==", - "requires": { - "npm-package-arg": "^8.1.5", - "promzard": "^0.3.0", - "read": "~1.0.1", - "read-package-json": "^4.1.1", - "semver": "^7.3.5", - "validate-npm-package-license": "^3.0.4", - "validate-npm-package-name": "^3.0.0" - } - }, - "inline-style-parser": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/inline-style-parser/-/inline-style-parser-0.1.1.tgz", - "integrity": "sha512-7NXolsK4CAS5+xvdj5OMMbI962hU/wvwoxk+LWR9Ek9bVtyuuYScDN6eS0rUm6TxApFpw7CX1o4uJzcd4AyD3Q==", - "dev": true - }, - "internal-slot": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.3.tgz", - "integrity": "sha512-O0DB1JC/sPyZl7cIo78n5dR7eUSwwpYPiXRhTzNxZVAMUuB8vlnRFyLxdrVToks6XPLVnFfbzaVd5WLjhgg+vA==", - "dev": true, - "requires": { - "get-intrinsic": "^1.1.0", - "has": "^1.0.3", - "side-channel": "^1.0.4" - } - }, - "ip": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/ip/-/ip-1.1.5.tgz", - "integrity": "sha1-vd7XARQpCCjAoDnnLvJfWq7ENUo=" - }, - "ip-regex": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ip-regex/-/ip-regex-4.3.0.tgz", - "integrity": "sha512-B9ZWJxHHOHUhUjCPrMpLD4xEq35bUTClHM1S6CBU5ixQnkZmwipwgc96vAd7AAGM9TGHvJR+Uss+/Ak6UphK+Q==" - }, - "is-alphabetical": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-alphabetical/-/is-alphabetical-1.0.4.tgz", - "integrity": "sha512-DwzsA04LQ10FHTZuL0/grVDk4rFoVH1pjAToYwBrHSxcrBIGQuXrQMtD5U1b0U2XVgKZCTLLP8u2Qxqhy3l2Vg==", - "dev": true - }, - "is-alphanumerical": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-alphanumerical/-/is-alphanumerical-1.0.4.tgz", - "integrity": "sha512-UzoZUr+XfVz3t3v4KyGEniVL9BDRoQtY7tOyrRybkVNjDFWyo1yhXNGrrBTQxp3ib9BLAWs7k2YKBQsFRkZG9A==", - "dev": true, - "requires": { - "is-alphabetical": "^1.0.0", - "is-decimal": "^1.0.0" - } - }, - "is-arguments": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", - "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", - "dev": true, - "requires": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" - } - }, - "is-bigint": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.2.tgz", - "integrity": "sha512-0JV5+SOCQkIdzjBK9buARcV804Ddu7A0Qet6sHi3FimE9ne6m4BGQZfRn+NZiXbBk4F4XmHfDZIipLj9pX8dSA==", - "dev": true - }, - "is-binary-path": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", - "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", - "dev": true, - "requires": { - "binary-extensions": "^2.0.0" - } - }, - "is-boolean-object": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.1.tgz", - "integrity": "sha512-bXdQWkECBUIAcCkeH1unwJLIpZYaa5VvuygSyS/c2lf719mTKZDU5UdDRlpd01UjADgmW8RfqaP+mRaVPdr/Ng==", - "dev": true, - "requires": { - "call-bind": "^1.0.2" - } - }, - "is-buffer": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.5.tgz", - "integrity": "sha512-i2R6zNFDwgEHJyQUtJEk0XFi1i0dPFn/oqjK3/vPCcDeJvW5NQ83V8QbicfF1SupOaB0h8ntgBC2YiE7dfyctQ==", - "dev": true - }, - "is-callable": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.4.tgz", - "integrity": "sha512-nsuwtxZfMX67Oryl9LCQ+upnC0Z0BgpwntpS89m1H/TLF0zNfzfLMV/9Wa/6MZsj0acpEjAO0KF1xT6ZdLl95w==", - "dev": true - }, - "is-cidr": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/is-cidr/-/is-cidr-4.0.2.tgz", - "integrity": "sha512-z4a1ENUajDbEl/Q6/pVBpTR1nBjjEE1X7qb7bmWYanNnPoKAvUCPFKeXV6Fe4mgTkWKBqiHIcwsI3SndiO5FeA==", - "requires": { - "cidr-regex": "^3.1.1" - } - }, - "is-core-module": { - "version": "2.8.1", - "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.8.1.tgz", - "integrity": "sha512-SdNCUs284hr40hFTFP6l0IfZ/RSrMXF3qgoRHd3/79unUTvrFO/JoXwkGm+5J/Oe3E/b5GsnG330uUNgRpu1PA==", - "requires": { - "has": "^1.0.3" - } - }, - "is-date-object": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.4.tgz", - "integrity": "sha512-/b4ZVsG7Z5XVtIxs/h9W8nvfLgSAyKYdtGWQLbqy6jA1icmgjf8WCoTKgeS4wy5tYaPePouzFMANbnj94c2Z+A==", - "dev": true - }, - "is-decimal": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-decimal/-/is-decimal-1.0.4.tgz", - "integrity": "sha512-RGdriMmQQvZ2aqaQq3awNA6dCGtKpiDFcOzrTWrDAT2MiWrKQVPmxLGHl7Y2nNu6led0kEyoX0enY0qXYsv9zw==", - "dev": true - }, - "is-extglob": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", - "dev": true - }, - "is-fullwidth-code-point": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", - "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=" - }, - "is-glob": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", - "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", - "dev": true, - "requires": { - "is-extglob": "^2.1.1" - } - }, - "is-hexadecimal": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-hexadecimal/-/is-hexadecimal-1.0.4.tgz", - "integrity": "sha512-gyPJuv83bHMpocVYoqof5VDiZveEoGoFL8m3BXNb2VW8Xs+rz9kqO8LOQ5DH6EsuvilT1ApazU0pyl+ytbPtlw==", - "dev": true - }, - "is-lambda": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-lambda/-/is-lambda-1.0.1.tgz", - "integrity": "sha1-PZh3iZ5qU+/AFgUEzeFfgubwYdU=" - }, - "is-negative-zero": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.1.tgz", - "integrity": "sha512-2z6JzQvZRa9A2Y7xC6dQQm4FSTSTNWjKIYYTt4246eMTJmIo0Q+ZyOsU66X8lxK1AbB92dFeglPLrhwpeRKO6w==", - "dev": true - }, - "is-number": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", - "dev": true - }, - "is-number-object": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.5.tgz", - "integrity": "sha512-RU0lI/n95pMoUKu9v1BZP5MBcZuNSVJkMkAG2dJqC4z2GlkGUNeH68SuHuBKBD/XFe+LHZ+f9BKkLET60Niedw==", - "dev": true - }, - "is-plain-obj": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz", - "integrity": "sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==", - "dev": true - }, - "is-potential-custom-element-name": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz", - "integrity": "sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ==", - "dev": true - }, - "is-regex": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", - "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", - "dev": true, - "requires": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" - } - }, - "is-shared-array-buffer": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.1.tgz", - "integrity": "sha512-IU0NmyknYZN0rChcKhRO1X8LYz5Isj/Fsqh8NJOSf+N/hCOTwy29F32Ik7a+QszE63IdvmwdTPDd6cZ5pg4cwA==", - "dev": true - }, - "is-stream": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.0.tgz", - "integrity": "sha512-XCoy+WlUr7d1+Z8GgSuXmpuUFC9fOhRXglJMx+dwLKTkL44Cjd4W1Z5P+BQZpr+cR93aGP4S/s7Ftw6Nd/kiEw==", - "dev": true - }, - "is-string": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", - "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", - "dev": true, - "requires": { - "has-tostringtag": "^1.0.0" - } - }, - "is-symbol": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", - "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", - "dev": true, - "requires": { - "has-symbols": "^1.0.2" - } - }, - "is-typedarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", - "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=" - }, - "is-weakref": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.1.tgz", - "integrity": "sha512-b2jKc2pQZjaeFYWEf7ScFj+Be1I+PXmlu572Q8coTXZ+LD/QQZ7ShPMst8h16riVgyXTQwUsFEl74mDvc/3MHQ==", - "dev": true, - "requires": { - "call-bind": "^1.0.0" - } - }, - "is-whitespace-character": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-whitespace-character/-/is-whitespace-character-1.0.4.tgz", - "integrity": "sha512-SDweEzfIZM0SJV0EUga669UTKlmL0Pq8Lno0QDQsPnvECB3IM2aP0gdx5TrU0A01MAPfViaZiI2V1QMZLaKK5w==", - "dev": true - }, - "is-windows": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz", - "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==", - "dev": true - }, - "is-word-character": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-word-character/-/is-word-character-1.0.4.tgz", - "integrity": "sha512-5SMO8RVennx3nZrqtKwCGyyetPE9VDba5ugvKLaD4KopPG5kR4mQ7tNt/r7feL5yt5h3lpuBbIUmCOG2eSzXHA==", - "dev": true - }, - "isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", - "dev": true - }, - "isexe": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=" - }, - "isstream": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", - "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=", - "dev": true - }, - "istanbul-lib-coverage": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.0.0.tgz", - "integrity": "sha512-UiUIqxMgRDET6eR+o5HbfRYP1l0hqkWOs7vNxC/mggutCMUIhWMm8gAHb8tHlyfD3/l6rlgNA5cKdDzEAf6hEg==", - "dev": true - }, - "istanbul-lib-hook": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/istanbul-lib-hook/-/istanbul-lib-hook-3.0.0.tgz", - "integrity": "sha512-Pt/uge1Q9s+5VAZ+pCo16TYMWPBIl+oaNIjgLQxcX0itS6ueeaA+pEfThZpH8WxhFgCiEb8sAJY6MdUKgiIWaQ==", - "dev": true, - "requires": { - "append-transform": "^2.0.0" - } - }, - "istanbul-lib-instrument": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-4.0.3.tgz", - "integrity": "sha512-BXgQl9kf4WTCPCCpmFGoJkz/+uhvm7h7PFKUYxh7qarQd3ER33vHG//qaE8eN25l07YqZPpHXU9I09l/RD5aGQ==", - "dev": true, - "requires": { - "@babel/core": "^7.7.5", - "@istanbuljs/schema": "^0.1.2", - "istanbul-lib-coverage": "^3.0.0", - "semver": "^6.3.0" - }, - "dependencies": { - "semver": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", - "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", - "dev": true - } - } - }, - "istanbul-lib-processinfo": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/istanbul-lib-processinfo/-/istanbul-lib-processinfo-2.0.2.tgz", - "integrity": "sha512-kOwpa7z9hme+IBPZMzQ5vdQj8srYgAtaRqeI48NGmAQ+/5yKiHLV0QbYqQpxsdEF0+w14SoB8YbnHKcXE2KnYw==", - "dev": true, - "requires": { - "archy": "^1.0.0", - "cross-spawn": "^7.0.0", - "istanbul-lib-coverage": "^3.0.0-alpha.1", - "make-dir": "^3.0.0", - "p-map": "^3.0.0", - "rimraf": "^3.0.0", - "uuid": "^3.3.3" - }, - "dependencies": { - "p-map": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-3.0.0.tgz", - "integrity": "sha512-d3qXVTF/s+W+CdJ5A29wywV2n8CQQYahlgz2bFiA+4eVNJbHJodPZ+/gXwPGh0bOqA+j8S+6+ckmvLGPk1QpxQ==", - "dev": true, - "requires": { - "aggregate-error": "^3.0.0" - } - } - } - }, - "istanbul-lib-report": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-3.0.0.tgz", - "integrity": "sha512-wcdi+uAKzfiGT2abPpKZ0hSU1rGQjUQnLvtY5MpQ7QCTahD3VODhcu4wcfY1YtkGaDD5yuydOLINXsfbus9ROw==", - "dev": true, - "requires": { - "istanbul-lib-coverage": "^3.0.0", - "make-dir": "^3.0.0", - "supports-color": "^7.1.0" - } - }, - "istanbul-lib-source-maps": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.0.tgz", - "integrity": "sha512-c16LpFRkR8vQXyHZ5nLpY35JZtzj1PQY1iZmesUbf1FZHbIupcWfjgOXBY9YHkLEQ6puz1u4Dgj6qmU/DisrZg==", - "dev": true, - "requires": { - "debug": "^4.1.1", - "istanbul-lib-coverage": "^3.0.0", - "source-map": "^0.6.1" - }, - "dependencies": { - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - } - } - }, - "istanbul-reports": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-3.0.2.tgz", - "integrity": "sha512-9tZvz7AiR3PEDNGiV9vIouQ/EAcqMXFmkcA1CDFTwOB98OZVDL0PH9glHotf5Ugp6GCOTypfzGWI/OqjWNCRUw==", - "dev": true, - "requires": { - "html-escaper": "^2.0.0", - "istanbul-lib-report": "^3.0.0" - } - }, - "jackspeak": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-1.4.1.tgz", - "integrity": "sha512-npN8f+M4+IQ8xD3CcWi3U62VQwKlT3Tj4GxbdT/fYTmeogD9eBF9OFdpoFG/VPNoshRjPUijdkp/p2XrzUHaVg==", - "dev": true, - "requires": { - "cliui": "^7.0.4" - } - }, - "js-tokens": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true - }, - "js-yaml": { - "version": "3.14.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", - "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", - "dev": true, - "requires": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" - } - }, - "jsbn": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", - "integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=", - "dev": true - }, - "jsdom": { - "version": "18.1.1", - "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-18.1.1.tgz", - "integrity": "sha512-NmJQbjQ/gpS/1at/ce3nCx89HbXL/f5OcenBe8wU1Eik0ROhyUc3LtmG3567dEHAGXkN8rmILW/qtCOPxPHQJw==", - "dev": true, - "requires": { - "abab": "^2.0.5", - "acorn": "^8.5.0", - "acorn-globals": "^6.0.0", - "cssom": "^0.5.0", - "cssstyle": "^2.3.0", - "data-urls": "^3.0.1", - "decimal.js": "^10.3.1", - "domexception": "^4.0.0", - "escodegen": "^2.0.0", - "form-data": "^4.0.0", - "html-encoding-sniffer": "^3.0.0", - "http-proxy-agent": "^5.0.0", - "https-proxy-agent": "^5.0.0", - "is-potential-custom-element-name": "^1.0.1", - "nwsapi": "^2.2.0", - "parse5": "6.0.1", - "saxes": "^5.0.1", - "symbol-tree": "^3.2.4", - "tough-cookie": "^4.0.0", - "w3c-hr-time": "^1.0.2", - "w3c-xmlserializer": "^3.0.0", - "webidl-conversions": "^7.0.0", - "whatwg-encoding": "^2.0.0", - "whatwg-mimetype": "^3.0.0", - "whatwg-url": "^10.0.0", - "ws": "^8.2.3", - "xml-name-validator": "^4.0.0" - }, - "dependencies": { - "acorn": { - "version": "8.5.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.5.0.tgz", - "integrity": "sha512-yXbYeFy+jUuYd3/CDcg2NkIYE991XYX/bje7LmjJigUciaeO1JR4XxXgCIV1/Zc/dRuFEyw1L0pbA+qynJkW5Q==", - "dev": true - } - } - }, - "jsesc": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", - "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", - "dev": true - }, - "json-parse-errback": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/json-parse-errback/-/json-parse-errback-2.0.1.tgz", - "integrity": "sha1-x6nCvjqFWzQvgqv8ibyFk1tYhPo=", - "dev": true - }, - "json-parse-even-better-errors": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", - "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==" - }, - "json-schema": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz", - "integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=", - "dev": true - }, - "json-schema-traverse": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", - "dev": true - }, - "json-stable-stringify-without-jsonify": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", - "integrity": "sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE=", - "dev": true - }, - "json-stringify-nice": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/json-stringify-nice/-/json-stringify-nice-1.1.4.tgz", - "integrity": "sha512-5Z5RFW63yxReJ7vANgW6eZFGWaQvnPE3WNmZoOJrSkGju2etKA2L5rrOa1sm877TVTFt57A80BH1bArcmlLfPw==" - }, - "json-stringify-safe": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", - "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=", - "dev": true - }, - "json5": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.0.tgz", - "integrity": "sha512-f+8cldu7X/y7RAJurMEJmdoKXGB/X550w2Nr3tTbezL6RwEE/iMcm+tZnXeoZtKuOq6ft8+CqzEkrIgx1fPoQA==", - "dev": true, - "requires": { - "minimist": "^1.2.5" - } - }, - "jsonparse": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/jsonparse/-/jsonparse-1.3.1.tgz", - "integrity": "sha1-P02uSpH6wxX3EGL4UhzCOfE2YoA=" - }, - "jsprim": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz", - "integrity": "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=", - "dev": true, - "requires": { - "assert-plus": "1.0.0", - "extsprintf": "1.3.0", - "json-schema": "0.2.3", - "verror": "1.10.0" - } - }, - "just-diff": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/just-diff/-/just-diff-5.0.1.tgz", - "integrity": "sha512-X00TokkRIDotUIf3EV4xUm6ELc/IkqhS/vPSHdWnsM5y0HoNMfEqrazizI7g78lpHvnRSRt/PFfKtRqJCOGIuQ==" - }, - "just-diff-apply": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/just-diff-apply/-/just-diff-apply-4.0.1.tgz", - "integrity": "sha512-AKOkzB5P6FkfP21UlZVX/OPXx/sC2GagpLX9cBxqHqDuRjwmZ/AJRKSNrB9jHPpRW1W1ONs6gly1gW46t055nQ==" - }, - "lcov-parse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/lcov-parse/-/lcov-parse-1.0.0.tgz", - "integrity": "sha1-6w1GtUER68VhrLTECO+TY73I9+A=", - "dev": true - }, - "levn": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", - "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", - "dev": true, - "requires": { - "prelude-ls": "^1.2.1", - "type-check": "~0.4.0" - } - }, - "libnpmaccess": { - "version": "file:workspaces/libnpmaccess", - "requires": { - "@npmcli/template-oss": "^2.4.2", - "aproba": "^2.0.0", - "minipass": "^3.1.1", - "nock": "^12.0.1", - "npm-package-arg": "^8.1.2", - "npm-registry-fetch": "^12.0.1", - "tap": "^15.1.0" - } - }, - "libnpmdiff": { - "version": "file:workspaces/libnpmdiff", - "requires": { - "@npmcli/disparity-colors": "^1.0.1", - "@npmcli/installed-package-contents": "^1.0.7", - "@npmcli/template-oss": "^2.4.2", - "binary-extensions": "^2.2.0", - "diff": "^5.0.0", - "eslint": "^8.1.0", - "minimatch": "^3.0.4", - "npm-package-arg": "^8.1.4", - "pacote": "^12.0.0", - "tap": "^15.0.9", - "tar": "^6.1.0" - } - }, - "libnpmexec": { - "version": "file:workspaces/libnpmexec", - "requires": { - "@npmcli/arborist": "^4.0.0", - "@npmcli/ci-detect": "^2.0.0", - "@npmcli/run-script": "^2.0.0", - "@npmcli/template-oss": "^2.4.2", - "bin-links": "^3.0.0", - "chalk": "^4.1.0", - "mkdirp-infer-owner": "^2.0.0", - "npm-package-arg": "^8.1.2", - "pacote": "^12.0.0", - "proc-log": "^1.0.0", - "read": "^1.0.7", - "read-package-json-fast": "^2.0.2", - "tap": "^15.0.6", - "walk-up-path": "^1.0.0" - } - }, - "libnpmfund": { - "version": "file:workspaces/libnpmfund", - "requires": { - "@npmcli/arborist": "^4.0.0", - "@npmcli/template-oss": "^2.4.2", - "tap": "^15.0.9" - } - }, - "libnpmhook": { - "version": "file:workspaces/libnpmhook", - "requires": { - "@npmcli/template-oss": "^2.4.2", - "aproba": "^2.0.0", - "nock": "^9.6.1", - "npm-registry-fetch": "^12.0.1", - "tap": "^15.1.0" - }, - "dependencies": { - "debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", - "dev": true, - "requires": { - "ms": "^2.1.1" - } - }, - "mkdirp": { - "version": "0.5.5", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", - "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", - "dev": true, - "requires": { - "minimist": "^1.2.5" - } - }, - "nock": { - "version": "9.6.1", - "resolved": "https://registry.npmjs.org/nock/-/nock-9.6.1.tgz", - "integrity": "sha512-EDgl/WgNQ0C1BZZlASOQkQdE6tAWXJi8QQlugqzN64JJkvZ7ILijZuG24r4vCC7yOfnm6HKpne5AGExLGCeBWg==", - "dev": true, - "requires": { - "chai": "^4.1.2", - "debug": "^3.1.0", - "deep-equal": "^1.0.0", - "json-stringify-safe": "^5.0.1", - "lodash": "^4.17.5", - "mkdirp": "^0.5.0", - "propagate": "^1.0.0", - "qs": "^6.5.1", - "semver": "^5.5.0" - } - }, - "propagate": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/propagate/-/propagate-1.0.0.tgz", - "integrity": "sha1-AMLa7t2iDofjeCs0Stuhzd1q1wk=", - "dev": true - }, - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", - "dev": true - } - } - }, - "libnpmorg": { - "version": "file:workspaces/libnpmorg", - "requires": { - "@npmcli/template-oss": "^2.4.2", - "aproba": "^2.0.0", - "minipass": "^3.1.1", - "nock": "^12.0.1", - "npm-registry-fetch": "^12.0.1", - "tap": "^15.0.0" - } - }, - "libnpmpack": { - "version": "file:workspaces/libnpmpack", - "requires": { - "@npmcli/run-script": "^2.0.0", - "@npmcli/template-oss": "^2.4.2", - "nock": "^13.0.7", - "npm-package-arg": "^8.1.0", - "pacote": "^12.0.0", - "tap": "^15.0.0" - }, - "dependencies": { - "nock": { - "version": "13.2.1", - "resolved": "https://registry.npmjs.org/nock/-/nock-13.2.1.tgz", - "integrity": "sha512-CoHAabbqq/xZEknubuyQMjq6Lfi5b7RtK6SoNK6m40lebGp3yiMagWtIoYaw2s9sISD7wPuCfwFpivVHX/35RA==", - "dev": true, - "requires": { - "debug": "^4.1.0", - "json-stringify-safe": "^5.0.1", - "lodash.set": "^4.3.2", - "propagate": "^2.0.0" - } - } - } - }, - "libnpmpublish": { - "version": "file:workspaces/libnpmpublish", - "requires": { - "@npmcli/template-oss": "^2.4.2", - "libnpmpack": "^3.0.0", - "lodash.clonedeep": "^4.5.0", - "nock": "^12.0.2", - "normalize-package-data": "^3.0.2", - "npm-package-arg": "^8.1.2", - "npm-registry-fetch": "^12.0.1", - "semver": "^7.1.3", - "ssri": "^8.0.1", - "tap": "^15" - } - }, - "libnpmsearch": { - "version": "file:workspaces/libnpmsearch", - "requires": { - "@npmcli/template-oss": "^2.4.2", - "nock": "^9.6.1", - "npm-registry-fetch": "^12.0.1", - "tap": "^15" - }, - "dependencies": { - "debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", - "dev": true, - "requires": { - "ms": "^2.1.1" - } - }, - "mkdirp": { - "version": "0.5.5", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", - "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", - "dev": true, - "requires": { - "minimist": "^1.2.5" - } - }, - "nock": { - "version": "9.6.1", - "resolved": "https://registry.npmjs.org/nock/-/nock-9.6.1.tgz", - "integrity": "sha512-EDgl/WgNQ0C1BZZlASOQkQdE6tAWXJi8QQlugqzN64JJkvZ7ILijZuG24r4vCC7yOfnm6HKpne5AGExLGCeBWg==", - "dev": true, - "requires": { - "chai": "^4.1.2", - "debug": "^3.1.0", - "deep-equal": "^1.0.0", - "json-stringify-safe": "^5.0.1", - "lodash": "^4.17.5", - "mkdirp": "^0.5.0", - "propagate": "^1.0.0", - "qs": "^6.5.1", - "semver": "^5.5.0" - } - }, - "propagate": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/propagate/-/propagate-1.0.0.tgz", - "integrity": "sha1-AMLa7t2iDofjeCs0Stuhzd1q1wk=", - "dev": true - }, - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", - "dev": true - } - } - }, - "libnpmteam": { - "version": "file:workspaces/libnpmteam", - "requires": { - "@npmcli/template-oss": "^2.4.2", - "aproba": "^2.0.0", - "nock": "^12.0.1", - "npm-registry-fetch": "^12.0.1", - "tap": "^15" - } - }, - "libnpmversion": { - "version": "file:workspaces/libnpmversion", - "requires": { - "@npmcli/git": "^2.0.7", - "@npmcli/run-script": "^2.0.0", - "@npmcli/template-oss": "^2.4.2", - "json-parse-even-better-errors": "^2.3.1", - "require-inject": "^1.4.4", - "semver": "^7.3.5", - "stringify-package": "^1.0.1", - "tap": "^15" - } - }, - "libtap": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/libtap/-/libtap-1.1.4.tgz", - "integrity": "sha512-jM+QyAeRdVs1bJrNpjlu+l8gRdDkAehqls31AwSnqXghVLUP6nbYeU2Xfs2svYS7ZdksvnHvrxCKRBFEz/BCjA==", - "dev": true, - "requires": { - "async-hook-domain": "^2.0.4", - "bind-obj-methods": "^3.0.0", - "diff": "^4.0.2", - "function-loop": "^2.0.1", - "minipass": "^3.1.5", - "own-or": "^1.0.0", - "own-or-env": "^1.0.2", - "signal-exit": "^3.0.4", - "stack-utils": "^2.0.4", - "tap-parser": "^10.0.1", - "tap-yaml": "^1.0.0", - "tcompare": "^5.0.6", - "trivial-deferred": "^1.0.1", - "yapool": "^1.0.0" - }, - "dependencies": { - "diff": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", - "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", - "dev": true - } - } - }, - "licensee": { - "version": "8.2.0", - "resolved": "https://registry.npmjs.org/licensee/-/licensee-8.2.0.tgz", - "integrity": "sha512-Z5fQ+qP85N38klGijH0bXiWVlKqLKDMqsckKL+VcA+ZQ/DJK5cpIpvryGHtREaQ3Ah5jrgtXN8mHfII7UtlsJg==", - "dev": true, - "requires": { - "@blueoak/list": "^2.0.0", - "correct-license-metadata": "^1.0.1", - "docopt": "^0.6.2", - "fs-access": "^2.0.0", - "has": "^1.0.3", - "json-parse-errback": "^2.0.1", - "npm-license-corrections": "^1.0.0", - "read-package-tree": "^5.3.1", - "run-parallel": "^1.1.9", - "semver": "^6.3.0", - "simple-concat": "^1.0.0", - "spdx-expression-parse": "^3.0.0", - "spdx-expression-validate": "^2.0.0", - "spdx-osi": "^3.0.0", - "spdx-whitelisted": "^1.0.0" - }, - "dependencies": { - "semver": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", - "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", - "dev": true - } - } - }, - "lodash": { - "version": "4.17.21", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", - "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", - "dev": true - }, - "lodash.clonedeep": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz", - "integrity": "sha1-4j8/nE+Pvd6HJSnBBxhXoIblzO8=", - "dev": true - }, - "lodash.flattendeep": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz", - "integrity": "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=", - "dev": true - }, - "lodash.merge": { - "version": "4.6.2", - "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", - "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==", - "dev": true - }, - "lodash.set": { - "version": "4.3.2", - "resolved": "https://registry.npmjs.org/lodash.set/-/lodash.set-4.3.2.tgz", - "integrity": "sha1-2HV7HagH3eJIFrDWqEvqGnYjCyM=", - "dev": true - }, - "lodash.uniq": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/lodash.uniq/-/lodash.uniq-4.5.0.tgz", - "integrity": "sha1-0CJTc662Uq3BvILklFM5qEJ1R3M=", - "dev": true - }, - "log-driver": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/log-driver/-/log-driver-1.2.7.tgz", - "integrity": "sha512-U7KCmLdqsGHBLeWqYlFA0V0Sl6P08EE1ZrmA9cxjUE0WVqT9qnyVDPz1kzpFEP0jdJuFnasWIfSd7fsaNXkpbg==", - "dev": true - }, - "lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", - "requires": { - "yallist": "^4.0.0" - } - }, - "make-dir": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.1.0.tgz", - "integrity": "sha512-g3FeP20LNwhALb/6Cz6Dd4F2ngze0jz7tbzrD2wAV+o9FeNHe4rL+yK2md0J/fiSf1sa1ADhXqi5+oVwOM/eGw==", - "dev": true, - "requires": { - "semver": "^6.0.0" - }, - "dependencies": { - "semver": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", - "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", - "dev": true - } - } - }, - "make-error": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", - "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", - "dev": true, - "optional": true, - "peer": true - }, - "make-fetch-happen": { - "version": "10.0.3", - "resolved": "https://registry.npmjs.org/make-fetch-happen/-/make-fetch-happen-10.0.3.tgz", - "integrity": "sha512-CzarPHynPpHjhF5in/YapnO44rSZeYX5VCMfdXa99+gLwpbfFLh20CWa6dP/taV9Net9PWJwXNKtp/4ZTCQnag==", - "requires": { - "agentkeepalive": "^4.2.0", - "cacache": "^15.3.0", - "http-cache-semantics": "^4.1.0", - "http-proxy-agent": "^5.0.0", - "https-proxy-agent": "^5.0.0", - "is-lambda": "^1.0.1", - "lru-cache": "^7.3.1", - "minipass": "^3.1.6", - "minipass-collect": "^1.0.2", - "minipass-fetch": "^1.4.1", - "minipass-flush": "^1.0.5", - "minipass-pipeline": "^1.2.4", - "negotiator": "^0.6.3", - "promise-retry": "^2.0.1", - "socks-proxy-agent": "^6.1.1", - "ssri": "^8.0.1" - }, - "dependencies": { - "lru-cache": { - "version": "7.3.1", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-7.3.1.tgz", - "integrity": "sha512-nX1x4qUrKqwbIAhv4s9et4FIUVzNOpeY07bsjGUy8gwJrXH/wScImSQqXErmo/b2jZY2r0mohbLA9zVj7u1cNw==" - } - } - }, - "markdown-escapes": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/markdown-escapes/-/markdown-escapes-1.0.4.tgz", - "integrity": "sha512-8z4efJYk43E0upd0NbVXwgSTQs6cT3T06etieCMEg7dRbzCbxUCK/GHlX8mhHRDcp+OLlHkPKsvqQTCvsRl2cg==", - "dev": true - }, - "marked": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/marked/-/marked-0.7.0.tgz", - "integrity": "sha512-c+yYdCZJQrsRjTPhUx7VKkApw9bwDkNbHUKo1ovgcfDjb2kc8rLuRbIFyXL5WOEUwzSSKo3IXpph2K6DqB/KZg==", - "dev": true, - "peer": true - }, - "marked-man": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/marked-man/-/marked-man-0.7.0.tgz", - "integrity": "sha512-zxK5E4jbuARALc+fIUAanM2njVGnrd9YvKrqoDHUg2XwNLJijo39EzMIg59LecHBHsIHNtPqepqnJp4SmL/EVg==", - "dev": true, - "requires": {} - }, - "mdast-squeeze-paragraphs": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/mdast-squeeze-paragraphs/-/mdast-squeeze-paragraphs-4.0.0.tgz", - "integrity": "sha512-zxdPn69hkQ1rm4J+2Cs2j6wDEv7O17TfXTJ33tl/+JPIoEmtV9t2ZzBM5LPHE8QlHsmVD8t3vPKCyY3oH+H8MQ==", - "dev": true, - "requires": { - "unist-util-remove": "^2.0.0" - } - }, - "mdast-util-definitions": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-definitions/-/mdast-util-definitions-4.0.0.tgz", - "integrity": "sha512-k8AJ6aNnUkB7IE+5azR9h81O5EQ/cTDXtWdMq9Kk5KcEW/8ritU5CeLg/9HhOC++nALHBlaogJ5jz0Ybk3kPMQ==", - "dev": true, - "requires": { - "unist-util-visit": "^2.0.0" - } - }, - "mdast-util-to-hast": { - "version": "10.0.1", - "resolved": "https://registry.npmjs.org/mdast-util-to-hast/-/mdast-util-to-hast-10.0.1.tgz", - "integrity": "sha512-BW3LM9SEMnjf4HXXVApZMt8gLQWVNXc3jryK0nJu/rOXPOnlkUjmdkDlmxMirpbU9ILncGFIwLH/ubnWBbcdgA==", - "dev": true, - "requires": { - "@types/mdast": "^3.0.0", - "@types/unist": "^2.0.0", - "mdast-util-definitions": "^4.0.0", - "mdurl": "^1.0.0", - "unist-builder": "^2.0.0", - "unist-util-generated": "^1.0.0", - "unist-util-position": "^3.0.0", - "unist-util-visit": "^2.0.0" - } - }, - "mdurl": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/mdurl/-/mdurl-1.0.1.tgz", - "integrity": "sha1-/oWy7HWlkDfyrf7BAP1sYBdhFS4=", - "dev": true - }, - "mime-db": { - "version": "1.49.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.49.0.tgz", - "integrity": "sha512-CIc8j9URtOVApSFCQIF+VBkX1RwXp/oMMOrqdyXSBXq5RWNEsRfyj1kiRnQgmNXmHxPoFIxOroKA3zcU9P+nAA==", - "dev": true - }, - "mime-types": { - "version": "2.1.32", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.32.tgz", - "integrity": "sha512-hJGaVS4G4c9TSMYh2n6SQAGrC4RnfU+daP8G7cSCmaqNjiOoUY0VHCMS42pxnQmVF1GWwFhbHWn3RIxCqTmZ9A==", - "dev": true, - "requires": { - "mime-db": "1.49.0" - } - }, - "mimic-response": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-2.1.0.tgz", - "integrity": "sha512-wXqjST+SLt7R009ySCglWBCFpjUygmCIfD790/kVbiGmUgfYGuB14PiTd5DwVxSV4NcYHjzMkoj5LjQZwTQLEA==", - "dev": true - }, - "minify-registry-metadata": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/minify-registry-metadata/-/minify-registry-metadata-2.2.0.tgz", - "integrity": "sha512-kBVcTfDnYx9nL1U+6l6drCrZHPlkEoniLLud//nXxXvJAx0D7P4IHU2vkcCrLozoAPomiIX/CzaEXFm1CmT/8A==", - "dev": true - }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "requires": { - "brace-expansion": "^1.1.7" - } - }, - "minimist": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", - "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", - "dev": true - }, - "minipass": { - "version": "3.1.6", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.1.6.tgz", - "integrity": "sha512-rty5kpw9/z8SX9dmxblFA6edItUmwJgMeYDZRrwlIVN27i8gysGbznJwUggw2V/FVqFSDdWy040ZPS811DYAqQ==", - "requires": { - "yallist": "^4.0.0" - } - }, - "minipass-collect": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/minipass-collect/-/minipass-collect-1.0.2.tgz", - "integrity": "sha512-6T6lH0H8OG9kITm/Jm6tdooIbogG9e0tLgpY6mphXSm/A9u8Nq1ryBG+Qspiub9LjWlBPsPS3tWQ/Botq4FdxA==", - "requires": { - "minipass": "^3.0.0" - } - }, - "minipass-fetch": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/minipass-fetch/-/minipass-fetch-1.4.1.tgz", - "integrity": "sha512-CGH1eblLq26Y15+Azk7ey4xh0J/XfJfrCox5LDJiKqI2Q2iwOLOKrlmIaODiSQS8d18jalF6y2K2ePUm0CmShw==", - "requires": { - "encoding": "^0.1.12", - "minipass": "^3.1.0", - "minipass-sized": "^1.0.3", - "minizlib": "^2.0.0" - } - }, - "minipass-flush": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/minipass-flush/-/minipass-flush-1.0.5.tgz", - "integrity": "sha512-JmQSYYpPUqX5Jyn1mXaRwOda1uQ8HP5KAT/oDSLCzt1BYRhQU0/hDtsB1ufZfEEzMZ9aAVmsBw8+FWsIXlClWw==", - "requires": { - "minipass": "^3.0.0" - } - }, - "minipass-json-stream": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/minipass-json-stream/-/minipass-json-stream-1.0.1.tgz", - "integrity": "sha512-ODqY18UZt/I8k+b7rl2AENgbWE8IDYam+undIJONvigAz8KR5GWblsFTEfQs0WODsjbSXWlm+JHEv8Gr6Tfdbg==", - "requires": { - "jsonparse": "^1.3.1", - "minipass": "^3.0.0" - } - }, - "minipass-pipeline": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/minipass-pipeline/-/minipass-pipeline-1.2.4.tgz", - "integrity": "sha512-xuIq7cIOt09RPRJ19gdi4b+RiNvDFYe5JH+ggNvBqGqpQXcru3PcRmOZuHBKWK1Txf9+cQ+HMVN4d6z46LZP7A==", - "requires": { - "minipass": "^3.0.0" - } - }, - "minipass-sized": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/minipass-sized/-/minipass-sized-1.0.3.tgz", - "integrity": "sha512-MbkQQ2CTiBMlA2Dm/5cY+9SWFEN8pzzOXi6rlM5Xxq0Yqbda5ZQy9sU75a673FE9ZK0Zsbr6Y5iP6u9nktfg2g==", - "requires": { - "minipass": "^3.0.0" - } - }, - "minizlib": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-2.1.2.tgz", - "integrity": "sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==", - "requires": { - "minipass": "^3.0.0", - "yallist": "^4.0.0" - } - }, - "mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==" - }, - "mkdirp-classic": { - "version": "0.5.3", - "resolved": "https://registry.npmjs.org/mkdirp-classic/-/mkdirp-classic-0.5.3.tgz", - "integrity": "sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==", - "dev": true - }, - "mkdirp-infer-owner": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mkdirp-infer-owner/-/mkdirp-infer-owner-2.0.0.tgz", - "integrity": "sha512-sdqtiFt3lkOaYvTXSRIUjkIdPTcxgv5+fgqYE/5qgwdw12cOrAuzzgzvVExIkH/ul1oeHN3bCLOWSG3XOqbKKw==", - "requires": { - "chownr": "^2.0.0", - "infer-owner": "^1.0.4", - "mkdirp": "^1.0.3" - } - }, - "ms": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" - }, - "mute-stream": { - "version": "0.0.8", - "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.8.tgz", - "integrity": "sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==" - }, - "napi-build-utils": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/napi-build-utils/-/napi-build-utils-1.0.2.tgz", - "integrity": "sha512-ONmRUqK7zj7DWX0D9ADe03wbwOBZxNAfF20PlGfCWQcD3+/MakShIHrMqx9YwPTfxDdF1zLeL+RGZiR9kGMLdg==", - "dev": true - }, - "natural-compare": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", - "integrity": "sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=", - "dev": true - }, - "negotiator": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.3.tgz", - "integrity": "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==" - }, - "nock": { - "version": "12.0.3", - "resolved": "https://registry.npmjs.org/nock/-/nock-12.0.3.tgz", - "integrity": "sha512-QNb/j8kbFnKCiyqi9C5DD0jH/FubFGj5rt9NQFONXwQm3IPB0CULECg/eS3AU1KgZb/6SwUa4/DTRKhVxkGABw==", - "dev": true, - "requires": { - "debug": "^4.1.0", - "json-stringify-safe": "^5.0.1", - "lodash": "^4.17.13", - "propagate": "^2.0.0" - } - }, - "node-abi": { - "version": "2.30.0", - "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-2.30.0.tgz", - "integrity": "sha512-g6bZh3YCKQRdwuO/tSZZYJAw622SjsRfJ2X0Iy4sSOHZ34/sPPdVBn8fev2tj7njzLwuqPw9uMtGsGkO5kIQvg==", - "dev": true, - "requires": { - "semver": "^5.4.1" - }, - "dependencies": { - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", - "dev": true - } - } - }, - "node-addon-api": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-3.2.1.tgz", - "integrity": "sha512-mmcei9JghVNDYydghQmeDX8KoAm0FAiYyIcUt/N4nhyAipB17pllZQDOJD2fotxABnt4Mdz+dKTO7eftLg4d0A==", - "dev": true - }, - "node-gyp": { - "version": "8.4.1", - "resolved": "https://registry.npmjs.org/node-gyp/-/node-gyp-8.4.1.tgz", - "integrity": "sha512-olTJRgUtAb/hOXG0E93wZDs5YiJlgbXxTwQAFHyNlRsXQnYzUaF2aGgujZbw+hR8aF4ZG/rST57bWMWD16jr9w==", - "requires": { - "env-paths": "^2.2.0", - "glob": "^7.1.4", - "graceful-fs": "^4.2.6", - "make-fetch-happen": "^9.1.0", - "nopt": "^5.0.0", - "npmlog": "^6.0.0", - "rimraf": "^3.0.2", - "semver": "^7.3.5", - "tar": "^6.1.2", - "which": "^2.0.2" - }, - "dependencies": { - "@tootallnate/once": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-1.1.2.tgz", - "integrity": "sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==" - }, - "http-proxy-agent": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-4.0.1.tgz", - "integrity": "sha512-k0zdNgqWTGA6aeIRVpvfVob4fL52dTfaehylg0Y4UvSySvOq/Y+BOyPrgpUrA7HylqvU8vIZGsRuXmspskV0Tg==", - "requires": { - "@tootallnate/once": "1", - "agent-base": "6", - "debug": "4" - } - }, - "make-fetch-happen": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/make-fetch-happen/-/make-fetch-happen-9.1.0.tgz", - "integrity": "sha512-+zopwDy7DNknmwPQplem5lAZX/eCOzSvSNNcSKm5eVwTkOBzoktEfXsa9L23J/GIRhxRsaxzkPEhrJEpE2F4Gg==", - "requires": { - "agentkeepalive": "^4.1.3", - "cacache": "^15.2.0", - "http-cache-semantics": "^4.1.0", - "http-proxy-agent": "^4.0.1", - "https-proxy-agent": "^5.0.0", - "is-lambda": "^1.0.1", - "lru-cache": "^6.0.0", - "minipass": "^3.1.3", - "minipass-collect": "^1.0.2", - "minipass-fetch": "^1.3.2", - "minipass-flush": "^1.0.5", - "minipass-pipeline": "^1.2.4", - "negotiator": "^0.6.2", - "promise-retry": "^2.0.1", - "socks-proxy-agent": "^6.0.0", - "ssri": "^8.0.0" - } - } - } - }, - "node-modules-regexp": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz", - "integrity": "sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA=", - "dev": true, - "optional": true, - "peer": true - }, - "node-preload": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/node-preload/-/node-preload-0.2.1.tgz", - "integrity": "sha512-RM5oyBy45cLEoHqCeh+MNuFAxO0vTFBLskvQbOKnEE7YTTSN4tbN8QWDIPQ6L+WvKsB/qLEGpYe2ZZ9d4W9OIQ==", - "dev": true, - "requires": { - "process-on-spawn": "^1.0.0" - } - }, - "noop-logger": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/noop-logger/-/noop-logger-0.1.1.tgz", - "integrity": "sha1-lKKxYzxPExdVMAfYlm/Q6EG2pMI=", - "dev": true - }, - "nopt": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/nopt/-/nopt-5.0.0.tgz", - "integrity": "sha512-Tbj67rffqceeLpcRXrT7vKAN8CwfPeIBgM7E6iBkmKLV7bEMwpGgYLGv0jACUsECaa/vuxP0IjEont6umdMgtQ==", - "requires": { - "abbrev": "1" - } - }, - "normalize-package-data": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-3.0.3.tgz", - "integrity": "sha512-p2W1sgqij3zMMyRC067Dg16bfzVH+w7hyegmpIvZ4JNjqtGOVAIvLmjBx3yP7YTe9vKJgkoNOPjwQGogDoMXFA==", - "requires": { - "hosted-git-info": "^4.0.1", - "is-core-module": "^2.5.0", - "semver": "^7.3.4", - "validate-npm-package-license": "^3.0.1" - } - }, - "normalize-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", - "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", - "dev": true - }, - "npm-audit-report": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/npm-audit-report/-/npm-audit-report-2.1.5.tgz", - "integrity": "sha512-YB8qOoEmBhUH1UJgh1xFAv7Jg1d+xoNhsDYiFQlEFThEBui0W1vIz2ZK6FVg4WZjwEdl7uBQlm1jy3MUfyHeEw==", - "requires": { - "chalk": "^4.0.0" - } - }, - "npm-bundled": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/npm-bundled/-/npm-bundled-1.1.2.tgz", - "integrity": "sha512-x5DHup0SuyQcmL3s7Rx/YQ8sbw/Hzg0rj48eN0dV7hf5cmQq5PXIeioroH3raV1QC1yh3uTYuMThvEQF3iKgGQ==", - "requires": { - "npm-normalize-package-bin": "^1.0.1" - } - }, - "npm-install-checks": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/npm-install-checks/-/npm-install-checks-4.0.0.tgz", - "integrity": "sha512-09OmyDkNLYwqKPOnbI8exiOZU2GVVmQp7tgez2BPi5OZC8M82elDAps7sxC4l//uSUtotWqoEIDwjRvWH4qz8w==", - "requires": { - "semver": "^7.1.1" - } - }, - "npm-license-corrections": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/npm-license-corrections/-/npm-license-corrections-1.4.0.tgz", - "integrity": "sha512-elrOuaygiK9SDD1Rzl6gxbRSJgcClcNER5RvdilSwlHWurD2GTlTt8RHZDMKkwgfkDHTg2F7n10IrPqCzdCCcw==", - "dev": true - }, - "npm-normalize-package-bin": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/npm-normalize-package-bin/-/npm-normalize-package-bin-1.0.1.tgz", - "integrity": "sha512-EPfafl6JL5/rU+ot6P3gRSCpPDW5VmIzX959Ob1+ySFUuuYHWHekXpwdUZcKP5C+DS4GEtdJluwBjnsNDl+fSA==" - }, - "npm-package-arg": { - "version": "8.1.5", - "resolved": "https://registry.npmjs.org/npm-package-arg/-/npm-package-arg-8.1.5.tgz", - "integrity": "sha512-LhgZrg0n0VgvzVdSm1oiZworPbTxYHUJCgtsJW8mGvlDpxTM1vSJc3m5QZeUkhAHIzbz3VCHd/R4osi1L1Tg/Q==", - "requires": { - "hosted-git-info": "^4.0.1", - "semver": "^7.3.4", - "validate-npm-package-name": "^3.0.0" - } - }, - "npm-packlist": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-3.0.0.tgz", - "integrity": "sha512-L/cbzmutAwII5glUcf2DBRNY/d0TFd4e/FnaZigJV6JD85RHZXJFGwCndjMWiiViiWSsWt3tiOLpI3ByTnIdFQ==", - "requires": { - "glob": "^7.1.6", - "ignore-walk": "^4.0.1", - "npm-bundled": "^1.1.1", - "npm-normalize-package-bin": "^1.0.1" - } - }, - "npm-pick-manifest": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/npm-pick-manifest/-/npm-pick-manifest-6.1.1.tgz", - "integrity": "sha512-dBsdBtORT84S8V8UTad1WlUyKIY9iMsAmqxHbLdeEeBNMLQDlDWWra3wYUx9EBEIiG/YwAy0XyNHDd2goAsfuA==", - "requires": { - "npm-install-checks": "^4.0.0", - "npm-normalize-package-bin": "^1.0.1", - "npm-package-arg": "^8.1.2", - "semver": "^7.3.4" - } - }, - "npm-profile": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/npm-profile/-/npm-profile-6.0.0.tgz", - "integrity": "sha512-ZiwXx3Fq3wNqJMz+d4AVZ9X4xAw/0TqsvdiyDF5Y+h9lQ7AjYDOxY06lj7AP5vUBqB/7k/0oNFQOx03Ay0iHPw==", - "requires": { - "npm-registry-fetch": "^12.0.0" - } - }, - "npm-registry-fetch": { - "version": "12.0.2", - "resolved": "https://registry.npmjs.org/npm-registry-fetch/-/npm-registry-fetch-12.0.2.tgz", - "integrity": "sha512-Df5QT3RaJnXYuOwtXBXS9BWs+tHH2olvkCLh6jcR/b/u3DvPMlp3J0TvvYwplPKxHMOwfg287PYih9QqaVFoKA==", - "requires": { - "make-fetch-happen": "^10.0.1", - "minipass": "^3.1.6", - "minipass-fetch": "^1.4.1", - "minipass-json-stream": "^1.0.1", - "minizlib": "^2.1.2", - "npm-package-arg": "^8.1.5" - } - }, - "npm-user-validate": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/npm-user-validate/-/npm-user-validate-1.0.1.tgz", - "integrity": "sha512-uQwcd/tY+h1jnEaze6cdX/LrhWhoBxfSknxentoqmIuStxUExxjWd3ULMLFPiFUrZKbOVMowH6Jq2FRWfmhcEw==" - }, - "npmlog": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-6.0.1.tgz", - "integrity": "sha512-BTHDvY6nrRHuRfyjt1MAufLxYdVXZfd099H4+i1f0lPywNQyI4foeNXJRObB/uy+TYqUW0vAD9gbdSOXPst7Eg==", - "requires": { - "are-we-there-yet": "^3.0.0", - "console-control-strings": "^1.1.0", - "gauge": "^4.0.0", - "set-blocking": "^2.0.0" - } - }, - "null-check": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/null-check/-/null-check-1.0.0.tgz", - "integrity": "sha1-l33/1xdgErnsMNKjnbXPcqBDnt0=", - "dev": true - }, - "number-is-nan": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", - "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", - "dev": true - }, - "nwsapi": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.0.tgz", - "integrity": "sha512-h2AatdwYH+JHiZpv7pt/gSX1XoRGb7L/qSIeuqA6GwYoF9w1vP1cw42TO0aI2pNyshRK5893hNSl+1//vHK7hQ==", - "dev": true - }, - "nyc": { - "version": "15.1.0", - "resolved": "https://registry.npmjs.org/nyc/-/nyc-15.1.0.tgz", - "integrity": "sha512-jMW04n9SxKdKi1ZMGhvUTHBN0EICCRkHemEoE5jm6mTYcqcdas0ATzgUgejlQUHMvpnOZqGB5Xxsv9KxJW1j8A==", - "dev": true, - "requires": { - "@istanbuljs/load-nyc-config": "^1.0.0", - "@istanbuljs/schema": "^0.1.2", - "caching-transform": "^4.0.0", - "convert-source-map": "^1.7.0", - "decamelize": "^1.2.0", - "find-cache-dir": "^3.2.0", - "find-up": "^4.1.0", - "foreground-child": "^2.0.0", - "get-package-type": "^0.1.0", - "glob": "^7.1.6", - "istanbul-lib-coverage": "^3.0.0", - "istanbul-lib-hook": "^3.0.0", - "istanbul-lib-instrument": "^4.0.0", - "istanbul-lib-processinfo": "^2.0.2", - "istanbul-lib-report": "^3.0.0", - "istanbul-lib-source-maps": "^4.0.0", - "istanbul-reports": "^3.0.2", - "make-dir": "^3.0.0", - "node-preload": "^0.2.1", - "p-map": "^3.0.0", - "process-on-spawn": "^1.0.0", - "resolve-from": "^5.0.0", - "rimraf": "^3.0.0", - "signal-exit": "^3.0.2", - "spawn-wrap": "^2.0.0", - "test-exclude": "^6.0.0", - "yargs": "^15.0.2" - }, - "dependencies": { - "find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", - "dev": true, - "requires": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" - } - }, - "locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", - "dev": true, - "requires": { - "p-locate": "^4.1.0" - } - }, - "p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "dev": true, - "requires": { - "p-try": "^2.0.0" - } - }, - "p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", - "dev": true, - "requires": { - "p-limit": "^2.2.0" - } - }, - "p-map": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-3.0.0.tgz", - "integrity": "sha512-d3qXVTF/s+W+CdJ5A29wywV2n8CQQYahlgz2bFiA+4eVNJbHJodPZ+/gXwPGh0bOqA+j8S+6+ckmvLGPk1QpxQ==", - "dev": true, - "requires": { - "aggregate-error": "^3.0.0" - } - }, - "p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "dev": true - }, - "path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true - }, - "resolve-from": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", - "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", - "dev": true - } - } - }, - "oauth-sign": { - "version": "0.9.0", - "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz", - "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==", - "dev": true - }, - "object-assign": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", - "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", - "dev": true - }, - "object-inspect": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.11.1.tgz", - "integrity": "sha512-If7BjFlpkzzBeV1cqgT3OSWT3azyoxDGajR+iGnFBfVV2EWyDyWaZZW2ERDjUaY2QM8i5jI3Sj7mhsM4DDAqWA==", - "dev": true - }, - "object-is": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.1.5.tgz", - "integrity": "sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==", - "dev": true, - "requires": { - "call-bind": "^1.0.2", - "define-properties": "^1.1.3" - } - }, - "object-keys": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", - "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", - "dev": true - }, - "object.assign": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.2.tgz", - "integrity": "sha512-ixT2L5THXsApyiUPYKmW+2EHpXXe5Ii3M+f4e+aJFAHao5amFRW6J0OO6c/LU8Be47utCx2GL89hxGB6XSmKuQ==", - "dev": true, - "requires": { - "call-bind": "^1.0.0", - "define-properties": "^1.1.3", - "has-symbols": "^1.0.1", - "object-keys": "^1.1.1" - } - }, - "object.getownpropertydescriptors": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.2.tgz", - "integrity": "sha512-WtxeKSzfBjlzL+F9b7M7hewDzMwy+C8NRssHd1YrNlzHzIDrXcXiNOMrezdAEM4UXixgV+vvnyBeN7Rygl2ttQ==", - "dev": true, - "requires": { - "call-bind": "^1.0.2", - "define-properties": "^1.1.3", - "es-abstract": "^1.18.0-next.2" - } - }, - "once": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", - "requires": { - "wrappy": "1" - } - }, - "opener": { - "version": "1.5.2", - "resolved": "https://registry.npmjs.org/opener/-/opener-1.5.2.tgz", - "integrity": "sha512-ur5UIdyw5Y7yEj9wLzhqXiy6GZ3Mwx0yGI+5sMn2r0N0v3cKJvUmFH5yPP+WXh9e0xfyzyJX95D8l088DNFj7A==" - }, - "optionator": { - "version": "0.9.1", - "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.1.tgz", - "integrity": "sha512-74RlY5FCnhq4jRxVUPKDaRwrVNXMqsGsiW6AJw4XK8hmtm10wC0ypZBLw5IIp85NZMr91+qd1RvvENwg7jjRFw==", - "dev": true, - "requires": { - "deep-is": "^0.1.3", - "fast-levenshtein": "^2.0.6", - "levn": "^0.4.1", - "prelude-ls": "^1.2.1", - "type-check": "^0.4.0", - "word-wrap": "^1.2.3" - } - }, - "own-or": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/own-or/-/own-or-1.0.0.tgz", - "integrity": "sha1-Tod/vtqaLsgAD7wLyuOWRe6L+Nw=", - "dev": true - }, - "own-or-env": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/own-or-env/-/own-or-env-1.0.2.tgz", - "integrity": "sha512-NQ7v0fliWtK7Lkb+WdFqe6ky9XAzYmlkXthQrBbzlYbmFKoAYbDDcwmOm6q8kOuwSRXW8bdL5ORksploUJmWgw==", - "dev": true, - "requires": { - "own-or": "^1.0.0" - } - }, - "p-map": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-4.0.0.tgz", - "integrity": "sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==", - "requires": { - "aggregate-error": "^3.0.0" - } - }, - "package-hash": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/package-hash/-/package-hash-4.0.0.tgz", - "integrity": "sha512-whdkPIooSu/bASggZ96BWVvZTRMOFxnyUG5PnTSGKoJE2gd5mbVNmR2Nj20QFzxYYgAXpoqC+AiXzl+UMRh7zQ==", - "dev": true, - "requires": { - "graceful-fs": "^4.1.15", - "hasha": "^5.0.0", - "lodash.flattendeep": "^4.4.0", - "release-zalgo": "^1.0.0" - } - }, - "pacote": { - "version": "12.0.3", - "resolved": "https://registry.npmjs.org/pacote/-/pacote-12.0.3.tgz", - "integrity": "sha512-CdYEl03JDrRO3x18uHjBYA9TyoW8gy+ThVcypcDkxPtKlw76e4ejhYB6i9lJ+/cebbjpqPW/CijjqxwDTts8Ow==", - "requires": { - "@npmcli/git": "^2.1.0", - "@npmcli/installed-package-contents": "^1.0.6", - "@npmcli/promise-spawn": "^1.2.0", - "@npmcli/run-script": "^2.0.0", - "cacache": "^15.0.5", - "chownr": "^2.0.0", - "fs-minipass": "^2.1.0", - "infer-owner": "^1.0.4", - "minipass": "^3.1.3", - "mkdirp": "^1.0.3", - "npm-package-arg": "^8.0.1", - "npm-packlist": "^3.0.0", - "npm-pick-manifest": "^6.0.0", - "npm-registry-fetch": "^12.0.0", - "promise-retry": "^2.0.1", - "read-package-json-fast": "^2.0.1", - "rimraf": "^3.0.2", - "ssri": "^8.0.1", - "tar": "^6.1.0" - } - }, - "parent-module": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", - "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", - "dev": true, - "requires": { - "callsites": "^3.0.0" - } - }, - "parse-conflict-json": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/parse-conflict-json/-/parse-conflict-json-2.0.1.tgz", - "integrity": "sha512-Y7nYw+QaSGBto1LB9lgwOR05Rtz5SbuTf+Oe7HJ6SYQ/DHsvRjQ8O03oWdJbvkt6GzDWospgyZbGmjDYL0sDgA==", - "requires": { - "json-parse-even-better-errors": "^2.3.1", - "just-diff": "^5.0.1", - "just-diff-apply": "^4.0.1" - } - }, - "parse-entities": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/parse-entities/-/parse-entities-2.0.0.tgz", - "integrity": "sha512-kkywGpCcRYhqQIchaWqZ875wzpS/bMKhz5HnN3p7wveJTkTtyAB/AlnS0f8DFSqYW1T82t6yEAkEcB+A1I3MbQ==", - "dev": true, - "requires": { - "character-entities": "^1.0.0", - "character-entities-legacy": "^1.0.0", - "character-reference-invalid": "^1.0.0", - "is-alphanumerical": "^1.0.0", - "is-decimal": "^1.0.0", - "is-hexadecimal": "^1.0.0" - } - }, - "parse5": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/parse5/-/parse5-6.0.1.tgz", - "integrity": "sha512-Ofn/CTFzRGTTxwpNEs9PP93gXShHcTq255nzRYSKe8AkVpZY7e1fpmTfOyoIvjP5HG7Z2ZM7VS9PPhQGW2pOpw==", - "dev": true - }, - "path-is-absolute": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" - }, - "path-key": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", - "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", - "dev": true - }, - "path-parse": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", - "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", - "dev": true - }, - "pathval": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz", - "integrity": "sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ==", - "dev": true - }, - "performance-now": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", - "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=", - "dev": true - }, - "picomatch": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.0.tgz", - "integrity": "sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw==", - "dev": true - }, - "pirates": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/pirates/-/pirates-3.0.2.tgz", - "integrity": "sha512-c5CgUJq6H2k6MJz72Ak1F5sN9n9wlSlJyEnwvpm9/y3WB4E3pHBDT2c6PEiS1vyJvq2bUxUAIu0EGf8Cx4Ic7Q==", - "dev": true, - "optional": true, - "peer": true, - "requires": { - "node-modules-regexp": "^1.0.0" - } - }, - "platform": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/platform/-/platform-1.3.6.tgz", - "integrity": "sha512-fnWVljUchTro6RiCFvCXBbNhJc2NijN7oIQxbwsyL0buWJPG85v81ehlHI9fXrJsMNgTofEoWIQeClKpgxFLrg==", - "dev": true - }, - "prebuild-install": { - "version": "6.1.2", - "resolved": "https://registry.npmjs.org/prebuild-install/-/prebuild-install-6.1.2.tgz", - "integrity": "sha512-PzYWIKZeP+967WuKYXlTOhYBgGOvTRSfaKI89XnfJ0ansRAH7hDU45X+K+FZeI1Wb/7p/NnuctPH3g0IqKUuSQ==", - "dev": true, - "requires": { - "detect-libc": "^1.0.3", - "expand-template": "^2.0.3", - "github-from-package": "0.0.0", - "minimist": "^1.2.3", - "mkdirp-classic": "^0.5.3", - "napi-build-utils": "^1.0.1", - "node-abi": "^2.21.0", - "noop-logger": "^0.1.1", - "npmlog": "^4.0.1", - "pump": "^3.0.0", - "rc": "^1.2.7", - "simple-get": "^3.0.3", - "tar-fs": "^2.0.0", - "tunnel-agent": "^0.6.0" - }, - "dependencies": { - "aproba": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", - "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==", - "dev": true - }, - "are-we-there-yet": { - "version": "1.1.7", - "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.7.tgz", - "integrity": "sha512-nxwy40TuMiUGqMyRHgCSWZ9FM4VAoRP4xUYSTv5ImRog+h9yISPbVH7H8fASCIzYn9wlEv4zvFL7uKDMCFQm3g==", - "dev": true, - "requires": { - "delegates": "^1.0.0", - "readable-stream": "^2.0.6" - } - }, - "gauge": { - "version": "2.7.4", - "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", - "integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=", - "dev": true, - "requires": { - "aproba": "^1.0.3", - "console-control-strings": "^1.0.0", - "has-unicode": "^2.0.0", - "object-assign": "^4.1.0", - "signal-exit": "^3.0.0", - "string-width": "^1.0.1", - "strip-ansi": "^3.0.1", - "wide-align": "^1.1.0" - } - }, - "is-fullwidth-code-point": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", - "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", - "dev": true, - "requires": { - "number-is-nan": "^1.0.0" - } - }, - "npmlog": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz", - "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==", - "dev": true, - "requires": { - "are-we-there-yet": "~1.1.2", - "console-control-strings": "~1.1.0", - "gauge": "~2.7.3", - "set-blocking": "~2.0.0" - } - }, - "readable-stream": { - "version": "2.3.7", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", - "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", - "dev": true, - "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" - } - }, - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true - }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, - "requires": { - "safe-buffer": "~5.1.0" - } - }, - "string-width": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", - "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", - "dev": true, - "requires": { - "code-point-at": "^1.0.0", - "is-fullwidth-code-point": "^1.0.0", - "strip-ansi": "^3.0.0" - } - } - } - }, - "prelude-ls": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", - "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==", - "dev": true - }, - "proc-log": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/proc-log/-/proc-log-1.0.0.tgz", - "integrity": "sha512-aCk8AO51s+4JyuYGg3Q/a6gnrlDO09NpVWePtjp7xwphcoQ04x5WAfCyugcsbLooWcMJ87CLkD4+604IckEdhg==" - }, - "process-nextick-args": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", - "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", - "dev": true - }, - "process-on-spawn": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/process-on-spawn/-/process-on-spawn-1.0.0.tgz", - "integrity": "sha512-1WsPDsUSMmZH5LeMLegqkPDrsGgsWwk1Exipy2hvB0o/F0ASzbpIctSCcZIK1ykJvtTJULEH+20WOFjMvGnCTg==", - "dev": true, - "requires": { - "fromentries": "^1.2.0" - } - }, - "progress": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz", - "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==", - "dev": true - }, - "promise-all-reject-late": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz", - "integrity": "sha512-vuf0Lf0lOxyQREH7GDIOUMLS7kz+gs8i6B+Yi8dC68a2sychGrHTJYghMBD6k7eUcH0H5P73EckCA48xijWqXw==" - }, - "promise-call-limit": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-call-limit/-/promise-call-limit-1.0.1.tgz", - "integrity": "sha512-3+hgaa19jzCGLuSCbieeRsu5C2joKfYn8pY6JAuXFRVfF4IO+L7UPpFWNTeWT9pM7uhskvbPPd/oEOktCn317Q==" - }, - "promise-inflight": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-inflight/-/promise-inflight-1.0.1.tgz", - "integrity": "sha1-mEcocL8igTL8vdhoEputEsPAKeM=" - }, - "promise-retry": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/promise-retry/-/promise-retry-2.0.1.tgz", - "integrity": "sha512-y+WKFlBR8BGXnsNlIHFGPZmyDf3DFMoLhaflAnyZgV6rG6xu+JwesTo2Q9R6XwYmtmwAFCkAk3e35jEdoeh/3g==", - "requires": { - "err-code": "^2.0.2", - "retry": "^0.12.0" - } - }, - "promzard": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/promzard/-/promzard-0.3.0.tgz", - "integrity": "sha1-JqXW7ox97kyxIggwWs+5O6OCqe4=", - "requires": { - "read": "1" - } - }, - "propagate": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/propagate/-/propagate-2.0.1.tgz", - "integrity": "sha512-vGrhOavPSTz4QVNuBNdcNXePNdNMaO1xj9yBeH1ScQPjk/rhg9sSlCXPhMkFuaNNW/syTvYqsnbIJxMBfRbbag==", - "dev": true - }, - "property-information": { - "version": "5.6.0", - "resolved": "https://registry.npmjs.org/property-information/-/property-information-5.6.0.tgz", - "integrity": "sha512-YUHSPk+A30YPv+0Qf8i9Mbfe/C0hdPXk1s1jPVToV8pk8BQtpw10ct89Eo7OWkutrwqvT0eicAxlOg3dOAu8JA==", - "dev": true, - "requires": { - "xtend": "^4.0.0" - } - }, - "psl": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/psl/-/psl-1.8.0.tgz", - "integrity": "sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ==", - "dev": true - }, - "pump": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", - "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", - "dev": true, - "requires": { - "end-of-stream": "^1.1.0", - "once": "^1.3.1" - } - }, - "punycode": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", - "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", - "dev": true - }, - "qrcode-terminal": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/qrcode-terminal/-/qrcode-terminal-0.12.0.tgz", - "integrity": "sha512-EXtzRZmC+YGmGlDFbXKxQiMZNwCLEO6BANKXG4iCtSIM0yqc/pappSx3RIKr4r0uh5JsBckOXeKrB3Iz7mdQpQ==" - }, - "qs": { - "version": "6.5.2", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", - "integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==", - "dev": true - }, - "queue-microtask": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", - "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", - "dev": true - }, - "rc": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", - "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", - "dev": true, - "requires": { - "deep-extend": "^0.6.0", - "ini": "~1.3.0", - "minimist": "^1.2.0", - "strip-json-comments": "~2.0.1" - }, - "dependencies": { - "ini": { - "version": "1.3.8", - "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", - "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", - "dev": true - }, - "strip-json-comments": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", - "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", - "dev": true - } - } - }, - "read": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/read/-/read-1.0.7.tgz", - "integrity": "sha1-s9oZvQUkMal2cdRKQmNK33ELQMQ=", - "requires": { - "mute-stream": "~0.0.4" - } - }, - "read-cmd-shim": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/read-cmd-shim/-/read-cmd-shim-2.0.0.tgz", - "integrity": "sha512-HJpV9bQpkl6KwjxlJcBoqu9Ba0PQg8TqSNIOrulGt54a0uup0HtevreFHzYzkm0lpnleRdNBzXznKrgxglEHQw==" - }, - "read-package-json": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/read-package-json/-/read-package-json-4.1.1.tgz", - "integrity": "sha512-P82sbZJ3ldDrWCOSKxJT0r/CXMWR0OR3KRh55SgKo3p91GSIEEC32v3lSHAvO/UcH3/IoL7uqhOFBduAnwdldw==", - "requires": { - "glob": "^7.1.1", - "json-parse-even-better-errors": "^2.3.0", - "normalize-package-data": "^3.0.0", - "npm-normalize-package-bin": "^1.0.0" - } - }, - "read-package-json-fast": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/read-package-json-fast/-/read-package-json-fast-2.0.3.tgz", - "integrity": "sha512-W/BKtbL+dUjTuRL2vziuYhp76s5HZ9qQhd/dKfWIZveD0O40453QNyZhC0e63lqZrAQ4jiOapVoeJ7JrszenQQ==", - "requires": { - "json-parse-even-better-errors": "^2.3.0", - "npm-normalize-package-bin": "^1.0.1" - } - }, - "read-package-tree": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/read-package-tree/-/read-package-tree-5.3.1.tgz", - "integrity": "sha512-mLUDsD5JVtlZxjSlPPx1RETkNjjvQYuweKwNVt1Sn8kP5Jh44pvYuUHCp6xSVDZWbNxVxG5lyZJ921aJH61sTw==", - "dev": true, - "requires": { - "read-package-json": "^2.0.0", - "readdir-scoped-modules": "^1.0.0", - "util-promisify": "^2.1.0" - }, - "dependencies": { - "hosted-git-info": { - "version": "2.8.9", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.9.tgz", - "integrity": "sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==", - "dev": true - }, - "normalize-package-data": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz", - "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", - "dev": true, - "requires": { - "hosted-git-info": "^2.1.4", - "resolve": "^1.10.0", - "semver": "2 || 3 || 4 || 5", - "validate-npm-package-license": "^3.0.1" - } - }, - "read-package-json": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/read-package-json/-/read-package-json-2.1.2.tgz", - "integrity": "sha512-D1KmuLQr6ZSJS0tW8hf3WGpRlwszJOXZ3E8Yd/DNRaM5d+1wVRZdHlpGBLAuovjr28LbWvjpWkBHMxpRGGjzNA==", - "dev": true, - "requires": { - "glob": "^7.1.1", - "json-parse-even-better-errors": "^2.3.0", - "normalize-package-data": "^2.0.0", - "npm-normalize-package-bin": "^1.0.0" - } - }, - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", - "dev": true - } - } - }, - "readable-stream": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.0.tgz", - "integrity": "sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA==", - "requires": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" - } - }, - "readdir-scoped-modules": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/readdir-scoped-modules/-/readdir-scoped-modules-1.1.0.tgz", - "integrity": "sha512-asaikDeqAQg7JifRsZn1NJZXo9E+VwlyCfbkZhwyISinqk5zNS6266HS5kah6P0SaQKGF6SkNnZVHUzHFYxYDw==", - "requires": { - "debuglog": "^1.0.1", - "dezalgo": "^1.0.0", - "graceful-fs": "^4.1.2", - "once": "^1.3.0" - } - }, - "readdirp": { - "version": "3.5.0", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.5.0.tgz", - "integrity": "sha512-cMhu7c/8rdhkHXWsY+osBhfSy0JikwpHK/5+imo+LpeasTF8ouErHrlYkwT0++njiyuDvc7OFY5T3ukvZ8qmFQ==", - "dev": true, - "requires": { - "picomatch": "^2.2.1" - } - }, - "regexp.prototype.flags": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.3.1.tgz", - "integrity": "sha512-JiBdRBq91WlY7uRJ0ds7R+dU02i6LKi8r3BuQhNXn+kmeLN+EfHhfjqMRis1zJxnlu88hq/4dx0P2OP3APRTOA==", - "dev": true, - "requires": { - "call-bind": "^1.0.2", - "define-properties": "^1.1.3" - } - }, - "regexpp": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-3.2.0.tgz", - "integrity": "sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg==", - "dev": true - }, - "release-zalgo": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/release-zalgo/-/release-zalgo-1.0.0.tgz", - "integrity": "sha1-CXALflB0Mpc5Mw5TXFqQ+2eFFzA=", - "dev": true, - "requires": { - "es6-error": "^4.0.1" - } - }, - "remark-footnotes": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/remark-footnotes/-/remark-footnotes-2.0.0.tgz", - "integrity": "sha512-3Clt8ZMH75Ayjp9q4CorNeyjwIxHFcTkaektplKGl2A1jNGEUey8cKL0ZC5vJwfcD5GFGsNLImLG/NGzWIzoMQ==", - "dev": true - }, - "remark-mdx": { - "version": "1.6.22", - "resolved": "https://registry.npmjs.org/remark-mdx/-/remark-mdx-1.6.22.tgz", - "integrity": "sha512-phMHBJgeV76uyFkH4rvzCftLfKCr2RZuF+/gmVcaKrpsihyzmhXjA0BEMDaPTXG5y8qZOKPVo83NAOX01LPnOQ==", - "dev": true, - "requires": { - "@babel/core": "7.12.9", - "@babel/helper-plugin-utils": "7.10.4", - "@babel/plugin-proposal-object-rest-spread": "7.12.1", - "@babel/plugin-syntax-jsx": "7.12.1", - "@mdx-js/util": "1.6.22", - "is-alphabetical": "1.0.4", - "remark-parse": "8.0.3", - "unified": "9.2.0" - }, - "dependencies": { - "@babel/helper-plugin-utils": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz", - "integrity": "sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg==", - "dev": true - } - } - }, - "remark-parse": { - "version": "8.0.3", - "resolved": "https://registry.npmjs.org/remark-parse/-/remark-parse-8.0.3.tgz", - "integrity": "sha512-E1K9+QLGgggHxCQtLt++uXltxEprmWzNfg+MxpfHsZlrddKzZ/hZyWHDbK3/Ap8HJQqYJRXP+jHczdL6q6i85Q==", - "dev": true, - "requires": { - "ccount": "^1.0.0", - "collapse-white-space": "^1.0.2", - "is-alphabetical": "^1.0.0", - "is-decimal": "^1.0.0", - "is-whitespace-character": "^1.0.0", - "is-word-character": "^1.0.0", - "markdown-escapes": "^1.0.0", - "parse-entities": "^2.0.0", - "repeat-string": "^1.5.4", - "state-toggle": "^1.0.0", - "trim": "0.0.1", - "trim-trailing-lines": "^1.0.0", - "unherit": "^1.0.4", - "unist-util-remove-position": "^2.0.0", - "vfile-location": "^3.0.0", - "xtend": "^4.0.1" - } - }, - "remark-squeeze-paragraphs": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/remark-squeeze-paragraphs/-/remark-squeeze-paragraphs-4.0.0.tgz", - "integrity": "sha512-8qRqmL9F4nuLPIgl92XUuxI3pFxize+F1H0e/W3llTk0UsjJaj01+RrirkMw7P21RKe4X6goQhYRSvNWX+70Rw==", - "dev": true, - "requires": { - "mdast-squeeze-paragraphs": "^4.0.0" - } - }, - "repeat-string": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", - "integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc=", - "dev": true - }, - "request": { - "version": "2.88.2", - "resolved": "https://registry.npmjs.org/request/-/request-2.88.2.tgz", - "integrity": "sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw==", - "dev": true, - "requires": { - "aws-sign2": "~0.7.0", - "aws4": "^1.8.0", - "caseless": "~0.12.0", - "combined-stream": "~1.0.6", - "extend": "~3.0.2", - "forever-agent": "~0.6.1", - "form-data": "~2.3.2", - "har-validator": "~5.1.3", - "http-signature": "~1.2.0", - "is-typedarray": "~1.0.0", - "isstream": "~0.1.2", - "json-stringify-safe": "~5.0.1", - "mime-types": "~2.1.19", - "oauth-sign": "~0.9.0", - "performance-now": "^2.1.0", - "qs": "~6.5.2", - "safe-buffer": "^5.1.2", - "tough-cookie": "~2.5.0", - "tunnel-agent": "^0.6.0", - "uuid": "^3.3.2" - }, - "dependencies": { - "form-data": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz", - "integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==", - "dev": true, - "requires": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.6", - "mime-types": "^2.1.12" - } - }, - "tough-cookie": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.5.0.tgz", - "integrity": "sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g==", - "dev": true, - "requires": { - "psl": "^1.1.28", - "punycode": "^2.1.1" - } - } - } - }, - "require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", - "dev": true - }, - "require-inject": { - "version": "1.4.4", - "resolved": "https://registry.npmjs.org/require-inject/-/require-inject-1.4.4.tgz", - "integrity": "sha512-5Y5ctRN84+I4iOZO61gm+48tgP/6Hcd3VZydkaEM3MCuOvnHRsTJYQBOc01faI/Z9at5nsCAJVHhlfPA6Pc0Og==", - "dev": true, - "requires": { - "caller": "^1.0.1" - } - }, - "require-main-filename": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", - "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", - "dev": true - }, - "resolve": { - "version": "1.20.0", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.20.0.tgz", - "integrity": "sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A==", - "dev": true, - "requires": { - "is-core-module": "^2.2.0", - "path-parse": "^1.0.6" - } - }, - "resolve-from": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", - "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", - "dev": true - }, - "retry": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", - "integrity": "sha1-G0KmJmoh8HQh0bC1S33BZ7AcATs=" - }, - "rimraf": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", - "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", - "requires": { - "glob": "^7.1.3" - } - }, - "run-parallel": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", - "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", - "dev": true, - "requires": { - "queue-microtask": "^1.2.2" - } - }, - "safe-buffer": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" - }, - "safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "devOptional": true - }, - "saxes": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/saxes/-/saxes-5.0.1.tgz", - "integrity": "sha512-5LBh1Tls8c9xgGjw3QrMwETmTMVk0oFgvrFSvWx62llR2hcEInrKNZ2GZCCuuy2lvWrdl5jhbpeqc5hRYKFOcw==", - "dev": true, - "requires": { - "xmlchars": "^2.2.0" - } - }, - "semver": { - "version": "7.3.5", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.5.tgz", - "integrity": "sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ==", - "requires": { - "lru-cache": "^6.0.0" - } - }, - "set-blocking": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=" - }, - "shebang-command": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", - "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", - "dev": true, - "requires": { - "shebang-regex": "^3.0.0" - } - }, - "shebang-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", - "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", - "dev": true - }, - "side-channel": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", - "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", - "dev": true, - "requires": { - "call-bind": "^1.0.0", - "get-intrinsic": "^1.0.2", - "object-inspect": "^1.9.0" - } - }, - "signal-exit": { - "version": "3.0.6", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.6.tgz", - "integrity": "sha512-sDl4qMFpijcGw22U5w63KmD3cZJfBuFlVNbVMKje2keoKML7X2UzWbc4XrmEbDwg0NXJc3yv4/ox7b+JWb57kQ==" - }, - "simple-concat": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/simple-concat/-/simple-concat-1.0.1.tgz", - "integrity": "sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==", - "dev": true - }, - "simple-get": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/simple-get/-/simple-get-3.1.1.tgz", - "integrity": "sha512-CQ5LTKGfCpvE1K0n2us+kuMPbk/q0EKl82s4aheV9oXjFEz6W/Y7oQFVJuU6QG77hRT4Ghb5RURteF5vnWjupA==", - "dev": true, - "requires": { - "decompress-response": "^4.2.0", - "once": "^1.3.1", - "simple-concat": "^1.0.0" - } - }, - "smart-buffer": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/smart-buffer/-/smart-buffer-4.2.0.tgz", - "integrity": "sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg==" - }, - "socks": { - "version": "2.6.1", - "resolved": "https://registry.npmjs.org/socks/-/socks-2.6.1.tgz", - "integrity": "sha512-kLQ9N5ucj8uIcxrDwjm0Jsqk06xdpBjGNQtpXy4Q8/QY2k+fY7nZH8CARy+hkbG+SGAovmzzuauCpBlb8FrnBA==", - "requires": { - "ip": "^1.1.5", - "smart-buffer": "^4.1.0" - } - }, - "socks-proxy-agent": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/socks-proxy-agent/-/socks-proxy-agent-6.1.1.tgz", - "integrity": "sha512-t8J0kG3csjA4g6FTbsMOWws+7R7vuRC8aQ/wy3/1OWmsgwA68zs/+cExQ0koSitUDXqhufF/YJr9wtNMZHw5Ew==", - "requires": { - "agent-base": "^6.0.2", - "debug": "^4.3.1", - "socks": "^2.6.1" - } - }, - "source-map": { - "version": "0.5.7", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", - "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", - "dev": true - }, - "source-map-support": { - "version": "0.5.19", - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", - "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", - "dev": true, - "requires": { - "buffer-from": "^1.0.0", - "source-map": "^0.6.0" - }, - "dependencies": { - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - } - } - }, - "space-separated-tokens": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/space-separated-tokens/-/space-separated-tokens-1.1.5.tgz", - "integrity": "sha512-q/JSVd1Lptzhf5bkYm4ob4iWPjx0KiRe3sRFBNrVqbJkFaBm5vbbowy1mymoPNLRa52+oadOhJ+K49wsSeSjTA==", - "dev": true - }, - "spawk": { - "version": "1.7.1", - "resolved": "https://registry.npmjs.org/spawk/-/spawk-1.7.1.tgz", - "integrity": "sha512-qkPqVdPp5ICEeSYKB/qCkwIBB0IWQuouEvYenQvpTq15fqSQgutpH453NjEImrpCWTwQwj2bQjGp8YGHapEiWw==", - "dev": true - }, - "spawn-wrap": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/spawn-wrap/-/spawn-wrap-2.0.0.tgz", - "integrity": "sha512-EeajNjfN9zMnULLwhZZQU3GWBoFNkbngTUPfaawT4RkMiviTxcX0qfhVbGey39mfctfDHkWtuecgQ8NJcyQWHg==", - "dev": true, - "requires": { - "foreground-child": "^2.0.0", - "is-windows": "^1.0.2", - "make-dir": "^3.0.0", - "rimraf": "^3.0.0", - "signal-exit": "^3.0.2", - "which": "^2.0.1" - } - }, - "spdx-compare": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/spdx-compare/-/spdx-compare-1.0.0.tgz", - "integrity": "sha512-C1mDZOX0hnu0ep9dfmuoi03+eOdDoz2yvK79RxbcrVEG1NO1Ph35yW102DHWKN4pk80nwCgeMmSY5L25VE4D9A==", - "dev": true, - "requires": { - "array-find-index": "^1.0.2", - "spdx-expression-parse": "^3.0.0", - "spdx-ranges": "^2.0.0" - } - }, - "spdx-correct": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.1.tgz", - "integrity": "sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w==", - "requires": { - "spdx-expression-parse": "^3.0.0", - "spdx-license-ids": "^3.0.0" - } - }, - "spdx-exceptions": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz", - "integrity": "sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A==" - }, - "spdx-expression-parse": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz", - "integrity": "sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==", - "requires": { - "spdx-exceptions": "^2.1.0", - "spdx-license-ids": "^3.0.0" - } - }, - "spdx-expression-validate": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/spdx-expression-validate/-/spdx-expression-validate-2.0.0.tgz", - "integrity": "sha512-b3wydZLM+Tc6CFvaRDBOF9d76oGIHNCLYFeHbftFXUWjnfZWganmDmvtM5sm1cRwJc/VDBMLyGGrsLFd1vOxbg==", - "dev": true, - "requires": { - "spdx-expression-parse": "^3.0.0" - } - }, - "spdx-license-ids": { - "version": "3.0.11", - "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.11.tgz", - "integrity": "sha512-Ctl2BrFiM0X3MANYgj3CkygxhRmr9mi6xhejbdO960nF6EDJApTYpn0BQnDKlnNBULKiCN1n3w9EBkHK8ZWg+g==" - }, - "spdx-osi": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/spdx-osi/-/spdx-osi-3.0.0.tgz", - "integrity": "sha512-7DZMaD/rNHWGf82qWOazBsLXQsaLsoJb9RRjhEUQr5o86kw3A1ErGzSdvaXl+KalZyKkkU5T2a5NjCCutAKQSw==", - "dev": true - }, - "spdx-ranges": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/spdx-ranges/-/spdx-ranges-2.1.1.tgz", - "integrity": "sha512-mcdpQFV7UDAgLpXEE/jOMqvK4LBoO0uTQg0uvXUewmEFhpiZx5yJSZITHB8w1ZahKdhfZqP5GPEOKLyEq5p8XA==", - "dev": true - }, - "spdx-whitelisted": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/spdx-whitelisted/-/spdx-whitelisted-1.0.0.tgz", - "integrity": "sha512-X4FOpUCvZuo42MdB1zAZ/wdX4N0lLcWDozf2KYFVDgtLv8Lx+f31LOYLP2/FcwTzsPi64bS/VwKqklI4RBletg==", - "dev": true, - "requires": { - "spdx-compare": "^1.0.0", - "spdx-ranges": "^2.0.0" - } - }, - "sprintf-js": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", - "dev": true - }, - "sshpk": { - "version": "1.16.1", - "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz", - "integrity": "sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==", - "dev": true, - "requires": { - "asn1": "~0.2.3", - "assert-plus": "^1.0.0", - "bcrypt-pbkdf": "^1.0.0", - "dashdash": "^1.12.0", - "ecc-jsbn": "~0.1.1", - "getpass": "^0.1.1", - "jsbn": "~0.1.0", - "safer-buffer": "^2.0.2", - "tweetnacl": "~0.14.0" - } - }, - "ssri": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/ssri/-/ssri-8.0.1.tgz", - "integrity": "sha512-97qShzy1AiyxvPNIkLWoGua7xoQzzPjQ0HAH4B0rWKo7SZ6USuPcrUiAFrws0UH8RrbWmgq3LMTObhPIHbbBeQ==", - "requires": { - "minipass": "^3.1.1" - } - }, - "stack-utils": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-2.0.5.tgz", - "integrity": "sha512-xrQcmYhOsn/1kX+Vraq+7j4oE2j/6BFscZ0etmYg81xuM8Gq0022Pxb8+IqgOFUIaxHs0KaSb7T1+OegiNrNFA==", - "dev": true, - "requires": { - "escape-string-regexp": "^2.0.0" - }, - "dependencies": { - "escape-string-regexp": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz", - "integrity": "sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==", - "dev": true - } - } - }, - "state-toggle": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/state-toggle/-/state-toggle-1.0.3.tgz", - "integrity": "sha512-d/5Z4/2iiCnHw6Xzghyhb+GcmF89bxwgXG60wjIiZaxnymbyOmI8Hk4VqHXiVVp6u2ysaskFfXg3ekCj4WNftQ==", - "dev": true - }, - "string_decoder": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", - "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", - "requires": { - "safe-buffer": "~5.2.0" - } - }, - "string-width": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", - "requires": { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" - }, - "strip-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "requires": { - "ansi-regex": "^3.0.0" - } - } - } - }, - "string.prototype.trimend": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.4.tgz", - "integrity": "sha512-y9xCjw1P23Awk8EvTpcyL2NIr1j7wJ39f+k6lvRnSMz+mz9CGz9NYPelDk42kOz6+ql8xjfK8oYzy3jAP5QU5A==", - "dev": true, - "requires": { - "call-bind": "^1.0.2", - "define-properties": "^1.1.3" - } - }, - "string.prototype.trimstart": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.4.tgz", - "integrity": "sha512-jh6e984OBfvxS50tdY2nRZnoC5/mLFKOREQfw8t5yytkoUsJRNxvI/E39qu1sD0OtWI3OC0XgKSmcWwziwYuZw==", - "dev": true, - "requires": { - "call-bind": "^1.0.2", - "define-properties": "^1.1.3" - } - }, - "stringify-package": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/stringify-package/-/stringify-package-1.0.1.tgz", - "integrity": "sha512-sa4DUQsYciMP1xhKWGuFM04fB0LG/9DlluZoSVywUMRNvzid6XucHK0/90xGxRoHrAaROrcHK1aPKaijCtSrhg==" - }, - "strip-ansi": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", - "requires": { - "ansi-regex": "^2.0.0" - } - }, - "strip-json-comments": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", - "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", - "dev": true - }, - "style-to-object": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/style-to-object/-/style-to-object-0.3.0.tgz", - "integrity": "sha512-CzFnRRXhzWIdItT3OmF8SQfWyahHhjq3HwcMNCNLn+N7klOOqPjMeG/4JSu77D7ypZdGvSzvkrbyeTMizz2VrA==", - "dev": true, - "requires": { - "inline-style-parser": "0.1.1" - } - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "requires": { - "has-flag": "^4.0.0" - } - }, - "symbol-tree": { - "version": "3.2.4", - "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz", - "integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==", - "dev": true - }, - "tap": { - "version": "15.1.6", - "resolved": "https://registry.npmjs.org/tap/-/tap-15.1.6.tgz", - "integrity": "sha512-TN7xH6Q2tUPTd6qwmkhuFJcx1vUR8e4dDUpBKc61G0krOzne7Ia6aKIFb8O/0kVazachSSuVME1V8nQ2xwWL8w==", - "dev": true, - "requires": { - "@isaacs/import-jsx": "*", - "@types/react": "*", - "chokidar": "^3.3.0", - "coveralls": "^3.0.11", - "findit": "^2.0.0", - "foreground-child": "^2.0.0", - "fs-exists-cached": "^1.0.0", - "glob": "^7.1.6", - "ink": "*", - "isexe": "^2.0.0", - "istanbul-lib-processinfo": "^2.0.2", - "jackspeak": "^1.4.1", - "libtap": "^1.1.4", - "minipass": "^3.1.1", - "mkdirp": "^1.0.4", - "nyc": "^15.1.0", - "opener": "^1.5.1", - "react": "*", - "rimraf": "^3.0.0", - "signal-exit": "^3.0.6", - "source-map-support": "^0.5.16", - "tap-mocha-reporter": "^5.0.0", - "tap-parser": "^10.0.1", - "tap-yaml": "^1.0.0", - "tcompare": "^5.0.7", - "treport": "*", - "which": "^2.0.2" - }, - "dependencies": { - "@babel/code-frame": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/highlight": "^7.16.0" - } - }, - "@babel/compat-data": { - "version": "7.16.0", - "bundled": true, - "dev": true - }, - "@babel/core": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/code-frame": "^7.16.0", - "@babel/generator": "^7.16.0", - "@babel/helper-compilation-targets": "^7.16.0", - "@babel/helper-module-transforms": "^7.16.0", - "@babel/helpers": "^7.16.0", - "@babel/parser": "^7.16.0", - "@babel/template": "^7.16.0", - "@babel/traverse": "^7.16.0", - "@babel/types": "^7.16.0", - "convert-source-map": "^1.7.0", - "debug": "^4.1.0", - "gensync": "^1.0.0-beta.2", - "json5": "^2.1.2", - "semver": "^6.3.0", - "source-map": "^0.5.0" - } - }, - "@babel/generator": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.16.0", - "jsesc": "^2.5.1", - "source-map": "^0.5.0" - } - }, - "@babel/helper-annotate-as-pure": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-compilation-targets": { - "version": "7.16.3", - "bundled": true, - "dev": true, - "requires": { - "@babel/compat-data": "^7.16.0", - "@babel/helper-validator-option": "^7.14.5", - "browserslist": "^4.17.5", - "semver": "^6.3.0" - } - }, - "@babel/helper-function-name": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-get-function-arity": "^7.16.0", - "@babel/template": "^7.16.0", - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-get-function-arity": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-hoist-variables": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-member-expression-to-functions": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-module-imports": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-module-transforms": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-module-imports": "^7.16.0", - "@babel/helper-replace-supers": "^7.16.0", - "@babel/helper-simple-access": "^7.16.0", - "@babel/helper-split-export-declaration": "^7.16.0", - "@babel/helper-validator-identifier": "^7.15.7", - "@babel/template": "^7.16.0", - "@babel/traverse": "^7.16.0", - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-optimise-call-expression": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-plugin-utils": { - "version": "7.14.5", - "bundled": true, - "dev": true - }, - "@babel/helper-replace-supers": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-member-expression-to-functions": "^7.16.0", - "@babel/helper-optimise-call-expression": "^7.16.0", - "@babel/traverse": "^7.16.0", - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-simple-access": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-split-export-declaration": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/types": "^7.16.0" - } - }, - "@babel/helper-validator-identifier": { - "version": "7.15.7", - "bundled": true, - "dev": true - }, - "@babel/helper-validator-option": { - "version": "7.14.5", - "bundled": true, - "dev": true - }, - "@babel/helpers": { - "version": "7.16.3", - "bundled": true, - "dev": true, - "requires": { - "@babel/template": "^7.16.0", - "@babel/traverse": "^7.16.3", - "@babel/types": "^7.16.0" - } - }, - "@babel/highlight": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-validator-identifier": "^7.15.7", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - } - }, - "@babel/parser": { - "version": "7.16.3", - "bundled": true, - "dev": true - }, - "@babel/plugin-proposal-object-rest-spread": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/compat-data": "^7.16.0", - "@babel/helper-compilation-targets": "^7.16.0", - "@babel/helper-plugin-utils": "^7.14.5", - "@babel/plugin-syntax-object-rest-spread": "^7.8.3", - "@babel/plugin-transform-parameters": "^7.16.0" - } - }, - "@babel/plugin-syntax-jsx": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.14.5" - } - }, - "@babel/plugin-syntax-object-rest-spread": { - "version": "7.8.3", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } - }, - "@babel/plugin-transform-destructuring": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.14.5" - } - }, - "@babel/plugin-transform-parameters": { - "version": "7.16.3", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-plugin-utils": "^7.14.5" - } - }, - "@babel/plugin-transform-react-jsx": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-annotate-as-pure": "^7.16.0", - "@babel/helper-module-imports": "^7.16.0", - "@babel/helper-plugin-utils": "^7.14.5", - "@babel/plugin-syntax-jsx": "^7.16.0", - "@babel/types": "^7.16.0" - } - }, - "@babel/template": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/code-frame": "^7.16.0", - "@babel/parser": "^7.16.0", - "@babel/types": "^7.16.0" - } - }, - "@babel/traverse": { - "version": "7.16.3", - "bundled": true, - "dev": true, - "requires": { - "@babel/code-frame": "^7.16.0", - "@babel/generator": "^7.16.0", - "@babel/helper-function-name": "^7.16.0", - "@babel/helper-hoist-variables": "^7.16.0", - "@babel/helper-split-export-declaration": "^7.16.0", - "@babel/parser": "^7.16.3", - "@babel/types": "^7.16.0", - "debug": "^4.1.0", - "globals": "^11.1.0" - } - }, - "@babel/types": { - "version": "7.16.0", - "bundled": true, - "dev": true, - "requires": { - "@babel/helper-validator-identifier": "^7.15.7", - "to-fast-properties": "^2.0.0" - } - }, - "@isaacs/import-jsx": { - "version": "4.0.1", - "bundled": true, - "dev": true, - "requires": { - "@babel/core": "^7.5.5", - "@babel/plugin-proposal-object-rest-spread": "^7.5.5", - "@babel/plugin-transform-destructuring": "^7.5.0", - "@babel/plugin-transform-react-jsx": "^7.3.0", - "caller-path": "^3.0.1", - "find-cache-dir": "^3.2.0", - "make-dir": "^3.0.2", - "resolve-from": "^3.0.0", - "rimraf": "^3.0.0" - }, - "dependencies": { - "caller-callsite": { - "version": "4.1.0", - "bundled": true, - "dev": true, - "requires": { - "callsites": "^3.1.0" - } - }, - "caller-path": { - "version": "3.0.1", - "bundled": true, - "dev": true, - "requires": { - "caller-callsite": "^4.1.0" - } - }, - "callsites": { - "version": "3.1.0", - "bundled": true, - "dev": true - } - } - }, - "@types/prop-types": { - "version": "15.7.4", - "bundled": true, - "dev": true - }, - "@types/react": { - "version": "17.0.34", - "bundled": true, - "dev": true, - "requires": { - "@types/prop-types": "*", - "@types/scheduler": "*", - "csstype": "^3.0.2" - } - }, - "@types/scheduler": { - "version": "0.16.2", - "bundled": true, - "dev": true - }, - "@types/yoga-layout": { - "version": "1.9.2", - "bundled": true, - "dev": true - }, - "ansi-escapes": { - "version": "4.3.2", - "bundled": true, - "dev": true, - "requires": { - "type-fest": "^0.21.3" - }, - "dependencies": { - "type-fest": { - "version": "0.21.3", - "bundled": true, - "dev": true - } - } - }, - "ansi-regex": { - "version": "5.0.1", - "bundled": true, - "dev": true - }, - "ansi-styles": { - "version": "3.2.1", - "bundled": true, - "dev": true, - "requires": { - "color-convert": "^1.9.0" - } - }, - "ansicolors": { - "version": "0.3.2", - "bundled": true, - "dev": true - }, - "astral-regex": { - "version": "2.0.0", - "bundled": true, - "dev": true - }, - "auto-bind": { - "version": "4.0.0", - "bundled": true, - "dev": true - }, - "balanced-match": { - "version": "1.0.2", - "bundled": true, - "dev": true - }, - "brace-expansion": { - "version": "1.1.11", - "bundled": true, - "dev": true, - "requires": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "browserslist": { - "version": "4.17.6", - "bundled": true, - "dev": true, - "requires": { - "caniuse-lite": "^1.0.30001274", - "electron-to-chromium": "^1.3.886", - "escalade": "^3.1.1", - "node-releases": "^2.0.1", - "picocolors": "^1.0.0" - } - }, - "caniuse-lite": { - "version": "1.0.30001279", - "bundled": true, - "dev": true - }, - "cardinal": { - "version": "2.1.1", - "bundled": true, - "dev": true, - "requires": { - "ansicolors": "~0.3.2", - "redeyed": "~2.1.0" - } - }, - "chalk": { - "version": "2.4.2", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - } - }, - "ci-info": { - "version": "2.0.0", - "bundled": true, - "dev": true - }, - "cli-boxes": { - "version": "2.2.1", - "bundled": true, - "dev": true - }, - "cli-cursor": { - "version": "3.1.0", - "bundled": true, - "dev": true, - "requires": { - "restore-cursor": "^3.1.0" - } - }, - "cli-truncate": { - "version": "2.1.0", - "bundled": true, - "dev": true, - "requires": { - "slice-ansi": "^3.0.0", - "string-width": "^4.2.0" - } - }, - "code-excerpt": { - "version": "3.0.0", - "bundled": true, - "dev": true, - "requires": { - "convert-to-spaces": "^1.0.1" - } - }, - "color-convert": { - "version": "1.9.3", - "bundled": true, - "dev": true, - "requires": { - "color-name": "1.1.3" - } - }, - "color-name": { - "version": "1.1.3", - "bundled": true, - "dev": true - }, - "commondir": { - "version": "1.0.1", - "bundled": true, - "dev": true - }, - "concat-map": { - "version": "0.0.1", - "bundled": true, - "dev": true - }, - "convert-source-map": { - "version": "1.8.0", - "bundled": true, - "dev": true, - "requires": { - "safe-buffer": "~5.1.1" - } - }, - "convert-to-spaces": { - "version": "1.0.2", - "bundled": true, - "dev": true - }, - "csstype": { - "version": "3.0.9", - "bundled": true, - "dev": true - }, - "debug": { - "version": "4.3.2", - "bundled": true, - "dev": true, - "requires": { - "ms": "2.1.2" - } - }, - "electron-to-chromium": { - "version": "1.3.893", - "bundled": true, - "dev": true - }, - "emoji-regex": { - "version": "8.0.0", - "bundled": true, - "dev": true - }, - "escalade": { - "version": "3.1.1", - "bundled": true, - "dev": true - }, - "escape-string-regexp": { - "version": "1.0.5", - "bundled": true, - "dev": true - }, - "esprima": { - "version": "4.0.1", - "bundled": true, - "dev": true - }, - "events-to-array": { - "version": "1.1.2", - "bundled": true, - "dev": true - }, - "find-cache-dir": { - "version": "3.3.2", - "bundled": true, - "dev": true, - "requires": { - "commondir": "^1.0.1", - "make-dir": "^3.0.2", - "pkg-dir": "^4.1.0" - } - }, - "find-up": { - "version": "4.1.0", - "bundled": true, - "dev": true, - "requires": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" - } - }, - "fs.realpath": { - "version": "1.0.0", - "bundled": true, - "dev": true - }, - "gensync": { - "version": "1.0.0-beta.2", - "bundled": true, - "dev": true - }, - "glob": { - "version": "7.2.0", - "bundled": true, - "dev": true, - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - } - }, - "globals": { - "version": "11.12.0", - "bundled": true, - "dev": true - }, - "has-flag": { - "version": "3.0.0", - "bundled": true, - "dev": true - }, - "indent-string": { - "version": "4.0.0", - "bundled": true, - "dev": true - }, - "inflight": { - "version": "1.0.6", - "bundled": true, - "dev": true, - "requires": { - "once": "^1.3.0", - "wrappy": "1" - } - }, - "inherits": { - "version": "2.0.4", - "bundled": true, - "dev": true - }, - "ink": { - "version": "3.2.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-escapes": "^4.2.1", - "auto-bind": "4.0.0", - "chalk": "^4.1.0", - "cli-boxes": "^2.2.0", - "cli-cursor": "^3.1.0", - "cli-truncate": "^2.1.0", - "code-excerpt": "^3.0.0", - "indent-string": "^4.0.0", - "is-ci": "^2.0.0", - "lodash": "^4.17.20", - "patch-console": "^1.0.0", - "react-devtools-core": "^4.19.1", - "react-reconciler": "^0.26.2", - "scheduler": "^0.20.2", - "signal-exit": "^3.0.2", - "slice-ansi": "^3.0.0", - "stack-utils": "^2.0.2", - "string-width": "^4.2.2", - "type-fest": "^0.12.0", - "widest-line": "^3.1.0", - "wrap-ansi": "^6.2.0", - "ws": "^7.5.5", - "yoga-layout-prebuilt": "^1.9.6" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "bundled": true, - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "bundled": true, - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "bundled": true, - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "bundled": true, - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "bundled": true, - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } - } - }, - "is-ci": { - "version": "2.0.0", - "bundled": true, - "dev": true, - "requires": { - "ci-info": "^2.0.0" - } - }, - "is-fullwidth-code-point": { - "version": "3.0.0", - "bundled": true, - "dev": true - }, - "js-tokens": { - "version": "4.0.0", - "bundled": true, - "dev": true - }, - "jsesc": { - "version": "2.5.2", - "bundled": true, - "dev": true - }, - "json5": { - "version": "2.2.0", - "bundled": true, - "dev": true, - "requires": { - "minimist": "^1.2.5" - } - }, - "locate-path": { - "version": "5.0.0", - "bundled": true, - "dev": true, - "requires": { - "p-locate": "^4.1.0" - } - }, - "lodash": { - "version": "4.17.21", - "bundled": true, - "dev": true - }, - "loose-envify": { - "version": "1.4.0", - "bundled": true, - "dev": true, - "requires": { - "js-tokens": "^3.0.0 || ^4.0.0" - } - }, - "make-dir": { - "version": "3.1.0", - "bundled": true, - "dev": true, - "requires": { - "semver": "^6.0.0" - } - }, - "mimic-fn": { - "version": "2.1.0", - "bundled": true, - "dev": true - }, - "minimatch": { - "version": "3.0.4", - "bundled": true, - "dev": true, - "requires": { - "brace-expansion": "^1.1.7" - } - }, - "minimist": { - "version": "1.2.5", - "bundled": true, - "dev": true - }, - "minipass": { - "version": "3.1.5", - "bundled": true, - "dev": true, - "requires": { - "yallist": "^4.0.0" - } - }, - "ms": { - "version": "2.1.2", - "bundled": true, - "dev": true - }, - "node-releases": { - "version": "2.0.1", - "bundled": true, - "dev": true - }, - "object-assign": { - "version": "4.1.1", - "bundled": true, - "dev": true - }, - "once": { - "version": "1.4.0", - "bundled": true, - "dev": true, - "requires": { - "wrappy": "1" - } - }, - "onetime": { - "version": "5.1.2", - "bundled": true, - "dev": true, - "requires": { - "mimic-fn": "^2.1.0" - } - }, - "p-limit": { - "version": "2.3.0", - "bundled": true, - "dev": true, - "requires": { - "p-try": "^2.0.0" - } - }, - "p-locate": { - "version": "4.1.0", - "bundled": true, - "dev": true, - "requires": { - "p-limit": "^2.2.0" - } - }, - "p-try": { - "version": "2.2.0", - "bundled": true, - "dev": true - }, - "patch-console": { - "version": "1.0.0", - "bundled": true, - "dev": true - }, - "path-exists": { - "version": "4.0.0", - "bundled": true, - "dev": true - }, - "path-is-absolute": { - "version": "1.0.1", - "bundled": true, - "dev": true - }, - "picocolors": { - "version": "1.0.0", - "bundled": true, - "dev": true - }, - "pkg-dir": { - "version": "4.2.0", - "bundled": true, - "dev": true, - "requires": { - "find-up": "^4.0.0" - } - }, - "punycode": { - "version": "2.1.1", - "bundled": true, - "dev": true - }, - "react": { - "version": "17.0.2", - "bundled": true, - "dev": true, - "requires": { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1" - } - }, - "react-devtools-core": { - "version": "4.21.0", - "bundled": true, - "dev": true, - "requires": { - "shell-quote": "^1.6.1", - "ws": "^7" - } - }, - "react-reconciler": { - "version": "0.26.2", - "bundled": true, - "dev": true, - "requires": { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1", - "scheduler": "^0.20.2" - } - }, - "redeyed": { - "version": "2.1.1", - "bundled": true, - "dev": true, - "requires": { - "esprima": "~4.0.0" - } - }, - "resolve-from": { - "version": "3.0.0", - "bundled": true, - "dev": true - }, - "restore-cursor": { - "version": "3.1.0", - "bundled": true, - "dev": true, - "requires": { - "onetime": "^5.1.0", - "signal-exit": "^3.0.2" - } - }, - "rimraf": { - "version": "3.0.2", - "bundled": true, - "dev": true, - "requires": { - "glob": "^7.1.3" - } - }, - "safe-buffer": { - "version": "5.1.2", - "bundled": true, - "dev": true - }, - "scheduler": { - "version": "0.20.2", - "bundled": true, - "dev": true, - "requires": { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1" - } - }, - "semver": { - "version": "6.3.0", - "bundled": true, - "dev": true - }, - "shell-quote": { - "version": "1.7.3", - "bundled": true, - "dev": true - }, - "signal-exit": { - "version": "3.0.6", - "bundled": true, - "dev": true - }, - "slice-ansi": { - "version": "3.0.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^4.0.0", - "astral-regex": "^2.0.0", - "is-fullwidth-code-point": "^3.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "bundled": true, - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "color-convert": { - "version": "2.0.1", - "bundled": true, - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "bundled": true, - "dev": true - } - } - }, - "source-map": { - "version": "0.5.7", - "bundled": true, - "dev": true - }, - "stack-utils": { - "version": "2.0.5", - "bundled": true, - "dev": true, - "requires": { - "escape-string-regexp": "^2.0.0" - }, - "dependencies": { - "escape-string-regexp": { - "version": "2.0.0", - "bundled": true, - "dev": true - } - } - }, - "string-width": { - "version": "4.2.3", - "bundled": true, - "dev": true, - "requires": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - } - }, - "strip-ansi": { - "version": "6.0.1", - "bundled": true, - "dev": true, - "requires": { - "ansi-regex": "^5.0.1" - } - }, - "supports-color": { - "version": "5.5.0", - "bundled": true, - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - }, - "tap-parser": { - "version": "10.1.0", - "bundled": true, - "dev": true, - "requires": { - "events-to-array": "^1.0.1", - "minipass": "^3.0.0", - "tap-yaml": "^1.0.0" - } - }, - "tap-yaml": { - "version": "1.0.0", - "bundled": true, - "dev": true, - "requires": { - "yaml": "^1.5.0" - } - }, - "to-fast-properties": { - "version": "2.0.0", - "bundled": true, - "dev": true - }, - "treport": { - "version": "3.0.2", - "bundled": true, - "dev": true, - "requires": { - "@isaacs/import-jsx": "^4.0.1", - "cardinal": "^2.1.1", - "chalk": "^3.0.0", - "ink": "^3.2.0", - "ms": "^2.1.2", - "tap-parser": "^10.0.1", - "unicode-length": "^2.0.2" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "bundled": true, - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "3.0.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "bundled": true, - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "bundled": true, - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "bundled": true, - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "bundled": true, - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } - } - }, - "type-fest": { - "version": "0.12.0", - "bundled": true, - "dev": true - }, - "unicode-length": { - "version": "2.0.2", - "bundled": true, - "dev": true, - "requires": { - "punycode": "^2.0.0", - "strip-ansi": "^3.0.1" - }, - "dependencies": { - "ansi-regex": { - "version": "2.1.1", - "bundled": true, - "dev": true - }, - "strip-ansi": { - "version": "3.0.1", - "bundled": true, - "dev": true, - "requires": { - "ansi-regex": "^2.0.0" - } - } - } - }, - "widest-line": { - "version": "3.1.0", - "bundled": true, - "dev": true, - "requires": { - "string-width": "^4.0.0" - } - }, - "wrap-ansi": { - "version": "6.2.0", - "bundled": true, - "dev": true, - "requires": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "bundled": true, - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "color-convert": { - "version": "2.0.1", - "bundled": true, - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "bundled": true, - "dev": true - } - } - }, - "wrappy": { - "version": "1.0.2", - "bundled": true, - "dev": true - }, - "ws": { - "version": "7.5.5", - "bundled": true, - "dev": true, - "requires": {} - }, - "yallist": { - "version": "4.0.0", - "bundled": true, - "dev": true - }, - "yaml": { - "version": "1.10.2", - "bundled": true, - "dev": true - }, - "yoga-layout-prebuilt": { - "version": "1.10.0", - "bundled": true, - "dev": true, - "requires": { - "@types/yoga-layout": "1.9.2" - } - } - } - }, - "tap-mocha-reporter": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/tap-mocha-reporter/-/tap-mocha-reporter-5.0.1.tgz", - "integrity": "sha512-1knFWOwd4khx/7uSEnUeaP9IPW3w+sqTgJMhrwah6t46nZ8P25atOKAjSvVDsT67lOPu0nfdOqUwoyKn+3E5pA==", - "dev": true, - "requires": { - "color-support": "^1.1.0", - "debug": "^4.1.1", - "diff": "^4.0.1", - "escape-string-regexp": "^2.0.0", - "glob": "^7.0.5", - "tap-parser": "^10.0.0", - "tap-yaml": "^1.0.0", - "unicode-length": "^2.0.2" - }, - "dependencies": { - "diff": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", - "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", - "dev": true - }, - "escape-string-regexp": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz", - "integrity": "sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==", - "dev": true - } - } - }, - "tap-parser": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/tap-parser/-/tap-parser-10.1.0.tgz", - "integrity": "sha512-FujQeciDaOiOvaIVGS1Rpb0v4R6XkOjvWCWowlz5oKuhPkEJ8U6pxgqt38xuzYhPt8dWEnfHn2jqpZdJEkW7pA==", - "dev": true, - "requires": { - "events-to-array": "^1.0.1", - "minipass": "^3.0.0", - "tap-yaml": "^1.0.0" - } - }, - "tap-yaml": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/tap-yaml/-/tap-yaml-1.0.0.tgz", - "integrity": "sha512-Rxbx4EnrWkYk0/ztcm5u3/VznbyFJpyXO12dDBHKWiDVxy7O2Qw6MRrwO5H6Ww0U5YhRY/4C/VzWmFPhBQc4qQ==", - "dev": true, - "requires": { - "yaml": "^1.5.0" - } - }, - "tar": { - "version": "6.1.11", - "resolved": "https://registry.npmjs.org/tar/-/tar-6.1.11.tgz", - "integrity": "sha512-an/KZQzQUkZCkuoAA64hM92X0Urb6VpRhAFllDzz44U2mcD5scmT3zBc4VgVpkugF580+DQn8eAFSyoQt0tznA==", - "requires": { - "chownr": "^2.0.0", - "fs-minipass": "^2.0.0", - "minipass": "^3.0.0", - "minizlib": "^2.1.1", - "mkdirp": "^1.0.3", - "yallist": "^4.0.0" - } - }, - "tar-fs": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.1.tgz", - "integrity": "sha512-V0r2Y9scmbDRLCNex/+hYzvp/zyYjvFbHPNgVTKfQvVrb6guiE/fxP+XblDNR011utopbkex2nM4dHNV6GDsng==", - "dev": true, - "requires": { - "chownr": "^1.1.1", - "mkdirp-classic": "^0.5.2", - "pump": "^3.0.0", - "tar-stream": "^2.1.4" - }, - "dependencies": { - "chownr": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.4.tgz", - "integrity": "sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==", - "dev": true - } - } - }, - "tar-stream": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-2.2.0.tgz", - "integrity": "sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==", - "dev": true, - "requires": { - "bl": "^4.0.3", - "end-of-stream": "^1.4.1", - "fs-constants": "^1.0.0", - "inherits": "^2.0.3", - "readable-stream": "^3.1.1" - } - }, - "tcompare": { - "version": "5.0.7", - "resolved": "https://registry.npmjs.org/tcompare/-/tcompare-5.0.7.tgz", - "integrity": "sha512-d9iddt6YYGgyxJw5bjsN7UJUO1kGOtjSlNy/4PoGYAjQS5pAT/hzIoLf1bZCw+uUxRmZJh7Yy1aA7xKVRT9B4w==", - "dev": true, - "requires": { - "diff": "^4.0.2" - }, - "dependencies": { - "diff": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", - "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", - "dev": true - } - } - }, - "test-exclude": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", - "integrity": "sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w==", - "dev": true, - "requires": { - "@istanbuljs/schema": "^0.1.2", - "glob": "^7.1.4", - "minimatch": "^3.0.4" - } - }, - "text-table": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", - "integrity": "sha1-f17oI66AUgfACvLfSoTsP8+lcLQ=" - }, - "tiny-relative-date": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/tiny-relative-date/-/tiny-relative-date-1.3.0.tgz", - "integrity": "sha512-MOQHpzllWxDCHHaDno30hhLfbouoYlOI8YlMNtvKe1zXbjEVhbcEovQxvZrPvtiYW630GQDoMMarCnjfyfHA+A==" - }, - "to-fast-properties": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", - "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", - "dev": true - }, - "to-regex-range": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", - "dev": true, - "requires": { - "is-number": "^7.0.0" - } - }, - "tough-cookie": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-4.0.0.tgz", - "integrity": "sha512-tHdtEpQCMrc1YLrMaqXXcj6AxhYi/xgit6mZu1+EDWUn+qhUf8wMQoFIy9NXuq23zAwtcB0t/MjACGR18pcRbg==", - "dev": true, - "requires": { - "psl": "^1.1.33", - "punycode": "^2.1.1", - "universalify": "^0.1.2" - } - }, - "tr46": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/tr46/-/tr46-3.0.0.tgz", - "integrity": "sha512-l7FvfAHlcmulp8kr+flpQZmVwtu7nfRV7NZujtN0OqES8EL4O4e0qqzL0DC5gAvx/ZC/9lk6rhcUwYvkBnBnYA==", - "dev": true, - "requires": { - "punycode": "^2.1.1" - } - }, - "treeverse": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/treeverse/-/treeverse-1.0.4.tgz", - "integrity": "sha512-whw60l7r+8ZU8Tu/Uc2yxtc4ZTZbR/PF3u1IPNKGQ6p8EICLb3Z2lAgoqw9bqYd8IkgnsaOcLzYHFckjqNsf0g==" - }, - "trim": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/trim/-/trim-0.0.1.tgz", - "integrity": "sha1-WFhUf2spB1fulczMZm+1AITEYN0=", - "dev": true - }, - "trim-trailing-lines": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/trim-trailing-lines/-/trim-trailing-lines-1.1.4.tgz", - "integrity": "sha512-rjUWSqnfTNrjbB9NQWfPMH/xRK1deHeGsHoVfpxJ++XeYXE0d6B1En37AHfw3jtfTU7dzMzZL2jjpe8Qb5gLIQ==", - "dev": true - }, - "trivial-deferred": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/trivial-deferred/-/trivial-deferred-1.0.1.tgz", - "integrity": "sha1-N21NKdlR1jaKb3oK6FwvTV4GWPM=", - "dev": true - }, - "trough": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/trough/-/trough-1.0.5.tgz", - "integrity": "sha512-rvuRbTarPXmMb79SmzEp8aqXNKcK+y0XaB298IXueQ8I2PsrATcPBCSPyK/dDNa2iWOhKlfNnOjdAOTBU/nkFA==", - "dev": true - }, - "ts-node": { - "version": "8.10.2", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", - "integrity": "sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA==", - "dev": true, - "optional": true, - "peer": true, - "requires": { - "arg": "^4.1.0", - "diff": "^4.0.1", - "make-error": "^1.1.1", - "source-map-support": "^0.5.17", - "yn": "3.1.1" - }, - "dependencies": { - "diff": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", - "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", - "dev": true, - "optional": true, - "peer": true - } - } - }, - "tunnel-agent": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", - "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", - "dev": true, - "requires": { - "safe-buffer": "^5.0.1" - } - }, - "tweetnacl": { - "version": "0.14.5", - "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", - "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=", - "dev": true - }, - "type-check": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", - "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==", - "dev": true, - "requires": { - "prelude-ls": "^1.2.1" - } - }, - "type-detect": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", - "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", - "dev": true - }, - "type-fest": { - "version": "0.8.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz", - "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", - "dev": true - }, - "typedarray-to-buffer": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-4.0.0.tgz", - "integrity": "sha512-6dOYeZfS3O9RtRD1caom0sMxgK59b27+IwoNy8RDPsmslSGOyU+mpTamlaIW7aNKi90ZQZ9DFaZL3YRoiSCULQ==" - }, - "typescript": { - "version": "3.9.10", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.10.tgz", - "integrity": "sha512-w6fIxVE/H1PkLKcCPsFqKE7Kv7QUwhU8qQY2MueZXWx5cPZdwFupLgKK3vntcK98BtNHZtAF4LA/yl2a7k8R6Q==", - "dev": true, - "optional": true, - "peer": true - }, - "unbox-primitive": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.1.tgz", - "integrity": "sha512-tZU/3NqK3dA5gpE1KtyiJUrEB0lxnGkMFHptJ7q6ewdZ8s12QrODwNbhIJStmJkd1QDXa1NRA8aF2A1zk/Ypyw==", - "dev": true, - "requires": { - "function-bind": "^1.1.1", - "has-bigints": "^1.0.1", - "has-symbols": "^1.0.2", - "which-boxed-primitive": "^1.0.2" - } - }, - "unherit": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/unherit/-/unherit-1.1.3.tgz", - "integrity": "sha512-Ft16BJcnapDKp0+J/rqFC3Rrk6Y/Ng4nzsC028k2jdDII/rdZ7Wd3pPT/6+vIIxRagwRc9K0IUX0Ra4fKvw+WQ==", - "dev": true, - "requires": { - "inherits": "^2.0.0", - "xtend": "^4.0.0" - } - }, - "unicode-length": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/unicode-length/-/unicode-length-2.0.2.tgz", - "integrity": "sha512-Ph/j1VbS3/r77nhoY2WU0GWGjVYOHL3xpKp0y/Eq2e5r0mT/6b649vm7KFO6RdAdrZkYLdxphYVgvODxPB+Ebg==", - "dev": true, - "requires": { - "punycode": "^2.0.0", - "strip-ansi": "^3.0.1" - } - }, - "unified": { - "version": "9.2.0", - "resolved": "https://registry.npmjs.org/unified/-/unified-9.2.0.tgz", - "integrity": "sha512-vx2Z0vY+a3YoTj8+pttM3tiJHCwY5UFbYdiWrwBEbHmK8pvsPj2rtAX2BFfgXen8T39CJWblWRDT4L5WGXtDdg==", - "dev": true, - "requires": { - "bail": "^1.0.0", - "extend": "^3.0.0", - "is-buffer": "^2.0.0", - "is-plain-obj": "^2.0.0", - "trough": "^1.0.0", - "vfile": "^4.0.0" - } - }, - "unique-filename": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/unique-filename/-/unique-filename-1.1.1.tgz", - "integrity": "sha512-Vmp0jIp2ln35UTXuryvjzkjGdRyf9b2lTXuSYUiPmzRcl3FDtYqAwOnTJkAngD9SWhnoJzDbTKwaOrZ+STtxNQ==", - "requires": { - "unique-slug": "^2.0.0" - } - }, - "unique-slug": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/unique-slug/-/unique-slug-2.0.2.tgz", - "integrity": "sha512-zoWr9ObaxALD3DOPfjPSqxt4fnZiWblxHIgeWqW8x7UqDzEtHEQLzji2cuJYQFCU6KmoJikOYAZlrTHHebjx2w==", - "requires": { - "imurmurhash": "^0.1.4" - } - }, - "unist-builder": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/unist-builder/-/unist-builder-2.0.3.tgz", - "integrity": "sha512-f98yt5pnlMWlzP539tPc4grGMsFaQQlP/vM396b00jngsiINumNmsY8rkXjfoi1c6QaM8nQ3vaGDuoKWbe/1Uw==", - "dev": true - }, - "unist-util-generated": { - "version": "1.1.6", - "resolved": "https://registry.npmjs.org/unist-util-generated/-/unist-util-generated-1.1.6.tgz", - "integrity": "sha512-cln2Mm1/CZzN5ttGK7vkoGw+RZ8VcUH6BtGbq98DDtRGquAAOXig1mrBQYelOwMXYS8rK+vZDyyojSjp7JX+Lg==", - "dev": true - }, - "unist-util-is": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-4.1.0.tgz", - "integrity": "sha512-ZOQSsnce92GrxSqlnEEseX0gi7GH9zTJZ0p9dtu87WRb/37mMPO2Ilx1s/t9vBHrFhbgweUwb+t7cIn5dxPhZg==", - "dev": true - }, - "unist-util-position": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/unist-util-position/-/unist-util-position-3.1.0.tgz", - "integrity": "sha512-w+PkwCbYSFw8vpgWD0v7zRCl1FpY3fjDSQ3/N/wNd9Ffa4gPi8+4keqt99N3XW6F99t/mUzp2xAhNmfKWp95QA==", - "dev": true - }, - "unist-util-remove": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/unist-util-remove/-/unist-util-remove-2.1.0.tgz", - "integrity": "sha512-J8NYPyBm4baYLdCbjmf1bhPu45Cr1MWTm77qd9istEkzWpnN6O9tMsEbB2JhNnBCqGENRqEWomQ+He6au0B27Q==", - "dev": true, - "requires": { - "unist-util-is": "^4.0.0" - } - }, - "unist-util-remove-position": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/unist-util-remove-position/-/unist-util-remove-position-2.0.1.tgz", - "integrity": "sha512-fDZsLYIe2uT+oGFnuZmy73K6ZxOPG/Qcm+w7jbEjaFcJgbQ6cqjs/eSPzXhsmGpAsWPkqZM9pYjww5QTn3LHMA==", - "dev": true, - "requires": { - "unist-util-visit": "^2.0.0" - } - }, - "unist-util-stringify-position": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/unist-util-stringify-position/-/unist-util-stringify-position-2.0.3.tgz", - "integrity": "sha512-3faScn5I+hy9VleOq/qNbAd6pAx7iH5jYBMS9I1HgQVijz/4mv5Bvw5iw1sC/90CODiKo81G/ps8AJrISn687g==", - "dev": true, - "requires": { - "@types/unist": "^2.0.2" - } - }, - "unist-util-visit": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-2.0.3.tgz", - "integrity": "sha512-iJ4/RczbJMkD0712mGktuGpm/U4By4FfDonL7N/9tATGIF4imikjOuagyMY53tnZq3NP6BcmlrHhEKAfGWjh7Q==", - "dev": true, - "requires": { - "@types/unist": "^2.0.0", - "unist-util-is": "^4.0.0", - "unist-util-visit-parents": "^3.0.0" - } - }, - "unist-util-visit-parents": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-3.1.1.tgz", - "integrity": "sha512-1KROIZWo6bcMrZEwiH2UrXDyalAa0uqzWCxCJj6lPOvTve2WkfgCytoDTPaMnodXh1WrXOq0haVYHj99ynJlsg==", - "dev": true, - "requires": { - "@types/unist": "^2.0.0", - "unist-util-is": "^4.0.0" - } - }, - "universalify": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz", - "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==", - "dev": true - }, - "uri-js": { - "version": "4.4.1", - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", - "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", - "dev": true, - "requires": { - "punycode": "^2.1.0" - } - }, - "util-deprecate": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" - }, - "util-promisify": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/util-promisify/-/util-promisify-2.1.0.tgz", - "integrity": "sha1-PCI2R2xNMsX/PEcAKt18E7moKlM=", - "dev": true, - "requires": { - "object.getownpropertydescriptors": "^2.0.3" - } - }, - "uuid": { - "version": "3.4.0", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz", - "integrity": "sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==", - "dev": true - }, - "v8-compile-cache": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz", - "integrity": "sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA==", - "dev": true - }, - "validate-npm-package-license": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz", - "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==", - "requires": { - "spdx-correct": "^3.0.0", - "spdx-expression-parse": "^3.0.0" - } - }, - "validate-npm-package-name": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/validate-npm-package-name/-/validate-npm-package-name-3.0.0.tgz", - "integrity": "sha1-X6kS2B630MdK/BQN5zF/DKffQ34=", - "requires": { - "builtins": "^1.0.3" - } - }, - "verror": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", - "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=", - "dev": true, - "requires": { - "assert-plus": "^1.0.0", - "core-util-is": "1.0.2", - "extsprintf": "^1.2.0" - } - }, - "vfile": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/vfile/-/vfile-4.2.1.tgz", - "integrity": "sha512-O6AE4OskCG5S1emQ/4gl8zK586RqA3srz3nfK/Viy0UPToBc5Trp9BVFb1u0CjsKrAWwnpr4ifM/KBXPWwJbCA==", - "dev": true, - "requires": { - "@types/unist": "^2.0.0", - "is-buffer": "^2.0.0", - "unist-util-stringify-position": "^2.0.0", - "vfile-message": "^2.0.0" - } - }, - "vfile-location": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/vfile-location/-/vfile-location-3.2.0.tgz", - "integrity": "sha512-aLEIZKv/oxuCDZ8lkJGhuhztf/BW4M+iHdCwglA/eWc+vtuRFJj8EtgceYFX4LRjOhCAAiNHsKGssC6onJ+jbA==", - "dev": true - }, - "vfile-message": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/vfile-message/-/vfile-message-2.0.4.tgz", - "integrity": "sha512-DjssxRGkMvifUOJre00juHoP9DPWuzjxKuMDrhNbk2TdaYYBNMStsNhEOt3idrtI12VQYM/1+iM0KOzXi4pxwQ==", - "dev": true, - "requires": { - "@types/unist": "^2.0.0", - "unist-util-stringify-position": "^2.0.0" - } - }, - "vlq": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/vlq/-/vlq-0.2.3.tgz", - "integrity": "sha512-DRibZL6DsNhIgYQ+wNdWDL2SL3bKPlVrRiBqV5yuMm++op8W4kGFtaQfCs4KEJn0wBZcHVHJ3eoywX8983k1ow==", - "dev": true, - "optional": true, - "peer": true - }, - "w3c-hr-time": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/w3c-hr-time/-/w3c-hr-time-1.0.2.tgz", - "integrity": "sha512-z8P5DvDNjKDoFIHK7q8r8lackT6l+jo/Ye3HOle7l9nICP9lf1Ci25fy9vHd0JOWewkIFzXIEig3TdKT7JQ5fQ==", - "dev": true, - "requires": { - "browser-process-hrtime": "^1.0.0" - } - }, - "w3c-xmlserializer": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-3.0.0.tgz", - "integrity": "sha512-3WFqGEgSXIyGhOmAFtlicJNMjEps8b1MG31NCA0/vOF9+nKMUW1ckhi9cnNHmf88Rzw5V+dwIwsm2C7X8k9aQg==", - "dev": true, - "requires": { - "xml-name-validator": "^4.0.0" - } - }, - "walk-up-path": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/walk-up-path/-/walk-up-path-1.0.0.tgz", - "integrity": "sha512-hwj/qMDUEjCU5h0xr90KGCf0tg0/LgJbmOWgrWKYlcJZM7XvquvUJZ0G/HMGr7F7OQMOUuPHWP9JpriinkAlkg==" - }, - "wcwidth": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/wcwidth/-/wcwidth-1.0.1.tgz", - "integrity": "sha1-8LDc+RW8X/FSivrbLA4XtTLaL+g=", - "requires": { - "defaults": "^1.0.3" - } - }, - "web-namespaces": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/web-namespaces/-/web-namespaces-1.1.4.tgz", - "integrity": "sha512-wYxSGajtmoP4WxfejAPIr4l0fVh+jeMXZb08wNc0tMg6xsfZXj3cECqIK0G7ZAqUq0PP8WlMDtaOGVBTAWztNw==", - "dev": true - }, - "webidl-conversions": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", - "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", - "dev": true - }, - "whatwg-encoding": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-2.0.0.tgz", - "integrity": "sha512-p41ogyeMUrw3jWclHWTQg1k05DSVXPLcVxRTYsXUk+ZooOCZLcoYgPZ/HL/D/N+uQPOtcp1me1WhBEaX02mhWg==", - "dev": true, - "requires": { - "iconv-lite": "0.6.3" - } - }, - "whatwg-mimetype": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-3.0.0.tgz", - "integrity": "sha512-nt+N2dzIutVRxARx1nghPKGv1xHikU7HKdfafKkLNLindmPU/ch3U31NOCGGA/dmPcmb1VlofO0vnKAcsm0o/Q==", - "dev": true - }, - "whatwg-url": { - "version": "10.0.0", - "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-10.0.0.tgz", - "integrity": "sha512-CLxxCmdUby142H5FZzn4D8ikO1cmypvXVQktsgosNy4a4BHrDHeciBBGZhb0bNoR5/MltoCatso+vFjjGx8t0w==", - "dev": true, - "requires": { - "tr46": "^3.0.0", - "webidl-conversions": "^7.0.0" - } - }, - "which": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", - "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "requires": { - "isexe": "^2.0.0" - } - }, - "which-boxed-primitive": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", - "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", - "dev": true, - "requires": { - "is-bigint": "^1.0.1", - "is-boolean-object": "^1.1.0", - "is-number-object": "^1.0.4", - "is-string": "^1.0.5", - "is-symbol": "^1.0.3" - } - }, - "which-module": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", - "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", - "dev": true - }, - "wide-align": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.5.tgz", - "integrity": "sha512-eDMORYaPNZ4sQIuuYPDHdQvf4gyCF9rEEV/yPxGfwPkRodwEgiMUUXTx/dex+Me0wxx53S+NgUHaP7y3MGlDmg==", - "requires": { - "string-width": "^1.0.2 || 2 || 3 || 4" - } - }, - "word-wrap": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz", - "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==", - "dev": true - }, - "wrap-ansi": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", - "dev": true, - "requires": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true - }, - "is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true - }, - "string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "requires": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - } - }, - "strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, - "requires": { - "ansi-regex": "^5.0.1" - } - } - } - }, - "wrappy": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" - }, - "write-file-atomic": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-4.0.0.tgz", - "integrity": "sha512-JhcWoKffJNF7ivO9yflBhc7tn3wKnokMUfWpBriM9yCXj4ePQnRPcWglBkkg1AHC8nsW/EfxwwhqsLtOy59djA==", - "requires": { - "imurmurhash": "^0.1.4", - "is-typedarray": "^1.0.0", - "signal-exit": "^3.0.2", - "typedarray-to-buffer": "^4.0.0" - } - }, - "ws": { - "version": "8.2.3", - "resolved": "https://registry.npmjs.org/ws/-/ws-8.2.3.tgz", - "integrity": "sha512-wBuoj1BDpC6ZQ1B7DWQBYVLphPWkm8i9Y0/3YdHjHKHiohOJ1ws+3OccDWtH+PoC9DZD5WOTrJvNbWvjS6JWaA==", - "dev": true, - "requires": {} - }, - "xml-name-validator": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-4.0.0.tgz", - "integrity": "sha512-ICP2e+jsHvAj2E2lIHxa5tjXRlKDJo4IdvPvCXbXQGdzSfmSpNVyIKMvoZHjDY9DP0zV17iI85o90vRFXNccRw==", - "dev": true - }, - "xmlchars": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/xmlchars/-/xmlchars-2.2.0.tgz", - "integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==", - "dev": true - }, - "xtend": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", - "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", - "dev": true - }, - "y18n": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.3.tgz", - "integrity": "sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ==", - "dev": true - }, - "yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" - }, - "yaml": { - "version": "1.10.2", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", - "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", - "dev": true - }, - "yapool": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/yapool/-/yapool-1.0.0.tgz", - "integrity": "sha1-9pPymjFbUNmp2iZGp6ZkXJaYW2o=", - "dev": true - }, - "yargs": { - "version": "15.4.1", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-15.4.1.tgz", - "integrity": "sha512-aePbxDmcYW++PaqBsJ+HYUFwCdv4LVvdnhBy78E57PIor8/OVvhMrADFFEDh8DHDFRv/O9i3lPhsENjO7QX0+A==", - "dev": true, - "requires": { - "cliui": "^6.0.0", - "decamelize": "^1.2.0", - "find-up": "^4.1.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^4.2.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^18.1.2" - }, - "dependencies": { - "ansi-regex": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", - "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==", - "dev": true - }, - "cliui": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-6.0.0.tgz", - "integrity": "sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ==", - "dev": true, - "requires": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", - "wrap-ansi": "^6.2.0" - } - }, - "find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", - "dev": true, - "requires": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" - } - }, - "is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true - }, - "locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", - "dev": true, - "requires": { - "p-locate": "^4.1.0" - } - }, - "p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "dev": true, - "requires": { - "p-try": "^2.0.0" - } - }, - "p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", - "dev": true, - "requires": { - "p-limit": "^2.2.0" - } - }, - "p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "dev": true - }, - "path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true - }, - "string-width": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.2.tgz", - "integrity": "sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA==", - "dev": true, - "requires": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.0" - } - }, - "strip-ansi": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", - "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", - "dev": true, - "requires": { - "ansi-regex": "^5.0.0" - } - }, - "wrap-ansi": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", - "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", - "dev": true, - "requires": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - } - } - } - }, - "yargs-parser": { - "version": "18.1.3", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-18.1.3.tgz", - "integrity": "sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==", - "dev": true, - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } - }, - "yn": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", - "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", - "dev": true, - "optional": true, - "peer": true - }, - "zwitch": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/zwitch/-/zwitch-1.0.5.tgz", - "integrity": "sha512-V50KMwwzqJV0NpZIZFwfOD5/lyny3WlSzRiXgA0G7VUnRlqttta1L6UQIHzd6EuBY/cHGfwTIck7w1yH6Q5zUw==", - "dev": true } } } diff --git a/package.json b/package.json index c407a66..d727641 100644 --- a/package.json +++ b/package.json @@ -1,18 +1,20 @@ { - "version": "8.5.1", + "version": "9.2.0", "name": "npm", "description": "a package manager for JavaScript", "workspaces": [ "docs", + "smoke-tests", + "mock-registry", "workspaces/*" ], "files": [ + "bin/", + "lib/", "index.js", - "bin", - "docs/content/**/*.md", - "docs/output/**/*.html", - "lib", - "man" + "docs/content/", + "docs/output/", + "man/" ], "keywords": [ "install", @@ -20,15 +22,11 @@ "package manager", "package.json" ], - "preferGlobal": true, - "config": { - "publishtest": false - }, "homepage": "https://docs.npmjs.com/", - "author": "Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me)", + "author": "GitHub Inc.", "repository": { "type": "git", - "url": "https://github.com/npm/cli" + "url": "https://github.com/npm/cli.git" }, "bugs": { "url": "https://github.com/npm/cli/issues" @@ -55,96 +53,91 @@ }, "dependencies": { "@isaacs/string-locale-compare": "^1.1.0", - "@npmcli/arborist": "^4.3.1", - "@npmcli/ci-detect": "^2.0.0", - "@npmcli/config": "^3.0.0", - "@npmcli/map-workspaces": "^2.0.0", - "@npmcli/package-json": "^1.0.1", - "@npmcli/run-script": "^2.0.0", - "abbrev": "~1.1.1", - "ansicolors": "~0.3.2", - "ansistyles": "~0.1.3", + "@npmcli/arborist": "^6.1.5", + "@npmcli/config": "^6.1.0", + "@npmcli/map-workspaces": "^3.0.0", + "@npmcli/package-json": "^3.0.0", + "@npmcli/run-script": "^6.0.0", + "abbrev": "^2.0.0", "archy": "~1.0.0", - "cacache": "^15.3.0", + "cacache": "^17.0.3", "chalk": "^4.1.2", - "chownr": "^2.0.0", + "ci-info": "^3.7.0", "cli-columns": "^4.0.0", - "cli-table3": "^0.6.1", - "columnify": "~1.5.4", - "fastest-levenshtein": "^1.0.12", - "glob": "^7.2.0", - "graceful-fs": "^4.2.9", - "hosted-git-info": "^4.1.0", - "ini": "^2.0.0", - "init-package-json": "^2.0.5", + "cli-table3": "^0.6.3", + "columnify": "^1.6.0", + "fastest-levenshtein": "^1.0.16", + "fs-minipass": "^2.1.0", + "glob": "^8.0.1", + "graceful-fs": "^4.2.10", + "hosted-git-info": "^6.1.1", + "ini": "^3.0.1", + "init-package-json": "^4.0.1", "is-cidr": "^4.0.2", - "json-parse-even-better-errors": "^2.3.1", - "libnpmaccess": "^5.0.1", - "libnpmdiff": "^3.0.0", - "libnpmexec": "^3.0.3", - "libnpmfund": "^2.0.2", - "libnpmhook": "^7.0.1", - "libnpmorg": "^3.0.1", - "libnpmpack": "^3.1.0", - "libnpmpublish": "^5.0.1", - "libnpmsearch": "^4.0.1", - "libnpmteam": "^3.0.1", - "libnpmversion": "^2.0.2", - "make-fetch-happen": "^10.0.3", - "minipass": "^3.1.6", + "json-parse-even-better-errors": "^3.0.0", + "libnpmaccess": "^7.0.1", + "libnpmdiff": "^5.0.6", + "libnpmexec": "^5.0.6", + "libnpmfund": "^4.0.6", + "libnpmhook": "^9.0.1", + "libnpmorg": "^5.0.1", + "libnpmpack": "^5.0.6", + "libnpmpublish": "^7.0.6", + "libnpmsearch": "^6.0.1", + "libnpmteam": "^5.0.1", + "libnpmversion": "^4.0.1", + "make-fetch-happen": "^11.0.2", + "minimatch": "^5.1.1", + "minipass": "^4.0.0", "minipass-pipeline": "^1.2.4", "mkdirp": "^1.0.4", - "mkdirp-infer-owner": "^2.0.0", "ms": "^2.1.2", - "node-gyp": "^8.4.1", - "nopt": "^5.0.0", - "npm-audit-report": "^2.1.5", - "npm-install-checks": "^4.0.0", - "npm-package-arg": "^8.1.5", - "npm-pick-manifest": "^6.1.1", - "npm-profile": "^6.0.0", - "npm-registry-fetch": "^12.0.2", + "node-gyp": "^9.3.0", + "nopt": "^7.0.0", + "npm-audit-report": "^4.0.0", + "npm-install-checks": "^6.0.0", + "npm-package-arg": "^10.1.0", + "npm-pick-manifest": "^8.0.1", + "npm-profile": "^7.0.1", + "npm-registry-fetch": "^14.0.3", "npm-user-validate": "^1.0.1", - "npmlog": "^6.0.1", - "opener": "^1.5.2", - "pacote": "^12.0.3", - "parse-conflict-json": "^2.0.1", - "proc-log": "^1.0.0", + "npmlog": "^7.0.1", + "p-map": "^4.0.0", + "pacote": "^15.0.7", + "parse-conflict-json": "^3.0.0", + "proc-log": "^3.0.0", "qrcode-terminal": "^0.12.0", "read": "~1.0.7", - "read-package-json": "^4.1.1", - "read-package-json-fast": "^2.0.3", - "readdir-scoped-modules": "^1.1.0", + "read-package-json": "^6.0.0", + "read-package-json-fast": "^3.0.1", "rimraf": "^3.0.2", - "semver": "^7.3.5", - "ssri": "^8.0.1", - "tar": "^6.1.11", + "semver": "^7.3.8", + "ssri": "^10.0.1", + "tar": "^6.1.13", "text-table": "~0.2.0", "tiny-relative-date": "^1.3.0", - "treeverse": "^1.0.4", - "validate-npm-package-name": "~3.0.0", - "which": "^2.0.2", - "write-file-atomic": "^4.0.0" + "treeverse": "^3.0.0", + "validate-npm-package-name": "^5.0.0", + "which": "^3.0.0", + "write-file-atomic": "^5.0.0" }, "bundleDependencies": [ "@isaacs/string-locale-compare", "@npmcli/arborist", - "@npmcli/ci-detect", "@npmcli/config", "@npmcli/map-workspaces", "@npmcli/package-json", "@npmcli/run-script", "abbrev", - "ansicolors", - "ansistyles", "archy", "cacache", "chalk", - "chownr", + "ci-info", "cli-columns", "cli-table3", "columnify", "fastest-levenshtein", + "fs-minipass", "glob", "graceful-fs", "hosted-git-info", @@ -164,10 +157,10 @@ "libnpmteam", "libnpmversion", "make-fetch-happen", + "minimatch", "minipass", "minipass-pipeline", "mkdirp", - "mkdirp-infer-owner", "ms", "node-gyp", "nopt", @@ -179,7 +172,7 @@ "npm-registry-fetch", "npm-user-validate", "npmlog", - "opener", + "p-map", "pacote", "parse-conflict-json", "proc-log", @@ -187,7 +180,6 @@ "read", "read-package-json", "read-package-json-fast", - "readdir-scoped-modules", "rimraf", "semver", "ssri", @@ -200,32 +192,42 @@ "write-file-atomic" ], "devDependencies": { - "@npmcli/eslint-config": "^2.0.0", - "@npmcli/template-oss": "^2.4.3", - "eslint": "^8.3.0", - "licensee": "^8.2.0", + "@npmcli/docs": "^1.0.0", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/fs": "^3.1.0", + "@npmcli/git": "^4.0.1", + "@npmcli/mock-registry": "^1.0.0", + "@npmcli/promise-spawn": "^6.0.1", + "@npmcli/template-oss": "4.11.0", + "licensee": "^10.0.0", + "nock": "^13.2.4", + "npm-packlist": "^7.0.4", + "remark": "^14.0.2", + "remark-gfm": "^3.0.1", + "remark-github": "^11.2.4", "spawk": "^1.7.1", - "tap": "^15.1.6" + "tap": "^16.3.2" }, "scripts": { + "dependencies": "node scripts/bundle-and-gitignore-deps.js && node scripts/dependency-graph.js", "dumpconf": "env | grep npm | sort | uniq", - "preversion": "bash scripts/update-authors.sh && git add AUTHORS && git commit -m \"update AUTHORS\" || true", "licenses": "licensee --production --errors-only", "test": "tap", - "test-all": "npm run test --if-present --workspaces --include-workspace-root", - "check-coverage": "tap", + "test-all": "node . run test -ws -iwr --if-present", "snap": "tap", - "postsnap": "make -s mandocs", - "test:nocleanup": "NO_TEST_CLEANUP=1 npm run test --", - "sudotest": "sudo npm run test --", - "sudotest:nocleanup": "sudo NO_TEST_CLEANUP=1 npm run test --", - "posttest": "npm run lint", - "eslint": "eslint", - "lint": "npm run eslint -- bin lib scripts smoke-tests test ./*.js", - "lintfix": "npm run lint -- --fix", + "prepack": "node . run build -w docs", + "test:nocleanup": "NO_TEST_CLEANUP=1 node . run test --", + "sudotest": "sudo node . run run test --", + "sudotest:nocleanup": "sudo NO_TEST_CLEANUP=1 node . run test --", + "posttest": "node . run lint", + "lint": "eslint \"**/*.js\"", + "lintfix": "node . run lint -- --fix", + "lint-all": "node . run lint -ws -iwr --if-present", "prelint": "rimraf test/npm_cache*", - "resetdeps": "bash scripts/resetdeps.sh", - "smoke-tests": "tap smoke-tests/index.js" + "resetdeps": "node scripts/resetdeps.js", + "rp-pull-request": "node scripts/update-authors.js", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force" }, "tap": { "test-env": [ @@ -233,32 +235,28 @@ ], "color": 1, "files": "test/{lib,bin,index.js}", - "coverage-map": "test/coverage-map.js", - "check-coverage": true, - "timeout": 600 + "timeout": 600, + "nyc-arg": [ + "--exclude", + "docs/**", + "--exclude", + "smoke-tests/**", + "--exclude", + "mock-registry/**", + "--exclude", + "workspaces/**", + "--exclude", + "tap-snapshots/**" + ], + "test-ignore": "^(docs|smoke-tests|mock-registry|workspaces)/" }, "templateOSS": { - "applyRootRepoFiles": false, - "applyWorkspaceRepoFiles": true, - "applyRootModuleFiles": false, - "workspaces": [ - "@npmcli/arborist", - "libnpmaccess", - "libnpmdiff", - "libnpmfund", - "libnpmexec", - "libnpmorg", - "libnpmhook", - "libnpmpack", - "libnpmpublish", - "libnpmsearch", - "libnpmteam", - "libnpmversion" - ], - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "./scripts/template-oss/root.js" }, "license": "Artistic-2.0", "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } } diff --git a/release-please-config.json b/release-please-config.json new file mode 100644 index 0000000..389df42 --- /dev/null +++ b/release-please-config.json @@ -0,0 +1,78 @@ +{ + "bootstrap-sha": "141faf0c19eae382d0e19833129f5545fc2355c8", + "plugins": [ + "node-workspace" + ], + "changelog-sections": [ + { + "type": "feat", + "section": "Features", + "hidden": false + }, + { + "type": "fix", + "section": "Bug Fixes", + "hidden": false + }, + { + "type": "docs", + "section": "Documentation", + "hidden": false + }, + { + "type": "deps", + "section": "Dependencies", + "hidden": false + }, + { + "type": "chore", + "hidden": true + } + ], + "packages": { + ".": { + "package-name": "", + "prerelease": false + }, + "workspaces/arborist": { + "prerelease": false + }, + "workspaces/libnpmaccess": { + "prerelease": false + }, + "workspaces/libnpmdiff": { + "prerelease": false + }, + "workspaces/libnpmexec": { + "prerelease": false + }, + "workspaces/libnpmfund": { + "prerelease": false + }, + "workspaces/libnpmhook": { + "prerelease": false + }, + "workspaces/libnpmorg": { + "prerelease": false + }, + "workspaces/libnpmpack": { + "prerelease": false + }, + "workspaces/libnpmpublish": { + "prerelease": false + }, + "workspaces/libnpmsearch": { + "prerelease": false + }, + "workspaces/libnpmteam": { + "prerelease": false + }, + "workspaces/libnpmversion": { + "prerelease": false + }, + "workspaces/config": {} + }, + "exclude-packages-from-root": true, + "group-pull-request-title-pattern": "chore: release ${version}", + "pull-request-title-pattern": "chore: release${component} ${version}" +} diff --git a/scripts/bundle-and-gitignore-deps.js b/scripts/bundle-and-gitignore-deps.js index 96c1419..6057e8b 100644 --- a/scripts/bundle-and-gitignore-deps.js +++ b/scripts/bundle-and-gitignore-deps.js @@ -1,38 +1,24 @@ const Arborist = require('@npmcli/arborist') -const { resolve } = require('path') -const ignore = resolve(__dirname, '../node_modules/.gitignore') -const { writeFileSync } = require('fs') -const pj = resolve(__dirname, '../package.json') -const pkg = require(pj) -const bundle = [] -const arb = new Arborist({ path: resolve(__dirname, '..') }) -const shouldIgnore = [] +const packlist = require('npm-packlist') +const { join, relative } = require('path') +const localeCompare = require('@isaacs/string-locale-compare')('en') +const PackageJson = require('@npmcli/package-json') +const { run, CWD, git, fs } = require('./util') +const npmGit = require('@npmcli/git') -arb.loadVirtual().then(tree => { - for (const node of tree.children.values()) { - const has = (obj, key) => Object.prototype.hasOwnProperty.call(obj, key) - const nonProdWorkspace = - node.isWorkspace && !(has(tree.package.dependencies, node.name)) - if (node.dev || nonProdWorkspace) { - console.error('ignore', node.name) - shouldIgnore.push(node.name) - } else if (tree.edgesOut.has(node.name)) { - console.error('BUNDLE', node.name) - bundle.push(node.name) - } - } - pkg.bundleDependencies = bundle.sort((a, b) => a.localeCompare(b, 'en')) - - const ignores = shouldIgnore.sort((a, b) => a.localeCompare(b, 'en')) - .map(i => `/${i}`) - .join('\n') - const ignoreData = `# Automatically generated to ignore dev deps -/.package-lock.json +const ALWAYS_IGNORE = ` +.bin/ +.cache/ package-lock.json CHANGELOG* changelog* +ChangeLog* +Changelog* README* readme* +ReadMe* +Readme* +__pycache__ .editorconfig .idea/ .npmignore @@ -51,9 +37,219 @@ readme* .babelrc* .nyc_output .gitkeep - -${ignores} ` - writeFileSync(ignore, ignoreData) - writeFileSync(pj, JSON.stringify(pkg, 0, 2) + '\n') -}) + +const lsAndRmIgnored = async (dir) => { + const files = await git( + 'ls-files', + '--cached', + '--ignored', + `--exclude-standard`, + dir, + { lines: true } + ) + + for (const file of files) { + await git('rm', file) + } + + // check if there are still ignored files left + // if so we will error in the next step + const notRemoved = await git( + 'ls-files', + '--cached', + '--ignored', + `--exclude-standard`, + dir, + { lines: true } + ) + + return notRemoved +} + +const getAllowedPaths = (files) => { + // Get all files within node_modules and remove + // the node_modules/ portion of the path for processing + // since this list will go inside a gitignore at the + // root of the node_modules dir + const nmFiles = files + .filter(f => f.startsWith('node_modules/')) + .map(f => f.replace(/^node_modules\//, '')) + .sort(localeCompare) + + class AllowSegments { + #segments + #usedSegments + + constructor (pathSegments, rootSegments = []) { + // Copy strings with spread operator since we mutate these arrays + this.#segments = [...pathSegments] + this.#usedSegments = [...rootSegments] + } + + get next () { + return this.#segments[0] + } + + get remaining () { + return this.#segments + } + + get used () { + return this.#usedSegments + } + + use () { + const segment = this.#segments.shift() + this.#usedSegments.push(segment) + return segment + } + + allowContents ({ use = true, isDirectory = true } = {}) { + if (use) { + this.use() + } + // Allow a previously ignored directy + // Important: this should NOT have a trailing + // slash if we are not sure it is a directory. + // Since a dep can be a directory or a symlink and + // a trailing slash in a .gitignore file + // tells git to treat it only as a directory + return [`!/${this.used.join('/')}${isDirectory ? '/' : ''}`] + } + + allow ({ use = true } = {}) { + if (use) { + this.use() + } + // Allow a previously ignored directory but ignore everything inside + return [ + ...this.allowContents({ use: false, isDirectory: true }), + `/${this.used.join('/')}/*`, + ] + } + } + + const gatherAllows = (pathParts, usedParts) => { + const ignores = [] + const segments = new AllowSegments(pathParts, usedParts) + + if (segments.next) { + // 1) Process scope segment of the path, if it has one + if (segments.next.startsWith('@')) { + // For scoped deps we need to allow the entire scope dir + // due to how gitignore works. Without this the gitignore will + // never look to allow our bundled dep since the scope dir was ignored. + // It ends up looking like this for `@colors/colors`: + // + // # Allow @colors dir + // !/@colors/ + // # Ignore everything inside. This is safe because there is + // # nothing inside a scope except other packages + // !/colors/* + // + // Then later we will allow the specific dep inside that scope. + // This way if a scope includes bundled AND unbundled deps, + // we only allow the bundled ones. + ignores.push(...segments.allow()) + } + + // 2) Now we process the name segment of the path + // and allow the dir and everything inside of it (like source code, etc) + ignores.push(...segments.allowContents({ isDirectory: false })) + + // 3) If we still have remaining segments and the next segment + // is a nested node_modules directory... + if (segments.next && segments.use() === 'node_modules') { + ignores.push( + // Allow node_modules and ignore everything inside of it + // Set false here since we already "used" the node_modules path segment + ...segments.allow({ use: false }), + // Repeat the process with the remaining path segments to include whatever is left + ...gatherAllows(segments.remaining, segments.used) + ) + } + } + + return ignores + } + + const allowPaths = new Set() + for (const file of nmFiles) { + for (const allow of gatherAllows(file.split('/'))) { + allowPaths.add(allow) + } + } + + return [...allowPaths] +} + +const setBundleDeps = async () => { + const pkg = await PackageJson.load(CWD) + + pkg.update({ + bundleDependencies: Object.keys(pkg.content.dependencies).sort(localeCompare), + }) + + await pkg.save() + + return pkg.content.bundleDependencies +} + +/* +This file sets what is checked in to node_modules. The root .gitignore file +includes node_modules and this file writes an ignore file to +node_modules/.gitignore. We ignore everything and then use a query to find all +the bundled deps and allow each one of those explicitly. + +Since node_modules can be nested we have to process each portion of the path and +allow it while also ignoring everything inside of it, with the exception of a +deps source. We have to do this since everything is ignored by default, and git +will not allow a nested path if its parent has not also been allowed. BUT! We +also have to ignore other things in those directories. +*/ +const main = async () => { + await setBundleDeps() + + const arb = new Arborist({ path: CWD }) + const files = await arb.loadActual().then(packlist) + + const ignoreFile = [ + '# Automatically generated to ignore everything except bundled deps', + '# Ignore everything by default except this file', + '/*', + '!/.gitignore', + '# Allow all bundled deps', + ...getAllowedPaths(files), + '# Always ignore some specific patterns within any allowed package', + ...ALWAYS_IGNORE.trim().split('\n'), + ] + + const NODE_MODULES = join(CWD, 'node_modules') + const res = await fs.writeFile(join(NODE_MODULES, '.gitignore'), ignoreFile.join('\n')) + + if (!await npmGit.is({ cwd: CWD })) { + // if we are not running in a git repo then write the files but we do not + // need to run any git commands to check if we have unmatched files in source + return res + } + + // After we write the file we have to check if any of the paths already checked in + // inside node_modules are now going to be ignored. If we find any then fail with + // a list of the paths remaining. We already attempted to `git rm` them so just + // explain what happened and leave the repo in a state to debug. + const trackedAndIgnored = await lsAndRmIgnored(NODE_MODULES) + + if (trackedAndIgnored.length) { + const message = [ + 'The following files are checked in to git but will now be ignored.', + `They could not be removed automatically and will need to be removed manually.`, + ...trackedAndIgnored.map(p => relative(NODE_MODULES, p)), + ].join('\n') + throw new Error(message) + } + + return res +} + +run(main) diff --git a/scripts/changelog.js b/scripts/changelog.js deleted file mode 100644 index d385468..0000000 --- a/scripts/changelog.js +++ /dev/null @@ -1,107 +0,0 @@ -'use strict' - -/* -Usage: - -node scripts/changelog.js [comittish] - -Generates changelog entries in our format as best as its able based on -commits starting at comittish, or if that's not passed, latest. - -Ordinarily this is run via the gen-changelog shell script, which appends -the result to the changelog. - -*/ -const execSync = require('child_process').execSync -const branch = process.argv[2] || 'origin/latest' -const log = execSync(`git log --reverse --pretty='format:%h' ${branch}...`) - .toString() - .split(/\n/) - -function printCommit (c) { - console.log(`* [\`${c.hash}\`](${c.url})`) - for (const pr of c.prs) { - console.log(` [#${pr.number}](${pr.url})`) - // remove the (#111) relating to this pull request from the commit message, - // since we manually add the link outside of the commit message - const msgRe = new RegExp(`\\s*\\(#${pr.number}\\)`, 'g') - c.message = c.message.replace(msgRe, '') - } - // no need to indent this output, it's already got 2 spaces - console.log(c.message) - // no credit for deps commits, leading spaces are important here - if (!c.message.startsWith(' deps')) { - for (const user of c.credit) { - console.log(` ([${user.name}](${user.url}))`) - } - } -} - -const main = async () => { - const query = ` - fragment commitCredit on GitObject { - ... on Commit { - message - url - authors (first:10) { - nodes { - user { - login - url - } - email - name - } - } - associatedPullRequests (first:10) { - nodes { - number - url - merged - } - } - } - } - - query { - repository (owner:"npm", name:"cli") { - ${log.map((sha) => `_${sha}: object (expression: "${sha}") { - ...commitCredit - }`).join('\n')} - } - } - ` - - const response = execSync(`gh api graphql -f query='${query}'`).toString() - const body = JSON.parse(response) - - for (const [hash, data] of Object.entries(body.data.repository)) { - const commit = { - hash: hash.slice(1), // remove leading _ - url: data.url, - message: data.message.replace(/(\r?\n)+/gm, '\n') // swap multiple new lines with one - .replace(/^/gm, ' ') // add two spaces to the start of each line - .replace(/([^\s]+@\d+\.\d+\.\d+.*)/g, '`$1`'), // wrap package@version in backticks - prs: data.associatedPullRequests.nodes.filter((pull) => pull.merged), - credit: data.authors.nodes.map((author) => { - if (author.user && author.user.login) { - return { - name: `@${author.user.login}`, - url: author.user.url, - } - } - // if the commit used an email that's not associated with a github account - // then the user field will be empty, so we fall back to using the committer's - // name and email as specified by git - return { - name: author.name, - url: `mailto:${author.email}`, - } - }), - } - - printCommit(commit) - } -} - -main() diff --git a/scripts/clean-old.sh b/scripts/clean-old.sh deleted file mode 100755 index 32a203e..0000000 --- a/scripts/clean-old.sh +++ /dev/null @@ -1,165 +0,0 @@ -#!/usr/bin/env bash - -# look for old 0.x cruft, and get rid of it. -# Should already be sitting in the npm folder. - -# This doesn't have to be quite as cross-platform as install.sh. -# There are some bash-isms, because maintaining *two* -# fully-portable posix/bourne sh scripts is too much for -# one project with a sane maintainer. - -# If readlink isn't available, then this is just too tricky. -# However, greadlink is fine, so Solaris can join the party, too. -readlink="readlink" -which $readlink >/dev/null 2>/dev/null -if [ $? -ne 0 ]; then - readlink="greadlink" - which $readlink >/dev/null 2>/dev/null - if [ $? -ne 0 ]; then - echo "Can't find the readlink or greadlink command. Aborting." - exit 1 - fi -fi - -if [ "x$npm_config_prefix" != "x" ]; then - PREFIXES=$npm_config_prefix -else - node="$NODE" - if [ "x$node" = "x" ]; then - node=`which node` - fi - if [ "x$node" = "x" ]; then - echo "Can't find node to determine prefix. Aborting." - exit 1 - fi - - - PREFIX=`dirname $node` - PREFIX=`dirname $PREFIX` - echo "cleanup prefix=$PREFIX" - PREFIXES=$PREFIX - - altprefix=`"$node" -e process.installPrefix` - if [ "x$altprefix" != "x" ] && [ "x$altprefix" != "x$PREFIX" ]; then - echo "altprefix=$altprefix" - PREFIXES="$PREFIX $altprefix" - fi -fi - -# now prefix is where npm would be rooted by default -# go hunting. - -packages= -for prefix in $PREFIXES; do - packages="$packages - "`ls "$prefix"/lib/node/.npm 2>/dev/null | grep -v .cache` -done - -packages=`echo $packages` - -filelist=() -fid=0 - -for prefix in $PREFIXES; do - # remove any links into the .npm dir, or links to - # version-named shims/symlinks. - for folder in share/man bin lib/node; do - find $prefix/$folder -type l | while read file; do - target=`$readlink $file | grep '/\.npm/'` - if [ "x$target" != "x" ]; then - # found one! - filelist[$fid]="$file" - let 'fid++' - # also remove any symlinks to this file. - base=`basename "$file"` - base=`echo "$base" | awk -F@ '{print $1}'` - if [ "x$base" != "x" ]; then - find "`dirname $file`" -type l -name "$base"'*' \ - | while read l; do - target=`$readlink "$l" | grep "$base"` - if [ "x$target" != "x" ]; then - filelist[$fid]="$1" - let 'fid++' - fi - done - fi - fi - done - - # Scour for shim files. These are relics of 0.2 npm installs. - # note: grep -r is not portable. - find $prefix/$folder -type f \ - | xargs grep -sl '// generated by npm' \ - | while read file; do - filelist[$fid]="$file" - let 'fid++' - done - done - - # now remove the package modules, and the .npm folder itself. - if [ "x$packages" != "x" ]; then - for pkg in $packages; do - filelist[$fid]="$prefix/lib/node/$pkg" - let 'fid++' - for i in $prefix/lib/node/$pkg\@*; do - filelist[$fid]="$i" - let 'fid++' - done - done - fi - - for folder in lib/node/.npm lib/npm share/npm; do - if [ -d $prefix/$folder ]; then - filelist[$fid]="$prefix/$folder" - let 'fid++' - fi - done -done - -# now actually clean, but only if there's anything TO clean -if [ "${#filelist[@]}" -gt 0 ]; then - echo "" - echo "This script will find and eliminate any shims, symbolic" - echo "links, and other cruft that was installed by npm 0.x." - echo "" - - if [ "x$packages" != "x" ]; then - echo "The following packages appear to have been installed with" - echo "an old version of npm, and will be removed forcibly:" - for pkg in $packages; do - echo " $pkg" - done - echo "Make a note of these. You may want to install them" - echo "with npm 1.0 when this process is completed." - echo "" - fi - - OK= - if [ "x$1" = "x-y" ]; then - OK="yes" - fi - - while [ "$OK" != "y" ] && [ "$OK" != "yes" ] && [ "$OK" != "no" ]; do - echo "Is this OK?" - echo " enter 'yes' or 'no'" - echo " or 'show' to see a list of files " - read OK - if [ "x$OK" = "xshow" ] || [ "x$OK" = "xs" ]; then - for i in "${filelist[@]}"; do - echo "$i" - done - fi - done - if [ "$OK" = "no" ]; then - echo "Aborting" - exit 1 - fi - for i in "${filelist[@]}"; do - rm -rf "$i" - done -fi - -echo "" -echo 'All clean!' - -exit 0 diff --git a/scripts/config-doc-command.js b/scripts/config-doc-command.js deleted file mode 100644 index 9db026f..0000000 --- a/scripts/config-doc-command.js +++ /dev/null @@ -1,55 +0,0 @@ -const { definitions } = require('../lib/utils/config/index.js') -const { writeFileSync, readFileSync } = require('fs') -const { resolve } = require('path') - -const configDoc = process.argv[2] -const commandFile = process.argv[3] - -// Note: commands without params skip this whole process. -const { params } = require(resolve(commandFile)) - -const describeAll = () => - params.map(name => definitions[name].describe()).join( - '\n\n<!-- automatically generated, do not edit manually -->\n' + - '<!-- see lib/utils/config/definitions.js -->\n\n' - ) - -const addBetweenTags = (doc, startTag, endTag, body) => { - const startSplit = doc.split(startTag) - if (startSplit.length !== 2) { - throw new Error('Did not find exactly one start tag') - } - - const endSplit = startSplit[1].split(endTag) - if (endSplit.length !== 2) { - throw new Error('Did not find exactly one end tag') - } - - return [ - startSplit[0], - startTag, - '\n<!-- automatically generated, do not edit manually -->\n' + - '<!-- see lib/utils/config/definitions.js -->\n', - body, - '\n\n<!-- automatically generated, do not edit manually -->\n' + - '<!-- see lib/utils/config/definitions.js -->', - '\n\n', - endTag, - endSplit[1], - ].join('') -} - -const addDescriptions = doc => { - const startTag = '<!-- AUTOGENERATED CONFIG DESCRIPTIONS START -->' - const endTag = '<!-- AUTOGENERATED CONFIG DESCRIPTIONS END -->' - return addBetweenTags(doc, startTag, endTag, describeAll()) -} - -// always write SOMETHING so that Make sees the file is up to date. -const doc = readFileSync(configDoc, 'utf8') -const hasTag = doc.includes('<!-- AUTOGENERATED CONFIG DESCRIPTIONS START -->') -const newDoc = params && hasTag ? addDescriptions(doc) : doc -if (params && !hasTag) { - console.error('WARNING: did not find config description section', configDoc) -} -writeFileSync(configDoc, newDoc) diff --git a/scripts/config-doc.js b/scripts/config-doc.js deleted file mode 100644 index b14baa3..0000000 --- a/scripts/config-doc.js +++ /dev/null @@ -1,54 +0,0 @@ -const { shorthands, describeAll } = require('../lib/utils/config/index.js') -const { writeFileSync, readFileSync } = require('fs') -const { resolve } = require('path') -const configDoc = resolve(__dirname, '../docs/content/using-npm/config.md') - -const addBetweenTags = (doc, startTag, endTag, body) => { - const startSplit = doc.split(startTag) - if (startSplit.length !== 2) { - throw new Error('Did not find exactly one start tag') - } - - const endSplit = startSplit[1].split(endTag) - if (endSplit.length !== 2) { - throw new Error('Did not find exactly one end tag') - } - - return [ - startSplit[0], - startTag, - '\n<!-- automatically generated, do not edit manually -->\n' + - '<!-- see lib/utils/config/definitions.js -->\n', - body, - '\n\n<!-- automatically generated, do not edit manually -->\n' + - '<!-- see lib/utils/config/definitions.js -->\n', - endTag, - endSplit[1], - ].join('') -} - -const addDescriptions = doc => { - const startTag = '<!-- AUTOGENERATED CONFIG DESCRIPTIONS START -->' - const endTag = '<!-- AUTOGENERATED CONFIG DESCRIPTIONS END -->' - return addBetweenTags(doc, startTag, endTag, describeAll()) -} - -const addShorthands = doc => { - const startTag = '<!-- AUTOGENERATED CONFIG SHORTHANDS START -->' - const endTag = '<!-- AUTOGENERATED CONFIG SHORTHANDS END -->' - const body = Object.entries(shorthands) - .sort(([shorta, expansiona], [shortb, expansionb]) => { - // sort by what they're short FOR - return expansiona.join(' ').localeCompare(expansionb.join(' '), 'en') || - shorta.localeCompare(shortb, 'en') - }) - .map(([short, expansion]) => { - const dash = short.length === 1 ? '-' : '--' - return `* \`${dash}${short}\`: \`${expansion.join(' ')}\`` - }).join('\n') - return addBetweenTags(doc, startTag, endTag, body) -} - -const doc = readFileSync(configDoc, 'utf8') -writeFileSync(configDoc, addDescriptions(addShorthands(doc))) -console.log(`updated docs/content/using-npm/config.md`) diff --git a/scripts/create-node-pr.js b/scripts/create-node-pr.js new file mode 100644 index 0000000..712f71b --- /dev/null +++ b/scripts/create-node-pr.js @@ -0,0 +1,284 @@ +const { join, basename } = require('path') +const fsp = require('fs/promises') +const hgi = require('hosted-git-info') +const semver = require('semver') +const pacote = require('pacote') +const log = require('proc-log') +const tar = require('tar') +const { cp, withTempDir } = require('@npmcli/fs') +const { CWD, run, spawn, git, fs, gh } = require('./util.js') + +const NODE_FORK = 'npm/node' +// this script expects node to already be cloned to a directory at the cli root named "node" +const NODE_DIR = join(CWD, 'node') +const gitNode = spawn.create('git', { cwd: NODE_DIR }) + +const createNodeTarball = async ({ mani, registryOnly, localTest, tag, dir: extractDir }) => { + const tarball = join(extractDir, 'npm-node.tgz') + await pacote.tarball.file(mani._from, tarball, { resolved: mani._resolved }) + + if (registryOnly) { + // a future goal is to only need files from the published tarball for + // inclusion in node. in that case, we'd be able to remove everything after + // this line since we have already fetched the tarball + return tarball + } + + // extract tarball to current dir and delete original tarball + await tar.x({ strip: 1, file: tarball, cwd: extractDir }) + await fs.rimraf(tarball) + + // checkout the tag since we need to get files from source. + if (!localTest) { + try { + await git('checkout', tag) + } catch (err) { + log.error('Use the `--local-test` flag to avoid checking out the tag') + throw err + } + } + // currently there is an empty .npmrc file in the deps/npm dir in the node repo + // i do not know why and it might not be used but in order to minimize any + // unnecessary churn, let's create that file to match the old process + await fsp.writeFile(join(extractDir, '.npmrc'), '', 'utf-8') + + // copy our test dirs so that tests can be run + for (const path of ['tap-snapshots/', 'test/']) { + await cp(join(CWD, path), join(extractDir, path), { recursive: true }) + } + + // recreate the tarball as closely as possible to how we would before publishing + // to the registry. the only difference here is the extra files we put in the dir + await tar.c({ + ...pacote.DirFetcher.tarCreateOptions(mani), + cwd: extractDir, + file: tarball, + }, ['.']) + + return tarball +} + +const getPrBody = async ({ releases, closePrs }) => { + const useSummary = releases.length > 1 + const releasePath = (v) => `/npm/cli/releases/tag/v${v}` + + // XXX: add links to relevant CI and CITGM runs once we no longer include our tests + let prBody = '' + + if (useSummary) { + const summary = releases.map(r => { + return `[\`npm@${r.version}\`](https://github.com${releasePath(r.version)})` + }) + prBody += `This PR contains changes from: ${summary.join(' ')}\n\n` + } + + if (closePrs.length) { + prBody += `This PR replaces: ${closePrs.map(pr => pr.url).join(' ')}\n\n` + } + + if (prBody) { + prBody += '---\n\n' + } + + for (const { version, body } of releases) { + prBody += useSummary + ? `<details><summary>${version}</summary>\n<p>\n\n${body}\n\n</p>\n</details>` + : body + prBody += '\n' + } + + // These comes from the releases so those link to the raw comparison between tags. + // Since we are putting this in a PR we can change those links back to the releases. + prBody = prBody.replace(/\/npm\/cli\/compare\/v[\w.-]+\.\.\.v([\w.-]+)/g, releasePath('$1')) + + const { remark } = await import('remark') + const { default: remarkGfm } = await import('remark-gfm') + const { default: remarkGithub } = await import('remark-github') + + return remark() + .use(remarkGfm) + .use(remarkGithub, { + repository: 'npm/cli', + // dont link mentions, but anything else make the link an explicit referance to npm/cli + buildUrl: (values, buildUrl) => values.type === 'mention' ? false : buildUrl(values), + }) + .process(prBody) + .then(v => String(v)) +} + +const tokenRemoteUrl = ({ host, token }) => { + // this is a remote url that uses a github token as the username + // in order to authenticate with github + const headRemoteUrl = new URL(host.https()) + headRemoteUrl.username = token + // we have to manually change the protocol. the whatwg url spec + // does not allow changing a special protocol to another one + // but the protocol has to be `https:` without the `git+` + return headRemoteUrl.toString().replace('git+https:', 'https:') +} + +const main = async (spec, branch = 'main', opts) => withTempDir(CWD, async (tmpDir) => { + const { GITHUB_TOKEN } = process.env + const { dryRun, registryOnly, localTest } = opts + + if (!spec) { + throw new Error('`spec` is required as the first argument') + } + + if (!branch) { + throw new Error('`branch` is required as the second argument') + } + + if (!GITHUB_TOKEN) { + throw new Error(`process.env.GITHUB_TOKEN is required`) + } + + await fsp.access(NODE_DIR, fsp.constants.F_OK).catch(() => { + throw new Error(`node repo must be checked out to \`${NODE_DIR}\` to continue`) + }) + + await gh.json('repo', 'view', NODE_FORK, 'url').catch(() => { + throw new Error(`node repo must be forked to ${NODE_FORK}`) + }) + + await git.dirty().catch((er) => { + if (localTest) { + return log.info('Skipping git dirty check due to `--local-test` flag') + } + throw er + }) + + const mani = await pacote.manifest(`npm@${spec}`, { preferOnline: true }) + const packument = await pacote.packument('npm', { preferOnline: true }) + const npmVersions = Object.keys(packument.versions).sort(semver.rcompare) + + const npmVersion = semver.parse(mani.version) + const npmHost = hgi.fromUrl(NODE_FORK) + const npmTag = `v${npmVersion}` + const npmBranch = `npm-${npmTag}` + const npmRemoteUrl = tokenRemoteUrl({ host: npmHost, token: GITHUB_TOKEN }) + const npmMessage = (v = npmVersion) => `deps: upgrade npm to ${v}` + + const tarball = await createNodeTarball({ + mani, + tag: npmTag, + dir: tmpDir, + registryOnly, + localTest, + }) + log.info('tarball path', tarball) + + const nodeRemote = 'origin' + const nodeBranch = /^\d+$/.test(branch) ? `v${branch}.x-staging` : branch + const nodeHost = hgi.fromUrl(await gitNode('remote', 'get-url', nodeRemote, { out: true })) + const nodePrArgs = ['pr', '-R', nodeHost.path()] + + await gitNode('fetch', nodeRemote) + await gitNode('checkout', nodeBranch) + await gitNode('reset', '--hard', `${nodeRemote}/${nodeBranch}`) + + const nodeNpmPath = join('deps', 'npm') + const nodeNpmDir = join(NODE_DIR, nodeNpmPath) + const nodeNpmVersion = require(join(nodeNpmDir, 'package.json')).version + + // this is the range of all versions included in this update based + // on the current version of npm in node currently. we use this + // to build a list of all release notes and to close any existing PRs + const newNpmVersions = npmVersions.slice( + npmVersions.indexOf(npmVersion.toString()), + npmVersions.indexOf(nodeNpmVersion) + ) + .reverse() + .map((v) => semver.parse(v)) + .filter((version) => version.major === npmVersion.major) + + // get a list of all versions changelogs to add to the body of the PR + // do this before we checkout our branch and make any changes + const npmReleases = await Promise.all(newNpmVersions.map(async (v) => { + // dont include prereleases unless we are updating to a prerlease since we + // manually put all prerelease notes into the first stable major version + if (v.prerelease.length && !npmVersion.prerelease.length) { + return null + } + return { + version: v, + body: await gh.json('release', 'view', `v${v}`, 'body', { quiet: true }).then(r => r.trim()), + } + })).then(r => r.filter(Boolean)) + + log.info('npm versions', newNpmVersions.map(v => v.toString())) + log.info('npm releases', npmReleases.map(u => u.version.toString())) + + await gitNode('branch', '-D', npmBranch, { ok: true }) + await gitNode('checkout', '-b', npmBranch) + await fs.clean(nodeNpmDir) + await tar.x({ strip: 1, file: tarball, cwd: nodeNpmDir }) + await fs.rimraf(join(nodeNpmDir, basename(tarball))) + + await gitNode('add', '-A', nodeNpmPath) + await gitNode('commit', '-m', npmMessage()) + await gitNode('rebase', '--whitespace', 'fix', nodeBranch) + + await gitNode('remote', 'rm', npmHost.user, { ok: true }) + await gitNode('remote', 'add', npmHost.user, npmRemoteUrl) + if (!dryRun) { + await gitNode('push', npmHost.user, npmBranch, '--force') + } + + const npmPrs = await gh.json( + ...nodePrArgs, 'list', + '-S', `in:title "${npmMessage('')}"`, + 'number,title,url' + ) + + log.info('Found other npm PRs', npmPrs) + + let existingPr = null + const closePrs = [] + + for (const pr of npmPrs) { + const prVersion = pr.title.replace(npmMessage(''), '').trim() + log.silly('checking existing PR', prVersion, pr) + + if (!existingPr && prVersion === npmVersion.toString()) { + existingPr = pr + } else if (newNpmVersions.some(v => v.toString() === prVersion)) { + closePrs.push(pr) + } + } + + log.info('Found exisiting PR', existingPr) + log.info('Found PRs to close', closePrs) + + const prBody = await getPrBody({ releases: npmReleases, closePrs }) + + const prArgs = [ + nodePrArgs, + (existingPr ? ['edit', existingPr.number] : ['create', '-H', `${npmHost.user}:${npmBranch}`]), + '-B', nodeBranch, + '-t', npmMessage(), + ].flat() + + if (dryRun) { + log.info(`gh ${prArgs.join(' ')}`) + return prBody + } + + const newOrUpdatedPr = await gh(prArgs, '-F', '-', { input: prBody, out: true }) + const closeMessage = `Closing in favor of ${newOrUpdatedPr}` + + for (const closePr of closePrs) { + log.info('Attempting to close PR', closePr.url) + try { + await gh(nodePrArgs, 'close', closePr.number, '-c', closeMessage) + } catch (err) { + log.error('Could not close PR', err) + } + } + + return newOrUpdatedPr +}) + +run(({ argv, ...opts }) => main(argv.remain[0], argv.remain[1], opts), { + redact: new RegExp(process.env.GITHUB_TOKEN, 'g'), +}) diff --git a/scripts/dependency-graph.js b/scripts/dependency-graph.js new file mode 100644 index 0000000..2d8a773 --- /dev/null +++ b/scripts/dependency-graph.js @@ -0,0 +1,189 @@ +const Arborist = require('@npmcli/arborist') +const { readFileSync } = require('fs') +const { join } = require('path') +const log = require('proc-log') +const { run, CWD, pkg, fs } = require('./util.js') + +// Generates our dependency graph documents in DEPENDENCIES.md. + +// To re-create npm-cli-repos.txt run: +// npx -p @npmcli/stafftools gh repos --json | json -a name | sort > scripts/npm-cli-repos.txt +const repos = readFileSync(join(CWD, 'scripts', 'npm-cli-repos.txt'), 'utf-8').trim().split('\n') + +// these have a different package name than the repo name, and are ours. +const aliases = { + semver: 'node-semver', + abbrev: 'abbrev-js', +} + +// These are entries in npm-cli-repos.txt that correlate to namespaced repos. +// If we see a bare package with just this name, it's NOT ours +const namespaced = [ + 'arborist', + 'config', + 'disparity-colors', + 'eslint-config', + 'exec', + 'fs', + 'git', + 'installed-package-contents', + 'lint', + 'map-workspaces', + 'metavuln-calculator', + 'move-file', + 'name-from-folder', + 'node-gyp', + 'package-json', + 'promise-spawn', + 'run-script', + 'template-oss', +] + +function isOurs (name) { + if (name.startsWith('libnpm')) { + return true + } + if (name.startsWith('@npmcli')) { + return true + } + if (aliases[name]) { + return true + } + // this will prevent e.g. `fs` from being mistaken as ours + if (namespaced.includes(name)) { + return false + } + if (repos.includes(name)) { + return true + } + return false +} + +function escapeName (name) { + if (name.startsWith('@')) { + return `${stripName(name)}["${name}"]` + } + return name +} + +function stripName (name) { + if (name.startsWith('@')) { + const parts = name.slice(1).split('/') + return `${parts[0]}-${parts[1]}` + } + return name +} + +const main = async function () { + // add all of the cli's public workspaces as package names + for (const { name, pkg: ws } of await pkg.mapWorkspaces()) { + if (!ws.private) { + repos.push(name) + } + } + + const arborist = new Arborist({ prefix: CWD, path: CWD }) + const tree = await arborist.loadVirtual({ path: CWD, name: 'npm' }) + tree.name = 'npm' + + const [annotationsOurs, heirarchyOurs] = walk(tree, true) + const [annotationsAll] = walk(tree, false) + + const out = [ + '# npm dependencies', + '', + '## `github.com/npm/` only', + '```mermaid', + 'graph LR;', + ...annotationsOurs.sort(), + '```', + '', + '## all dependencies', + '```mermaid', + 'graph LR;', + ...annotationsAll.sort(), + '```', + '', + '## npm dependency heirarchy', + '', + 'These are the groups of dependencies in npm that depend on each other.', + 'Each group depends on packages lower down the chain, nothing depends on', + 'packages higher up the chain.', + '', + ` - ${heirarchyOurs.reverse().join('\n - ')}`, + ] + + return fs.writeFile(join(CWD, 'DEPENDENCIES.md'), out.join('\n')) +} + +const walk = function (tree, onlyOurs) { + const annotations = [] // mermaid dependency annotations + const dependedBy = {} + + iterate(tree, dependedBy, annotations, onlyOurs) + + const allDeps = new Set(Object.keys(dependedBy)) + const foundDeps = new Set() + const heirarchy = [] + + if (onlyOurs) { + while (allDeps.size) { + log.silly('SIZE', allDeps.size) + const level = [] + + for (const dep of allDeps) { + log.silly(dep, '::', [...dependedBy[dep]].join(', ')) + log.silly('-'.repeat(80)) + + if (!dependedBy[dep].size) { + level.push(dep) + foundDeps.add(dep) + } + } + + log.silly('LEVEL', level.length) + log.silly('FOUND', foundDeps.size) + + for (const dep of allDeps) { + for (const found of foundDeps) { + allDeps.delete(found) + dependedBy[dep].delete(found) + } + } + + log.silly('SIZE', allDeps.size) + + if (!level.length) { + const remaining = `Remaining deps: ${[...allDeps.keys()]}` + throw new Error(`Would do an infinite loop here, need to debug. ${remaining}`) + } + + heirarchy.push(level.join(', ')) + log.silly('HIEARARCHY', heirarchy.length) + log.silly('='.repeat(80)) + } + } + + return [annotations, heirarchy] +} + +const iterate = function (node, dependedBy, annotations, onlyOurs) { + if (!dependedBy[node.packageName]) { + dependedBy[node.packageName] = new Set() + } + for (const [name, edge] of node.edgesOut) { + if ( + (!onlyOurs || isOurs(name)) && !node.dev + ) { + if (!dependedBy[node.packageName].has(edge.name)) { + dependedBy[node.packageName].add(edge.name) + annotations.push(` ${stripName(node.packageName)}-->${escapeName(edge.name)};`) + if (edge.to) { + iterate(edge.to.target, dependedBy, annotations, onlyOurs) + } + } + } + } +} + +run(main) diff --git a/scripts/docs-build.js b/scripts/docs-build.js deleted file mode 100644 index f786e59..0000000 --- a/scripts/docs-build.js +++ /dev/null @@ -1,45 +0,0 @@ -#!/usr/bin/env node - -var fs = require('fs') -var marked = require('marked-man') -var npm = require('../lib/npm.js') -var args = process.argv.slice(2) -var src = args[0] -var dest = args[1] || src - -fs.readFile(src, 'utf8', function (err, data) { - if (err) { - return console.log(err) - } - - function frontmatter (match, p1) { - const fm = { } - - p1.split(/\r?\n/).forEach((kv) => { - const result = kv.match(/^([^\s:]+):\s*(.*)/) - if (result) { - fm[result[1]] = result[2] - } - }) - - return `# ${fm.title}(${fm.section}) - ${fm.description}` - } - - function replacer (match, p1) { - return 'npm help ' + p1.replace(/npm /, '') - } - - var result = data.replace(/@VERSION@/g, npm.version) - .replace(/^---\n([\s\S]+\n)---/, frontmatter) - .replace(/\[([^\]]+)\]\(\/commands\/([^)]+)\)/g, replacer) - .replace(/\[([^\]]+)\]\(\/configuring-npm\/([^)]+)\)/g, replacer) - .replace(/\[([^\]]+)\]\(\/using-npm\/([^)]+)\)/g, replacer) - .trim() - - var date = new Date(process.env.SOURCE_DATE_EPOCH) - fs.writeFile(dest, marked(result, {date}), 'utf8', function (err) { - if (err) { - return console.log(err) - } - }) -}) diff --git a/scripts/git-dirty.js b/scripts/git-dirty.js index 484a4d2..1c86485 100644 --- a/scripts/git-dirty.js +++ b/scripts/git-dirty.js @@ -1,17 +1,3 @@ -#!/usr/bin/env node -const { spawnSync } = require('child_process') -const changes = spawnSync('git', ['status', '--porcelain', '-uno']) -const stdout = changes.stdout.toString('utf8') -const stderr = changes.stderr.toString('utf8') -const { status, signal } = changes -console.log(stdout) -console.error(stderr) -if (status || signal) { - console.error({ status, signal }) - process.exitCode = status || 1 -} -if (stdout.trim() !== '') { - throw new Error('git dirty') -} else { - console.log('git clean') -} +const { run, git } = require('./util.js') + +run(git.dirty) diff --git a/scripts/install.sh b/scripts/install.sh deleted file mode 100755 index cd6ea39..0000000 --- a/scripts/install.sh +++ /dev/null @@ -1,175 +0,0 @@ -#!/bin/sh - -# A word about this shell script: -# -# It must work everywhere, including on systems that lack -# a /bin/bash, map 'sh' to ksh, ksh97, bash, ash, or zsh, -# and potentially have either a posix shell or bourne -# shell living at /bin/sh. -# -# See this helpful document on writing portable shell scripts: -# http://www.gnu.org/s/hello/manual/autoconf/Portable-Shell.html -# -# The only shell it won't ever work on is cmd.exe. - -if [ "x$0" = "xsh" ]; then - # run as curl | sh - # on some systems, you can just do cat>npm-install.sh - # which is a bit cuter. But on others, &1 is already closed, - # so catting to another script file won't do anything. - # Follow Location: headers, and fail on errors - curl -q -f -L -s https://www.npmjs.org/install.sh > npm-install-$$.sh - ret=$? - if [ $ret -eq 0 ]; then - (exit 0) - else - rm npm-install-$$.sh - echo "failed to download script" >&2 - exit $ret - fi - sh npm-install-$$.sh - ret=$? - rm npm-install-$$.sh - exit $ret -fi - -debug=0 -npm_config_loglevel="error" -if [ "x$npm_debug" = "x" ]; then - (exit 0) -else - echo "running in debug mode." - echo "note that this requires bash or zsh." - set -o xtrace - set -o pipefail - npm_config_loglevel="verbose" - debug=1 -fi -export npm_config_loglevel - -# make sure that node exists -node=`which node 2>&1` -ret=$? -# if not found, try "nodejs" as it is the case on debian -if [ $ret -ne 0 ]; then - node=`which nodejs 2>&1` - ret=$? -fi -if [ $ret -eq 0 ] && [ -x "$node" ]; then - if [ $debug -eq 1 ]; then - echo "found 'node' at: $node" - echo -n "version: " - $node --version - echo "" - fi - (exit 0) -else - echo "npm cannot be installed without node.js." >&2 - echo "install node first, and then try again." >&2 - echo "" >&2 - exit $ret -fi - -ret=0 -tar="${TAR}" -if [ -z "$tar" ]; then - tar="${npm_config_tar}" -fi -if [ -z "$tar" ]; then - tar=`which tar 2>&1` - ret=$? -fi - -if [ $ret -eq 0 ] && [ -x "$tar" ]; then - if [ $debug -eq 1 ]; then - echo "found 'tar' at: $tar" - echo -n "version: " - $tar --version - echo "" - fi - ret=$? -fi - -if [ $ret -eq 0 ]; then - (exit 0) -else - echo "this script requires 'tar', please install it and try again." - exit 1 -fi - -curl=`which curl 2>&1` -ret=$? -if [ $ret -eq 0 ]; then - if [ $debug -eq 1 ]; then - echo "found 'curl' at: $curl" - echo -n "version: " - $curl --version | head -n 1 - echo "" - fi - (exit 0) -else - echo "this script requires 'curl', please install it and try again." - exit 1 -fi - -# set the temp dir -TMP="${TMPDIR}" -if [ "x$TMP" = "x" ]; then - TMP="/tmp" -fi -TMP="${TMP}/npm.$$" -rm -rf "$TMP" || true -mkdir "$TMP" -if [ $? -ne 0 ]; then - echo "failed to mkdir $TMP" >&2 - exit 1 -fi - -BACK="$PWD" - -t="${npm_install}" -if [ -z "$t" ]; then - t="latest" -fi - -# need to echo "" after, because Posix sed doesn't treat EOF -# as an implied end of line. -url=`(curl -qSsL https://registry.npmjs.org/npm/$t; echo "") \ - | sed -e 's/^.*tarball":"//' \ - | sed -e 's/".*$//'` - -ret=$? -if [ "x$url" = "x" ]; then - ret=125 - # try without the -e arg to sed. - url=`(curl -qSsL https://registry.npmjs.org/npm/$t; echo "") \ - | sed 's/^.*tarball":"//' \ - | sed 's/".*$//'` - ret=$? - if [ "x$url" = "x" ]; then - ret=125 - fi -fi -if [ $ret -ne 0 ]; then - echo "failed to get tarball url for npm/$t" >&2 - exit $ret -fi - - -echo "fetching: $url" >&2 - -cd "$TMP" \ - && curl -qSsL -o npm.tgz "$url" \ - && $tar -xzf npm.tgz \ - && cd "$TMP"/package \ - && echo "installing npm@$t" \ - && "$node" bin/npm-cli.js install -gf ../npm.tgz \ - && cd "$BACK" \ - && rm -rf "$TMP" \ - && echo "successfully installed npm@$t" - -ret=$? -if [ $ret -ne 0 ]; then - echo "failed!" >&2 -fi -exit $ret diff --git a/scripts/maketest b/scripts/maketest deleted file mode 100755 index 4ef1e92..0000000 --- a/scripts/maketest +++ /dev/null @@ -1,85 +0,0 @@ -#!/usr/bin/env node -'use strict' -const loadFromDir = require('tacks/load-from-dir.js') - -process.exit(main(process.argv.slice(2))) - -function main (argv) { - if (argv.length !== 1) { - console.error('Usage: maketest <fixturedir>') - return 1 - } - const fixturedir = process.argv[2] - - console.log(generateFromDir(fixturedir)) - return 0 -} - -function indent (ind, str) { - return str.replace(/\n/g, '\n' + ind) -} - -function generateFromDir (dir) { - const tacks = loadFromDir(dir) - return `'use strict' -const path = require('path') -const test = require('tap').test -const Tacks = require('tacks') -const File = Tacks.File -const Symlink = Tacks.Symlink -const Dir = Tacks.Dir -const common = require('../common-tap.js') - -const basedir = path.join(__dirname, path.basename(__filename, '.js')) -const testdir = path.join(basedir, 'testdir') -const cachedir = path.join(basedir, 'cache') -const globaldir = path.join(basedir, 'global') -const tmpdir = path.join(basedir, 'tmp') - -const conf = { - cwd: testdir, - env: common.newEnv().extend({ - npm_config_cache: cachedir, - npm_config_tmp: tmpdir, - npm_config_prefix: globaldir, - npm_config_registry: common.registry, - npm_config_loglevel: 'warn' - }) -} - -const fixture = new Tacks(Dir({ - cache: Dir(), - global: Dir(), - tmp: Dir(), - testdir: ${indent(' ', tacks.fixture.toSource())} -})) - -function setup () { - cleanup() - fixture.create(basedir) -} - -function cleanup () { - fixture.remove(basedir) -} - -test('setup', t => { - setup() - return common.fakeRegistry.listen() -}) - -test('example', t => { - return common.npm(['install'], conf).then(([code, stdout, stderr]) => { - t.is(code, 0, 'command ran ok') - t.comment(stdout.trim()) - t.comment(stderr.trim()) - // your assertions here - }) -}) - -test('cleanup', t => { - common.fakeRegistry.close() - cleanup() - t.done() -})\n` -} diff --git a/scripts/npm-cli-repos.txt b/scripts/npm-cli-repos.txt new file mode 100644 index 0000000..3f16b74 --- /dev/null +++ b/scripts/npm-cli-repos.txt @@ -0,0 +1,84 @@ +abbrev-js +agent +are-we-there-yet +benchmarks +bin-links +cacache +cli +cmd-shim +config +create-oss +dezalgo +disparity-colors +doctornpm +documentation +eslint-config +exec +fs +fs-minipass +gauge +git +graphec +hosted-git-info +ignore-walk +infer-owner +inflight +ini +init-package-json +installed-package-contents +json-parse-even-better-errors +make-fetch-happen +map-workspaces +metavuln-calculator +minify-registry-metadata +minipass-fetch +move-file +mute-stream +name-from-folder +nock-registry +node-gyp +node-semver +node-tar +node-which +nopt +normalize-package-data +npm-audit-report +npm-bundled +npm-cli-release-please +npm-install-checks +npm-install-script +npm-normalize-package-bin +npm-package-arg +npm-packlist +npm-pick-manifest +npm-profile +npm-registry-fetch +npm-registry-mock +npm-user-validate +npmlog +package-json +pacote +parse-conflict-json +proc-log +proggy +promise-spawn +promzard +query +read +read-cmd-shim +read-package-json +read-package-json-fast +readdir-scoped-modules +rfcs +run-script +ssri +stafftools +statusboard +tap-nock +template-oss +treeverse +unique-filename +unique-slug +validate-npm-package-name +wrappy +write-file-atomic diff --git a/scripts/pr b/scripts/pr deleted file mode 100755 index 30a3b05..0000000 --- a/scripts/pr +++ /dev/null @@ -1,167 +0,0 @@ -#!/usr/bin/env bash - -# Land a pull request -# Creates a PR-### branch, pulls the commits, opens up an interactive rebase to -# squash, and then annotates the commit with the changelog goobers -# -# Usage: -# pr <url|number> [<upstream remote>=origin] - -main () { - if [ "$1" = "finish" ]; then - shift - finish "$@" - return $? - fi - - local url="$(prurl "$@")" - local num=$(basename $url) - local prpath="${url#git@github.com:}" - local repo=${prpath%/pull/$num} - local prweb="https://github.com/$prpath" - local root="$(prroot "$url")" - local api="https://api.github.com/repos/${repo}/pulls/${num}" - local user=$(curl -s $api | json user.login) - local ref="$(prref "$url" "$root")" - local curhead="$(git show --no-patch --pretty=%H HEAD)" - local curbranch="$(git rev-parse --abbrev-ref HEAD)" - local cleanlines - IFS=$'\n' cleanlines=($(git status -s -uno)) - if [ ${#cleanlines[@]} -ne 0 ]; then - echo "working dir not clean" >&2 - IFS=$'\n' echo "${cleanlines[@]}" >&2 - echo "aborting PR merge" >&2 - fi - - # ok, ready to rock - branch=PR-$num - if [ "$curbranch" == "$branch" ]; then - echo "already on $branch, you're on your own" >&2 - return 1 - fi - - me=$(git config github.user || git config user.name) - if [ "$me" == "" ]; then - echo "run 'git config --add github.user <username>'" >&2 - return 1 - fi - - exists=$(git show --no-patch --pretty=%H $branch 2>/dev/null) - if [ "$exists" == "" ]; then - git fetch origin pull/$num/head:$branch - git checkout $branch - else - git checkout $branch - git pull --rebase origin pull/$num/head - fi - - git rebase -i $curbranch # squash and test - - if [ $? -eq 0 ]; then - finish "${curbranch}" - else - echo "resolve conflicts and run: $0 finish "'"'${curbranch}'"' - fi -} - -# add the PR-URL to the last commit, after squashing -finish () { - if [ $# -eq 0 ]; then - echo "Usage: $0 finish <branch> (while on a PR-### branch)" >&2 - return 1 - fi - - local curbranch="$1" - local ref=$(cat .git/HEAD) - local prnum - case $ref in - "ref: refs/heads/PR-"*) - prnum=${ref#ref: refs/heads/PR-} - ;; - *) - echo "not on the PR-## branch any more!" >&2 - return 1 - ;; - esac - - local me=$(git config github.user || git config user.name) - if [ "$me" == "" ]; then - echo "run 'git config --add github.user <username>'" >&2 - return 1 - fi - - set -x - - local url="$(prurl "$prnum")" - local num=$prnum - local prpath="${url#git@github.com:}" - local repo=${prpath%/pull/$num} - local prweb="https://github.com/$prpath" - local root="$(prroot "$url")" - - local api="https://api.github.com/repos/${repo}/pulls/${num}" - local user=$(curl -s $api | json user.login) - - local lastmsg="$(git log -1 --pretty=%B)" - local newmsg="${lastmsg} - -PR-URL: ${prweb} -Credit: @${user} -Close: #${num} -Reviewed-by: @${me} -" - git commit --amend -m "$newmsg" - git checkout $curbranch - git merge PR-${prnum} --ff-only - set +x -} - - -prurl () { - local url="$1" - if [ "$url" == "" ] && type pbpaste &>/dev/null; then - url="$(pbpaste)" - fi - if [[ "$url" =~ ^[0-9]+$ ]]; then - local us="$2" - if [ "$us" == "" ]; then - us="origin" - fi - local num="$url" - local o="$(git config --get remote.${us}.url)" - url="${o}" - url="${url#(git:\/\/|https:\/\/)}" - url="${url#git@}" - url="${url#github.com[:\/]}" - url="${url%.git}" - url="https://github.com/${url}/pull/$num" - fi - url=${url%/commits} - url=${url%/files} - url="$(echo $url | perl -p -e 's/#issuecomment-[0-9]+$//g')" - - local p='^https:\/\/github.com\/[^\/]+\/[^\/]+\/pull\/[0-9]+$' - if ! [[ "$url" =~ $p ]]; then - echo "Usage:" - echo " $0 <pull req url>" - echo " $0 <pull req number> [<remote name>=origin]" - type pbpaste &>/dev/null && - echo "(will read url/id from clipboard if not specified)" - exit 1 - fi - url="${url/https:\/\/github\.com\//git@github.com:}" - echo "$url" -} - -prroot () { - local url="$1" - echo "${url/\/pull\/+([0-9])/}" -} - -prref () { - local url="$1" - local root="$2" - echo "refs${url:${#root}}/head" -} - -main "$@" diff --git a/scripts/publish-tag.js b/scripts/publish-tag.js deleted file mode 100644 index fb8a482..0000000 --- a/scripts/publish-tag.js +++ /dev/null @@ -1,3 +0,0 @@ -var semver = require('semver') -var version = semver.parse(require('../package.json').version) -console.log('next-%s', version.major) diff --git a/scripts/publish.js b/scripts/publish.js new file mode 100644 index 0000000..62f2217 --- /dev/null +++ b/scripts/publish.js @@ -0,0 +1,110 @@ +const semver = require('semver') +const log = require('proc-log') +const pacote = require('pacote') +const { run, git, npm, pkg: cli, spawn } = require('./util.js') + +const resetdeps = () => npm('run', 'resetdeps') + +const op = () => spawn('op', 'item', 'get', 'npm', '--otp', { out: true, ok: true }) + +const getVersion = async (s) => { + const mani = await pacote.manifest(s, { preferOnline: true }) + return mani.version +} +const getLatest = async (s) => { + const pack = await pacote.packument(s, { preferOnline: true }) + return pack['dist-tags'].latest +} + +const TAG = { + cli: ({ version }) => `next-${semver.major(version)}`, + workspace: async ({ name, version }) => { + const { prerelease, major } = semver.parse(version) + if (prerelease.length) { + return 'prerelease' + } + if (major === await getLatest(name).then(v => semver.major(v))) { + return 'latest' + } + return 'backport' + }, +} + +const needsPublish = async ({ private, name, version }, { force, getTag }) => { + if (private) { + return + } + + const tag = await getTag({ name, version }) + if (force || version !== await getVersion(`${name}@${tag}`)) { + return tag + } +} + +const getPublishes = async (opts) => { + const publish = [] + + for (const { name, pkg } of await cli.mapWorkspaces()) { + publish.push({ + workspace: name, + tag: await needsPublish(pkg, { ...opts, getTag: TAG.workspace }), + }) + } + + publish.push({ + tag: await needsPublish(cli, { ...opts, getTag: TAG.cli }), + }) + + return publish.filter(p => p.tag) +} + +const main = async (opts) => { + const packOnly = opts.pack || opts.packDestination + const publishes = await getPublishes({ force: packOnly }) + + if (!publishes.length) { + throw new Error( + 'Nothing to publish, exiting. ' + + 'All packages to publish should have their version bumped before running this script.' + ) + } + + log.info('publish', '\n' + publishes.map(JSON.stringify).join('\n')) + + await git('clean', '-fd') + await resetdeps() + await npm('ls', '--omit=dev', { quiet: true }) + await npm('rm', '--global', '--force', 'npm') + await npm('link', '--force', '--ignore-scripts') + + if (opts.test) { + await npm('run', 'lint-all', '--ignore-scripts') + await npm('run', 'postlint', '--ignore-scripts') + await npm('run', 'test-all', '--ignore-scripts') + } + + await npm('prune', '--omit=dev', '--no-save', '--no-audit', '--no-fund') + await npm('install', '-w', 'docs', '--ignore-scripts', '--no-audit', '--no-fund') + await git.dirty() + + for (const p of publishes) { + const workspace = p.workspace && `--workspace=${p.workspace}` + if (packOnly) { + await npm( + 'pack', + workspace, + opts.packDestination && `--pack-destination=${opts.packDestination}` + ) + } else { + await npm( + 'publish', + workspace, + `--tag=${p.tag}`, + opts.dryRun && '--dry-run', + opts.otp && `--otp=${opts.otp === 'op' ? await op() : opts.otp}` + ) + } + } +} + +run(main).catch(resetdeps) diff --git a/scripts/release.sh b/scripts/release.sh deleted file mode 100644 index a3c1356..0000000 --- a/scripts/release.sh +++ /dev/null @@ -1,43 +0,0 @@ -#!/usr/bin/env bash - -# script for creating a zip and tarball for inclusion in node - -unset CDPATH - -set -e - -rm -rf release *.tgz || true -rm node_modules/node-gyp/gyp/pylib/gyp/__pycache__/*.pyc || true -rm node_modules/node-gyp/gyp/pylib/gyp/generator/__pycache__/*.pyc || true -mkdir release -node ./bin/npm-cli.js pack --loglevel error >/dev/null -mv *.tgz release -cd release -tar xzf *.tgz -cp ../.npmrc package/ -cp -r ../tap-snapshots package/ -cp -r ../test package/ - -mkdir node_modules -mv package node_modules/npm - -# make the zip for windows users -cp node_modules/npm/bin/*.cmd . -zipname=npm-$(node ../bin/npm-cli.js -v).zip -zip -q -9 -r -X "$zipname" *.cmd node_modules - -# make the tar for node's deps -cd node_modules -tarname=npm-$(node ../../bin/npm-cli.js -v).tgz -tar czf "$tarname" npm - -cd .. -mv "node_modules/$tarname" . - -rm -rf *.cmd -rm -rf node_modules - -cd .. - -echo "release/$tarname" -echo "release/$zipname" diff --git a/scripts/relocate.sh b/scripts/relocate.sh deleted file mode 100755 index ff40f85..0000000 --- a/scripts/relocate.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/usr/bin/env bash - -# Change the cli shebang to point at the specified node -# Useful for when the program is moved around after install. -# Also used by the default 'make install' in node to point -# npm at the newly installed node, rather than the first one -# in the PATH, which would be the default otherwise. - -# bash /path/to/npm/scripts/relocate.sh $nodepath -# If $nodepath is blank, then it'll use /usr/bin/env - -dir="$(dirname "$(dirname "$0")")" -cli="$dir"/bin/npm-cli.js -tmp="$cli".tmp - -node="$1" -if [ "x$node" = "x" ]; then - node="/usr/bin/env node" -fi -node="#!$node" - -sed -e 1d "$cli" > "$tmp" -echo "$node" > "$cli" -cat "$tmp" >> "$cli" -rm "$tmp" -chmod ogu+x $cli diff --git a/scripts/remove-files.js b/scripts/remove-files.js new file mode 100644 index 0000000..75b4385 --- /dev/null +++ b/scripts/remove-files.js @@ -0,0 +1,11 @@ +const { join } = require('path') +const { CWD, run, pkg, fs, git } = require('./util.js') + +const main = async () => { + await git.dirty() + for (const p of pkg.files) { + await fs.rimraf(join(CWD, p)) + } +} + +run(main) diff --git a/scripts/resetdeps.js b/scripts/resetdeps.js new file mode 100644 index 0000000..95899ff --- /dev/null +++ b/scripts/resetdeps.js @@ -0,0 +1,19 @@ + +const { join } = require('path') +const { CWD, run, pkg, fs, git, npm } = require('./util.js') + +const checkout = () => git('checkout', 'node_modules/') + +const main = async ({ packageLock }) => { + await fs.rimraf(join(CWD, 'node_modules')) + for (const { path } of await pkg.mapWorkspaces()) { + await fs.rimraf(join(path, 'node_modules')) + } + + await checkout() + await npm('i', '--ignore-scripts', '--no-audit', '--no-fund', packageLock && '--package-lock') + await npm('rebuild', '--ignore-scripts') + await npm('run', 'dependencies', '--ignore-scripts') +} + +run(main).catch(checkout) diff --git a/scripts/resetdeps.sh b/scripts/resetdeps.sh deleted file mode 100755 index 9579877..0000000 --- a/scripts/resetdeps.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash -set -e -set -x -rm -rf node_modules -git checkout node_modules -node . i --ignore-scripts --no-audit -node . rebuild --ignore-scripts --no-audit -node scripts/bundle-and-gitignore-deps.js diff --git a/scripts/template-oss/_step-deps.yml b/scripts/template-oss/_step-deps.yml new file mode 100644 index 0000000..22f8d00 --- /dev/null +++ b/scripts/template-oss/_step-deps.yml @@ -0,0 +1,2 @@ +- name: Reset Deps + run: {{rootNpmPath}} run resetdeps {{~#if jobDepFlags}} -- {{ jobDepFlags }}{{/if}} diff --git a/scripts/template-oss/_step-test.yml b/scripts/template-oss/_step-test.yml new file mode 100644 index 0000000..9471e6a --- /dev/null +++ b/scripts/template-oss/_step-test.yml @@ -0,0 +1,4 @@ +{{> defaultStepTest }} +- name: Check Git Status + if: matrix && matrix.platform.os != 'windows-latest' + run: node scripts/git-dirty.js diff --git a/scripts/template-oss/branch-specific-config.js b/scripts/template-oss/branch-specific-config.js new file mode 100644 index 0000000..9dfbedd --- /dev/null +++ b/scripts/template-oss/branch-specific-config.js @@ -0,0 +1,5 @@ +// Leave this empty to use the default ciVersions from template-oss +// This file is kept here to make it easier to apply template-oss +// changes to other branches which might have different ciVersions +// or other conifg options +module.exports = {} diff --git a/scripts/template-oss/ci-npmcli-docs.yml b/scripts/template-oss/ci-npmcli-docs.yml new file mode 100644 index 0000000..1e3cd05 --- /dev/null +++ b/scripts/template-oss/ci-npmcli-docs.yml @@ -0,0 +1,22 @@ +{{> ci }} + + compare-docs: + {{> job jobName="Compare Docs" jobCheckout=(obj fetch-depth=0) jobIf="github.event_name == 'pull_request'" }} + - name: Build Docs + run: | + node . run build -w docs + mv man/ man-update/ + mv docs/output/ docs/output-update/ + mv docs/content/ docs/content-update/ + - name: Get Current Docs + run: | + git clean -fd + git checkout $\{{ github.event.pull_request.base.ref }} + node . run resetdeps + node . run build -w docs + - name: Diff Man + run: diff -r --color=always man/ man-update/ || true + - name: Diff HTML + run: diff -r --color=always docs/output/ docs/output-update/ || true + - name: Diff Markdown + run: diff -r --color=always docs/content/ docs/content-update/ || true diff --git a/scripts/template-oss/ci-release.yml b/scripts/template-oss/ci-release.yml new file mode 100644 index 0000000..9482c31 --- /dev/null +++ b/scripts/template-oss/ci-release.yml @@ -0,0 +1,21 @@ +{{> ciRelease}} + + smoke-publish: + {{> jobMatrix + jobName="Smoke Publish" + jobCheck=(obj sha="inputs.check-sha") + jobCheckout=(obj ref="${{ inputs.ref }}") + windowsCI=false + }} + - name: Pack + run: | + NPM_VERSION="$({{ rootNpmPath }} --version)-$GITHUB_SHA.0" + {{ rootNpmPath }} version $NPM_VERSION --ignore-scripts + node scripts/publish.js --pack-destination=$RUNNER_TEMP + {{ rootNpmPath }} install --global $RUNNER_TEMP/npm-$NPM_VERSION.tgz + {{ rootNpmPath }} install -w smoke-tests --ignore-scripts --no-audit --no-fund + node scripts/remove-files.js + # call installed npm instead of local source since we are testing + # the packed tarball that we just installed globally + SMOKE_PUBLISH_NPM=1 npm test -w smoke-tests --ignore-scripts + {{> stepChecks jobCheck=true }} diff --git a/scripts/template-oss/ci.yml b/scripts/template-oss/ci.yml new file mode 100644 index 0000000..ec8e954 --- /dev/null +++ b/scripts/template-oss/ci.yml @@ -0,0 +1,13 @@ +{{> ci }} + + licenses: + {{> job jobName="Check Licenses" }} + - name: Check Licenses + run: {{rootNpmPath}} run licenses + + smoke-tests: + {{> job jobName="Smoke Tests" }} + - name: Run Smoke Tests + run: {{rootNpmPath}} test -w smoke-tests --ignore-scripts + - name: Check Git Status + run: node scripts/git-dirty.js diff --git a/scripts/template-oss/create-node-pr.yml b/scripts/template-oss/create-node-pr.yml new file mode 100644 index 0000000..3946ba7 --- /dev/null +++ b/scripts/template-oss/create-node-pr.yml @@ -0,0 +1,32 @@ +name: "Create Node PR" + +on: + workflow_dispatch: + inputs: + spec: + description: "The npm spec to create the PR from" + required: true + default: 'latest' + branch: + description: "The major node version to serve as the base of the PR. Should be `main` or a number like `18`, `19`, etc." + required: true + default: 'main' + dryRun: + description: "Setting this to anything will run all the steps except opening the PR" + +jobs: + create-pull-request: + {{> job jobName="Create Node PR" jobCheckout=(obj fetch-depth=0) }} + - name: Checkout Node + uses: actions/checkout@v3 + with: + token: $\{{ secrets.NODE_PULL_REQUEST_TOKEN }} + repository: nodejs/node + fetch-depth: 0 + path: node + - name: Create Node Pull Request + env: + GITHUB_TOKEN: $\{{ secrets.NODE_PULL_REQUEST_TOKEN }} + run: | + DRY_RUN=$([ -z "$\{{ inputs.dryRun }}" ] && echo "" || echo "--dry-run") + node scripts/create-node-pr.js $\{{ inputs.spec }} $\{{ inputs.branch }} "$DRY_RUN" diff --git a/scripts/template-oss/index.js b/scripts/template-oss/index.js new file mode 100644 index 0000000..f18acc2 --- /dev/null +++ b/scripts/template-oss/index.js @@ -0,0 +1,3 @@ +module.exports = { + ...require('./branch-specific-config.js'), +} diff --git a/scripts/template-oss/root.js b/scripts/template-oss/root.js new file mode 100644 index 0000000..cb59c47 --- /dev/null +++ b/scripts/template-oss/root.js @@ -0,0 +1,46 @@ +module.exports = { + rootRepo: { + add: { + '.github/workflows/ci.yml': 'ci.yml', + '.github/workflows/ci-release.yml': 'ci-release.yml', + '.github/workflows/create-node-pr.yml': 'create-node-pr.yml', + '.github/ISSUE_TEMPLATE/bug.yml': false, + '.github/ISSUE_TEMPLATE/config.yml': false, + '.github/dependabot.yml': false, + '.github/workflows/post-dependabot.yml': false, + }, + }, + workspaceRepo: { + add: { + '.github/workflows/release.yml': false, + '.github/workflows/ci-release.yml': false, + '.github/dependabot.yml': false, + '.github/workflows/post-dependabot.yml': false, + }, + }, + lockfile: true, + npm: '.', + defaultBranch: 'latest', + distPaths: [ + 'index.js', + 'docs/content/', + 'docs/output/', + 'man/', + ], + allowPaths: [ + '/node_modules/', + '/index.js', + '/DEPENDENCIES.md', + '/CONTRIBUTING.md', + '/configure', + '/AUTHORS', + '/.mailmap', + '/.licensee.json', + '/.gitattributes', + ], + ignorePaths: [ + '/node_modules/.bin/', + '/node_modules/.cache/', + ], + ...require('./branch-specific-config.js'), +} diff --git a/scripts/update-authors.js b/scripts/update-authors.js new file mode 100755 index 0000000..fc567b6 --- /dev/null +++ b/scripts/update-authors.js @@ -0,0 +1,27 @@ +const { join } = require('path') +const { CWD, run, git, fs } = require('./util.js') + +const main = async () => { + const allAuthors = await git('log', '--use-mailmap', '--reverse', '--format=%aN <%aE>', { + lines: true, + quiet: true, + }) + + const authors = new Set() + for (const author of allAuthors) { + if ( + !author.includes('[bot]') && + !author.startsWith('npm team') && + !author.startsWith('npm CLI robot') + ) { + authors.add(author) + } + } + + return fs.writeFile(join(CWD, 'AUTHORS'), [ + `# Authors sorted by whether or not they're me`, + ...authors, + ].join('\n')) +} + +run(main) diff --git a/scripts/update-authors.sh b/scripts/update-authors.sh deleted file mode 100755 index ac7b991..0000000 --- a/scripts/update-authors.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/sh - -git log --use-mailmap --reverse --format='%aN <%aE>' | perl -wnE ' -BEGIN { - say "# Authors sorted by whether or not they\x27re me"; -} - -print $seen{$_} = $_ unless $seen{$_} -' > AUTHORS diff --git a/scripts/util.js b/scripts/util.js new file mode 100644 index 0000000..bb8dd48 --- /dev/null +++ b/scripts/util.js @@ -0,0 +1,204 @@ +const fsp = require('fs/promises') +const { resolve, join, relative } = require('path') +const { formatWithOptions } = require('util') +const log = require('proc-log') +const nopt = require('nopt') +const npmGit = require('@npmcli/git') +const promiseSpawn = require('@npmcli/promise-spawn') +const mapWorkspaces = require('@npmcli/map-workspaces') + +const CWD = resolve(__dirname, '..') + +const pkg = require(join(CWD, 'package.json')) +pkg.mapWorkspaces = async () => { + const ws = [] + for (const [name, path] of await mapWorkspaces({ pkg })) { + ws.push({ name, path, pkg: require(join(path, 'package.json')) }) + } + return ws +} + +const fs = { + rimraf: (p) => fsp.rm(p, { recursive: true, force: true }), + mkdirp: (p) => fsp.mkdir(p, { recursive: true }), + clean: (p) => fs.rimraf(p).then(() => fs.mkdirp(p)), + rmAll: (p) => Promise.all(p.map(fs.rimraf)), + writeFile: async (p, d) => { + await fsp.writeFile(p, d.trim() + '\n', 'utf-8') + return `Wrote to ${relative(CWD, p)}` + }, +} + +// for spawn, allow a flat array of arguments where the +// the last arg can optionall be an options object +const getArgs = (allArgs) => { + let args = allArgs.flat().filter(Boolean) + let opts = {} + + const last = args[args.length - 1] + if (typeof last === 'object') { + args = args.slice(0, -1) + opts = last + } + + return { args, opts } +} + +const spawn = async (cmd, ...allArgs) => { + const { + args, + opts: { ok, input, out, lines, quiet, env, ...opts }, + } = getArgs(allArgs) + + log.info('spawn', `${cmd} ${args.join(' ')}`) + + let res = null + try { + const spawnOpts = { + stdio: quiet || out || lines ? 'pipe' : 'inherit', + cwd: CWD, + env: { ...process.env, ...env }, + ...opts, + } + const proc = cmd === 'git' ? npmGit.spawn(args, spawnOpts) : promiseSpawn(cmd, args, spawnOpts) + if (input && proc.stdin) { + log.silly('input', input) + proc.stdin.write(input) + proc.stdin.end() + } + res = await proc + } catch (err) { + if (!ok) { + throw err + } + log.silly('suppressed error', err) + } + + if (res?.stdout) { + res.stdout = res.stdout.toString().trim() + if (res.stdout && !quiet) { + log.silly('stdout', res.stdout) + } + } + + if (res?.stderr) { + res.stderr = res.stderr.toString().trim() + if (res.stderr) { + log.silly('stderr', res.stderr) + } + } + + if (lines) { + return (res?.stdout || '') + .split('\n') + .map(l => l.trim()) + .filter(Boolean) + } + + if (out) { + return res?.stdout || '' + } + + return res +} + +// allows for creating spawn functions with a prefilled +// command and checking if the last arg is an options obj +spawn.create = (cmd, ...prefillArgs) => (...cmdArgs) => { + const prefill = getArgs(prefillArgs) + const command = getArgs(cmdArgs) + return spawn( + cmd, + [...prefill.args, ...command.args], + { ...prefill.opts, ...command.opts } + ) +} + +const npm = spawn.create('node', '.') +npm.query = (...args) => npm('query', ...args, { out: true }).then(JSON.parse) + +const git = spawn.create('git') +git.dirty = () => npmGit.isClean({ cwd: CWD }).then(async r => { + if (r) { + return 'git clean' + } + await git('status', '--porcelain=v1', '-uno') + throw new Error('git dirty') +}) + +const gh = spawn.create('gh') +gh.json = async (..._args) => { + const { args, opts } = getArgs(_args) + const keys = args.pop() + let data = await gh(...args, '--json', keys, { ...opts, out: true }).then(JSON.parse) + if (keys.split(',').length === 1) { + data = data[keys] + } + return data +} + +const run = async (main, { redact } = {}) => { + const argv = {} + for (const [k, v] of Object.entries(nopt({}, {}, process.argv))) { + argv[k] = v + // create camelcase key too + argv[k.replace(/-([a-z])/g, (_, c) => c.toUpperCase())] = v + } + + const defaultLevels = ['error', 'warn', 'info'] + process.on('log', (l, ...args) => { + if (argv.debug || process.env.CI || defaultLevels.includes(l)) { + for (const line of formatWithOptions({ colors: true }, ...args).split('\n')) { + const redacted = redact ? line.replace(redact, '***') : line + // eslint-disable-next-line no-console + console.error(l.slice(0, 4).toUpperCase(), redacted) + } + } + }) + + log.silly('argv', argv) + + try { + const res = await main(argv) + if (res) { + // eslint-disable-next-line no-console + console.log(res) + } + } catch (err) { + process.exitCode = err.status || 1 + + const messages = [] + if (err.args) { + // its an error from promise-spawn + for (const [name, value] of Object.entries(err)) { + if (value) { + let msg = Array.isArray(value) ? value.join(' ') : value.toString() + let sep = ' ' + if (msg.includes('\n')) { + msg = ' ' + msg.split('\n').map(l => l.trim()).join('\n ').trim() + sep = '\n' + } + messages.push(`${name}:${sep}${msg}`) + } + // delete from error object so we can log them separately + delete err[name] + } + } + + log.error(err) + if (messages.length) { + log.error(messages.join('\n')) + } + } +} + +module.exports = { + CWD, + pkg, + run, + fs, + spawn, + gh, + npm, + git, +} diff --git a/smoke-tests/.eslintrc.js b/smoke-tests/.eslintrc.js new file mode 100644 index 0000000..5db9f81 --- /dev/null +++ b/smoke-tests/.eslintrc.js @@ -0,0 +1,17 @@ +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' + +const { readdirSync: readdir } = require('fs') + +const localConfigs = readdir(__dirname) + .filter((file) => file.startsWith('.eslintrc.local.')) + .map((file) => `./${file}`) + +module.exports = { + root: true, + extends: [ + '@npmcli', + ...localConfigs, + ], +} diff --git a/smoke-tests/.gitignore b/smoke-tests/.gitignore new file mode 100644 index 0000000..79af2bf --- /dev/null +++ b/smoke-tests/.gitignore @@ -0,0 +1,21 @@ +# This file is automatically added by @npmcli/template-oss. Do not edit. + +# ignore everything in the root +/* + +# keep these +!**/.gitignore +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ +!/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/smoke-tests/content/abbrev.json b/smoke-tests/content/abbrev.json deleted file mode 100644 index ffcf547..0000000 --- a/smoke-tests/content/abbrev.json +++ /dev/null @@ -1,449 +0,0 @@ -{ - "_id": "abbrev", - "_rev": "72-d1d46bef3d311d6da6737e109e771869", - "name": "abbrev", - "dist-tags": { - "latest": "1.1.1" - }, - "versions": { - "1.0.3": { - "name": "abbrev", - "version": "1.0.3", - "description": "Like ruby's abbrev module, but in js", - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me" - }, - "main": "./lib/abbrev.js", - "scripts": { - "test": "node lib/abbrev.js" - }, - "repository": { - "type": "git", - "url": "git://github.com/isaacs/abbrev-js.git" - }, - "_id": "abbrev@1.0.3", - "engines": { - "node": "*" - }, - "_engineSupported": true, - "_npmVersion": "1.0.0rc7", - "_nodeVersion": "v0.5.0-pre", - "_defaultsLoaded": true, - "dist": { - "shasum": "aa049c967f999222aa42e14434f0c562ef468241", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.3.tgz" - }, - "directories": {} - }, - "1.0.4": { - "name": "abbrev", - "version": "1.0.4", - "description": "Like ruby's abbrev module, but in js", - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me" - }, - "main": "./lib/abbrev.js", - "scripts": { - "test": "node lib/abbrev.js" - }, - "repository": { - "type": "git", - "url": "http://github.com/isaacs/abbrev-js" - }, - "license": { - "type": "MIT", - "url": "https://github.com/isaacs/abbrev-js/raw/master/LICENSE" - }, - "_id": "abbrev@1.0.4", - "dist": { - "shasum": "bd55ae5e413ba1722ee4caba1f6ea10414a59ecd", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.4.tgz" - }, - "_npmVersion": "1.1.70", - "_npmUser": { - "name": "isaacs", - "email": "i@izs.me" - }, - "maintainers": [ - { - "name": "isaacs", - "email": "i@izs.me" - } - ], - "directories": {} - }, - "1.0.5": { - "name": "abbrev", - "version": "1.0.5", - "description": "Like ruby's abbrev module, but in js", - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me" - }, - "main": "abbrev.js", - "scripts": { - "test": "node test.js" - }, - "repository": { - "type": "git", - "url": "http://github.com/isaacs/abbrev-js" - }, - "license": { - "type": "MIT", - "url": "https://github.com/isaacs/abbrev-js/raw/master/LICENSE" - }, - "bugs": { - "url": "https://github.com/isaacs/abbrev-js/issues" - }, - "homepage": "https://github.com/isaacs/abbrev-js", - "_id": "abbrev@1.0.5", - "_shasum": "5d8257bd9ebe435e698b2fa431afde4fe7b10b03", - "_from": ".", - "_npmVersion": "1.4.7", - "_npmUser": { - "name": "isaacs", - "email": "i@izs.me" - }, - "maintainers": [ - { - "name": "isaacs", - "email": "i@izs.me" - } - ], - "dist": { - "shasum": "5d8257bd9ebe435e698b2fa431afde4fe7b10b03", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.5.tgz" - }, - "directories": {} - }, - "1.0.6": { - "name": "abbrev", - "version": "1.0.6", - "description": "Like ruby's abbrev module, but in js", - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me" - }, - "main": "abbrev.js", - "scripts": { - "test": "node test.js" - }, - "repository": { - "type": "git", - "url": "git+ssh://git@github.com/isaacs/abbrev-js.git" - }, - "license": "ISC", - "gitHead": "648a6735d9c5a7a04885e3ada49eed4db36181c2", - "bugs": { - "url": "https://github.com/isaacs/abbrev-js/issues" - }, - "homepage": "https://github.com/isaacs/abbrev-js#readme", - "_id": "abbrev@1.0.6", - "_shasum": "b6d632b859b3fa2d6f7e4b195472461b9e32dc30", - "_from": ".", - "_npmVersion": "2.10.0", - "_nodeVersion": "2.0.1", - "_npmUser": { - "name": "isaacs", - "email": "isaacs@npmjs.com" - }, - "dist": { - "shasum": "b6d632b859b3fa2d6f7e4b195472461b9e32dc30", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.6.tgz" - }, - "maintainers": [ - { - "name": "isaacs", - "email": "i@izs.me" - } - ], - "directories": {} - }, - "1.0.7": { - "name": "abbrev", - "version": "1.0.7", - "description": "Like ruby's abbrev module, but in js", - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me" - }, - "main": "abbrev.js", - "scripts": { - "test": "tap test.js --cov" - }, - "repository": { - "type": "git", - "url": "git+ssh://git@github.com/isaacs/abbrev-js.git" - }, - "license": "ISC", - "devDependencies": { - "tap": "^1.2.0" - }, - "gitHead": "821d09ce7da33627f91bbd8ed631497ed6f760c2", - "bugs": { - "url": "https://github.com/isaacs/abbrev-js/issues" - }, - "homepage": "https://github.com/isaacs/abbrev-js#readme", - "_id": "abbrev@1.0.7", - "_shasum": "5b6035b2ee9d4fb5cf859f08a9be81b208491843", - "_from": ".", - "_npmVersion": "2.10.1", - "_nodeVersion": "2.0.1", - "_npmUser": { - "name": "isaacs", - "email": "isaacs@npmjs.com" - }, - "dist": { - "shasum": "5b6035b2ee9d4fb5cf859f08a9be81b208491843", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.7.tgz" - }, - "maintainers": [ - { - "name": "isaacs", - "email": "i@izs.me" - } - ], - "directories": {} - }, - "1.0.9": { - "name": "abbrev", - "version": "1.0.9", - "description": "Like ruby's abbrev module, but in js", - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me" - }, - "main": "abbrev.js", - "scripts": { - "test": "tap test.js --cov" - }, - "repository": { - "type": "git", - "url": "git+ssh://git@github.com/isaacs/abbrev-js.git" - }, - "license": "ISC", - "devDependencies": { - "tap": "^5.7.2" - }, - "files": [ - "abbrev.js" - ], - "gitHead": "c386cd9dbb1d8d7581718c54d4ba944cc9298d6f", - "bugs": { - "url": "https://github.com/isaacs/abbrev-js/issues" - }, - "homepage": "https://github.com/isaacs/abbrev-js#readme", - "_id": "abbrev@1.0.9", - "_shasum": "91b4792588a7738c25f35dd6f63752a2f8776135", - "_from": ".", - "_npmVersion": "3.9.1", - "_nodeVersion": "4.4.4", - "_npmUser": { - "name": "isaacs", - "email": "i@izs.me" - }, - "dist": { - "shasum": "91b4792588a7738c25f35dd6f63752a2f8776135", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.9.tgz" - }, - "maintainers": [ - { - "name": "isaacs", - "email": "i@izs.me" - } - ], - "_npmOperationalInternal": { - "host": "packages-16-east.internal.npmjs.com", - "tmp": "tmp/abbrev-1.0.9.tgz_1466016055839_0.7825860097073019" - }, - "directories": {} - }, - "1.1.0": { - "name": "abbrev", - "version": "1.1.0", - "description": "Like ruby's abbrev module, but in js", - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me" - }, - "main": "abbrev.js", - "scripts": { - "test": "tap test.js --100", - "preversion": "npm test", - "postversion": "npm publish", - "postpublish": "git push origin --all; git push origin --tags" - }, - "repository": { - "type": "git", - "url": "git+ssh://git@github.com/isaacs/abbrev-js.git" - }, - "license": "ISC", - "devDependencies": { - "tap": "^10.1" - }, - "files": [ - "abbrev.js" - ], - "gitHead": "7136d4d95449dc44115d4f78b80ec907724f64e0", - "bugs": { - "url": "https://github.com/isaacs/abbrev-js/issues" - }, - "homepage": "https://github.com/isaacs/abbrev-js#readme", - "_id": "abbrev@1.1.0", - "_shasum": "d0554c2256636e2f56e7c2e5ad183f859428d81f", - "_from": ".", - "_npmVersion": "4.3.0", - "_nodeVersion": "8.0.0-pre", - "_npmUser": { - "name": "isaacs", - "email": "i@izs.me" - }, - "dist": { - "shasum": "d0554c2256636e2f56e7c2e5ad183f859428d81f", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.0.tgz" - }, - "maintainers": [ - { - "name": "isaacs", - "email": "i@izs.me" - } - ], - "_npmOperationalInternal": { - "host": "packages-12-west.internal.npmjs.com", - "tmp": "tmp/abbrev-1.1.0.tgz_1487054000015_0.9229173036292195" - }, - "directories": {} - }, - "1.1.1": { - "name": "abbrev", - "version": "1.1.1", - "description": "Like ruby's abbrev module, but in js", - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me" - }, - "main": "abbrev.js", - "scripts": { - "test": "tap test.js --100", - "preversion": "npm test", - "postversion": "npm publish", - "postpublish": "git push origin --all; git push origin --tags" - }, - "repository": { - "type": "git", - "url": "git+ssh://git@github.com/isaacs/abbrev-js.git" - }, - "license": "ISC", - "devDependencies": { - "tap": "^10.1" - }, - "files": [ - "abbrev.js" - ], - "gitHead": "a9ee72ebc8fe3975f1b0c7aeb3a8f2a806a432eb", - "bugs": { - "url": "https://github.com/isaacs/abbrev-js/issues" - }, - "homepage": "https://github.com/isaacs/abbrev-js#readme", - "_id": "abbrev@1.1.1", - "_npmVersion": "5.4.2", - "_nodeVersion": "8.5.0", - "_npmUser": { - "name": "isaacs", - "email": "i@izs.me" - }, - "dist": { - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", - "shasum": "f8f2c887ad10bf67f634f005b6987fed3179aac8", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" - }, - "maintainers": [ - { - "name": "gabra", - "email": "jerry+1@npmjs.com" - }, - { - "name": "isaacs", - "email": "i@izs.me" - } - ], - "_npmOperationalInternal": { - "host": "s3://npm-registry-packages", - "tmp": "tmp/abbrev-1.1.1.tgz_1506566833068_0.05750026390887797" - }, - "directories": {} - } - }, - "maintainers": [ - { - "email": "quitlahok@gmail.com", - "name": "nlf" - }, - { - "email": "ruyadorno@hotmail.com", - "name": "ruyadorno" - }, - { - "email": "darcy@darcyclarke.me", - "name": "darcyclarke" - }, - { - "email": "evilpacket@gmail.com", - "name": "adam_baldwin" - }, - { - "email": "i@izs.me", - "name": "isaacs" - } - ], - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me" - }, - "description": "Like ruby's abbrev module, but in js", - "time": { - "modified": "2020-10-13T05:04:03.636Z", - "created": "2011-03-21T22:21:11.183Z", - "1.0.1": "2011-03-21T22:21:11.183Z", - "1.0.2": "2011-03-21T22:21:11.183Z", - "1.0.3": "2011-03-21T22:21:11.183Z", - "1.0.3-1": "2011-03-24T23:01:19.581Z", - "1.0.4": "2013-01-09T00:01:24.135Z", - "1.0.5": "2014-04-17T20:09:12.523Z", - "1.0.6": "2015-05-21T00:58:16.778Z", - "1.0.7": "2015-05-30T22:57:54.685Z", - "1.0.9": "2016-06-15T18:41:01.215Z", - "1.1.0": "2017-02-14T06:33:20.235Z", - "1.1.1": "2017-09-28T02:47:13.220Z" - }, - "repository": { - "type": "git", - "url": "git+ssh://git@github.com/isaacs/abbrev-js.git" - }, - "users": { - "leesei": true, - "ceejbot": true, - "isaacs": true, - "npm-www": true, - "tunnckocore": true, - "ruanyu1": true, - "leodutra": true, - "jessaustin": true, - "jian263994241": true, - "floriannagel": true, - "tdmalone": true, - "ryanve": true, - "detj": true, - "monjer": true, - "d-band": true - }, - "readme": "# abbrev-js\n\nJust like [ruby's Abbrev](http://apidock.com/ruby/Abbrev).\n\nUsage:\n\n var abbrev = require(\"abbrev\");\n abbrev(\"foo\", \"fool\", \"folding\", \"flop\");\n \n // returns:\n { fl: 'flop'\n , flo: 'flop'\n , flop: 'flop'\n , fol: 'folding'\n , fold: 'folding'\n , foldi: 'folding'\n , foldin: 'folding'\n , folding: 'folding'\n , foo: 'foo'\n , fool: 'fool'\n }\n\nThis is handy for command-line scripts, or other cases where you want to be able to accept shorthands.\n", - "readmeFilename": "README.md", - "homepage": "https://github.com/isaacs/abbrev-js#readme", - "bugs": { - "url": "https://github.com/isaacs/abbrev-js/issues" - }, - "license": "ISC" -} diff --git a/smoke-tests/content/abbrev.min.json b/smoke-tests/content/abbrev.min.json deleted file mode 100644 index c03d91c..0000000 --- a/smoke-tests/content/abbrev.min.json +++ /dev/null @@ -1,89 +0,0 @@ -{ - "name": "abbrev", - "dist-tags": { - "latest": "1.1.1" - }, - "versions": { - "1.0.3": { - "name": "abbrev", - "version": "1.0.3", - "dist": { - "shasum": "aa049c967f999222aa42e14434f0c562ef468241", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.3.tgz" - }, - "engines": { - "node": "*" - } - }, - "1.0.4": { - "name": "abbrev", - "version": "1.0.4", - "dist": { - "shasum": "bd55ae5e413ba1722ee4caba1f6ea10414a59ecd", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.4.tgz" - } - }, - "1.0.5": { - "name": "abbrev", - "version": "1.0.5", - "dist": { - "shasum": "5d8257bd9ebe435e698b2fa431afde4fe7b10b03", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.5.tgz" - } - }, - "1.0.6": { - "name": "abbrev", - "version": "1.0.6", - "dist": { - "shasum": "b6d632b859b3fa2d6f7e4b195472461b9e32dc30", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.6.tgz" - } - }, - "1.0.7": { - "name": "abbrev", - "version": "1.0.7", - "devDependencies": { - "tap": "^1.2.0" - }, - "dist": { - "shasum": "5b6035b2ee9d4fb5cf859f08a9be81b208491843", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.7.tgz" - } - }, - "1.0.9": { - "name": "abbrev", - "version": "1.0.9", - "devDependencies": { - "tap": "^5.7.2" - }, - "dist": { - "shasum": "91b4792588a7738c25f35dd6f63752a2f8776135", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.9.tgz" - } - }, - "1.1.0": { - "name": "abbrev", - "version": "1.1.0", - "devDependencies": { - "tap": "^10.1" - }, - "dist": { - "shasum": "d0554c2256636e2f56e7c2e5ad183f859428d81f", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.0.tgz" - } - }, - "1.1.1": { - "name": "abbrev", - "version": "1.1.1", - "devDependencies": { - "tap": "^10.1" - }, - "dist": { - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", - "shasum": "f8f2c887ad10bf67f634f005b6987fed3179aac8", - "tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" - } - } - }, - "modified": "2020-10-13T05:04:03.636Z" -} diff --git a/smoke-tests/content/abbrev/-/abbrev-1.0.4.tgz b/smoke-tests/content/abbrev/-/abbrev-1.0.4.tgz deleted file mode 100644 index dfd1b55919e2f24febd758561d7640b0c1a7059a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2295 zcmV<T2nhEdiwFP!000001ML}WbK5pDpZO~`yqQ`WGt|ScIk)K@W79EvvgDEE=5jfI zfG9|UO%W_X+EG*g_uB<PJ^aXhNSaJ%%<%}=#XbS-VgY9?zGhS2$V}^BDVe_b%3rhD z+~3`W7tOtcgZ&l|+-&cfmd2X<@S@dj9_+MsTKhZuFPg2L<_^()Z9^XWN>#8NP5Dwe z#ur$&f06H#1K_4?&fP<B*=UsW8`mS;4bPR3DWO|_)894NF;{UevcisZ#5IS!94)pK z7-pEuahY%rMr8pag)3zkSy{|vPCSufEQbI1Fo<VK$qSytPvW2AcjeFd&xUx;gck2N z5;1BR!G0yl7@%;RY)3@FRYBCL9CO%YK!Q8Xl=Dm~QOJBjl(VA94jYZBC}!ozkLA1} z$S7qwUsb9S5%W~>HC2mDPt;j7)D(y+^Q01~J}<M8v)jg;DfGC}iH^eVAk+prch2`) ze;fCWei$5|h5mf}C+PS;@qe(tgYn<m-D~f*Tdln|#(%rnevbcd^8F2#`_plL!O6e~ z!kGSGgF4WImo*zPEE8iHU+e8n6b&<8_Z{a#;Wj#SbWq%|yh;bJA?Lr9BImU#yVQTw zGzO}<6DeH}s7Xwlj72)t-9%;;wf<=|P*_pssXEl~CzvFMutjuR8sQ;AKE!1AQBt!R zO>4;U<5=+oI(-U1eQZG6CFL5z7$Fmbx^tZ2Oeny=8B50tq{sp1d5*xVM5G*S;`0Cp zWHH0M88gKd++vr*LY8pL(gF$zBaYLXaO$!+=2-y>lW#$CmA{#6s`$4F=}*~XpO61` ztGP?@zqh~BKG<vS?_m75_V%9R|C@YAGF#+gIxC>vZ2sND-&Rxqw&3AG?K?q|fF@TM zii+nqe2lSw&hxoYR4(Z4i`#LufN74qk&kh!=bVF_Ks;ml6e|PTmFWU9EHGs1$Wei( zJ%$P}-0s<eC<_V%B`3u#!<~)07MM~p77XP9CZKZ8(}GbE;!H$>AyC6`0C!+H+`3jW z<}9HSgvP2NxW)5XmW6}X7rBT@hKEFPQc}29!<Yo;!f4R!)@2l0D(*RCr$?2Jm{7~L zTUj|ugqnFU79<+$A4Dob>LS7;KN=XiiYEz45NNmdb!DBVAuSnAXkn*F>%E=HIng>x zPjHGRm<v%Q*F0m1Q>Hau@mQw;5{-E%k+<j?s!Yd%Ji_dWsfJR7yy1Gz%?3zifu<T0 zXaTa-s@fqnW4Qh!?wAQfy*Ryus@%y*JqA=-2%P&2a}Mdd?<Ve;;b{ni-pTM?&<`OR zz<Iy-YjhkQgBuJG#`OO#8lLtphJY0PpgVjIy%Pw!@8Mrj_t<m7f1mfm!2o)Fh|bPC zQF!b@)II8497o-^@CNz1y&-fWEYwiwum_~jii*O4gTl_j{?RFd!JDWP4c~ik5)Hc~ z^8|$ka31uB(a}XG=)?I%|GYN{QT?&g?RBH>NguU@XJL2fqgGS};jak5;56uTw5s3& zt?z65j(X?s`_bFep>x{n9EXT}6QX6on@(s{p;JelAUgBlI5-R5hMKE~Qu><ASm(Su z4K)h&1^9O~jCx&~lcQdD*hkPqFZ;tK>$_+WdJy!Z0h;QZ^m{0trV}}OS_txWLnDQz z8a7r0NeI3eP}ecG9EU*%WetdVo!I}5)$8;3rC)XaZ`_-{vX0N6|9d-B>o4#BZL0rw zTFv(J`Ts3G$K2O_{*kh^!g_txv-@FL$(xSjSo~b3*L-o#ig<>DYmnni%2Xe%>sYAO z^)<Su&nJJ(Cs@>;=Ms;ZVo?k7oGtt;mxZKDwg+2A%a&*F-Zu<ukV9BXCTaFMP~9cy z)T)~cKLAg$O30}UMkbcf0gNZ$L`+MIEb<a@w>h5kOPH?Xb>~SVE%wW-v_f!Nl(G10 zn0&W3=XSknSdA2B%Ebg~SbOQRN%;v+r^O6jzJ3iY_~Q?FY35!i-5R#K^@jjl+<U9z zD=KRI7?1vyTo0Oc{hR^%>QbXipg>+MClhQ)l2wgmPClg#_TdtKM4F$FfZFZtN-d3l z5SK_o>actuZjC^rT`I5eiU|K$q7Px9aW#uDhB*4lsBkw^`7wute-yFAx-^>!vK?zT zMO6~h<BKgUs#5;3DxE}*5TiN~u0`rVWi&ND39X^L0k(Ck=$0kd$e7D=Is?vP^iy$8 zRpm_H!o0)~z?yEx6je=hv%|HbdQ;a%S}~Pg8Lpj>rE=D<(WLj&oxM6{CK_G$iJ8_0 z+C_eRdWj(}^BkAW(&L=z5t6S>snD<utxMV^THT7^j6#}|U3L?$Y<pygHsDerE+I*% z)8;NjYDt!!Tp3Sda>eqjytzVe;zV~=?kpWT!W+gK7hO1lqIOlcRGW6MLqGhmVz=f! z;NEm?9lFO&Ll3xV243D%`EpIj$`{bSEdgA9c5R_MXZ34$f%SDc%U9ZjI9bWFJLrR@ zyu8N*o6B&wxfpD1I(2EE*KlpF>SifkKeiT?KK4)(gYBnQ=gy{%ja;cV@|q1dOl2O7 zjJ}FmJ3YdL(8N^0;Ah=$VgFT&L^v3o^h&H8nj&-JX%_o7<<o;RNp!T&3NN<B#><t) zxOF{T79v?6Bp8S2ex)Ryq=}r?+`LTnomOkb(WMiFFsa$2lNL_`<B3)r7bQ!U2d&A( zlz6myJdAi2{)QAaLs$v057E_w+BO;Fi&W8=k+JR8P3FXC-WaVc*ar8%sk?0jY3YY> zPm)2`wLzPP`Yg+mMa>ot9z1RL)8tP%qmPX_%WA(2dR^aSe!O+p{VOTbn(Mh=**V-T zv_!QJ;L-ypy+f|rgsVq7aOpXp=)WL`u%(|(9Z&yHWCKhzgya_F_hGd{;CXIrSbG(f zb80gSXIPN9TJ6R=qJCDK8*olwrk@=%JD3^T6_{x#;}+seaAg4_b!=pQW7~|Ymg^3+ z+8Blc7ztxE7i?s@vF^tf7#nC@f!xB{2&QS5z<3klOYrV~yk)r8C<wpjzfzvR=kNJ@ R{{B+m{{XuiaUK97008;mf*Sw; diff --git a/smoke-tests/content/abbrev/-/abbrev-1.1.1.tgz b/smoke-tests/content/abbrev/-/abbrev-1.1.1.tgz deleted file mode 100644 index 4d9504504f5a3eafa0602b6f5d04ab63a62397e5..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2301 zcmV<Z2m<#XiwFP!000006YW`hbKAHP&)@tM8+GO^O=vy*oN+GKGBRzml_gh{FHJM< z3`Ic_Y>MCkq#ZTq@7`Si6eY*LOXrfzv}0r<5{rEU`vX8{QG654SSvHn=Cu;(i?7_; z?e@Xm9y~^;c6hiCFFL!OgWdK)XJ>!^MZ42EXt&`-`)fP$SSwT>Np$6p>M^mv>iIv? zJ~;rjG+MCQ5!9mbShCxiOSD@i6&ERyJ5Bs&s1v4Q$+O&!^!N<}S&Wxk3XCu;#H2`= z3*#aOp2D><f>Dvrg(R6kMNtg@Y(f~%lY-?;!jJqf{NJj%U_Tk=Ma0v}pJu7Um{vGK zULzrADkr`?%7EUH6SlWI?Y8Deh7854IMQsP*;b=M<qw9lVw`X_U*{-E$T8zNa;P~7 z$!8ec_I8vcui<lY9?et@RorX8B||+t7jj8T=6RkSwOS}NFUHMSELxm0qFN@}?K0Yg z$1GKPUV^Y&rvLVsWh|YrH0EqQ6H!Kt|LU}HrdEchJkd-a3{#a(>|Z(e4$i-=`_^jg z8?3S4uK(TLy<MvR_I`VRr*pV>NcG=o??2c7_h_bEo9tsIWUk;1RBv`k*t#zJj$`Qy zk>0T7MU=;L99-);&a_Blf{1l0)Ej!S4#w9k&YKf9<te+6B4aXN);%esWiyi^7x^+n z_}DU5wp_cyZzIHtBUouBZ6H}*$kaMk&*xk<%*qE~X|Z538Yd(aB??u>BAxPCVTrjc zkaj0|UiGPP8qSkWTIwJ3(kj8UDC6<haQS{M=XSp82wJ&GIiEs3k~7qv=Bk;nbe7NI z<(oIqfnR@xmnQdI>8BBE*m$Uellx$Hnu@Tg86)^rdR=HY$Qk@U6%y*VkpzyiZ5I-J zkS1%|1r(wM_TdU%BhQb>K+jjNO0zWnfnOmDnG;hjtqJIKP34lOvl{$)MLvR1)9RLB z9KoMf3ly$q$meVU3H!)nF_Td?=j8j+#X%g3^!Rd1GDz7+>=2Q0iM>eTb^$j$b)a;b z9!*kOM|~ka8`jWWl-!`86vb=~EQ&Es#Ta@8b8!cY0!sk*iFu@GTSVB$+JHOU1jv{% z9HkSW9gB-XIkcFholLU(>0YPC)g0Kb)t<<-cF<1p<LM=VxR4U3&GKW;^a$zKu9ReW z1)VEeCE8rYa84!7$S=DHE8iX&q6N4zh*L-!8nn1`o?4bwB-bXAm_o5KRW#QaO`PbL zDx6h7-8nuhsTjLnUcYWwu1&w!dq4b8iCgzRlimz%z4t(xhCY*~47_|`^5vS6Di+YO ztvWdU(T(ky6<~htDzLGxvV5&wh?7d6T|pl#=hXut*qny@&B=(?(y59uR$d+F=DJ~~ z;>}}oQQC_>w-mvvr)KBgLdOPHstsJT<%Up(hf8Cx<kmrt5fIu41rhwD-#hre-7%+} z=k`=9&wst3>-R(do7niB^WWj_?%MsYvxn!u_HO&|`TX}i+6a#zxD8J8JKXC4-zP<s zY}>oX1PZ)rNWDYh9Yk+X=fMc<uxdK*MFERw358;iZ>TboelR-ohk#o+>6nTn5qGpD zRvMh`Rdbw?HPkc1j?)#{5-(MAEc>_tk6azer7j|v<apr}QaR2AlMAlsQb#*^VUAH5 zZuWT8<x_m3NDBdO!j+MF=sBTZlrEjDka%xnW|Kx5Jq6xsr%Wem&LkTz0nZa@&L*_? ziCaFwoRudEL@{y8oOl&NDsqfVyR0o{m8a!UmNDAR5z~@{+~zt(m_rB$C!=@X(8v71 z#c=R*aO@vL%?q(#1FwG!#N=I$&IUs`#vJy%;5-Dc*8`Lqdi_!0ht4~k4jB5U-Vpf* zD1yo=#r<yY@;K<9YN_D-q8FfvN*V?y&bdGAo?+K}8}x$Fdu{k681?-yY@!0_55WJ~ z?~fonBPDA-z4f6NcyD_?oD7DJ*MAS;h2IUlo{R1d{qD#``SK0<y90!yzh9y*<bh-F z+&d)~hCrgW>%2SjM&ST04l%0mvNs~{PlkhY=nX=07%oE}4R|AuL@{sZZ0N$fGheSu z^w{e=UUw7>`oxV!M?;T1==-O=;MDJTeG(jK?$Ka~jF*^IE#QJT3_`LvxEzr*#)S$| zN8dLZb-F1B=!LfL4>9<2PisBdO#g#Qs22X0EP4-Di{@6iCn_dy*`&Eq36HGTsl;`R zg-ILn42uMd1y?;SN+nW9jPr=6RH~6KA5+5XWkOCwN{N_9s1GJ0))#?@Hfu+Jd4M`q zK`pcrwT3n_VNpUWoW{zbvbG#LZ%eK>d>5JGq?nKoW$7h+!HoqiZbP<Z?rfGh-lZrk z`}xLQt9Lw@6H!CV3Jw%Y630|r30I|et|?hz3O2VX(su9WVnMu4xCWt9Jd~hGre!7q zQ>HD_z0Y1QDkMac>4Z~6>d4@qMh*CHP(#fLEym0-2}8RZ07BTM4{tc}9CJ_id$RX1 z%r5{MS1)N=?iLo_(>kV#{2Lap>-hh;z&g}rYVpHegO#@^*B^`!2XGVdEdu%L_=L(H zAdFkW3&93>aN%JMb}xG#R@3G1Vt|E(807Q^{h)s`L@WL|LdI`nQE2ex;{7l<JsUY^ zgWj=^#0`YfL1_?m*TKgC0kIkHoDC#_$B=|jV<q}7AUv|T;Sf@}6?(uE=&_m+WU0`^ zF}@u8UJrGJB)rbt{IYXzdHx&v-toELTui>f8RPf9{~yr#ud}zmv$xaf?C;R|Z~vh4 zeE$0$?N6}!?Cdyy#bhAH-Z1!JKk9pW@TzV<T1Od2oWIdut%;*$#v2G7mkO8Bk+b^1 zu=;E$*)Ii`tX}?gq4C<O?uqr<R0xC>dL-tV5aR3CL}Vqm{%N)BjSr!c`k!E$9Kjax zZP||_`2IO1dq@&m%vf3@P9CT7C&=kj^x0zr+Aks22*wGKY}p&IqtD{BQzO<d^)Zw_ z6JZC><0-<t`SXWMcrFmQaX7*wH10vTv%?Zk;&+Jfw8M;P7fG1j(&LzAIc^aM`lMHV XAuc?(=l0zG|J#26_s&xu03ZMWWJ!4Y diff --git a/smoke-tests/content/promise-all-reject-late.json b/smoke-tests/content/promise-all-reject-late.json deleted file mode 100644 index e243b92..0000000 --- a/smoke-tests/content/promise-all-reject-late.json +++ /dev/null @@ -1,138 +0,0 @@ -{ - "_id": "promise-all-reject-late", - "_rev": "1-bb2ac9479869cc8479d1dd01c568acc0", - "name": "promise-all-reject-late", - "dist-tags": { - "latest": "1.0.1" - }, - "versions": { - "1.0.0": { - "name": "promise-all-reject-late", - "version": "1.0.0", - "description": "Like Promise.all, but save rejections until all promises are resolved", - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me", - "url": "https://izs.me" - }, - "license": "ISC", - "scripts": { - "test": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags" - }, - "tap": { - "check-coverage": true - }, - "devDependencies": { - "tap": "^14.10.5" - }, - "gitHead": "e9614a15b22f421aa97ff281d4e0f23681edbe98", - "_id": "promise-all-reject-late@1.0.0", - "_nodeVersion": "13.3.0", - "_npmVersion": "6.13.4", - "dist": { - "integrity": "sha512-f5XvVl++12pEo7Sv7f7FGfzVuVpeY2msNKjn7nNcXyOSKh5uVu7IAzDO6RE9hDVoHJhxvg+gqEacwkZ891Se5g==", - "shasum": "4fa37515e2d78c3b0462414402a8debce62b8b9f", - "tarball": "https://registry.npmjs.org/promise-all-reject-late/-/promise-all-reject-late-1.0.0.tgz", - "fileCount": 7, - "unpackedSize": 123039, - "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeBmldCRA9TVsSAnZWagAAaigP/2CarvNCbglNS0dgjOoH\n7ZuFo1cG+N8BkZct00TyEJjuB+5UUmv9TSnZogfEOGutvMqUTSRhvm3fOWsJ\n7TXs8zJ6SotDR9+xlxqi/skpYXfRdNjdaMvo9kYO5jaV84pstdbl17sPeYXd\nCudbAKp1sYodlaJyqpyfUd2PWUNe/VGLODmjLogHB4/bevT3tdjsdauKrUS4\n3VFw8sS1Fwp7P2YneNIK3C1TY/Yb66KysZO23VsQemCQFKXpQJMa9B6yj8zs\n5BQp+W5tM70IfW6OXD0+Vt2jWr9jmKmoWVEiL5usJT3zD7vRbeH3xQvSEgDD\nskI8vH8iJ+3EbEOWTGlIu7mX88Dp2KnHOoRUkOR03WJWuGnsTC8Uyqi0F1Xd\nFeFlaeNzynR/R2LcdRNiFOM+1xtzfAtVGF7TIp9UjgJwSNNkEMlkNzQqSiC7\n/AeqsAYoBBNmYWY2fvXdS9HQ4HfIGjI++jCYWX4I7sUvOjqfcwlEz8MwromA\nqeBAFPdvnB0F/q/AOOLkcdsO81jES7ts0nB7bDt0rDbztWWq34BSMDnNoSDo\nDE9q8u7g68tQcr3WmOQr4ro10sSbJVJZmz8DSJKCbVJ+FN0+GM+49oyyhIFl\nOjokXn5U8ASEdiZnmFnt51dr9A4fyjhehotJA6qSs7t2fBe86VnufijC971U\nv3Jc\r\n=lLwf\r\n-----END PGP SIGNATURE-----\r\n" - }, - "maintainers": [ - { - "name": "isaacs", - "email": "i@izs.me" - } - ], - "_npmUser": { - "name": "isaacs", - "email": "i@izs.me" - }, - "directories": {}, - "_npmOperationalInternal": { - "host": "s3://npm-registry-packages", - "tmp": "tmp/promise-all-reject-late_1.0.0_1577478492470_0.9438095135747766" - }, - "_hasShrinkwrap": false - }, - "1.0.1": { - "name": "promise-all-reject-late", - "version": "1.0.1", - "description": "Like Promise.all, but save rejections until all promises are resolved", - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me", - "url": "https://izs.me" - }, - "license": "ISC", - "scripts": { - "test": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags" - }, - "tap": { - "check-coverage": true - }, - "devDependencies": { - "tap": "^14.10.5" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - }, - "gitHead": "c892a9db86650c9229ab4cc70395106684d6818a", - "_id": "promise-all-reject-late@1.0.1", - "_nodeVersion": "12.14.1", - "_npmVersion": "6.13.6", - "dist": { - "integrity": "sha512-vuf0Lf0lOxyQREH7GDIOUMLS7kz+gs8i6B+Yi8dC68a2sychGrHTJYghMBD6k7eUcH0H5P73EckCA48xijWqXw==", - "shasum": "f8ebf13483e5ca91ad809ccc2fcf25f26f8643c2", - "tarball": "https://registry.npmjs.org/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz", - "fileCount": 8, - "unpackedSize": 123171, - "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeL65kCRA9TVsSAnZWagAAas4P/2WFFJvncp0LWb3DbE0t\ndx9BhZEwY3W8V6ug8uKvph24LoQp1PakkncscKS7PsCVHyIslD+fi6V99AmI\nOmL2ECAMUd5N69Cs8eTi4tKTNtUoIslfCu0+SMlCAF11D7oBXSabdOxGQofA\nuksoHdCqGM6M1y2BGjK7FR8dSwvgbQCPaUzazZ5w7w4XqVxDlzbvNj2E5mSF\n5HjlT5q239uNQppwPIFpisyi9DKa0ran2N7F2ioZ1PHvhFCqo6rmL8tAQsxQ\n+3OA4eFD0FJCJuqd3MOaY66mkncfNpmPvQYMyigKBUdJJyrgNsB67yfaFduy\ndK198Bnva5kotttQ4EHxM6gkqRm2d9o1/sYmAUtDELgrVDxzeNl+yG+nCkho\n1ta4cY+wy1dTjqAYaprQJ855nIeGGnr3tvz4dEGX/5eyh5K+oYVOYRFvWFX6\nVlEhBmSRqamfW5N1ndMyY18FM+Vc12yu66yZ3z1FqbgEGqdf3EP3lwWqClpP\nbPdXANzHM1FIz1PGHC7IZFWXH5KV1z+JXXahg/d8CLzz0PY6jaBt4c2xDvo7\nLaEAm7kNMbdewKvuTuG7x2Kqyf1KwjpOhXMrq6h0rlFm0pRt0xAArQ9Sglw8\n2Vq9Ic9EEsSIpzA5iQ86O1xkTREGHTB3uTRXUJixXIGkhLkhBB+Uj9y+GoOh\nX+Dm\r\n=yF+m\r\n-----END PGP SIGNATURE-----\r\n" - }, - "maintainers": [ - { - "name": "isaacs", - "email": "i@izs.me" - } - ], - "_npmUser": { - "name": "isaacs", - "email": "i@izs.me" - }, - "directories": {}, - "_npmOperationalInternal": { - "host": "s3://npm-registry-packages", - "tmp": "tmp/promise-all-reject-late_1.0.1_1580183139628_0.5159334029276426" - }, - "_hasShrinkwrap": false - } - }, - "time": { - "created": "2019-12-27T20:28:12.428Z", - "1.0.0": "2019-12-27T20:28:12.645Z", - "modified": "2020-01-28T03:45:42.154Z", - "1.0.1": "2020-01-28T03:45:39.762Z" - }, - "maintainers": [ - { - "name": "isaacs", - "email": "i@izs.me" - } - ], - "description": "Like Promise.all, but save rejections until all promises are resolved", - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me", - "url": "https://izs.me" - }, - "license": "ISC", - "readme": "# promise-all-reject-late\n\nLike Promise.all, but save rejections until all promises are resolved.\n\nThis is handy when you want to do a bunch of things in parallel, and\nrollback on failure, without clobbering or conflicting with those parallel\nactions that may be in flight. For example, creating a bunch of files,\nand deleting any if they don't all succeed.\n\nExample:\n\n```js\nconst lateReject = require('promise-all-reject-late')\n\nconst { promisify } = require('util')\nconst fs = require('fs')\nconst writeFile = promisify(fs.writeFile)\n\nconst createFilesOrRollback = (files) => {\n return lateReject(files.map(file => writeFile(file, 'some data')))\n .catch(er => {\n // try to clean up, then fail with the initial error\n // we know that all write attempts are finished at this point\n return lateReject(files.map(file => rimraf(file)))\n .catch(er => {\n console.error('failed to clean up, youre on your own i guess', er)\n })\n .then(() => {\n // fail with the original error\n throw er\n })\n })\n}\n```\n\n## API\n\n* `lateReject([array, of, promises])` - Resolve all the promises,\n returning a promise that rejects with the first error, or resolves with\n the array of results, but only after all promises are settled.\n", - "readmeFilename": "README.md", - "_cached": false, - "_contentLength": 0 -} \ No newline at end of file diff --git a/smoke-tests/content/promise-all-reject-late.min.json b/smoke-tests/content/promise-all-reject-late.min.json deleted file mode 100644 index 699be7a..0000000 --- a/smoke-tests/content/promise-all-reject-late.min.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "name": "promise-all-reject-late", - "dist-tags": { - "latest": "1.0.1" - }, - "versions": { - "1.0.0": { - "name": "promise-all-reject-late", - "version": "1.0.0", - "devDependencies": { - "tap": "^14.10.5" - }, - "dist": { - "integrity": "sha512-f5XvVl++12pEo7Sv7f7FGfzVuVpeY2msNKjn7nNcXyOSKh5uVu7IAzDO6RE9hDVoHJhxvg+gqEacwkZ891Se5g==", - "shasum": "4fa37515e2d78c3b0462414402a8debce62b8b9f", - "tarball": "https://registry.npmjs.org/promise-all-reject-late/-/promise-all-reject-late-1.0.0.tgz", - "fileCount": 7, - "unpackedSize": 123039, - "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeBmldCRA9TVsSAnZWagAAaigP/2CarvNCbglNS0dgjOoH\n7ZuFo1cG+N8BkZct00TyEJjuB+5UUmv9TSnZogfEOGutvMqUTSRhvm3fOWsJ\n7TXs8zJ6SotDR9+xlxqi/skpYXfRdNjdaMvo9kYO5jaV84pstdbl17sPeYXd\nCudbAKp1sYodlaJyqpyfUd2PWUNe/VGLODmjLogHB4/bevT3tdjsdauKrUS4\n3VFw8sS1Fwp7P2YneNIK3C1TY/Yb66KysZO23VsQemCQFKXpQJMa9B6yj8zs\n5BQp+W5tM70IfW6OXD0+Vt2jWr9jmKmoWVEiL5usJT3zD7vRbeH3xQvSEgDD\nskI8vH8iJ+3EbEOWTGlIu7mX88Dp2KnHOoRUkOR03WJWuGnsTC8Uyqi0F1Xd\nFeFlaeNzynR/R2LcdRNiFOM+1xtzfAtVGF7TIp9UjgJwSNNkEMlkNzQqSiC7\n/AeqsAYoBBNmYWY2fvXdS9HQ4HfIGjI++jCYWX4I7sUvOjqfcwlEz8MwromA\nqeBAFPdvnB0F/q/AOOLkcdsO81jES7ts0nB7bDt0rDbztWWq34BSMDnNoSDo\nDE9q8u7g68tQcr3WmOQr4ro10sSbJVJZmz8DSJKCbVJ+FN0+GM+49oyyhIFl\nOjokXn5U8ASEdiZnmFnt51dr9A4fyjhehotJA6qSs7t2fBe86VnufijC971U\nv3Jc\r\n=lLwf\r\n-----END PGP SIGNATURE-----\r\n" - } - }, - "1.0.1": { - "name": "promise-all-reject-late", - "version": "1.0.1", - "devDependencies": { - "tap": "^14.10.5" - }, - "dist": { - "integrity": "sha512-vuf0Lf0lOxyQREH7GDIOUMLS7kz+gs8i6B+Yi8dC68a2sychGrHTJYghMBD6k7eUcH0H5P73EckCA48xijWqXw==", - "shasum": "f8ebf13483e5ca91ad809ccc2fcf25f26f8643c2", - "tarball": "https://registry.npmjs.org/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz", - "fileCount": 8, - "unpackedSize": 123171, - "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeL65kCRA9TVsSAnZWagAAas4P/2WFFJvncp0LWb3DbE0t\ndx9BhZEwY3W8V6ug8uKvph24LoQp1PakkncscKS7PsCVHyIslD+fi6V99AmI\nOmL2ECAMUd5N69Cs8eTi4tKTNtUoIslfCu0+SMlCAF11D7oBXSabdOxGQofA\nuksoHdCqGM6M1y2BGjK7FR8dSwvgbQCPaUzazZ5w7w4XqVxDlzbvNj2E5mSF\n5HjlT5q239uNQppwPIFpisyi9DKa0ran2N7F2ioZ1PHvhFCqo6rmL8tAQsxQ\n+3OA4eFD0FJCJuqd3MOaY66mkncfNpmPvQYMyigKBUdJJyrgNsB67yfaFduy\ndK198Bnva5kotttQ4EHxM6gkqRm2d9o1/sYmAUtDELgrVDxzeNl+yG+nCkho\n1ta4cY+wy1dTjqAYaprQJ855nIeGGnr3tvz4dEGX/5eyh5K+oYVOYRFvWFX6\nVlEhBmSRqamfW5N1ndMyY18FM+Vc12yu66yZ3z1FqbgEGqdf3EP3lwWqClpP\nbPdXANzHM1FIz1PGHC7IZFWXH5KV1z+JXXahg/d8CLzz0PY6jaBt4c2xDvo7\nLaEAm7kNMbdewKvuTuG7x2Kqyf1KwjpOhXMrq6h0rlFm0pRt0xAArQ9Sglw8\n2Vq9Ic9EEsSIpzA5iQ86O1xkTREGHTB3uTRXUJixXIGkhLkhBB+Uj9y+GoOh\nX+Dm\r\n=yF+m\r\n-----END PGP SIGNATURE-----\r\n" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - } - }, - "modified": "2020-01-28T03:45:42.154Z", - "_cached": false, - "_contentLength": 2803 -} \ No newline at end of file diff --git a/smoke-tests/content/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz b/smoke-tests/content/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz deleted file mode 100644 index 7da40442387663b9f251a44867e18246aaa6c25d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 30838 zcmV(|K+(S+iwFP!000006YRZNo9arEAlT36S47=@$a`CdgLXmn<jkOjT?izQfc!H1 z6WY<fBf7GF`$z&JAOa$E$dlDGJr$Yvpv7g9nVXy2=H`K{*s`Iue;8I`8J-_$|K*qe zfgp&Z=*zw9)gOw$FaHI>a1erU94y<F2QW&MzrX%dKK`X~B1h$?{G)JAxV*gn{(t1} zzrLJ${l)d;<RvjJ&xpUjSf1jfs`e85uJ+<5rWVED+W+la`^SI#_U&JGme>CFFOIb< z|5be@E`Nd(7ya1BzV~|8a(u-;U*ee_%`!h+_1nKt+-%8@$klQ*8`Kx3BZ`>`OnGP6 zn+=#Lce<<{WH)fM5_+seR*+QhN#vjvdvXw){^?wclk%rxUNfz}=SLFBnHB#iT<3K8 zgx%>_PLjylrR784{zdUKEvi1!m4osdzx~VQ*YZ^DP#yiR?wS9XzjI%;&z<m3dB^AD zA3`wn{rCrA0{qYM{~z(UG_{wJK)p;YMe}0q+c(M&ipVm|<mGqekC#y_%gW34$BUqt zPO2qZ^zGYRi(D&?E#G@d{FgM=zP~8tL*GjgqFQ?SD|>3&k6u(OK99FbuEeD<(UV** zMU7tGl)d6xkVb(YYcF{@dSA+G)vuo>FS@3^l<iBYqwR_pBa*#DQ@_6ik)K(rrk2p; zN>pht@~#}k-;~!c_WYzoqk8}8jltWOUTy_}CP$@wdyyTd`fN*!e|-D495OEg*I!CK zo+-)kGUqvQL^JfuZ#|(r|LvtWqhG2<z14Ea@h@~qvT1L`3NO9s^rd`?@6DDYM))R; zmctjG8T9zFJy$+b0(%2Iqoymm6nphkBX&L=m9Kbv`i1L%V;Q~@gUcQ{nvRy6`o;ax za>fY4j}pMkjC)~3X1070h82*jZz7qO>8M9enU_Atf9uUQFT$LmM!o6x@^g8HT7EB| zzZ{kAOF1ksi&Y7$Z1Y0**xsP}1pcLZ^nChF8upd~SH6)iu@Y9(N@&0Id5(RVazgdN zFDrp5U(j3jsz*z@l^-j7f02ev`DuLh#l6|L9<>~Cv#ND1{Cm|G%$UJ+G+<^FQ$5Jl zt(P2MHe8idtsnUQ(&I-$^+s;Bte!6MDgl--X3Pm<P40>Y<yX}2XZR9%wpT;#-;)2w z|4$_P&;4EG|7F_yXT0MJ`48jx2l-D_I^loH|9}3U;(MjuR|-QxOA@CPu7Cda@-mP7 zQf_KLt}g#ymH4eL#xH;VKkqd7{c`({^7((gY5YISD=#mn7e$)xXi8E_<nq?bU;bL( zs^){=9W8mW%4^_%FMs}zR{%d8%`+0Sya)h)oI$-@gZYc~*Yc^$2Sr-!JDK+SHRatu zew0&%_j@Ln^H=pbzh8j7yp&y^r18JL{7Fw8-EvAa{`CFzX8pkB^zVOsFJCH`y6htm zk+v_t=mx^+fj1C;)JK2+cDk3Ok#|kV->;CWTK@gpw{k*F9qos92>d9i2zE`@d$d2H zS`s03l2_VSl+~j0X)kr0Z*M)3RF|~;r58nVae3%W@9G0CSIX{TWX1gb+@!P){&?$F zOMf|E|8XM4%b)-J=PPRbamGF|BR@Zb{Ba^oeMfUjrQ<@b<kXqxR&@tdggAXnO|SCj zTY3J!der>y^LLT|wI%gWngl+V|0s$=AMAeu{7?J;KjiNu43c`(g{c*3zyGN;vddxn z?R3YLOI`WTFTcMI`D(zI@<!3(_=g-B*<awlo`!tjJ4Gc#Tcu!X#V5)1r;EtGGo!r9 zqjGSk-m>Js`1e}w)iUAndptR@GOhVr?p*x0e|!1;EOb6jR9{S1&rMjraMJp6;`%Uo zeL8`CHHm$k$gU@|w+XG;r1sYSkB2>f`nGaD3FO>+<pJ%WDRVh7zrXzDfBcUUXU&t{ z((=5|c7Ofjr(oP+slT44;J;tS!R145#=_~ABPUv4ww&uR^y5dn8bj45RFd`gKj~Ei z-*bu=Sud^V+WdUwy)y&+>3cO0FML?>*ZGDjIOXK|=NDbR%$BD&>vEjDe$X2?RekvT zpFBU%&eQLyb$kMHYF$nI=O?Q9ySh}OzO-Dew7{z?-(MgQeC_2EJDwhW_fbidYBj1a zFYWeup0E9ertg%1D`R}0dUj=V*EV~lZB&kfOp7eNI2rSK*}81#l*2x`R*#Z1Hu3Kl zBLDuE3hCef_+I{12$e^*9Qpq8KT8w8WMTP2)<6BdZ1UH;7$iT+ev&KZe8c2>jmY<E z44f{W=(W@I$~#(hUmBJ4{NtpMT=i`3M|NDISaE`7Yd75g$H{q`SD$m!xu+iSJ?&2S zorD2&-E~RsKWqr!G>jfYM6Mg^Y4ormdehL#9yY{o*vmRRY>3}9%)EyUiR*@%b&tDG z4LjEjJ?k;V?hSdg#|<Iy=G}*&<hx4jL*HNE?=Q&r7xeoJ_WcF_{z80z>3o0bRwLxE zSC3Rf`ewTM{V!+UEBm?R(~BmY`&TE?)t$0Wu1>7%?WCmb)k)^Pos=|sJ1OaK1zLMO z`Rg@i)krG8^KC%=zvm+#Sw?@6s{vkp@nvGXxpX~uS7u0LDTz=@_TTF^r=I-d-u>$F z+XjC>kMGL(lB*B>-`&)>=>H#LHox#4pXvVyiV`2=e=r6?|Ed4~NBmXe=C?`>`t4s| zeml>cwIXzycw5yF`K=nDzm@ZK<w>vFK|jDB(CKQ$FO?=GzTSoE>t{_UE-%#cYIRN3 z0<E+#J;kc8pN8yj|MyPbX--@5Rjs8*r!TpT=IfUdKd>LzZx_Mw+hv-rZkb6E#Q)lE zN19Q^9Eu-a;O^reeq^*iKySCMPFgk4ABk~%18jMTW<*v}RFGp+#vr%_6DsO#ecu%e zAA>~AIE-NMu$`yEFpb0ALN?mRBqAvy*9^&DK;D#R=AtkWq|UA|m(FoHDP|06>GHCN zJ5)f7_d!4Z^Pk_|s%qI4sm>U_lJHGkzmUtc4AZHC9@SU=jVL<={Ov}+{`>bE@*0|_ zMRMXt52;)J?^)`;0xyaCdfci(eofnUj~kJ}&}@%akOOY}0%}`4MS4>U=a$2x3G#Cr zF}qew9&9^grpaQ~w;(ZUC)S`FK!xtF)QOmngmf(}c)-ka78Mu&2yK%hsP9yCC4Qi< zfXWv8Qe9W-TX4xY(Dg0HSLN8O@1Z{+;s=CW-;Mn=QtD`P-2yD1e(SKSFTFEDK0beK zy<K-=1(mpZYx9nL17CLG+exd2c+-b>`w?nc2B%K>o(Wo@=C6t#%mo7rpJww;{^#3g z-+JSN1$mcqP0b0ksHLY~ZAP}d&qTy^cl{(2-+NC<jC+@B)<(Z(?Ve{3Myf@cOlsw- z&w3M=*z0pW93@-R;N`8(8qj);>;xDa%{Xs5-_HloJn-bb+0jBH!R-0i)5C}#hW*gp zPw4IR_z$u685=`O-Y}9cU;UBYF9SkzgL)$Pw9&g!)1Xi9e#SqmV?Vy^t#?1(Yud$& z<zT|7l)X2OhCW7iy@JpCXi+SYzyLDZki8BqSXl^Z0%+tGFe#g3hmOrFJFUOmwQ&M* zZ4MJ=&}gf>l-|R9fa(28>D8bg;=r+z)+x-;QZ>bqO9_4={XeTW9=-CdPad^s+A~Jl zGazBzSHuWJ2dUlFLQp{4kt6^>ymO1tkH<$b?f{TJ#AYL4tGKo-*b1S#Nw2>f_A?nT z__4Q_kfNsy4*OK2Q{z9ZXRhY=N7@khbRS%RSJb{7*SZk+HC+i+M76YQkO!Xy)t<L+ zlT@FUy3_s&JZ8(t4#Cu5iNG5&hLLiN#vP&9hqs2wsK?CO92X2jgAvN~j36c{b5cM{ z{yCwhn6hJ^XJhb+9OW%7P7}+CUvI*<vv@1<ZOx0%v-MZXQy@pN_D|8APLRuPI2|<A znWSX7Ww*WUbf*=rX{+s+k>_-0v?vBW(@mFYwmeQPs?QSE+7i_bXei)F9s!C3>Lx^b z0=pXv$MqU->qEyehLe0~t{>>5_XrZDUSfSZ4L?nhGw6~e=cA@HNhyzl$BfuZJG}{s zsXip}qd1GyF{nG6L%Y}R>TO&xRax<vEirZFY_G=jI>PLDLzXIik}l^wCd%D503nNh z+wR-cbCS5k?o|tZBUPpKK}gAopRwB2RQt<C?*(>A+sk27VH&QEmT8FdQm7u+)P#`M zc_#>CTw!txLt}&ihNZ#i*r~+fR>n>aU32Ro8(0_CLD#~DMj^R-f}hNR)R8ydghh+Z z;U6-9ZtTU21@uuXc^$gHMscaqOUvH)=XB2*cGW%S!=~Lcho)G^Toh^GbpY)s_TVEn zAzie+jZlZ8I%+<l*v&DPv3;MV*+uUtle3~LVd9<yCOwzj?@(|>$n7C6`@q@<y0JX^ zwcT@Vyx%uVANSA$6X44SKGAC)Kl=p7T(wZOU20s6z*~+q9DgUDrz8k^fA^00_$ecv zKjGJNVFkEi!Rogu|0zdoY{AHcvd|^488L0rcO*ZK#;M@?TWtn0eUDGbybnw!Q>!x= zw70MVo7{M;QR}&ly19)m`q|RWN4`4t^R<yA{ByGR(~19c8$Iz`RdA^lM1ILViKV?k zd7vN2`|Lp<;6I@2cQ@^X5@1RD^5518z}KW-u9MY@*$h*8$?T?EX*5|ySm2VWNly!) zGub5bjjD*9kOBg3I|XKwaFb_}z(?YG=mA@o=gS#08!vlDZ%A;mf%78&+|aLyr)pZz zs>5rq#Jh2m)Qu_!b1P2doujoXf4pZ{dU0QoJ2h2I&6QhM(zlvS(ObxAWR-x=oeMvj zXJs$8TGa%7c+hjm%@;K8xL2@M|Gl2HYG|MLBGe)l>^d(-gC*h&cD;!tcVU>6W297? zzgEfWm&HlpJd_8e&T&PlpTg(__kz;ttX0GNnlr^ExE<m4mRFZ%XH$%Gq*OaMZaW2L zp&s`ROdxUKT<^wVr>%8S>2TnJd8s+{d8qFcRKkh$j9UO5FLA>D!QvGl!ouf-g5o=+ zDyH~eNtKhw6#CJ9IH<kCl@rB$NKNP|YMy}Bq&ywAYDizx(PcXr3<oh!g+~#<r>5_& zvD^q?Y$IB`z1flWFfzjUxjhd8K@|4Igob;tOO9P>AOn*bp~EyjotfReO;TDhwUgui zIYZX-BUg5;qt*)K<RnLt_X9St6#qiM(|CTMQdPP5o>~oRFV;)I59kd&Hy+;suju~n zQVaTeY}U#Z2zLFAtqqG6fx?!s9Ur&bBHyD6eyn;+N!R5`I$lgmX+~|K^oX|=2`yya zP-xj-0BO!04qgHp{7T97cs7S43pAdSu&SoZsgtzMcT3eKDXrKlx#r86DpJfx-nAzw zTtTeJTKzVmCDa0xJvoDPcBpEd85Rw-;$Q{JWUyy?4dh&8Jox@f(|Tg6E&r>&-e}d& zf6WI#kx=$PA(P=25#b2lf_TqUHe6?aMDZ0PyGk4k{8h&pD$FkM@G(IwCSayY8D++b zW3&?%TaU&RmUw%29uQ23bGrxQ@IB_WQu;~vLC^Hx3F?Um^<nD->T6Q?81EN&G8>@6 zwB6@QJ9&ol$Gs)nTLH%S>82kkY?6$_ovL<7De`)NJ~(28HN)mR5DzkPkU5yK07<l? zj-A+9Xa4dzkrW4|`jF`7ng8FRTIIVx1Y!?*K*CDX`gx7H0$5S6{Atw?z9!uMkRKPp zbg>s)X>H^(wPm`qBVaha0SFa+XyHl5&K%^!5!S=|{D|4$BQZ>d=12>M;fQG41yd{- z*&r#*C7Hf6+GOgJgp>8sMB1ggezJD{9j;B12c#=aqEaz-(nmVRlQQHDZcWJ7vu5(7 zBcStnA41~ka0c^yut=A|j>Kk=uxc=>;=)r}rtjM=)vuC09%2UlK%T(t9rPN%ch_1q z?60|I>u2mi*!5@;0d^Ki_&hY2V$Prlk`au`P5@4&q2nGQuCHMJ6eWTq!dRm|?yWhS zmWW~+S|&P6Vr!$ON0pX93y_}Vnzz_soCcL){o5s;2|<sTr$pPf9(l4WJ^mTaIRU+p zwLEOqkiO!X14e9hqyrXcC-Qg2+MXWit*uT4#BRVddEAOE!-F5<LOg@Z1!{%N<+xSD z`U;z5fRCxA5J-F{nZm#T0_32xn*(at#B#`E^dZxCpF;#a;efVk2w$`IDhqK_)Vd%I zlCZ>ht1wZG4Ycbm2S>!s5yTsIH-PH)fE=TT*~%piJHjHiJ)wpH6<hroztVkMYRAW5 zJ~!A2Y`W+JBjE=5o$Sb-qN%OVbp7X~+AZjkAh#Eq$u?`Z<Xt(A2;0;8Hf~H%kK--q zkibd<<dmqC4Xt2jtNJIX{k+n24Y)$=>a<4d3pEOA1$0m4#!0wnyRhD#PZ)U)Zx9rw z1N0ejl;oP0c(UT0r4WSvc;GkNS)Lpfw;J<3y1>tM`FrRUao%5R!3_-#(@DU<F@n*E z<Oa)STQl{(x0^Y7Ofy#K9vOJTul+T&n~oeSLf37U2aZBPGWHb2bX_t$UeMe0Is>F= z)f1yG()OD~cginTTmEj}a<#<t)n87c8{j7j-CSx)Afz4gYvo8=Fs1H}_?`hIWTZP| zE=_pRQsj;v1*8X|ss_0vXCG-Fz>^Jv*fTS;a}1q$$o$CjG%R|9-C(XPdo~(3B2XkN zmDLr<Ui>&dUd`&z&$|fT0k7zDd!=;({55?nDxDAMz7Y-A#1PJyQ5!o1N02xQLlOj+ zL287iyGcZs<!}t@xKzrsKDX&RDnmM;0d<H}_m8SPG^B~L>F;nT99YkJUOtG~%JuTj zW1#q+A}5#JD6sYz-XFsiJsx|xo)Ty^$P2CG+F#ee7Tk4G7nnl)kwqk0IA*4c8>1ss z=*u0M;G3nRFq2*uyCJpR_Hz_J;xO)r`|chpn7M=?Lu?2*<RaLzbI9&E0MQxB;ByqN z7r#WZXS@Z%9+J<`t041vIZVrpJ_+JJIrZIrMNQs&H=4R&x<0njlo2v8?SRGUXdU6* z`OX=o(qTTayBlynBzaTyl`UKl8-^nLR6KNv?mR-cf`@zA-lT1L*B{IDnBDO5acIQN zBw}qIwe-k;?4EkY9e4$|BF@{{X^ekO5q6=hnbnS(B#ck&%#ew33<rmWimqip+d5p^ z?uv-H7gzoEF_(x5DXPK*HAYE$cg%$@yW_FY-vNDWpT^sG2W}P<xQX7R$Vyct=u5ZV zbHnii^eSEV{k5ipluZmJLmU%Xfk)o5+IT1$3yxOjJ#>H^%>l4ac9gV7y8Jp_^_T2% z2xf}PCh}N-_H#d1fl&g_!w4^s*_d5~Tu3qSbB;SxF2Cu%ztoj&t)*Jgl?U(In|jX6 zH!pFk56|Z%)>^B|!EVWk?^>7iRP@RZa`nNF5=`%bd6Z{b0l$u%HSgaKZz=ot!?jio z|Ld&Ns*eXUvm9c19<PCc;vLPoF;OP_G0wtNh_tP307=EBy@n_uj3i($&e-mTpgRl& z$1J)Xw8c)obp+2Ed(=dlyX2;qDmU3k5Bm9WU)OhxYBteRr=?#4Qa38W1tB+$%KyLi zZ7I2LqRDlm${LiNQVXz>R|a_P*}8YXy+8W<yAkVZjv_zwA7Uk~e_n#ULaj&W`M6cX z`g&we;f}B*Ap-PrNx+fSK5-b1K~zUw^a6Rj-rC#<O4+`C)RBl!=bAB;hgw`{8n8Jm z00|c|o?eLfDpEO>w|EFc@^KSaYW0y$IsZJg-y!&kS?>b1CdKKnbprL3IW&L`Wuya4 z?^saV6+0$<hoX7&uu}5|$eh#P?(692Gvc>`SYc89*2A!on6&`C>jdMOlK0U>5<6`! zS}v15WNgbjoqp&PJ=ISm*-`pZe<Af@U}jK5!Q9)_4jA>xY1rMR+nj+8ioIB&fhMHS zB?R8aLaVU?-^PfwSdoKE%=r|e4PKSfn*^1!cPnnyvBSDe#oP}Zq>Aa=mMTBW5k#IF zVrQUrhnx;uNV5TkE;bY+amobY#?c|qilWCI`l%UYoJei#2tlTEy+0%OJ-VGEF>{pS z047(QJwl!CZkS1y-&4Uz!Dr5J#WAvEFSYPFkKt7~^|yb&4W3@B^wqt0*&2GRWtx}7 zuiojKyHz?(E0CkIMcn{<pHXAQt+NS!309t6+_!BiIQ32ReX7F8Xy?Cwn0+HnR?Epd zINyEDAdZz<54httQ>Za_R1hoHsDA4hRs%&E?GFH67<B0=kuo{I+OD@AA_xddTl8E% z&Owp0m^@iY4g>Ufm>C&>DHK^WGFB_yR1LnpvU{2YFNTIT2TUni$He}*v3eeZxuqtT zQ1Lt7s9FTAYD}N!&<~oAe0BSi;AfqT7WgGWN)6)^J^qPKxQ2XLT6Q_Fb@?x+0D7TJ zmx~210shg?1~zRGyZJU?k4OVY-}}UdN50&j4`AFtt}(khuf4ks0v8Ltw@OqX>#Mz_ zzfh<SMHQO_(l^pU2z%B9Rs<S9(qw0bC_&7Sy^KEu-6J<J@IhM`4#%6`veRkH$Mz_t z2fb-L6L*8>#L(&cFPVd<pw0tkxoY_90zz+KUx`^SC29}?f?7eB6s@kMEHX_*R-<B% zEJmynEHkP>pzHLqw`k3;#_0_C6|M7m)8JNUk$XGXu~V)+oZ_7Va7;7=+Z@Dh`+JyQ z<LmasWn}~~#x!ySq<jQzkMyvJvv4>N5O<EdM{lm!!P?CsZ`4)B`+{$z3;J$3KWJ*D z4QTRb=_j2hD02h5rp?Wj+Vj!*nmYZ(3}tye9cx3KP{<w0j{9qKBG4fK+r3^yIxbIU zO4esEl7xoa$vP4GJ%Kh==U5J;O@1&t4y}5b%W_&9z!cSIo(vePnj;t2<T^#$AIe<U zl}l6ekxB&rfWfC&?hN)s($jJ41ng^S4g%43*-qAnv&G8Z!_#c*(g-#_Xk%_l<>Rih zvQwk5VJ|gz83MTDESPRK2>=2sfjuyQzX!CU?Ti`E+~x#!XmhOc)%52FRnBpp4|$IV zUEe!d{||FJo+45W^-QGt_>|o7m83ybqX!!Ym+`peaUzLy==eS!9mdPJ$%wjg<leWh zo<rvXw#Mgj(gK?x1W%j@LfX<^S250GX?dR-(27)fq!~i>ba!|4?QK6j6ZriI{)FJW zi!JEuQ1D5)8{6ySWX;ed6nj*E>rCgU5m3l@G_@2e80?ONuHGFG$sin1M`pQzO=%t} zme=e0D>P4ZcxSC-W{80}w(?kwM-cxxr*xHEa-Ca()w<nJxT9_XJaR-~?~H=xq`!h+ zt$2PrYhfR<!5)hf6<%%0F>SA%4Kdh_4|>dW+FmxXSIi0;ARPsYtr@<U<8pVt?6U5V z><qjhRs@$F3x2;d<wjA`N!4~fPyBrmqXQf;9y_1Da`gC-)~d4KTh?c3I#0L-t^n5@ z`gYnZ>YM1$YGi~~)(;^qOb!dy>8Yy~oy(1M+^ST&<9rtQ={|we8ETEt`MCBhcfTHK z-i$O55&}?*_77MOJBGu_akaE^2i6MIhJA3xDB^aLIlzDu#_ELJqrLH9GR<%k5i&_J ziKIskwRvyB30sNnGO)=$H!JVsRw292+1&vl?}`$XsI@N1gLgu2j&HQo$jZ(OUMkMN zE+FumYk8JilJ52HJL5M@wewB*N2l{p7YJ(i?t}ire>~-LJHf1a?{w6v;e6e9x|@lp zB9or4n{%yWbBdLax!}P%(p^mVUe6nZh{1JLT_rGgRV2sBY)e9>s^N=a>Pax409>Au z<;;&*P%>kjU3`2_O5XDl-}pE_j}3Sw?Mr=3i=s;FPGrT7?>7uCt1CXZINr(WzhRG~ zhf3tfajPz<_t1~=lyG^2TXp8!Sqp6<S~P4t+?e@3(vhVp^_Y;FPf<*zmMi9&E^(r? zRRx^1`}E39>otlEmr~~^X0*$rkLEJy$L-i{PQe;-6-cRmThIp&;lrUYJdD+i6hiEB zwAhUiF9(${j)(qowt{h@RGjE^u!W?JbD)J}l}uJ9Cy!kdg5dUY>kbcxRcV-n^R>Xa zL_!yG406Kg9}k{bv3Aft`gGn{^7`nONvq{u=Otbb%v|&d1@r>7r19mjbprJjcbdy1 zP9p^{1t1kQST~(P8-`xPXm&s2{VQMUO&;z=p5Ld$c_HE>hvO4es32A(sD5jQV*^KY zu<4DC8t-?;_+-w=V^EYh6Pq9HUEb!kBt2^8fF%|@zs5`r)#t+l9H|qQgfUz*$CSMW z*8IYSaBVvcr!%3$3)}VfxfrZ_k&e(K5vOW(B+EKJcKtjvRlR|&sdqVPL0?Z;P^;_A zW_@0u<lTr~r5b>`-Ng{|w@lDr&BUkcMSfjs*W=gJ2tT^nB;BhdfW9Z<P0-zmR564X z`gV*HE9(f1=l6BT25#q|wX5?vF46P{%<#_L@$0f=Zb8>Hy1vjXK@>SgrYjc-fItit zMn)W<mJ*G*gV`XFS+(>>iJ|CIHhKlHLZtku=j{ffA%=mqnwfKo>x0mgUyxMC)X~h` ziS7ud1_CB;y~A|uEU|u~md)sX*a1TTI8G{?Ui2f8R;L)r4YqAjpGIP`ne~AO&X^C# zS8LNBiO1)hF0W88WT=jtI9)1Q;Oz{aQ*C^;94OL!t|hy!tV}z)ztf_X(Wa8Q+M8<Q zl}bZoJJ*J@?5HQc4}!+#=!L@pZw{GVVXp?qP#<)8i4!8MXp-QhDN1V}?;fdi;8RPh zE<j64Tn<~{*Nd#67Uy#T$%*u;Fj18i?F15*rZ31Yd!MJjw2f-Se*1UuecbQ;;+MaD zviL=F{r%@lhAZ#P&$}|O;8uisJ8RYOzGfOKC#O6!S`gE0(<ecx;IrHeu^AT5O$DE` zdm7(u45ROiuuVZ54gh9{5EF+xmg|R8gD`dJ=%$?|wuKg@G2|{s<|t{B19q}F9+IQd zK%ZcmGti0_=fhf;ZIFRLsQuy04Yj_&B=DAusmSu9iRU3(IM@Ta+O^#gzVM|SZMW$u zU?~i#E8vO<$CMR^(K4Pa_c^N1`UM<FT`m+7x`RGvj$3i7u5fL=ru4v%v<)rBPqy1H z)zV&}R&=}^H`UfwZX4(y*r-d51jz(<7Piemi=zQl>6=(M)$AAw&7L1j#NIeZ)X13Z zCWT<x0g(?(dI}Ebn!K06IkuW^qr=qptd-a#7V{u4<B@d!`8uHYUQko$<K<dre^C^) z%G??DL~F1JXKgszr^PWJ^$L@nn#rOGx{uQ);UDlb=(#mEZtDb~L03a@YHeYk7Nrb5 z&N&Phz?s5hi^yVRbC9SrnB(!j#SKttoGE)!EJaK>LIG{!OZ_3*LFSV|I!#kt>}=5` zX5h$5Y$QCY6`QX7OSO+P%$fxCQBxg68>IbyPOJh|1`IR+7Q@VwK)zV6+k&W#Nt$gN zRKoUn4pgS;5*{kd#9PiYb1&lZKno*^Y{$EqAApni=z{xLmR60HAH9_+d8CFvF`=Ab z)>NpEY6ZK&L}H7v60U8OqXN7mY(dpFn2BiN?T)oaKyX4z%W;Un^R~Ltq@|EgP)I74 z2iciH8t?Y7ZFjY5PuE?V=u3htc7@*NfHxZUb$(AP@lQhYvDN;}d~yrBqRQ=+IzauU zN-|vyp$#wu7CmC+SZy<ytp@?bsonOb0e+ROqdpw!&$!D@AS-O@gQmIA`aVo4tgFxj zRY-Um&DImJPo}!PReWnO=z#e$ou~UX)&&(3TPBVNgABYPQK2pMcri5By1sSb>C6xS zW1-GRBg<_!>f%FkUZVYpw(#>N)En3nDK5*vYiM8fsS^yC1;;W2FCdrbK|nhqh#zxc zXf#Nt_*muU(Fp!|Ira{AiQ2m>^@#q`>!jr?bFTu@mgu%;d4{xi(`jEv7NOn1H2kzc z&wW&%$((xpnhVx<Z?@oOiEfUmw(~wPwY#0+)?ZSIBS!Kt(M@c<vG$|A?5q`=h~-t1 z%AP<MQ}*BuO<~Q@<8XMO2{-0DG?-Fu=-Bz55<7=1A2u<lZkFRbG8UfTj90J~d0tOy zQ=!2;7jk~L52)<QrQoTuL&=?(d6V&BIp0$*!1IBI8gx2{j`oyr8PRF0`;CyooVtML zG6KRg)DLaJ=vooJm#5MgUI}9GT;5+Peot1;+nS|Mq7HhsM6h<qw;pFnJjsDKplh;T zUueo{%MhPi2L{aBBHPy~W5>-r+ggl7-)WD>Q^Mm}3kLP@*h6Q0-0kUF$PP4Kom)sg zGB@^NuaUB3!qFj@0}orK$SCBVtcQA)O>%M$-vlqdSZQJ#uQxw&i`7I*A1UY070)`u zymUbtG%1@^(H<&joOh=qXie&e)W|qKcN81f2`t%^b{-Gz!#w69?!az~!6sa#v^fSH zw6|6{$Xd7i%ebqMJ(jT{LlT$+WDC2(dCu^2e5I<V`K~U~LlQnLhwz*S_5|`wKr3nH zS=}zYoN*&CUz_4^9&Wi6N>5GBhNSyzv2T%Z{JiyPVce4Ypl3=uTtTi7dOK^KAvVZ6 zO}fJ+l3^gRqqJzO2WWqd&M<~3V#_0shkY=CqA9T(x5*rWgS3x3nGCbN(Rw35Y6sbg z1i5VY35K=-T^=ts7#lpQNBEH{k>>iD*7~eOBm9rh<{JKmLf6+?a8o)dw(oU#j!627 zIFOL31MYj0v6_m}Ol~X83>>cmctot-qqJ-fsD)t)I{-u=c(zY^JD@<MuC)&42U}!E z9UKto707_k$*x;|s@Fo@P^gknR#XnL_;q;Qgvv7~{L0}{?c`-dep*R+({di^<xpw- z<3Has?|@ew^X^ishWyp2Ty_;1Oxl{`Sv$8ED3s-FXPr1(b5Hp|Z^QP#{q3e&>AkgO zkAzl<Oi84cY@8Nc+#m7yGpfxs<TKe`&s#OjFAIxx6rE-U34YYEU0=mP4Wi&V92dd; zB!Ksrxh+*r9=Rmo(xmu#WBe8B38T|-tA^EJUUQ}s5@u6G9?YRd8`dc90P3?H&uYY4 z&Fv)TqSVyGPz9sWSjuN8Z2}BpMsvZTskJBY#46cBGo%xVYZt%)mNCaqE~$E}-gBzC z`EKd{`yA?%-htof9o0(jx0<<i0QNzRE<LW8F|L+fReIRtA^OxL`3`v1Gw&`n3%wl+ zQCv>Q1;V)L){()Xwy>nJr52qg6K7oQf9#wUg<px?E8H5f*Ry6g^%p`i7FcmV33@Q- zduAsl7reW|?M@S%URP>8($9b1({TY>V{`W1z|Bha@n}w4WWEI_$H3quEt$}%0rj`a z#tb*!YBNdn?IuB88WYGPfrsFPM;Be67>wq!8;kRSD<RBgJ|BZB$L+HN0z2yVs~oS- z^1NS5S3AD{nPdA2DqTaaNOgVQBs;UB*C<EXBdZHYs@m-+JS;7mrX0r{<PI0b5e6Pb zYsqnK33r5cx4=ng43ab~ZjX^Ctv2L1b`V($_Xdw;#7>gTt+3fO(U+=?R}|TCs_F-i zGX&wMT>kH1*LzdlT&cC>2Cj0t=+6<7Z6llEa=}rnX*&nG?T`nZV4@A8gP$lvNeO3+ z>N!c+&)1@EGUTF*Y9k*(d-@{q!DwJxs8Wn9J=uV`3HO`$&dTo%<j)o>Ke5fi8Rm%^ z)lnUp{bGLwsI|@jZtj{hF^KG<hy}wXISb#Ig6{v56PeEIGw-`npeHo73SfnPwSKgQ z&|tlKE+6t@OTbf`$hM<dGMhz3z6Q7Hv=EX=r4xCl>Dx(fgKY<6Q%nr?=s78`#fO<Y zw-N>vdK|#Pcq}c4+C&(^IZHlS?&W6sxRcUrdHUPNaMfM(_O7Xw$kkN8O*O4DeP3(z zAn%{^J>`-@jJ(szt0|@md+ti=r-|02Ki}5v-Y-b-j63HF?xlB6XLUw@17j%MC%oZ} zM3>XO$%;W{<KBW%ZNQmC2R-j3n5_}QI?>tXP}#?%&gs&cTIlKy0gpQEZx`^07e<z) zy8C1|+|IWEFfyM@Rl8c2e9l3ANJ{x(5UJW@;F)x_Gt@H?%cIsAQiFYII5KE6%wT1W z;;|4AxstUDoaF#V?5;`{lEOpU*WHdr=0|B}6gsKmgCj7~CX4Q#atqTRcDn|IvB(lw z$l|cSw~md1inp26_XCUY6I%Qg+=?D=XRR9E*A$TvP-I9KoipkIQhAbK`xAoH_S!z9 zGBWbL-E?mzKs-zbn|)_Kj0v`lZGkAkoE*cTY)cgSlG>wUS`>&YjEjVp9_^NNLy^;d z+Pl)Aen=4P34*+Vt@e(3J!#d@8dPp8=9)70$HPe*Rd9K03fX}x252^((6K2ZxHt?z zOQdMgB>Zj;XSs#U1aAtn?0k=GR5cA{Qb`GAurrMDf(3U`_wbw`^)$a#8#ia81iuw) zl{WXf^5NF7eYvxp<GcH*;Z(tj{l!@UJt~53%F%gugJ0?od;?o|)8(X@Uoc$d)|ksC zIipej%%(+QSnx*)A;zO7d>6Gc*|F45HXFsBT5Ws-`Ha@<c`f7{Fkn2(IO@nOW>Gtg zvaz8ct3lhQ(M9463ne<{0)V^vGKz$-OOTnoQRdt22-*taK$!CcLLEGGI$6@_JW2Rm zUlDsL#GWjSQEwjd+u!i_d*j^j#HWP~OgV1p&cj5;=e+S3pf!n4ht0OJNK}4>P=jq` zjU`u~4RpsJb_hpIGq4HYoGN7fQasEP`<K7XFj$3b7NTMRk%jBJ!}h@H&-al&%9c<0 z-pXnGonPd^L~i=^N*=>XTBZ8tKNJO>C(NLCuq%SxUTM{E8)S*Z@m}6_s7zh!%9>q^ zN*1qE7aitm*j*12o<^35#xfbR3&H8Sux5)0?*&mf33W}T*T+(QI!GCRP=lPo?Ub<W zsolg3s*tOTBFjk{{o2(0ThJA4ZZ0%S(Rb71cFgyON;cn0u;fxvI@ifP5pho~LAq}n zUCD=io#S-A2j9BE<Jb)B^DW|$*to4b_Q<yU`GWXYa7$8Noz*tx7v=GxmTg*C9NE6V zw+?e<Nysp?-WBX>1>CnWZ*h7vdmcGge%@5P0Ije&AJ#6FFP-?p4%)M-zL+lZaW-Zq z%uvD&NrHCzQ-b8N^;Olt3F`Mg5G_{*-y`+niH<%4t?6<)tW}E!J0RHYY#^`E_QsJB z=~%E-wp?)QjW!x)Ava09kW|y-au^(g#rD{X?Fnmc;R(Qaq$RN3<3R97eT@y)lY@+^ z8*MvUgj(K2A->JbeY6Y2&xbFr;8x^#JFEAE_%d{%cHGUPKgL6@IE2$6&`{EryikyX z29xH85?8-2JK`4f3A3vUO|v7mEW>ZK7!T+|Ez*Id#u~xJ!$Yzg5t68_82@PSZG(tZ z@UXJn&CJQRJky@Qtg&70rGkL5k*+yYO;i}ROSo>r4<7AQ`o$o+R{{J}?aHcx1IZ`; zC-|uh?KiL|s-913ihjv1;V7q8kj8f?VyO>hGu6Vi(lL$z+dwxjUshVLPF-@V^;W9t zms%bV-f=?p-koMPiBGVTHPhMJ8&=Z75aR#>N4p5IT{Q?#ytz|;UCQwp<_WL5{~D$o zV*@amB;>L`a=DQ9rX*|*a58{HWy18;)JKzT+GUsRAwFAVZNoGR1oSa1)n)xKZco)A z(Vb3Xc%nyM2U|`jMUNm?PcK$@WAIN`MwTtT)ZKlu3G$P?a)NrI;_0|fX=_sL1fne6 zHgK)8EF2+FlVzYyMK;U?k`a%~BpGH5PZKBv1m3pOn`IyfqAWi}k;P<AJCm+5$YudP z+e+IN>FfsU&EeoRQAe+}`d?Q`?iK2Z7OyJ-8&r^E5@C<5Fdv<23XZ}ZlT>iL2lIv9 zU@1cRt|~OEex88+WbeK~K4JBC-Yh7I4ZRW7-|I9P^N1P*i@9Sk`cW2wCK_S<&%o&o zo1efV#b&C|H{#TkS<;`4MO>WB4MkWUzOWEJiz!}~$^S~(T|%sJD}S5GWqh6;)!9MZ zwXKzA(n{P{lFhLb17?He$yWU7KzeTR;RR@o$9WhvT71X@o3@sTGT;IND)u;efum`E zqEOpL%$CUBE_GUtwQHT~$vn&eelDDO_YF0Ycdj=LZFc1K(My>*HO>YeEAV=PrYg<T z$qo{cz+TuaJHn<T03W7{BjzvAF}&(~(69qXat{f|Nx@BRI~T(dMK0{UH%L6pZQ`)M z`RZy*tWRk5^FhuJ(BIRk-h``${WXoUh(9K)uE_I!x}X5rcJ!&Qt&5qu)D0PCMo3Ar zfrlzvTn~hGFr13rHBJpP-DjzJVi-o}n9;OLp}X!uPr)PJcAV#Y)_1nd{4~~fgR|w8 zR7%~)aW~|tl^74+@t)#ucj_9(4JLTZ^F}i?^RdHXJ5<-6-`>#cF*pE5h}v_}wQ<x1 zaXFtZf_?kg6Jb@v$7ul;vJQdmV>IT*+R&dNdL;KXV9kf{t}lL>#PR8-=I?haf0qn( zZv*k$Liw+|cWZ9o$cgqToSWT_A40m?iu@gzM<VHD^V}A@*4#@8DEx+-u1NK;QrqR( zM}=+hcRq{etaSoi)n}^@TKEUXdB{9Fq`M^LrJ##=K}K@0>U0B4pJ+A%yX{%-(Z0fo zQM%|0P&?CDLp`Q*#p756WpOG$NS*z#?Hm{xi%6f=R(XmIhs$fb^Bn`dUcFzJ=B6*s zd!T&c>3vo?x&M;)L-FcX(+ybq8&H|Ml8j3JqBPOTj>svpZt*^ec_iS#^CNs1r0XFs z6wrk2Ec)C=KenS8up6*cPt*3%263aHkNM-FG6UnbAxG4cVUzPtw)Zv?dY9{pzvuJM zhs4eJiYzyh_1`YB!JB(&YSn%5H>6(a{u6`cei5yYBj)zIo3p^<Vp{kIh2UXlYfEt& zkwQY~`yE{v#}0@EY$?7+F)S|0na#Ukc-X1{OZ2cctsX>P;xP6wAlF-Szd@C7x|ym; zGzfXU<C1gtm<xgQkC%n=EJZ7)zPG;ruvJFwn6kCEo#a34xN#-uu#z0$hx?|slRcw# zE-m}p#mD}k;e$e8H6Ogmf@??Zf0qAh*w6n!`LCPt9ciBwyskk1d|Br^@ZSs9)74tH zY*5}=AClStBM@d}nPzY2<i;TqG%o<@U4bWKw$HbRnWIHy98pUe+u5tspCuk*h$h_K zQbGqtmBE0VdxT&R%FG7f!zz9*(fcRVg?9_d-q%+7xN`=6Q(dKrQt=+fV^Ik`t6bc? zqEa$$F0}9uu9t_s7;4a7cOljwW?_3KnE0B3QDeU5IYx}7;emptqeHvBo;h^a%8AW( zG1zZs`^}6v3}j}2TNAa{VUk&2!g<ixd*V6(@_&3FU1bNnTiWr{W9cp5<+CcRPXyQ= zyyX3;y1G?I@*CuA@+dJmvI#vN;#Igw>aLduU>{Artrsg2Dh9I|0L?{9*etdERGdp0 z;rkgtr+R0z5axx*ud-BIghyzp#1!uO{&x9f<l$0_@4OGxlS=yMqwX_(<!-jp=be5M zV~?YT@ITVoXW-YJe7@AGA%ESu!o)%&k1eL;L<7eKoUYUZ+%Y@;fCx-@K2I0(Y}7Lm zNChYha0H7<Q3@~-pPZ-TF5u25CRa!x+c7ri3Y)QzG}YG6*@icXc9$BicZs{NDzpZg z{K(e<J+%||E7X#lug5Lu>%FimI*PO+q}~$96-Ds}DBe$wDcLI)6X$3S_l|{z2&6&! zXgJ_vJ`Td!s=pVHgB?I<qdx5{vv67%2RWdJ^PvFx=@Rza$#a9`vO~^^gby4V`>K40 ztv#$?h(2XFy+W->csZ`)ISok2tK*gKC=8;kjuVRw7e-8_Al{#+-IY2TbKp+f?B?ch zhT6Cs7~{m!6`x9$-JNpaf(@AjG;C8WF6@p5O37&~wda#20qwWS&-djq^vs@9XP_rS zR7b57ps(q$(RT_*>`Q~7*n{-oun`4E&=#}djwaTnbd5ww6IbazS}^|hD2+#aM9uxe z#_cIS>g{_2c;q|m1YLsWY^8xiZWUwW=U7ROjN6*mH#M!_3J_iP6nemFpH{_thO~7> zyw_@YU&eX^ZM(`-$wH!a(Nmq6APS%E5k;40n{bB~D-Xpt_Jm`-hFBv|{<dluUvmYw zNr^Rc+}qRwp|E+3EJoXSq0fTQ9~awguiMSlt}Lk_Hlq>>3nb1K%n9t4Ofg(9c)U#& zu(O+~b7xBi>0-EMaKvchV6Ll&)LhWoX-T3*r%GtQwlMyqm(*0cf2-+|EH?^^?L=Q= zj5#IDEL22X8bHNn@9nj8Lmz3=RC>Kt6n5r*2b+-#ay$pN^lC|9;dasOjO>+9hN{gR z?9}E~#4?8Ss7V2nQ`wczQj)=^Qt7YYUdVG!N(R49rH5L{h#uLgBu{fmTylz+Ej!`T zH!{y`G#K9AcI8&RkK8jAqVK)n9hR5Nt@;gLGr(cDqlTDDZC2Q_GgTPVOif}q?sSIh zR6@ddglxbgx9v~#Ei+UC$r`TO<HOO$;Vv1)@~-W&)^L$n-JG2R9Tel|8q%m1-?{G2 zrQl9gD)RxYu%|L7?!bQ~)y>rw)}+`G6UY{{X|L7?*XYJ52{{Uh#tM|A4K{drO{ILK zk3EB41+vDdI;b_VFOguEn46K9k`FN2>I@KJo2To(94F!Zw4Sdfz}pnk5028CqFldy zNGiM)0q@59iAJZgl~u08!wK|e?}=aM<$eQO()jJ9Ss)(Ip+T}@c)TN;(R9gB9I)IF z$fyf62v<A4te&b;eX>^dISup{bcNW>g(kWv)S5!weuxeCthw1QyDJ=ywmuFLJ@>)h zO<yq4m%CG(=w5x~l`eIC|FZ4Ghg~y2E5hBtI~3d&BYWQk?_bxv8-i2$vFhi}f`JEQ z$7CS}V}@+&^KCFA+w|@*OU8&`tT)ewi*Abv{kkO)S8!_{dp&DfaEa(~1lq|ZZ)DEG zUMeRAyp@LbV#o_KeJ+mT`AE+hPU2v==gPhqNpj|J3d>{OaXFoBvH-!?FbuX`S?1$N zQ=kEkJ!f|Zt<(44=dc>7Q)!1gJob**pX?Y>GClDF`uS{)6VRH-^>z_wI1Mr~4xGXd zGivYoiYj1AkgpeO@#wlHreQ!VGw@>IYYTTbad`nBBjO?m=G-U&S<htv^x$m$)Gffl zd;roQD~=YsSr2NWFrPm3hwjKpRajEf9@Qy8pK?=t1pi8$>x(V)YsUrD0&;fTZ<`^z zTsqk}i)qO-dP_tnb`7#%Z}vQTw3OuMb57pC)`(qB>Lnx%vP@RQgmR~97!QWzRFlGu z)9-;IC^+~W>@W<pjoe;WIqX*qD2d^+8+wIE&ySFO4EoF*+^gfX@5!+=(gl^!V|li= zgIyDK&++|Iifdl>xWeOej;U+FHA&u1o4Ti*B0bCpQCrf@$kAMwnzmPpw^E>^5>9#} zm!yxWy&*POzg;Y>nQHqupz~8Lb8={Cu!WElIu1dr(FQGvm>hV)pCHeLN3K0jXL0iK zZ~yl4nFrx|FQG>TzMqgR7pN6YFUNI(?*`H(mbT80nZsN>oZ0J$b+Ez4Zto{H0kWiL z;Hwq78MVU!z1bN$zS+%DCUe7)uv=69*y1NK0PTdJKNO9{Asa(PA9k!Kmp=xvma6{6 zCw*&wm$wVqaje(9#UA=pubkq)ZtcSbXi4GAVbk>vQ=z*CRHZYS9@f;Zqk0z6)u*G; zs)vci)-Uz~OXW)^mDfGchY5w6fIG7sszwgP%e5HHi?$<h7-2cQbqH-Rquu0D<+-m2 z{CL-|>nJ$>h<$6+KPymQ*$qF>zi(hK<UN(Buc0+4S%<`<{cPpuAkc~PSuO^lKSVc_ zU`}Rzo0W6iA42X-fK8d+E<#(|_MM@CsHU$myUD~IlW4XM#;LL@8xojIZ#1UcL{7R| zWN1xx0)2|(-T|*j^X^iUT=2T~p{)eO94-ty3D~&_yVPPU>&V`m;WV;shvIf9s8Y57 zU`EG=2H%^LCBO9u0$^q?NX-v008v_--ApW`a6?s3Lu>b(AGUeisV)(wK3bts&KA!s z?mPpnXn8tnod7kMjCcB&;?Y%4<YxvO=p*+CVzJv>PY6H(wqCNAdobRcCH8via9S57 zda{8X)sZq;tfoDy-=#uSI*?X(zlyP=-Rq#cO%tE~O{uhprL>+HbgytP)Of8F*=V-_ zY+?#YNMeUz+0zE$gzT|KE^k<GVcA5YEoSJbcccg}pflV)YAZa5beqSCozfx3kS($E zf$hs%A%x0r(hjU)yUZhJ)E7+k#wr)Sc)(F_^=uv)P(Q!$@fB)K#`AG)JT+MQSd53_ zf-#G5K3y%1q)T>?`8vfVBs!pMmJKsul`VbW2y%ZwbE^eV&=C&~c|QRPj#4R(NKtc* z1d^WMwnUOjXo9Qf=7wEm+n4rHAbS^r{0*w>Nj)a!X*T|KYp*XrFQhCFo2|F@q24Gq zx+F&v@sO}rT^3TinC~w92J2m_SA9}c3wbKEa{+orr7o+5G~9BfABvWl;q!%&?>p^c zImn!@JwFnMQEvnA*b!fE_Wa1Bk%5hb2YfLQX#B`1fi^(tQdwAd88pU^Sx4K8UC=Bx zqlu0@C$6tmF7#)8GH(w*a?8B;4>c$68FoqC^U)oD*h2y%xjL}aZ4qK~66~PsDI;LZ zfD`y0lJD0&XC$#^>cTd!WNj1@JXmuVpjs#k2~D@_skYB2nSnELwo@H(3iLOOk`TS8 zGl5;Z)FvPAkB&XVeKp96_v(XI4dqLZb58_0E*cyWfaPKRXxe*8UPDl^xF1jXQYyb~ z6b#n6bw9y7cf`v_%3SB`{S<ZXh#BxhcHRRjnd|l>>#&$EY@C#uP@B{Y1H8w_eeh`p z__b9s-CF20u8bKE?D+u@_iW<!aCQw7eh=-FeP-IHwp&y{*P%Ax)>MXfk|nU;A(`Fg z3wa{V!TEAhNQpZYSa1i(>T1bkyBL}?@(^wkR=h5^bRYX?Y6rhUEs5}Y+=9QZ8C=oA zDrC2#lPR?dByBPu1oDj462@291i{hJreb~C9jE4gy~b7EGg4mUbQ>OQWjdJe6>ef# zYid54Z7FD=92bPO43S5BlfI+Hy^WiHo&9<TeodbbSDRY3J+1>~@rZ+LC}z=Zq~gPr zC|~T3XV6TrdV3iH4F%n;kv^EKKsQ>rN;+J~rM^RLMhw-l`fHB?TsbpgWWXgvP8w+w zqw6Z?`%whx=au0L(26GK!zO!v)rFZo6U9_b+hM*l+Ys8i1C#cgBLv~VV}h_5Tk~bK zRQoG&llPnsHDP<$tUKQ?H}=rt_f{+_2W0^b*Xq<fz~SLAK2B#%3<IxPFYo$l>Xcgh zm;0kV!7?A=SLFG4wOO2PzlDLxcsmhd@h}aT!<J%(hf;YVm<Dk+&yQTW-XS+AnY3EX z_-S=+>?w5by`skW-i<ojrNKC9V-!0>mLQL=mwS{}2C{bWfymzqs?e9(V2|ULJQwW` zM`{4&k+f#w!H%D3+1?pVfi2CT@zxnf7(=5Q2`oa_o&egDX^9_7N}c>@H&s2))Viqu z@1u0DZX&pHbt2V2X!XxcTI#t3o7O6+`${yY99Lfa7Mpos_Fq%`7l*oTLBH$S<^eBU z+s4>5Mx=zY;-M6D1$eM3I%;SK0}CZZ;fM_6&|+}ynC`&x2}U?3>s7uYaS9(zb_;t0 z&%IsSrBP|)?<qc4@@bQB%()msRTe>hl!x}*MzuGPE5cl#H`%ZjYEkRNm_RdX;*8=! zmJV%tKmkZNx5v+dh1}yC6s_@!M>+uX+?JOmzzU5*X+aJ5x#UJ*=HlDI%JT=?tes5N zEv&_Yc%<_c)#(Vc7{JHAz_H??2N)BU>@00!Pv(Z^P7f%Df{tlsTT09!3g9+Vj^yTR z>DgSx$IIDd#jLiayj|}5Vdo3Q_p&P6<DIt+dSB5}2`+gH)q;%MHBBG)S-O*A{<ihc zoq+3|%{8iTz;3q!c&#-;+?0TP`Kd(sduzu}&4`E1ZWceE7VbS>Ec?20=mfR%u;J~p zh!a)tyRF~y=_{D<tr&jG<gIIkBA;&C^sZCxxTR079Po~yZ|TuF=i)=M#;5BC?rals zTXn8pVp!E8JHH;iy`Pk-XZg6|r0QkIFZk0Xl{bN)$T%0mL*7@rtM6U!8UuY2=lA8b zl=~Gf53TR+6BErF*is0+owRCb4OW0@2Xoc$&zA$SQ|x+)FdFPc+~8~>>#P!fN0VN! zm@aa3F`wAR%!!9ES<D9sy9!mw_G5fQ@op~^t=!l~W2No#^l{rnqx5%sO-V|N=@W`P zCy#F+S46o!Z?Y9J)EX_^<bZ8AW~bd-PqWn`jz$>~!_=Tbw&%H8-mi;fR{$$K%AY2Y zYp5mBu^b?hG+f0z7x%kfpTY?YS<Bt0Dnfo)<j)VP$^;K_e#WVE0$E{QAJlsnHJDiq ze<Ku_0<YE#%FEEfI><XsG$A7$t=n6%z47g_9q;fEcG8`c;;UUYU%+61p>R9yj~oZ` zoX*&zib>ZeWlo`_b)GfRm#*qH-yhr0xEC%!YceDk-%*1NiQql%@%|1U$pe|;^I{j! zQD5$DxBmTIV}HWC_V3{PaBl8L>P7a}cYkV0dPC<M^qlMVk@pR1lv;=EfsIJRZO1So zY!vZ6tItAulMj{7v+g%PE>#9sdz>=x+)98quobVoo;1n!hgxmoFt+GfO8aaVW&8dC z=!hd>5b8t|X;;p?pM>b2v7JsJD@5vpW+wmASKC<<%G22B(L_EiQcmJEd<x9+rbtxT zLBG`0c?0`~OnK78$f*N%op3efcYM#8;s+RD!EB@v`|)mkXxr{;dEEFO-;-gv&|)4A zrD>ddmS>BFHrCJsGGf-IYWOo>J?<C$q~|j+-gh6Z!T3S~y!P^^^?rg<D|J8FTJo9t zre~N{TI}hlUZdH7dL3+O16^=MiBh(s<&2t6=G>I(X4$60<;=RxCzC$VhPWO*W<{s3 zGegc|mvgZ=7=&xL)rkyPfjV?SZe=esDqxps{$#GvYu$)X%6(oXl>Rz5#0BVye5Zul zhOUPL0Ks{C=>zDXuNz~NWCDv;rv8y14>V%~Fc#51f{8G-S@$s5&WfGL3c9rK%44sy z#rg`NlB?O6<3wYg!9!w{r;hMk^4l9<eL=y;u3Gr17;$j+)7HN=<26~4iF)&%xa_S! zvP&aadtf8!SZ@>S&2FI-z9~%9taljk!pt!H4yqB5Df$DCoGp%BMUvMC4jw_^WJv+Y zo>jBVpX9jOM5VrXzdk9f{UjG%0j{WVb=s7h94>KFo2A7pv8Nq08V^T=8Z0*<07j10 znZdc^g)4<jX^GNBlV9na>+xM7_J@6T8uX})5phsmSCx88Rc1qPM?n8M*W|s01<<=4 z5Kfx`-0?HqO;fI5pzkeSN0Vc%b(9^$|59#VuVnajt2*Am)}3}aX||dp+pnR8lbPN2 zZpa_ZxjWHD1?CL(^u7!I3!<OGKHA|-ig!MSPgYBQx^cm6n*Fb2_*b|!>0Zy8?c;DX za3FNLXmPNFb*OKcnFhHzGl%$9lTrL(L#tn>k-P_f!S3o(GZ$<hOa*y36K8Xvqs3U% zT?VpeCdwLWP!Rd5P|~B~I8UNh0==MA9@b@WzC>lg7fG^S_Wc#T45kB~UeOzx^*{=2 z5G<-+_0=k~pRZN%2KIu^+bXjL^(h8|%PnDMH;hIzQtt{pLD9@K|9{&1(q_ex>`;HM zUqSSIm}%3L&<>6_4vQVJ?*fPYMmySfKs-<X_9uzuA|Zh;MOF8Vo2ZJ57EWfK%shGa zqmmV(IaJ_@j*ldzhv=;};lU%9hl=ESxZEiw(VS>7Fz*kWWUB!jHl%zE*de%ATaAu+ zOv_PML*KslZ^sbo1sUP@yeH2b+AJJy)9Q!>>>)fl7RHRs;hjdqJdE`TgUZA5%x*aH zaON$k4r#gjxxTX6<r*k&Y*8ZtT$RD5w(QpYl?#f8wzAs2$OpzF(mo+2|I>$@nY<mE z80b*Pr5pQ9%J7OmLIQR;-1wb5eh6S`z1Pdgh{BXPUOSkBjxBHcvm;m0^&FADro<YL z{6SyK<$r}5P2u@_o=pCy+z12TQhLW8&Zw&qP^32NF}AO4JLP_3r_^@buIDMPRKyi) z-KtAXLMe(}xUtf0pElWYgZ9d(C${H)SuiG;X6XpgS?AG}nc1N}uO-93UBo%l;Cr=7 zS*f)cz!f;G!Yoz3U7e%tw$mQVq}?YL<`f-oy7soFcj@VTGL<ckoH^Z|G8$teqT6C* zygjm6k7H4DC~t})zl8F*lzdc?&!Uf?*Z!PgMkt8BMO!(CI~I%9#RX|$9Z10j<PnDm z1#F?tu&P)0>P#j5roP{qS{3l&RSjvvW~bJeLo7CKN;7chlRFDy7Ka7V^~%k*P^lk~ zE{ne=<E49;JZ75}@j>j(i$~1~W{Aqux4g#;&_r=!tr+|SLM`PmkkN515Pe&fp5y^r zoL$f0@&+wV@f9uA>ouWop_NS+;ATAC>@n5Vl3b!XP=+UadkA;=Rkx+8yVsO8_lDAR z^qumsmURB$N~}^k8@k@ek)<>cA~xlA9!@RtrZv39$ee6l(Pl<8h?98HJB;RLcfMZH z?J*7zTVo0ri6Q{<RY$RpyxNukjyg8i{*F0#OtXcpbjUXycHWbEWUHlv^s~eKQ5O7Q zFy_OE2@w5?zp|yTa8DRJUzASZa%jIM6G`DZH~>tcoo9E+ndfdmN9(NTY~P%&nj^KN zAK6t$tF7%(d*M61{milJm1?anwPd)?*a8XYREr~dbF{SAV7uOVZD%JUJWux7c(Kcb zEifffoz2t18`4=K#J*NCMZ%l7zW3?ZuTaC;xO~s2U9Yryl1#Is^;)6uz17>7_cTh= z^{t&lyKXvJ3AW<?75T@ZMk7#5(eHC)x?A^p+LBkRm0^9frc7nOur}7VOm8<l-xD;+ zk@{V>x#1k9xMKRdG9&_A7p*O{jo$S~JU%^c+&+D%fV$2=9cEXD++!{#!PEV)O3!=w zr8CeF2j{POxg~1qOl3|e%BZFmeE@6sI^zvvw}6TXtwp*_j$O{0ch?ZbqsEpTH>wWZ zAj$rCXI6{DS<SSUJATJe8=ui-h}~62O|F~=5mpvu!Cp$EWrYOAa!Odf1X@FMLr@6N zKag6hi0_9uVlEn(MQp3UUf*#OR<^41jm+<M)N!^ja7NJfRnVcWfqZPwpo3Kf0fQSt z+zMEYRNR_$hK+WfVMiN2YwcsNm6ncR2E#uQlQWbYJ`$p8`LKdEixto$Dozpam4P|j zsMTBLO=Gm>ZID-Mtz!!xVYE$=;?ehj)~Z+^9a=kLMUe(MtoFJaW)Af!)l>H7c0GSh zcbP&<!B5lD*qIf82!n7l;+t>C?%O9K0DGMa$;m$*_PDMHfVQf+J+_L|{eBg24~<G= z!|__Lyi*969Q0>fStV=mScaXVY6@VFt{n%$#3r=uU{WjVAiDr&i?-P7)#`i&&SF}V z$lyu=TliLn^8)mQis)-TC8ORy7&IjpQMJ6<6NueryD%_jWD$9(#^YUfp%f>rOwZ`h zECVOA^L%K69<rg=QG3}LKfVRA0o+^MdS>3tni%g+W*uB7+fJ`MW!eBV=NrdOi>^3Z zc>;P`akigKP<G$*%iMNGaU-2=ZW*vXHg}UYvc+5eXo)pz*jind16gS^84}8C+y0^J z<IS>sifEcq`N!qM!ioI6zA^#(jPRQ~r3mhGq`MQhM^sl`Vq0s$#buvxcz<AR_?o;b z6CKhxjNG*~TWp5pf%clV)@PO))LMalkp$L6m0Q?E9j<ogysU0k+huo8@0H#&F)G2} zKbZ{Hu=$ebO6r*%{q@ds_NM6RPru%kcK9d^mh#gKq3i@E?j9eesAD`qIQbs_iYCeY zDVyE@<@k`zvCqvV-ie06@utmRavA*^H@D=_O~yNtrJ_U=>AUi;tsD4Zn)HvWsOUQM zTwxh$#5riOsgVtZQrCE!ArFGntN{A1r!1NaunkvO(2<7NWQ@_(@w__FI<-n$55&Zo zHXvt4tI{8JZMWiaz<%r+vhN^mtSDxOVa9H!36K$XGxzC(AkEjxBwc`>cV-l*nX?em z@mMwqWi}pBlm_mk=H3@q-SKR!u(h?k0uKvR2FThLb*oIfPVQ+;s1|D^jV<XKBo-MI z^_R9r9WBN03&??9tq0|<@}eWajTZIda-D(0Yq6w~?dh(hWhdMO;TO`0rZf<t_U>-! z)WCBz>vX^(9-;Q6Law#|0JQNwOksU`vLFT~r0y8d-tG6!V#)(cYTv+?1Hmo=;LscH zVOp&0AY~2G6F@Z3*-*!;qbj+;{X90Cq^bISj$ARw5qfT}^SO1^DWWf^werAZ(ZL>_ zQ!Q&!g!oqL_?j8o!LB)FE}3aE7LeufneLp>*GlCjd_+JaOhn&GCqOyGFv6<MY)NkS zH{77S+6<kp-X~3kG?YFLQEPc&>b0`8cc$WDi*q%sKC(Odyf)kq%gv(NX%OVm!<9av zH28J7a)bb)ynV3%(%y+Y%%SMCC`V=9e~CRt&XP$b{)7#tUgaI<{5voa0ut<OM$&oi zgFQK&MX`W}sCsgQ=3nok0KyQEFymRkm+BW+RV;qog+`w%&-&{f&$^}U(m9^Y_&8K! zy$okJ8b0lM_T|7#j3impG>t=WZbn&79E}+%aKqjtTyJCfTEYPZ$9pv<4c-PFge_GQ z?8cqhEhWaoIzf-?8}2!f|4tt9Ke>h{hP9RrMdHsLOq7vxJzeM3k130i^u!v^D0X$X zS%ZZds_O&U*LdIr_KMQz4*Gfj#_r`SpDnj%E>#^2t%FZ7(y$2>1z53Y4KC+M9C&F{ zqotFOrqh|H+G_<^Q(L$hZR~!Y0<970>J3q4(D2osr*emNf3^^8#z5!Zaf@uZBGjx5 z$78AtX&YAum)^8FnHy^!*l;QtF!iukHw9X1x5_Aw*D9;BL@|?&mdDce5nY;*DC?E< z%IDW2q?}@!PJnV~k#uxrFk6H@F#V&~p_@hB+#cPIkH7#^EFuGJ=CoUNNUT-7^<F5~ zD}9!>h58ZnbbK*iRYt9eSe1tI2055)YuV<R#`r})gj=VTlZg$>+F7x{t#?Z2AAoO= z8D8d<&rJpxtToDU3B`A&twY6>hF#EYw}z8$i-31Z6K-2b(<4Bxg^3*#DDK3K<<#3G zZSMTa5S|nf18?njmNzC@eS=TeK9Xx;U1HVJcOL%AvWh^4h={(FA}Bem*ejU{*v1|_ z2S>A|=^iP3sAA*Y1h$B_+iSYZsXX=Qqb&5{+5zReNV&S)%q(%(C?boYt{wYJZY)<@ zR*M{tt=guw<B`{lj)~C9)YX(ODaNJ5SJa7*B*c6g-c57AXfsO{R}63CfO4H1^f|YR zZn^HRyx}_{*2k?e&q{;Mc2fjIj(1kbUYrwC#cr*dren%YVon?v?Qy#@gk)0M=gNK> z_SJrjlGpOG+yXx1<Z_ueSIc^1z`Y7IYv5DKmBIT;&r|A;FlZ|bv2x7zi`Os6A) z6h-kn2Ia^u?wbA(A{vJ_J7GF)e8>9Jj#6fsy~R#!Y2oHVO0uMDe1*KSzmla~(R};M zp*^}G0OJj}6z%?exb93{lcGUsD)m^JXQbW)tdX2KQCA&Et?&55griW@(Z?;nhfj{C z$5~9hTehf{Fru9f=MNk0JgR1gcT0?Fuu8xJzV(Q|1stK{<1$~x^;)Y)i7qj<P17K% z@LaUXhGLJ`%9zbDth@S_@5|?wfE^AlekWgcw`tFAuOO8njv7f1M#4}AJc_rg6+XQT z`xCNw=|kkvay@M`G_=W=-zSO3Am5-Sy3QwwLrTA_mK%gyhkV~;jpe~VC<AQ-SUK$2 z@euC!c|P614M+8HmB#}LEV%+q$cJ7B+qRIkfz~K#G4H`cg=yzVB=IyC>uW)uu`H}N z`B!rUentuXWRW&KZKX1Utx^+@b9}9^=$cy05v)~~dR}GLrmQl<?#C#11h(a|Dr3A( zTJjOxFczeuE81G?_LAAJMyr9}f?Eili)w##^<2s_6D@(D_<0k<J^VO+&Nol#=W<vY zc){;a$%c(p8r5yBHtdd9EqQCUj*IEG*du*qvfmB-6}pf%$MxQ5VJfm73>saMZ2GO$ zVO6&T|Ij}kF?S{`TGOIJQO@!;wdVO;zGg?bQx~LUvdtnPx2X`aLeM|2?)(57BK>+1 zg`?-tZFU2pM&rtp6;O0n7EABEme^ZQ0joRRk;=3`CL1l<pxl0cK`+^QqgO6=_|{y} zCLI~(O`BbB*`hd7%XE_f_qerD*L;>g`ZH5nu0$c%G>IXy(S(KlHiY*Qo^orCi>I=P zt4yAyvbZhm41dl?{ErgPKcK|3V{(Upp|C@>Pv%MXij(>+;AoG1Tt>NE^TgQMP;*mf zg9ExYoZ>RRI+9S!Y#jB2;)9MX9Co{P(?1@DK7*+nsxxY6O@riH9zuHNT2+MLNbGG) z(l;!L#7&U^EvxbxMT@%6AI#uEh?W~=!+kNH@YQp|u9Cz(t(S5J&GL~^?NN!?7boEZ z_GKPE?&OUDg{TQp7n*8Ms?O9U1J>6x*K1HagO<l)Z8_EfaWv`M^IeB)s`PSe<C`X9 zk@Qq2`^zCucM*2bB*bN%uMK)FY_OU(>REaC)39@g`1d)iq_*&Zsrdc8-qULlYrvE_ zZ6Jy=(&i>7G7G6mwtC{0?37_as)M7ks-jz<?2Is--$JrAZ7e&Z31R^K0Z*4*v92%! zk*86~1o+}WS^2Li$L`lxT9NTr7H$0ftQq-yLdhiX%VgZ#ism6lf=RO2S{*lruaixx zZEly{S&?dPVWl;bHxvL$Rk2m0R};2Y1YFJJA#35xYDCRs57t2^4lPbvw3;G8fsDLv zPj=mnW*n=z1m06UxRU&+Lgp)c%LQzNl*>gV@jR{hSR2tZ23i~Hd^sL-#IoC1AH5c9 z3Q~@g5{|PqvnwrwFG&U=$Z#Ct-_i-l^C|66l(k$~c+q5geBZJ*GNyG}i@}a^N2CjS z#^O+}nynR920=-m4-QthQX?wkK^4_}yX*VCJ*OXKt|j-SCf2KsmoC|T(RAqO;7=zz zR3iUYqGI4Z2h6axZw4<g3MZt$5yoYoD``b;kqM(5&$6X+P2H2lEylBnynD{d9x{Aj zGCKL@XLmk0_N@sFO7e5=p66YiX4MM-B$GshDRCpeqW2bwy@4C9osX-$rC<khsyN`= z=%QLhSo)~Q98m2I3EFfzy2QwXzAjJ(rz+GQ$H-<tiWk!GXj>9@G(cV(>=k^EPPS}S z=8&3Ro!1y}(AwuZ%OVSCX)ke^$vI!M=-mR2aPo1P*Bx9RSsk>>@pY>@n|9QL1rqxT zO6o4M$9lVd&sr@d1v7~1Mp3E$usc#M5otlbJqHI%dM*>zZn@_KeuM9Ey1pYDxF;&F zNi>pE5<FEsbw6@xHw{U@&6aVyVx!WBVcCVBE*=n>>oMUzmQ`-%Rs3H-UuWQQBPunM zXAXebR^K%wtkq$drLdE1qqs6;sdd~HoyuT5=+xNbk{=5TvqARvMt@%3x?mv2?`w5N zs+c6P<C{%RS33UKpN|3UI2E2|c=?>KV49QOr-Zscoa?SFzs0#Ow*KE|&inv-Ud^YA ze5p39CO_$V4!wsYgPlvv8YHE|gz|<)dM<@$r)=2phram{S9((i^^F3;1?m+Q!S{SV z?cL+NCYuLPhj-j^2k!*amcg~G$!;DU^GN~d1T;|1%t(g5l&?DuIviK*MhVTApL-%N z<vmArU8GzYbS1*7Q;4zXIpP9pT15NkKx0$U5PGs^WUaVquA1x$nF+1o+(x{?aHG*> z-bVyf75lbQE7MeYGB92{G`4hbYN+&6r*Su1k%)v@^gb`GxRDOg4V8x{2swfoyOrah z)m(Zwk58AZ+ymQ-p#bhyMXXkxPwSgiTa*OUkp?wkx1TqwKyy3<aJqx7AiKDlLLF$` zp;)_4!qj#ux$EY#C%mTE_>WUe<|R5Qibbs6s<R_zHmm{>W(F>Wae~rEeWMu9%Y;t- z1|yd=-rXA9Mbb<%zP7Osc;nK=F??&EomtZ|Hg63@;%NJ)i@#LD!7f~?AG-OJ;Gt9E zV^#f-XJg5SIY|(%Y(tDi=ABD+Xy~>+Sm6}9AZ0Kkf@<soN~Hy@-ozsX99WWh&rsUJ zafAxaB}-3~Nt#PXlHloVcw&@P!^kN981rR_CsfuV8-wiJ($?GO`Xw85LTQ{-ImRB{ zq;x({^EGGwUH9d%aE8g#%K333l=h~+RFup);V&3hYsa3Q@}dVI@8ZR->0M8X^7yl4 zV!*p+=d6lpit^h{l$`RI79CGSHl%3LGwda?^`5Xi-3eVOOCh9Fn!#@Aa|-RNt7D?Y z@V(na(05r<!xyeuw(n5ovW6D?JVQn5-ed&7!(wp4?j$;l;t04l`)1Y0-*QU2an62S zNjh>ydyfrH>I*vYEThDoe7g@wHGe7+PrHUDvDXpAn!g!2p3I?b8pbVFKEWLS2SYQw z3PduGV8^{7qZe+DD?AwVEnx~tYd}xb2w`_j<)=*w=dNreajORZ-81>fwl4gVG7S6i z0Pr6$fEX^r5hStp@#;0y;ru2Z%PJqk3a^^{Ih)&~_ii@O{b)a4b9v2FFQwNX!E<do zL|~2=uZK_STbU&e;=b=^#510FJ|w~W$DwOCdO7CqA76{XM?Vk99-Mq5UNZ$wh<$}Z zyt*!uu=vGj<CP}H*JxrLWo*8CSn+3tJDWeA=*hzcd~W<MdsNiJygTZ4g+AI=$amjX zPZpT$1oZdHINVLy^HuS`Xi`taq{Mgu9~k^S#gCsDvfuR_^UepG@yP6)IpQnhsy{pF ze#B_cof3KXqhs_%ZhK5@bCd4`LO+SG)UN%$mdGbZWU8Jh>324Q`?1_*1I#s+96fMM zRSHX~L{bpPvnn0XS1Fda_8$?mkFohf`v2W|n%o$<VPPLJ)32<soHz-@E%l?S(jAkO zq@;H&knEIPL*eyHe&-~y{lsB->B^&X5K7b=dWw+;Sb2<@=xL<ibzEQNFH$~q$1<Gp z#L^~z4kS$G)Jrng(J$^)s38vt$FUb-Fn)9=nUO3-Y#Q>=yQTD9k(aIa%otnVZF7}f z-Yvg9Z1i*>gb95NhgM7H<Ue*8TI`r%p#N`9*wT-#i)@@B2cBMbeBGrF>4W+#Rf~iC zJ+O<95%b!({^92Tlf%50A`Ezsu%I66dUiZQ=AUYizaQD=fzXvl_46&;Ki*1ST;3=B zNJAX<{ScR)fh6)Sx`|_dI*uE@@V8w7cZ$IW^A}g+y_-S3;edZ<D0!c*^iJ5%^`i&U z*{2k*FRDqOs6Ioh8hx>|Bu$Ue8!39O+>0WSf;W2h<5t8|k>t4w&oxQ{9h}=CGsoMm z#D74`bA+7i(kC1569rK+3)r`DqNj#a^B~_f9ERP(Z*Do6DD<w;I|Kc@sX+<`e)`ut z8-n9pvmu^>6Q0g#B<P)lxJOt;5{CXa4=<{<A)Im{g~!)T=H(|{PlmB3JDxP6e$#4* zOT}4D-pk7GRa`{d?`$qQi`vz^Qyu;IQRmBd=ALiCmu)|;DFP*IxZl=Vz^&8j(-m>A z?)jEBy?~^KPBstM!y6l9X;lqQ;qZ?mJ!IKl9cSKUc<#ZcPLOl&!`v{xZO`K<{8axh zgZ?4wi=}N&Iys(ZxA)pfn-g0xsu4yPq?m(kp5y(KSIDo>t@rT*Os42O-?3>vF{)er zW-2q8qN&91M)wIlZ}#z#96gdq_x2P653ukU6VcN&#_r^~m#Xu<KY^gzB!^ej#IBPH z+$504%J1Yc@m<jo$3v9R7I|fGDJ*hwWGC3Kk1XDc=etfSoxT2k4E0i_66@K{L+1$i zZtJ~SN8-3)GUaPOPA-diNL0}Kpdp=otQxuZv3YC%oiM`kBber%E*9>Bm_l-vi}`=F z2ji=>`jSZXDUSBC-@x14UeEfTLkfMHESTz{mECgEZ|l9QA~iAhi|0~y{7-UJ_c1_E zMwW%wsEg0%_$tq4Z$2#MKK@M;e9<js3&G!&)6zcTz;j5yyk^MH#ox+1$$5sYH+u^t zEx_N@wrNWm{cv{PC`*3m+8!O0ZzC=Ij@RALp`dih=lh7Fy-hy<(3WO4cNgURO%2{y z#(#*k91ErRjYN&O=k;S1elA;kE)dyP%+t@G*u~QAgW*q;dcZ<bs?Tt!No09Vag0c( zbEjyRNA&-Di-{lF(Gz2J=Q?{;b6o_X<ntRPQ3eP1;f<93_?D5rFt91_+_0+|(;x-X ztd#xuTzcN!+J@_1OZ42!fx(MmnH%oXR%)-)Ye3zt3p!fi0e8hp>e)b4{t6)}Y;G8E z<$b&ZR#M)1lKkrQQhuIV<#qAAtW&Wb@Z90%R3)8%@KTt@?AjcbBHaJv8zNm&Y2WZd z>kJ<n!9SF{IoRRLy#7`?wX0y6TbGudQs9Ri4Y&S#k64N~HhA*C&z>RleJA@R1mrhT z8io;qn&ezoa4uo=YQ22Ge&b)kw{evBr0(5(e@3%6gfn}ke^+zc-LVFzk)*_-lNw7D zr)=oAc)>ofMBbz4+tj16CrRC1rdcuBi!`0_+j^0yI!pE<ZCXCli%;rCQ`Bj9^gbHT z!_j36ugT%zcVgD(hWD@=`HrAum(m!gw{=Mi=q6hdlEDtiJ|yeGytNO8&ZqdbrJ>;m zD&=nwlZfKI4&&jV?iTL%oZ?T8?E~TIY<cujI%oSS9AqTBO2a@JANw6K5GM#H*S}QT z(`OP<#l{^wrohjxp45~+X?R0_tmQ6|hX?um$Zk*YXR6;HJ+MRoO6J_gY#(XT-1W^z z%t{Kbaxks2TFKd3yQDb#R(>uXixeTC@IU`kNQp{H9Yn^N^A00dMtfK3ARA$C)H>ee zD|uvu{EqUFPpj%h9QvkEu@69xIn#G?D9_i=V?FsB71qhZ<3B`VOJ|23)5bST(>JV7 zPXC%%`K?D5npd1w(_75#o%_mi$cd_y+Vv@l#OL+v&&^y5(?{upa(Ship6;`!EI990 zzNEHy)5!<k$?r7cq-bojy-Dx%xZiuaQ<M}rr#qLrI#mb#bWwab$o)nNxexQ{Prv5m z3Lcj?PWC@h;yC{RGTKg-RZO-AhV6Yvggq)>_y}jIr3{muf2$(<p<w$19j$JK*fe3` zxd5Av)7u^QVD%+!LBAt9^L&WOVsy#z#S7BqA6|NEsdciFP2L;MzNN`qgWK=M<u}FZ zmxv+AHlk)KA@0rEpJ4C*@DP3g<aeZu{O9!$PMW=cqr>EGA11R|UOOAp=p+q|pWS-D zx!LDI3{$cnX&8B1KmLjIoq3mhnpXTV#eFY_p3s2bdv4}BcpmQ%EFbHiIs3Qxz<$7S z{eg~q({g&xAEgC~+ZDen{feak`X-HEhRbAfJU>|F7fVH)DWfG56u*1R+<DF3Cnb(v zOeCyM*(WKPlXKzV{F_G#w(q#gZhD-|#hKpYwDA8Q5()H?UHTEKzGu|*M<C_J#XiZA zJ$Au-l9m1RPDW<-=;4if|GiczpR?h!1mMw2o-Rcv!woR#PSXA!j8Pg^e>_8yObh<m zUVIxv@`5kS-F!WhbADhNz#C<De)Bq<L)3dts%|nuWNUpY@6(FJ9eIBvu_q;vFV|6& zWyFv3Yu}ZB&81#R8DE;B@EOzkheqWOjmkfaM&&7s_+1U6cd6<^-zqFmL_tPGLiRXb zixK{4`^)X$o7zzKwNWm8$WHY0i9%5c@aMWw@tdUxdX6Ge9hGo7ZQWKI8*f#CCrk_A zSOn|i?663*xBU%E>lECrcKf@-f>4WX2+&-Q9gb%d&(760fJkF-yTgouQFaGgMTh6k zYsI&6RATzbr3NMIMqR5gCCfiNPWT&xaZ}+a9tav*kU5%BBPcwrUAqu_DUI2^D~FR^ z?Iwi{{&ek^X92-s^jY<%#7@k$?jp#+Qj7kUA~^ZVATo8lsoES#llqt;#znAcxa*y@ zaTu6qRdg?5H6i#<&KK;^*qa!;b4;-;Q%8L|?=@r%XyODXwrWeB7%vAyw%2w#1LB*j z-JgV;oRL50#q|kixx82n0Eb8o{*)pp&v6Qt1Ye$ED6Tt8i^8iCi^}jAvc?0?u4G~* zby!c_pzfsUoP*NBlDb-06+TIVG6u91CC?W2#7^6r1XmTbb_<dD#!{__IR=zTh40io z4^%y$A-^ZMXR>>`D4oDPr?(b22hmQsVUS%3KaQ*=)zGU{S)2{93MmhLa1SqeZ9gZ~ zhTfdZjD*cRSGTm9AU8;2ue4@(bx2lmanrLTzFgka+uHH9y3=`-QI8c-50p^%vytE` zvXxGsnTinTc_PBEQSs&+r{46y9FV4Nuavb?297SPp&kq@k2>SGNYkfAAjCClo!&}n zEDt_Df+l-xFtzt1w1cho<psLlPS*fZ4}P-JTH|eP!Xnmdr4!RNVhQwp)Im!_UpOtu z=h1ft8lvy~H7ZAn<fzyQ&n0)T?4i}6-xDW(Yg??K_<l|-nlM!D9{UY`>y5<)qPI}K zA{LvANzq?0^1=rJ%oC-dP90ryJ1-7(ORZBuZ>wWCqxSU^^hK0Yu+MsH@K(Y|;4qYx z`2(wZToxYDSpD_fc)S4|;_~LQ6hX{UOT1_tT!*i>MsTy?5_G$ROA;@`^_p^|tk!@z zT5E!+bH|=1A^e6YnilMCn)~{8H{yl@jUNtvr6w?%NY1)80<(3X2)#xWVnrU|Bqh*j zm;LZrN0J;;$yCBn!BlDb(q1Vn{TY?UyNZy|1H$o0|C@bU<(|7c@Zk*J-Ap;jQcf|r zg_?4|+)=bug)I^=XS5Y`Bm(Od^1MuM&}hV&mTX!Vvlr+~M^+5<X@EC3B1s{~$%Ua~ zTsmSD>NjnW-Lv9ua$uP59$zT1IPy`h%efoGZtVEJwGH^aaj`D}odf3jz4EZh6rpzA z*ZKN@l-ia}H0raVQgL3RnUYh|J&n2MW`3}IJTWvo8j6&K)38j*3!DB1aD>s1%Tfd} z2N6XbTLF+=V}K$n(jg@SriMD!gPeN1Sf5nd=<0|uo9%RC5Ij(vALLaHXsazkUpE<L zy;MiTYHOeXLKEIX)4n;T3`BhmpQdv;g21m(Y*)wBsbEw%?-SBU4$ornt{7k5DYyU+ z(0}<FvCv>1j&na;X(OLqi-f&KcxP<RXm&dUYugs`GRJveaWsq9d0`JHfQM@?aVz3| zp6p|=G=#umk5i|hO!pYr=wYq>ZoWj?t8tE6;veNw(?%8+P<??7Il&AEboy3`;5^?y z(vex#r%SBTq@Ct?QW?y;?b@(c<yZi5)+E_m6U8oV4<@V&PTfH0#3-}OP+nbin8i%* znIc-=8bx|U94fqyvPB;mwO-R)&~|!)_Xnk+HCo|I!Mt6o1ShHsKd99kE7j}kH=KF; zy7Y9NS4*_W$Kr(JW(n+-!}A7kIDI#lr3m7)wMb$VZ?qlAX&OCkwSi~8(xu0Z%4A%A zWfl?{=KdRfzzptr-qmR~OCSk;h`dt7{Q@>b$K`wJ1ne0yRvumBfc6Y*E+v|4c5O@n zik%5ChbB2Trf>3GB*lf|++AY4q&?_`k)<>c4l?C-DQe;Q{ylPDg&GW-4c_earbTK! zqKM_#U3pSj^~*!o*e)D)UtDN(M<Q19%GO?jwhaIsY*{Qfb|gHSfYn(QuMWy8-502e ztyQ3x`H7E_Je6f{%R;AP7=MKhUcsL6db%h@(4J$HfY8GZrRpwi_xF^^HinyHy}esO z4R8hn3{kgfcU?O`4t=PMdBJII)wQNfB(~StnQK99%_@?B9CaQ&&QZlAar5ZyGN@q; z9iFI4f?txe7;`vQ+#oMDu22JHT)#)S$iZ3RZg;357yz5zf<U%)rMET^igTSJ*`Sy8 z>SjD;+ZAeGog(^n1c)1PF@WdIp;hU&kR|OZ6{{|Z$ly2z*h(AmpqjFrJQJr3Gps2R zxohOob!!?OFiodin9x@!p^1)HuKhJ6rx~Oy(-@y*I$oHB80c^&VmBg&<H>Xcbj>v} zp$Ja5HM1tky+LK6b|gmxCEIz4RgE*G3040iyM7*qHCKU#l)$H)2>k#bAoJs*6hX|z zw&DZK<q@c{W<*qy_fx~xabH+1ho98^{<CuCS!>}@1jlQG`~V*e^W!2?q2(GVEpG*{ zyQr!&P^h%ZBgrZ*NCa+=+3dN@Y1??_;&Wr<NT(^blugh>uLJ1wv?Kx<(vav&DT4Bx zl=s%vmaR#)rB*=-nuxOPmscFJF0SXC&26^)tTGQI7=`Jt1fY%fhGe6@#mrtG9c@^* zxk8HN8cm}T*Ml|_ui2mO$4C7|Avx|@1ZMFEVH(yzC^Kz7k%l`-kY7Mz40MRh*o}xF zKS3&3nohu>FPM8+AL#4dZU**xq_}9)jX~v8CtQ5co|Gl<hMB=$IC}zs;Q)g_r3k|F zwPLQyLj#<)JK|9_JLCw|ou%FBnWJX+ptMEsP%G}r8;u)w&=J8C`y;Wm>v|Uguz`Ch zE_?@*XkR_h#Re=QG6r{hJ$aU~R$_zS(W(@tM=J&0FPSu}1Ts)5j33jT_p0n4H54H0 z(c`?T{f61opoIh+hB(lf^y;p;IT+JbZM&&%%8KRsV!%1o#o?r~Q5*Wfn`o=8jAEEv z5r#<Jg8@=wwob#q1(qN!#Hnr}y!o0`?U>x5#2R+6xYOeWPH*ssVEH>CVsD~fAIQVI zi`1RIFTq#z$S0WL6hvQ2Cos=;;%HlA4XQS`L28BQjasoTwMDNzGzsD*ErjEQ$=*%X zb8cjq8+3&UeWPNN=L`XHA{4y9AKWnNT6Zs=6i_A-RV!0;e#M9qzzeabTBUM6lSyML zF`GWtaE9BixSkaELvGdRL$f~2^v3Gao=P=qiTd6^D;5p2vO<)0%cUnm-9dUyQZMgo z8@99TkT7rfd#X~czzS&Ok$3i6iOpiOp_iz71Th$W^fxj!<Tw~>{VqIL!TAav?^L|3 z!oCHsF+?iTdvi}&PP?{VDT+04b%qk{L8Iu)xV>GK6|dPi97%djwdLjtHALF%4F}EO zzbrAYncyUcKRh+$oCc>EVO;bB?0tUg-2%QM@pPHbYy<I?4m{#;ZPG&wOvYx%P6Gi1 z4eJ;=R)b-4p(|_VW_U&Jx&RG_bN*T?=aIFHDn&Cxir5iEw+wg79#&!S)u5$J*c?Mi z@yN|isFZsw7pUQ2F5e@8=lR5p_tjn#o-EOMaZ9ol+kvM?gdD@`#Y@LY(v$bj*WnN8 z@$%beN$NkH2stIJDCej%+6qvR@g&6uBm*BfiX2AmN~5h;hMR_s^sDIP&=PjU!1-1Q z>|~xSg@#HxBLU<$g?1*7?$61smj=#~>*X><e#pRFbG;K*$dO&pJssVbw;fTCoW6Fb zRR`aSxtock-JjC<m{Xq~#FgfWyv~`+{|_a?%Swch+MBm22ESeYJ%K!*B&MHF-gRe_ zs(i$2mP{Rn%DS~9%9Eit=(%RPyqg$=6v$Jdw@R=Y4NYP*#uHxx`Nxxh9t|yVFJ&>L za)jh~=GtA~Uy_(npB(|L3JQeWa(Q8cSw&%txms~FLneF7D9+oH!_Wke(i$3zvmym( z<z;2G+HRx~pdp8uTpZiT)ZS!S0G@G#nr8?9wwKz@<wX2KrorWQ=RGNlkY)2a1tOy9 zT&NFL^o$uqUgADOfWf4Ne@aL`-$T1P12#V80hCv@KzFU0PQUBWaFg#-lu};q)q^!> zTT?--Hn)RS5yTb7t+vZUTdZr_HiPcw(AM9Qo4(L!ABuPpUC2Nl$>ly1V|LcV+~YsN z3{i0U7I7m__hhHmLA&cpXWi8lfm_Uq^Mj_*w9#31^NizxBPssUAR;HyvjZufNBpv= z>1b(I%MMe4DVH#;W`!A7r+Y$~&o_)GP8V|xUGuGaO&CtcO%qxl=e)I&j<|-7M$^u* zxw8qtV%xLI)&!cx!C*RCzqZ+)#mgji0Bst^d;M@vAR`2ZU-J0if~BfC_BFZ1EQXp1 zNt?EbZ4@dHOIJ`1smrHrF-tuS#w!uzA4C8$8bk26bOQ2x89+S0^>m;@^jDR6-{`9N zU`bCGwpjG*I<I?`8lu$H=|P6uWV_K@fFlui2Gn?{fwi?i02?Dxn{SXcKLm#R!>(AN zNN4ey6wa!Wcbg{ohEfWW&RyIx?{sJ)@0QNxkitXfde+Azql@n*Cxyy5!@iUb0@Gj1 za`C(+??JPSYOu<s#MAv7&(b6(bqXmk&h$RT8}&5Lx6wNAZRWGLiF^0qqTed+A$PKK z=JEt-lOGGz09=e_*1l|1yHblVcFSXRfX={%SVZP_V=oN&{RA@sTN`*hgS)GZJOS+k z(l>mNuxp}dSZ!0VEUt^#hR%uEp*N{4^krdYXNr4OG>jkz$cg@@1iWS9WxVFwv!<qX z2H0_D@B*~2%*RL7)`uq5mFJSV?%|d4+SzN}adjsjG!9!sG+eJiJqH7bMP=BLH=aoC zjLIH1Rs+b=_tdwCB&DqQ=ds3V>5T4*oa9Qtn^W{m2`GPq=n3av)jL{XcUVteZhABE zSjLP2(81b`noYRJ%8uJkXr(Q;y1Sv>Auu2A)LUS^tM~olq;FNYIXRwyOtIHkSdA9z zD%^C1AUwGL=Gn_r5a83r0G<{C_y)1{e&u|t*cw61H;D~z>VRU8saejT*WIYLAna97 ztPDB|tDCZeF2`CQ92483M!@AoxiL3fp|L4*&|=|G=2#nRg8_-Ha2y`c1WXoHMp}LQ z7JQbi>-A&?DH*rFNrj5$-!PLp2uMQ!0;c07iOTC<rPg*`89i3uzBcP=J7#AGJW0L3 znKc<0>h+clvY`TlkqZsWptXQHKub9`>FT)W8eq+8$S#LZ-h=BW1rzcWOL$r+;hC-? z!3|{amEa2^{w?GydwGc&gzq%Bsq<$niKWvyVqVJ@VQRAFTitG@IU7NaLkLyXTX_VB zt@wlEAuV|1c2{Mi(zPXKOs(w(vZ_N!f8~yCQf>Pc+($jGSL6<_IYF=iL#MK|!{6Zf zW+QNX^n!G}_-ADr5dADU{6#cJQn+5qiP6OY@x}Ja@gNqLoYso3tUYk8dZcD8w+E{S zv3+VdAy9&?!xMpN56uBCc;$740gfPMQhmL3*sOP}Ee8wR+Pd24Yjy0QtH77=|KGp- zORmq^b`PBYehq8m<@;s+Pq|#i5TuZHKlp%Uv|RWX7{$sUh+*a6z2FOqK*8U4cO>oO zIWBDnUHMixr@<7ifB!)~;lB9kB0HJ3p-B#33S_k4WQy`NtD$32xYW`EOM=CBavnZE z=}QV<7@xp=4Z!?TU_7_r&^x|x0vNpK6hi%hS_mE&&Mi6x+7911Z@>sL?YY}i$U@hl zX|}NWT9~n0)#F{>F8m+qKcu7cRpbA?@R!S8J>B^E^y?3wn4h|{`sv=Orypb{3e*hW zaB1_rodOi_Hv<iJeIa`3^3-tL#ADNARLR-i{Qi7rq^l7f5G6Nw$=MbRTM{L`P$~(A zsv7%}ON&lOu_8JZ_2JqvcFVI$z_bNz(NT!rd3XQ)jPqS1O;kL?2#6sPI)$Jgzy(j| zPSWrBP0v<u$z0IKt;c+24GnP2V1^9a0i+P?rw-<(CVzbX(LNXYKW!3?LG!D|eTOz4 z(|-sFX?~pkmr)r1gZ}@B&z}kzME}c|x6tyhU%t$@l2Zu&ZE2nJ3;Qjv7ktAj>}lOC zxJH393UmNjX9Ef;6x?k<r-Ik@LcqC(y27B@;CEl_fMznmS}hoQL7*kov-w{N`+#g2 zL7!OFU>H8+-UA|AU=3Xe$iEw2hHnHg4TrzN`$C_4?rv$fpwWJT;luWV--uiHYoX8z zVDJZ8Gu5C8*5>I5(oG*jb))mkm!Mk(j#v59W8E)EVfT4I7?J*GH$sWyu`C}Up?L!M zZ(qLr?QegRoi9Nr9k&o7dK%%f@Ylkb4gSlYGiKz^KYuy@?Ejr{EeU?%@3+4UJ??_n zPHzd$?IXdtK8WmotzZzr^DCgg2+r5*gKJCC@S|JK$ev#2;ID<hL^$}l@YjEjP86GW zJzKvS&guDAjW(li;d@u$(Vbrke|8LwFL1O=|M};ie~yl&uWT6f|Ciu=Kf?__01%vh zez;Otm8bQBXZ{kR`Lql!6CBQ<<Vv(!h`b^{e!Axiif-&rlO0Y;)Qtk|y1W+f0?}F( zg5Nq@o(t}V>(41fijp&oJVUc3&8CIu@-mdn;e?+Mw}#4pjrtl)O)!w4_1Fl59TN1+ zh_;GdF!p*uDu^EMIDh^n7~)48f4^xi#L8d(@^iAa01I(cofwe>uEI}P?s*^FO+pX; z{5@Q^U%ve5PX%J!{qp5s3xB)8$bUw*(O-hS@ynG8{MXNaE0hY;6B&pwA2xk?`pb3E zoc7lF{%M*{Yu@?juprsNT8w)8OSr?&#O3tHmqPST)P-<&1`j>ebxzdE2$-+}ErcxN z9f@-Iu(WlsIe%*!{9Ar5=l|Ce3kb9p!$x=5{_1P$+uC@1{s*W1o%{zO5c0?Q|06zs zD$KXM!=E<9Df&AgMQ3@Tpc%mdS1^OEE*Q4veED)(CI43V&y#fUU;nH3&L5vYK7V}v R`1~V({y&|#T>b$50RR?OQ^^1T diff --git a/smoke-tests/index.js b/smoke-tests/index.js deleted file mode 100644 index 464187d..0000000 --- a/smoke-tests/index.js +++ /dev/null @@ -1,351 +0,0 @@ -const fs = require('fs') -const { promisify } = require('util') -const execAsync = promisify(require('child_process').exec) -const { join, resolve } = require('path') -const t = require('tap') -const rimraf = promisify(require('rimraf')) - -const normalizePath = path => path.replace(/[A-Z]:/, '').replace(/\\/g, '/') -const cwd = normalizePath(process.cwd()) -t.cleanSnapshot = s => - s - .split(cwd) - .join('{CWD}') - .split(registry) - .join('https://registry.npmjs.org/') - .split(normalizePath(process.execPath)) - .join('node') - .split(process.cwd()) - .join('{CWD}') - .replace(/\\+/g, '/') - .replace(/\r\n/g, '\n') - .replace(/ \(in a browser\)/g, '') - .replace(/^npm@.* /gm, 'npm ') - .replace(/^.*debug-[0-9]+.log$/gm, '') - -// setup server -const { start, stop, registry } = require('./server.js') -t.before(start) -t.teardown(stop) - -// setup fixtures -const path = t.testdir({ - '.npmrc': '', - cache: {}, - project: {}, - bin: {}, -}) -const localPrefix = resolve(path, 'project') -const userconfigLocation = resolve(path, '.npmrc') -const npmLocation = resolve(__dirname, '../bin/npm-cli.js') -const cacheLocation = resolve(path, 'cache') -const binLocation = resolve(path, 'bin') -const env = { - HOME: path, - PATH: `${process.env.PATH}:${binLocation}`, -} -const npmOpts = [ - `--registry=${registry}`, - `--cache="${cacheLocation}"`, - `--userconfig="${userconfigLocation}"`, - '--no-audit', - '--no-update-notifier', - '--loglevel=silly', -].join(' ') -const npmBin = `"${process.execPath}" "${npmLocation}" ${npmOpts}` -const exec = async cmd => { - const res = await execAsync(cmd, { cwd: localPrefix, env }) - if (res.stderr) { - console.error(res.stderr) - } - return String(res.stdout) -} -const readFile = filename => String(fs.readFileSync(resolve(localPrefix, filename))) - -// this test must come first, its package.json will be destroyed and the one -// created in the next test (npm init) will create a new one that must be -// present for later tests -t.test('npm install sends correct user-agent', async t => { - const pkgPath = join(localPrefix, 'package.json') - const pkgContent = JSON.stringify({ - name: 'smoke-test-workspaces', - workspaces: ['packages/*'], - }) - fs.writeFileSync(pkgPath, pkgContent, { encoding: 'utf8' }) - - const wsRoot = join(localPrefix, 'packages') - fs.mkdirSync(wsRoot) - - const wsPath = join(wsRoot, 'foo') - fs.mkdirSync(wsPath) - - const wsPkgPath = join(wsPath, 'package.json') - const wsContent = JSON.stringify({ - name: 'foo', - }) - fs.writeFileSync(wsPkgPath, wsContent, { encoding: 'utf8' }) - t.teardown(async () => { - await rimraf(`${localPrefix}/*`) - }) - - const cmd = `${npmBin} install fail_reflect_user_agent` - await t.rejects( - exec(cmd), - { - stderr: /workspaces\/false/, - }, - 'workspaces/false is present in output' - ) - - const wsCmd = `${npmBin} install fail_reflect_user_agent --workspaces` - await t.rejects( - exec(wsCmd), - { - stderr: /workspaces\/true/, - }, - 'workspaces/true is present in output' - ) -}) - -t.test('npm init', async t => { - const cmd = `${npmBin} init -y` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes, 'should have successful npm init result') - const pkg = JSON.parse(fs.readFileSync(resolve(localPrefix, 'package.json'))) - t.equal(pkg.name, 'project', 'should have expected generated name') - t.equal(pkg.version, '1.0.0', 'should have expected generated version') -}) - -t.test('npm (no args)', async t => { - const cmd = `"${process.execPath}" "${npmLocation}" --no-audit --no-update-notifier` - const cmdRes = await execAsync(cmd, { cwd: localPrefix, env }).catch(err => { - t.equal(err.code, 1, 'should exit with error code') - return err - }) - - t.equal(cmdRes.stderr, '', 'should have no stderr output') - t.matchSnapshot(String(cmdRes.stdout), 'should have expected no args output') -}) - -t.test('npm install prodDep@version', async t => { - const cmd = `${npmBin} install abbrev@1.0.4` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes.replace(/in.*s/, ''), 'should have expected install reify output') - t.matchSnapshot(readFile('package.json'), 'should have expected package.json result') - t.matchSnapshot(readFile('package-lock.json'), 'should have expected lockfile result') -}) - -t.test('npm install dev dep', async t => { - const cmd = `${npmBin} install -D promise-all-reject-late` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes.replace(/in.*s/, ''), 'should have expected dev dep added reify output') - t.matchSnapshot( - readFile('package.json'), - 'should have expected dev dep added package.json result' - ) - t.matchSnapshot( - readFile('package-lock.json'), - 'should have expected dev dep added lockfile result' - ) -}) - -t.test('npm ls', async t => { - const cmd = `${npmBin} ls` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes, 'should have expected ls output') -}) - -t.test('npm fund', async t => { - const cmd = `${npmBin} fund` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes, 'should have expected fund output') -}) - -t.test('npm explain', async t => { - const cmd = `${npmBin} explain abbrev` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes, 'should have expected explain output') -}) - -t.test('npm diff', async t => { - const cmd = `${npmBin} diff --diff=abbrev@1.0.4 --diff=abbrev@1.1.1` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes, 'should have expected diff output') -}) - -t.test('npm outdated', async t => { - const cmd = `${npmBin} outdated` - const cmdRes = await exec(cmd).catch(err => { - t.equal(err.code, 1, 'should exit with error code') - return err - }) - - t.not(cmdRes.stderr, '', 'should have stderr output') - t.matchSnapshot(String(cmdRes.stdout), 'should have expected outdated output') -}) - -t.test('npm set-script', async t => { - const cmd = `${npmBin} set-script "hello" "echo Hello"` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes, 'should have expected set-script output') - t.matchSnapshot( - readFile('package.json'), - 'should have expected script added package.json result' - ) -}) - -t.test('npm run-script', async t => { - const cmd = `${npmBin} run hello` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes, 'should have expected run-script output') -}) - -t.test('npm prefix', async t => { - const cmd = `${npmBin} prefix` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes, 'should have expected prefix output') -}) - -t.test('npm view', async t => { - const cmd = `${npmBin} view abbrev@1.0.4` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes, 'should have expected view output') -}) - -t.test('npm update dep', async t => { - const cmd = `${npmBin} update abbrev` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes.replace(/in.*s/, ''), 'should have expected update reify output') - t.matchSnapshot(readFile('package.json'), 'should have expected update package.json result') - t.matchSnapshot(readFile('package-lock.json'), 'should have expected update lockfile result') -}) - -t.test('npm uninstall', async t => { - const cmd = `${npmBin} uninstall promise-all-reject-late` - const cmdRes = await exec(cmd) - - t.matchSnapshot(cmdRes.replace(/in.*s/, ''), 'should have expected uninstall reify output') - t.matchSnapshot(readFile('package.json'), 'should have expected uninstall package.json result') - t.matchSnapshot(readFile('package-lock.json'), 'should have expected uninstall lockfile result') -}) - -t.test('npm pkg', async t => { - let cmd = `${npmBin} pkg get license` - let cmdRes = await exec(cmd) - t.matchSnapshot(cmdRes.replace(/in.*s/, ''), 'should have expected pkg get output') - - cmd = `${npmBin} pkg set tap[test-env][0]=LC_ALL=sk` - cmdRes = await exec(cmd) - t.matchSnapshot(cmdRes.replace(/in.*s/, ''), 'should have expected pkg set output') - - t.matchSnapshot( - readFile('package.json'), - 'should have expected npm pkg set modified package.json result' - ) - - cmd = `${npmBin} pkg get` - cmdRes = await exec(cmd) - t.matchSnapshot(cmdRes.replace(/in.*s/, ''), 'should print package.json contents') - - cmd = `${npmBin} pkg delete tap` - cmdRes = await exec(cmd) - t.matchSnapshot(cmdRes.replace(/in.*s/, ''), 'should have expected pkg delete output') - - t.matchSnapshot( - readFile('package.json'), - 'should have expected npm pkg delete modified package.json result' - ) -}) - -t.test('npm update --no-save --no-package-lock', async t => { - // setup, manually reset dep value - await exec(`${npmBin} pkg set "dependencies.abbrev==1.0.4"`) - await exec(`${npmBin} install`) - await exec(`${npmBin} pkg set "dependencies.abbrev=^1.0.4"`) - - const cmd = `${npmBin} update --no-save --no-package-lock` - await exec(cmd) - - t.equal( - JSON.parse(readFile('package.json')).dependencies.abbrev, - '^1.0.4', - 'should have expected update --no-save --no-package-lock package.json result' - ) - t.equal( - JSON.parse(readFile('package-lock.json')).packages['node_modules/abbrev'].version, - '1.0.4', - 'should have expected update --no-save --no-package-lock lockfile result' - ) -}) - -t.test('npm update --no-save', async t => { - const cmd = `${npmBin} update --no-save` - await exec(cmd) - - t.equal( - JSON.parse(readFile('package.json')).dependencies.abbrev, - '^1.0.4', - 'should have expected update --no-save package.json result' - ) - t.equal( - JSON.parse(readFile('package-lock.json')).packages['node_modules/abbrev'].version, - '1.1.1', - 'should have expected update --no-save lockfile result' - ) -}) - -t.test('npm update --save', async t => { - const cmd = `${npmBin} update --save` - await exec(cmd) - - t.equal( - JSON.parse(readFile('package.json')).dependencies.abbrev, - '^1.1.1', - 'should have expected update --save package.json result' - ) - t.equal( - JSON.parse(readFile('package-lock.json')).packages['node_modules/abbrev'].version, - '1.1.1', - 'should have expected update --save lockfile result' - ) -}) - -t.test('npm ci', async t => { - await exec(`${npmBin} uninstall abbrev`) - await exec(`${npmBin} install abbrev@1.0.4 --save-exact`) - - t.equal( - JSON.parse(readFile('package-lock.json')).packages['node_modules/abbrev'].version, - '1.0.4', - 'should have stored exact installed version' - ) - - await exec(`${npmBin} pkg set "dependencies.abbrev=^1.1.1"`) - - try { - const npmOpts = [ - `--registry=${registry}`, - `--cache="${cacheLocation}"`, - `--userconfig="${userconfigLocation}"`, - '--no-audit', - '--no-update-notifier', - '--loglevel=error', - ].join(' ') - const npmBin = `"${process.execPath}" "${npmLocation}" ${npmOpts}` - await exec(`${npmBin} ci`) - } catch (err) { - t.matchSnapshot(err.stderr, 'should throw mismatch deps in lock file error') - } -}) diff --git a/smoke-tests/package.json b/smoke-tests/package.json new file mode 100644 index 0000000..474ad2c --- /dev/null +++ b/smoke-tests/package.json @@ -0,0 +1,54 @@ +{ + "name": "@npmcli/smoke-tests", + "description": "The npm cli smoke tests", + "version": "1.0.0", + "private": true, + "scripts": { + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force", + "lintfix": "node .. run lint -- --fix", + "snap": "tap", + "test": "tap", + "posttest": "node .. run lint" + }, + "repository": { + "type": "git", + "url": "https://github.com/npm/cli.git", + "directory": "smoke-tests" + }, + "devDependencies": { + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/mock-registry": "^1.0.0", + "@npmcli/promise-spawn": "^6.0.1", + "@npmcli/template-oss": "4.11.0", + "http-proxy": "^1.18.1", + "just-extend": "^6.1.1", + "just-safe-set": "^4.1.1", + "tap": "^16.3.2", + "which": "^3.0.0" + }, + "author": "GitHub Inc.", + "license": "ISC", + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../scripts/template-oss/index.js" + }, + "tap": { + "no-coverage": true, + "timeout": 600, + "test-ignore": "fixtures/*", + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] + }, + "files": [ + "bin/", + "lib/" + ], + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } +} diff --git a/smoke-tests/server.js b/smoke-tests/server.js deleted file mode 100644 index 31ffebb..0000000 --- a/smoke-tests/server.js +++ /dev/null @@ -1,282 +0,0 @@ -/* istanbul ignore file */ -const { join, dirname, basename } = require('path') -const { existsSync, readFileSync, writeFileSync } = require('fs') -const PORT = 12345 + (+process.env.TAP_CHILD_ID || 0) -const http = require('http') -const https = require('https') - -const mkdirp = require('mkdirp') -const doProxy = process.env.ARBORIST_TEST_PROXY -const missing = /\/@isaacs(\/|%2[fF])(this-does-not-exist-at-all|testing-missing-tgz\/-\/)/ -const corgiDoc = 'application/vnd.npm.install-v1+json; q=1.0, application/json; q=0.8, */*' -const { gzipSync, unzipSync } = require('zlib') - -let advisoryBulkResponse = null -let failAdvisoryBulk = false -let auditResponse = null -let failAudit = false -const startServer = () => new Promise((res, rej) => { - const server = exports.server = http.createServer((req, res) => { - res.setHeader('connection', 'close') - - if (req.url === '/-/npm/v1/security/advisories/bulk') { - const body = [] - req.on('data', c => body.push(c)) - req.on('end', () => { - res.setHeader('connection', 'close') - if (failAdvisoryBulk) { - res.statusCode = 503 - return res.end('no advisory bulk for you') - } - if (!advisoryBulkResponse) { - if (auditResponse && !failAudit) { - // simulate what the registry does when quick audits are allowed, - // but advisory bulk requests are not - res.statusCode = 405 - return res.end(JSON.stringify({ - code: 'MethodNotAllowedError', - message: 'POST is not allowed', - })) - } else { - res.statusCode = 404 - return res.end('not found') - } - } - if (doProxy && !existsSync(advisoryBulkResponse)) { - // hit the main registry, then fall back to staging for now - // XXX: remove this when bulk advisory endpoint pushed to production! - const opts = { - host: 'registry.npmjs.org', - method: req.method, - path: req.url, - headers: { - ...req.headers, - accept: '*', - host: 'registry.npmjs.org', - connection: 'close', - 'if-none-match': '', - }, - } - const handleUpstream = upstream => { - res.statusCode = upstream.statusCode - if (upstream.statusCode >= 300 || upstream.statusCode < 200) { - console.error('UPSTREAM ERROR', upstream.statusCode) - return upstream.pipe(res) - } - res.setHeader('content-encoding', upstream.headers['content-encoding']) - const file = advisoryBulkResponse - console.error('PROXY', `${req.url} -> ${file} ${upstream.statusCode}`) - mkdirp.sync(dirname(file)) - const data = [] - upstream.on('end', () => { - const out = Buffer.concat(data) - const obj = JSON.parse(unzipSync(out).toString()) - writeFileSync(file, JSON.stringify(obj, 0, 2) + '\n') - res.end(out) - }) - upstream.on('data', c => data.push(c)) - } - return https.request(opts).on('response', upstream => { - if (upstream.statusCode !== 200) { - console.error('ATTEMPTING TO PROXY FROM STAGING') - console.error('NOTE: THIS WILL FAIL WHEN NOT ON VPN!') - opts.host = 'security-microservice-3-west.npm.red' - opts.headers.host = opts.host - opts.path = '/v1/advisories/bulk' - https.request(opts) - .on('response', upstream => handleUpstream(upstream)) - .end(Buffer.concat(body)) - } else { - handleUpstream(upstream) - } - }).end(Buffer.concat(body)) - } else { - res.setHeader('content-encoding', 'gzip') - res.end(gzipSync(readFileSync(advisoryBulkResponse))) - } - }) - return - } else if (req.url === '/-/npm/v1/security/audits/quick') { - const body = [] - req.on('data', c => body.push(c)) - req.on('end', () => { - res.setHeader('connection', 'close') - if (failAudit) { - res.statusCode = 503 - return res.end('no audit for you') - } - if (!auditResponse) { - res.statusCode = 404 - return res.end('not found') - } - if (doProxy && !existsSync(auditResponse)) { - return https.request({ - host: 'registry.npmjs.org', - method: req.method, - path: req.url, - headers: { - ...req.headers, - accept: '*', - host: 'registry.npmjs.org', - connection: 'close', - 'if-none-match': '', - }, - }).on('response', upstream => { - res.statusCode = upstream.statusCode - if (upstream.statusCode >= 300 || upstream.statusCode < 200) { - console.error('UPSTREAM ERROR', upstream.statusCode) - // don't save if it's not a valid response - return upstream.pipe(res) - } - res.setHeader('content-encoding', upstream.headers['content-encoding']) - const file = auditResponse - console.error('PROXY', `${req.url} -> ${file} ${upstream.statusCode}`) - mkdirp.sync(dirname(file)) - const data = [] - upstream.on('end', () => { - const out = Buffer.concat(data) - // make it a bit prettier to read later - const obj = JSON.parse(unzipSync(out).toString()) - writeFileSync(file, JSON.stringify(obj, 0, 2) + '\n') - res.end(out) - }) - upstream.on('data', c => data.push(c)) - }).end(Buffer.concat(body)) - } else { - res.setHeader('content-encoding', 'gzip') - res.end(gzipSync(readFileSync(auditResponse))) - } - }) - return - } - - const f = join(__dirname, 'content', join('/', req.url.replace(/@/, '').replace(/%2f/i, '/'))) - // a magic package that causes us to return an error that will be logged - if (basename(f) === 'fail_reflect_user_agent') { - res.setHeader('npm-notice', req.headers['user-agent']) - res.writeHead(404) - return res.end() - } - const isCorgi = req.headers.accept.includes('application/vnd.npm.install-v1+json') - const file = f + ( - isCorgi && existsSync(`${f}.min.json`) ? '.min.json' - : existsSync(`${f}.json`) ? '.json' - : existsSync(`${f}/index.json`) ? 'index.json' - : '' - ) - - try { - const body = readFileSync(file) - res.setHeader('content-length', body.length) - res.setHeader('content-type', /\.min\.json$/.test(file) ? corgiDoc - : /\.json$/.test(file) ? 'application/json' - : 'application/octet-stream') - res.end(body) - } catch (er) { - // testing things going missing from the registry somehow - if (missing.test(req.url)) { - res.statusCode = 404 - res.end('{"error": "not found"}') - return - } - - if (doProxy) { - return https.get({ - host: 'registry.npmjs.org', - path: req.url, - headers: { - ...req.headers, - accept: '*', - 'accept-encoding': 'identity', - host: 'registry.npmjs.org', - connection: 'close', - 'if-none-match': '', - }, - }).on('response', upstream => { - const errorStatus = - upstream.statusCode >= 300 || upstream.statusCode < 200 - - if (errorStatus) { - console.error('UPSTREAM ERROR', upstream.statusCode) - } - - const ct = upstream.headers['content-type'] - const isJson = ct.includes('application/json') - const file = isJson ? f + '.json' : f - console.error('PROXY', `${req.url} -> ${file} ${ct}`) - mkdirp.sync(dirname(file)) - const data = [] - res.statusCode = upstream.statusCode - res.setHeader('content-type', ct) - upstream.on('end', () => { - console.error('ENDING', req.url) - const out = Buffer.concat(data) - if (!errorStatus) { - if (isJson) { - const obj = JSON.parse(out.toString()) - writeFileSync(file, JSON.stringify(obj, 0, 2) + '\n') - const mrm = require('minify-registry-metadata') - const minFile = file.replace(/\.json$/, '.min.json') - writeFileSync(minFile, JSON.stringify(mrm(obj), 0, 2) + '\n') - console.error('WROTE JSONS', [file, minFile]) - } else { - writeFileSync(file, out) - } - } - res.end(out) - }) - upstream.on('data', c => data.push(c)) - }).end() - } - - res.statusCode = er.code === 'ENOENT' ? 404 : 500 - if (res.method === 'GET') { - console.error(er) - } - res.setHeader('content-type', 'text/plain') - res.end(er.stack) - } - }) - server.listen(PORT, res) -}) - -exports.auditResponse = value => { - if (auditResponse && auditResponse !== value) { - throw new Error('setting audit response, but already set\n' + - '(did you forget to call the returned function on teardown?)') - } - auditResponse = value - return () => auditResponse = null -} -exports.failAudit = () => { - failAudit = true - return () => failAudit = false -} - -exports.advisoryBulkResponse = value => { - if (advisoryBulkResponse && advisoryBulkResponse !== value) { - throw new Error('setting advisory bulk response, but already set\n' + - '(did you forget to call the returned function on teardown?)') - } - advisoryBulkResponse = value - return () => advisoryBulkResponse = null -} -exports.failAdvisoryBulk = () => { - failAdvisoryBulk = true - return () => failAdvisoryBulk = false -} - -exports.registry = `http://localhost:${PORT}/` - -exports.start = startServer -exports.stop = () => exports.server.close() - -if (require.main === module) { - startServer().then(() => { - console.log(`Mock registry live at: - ${exports.registry} -Press ^D to close gracefully.`) - }) - process.openStdin() - process.stdin.on('end', () => exports.stop()) -} diff --git a/smoke-tests/tap-snapshots/test/index.js.test.cjs b/smoke-tests/tap-snapshots/test/index.js.test.cjs new file mode 100644 index 0000000..de87748 --- /dev/null +++ b/smoke-tests/tap-snapshots/test/index.js.test.cjs @@ -0,0 +1,481 @@ +/* IMPORTANT + * This snapshot file is auto-generated, but designed for humans. + * It should be checked into source control and tracked carefully. + * Re-generate by setting TAP_SNAPSHOT=1 and running tests. + * Make sure to inspect the output below. Do not ignore changes! + */ +'use strict' +exports[`test/index.js TAP basic npm (no args) > should have expected no args output 1`] = ` +npm <command> + +Usage: + +npm install install all the dependencies in your project +npm install <foo> add the <foo> dependency to your project +npm test run this project's tests +npm run <foo> run the script named <foo> +npm <command> -h quick help on <command> +npm -l display usage info for all commands +npm help <term> search for help on <term> +npm help npm more involved overview + +All commands: + + access, adduser, audit, bugs, cache, ci, completion, + config, dedupe, deprecate, diff, dist-tag, docs, doctor, + edit, exec, explain, explore, find-dupes, fund, get, help, + hook, init, install, install-ci-test, install-test, link, + ll, login, logout, ls, org, outdated, owner, pack, ping, + pkg, prefix, profile, prune, publish, query, rebuild, repo, + restart, root, run-script, search, set, shrinkwrap, star, + stars, start, stop, team, test, token, uninstall, unpublish, + unstar, update, version, view, whoami + +Specify configs in the ini-formatted file: + {NPM}/{TESTDIR}/project/.npmrc +or on the command line via: npm <command> --key=value + +More configuration info: npm help config +Configuration fields: npm help 7 config + +npm {NPM} +` + +exports[`test/index.js TAP basic npm ci > should throw mismatch deps in lock file error 1`] = ` +npm ERR! code EUSAGE +npm ERR! +npm ERR! \`npm ci\` can only install packages when your package.json and package-lock.json or npm-shrinkwrap.json are in sync. Please update your lock file with \`npm install\` before continuing. +npm ERR! +npm ERR! Invalid: lock file's abbrev@1.0.4 does not satisfy abbrev@1.1.1 +npm ERR! +npm ERR! Clean install a project +npm ERR! +npm ERR! Usage: +npm ERR! npm ci +npm ERR! +npm ERR! Options: +npm ERR! [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] +npm ERR! [-E|--save-exact] [-g|--global] [--install-strategy <hoisted|nested|shallow>] +npm ERR! [--legacy-bundling] [--global-style] +npm ERR! [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] +npm ERR! [--strict-peer-deps] [--no-package-lock] [--foreground-scripts] +npm ERR! [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] +npm ERR! [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +npm ERR! [-ws|--workspaces] [--include-workspace-root] [--no-install-links] +npm ERR! +npm ERR! aliases: clean-install, ic, install-clean, isntall-clean +npm ERR! +npm ERR! Run "npm help ci" for more info + +npm ERR! A complete log of this run can be found in: + +` + +exports[`test/index.js TAP basic npm diff > should have expected diff output 1`] = ` +diff --git a/index.js b/index.js +index v1.0.4..v1.1.1 100644 +--- a/index.js ++++ b/index.js +@@ -1,1 +1,1 @@ +-module.exports = "1.0.4" +/ No newline at end of file ++module.exports = "1.1.1" +/ No newline at end of file +diff --git a/package.json b/package.json +index v1.0.4..v1.1.1 100644 +--- a/package.json ++++ b/package.json +@@ -1,4 +1,4 @@ + { + "name": "abbrev", +- "version": "1.0.4" ++ "version": "1.1.1" + } +/ No newline at end of file +` + +exports[`test/index.js TAP basic npm explain > should have expected explain output 1`] = ` +abbrev@1.0.4 +node_modules/abbrev + abbrev@"^1.0.4" from the root project +` + +exports[`test/index.js TAP basic npm fund > should have expected fund output 1`] = ` +project@1.0.0 +\`-- https://github.com/sponsors + \`-- promise-all-reject-late@5.0.0 +` + +exports[`test/index.js TAP basic npm init > should have successful npm init result 1`] = ` +Wrote to {NPM}/{TESTDIR}/project/package.json: + +{ + "name": "project", + "version": "1.0.0", + "description": "", + "main": "index.js", + "scripts": { + "test": "echo /"Error: no test specified/" && exit 1" + }, + "keywords": [], + "author": "", + "license": "ISC" +} +` + +exports[`test/index.js TAP basic npm install dev dep > should have expected dev dep added lockfile result 1`] = ` +Object { + "lockfileVersion": 3, + "name": "project", + "packages": Object { + "": Object { + "dependencies": Object { + "abbrev": "^1.0.4", + }, + "devDependencies": Object { + "promise-all-reject-late": "^5.0.0", + }, + "license": "ISC", + "name": "project", + "version": "1.0.0", + }, + "node_modules/abbrev": Object { + "resolved": "{REGISTRY}/abbrev/-/abbrev-1.0.4.tgz", + "version": "1.0.4", + }, + "node_modules/promise-all-reject-late": Object { + "dev": true, + "funding": Object { + "url": "https://github.com/sponsors", + }, + "resolved": "{REGISTRY}/promise-all-reject-late/-/promise-all-reject-late-5.0.0.tgz", + "version": "5.0.0", + }, + }, + "requires": true, + "version": "1.0.0", +} +` + +exports[`test/index.js TAP basic npm install dev dep > should have expected dev dep added package.json result 1`] = ` +Object { + "author": "", + "dependencies": Object { + "abbrev": "^1.0.4", + }, + "description": "", + "devDependencies": Object { + "promise-all-reject-late": "^5.0.0", + }, + "keywords": Array [], + "license": "ISC", + "main": "index.js", + "name": "project", + "scripts": Object { + "test": "echo /"Error: no test specified/" && exit 1", + }, + "version": "1.0.0", +} +` + +exports[`test/index.js TAP basic npm install dev dep > should have expected dev dep added reify output 1`] = ` +added 1 package in {TIME} + +1 package is looking for funding + run \`npm fund\` for details +` + +exports[`test/index.js TAP basic npm install prodDep@version > should have expected install reify output 1`] = ` +added 1 package in {TIME} +` + +exports[`test/index.js TAP basic npm install prodDep@version > should have expected lockfile result 1`] = ` +Object { + "lockfileVersion": 3, + "name": "project", + "packages": Object { + "": Object { + "dependencies": Object { + "abbrev": "^1.0.4", + }, + "license": "ISC", + "name": "project", + "version": "1.0.0", + }, + "node_modules/abbrev": Object { + "resolved": "{REGISTRY}/abbrev/-/abbrev-1.0.4.tgz", + "version": "1.0.4", + }, + }, + "requires": true, + "version": "1.0.0", +} +` + +exports[`test/index.js TAP basic npm install prodDep@version > should have expected package.json result 1`] = ` +Object { + "author": "", + "dependencies": Object { + "abbrev": "^1.0.4", + }, + "description": "", + "keywords": Array [], + "license": "ISC", + "main": "index.js", + "name": "project", + "scripts": Object { + "test": "echo /"Error: no test specified/" && exit 1", + }, + "version": "1.0.0", +} +` + +exports[`test/index.js TAP basic npm ls > should have expected ls output 1`] = ` +project@1.0.0 {NPM}/{TESTDIR}/project ++-- abbrev@1.0.4 +\`-- promise-all-reject-late@5.0.0 +` + +exports[`test/index.js TAP basic npm outdated > should have expected outdated output 1`] = ` +Package Current Wanted Latest Location Depended by +abbrev 1.0.4 1.1.1 1.1.1 node_modules/abbrev project +` + +exports[`test/index.js TAP basic npm pkg > should have expected npm pkg delete modified package.json result 1`] = ` +Object { + "author": "", + "dependencies": Object { + "abbrev": "^1.0.4", + }, + "description": "", + "keywords": Array [], + "license": "ISC", + "main": "index.js", + "name": "project", + "scripts": Object { + "hello": "echo Hello", + "test": "echo /"Error: no test specified/" && exit 1", + }, + "version": "1.0.0", +} +` + +exports[`test/index.js TAP basic npm pkg > should have expected npm pkg set modified package.json result 1`] = ` +Object { + "author": "", + "dependencies": Object { + "abbrev": "^1.0.4", + }, + "description": "", + "keywords": Array [], + "license": "ISC", + "main": "index.js", + "name": "project", + "scripts": Object { + "hello": "echo Hello", + "test": "echo /"Error: no test specified/" && exit 1", + }, + "tap": Object { + "test-env": Array [ + "LC_ALL=sk", + ], + }, + "version": "1.0.0", +} +` + +exports[`test/index.js TAP basic npm pkg > should have expected pkg delete output 1`] = ` + +` + +exports[`test/index.js TAP basic npm pkg > should have expected pkg get output 1`] = ` +"ISC" +` + +exports[`test/index.js TAP basic npm pkg > should have expected pkg set output 1`] = ` + +` + +exports[`test/index.js TAP basic npm pkg > should print package.json contents 1`] = ` +{ + "name": "project", + "version": "1.0.0", + "description": "", + "main": "index.js", + "scripts": { + "test": "echo /"Error: no test specified/" && exit 1", + "hello": "echo Hello" + }, + "keywords": [], + "author": "", + "license": "ISC", + "dependencies": { + "abbrev": "^1.0.4" + }, + "tap": { + "test-env": [ + "LC_ALL=sk" + ] + } +} +` + +exports[`test/index.js TAP basic npm pkg set scripts > should have expected script added package.json result 1`] = ` +Object { + "author": "", + "dependencies": Object { + "abbrev": "^1.0.4", + }, + "description": "", + "devDependencies": Object { + "promise-all-reject-late": "^5.0.0", + }, + "keywords": Array [], + "license": "ISC", + "main": "index.js", + "name": "project", + "scripts": Object { + "hello": "echo Hello", + "test": "echo /"Error: no test specified/" && exit 1", + }, + "version": "1.0.0", +} +` + +exports[`test/index.js TAP basic npm pkg set scripts > should have expected set-script output 1`] = ` + +` + +exports[`test/index.js TAP basic npm prefix > should have expected prefix output 1`] = ` +{NPM}/{TESTDIR}/project +` + +exports[`test/index.js TAP basic npm run-script > should have expected run-script output 1`] = ` +> project@1.0.0 hello +> echo Hello + +Hello +` + +exports[`test/index.js TAP basic npm uninstall > should have expected uninstall lockfile result 1`] = ` +Object { + "lockfileVersion": 3, + "name": "project", + "packages": Object { + "": Object { + "dependencies": Object { + "abbrev": "^1.0.4", + }, + "license": "ISC", + "name": "project", + "version": "1.0.0", + }, + "node_modules/abbrev": Object { + "resolved": "{REGISTRY}/abbrev/-/abbrev-1.1.1.tgz", + "version": "1.1.1", + }, + }, + "requires": true, + "version": "1.0.0", +} +` + +exports[`test/index.js TAP basic npm uninstall > should have expected uninstall package.json result 1`] = ` +Object { + "author": "", + "dependencies": Object { + "abbrev": "^1.0.4", + }, + "description": "", + "keywords": Array [], + "license": "ISC", + "main": "index.js", + "name": "project", + "scripts": Object { + "hello": "echo Hello", + "test": "echo /"Error: no test specified/" && exit 1", + }, + "version": "1.0.0", +} +` + +exports[`test/index.js TAP basic npm uninstall > should have expected uninstall reify output 1`] = ` +removed 1 package in {TIME} +` + +exports[`test/index.js TAP basic npm update dep > should have expected update lockfile result 1`] = ` +Object { + "lockfileVersion": 3, + "name": "project", + "packages": Object { + "": Object { + "dependencies": Object { + "abbrev": "^1.0.4", + }, + "devDependencies": Object { + "promise-all-reject-late": "^5.0.0", + }, + "license": "ISC", + "name": "project", + "version": "1.0.0", + }, + "node_modules/abbrev": Object { + "resolved": "{REGISTRY}/abbrev/-/abbrev-1.1.1.tgz", + "version": "1.1.1", + }, + "node_modules/promise-all-reject-late": Object { + "dev": true, + "funding": Object { + "url": "https://github.com/sponsors", + }, + "resolved": "{REGISTRY}/promise-all-reject-late/-/promise-all-reject-late-5.0.0.tgz", + "version": "5.0.0", + }, + }, + "requires": true, + "version": "1.0.0", +} +` + +exports[`test/index.js TAP basic npm update dep > should have expected update package.json result 1`] = ` +Object { + "author": "", + "dependencies": Object { + "abbrev": "^1.0.4", + }, + "description": "", + "devDependencies": Object { + "promise-all-reject-late": "^5.0.0", + }, + "keywords": Array [], + "license": "ISC", + "main": "index.js", + "name": "project", + "scripts": Object { + "hello": "echo Hello", + "test": "echo /"Error: no test specified/" && exit 1", + }, + "version": "1.0.0", +} +` + +exports[`test/index.js TAP basic npm update dep > should have expected update reify output 1`] = ` +changed 1 package in {TIME} + +1 package is looking for funding + run \`npm fund\` for details +` + +exports[`test/index.js TAP basic npm view > should have expected view output 1`] = ` +abbrev@1.0.4 | Proprietary | deps: none | versions: 2 +mocked test package + +dist +.tarball: {REGISTRY}/abbrev/-/abbrev-1.0.4.tgz +.shasum: undefined + +dist-tags: +latest: 1.1.1 + +published just now +` diff --git a/smoke-tests/test/fixtures/setup.js b/smoke-tests/test/fixtures/setup.js new file mode 100644 index 0000000..683a8ff --- /dev/null +++ b/smoke-tests/test/fixtures/setup.js @@ -0,0 +1,217 @@ +const fs = require('fs/promises') +const { existsSync } = require('fs') +const { join, resolve, sep, extname, relative, delimiter } = require('path') +const which = require('which') +const spawn = require('@npmcli/promise-spawn') +const justExtend = require('just-extend') +const justSet = require('just-safe-set') +const MockRegistry = require('@npmcli/mock-registry') +const { Blob } = require('buffer') +const http = require('http') +const httpProxy = require('http-proxy') + +const { SMOKE_PUBLISH_NPM, CI, PATH, Path, TAP_CHILD_ID = '0' } = process.env +const PORT = 12345 + (+TAP_CHILD_ID) +const CLI_ROOT = resolve(process.cwd(), '..') + +const set = (obj, ...args) => justSet(obj, ...args) && obj +const merge = (...args) => justExtend(true, ...args) +const normalizePath = path => path.replace(/[A-Z]:/, '').replace(/\\/g, '/') + +const testdirHelper = (obj) => { + for (const [key, value] of Object.entries(obj)) { + if (extname(key) === '.json') { + obj[key] = JSON.stringify(value, null, 2) + } else if (typeof value === 'object') { + obj[key] = testdirHelper(value) + } else { + obj[key] = value + } + } + return obj +} + +const getSpawnArgs = async () => { + const cliBin = join('bin', 'npm') + const cliJsBin = join('bin', 'npm-cli.js') + const npmLinks = await which('npm', { all: true }) + const npmPaths = await Promise.all(npmLinks.map(npm => fs.realpath(npm))) + + const cleanNpmPaths = [...new Set([ + CLI_ROOT, + join(CLI_ROOT, cliBin), + join(CLI_ROOT, cliJsBin), + ...npmLinks, + ...npmPaths, + ...npmPaths.map(n => n.replace(sep + cliBin, '')), + ...npmPaths.map(n => n.replace(sep + cliJsBin, '')), + ])] + + if (SMOKE_PUBLISH_NPM) { + return { + command: ['npm'], + NPM: cleanNpmPaths, + } + } + + return { + command: [process.execPath, join(CLI_ROOT, cliJsBin)], + NODE: process.execPath, + NPM: cleanNpmPaths, + } +} + +module.exports = async (t, { testdir = {}, debug } = {}) => { + // setup fixtures + const root = t.testdir({ + cache: {}, + project: { '.npmrc': '' }, + bin: {}, + global: { '.npmrc': '' }, + ...testdirHelper(testdir), + }) + const paths = { + root, + project: join(root, 'project'), + global: join(root, 'global'), + userConfig: join(root, 'project', '.npmrc'), + globalConfig: join(root, 'global', '.npmrc'), + cache: join(root, 'cache'), + bin: join(root, 'bin'), + } + + const registry = new MockRegistry({ + tap: t, + registry: 'http://smoke-test-registry.club/', + debug, + strict: true, + }) + const httpProxyRegistry = `http://localhost:${PORT}` + const proxy = httpProxy.createProxyServer({}) + const server = http.createServer((req, res) => proxy.web(req, res, { target: registry.origin })) + await new Promise(res => server.listen(PORT, res)) + t.teardown(() => server.close()) + + // update notifier should never be written + t.afterEach((t) => { + t.equal(existsSync(join(paths.cache, '_update-notifier-last-checked')), false) + }) + + const debugLog = debug || CI ? (...a) => console.error(...a) : () => {} + const { command, ...spawnPaths } = await getSpawnArgs({ log: debugLog }) + const cleanPaths = Object.entries(spawnPaths) + + const cleanOutput = s => { + // sometimes we print normalized paths in snapshots regardless of + // platform so replace those first then replace platform style paths + for (const [key, value] of cleanPaths) { + const values = [].concat(value) + for (const v of values) { + s = s.split(normalizePath(v)).join(`{${key}}`) + } + } + for (const [key, value] of cleanPaths) { + const values = [].concat(value) + for (const v of values) { + s = s.split(v).join(`{${key}}`) + } + } + return s + .split(relative(CLI_ROOT, t.testdirName)).join('{TESTDIR}') + .split(httpProxyRegistry).join('{REGISTRY}') + .split(registry.origin).join('{REGISTRY}') + .replace(/\\+/g, '/') + .replace(/\r\n/g, '\n') + .replace(/ \(in a browser\)/g, '') + .replace(/^npm@.* /gm, 'npm ') + .replace(/^.*debug-[0-9]+.log$/gm, '') + .replace(/in \d+[ms]+$/gm, 'in {TIME}') + } + const log = (...a) => debugLog(cleanOutput(a.join(' '))) + t.cleanSnapshot = cleanOutput + + const npm = async (...args) => { + const defaultFlags = [ + `--registry=${httpProxyRegistry}`, + `--cache=${paths.cache}`, + `--prefix=${paths.project}`, + `--userconfig=${paths.userConfig}`, + `--globalconfig=${paths.globalConfig}`, + '--no-audit', + '--no-update-notifier', + '--loglevel=silly', + '--fetch-retries=0', + ] + const [positionals, flags] = args.reduce((acc, arg) => { + if (arg.startsWith('-')) { + acc[1].push(arg) + } else { + acc[0].push(arg) + } + return acc + }, [[], defaultFlags]) + + const spawnCmd = command[0] + const spawnArgs = [...command.slice(1), ...positionals, ...flags] + + log(`${spawnCmd} ${spawnArgs.filter(a => !defaultFlags.includes(a)).join(' ')}`) + log('-'.repeat(40)) + + const { stderr, stdout } = await spawn(spawnCmd, spawnArgs, { + cwd: paths.project, + env: { + HTTP_PROXY: httpProxyRegistry, + HOME: paths.root, + [Path ? 'Path' : 'PATH']: `${Path || PATH}${delimiter}${paths.bin}`, + COMSPEC: process.env.COMSPEC, + }, + }) + + log(stderr) + log('-'.repeat(40)) + log(stdout) + log('='.repeat(40)) + + return cleanOutput(stdout) + } + + // helpers for reading/writing files and their source + const readFile = async (f) => { + const file = await fs.readFile(join(paths.project, f), 'utf-8') + return extname(f) === '.json' ? JSON.parse(file) : file + } + + // Returns a recurisve list of relative file paths in the testdir root + // will also follow symlinks and print their relative paths + const tree = async (rootDir = paths.project, dir = rootDir) => { + const results = {} + for (const item of await fs.readdir(dir)) { + const itemPath = join(dir, item) + const relPath = relative(rootDir, itemPath) + const stat = await fs.lstat(itemPath) + + if (stat.isSymbolicLink()) { + const realpath = await fs.realpath(itemPath) + merge(results, await tree(rootDir, realpath)) + } else if (stat.isDirectory()) { + merge(results, await tree(rootDir, itemPath)) + } else { + const raw = await readFile(relPath) + const content = typeof raw === 'string' ? `${new Blob([raw]).size} bytes` : raw + merge(results, set({}, relPath.split(sep), content)) + } + } + return results + } + + return { + npm, + readFile, + tree, + paths, + registry, + isSmokePublish: !!SMOKE_PUBLISH_NPM, + } +} + +module.exports.testdir = testdirHelper diff --git a/smoke-tests/test/index.js b/smoke-tests/test/index.js new file mode 100644 index 0000000..98f276b --- /dev/null +++ b/smoke-tests/test/index.js @@ -0,0 +1,335 @@ +const { join } = require('path') +const t = require('tap') +const setup = require('./fixtures/setup.js') + +t.test('basic', async t => { + const { registry, npm, isSmokePublish, readFile, paths } = await setup(t, { + testdir: { + packages: { + 'abbrev-1.0.4': { + 'package.json': { name: 'abbrev', version: '1.0.4' }, + 'index.js': 'module.exports = "1.0.4"', + }, + 'abbrev-1.1.1': { + 'package.json': { name: 'abbrev', version: '1.1.1' }, + 'index.js': 'module.exports = "1.1.1"', + }, + 'promise-all-reject-late': { + 'package.json': { name: 'promise-all-reject-late', version: '5.0.0' }, + 'index.js': 'module.exports = null', + }, + }, + }, + }) + + const abbrevManifest = () => registry.manifest({ name: 'abbrev', versions: ['1.0.4', '1.1.1'] }) + + await t.test('npm init', async t => { + const cmdRes = await npm('init', '-y') + + t.matchSnapshot(cmdRes, 'should have successful npm init result') + const pkg = await readFile('package.json') + t.equal(pkg.name, 'project', 'should have expected generated name') + t.equal(pkg.version, '1.0.0', 'should have expected generated version') + }) + + await t.test('npm --version', async t => { + const v = await npm('--version') + + if (isSmokePublish) { + t.match(v.trim(), /-[0-9a-f]{40}\.\d$/, 'must have a git version') + } else { + t.match(v.trim(), /^\d+\.\d+\.\d+/, 'has a version') + } + }) + + await t.test('npm (no args)', async t => { + const err = await npm('--loglevel=notice').catch(e => e) + + t.equal(err.code, 1, 'should exit with error code') + t.equal(err.stderr, '', 'should have no stderr output') + t.matchSnapshot(err.stdout, 'should have expected no args output') + }) + + await t.test('npm install prodDep@version', async t => { + const manifest = abbrevManifest() + await registry.package({ + manifest: manifest, + tarballs: { '1.0.4': join(paths.root, 'packages', 'abbrev-1.0.4') }, + }) + + const cmdRes = await npm('install', 'abbrev@1.0.4') + + t.matchSnapshot(cmdRes, 'should have expected install reify output') + t.resolveMatchSnapshot(readFile('package.json'), 'should have expected package.json result') + t.resolveMatchSnapshot(readFile('package-lock.json'), 'should have expected lockfile result') + }) + + await t.test('npm install dev dep', async t => { + const manifest = registry.manifest({ + name: 'promise-all-reject-late', + packuments: [{ version: '5.0.0', funding: 'https://github.com/sponsors' }], + }) + await registry.package({ + manifest: manifest, + tarballs: { '5.0.0': join(paths.root, 'packages', 'promise-all-reject-late') }, + }) + + const cmdRes = await npm('install', 'promise-all-reject-late', '-D') + + t.matchSnapshot(cmdRes, 'should have expected dev dep added reify output') + t.resolveMatchSnapshot( + readFile('package.json'), + 'should have expected dev dep added package.json result' + ) + t.resolveMatchSnapshot( + readFile('package-lock.json'), + 'should have expected dev dep added lockfile result' + ) + }) + + await t.test('npm ls', async t => { + const cmdRes = await npm('ls') + + t.matchSnapshot(cmdRes, 'should have expected ls output') + }) + + await t.test('npm fund', async t => { + const cmdRes = await npm('fund') + + t.matchSnapshot(cmdRes, 'should have expected fund output') + }) + + await t.test('npm explain', async t => { + const cmdRes = await npm('explain', 'abbrev') + + t.matchSnapshot(cmdRes, 'should have expected explain output') + }) + + await t.test('npm diff', async t => { + const manifest = abbrevManifest() + await registry.package({ + manifest: manifest, + tarballs: { '1.0.4': join(paths.root, 'packages', 'abbrev-1.0.4') }, + }) + await registry.package({ + manifest: manifest, + tarballs: { '1.1.1': join(paths.root, 'packages', 'abbrev-1.1.1') }, + }) + + const cmdRes = await npm('diff', '--diff=abbrev@1.0.4', '--diff=abbrev@1.1.1') + + t.matchSnapshot(cmdRes, 'should have expected diff output') + }) + + await t.test('npm outdated', async t => { + await registry.package({ + manifest: registry.manifest({ + name: 'promise-all-reject-late', + versions: ['5.0.0'], + }), + }) + await registry.package({ + manifest: abbrevManifest(), + }) + + const outdated = await npm('outdated').catch(e => e) + + t.equal(outdated.code, 1, 'should exit with error code') + t.not(outdated.stderr, '', 'should have stderr output') + t.matchSnapshot(outdated.stdout, 'should have expected outdated output') + }) + + await t.test('npm pkg set scripts', async t => { + const cmdRes = await npm('pkg', 'set', 'scripts.hello=echo Hello') + + t.matchSnapshot(cmdRes, 'should have expected set-script output') + t.resolveMatchSnapshot( + readFile('package.json'), + 'should have expected script added package.json result' + ) + }) + + await t.test('npm run-script', async t => { + const cmdRes = await npm('run', 'hello') + + t.matchSnapshot(cmdRes, 'should have expected run-script output') + }) + + await t.test('npm prefix', async t => { + const cmdRes = await npm('prefix') + + t.matchSnapshot(cmdRes, 'should have expected prefix output') + }) + + await t.test('npm view', async t => { + await registry.package({ + manifest: abbrevManifest(), + }) + const cmdRes = await npm('view', 'abbrev@1.0.4') + + t.matchSnapshot(cmdRes, 'should have expected view output') + }) + + await t.test('npm update dep', async t => { + const manifest = abbrevManifest() + await registry.package({ + manifest: manifest, + tarballs: { + '1.1.1': join(paths.root, 'packages', 'abbrev-1.1.1'), + }, + }) + + const cmdRes = await npm('update', 'abbrev') + + t.matchSnapshot(cmdRes, 'should have expected update reify output') + t.resolveMatchSnapshot(readFile('package.json'), + 'should have expected update package.json result') + t.resolveMatchSnapshot(readFile('package-lock.json'), + 'should have expected update lockfile result') + }) + + await t.test('npm uninstall', async t => { + const cmdRes = await npm('uninstall', 'promise-all-reject-late') + + t.matchSnapshot(cmdRes, 'should have expected uninstall reify output') + t.resolveMatchSnapshot(readFile('package.json'), + 'should have expected uninstall package.json result') + t.resolveMatchSnapshot(readFile('package-lock.json'), + 'should have expected uninstall lockfile result') + }) + + await t.test('npm pkg', async t => { + let cmdRes = await npm('pkg', 'get', 'license') + t.matchSnapshot(cmdRes, 'should have expected pkg get output') + + cmdRes = await npm('pkg', 'set', 'tap[test-env][0]=LC_ALL=sk') + t.matchSnapshot(cmdRes, 'should have expected pkg set output') + + t.resolveMatchSnapshot( + readFile('package.json'), + 'should have expected npm pkg set modified package.json result' + ) + + cmdRes = await npm('pkg', 'get') + t.matchSnapshot(cmdRes, 'should print package.json contents') + + cmdRes = await npm('pkg', 'delete', 'tap') + t.matchSnapshot(cmdRes, 'should have expected pkg delete output') + + t.resolveMatchSnapshot( + readFile('package.json'), + 'should have expected npm pkg delete modified package.json result' + ) + }) + + await t.test('npm update --no-save --no-package-lock', async t => { + const manifest = abbrevManifest() + await registry.package({ + manifest: manifest, + tarballs: { + '1.0.4': join(paths.root, 'packages', 'abbrev-1.0.4'), + }, + }) + + // setup, manually reset dep value + await npm('pkg', 'set', 'dependencies.abbrev==1.0.4') + await npm('install') + + await registry.package({ + manifest: manifest, + tarballs: { + '1.1.1': join(paths.root, 'packages', 'abbrev-1.1.1'), + }, + }) + + await npm('pkg', 'set', 'dependencies.abbrev=^1.0.4') + await npm('update', '--no-save', '--no-package-lock') + + t.equal( + (await readFile('package.json')).dependencies.abbrev, + '^1.0.4', + 'should have expected update --no-save --no-package-lock package.json result' + ) + t.equal( + (await readFile('package-lock.json')).packages['node_modules/abbrev'].version, + '1.0.4', + 'should have expected update --no-save --no-package-lock lockfile result' + ) + t.equal( + (await readFile('node_modules/abbrev/package.json')).version, + '1.1.1', + 'actual installed version is 1.1.1' + ) + }) + + await t.test('npm update --no-save', async t => { + const manifest = abbrevManifest() + await registry.package({ + manifest: manifest, + }) + + await npm('update', '--no-save') + + t.equal( + (await readFile('package.json')).dependencies.abbrev, + '^1.0.4', + 'should have expected update --no-save package.json result' + ) + t.equal( + (await readFile('package-lock.json')).packages['node_modules/abbrev'].version, + '1.1.1', + 'should have expected update --no-save lockfile result' + ) + }) + + await t.test('npm update --save', async t => { + const manifest = abbrevManifest() + await registry.package({ + manifest: manifest, + }) + + await npm('update', '--save') + + t.equal( + (await readFile('package.json')).dependencies.abbrev, + '^1.1.1', + 'should have expected update --save package.json result' + ) + t.equal( + (await readFile('package-lock.json')).packages['node_modules/abbrev'].version, + '1.1.1', + 'should have expected update --save lockfile result' + ) + }) + + await t.test('npm ci', async t => { + await npm('uninstall', 'abbrev') + + const manifest = abbrevManifest() + await registry.package({ + manifest: manifest, + tarballs: { + '1.0.4': join(paths.root, 'packages', 'abbrev-1.0.4'), + }, + }) + + await npm('install', 'abbrev@1.0.4', '--save-exact') + + t.equal( + (await readFile('package-lock.json')).packages['node_modules/abbrev'].version, + '1.0.4', + 'should have stored exact installed version' + ) + + await npm('pkg', 'set', 'dependencies.abbrev=^1.1.1') + + await registry.package({ + manifest, + }) + + const err = await npm('ci', '--loglevel=error').catch(e => e) + t.equal(err.code, 1) + t.matchSnapshot(err.stderr, 'should throw mismatch deps in lock file error') + }) +}) diff --git a/smoke-tests/test/workspace-ua.js b/smoke-tests/test/workspace-ua.js new file mode 100644 index 0000000..8cfc404 --- /dev/null +++ b/smoke-tests/test/workspace-ua.js @@ -0,0 +1,36 @@ + +const t = require('tap') +const setup = require('./fixtures/setup.js') + +t.test('basic', async t => { + const { registry, npm } = await setup(t) + + const mock = () => registry.nock + .get(`/fail_reflect_user_agent`) + // XXX: why does this get fetched twice for each uninstall? + .times(2) + .reply(404, {}, { 'npm-notice': (req) => req.headers['user-agent'] }) + + await t.test('npm install sends correct user-agent', async t => { + await npm('init', '-y') + await npm('init', '-y', `--workspace=foo`) + + mock() + await t.rejects( + npm('install', 'fail_reflect_user_agent'), + { + stderr: /workspaces\/false/, + }, + 'workspaces/false is present in output' + ) + + mock() + await t.rejects( + npm('install', 'fail_reflect_user_agent', '--workspaces'), + { + stderr: /workspaces\/true/, + }, + 'workspaces/true is present in output' + ) + }) +}) diff --git a/tap-snapshots/smoke-tests/index.js.test.cjs b/tap-snapshots/smoke-tests/index.js.test.cjs deleted file mode 100644 index 5fa3977..0000000 --- a/tap-snapshots/smoke-tests/index.js.test.cjs +++ /dev/null @@ -1,784 +0,0 @@ -/* IMPORTANT - * This snapshot file is auto-generated, but designed for humans. - * It should be checked into source control and tracked carefully. - * Re-generate by setting TAP_SNAPSHOT=1 and running tests. - * Make sure to inspect the output below. Do not ignore changes! - */ -'use strict' -exports[`smoke-tests/index.js TAP npm (no args) > should have expected no args output 1`] = ` -npm <command> - -Usage: - -npm install install all the dependencies in your project -npm install <foo> add the <foo> dependency to your project -npm test run this project's tests -npm run <foo> run the script named <foo> -npm <command> -h quick help on <command> -npm -l display usage info for all commands -npm help <term> search for help on <term> -npm help npm more involved overview - -All commands: - - access, adduser, audit, bin, bugs, cache, ci, completion, - config, dedupe, deprecate, diff, dist-tag, docs, doctor, - edit, exec, explain, explore, find-dupes, fund, get, help, - hook, init, install, install-ci-test, install-test, link, - ll, login, logout, ls, org, outdated, owner, pack, ping, - pkg, prefix, profile, prune, publish, rebuild, repo, - restart, root, run-script, search, set, set-script, - shrinkwrap, star, stars, start, stop, team, test, token, - uninstall, unpublish, unstar, update, version, view, whoami - -Specify configs in the ini-formatted file: - {CWD}/smoke-tests/tap-testdir-index/.npmrc -or on the command line via: npm <command> --key=value - -More configuration info: npm help config -Configuration fields: npm help 7 config - -npm {CWD} - -` - -exports[`smoke-tests/index.js TAP npm ci > should throw mismatch deps in lock file error 1`] = ` -npm ERR! \`npm ci\` can only install packages when your package.json and package-lock.json or npm-shrinkwrap.json are in sync. Please update your lock file with \`npm install\` before continuing. -npm ERR! -npm ERR! Invalid: lock file's abbrev@1.0.4 does not satisfy abbrev@1.1.1 -npm ERR! - -npm ERR! A complete log of this run can be found in: - - -` - -exports[`smoke-tests/index.js TAP npm diff > should have expected diff output 1`] = ` -diff --git a/package.json b/package.json -index v1.0.4..v1.1.1 100644 ---- a/package.json -+++ b/package.json -@@ -1,15 +1,21 @@ - { - "name": "abbrev", -- "version": "1.0.4", -+ "version": "1.1.1", - "description": "Like ruby's abbrev module, but in js", - "author": "Isaac Z. Schlueter <i@izs.me>", -- "main": "./lib/abbrev.js", -+ "main": "abbrev.js", - "scripts": { -- "test": "node lib/abbrev.js" -+ "test": "tap test.js --100", -+ "preversion": "npm test", -+ "postversion": "npm publish", -+ "postpublish": "git push origin --all; git push origin --tags" - }, - "repository": "http://github.com/isaacs/abbrev-js", -- "license": { -- "type": "MIT", -- "url": "https://github.com/isaacs/abbrev-js/raw/master/LICENSE" -- } -+ "license": "ISC", -+ "devDependencies": { -+ "tap": "^10.1" -+ }, -+ "files": [ -+ "abbrev.js" -+ ] - } -diff --git a/LICENSE b/LICENSE -index v1.0.4..v1.1.1 100644 ---- a/LICENSE -+++ b/LICENSE -@@ -1,4 +1,27 @@ --Copyright 2009, 2010, 2011 Isaac Z. Schlueter. -+This software is dual-licensed under the ISC and MIT licenses. -+You may use this software under EITHER of the following licenses. -+ -+---------- -+ -+The ISC License -+ -+Copyright (c) Isaac Z. Schlueter and Contributors -+ -+Permission to use, copy, modify, and/or distribute this software for any -+purpose with or without fee is hereby granted, provided that the above -+copyright notice and this permission notice appear in all copies. -+ -+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -+WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -+MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -+ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -+WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -+ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR -+IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -+ -+---------- -+ -+Copyright Isaac Z. Schlueter and Contributors - All rights reserved. - - Permission is hereby granted, free of charge, to any person -diff --git a/lib/abbrev.js b/lib/abbrev.js -deleted file mode 100644 -index v1.0.4..v1.1.1 ---- a/lib/abbrev.js -+++ b/lib/abbrev.js -@@ -1,111 +0,0 @@ -- --module.exports = exports = abbrev.abbrev = abbrev -- --abbrev.monkeyPatch = monkeyPatch -- --function monkeyPatch () { -- Object.defineProperty(Array.prototype, 'abbrev', { -- value: function () { return abbrev(this) }, -- enumerable: false, configurable: true, writable: true -- }) -- -- Object.defineProperty(Object.prototype, 'abbrev', { -- value: function () { return abbrev(Object.keys(this)) }, -- enumerable: false, configurable: true, writable: true -- }) --} -- --function abbrev (list) { -- if (arguments.length !== 1 || !Array.isArray(list)) { -- list = Array.prototype.slice.call(arguments, 0) -- } -- for (var i = 0, l = list.length, args = [] ; i < l ; i ++) { -- args[i] = typeof list[i] === "string" ? list[i] : String(list[i]) -- } -- -- // sort them lexicographically, so that they're next to their nearest kin -- args = args.sort(lexSort) -- -- // walk through each, seeing how much it has in common with the next and previous -- var abbrevs = {} -- , prev = "" -- for (var i = 0, l = args.length ; i < l ; i ++) { -- var current = args[i] -- , next = args[i + 1] || "" -- , nextMatches = true -- , prevMatches = true -- if (current === next) continue -- for (var j = 0, cl = current.length ; j < cl ; j ++) { -- var curChar = current.charAt(j) -- nextMatches = nextMatches && curChar === next.charAt(j) -- prevMatches = prevMatches && curChar === prev.charAt(j) -- if (!nextMatches && !prevMatches) { -- j ++ -- break -- } -- } -- prev = current -- if (j === cl) { -- abbrevs[current] = current -- continue -- } -- for (var a = current.substr(0, j) ; j <= cl ; j ++) { -- abbrevs[a] = current -- a += current.charAt(j) -- } -- } -- return abbrevs --} -- --function lexSort (a, b) { -- return a === b ? 0 : a > b ? 1 : -1 --} -- -- --// tests --if (module === require.main) { -- --var assert = require("assert") --var util = require("util") -- --console.log("running tests") --function test (list, expect) { -- var actual = abbrev(list) -- assert.deepEqual(actual, expect, -- "abbrev("+util.inspect(list)+") === " + util.inspect(expect) + "/n"+ -- "actual: "+util.inspect(actual)) -- actual = abbrev.apply(exports, list) -- assert.deepEqual(abbrev.apply(exports, list), expect, -- "abbrev("+list.map(JSON.stringify).join(",")+") === " + util.inspect(expect) + "/n"+ -- "actual: "+util.inspect(actual)) --} -- --test([ "ruby", "ruby", "rules", "rules", "rules" ], --{ rub: 'ruby' --, ruby: 'ruby' --, rul: 'rules' --, rule: 'rules' --, rules: 'rules' --}) --test(["fool", "foom", "pool", "pope"], --{ fool: 'fool' --, foom: 'foom' --, poo: 'pool' --, pool: 'pool' --, pop: 'pope' --, pope: 'pope' --}) --test(["a", "ab", "abc", "abcd", "abcde", "acde"], --{ a: 'a' --, ab: 'ab' --, abc: 'abc' --, abcd: 'abcd' --, abcde: 'abcde' --, ac: 'acde' --, acd: 'acde' --, acde: 'acde' --}) -- --console.log("pass") -- --} -/ No newline at end of file -diff --git a/abbrev.js b/abbrev.js -new file mode 100644 -index v1.0.4..v1.1.1 ---- a/abbrev.js -+++ b/abbrev.js -@@ -0,0 +1,61 @@ -+module.exports = exports = abbrev.abbrev = abbrev -+ -+abbrev.monkeyPatch = monkeyPatch -+ -+function monkeyPatch () { -+ Object.defineProperty(Array.prototype, 'abbrev', { -+ value: function () { return abbrev(this) }, -+ enumerable: false, configurable: true, writable: true -+ }) -+ -+ Object.defineProperty(Object.prototype, 'abbrev', { -+ value: function () { return abbrev(Object.keys(this)) }, -+ enumerable: false, configurable: true, writable: true -+ }) -+} -+ -+function abbrev (list) { -+ if (arguments.length !== 1 || !Array.isArray(list)) { -+ list = Array.prototype.slice.call(arguments, 0) -+ } -+ for (var i = 0, l = list.length, args = [] ; i < l ; i ++) { -+ args[i] = typeof list[i] === "string" ? list[i] : String(list[i]) -+ } -+ -+ // sort them lexicographically, so that they're next to their nearest kin -+ args = args.sort(lexSort) -+ -+ // walk through each, seeing how much it has in common with the next and previous -+ var abbrevs = {} -+ , prev = "" -+ for (var i = 0, l = args.length ; i < l ; i ++) { -+ var current = args[i] -+ , next = args[i + 1] || "" -+ , nextMatches = true -+ , prevMatches = true -+ if (current === next) continue -+ for (var j = 0, cl = current.length ; j < cl ; j ++) { -+ var curChar = current.charAt(j) -+ nextMatches = nextMatches && curChar === next.charAt(j) -+ prevMatches = prevMatches && curChar === prev.charAt(j) -+ if (!nextMatches && !prevMatches) { -+ j ++ -+ break -+ } -+ } -+ prev = current -+ if (j === cl) { -+ abbrevs[current] = current -+ continue -+ } -+ for (var a = current.substr(0, j) ; j <= cl ; j ++) { -+ abbrevs[a] = current -+ a += current.charAt(j) -+ } -+ } -+ return abbrevs -+} -+ -+function lexSort (a, b) { -+ return a === b ? 0 : a > b ? 1 : -1 -+} - -` - -exports[`smoke-tests/index.js TAP npm explain > should have expected explain output 1`] = ` -abbrev@1.0.4 -node_modules/abbrev - abbrev@"^1.0.4" from the root project - -` - -exports[`smoke-tests/index.js TAP npm fund > should have expected fund output 1`] = ` -project@1.0.0 -\`-- https://github.com/sponsors/isaacs - \`-- promise-all-reject-late@1.0.1 - - -` - -exports[`smoke-tests/index.js TAP npm init > should have successful npm init result 1`] = ` -Wrote to {CWD}/smoke-tests/tap-testdir-index/project/package.json: - -{ - "name": "project", - "version": "1.0.0", - "description": "", - "main": "index.js", - "scripts": { - "test": "echo /"Error: no test specified/" && exit 1" - }, - "keywords": [], - "author": "", - "license": "ISC" -} - - - -` - -exports[`smoke-tests/index.js TAP npm install dev dep > should have expected dev dep added lockfile result 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "lockfileVersion": 2, - "requires": true, - "packages": { - "": { - "name": "project", - "version": "1.0.0", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - }, - "devDependencies": { - "promise-all-reject-late": "^1.0.1" - } - }, - "node_modules/abbrev": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.4.tgz", - "integrity": "sha1-vVWuXkE7oXIu5Mq6H26hBBSlns0=" - }, - "node_modules/promise-all-reject-late": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz", - "integrity": "sha512-vuf0Lf0lOxyQREH7GDIOUMLS7kz+gs8i6B+Yi8dC68a2sychGrHTJYghMBD6k7eUcH0H5P73EckCA48xijWqXw==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - } - }, - "dependencies": { - "abbrev": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.4.tgz", - "integrity": "sha1-vVWuXkE7oXIu5Mq6H26hBBSlns0=" - }, - "promise-all-reject-late": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz", - "integrity": "sha512-vuf0Lf0lOxyQREH7GDIOUMLS7kz+gs8i6B+Yi8dC68a2sychGrHTJYghMBD6k7eUcH0H5P73EckCA48xijWqXw==", - "dev": true - } - } -} - -` - -exports[`smoke-tests/index.js TAP npm install dev dep > should have expected dev dep added package.json result 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "description": "", - "main": "index.js", - "scripts": { - "test": "echo /"Error: no test specified/" && exit 1" - }, - "keywords": [], - "author": "", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - }, - "devDependencies": { - "promise-all-reject-late": "^1.0.1" - } -} - -` - -exports[`smoke-tests/index.js TAP npm install dev dep > should have expected dev dep added reify output 1`] = ` - -added 1 package - -1 package is looking for funding - run \`npm fund\` for details - -` - -exports[`smoke-tests/index.js TAP npm install prodDep@version > should have expected install reify output 1`] = ` - -added 1 package - -` - -exports[`smoke-tests/index.js TAP npm install prodDep@version > should have expected lockfile result 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "lockfileVersion": 2, - "requires": true, - "packages": { - "": { - "name": "project", - "version": "1.0.0", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - } - }, - "node_modules/abbrev": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.4.tgz", - "integrity": "sha1-vVWuXkE7oXIu5Mq6H26hBBSlns0=" - } - }, - "dependencies": { - "abbrev": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.4.tgz", - "integrity": "sha1-vVWuXkE7oXIu5Mq6H26hBBSlns0=" - } - } -} - -` - -exports[`smoke-tests/index.js TAP npm install prodDep@version > should have expected package.json result 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "description": "", - "main": "index.js", - "scripts": { - "test": "echo /"Error: no test specified/" && exit 1" - }, - "keywords": [], - "author": "", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - } -} - -` - -exports[`smoke-tests/index.js TAP npm ls > should have expected ls output 1`] = ` -project@1.0.0 {CWD}/smoke-tests/tap-testdir-index/project -+-- abbrev@1.0.4 -\`-- promise-all-reject-late@1.0.1 - - -` - -exports[`smoke-tests/index.js TAP npm outdated > should have expected outdated output 1`] = ` -Package Current Wanted Latest Location Depended by -abbrev 1.0.4 1.1.1 1.1.1 node_modules/abbrev project - -` - -exports[`smoke-tests/index.js TAP npm pkg > should have expected npm pkg delete modified package.json result 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "description": "", - "main": "index.js", - "scripts": { - "test": "echo /"Error: no test specified/" && exit 1", - "hello": "echo Hello" - }, - "keywords": [], - "author": "", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - } -} - -` - -exports[`smoke-tests/index.js TAP npm pkg > should have expected npm pkg set modified package.json result 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "description": "", - "main": "index.js", - "scripts": { - "test": "echo /"Error: no test specified/" && exit 1", - "hello": "echo Hello" - }, - "keywords": [], - "author": "", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - }, - "tap": { - "test-env": [ - "LC_ALL=sk" - ] - } -} - -` - -exports[`smoke-tests/index.js TAP npm pkg > should have expected pkg delete output 1`] = ` - -` - -exports[`smoke-tests/index.js TAP npm pkg > should have expected pkg get output 1`] = ` -"ISC" - -` - -exports[`smoke-tests/index.js TAP npm pkg > should have expected pkg set output 1`] = ` - -` - -exports[`smoke-tests/index.js TAP npm pkg > should print package.json contents 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "description": "", - "ma", - "scripts": { - "test": "echo /"Error: no test specified/" && exit 1", - "hello": "echo Hello" - }, - "keywords": [], - "author": "", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - }, - "tap": { - "test-env": [ - "LC_ALL=sk" - ] - } -} - -` - -exports[`smoke-tests/index.js TAP npm prefix > should have expected prefix output 1`] = ` -{CWD}/smoke-tests/tap-testdir-index/project - -` - -exports[`smoke-tests/index.js TAP npm run-script > should have expected run-script output 1`] = ` - -> project@1.0.0 hello -> echo Hello - -Hello - -` - -exports[`smoke-tests/index.js TAP npm set-script > should have expected script added package.json result 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "description": "", - "main": "index.js", - "scripts": { - "test": "echo /"Error: no test specified/" && exit 1", - "hello": "echo Hello" - }, - "keywords": [], - "author": "", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - }, - "devDependencies": { - "promise-all-reject-late": "^1.0.1" - } -} - -` - -exports[`smoke-tests/index.js TAP npm set-script > should have expected set-script output 1`] = ` - -` - -exports[`smoke-tests/index.js TAP npm uninstall > should have expected uninstall lockfile result 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "lockfileVersion": 2, - "requires": true, - "packages": { - "": { - "name": "project", - "version": "1.0.0", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - } - }, - "node_modules/abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - } - }, - "dependencies": { - "abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - } - } -} - -` - -exports[`smoke-tests/index.js TAP npm uninstall > should have expected uninstall package.json result 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "description": "", - "main": "index.js", - "scripts": { - "test": "echo /"Error: no test specified/" && exit 1", - "hello": "echo Hello" - }, - "keywords": [], - "author": "", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - } -} - -` - -exports[`smoke-tests/index.js TAP npm uninstall > should have expected uninstall reify output 1`] = ` - -removed 1 package - -` - -exports[`smoke-tests/index.js TAP npm update dep > should have expected update lockfile result 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "lockfileVersion": 2, - "requires": true, - "packages": { - "": { - "name": "project", - "version": "1.0.0", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - }, - "devDependencies": { - "promise-all-reject-late": "^1.0.1" - } - }, - "node_modules/abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - }, - "node_modules/promise-all-reject-late": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz", - "integrity": "sha512-vuf0Lf0lOxyQREH7GDIOUMLS7kz+gs8i6B+Yi8dC68a2sychGrHTJYghMBD6k7eUcH0H5P73EckCA48xijWqXw==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - } - }, - "dependencies": { - "abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - }, - "promise-all-reject-late": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-all-reject-late/-/promise-all-reject-late-1.0.1.tgz", - "integrity": "sha512-vuf0Lf0lOxyQREH7GDIOUMLS7kz+gs8i6B+Yi8dC68a2sychGrHTJYghMBD6k7eUcH0H5P73EckCA48xijWqXw==", - "dev": true - } - } -} - -` - -exports[`smoke-tests/index.js TAP npm update dep > should have expected update package.json result 1`] = ` -{ - "name": "project", - "version": "1.0.0", - "description": "", - "main": "index.js", - "scripts": { - "test": "echo /"Error: no test specified/" && exit 1", - "hello": "echo Hello" - }, - "keywords": [], - "author": "", - "license": "ISC", - "dependencies": { - "abbrev": "^1.0.4" - }, - "devDependencies": { - "promise-all-reject-late": "^1.0.1" - } -} - -` - -exports[`smoke-tests/index.js TAP npm update dep > should have expected update reify output 1`] = ` - -changed 1 package - -1 package is looking for funding - run \`npm fund\` for details - -` - -exports[`smoke-tests/index.js TAP npm view > should have expected view output 1`] = ` - -abbrev@1.0.4 | MIT | deps: none | versions: 8 -Like ruby's abbrev module, but in js -https://github.com/isaacs/abbrev-js#readme - -dist -.tarball: https://registry.npmjs.org/abbrev/-/abbrev-1.0.4.tgz -.shasum: bd55ae5e413ba1722ee4caba1f6ea10414a59ecd - -maintainers: -- nlf <quitlahok@gmail.com> -- ruyadorno <ruyadorno@hotmail.com> -- darcyclarke <darcy@darcyclarke.me> -- adam_baldwin <evilpacket@gmail.com> -- isaacs <i@izs.me> - -dist-tags: -latest: 1.1.1 - -published over a year ago by isaacs <i@izs.me> - -` diff --git a/tap-snapshots/test/lib/commands/audit.js.test.cjs b/tap-snapshots/test/lib/commands/audit.js.test.cjs new file mode 100644 index 0000000..3e7658c --- /dev/null +++ b/tap-snapshots/test/lib/commands/audit.js.test.cjs @@ -0,0 +1,353 @@ +/* IMPORTANT + * This snapshot file is auto-generated, but designed for humans. + * It should be checked into source control and tracked carefully. + * Re-generate by setting TAP_SNAPSHOT=1 and running tests. + * Make sure to inspect the output below. Do not ignore changes! + */ +'use strict' +exports[`test/lib/commands/audit.js TAP audit fix - bulk endpoint > lockfile has test-dep-a@1.0.1 1`] = ` +{ + "name": "test-dep", + "version": "1.0.0", + "lockfileVersion": 2, + "requires": true, + "packages": { + "": { + "name": "test-dep", + "version": "1.0.0", + "dependencies": { + "test-dep-a": "*" + } + }, + "node_modules/test-dep-a": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/test-dep-a/-/test-dep-a-1.0.1.tgz" + } + }, + "dependencies": { + "test-dep-a": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/test-dep-a/-/test-dep-a-1.0.1.tgz" + } + } +} + +` + +exports[`test/lib/commands/audit.js TAP audit fix - bulk endpoint > must match snapshot 1`] = ` + +added 1 package, and audited 2 packages in xxx + +found 0 vulnerabilities +` + +exports[`test/lib/commands/audit.js TAP audit signatures ignores optional dependencies > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has a verified registry signature + +` + +exports[`test/lib/commands/audit.js TAP audit signatures json output with invalid and missing signatures > must match snapshot 1`] = ` +{ + "invalid": [ + { + "name": "kms-demo", + "version": "1.0.0", + "location": "node_modules/kms-demo", + "resolved": "https://registry.npmjs.org/kms-demo/-/kms-demo-1.0.0.tgz", + "integrity": "sha512-QqZ7VJ/8xPkS9s2IWB7Shj3qTJdcRyeXKbPQnsZjsPEwvutGv0EGeVchPcauoiDFJlGbZMFq5GDCurAGNSghJQ==", + "signature": "bogus", + "keyid": "SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA" + } + ], + "missing": [ + { + "name": "async", + "version": "1.1.1", + "location": "node_modules/async", + "resolved": "https://registry.npmjs.org/async/-/async-1.1.1.tgz" + } + ] +} +` + +exports[`test/lib/commands/audit.js TAP audit signatures json output with invalid signatures > must match snapshot 1`] = ` +{ + "invalid": [ + { + "name": "kms-demo", + "version": "1.0.0", + "location": "node_modules/kms-demo", + "resolved": "https://registry.npmjs.org/kms-demo/-/kms-demo-1.0.0.tgz", + "integrity": "sha512-QqZ7VJ/8xPkS9s2IWB7Shj3qTJdcRyeXKbPQnsZjsPEwvutGv0EGeVchPcauoiDFJlGbZMFq5GDCurAGNSghJQ==", + "signature": "bogus", + "keyid": "SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA" + } + ], + "missing": [] +} +` + +exports[`test/lib/commands/audit.js TAP audit signatures json output with valid signatures > must match snapshot 1`] = ` +{ + "invalid": [], + "missing": [] +} +` + +exports[`test/lib/commands/audit.js TAP audit signatures multiple registries with keys and signatures > must match snapshot 1`] = ` +audited 2 packages in xxx + +2 packages have verified registry signatures + +` + +exports[`test/lib/commands/audit.js TAP audit signatures omit dev dependencies with missing signature > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has a verified registry signature + +` + +exports[`test/lib/commands/audit.js TAP audit signatures output details about missing signatures > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has a missing registry signature but the registry is providing signing keys: + +kms-demo@1.0.0 (https://registry.npmjs.org/) +` + +exports[`test/lib/commands/audit.js TAP audit signatures third-party registry with invalid signatures errors > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has an invalid registry signature: + +@npmcli/arborist@1.0.14 (https://verdaccio-clone.org) + +Someone might have tampered with this package since it was published on the registry! + +` + +exports[`test/lib/commands/audit.js TAP audit signatures third-party registry with keys and missing signatures errors > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has a missing registry signature but the registry is providing signing keys: + +@npmcli/arborist@1.0.14 (https://verdaccio-clone.org) +` + +exports[`test/lib/commands/audit.js TAP audit signatures third-party registry with keys and signatures > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has a verified registry signature + +` + +exports[`test/lib/commands/audit.js TAP audit signatures with both invalid and missing signatures > must match snapshot 1`] = ` +audited 2 packages in xxx + +1 package has a missing registry signature but the registry is providing signing keys: + +async@1.1.1 (https://registry.npmjs.org/) + +1 package has an invalid registry signature: + +kms-demo@1.0.0 (https://registry.npmjs.org/) + +Someone might have tampered with this package since it was published on the registry! + +` + +exports[`test/lib/commands/audit.js TAP audit signatures with bundled and peer deps and no signatures > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has a verified registry signature + +` + +exports[`test/lib/commands/audit.js TAP audit signatures with invalid signatures > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has an invalid registry signature: + +kms-demo@1.0.0 (https://registry.npmjs.org/) + +Someone might have tampered with this package since it was published on the registry! + +` + +exports[`test/lib/commands/audit.js TAP audit signatures with invalid signtaures and color output enabled > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has an invalid registry signature: + +kms-demo@1.0.0 (https://registry.npmjs.org/) + +Someone might have tampered with this package since it was published on the registry! + +` + +exports[`test/lib/commands/audit.js TAP audit signatures with keys but missing signature > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has a missing registry signature but the registry is providing signing keys: + +kms-demo@1.0.0 (https://registry.npmjs.org/) +` + +exports[`test/lib/commands/audit.js TAP audit signatures with multiple invalid signatures > must match snapshot 1`] = ` +audited 2 packages in xxx + +2 packages have invalid registry signatures: + +async@1.1.1 (https://registry.npmjs.org/) +kms-demo@1.0.0 (https://registry.npmjs.org/) + +Someone might have tampered with these packages since they where published on the registry! + +` + +exports[`test/lib/commands/audit.js TAP audit signatures with multiple missing signatures > must match snapshot 1`] = ` +audited 2 packages in xxx + +2 packages have missing registry signatures but the registry is providing signing keys: + +async@1.1.1 (https://registry.npmjs.org/) +kms-demo@1.0.0 (https://registry.npmjs.org/) +` + +exports[`test/lib/commands/audit.js TAP audit signatures with multiple valid signatures and one invalid > must match snapshot 1`] = ` +audited 3 packages in xxx + +2 packages have verified registry signatures + +1 package has an invalid registry signature: + +node-fetch@1.6.0 (https://registry.npmjs.org/) + +Someone might have tampered with this package since it was published on the registry! + +` + +exports[`test/lib/commands/audit.js TAP audit signatures with valid and missing signatures > must match snapshot 1`] = ` +audited 2 packages in xxx + +1 package has a verified registry signature + +1 package has a missing registry signature but the registry is providing signing keys: + +async@1.1.1 (https://registry.npmjs.org/) +` + +exports[`test/lib/commands/audit.js TAP audit signatures with valid signatures > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has a verified registry signature + +` + +exports[`test/lib/commands/audit.js TAP audit signatures with valid signatures using alias > must match snapshot 1`] = ` +audited 1 package in xxx + +1 package has a verified registry signature + +` + +exports[`test/lib/commands/audit.js TAP audit signatures workspaces verifies registry deps and ignores local workspace deps > must match snapshot 1`] = ` +audited 3 packages in xxx + +3 packages have verified registry signatures + +` + +exports[`test/lib/commands/audit.js TAP audit signatures workspaces verifies registry deps when filtering by workspace name > must match snapshot 1`] = ` +audited 2 packages in xxx + +2 packages have verified registry signatures + +` + +exports[`test/lib/commands/audit.js TAP fallback audit > must match snapshot 1`] = ` +# npm audit report + +test-dep-a 1.0.0 +Severity: high +Test advisory 100 - https://github.com/advisories/GHSA-100 +fix available via \`npm audit fix\` +node_modules/test-dep-a + +1 high severity vulnerability + +To address all issues, run: + npm audit fix +` + +exports[`test/lib/commands/audit.js TAP json audit > must match snapshot 1`] = ` +{ + "auditReportVersion": 2, + "vulnerabilities": { + "test-dep-a": { + "name": "test-dep-a", + "severity": "high", + "isDirect": true, + "via": [ + { + "source": 100, + "name": "test-dep-a", + "dependency": "test-dep-a", + "title": "Test advisory 100", + "url": "https://github.com/advisories/GHSA-100", + "severity": "high", + "cwe": [ + "cwe-0" + ], + "cvss": { + "score": 0 + }, + "range": "*" + } + ], + "effects": [], + "range": "*", + "nodes": [ + "node_modules/test-dep-a" + ], + "fixAvailable": false + } + }, + "metadata": { + "vulnerabilities": { + "info": 0, + "low": 0, + "moderate": 0, + "high": 1, + "critical": 0, + "total": 1 + }, + "dependencies": { + "prod": 2, + "dev": 0, + "optional": 0, + "peer": 0, + "peerOptional": 0, + "total": 1 + } + } +} +` + +exports[`test/lib/commands/audit.js TAP normal audit > must match snapshot 1`] = ` +# npm audit report + +test-dep-a 1.0.0 +Severity: high +Test advisory 100 - https://github.com/advisories/GHSA-100 +fix available via \`npm audit fix\` +node_modules/test-dep-a + +1 high severity vulnerability + +To address all issues, run: + npm audit fix +` diff --git a/tap-snapshots/test/lib/commands/cache.js.test.cjs b/tap-snapshots/test/lib/commands/cache.js.test.cjs new file mode 100644 index 0000000..1cd6994 --- /dev/null +++ b/tap-snapshots/test/lib/commands/cache.js.test.cjs @@ -0,0 +1,63 @@ +/* IMPORTANT + * This snapshot file is auto-generated, but designed for humans. + * It should be checked into source control and tracked carefully. + * Re-generate by setting TAP_SNAPSHOT=1 and running tests. + * Make sure to inspect the output below. Do not ignore changes! + */ +'use strict' +exports[`test/lib/commands/cache.js TAP cache ls > logs cache entries 1`] = ` +make-fetch-happen:request-cache:https://registry.npmjs.org/test-package +make-fetch-happen:request-cache:https://registry.npmjs.org/test-package/-/test-package-1.0.0.tgz +` + +exports[`test/lib/commands/cache.js TAP cache ls corrupted > logs cache entries with bad data 1`] = ` +make-fetch-happen:request-cache:https://registry.npmjs.org/corrupted +make-fetch-happen:request-cache:https://registry.npmjs.org/corrupted/-/corrupted-3.1.0.tgz +` + +exports[`test/lib/commands/cache.js TAP cache ls missing packument version not an object > logs cache entry for packument 1`] = ` +make-fetch-happen:request-cache:https://registry.npmjs.org/missing-version +` + +exports[`test/lib/commands/cache.js TAP cache ls nonpublic registry > logs cache entry for extemporaneously and its tarball 1`] = ` +make-fetch-happen:request-cache:https://somerepo.github.org/aabbcc/ +make-fetch-happen:request-cache:https://somerepo.github.org/extemporaneously +` + +exports[`test/lib/commands/cache.js TAP cache ls pkgs > logs cache entries for npm and webpack and one webpack tgz 1`] = ` +make-fetch-happen:request-cache:https://registry.npmjs.org/npm +make-fetch-happen:request-cache:https://registry.npmjs.org/npm/-/npm-1.2.0.tgz +make-fetch-happen:request-cache:https://registry.npmjs.org/webpack +make-fetch-happen:request-cache:https://registry.npmjs.org/webpack/-/webpack-4.47.0.tgz +` + +exports[`test/lib/commands/cache.js TAP cache ls scoped and scoped slash > logs cache entries for @gar and @fritzy 1`] = ` +make-fetch-happen:request-cache:https://registry.npmjs.org/@fritzy%2fstaydown +make-fetch-happen:request-cache:https://registry.npmjs.org/@gar%2fnpm-expansion +` + +exports[`test/lib/commands/cache.js TAP cache ls special > logs cache entries for foo 1`] = ` +make-fetch-happen:request-cache:https://registry.npmjs.org/foo +make-fetch-happen:request-cache:https://registry.npmjs.org/foo/-/foo-1.2.3-beta.tgz +` + +exports[`test/lib/commands/cache.js TAP cache rm > logs deleting single entry 1`] = ` +Deleted: make-fetch-happen:request-cache:https://registry.npmjs.org/test-package/-/test-package-1.0.0.tgz +` + +exports[`test/lib/commands/cache.js TAP cache verify > shows verified cache output 1`] = ` +Cache verified and compressed ({PATH}) +Content verified: 0 (0 bytes) +Index entries: 0 +Finished in xxxs +` + +exports[`test/lib/commands/cache.js TAP cache verify w/ extra output > shows extra output 1`] = ` +Cache verified and compressed ({PATH}) +Content verified: 17057 (1644485260 bytes) +Corrupted content removed: 12345 +Content garbage-collected: 1144 (248164665 bytes) +Missing content: 92 +Index entries: 20175 +Finished in xxxs +` diff --git a/tap-snapshots/test/lib/commands/ci.js.test.cjs b/tap-snapshots/test/lib/commands/ci.js.test.cjs deleted file mode 100644 index d6a7471..0000000 --- a/tap-snapshots/test/lib/commands/ci.js.test.cjs +++ /dev/null @@ -1,13 +0,0 @@ -/* IMPORTANT - * This snapshot file is auto-generated, but designed for humans. - * It should be checked into source control and tracked carefully. - * Re-generate by setting TAP_SNAPSHOT=1 and running tests. - * Make sure to inspect the output below. Do not ignore changes! - */ -'use strict' -exports[`test/lib/commands/ci.js TAP should throw error when ideal inventory mismatches virtual > must match snapshot 1`] = ` -\`npm ci\` can only install packages when your package.json and package-lock.json or npm-shrinkwrap.json are in sync. Please update your lock file with \`npm install\` before continuing. - -Invalid: lock file's foo@1.0.0 does not satisfy foo@2.0.0 - -` diff --git a/tap-snapshots/test/lib/commands/completion.js.test.cjs b/tap-snapshots/test/lib/commands/completion.js.test.cjs index 13a3f66..3e7125b 100644 --- a/tap-snapshots/test/lib/commands/completion.js.test.cjs +++ b/tap-snapshots/test/lib/commands/completion.js.test.cjs @@ -44,72 +44,82 @@ exports[`test/lib/commands/completion.js TAP completion double dashes escape fro Array [ Array [ String( - ci - install-ci-test - install - install-test - uninstall - cache - config - set - get - update - outdated - prune - pack - find-dupes - dedupe - hook - rebuild - link - publish - star - stars - unstar - adduser - login - logout - unpublish - owner access - team - deprecate - shrinkwrap - token - profile + adduser audit - fund - org - help - ls - ll - search - view - init - version - edit - explore - docs - repo bugs - root - prefix - bin - whoami + cache + ci + completion + config + dedupe + deprecate diff dist-tag - ping - pkg - test - stop - start - restart - run-script - set-script - completion + docs doctor + edit exec explain + explore + find-dupes + fund + get + help + hook + init + install + install-ci-test + install-test + link + ll + login + logout + ls + org + outdated + owner + pack + ping + pkg + prefix + profile + prune + publish + query + rebuild + repo + restart + root + run-script + search + set + shrinkwrap + star + stars + start + stop + team + test + token + uninstall + unpublish + unstar + update + version + view + whoami + author + home + issues + info + show + find + add + unlink + remove + rm + r un rb list @@ -143,40 +153,25 @@ Array [ isnt isnta isntal + isntall install-clean isntall-clean hlep dist-tags upgrade udpate - login - add-user - author - home - issues - info - show - find - add - unlink - remove - rm - r rum sit urn ogr + add-user ), ], ] ` exports[`test/lib/commands/completion.js TAP completion filtered subcommands > filtered subcommands 1`] = ` -Array [ - Array [ - "public", - ], -] +Array [] ` exports[`test/lib/commands/completion.js TAP completion flags > flags 1`] = ` @@ -197,12 +192,12 @@ exports[`test/lib/commands/completion.js TAP completion multiple command names > Array [ Array [ String( - adduser access + adduser audit - add-user author add + add-user ), ], ] @@ -220,15 +215,11 @@ exports[`test/lib/commands/completion.js TAP completion subcommand completion > Array [ Array [ String( - public - restricted + get grant + list revoke - ls-packages - ls-collaborators - edit - 2fa-required - 2fa-not-required + set ), ], ] diff --git a/tap-snapshots/test/lib/commands/config.js.test.cjs b/tap-snapshots/test/lib/commands/config.js.test.cjs index 8e97915..93a3e9a 100644 --- a/tap-snapshots/test/lib/commands/config.js.test.cjs +++ b/tap-snapshots/test/lib/commands/config.js.test.cjs @@ -20,7 +20,7 @@ exports[`test/lib/commands/config.js TAP config list --json > output matches sna "also": null, "audit": true, "audit-level": null, - "auth-type": "legacy", + "auth-type": "web", "before": null, "bin-links": true, "browser": null, @@ -60,8 +60,8 @@ exports[`test/lib/commands/config.js TAP config list --json > output matches sna "git": "git", "git-tag-version": true, "global": false, - "global-style": false, "globalconfig": "{GLOBALPREFIX}/npmrc", + "global-style": false, "heading": "npm", "https-proxy": null, "if-present": false, @@ -81,6 +81,8 @@ exports[`test/lib/commands/config.js TAP config list --json > output matches sna "init.license": "ISC", "init.module": "{HOME}/.npm-init.js", "init.version": "1.0.0", + "install-links": true, + "install-strategy": "hoisted", "key": null, "legacy-bundling": false, "legacy-peer-deps": false, @@ -89,18 +91,18 @@ exports[`test/lib/commands/config.js TAP config list --json > output matches sna "location": "user", "lockfile-version": null, "loglevel": "notice", + "logs-dir": null, "logs-max": 10, "long": false, "maxsockets": 15, "message": "%s", "node-options": null, - "node-version": "{NODE-VERSION}", "noproxy": [ "" ], - "npm-version": "{NPM-VERSION}", "offline": false, "omit": [], + "omit-lockfile-registry-resolved": false, "only": null, "optional": null, "otp": null, @@ -118,6 +120,7 @@ exports[`test/lib/commands/config.js TAP config list --json > output matches sna "read-only": false, "rebuild-bundle": true, "registry": "https://registry.npmjs.org/", + "replace-registry-host": "npmjs", "save": true, "save-bundle": false, "save-dev": false, @@ -136,8 +139,6 @@ exports[`test/lib/commands/config.js TAP config list --json > output matches sna "shrinkwrap": true, "sign-git-commit": false, "sign-git-tag": false, - "sso-poll-frequency": 500, - "sso-type": "oauth", "strict-peer-deps": false, "strict-ssl": true, "tag": "latest", @@ -155,6 +156,7 @@ exports[`test/lib/commands/config.js TAP config list --json > output matches sna "which": null, "workspace": [], "workspaces": null, + "workspaces-update": true, "yes": null, "metrics-registry": "https://registry.npmjs.org/" } @@ -170,7 +172,7 @@ allow-same-version = false also = null audit = true audit-level = null -auth-type = "legacy" +auth-type = "web" before = null bin-links = true browser = null @@ -232,6 +234,8 @@ init.author.url = "" init.license = "ISC" init.module = "{HOME}/.npm-init.js" init.version = "1.0.0" +install-links = true +install-strategy = "hoisted" json = false key = null legacy-bundling = false @@ -241,17 +245,17 @@ local-address = null location = "user" lockfile-version = null loglevel = "notice" +logs-dir = null logs-max = 10 ; long = false ; overridden by cli maxsockets = 15 message = "%s" metrics-registry = "https://registry.npmjs.org/" node-options = null -node-version = "{NODE-VERSION}" noproxy = [""] -npm-version = "{NPM-VERSION}" offline = false omit = [] +omit-lockfile-registry-resolved = false only = null optional = null otp = null @@ -270,6 +274,7 @@ proxy = null read-only = false rebuild-bundle = true registry = "https://registry.npmjs.org/" +replace-registry-host = "npmjs" save = true save-bundle = false save-dev = false @@ -288,8 +293,6 @@ shell = "{SHELL}" shrinkwrap = true sign-git-commit = false sign-git-tag = false -sso-poll-frequency = 500 -sso-type = "oauth" strict-peer-deps = false strict-ssl = true tag = "latest" @@ -308,6 +311,7 @@ viewer = "{VIEWER}" which = null workspace = [] workspaces = null +workspaces-update = true yes = null ; "global" config from {GLOBALPREFIX}/npmrc @@ -338,6 +342,9 @@ prefix = "{LOCALPREFIX}" userconfig = "{HOME}/.npmrc" ; node bin location = {EXECPATH} +; node version = {NODE-VERSION} +; npm local prefix = {LOCALPREFIX} +; npm version = {NPM-VERSION} ; cwd = {NPMDIR} ; HOME = {HOME} ; Run \`npm config ls -l\` to show all defaults. @@ -347,10 +354,14 @@ exports[`test/lib/commands/config.js TAP config list with publishConfig > output ; "cli" config from command line options cache = "{NPMDIR}/test/lib/commands/tap-testdir-config-config-list-with-publishConfig-sandbox/cache" +location = "project" prefix = "{LOCALPREFIX}" userconfig = "{HOME}/.npmrc" ; node bin location = {EXECPATH} +; node version = {NODE-VERSION} +; npm local prefix = {LOCALPREFIX} +; npm version = {NPM-VERSION} ; cwd = {NPMDIR} ; HOME = {HOME} ; Run \`npm config ls -l\` to show all defaults. @@ -379,6 +390,9 @@ prefix = "{LOCALPREFIX}" userconfig = "{HOME}/.npmrc" ; node bin location = {EXECPATH} +; node version = {NODE-VERSION} +; npm local prefix = {LOCALPREFIX} +; npm version = {NPM-VERSION} ; cwd = {NPMDIR} ; HOME = {HOME} ; Run \`npm config ls -l\` to show all defaults. diff --git a/tap-snapshots/test/lib/commands/dist-tag.js.test.cjs b/tap-snapshots/test/lib/commands/dist-tag.js.test.cjs index 73cc223..da79444 100644 --- a/tap-snapshots/test/lib/commands/dist-tag.js.test.cjs +++ b/tap-snapshots/test/lib/commands/dist-tag.js.test.cjs @@ -21,7 +21,7 @@ latest: 1.0.0 ` exports[`test/lib/commands/dist-tag.js TAP ls on missing package > should log no dist-tag found msg 1`] = ` -dist-tag ls Couldn't get dist-tag data for foo@latest +dist-tag ls Couldn't get dist-tag data for foo@* ` diff --git a/tap-snapshots/test/lib/commands/doctor.js.test.cjs b/tap-snapshots/test/lib/commands/doctor.js.test.cjs new file mode 100644 index 0000000..8d21f98 --- /dev/null +++ b/tap-snapshots/test/lib/commands/doctor.js.test.cjs @@ -0,0 +1,1647 @@ +/* IMPORTANT + * This snapshot file is auto-generated, but designed for humans. + * It should be checked into source control and tracked carefully. + * Re-generate by setting TAP_SNAPSHOT=1 and running tests. + * Make sure to inspect the output below. Do not ignore changes! + */ +'use strict' +exports[`test/lib/commands/doctor.js TAP all clear > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP all clear > output 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-all-clear/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP all clear in color > everything is ok in color 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-all-clear-in-color/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP all clear in color > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP bad proxy > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP bad proxy > output 1`] = ` +Check  Value  Recommendation/Notes +npm ping  not ok unsupported proxy protocol: 'ssh:' +npm -v  not ok Error: unsupported proxy protocol: 'ssh:' +node -v  not ok Error: unsupported proxy protocol: 'ssh:' +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-bad-proxy/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP cacache badContent > corrupted cache content 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-cacache-badContent/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 2 tarballs +` + +exports[`test/lib/commands/doctor.js TAP cacache badContent > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 1, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 2 + } + ), + ], + ], + "warn": Array [ + Array [ + "verifyCachedFiles", + "Corrupted content removed: 1", + ], + Array [ + "verifyCachedFiles", + "Cache issues have been fixed", + ], + ], +} +` + +exports[`test/lib/commands/doctor.js TAP cacache missingContent > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 1, + "verifiedContent": 2 + } + ), + ], + ], + "warn": Array [ + Array [ + "verifyCachedFiles", + "Missing content: 1", + ], + Array [ + "verifyCachedFiles", + "Cache issues have been fixed", + ], + ], +} +` + +exports[`test/lib/commands/doctor.js TAP cacache missingContent > missing content 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-cacache-missingContent/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 2 tarballs +` + +exports[`test/lib/commands/doctor.js TAP cacache reclaimedCount > content garbage collected 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-cacache-reclaimedCount/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 2 tarballs +` + +exports[`test/lib/commands/doctor.js TAP cacache reclaimedCount > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 1, + "missingContent": 0, + "verifiedContent": 2 + } + ), + ], + ], + "warn": Array [ + Array [ + "verifyCachedFiles", + "Content garbage-collected: 1 (undefined bytes)", + ], + Array [ + "verifyCachedFiles", + "Cache issues have been fixed", + ], + ], +} +` + +exports[`test/lib/commands/doctor.js TAP discrete checks cache > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP discrete checks cache > output 1`] = ` +Check  Value  Recommendation/Notes +Perms check on cached files ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP discrete checks git > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP discrete checks git > output 1`] = ` +Check Value  Recommendation/Notes +` + +exports[`test/lib/commands/doctor.js TAP discrete checks invalid environment > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP discrete checks invalid environment > output 1`] = ` +Check  Value  Recommendation/Notes +git executable in PATH  ok  /path/to/git +global bin folder in PATH not ok Error: Add {CWD}/test/lib/commands/tap-testdir-doctor-discrete-checks-invalid-environment/global/bin to your $PATH +` + +exports[`test/lib/commands/doctor.js TAP discrete checks permissions - not windows > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP discrete checks permissions - not windows > output 1`] = ` +Check  Value  Recommendation/Notes +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +` + +exports[`test/lib/commands/doctor.js TAP discrete checks permissions - windows > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP discrete checks permissions - windows > output 1`] = ` +Check Value  Recommendation/Notes +` + +exports[`test/lib/commands/doctor.js TAP discrete checks ping > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP discrete checks ping > output 1`] = ` +Check  Value  Recommendation/Notes +npm ping ok   +` + +exports[`test/lib/commands/doctor.js TAP discrete checks registry > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP discrete checks registry > output 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm config get registry ok  using default registry (https://registry.npmjs.org/) +` + +exports[`test/lib/commands/doctor.js TAP discrete checks versions > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP discrete checks versions > output 1`] = ` +Check  Value  Recommendation/Notes +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v ok  current: v1.0.0, recommended: v1.0.0 +` + +exports[`test/lib/commands/doctor.js TAP error reading directory > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [ + Array [ + "checkFilesPermission", + "error reading directory {CWD}/test/lib/commands/tap-testdir-doctor-error-reading-directory/cache", + ], + Array [ + "checkFilesPermission", + "error reading directory {CWD}/test/lib/commands/tap-testdir-doctor-error-reading-directory/prefix/node_modules", + ], + Array [ + "checkFilesPermission", + "error reading directory {CWD}/test/lib/commands/tap-testdir-doctor-error-reading-directory/global/lib/node_modules", + ], + Array [ + "checkFilesPermission", + "error reading directory {CWD}/test/lib/commands/tap-testdir-doctor-error-reading-directory/prefix/node_modules/.bin", + ], + Array [ + "checkFilesPermission", + "error reading directory {CWD}/test/lib/commands/tap-testdir-doctor-error-reading-directory/global/bin", + ], + ], +} +` + +exports[`test/lib/commands/doctor.js TAP error reading directory > readdir error 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-error-reading-directory/global/bin +Perms check on cached files  not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-error-reading-directory/cache (should be owned by current user) +Perms check on local node_modules  not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-error-reading-directory/prefix/node_modules (should be owned by current user) +Perms check on global node_modules not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-error-reading-directory/global/lib/node_modules +Perms check on local bin folder  not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-error-reading-directory/prefix/node_modules/.bin +Perms check on global bin folder  not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-error-reading-directory/global/bin +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP incorrect owner > incorrect owner 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-owner/global/bin +Perms check on cached files  not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-owner/cache (should be owned by current user) +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP incorrect owner > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [ + Array [ + "checkFilesPermission", + "should be owner of {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-owner/cache/_cacache", + ], + ], +} +` + +exports[`test/lib/commands/doctor.js TAP incorrect permissions > incorrect owner 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-permissions/global/bin +Perms check on cached files  not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-permissions/cache (should be owned by current user) +Perms check on local node_modules  not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-permissions/prefix/node_modules (should be owned by current user) +Perms check on global node_modules not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-permissions/global/lib/node_modules +Perms check on local bin folder  not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-permissions/prefix/node_modules/.bin +Perms check on global bin folder  not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-permissions/global/bin +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP incorrect permissions > logs 1`] = ` +Object { + "error": Array [ + Array [ + "checkFilesPermission", + "Missing permissions on {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-permissions/cache (expect: readable)", + ], + Array [ + "checkFilesPermission", + "Missing permissions on {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-permissions/prefix/node_modules (expect: readable, writable)", + ], + Array [ + "checkFilesPermission", + "Missing permissions on {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-permissions/global/lib/node_modules (expect: readable)", + ], + Array [ + "checkFilesPermission", + "Missing permissions on {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-permissions/prefix/node_modules/.bin (expect: readable, writable, executable)", + ], + Array [ + "checkFilesPermission", + "Missing permissions on {CWD}/test/lib/commands/tap-testdir-doctor-incorrect-permissions/global/bin (expect: executable)", + ], + ], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP missing git > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [ + Array [ + Error: test error, + ], + ], +} +` + +exports[`test/lib/commands/doctor.js TAP missing git > missing git 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  not ok Error: Install git and ensure it's in your PATH. +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-missing-git/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP missing global directories > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [ + Array [ + "checkFilesPermission", + "error getting info for {CWD}/test/lib/commands/tap-testdir-doctor-missing-global-directories/global/lib/node_modules", + ], + Array [ + "checkFilesPermission", + "error getting info for {CWD}/test/lib/commands/tap-testdir-doctor-missing-global-directories/global/bin", + ], + ], +} +` + +exports[`test/lib/commands/doctor.js TAP missing global directories > missing global directories 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-missing-global-directories/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-missing-global-directories/global/lib/node_modules +Perms check on local bin folder  ok   +Perms check on global bin folder  not ok Check the permissions of files in {CWD}/test/lib/commands/tap-testdir-doctor-missing-global-directories/global/bin +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP missing local node_modules > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP missing local node_modules > missing local node_modules 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-missing-local-node_modules/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP node out of date - current > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP node out of date - current > node is out of date 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  not ok Use node v2.0.1 (current: v2.0.0) +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-node-out-of-date---current/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP node out of date - lts > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP node out of date - lts > node is out of date 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  not ok Use node v1.0.0 (current: v0.0.1) +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-node-out-of-date---lts/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP non-default registry > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP non-default registry > non default registry 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  not ok Try \`npm config set registry=https://registry.npmjs.org/\` +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-non-default-registry/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP npm out of date > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP npm out of date > npm is out of date 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  not ok Use npm v2.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-npm-out-of-date/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP ping 404 > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP ping 404 > ping 404 1`] = ` +Check  Value  Recommendation/Notes +npm ping  not ok 404 404 Not Found - GET https://registry.npmjs.org/-/ping?write=true +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-ping-404/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP ping 404 in color > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP ping 404 in color > ping 404 in color 1`] = ` +Check  Value  Recommendation/Notes +npm ping  not ok 404 404 Not Found - GET https://registry.npmjs.org/-/ping?write=true +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-ping-404-in-color/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP ping exception with code > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP ping exception with code > ping failure 1`] = ` +Check  Value  Recommendation/Notes +npm ping  not ok request to https://registry.npmjs.org/-/ping?write=true failed, reason: Test Error +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-ping-exception-with-code/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP ping exception without code > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP ping exception without code > ping failure 1`] = ` +Check  Value  Recommendation/Notes +npm ping  not ok request to https://registry.npmjs.org/-/ping?write=true failed, reason: Test Error +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH  ok  {CWD}/test/lib/commands/tap-testdir-doctor-ping-exception-without-code/global/bin +Perms check on cached files  ok   +Perms check on local node_modules  ok   +Perms check on global node_modules ok   +Perms check on local bin folder  ok   +Perms check on global bin folder  ok   +Verify cache contents  ok  verified 0 tarballs +` + +exports[`test/lib/commands/doctor.js TAP silent errors > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP silent errors > output 1`] = ` + +` + +exports[`test/lib/commands/doctor.js TAP silent success > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + Array [ + "verifyCachedFiles", + "Verifying the npm cache", + ], + Array [ + "verifyCachedFiles", + String( + Verification complete. Stats: { + "badContentCount": 0, + "reclaimedCount": 0, + "missingContent": 0, + "verifiedContent": 0 + } + ), + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP silent success > output 1`] = ` + +` + +exports[`test/lib/commands/doctor.js TAP windows skips permissions checks > logs 1`] = ` +Object { + "error": Array [], + "info": Array [ + Array [ + "Running checkup", + ], + Array [ + "checkPing", + "Pinging registry", + ], + Array [ + "getLatestNpmVersion", + "Getting npm package information", + ], + Array [ + "getLatestNodejsVersion", + "Getting Node.js release information", + ], + Array [ + "getGitPath", + "Finding git in your PATH", + ], + Array [ + "getBinPath", + "Finding npm global bin in your PATH", + ], + ], + "warn": Array [], +} +` + +exports[`test/lib/commands/doctor.js TAP windows skips permissions checks > no permissions checks 1`] = ` +Check  Value  Recommendation/Notes +npm ping  ok   +npm -v  ok  current: v1.0.0, latest: v1.0.0 +node -v  ok  current: v1.0.0, recommended: v1.0.0 +npm config get registry  ok  using default registry (https://registry.npmjs.org/) +git executable in PATH  ok  /path/to/git +global bin folder in PATH ok  {CWD}/test/lib/commands/tap-testdir-doctor-windows-skips-permissions-checks/global +` diff --git a/tap-snapshots/test/lib/commands/init.js.test.cjs b/tap-snapshots/test/lib/commands/init.js.test.cjs index 3ca9d93..86b3fdd 100644 --- a/tap-snapshots/test/lib/commands/init.js.test.cjs +++ b/tap-snapshots/test/lib/commands/init.js.test.cjs @@ -10,28 +10,50 @@ Array [] ` exports[`test/lib/commands/init.js TAP workspaces no args > should print helper info 1`] = ` -Array [ - Array [ - String( - This utility will walk you through creating a package.json file. - It only covers the most common items, and tries to guess sensible defaults. - - See \`npm help init\` for definitive documentation on these fields - and exactly what they do. - - Use \`npm install <pkg>\` afterwards to install a package and - save it as a dependency in the package.json file. - - Press ^C at any time to quit. - ), - ], -] +Array [] ` exports[`test/lib/commands/init.js TAP workspaces no args, existing folder > should print helper info 1`] = ` Array [] ` +exports[`test/lib/commands/init.js TAP workspaces post workspace-init reify > should print helper info 1`] = ` +Array [ + Array [ + String( + + added 1 package in 100ms + ), + ], +] +` + +exports[`test/lib/commands/init.js TAP workspaces post workspace-init reify > should reify tree on init ws complete 1`] = ` +{ + "name": "top-level", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "top-level", + "workspaces": [ + "a" + ] + }, + "a": { + "version": "1.0.0", + "license": "ISC", + "devDependencies": {} + }, + "node_modules/a": { + "resolved": "a", + "link": true + } + } +} + +` + exports[`test/lib/commands/init.js TAP workspaces with arg but missing workspace folder > should print helper info 1`] = ` Array [] ` diff --git a/tap-snapshots/test/lib/commands/link.js.test.cjs b/tap-snapshots/test/lib/commands/link.js.test.cjs index a9a10b2..0c34bd9 100644 --- a/tap-snapshots/test/lib/commands/link.js.test.cjs +++ b/tap-snapshots/test/lib/commands/link.js.test.cjs @@ -5,6 +5,11 @@ * Make sure to inspect the output below. Do not ignore changes! */ 'use strict' +exports[`test/lib/commands/link.js TAP hash character in working directory path > should create a global link to current pkg, even within path with hash 1`] = ` +{CWD}/test/lib/commands/tap-testdir-link-hash-character-in-working-directory-path/global-prefix/lib/node_modules/test-pkg-link -> {CWD}/test/lib/commands/tap-testdir-link-hash-character-in-working-directory-path/i_like_#_in_my_paths/test-pkg-link + +` + exports[`test/lib/commands/link.js TAP link global linked pkg to local nm when using args > should create a local symlink to global pkg 1`] = ` {CWD}/test/lib/commands/tap-testdir-link-link-global-linked-pkg-to-local-nm-when-using-args/my-project/node_modules/@myscope/bar -> {CWD}/test/lib/commands/tap-testdir-link-link-global-linked-pkg-to-local-nm-when-using-args/global-prefix/lib/node_modules/@myscope/bar {CWD}/test/lib/commands/tap-testdir-link-link-global-linked-pkg-to-local-nm-when-using-args/my-project/node_modules/@myscope/linked -> {CWD}/test/lib/commands/tap-testdir-link-link-global-linked-pkg-to-local-nm-when-using-args/scoped-linked @@ -43,3 +48,8 @@ exports[`test/lib/commands/link.js TAP link ws to globalDir when workspace speci {CWD}/test/lib/commands/tap-testdir-link-link-ws-to-globalDir-when-workspace-specified-and-no-args/global-prefix/lib/node_modules/a -> {CWD}/test/lib/commands/tap-testdir-link-link-ws-to-globalDir-when-workspace-specified-and-no-args/test-pkg-link/packages/a ` + +exports[`test/lib/commands/link.js TAP test linked installed as symlinks > linked package should not be installed 1`] = ` +{CWD}/test/lib/commands/tap-testdir-link-test-linked-installed-as-symlinks/prefix/node_modules/mylink -> {CWD}/test/lib/commands/tap-testdir-link-test-linked-installed-as-symlinks/other/mylink + +` diff --git a/tap-snapshots/test/lib/commands/ls.js.test.cjs b/tap-snapshots/test/lib/commands/ls.js.test.cjs index 105b13b..f511dec 100644 --- a/tap-snapshots/test/lib/commands/ls.js.test.cjs +++ b/tap-snapshots/test/lib/commands/ls.js.test.cjs @@ -114,23 +114,6 @@ test-npm-ls@1.0.0 ` -exports[`test/lib/commands/ls.js TAP ls --only=development > should output tree containing only development deps 1`] = ` -test-npm-ls@1.0.0 {CWD}/tap-testdir-ls-ls---only-development -\`-- dev-dep@1.0.0 - \`-- foo@1.0.0 - \`-- dog@1.0.0 - -` - -exports[`test/lib/commands/ls.js TAP ls --only=prod > should output tree containing only prod deps 1`] = ` -test-npm-ls@1.0.0 {CWD}/tap-testdir-ls-ls---only-prod -+-- chai@1.0.0 -+-- optional-dep@1.0.0 -\`-- prod-dep@1.0.0 - \`-- dog@2.0.0 - -` - exports[`test/lib/commands/ls.js TAP ls --parseable --depth=0 > should output tree containing only top-level dependencies 1`] = ` {CWD}/tap-testdir-ls-ls---parseable---depth-0 {CWD}/tap-testdir-ls-ls---parseable---depth-0/node_modules/chai @@ -204,21 +187,6 @@ exports[`test/lib/commands/ls.js TAP ls --parseable --long with extraneous deps {CWD}/tap-testdir-ls-ls---parseable---long-with-extraneous-deps/node_modules/dog:dog@1.0.0 ` -exports[`test/lib/commands/ls.js TAP ls --parseable --only=development > should output tree containing only development deps 1`] = ` -{CWD}/tap-testdir-ls-ls---parseable---only-development -{CWD}/tap-testdir-ls-ls---parseable---only-development/node_modules/dev-dep -{CWD}/tap-testdir-ls-ls---parseable---only-development/node_modules/foo -{CWD}/tap-testdir-ls-ls---parseable---only-development/node_modules/dog -` - -exports[`test/lib/commands/ls.js TAP ls --parseable --only=prod > should output tree containing only prod deps 1`] = ` -{CWD}/tap-testdir-ls-ls---parseable---only-prod -{CWD}/tap-testdir-ls-ls---parseable---only-prod/node_modules/chai -{CWD}/tap-testdir-ls-ls---parseable---only-prod/node_modules/optional-dep -{CWD}/tap-testdir-ls-ls---parseable---only-prod/node_modules/prod-dep -{CWD}/tap-testdir-ls-ls---parseable---only-prod/node_modules/prod-dep/node_modules/dog -` - exports[`test/lib/commands/ls.js TAP ls --parseable --production > should output tree containing production deps 1`] = ` {CWD}/tap-testdir-ls-ls---parseable---production {CWD}/tap-testdir-ls-ls---parseable---production/node_modules/chai @@ -287,6 +255,12 @@ exports[`test/lib/commands/ls.js TAP ls --parseable no args > should output pars {CWD}/tap-testdir-ls-ls---parseable-no-args/node_modules/dog ` +exports[`test/lib/commands/ls.js TAP ls --parseable overridden dep > should contain overridden outout 1`] = ` +{CWD}/tap-testdir-ls-ls---parseable-overridden-dep:test-overridden@1.0.0 +{CWD}/tap-testdir-ls-ls---parseable-overridden-dep/node_modules/foo:foo@1.0.0 +{CWD}/tap-testdir-ls-ls---parseable-overridden-dep/node_modules/bar:bar@1.0.0:OVERRIDDEN +` + exports[`test/lib/commands/ls.js TAP ls --parseable resolved points to git ref > should output tree containing git refs 1`] = ` {CWD}/tap-testdir-ls-ls---parseable-resolved-points-to-git-ref {CWD}/tap-testdir-ls-ls---parseable-resolved-points-to-git-ref/node_modules/abbrev @@ -504,6 +478,15 @@ workspaces-tree@1.0.0 {CWD}/tap-testdir-ls-ls-loading-a-tree-containing-workspac ` +exports[`test/lib/commands/ls.js TAP ls loading a tree containing workspaces > should inlude root and specified workspace 1`] = ` +workspaces-tree@1.0.0 {CWD}/tap-testdir-ls-ls-loading-a-tree-containing-workspaces ++-- d@1.0.0 -> ./d +| \`-- foo@1.1.1 +| \`-- bar@1.0.0 +\`-- pacote@1.0.0 + +` + exports[`test/lib/commands/ls.js TAP ls loading a tree containing workspaces > should list --all workspaces properly 1`] = ` workspaces-tree@1.0.0 {CWD}/tap-testdir-ls-ls-loading-a-tree-containing-workspaces +-- a@1.0.0 -> ./a @@ -515,7 +498,8 @@ workspaces-tree@1.0.0 {CWD}/tap-testdir-ls-ls-loading-a-tree-containing-workspac | \`-- foo@1.1.1 | \`-- bar@1.0.0 +-- e@1.0.0 -> ./group/e -\`-- f@1.0.0 -> ./group/f ++-- f@1.0.0 -> ./group/f +\`-- pacote@1.0.0 ` @@ -529,7 +513,8 @@ workspaces-tree@1.0.0 {CWD}/tap-testdir-ls-ls-loading-a-tree-containing-workspac | \`-- foo@1.1.1 | \`-- bar@1.0.0 +-- e@1.0.0 -> ./group/e -\`-- f@1.0.0 -> ./group/f ++-- f@1.0.0 -> ./group/f +\`-- pacote@1.0.0 ` @@ -543,13 +528,14 @@ exports[`test/lib/commands/ls.js TAP ls loading a tree containing workspaces > s +-- d@1.0.0 -> ./d | \`-- foo@1.1.1 +-- e@1.0.0 -> ./group/e -\`-- f@1.0.0 -> ./group/f ++-- f@1.0.0 -> ./group/f +\`-- pacote@1.0.0  ` exports[`test/lib/commands/ls.js TAP ls loading a tree containing workspaces > should not list workspaces with --no-workspaces 1`] = ` workspaces-tree@1.0.0 {CWD}/tap-testdir-ls-ls-loading-a-tree-containing-workspaces -\`-- (empty) +\`-- pacote@1.0.0  ` @@ -587,6 +573,20 @@ test-npm-ls@1.0.0 {CWD}/tap-testdir-ls-ls-no-args ` +exports[`test/lib/commands/ls.js TAP ls overridden dep > should contain overridden outout 1`] = ` +test-overridden@1.0.0 {CWD}/tap-testdir-ls-ls-overridden-dep +\`-- foo@1.0.0 + \`-- bar@1.0.0 overridden + +` + +exports[`test/lib/commands/ls.js TAP ls overridden dep w/ color > should contain overridden outout 1`] = ` +test-overridden@1.0.0 {CWD}/tap-testdir-ls-ls-overridden-dep-w-color +\`-- foo@1.0.0 + \`-- bar@1.0.0 overridden + +` + exports[`test/lib/commands/ls.js TAP ls print deduped symlinks > should output tree containing linked deps 1`] = ` print-deduped-symlinks@1.0.0 {CWD}/tap-testdir-ls-ls-print-deduped-symlinks +-- a@1.0.0 @@ -698,6 +698,13 @@ dedupe-entries@1.0.0 {CWD}/tap-testdir-ls-ls-with-no-args-dedupe-entries-and-not ` +exports[`test/lib/commands/ls.js TAP ls workspace and missing optional dep > should omit missing optional dep 1`] = ` +root@ {CWD}/tap-testdir-ls-ls-workspace-and-missing-optional-dep ++-- baz@1.0.0 -> ./baz +\`-- foo@1.0.0 + +` + exports[`test/lib/commands/ls.js TAP show multiple invalid reasons > ls result 1`] = ` test-npm-ls@1.0.0 {cwd}/tap-testdir-ls-show-multiple-invalid-reasons +-- cat@1.0.0 invalid: "^2.0.0" from the root project diff --git a/tap-snapshots/test/lib/commands/owner.js.test.cjs b/tap-snapshots/test/lib/commands/owner.js.test.cjs deleted file mode 100644 index f3d7335..0000000 --- a/tap-snapshots/test/lib/commands/owner.js.test.cjs +++ /dev/null @@ -1,20 +0,0 @@ -/* IMPORTANT - * This snapshot file is auto-generated, but designed for humans. - * It should be checked into source control and tracked carefully. - * Re-generate by setting TAP_SNAPSHOT=1 and running tests. - * Make sure to inspect the output below. Do not ignore changes! - */ -'use strict' -exports[`test/lib/commands/owner.js TAP owner ls <pkg> > should output owners of <pkg> 1`] = ` -nlf <quitlahok@gmail.com> -ruyadorno <ruyadorno@hotmail.com> -darcyclarke <darcy@darcyclarke.me> -isaacs <i@izs.me> -` - -exports[`test/lib/commands/owner.js TAP owner ls no args > should output owners of cwd package 1`] = ` -nlf <quitlahok@gmail.com> -ruyadorno <ruyadorno@hotmail.com> -darcyclarke <darcy@darcyclarke.me> -isaacs <i@izs.me> -` diff --git a/tap-snapshots/test/lib/commands/pack.js.test.cjs b/tap-snapshots/test/lib/commands/pack.js.test.cjs index e3219b4..fdb64f9 100644 --- a/tap-snapshots/test/lib/commands/pack.js.test.cjs +++ b/tap-snapshots/test/lib/commands/pack.js.test.cjs @@ -56,6 +56,36 @@ Array [ ] ` +exports[`test/lib/commands/pack.js TAP should log scoped package output as valid json > logs pack contents 1`] = ` +Array [] +` + +exports[`test/lib/commands/pack.js TAP should log scoped package output as valid json > outputs as json 1`] = ` +Array [ + Array [ + Object { + "bundled": Array [], + "entryCount": 1, + "filename": "myscope-test-package-1.0.0.tgz", + "files": Array [ + Object { + "mode": 420, + "path": "package.json", + "size": 50, + }, + ], + "id": "@myscope/test-package@1.0.0", + "integrity": "sha512-bUu8iTm2E5DZMrwKeyx963K6ViEmaFocXh75EujgI+FHSaJeqvObcdk1KFwdx8CbOgsfNHEvWNQw/bONAJsoNw==", + "name": "@myscope/test-package", + "shasum": "7e6eb2e1ca46bed6b8fa8e144e0fcd1b22fe2d98", + "size": 145, + "unpackedSize": 50, + "version": "1.0.0", + }, + ], +] +` + exports[`test/lib/commands/pack.js TAP should pack current directory with no arguments > logs pack contents 1`] = ` Array [ undefined, diff --git a/tap-snapshots/test/lib/commands/profile.js.test.cjs b/tap-snapshots/test/lib/commands/profile.js.test.cjs index 31205b7..2103ccd 100644 --- a/tap-snapshots/test/lib/commands/profile.js.test.cjs +++ b/tap-snapshots/test/lib/commands/profile.js.test.cjs @@ -47,56 +47,56 @@ github https://github.com/npm ` exports[`test/lib/commands/profile.js TAP profile get no args default output > should output table with contents 1`] = ` -name: foo -email: foo@github.com (verified) -two-factor auth: auth-and-writes -fullname: Foo Bar -homepage: https://github.com -freenode: foobar -twitter: https://twitter.com/npmjs -github: https://github.com/npm -created: 2015-02-26T01:26:37.384Z -updated: 2020-08-12T16:19:35.326Z +name: foo +email: foo@github.com (verified) +two-factor auth: auth-and-writes +fullname: Foo Bar +homepage: https://github.com +freenode: foobar +twitter: https://twitter.com/npmjs +github: https://github.com/npm +created: 2015-02-26T01:26:37.384Z +updated: 2020-08-12T16:19:35.326Z ` exports[`test/lib/commands/profile.js TAP profile get no args no tfa enabled > should output expected profile values 1`] = ` -name: foo -email: foo@github.com (verified) -two-factor auth: disabled -fullname: Foo Bar -homepage: https://github.com -freenode: foobar -twitter: https://twitter.com/npmjs -github: https://github.com/npm -created: 2015-02-26T01:26:37.384Z -updated: 2020-08-12T16:19:35.326Z +name: foo +email: foo@github.com (verified) +two-factor auth: disabled +fullname: Foo Bar +homepage: https://github.com +freenode: foobar +twitter: https://twitter.com/npmjs +github: https://github.com/npm +created: 2015-02-26T01:26:37.384Z +updated: 2020-08-12T16:19:35.326Z ` exports[`test/lib/commands/profile.js TAP profile get no args profile has cidr_whitelist item > should output table with contents 1`] = ` -name: foo -email: foo@github.com (verified) -two-factor auth: auth-and-writes -fullname: Foo Bar -homepage: https://github.com -freenode: foobar -twitter: https://twitter.com/npmjs -github: https://github.com/npm -created: 2015-02-26T01:26:37.384Z -updated: 2020-08-12T16:19:35.326Z -cidr_whitelist: 192.168.1.1 +name: foo +email: foo@github.com (verified) +two-factor auth: auth-and-writes +fullname: Foo Bar +homepage: https://github.com +freenode: foobar +twitter: https://twitter.com/npmjs +github: https://github.com/npm +created: 2015-02-26T01:26:37.384Z +updated: 2020-08-12T16:19:35.326Z +cidr_whitelist: 192.168.1.1 ` exports[`test/lib/commands/profile.js TAP profile get no args unverified email > should output table with contents 1`] = ` -name: foo -email: foo@github.com(unverified) -two-factor auth: auth-and-writes -fullname: Foo Bar -homepage: https://github.com -freenode: foobar -twitter: https://twitter.com/npmjs -github: https://github.com/npm -created: 2015-02-26T01:26:37.384Z -updated: 2020-08-12T16:19:35.326Z +name: foo +email: foo@github.com(unverified) +two-factor auth: auth-and-writes +fullname: Foo Bar +homepage: https://github.com +freenode: foobar +twitter: https://twitter.com/npmjs +github: https://github.com/npm +created: 2015-02-26T01:26:37.384Z +updated: 2020-08-12T16:19:35.326Z ` exports[`test/lib/commands/profile.js TAP profile set <key> <value> writable key --parseable > should output parseable set key success msg 1`] = ` diff --git a/tap-snapshots/test/lib/commands/publish.js.test.cjs b/tap-snapshots/test/lib/commands/publish.js.test.cjs index dec7727..fd9fd74 100644 --- a/tap-snapshots/test/lib/commands/publish.js.test.cjs +++ b/tap-snapshots/test/lib/commands/publish.js.test.cjs @@ -5,153 +5,361 @@ * Make sure to inspect the output below. Do not ignore changes! */ 'use strict' -exports[`test/lib/commands/publish.js TAP private workspaces colorless > should output all publishes 1`] = ` +exports[`test/lib/commands/publish.js TAP _auth config default registry > new package version 1`] = ` ++ test-package@1.0.0 +` + +exports[`test/lib/commands/publish.js TAP bare _auth and registry config > new package version 1`] = ` ++ @npm/test-package@1.0.0 +` + +exports[`test/lib/commands/publish.js TAP dry-run > must match snapshot 1`] = ` Array [ - "+ @npmcli/b@1.0.0", + Array [ + "", + ], + Array [ + "", + "package: test-package@1.0.0", + ], + Array [ + "=== Tarball Contents ===", + ], + Array [ + "", + "87B package.json", + ], + Array [ + "=== Tarball Details ===", + ], + Array [ + "", + String( + name: test-package + version: 1.0.0 + filename: test-package-1.0.0.tgz + package size: 160 B + unpacked size: 87 B + shasum:{sha} + integrity:{sha} + total files: 1 + ), + ], + Array [ + "", + "", + ], + Array [ + "", + "Publishing to https://registry.npmjs.org/ with tag latest and default access (dry-run)", + ], ] ` -exports[`test/lib/commands/publish.js TAP private workspaces colorless > should publish all non-private workspaces 1`] = ` +exports[`test/lib/commands/publish.js TAP has mTLS auth for scope configured registry > new package version 1`] = ` ++ @npm/test-package@1.0.0 +` + +exports[`test/lib/commands/publish.js TAP has token auth for scope configured registry > new package version 1`] = ` ++ @npm/test-package@1.0.0 +` + +exports[`test/lib/commands/publish.js TAP ignore-scripts > new package version 1`] = ` ++ test-package@1.0.0 +` + +exports[`test/lib/commands/publish.js TAP json > must match snapshot 1`] = ` Array [ - Object { - "_id": "@npmcli/b@1.0.0", - "name": "@npmcli/b", - "readme": "ERROR: No README data found!", - "version": "1.0.0", - }, + Array [ + "", + "Publishing to https://registry.npmjs.org/ with tag latest and default access", + ], ] ` -exports[`test/lib/commands/publish.js TAP private workspaces with color > should output all publishes 1`] = ` -Array [ - "+ @npmcli/b@1.0.0", -] -` - -exports[`test/lib/commands/publish.js TAP private workspaces with color > should publish all non-private workspaces 1`] = ` -Array [ - Object { - "_id": "@npmcli/b@1.0.0", - "name": "@npmcli/b", - "readme": "ERROR: No README data found!", - "version": "1.0.0", - }, -] -` - -exports[`test/lib/commands/publish.js TAP workspaces all workspaces > should output all publishes 1`] = ` -Array [ - "+ workspace-a@1.2.3-a", - "+ workspace-b@1.2.3-n", - "+ workspace-n@1.2.3-n", -] -` - -exports[`test/lib/commands/publish.js TAP workspaces all workspaces > should publish all workspaces 1`] = ` -Array [ - Object { - "_id": "workspace-a@1.2.3-a", - "name": "workspace-a", - "readme": "ERROR: No README data found!", - "repository": Object { - "type": "git", - "url": "http://repo.workspace-a/", - }, - "version": "1.2.3-a", - }, - Object { - "_id": "workspace-b@1.2.3-n", - "bugs": Object { - "url": "https://github.com/npm/workspace-b/issues", - }, - "homepage": "https://github.com/npm/workspace-b#readme", - "name": "workspace-b", - "readme": "ERROR: No README data found!", - "repository": Object { - "type": "git", - "url": "git+https://github.com/npm/workspace-b.git", - }, - "version": "1.2.3-n", - }, - Object { - "_id": "workspace-n@1.2.3-n", - "name": "workspace-n", - "readme": "ERROR: No README data found!", - "version": "1.2.3-n", - }, -] -` - -exports[`test/lib/commands/publish.js TAP workspaces json > should output all publishes as json 1`] = ` -Array [ - String( +exports[`test/lib/commands/publish.js TAP json > new package json 1`] = ` +{ + "id": "test-package@1.0.0", + "name": "test-package", + "version": "1.0.0", + "size": 160, + "unpackedSize": 87, + "shasum": "{sha}", + "integrity": "{sha}", + "filename": "test-package-1.0.0.tgz", + "files": [ { - "workspace-a": { - "id": "workspace-a@1.2.3-a" - }, - "workspace-b": { - "id": "workspace-b@1.2.3-n" - }, - "workspace-n": { - "id": "workspace-n@1.2.3-n" - } + "path": "package.json", + "size": 87, + "mode": 420 } - ), + ], + "entryCount": 1, + "bundled": [] +} +` + +exports[`test/lib/commands/publish.js TAP no auth dry-run > must match snapshot 1`] = ` ++ test-package@1.0.0 +` + +exports[`test/lib/commands/publish.js TAP no auth dry-run > warns about auth being needed 1`] = ` +Array [ + Array [ + "", + "This command requires you to be logged in to https://registry.npmjs.org/ (dry-run)", + ], ] ` -exports[`test/lib/commands/publish.js TAP workspaces json > should publish all workspaces 1`] = ` +exports[`test/lib/commands/publish.js TAP public access > must match snapshot 1`] = ` Array [ - Object { - "_id": "workspace-a@1.2.3-a", + Array [ + "", + ], + Array [ + "", + "package: @npm/test-package@1.0.0", + ], + Array [ + "=== Tarball Contents ===", + ], + Array [ + "", + "55B package.json", + ], + Array [ + "=== Tarball Details ===", + ], + Array [ + "", + String( + name: @npm/test-package + version: 1.0.0 + filename: npm-test-package-1.0.0.tgz + package size: 147 B + unpacked size: 55 B + shasum:{sha} + integrity:{sha} + total files: 1 + ), + ], + Array [ + "", + "", + ], + Array [ + "", + "Publishing to https://registry.npmjs.org/ with tag latest and public access", + ], +] +` + +exports[`test/lib/commands/publish.js TAP public access > new package version 1`] = ` ++ @npm/test-package@1.0.0 +` + +exports[`test/lib/commands/publish.js TAP re-loads publishConfig.registry if added during script process > new package version 1`] = ` ++ test-package@1.0.0 +` + +exports[`test/lib/commands/publish.js TAP respects publishConfig.registry, runs appropriate scripts > new package version 1`] = ` + +` + +exports[`test/lib/commands/publish.js TAP restricted access > must match snapshot 1`] = ` +Array [ + Array [ + "", + ], + Array [ + "", + "package: @npm/test-package@1.0.0", + ], + Array [ + "=== Tarball Contents ===", + ], + Array [ + "", + "55B package.json", + ], + Array [ + "=== Tarball Details ===", + ], + Array [ + "", + String( + name: @npm/test-package + version: 1.0.0 + filename: npm-test-package-1.0.0.tgz + package size: 147 B + unpacked size: 55 B + shasum:{sha} + integrity:{sha} + total files: 1 + ), + ], + Array [ + "", + "", + ], + Array [ + "", + "Publishing to https://registry.npmjs.org/ with tag latest and restricted access", + ], +] +` + +exports[`test/lib/commands/publish.js TAP restricted access > new package version 1`] = ` ++ @npm/test-package@1.0.0 +` + +exports[`test/lib/commands/publish.js TAP scoped _auth config scoped registry > new package version 1`] = ` ++ @npm/test-package@1.0.0 +` + +exports[`test/lib/commands/publish.js TAP tarball > must match snapshot 1`] = ` +Array [ + Array [ + "", + ], + Array [ + "", + "package: test-tar-package@1.0.0", + ], + Array [ + "=== Tarball Contents ===", + ], + Array [ + "", + String( + 26B index.js + 98B package.json + ), + ], + Array [ + "=== Tarball Details ===", + ], + Array [ + "", + String( + name: test-tar-package + version: 1.0.0 + filename: test-tar-package-1.0.0.tgz + package size: 218 B + unpacked size: 124 B + shasum:{sha} + integrity:{sha} + total files: 2 + ), + ], + Array [ + "", + "", + ], + Array [ + "", + "Publishing to https://registry.npmjs.org/ with tag latest and default access", + ], +] +` + +exports[`test/lib/commands/publish.js TAP tarball > new package json 1`] = ` ++ test-tar-package@1.0.0 +` + +exports[`test/lib/commands/publish.js TAP workspaces all workspaces - color > all public workspaces 1`] = ` ++ workspace-a@1.2.3-a ++ workspace-b@1.2.3-n ++ workspace-n@1.2.3-n +` + +exports[`test/lib/commands/publish.js TAP workspaces all workspaces - color > warns about skipped private workspace in color 1`] = ` +Array [ + Array [ + "publish", + "Skipping workspace \\u001b[32mworkspace-p\\u001b[39m, marked as \\u001b[1mprivate\\u001b[22m", + ], +] +` + +exports[`test/lib/commands/publish.js TAP workspaces all workspaces - no color > all public workspaces 1`] = ` ++ workspace-a@1.2.3-a ++ workspace-b@1.2.3-n ++ workspace-n@1.2.3-n +` + +exports[`test/lib/commands/publish.js TAP workspaces all workspaces - no color > warns about skipped private workspace 1`] = ` +Array [ + Array [ + "publish", + "Skipping workspace workspace-p, marked as private", + ], +] +` + +exports[`test/lib/commands/publish.js TAP workspaces json > all workspaces in json 1`] = ` +{ + "workspace-a": { + "id": "workspace-a@1.2.3-a", "name": "workspace-a", - "readme": "ERROR: No README data found!", - "repository": Object { - "type": "git", - "url": "http://repo.workspace-a/", - }, "version": "1.2.3-a", + "size": 162, + "unpackedSize": 82, + "shasum": "{sha}", + "integrity": "{sha}", + "filename": "workspace-a-1.2.3-a.tgz", + "files": [ + { + "path": "package.json", + "size": 82, + "mode": 420 + } + ], + "entryCount": 1, + "bundled": [] }, - Object { - "_id": "workspace-b@1.2.3-n", - "bugs": Object { - "url": "https://github.com/npm/workspace-b/issues", - }, - "homepage": "https://github.com/npm/workspace-b#readme", + "workspace-b": { + "id": "workspace-b@1.2.3-n", "name": "workspace-b", - "readme": "ERROR: No README data found!", - "repository": Object { - "type": "git", - "url": "git+https://github.com/npm/workspace-b.git", - }, "version": "1.2.3-n", + "size": 171, + "unpackedSize": 92, + "shasum": "{sha}", + "integrity": "{sha}", + "filename": "workspace-b-1.2.3-n.tgz", + "files": [ + { + "path": "package.json", + "size": 92, + "mode": 420 + } + ], + "entryCount": 1, + "bundled": [] }, - Object { - "_id": "workspace-n@1.2.3-n", + "workspace-n": { + "id": "workspace-n@1.2.3-n", "name": "workspace-n", - "readme": "ERROR: No README data found!", "version": "1.2.3-n", - }, -] + "size": 140, + "unpackedSize": 42, + "shasum": "{sha}", + "integrity": "{sha}", + "filename": "workspace-n-1.2.3-n.tgz", + "files": [ + { + "path": "package.json", + "size": 42, + "mode": 420 + } + ], + "entryCount": 1, + "bundled": [] + } +} ` -exports[`test/lib/commands/publish.js TAP workspaces one workspace > should output one publish 1`] = ` -Array [ - "+ workspace-a@1.2.3-a", -] -` - -exports[`test/lib/commands/publish.js TAP workspaces one workspace > should publish given workspace 1`] = ` -Array [ - Object { - "_id": "workspace-a@1.2.3-a", - "name": "workspace-a", - "readme": "ERROR: No README data found!", - "repository": Object { - "type": "git", - "url": "http://repo.workspace-a/", - }, - "version": "1.2.3-a", - }, -] +exports[`test/lib/commands/publish.js TAP workspaces one workspace - success > single workspace 1`] = ` ++ workspace-a@1.2.3-a ` diff --git a/tap-snapshots/test/lib/commands/query.js.test.cjs b/tap-snapshots/test/lib/commands/query.js.test.cjs new file mode 100644 index 0000000..9ad6e2e --- /dev/null +++ b/tap-snapshots/test/lib/commands/query.js.test.cjs @@ -0,0 +1,243 @@ +/* IMPORTANT + * This snapshot file is auto-generated, but designed for humans. + * It should be checked into source control and tracked carefully. + * Re-generate by setting TAP_SNAPSHOT=1 and running tests. + * Make sure to inspect the output below. Do not ignore changes! + */ +'use strict' +exports[`test/lib/commands/query.js TAP global > should return global package 1`] = ` +[ + { + "name": "lorem", + "version": "2.0.0", + "_id": "lorem@2.0.0", + "pkgid": "lorem@2.0.0", + "location": "node_modules/lorem", + "path": "{CWD}/test/lib/commands/tap-testdir-query-global/global/node_modules/lorem", + "realpath": "{CWD}/test/lib/commands/tap-testdir-query-global/global/node_modules/lorem", + "resolved": null, + "from": [ + "" + ], + "to": [], + "dev": false, + "inBundle": false, + "deduped": false, + "overridden": false, + "queryContext": {} + } +] +` + +exports[`test/lib/commands/query.js TAP include-workspace-root > should return workspace object and root object 1`] = ` +[ + { + "name": "project", + "workspaces": [ + "c" + ], + "dependencies": { + "a": "^1.0.0", + "b": "^1.0.0" + }, + "pkgid": "project@", + "location": "", + "path": "{CWD}/test/lib/commands/tap-testdir-query-include-workspace-root/prefix", + "realpath": "{CWD}/test/lib/commands/tap-testdir-query-include-workspace-root/prefix", + "resolved": null, + "from": [], + "to": [ + "node_modules/c", + "node_modules/a", + "node_modules/b" + ], + "dev": false, + "inBundle": false, + "deduped": false, + "overridden": false, + "queryContext": {} + }, + { + "name": "c", + "version": "1.0.0", + "_id": "c@1.0.0", + "pkgid": "c@1.0.0", + "location": "c", + "path": "{CWD}/test/lib/commands/tap-testdir-query-include-workspace-root/prefix/c", + "realpath": "{CWD}/test/lib/commands/tap-testdir-query-include-workspace-root/prefix/c", + "resolved": null, + "from": [], + "to": [], + "dev": false, + "inBundle": false, + "deduped": false, + "overridden": false, + "queryContext": {} + } +] +` + +exports[`test/lib/commands/query.js TAP linked node > should return linked node res 1`] = ` +[ + { + "name": "a", + "version": "1.0.0", + "_id": "a@1.0.0", + "pkgid": "a@1.0.0", + "location": "a", + "path": "{CWD}/test/lib/commands/tap-testdir-query-linked-node/prefix/a", + "realpath": "{CWD}/test/lib/commands/tap-testdir-query-linked-node/prefix/a", + "resolved": null, + "from": [], + "to": [], + "dev": false, + "inBundle": false, + "deduped": false, + "overridden": false, + "queryContext": {} + } +] +` + +exports[`test/lib/commands/query.js TAP recursive tree > should return everything in the tree, accounting for recursion 1`] = ` +[ + { + "name": "project", + "dependencies": { + "a": "^1.0.0", + "b": "^1.0.0" + }, + "pkgid": "project@", + "location": "", + "path": "{CWD}/test/lib/commands/tap-testdir-query-recursive-tree/prefix", + "realpath": "{CWD}/test/lib/commands/tap-testdir-query-recursive-tree/prefix", + "resolved": null, + "from": [], + "to": [ + "node_modules/a", + "node_modules/b" + ], + "dev": false, + "inBundle": false, + "deduped": false, + "overridden": false, + "queryContext": {} + }, + { + "pkgid": "a@", + "location": "node_modules/a", + "path": "{CWD}/test/lib/commands/tap-testdir-query-recursive-tree/prefix/node_modules/a", + "realpath": "{CWD}/test/lib/commands/tap-testdir-query-recursive-tree/prefix/node_modules/a", + "resolved": null, + "from": [ + "" + ], + "to": [], + "dev": false, + "inBundle": false, + "deduped": false, + "overridden": false, + "queryContext": {} + }, + { + "pkgid": "b@", + "location": "node_modules/b", + "path": "{CWD}/test/lib/commands/tap-testdir-query-recursive-tree/prefix/node_modules/b", + "realpath": "{CWD}/test/lib/commands/tap-testdir-query-recursive-tree/prefix/node_modules/b", + "resolved": null, + "from": [ + "" + ], + "to": [], + "dev": false, + "inBundle": false, + "deduped": false, + "overridden": false, + "queryContext": {} + } +] +` + +exports[`test/lib/commands/query.js TAP simple query > should return root object and direct children 1`] = ` +[ + { + "name": "project", + "dependencies": { + "a": "^1.0.0", + "b": "^1.0.0" + }, + "peerDependencies": { + "c": "1.0.0" + }, + "pkgid": "project@", + "location": "", + "path": "{CWD}/test/lib/commands/tap-testdir-query-simple-query/prefix", + "realpath": "{CWD}/test/lib/commands/tap-testdir-query-simple-query/prefix", + "resolved": null, + "from": [], + "to": [ + "node_modules/a", + "node_modules/b" + ], + "dev": false, + "inBundle": false, + "deduped": false, + "overridden": false, + "queryContext": {} + }, + { + "pkgid": "a@", + "location": "node_modules/a", + "path": "{CWD}/test/lib/commands/tap-testdir-query-simple-query/prefix/node_modules/a", + "realpath": "{CWD}/test/lib/commands/tap-testdir-query-simple-query/prefix/node_modules/a", + "resolved": null, + "from": [ + "" + ], + "to": [], + "dev": false, + "inBundle": false, + "deduped": false, + "overridden": false, + "queryContext": {} + }, + { + "pkgid": "b@", + "location": "node_modules/b", + "path": "{CWD}/test/lib/commands/tap-testdir-query-simple-query/prefix/node_modules/b", + "realpath": "{CWD}/test/lib/commands/tap-testdir-query-simple-query/prefix/node_modules/b", + "resolved": null, + "from": [ + "" + ], + "to": [], + "dev": false, + "inBundle": false, + "deduped": false, + "overridden": false, + "queryContext": {} + } +] +` + +exports[`test/lib/commands/query.js TAP workspace query > should return workspace object 1`] = ` +[ + { + "name": "c", + "version": "1.0.0", + "_id": "c@1.0.0", + "pkgid": "c@1.0.0", + "location": "c", + "path": "{CWD}/test/lib/commands/tap-testdir-query-workspace-query/prefix/c", + "realpath": "{CWD}/test/lib/commands/tap-testdir-query-workspace-query/prefix/c", + "resolved": null, + "from": [], + "to": [], + "dev": false, + "inBundle": false, + "deduped": false, + "overridden": false, + "queryContext": {} + } +] +` diff --git a/tap-snapshots/test/lib/commands/search.js.test.cjs b/tap-snapshots/test/lib/commands/search.js.test.cjs index 139fca2..152e660 100644 --- a/tap-snapshots/test/lib/commands/search.js.test.cjs +++ b/tap-snapshots/test/lib/commands/search.js.test.cjs @@ -9,12 +9,130 @@ exports[`test/lib/commands/search.js TAP empty search results > should have expe No matches found for "foo" ` -exports[`test/lib/commands/search.js TAP search <name> --searchexclude --searchopts > should have filtered expected search results 1`] = ` -NAME | AUTHOR | DATE | VERSION | KEYWORDS -foo | =foo | prehistoric | 1.0.0 | +exports[`test/lib/commands/search.js TAP search /<name>/--color > should have expected search results with color 1`] = ` +NAME | DESCRIPTION | AUTHOR | DATE | VERSION | KEYWORDS +libnpm | Collection of… | =nlf… | 2019-07-16 | 3.0.1 | npm api package manager lib +libnpmaccess | programmatic… | =nlf… | 2020-11-03 | 4.0.1 | libnpmaccess +@evocateur/libnpmaccess | programmatic… | =evocateur | 2019-07-16 | 3.1.2 | +@evocateur/libnpmpublish | Programmatic API… | =evocateur | 2019-07-16 | 1.2.2 | +libnpmorg | Programmatic api… | =nlf… | 2020-11-03 | 2.0.1 | libnpm npm package manager api orgs teams +libnpmsearch | Programmatic API… | =nlf… | 2020-12-08 | 3.1.0 | npm search api libnpm +libnpmteam | npm Team management… | =nlf… | 2020-11-03 | 2.0.2 | +libnpmhook | programmatic API… | =nlf… | 2020-11-03 | 6.0.1 | npm hooks registry npm api +libnpmpublish | Programmatic API… | =nlf… | 2020-11-03 | 4.0.0 | +libnpmfund | Programmatic API… | =nlf… | 2020-12-08 | 1.0.2 | npm npmcli libnpm cli git fund gitfund +@npmcli/map-workspaces | Retrieves a… | =nlf… | 2020-09-30 | 1.0.1 | npm npmcli libnpm cli workspaces map-workspaces +libnpmversion | library to do the… | =nlf… | 2020-11-04 | 1.0.7 | +@types/libnpmsearch | TypeScript… | =types | 2019-09-26 | 2.0.1 | ` -exports[`test/lib/commands/search.js TAP search <name> > should have expected search results 1`] = ` -NAME | AUTHOR | DATE | VERSION | KEYWORDS -libnpm | =nlf… | 2019-07-16 | 3.0.1 | npm api package manager liblibnpmaccess | =nlf… | 2020-11-03 | 4.0.1 | @evocateur/libnpmaccess | =evocateur | 2019-07-16 | 3.1.2 | @evocateur/libnpmpublish | =evocateur | 2019-07-16 | 1.2.2 | libnpmorg | =nlf… | 2020-11-03 | 2.0.1 | libnpm npm package manager api orgs teamslibnpmsearch | =nlf… | 2020-12-08 | 3.1.0 | npm search api libnpmlibnpmteam | =nlf… | 2020-11-03 | 2.0.2 | libnpmhook | =nlf… | 2020-11-03 | 6.0.1 | npm hooks registry npm apilibnpmpublish | =nlf… | 2020-11-03 | 4.0.0 | libnpmfund | =nlf… | 2020-12-08 | 1.0.2 | npm npmcli libnpm cli git fund gitfund@npmcli/map-workspaces | =nlf… | 2020-09-30 | 1.0.1 | npm npmcli libnpm cli workspaces map-workspaceslibnpmversion | =nlf… | 2020-11-04 | 1.0.7 | @types/libnpmsearch | =types | 2019-09-26 | 2.0.1 | +exports[`test/lib/commands/search.js TAP search <name> --color > should have expected search results with color 1`] = ` +NAME | DESCRIPTION | AUTHOR | DATE | VERSION | KEYWORDS +libnpm | Collection of… | =nlf… | 2019-07-16 | 3.0.1 | npm api package manager lib +libnpmaccess | programmatic… | =nlf… | 2020-11-03 | 4.0.1 | libnpmaccess +@evocateur/libnpmaccess | programmatic… | =evocateur | 2019-07-16 | 3.1.2 |  +@evocateur/libnpmpublish | Programmatic API… | =evocateur | 2019-07-16 | 1.2.2 |  +libnpmorg | Programmatic api… | =nlf… | 2020-11-03 | 2.0.1 | libnpm npm package manager api orgs teams +libnpmsearch | Programmatic API… | =nlf… | 2020-12-08 | 3.1.0 | npm search api libnpm +libnpmteam | npm Team management… | =nlf… | 2020-11-03 | 2.0.2 |  +libnpmhook | programmatic API… | =nlf… | 2020-11-03 | 6.0.1 | npm hooks registry npm api +libnpmpublish | Programmatic API… | =nlf… | 2020-11-03 | 4.0.0 |  +libnpmfund | Programmatic API… | =nlf… | 2020-12-08 | 1.0.2 | npm npmcli libnpm cli git fund gitfund +@npmcli/map-workspaces | Retrieves a… | =nlf… | 2020-09-30 | 1.0.1 | npm npmcli libnpm cli workspaces map-workspaces +libnpmversion | library to do the… | =nlf… | 2020-11-04 | 1.0.7 |  +@types/libnpmsearch | TypeScript… | =types | 2019-09-26 | 2.0.1 |  +` + +exports[`test/lib/commands/search.js TAP search <name> --parseable > should have expected search results as parseable 1`] = ` +libnpm Collection of programmatic APIs for the npm CLI =nlf =ruyadorno =darcyclarke =isaacs 2019-07-16 3.0.1 npm api package manager lib +libnpmaccess programmatic library for \`npm access\` commands =nlf =ruyadorno =darcyclarke =isaacs 2020-11-03 4.0.1 libnpmaccess +@evocateur/libnpmaccess programmatic library for \`npm access\` commands =evocateur 2019-07-16 3.1.2 +@evocateur/libnpmpublish Programmatic API for the bits behind npm publish and unpublish =evocateur 2019-07-16 1.2.2 +libnpmorg Programmatic api for \`npm org\` commands =nlf =ruyadorno =darcyclarke =isaacs 2020-11-03 2.0.1 libnpm npm package manager api orgs teams +libnpmsearch Programmatic API for searching in npm and compatible registries. =nlf =ruyadorno =darcyclarke =isaacs 2020-12-08 3.1.0 npm search api libnpm +libnpmteam npm Team management APIs =nlf =ruyadorno =darcyclarke =isaacs 2020-11-03 2.0.2 +libnpmhook programmatic API for managing npm registry hooks =nlf =ruyadorno =darcyclarke =isaacs 2020-11-03 6.0.1 npm hooks registry npm api +libnpmpublish Programmatic API for the bits behind npm publish and unpublish =nlf =ruyadorno =darcyclarke =isaacs 2020-11-03 4.0.0 +libnpmfund Programmatic API for npm fund =nlf =ruyadorno =darcyclarke =isaacs 2020-12-08 1.0.2 npm npmcli libnpm cli git fund gitfund +@npmcli/map-workspaces Retrieves a name:pathname Map for a given workspaces config =nlf =ruyadorno =darcyclarke =isaacs 2020-09-30 1.0.1 npm npmcli libnpm cli workspaces map-workspaces +libnpmversion library to do the things that 'npm version' does =nlf =ruyadorno =darcyclarke =isaacs 2020-11-04 1.0.7 +@types/libnpmsearch TypeScript definitions for libnpmsearch =types 2019-09-26 2.0.1 +` + +exports[`test/lib/commands/search.js TAP search <name> > should have filtered expected search results 1`] = ` +NAME | DESCRIPTION | AUTHOR | DATE | VERSION | KEYWORDS +foo | | =foo | prehistoric | 1.0.0 | +libnpmversion | | =foo | prehistoric | 1.0.0 | +` + +exports[`test/lib/commands/search.js TAP search <name> text > should have expected search results 1`] = ` +NAME | DESCRIPTION | AUTHOR | DATE | VERSION | KEYWORDS +libnpm | Collection of… | =nlf… | 2019-07-16 | 3.0.1 | npm api package manager lib +libnpmaccess | programmatic… | =nlf… | 2020-11-03 | 4.0.1 | libnpmaccess +@evocateur/libnpmaccess | programmatic… | =evocateur | 2019-07-16 | 3.1.2 | +@evocateur/libnpmpublish | Programmatic API… | =evocateur | 2019-07-16 | 1.2.2 | +libnpmorg | Programmatic api… | =nlf… | 2020-11-03 | 2.0.1 | libnpm npm package manager api orgs teams +libnpmsearch | Programmatic API… | =nlf… | 2020-12-08 | 3.1.0 | npm search api libnpm +libnpmteam | npm Team management… | =nlf… | 2020-11-03 | 2.0.2 | +libnpmhook | programmatic API… | =nlf… | 2020-11-03 | 6.0.1 | npm hooks registry npm api +libnpmpublish | Programmatic API… | =nlf… | 2020-11-03 | 4.0.0 | +libnpmfund | Programmatic API… | =nlf… | 2020-12-08 | 1.0.2 | npm npmcli libnpm cli git fund gitfund +@npmcli/map-workspaces | Retrieves a… | =nlf… | 2020-09-30 | 1.0.1 | npm npmcli libnpm cli workspaces map-workspaces +libnpmversion | library to do the… | =nlf… | 2020-11-04 | 1.0.7 | +@types/libnpmsearch | TypeScript… | =types | 2019-09-26 | 2.0.1 | +` + +exports[`test/lib/commands/search.js TAP search exclude forward slash > results should not have libnpmversion 1`] = ` +NAME | DESCRIPTION | AUTHOR | DATE | VERSION | KEYWORDS +libnpm | Collection of… | =nlf… | 2019-07-16 | 3.0.1 | npm api package manager lib +libnpmaccess | programmatic… | =nlf… | 2020-11-03 | 4.0.1 | libnpmaccess +@evocateur/libnpmaccess | programmatic… | =evocateur | 2019-07-16 | 3.1.2 | +@evocateur/libnpmpublish | Programmatic API… | =evocateur | 2019-07-16 | 1.2.2 | +libnpmorg | Programmatic api… | =nlf… | 2020-11-03 | 2.0.1 | libnpm npm package manager api orgs teams +libnpmsearch | Programmatic API… | =nlf… | 2020-12-08 | 3.1.0 | npm search api libnpm +libnpmteam | npm Team management… | =nlf… | 2020-11-03 | 2.0.2 | +libnpmhook | programmatic API… | =nlf… | 2020-11-03 | 6.0.1 | npm hooks registry npm api +libnpmpublish | Programmatic API… | =nlf… | 2020-11-03 | 4.0.0 | +libnpmfund | Programmatic API… | =nlf… | 2020-12-08 | 1.0.2 | npm npmcli libnpm cli git fund gitfund +@npmcli/map-workspaces | Retrieves a… | =nlf… | 2020-09-30 | 1.0.1 | npm npmcli libnpm cli workspaces map-workspaces +@types/libnpmsearch | TypeScript… | =types | 2019-09-26 | 2.0.1 | +` + +exports[`test/lib/commands/search.js TAP search exclude regex > results should not have libnpmversion 1`] = ` +NAME | DESCRIPTION | AUTHOR | DATE | VERSION | KEYWORDS +libnpm | Collection of… | =nlf… | 2019-07-16 | 3.0.1 | npm api package manager lib +libnpmaccess | programmatic… | =nlf… | 2020-11-03 | 4.0.1 | libnpmaccess +@evocateur/libnpmaccess | programmatic… | =evocateur | 2019-07-16 | 3.1.2 | +@evocateur/libnpmpublish | Programmatic API… | =evocateur | 2019-07-16 | 1.2.2 | +libnpmorg | Programmatic api… | =nlf… | 2020-11-03 | 2.0.1 | libnpm npm package manager api orgs teams +libnpmsearch | Programmatic API… | =nlf… | 2020-12-08 | 3.1.0 | npm search api libnpm +libnpmteam | npm Team management… | =nlf… | 2020-11-03 | 2.0.2 | +libnpmhook | programmatic API… | =nlf… | 2020-11-03 | 6.0.1 | npm hooks registry npm api +libnpmpublish | Programmatic API… | =nlf… | 2020-11-03 | 4.0.0 | +libnpmfund | Programmatic API… | =nlf… | 2020-12-08 | 1.0.2 | npm npmcli libnpm cli git fund gitfund +@npmcli/map-workspaces | Retrieves a… | =nlf… | 2020-09-30 | 1.0.1 | npm npmcli libnpm cli workspaces map-workspaces +@types/libnpmsearch | TypeScript… | =types | 2019-09-26 | 2.0.1 | +` + +exports[`test/lib/commands/search.js TAP search exclude string > results should not have libnpmversion 1`] = ` +NAME | DESCRIPTION | AUTHOR | DATE | VERSION | KEYWORDS +libnpm | Collection of… | =nlf… | 2019-07-16 | 3.0.1 | npm api package manager lib +libnpmaccess | programmatic… | =nlf… | 2020-11-03 | 4.0.1 | libnpmaccess +@evocateur/libnpmaccess | programmatic… | =evocateur | 2019-07-16 | 3.1.2 | +@evocateur/libnpmpublish | Programmatic API… | =evocateur | 2019-07-16 | 1.2.2 | +libnpmorg | Programmatic api… | =nlf… | 2020-11-03 | 2.0.1 | libnpm npm package manager api orgs teams +libnpmsearch | Programmatic API… | =nlf… | 2020-12-08 | 3.1.0 | npm search api libnpm +libnpmteam | npm Team management… | =nlf… | 2020-11-03 | 2.0.2 | +libnpmhook | programmatic API… | =nlf… | 2020-11-03 | 6.0.1 | npm hooks registry npm api +libnpmpublish | Programmatic API… | =nlf… | 2020-11-03 | 4.0.0 | +libnpmfund | Programmatic API… | =nlf… | 2020-12-08 | 1.0.2 | npm npmcli libnpm cli git fund gitfund +@npmcli/map-workspaces | Retrieves a… | =nlf… | 2020-09-30 | 1.0.1 | npm npmcli libnpm cli workspaces map-workspaces +@types/libnpmsearch | TypeScript… | =types | 2019-09-26 | 2.0.1 | +` + +exports[`test/lib/commands/search.js TAP search exclude username with upper case letters > results should not have nlf 1`] = ` +NAME | DESCRIPTION | AUTHOR | DATE | VERSION | KEYWORDS +@evocateur/libnpmaccess | programmatic… | =evocateur | 2019-07-16 | 3.1.2 | +@evocateur/libnpmpublish | Programmatic API… | =evocateur | 2019-07-16 | 1.2.2 | +@types/libnpmsearch | TypeScript… | =types | 2019-09-26 | 2.0.1 | ` diff --git a/tap-snapshots/test/lib/commands/shrinkwrap.js.test.cjs b/tap-snapshots/test/lib/commands/shrinkwrap.js.test.cjs index ddc80a9..d97f13d 100644 --- a/tap-snapshots/test/lib/commands/shrinkwrap.js.test.cjs +++ b/tap-snapshots/test/lib/commands/shrinkwrap.js.test.cjs @@ -16,7 +16,7 @@ exports[`test/lib/commands/shrinkwrap.js TAP with hidden lockfile ancient > must }, "config": {}, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 1, "requires": true }, @@ -39,7 +39,7 @@ exports[`test/lib/commands/shrinkwrap.js TAP with hidden lockfile ancient upgrad "lockfile-version": 3 }, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 3, "requires": true, "packages": {} @@ -61,7 +61,7 @@ exports[`test/lib/commands/shrinkwrap.js TAP with hidden lockfile existing > mus }, "config": {}, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 2, "requires": true, "packages": {} @@ -85,7 +85,7 @@ exports[`test/lib/commands/shrinkwrap.js TAP with hidden lockfile existing downg "lockfile-version": 1 }, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 1, "requires": true }, @@ -108,7 +108,7 @@ exports[`test/lib/commands/shrinkwrap.js TAP with hidden lockfile existing upgra "lockfile-version": 3 }, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 3, "requires": true, "packages": {} @@ -124,13 +124,13 @@ exports[`test/lib/commands/shrinkwrap.js TAP with nothing ancient > must match s "localPrefix": {}, "config": {}, "shrinkwrap": { - "name": "root", - "lockfileVersion": 2, + "name": "prefix", + "lockfileVersion": 3, "requires": true, "packages": {} }, "logs": [ - "created a lockfile as npm-shrinkwrap.json with version 2" + "created a lockfile as npm-shrinkwrap.json with version 3" ] } ` @@ -142,7 +142,7 @@ exports[`test/lib/commands/shrinkwrap.js TAP with nothing ancient upgrade > must "lockfile-version": 3 }, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 3, "requires": true, "packages": {} @@ -162,17 +162,17 @@ exports[`test/lib/commands/shrinkwrap.js TAP with npm-shrinkwrap.json ancient > }, "config": {}, "shrinkwrap": { - "name": "root", - "lockfileVersion": 2, + "name": "prefix", + "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "root" + "name": "prefix" } } }, "logs": [ - "npm-shrinkwrap.json updated to version 2" + "npm-shrinkwrap.json updated to version 3" ] } ` @@ -188,12 +188,12 @@ exports[`test/lib/commands/shrinkwrap.js TAP with npm-shrinkwrap.json ancient up "lockfile-version": 3 }, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "root" + "name": "prefix" } } }, @@ -212,12 +212,12 @@ exports[`test/lib/commands/shrinkwrap.js TAP with npm-shrinkwrap.json existing > }, "config": {}, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 2, "requires": true, "packages": { "": { - "name": "root" + "name": "prefix" } } }, @@ -238,7 +238,7 @@ exports[`test/lib/commands/shrinkwrap.js TAP with npm-shrinkwrap.json existing d "lockfile-version": 1 }, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 1, "requires": true }, @@ -259,12 +259,12 @@ exports[`test/lib/commands/shrinkwrap.js TAP with npm-shrinkwrap.json existing u "lockfile-version": 3 }, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "root" + "name": "prefix" } } }, @@ -283,17 +283,17 @@ exports[`test/lib/commands/shrinkwrap.js TAP with package-lock.json ancient > mu }, "config": {}, "shrinkwrap": { - "name": "root", - "lockfileVersion": 2, + "name": "prefix", + "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "root" + "name": "prefix" } } }, "logs": [ - "package-lock.json has been renamed to npm-shrinkwrap.json and updated to version 2" + "package-lock.json has been renamed to npm-shrinkwrap.json and updated to version 3" ] } ` @@ -309,12 +309,12 @@ exports[`test/lib/commands/shrinkwrap.js TAP with package-lock.json ancient upgr "lockfile-version": 3 }, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "root" + "name": "prefix" } } }, @@ -333,12 +333,12 @@ exports[`test/lib/commands/shrinkwrap.js TAP with package-lock.json existing > m }, "config": {}, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 2, "requires": true, "packages": { "": { - "name": "root" + "name": "prefix" } } }, @@ -359,7 +359,7 @@ exports[`test/lib/commands/shrinkwrap.js TAP with package-lock.json existing dow "lockfile-version": 1 }, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 1, "requires": true }, @@ -380,12 +380,12 @@ exports[`test/lib/commands/shrinkwrap.js TAP with package-lock.json existing upg "lockfile-version": 3 }, "shrinkwrap": { - "name": "root", + "name": "prefix", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "root" + "name": "prefix" } } }, diff --git a/tap-snapshots/test/lib/commands/unpublish.js.test.cjs b/tap-snapshots/test/lib/commands/unpublish.js.test.cjs deleted file mode 100644 index d84f26f..0000000 --- a/tap-snapshots/test/lib/commands/unpublish.js.test.cjs +++ /dev/null @@ -1,14 +0,0 @@ -/* IMPORTANT - * This snapshot file is auto-generated, but designed for humans. - * It should be checked into source control and tracked carefully. - * Re-generate by setting TAP_SNAPSHOT=1 and running tests. - * Make sure to inspect the output below. Do not ignore changes! - */ -'use strict' -exports[`test/lib/commands/unpublish.js TAP workspaces all workspaces --force > should output all workspaces 1`] = ` -- workspace-a- workspace-b- workspace-n -` - -exports[`test/lib/commands/unpublish.js TAP workspaces one workspace --force > should output one workspaces 1`] = ` -- workspace-a -` diff --git a/tap-snapshots/test/lib/commands/version.js.test.cjs b/tap-snapshots/test/lib/commands/version.js.test.cjs new file mode 100644 index 0000000..0fed009 --- /dev/null +++ b/tap-snapshots/test/lib/commands/version.js.test.cjs @@ -0,0 +1,78 @@ +/* IMPORTANT + * This snapshot file is auto-generated, but designed for humans. + * It should be checked into source control and tracked carefully. + * Re-generate by setting TAP_SNAPSHOT=1 and running tests. + * Make sure to inspect the output below. Do not ignore changes! + */ +'use strict' +exports[`test/lib/commands/version.js TAP empty versions workspaces with one arg, all workspaces > must match snapshot 1`] = ` +{ + "name": "workspaces-test", + "version": "1.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "workspaces-test", + "version": "1.0.0", + "workspaces": [ + "workspace-a", + "workspace-b" + ] + }, + "node_modules/workspace-a": { + "resolved": "workspace-a", + "link": true + }, + "node_modules/workspace-b": { + "resolved": "workspace-b", + "link": true + }, + "workspace-a": { + "version": "2.0.0" + }, + "workspace-b": { + "version": "2.0.0" + } + } +} + +` + +exports[`test/lib/commands/version.js TAP empty versions workspaces with one arg, all workspaces, saves package.json > must match snapshot 1`] = ` +{ + "name": "workspaces-test", + "version": "1.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "workspaces-test", + "version": "1.0.0", + "workspaces": [ + "workspace-a", + "workspace-b" + ], + "dependencies": { + "workspace-a": "^2.0.0", + "workspace-b": "^2.0.0" + } + }, + "node_modules/workspace-a": { + "resolved": "workspace-a", + "link": true + }, + "node_modules/workspace-b": { + "resolved": "workspace-b", + "link": true + }, + "workspace-a": { + "version": "2.0.0" + }, + "workspace-b": { + "version": "2.0.0" + } + } +} + +` diff --git a/tap-snapshots/test/lib/commands/view.js.test.cjs b/tap-snapshots/test/lib/commands/view.js.test.cjs index 72d09b4..d5b7a3b 100644 --- a/tap-snapshots/test/lib/commands/view.js.test.cjs +++ b/tap-snapshots/test/lib/commands/view.js.test.cjs @@ -5,135 +5,142 @@ * Make sure to inspect the output below. Do not ignore changes! */ 'use strict' -exports[`test/lib/commands/view.js TAP should log info by field name array field - 1 element > must match snapshot 1`] = ` - -claudia -` - -exports[`test/lib/commands/view.js TAP should log info by field name array field - 2 elements > must match snapshot 1`] = ` - -maintainers[0].name = 'claudia' -maintainers[1].name = 'isaacs' -` - -exports[`test/lib/commands/view.js TAP should log info by field name maintainers with email > must match snapshot 1`] = ` - -{ - "maintainers": [ - { - "name": "claudia", - "email": "c@yellow.com", - "twitter": "cyellow" - }, - { - "name": "isaacs", - "email": "i@yellow.com", - "twitter": "iyellow" - } - ], - "name": "yellow" -} -` - -exports[`test/lib/commands/view.js TAP should log info by field name maintainers with url > must match snapshot 1`] = ` - -[ - "claudia (http://c.pink.com)", - "isaacs (http://i.pink.com)" -] -` - -exports[`test/lib/commands/view.js TAP should log info by field name nested field with brackets > must match snapshot 1`] = ` - -"123" -` - -exports[`test/lib/commands/view.js TAP should log info by field name readme > must match snapshot 1`] = ` - -a very useful readme -` - -exports[`test/lib/commands/view.js TAP should log info by field name several fields > must match snapshot 1`] = ` - -{ - "name": "yellow", - "version": "1.0.0" -} -` - -exports[`test/lib/commands/view.js TAP should log info by field name several fields with several versions > must match snapshot 1`] = ` - -yellow@1.0.0 'claudia' -yellow@1.0.1 'claudia' -yellow@1.0.2 'claudia' -` - -exports[`test/lib/commands/view.js TAP should log info of package in current working dir non-specific version > must match snapshot 1`] = ` - - -blue@1.0.0 | Proprietary | deps: none | versions: 2 - -dist -.tarball:http://hm.blue.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B - -dist-tags: -latest: 1.0.0 - -published {TIME} ago -` - -exports[`test/lib/commands/view.js TAP should log info of package in current working dir specific version > must match snapshot 1`] = ` - - -blue@1.0.0 | Proprietary | deps: none | versions: 2 - -dist -.tarball:http://hm.blue.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B - -dist-tags: -latest: 1.0.0 - -published {TIME} ago -` - -exports[`test/lib/commands/view.js TAP should log package info package from git > must match snapshot 1`] = ` - +exports[`test/lib/commands/view.js TAP deprecated package with license, bugs, repository and other fields > must match snapshot 1`] = ` green@1.0.0 | ACME | deps: 2 | versions: 2 green is a very important color DEPRECATED!! - true -keywords:colors, green, crayola +keywords:,colors, green, crayola -bin:green +bin:,green dist -.tarball:http://hm.green.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.green.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1.0 GB dependencies: red: 1.0.0 yellow: 1.0.0 maintainers: --claudia <c@yellow.com> --isaacs <i@yellow.com> +-,claudia <c@yellow.com> +-,isaacs <i@yellow.com> dist-tags: latest: 1.0.0 ` -exports[`test/lib/commands/view.js TAP should log package info package with --json and semver range > must match snapshot 1`] = ` +exports[`test/lib/commands/view.js TAP deprecated package with unicode > must match snapshot 1`] = ` +green@1.0.0 | ACME | deps: 2 | versions: 2 +green is a very important color + +DEPRECATED ⚠️ - true + +keywords:,colors, green, crayola + +bin:,green + +dist +.tarball:,http://hm.green.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1.0 GB + +dependencies: +red: 1.0.0 +yellow: 1.0.0 + +maintainers: +-,claudia <c@yellow.com> +-,isaacs <i@yellow.com> + +dist-tags: +latest: 1.0.0 +` + +exports[`test/lib/commands/view.js TAP package from git > must match snapshot 1`] = ` + +green@1.0.0 | ACME | deps: 2 | versions: 2 +green is a very important color + +DEPRECATED!! - true + +keywords:,colors, green, crayola + +bin:,green + +dist +.tarball:,http://hm.green.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1.0 GB + +dependencies: +red: 1.0.0 +yellow: 1.0.0 + +maintainers: +-,claudia <c@yellow.com> +-,isaacs <i@yellow.com> + +dist-tags: +latest: 1.0.0 +` + +exports[`test/lib/commands/view.js TAP package in cwd directory > must match snapshot 1`] = ` + +blue@1.0.0 | Proprietary | deps: none | versions: 2 + +dist +.tarball:,http://hm.blue.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1 B + +dist-tags: +latest: 1.0.0 + +published {TIME} ago +` + +exports[`test/lib/commands/view.js TAP package in cwd non-specific version > must match snapshot 1`] = ` + +blue@1.0.0 | Proprietary | deps: none | versions: 2 + +dist +.tarball:,http://hm.blue.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1 B + +dist-tags: +latest: 1.0.0 + +published {TIME} ago +` + +exports[`test/lib/commands/view.js TAP package in cwd specific version > must match snapshot 1`] = ` + +blue@1.0.0 | Proprietary | deps: none | versions: 2 + +dist +.tarball:,http://hm.blue.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1 B + +dist-tags: +latest: 1.0.0 + +published {TIME} ago +` + +exports[`test/lib/commands/view.js TAP package with --json and semver range > must match snapshot 1`] = ` [ { "_npmUser": "claudia <claudia@cyan.com>", @@ -151,7 +158,7 @@ exports[`test/lib/commands/view.js TAP should log package info package with --js "tarball": "http://hm.cyan.com/1.0.0.tgz", "integrity": "---", "fileCount": 1, - "unpackedSize": 1 + "unpackedSize": 1000000 } }, { @@ -168,77 +175,44 @@ exports[`test/lib/commands/view.js TAP should log package info package with --js ] ` -exports[`test/lib/commands/view.js TAP should log package info package with homepage > must match snapshot 1`] = ` - +exports[`test/lib/commands/view.js TAP package with homepage > must match snapshot 1`] = ` orange@1.0.0 | Proprietary | deps: none | versions: 2 http://hm.orange.com dist -.tarball:http://hm.orange.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.orange.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1 B dist-tags: latest: 1.0.0 ` -exports[`test/lib/commands/view.js TAP should log package info package with license, bugs, repository and other fields > must match snapshot 1`] = ` - - -green@1.0.0 | ACME | deps: 2 | versions: 2 -green is a very important color - -DEPRECATED!! - true - -keywords:colors, green, crayola - -bin:green - -dist -.tarball:http://hm.green.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B - -dependencies: -red: 1.0.0 -yellow: 1.0.0 - -maintainers: --claudia <c@yellow.com> --isaacs <i@yellow.com> - -dist-tags: -latest: 1.0.0 -` - -exports[`test/lib/commands/view.js TAP should log package info package with maintainers info as object > must match snapshot 1`] = ` - +exports[`test/lib/commands/view.js TAP package with maintainers info as object > must match snapshot 1`] = ` pink@1.0.0 | Proprietary | deps: none | versions: 2 dist -.tarball:http://hm.pink.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.pink.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1 B dist-tags: latest: 1.0.0 ` -exports[`test/lib/commands/view.js TAP should log package info package with more than 25 deps > must match snapshot 1`] = ` - +exports[`test/lib/commands/view.js TAP package with more than 25 deps > must match snapshot 1`] = ` black@1.0.0 | Proprietary | deps: 25 | versions: 2 dist -.tarball:http://hm.black.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.black.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1 B dependencies: 0: 1.0.0 @@ -271,16 +245,15 @@ dist-tags: latest: 1.0.0 ` -exports[`test/lib/commands/view.js TAP should log package info package with no modified time > must match snapshot 1`] = ` - +exports[`test/lib/commands/view.js TAP package with no modified time > must match snapshot 1`] = ` cyan@1.0.0 | Proprietary | deps: none | versions: 2 dist -.tarball:http://hm.cyan.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.cyan.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1.0 MB dist-tags: latest: 1.0.0 @@ -288,16 +261,15 @@ dist-tags: published by claudia <claudia@cyan.com> ` -exports[`test/lib/commands/view.js TAP should log package info package with no repo or homepage > must match snapshot 1`] = ` - +exports[`test/lib/commands/view.js TAP package with no repo or homepage > must match snapshot 1`] = ` blue@1.0.0 | Proprietary | deps: none | versions: 2 dist -.tarball:http://hm.blue.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.blue.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1 B dist-tags: latest: 1.0.0 @@ -305,16 +277,15 @@ dist-tags: published {TIME} ago ` -exports[`test/lib/commands/view.js TAP should log package info package with semver range > must match snapshot 1`] = ` - +exports[`test/lib/commands/view.js TAP package with semver range > must match snapshot 1`] = ` blue@1.0.0 | Proprietary | deps: none | versions: 2 dist -.tarball:http://hm.blue.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.blue.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1 B dist-tags: latest: 1.0.0 @@ -324,10 +295,10 @@ published {TIME} ago blue@1.0.1 | Proprietary | deps: none | versions: 2 dist -.tarball:http://hm.blue.com/1.0.1.tgz -.shasum:124 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.blue.com/1.0.1.tgz +.shasum:,124 +.integrity:,--- +.unpackedSize:,1.0 kB dist-tags: latest: 1.0.0 @@ -335,8 +306,47 @@ dist-tags: published over a year from now ` -exports[`test/lib/commands/view.js TAP workspaces all workspaces --json > must match snapshot 1`] = ` +exports[`test/lib/commands/view.js TAP specific field names array field - 1 element > must match snapshot 1`] = ` +claudia +` +exports[`test/lib/commands/view.js TAP specific field names array field - 2 elements > must match snapshot 1`] = ` +maintainers[0].name = 'claudia' +maintainers[1].name = 'isaacs' +` + +exports[`test/lib/commands/view.js TAP specific field names maintainers with email > must match snapshot 1`] = ` +maintainers = [ + { name: 'claudia', email: 'c@yellow.com', twitter: 'cyellow' }, + { name: 'isaacs', email: 'i@yellow.com', twitter: 'iyellow' } +] +name = 'yellow' +` + +exports[`test/lib/commands/view.js TAP specific field names maintainers with url > must match snapshot 1`] = ` +[ 'claudia (http://c.pink.com)', 'isaacs (http://i.pink.com)' ] +` + +exports[`test/lib/commands/view.js TAP specific field names nested field with brackets > must match snapshot 1`] = ` +123 +` + +exports[`test/lib/commands/view.js TAP specific field names readme > must match snapshot 1`] = ` +a very useful readme +` + +exports[`test/lib/commands/view.js TAP specific field names several fields > must match snapshot 1`] = ` +name = 'yellow' +version = '1.0.0' +` + +exports[`test/lib/commands/view.js TAP specific field names several fields with several versions > must match snapshot 1`] = ` +yellow@1.0.0 'claudia' +yellow@1.0.1 'claudia' +yellow@1.0.2 'claudia' +` + +exports[`test/lib/commands/view.js TAP workspaces all workspaces --json > must match snapshot 1`] = ` { "green": { "_id": "green", @@ -389,7 +399,7 @@ exports[`test/lib/commands/view.js TAP workspaces all workspaces --json > must m "tarball": "http://hm.green.com/1.0.0.tgz", "integrity": "---", "fileCount": 1, - "unpackedSize": 1 + "unpackedSize": 1000000000 } }, "orange": { @@ -417,29 +427,28 @@ exports[`test/lib/commands/view.js TAP workspaces all workspaces --json > must m exports[`test/lib/commands/view.js TAP workspaces all workspaces > must match snapshot 1`] = ` - green@1.0.0 | ACME | deps: 2 | versions: 2 green is a very important color DEPRECATED!! - true -keywords:colors, green, crayola +keywords:,colors, green, crayola -bin:green +bin:,green dist -.tarball:http://hm.green.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.green.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1.0 GB dependencies: red: 1.0.0 yellow: 1.0.0 maintainers: --claudia <c@yellow.com> --isaacs <i@yellow.com> +-,claudia <c@yellow.com> +-,isaacs <i@yellow.com> dist-tags: latest: 1.0.0 @@ -448,10 +457,10 @@ dist-tags: http://hm.orange.com dist -.tarball:http://hm.orange.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.orange.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1 B dist-tags: latest: 1.0.0 @@ -462,13 +471,11 @@ exports[`test/lib/commands/view.js TAP workspaces all workspaces nonexistent fie ` exports[`test/lib/commands/view.js TAP workspaces all workspaces nonexistent field > must match snapshot 1`] = ` - green: orange: ` exports[`test/lib/commands/view.js TAP workspaces all workspaces single field --json > must match snapshot 1`] = ` - { "green": "green", "orange": "orange" @@ -476,7 +483,6 @@ exports[`test/lib/commands/view.js TAP workspaces all workspaces single field -- ` exports[`test/lib/commands/view.js TAP workspaces all workspaces single field > must match snapshot 1`] = ` - green: green orange: @@ -485,55 +491,56 @@ orange exports[`test/lib/commands/view.js TAP workspaces one specific workspace > must match snapshot 1`] = ` - green@1.0.0 | ACME | deps: 2 | versions: 2 green is a very important color DEPRECATED!! - true -keywords:colors, green, crayola +keywords:,colors, green, crayola -bin:green +bin:,green dist -.tarball:http://hm.green.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.green.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1.0 GB dependencies: red: 1.0.0 yellow: 1.0.0 maintainers: --claudia <c@yellow.com> --isaacs <i@yellow.com> +-,claudia <c@yellow.com> +-,isaacs <i@yellow.com> dist-tags: latest: 1.0.0 ` exports[`test/lib/commands/view.js TAP workspaces remote package name > must match snapshot 1`] = ` -Ignoring workspaces for specified package(s) -` - -exports[`test/lib/commands/view.js TAP workspaces remote package name > must match snapshot 2`] = ` - pink@1.0.0 | Proprietary | deps: none | versions: 2 dist -.tarball:http://hm.pink.com/1.0.0.tgz -.shasum:123 -.integrity:--- -.unpackedSize:1 B +.tarball:,http://hm.pink.com/1.0.0.tgz +.shasum:,123 +.integrity:,--- +.unpackedSize:,1 B dist-tags: latest: 1.0.0 ` -exports[`test/lib/commands/view.js TAP workspaces single workspace --json > must match snapshot 1`] = ` +exports[`test/lib/commands/view.js TAP workspaces remote package name > should have warning of ignoring workspaces 1`] = ` +Array [ + Array [ + "Ignoring workspaces for specified package(s)", + ], +] +` +exports[`test/lib/commands/view.js TAP workspaces single workspace --json > must match snapshot 1`] = ` { "green": { "_id": "green", @@ -586,7 +593,7 @@ exports[`test/lib/commands/view.js TAP workspaces single workspace --json > must "tarball": "http://hm.green.com/1.0.0.tgz", "integrity": "---", "fileCount": 1, - "unpackedSize": 1 + "unpackedSize": 1000000000 } } } diff --git a/tap-snapshots/test/lib/docs.js.test.cjs b/tap-snapshots/test/lib/docs.js.test.cjs new file mode 100644 index 0000000..8038dfa --- /dev/null +++ b/tap-snapshots/test/lib/docs.js.test.cjs @@ -0,0 +1,4278 @@ +/* IMPORTANT + * This snapshot file is auto-generated, but designed for humans. + * It should be checked into source control and tracked carefully. + * Re-generate by setting TAP_SNAPSHOT=1 and running tests. + * Make sure to inspect the output below. Do not ignore changes! + */ +'use strict' +exports[`test/lib/docs.js TAP basic usage > must match snapshot 1`] = ` +npm <command> + +Usage: + +npm install install all the dependencies in your project +npm install <foo> add the <foo> dependency to your project +npm test run this project's tests +npm run <foo> run the script named <foo> +npm <command> -h quick help on <command> +npm -l display usage info for all commands +npm help <term> search for help on <term> +npm help npm more involved overview + +All commands: + + + +Specify configs in the ini-formatted file: + /some/config/file/.npmrc +or on the command line via: npm <command> --key=value + +More configuration info: npm help config +Configuration fields: npm help 7 config + +npm@{VERSION} {BASEDIR} +` + +exports[`test/lib/docs.js TAP command list > abbrevs 1`] = ` +Object { + "ac": "access", + "acc": "access", + "acce": "access", + "acces": "access", + "access": "access", + "add": "add", + "add-": "add-user", + "add-u": "add-user", + "add-us": "add-user", + "add-use": "add-user", + "add-user": "add-user", + "addu": "adduser", + "addus": "adduser", + "adduse": "adduser", + "adduser": "adduser", + "aud": "audit", + "audi": "audit", + "audit": "audit", + "aut": "author", + "auth": "author", + "autho": "author", + "author": "author", + "b": "bugs", + "bu": "bugs", + "bug": "bugs", + "bugs": "bugs", + "c": "c", + "ca": "cache", + "cac": "cache", + "cach": "cache", + "cache": "cache", + "ci": "ci", + "cit": "cit", + "clean-install": "clean-install", + "clean-install-": "clean-install-test", + "clean-install-t": "clean-install-test", + "clean-install-te": "clean-install-test", + "clean-install-tes": "clean-install-test", + "clean-install-test": "clean-install-test", + "com": "completion", + "comp": "completion", + "compl": "completion", + "comple": "completion", + "complet": "completion", + "completi": "completion", + "completio": "completion", + "completion": "completion", + "con": "config", + "conf": "config", + "confi": "config", + "config": "config", + "cr": "create", + "cre": "create", + "crea": "create", + "creat": "create", + "create": "create", + "dd": "ddp", + "ddp": "ddp", + "ded": "dedupe", + "dedu": "dedupe", + "dedup": "dedupe", + "dedupe": "dedupe", + "dep": "deprecate", + "depr": "deprecate", + "depre": "deprecate", + "deprec": "deprecate", + "depreca": "deprecate", + "deprecat": "deprecate", + "deprecate": "deprecate", + "dif": "diff", + "diff": "diff", + "dist-tag": "dist-tag", + "dist-tags": "dist-tags", + "docs": "docs", + "doct": "doctor", + "docto": "doctor", + "doctor": "doctor", + "ed": "edit", + "edi": "edit", + "edit": "edit", + "exe": "exec", + "exec": "exec", + "expla": "explain", + "explai": "explain", + "explain": "explain", + "explo": "explore", + "explor": "explore", + "explore": "explore", + "find": "find", + "find-": "find-dupes", + "find-d": "find-dupes", + "find-du": "find-dupes", + "find-dup": "find-dupes", + "find-dupe": "find-dupes", + "find-dupes": "find-dupes", + "fu": "fund", + "fun": "fund", + "fund": "fund", + "g": "get", + "ge": "get", + "get": "get", + "he": "help", + "hel": "help", + "help": "help", + "hl": "hlep", + "hle": "hlep", + "hlep": "hlep", + "hom": "home", + "home": "home", + "hoo": "hook", + "hook": "hook", + "i": "i", + "ic": "ic", + "in": "in", + "inf": "info", + "info": "info", + "ini": "init", + "init": "init", + "inn": "innit", + "inni": "innit", + "innit": "innit", + "ins": "ins", + "inst": "inst", + "insta": "insta", + "instal": "instal", + "install": "install", + "install-ci": "install-ci-test", + "install-ci-": "install-ci-test", + "install-ci-t": "install-ci-test", + "install-ci-te": "install-ci-test", + "install-ci-tes": "install-ci-test", + "install-ci-test": "install-ci-test", + "install-cl": "install-clean", + "install-cle": "install-clean", + "install-clea": "install-clean", + "install-clean": "install-clean", + "install-t": "install-test", + "install-te": "install-test", + "install-tes": "install-test", + "install-test": "install-test", + "isnt": "isnt", + "isnta": "isnta", + "isntal": "isntal", + "isntall": "isntall", + "isntall-": "isntall-clean", + "isntall-c": "isntall-clean", + "isntall-cl": "isntall-clean", + "isntall-cle": "isntall-clean", + "isntall-clea": "isntall-clean", + "isntall-clean": "isntall-clean", + "iss": "issues", + "issu": "issues", + "issue": "issues", + "issues": "issues", + "it": "it", + "la": "la", + "lin": "link", + "link": "link", + "lis": "list", + "list": "list", + "ll": "ll", + "ln": "ln", + "logi": "login", + "login": "login", + "logo": "logout", + "logou": "logout", + "logout": "logout", + "ls": "ls", + "og": "ogr", + "ogr": "ogr", + "or": "org", + "org": "org", + "ou": "outdated", + "out": "outdated", + "outd": "outdated", + "outda": "outdated", + "outdat": "outdated", + "outdate": "outdated", + "outdated": "outdated", + "ow": "owner", + "own": "owner", + "owne": "owner", + "owner": "owner", + "pa": "pack", + "pac": "pack", + "pack": "pack", + "pi": "ping", + "pin": "ping", + "ping": "ping", + "pk": "pkg", + "pkg": "pkg", + "pre": "prefix", + "pref": "prefix", + "prefi": "prefix", + "prefix": "prefix", + "pro": "profile", + "prof": "profile", + "profi": "profile", + "profil": "profile", + "profile": "profile", + "pru": "prune", + "prun": "prune", + "prune": "prune", + "pu": "publish", + "pub": "publish", + "publ": "publish", + "publi": "publish", + "publis": "publish", + "publish": "publish", + "q": "query", + "qu": "query", + "que": "query", + "quer": "query", + "query": "query", + "r": "r", + "rb": "rb", + "reb": "rebuild", + "rebu": "rebuild", + "rebui": "rebuild", + "rebuil": "rebuild", + "rebuild": "rebuild", + "rem": "remove", + "remo": "remove", + "remov": "remove", + "remove": "remove", + "rep": "repo", + "repo": "repo", + "res": "restart", + "rest": "restart", + "resta": "restart", + "restar": "restart", + "restart": "restart", + "rm": "rm", + "ro": "root", + "roo": "root", + "root": "root", + "rum": "rum", + "run": "run", + "run-": "run-script", + "run-s": "run-script", + "run-sc": "run-script", + "run-scr": "run-script", + "run-scri": "run-script", + "run-scrip": "run-script", + "run-script": "run-script", + "s": "s", + "se": "se", + "sea": "search", + "sear": "search", + "searc": "search", + "search": "search", + "set": "set", + "sho": "show", + "show": "show", + "shr": "shrinkwrap", + "shri": "shrinkwrap", + "shrin": "shrinkwrap", + "shrink": "shrinkwrap", + "shrinkw": "shrinkwrap", + "shrinkwr": "shrinkwrap", + "shrinkwra": "shrinkwrap", + "shrinkwrap": "shrinkwrap", + "si": "sit", + "sit": "sit", + "star": "star", + "stars": "stars", + "start": "start", + "sto": "stop", + "stop": "stop", + "t": "t", + "tea": "team", + "team": "team", + "tes": "test", + "test": "test", + "to": "token", + "tok": "token", + "toke": "token", + "token": "token", + "ts": "tst", + "tst": "tst", + "ud": "udpate", + "udp": "udpate", + "udpa": "udpate", + "udpat": "udpate", + "udpate": "udpate", + "un": "un", + "uni": "uninstall", + "unin": "uninstall", + "unins": "uninstall", + "uninst": "uninstall", + "uninsta": "uninstall", + "uninstal": "uninstall", + "uninstall": "uninstall", + "unl": "unlink", + "unli": "unlink", + "unlin": "unlink", + "unlink": "unlink", + "unp": "unpublish", + "unpu": "unpublish", + "unpub": "unpublish", + "unpubl": "unpublish", + "unpubli": "unpublish", + "unpublis": "unpublish", + "unpublish": "unpublish", + "uns": "unstar", + "unst": "unstar", + "unsta": "unstar", + "unstar": "unstar", + "up": "up", + "upd": "update", + "upda": "update", + "updat": "update", + "update": "update", + "upg": "upgrade", + "upgr": "upgrade", + "upgra": "upgrade", + "upgrad": "upgrade", + "upgrade": "upgrade", + "ur": "urn", + "urn": "urn", + "v": "v", + "veri": "verison", + "veris": "verison", + "veriso": "verison", + "verison": "verison", + "vers": "version", + "versi": "version", + "versio": "version", + "version": "version", + "vi": "view", + "vie": "view", + "view": "view", + "who": "whoami", + "whoa": "whoami", + "whoam": "whoami", + "whoami": "whoami", + "why": "why", + "x": "x", +} +` + +exports[`test/lib/docs.js TAP command list > aliases 1`] = ` +Object { + "add": "install", + "add-user": "adduser", + "author": "owner", + "c": "config", + "cit": "install-ci-test", + "clean-install": "ci", + "clean-install-test": "cit", + "create": "init", + "ddp": "dedupe", + "dist-tags": "dist-tag", + "find": "search", + "hlep": "help", + "home": "docs", + "i": "install", + "ic": "ci", + "in": "install", + "info": "view", + "innit": "init", + "ins": "install", + "inst": "install", + "insta": "install", + "instal": "install", + "install-clean": "ci", + "isnt": "install", + "isnta": "install", + "isntal": "install", + "isntall": "install", + "isntall-clean": "ci", + "issues": "bugs", + "it": "install-test", + "la": "ll", + "list": "ls", + "ln": "link", + "ogr": "org", + "r": "uninstall", + "rb": "rebuild", + "remove": "uninstall", + "rm": "uninstall", + "rum": "run-script", + "run": "run-script", + "s": "search", + "se": "search", + "show": "view", + "sit": "cit", + "t": "test", + "tst": "test", + "udpate": "update", + "un": "uninstall", + "unlink": "uninstall", + "up": "update", + "upgrade": "update", + "urn": "run-script", + "v": "view", + "verison": "version", + "why": "explain", + "x": "exec", +} +` + +exports[`test/lib/docs.js TAP command list > allCommands 1`] = ` +Array [ + "access", + "adduser", + "audit", + "bugs", + "cache", + "ci", + "completion", + "config", + "dedupe", + "deprecate", + "diff", + "dist-tag", + "docs", + "doctor", + "edit", + "exec", + "explain", + "explore", + "find-dupes", + "fund", + "get", + "help", + "help-search", + "hook", + "init", + "install", + "install-ci-test", + "install-test", + "link", + "ll", + "login", + "logout", + "ls", + "org", + "outdated", + "owner", + "pack", + "ping", + "pkg", + "prefix", + "profile", + "prune", + "publish", + "query", + "rebuild", + "repo", + "restart", + "root", + "run-script", + "search", + "set", + "shrinkwrap", + "star", + "stars", + "start", + "stop", + "team", + "test", + "token", + "uninstall", + "unpublish", + "unstar", + "update", + "version", + "view", + "whoami", +] +` + +exports[`test/lib/docs.js TAP command list > commands 1`] = ` +Array [ + "access", + "adduser", + "audit", + "bugs", + "cache", + "ci", + "completion", + "config", + "dedupe", + "deprecate", + "diff", + "dist-tag", + "docs", + "doctor", + "edit", + "exec", + "explain", + "explore", + "find-dupes", + "fund", + "get", + "help", + "hook", + "init", + "install", + "install-ci-test", + "install-test", + "link", + "ll", + "login", + "logout", + "ls", + "org", + "outdated", + "owner", + "pack", + "ping", + "pkg", + "prefix", + "profile", + "prune", + "publish", + "query", + "rebuild", + "repo", + "restart", + "root", + "run-script", + "search", + "set", + "shrinkwrap", + "star", + "stars", + "start", + "stop", + "team", + "test", + "token", + "uninstall", + "unpublish", + "unstar", + "update", + "version", + "view", + "whoami", +] +` + +exports[`test/lib/docs.js TAP command list > plumbing 1`] = ` +Array [ + "help-search", +] +` + +exports[`test/lib/docs.js TAP config > all definitions 1`] = ` +#### \`_auth\` + +* Default: null +* Type: null or String + +A basic-auth string to use when authenticating against the npm registry. +This will ONLY be used to authenticate against the npm registry. For other +registries you will need to scope it like "//other-registry.tld/:_auth" + +Warning: This should generally not be set via a command-line option. It is +safer to use a registry-provided authentication bearer token stored in the +~/.npmrc file by running \`npm login\`. + +#### \`access\` + +* Default: 'public' for new packages, existing packages it will not change the + current level +* Type: null, "restricted", or "public" + +If do not want your scoped package to be publicly viewable (and installable) +set \`--access=restricted\`. + +Unscoped packages can not be set to \`restricted\`. + +Note: This defaults to not changing the current access level for existing +packages. Specifying a value of \`restricted\` or \`public\` during publish will +change the access for an existing package the same way that \`npm access set +status\` would. + +#### \`all\` + +* Default: false +* Type: Boolean + +When running \`npm outdated\` and \`npm ls\`, setting \`--all\` will show all +outdated or installed packages, rather than only those directly depended +upon by the current project. + +#### \`allow-same-version\` + +* Default: false +* Type: Boolean + +Prevents throwing an error when \`npm version\` is used to set the new version +to the same value as the current version. + +#### \`audit\` + +* Default: true +* Type: Boolean + +When "true" submit audit reports alongside the current npm command to the +default registry and all registries configured for scopes. See the +documentation for [\`npm audit\`](/commands/npm-audit) for details on what is +submitted. + +#### \`audit-level\` + +* Default: null +* Type: null, "info", "low", "moderate", "high", "critical", or "none" + +The minimum level of vulnerability for \`npm audit\` to exit with a non-zero +exit code. + +#### \`auth-type\` + +* Default: "web" +* Type: "legacy" or "web" + +What authentication strategy to use with \`login\`. + +#### \`before\` + +* Default: null +* Type: null or Date + +If passed to \`npm install\`, will rebuild the npm tree such that only +versions that were available **on or before** the \`--before\` time get +installed. If there's no versions available for the current set of direct +dependencies, the command will error. + +If the requested version is a \`dist-tag\` and the given tag does not pass the +\`--before\` filter, the most recent version less than or equal to that tag +will be used. For example, \`foo@latest\` might install \`foo@1.2\` even though +\`latest\` is \`2.0\`. + +#### \`bin-links\` + +* Default: true +* Type: Boolean + +Tells npm to create symlinks (or \`.cmd\` shims on Windows) for package +executables. + +Set to false to have it not do this. This can be used to work around the +fact that some file systems don't support symlinks, even on ostensibly Unix +systems. + +#### \`browser\` + +* Default: OS X: \`"open"\`, Windows: \`"start"\`, Others: \`"xdg-open"\` +* Type: null, Boolean, or String + +The browser that is called by npm commands to open websites. + +Set to \`false\` to suppress browser behavior and instead print urls to +terminal. + +Set to \`true\` to use default system URL opener. + +#### \`ca\` + +* Default: null +* Type: null or String (can be set multiple times) + +The Certificate Authority signing certificate that is trusted for SSL +connections to the registry. Values should be in PEM format (Windows calls +it "Base-64 encoded X.509 (.CER)") with newlines replaced by the string +"\\n". For example: + +\`\`\`ini +ca="-----BEGIN CERTIFICATE-----\\nXXXX\\nXXXX\\n-----END CERTIFICATE-----" +\`\`\` + +Set to \`null\` to only allow "known" registrars, or to a specific CA cert to +trust only that specific signing authority. + +Multiple CAs can be trusted by specifying an array of certificates: + +\`\`\`ini +ca[]="..." +ca[]="..." +\`\`\` + +See also the \`strict-ssl\` config. + +#### \`cache\` + +* Default: Windows: \`%LocalAppData%\\npm-cache\`, Posix: \`~/.npm\` +* Type: Path + +The location of npm's cache directory. + +#### \`cafile\` + +* Default: null +* Type: Path + +A path to a file containing one or multiple Certificate Authority signing +certificates. Similar to the \`ca\` setting, but allows for multiple CA's, as +well as for the CA information to be stored in a file on disk. + +#### \`call\` + +* Default: "" +* Type: String + +Optional companion option for \`npm exec\`, \`npx\` that allows for specifying a +custom command to be run along with the installed packages. + +\`\`\`bash +npm exec --package yo --package generator-node --call "yo node" +\`\`\` + + +#### \`ci-name\` + +* Default: The name of the current CI system, or \`null\` when not on a known CI + platform. +* Type: null or String + +The name of a continuous integration system. If not set explicitly, npm will +detect the current CI environment using the +[\`ci-info\`](http://npm.im/ci-info) module. + +#### \`cidr\` + +* Default: null +* Type: null or String (can be set multiple times) + +This is a list of CIDR address to be used when configuring limited access +tokens with the \`npm token create\` command. + +#### \`color\` + +* Default: true unless the NO_COLOR environ is set to something other than '0' +* Type: "always" or Boolean + +If false, never shows colors. If \`"always"\` then always shows colors. If +true, then only prints color codes for tty file descriptors. + +#### \`commit-hooks\` + +* Default: true +* Type: Boolean + +Run git commit hooks when using the \`npm version\` command. + +#### \`depth\` + +* Default: \`Infinity\` if \`--all\` is set, otherwise \`1\` +* Type: null or Number + +The depth to go when recursing packages for \`npm ls\`. + +If not set, \`npm ls\` will show only the immediate dependencies of the root +project. If \`--all\` is set, then npm will show all dependencies by default. + +#### \`description\` + +* Default: true +* Type: Boolean + +Show the description in \`npm search\` + +#### \`diff\` + +* Default: +* Type: String (can be set multiple times) + +Define arguments to compare in \`npm diff\`. + +#### \`diff-dst-prefix\` + +* Default: "b/" +* Type: String + +Destination prefix to be used in \`npm diff\` output. + +#### \`diff-ignore-all-space\` + +* Default: false +* Type: Boolean + +Ignore whitespace when comparing lines in \`npm diff\`. + +#### \`diff-name-only\` + +* Default: false +* Type: Boolean + +Prints only filenames when using \`npm diff\`. + +#### \`diff-no-prefix\` + +* Default: false +* Type: Boolean + +Do not show any source or destination prefix in \`npm diff\` output. + +Note: this causes \`npm diff\` to ignore the \`--diff-src-prefix\` and +\`--diff-dst-prefix\` configs. + +#### \`diff-src-prefix\` + +* Default: "a/" +* Type: String + +Source prefix to be used in \`npm diff\` output. + +#### \`diff-text\` + +* Default: false +* Type: Boolean + +Treat all files as text in \`npm diff\`. + +#### \`diff-unified\` + +* Default: 3 +* Type: Number + +The number of lines of context to print in \`npm diff\`. + +#### \`dry-run\` + +* Default: false +* Type: Boolean + +Indicates that you don't want npm to make any changes and that it should +only report what it would have done. This can be passed into any of the +commands that modify your local installation, eg, \`install\`, \`update\`, +\`dedupe\`, \`uninstall\`, as well as \`pack\` and \`publish\`. + +Note: This is NOT honored by other network related commands, eg \`dist-tags\`, +\`owner\`, etc. + +#### \`editor\` + +* Default: The EDITOR or VISUAL environment variables, or + '%SYSTEMROOT%\\notepad.exe' on Windows, or 'vi' on Unix systems +* Type: String + +The command to run for \`npm edit\` and \`npm config edit\`. + +#### \`engine-strict\` + +* Default: false +* Type: Boolean + +If set to true, then npm will stubbornly refuse to install (or even consider +installing) any package that claims to not be compatible with the current +Node.js version. + +This can be overridden by setting the \`--force\` flag. + +#### \`fetch-retries\` + +* Default: 2 +* Type: Number + +The "retries" config for the \`retry\` module to use when fetching packages +from the registry. + +npm will retry idempotent read requests to the registry in the case of +network failures or 5xx HTTP errors. + +#### \`fetch-retry-factor\` + +* Default: 10 +* Type: Number + +The "factor" config for the \`retry\` module to use when fetching packages. + +#### \`fetch-retry-maxtimeout\` + +* Default: 60000 (1 minute) +* Type: Number + +The "maxTimeout" config for the \`retry\` module to use when fetching +packages. + +#### \`fetch-retry-mintimeout\` + +* Default: 10000 (10 seconds) +* Type: Number + +The "minTimeout" config for the \`retry\` module to use when fetching +packages. + +#### \`fetch-timeout\` + +* Default: 300000 (5 minutes) +* Type: Number + +The maximum amount of time to wait for HTTP requests to complete. + +#### \`force\` + +* Default: false +* Type: Boolean + +Removes various protections against unfortunate side effects, common +mistakes, unnecessary performance degradation, and malicious input. + +* Allow clobbering non-npm files in global installs. +* Allow the \`npm version\` command to work on an unclean git repository. +* Allow deleting the cache folder with \`npm cache clean\`. +* Allow installing packages that have an \`engines\` declaration requiring a + different version of npm. +* Allow installing packages that have an \`engines\` declaration requiring a + different version of \`node\`, even if \`--engine-strict\` is enabled. +* Allow \`npm audit fix\` to install modules outside your stated dependency + range (including SemVer-major changes). +* Allow unpublishing all versions of a published package. +* Allow conflicting peerDependencies to be installed in the root project. +* Implicitly set \`--yes\` during \`npm init\`. +* Allow clobbering existing values in \`npm pkg\` +* Allow unpublishing of entire packages (not just a single version). + +If you don't have a clear idea of what you want to do, it is strongly +recommended that you do not use this option! + +#### \`foreground-scripts\` + +* Default: false +* Type: Boolean + +Run all build scripts (ie, \`preinstall\`, \`install\`, and \`postinstall\`) +scripts for installed packages in the foreground process, sharing standard +input, output, and error with the main npm process. + +Note that this will generally make installs run slower, and be much noisier, +but can be useful for debugging. + +#### \`format-package-lock\` + +* Default: true +* Type: Boolean + +Format \`package-lock.json\` or \`npm-shrinkwrap.json\` as a human readable +file. + +#### \`fund\` + +* Default: true +* Type: Boolean + +When "true" displays the message at the end of each \`npm install\` +acknowledging the number of dependencies looking for funding. See [\`npm +fund\`](/commands/npm-fund) for details. + +#### \`git\` + +* Default: "git" +* Type: String + +The command to use for git commands. If git is installed on the computer, +but is not in the \`PATH\`, then set this to the full path to the git binary. + +#### \`git-tag-version\` + +* Default: true +* Type: Boolean + +Tag the commit when using the \`npm version\` command. Setting this to false +results in no commit being made at all. + +#### \`global\` + +* Default: false +* Type: Boolean + +Operates in "global" mode, so that packages are installed into the \`prefix\` +folder instead of the current working directory. See +[folders](/configuring-npm/folders) for more on the differences in behavior. + +* packages are installed into the \`{prefix}/lib/node_modules\` folder, instead + of the current working directory. +* bin files are linked to \`{prefix}/bin\` +* man pages are linked to \`{prefix}/share/man\` + +#### \`globalconfig\` + +* Default: The global --prefix setting plus 'etc/npmrc'. For example, + '/usr/local/etc/npmrc' +* Type: Path + +The config file to read for global config options. + +#### \`heading\` + +* Default: "npm" +* Type: String + +The string that starts all the debugging log output. + +#### \`https-proxy\` + +* Default: null +* Type: null or URL + +A proxy to use for outgoing https requests. If the \`HTTPS_PROXY\` or +\`https_proxy\` or \`HTTP_PROXY\` or \`http_proxy\` environment variables are set, +proxy settings will be honored by the underlying \`make-fetch-happen\` +library. + +#### \`if-present\` + +* 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 +running scripts that may only apply for some builds in an otherwise generic +CI setup. + +This value is not exported to the environment for child processes. + +#### \`ignore-scripts\` + +* Default: false +* Type: Boolean + +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. + +#### \`include\` + +* Default: +* Type: "prod", "dev", "optional", or "peer" (can be set multiple times) + +Option that allows for defining which types of dependencies to install. + +This is the inverse of \`--omit=<type>\`. + +Dependency types specified in \`--include\` will not be omitted, regardless of +the order in which omit/include are specified on the command-line. + +#### \`include-staged\` + +* Default: false +* Type: Boolean + +Allow installing "staged" published packages, as defined by [npm RFC PR +#92](https://github.com/npm/rfcs/pull/92). + +This is experimental, and not implemented by the npm public registry. + +#### \`include-workspace-root\` + +* Default: false +* Type: Boolean + +Include the workspace root when workspaces are enabled for a command. + +When false, specifying individual workspaces via the \`workspace\` config, or +all workspaces via the \`workspaces\` flag, will cause npm to operate only on +the specified workspaces, and not on the root project. + +This value is not exported to the environment for child processes. + +#### \`init-author-email\` + +* Default: "" +* Type: String + +The value \`npm init\` should use by default for the package author's email. + +#### \`init-author-name\` + +* Default: "" +* Type: String + +The value \`npm init\` should use by default for the package author's name. + +#### \`init-author-url\` + +* Default: "" +* Type: "" or URL + +The value \`npm init\` should use by default for the package author's +homepage. + +#### \`init-license\` + +* Default: "ISC" +* Type: String + +The value \`npm init\` should use by default for the package license. + +#### \`init-module\` + +* Default: "~/.npm-init.js" +* Type: Path + +A module that will be loaded by the \`npm init\` command. See the +documentation for the +[init-package-json](https://github.com/npm/init-package-json) module for +more information, or [npm init](/commands/npm-init). + +#### \`init-version\` + +* Default: "1.0.0" +* Type: SemVer string + +The value that \`npm init\` should use by default for the package version +number, if not already set in package.json. + +#### \`install-links\` + +* Default: true +* Type: Boolean + +When set file: protocol dependencies will be packed and installed as regular +dependencies instead of creating a symlink. This option has no effect on +workspaces. + +#### \`install-strategy\` + +* Default: "hoisted" +* Type: "hoisted", "nested", or "shallow" + +Sets the strategy for installing packages in node_modules. hoisted +(default): Install non-duplicated in top-level, and duplicated as necessary +within directory structure. nested: (formerly --legacy-bundling) install in +place, no hoisting. shallow (formerly --global-style) only install direct +deps at top-level. linked: (coming soon) install in node_modules/.store, +link in place, unhoisted. + +#### \`json\` + +* Default: false +* Type: Boolean + +Whether or not to output JSON data, rather than the normal output. + +* In \`npm pkg set\` it enables parsing set values with JSON.parse() before + saving them to your \`package.json\`. + +Not supported by all npm commands. + +#### \`legacy-peer-deps\` + +* Default: false +* Type: Boolean + +Causes npm to completely ignore \`peerDependencies\` when building a package +tree, as in npm versions 3 through 6. + +If a package cannot be installed because of overly strict \`peerDependencies\` +that collide, it provides a way to move forward resolving the situation. + +This differs from \`--omit=peer\`, in that \`--omit=peer\` will avoid unpacking +\`peerDependencies\` on disk, but will still design a tree such that +\`peerDependencies\` _could_ be unpacked in a correct place. + +Use of \`legacy-peer-deps\` is not recommended, as it will not enforce the +\`peerDependencies\` contract that meta-dependencies may rely on. + +#### \`link\` + +* Default: false +* Type: Boolean + +Used with \`npm ls\`, limiting output to only those packages that are linked. + +#### \`local-address\` + +* Default: null +* Type: IP Address + +The IP address of the local interface to use when making connections to the +npm registry. Must be IPv4 in versions of Node prior to 0.12. + +#### \`location\` + +* Default: "user" unless \`--global\` is passed, which will also set this value + to "global" +* Type: "global", "user", or "project" + +When passed to \`npm config\` this refers to which config file to use. + +When set to "global" mode, packages are installed into the \`prefix\` folder +instead of the current working directory. See +[folders](/configuring-npm/folders) for more on the differences in behavior. + +* packages are installed into the \`{prefix}/lib/node_modules\` folder, instead + of the current working directory. +* bin files are linked to \`{prefix}/bin\` +* man pages are linked to \`{prefix}/share/man\` + +#### \`lockfile-version\` + +* Default: Version 3 if no lockfile, auto-converting v1 lockfiles to v3, + otherwise maintain current lockfile version. +* Type: null, 1, 2, 3, "1", "2", or "3" + +Set the lockfile format version to be used in package-lock.json and +npm-shrinkwrap-json files. Possible options are: + +1: The lockfile version used by npm versions 5 and 6. Lacks some data that +is used during the install, resulting in slower and possibly less +deterministic installs. Prevents lockfile churn when interoperating with +older npm versions. + +2: The default lockfile version used by npm version 7 and 8. Includes both +the version 1 lockfile data and version 3 lockfile data, for maximum +determinism and interoperability, at the expense of more bytes on disk. + +3: Only the new lockfile information introduced in npm version 7. Smaller on +disk than lockfile version 2, but not interoperable with older npm versions. +Ideal if all users are on npm version 7 and higher. + +#### \`loglevel\` + +* Default: "notice" +* Type: "silent", "error", "warn", "notice", "http", "info", "verbose", or + "silly" + +What level of logs to report. All logs are written to a debug log, with the +path to that file printed if the execution of a command fails. + +Any logs of a higher level than the setting are shown. The default is +"notice". + +See also the \`foreground-scripts\` config. + +#### \`logs-dir\` + +* Default: A directory named \`_logs\` inside the cache +* Type: null or Path + +The location of npm's log directory. See [\`npm logging\`](/using-npm/logging) +for more information. + +#### \`logs-max\` + +* Default: 10 +* Type: Number + +The maximum number of log files to store. + +If set to 0, no log files will be written for the current run. + +#### \`long\` + +* Default: false +* Type: Boolean + +Show extended information in \`ls\`, \`search\`, and \`help-search\`. + +#### \`maxsockets\` + +* Default: 15 +* Type: Number + +The maximum number of connections to use per origin (protocol/host/port +combination). + +#### \`message\` + +* Default: "%s" +* Type: String + +Commit message which is used by \`npm version\` when creating version commit. + +Any "%s" in the message will be replaced with the version number. + +#### \`node-options\` + +* Default: null +* Type: null or String + +Options to pass through to Node.js via the \`NODE_OPTIONS\` environment +variable. This does not impact how npm itself is executed but it does impact +how lifecycle scripts are called. + +#### \`noproxy\` + +* Default: The value of the NO_PROXY environment variable +* Type: String (can be set multiple times) + +Domain extensions that should bypass any proxies. + +Also accepts a comma-delimited string. + +#### \`offline\` + +* Default: false +* Type: Boolean + +Force offline mode: no network requests will be done during install. To +allow the CLI to fill in missing cache data, see \`--prefer-offline\`. + +#### \`omit\` + +* Default: 'dev' if the \`NODE_ENV\` environment variable is set to + 'production', otherwise empty. +* Type: "dev", "optional", or "peer" (can be set multiple times) + +Dependency types to omit from the installation tree on disk. + +Note that these dependencies _are_ still resolved and added to the +\`package-lock.json\` or \`npm-shrinkwrap.json\` file. They are just not +physically installed on disk. + +If a package type appears in both the \`--include\` and \`--omit\` lists, then +it will be included. + +If the resulting omit list includes \`'dev'\`, then the \`NODE_ENV\` environment +variable will be set to \`'production'\` for all lifecycle scripts. + +#### \`omit-lockfile-registry-resolved\` + +* Default: false +* Type: Boolean + +This option causes npm to create lock files without a \`resolved\` key for +registry dependencies. Subsequent installs will need to resolve tarball +endpoints with the configured registry, likely resulting in a longer install +time. + +#### \`otp\` + +* Default: null +* Type: null or String + +This is a one-time password from a two-factor authenticator. It's needed +when publishing or changing package permissions with \`npm access\`. + +If not set, and a registry response fails with a challenge for a one-time +password, npm will prompt on the command line for one. + +#### \`pack-destination\` + +* Default: "." +* Type: String + +Directory in which \`npm pack\` will save tarballs. + +#### \`package\` + +* Default: +* Type: String (can be set multiple times) + +The package or packages to install for [\`npm exec\`](/commands/npm-exec) + +#### \`package-lock\` + +* Default: true +* Type: Boolean + +If set to false, then ignore \`package-lock.json\` files when installing. This +will also prevent _writing_ \`package-lock.json\` if \`save\` is true. + +This configuration does not affect \`npm ci\`. + +#### \`package-lock-only\` + +* Default: false +* Type: Boolean + +If set to true, the current operation will only use the \`package-lock.json\`, +ignoring \`node_modules\`. + +For \`update\` this means only the \`package-lock.json\` will be updated, +instead of checking \`node_modules\` and downloading dependencies. + +For \`list\` this means the output will be based on the tree described by the +\`package-lock.json\`, rather than the contents of \`node_modules\`. + +#### \`parseable\` + +* Default: false +* Type: Boolean + +Output parseable results from commands that write to standard output. For +\`npm search\`, this will be tab-separated table format. + +#### \`prefer-offline\` + +* Default: false +* Type: Boolean + +If true, staleness checks for cached data will be bypassed, but missing data +will be requested from the server. To force full offline mode, use +\`--offline\`. + +#### \`prefer-online\` + +* Default: false +* Type: Boolean + +If true, staleness checks for cached data will be forced, making the CLI +look for updates immediately even for fresh package data. + +#### \`prefix\` + +* Default: In global mode, the folder where the node executable is installed. + Otherwise, the nearest parent folder containing either a package.json file + or a node_modules folder. +* Type: Path + +The location to install global items. If set on the command line, then it +forces non-global commands to run in the specified folder. + +#### \`preid\` + +* Default: "" +* Type: String + +The "prerelease identifier" to use as a prefix for the "prerelease" part of +a semver. Like the \`rc\` in \`1.2.0-rc.8\`. + +#### \`progress\` + +* Default: \`true\` unless running in a known CI system +* Type: Boolean + +When set to \`true\`, npm will display a progress bar during time intensive +operations, if \`process.stderr\` is a TTY. + +Set to \`false\` to suppress the progress bar. + +#### \`proxy\` + +* Default: null +* Type: null, false, or URL + +A proxy to use for outgoing http requests. If the \`HTTP_PROXY\` or +\`http_proxy\` environment variables are set, proxy settings will be honored +by the underlying \`request\` library. + +#### \`read-only\` + +* Default: false +* Type: Boolean + +This is used to mark a token as unable to publish when configuring limited +access tokens with the \`npm token create\` command. + +#### \`rebuild-bundle\` + +* Default: true +* Type: Boolean + +Rebuild bundled dependencies after installation. + +#### \`registry\` + +* Default: "https://registry.npmjs.org/" +* Type: URL + +The base URL of the npm registry. + +#### \`replace-registry-host\` + +* Default: "npmjs" +* Type: "npmjs", "never", "always", or String + +Defines behavior for replacing the registry host in a lockfile with the +configured registry. + +The default behavior is to replace package dist URLs from the default +registry (https://registry.npmjs.org) to the configured registry. If set to +"never", then use the registry value. If set to "always", then replace the +registry host with the configured host every time. + +You may also specify a bare hostname (e.g., "registry.npmjs.org"). + +#### \`save\` + +* Default: \`true\` unless when using \`npm update\` where it defaults to \`false\` +* Type: Boolean + +Save installed packages to a \`package.json\` file as dependencies. + +When used with the \`npm rm\` command, removes the dependency from +\`package.json\`. + +Will also prevent writing to \`package-lock.json\` if set to \`false\`. + +#### \`save-bundle\` + +* Default: false +* Type: Boolean + +If a package would be saved at install time by the use of \`--save\`, +\`--save-dev\`, or \`--save-optional\`, then also put it in the +\`bundleDependencies\` list. + +Ignored if \`--save-peer\` is set, since peerDependencies cannot be bundled. + +#### \`save-dev\` + +* Default: false +* Type: Boolean + +Save installed packages to a package.json file as \`devDependencies\`. + +#### \`save-exact\` + +* Default: false +* Type: Boolean + +Dependencies saved to package.json will be configured with an exact version +rather than using npm's default semver range operator. + +#### \`save-optional\` + +* Default: false +* Type: Boolean + +Save installed packages to a package.json file as \`optionalDependencies\`. + +#### \`save-peer\` + +* Default: false +* Type: Boolean + +Save installed packages to a package.json file as \`peerDependencies\` + +#### \`save-prefix\` + +* Default: "^" +* Type: String + +Configure how versions of packages installed to a package.json file via +\`--save\` or \`--save-dev\` get prefixed. + +For example if a package has version \`1.2.3\`, by default its version is set +to \`^1.2.3\` which allows minor upgrades for that package, but after \`npm +config set save-prefix='~'\` it would be set to \`~1.2.3\` which only allows +patch upgrades. + +#### \`save-prod\` + +* Default: false +* Type: Boolean + +Save installed packages into \`dependencies\` specifically. This is useful if +a package already exists in \`devDependencies\` or \`optionalDependencies\`, but +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. + +#### \`scope\` + +* Default: the scope of the current project, if any, or "" +* Type: String + +Associate an operation with a scope for a scoped registry. + +Useful when logging in to or out of a private registry: + +\`\`\` +# log in, linking the scope to the custom registry +npm login --scope=@mycorp --registry=https://registry.mycorp.com + +# log out, removing the link and the auth token +npm logout --scope=@mycorp +\`\`\` + +This will cause \`@mycorp\` to be mapped to the registry for future +installation of packages specified according to the pattern +\`@mycorp/package\`. + +This will also cause \`npm init\` to create a scoped package. + +\`\`\` +# accept all defaults, and create a package named "@foo/whatever", +# instead of just named "whatever" +npm init --scope=@foo --yes +\`\`\` + + +#### \`script-shell\` + +* Default: '/bin/sh' on POSIX systems, 'cmd.exe' on Windows +* Type: null or String + +The shell to use for scripts run with the \`npm exec\`, \`npm run\` and \`npm +init <package-spec>\` commands. + +#### \`searchexclude\` + +* Default: "" +* Type: String + +Space-separated options that limit the results from search. + +#### \`searchlimit\` + +* Default: 20 +* Type: Number + +Number of items to limit search results to. Will not apply at all to legacy +searches. + +#### \`searchopts\` + +* Default: "" +* Type: String + +Space-separated options that are always passed to search. + +#### \`searchstaleness\` + +* Default: 900 +* Type: Number + +The age of the cache, in seconds, before another registry request is made if +using legacy search endpoint. + +#### \`shell\` + +* Default: SHELL environment variable, or "bash" on Posix, or "cmd.exe" on + Windows +* Type: String + +The shell to run for the \`npm explore\` command. + +#### \`sign-git-commit\` + +* Default: false +* Type: Boolean + +If set to true, then the \`npm version\` command will commit the new package +version using \`-S\` to add a signature. + +Note that git requires you to have set up GPG keys in your git configs for +this to work properly. + +#### \`sign-git-tag\` + +* Default: false +* Type: Boolean + +If set to true, then the \`npm version\` command will tag the version using +\`-s\` to add a signature. + +Note that git requires you to have set up GPG keys in your git configs for +this to work properly. + +#### \`strict-peer-deps\` + +* Default: false +* Type: Boolean + +If set to \`true\`, and \`--legacy-peer-deps\` is not set, then _any_ +conflicting \`peerDependencies\` will be treated as an install failure, even +if npm could reasonably guess the appropriate resolution based on non-peer +dependency relationships. + +By default, conflicting \`peerDependencies\` deep in the dependency graph will +be resolved using the nearest non-peer dependency specification, even if +doing so will result in some packages receiving a peer dependency outside +the range set in their package's \`peerDependencies\` object. + +When such and override is performed, a warning is printed, explaining the +conflict and the packages involved. If \`--strict-peer-deps\` is set, then +this warning is treated as a failure. + +#### \`strict-ssl\` + +* Default: true +* Type: Boolean + +Whether or not to do SSL key validation when making requests to the registry +via https. + +See also the \`ca\` config. + +#### \`tag\` + +* Default: "latest" +* Type: String + +If you ask npm to install a package and don't tell it a specific version, +then it will install the specified tag. + +Also the tag that is added to the package@version specified by the \`npm tag\` +command, if no explicit tag is given. + +When used by the \`npm diff\` command, this is the tag used to fetch the +tarball that will be compared with the local files by default. + +#### \`tag-version-prefix\` + +* Default: "v" +* Type: String + +If set, alters the prefix used when tagging a new version when performing a +version increment using \`npm version\`. To remove the prefix altogether, set +it to the empty string: \`""\`. + +Because other tools may rely on the convention that npm version tags look +like \`v1.0.0\`, _only use this property if it is absolutely necessary_. In +particular, use care when overriding this setting for public packages. + +#### \`timing\` + +* Default: false +* Type: Boolean + +If true, writes timing information to a process specific json file in the +cache or \`logs-dir\`. The file name ends with \`-timing.json\`. + +You can quickly view it with this [json](https://npm.im/json) command line: +\`cat ~/.npm/_logs/*-timing.json | npm exec -- json -g\`. + +Timing information will also be reported in the terminal. To suppress this +while still writing the timing file, use \`--silent\`. + +#### \`umask\` + +* Default: 0 +* Type: Octal numeric string in range 0000..0777 (0..511) + +The "umask" value to use when setting the file creation mode on files and +folders. + +Folders and executables are given a mode which is \`0o777\` masked against +this value. Other files are given a mode which is \`0o666\` masked against +this value. + +Note that the underlying system will _also_ apply its own umask value to +files and folders that are created, and npm does not circumvent this, but +rather adds the \`--umask\` config to it. + +Thus, the effective default umask value on most POSIX systems is 0o22, +meaning that folders and executables are created with a mode of 0o755 and +other files are created with a mode of 0o644. + +#### \`unicode\` + +* Default: false on windows, true on mac/unix systems with a unicode locale, + as defined by the \`LC_ALL\`, \`LC_CTYPE\`, or \`LANG\` environment variables. +* Type: Boolean + +When set to true, npm uses unicode characters in the tree output. When +false, it uses ascii characters instead of unicode glyphs. + +#### \`update-notifier\` + +* Default: true +* Type: Boolean + +Set to false to suppress the update notification when using an older version +of npm than the latest. + +#### \`usage\` + +* Default: false +* Type: Boolean + +Show short usage output about the command specified. + +#### \`user-agent\` + +* Default: "npm/{npm-version} node/{node-version} {platform} {arch} + workspaces/{workspaces} {ci}" +* Type: String + +Sets the User-Agent request header. The following fields are replaced with +their actual counterparts: + +* \`{npm-version}\` - The npm version in use +* \`{node-version}\` - The Node.js version in use +* \`{platform}\` - The value of \`process.platform\` +* \`{arch}\` - The value of \`process.arch\` +* \`{workspaces}\` - Set to \`true\` if the \`workspaces\` or \`workspace\` options + are set. +* \`{ci}\` - The value of the \`ci-name\` config, if set, prefixed with \`ci/\`, or + an empty string if \`ci-name\` is empty. + +#### \`userconfig\` + +* Default: "~/.npmrc" +* Type: Path + +The location of user-level configuration settings. + +This may be overridden by the \`npm_config_userconfig\` environment variable +or the \`--userconfig\` command line option, but may _not_ be overridden by +settings in the \`globalconfig\` file. + +#### \`version\` + +* Default: false +* Type: Boolean + +If true, output the npm version and exit successfully. + +Only relevant when specified explicitly on the command line. + +#### \`versions\` + +* Default: false +* Type: Boolean + +If true, output the npm version as well as node's \`process.versions\` map and +the version in the current working directory's \`package.json\` file if one +exists, and exit successfully. + +Only relevant when specified explicitly on the command line. + +#### \`viewer\` + +* Default: "man" on Posix, "browser" on Windows +* Type: String + +The program to use to view help content. + +Set to \`"browser"\` to view html help content in the default web browser. + +#### \`which\` + +* Default: null +* Type: null or Number + +If there are multiple funding sources, which 1-indexed source URL to open. + +#### \`workspace\` + +* Default: +* Type: String (can be set multiple times) + +Enable running a command in the context of the configured workspaces of the +current project while filtering by running only the workspaces defined by +this configuration option. + +Valid values for the \`workspace\` config are either: + +* Workspace names +* Path to a workspace directory +* Path to a parent workspace directory (will result in selecting all + workspaces within that folder) + +When set for the \`npm init\` command, this may be set to the folder of a +workspace which does not yet exist, to create the folder and set it up as a +brand new workspace within the project. + +This value is not exported to the environment for child processes. + +#### \`workspaces\` + +* Default: null +* Type: null or Boolean + +Set to true to run the command in the context of **all** configured +workspaces. + +Explicitly setting this to false will cause commands like \`install\` to +ignore workspaces altogether. When not set explicitly: + +- Commands that operate on the \`node_modules\` tree (install, update, etc.) +will link workspaces into the \`node_modules\` folder. - Commands that do +other things (test, exec, publish, etc.) will operate on the root project, +_unless_ one or more workspaces are specified in the \`workspace\` config. + +This value is not exported to the environment for child processes. + +#### \`workspaces-update\` + +* Default: true +* Type: Boolean + +If set to true, the npm cli will run an update after operations that may +possibly change the workspaces installed to the \`node_modules\` folder. + +#### \`yes\` + +* Default: null +* Type: null or Boolean + +Automatically answer "yes" to any prompts that npm might print on the +command line. + +#### \`also\` + +* Default: null +* Type: null, "dev", or "development" +* DEPRECATED: Please use --include=dev instead. + +When set to \`dev\` or \`development\`, this is an alias for \`--include=dev\`. + +#### \`cache-max\` + +* Default: Infinity +* Type: Number +* DEPRECATED: This option has been deprecated in favor of \`--prefer-online\` + +\`--cache-max=0\` is an alias for \`--prefer-online\` + +#### \`cache-min\` + +* Default: 0 +* Type: Number +* DEPRECATED: This option has been deprecated in favor of \`--prefer-offline\`. + +\`--cache-min=9999 (or bigger)\` is an alias for \`--prefer-offline\`. + +#### \`cert\` + +* Default: null +* Type: null or String +* DEPRECATED: \`key\` and \`cert\` are no longer used for most registry + operations. Use registry scoped \`keyfile\` and \`certfile\` instead. Example: + //other-registry.tld/:keyfile=/path/to/key.pem + //other-registry.tld/:certfile=/path/to/cert.crt + +A client certificate to pass when accessing the registry. Values should be +in PEM format (Windows calls it "Base-64 encoded X.509 (.CER)") with +newlines replaced by the string "\\n". For example: + +\`\`\`ini +cert="-----BEGIN CERTIFICATE-----\\nXXXX\\nXXXX\\n-----END CERTIFICATE-----" +\`\`\` + +It is _not_ the path to a certificate file, though you can set a +registry-scoped "certfile" path like +"//other-registry.tld/:certfile=/path/to/cert.pem". + +#### \`dev\` + +* Default: false +* Type: Boolean +* DEPRECATED: Please use --include=dev instead. + +Alias for \`--include=dev\`. + +#### \`global-style\` + +* Default: false +* Type: Boolean +* DEPRECATED: This option has been deprecated in favor of + \`--install-strategy=shallow\` + +Only install direct dependencies in the top level \`node_modules\`, but hoist +on deeper dependendencies. Sets \`--install-strategy=shallow\`. + +#### \`init.author.email\` + +* Default: "" +* Type: String +* DEPRECATED: Use \`--init-author-email\` instead. + +Alias for \`--init-author-email\` + +#### \`init.author.name\` + +* Default: "" +* Type: String +* DEPRECATED: Use \`--init-author-name\` instead. + +Alias for \`--init-author-name\` + +#### \`init.author.url\` + +* Default: "" +* Type: "" or URL +* DEPRECATED: Use \`--init-author-url\` instead. + +Alias for \`--init-author-url\` + +#### \`init.license\` + +* Default: "ISC" +* Type: String +* DEPRECATED: Use \`--init-license\` instead. + +Alias for \`--init-license\` + +#### \`init.module\` + +* Default: "~/.npm-init.js" +* Type: Path +* DEPRECATED: Use \`--init-module\` instead. + +Alias for \`--init-module\` + +#### \`init.version\` + +* Default: "1.0.0" +* Type: SemVer string +* DEPRECATED: Use \`--init-version\` instead. + +Alias for \`--init-version\` + +#### \`key\` + +* Default: null +* Type: null or String +* DEPRECATED: \`key\` and \`cert\` are no longer used for most registry + operations. Use registry scoped \`keyfile\` and \`certfile\` instead. Example: + //other-registry.tld/:keyfile=/path/to/key.pem + //other-registry.tld/:certfile=/path/to/cert.crt + +A client key to pass when accessing the registry. Values should be in PEM +format with newlines replaced by the string "\\n". For example: + +\`\`\`ini +key="-----BEGIN PRIVATE KEY-----\\nXXXX\\nXXXX\\n-----END PRIVATE KEY-----" +\`\`\` + +It is _not_ the path to a key file, though you can set a registry-scoped +"keyfile" path like "//other-registry.tld/:keyfile=/path/to/key.pem". + +#### \`legacy-bundling\` + +* Default: false +* Type: Boolean +* DEPRECATED: This option has been deprecated in favor of + \`--install-strategy=nested\` + +Instead of hoisting package installs in \`node_modules\`, install packages in +the same manner that they are depended on. This may cause very deep +directory structures and duplicate package installs as there is no +de-duplicating. Sets \`--install-strategy=nested\`. + +#### \`only\` + +* Default: null +* Type: null, "prod", or "production" +* DEPRECATED: Use \`--omit=dev\` to omit dev dependencies from the install. + +When set to \`prod\` or \`production\`, this is an alias for \`--omit=dev\`. + +#### \`optional\` + +* Default: null +* Type: null or Boolean +* DEPRECATED: Use \`--omit=optional\` to exclude optional dependencies, or + \`--include=optional\` to include them. + +Default value does install optional deps unless otherwise omitted. + +Alias for --include=optional or --omit=optional + +#### \`production\` + +* Default: null +* Type: null or Boolean +* DEPRECATED: Use \`--omit=dev\` instead. + +Alias for \`--omit=dev\` + +#### \`shrinkwrap\` + +* Default: true +* Type: Boolean +* DEPRECATED: Use the --package-lock setting instead. + +Alias for --package-lock + +#### \`tmp\` + +* Default: The value returned by the Node.js \`os.tmpdir()\` method + <https://nodejs.org/api/os.html#os_os_tmpdir> +* Type: Path +* DEPRECATED: This setting is no longer used. npm stores temporary files in a + special location in the cache, and they are managed by + [\`cacache\`](http://npm.im/cacache). + +Historically, the location where temporary files were stored. No longer +relevant. +` + +exports[`test/lib/docs.js TAP config > all keys 1`] = ` +Array [ + "_auth", + "access", + "all", + "allow-same-version", + "also", + "audit", + "audit-level", + "auth-type", + "before", + "bin-links", + "browser", + "ca", + "cache", + "cache-max", + "cache-min", + "cafile", + "call", + "cert", + "ci-name", + "cidr", + "color", + "commit-hooks", + "depth", + "description", + "dev", + "diff", + "diff-ignore-all-space", + "diff-name-only", + "diff-no-prefix", + "diff-dst-prefix", + "diff-src-prefix", + "diff-text", + "diff-unified", + "dry-run", + "editor", + "engine-strict", + "fetch-retries", + "fetch-retry-factor", + "fetch-retry-maxtimeout", + "fetch-retry-mintimeout", + "fetch-timeout", + "force", + "foreground-scripts", + "format-package-lock", + "fund", + "git", + "git-tag-version", + "global", + "globalconfig", + "global-style", + "heading", + "https-proxy", + "if-present", + "ignore-scripts", + "include", + "include-staged", + "include-workspace-root", + "init-author-email", + "init-author-name", + "init-author-url", + "init-license", + "init-module", + "init-version", + "init.author.email", + "init.author.name", + "init.author.url", + "init.license", + "init.module", + "init.version", + "install-links", + "install-strategy", + "json", + "key", + "legacy-bundling", + "legacy-peer-deps", + "link", + "local-address", + "location", + "lockfile-version", + "loglevel", + "logs-dir", + "logs-max", + "long", + "maxsockets", + "message", + "node-options", + "noproxy", + "offline", + "omit", + "omit-lockfile-registry-resolved", + "only", + "optional", + "otp", + "package", + "package-lock", + "package-lock-only", + "pack-destination", + "parseable", + "prefer-offline", + "prefer-online", + "prefix", + "preid", + "production", + "progress", + "proxy", + "read-only", + "rebuild-bundle", + "registry", + "replace-registry-host", + "save", + "save-bundle", + "save-dev", + "save-exact", + "save-optional", + "save-peer", + "save-prefix", + "save-prod", + "scope", + "script-shell", + "searchexclude", + "searchlimit", + "searchopts", + "searchstaleness", + "shell", + "shrinkwrap", + "sign-git-commit", + "sign-git-tag", + "strict-peer-deps", + "strict-ssl", + "tag", + "tag-version-prefix", + "timing", + "tmp", + "umask", + "unicode", + "update-notifier", + "usage", + "user-agent", + "userconfig", + "version", + "versions", + "viewer", + "which", + "workspace", + "workspaces", + "workspaces-update", + "yes", +] +` + +exports[`test/lib/docs.js TAP config > keys that are flattened 1`] = ` +Array [ + "_auth", + "access", + "all", + "allow-same-version", + "also", + "audit", + "audit-level", + "auth-type", + "before", + "bin-links", + "browser", + "ca", + "cache", + "cache-max", + "cache-min", + "cafile", + "call", + "cert", + "ci-name", + "cidr", + "color", + "commit-hooks", + "depth", + "description", + "dev", + "diff", + "diff-ignore-all-space", + "diff-name-only", + "diff-no-prefix", + "diff-dst-prefix", + "diff-src-prefix", + "diff-text", + "diff-unified", + "dry-run", + "editor", + "engine-strict", + "fetch-retries", + "fetch-retry-factor", + "fetch-retry-maxtimeout", + "fetch-retry-mintimeout", + "fetch-timeout", + "force", + "foreground-scripts", + "format-package-lock", + "fund", + "git", + "git-tag-version", + "global", + "globalconfig", + "global-style", + "heading", + "https-proxy", + "if-present", + "ignore-scripts", + "include", + "include-staged", + "include-workspace-root", + "install-links", + "install-strategy", + "json", + "key", + "legacy-bundling", + "legacy-peer-deps", + "local-address", + "location", + "lockfile-version", + "loglevel", + "maxsockets", + "message", + "noproxy", + "offline", + "omit", + "omit-lockfile-registry-resolved", + "only", + "optional", + "otp", + "package", + "package-lock", + "package-lock-only", + "pack-destination", + "parseable", + "prefer-offline", + "prefer-online", + "preid", + "production", + "progress", + "proxy", + "read-only", + "rebuild-bundle", + "registry", + "replace-registry-host", + "save", + "save-bundle", + "save-dev", + "save-exact", + "save-optional", + "save-peer", + "save-prefix", + "save-prod", + "scope", + "script-shell", + "searchexclude", + "searchlimit", + "searchopts", + "searchstaleness", + "shell", + "shrinkwrap", + "sign-git-commit", + "sign-git-tag", + "strict-peer-deps", + "strict-ssl", + "tag", + "tag-version-prefix", + "umask", + "user-agent", + "workspace", + "workspaces", + "workspaces-update", +] +` + +exports[`test/lib/docs.js TAP config > keys that are not flattened 1`] = ` +Array [ + "init-author-email", + "init-author-name", + "init-author-url", + "init-license", + "init-module", + "init-version", + "init.author.email", + "init.author.name", + "init.author.url", + "init.license", + "init.module", + "init.version", + "link", + "logs-dir", + "logs-max", + "long", + "node-options", + "prefix", + "timing", + "tmp", + "unicode", + "update-notifier", + "usage", + "userconfig", + "version", + "versions", + "viewer", + "which", + "yes", +] +` + +exports[`test/lib/docs.js TAP shorthands > docs 1`] = ` +* \`-a\`: \`--all\` +* \`--enjoy-by\`: \`--before\` +* \`-c\`: \`--call\` +* \`--desc\`: \`--description\` +* \`-f\`: \`--force\` +* \`-g\`: \`--global\` +* \`--iwr\`: \`--include-workspace-root\` +* \`-L\`: \`--location\` +* \`-d\`: \`--loglevel info\` +* \`-s\`: \`--loglevel silent\` +* \`--silent\`: \`--loglevel silent\` +* \`--ddd\`: \`--loglevel silly\` +* \`--dd\`: \`--loglevel verbose\` +* \`--verbose\`: \`--loglevel verbose\` +* \`-q\`: \`--loglevel warn\` +* \`--quiet\`: \`--loglevel warn\` +* \`-l\`: \`--long\` +* \`-m\`: \`--message\` +* \`--local\`: \`--no-global\` +* \`-n\`: \`--no-yes\` +* \`--no\`: \`--no-yes\` +* \`-p\`: \`--parseable\` +* \`--porcelain\`: \`--parseable\` +* \`-C\`: \`--prefix\` +* \`--readonly\`: \`--read-only\` +* \`--reg\`: \`--registry\` +* \`-S\`: \`--save\` +* \`-B\`: \`--save-bundle\` +* \`-D\`: \`--save-dev\` +* \`-E\`: \`--save-exact\` +* \`-O\`: \`--save-optional\` +* \`-P\`: \`--save-prod\` +* \`-?\`: \`--usage\` +* \`-h\`: \`--usage\` +* \`-H\`: \`--usage\` +* \`--help\`: \`--usage\` +* \`-v\`: \`--version\` +* \`-w\`: \`--workspace\` +* \`--ws\`: \`--workspaces\` +* \`-y\`: \`--yes\` +` + +exports[`test/lib/docs.js TAP usage access > must match snapshot 1`] = ` +Set access level on published packages + +Usage: +npm access list packages [<user>|<scope>|<scope:team> [<package>] +npm access list collaborators [<package> [<user>]] +npm access get status [<package>] +npm access set status=public|private [<package>] +npm access set mfa=none|publish|automation [<package>] +npm access grant <read-only|read-write> <scope:team> [<package>] +npm access revoke <scope:team> [<package>] + +Options: +[--json] [--otp <otp>] [--registry <registry>] + +Run "npm help access" for more info + +\`\`\`bash +npm access list packages [<user>|<scope>|<scope:team> [<package>] +npm access list collaborators [<package> [<user>]] +npm access get status [<package>] +npm access set status=public|private [<package>] +npm access set mfa=none|publish|automation [<package>] +npm access grant <read-only|read-write> <scope:team> [<package>] +npm access revoke <scope:team> [<package>] +\`\`\` + +#### \`json\` +#### \`otp\` +#### \`registry\` +` + +exports[`test/lib/docs.js TAP usage adduser > must match snapshot 1`] = ` +Add a registry user account + +Usage: +npm adduser + +Options: +[--registry <registry>] [--scope <@scope>] [--auth-type <legacy|web>] + +alias: add-user + +Run "npm help adduser" for more info + +\`\`\`bash +npm adduser + +alias: add-user +\`\`\` + +#### \`registry\` +#### \`scope\` +#### \`auth-type\` +` + +exports[`test/lib/docs.js TAP usage audit > must match snapshot 1`] = ` +Run a security audit + +Usage: +npm audit [fix|signatures] + +Options: +[--audit-level <info|low|moderate|high|critical|none>] [--dry-run] [-f|--force] +[--json] [--package-lock-only] +[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] +[--foreground-scripts] [--ignore-scripts] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +Run "npm help audit" for more info + +\`\`\`bash +npm audit [fix|signatures] +\`\`\` + +#### \`audit-level\` +#### \`dry-run\` +#### \`force\` +#### \`json\` +#### \`package-lock-only\` +#### \`omit\` +#### \`foreground-scripts\` +#### \`ignore-scripts\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage bugs > must match snapshot 1`] = ` +Report bugs for a package in a web browser + +Usage: +npm bugs [<pkgname> [<pkgname> ...]] + +Options: +[--no-browser|--browser <browser>] [--registry <registry>] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] + +alias: issues + +Run "npm help bugs" for more info + +\`\`\`bash +npm bugs [<pkgname> [<pkgname> ...]] + +alias: issues +\`\`\` + +#### \`browser\` +#### \`registry\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage cache > must match snapshot 1`] = ` +Manipulates packages cache + +Usage: +npm cache add <package-spec> +npm cache clean [<key>] +npm cache ls [<name>@<version>] +npm cache verify + +Options: +[--cache <cache>] + +Run "npm help cache" for more info + +\`\`\`bash +npm cache add <package-spec> +npm cache clean [<key>] +npm cache ls [<name>@<version>] +npm cache verify +\`\`\` + +#### \`cache\` +` + +exports[`test/lib/docs.js TAP usage ci > must match snapshot 1`] = ` +Clean install a project + +Usage: +npm ci + +Options: +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] +[-E|--save-exact] [-g|--global] [--install-strategy <hoisted|nested|shallow>] +[--legacy-bundling] [--global-style] +[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] +[--strict-peer-deps] [--no-package-lock] [--foreground-scripts] +[--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +aliases: clean-install, ic, install-clean, isntall-clean + +Run "npm help ci" for more info + +\`\`\`bash +npm ci + +aliases: clean-install, ic, install-clean, isntall-clean +\`\`\` + +#### \`save\` +#### \`save-exact\` +#### \`global\` +#### \`install-strategy\` +#### \`legacy-bundling\` +#### \`global-style\` +#### \`omit\` +#### \`strict-peer-deps\` +#### \`package-lock\` +#### \`foreground-scripts\` +#### \`ignore-scripts\` +#### \`audit\` +#### \`bin-links\` +#### \`fund\` +#### \`dry-run\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage completion > must match snapshot 1`] = ` +Tab Completion for npm + +Usage: +npm completion + +Run "npm help completion" for more info + +\`\`\`bash +npm completion +\`\`\` + +NO PARAMS +` + +exports[`test/lib/docs.js TAP usage config > must match snapshot 1`] = ` +Manage the npm configuration files + +Usage: +npm config set <key>=<value> [<key>=<value> ...] +npm config get [<key> [<key> ...]] +npm config delete <key> [<key> ...] +npm config list [--json] +npm config edit +npm config fix + +Options: +[--json] [-g|--global] [--editor <editor>] [-L|--location <global|user|project>] +[-l|--long] + +alias: c + +Run "npm help config" for more info + +\`\`\`bash +npm config set <key>=<value> [<key>=<value> ...] +npm config get [<key> [<key> ...]] +npm config delete <key> [<key> ...] +npm config list [--json] +npm config edit +npm config fix + +alias: c +\`\`\` + +#### \`json\` +#### \`global\` +#### \`editor\` +#### \`location\` +#### \`long\` +` + +exports[`test/lib/docs.js TAP usage dedupe > must match snapshot 1`] = ` +Reduce duplication in the package tree + +Usage: +npm dedupe + +Options: +[--install-strategy <hoisted|nested|shallow>] [--legacy-bundling] +[--global-style] [--strict-peer-deps] [--no-package-lock] +[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] +[--no-audit] [--no-bin-links] [--no-fund] [--dry-run] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +alias: ddp + +Run "npm help dedupe" for more info + +\`\`\`bash +npm dedupe + +alias: ddp +\`\`\` + +#### \`install-strategy\` +#### \`legacy-bundling\` +#### \`global-style\` +#### \`strict-peer-deps\` +#### \`package-lock\` +#### \`omit\` +#### \`ignore-scripts\` +#### \`audit\` +#### \`bin-links\` +#### \`fund\` +#### \`dry-run\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage deprecate > must match snapshot 1`] = ` +Deprecate a version of a package + +Usage: +npm deprecate <package-spec> <message> + +Options: +[--registry <registry>] [--otp <otp>] + +Run "npm help deprecate" for more info + +\`\`\`bash +npm deprecate <package-spec> <message> +\`\`\` + +#### \`registry\` +#### \`otp\` +` + +exports[`test/lib/docs.js TAP usage diff > must match snapshot 1`] = ` +The registry diff command + +Usage: +npm diff [...<paths>] + +Options: +[--diff <package-spec> [--diff <package-spec> ...]] [--diff-name-only] +[--diff-unified <number>] [--diff-ignore-all-space] [--diff-no-prefix] +[--diff-src-prefix <path>] [--diff-dst-prefix <path>] [--diff-text] [-g|--global] +[--tag <tag>] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] + +Run "npm help diff" for more info + +\`\`\`bash +npm diff [...<paths>] +\`\`\` + +#### \`diff\` +#### \`diff-name-only\` +#### \`diff-unified\` +#### \`diff-ignore-all-space\` +#### \`diff-no-prefix\` +#### \`diff-src-prefix\` +#### \`diff-dst-prefix\` +#### \`diff-text\` +#### \`global\` +#### \`tag\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage dist-tag > must match snapshot 1`] = ` +Modify package distribution tags + +Usage: +npm dist-tag add <package-spec (with version)> [<tag>] +npm dist-tag rm <package-spec> <tag> +npm dist-tag ls [<package-spec>] + +Options: +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] + +alias: dist-tags + +Run "npm help dist-tag" for more info + +\`\`\`bash +npm dist-tag add <package-spec (with version)> [<tag>] +npm dist-tag rm <package-spec> <tag> +npm dist-tag ls [<package-spec>] + +alias: dist-tags +\`\`\` + +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage docs > must match snapshot 1`] = ` +Open documentation for a package in a web browser + +Usage: +npm docs [<pkgname> [<pkgname> ...]] + +Options: +[--no-browser|--browser <browser>] [--registry <registry>] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] + +alias: home + +Run "npm help docs" for more info + +\`\`\`bash +npm docs [<pkgname> [<pkgname> ...]] + +alias: home +\`\`\` + +#### \`browser\` +#### \`registry\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage doctor > must match snapshot 1`] = ` +Check your npm environment + +Usage: +npm doctor [ping] [registry] [versions] [environment] [permissions] [cache] + +Options: +[--registry <registry>] + +Run "npm help doctor" for more info + +\`\`\`bash +npm doctor [ping] [registry] [versions] [environment] [permissions] [cache] +\`\`\` + +#### \`registry\` +` + +exports[`test/lib/docs.js TAP usage edit > must match snapshot 1`] = ` +Edit an installed package + +Usage: +npm edit <pkg>[/<subpkg>...] + +Options: +[--editor <editor>] + +Run "npm help edit" for more info + +\`\`\`bash +npm edit <pkg>[/<subpkg>...] +\`\`\` + +#### \`editor\` +` + +exports[`test/lib/docs.js TAP usage exec > must match snapshot 1`] = ` +Run a command from a local or remote npm package + +Usage: +npm exec -- <pkg>[@<version>] [args...] +npm exec --package=<pkg>[@<version>] -- <cmd> [args...] +npm exec -c '<cmd> [args...]' +npm exec --package=foo -c '<cmd> [args...]' + +Options: +[--package <package-spec> [--package <package-spec> ...]] [-c|--call <call>] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] + +alias: x + +Run "npm help exec" for more info + +\`\`\`bash +npm exec -- <pkg>[@<version>] [args...] +npm exec --package=<pkg>[@<version>] -- <cmd> [args...] +npm exec -c '<cmd> [args...]' +npm exec --package=foo -c '<cmd> [args...]' + +alias: x +\`\`\` + +#### \`package\` +#### \`call\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage explain > must match snapshot 1`] = ` +Explain installed packages + +Usage: +npm explain <package-spec> + +Options: +[--json] [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] + +alias: why + +Run "npm help explain" for more info + +\`\`\`bash +npm explain <package-spec> + +alias: why +\`\`\` + +#### \`json\` +#### \`workspace\` +` + +exports[`test/lib/docs.js TAP usage explore > must match snapshot 1`] = ` +Browse an installed package + +Usage: +npm explore <pkg> [ -- <command>] + +Options: +[--shell <shell>] + +Run "npm help explore" for more info + +\`\`\`bash +npm explore <pkg> [ -- <command>] +\`\`\` + +#### \`shell\` +` + +exports[`test/lib/docs.js TAP usage find-dupes > must match snapshot 1`] = ` +Find duplication in the package tree + +Usage: +npm find-dupes + +Options: +[--install-strategy <hoisted|nested|shallow>] [--legacy-bundling] +[--global-style] [--strict-peer-deps] [--no-package-lock] +[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] +[--no-audit] [--no-bin-links] [--no-fund] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +Run "npm help find-dupes" for more info + +\`\`\`bash +npm find-dupes +\`\`\` + +#### \`install-strategy\` +#### \`legacy-bundling\` +#### \`global-style\` +#### \`strict-peer-deps\` +#### \`package-lock\` +#### \`omit\` +#### \`ignore-scripts\` +#### \`audit\` +#### \`bin-links\` +#### \`fund\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage fund > must match snapshot 1`] = ` +Retrieve funding information + +Usage: +npm fund [<package-spec>] + +Options: +[--json] [--no-browser|--browser <browser>] [--unicode] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[--which <fundingSourceNumber>] + +Run "npm help fund" for more info + +\`\`\`bash +npm fund [<package-spec>] +\`\`\` + +#### \`json\` +#### \`browser\` +#### \`unicode\` +#### \`workspace\` +#### \`which\` +` + +exports[`test/lib/docs.js TAP usage get > must match snapshot 1`] = ` +Get a value from the npm configuration + +Usage: +npm get [<key> ...] (See \`npm config\`) + +Run "npm help get" for more info + +\`\`\`bash +npm get [<key> ...] (See \`npm config\`) +\`\`\` + +NO PARAMS +` + +exports[`test/lib/docs.js TAP usage help > must match snapshot 1`] = ` +Get help on npm + +Usage: +npm help <term> [<terms..>] + +Options: +[--viewer <viewer>] + +alias: hlep + +Run "npm help help" for more info + +\`\`\`bash +npm help <term> [<terms..>] + +alias: hlep +\`\`\` + +#### \`viewer\` +` + +exports[`test/lib/docs.js TAP usage help-search > must match snapshot 1`] = ` +Search npm help documentation + +Usage: +npm help-search <text> + +Options: +[-l|--long] + +Run "npm help help-search" for more info + +\`\`\`bash +npm help-search <text> +\`\`\` + +#### \`long\` +` + +exports[`test/lib/docs.js TAP usage hook > must match snapshot 1`] = ` +Manage registry hooks + +Usage: +npm hook add <pkg> <url> <secret> [--type=<type>] +npm hook ls [pkg] +npm hook rm <id> +npm hook update <id> <url> <secret> + +Options: +[--registry <registry>] [--otp <otp>] + +Run "npm help hook" for more info + +\`\`\`bash +npm hook add <pkg> <url> <secret> [--type=<type>] +npm hook ls [pkg] +npm hook rm <id> +npm hook update <id> <url> <secret> +\`\`\` + +#### \`registry\` +#### \`otp\` +` + +exports[`test/lib/docs.js TAP usage init > must match snapshot 1`] = ` +Create a package.json file + +Usage: +npm init <package-spec> (same as \`npx <package-spec>) +npm init <@scope> (same as \`npx <@scope>/create\`) + +Options: +[-y|--yes] [-f|--force] [--scope <@scope>] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--no-workspaces-update] [--include-workspace-root] + +aliases: create, innit + +Run "npm help init" for more info + +\`\`\`bash +npm init <package-spec> (same as \`npx <package-spec>) +npm init <@scope> (same as \`npx <@scope>/create\`) + +aliases: create, innit +\`\`\` + +#### \`yes\` +#### \`force\` +#### \`scope\` +#### \`workspace\` +#### \`workspaces\` +#### \`workspaces-update\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage install > must match snapshot 1`] = ` +Install a package + +Usage: +npm install [<package-spec> ...] + +Options: +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] +[-E|--save-exact] [-g|--global] [--install-strategy <hoisted|nested|shallow>] +[--legacy-bundling] [--global-style] +[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] +[--strict-peer-deps] [--no-package-lock] [--foreground-scripts] +[--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +aliases: add, i, in, ins, inst, insta, instal, isnt, isnta, isntal, isntall + +Run "npm help install" for more info + +\`\`\`bash +npm install [<package-spec> ...] + +aliases: add, i, in, ins, inst, insta, instal, isnt, isnta, isntal, isntall +\`\`\` + +#### \`save\` +#### \`save-exact\` +#### \`global\` +#### \`install-strategy\` +#### \`legacy-bundling\` +#### \`global-style\` +#### \`omit\` +#### \`strict-peer-deps\` +#### \`package-lock\` +#### \`foreground-scripts\` +#### \`ignore-scripts\` +#### \`audit\` +#### \`bin-links\` +#### \`fund\` +#### \`dry-run\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage install-ci-test > must match snapshot 1`] = ` +Install a project with a clean slate and run tests + +Usage: +npm install-ci-test + +Options: +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] +[-E|--save-exact] [-g|--global] [--install-strategy <hoisted|nested|shallow>] +[--legacy-bundling] [--global-style] +[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] +[--strict-peer-deps] [--no-package-lock] [--foreground-scripts] +[--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +alias: cit + +Run "npm help install-ci-test" for more info + +\`\`\`bash +npm install-ci-test + +alias: cit +\`\`\` + +#### \`save\` +#### \`save-exact\` +#### \`global\` +#### \`install-strategy\` +#### \`legacy-bundling\` +#### \`global-style\` +#### \`omit\` +#### \`strict-peer-deps\` +#### \`package-lock\` +#### \`foreground-scripts\` +#### \`ignore-scripts\` +#### \`audit\` +#### \`bin-links\` +#### \`fund\` +#### \`dry-run\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage install-test > must match snapshot 1`] = ` +Install package(s) and run tests + +Usage: +npm install-test [<package-spec> ...] + +Options: +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] +[-E|--save-exact] [-g|--global] [--install-strategy <hoisted|nested|shallow>] +[--legacy-bundling] [--global-style] +[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] +[--strict-peer-deps] [--no-package-lock] [--foreground-scripts] +[--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +alias: it + +Run "npm help install-test" for more info + +\`\`\`bash +npm install-test [<package-spec> ...] + +alias: it +\`\`\` + +#### \`save\` +#### \`save-exact\` +#### \`global\` +#### \`install-strategy\` +#### \`legacy-bundling\` +#### \`global-style\` +#### \`omit\` +#### \`strict-peer-deps\` +#### \`package-lock\` +#### \`foreground-scripts\` +#### \`ignore-scripts\` +#### \`audit\` +#### \`bin-links\` +#### \`fund\` +#### \`dry-run\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage link > must match snapshot 1`] = ` +Symlink a package folder + +Usage: +npm link [<package-spec>] + +Options: +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] +[-E|--save-exact] [-g|--global] [--install-strategy <hoisted|nested|shallow>] +[--legacy-bundling] [--global-style] [--strict-peer-deps] [--no-package-lock] +[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] +[--no-audit] [--no-bin-links] [--no-fund] [--dry-run] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +alias: ln + +Run "npm help link" for more info + +\`\`\`bash +npm link [<package-spec>] + +alias: ln +\`\`\` + +#### \`save\` +#### \`save-exact\` +#### \`global\` +#### \`install-strategy\` +#### \`legacy-bundling\` +#### \`global-style\` +#### \`strict-peer-deps\` +#### \`package-lock\` +#### \`omit\` +#### \`ignore-scripts\` +#### \`audit\` +#### \`bin-links\` +#### \`fund\` +#### \`dry-run\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage ll > must match snapshot 1`] = ` +List installed packages + +Usage: +npm ll [[<@scope>/]<pkg> ...] + +Options: +[-a|--all] [--json] [-l|--long] [-p|--parseable] [-g|--global] [--depth <depth>] +[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--link] +[--package-lock-only] [--unicode] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +alias: la + +Run "npm help ll" for more info + +\`\`\`bash +npm ll [[<@scope>/]<pkg> ...] + +alias: la +\`\`\` + +#### \`all\` +#### \`json\` +#### \`long\` +#### \`parseable\` +#### \`global\` +#### \`depth\` +#### \`omit\` +#### \`link\` +#### \`package-lock-only\` +#### \`unicode\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage login > must match snapshot 1`] = ` +Login to a registry user account + +Usage: +npm login + +Options: +[--registry <registry>] [--scope <@scope>] [--auth-type <legacy|web>] + +Run "npm help login" for more info + +\`\`\`bash +npm login +\`\`\` + +#### \`registry\` +#### \`scope\` +#### \`auth-type\` +` + +exports[`test/lib/docs.js TAP usage logout > must match snapshot 1`] = ` +Log out of the registry + +Usage: +npm logout + +Options: +[--registry <registry>] [--scope <@scope>] + +Run "npm help logout" for more info + +\`\`\`bash +npm logout +\`\`\` + +#### \`registry\` +#### \`scope\` +` + +exports[`test/lib/docs.js TAP usage ls > must match snapshot 1`] = ` +List installed packages + +Usage: +npm ls <package-spec> + +Options: +[-a|--all] [--json] [-l|--long] [-p|--parseable] [-g|--global] [--depth <depth>] +[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--link] +[--package-lock-only] [--unicode] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +alias: list + +Run "npm help ls" for more info + +\`\`\`bash +npm ls <package-spec> + +alias: list +\`\`\` + +#### \`all\` +#### \`json\` +#### \`long\` +#### \`parseable\` +#### \`global\` +#### \`depth\` +#### \`omit\` +#### \`link\` +#### \`package-lock-only\` +#### \`unicode\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage npm > must match snapshot 1`] = ` +\`\`\`bash +npm +\`\`\` + +NO PARAMS +` + +exports[`test/lib/docs.js TAP usage npx > must match snapshot 1`] = ` +\`\`\`bash +npx -- <pkg>[@<version>] [args...] +npx --package=<pkg>[@<version>] -- <cmd> [args...] +npx -c '<cmd> [args...]' +npx --package=foo -c '<cmd> [args...]' +\`\`\` + +NO PARAMS +` + +exports[`test/lib/docs.js TAP usage org > must match snapshot 1`] = ` +Manage orgs + +Usage: +npm org set orgname username [developer | admin | owner] +npm org rm orgname username +npm org ls orgname [<username>] + +Options: +[--registry <registry>] [--otp <otp>] [--json] [-p|--parseable] + +alias: ogr + +Run "npm help org" for more info + +\`\`\`bash +npm org set orgname username [developer | admin | owner] +npm org rm orgname username +npm org ls orgname [<username>] + +alias: ogr +\`\`\` + +#### \`registry\` +#### \`otp\` +#### \`json\` +#### \`parseable\` +` + +exports[`test/lib/docs.js TAP usage outdated > must match snapshot 1`] = ` +Check for outdated packages + +Usage: +npm outdated [<package-spec> ...] + +Options: +[-a|--all] [--json] [-l|--long] [-p|--parseable] [-g|--global] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] + +Run "npm help outdated" for more info + +\`\`\`bash +npm outdated [<package-spec> ...] +\`\`\` + +#### \`all\` +#### \`json\` +#### \`long\` +#### \`parseable\` +#### \`global\` +#### \`workspace\` +` + +exports[`test/lib/docs.js TAP usage owner > must match snapshot 1`] = ` +Manage package owners + +Usage: +npm owner add <user> <package-spec> +npm owner rm <user> <package-spec> +npm owner ls <package-spec> + +Options: +[--registry <registry>] [--otp <otp>] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] + +alias: author + +Run "npm help owner" for more info + +\`\`\`bash +npm owner add <user> <package-spec> +npm owner rm <user> <package-spec> +npm owner ls <package-spec> + +alias: author +\`\`\` + +#### \`registry\` +#### \`otp\` +#### \`workspace\` +#### \`workspaces\` +` + +exports[`test/lib/docs.js TAP usage pack > must match snapshot 1`] = ` +Create a tarball from a package + +Usage: +npm pack <package-spec> + +Options: +[--dry-run] [--json] [--pack-destination <pack-destination>] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] + +Run "npm help pack" for more info + +\`\`\`bash +npm pack <package-spec> +\`\`\` + +#### \`dry-run\` +#### \`json\` +#### \`pack-destination\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage ping > must match snapshot 1`] = ` +Ping npm registry + +Usage: +npm ping + +Options: +[--registry <registry>] + +Run "npm help ping" for more info + +\`\`\`bash +npm ping +\`\`\` + +#### \`registry\` +` + +exports[`test/lib/docs.js TAP usage pkg > must match snapshot 1`] = ` +Manages your package.json + +Usage: +npm pkg set <key>=<value> [<key>=<value> ...] +npm pkg get [<key> [<key> ...]] +npm pkg delete <key> [<key> ...] +npm pkg set [<array>[<index>].<key>=<value> ...] +npm pkg set [<array>[].<key>=<value> ...] + +Options: +[-f|--force] [--json] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] + +Run "npm help pkg" for more info + +\`\`\`bash +npm pkg set <key>=<value> [<key>=<value> ...] +npm pkg get [<key> [<key> ...]] +npm pkg delete <key> [<key> ...] +npm pkg set [<array>[<index>].<key>=<value> ...] +npm pkg set [<array>[].<key>=<value> ...] +\`\`\` + +#### \`force\` +#### \`json\` +#### \`workspace\` +#### \`workspaces\` +` + +exports[`test/lib/docs.js TAP usage prefix > must match snapshot 1`] = ` +Display prefix + +Usage: +npm prefix [-g] + +Options: +[-g|--global] + +Run "npm help prefix" for more info + +\`\`\`bash +npm prefix [-g] +\`\`\` + +#### \`global\` +` + +exports[`test/lib/docs.js TAP usage profile > must match snapshot 1`] = ` +Change settings on your registry profile + +Usage: +npm profile enable-2fa [auth-only|auth-and-writes] +npm profile disable-2fa +npm profile get [<key>] +npm profile set <key> <value> + +Options: +[--registry <registry>] [--json] [-p|--parseable] [--otp <otp>] + +Run "npm help profile" for more info + +\`\`\`bash +npm profile enable-2fa [auth-only|auth-and-writes] +npm profile disable-2fa +npm profile get [<key>] +npm profile set <key> <value> +\`\`\` + +#### \`registry\` +#### \`json\` +#### \`parseable\` +#### \`otp\` +` + +exports[`test/lib/docs.js TAP usage prune > must match snapshot 1`] = ` +Remove extraneous packages + +Usage: +npm prune [[<@scope>/]<pkg>...] + +Options: +[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--dry-run] +[--json] [--foreground-scripts] [--ignore-scripts] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +Run "npm help prune" for more info + +\`\`\`bash +npm prune [[<@scope>/]<pkg>...] +\`\`\` + +#### \`omit\` +#### \`dry-run\` +#### \`json\` +#### \`foreground-scripts\` +#### \`ignore-scripts\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage publish > must match snapshot 1`] = ` +Publish a package + +Usage: +npm publish <package-spec> + +Options: +[--tag <tag>] [--access <restricted|public>] [--dry-run] [--otp <otp>] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] + +Run "npm help publish" for more info + +\`\`\`bash +npm publish <package-spec> +\`\`\` + +#### \`tag\` +#### \`access\` +#### \`dry-run\` +#### \`otp\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage query > must match snapshot 1`] = ` +Retrieve a filtered list of packages + +Usage: +npm query <selector> + +Options: +[-g|--global] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] + +Run "npm help query" for more info + +\`\`\`bash +npm query <selector> +\`\`\` + +#### \`global\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage rebuild > must match snapshot 1`] = ` +Rebuild a package + +Usage: +npm rebuild [<package-spec>] ...] + +Options: +[-g|--global] [--no-bin-links] [--foreground-scripts] [--ignore-scripts] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +alias: rb + +Run "npm help rebuild" for more info + +\`\`\`bash +npm rebuild [<package-spec>] ...] + +alias: rb +\`\`\` + +#### \`global\` +#### \`bin-links\` +#### \`foreground-scripts\` +#### \`ignore-scripts\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage repo > must match snapshot 1`] = ` +Open package repository page in the browser + +Usage: +npm repo [<pkgname> [<pkgname> ...]] + +Options: +[--no-browser|--browser <browser>] [--registry <registry>] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] + +Run "npm help repo" for more info + +\`\`\`bash +npm repo [<pkgname> [<pkgname> ...]] +\`\`\` + +#### \`browser\` +#### \`registry\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage restart > must match snapshot 1`] = ` +Restart a package + +Usage: +npm restart [-- <args>] + +Options: +[--ignore-scripts] [--script-shell <script-shell>] + +Run "npm help restart" for more info + +\`\`\`bash +npm restart [-- <args>] +\`\`\` + +#### \`ignore-scripts\` +#### \`script-shell\` +` + +exports[`test/lib/docs.js TAP usage root > must match snapshot 1`] = ` +Display npm root + +Usage: +npm root + +Options: +[-g|--global] + +Run "npm help root" for more info + +\`\`\`bash +npm root +\`\`\` + +#### \`global\` +` + +exports[`test/lib/docs.js TAP usage run-script > must match snapshot 1`] = ` +Run arbitrary package scripts + +Usage: +npm run-script <command> [-- <args>] + +Options: +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--if-present] [--ignore-scripts] +[--foreground-scripts] [--script-shell <script-shell>] + +aliases: run, rum, urn + +Run "npm help run-script" for more info + +\`\`\`bash +npm run-script <command> [-- <args>] + +aliases: run, rum, urn +\`\`\` + +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`if-present\` +#### \`ignore-scripts\` +#### \`foreground-scripts\` +#### \`script-shell\` +` + +exports[`test/lib/docs.js TAP usage search > must match snapshot 1`] = ` +Search for packages + +Usage: +npm search [search terms ...] + +Options: +[-l|--long] [--json] [--color|--no-color|--color always] [-p|--parseable] +[--no-description] [--searchopts <searchopts>] [--searchexclude <searchexclude>] +[--registry <registry>] [--prefer-online] [--prefer-offline] [--offline] + +aliases: find, s, se + +Run "npm help search" for more info + +\`\`\`bash +npm search [search terms ...] + +aliases: find, s, se +\`\`\` + +#### \`long\` +#### \`json\` +#### \`color\` +#### \`parseable\` +#### \`description\` +#### \`searchopts\` +#### \`searchexclude\` +#### \`registry\` +#### \`prefer-online\` +#### \`prefer-offline\` +#### \`offline\` +` + +exports[`test/lib/docs.js TAP usage set > must match snapshot 1`] = ` +Set a value in the npm configuration + +Usage: +npm set <key>=<value> [<key>=<value> ...] (See \`npm config\`) + +Run "npm help set" for more info + +\`\`\`bash +npm set <key>=<value> [<key>=<value> ...] (See \`npm config\`) +\`\`\` + +NO PARAMS +` + +exports[`test/lib/docs.js TAP usage shrinkwrap > must match snapshot 1`] = ` +Lock down dependency versions for publication + +Usage: +npm shrinkwrap + +Run "npm help shrinkwrap" for more info + +\`\`\`bash +npm shrinkwrap +\`\`\` + +NO PARAMS +` + +exports[`test/lib/docs.js TAP usage star > must match snapshot 1`] = ` +Mark your favorite packages + +Usage: +npm star [<package-spec>...] + +Options: +[--registry <registry>] [--unicode] [--otp <otp>] + +Run "npm help star" for more info + +\`\`\`bash +npm star [<package-spec>...] +\`\`\` + +#### \`registry\` +#### \`unicode\` +#### \`otp\` +` + +exports[`test/lib/docs.js TAP usage stars > must match snapshot 1`] = ` +View packages marked as favorites + +Usage: +npm stars [<user>] + +Options: +[--registry <registry>] + +Run "npm help stars" for more info + +\`\`\`bash +npm stars [<user>] +\`\`\` + +#### \`registry\` +` + +exports[`test/lib/docs.js TAP usage start > must match snapshot 1`] = ` +Start a package + +Usage: +npm start [-- <args>] + +Options: +[--ignore-scripts] [--script-shell <script-shell>] + +Run "npm help start" for more info + +\`\`\`bash +npm start [-- <args>] +\`\`\` + +#### \`ignore-scripts\` +#### \`script-shell\` +` + +exports[`test/lib/docs.js TAP usage stop > must match snapshot 1`] = ` +Stop a package + +Usage: +npm stop [-- <args>] + +Options: +[--ignore-scripts] [--script-shell <script-shell>] + +Run "npm help stop" for more info + +\`\`\`bash +npm stop [-- <args>] +\`\`\` + +#### \`ignore-scripts\` +#### \`script-shell\` +` + +exports[`test/lib/docs.js TAP usage team > must match snapshot 1`] = ` +Manage organization teams and team memberships + +Usage: +npm team create <scope:team> [--otp <otpcode>] +npm team destroy <scope:team> [--otp <otpcode>] +npm team add <scope:team> <user> [--otp <otpcode>] +npm team rm <scope:team> <user> [--otp <otpcode>] +npm team ls <scope>|<scope:team> + +Options: +[--registry <registry>] [--otp <otp>] [-p|--parseable] [--json] + +Run "npm help team" for more info + +\`\`\`bash +npm team create <scope:team> [--otp <otpcode>] +npm team destroy <scope:team> [--otp <otpcode>] +npm team add <scope:team> <user> [--otp <otpcode>] +npm team rm <scope:team> <user> [--otp <otpcode>] +npm team ls <scope>|<scope:team> +\`\`\` + +#### \`registry\` +#### \`otp\` +#### \`parseable\` +#### \`json\` +` + +exports[`test/lib/docs.js TAP usage test > must match snapshot 1`] = ` +Test a package + +Usage: +npm test [-- <args>] + +Options: +[--ignore-scripts] [--script-shell <script-shell>] + +aliases: tst, t + +Run "npm help test" for more info + +\`\`\`bash +npm test [-- <args>] + +aliases: tst, t +\`\`\` + +#### \`ignore-scripts\` +#### \`script-shell\` +` + +exports[`test/lib/docs.js TAP usage token > must match snapshot 1`] = ` +Manage your authentication tokens + +Usage: +npm token list +npm token revoke <id|token> +npm token create [--read-only] [--cidr=list] + +Options: +[--read-only] [--cidr <cidr> [--cidr <cidr> ...]] [--registry <registry>] +[--otp <otp>] + +Run "npm help token" for more info + +\`\`\`bash +npm token list +npm token revoke <id|token> +npm token create [--read-only] [--cidr=list] +\`\`\` + +#### \`read-only\` +#### \`cidr\` +#### \`registry\` +#### \`otp\` +` + +exports[`test/lib/docs.js TAP usage uninstall > must match snapshot 1`] = ` +Remove a package + +Usage: +npm uninstall [<@scope>/]<pkg>... + +Options: +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +aliases: unlink, remove, rm, r, un + +Run "npm help uninstall" for more info + +\`\`\`bash +npm uninstall [<@scope>/]<pkg>... + +aliases: unlink, remove, rm, r, un +\`\`\` + +#### \`save\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage unpublish > must match snapshot 1`] = ` +Remove a package from the registry + +Usage: +npm unpublish [<package-spec>] + +Options: +[--dry-run] [-f|--force] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] + +Run "npm help unpublish" for more info + +\`\`\`bash +npm unpublish [<package-spec>] +\`\`\` + +#### \`dry-run\` +#### \`force\` +#### \`workspace\` +#### \`workspaces\` +` + +exports[`test/lib/docs.js TAP usage unstar > must match snapshot 1`] = ` +Remove an item from your favorite packages + +Usage: +npm unstar [<package-spec>...] + +Options: +[--registry <registry>] [--unicode] [--otp <otp>] + +Run "npm help unstar" for more info + +\`\`\`bash +npm unstar [<package-spec>...] +\`\`\` + +#### \`registry\` +#### \`unicode\` +#### \`otp\` +` + +exports[`test/lib/docs.js TAP usage update > must match snapshot 1`] = ` +Update packages + +Usage: +npm update [<pkg>...] + +Options: +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] +[-g|--global] [--install-strategy <hoisted|nested|shallow>] [--legacy-bundling] +[--global-style] [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] +[--strict-peer-deps] [--no-package-lock] [--foreground-scripts] +[--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] + +aliases: up, upgrade, udpate + +Run "npm help update" for more info + +\`\`\`bash +npm update [<pkg>...] + +aliases: up, upgrade, udpate +\`\`\` + +#### \`save\` +#### \`global\` +#### \`install-strategy\` +#### \`legacy-bundling\` +#### \`global-style\` +#### \`omit\` +#### \`strict-peer-deps\` +#### \`package-lock\` +#### \`foreground-scripts\` +#### \`ignore-scripts\` +#### \`audit\` +#### \`bin-links\` +#### \`fund\` +#### \`dry-run\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +#### \`install-links\` +` + +exports[`test/lib/docs.js TAP usage version > must match snapshot 1`] = ` +Bump a package version + +Usage: +npm version [<newversion> | major | minor | patch | premajor | preminor | prepatch | prerelease | from-git] + +Options: +[--allow-same-version] [--no-commit-hooks] [--no-git-tag-version] [--json] +[--preid prerelease-id] [--sign-git-tag] +[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--no-workspaces-update] [--include-workspace-root] + +alias: verison + +Run "npm help version" for more info + +\`\`\`bash +npm version [<newversion> | major | minor | patch | premajor | preminor | prepatch | prerelease | from-git] + +alias: verison +\`\`\` + +#### \`allow-same-version\` +#### \`commit-hooks\` +#### \`git-tag-version\` +#### \`json\` +#### \`preid\` +#### \`sign-git-tag\` +#### \`workspace\` +#### \`workspaces\` +#### \`workspaces-update\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage view > must match snapshot 1`] = ` +View registry info + +Usage: +npm view [<package-spec>] [<field>[.subfield]...] + +Options: +[--json] [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] +[-ws|--workspaces] [--include-workspace-root] + +aliases: info, show, v + +Run "npm help view" for more info + +\`\`\`bash +npm view [<package-spec>] [<field>[.subfield]...] + +aliases: info, show, v +\`\`\` + +#### \`json\` +#### \`workspace\` +#### \`workspaces\` +#### \`include-workspace-root\` +` + +exports[`test/lib/docs.js TAP usage whoami > must match snapshot 1`] = ` +Display npm username + +Usage: +npm whoami + +Options: +[--registry <registry>] + +Run "npm help whoami" for more info + +\`\`\`bash +npm whoami +\`\`\` + +#### \`registry\` +` diff --git a/tap-snapshots/test/lib/load-all-commands.js.test.cjs b/tap-snapshots/test/lib/load-all-commands.js.test.cjs deleted file mode 100644 index d84cdfb..0000000 --- a/tap-snapshots/test/lib/load-all-commands.js.test.cjs +++ /dev/null @@ -1,1127 +0,0 @@ -/* IMPORTANT - * This snapshot file is auto-generated, but designed for humans. - * It should be checked into source control and tracked carefully. - * Re-generate by setting TAP_SNAPSHOT=1 and running tests. - * Make sure to inspect the output below. Do not ignore changes! - */ -'use strict' -exports[`test/lib/load-all-commands.js TAP load each command access > must match snapshot 1`] = ` -npm access - -Set access level on published packages - -Usage: -npm access public [<package>] -npm access restricted [<package>] -npm access grant <read-only|read-write> <scope:team> [<package>] -npm access revoke <scope:team> [<package>] -npm access 2fa-required [<package>] -npm access 2fa-not-required [<package>] -npm access ls-packages [<user>|<scope>|<scope:team>] -npm access ls-collaborators [<package> [<user>]] -npm access edit [<package>] - -Options: -[--registry <registry>] [--otp <otp>] - -Run "npm help access" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command adduser > must match snapshot 1`] = ` -npm adduser - -Add a registry user account - -Usage: -npm adduser - -Options: -[--registry <registry>] [--scope <@scope>] - -aliases: login, add-user - -Run "npm help adduser" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command audit > must match snapshot 1`] = ` -npm audit - -Run a security audit - -Usage: -npm audit [fix] - -Options: -[--audit-level <info|low|moderate|high|critical|none>] [--dry-run] [-f|--force] -[--json] [--package-lock-only] -[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -Run "npm help audit" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command bin > must match snapshot 1`] = ` -npm bin - -Display npm bin folder - -Usage: -npm bin - -Options: -[-g|--global] - -Run "npm help bin" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command bugs > must match snapshot 1`] = ` -npm bugs - -Report bugs for a package in a web browser - -Usage: -npm bugs [<pkgname>] - -Options: -[--no-browser|--browser <browser>] [--registry <registry>] - -alias: issues - -Run "npm help bugs" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command cache > must match snapshot 1`] = ` -npm cache - -Manipulates packages cache - -Usage: -npm cache add <tarball file> -npm cache add <folder> -npm cache add <tarball url> -npm cache add <git url> -npm cache add <name>@<version> -npm cache clean [<key>] -npm cache ls [<name>@<version>] -npm cache verify - -Options: -[--cache <cache>] - -Run "npm help cache" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command ci > must match snapshot 1`] = ` -npm ci - -Install a project with a clean slate - -Usage: -npm ci - -Options: -[--no-audit] [--ignore-scripts] [--script-shell <script-shell>] - -aliases: clean-install, ic, install-clean, isntall-clean - -Run "npm help ci" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command completion > must match snapshot 1`] = ` -npm completion - -Tab Completion for npm - -Usage: -npm completion - -Run "npm help completion" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command config > must match snapshot 1`] = ` -npm config - -Manage the npm configuration files - -Usage: -npm config set <key>=<value> [<key>=<value> ...] -npm config get [<key> [<key> ...]] -npm config delete <key> [<key> ...] -npm config list [--json] -npm config edit - -Options: -[--json] [-g|--global] [--editor <editor>] [-L|--location <global|user|project>] -[-l|--long] - -alias: c - -Run "npm help config" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command dedupe > must match snapshot 1`] = ` -npm dedupe - -Reduce duplication in the package tree - -Usage: -npm dedupe - -Options: -[--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] -[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] -[--no-audit] [--no-bin-links] [--no-fund] [--dry-run] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -alias: ddp - -Run "npm help dedupe" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command deprecate > must match snapshot 1`] = ` -npm deprecate - -Deprecate a version of a package - -Usage: -npm deprecate <pkg>[@<version>] <message> - -Options: -[--registry <registry>] [--otp <otp>] - -Run "npm help deprecate" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command diff > must match snapshot 1`] = ` -npm diff - -The registry diff command - -Usage: -npm diff [...<paths>] - -Options: -[--diff <pkg-name|spec|version> [--diff <pkg-name|spec|version> ...]] -[--diff-name-only] [--diff-unified <number>] [--diff-ignore-all-space] -[--diff-no-prefix] [--diff-src-prefix <path>] [--diff-dst-prefix <path>] -[--diff-text] [-g|--global] [--tag <tag>] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -Run "npm help diff" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command dist-tag > must match snapshot 1`] = ` -npm dist-tag - -Modify package distribution tags - -Usage: -npm dist-tag add <pkg>@<version> [<tag>] -npm dist-tag rm <pkg> <tag> -npm dist-tag ls [<pkg>] - -Options: -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -alias: dist-tags - -Run "npm help dist-tag" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command docs > must match snapshot 1`] = ` -npm docs - -Open documentation for a package in a web browser - -Usage: -npm docs [<pkgname> [<pkgname> ...]] - -Options: -[--no-browser|--browser <browser>] [--registry <registry>] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -alias: home - -Run "npm help docs" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command doctor > must match snapshot 1`] = ` -npm doctor - -Check your npm environment - -Usage: -npm doctor - -Options: -[--registry <registry>] - -Run "npm help doctor" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command edit > must match snapshot 1`] = ` -npm edit - -Edit an installed package - -Usage: -npm edit <pkg>[/<subpkg>...] - -Options: -[--editor <editor>] - -Run "npm help edit" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command exec > must match snapshot 1`] = ` -npm exec - -Run a command from a local or remote npm package - -Usage: -npm exec -- <pkg>[@<version>] [args...] -npm exec --package=<pkg>[@<version>] -- <cmd> [args...] -npm exec -c '<cmd> [args...]' -npm exec --package=foo -c '<cmd> [args...]' - -Options: -[--package <pkg>[@<version>] [--package <pkg>[@<version>] ...]] -[-c|--call <call>] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -alias: x - -Run "npm help exec" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command explain > must match snapshot 1`] = ` -npm explain - -Explain installed packages - -Usage: -npm explain <folder | specifier> - -Options: -[--json] [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - -alias: why - -Run "npm help explain" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command explore > must match snapshot 1`] = ` -npm explore - -Browse an installed package - -Usage: -npm explore <pkg> [ -- <command>] - -Options: -[--shell <shell>] - -Run "npm help explore" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command find-dupes > must match snapshot 1`] = ` -npm find-dupes - -Find duplication in the package tree - -Usage: -npm find-dupes - -Options: -[--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] -[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] -[--no-audit] [--no-bin-links] [--no-fund] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -Run "npm help find-dupes" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command fund > must match snapshot 1`] = ` -npm fund - -Retrieve funding information - -Usage: -npm fund [[<@scope>/]<pkg>] - -Options: -[--json] [--no-browser|--browser <browser>] [--unicode] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[--which <fundingSourceNumber>] - -Run "npm help fund" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command get > must match snapshot 1`] = ` -npm get - -Get a value from the npm configuration - -Usage: -npm get [<key> ...] (See \`npm config\`) - -Run "npm help get" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command help > must match snapshot 1`] = ` -npm help - -Get help on npm - -Usage: -npm help <term> [<terms..>] - -Options: -[--viewer <viewer>] - -alias: hlep - -Run "npm help help" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command hook > must match snapshot 1`] = ` -npm hook - -Manage registry hooks - -Usage: -npm hook add <pkg> <url> <secret> [--type=<type>] -npm hook ls [pkg] -npm hook rm <id> -npm hook update <id> <url> <secret> - -Options: -[--registry <registry>] [--otp <otp>] - -Run "npm help hook" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command init > must match snapshot 1`] = ` -npm init - -Create a package.json file - -Usage: -npm init [--force|-f|--yes|-y|--scope] -npm init <@scope> (same as \`npx <@scope>/create\`) -npm init [<@scope>/]<name> (same as \`npx [<@scope>/]create-<name>\`) - -Options: -[-y|--yes] [-f|--force] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -aliases: create, innit - -Run "npm help init" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command install > must match snapshot 1`] = ` -npm install - -Install a package - -Usage: -npm install [<@scope>/]<pkg> -npm install [<@scope>/]<pkg>@<tag> -npm install [<@scope>/]<pkg>@<version> -npm install [<@scope>/]<pkg>@<version range> -npm install <alias>@npm:<name> -npm install <folder> -npm install <tarball file> -npm install <tarball url> -npm install <git:// url> -npm install <github username>/<github project> - -Options: -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] -[-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] -[--strict-peer-deps] [--no-package-lock] -[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] -[--no-audit] [--no-bin-links] [--no-fund] [--dry-run] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -aliases: i, in, ins, inst, insta, instal, isnt, isnta, isntal, add - -Run "npm help install" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command install-ci-test > must match snapshot 1`] = ` -npm install-ci-test - -Install a project with a clean slate and run tests - -Usage: -npm install-ci-test - -Options: -[--no-audit] [--ignore-scripts] [--script-shell <script-shell>] - -alias: cit - -Run "npm help install-ci-test" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command install-test > must match snapshot 1`] = ` -npm install-test - -Install package(s) and run tests - -Usage: -npm install-test [<@scope>/]<pkg> -npm install-test [<@scope>/]<pkg>@<tag> -npm install-test [<@scope>/]<pkg>@<version> -npm install-test [<@scope>/]<pkg>@<version range> -npm install-test <alias>@npm:<name> -npm install-test <folder> -npm install-test <tarball file> -npm install-test <tarball url> -npm install-test <git:// url> -npm install-test <github username>/<github project> - -Options: -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] -[-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] -[--strict-peer-deps] [--no-package-lock] -[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] -[--no-audit] [--no-bin-links] [--no-fund] [--dry-run] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -alias: it - -Run "npm help install-test" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command link > must match snapshot 1`] = ` -npm link - -Symlink a package folder - -Usage: -npm link (in package dir) -npm link [<@scope>/]<pkg>[@<version>] - -Options: -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] -[-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] -[--strict-peer-deps] [--no-package-lock] -[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] -[--no-audit] [--no-bin-links] [--no-fund] [--dry-run] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -alias: ln - -Run "npm help link" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command ll > must match snapshot 1`] = ` -npm ll - -List installed packages - -Usage: -npm ll [[<@scope>/]<pkg> ...] - -Options: -[-a|--all] [--json] [-l|--long] [-p|--parseable] [-g|--global] [--depth <depth>] -[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--link] -[--package-lock-only] [--unicode] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -alias: la - -Run "npm help ll" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command login > must match snapshot 1`] = ` -npm adduser - -Add a registry user account - -Usage: -npm adduser - -Options: -[--registry <registry>] [--scope <@scope>] - -aliases: login, add-user - -Run "npm help adduser" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command logout > must match snapshot 1`] = ` -npm logout - -Log out of the registry - -Usage: -npm logout - -Options: -[--registry <registry>] [--scope <@scope>] - -Run "npm help logout" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command ls > must match snapshot 1`] = ` -npm ls - -List installed packages - -Usage: -npm ls [[<@scope>/]<pkg> ...] - -Options: -[-a|--all] [--json] [-l|--long] [-p|--parseable] [-g|--global] [--depth <depth>] -[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--link] -[--package-lock-only] [--unicode] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -alias: list - -Run "npm help ls" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command org > must match snapshot 1`] = ` -npm org - -Manage orgs - -Usage: -npm org set orgname username [developer | admin | owner] -npm org rm orgname username -npm org ls orgname [<username>] - -Options: -[--registry <registry>] [--otp <otp>] [--json] [-p|--parseable] - -alias: ogr - -Run "npm help org" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command outdated > must match snapshot 1`] = ` -npm outdated - -Check for outdated packages - -Usage: -npm outdated [[<@scope>/]<pkg> ...] - -Options: -[-a|--all] [--json] [-l|--long] [-p|--parseable] [-g|--global] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - -Run "npm help outdated" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command owner > must match snapshot 1`] = ` -npm owner - -Manage package owners - -Usage: -npm owner add <user> [<@scope>/]<pkg> -npm owner rm <user> [<@scope>/]<pkg> -npm owner ls [<@scope>/]<pkg> - -Options: -[--registry <registry>] [--otp <otp>] - -alias: author - -Run "npm help owner" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command pack > must match snapshot 1`] = ` -npm pack - -Create a tarball from a package - -Usage: -npm pack [[<@scope>/]<pkg>...] - -Options: -[--dry-run] [--json] [--pack-destination <pack-destination>] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -Run "npm help pack" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command ping > must match snapshot 1`] = ` -npm ping - -Ping npm registry - -Usage: -npm ping - -Options: -[--registry <registry>] - -Run "npm help ping" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command pkg > must match snapshot 1`] = ` -npm pkg - -Manages your package.json - -Usage: -npm pkg set <key>=<value> [<key>=<value> ...] -npm pkg get [<key> [<key> ...]] -npm pkg delete <key> [<key> ...] -npm pkg set [<array>[<index>].<key>=<value> ...] -npm pkg set [<array>[].<key>=<value> ...] - -Options: -[-f|--force] [--json] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] - -Run "npm help pkg" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command prefix > must match snapshot 1`] = ` -npm prefix - -Display prefix - -Usage: -npm prefix [-g] - -Options: -[-g|--global] - -Run "npm help prefix" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command profile > must match snapshot 1`] = ` -npm profile - -Change settings on your registry profile - -Usage: -npm profile enable-2fa [auth-only|auth-and-writes] -npm profile disable-2fa -npm profile get [<key>] -npm profile set <key> <value> - -Options: -[--registry <registry>] [--json] [-p|--parseable] [--otp <otp>] - -Run "npm help profile" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command prune > must match snapshot 1`] = ` -npm prune - -Remove extraneous packages - -Usage: -npm prune [[<@scope>/]<pkg>...] - -Options: -[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--dry-run] -[--json] [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -Run "npm help prune" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command publish > must match snapshot 1`] = ` -npm publish - -Publish a package - -Usage: -npm publish [<folder>] - -Options: -[--tag <tag>] [--access <restricted|public>] [--dry-run] [--otp <otp>] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -Run "npm help publish" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command rebuild > must match snapshot 1`] = ` -npm rebuild - -Rebuild a package - -Usage: -npm rebuild [[<@scope>/]<name>[@<version>] ...] - -Options: -[-g|--global] [--no-bin-links] [--ignore-scripts] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -alias: rb - -Run "npm help rebuild" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command repo > must match snapshot 1`] = ` -npm repo - -Open package repository page in the browser - -Usage: -npm repo [<pkgname> [<pkgname> ...]] - -Options: -[--no-browser|--browser <browser>] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -Run "npm help repo" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command restart > must match snapshot 1`] = ` -npm restart - -Restart a package - -Usage: -npm restart [-- <args>] - -Options: -[--ignore-scripts] [--script-shell <script-shell>] - -Run "npm help restart" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command root > must match snapshot 1`] = ` -npm root - -Display npm root - -Usage: -npm root - -Options: -[-g|--global] - -Run "npm help root" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command run-script > must match snapshot 1`] = ` -npm run-script - -Run arbitrary package scripts - -Usage: -npm run-script <command> [-- <args>] - -Options: -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] [--if-present] [--ignore-scripts] -[--script-shell <script-shell>] - -aliases: run, rum, urn - -Run "npm help run-script" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command search > must match snapshot 1`] = ` -npm search - -Search for packages - -Usage: -npm search [search terms ...] - -Options: -[-l|--long] [--json] [--color|--no-color|--color always] [-p|--parseable] -[--no-description] [--searchopts <searchopts>] [--searchexclude <searchexclude>] -[--registry <registry>] [--prefer-online] [--prefer-offline] [--offline] - -aliases: s, se, find - -Run "npm help search" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command set > must match snapshot 1`] = ` -npm set - -Set a value in the npm configuration - -Usage: -npm set <key>=<value> [<key>=<value> ...] (See \`npm config\`) - -Run "npm help set" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command set-script > must match snapshot 1`] = ` -npm set-script - -Set tasks in the scripts section of package.json - -Usage: -npm set-script [<script>] [<command>] - -Options: -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -Run "npm help set-script" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command shrinkwrap > must match snapshot 1`] = ` -npm shrinkwrap - -Lock down dependency versions for publication - -Usage: -npm shrinkwrap - -Run "npm help shrinkwrap" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command star > must match snapshot 1`] = ` -npm star - -Mark your favorite packages - -Usage: -npm star [<pkg>...] - -Options: -[--registry <registry>] [--unicode] - -Run "npm help star" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command stars > must match snapshot 1`] = ` -npm stars - -View packages marked as favorites - -Usage: -npm stars [<user>] - -Options: -[--registry <registry>] - -Run "npm help stars" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command start > must match snapshot 1`] = ` -npm start - -Start a package - -Usage: -npm start [-- <args>] - -Options: -[--ignore-scripts] [--script-shell <script-shell>] - -Run "npm help start" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command stop > must match snapshot 1`] = ` -npm stop - -Stop a package - -Usage: -npm stop [-- <args>] - -Options: -[--ignore-scripts] [--script-shell <script-shell>] - -Run "npm help stop" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command team > must match snapshot 1`] = ` -npm team - -Manage organization teams and team memberships - -Usage: -npm team create <scope:team> [--otp <otpcode>] -npm team destroy <scope:team> [--otp <otpcode>] -npm team add <scope:team> <user> [--otp <otpcode>] -npm team rm <scope:team> <user> [--otp <otpcode>] -npm team ls <scope>|<scope:team> - -Options: -[--registry <registry>] [--otp <otp>] [-p|--parseable] [--json] - -Run "npm help team" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command test > must match snapshot 1`] = ` -npm test - -Test a package - -Usage: -npm test [-- <args>] - -Options: -[--ignore-scripts] [--script-shell <script-shell>] - -aliases: tst, t - -Run "npm help test" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command token > must match snapshot 1`] = ` -npm token - -Manage your authentication tokens - -Usage: -npm token list -npm token revoke <id|token> -npm token create [--read-only] [--cidr=list] - -Options: -[--read-only] [--cidr <cidr> [--cidr <cidr> ...]] [--registry <registry>] -[--otp <otp>] - -Run "npm help token" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command uninstall > must match snapshot 1`] = ` -npm uninstall - -Remove a package - -Usage: -npm uninstall [<@scope>/]<pkg>... - -Options: -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -aliases: un, unlink, remove, rm, r - -Run "npm help uninstall" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command unpublish > must match snapshot 1`] = ` -npm unpublish - -Remove a package from the registry - -Usage: -npm unpublish [<@scope>/]<pkg>[@<version>] - -Options: -[--dry-run] [-f|--force] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] - -Run "npm help unpublish" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command unstar > must match snapshot 1`] = ` -npm unstar - -Remove an item from your favorite packages - -Usage: -npm unstar [<pkg>...] - -Options: -[--registry <registry>] [--unicode] [--otp <otp>] - -Run "npm help unstar" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command update > must match snapshot 1`] = ` -npm update - -Update packages - -Usage: -npm update [<pkg>...] - -Options: -[-g|--global] [--global-style] [--legacy-bundling] [--strict-peer-deps] -[--no-package-lock] -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] -[--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] -[--no-audit] [--no-bin-links] [--no-fund] [--dry-run] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -aliases: up, upgrade, udpate - -Run "npm help update" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command version > must match snapshot 1`] = ` -npm version - -Bump a package version - -Usage: -npm version [<newversion> | major | minor | patch | premajor | preminor | prepatch | prerelease | from-git] - -Options: -[--allow-same-version] [--no-commit-hooks] [--no-git-tag-version] [--json] -[--preid prerelease-id] [--sign-git-tag] -[-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -alias: verison - -Run "npm help version" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command view > must match snapshot 1`] = ` -npm view - -View registry info - -Usage: -npm view [<@scope>/]<pkg>[@<version>] [<field>[.subfield]...] - -Options: -[--json] [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] -[-ws|--workspaces] [--include-workspace-root] - -aliases: v, info, show - -Run "npm help view" for more info -` - -exports[`test/lib/load-all-commands.js TAP load each command whoami > must match snapshot 1`] = ` -npm whoami - -Display npm username - -Usage: -npm whoami - -Options: -[--registry <registry>] - -Run "npm help whoami" for more info -` diff --git a/tap-snapshots/test/lib/utils/cmd-list.js.test.cjs b/tap-snapshots/test/lib/utils/cmd-list.js.test.cjs deleted file mode 100644 index 9715807..0000000 --- a/tap-snapshots/test/lib/utils/cmd-list.js.test.cjs +++ /dev/null @@ -1,210 +0,0 @@ -/* IMPORTANT - * This snapshot file is auto-generated, but designed for humans. - * It should be checked into source control and tracked carefully. - * Re-generate by setting TAP_SNAPSHOT=1 and running tests. - * Make sure to inspect the output below. Do not ignore changes! - */ -'use strict' -exports[`test/lib/utils/cmd-list.js TAP > must match snapshot 1`] = ` -Object { - "affordances": Object { - "add": "install", - "add-user": "adduser", - "author": "owner", - "dist-tags": "dist-tag", - "find": "search", - "hlep": "help", - "home": "docs", - "ic": "ci", - "in": "install", - "info": "view", - "innit": "init", - "ins": "install", - "inst": "install", - "insta": "install", - "instal": "install", - "install-clean": "ci", - "isnt": "install", - "isnta": "install", - "isntal": "install", - "isntall-clean": "ci", - "issues": "bugs", - "la": "ll", - "login": "adduser", - "ogr": "org", - "r": "uninstall", - "remove": "uninstall", - "rm": "uninstall", - "rum": "run-script", - "show": "view", - "sit": "cit", - "udpate": "update", - "unlink": "uninstall", - "upgrade": "update", - "urn": "run-script", - "verison": "version", - }, - "aliases": Object { - "add": "install", - "add-user": "adduser", - "author": "owner", - "c": "config", - "cit": "install-ci-test", - "clean-install": "ci", - "clean-install-test": "cit", - "create": "init", - "ddp": "dedupe", - "dist-tags": "dist-tag", - "find": "search", - "hlep": "help", - "home": "docs", - "i": "install", - "ic": "ci", - "in": "install", - "info": "view", - "innit": "init", - "ins": "install", - "inst": "install", - "insta": "install", - "instal": "install", - "install-clean": "ci", - "isnt": "install", - "isnta": "install", - "isntal": "install", - "isntall-clean": "ci", - "issues": "bugs", - "it": "install-test", - "la": "ll", - "list": "ls", - "ln": "link", - "login": "adduser", - "ogr": "org", - "r": "uninstall", - "rb": "rebuild", - "remove": "uninstall", - "rm": "uninstall", - "rum": "run-script", - "run": "run-script", - "s": "search", - "se": "search", - "show": "view", - "sit": "cit", - "t": "test", - "tst": "test", - "udpate": "update", - "un": "uninstall", - "unlink": "uninstall", - "up": "update", - "upgrade": "update", - "urn": "run-script", - "v": "view", - "verison": "version", - "why": "explain", - "x": "exec", - }, - "cmdList": Array [ - "ci", - "install-ci-test", - "install", - "install-test", - "uninstall", - "cache", - "config", - "set", - "get", - "update", - "outdated", - "prune", - "pack", - "find-dupes", - "dedupe", - "hook", - "rebuild", - "link", - "publish", - "star", - "stars", - "unstar", - "adduser", - "login", - "logout", - "unpublish", - "owner", - "access", - "team", - "deprecate", - "shrinkwrap", - "token", - "profile", - "audit", - "fund", - "org", - "help", - "ls", - "ll", - "search", - "view", - "init", - "version", - "edit", - "explore", - "docs", - "repo", - "bugs", - "root", - "prefix", - "bin", - "whoami", - "diff", - "dist-tag", - "ping", - "pkg", - "test", - "stop", - "start", - "restart", - "run-script", - "set-script", - "completion", - "doctor", - "exec", - "explain", - ], - "plumbing": Array [ - "birthday", - "help-search", - ], - "shellouts": Array [ - "exec", - "run-script", - "test", - "start", - "stop", - "restart", - "birthday", - ], - "shorthands": Object { - "c": "config", - "cit": "install-ci-test", - "clean-install": "ci", - "clean-install-test": "cit", - "create": "init", - "ddp": "dedupe", - "i": "install", - "it": "install-test", - "list": "ls", - "ln": "link", - "rb": "rebuild", - "run": "run-script", - "s": "search", - "se": "search", - "t": "test", - "tst": "test", - "un": "uninstall", - "up": "update", - "v": "view", - "why": "explain", - "x": "exec", - }, -} -` diff --git a/tap-snapshots/test/lib/utils/config/definitions.js.test.cjs b/tap-snapshots/test/lib/utils/config/definitions.js.test.cjs deleted file mode 100644 index d75d32d..0000000 --- a/tap-snapshots/test/lib/utils/config/definitions.js.test.cjs +++ /dev/null @@ -1,1924 +0,0 @@ -/* IMPORTANT - * This snapshot file is auto-generated, but designed for humans. - * It should be checked into source control and tracked carefully. - * Re-generate by setting TAP_SNAPSHOT=1 and running tests. - * Make sure to inspect the output below. Do not ignore changes! - */ -'use strict' -exports[`test/lib/utils/config/definitions.js TAP > all config keys 1`] = ` -Array [ - "_auth", - "access", - "all", - "allow-same-version", - "also", - "audit", - "audit-level", - "auth-type", - "before", - "bin-links", - "browser", - "ca", - "cache", - "cache-max", - "cache-min", - "cafile", - "call", - "cert", - "ci-name", - "cidr", - "color", - "commit-hooks", - "depth", - "description", - "dev", - "diff", - "diff-ignore-all-space", - "diff-name-only", - "diff-no-prefix", - "diff-dst-prefix", - "diff-src-prefix", - "diff-text", - "diff-unified", - "dry-run", - "editor", - "engine-strict", - "fetch-retries", - "fetch-retry-factor", - "fetch-retry-maxtimeout", - "fetch-retry-mintimeout", - "fetch-timeout", - "force", - "foreground-scripts", - "format-package-lock", - "fund", - "git", - "git-tag-version", - "global", - "global-style", - "globalconfig", - "heading", - "https-proxy", - "if-present", - "ignore-scripts", - "include", - "include-staged", - "include-workspace-root", - "init-author-email", - "init-author-name", - "init-author-url", - "init-license", - "init-module", - "init-version", - "init.author.email", - "init.author.name", - "init.author.url", - "init.license", - "init.module", - "init.version", - "json", - "key", - "legacy-bundling", - "legacy-peer-deps", - "link", - "local-address", - "location", - "lockfile-version", - "loglevel", - "logs-max", - "long", - "maxsockets", - "message", - "node-options", - "node-version", - "noproxy", - "npm-version", - "offline", - "omit", - "only", - "optional", - "otp", - "package", - "package-lock", - "package-lock-only", - "pack-destination", - "parseable", - "prefer-offline", - "prefer-online", - "prefix", - "preid", - "production", - "progress", - "proxy", - "read-only", - "rebuild-bundle", - "registry", - "save", - "save-bundle", - "save-dev", - "save-exact", - "save-optional", - "save-peer", - "save-prefix", - "save-prod", - "scope", - "script-shell", - "searchexclude", - "searchlimit", - "searchopts", - "searchstaleness", - "shell", - "shrinkwrap", - "sign-git-commit", - "sign-git-tag", - "sso-poll-frequency", - "sso-type", - "strict-peer-deps", - "strict-ssl", - "tag", - "tag-version-prefix", - "timing", - "tmp", - "umask", - "unicode", - "update-notifier", - "usage", - "user-agent", - "userconfig", - "version", - "versions", - "viewer", - "which", - "workspace", - "workspaces", - "yes", -] -` - -exports[`test/lib/utils/config/definitions.js TAP > all config keys that are shared to flatOptions 1`] = ` -Array [] -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for _auth 1`] = ` -#### \`_auth\` - -* Default: null -* Type: null or String - -A basic-auth string to use when authenticating against the npm registry. - -Warning: This should generally not be set via a command-line option. It is -safer to use a registry-provided authentication bearer token stored in the -~/.npmrc file by running \`npm login\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for access 1`] = ` -#### \`access\` - -* Default: 'restricted' for scoped packages, 'public' for unscoped packages -* Type: null, "restricted", or "public" - -When publishing scoped packages, the access level defaults to \`restricted\`. -If you want your scoped package to be publicly viewable (and installable) -set \`--access=public\`. The only valid values for \`access\` are \`public\` and -\`restricted\`. Unscoped packages _always_ have an access level of \`public\`. - -Note: Using the \`--access\` flag on the \`npm publish\` command will only set -the package access level on the initial publish of the package. Any -subsequent \`npm publish\` commands using the \`--access\` flag will not have an -effect to the access level. To make changes to the access level after the -initial publish use \`npm access\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for all 1`] = ` -#### \`all\` - -* Default: false -* Type: Boolean - -When running \`npm outdated\` and \`npm ls\`, setting \`--all\` will show all -outdated or installed packages, rather than only those directly depended -upon by the current project. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for allow-same-version 1`] = ` -#### \`allow-same-version\` - -* Default: false -* Type: Boolean - -Prevents throwing an error when \`npm version\` is used to set the new version -to the same value as the current version. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for also 1`] = ` -#### \`also\` - -* Default: null -* Type: null, "dev", or "development" -* DEPRECATED: Please use --include=dev instead. - -When set to \`dev\` or \`development\`, this is an alias for \`--include=dev\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for audit 1`] = ` -#### \`audit\` - -* Default: true -* Type: Boolean - -When "true" submit audit reports alongside the current npm command to the -default registry and all registries configured for scopes. See the -documentation for [\`npm audit\`](/commands/npm-audit) for details on what is -submitted. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for audit-level 1`] = ` -#### \`audit-level\` - -* Default: null -* Type: null, "info", "low", "moderate", "high", "critical", or "none" - -The minimum level of vulnerability for \`npm audit\` to exit with a non-zero -exit code. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for auth-type 1`] = ` -#### \`auth-type\` - -* Default: "legacy" -* Type: "legacy", "sso", "saml", or "oauth" -* DEPRECATED: This method of SSO/SAML/OAuth is deprecated and will be removed - in a future version of npm in favor of web-based login. - -What authentication strategy to use with \`adduser\`/\`login\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for before 1`] = ` -#### \`before\` - -* Default: null -* Type: null or Date - -If passed to \`npm install\`, will rebuild the npm tree such that only -versions that were available **on or before** the \`--before\` time get -installed. If there's no versions available for the current set of direct -dependencies, the command will error. - -If the requested version is a \`dist-tag\` and the given tag does not pass the -\`--before\` filter, the most recent version less than or equal to that tag -will be used. For example, \`foo@latest\` might install \`foo@1.2\` even though -\`latest\` is \`2.0\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for bin-links 1`] = ` -#### \`bin-links\` - -* Default: true -* Type: Boolean - -Tells npm to create symlinks (or \`.cmd\` shims on Windows) for package -executables. - -Set to false to have it not do this. This can be used to work around the -fact that some file systems don't support symlinks, even on ostensibly Unix -systems. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for browser 1`] = ` -#### \`browser\` - -* Default: OS X: \`"open"\`, Windows: \`"start"\`, Others: \`"xdg-open"\` -* Type: null, Boolean, or String - -The browser that is called by npm commands to open websites. - -Set to \`false\` to suppress browser behavior and instead print urls to -terminal. - -Set to \`true\` to use default system URL opener. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for ca 1`] = ` -#### \`ca\` - -* Default: null -* Type: null or String (can be set multiple times) - -The Certificate Authority signing certificate that is trusted for SSL -connections to the registry. Values should be in PEM format (Windows calls -it "Base-64 encoded X.509 (.CER)") with newlines replaced by the string -"\\n". For example: - -\`\`\`ini -ca="-----BEGIN CERTIFICATE-----\\nXXXX\\nXXXX\\n-----END CERTIFICATE-----" -\`\`\` - -Set to \`null\` to only allow "known" registrars, or to a specific CA cert to -trust only that specific signing authority. - -Multiple CAs can be trusted by specifying an array of certificates: - -\`\`\`ini -ca[]="..." -ca[]="..." -\`\`\` - -See also the \`strict-ssl\` config. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for cache 1`] = ` -#### \`cache\` - -* Default: Windows: \`%LocalAppData%\\npm-cache\`, Posix: \`~/.npm\` -* Type: Path - -The location of npm's cache directory. See [\`npm -cache\`](/commands/npm-cache) -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for cache-max 1`] = ` -#### \`cache-max\` - -* Default: Infinity -* Type: Number -* DEPRECATED: This option has been deprecated in favor of \`--prefer-online\` - -\`--cache-max=0\` is an alias for \`--prefer-online\` -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for cache-min 1`] = ` -#### \`cache-min\` - -* Default: 0 -* Type: Number -* DEPRECATED: This option has been deprecated in favor of \`--prefer-offline\`. - -\`--cache-min=9999 (or bigger)\` is an alias for \`--prefer-offline\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for cafile 1`] = ` -#### \`cafile\` - -* Default: null -* Type: Path - -A path to a file containing one or multiple Certificate Authority signing -certificates. Similar to the \`ca\` setting, but allows for multiple CA's, as -well as for the CA information to be stored in a file on disk. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for call 1`] = ` -#### \`call\` - -* Default: "" -* Type: String - -Optional companion option for \`npm exec\`, \`npx\` that allows for specifying a -custom command to be run along with the installed packages. - -\`\`\`bash -npm exec --package yo --package generator-node --call "yo node" -\`\`\` - -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for cert 1`] = ` -#### \`cert\` - -* Default: null -* Type: null or String - -A client certificate to pass when accessing the registry. Values should be -in PEM format (Windows calls it "Base-64 encoded X.509 (.CER)") with -newlines replaced by the string "\\n". For example: - -\`\`\`ini -cert="-----BEGIN CERTIFICATE-----\\nXXXX\\nXXXX\\n-----END CERTIFICATE-----" -\`\`\` - -It is _not_ the path to a certificate file (and there is no "certfile" -option). -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for ci-name 1`] = ` -#### \`ci-name\` - -* Default: The name of the current CI system, or \`null\` when not on a known CI - platform. -* Type: null or String - -The name of a continuous integration system. If not set explicitly, npm will -detect the current CI environment using the -[\`@npmcli/ci-detect\`](http://npm.im/@npmcli/ci-detect) module. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for cidr 1`] = ` -#### \`cidr\` - -* Default: null -* Type: null or String (can be set multiple times) - -This is a list of CIDR address to be used when configuring limited access -tokens with the \`npm token create\` command. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for color 1`] = ` -#### \`color\` - -* Default: true unless the NO_COLOR environ is set to something other than '0' -* Type: "always" or Boolean - -If false, never shows colors. If \`"always"\` then always shows colors. If -true, then only prints color codes for tty file descriptors. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for commit-hooks 1`] = ` -#### \`commit-hooks\` - -* Default: true -* Type: Boolean - -Run git commit hooks when using the \`npm version\` command. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for depth 1`] = ` -#### \`depth\` - -* Default: \`Infinity\` if \`--all\` is set, otherwise \`1\` -* Type: null or Number - -The depth to go when recursing packages for \`npm ls\`. - -If not set, \`npm ls\` will show only the immediate dependencies of the root -project. If \`--all\` is set, then npm will show all dependencies by default. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for description 1`] = ` -#### \`description\` - -* Default: true -* Type: Boolean - -Show the description in \`npm search\` -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for dev 1`] = ` -#### \`dev\` - -* Default: false -* Type: Boolean -* DEPRECATED: Please use --include=dev instead. - -Alias for \`--include=dev\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for diff 1`] = ` -#### \`diff\` - -* Default: -* Type: String (can be set multiple times) - -Define arguments to compare in \`npm diff\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for diff-dst-prefix 1`] = ` -#### \`diff-dst-prefix\` - -* Default: "b/" -* Type: String - -Destination prefix to be used in \`npm diff\` output. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for diff-ignore-all-space 1`] = ` -#### \`diff-ignore-all-space\` - -* Default: false -* Type: Boolean - -Ignore whitespace when comparing lines in \`npm diff\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for diff-name-only 1`] = ` -#### \`diff-name-only\` - -* Default: false -* Type: Boolean - -Prints only filenames when using \`npm diff\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for diff-no-prefix 1`] = ` -#### \`diff-no-prefix\` - -* Default: false -* Type: Boolean - -Do not show any source or destination prefix in \`npm diff\` output. - -Note: this causes \`npm diff\` to ignore the \`--diff-src-prefix\` and -\`--diff-dst-prefix\` configs. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for diff-src-prefix 1`] = ` -#### \`diff-src-prefix\` - -* Default: "a/" -* Type: String - -Source prefix to be used in \`npm diff\` output. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for diff-text 1`] = ` -#### \`diff-text\` - -* Default: false -* Type: Boolean - -Treat all files as text in \`npm diff\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for diff-unified 1`] = ` -#### \`diff-unified\` - -* Default: 3 -* Type: Number - -The number of lines of context to print in \`npm diff\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for dry-run 1`] = ` -#### \`dry-run\` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, \`install\`, \`update\`, -\`dedupe\`, \`uninstall\`, as well as \`pack\` and \`publish\`. - -Note: This is NOT honored by other network related commands, eg \`dist-tags\`, -\`owner\`, etc. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for editor 1`] = ` -#### \`editor\` - -* Default: The EDITOR or VISUAL environment variables, or 'notepad.exe' on - Windows, or 'vim' on Unix systems -* Type: String - -The command to run for \`npm edit\` and \`npm config edit\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for engine-strict 1`] = ` -#### \`engine-strict\` - -* Default: false -* Type: Boolean - -If set to true, then npm will stubbornly refuse to install (or even consider -installing) any package that claims to not be compatible with the current -Node.js version. - -This can be overridden by setting the \`--force\` flag. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for fetch-retries 1`] = ` -#### \`fetch-retries\` - -* Default: 2 -* Type: Number - -The "retries" config for the \`retry\` module to use when fetching packages -from the registry. - -npm will retry idempotent read requests to the registry in the case of -network failures or 5xx HTTP errors. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for fetch-retry-factor 1`] = ` -#### \`fetch-retry-factor\` - -* Default: 10 -* Type: Number - -The "factor" config for the \`retry\` module to use when fetching packages. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for fetch-retry-maxtimeout 1`] = ` -#### \`fetch-retry-maxtimeout\` - -* Default: 60000 (1 minute) -* Type: Number - -The "maxTimeout" config for the \`retry\` module to use when fetching -packages. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for fetch-retry-mintimeout 1`] = ` -#### \`fetch-retry-mintimeout\` - -* Default: 10000 (10 seconds) -* Type: Number - -The "minTimeout" config for the \`retry\` module to use when fetching -packages. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for fetch-timeout 1`] = ` -#### \`fetch-timeout\` - -* Default: 300000 (5 minutes) -* Type: Number - -The maximum amount of time to wait for HTTP requests to complete. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for force 1`] = ` -#### \`force\` - -* Default: false -* Type: Boolean - -Removes various protections against unfortunate side effects, common -mistakes, unnecessary performance degradation, and malicious input. - -* Allow clobbering non-npm files in global installs. -* Allow the \`npm version\` command to work on an unclean git repository. -* Allow deleting the cache folder with \`npm cache clean\`. -* Allow installing packages that have an \`engines\` declaration requiring a - different version of npm. -* Allow installing packages that have an \`engines\` declaration requiring a - different version of \`node\`, even if \`--engine-strict\` is enabled. -* Allow \`npm audit fix\` to install modules outside your stated dependency - range (including SemVer-major changes). -* Allow unpublishing all versions of a published package. -* Allow conflicting peerDependencies to be installed in the root project. -* Implicitly set \`--yes\` during \`npm init\`. -* Allow clobbering existing values in \`npm pkg\` - -If you don't have a clear idea of what you want to do, it is strongly -recommended that you do not use this option! -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for foreground-scripts 1`] = ` -#### \`foreground-scripts\` - -* Default: false -* Type: Boolean - -Run all build scripts (ie, \`preinstall\`, \`install\`, and \`postinstall\`) -scripts for installed packages in the foreground process, sharing standard -input, output, and error with the main npm process. - -Note that this will generally make installs run slower, and be much noisier, -but can be useful for debugging. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for format-package-lock 1`] = ` -#### \`format-package-lock\` - -* Default: true -* Type: Boolean - -Format \`package-lock.json\` or \`npm-shrinkwrap.json\` as a human readable -file. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for fund 1`] = ` -#### \`fund\` - -* Default: true -* Type: Boolean - -When "true" displays the message at the end of each \`npm install\` -acknowledging the number of dependencies looking for funding. See [\`npm -fund\`](/commands/npm-fund) for details. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for git 1`] = ` -#### \`git\` - -* Default: "git" -* Type: String - -The command to use for git commands. If git is installed on the computer, -but is not in the \`PATH\`, then set this to the full path to the git binary. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for git-tag-version 1`] = ` -#### \`git-tag-version\` - -* Default: true -* Type: Boolean - -Tag the commit when using the \`npm version\` command. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for global 1`] = ` -#### \`global\` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the \`prefix\` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the \`{prefix}/lib/node_modules\` folder, instead - of the current working directory. -* bin files are linked to \`{prefix}/bin\` -* man pages are linked to \`{prefix}/share/man\` -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for global-style 1`] = ` -#### \`global-style\` - -* Default: false -* Type: Boolean - -Causes npm to install the package into your local \`node_modules\` folder with -the same layout it uses with the global \`node_modules\` folder. Only your -direct dependencies will show in \`node_modules\` and everything they depend -on will be flattened in their \`node_modules\` folders. This obviously will -eliminate some deduping. If used with \`legacy-bundling\`, \`legacy-bundling\` -will be preferred. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for globalconfig 1`] = ` -#### \`globalconfig\` - -* Default: The global --prefix setting plus 'etc/npmrc'. For example, - '/usr/local/etc/npmrc' -* Type: Path - -The config file to read for global config options. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for heading 1`] = ` -#### \`heading\` - -* Default: "npm" -* Type: String - -The string that starts all the debugging log output. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for https-proxy 1`] = ` -#### \`https-proxy\` - -* Default: null -* Type: null or URL - -A proxy to use for outgoing https requests. If the \`HTTPS_PROXY\` or -\`https_proxy\` or \`HTTP_PROXY\` or \`http_proxy\` environment variables are set, -proxy settings will be honored by the underlying \`make-fetch-happen\` -library. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for if-present 1`] = ` -#### \`if-present\` - -* 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 -running scripts that may only apply for some builds in an otherwise generic -CI setup. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for ignore-scripts 1`] = ` -#### \`ignore-scripts\` - -* Default: false -* Type: Boolean - -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. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for include 1`] = ` -#### \`include\` - -* Default: -* Type: "prod", "dev", "optional", or "peer" (can be set multiple times) - -Option that allows for defining which types of dependencies to install. - -This is the inverse of \`--omit=<type>\`. - -Dependency types specified in \`--include\` will not be omitted, regardless of -the order in which omit/include are specified on the command-line. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for include-staged 1`] = ` -#### \`include-staged\` - -* Default: false -* Type: Boolean - -Allow installing "staged" published packages, as defined by [npm RFC PR -#92](https://github.com/npm/rfcs/pull/92). - -This is experimental, and not implemented by the npm public registry. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for include-workspace-root 1`] = ` -#### \`include-workspace-root\` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the \`workspace\` config, or -all workspaces via the \`workspaces\` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init-author-email 1`] = ` -#### \`init-author-email\` - -* Default: "" -* Type: String - -The value \`npm init\` should use by default for the package author's email. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init-author-name 1`] = ` -#### \`init-author-name\` - -* Default: "" -* Type: String - -The value \`npm init\` should use by default for the package author's name. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init-author-url 1`] = ` -#### \`init-author-url\` - -* Default: "" -* Type: "" or URL - -The value \`npm init\` should use by default for the package author's -homepage. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init-license 1`] = ` -#### \`init-license\` - -* Default: "ISC" -* Type: String - -The value \`npm init\` should use by default for the package license. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init-module 1`] = ` -#### \`init-module\` - -* Default: "~/.npm-init.js" -* Type: Path - -A module that will be loaded by the \`npm init\` command. See the -documentation for the -[init-package-json](https://github.com/npm/init-package-json) module for -more information, or [npm init](/commands/npm-init). -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init-version 1`] = ` -#### \`init-version\` - -* Default: "1.0.0" -* Type: SemVer string - -The value that \`npm init\` should use by default for the package version -number, if not already set in package.json. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init.author.email 1`] = ` -#### \`init.author.email\` - -* Default: "" -* Type: String -* DEPRECATED: Use \`--init-author-email\` instead. - -Alias for \`--init-author-email\` -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init.author.name 1`] = ` -#### \`init.author.name\` - -* Default: "" -* Type: String -* DEPRECATED: Use \`--init-author-name\` instead. - -Alias for \`--init-author-name\` -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init.author.url 1`] = ` -#### \`init.author.url\` - -* Default: "" -* Type: "" or URL -* DEPRECATED: Use \`--init-author-url\` instead. - -Alias for \`--init-author-url\` -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init.license 1`] = ` -#### \`init.license\` - -* Default: "ISC" -* Type: String -* DEPRECATED: Use \`--init-license\` instead. - -Alias for \`--init-license\` -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init.module 1`] = ` -#### \`init.module\` - -* Default: "~/.npm-init.js" -* Type: Path -* DEPRECATED: Use \`--init-module\` instead. - -Alias for \`--init-module\` -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for init.version 1`] = ` -#### \`init.version\` - -* Default: "1.0.0" -* Type: SemVer string -* DEPRECATED: Use \`--init-version\` instead. - -Alias for \`--init-version\` -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for json 1`] = ` -#### \`json\` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In \`npm pkg set\` it enables parsing set values with JSON.parse() before - saving them to your \`package.json\`. - -Not supported by all npm commands. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for key 1`] = ` -#### \`key\` - -* Default: null -* Type: null or String - -A client key to pass when accessing the registry. Values should be in PEM -format with newlines replaced by the string "\\n". For example: - -\`\`\`ini -key="-----BEGIN PRIVATE KEY-----\\nXXXX\\nXXXX\\n-----END PRIVATE KEY-----" -\`\`\` - -It is _not_ the path to a key file (and there is no "keyfile" option). -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for legacy-bundling 1`] = ` -#### \`legacy-bundling\` - -* Default: false -* Type: Boolean - -Causes npm to install the package such that versions of npm prior to 1.4, -such as the one included with node 0.8, can install the package. This -eliminates all automatic deduping. If used with \`global-style\` this option -will be preferred. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for legacy-peer-deps 1`] = ` -#### \`legacy-peer-deps\` - -* Default: false -* Type: Boolean - -Causes npm to completely ignore \`peerDependencies\` when building a package -tree, as in npm versions 3 through 6. - -If a package cannot be installed because of overly strict \`peerDependencies\` -that collide, it provides a way to move forward resolving the situation. - -This differs from \`--omit=peer\`, in that \`--omit=peer\` will avoid unpacking -\`peerDependencies\` on disk, but will still design a tree such that -\`peerDependencies\` _could_ be unpacked in a correct place. - -Use of \`legacy-peer-deps\` is not recommended, as it will not enforce the -\`peerDependencies\` contract that meta-dependencies may rely on. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for link 1`] = ` -#### \`link\` - -* Default: false -* Type: Boolean - -Used with \`npm ls\`, limiting output to only those packages that are linked. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for local-address 1`] = ` -#### \`local-address\` - -* Default: null -* Type: IP Address - -The IP address of the local interface to use when making connections to the -npm registry. Must be IPv4 in versions of Node prior to 0.12. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for location 1`] = ` -#### \`location\` - -* Default: "user" unless \`--global\` is passed, which will also set this value - to "global" -* Type: "global", "user", or "project" - -When passed to \`npm config\` this refers to which config file to use. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for lockfile-version 1`] = ` -#### \`lockfile-version\` - -* Default: Version 2 if no lockfile or current lockfile version less than or - equal to 2, otherwise maintain current lockfile version -* Type: null, 1, 2, 3, "1", "2", or "3" - -Set the lockfile format version to be used in package-lock.json and -npm-shrinkwrap-json files. Possible options are: - -1: The lockfile version used by npm versions 5 and 6. Lacks some data that -is used during the install, resulting in slower and possibly less -deterministic installs. Prevents lockfile churn when interoperating with -older npm versions. - -2: The default lockfile version used by npm version 7. Includes both the -version 1 lockfile data and version 3 lockfile data, for maximum determinism -and interoperability, at the expense of more bytes on disk. - -3: Only the new lockfile information introduced in npm version 7. Smaller on -disk than lockfile version 2, but not interoperable with older npm versions. -Ideal if all users are on npm version 7 and higher. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for loglevel 1`] = ` -#### \`loglevel\` - -* Default: "notice" -* Type: "silent", "error", "warn", "notice", "http", "timing", "info", - "verbose", or "silly" - -What level of logs to report. All logs are written to a debug log, with the -path to that file printed if the execution of a command fails. - -Any logs of a higher level than the setting are shown. The default is -"notice". - -See also the \`foreground-scripts\` config. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for logs-max 1`] = ` -#### \`logs-max\` - -* Default: 10 -* Type: Number - -The maximum number of log files to store. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for long 1`] = ` -#### \`long\` - -* Default: false -* Type: Boolean - -Show extended information in \`ls\`, \`search\`, and \`help-search\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for maxsockets 1`] = ` -#### \`maxsockets\` - -* Default: 15 -* Type: Number - -The maximum number of connections to use per origin (protocol/host/port -combination). -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for message 1`] = ` -#### \`message\` - -* Default: "%s" -* Type: String - -Commit message which is used by \`npm version\` when creating version commit. - -Any "%s" in the message will be replaced with the version number. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for node-options 1`] = ` -#### \`node-options\` - -* Default: null -* Type: null or String - -Options to pass through to Node.js via the \`NODE_OPTIONS\` environment -variable. This does not impact how npm itself is executed but it does impact -how lifecycle scripts are called. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for node-version 1`] = ` -#### \`node-version\` - -* Default: Node.js \`process.version\` value -* Type: SemVer string - -The node version to use when checking a package's \`engines\` setting. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for noproxy 1`] = ` -#### \`noproxy\` - -* Default: The value of the NO_PROXY environment variable -* Type: String (can be set multiple times) - -Domain extensions that should bypass any proxies. - -Also accepts a comma-delimited string. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for npm-version 1`] = ` -#### \`npm-version\` - -* Default: Output of \`npm --version\` -* Type: SemVer string - -The npm version to use when checking a package's \`engines\` setting. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for offline 1`] = ` -#### \`offline\` - -* Default: false -* Type: Boolean - -Force offline mode: no network requests will be done during install. To -allow the CLI to fill in missing cache data, see \`--prefer-offline\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for omit 1`] = ` -#### \`omit\` - -* Default: 'dev' if the \`NODE_ENV\` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -\`package-lock.json\` or \`npm-shrinkwrap.json\` file. They are just not -physically installed on disk. - -If a package type appears in both the \`--include\` and \`--omit\` lists, then -it will be included. - -If the resulting omit list includes \`'dev'\`, then the \`NODE_ENV\` environment -variable will be set to \`'production'\` for all lifecycle scripts. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for only 1`] = ` -#### \`only\` - -* Default: null -* Type: null, "prod", or "production" -* DEPRECATED: Use \`--omit=dev\` to omit dev dependencies from the install. - -When set to \`prod\` or \`production\`, this is an alias for \`--omit=dev\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for optional 1`] = ` -#### \`optional\` - -* Default: null -* Type: null or Boolean -* DEPRECATED: Use \`--omit=optional\` to exclude optional dependencies, or - \`--include=optional\` to include them. - -Default value does install optional deps unless otherwise omitted. - -Alias for --include=optional or --omit=optional -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for otp 1`] = ` -#### \`otp\` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with \`npm access\`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for pack-destination 1`] = ` -#### \`pack-destination\` - -* Default: "." -* Type: String - -Directory in which \`npm pack\` will save tarballs. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for package 1`] = ` -#### \`package\` - -* Default: -* Type: String (can be set multiple times) - -The package to install for [\`npm exec\`](/commands/npm-exec) -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for package-lock 1`] = ` -#### \`package-lock\` - -* Default: true -* Type: Boolean - -If set to false, then ignore \`package-lock.json\` files when installing. This -will also prevent _writing_ \`package-lock.json\` if \`save\` is true. - -When package package-locks are disabled, automatic pruning of extraneous -modules will also be disabled. To remove extraneous modules with -package-locks disabled use \`npm prune\`. - -This configuration does not affect \`npm ci\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for package-lock-only 1`] = ` -#### \`package-lock-only\` - -* Default: false -* Type: Boolean - -If set to true, the current operation will only use the \`package-lock.json\`, -ignoring \`node_modules\`. - -For \`update\` this means only the \`package-lock.json\` will be updated, -instead of checking \`node_modules\` and downloading dependencies. - -For \`list\` this means the output will be based on the tree described by the -\`package-lock.json\`, rather than the contents of \`node_modules\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for parseable 1`] = ` -#### \`parseable\` - -* Default: false -* Type: Boolean - -Output parseable results from commands that write to standard output. For -\`npm search\`, this will be tab-separated table format. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for prefer-offline 1`] = ` -#### \`prefer-offline\` - -* Default: false -* Type: Boolean - -If true, staleness checks for cached data will be bypassed, but missing data -will be requested from the server. To force full offline mode, use -\`--offline\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for prefer-online 1`] = ` -#### \`prefer-online\` - -* Default: false -* Type: Boolean - -If true, staleness checks for cached data will be forced, making the CLI -look for updates immediately even for fresh package data. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for prefix 1`] = ` -#### \`prefix\` - -* Default: In global mode, the folder where the node executable is installed. - In local mode, the nearest parent folder containing either a package.json - file or a node_modules folder. -* Type: Path - -The location to install global items. If set on the command line, then it -forces non-global commands to run in the specified folder. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for preid 1`] = ` -#### \`preid\` - -* Default: "" -* Type: String - -The "prerelease identifier" to use as a prefix for the "prerelease" part of -a semver. Like the \`rc\` in \`1.2.0-rc.8\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for production 1`] = ` -#### \`production\` - -* Default: null -* Type: null or Boolean -* DEPRECATED: Use \`--omit=dev\` instead. - -Alias for \`--omit=dev\` -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for progress 1`] = ` -#### \`progress\` - -* Default: \`true\` unless running in a known CI system -* Type: Boolean - -When set to \`true\`, npm will display a progress bar during time intensive -operations, if \`process.stderr\` is a TTY. - -Set to \`false\` to suppress the progress bar. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for proxy 1`] = ` -#### \`proxy\` - -* Default: null -* Type: null, false, or URL - -A proxy to use for outgoing http requests. If the \`HTTP_PROXY\` or -\`http_proxy\` environment variables are set, proxy settings will be honored -by the underlying \`request\` library. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for read-only 1`] = ` -#### \`read-only\` - -* Default: false -* Type: Boolean - -This is used to mark a token as unable to publish when configuring limited -access tokens with the \`npm token create\` command. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for rebuild-bundle 1`] = ` -#### \`rebuild-bundle\` - -* Default: true -* Type: Boolean - -Rebuild bundled dependencies after installation. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for registry 1`] = ` -#### \`registry\` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for save 1`] = ` -#### \`save\` - -* Default: \`true\` unless when using \`npm update\` or \`npm dedupe\` where it - defaults to \`false\` -* Type: Boolean - -Save installed packages to a \`package.json\` file as dependencies. - -When used with the \`npm rm\` command, removes the dependency from -\`package.json\`. - -Will also prevent writing to \`package-lock.json\` if set to \`false\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for save-bundle 1`] = ` -#### \`save-bundle\` - -* Default: false -* Type: Boolean - -If a package would be saved at install time by the use of \`--save\`, -\`--save-dev\`, or \`--save-optional\`, then also put it in the -\`bundleDependencies\` list. - -Ignored if \`--save-peer\` is set, since peerDependencies cannot be bundled. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for save-dev 1`] = ` -#### \`save-dev\` - -* Default: false -* Type: Boolean - -Save installed packages to a package.json file as \`devDependencies\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for save-exact 1`] = ` -#### \`save-exact\` - -* Default: false -* Type: Boolean - -Dependencies saved to package.json will be configured with an exact version -rather than using npm's default semver range operator. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for save-optional 1`] = ` -#### \`save-optional\` - -* Default: false -* Type: Boolean - -Save installed packages to a package.json file as \`optionalDependencies\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for save-peer 1`] = ` -#### \`save-peer\` - -* Default: false -* Type: Boolean - -Save installed packages to a package.json file as \`peerDependencies\` -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for save-prefix 1`] = ` -#### \`save-prefix\` - -* Default: "^" -* Type: String - -Configure how versions of packages installed to a package.json file via -\`--save\` or \`--save-dev\` get prefixed. - -For example if a package has version \`1.2.3\`, by default its version is set -to \`^1.2.3\` which allows minor upgrades for that package, but after \`npm -config set save-prefix='~'\` it would be set to \`~1.2.3\` which only allows -patch upgrades. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for save-prod 1`] = ` -#### \`save-prod\` - -* Default: false -* Type: Boolean - -Save installed packages into \`dependencies\` specifically. This is useful if -a package already exists in \`devDependencies\` or \`optionalDependencies\`, but -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. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for scope 1`] = ` -#### \`scope\` - -* Default: the scope of the current project, if any, or "" -* Type: String - -Associate an operation with a scope for a scoped registry. - -Useful when logging in to or out of a private registry: - -\`\`\` -# log in, linking the scope to the custom registry -npm login --scope=@mycorp --registry=https://registry.mycorp.com - -# log out, removing the link and the auth token -npm logout --scope=@mycorp -\`\`\` - -This will cause \`@mycorp\` to be mapped to the registry for future -installation of packages specified according to the pattern -\`@mycorp/package\`. - -This will also cause \`npm init\` to create a scoped package. - -\`\`\` -# accept all defaults, and create a package named "@foo/whatever", -# instead of just named "whatever" -npm init --scope=@foo --yes -\`\`\` - -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for script-shell 1`] = ` -#### \`script-shell\` - -* Default: '/bin/sh' on POSIX systems, 'cmd.exe' on Windows -* Type: null or String - -The shell to use for scripts run with the \`npm exec\`, \`npm run\` and \`npm -init <pkg>\` commands. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for searchexclude 1`] = ` -#### \`searchexclude\` - -* Default: "" -* Type: String - -Space-separated options that limit the results from search. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for searchlimit 1`] = ` -#### \`searchlimit\` - -* Default: 20 -* Type: Number - -Number of items to limit search results to. Will not apply at all to legacy -searches. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for searchopts 1`] = ` -#### \`searchopts\` - -* Default: "" -* Type: String - -Space-separated options that are always passed to search. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for searchstaleness 1`] = ` -#### \`searchstaleness\` - -* Default: 900 -* Type: Number - -The age of the cache, in seconds, before another registry request is made if -using legacy search endpoint. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for shell 1`] = ` -#### \`shell\` - -* Default: SHELL environment variable, or "bash" on Posix, or "cmd.exe" on - Windows -* Type: String - -The shell to run for the \`npm explore\` command. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for shrinkwrap 1`] = ` -#### \`shrinkwrap\` - -* Default: true -* Type: Boolean -* DEPRECATED: Use the --package-lock setting instead. - -Alias for --package-lock -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for sign-git-commit 1`] = ` -#### \`sign-git-commit\` - -* Default: false -* Type: Boolean - -If set to true, then the \`npm version\` command will commit the new package -version using \`-S\` to add a signature. - -Note that git requires you to have set up GPG keys in your git configs for -this to work properly. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for sign-git-tag 1`] = ` -#### \`sign-git-tag\` - -* Default: false -* Type: Boolean - -If set to true, then the \`npm version\` command will tag the version using -\`-s\` to add a signature. - -Note that git requires you to have set up GPG keys in your git configs for -this to work properly. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for sso-poll-frequency 1`] = ` -#### \`sso-poll-frequency\` - -* Default: 500 -* Type: Number -* DEPRECATED: The --auth-type method of SSO/SAML/OAuth will be removed in a - future version of npm in favor of web-based login. - -When used with SSO-enabled \`auth-type\`s, configures how regularly the -registry should be polled while the user is completing authentication. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for sso-type 1`] = ` -#### \`sso-type\` - -* Default: "oauth" -* Type: null, "oauth", or "saml" -* DEPRECATED: The --auth-type method of SSO/SAML/OAuth will be removed in a - future version of npm in favor of web-based login. - -If \`--auth-type=sso\`, the type of SSO type to use. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for strict-peer-deps 1`] = ` -#### \`strict-peer-deps\` - -* Default: false -* Type: Boolean - -If set to \`true\`, and \`--legacy-peer-deps\` is not set, then _any_ -conflicting \`peerDependencies\` will be treated as an install failure, even -if npm could reasonably guess the appropriate resolution based on non-peer -dependency relationships. - -By default, conflicting \`peerDependencies\` deep in the dependency graph will -be resolved using the nearest non-peer dependency specification, even if -doing so will result in some packages receiving a peer dependency outside -the range set in their package's \`peerDependencies\` object. - -When such and override is performed, a warning is printed, explaining the -conflict and the packages involved. If \`--strict-peer-deps\` is set, then -this warning is treated as a failure. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for strict-ssl 1`] = ` -#### \`strict-ssl\` - -* Default: true -* Type: Boolean - -Whether or not to do SSL key validation when making requests to the registry -via https. - -See also the \`ca\` config. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for tag 1`] = ` -#### \`tag\` - -* Default: "latest" -* Type: String - -If you ask npm to install a package and don't tell it a specific version, -then it will install the specified tag. - -Also the tag that is added to the package@version specified by the \`npm tag\` -command, if no explicit tag is given. - -When used by the \`npm diff\` command, this is the tag used to fetch the -tarball that will be compared with the local files by default. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for tag-version-prefix 1`] = ` -#### \`tag-version-prefix\` - -* Default: "v" -* Type: String - -If set, alters the prefix used when tagging a new version when performing a -version increment using \`npm-version\`. To remove the prefix altogether, set -it to the empty string: \`""\`. - -Because other tools may rely on the convention that npm version tags look -like \`v1.0.0\`, _only use this property if it is absolutely necessary_. In -particular, use care when overriding this setting for public packages. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for timing 1`] = ` -#### \`timing\` - -* Default: false -* Type: Boolean - -If true, writes an \`npm-debug\` log to \`_logs\` and timing information to -\`_timing.json\`, both in your cache, even if the command completes -successfully. \`_timing.json\` is a newline delimited list of JSON objects. - -You can quickly view it with this [json](https://npm.im/json) command line: -\`npm exec -- json -g < ~/.npm/_timing.json\`. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for tmp 1`] = ` -#### \`tmp\` - -* Default: The value returned by the Node.js \`os.tmpdir()\` method - <https://nodejs.org/api/os.html#os_os_tmpdir> -* Type: Path -* DEPRECATED: This setting is no longer used. npm stores temporary files in a - special location in the cache, and they are managed by - [\`cacache\`](http://npm.im/cacache). - -Historically, the location where temporary files were stored. No longer -relevant. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for umask 1`] = ` -#### \`umask\` - -* Default: 0 -* Type: Octal numeric string in range 0000..0777 (0..511) - -The "umask" value to use when setting the file creation mode on files and -folders. - -Folders and executables are given a mode which is \`0o777\` masked against -this value. Other files are given a mode which is \`0o666\` masked against -this value. - -Note that the underlying system will _also_ apply its own umask value to -files and folders that are created, and npm does not circumvent this, but -rather adds the \`--umask\` config to it. - -Thus, the effective default umask value on most POSIX systems is 0o22, -meaning that folders and executables are created with a mode of 0o755 and -other files are created with a mode of 0o644. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for unicode 1`] = ` -#### \`unicode\` - -* Default: false on windows, true on mac/unix systems with a unicode locale, - as defined by the \`LC_ALL\`, \`LC_CTYPE\`, or \`LANG\` environment variables. -* Type: Boolean - -When set to true, npm uses unicode characters in the tree output. When -false, it uses ascii characters instead of unicode glyphs. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for update-notifier 1`] = ` -#### \`update-notifier\` - -* Default: true -* Type: Boolean - -Set to false to suppress the update notification when using an older version -of npm than the latest. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for usage 1`] = ` -#### \`usage\` - -* Default: false -* Type: Boolean - -Show short usage output about the command specified. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for user-agent 1`] = ` -#### \`user-agent\` - -* Default: "npm/{npm-version} node/{node-version} {platform} {arch} - workspaces/{workspaces} {ci}" -* Type: String - -Sets the User-Agent request header. The following fields are replaced with -their actual counterparts: - -* \`{npm-version}\` - The npm version in use -* \`{node-version}\` - The Node.js version in use -* \`{platform}\` - The value of \`process.platform\` -* \`{arch}\` - The value of \`process.arch\` -* \`{workspaces}\` - Set to \`true\` if the \`workspaces\` or \`workspace\` options - are set. -* \`{ci}\` - The value of the \`ci-name\` config, if set, prefixed with \`ci/\`, or - an empty string if \`ci-name\` is empty. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for userconfig 1`] = ` -#### \`userconfig\` - -* Default: "~/.npmrc" -* Type: Path - -The location of user-level configuration settings. - -This may be overridden by the \`npm_config_userconfig\` environment variable -or the \`--userconfig\` command line option, but may _not_ be overridden by -settings in the \`globalconfig\` file. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for version 1`] = ` -#### \`version\` - -* Default: false -* Type: Boolean - -If true, output the npm version and exit successfully. - -Only relevant when specified explicitly on the command line. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for versions 1`] = ` -#### \`versions\` - -* Default: false -* Type: Boolean - -If true, output the npm version as well as node's \`process.versions\` map and -the version in the current working directory's \`package.json\` file if one -exists, and exit successfully. - -Only relevant when specified explicitly on the command line. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for viewer 1`] = ` -#### \`viewer\` - -* Default: "man" on Posix, "browser" on Windows -* Type: String - -The program to use to view help content. - -Set to \`"browser"\` to view html help content in the default web browser. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for which 1`] = ` -#### \`which\` - -* Default: null -* Type: null or Number - -If there are multiple funding sources, which 1-indexed source URL to open. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for workspace 1`] = ` -#### \`workspace\` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the \`workspace\` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the \`npm init\` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for workspaces 1`] = ` -#### \`workspaces\` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like \`install\` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the \`node_modules\` tree (install, update, etc.) -will link workspaces into the \`node_modules\` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the \`workspace\` config. - -This value is not exported to the environment for child processes. -` - -exports[`test/lib/utils/config/definitions.js TAP > config description for yes 1`] = ` -#### \`yes\` - -* Default: null -* Type: null or Boolean - -Automatically answer "yes" to any prompts that npm might print on the -command line. -` diff --git a/tap-snapshots/test/lib/utils/config/describe-all.js.test.cjs b/tap-snapshots/test/lib/utils/config/describe-all.js.test.cjs deleted file mode 100644 index 27b8278..0000000 --- a/tap-snapshots/test/lib/utils/config/describe-all.js.test.cjs +++ /dev/null @@ -1,1914 +0,0 @@ -/* IMPORTANT - * This snapshot file is auto-generated, but designed for humans. - * It should be checked into source control and tracked carefully. - * Re-generate by setting TAP_SNAPSHOT=1 and running tests. - * Make sure to inspect the output below. Do not ignore changes! - */ -'use strict' -exports[`test/lib/utils/config/describe-all.js TAP > must match snapshot 1`] = ` -#### \`_auth\` - -* Default: null -* Type: null or String - -A basic-auth string to use when authenticating against the npm registry. - -Warning: This should generally not be set via a command-line option. It is -safer to use a registry-provided authentication bearer token stored in the -~/.npmrc file by running \`npm login\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`access\` - -* Default: 'restricted' for scoped packages, 'public' for unscoped packages -* Type: null, "restricted", or "public" - -When publishing scoped packages, the access level defaults to \`restricted\`. -If you want your scoped package to be publicly viewable (and installable) -set \`--access=public\`. The only valid values for \`access\` are \`public\` and -\`restricted\`. Unscoped packages _always_ have an access level of \`public\`. - -Note: Using the \`--access\` flag on the \`npm publish\` command will only set -the package access level on the initial publish of the package. Any -subsequent \`npm publish\` commands using the \`--access\` flag will not have an -effect to the access level. To make changes to the access level after the -initial publish use \`npm access\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`all\` - -* Default: false -* Type: Boolean - -When running \`npm outdated\` and \`npm ls\`, setting \`--all\` will show all -outdated or installed packages, rather than only those directly depended -upon by the current project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`allow-same-version\` - -* Default: false -* Type: Boolean - -Prevents throwing an error when \`npm version\` is used to set the new version -to the same value as the current version. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`audit\` - -* Default: true -* Type: Boolean - -When "true" submit audit reports alongside the current npm command to the -default registry and all registries configured for scopes. See the -documentation for [\`npm audit\`](/commands/npm-audit) for details on what is -submitted. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`audit-level\` - -* Default: null -* Type: null, "info", "low", "moderate", "high", "critical", or "none" - -The minimum level of vulnerability for \`npm audit\` to exit with a non-zero -exit code. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`before\` - -* Default: null -* Type: null or Date - -If passed to \`npm install\`, will rebuild the npm tree such that only -versions that were available **on or before** the \`--before\` time get -installed. If there's no versions available for the current set of direct -dependencies, the command will error. - -If the requested version is a \`dist-tag\` and the given tag does not pass the -\`--before\` filter, the most recent version less than or equal to that tag -will be used. For example, \`foo@latest\` might install \`foo@1.2\` even though -\`latest\` is \`2.0\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`bin-links\` - -* Default: true -* Type: Boolean - -Tells npm to create symlinks (or \`.cmd\` shims on Windows) for package -executables. - -Set to false to have it not do this. This can be used to work around the -fact that some file systems don't support symlinks, even on ostensibly Unix -systems. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`browser\` - -* Default: OS X: \`"open"\`, Windows: \`"start"\`, Others: \`"xdg-open"\` -* Type: null, Boolean, or String - -The browser that is called by npm commands to open websites. - -Set to \`false\` to suppress browser behavior and instead print urls to -terminal. - -Set to \`true\` to use default system URL opener. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`ca\` - -* Default: null -* Type: null or String (can be set multiple times) - -The Certificate Authority signing certificate that is trusted for SSL -connections to the registry. Values should be in PEM format (Windows calls -it "Base-64 encoded X.509 (.CER)") with newlines replaced by the string -"\\n". For example: - -\`\`\`ini -ca="-----BEGIN CERTIFICATE-----\\nXXXX\\nXXXX\\n-----END CERTIFICATE-----" -\`\`\` - -Set to \`null\` to only allow "known" registrars, or to a specific CA cert to -trust only that specific signing authority. - -Multiple CAs can be trusted by specifying an array of certificates: - -\`\`\`ini -ca[]="..." -ca[]="..." -\`\`\` - -See also the \`strict-ssl\` config. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`cache\` - -* Default: Windows: \`%LocalAppData%\\npm-cache\`, Posix: \`~/.npm\` -* Type: Path - -The location of npm's cache directory. See [\`npm -cache\`](/commands/npm-cache) - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`cafile\` - -* Default: null -* Type: Path - -A path to a file containing one or multiple Certificate Authority signing -certificates. Similar to the \`ca\` setting, but allows for multiple CA's, as -well as for the CA information to be stored in a file on disk. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`call\` - -* Default: "" -* Type: String - -Optional companion option for \`npm exec\`, \`npx\` that allows for specifying a -custom command to be run along with the installed packages. - -\`\`\`bash -npm exec --package yo --package generator-node --call "yo node" -\`\`\` - - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`cert\` - -* Default: null -* Type: null or String - -A client certificate to pass when accessing the registry. Values should be -in PEM format (Windows calls it "Base-64 encoded X.509 (.CER)") with -newlines replaced by the string "\\n". For example: - -\`\`\`ini -cert="-----BEGIN CERTIFICATE-----\\nXXXX\\nXXXX\\n-----END CERTIFICATE-----" -\`\`\` - -It is _not_ the path to a certificate file (and there is no "certfile" -option). - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`ci-name\` - -* Default: The name of the current CI system, or \`null\` when not on a known CI - platform. -* Type: null or String - -The name of a continuous integration system. If not set explicitly, npm will -detect the current CI environment using the -[\`@npmcli/ci-detect\`](http://npm.im/@npmcli/ci-detect) module. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`cidr\` - -* Default: null -* Type: null or String (can be set multiple times) - -This is a list of CIDR address to be used when configuring limited access -tokens with the \`npm token create\` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`color\` - -* Default: true unless the NO_COLOR environ is set to something other than '0' -* Type: "always" or Boolean - -If false, never shows colors. If \`"always"\` then always shows colors. If -true, then only prints color codes for tty file descriptors. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`commit-hooks\` - -* Default: true -* Type: Boolean - -Run git commit hooks when using the \`npm version\` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`depth\` - -* Default: \`Infinity\` if \`--all\` is set, otherwise \`1\` -* Type: null or Number - -The depth to go when recursing packages for \`npm ls\`. - -If not set, \`npm ls\` will show only the immediate dependencies of the root -project. If \`--all\` is set, then npm will show all dependencies by default. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`description\` - -* Default: true -* Type: Boolean - -Show the description in \`npm search\` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`diff\` - -* Default: -* Type: String (can be set multiple times) - -Define arguments to compare in \`npm diff\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`diff-dst-prefix\` - -* Default: "b/" -* Type: String - -Destination prefix to be used in \`npm diff\` output. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`diff-ignore-all-space\` - -* Default: false -* Type: Boolean - -Ignore whitespace when comparing lines in \`npm diff\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`diff-name-only\` - -* Default: false -* Type: Boolean - -Prints only filenames when using \`npm diff\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`diff-no-prefix\` - -* Default: false -* Type: Boolean - -Do not show any source or destination prefix in \`npm diff\` output. - -Note: this causes \`npm diff\` to ignore the \`--diff-src-prefix\` and -\`--diff-dst-prefix\` configs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`diff-src-prefix\` - -* Default: "a/" -* Type: String - -Source prefix to be used in \`npm diff\` output. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`diff-text\` - -* Default: false -* Type: Boolean - -Treat all files as text in \`npm diff\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`diff-unified\` - -* Default: 3 -* Type: Number - -The number of lines of context to print in \`npm diff\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`dry-run\` - -* Default: false -* Type: Boolean - -Indicates that you don't want npm to make any changes and that it should -only report what it would have done. This can be passed into any of the -commands that modify your local installation, eg, \`install\`, \`update\`, -\`dedupe\`, \`uninstall\`, as well as \`pack\` and \`publish\`. - -Note: This is NOT honored by other network related commands, eg \`dist-tags\`, -\`owner\`, etc. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`editor\` - -* Default: The EDITOR or VISUAL environment variables, or 'notepad.exe' on - Windows, or 'vim' on Unix systems -* Type: String - -The command to run for \`npm edit\` and \`npm config edit\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`engine-strict\` - -* Default: false -* Type: Boolean - -If set to true, then npm will stubbornly refuse to install (or even consider -installing) any package that claims to not be compatible with the current -Node.js version. - -This can be overridden by setting the \`--force\` flag. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`fetch-retries\` - -* Default: 2 -* Type: Number - -The "retries" config for the \`retry\` module to use when fetching packages -from the registry. - -npm will retry idempotent read requests to the registry in the case of -network failures or 5xx HTTP errors. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`fetch-retry-factor\` - -* Default: 10 -* Type: Number - -The "factor" config for the \`retry\` module to use when fetching packages. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`fetch-retry-maxtimeout\` - -* Default: 60000 (1 minute) -* Type: Number - -The "maxTimeout" config for the \`retry\` module to use when fetching -packages. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`fetch-retry-mintimeout\` - -* Default: 10000 (10 seconds) -* Type: Number - -The "minTimeout" config for the \`retry\` module to use when fetching -packages. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`fetch-timeout\` - -* Default: 300000 (5 minutes) -* Type: Number - -The maximum amount of time to wait for HTTP requests to complete. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`force\` - -* Default: false -* Type: Boolean - -Removes various protections against unfortunate side effects, common -mistakes, unnecessary performance degradation, and malicious input. - -* Allow clobbering non-npm files in global installs. -* Allow the \`npm version\` command to work on an unclean git repository. -* Allow deleting the cache folder with \`npm cache clean\`. -* Allow installing packages that have an \`engines\` declaration requiring a - different version of npm. -* Allow installing packages that have an \`engines\` declaration requiring a - different version of \`node\`, even if \`--engine-strict\` is enabled. -* Allow \`npm audit fix\` to install modules outside your stated dependency - range (including SemVer-major changes). -* Allow unpublishing all versions of a published package. -* Allow conflicting peerDependencies to be installed in the root project. -* Implicitly set \`--yes\` during \`npm init\`. -* Allow clobbering existing values in \`npm pkg\` - -If you don't have a clear idea of what you want to do, it is strongly -recommended that you do not use this option! - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`foreground-scripts\` - -* Default: false -* Type: Boolean - -Run all build scripts (ie, \`preinstall\`, \`install\`, and \`postinstall\`) -scripts for installed packages in the foreground process, sharing standard -input, output, and error with the main npm process. - -Note that this will generally make installs run slower, and be much noisier, -but can be useful for debugging. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`format-package-lock\` - -* Default: true -* Type: Boolean - -Format \`package-lock.json\` or \`npm-shrinkwrap.json\` as a human readable -file. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`fund\` - -* Default: true -* Type: Boolean - -When "true" displays the message at the end of each \`npm install\` -acknowledging the number of dependencies looking for funding. See [\`npm -fund\`](/commands/npm-fund) for details. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`git\` - -* Default: "git" -* Type: String - -The command to use for git commands. If git is installed on the computer, -but is not in the \`PATH\`, then set this to the full path to the git binary. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`git-tag-version\` - -* Default: true -* Type: Boolean - -Tag the commit when using the \`npm version\` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`global\` - -* Default: false -* Type: Boolean - -Operates in "global" mode, so that packages are installed into the \`prefix\` -folder instead of the current working directory. See -[folders](/configuring-npm/folders) for more on the differences in behavior. - -* packages are installed into the \`{prefix}/lib/node_modules\` folder, instead - of the current working directory. -* bin files are linked to \`{prefix}/bin\` -* man pages are linked to \`{prefix}/share/man\` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`global-style\` - -* Default: false -* Type: Boolean - -Causes npm to install the package into your local \`node_modules\` folder with -the same layout it uses with the global \`node_modules\` folder. Only your -direct dependencies will show in \`node_modules\` and everything they depend -on will be flattened in their \`node_modules\` folders. This obviously will -eliminate some deduping. If used with \`legacy-bundling\`, \`legacy-bundling\` -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`globalconfig\` - -* Default: The global --prefix setting plus 'etc/npmrc'. For example, - '/usr/local/etc/npmrc' -* Type: Path - -The config file to read for global config options. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`heading\` - -* Default: "npm" -* Type: String - -The string that starts all the debugging log output. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`https-proxy\` - -* Default: null -* Type: null or URL - -A proxy to use for outgoing https requests. If the \`HTTPS_PROXY\` or -\`https_proxy\` or \`HTTP_PROXY\` or \`http_proxy\` environment variables are set, -proxy settings will be honored by the underlying \`make-fetch-happen\` -library. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`if-present\` - -* 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 -running scripts that may only apply for some builds in an otherwise generic -CI setup. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`ignore-scripts\` - -* Default: false -* Type: Boolean - -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`include\` - -* Default: -* Type: "prod", "dev", "optional", or "peer" (can be set multiple times) - -Option that allows for defining which types of dependencies to install. - -This is the inverse of \`--omit=<type>\`. - -Dependency types specified in \`--include\` will not be omitted, regardless of -the order in which omit/include are specified on the command-line. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`include-staged\` - -* Default: false -* Type: Boolean - -Allow installing "staged" published packages, as defined by [npm RFC PR -#92](https://github.com/npm/rfcs/pull/92). - -This is experimental, and not implemented by the npm public registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`include-workspace-root\` - -* Default: false -* Type: Boolean - -Include the workspace root when workspaces are enabled for a command. - -When false, specifying individual workspaces via the \`workspace\` config, or -all workspaces via the \`workspaces\` flag, will cause npm to operate only on -the specified workspaces, and not on the root project. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init-author-email\` - -* Default: "" -* Type: String - -The value \`npm init\` should use by default for the package author's email. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init-author-name\` - -* Default: "" -* Type: String - -The value \`npm init\` should use by default for the package author's name. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init-author-url\` - -* Default: "" -* Type: "" or URL - -The value \`npm init\` should use by default for the package author's -homepage. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init-license\` - -* Default: "ISC" -* Type: String - -The value \`npm init\` should use by default for the package license. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init-module\` - -* Default: "~/.npm-init.js" -* Type: Path - -A module that will be loaded by the \`npm init\` command. See the -documentation for the -[init-package-json](https://github.com/npm/init-package-json) module for -more information, or [npm init](/commands/npm-init). - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init-version\` - -* Default: "1.0.0" -* Type: SemVer string - -The value that \`npm init\` should use by default for the package version -number, if not already set in package.json. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`json\` - -* Default: false -* Type: Boolean - -Whether or not to output JSON data, rather than the normal output. - -* In \`npm pkg set\` it enables parsing set values with JSON.parse() before - saving them to your \`package.json\`. - -Not supported by all npm commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`key\` - -* Default: null -* Type: null or String - -A client key to pass when accessing the registry. Values should be in PEM -format with newlines replaced by the string "\\n". For example: - -\`\`\`ini -key="-----BEGIN PRIVATE KEY-----\\nXXXX\\nXXXX\\n-----END PRIVATE KEY-----" -\`\`\` - -It is _not_ the path to a key file (and there is no "keyfile" option). - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`legacy-bundling\` - -* Default: false -* Type: Boolean - -Causes npm to install the package such that versions of npm prior to 1.4, -such as the one included with node 0.8, can install the package. This -eliminates all automatic deduping. If used with \`global-style\` this option -will be preferred. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`legacy-peer-deps\` - -* Default: false -* Type: Boolean - -Causes npm to completely ignore \`peerDependencies\` when building a package -tree, as in npm versions 3 through 6. - -If a package cannot be installed because of overly strict \`peerDependencies\` -that collide, it provides a way to move forward resolving the situation. - -This differs from \`--omit=peer\`, in that \`--omit=peer\` will avoid unpacking -\`peerDependencies\` on disk, but will still design a tree such that -\`peerDependencies\` _could_ be unpacked in a correct place. - -Use of \`legacy-peer-deps\` is not recommended, as it will not enforce the -\`peerDependencies\` contract that meta-dependencies may rely on. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`link\` - -* Default: false -* Type: Boolean - -Used with \`npm ls\`, limiting output to only those packages that are linked. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`local-address\` - -* Default: null -* Type: IP Address - -The IP address of the local interface to use when making connections to the -npm registry. Must be IPv4 in versions of Node prior to 0.12. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`location\` - -* Default: "user" unless \`--global\` is passed, which will also set this value - to "global" -* Type: "global", "user", or "project" - -When passed to \`npm config\` this refers to which config file to use. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`lockfile-version\` - -* Default: Version 2 if no lockfile or current lockfile version less than or - equal to 2, otherwise maintain current lockfile version -* Type: null, 1, 2, 3, "1", "2", or "3" - -Set the lockfile format version to be used in package-lock.json and -npm-shrinkwrap-json files. Possible options are: - -1: The lockfile version used by npm versions 5 and 6. Lacks some data that -is used during the install, resulting in slower and possibly less -deterministic installs. Prevents lockfile churn when interoperating with -older npm versions. - -2: The default lockfile version used by npm version 7. Includes both the -version 1 lockfile data and version 3 lockfile data, for maximum determinism -and interoperability, at the expense of more bytes on disk. - -3: Only the new lockfile information introduced in npm version 7. Smaller on -disk than lockfile version 2, but not interoperable with older npm versions. -Ideal if all users are on npm version 7 and higher. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`loglevel\` - -* Default: "notice" -* Type: "silent", "error", "warn", "notice", "http", "timing", "info", - "verbose", or "silly" - -What level of logs to report. All logs are written to a debug log, with the -path to that file printed if the execution of a command fails. - -Any logs of a higher level than the setting are shown. The default is -"notice". - -See also the \`foreground-scripts\` config. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`logs-max\` - -* Default: 10 -* Type: Number - -The maximum number of log files to store. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`long\` - -* Default: false -* Type: Boolean - -Show extended information in \`ls\`, \`search\`, and \`help-search\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`maxsockets\` - -* Default: 15 -* Type: Number - -The maximum number of connections to use per origin (protocol/host/port -combination). - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`message\` - -* Default: "%s" -* Type: String - -Commit message which is used by \`npm version\` when creating version commit. - -Any "%s" in the message will be replaced with the version number. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`node-options\` - -* Default: null -* Type: null or String - -Options to pass through to Node.js via the \`NODE_OPTIONS\` environment -variable. This does not impact how npm itself is executed but it does impact -how lifecycle scripts are called. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`node-version\` - -* Default: Node.js \`process.version\` value -* Type: SemVer string - -The node version to use when checking a package's \`engines\` setting. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`noproxy\` - -* Default: The value of the NO_PROXY environment variable -* Type: String (can be set multiple times) - -Domain extensions that should bypass any proxies. - -Also accepts a comma-delimited string. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`npm-version\` - -* Default: Output of \`npm --version\` -* Type: SemVer string - -The npm version to use when checking a package's \`engines\` setting. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`offline\` - -* Default: false -* Type: Boolean - -Force offline mode: no network requests will be done during install. To -allow the CLI to fill in missing cache data, see \`--prefer-offline\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`omit\` - -* Default: 'dev' if the \`NODE_ENV\` environment variable is set to - 'production', otherwise empty. -* Type: "dev", "optional", or "peer" (can be set multiple times) - -Dependency types to omit from the installation tree on disk. - -Note that these dependencies _are_ still resolved and added to the -\`package-lock.json\` or \`npm-shrinkwrap.json\` file. They are just not -physically installed on disk. - -If a package type appears in both the \`--include\` and \`--omit\` lists, then -it will be included. - -If the resulting omit list includes \`'dev'\`, then the \`NODE_ENV\` environment -variable will be set to \`'production'\` for all lifecycle scripts. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`otp\` - -* Default: null -* Type: null or String - -This is a one-time password from a two-factor authenticator. It's needed -when publishing or changing package permissions with \`npm access\`. - -If not set, and a registry response fails with a challenge for a one-time -password, npm will prompt on the command line for one. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`pack-destination\` - -* Default: "." -* Type: String - -Directory in which \`npm pack\` will save tarballs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`package\` - -* Default: -* Type: String (can be set multiple times) - -The package to install for [\`npm exec\`](/commands/npm-exec) - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`package-lock\` - -* Default: true -* Type: Boolean - -If set to false, then ignore \`package-lock.json\` files when installing. This -will also prevent _writing_ \`package-lock.json\` if \`save\` is true. - -When package package-locks are disabled, automatic pruning of extraneous -modules will also be disabled. To remove extraneous modules with -package-locks disabled use \`npm prune\`. - -This configuration does not affect \`npm ci\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`package-lock-only\` - -* Default: false -* Type: Boolean - -If set to true, the current operation will only use the \`package-lock.json\`, -ignoring \`node_modules\`. - -For \`update\` this means only the \`package-lock.json\` will be updated, -instead of checking \`node_modules\` and downloading dependencies. - -For \`list\` this means the output will be based on the tree described by the -\`package-lock.json\`, rather than the contents of \`node_modules\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`parseable\` - -* Default: false -* Type: Boolean - -Output parseable results from commands that write to standard output. For -\`npm search\`, this will be tab-separated table format. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`prefer-offline\` - -* Default: false -* Type: Boolean - -If true, staleness checks for cached data will be bypassed, but missing data -will be requested from the server. To force full offline mode, use -\`--offline\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`prefer-online\` - -* Default: false -* Type: Boolean - -If true, staleness checks for cached data will be forced, making the CLI -look for updates immediately even for fresh package data. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`prefix\` - -* Default: In global mode, the folder where the node executable is installed. - In local mode, the nearest parent folder containing either a package.json - file or a node_modules folder. -* Type: Path - -The location to install global items. If set on the command line, then it -forces non-global commands to run in the specified folder. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`preid\` - -* Default: "" -* Type: String - -The "prerelease identifier" to use as a prefix for the "prerelease" part of -a semver. Like the \`rc\` in \`1.2.0-rc.8\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`progress\` - -* Default: \`true\` unless running in a known CI system -* Type: Boolean - -When set to \`true\`, npm will display a progress bar during time intensive -operations, if \`process.stderr\` is a TTY. - -Set to \`false\` to suppress the progress bar. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`proxy\` - -* Default: null -* Type: null, false, or URL - -A proxy to use for outgoing http requests. If the \`HTTP_PROXY\` or -\`http_proxy\` environment variables are set, proxy settings will be honored -by the underlying \`request\` library. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`read-only\` - -* Default: false -* Type: Boolean - -This is used to mark a token as unable to publish when configuring limited -access tokens with the \`npm token create\` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`rebuild-bundle\` - -* Default: true -* Type: Boolean - -Rebuild bundled dependencies after installation. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`registry\` - -* Default: "https://registry.npmjs.org/" -* Type: URL - -The base URL of the npm registry. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`save\` - -* Default: \`true\` unless when using \`npm update\` or \`npm dedupe\` where it - defaults to \`false\` -* Type: Boolean - -Save installed packages to a \`package.json\` file as dependencies. - -When used with the \`npm rm\` command, removes the dependency from -\`package.json\`. - -Will also prevent writing to \`package-lock.json\` if set to \`false\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`save-bundle\` - -* Default: false -* Type: Boolean - -If a package would be saved at install time by the use of \`--save\`, -\`--save-dev\`, or \`--save-optional\`, then also put it in the -\`bundleDependencies\` list. - -Ignored if \`--save-peer\` is set, since peerDependencies cannot be bundled. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`save-dev\` - -* Default: false -* Type: Boolean - -Save installed packages to a package.json file as \`devDependencies\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`save-exact\` - -* Default: false -* Type: Boolean - -Dependencies saved to package.json will be configured with an exact version -rather than using npm's default semver range operator. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`save-optional\` - -* Default: false -* Type: Boolean - -Save installed packages to a package.json file as \`optionalDependencies\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`save-peer\` - -* Default: false -* Type: Boolean - -Save installed packages to a package.json file as \`peerDependencies\` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`save-prefix\` - -* Default: "^" -* Type: String - -Configure how versions of packages installed to a package.json file via -\`--save\` or \`--save-dev\` get prefixed. - -For example if a package has version \`1.2.3\`, by default its version is set -to \`^1.2.3\` which allows minor upgrades for that package, but after \`npm -config set save-prefix='~'\` it would be set to \`~1.2.3\` which only allows -patch upgrades. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`save-prod\` - -* Default: false -* Type: Boolean - -Save installed packages into \`dependencies\` specifically. This is useful if -a package already exists in \`devDependencies\` or \`optionalDependencies\`, but -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. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`scope\` - -* Default: the scope of the current project, if any, or "" -* Type: String - -Associate an operation with a scope for a scoped registry. - -Useful when logging in to or out of a private registry: - -\`\`\` -# log in, linking the scope to the custom registry -npm login --scope=@mycorp --registry=https://registry.mycorp.com - -# log out, removing the link and the auth token -npm logout --scope=@mycorp -\`\`\` - -This will cause \`@mycorp\` to be mapped to the registry for future -installation of packages specified according to the pattern -\`@mycorp/package\`. - -This will also cause \`npm init\` to create a scoped package. - -\`\`\` -# accept all defaults, and create a package named "@foo/whatever", -# instead of just named "whatever" -npm init --scope=@foo --yes -\`\`\` - - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`script-shell\` - -* Default: '/bin/sh' on POSIX systems, 'cmd.exe' on Windows -* Type: null or String - -The shell to use for scripts run with the \`npm exec\`, \`npm run\` and \`npm -init <pkg>\` commands. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`searchexclude\` - -* Default: "" -* Type: String - -Space-separated options that limit the results from search. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`searchlimit\` - -* Default: 20 -* Type: Number - -Number of items to limit search results to. Will not apply at all to legacy -searches. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`searchopts\` - -* Default: "" -* Type: String - -Space-separated options that are always passed to search. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`searchstaleness\` - -* Default: 900 -* Type: Number - -The age of the cache, in seconds, before another registry request is made if -using legacy search endpoint. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`shell\` - -* Default: SHELL environment variable, or "bash" on Posix, or "cmd.exe" on - Windows -* Type: String - -The shell to run for the \`npm explore\` command. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`sign-git-commit\` - -* Default: false -* Type: Boolean - -If set to true, then the \`npm version\` command will commit the new package -version using \`-S\` to add a signature. - -Note that git requires you to have set up GPG keys in your git configs for -this to work properly. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`sign-git-tag\` - -* Default: false -* Type: Boolean - -If set to true, then the \`npm version\` command will tag the version using -\`-s\` to add a signature. - -Note that git requires you to have set up GPG keys in your git configs for -this to work properly. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`strict-peer-deps\` - -* Default: false -* Type: Boolean - -If set to \`true\`, and \`--legacy-peer-deps\` is not set, then _any_ -conflicting \`peerDependencies\` will be treated as an install failure, even -if npm could reasonably guess the appropriate resolution based on non-peer -dependency relationships. - -By default, conflicting \`peerDependencies\` deep in the dependency graph will -be resolved using the nearest non-peer dependency specification, even if -doing so will result in some packages receiving a peer dependency outside -the range set in their package's \`peerDependencies\` object. - -When such and override is performed, a warning is printed, explaining the -conflict and the packages involved. If \`--strict-peer-deps\` is set, then -this warning is treated as a failure. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`strict-ssl\` - -* Default: true -* Type: Boolean - -Whether or not to do SSL key validation when making requests to the registry -via https. - -See also the \`ca\` config. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`tag\` - -* Default: "latest" -* Type: String - -If you ask npm to install a package and don't tell it a specific version, -then it will install the specified tag. - -Also the tag that is added to the package@version specified by the \`npm tag\` -command, if no explicit tag is given. - -When used by the \`npm diff\` command, this is the tag used to fetch the -tarball that will be compared with the local files by default. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`tag-version-prefix\` - -* Default: "v" -* Type: String - -If set, alters the prefix used when tagging a new version when performing a -version increment using \`npm-version\`. To remove the prefix altogether, set -it to the empty string: \`""\`. - -Because other tools may rely on the convention that npm version tags look -like \`v1.0.0\`, _only use this property if it is absolutely necessary_. In -particular, use care when overriding this setting for public packages. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`timing\` - -* Default: false -* Type: Boolean - -If true, writes an \`npm-debug\` log to \`_logs\` and timing information to -\`_timing.json\`, both in your cache, even if the command completes -successfully. \`_timing.json\` is a newline delimited list of JSON objects. - -You can quickly view it with this [json](https://npm.im/json) command line: -\`npm exec -- json -g < ~/.npm/_timing.json\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`umask\` - -* Default: 0 -* Type: Octal numeric string in range 0000..0777 (0..511) - -The "umask" value to use when setting the file creation mode on files and -folders. - -Folders and executables are given a mode which is \`0o777\` masked against -this value. Other files are given a mode which is \`0o666\` masked against -this value. - -Note that the underlying system will _also_ apply its own umask value to -files and folders that are created, and npm does not circumvent this, but -rather adds the \`--umask\` config to it. - -Thus, the effective default umask value on most POSIX systems is 0o22, -meaning that folders and executables are created with a mode of 0o755 and -other files are created with a mode of 0o644. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`unicode\` - -* Default: false on windows, true on mac/unix systems with a unicode locale, - as defined by the \`LC_ALL\`, \`LC_CTYPE\`, or \`LANG\` environment variables. -* Type: Boolean - -When set to true, npm uses unicode characters in the tree output. When -false, it uses ascii characters instead of unicode glyphs. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`update-notifier\` - -* Default: true -* Type: Boolean - -Set to false to suppress the update notification when using an older version -of npm than the latest. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`usage\` - -* Default: false -* Type: Boolean - -Show short usage output about the command specified. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`user-agent\` - -* Default: "npm/{npm-version} node/{node-version} {platform} {arch} - workspaces/{workspaces} {ci}" -* Type: String - -Sets the User-Agent request header. The following fields are replaced with -their actual counterparts: - -* \`{npm-version}\` - The npm version in use -* \`{node-version}\` - The Node.js version in use -* \`{platform}\` - The value of \`process.platform\` -* \`{arch}\` - The value of \`process.arch\` -* \`{workspaces}\` - Set to \`true\` if the \`workspaces\` or \`workspace\` options - are set. -* \`{ci}\` - The value of the \`ci-name\` config, if set, prefixed with \`ci/\`, or - an empty string if \`ci-name\` is empty. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`userconfig\` - -* Default: "~/.npmrc" -* Type: Path - -The location of user-level configuration settings. - -This may be overridden by the \`npm_config_userconfig\` environment variable -or the \`--userconfig\` command line option, but may _not_ be overridden by -settings in the \`globalconfig\` file. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`version\` - -* Default: false -* Type: Boolean - -If true, output the npm version and exit successfully. - -Only relevant when specified explicitly on the command line. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`versions\` - -* Default: false -* Type: Boolean - -If true, output the npm version as well as node's \`process.versions\` map and -the version in the current working directory's \`package.json\` file if one -exists, and exit successfully. - -Only relevant when specified explicitly on the command line. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`viewer\` - -* Default: "man" on Posix, "browser" on Windows -* Type: String - -The program to use to view help content. - -Set to \`"browser"\` to view html help content in the default web browser. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`which\` - -* Default: null -* Type: null or Number - -If there are multiple funding sources, which 1-indexed source URL to open. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`workspace\` - -* Default: -* Type: String (can be set multiple times) - -Enable running a command in the context of the configured workspaces of the -current project while filtering by running only the workspaces defined by -this configuration option. - -Valid values for the \`workspace\` config are either: - -* Workspace names -* Path to a workspace directory -* Path to a parent workspace directory (will result in selecting all - workspaces within that folder) - -When set for the \`npm init\` command, this may be set to the folder of a -workspace which does not yet exist, to create the folder and set it up as a -brand new workspace within the project. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`workspaces\` - -* Default: null -* Type: null or Boolean - -Set to true to run the command in the context of **all** configured -workspaces. - -Explicitly setting this to false will cause commands like \`install\` to -ignore workspaces altogether. When not set explicitly: - -- Commands that operate on the \`node_modules\` tree (install, update, etc.) -will link workspaces into the \`node_modules\` folder. - Commands that do -other things (test, exec, publish, etc.) will operate on the root project, -_unless_ one or more workspaces are specified in the \`workspace\` config. - -This value is not exported to the environment for child processes. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`yes\` - -* Default: null -* Type: null or Boolean - -Automatically answer "yes" to any prompts that npm might print on the -command line. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`also\` - -* Default: null -* Type: null, "dev", or "development" -* DEPRECATED: Please use --include=dev instead. - -When set to \`dev\` or \`development\`, this is an alias for \`--include=dev\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`auth-type\` - -* Default: "legacy" -* Type: "legacy", "sso", "saml", or "oauth" -* DEPRECATED: This method of SSO/SAML/OAuth is deprecated and will be removed - in a future version of npm in favor of web-based login. - -What authentication strategy to use with \`adduser\`/\`login\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`cache-max\` - -* Default: Infinity -* Type: Number -* DEPRECATED: This option has been deprecated in favor of \`--prefer-online\` - -\`--cache-max=0\` is an alias for \`--prefer-online\` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`cache-min\` - -* Default: 0 -* Type: Number -* DEPRECATED: This option has been deprecated in favor of \`--prefer-offline\`. - -\`--cache-min=9999 (or bigger)\` is an alias for \`--prefer-offline\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`dev\` - -* Default: false -* Type: Boolean -* DEPRECATED: Please use --include=dev instead. - -Alias for \`--include=dev\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init.author.email\` - -* Default: "" -* Type: String -* DEPRECATED: Use \`--init-author-email\` instead. - -Alias for \`--init-author-email\` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init.author.name\` - -* Default: "" -* Type: String -* DEPRECATED: Use \`--init-author-name\` instead. - -Alias for \`--init-author-name\` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init.author.url\` - -* Default: "" -* Type: "" or URL -* DEPRECATED: Use \`--init-author-url\` instead. - -Alias for \`--init-author-url\` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init.license\` - -* Default: "ISC" -* Type: String -* DEPRECATED: Use \`--init-license\` instead. - -Alias for \`--init-license\` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init.module\` - -* Default: "~/.npm-init.js" -* Type: Path -* DEPRECATED: Use \`--init-module\` instead. - -Alias for \`--init-module\` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`init.version\` - -* Default: "1.0.0" -* Type: SemVer string -* DEPRECATED: Use \`--init-version\` instead. - -Alias for \`--init-version\` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`only\` - -* Default: null -* Type: null, "prod", or "production" -* DEPRECATED: Use \`--omit=dev\` to omit dev dependencies from the install. - -When set to \`prod\` or \`production\`, this is an alias for \`--omit=dev\`. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`optional\` - -* Default: null -* Type: null or Boolean -* DEPRECATED: Use \`--omit=optional\` to exclude optional dependencies, or - \`--include=optional\` to include them. - -Default value does install optional deps unless otherwise omitted. - -Alias for --include=optional or --omit=optional - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`production\` - -* Default: null -* Type: null or Boolean -* DEPRECATED: Use \`--omit=dev\` instead. - -Alias for \`--omit=dev\` - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`shrinkwrap\` - -* Default: true -* Type: Boolean -* DEPRECATED: Use the --package-lock setting instead. - -Alias for --package-lock - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`sso-poll-frequency\` - -* Default: 500 -* Type: Number -* DEPRECATED: The --auth-type method of SSO/SAML/OAuth will be removed in a - future version of npm in favor of web-based login. - -When used with SSO-enabled \`auth-type\`s, configures how regularly the -registry should be polled while the user is completing authentication. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`sso-type\` - -* Default: "oauth" -* Type: null, "oauth", or "saml" -* DEPRECATED: The --auth-type method of SSO/SAML/OAuth will be removed in a - future version of npm in favor of web-based login. - -If \`--auth-type=sso\`, the type of SSO type to use. - -<!-- automatically generated, do not edit manually --> -<!-- see lib/utils/config/definitions.js --> - -#### \`tmp\` - -* Default: The value returned by the Node.js \`os.tmpdir()\` method - <https://nodejs.org/api/os.html#os_os_tmpdir> -* Type: Path -* DEPRECATED: This setting is no longer used. npm stores temporary files in a - special location in the cache, and they are managed by - [\`cacache\`](http://npm.im/cacache). - -Historically, the location where temporary files were stored. No longer -relevant. -` diff --git a/tap-snapshots/test/lib/utils/config/index.js.test.cjs b/tap-snapshots/test/lib/utils/config/index.js.test.cjs deleted file mode 100644 index f1cba92..0000000 --- a/tap-snapshots/test/lib/utils/config/index.js.test.cjs +++ /dev/null @@ -1,136 +0,0 @@ -/* IMPORTANT - * This snapshot file is auto-generated, but designed for humans. - * It should be checked into source control and tracked carefully. - * Re-generate by setting TAP_SNAPSHOT=1 and running tests. - * Make sure to inspect the output below. Do not ignore changes! - */ -'use strict' -exports[`test/lib/utils/config/index.js TAP > shorthands 1`] = ` -Object { - "?": Array [ - "--usage", - ], - "a": Array [ - "--all", - ], - "B": Array [ - "--save-bundle", - ], - "c": Array [ - "--call", - ], - "C": Array [ - "--prefix", - ], - "d": Array [ - "--loglevel", - "info", - ], - "D": Array [ - "--save-dev", - ], - "dd": Array [ - "--loglevel", - "verbose", - ], - "ddd": Array [ - "--loglevel", - "silly", - ], - "desc": Array [ - "--description", - ], - "E": Array [ - "--save-exact", - ], - "enjoy-by": Array [ - "--before", - ], - "f": Array [ - "--force", - ], - "g": Array [ - "--global", - ], - "h": Array [ - "--usage", - ], - "H": Array [ - "--usage", - ], - "help": Array [ - "--usage", - ], - "l": Array [ - "--long", - ], - "L": Array [ - "--location", - ], - "local": Array [ - "--no-global", - ], - "m": Array [ - "--message", - ], - "n": Array [ - "--no-yes", - ], - "no": Array [ - "--no-yes", - ], - "O": Array [ - "--save-optional", - ], - "p": Array [ - "--parseable", - ], - "P": Array [ - "--save-prod", - ], - "porcelain": Array [ - "--parseable", - ], - "q": Array [ - "--loglevel", - "warn", - ], - "quiet": Array [ - "--loglevel", - "warn", - ], - "readonly": Array [ - "--read-only", - ], - "reg": Array [ - "--registry", - ], - "s": Array [ - "--loglevel", - "silent", - ], - "S": Array [ - "--save", - ], - "silent": Array [ - "--loglevel", - "silent", - ], - "v": Array [ - "--version", - ], - "verbose": Array [ - "--loglevel", - "verbose", - ], - "w": Array [ - "--workspace", - ], - "ws": Array [ - "--workspaces", - ], - "y": Array [ - "--yes", - ], -} -` diff --git a/tap-snapshots/test/lib/utils/error-message.js.test.cjs b/tap-snapshots/test/lib/utils/error-message.js.test.cjs index 3b82e3c..de21a46 100644 --- a/tap-snapshots/test/lib/utils/error-message.js.test.cjs +++ b/tap-snapshots/test/lib/utils/error-message.js.test.cjs @@ -155,10 +155,6 @@ Object { "", "'yolo' is not in this registry.", ], - Array [ - "404", - "You should bug the author to publish it (or use the name yourself!)", - ], Array [ "404", String( @@ -503,6 +499,18 @@ Object { exports[`test/lib/utils/error-message.js TAP eacces/eperm {"windows":false,"loaded":true,"cachePath":false,"cacheDest":false} > must match snapshot 2`] = ` Array [ + Array [ + "title", + "npm", + ], + Array [ + "argv", + "", + ], + Array [ + "logfile", + "logs-max:10 dir:{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-false-loaded-true-cachePath-false-cacheDest-false-/cache/_logs/{DATE}-", + ], Array [ "logfile", "{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-false-loaded-true-cachePath-false-cacheDest-false-/cache/_logs/{DATE}-debug-0.log", @@ -531,6 +539,18 @@ Object { exports[`test/lib/utils/error-message.js TAP eacces/eperm {"windows":false,"loaded":true,"cachePath":false,"cacheDest":true} > must match snapshot 2`] = ` Array [ + Array [ + "title", + "npm", + ], + Array [ + "argv", + "", + ], + Array [ + "logfile", + "logs-max:10 dir:{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-false-loaded-true-cachePath-false-cacheDest-true-/cache/_logs/{DATE}-", + ], Array [ "logfile", "{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-false-loaded-true-cachePath-false-cacheDest-true-/cache/_logs/{DATE}-debug-0.log", @@ -562,6 +582,18 @@ Object { exports[`test/lib/utils/error-message.js TAP eacces/eperm {"windows":false,"loaded":true,"cachePath":true,"cacheDest":false} > must match snapshot 2`] = ` Array [ + Array [ + "title", + "npm", + ], + Array [ + "argv", + "", + ], + Array [ + "logfile", + "logs-max:10 dir:{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-false-loaded-true-cachePath-true-cacheDest-false-/cache/_logs/{DATE}-", + ], Array [ "logfile", "{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-false-loaded-true-cachePath-true-cacheDest-false-/cache/_logs/{DATE}-debug-0.log", @@ -593,6 +625,18 @@ Object { exports[`test/lib/utils/error-message.js TAP eacces/eperm {"windows":false,"loaded":true,"cachePath":true,"cacheDest":true} > must match snapshot 2`] = ` Array [ + Array [ + "title", + "npm", + ], + Array [ + "argv", + "", + ], + Array [ + "logfile", + "logs-max:10 dir:{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-false-loaded-true-cachePath-true-cacheDest-true-/cache/_logs/{DATE}-", + ], Array [ "logfile", "{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-false-loaded-true-cachePath-true-cacheDest-true-/cache/_logs/{DATE}-debug-0.log", @@ -771,6 +815,18 @@ Object { exports[`test/lib/utils/error-message.js TAP eacces/eperm {"windows":true,"loaded":true,"cachePath":false,"cacheDest":false} > must match snapshot 2`] = ` Array [ + Array [ + "title", + "npm", + ], + Array [ + "argv", + "", + ], + Array [ + "logfile", + "logs-max:10 dir:{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-true-loaded-true-cachePath-false-cacheDest-false-/cache/_logs/{DATE}-", + ], Array [ "logfile", "{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-true-loaded-true-cachePath-false-cacheDest-false-/cache/_logs/{DATE}-debug-0.log", @@ -810,6 +866,18 @@ Object { exports[`test/lib/utils/error-message.js TAP eacces/eperm {"windows":true,"loaded":true,"cachePath":false,"cacheDest":true} > must match snapshot 2`] = ` Array [ + Array [ + "title", + "npm", + ], + Array [ + "argv", + "", + ], + Array [ + "logfile", + "logs-max:10 dir:{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-true-loaded-true-cachePath-false-cacheDest-true-/cache/_logs/{DATE}-", + ], Array [ "logfile", "{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-true-loaded-true-cachePath-false-cacheDest-true-/cache/_logs/{DATE}-debug-0.log", @@ -849,6 +917,18 @@ Object { exports[`test/lib/utils/error-message.js TAP eacces/eperm {"windows":true,"loaded":true,"cachePath":true,"cacheDest":false} > must match snapshot 2`] = ` Array [ + Array [ + "title", + "npm", + ], + Array [ + "argv", + "", + ], + Array [ + "logfile", + "logs-max:10 dir:{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-true-loaded-true-cachePath-true-cacheDest-false-/cache/_logs/{DATE}-", + ], Array [ "logfile", "{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-true-loaded-true-cachePath-true-cacheDest-false-/cache/_logs/{DATE}-debug-0.log", @@ -888,6 +968,18 @@ Object { exports[`test/lib/utils/error-message.js TAP eacces/eperm {"windows":true,"loaded":true,"cachePath":true,"cacheDest":true} > must match snapshot 2`] = ` Array [ + Array [ + "title", + "npm", + ], + Array [ + "argv", + "", + ], + Array [ + "logfile", + "logs-max:10 dir:{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-true-loaded-true-cachePath-true-cacheDest-true-/cache/_logs/{DATE}-", + ], Array [ "logfile", "{CWD}/test/lib/utils/tap-testdir-error-message-eacces-eperm--windows-true-loaded-true-cachePath-true-cacheDest-true-/cache/_logs/{DATE}-debug-0.log", @@ -1084,6 +1176,12 @@ Object { "explanation", ], ], + "files": Array [ + Array [ + "eresolve-report.txt", + "report", + ], + ], "summary": Array [ Array [ "ERESOLVE", diff --git a/tap-snapshots/test/lib/utils/exit-handler.js.test.cjs b/tap-snapshots/test/lib/utils/exit-handler.js.test.cjs index 523aabc..1c0bb1c 100644 --- a/tap-snapshots/test/lib/utils/exit-handler.js.test.cjs +++ b/tap-snapshots/test/lib/utils/exit-handler.js.test.cjs @@ -7,46 +7,56 @@ 'use strict' exports[`test/lib/utils/exit-handler.js TAP handles unknown error with logs and debug file > debug file contents 1`] = ` 0 timing npm:load:whichnode Completed in {TIME}ms -15 timing config:load Completed in {TIME}ms -16 timing npm:load:configload Completed in {TIME}ms -17 timing npm:load:setTitle Completed in {TIME}ms -19 timing npm:load:display Completed in {TIME}ms -20 verbose logfile {CWD}/test/lib/utils/tap-testdir-exit-handler-handles-unknown-error-with-logs-and-debug-file/cache/_logs/{DATE}-debug-0.log -21 timing npm:load:logFile Completed in {TIME}ms -22 timing npm:load:timers Completed in {TIME}ms -23 timing npm:load:configScope Completed in {TIME}ms -24 timing npm:load Completed in {TIME}ms -25 verbose stack Error: Unknown error -26 verbose cwd {CWD} -27 verbose Foo 1.0.0 -28 verbose argv "/node" "{CWD}/test/lib/utils/exit-handler.js" -29 verbose node v1.0.0 -30 verbose npm v1.0.0 -31 error code ECODE -32 error ERR SUMMARY Unknown error -33 error ERR DETAIL Unknown error -34 verbose exit 1 -35 timing npm Completed in {TIME}ms -36 verbose code 1 -37 error A complete log of this run can be found in: -37 error {CWD}/test/lib/utils/tap-testdir-exit-handler-handles-unknown-error-with-logs-and-debug-file/cache/_logs/{DATE}-debug-0.log +13 timing config:load Completed in {TIME}ms +14 timing npm:load:configload Completed in {TIME}ms +15 timing npm:load:mkdirpcache Completed in {TIME}ms +16 timing npm:load:mkdirplogs Completed in {TIME}ms +17 verbose title npm +18 verbose argv +19 timing npm:load:setTitle Completed in {TIME}ms +21 timing npm:load:display Completed in {TIME}ms +22 verbose logfile logs-max:10 dir:{CWD}/test/lib/utils/tap-testdir-exit-handler-handles-unknown-error-with-logs-and-debug-file/cache/_logs/{DATE}- +23 verbose logfile {CWD}/test/lib/utils/tap-testdir-exit-handler-handles-unknown-error-with-logs-and-debug-file/cache/_logs/{DATE}-debug-0.log +24 timing npm:load:logFile Completed in {TIME}ms +25 timing npm:load:timers Completed in {TIME}ms +26 timing npm:load:configScope Completed in {TIME}ms +27 timing npm:load Completed in {TIME}ms +28 silly logfile done cleaning log files +29 verbose stack Error: Unknown error +30 verbose cwd {CWD} +31 verbose Foo 1.0.0 +32 verbose node v1.0.0 +33 verbose npm v1.0.0 +34 error code ECODE +35 error ERR SUMMARY Unknown error +36 error ERR DETAIL Unknown error +37 verbose exit 1 +39 timing npm Completed in {TIME}ms +40 verbose code 1 +41 error A complete log of this run can be found in: +41 error {CWD}/test/lib/utils/tap-testdir-exit-handler-handles-unknown-error-with-logs-and-debug-file/cache/_logs/{DATE}-debug-0.log ` exports[`test/lib/utils/exit-handler.js TAP handles unknown error with logs and debug file > logs 1`] = ` timing npm:load:whichnode Completed in {TIME}ms timing config:load Completed in {TIME}ms timing npm:load:configload Completed in {TIME}ms +timing npm:load:mkdirpcache Completed in {TIME}ms +timing npm:load:mkdirplogs Completed in {TIME}ms +verbose title npm +verbose argv timing npm:load:setTitle Completed in {TIME}ms timing npm:load:display Completed in {TIME}ms +verbose logfile logs-max:10 dir:{CWD}/test/lib/utils/tap-testdir-exit-handler-handles-unknown-error-with-logs-and-debug-file/cache/_logs/{DATE}- verbose logfile {CWD}/test/lib/utils/tap-testdir-exit-handler-handles-unknown-error-with-logs-and-debug-file/cache/_logs/{DATE}-debug-0.log timing npm:load:logFile Completed in {TIME}ms timing npm:load:timers Completed in {TIME}ms timing npm:load:configScope Completed in {TIME}ms timing npm:load Completed in {TIME}ms +silly logfile done cleaning log files verbose stack Error: Unknown error verbose cwd {CWD} verbose Foo 1.0.0 -verbose argv "/node" "{CWD}/test/lib/utils/exit-handler.js" verbose node v1.0.0 verbose npm v1.0.0 error code ECODE diff --git a/tap-snapshots/test/lib/utils/explain-dep.js.test.cjs b/tap-snapshots/test/lib/utils/explain-dep.js.test.cjs index 4d6f468..8550617 100644 --- a/tap-snapshots/test/lib/utils/explain-dep.js.test.cjs +++ b/tap-snapshots/test/lib/utils/explain-dep.js.test.cjs @@ -156,6 +156,28 @@ optdep@1.0.0 optional node_modules/optdep ` +exports[`test/lib/utils/explain-dep.js TAP overridden > explain color deep 1`] = ` +overridden-root@1.0.0 overridden +node_modules/overridden-root + overridden overridden-dep@"1.0.0" (was "^2.0.0") from the root project +` + +exports[`test/lib/utils/explain-dep.js TAP overridden > explain nocolor shallow 1`] = ` +overridden-root@1.0.0 overridden +node_modules/overridden-root + overridden overridden-dep@"1.0.0" (was "^2.0.0") from the root project +` + +exports[`test/lib/utils/explain-dep.js TAP overridden > print color 1`] = ` +overridden-root@1.0.0 overridden +node_modules/overridden-root +` + +exports[`test/lib/utils/explain-dep.js TAP overridden > print nocolor 1`] = ` +overridden-root@1.0.0 overridden +node_modules/overridden-root +` + exports[`test/lib/utils/explain-dep.js TAP peer > explain color deep 1`] = ` peer@1.0.0 peer node_modules/peer diff --git a/tap-snapshots/test/lib/utils/explain-eresolve.js.test.cjs b/tap-snapshots/test/lib/utils/explain-eresolve.js.test.cjs index 354081d..99ad5c0 100644 --- a/tap-snapshots/test/lib/utils/explain-eresolve.js.test.cjs +++ b/tap-snapshots/test/lib/utils/explain-eresolve.js.test.cjs @@ -29,11 +29,9 @@ node_modules/@isaacs/testing-peer-dep-conflict-chain-c @isaacs/testing-peer-dep-conflict-chain-c@"1" from the root project ` -exports[`test/lib/utils/explain-eresolve.js TAP chain-conflict > report 1`] = ` +exports[`test/lib/utils/explain-eresolve.js TAP chain-conflict > report from color 1`] = ` # npm resolution error report -\${TIME} - While resolving: project@1.2.3 Found: @isaacs/testing-peer-dep-conflict-chain-d@2.0.0 node_modules/@isaacs/testing-peer-dep-conflict-chain-d @@ -45,16 +43,8 @@ node_modules/@isaacs/testing-peer-dep-conflict-chain-c @isaacs/testing-peer-dep-conflict-chain-c@"1" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -Raw JSON explanation object: - -{ - "name": "chain-conflict", - "json": true -} - ` exports[`test/lib/utils/explain-eresolve.js TAP chain-conflict > report with color 1`] = ` @@ -69,10 +59,8 @@ Could not resolve dependency: @isaacs/testing-peer-dep-conflict-chain-c@"1" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP chain-conflict > report with no color 1`] = ` @@ -87,10 +75,8 @@ node_modules/@isaacs/testing-peer-dep-conflict-chain-c @isaacs/testing-peer-dep-conflict-chain-c@"1" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP cycleNested > explain with color, depth of 2 1`] = ` @@ -130,11 +116,9 @@ node_modules/@isaacs/peer-dep-cycle-c @isaacs/peer-dep-cycle-a@"1.x" from the root project ` -exports[`test/lib/utils/explain-eresolve.js TAP cycleNested > report 1`] = ` +exports[`test/lib/utils/explain-eresolve.js TAP cycleNested > report from color 1`] = ` # npm resolution error report -\${TIME} - Found: @isaacs/peer-dep-cycle-c@2.0.0 node_modules/@isaacs/peer-dep-cycle-c @isaacs/peer-dep-cycle-c@"2.x" from the root project @@ -155,14 +139,6 @@ node_modules/@isaacs/peer-dep-cycle-c Fix the upstream dependency conflict, or retry this command with --no-strict-peer-deps, --force, or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -Raw JSON explanation object: - -{ - "name": "cycleNested", - "json": true -} - ` exports[`test/lib/utils/explain-eresolve.js TAP cycleNested > report with color 1`] = ` @@ -186,8 +162,6 @@ Conflicting peer dependency: @isaacs/peer-dep-cycle-c@1.0.0[2 Fix the upstream dependency conflict, or retry this command with --no-strict-peer-deps, --force, or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP cycleNested > report with no color 1`] = ` @@ -211,8 +185,6 @@ node_modules/@isaacs/peer-dep-cycle-c Fix the upstream dependency conflict, or retry this command with --no-strict-peer-deps, --force, or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP eslint-plugin case > explain with color, depth of 2 1`] = ` @@ -255,11 +227,9 @@ node_modules/eslint dev eslint-plugin-eslint-plugin@"^3.1.0" from the root project ` -exports[`test/lib/utils/explain-eresolve.js TAP eslint-plugin case > report 1`] = ` +exports[`test/lib/utils/explain-eresolve.js TAP eslint-plugin case > report from color 1`] = ` # npm resolution error report -\${TIME} - While resolving: eslint-plugin-react@7.24.0 Found: eslint@6.8.0 node_modules/eslint @@ -287,16 +257,8 @@ node_modules/eslint dev eslint-plugin-eslint-plugin@"^3.1.0" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -Raw JSON explanation object: - -{ - "name": "eslint-plugin case", - "json": true -} - ` exports[`test/lib/utils/explain-eresolve.js TAP eslint-plugin case > report with color 1`] = ` @@ -319,10 +281,8 @@ Conflicting peer dependency: eslint@7.31.0 dev eslint-plugin-eslint-plugin@"^3.1.0" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP eslint-plugin case > report with no color 1`] = ` @@ -345,10 +305,8 @@ node_modules/eslint dev eslint-plugin-eslint-plugin@"^3.1.0" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP gatsby > explain with color, depth of 2 1`] = ` @@ -391,11 +349,9 @@ node_modules/ink-box gatsby@"" from the root project ` -exports[`test/lib/utils/explain-eresolve.js TAP gatsby > report 1`] = ` +exports[`test/lib/utils/explain-eresolve.js TAP gatsby > report from color 1`] = ` # npm resolution error report -\${TIME} - While resolving: gatsby-recipes@0.2.31 Found: ink@3.0.0-7 node_modules/ink @@ -421,14 +377,6 @@ node_modules/ink-box Fix the upstream dependency conflict, or retry this command with --no-strict-peer-deps, --force, or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -Raw JSON explanation object: - -{ - "name": "gatsby", - "json": true -} - ` exports[`test/lib/utils/explain-eresolve.js TAP gatsby > report with color 1`] = ` @@ -456,8 +404,6 @@ Could not resolve dependency: Fix the upstream dependency conflict, or retry this command with --no-strict-peer-deps, --force, or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP gatsby > report with no color 1`] = ` @@ -485,8 +431,6 @@ node_modules/ink-box Fix the upstream dependency conflict, or retry this command with --no-strict-peer-deps, --force, or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP no current node, but has current edge > explain with color, depth of 2 1`] = ` @@ -509,11 +453,9 @@ node_modules/eslint-plugin-jsdoc dev eslint-plugin-jsdoc@"^22.1.0" from the root project ` -exports[`test/lib/utils/explain-eresolve.js TAP no current node, but has current edge > report 1`] = ` +exports[`test/lib/utils/explain-eresolve.js TAP no current node, but has current edge > report from color 1`] = ` # npm resolution error report -\${TIME} - While resolving: eslint@7.22.0 Found: dev eslint@"file:." from the root project @@ -523,16 +465,8 @@ node_modules/eslint-plugin-jsdoc dev eslint-plugin-jsdoc@"^22.1.0" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -Raw JSON explanation object: - -{ - "name": "no current node, but has current edge", - "json": true -} - ` exports[`test/lib/utils/explain-eresolve.js TAP no current node, but has current edge > report with color 1`] = ` @@ -545,10 +479,8 @@ Could not resolve dependency: dev eslint-plugin-jsdoc@"^22.1.0" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP no current node, but has current edge > report with no color 1`] = ` @@ -561,10 +493,8 @@ node_modules/eslint-plugin-jsdoc dev eslint-plugin-jsdoc@"^22.1.0" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP no current node, no current edge, idk > explain with color, depth of 2 1`] = ` @@ -591,11 +521,9 @@ node_modules/eslint-plugin-jsdoc dev eslint-plugin-jsdoc@"^22.1.0" from the root project ` -exports[`test/lib/utils/explain-eresolve.js TAP no current node, no current edge, idk > report 1`] = ` +exports[`test/lib/utils/explain-eresolve.js TAP no current node, no current edge, idk > report from color 1`] = ` # npm resolution error report -\${TIME} - While resolving: eslint@7.22.0 Found: peer eslint@"^6.0.0" from eslint-plugin-jsdoc@22.2.0 node_modules/eslint-plugin-jsdoc @@ -607,16 +535,8 @@ node_modules/eslint-plugin-jsdoc dev eslint-plugin-jsdoc@"^22.1.0" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -Raw JSON explanation object: - -{ - "name": "no current node, no current edge, idk", - "json": true -} - ` exports[`test/lib/utils/explain-eresolve.js TAP no current node, no current edge, idk > report with color 1`] = ` @@ -631,10 +551,8 @@ Could not resolve dependency: dev eslint-plugin-jsdoc@"^22.1.0" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP no current node, no current edge, idk > report with no color 1`] = ` @@ -649,10 +567,8 @@ node_modules/eslint-plugin-jsdoc dev eslint-plugin-jsdoc@"^22.1.0" from the root project Fix the upstream dependency conflict, or retry -this command with --force, or --legacy-peer-deps +this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP withShrinkwrap > explain with color, depth of 2 1`] = ` @@ -682,11 +598,9 @@ node_modules/@isaacs/peer-dep-cycle-b @isaacs/peer-dep-cycle-a@"1.x" from the root project ` -exports[`test/lib/utils/explain-eresolve.js TAP withShrinkwrap > report 1`] = ` +exports[`test/lib/utils/explain-eresolve.js TAP withShrinkwrap > report from color 1`] = ` # npm resolution error report -\${TIME} - While resolving: @isaacs/peer-dep-cycle-b@1.0.0 Found: @isaacs/peer-dep-cycle-c@2.0.0 node_modules/@isaacs/peer-dep-cycle-c @@ -702,14 +616,6 @@ node_modules/@isaacs/peer-dep-cycle-b Fix the upstream dependency conflict, or retry this command with --no-strict-peer-deps, --force, or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -Raw JSON explanation object: - -{ - "name": "withShrinkwrap", - "json": true -} - ` exports[`test/lib/utils/explain-eresolve.js TAP withShrinkwrap > report with color 1`] = ` @@ -728,8 +634,6 @@ Could not resolve dependency: Fix the upstream dependency conflict, or retry this command with --no-strict-peer-deps, --force, or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` exports[`test/lib/utils/explain-eresolve.js TAP withShrinkwrap > report with no color 1`] = ` @@ -748,6 +652,4 @@ node_modules/@isaacs/peer-dep-cycle-b Fix the upstream dependency conflict, or retry this command with --no-strict-peer-deps, --force, or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution. - -See \${REPORT} for a full report. ` diff --git a/tap-snapshots/test/lib/utils/log-file.js.test.cjs b/tap-snapshots/test/lib/utils/log-file.js.test.cjs index ecce9ea..912a436 100644 --- a/tap-snapshots/test/lib/utils/log-file.js.test.cjs +++ b/tap-snapshots/test/lib/utils/log-file.js.test.cjs @@ -6,63 +6,65 @@ */ 'use strict' exports[`test/lib/utils/log-file.js TAP snapshot > must match snapshot 1`] = ` -0 error no prefix -1 error prefix with prefix -2 error prefix 1 2 3 -3 verbose { obj: { with: { many: [Object] } } } -4 verbose {"obj":{"with":{"many":{"props":1}}}} -5 verbose { -5 verbose "obj": { -5 verbose "with": { -5 verbose "many": { -5 verbose "props": 1 -5 verbose } -5 verbose } -5 verbose } -5 verbose } -6 verbose [ 'test', 'with', 'an', 'array' ] -7 verbose ["test","with","an","array"] -8 verbose [ -8 verbose "test", -8 verbose "with", -8 verbose "an", -8 verbose "array" -8 verbose ] -9 verbose [ 'test', [ 'with', [ 'an', [Array] ] ] ] -10 verbose ["test",["with",["an",["array"]]]] -11 verbose [ -11 verbose "test", -11 verbose [ -11 verbose "with", -11 verbose [ -11 verbose "an", -11 verbose [ -11 verbose "array" -11 verbose ] -11 verbose ] -11 verbose ] -11 verbose ] -12 error pre has many errors Error: message -12 error pre at stack trace line 0 -12 error pre at stack trace line 1 -12 error pre at stack trace line 2 -12 error pre at stack trace line 3 -12 error pre at stack trace line 4 -12 error pre at stack trace line 5 -12 error pre at stack trace line 6 -12 error pre at stack trace line 7 -12 error pre at stack trace line 8 -12 error pre at stack trace line 9 Error: message2 -12 error pre at stack trace line 0 -12 error pre at stack trace line 1 -12 error pre at stack trace line 2 -12 error pre at stack trace line 3 -12 error pre at stack trace line 4 -12 error pre at stack trace line 5 -12 error pre at stack trace line 6 -12 error pre at stack trace line 7 -12 error pre at stack trace line 8 -12 error pre at stack trace line 9 -13 error nostack [Error: message] +0 verbose logfile logs-max:10 dir:{CWD}/test/lib/utils/tap-testdir-log-file-snapshot/{DATE}- +1 silly logfile done cleaning log files +2 error no prefix +3 error prefix with prefix +4 error prefix 1 2 3 +5 verbose { obj: { with: { many: [Object] } } } +6 verbose {"obj":{"with":{"many":{"props":1}}}} +7 verbose { +7 verbose "obj": { +7 verbose "with": { +7 verbose "many": { +7 verbose "props": 1 +7 verbose } +7 verbose } +7 verbose } +7 verbose } +8 verbose [ 'test', 'with', 'an', 'array' ] +9 verbose ["test","with","an","array"] +10 verbose [ +10 verbose "test", +10 verbose "with", +10 verbose "an", +10 verbose "array" +10 verbose ] +11 verbose [ 'test', [ 'with', [ 'an', [Array] ] ] ] +12 verbose ["test",["with",["an",["array"]]]] +13 verbose [ +13 verbose "test", +13 verbose [ +13 verbose "with", +13 verbose [ +13 verbose "an", +13 verbose [ +13 verbose "array" +13 verbose ] +13 verbose ] +13 verbose ] +13 verbose ] +14 error pre has many errors Error: message +14 error pre at stack trace line 0 +14 error pre at stack trace line 1 +14 error pre at stack trace line 2 +14 error pre at stack trace line 3 +14 error pre at stack trace line 4 +14 error pre at stack trace line 5 +14 error pre at stack trace line 6 +14 error pre at stack trace line 7 +14 error pre at stack trace line 8 +14 error pre at stack trace line 9 Error: message2 +14 error pre at stack trace line 0 +14 error pre at stack trace line 1 +14 error pre at stack trace line 2 +14 error pre at stack trace line 3 +14 error pre at stack trace line 4 +14 error pre at stack trace line 5 +14 error pre at stack trace line 6 +14 error pre at stack trace line 7 +14 error pre at stack trace line 8 +14 error pre at stack trace line 9 +15 error nostack [Error: message] ` diff --git a/tap-snapshots/test/lib/utils/npm-usage.js.test.cjs b/tap-snapshots/test/lib/utils/npm-usage.js.test.cjs deleted file mode 100644 index 42c24fa..0000000 --- a/tap-snapshots/test/lib/utils/npm-usage.js.test.cjs +++ /dev/null @@ -1,1165 +0,0 @@ -/* IMPORTANT - * This snapshot file is auto-generated, but designed for humans. - * It should be checked into source control and tracked carefully. - * Re-generate by setting TAP_SNAPSHOT=1 and running tests. - * Make sure to inspect the output below. Do not ignore changes! - */ -'use strict' -exports[`test/lib/utils/npm-usage.js TAP usage basic usage > must match snapshot 1`] = ` -npm <command> - -Usage: - -npm install install all the dependencies in your project -npm install <foo> add the <foo> dependency to your project -npm test run this project's tests -npm run <foo> run the script named <foo> -npm <command> -h quick help on <command> -npm -l display usage info for all commands -npm help <term> search for help on <term> -npm help npm more involved overview - -All commands: - - access, adduser, audit, bin, bugs, cache, ci, completion, - config, dedupe, deprecate, diff, dist-tag, docs, doctor, - edit, exec, explain, explore, find-dupes, fund, get, help, - hook, init, install, install-ci-test, install-test, link, - ll, login, logout, ls, org, outdated, owner, pack, ping, - pkg, prefix, profile, prune, publish, rebuild, repo, - restart, root, run-script, search, set, set-script, - shrinkwrap, star, stars, start, stop, team, test, token, - uninstall, unpublish, unstar, update, version, view, whoami - -Specify configs in the ini-formatted file: - /some/config/file/.npmrc -or on the command line via: npm <command> --key=value - -More configuration info: npm help config -Configuration fields: npm help 7 config - -npm@{VERSION} {BASEDIR} -` - -exports[`test/lib/utils/npm-usage.js TAP usage set process.stdout.columns columns=0 > must match snapshot 1`] = ` -npm <command> - -Usage: - -npm install install all the dependencies in your project -npm install <foo> add the <foo> dependency to your project -npm test run this project's tests -npm run <foo> run the script named <foo> -npm <command> -h quick help on <command> -npm -l display usage info for all commands -npm help <term> search for help on <term> -npm help npm more involved overview - -All commands: - - access, adduser, audit, bin, bugs, cache, ci, completion, - config, dedupe, deprecate, diff, dist-tag, docs, doctor, - edit, exec, explain, explore, find-dupes, fund, get, help, - hook, init, install, install-ci-test, install-test, link, - ll, login, logout, ls, org, outdated, owner, pack, ping, - pkg, prefix, profile, prune, publish, rebuild, repo, - restart, root, run-script, search, set, set-script, - shrinkwrap, star, stars, start, stop, team, test, token, - uninstall, unpublish, unstar, update, version, view, whoami - -Specify configs in the ini-formatted file: - /some/config/file/.npmrc -or on the command line via: npm <command> --key=value - -More configuration info: npm help config -Configuration fields: npm help 7 config - -npm@{VERSION} {BASEDIR} -` - -exports[`test/lib/utils/npm-usage.js TAP usage set process.stdout.columns columns=90 > must match snapshot 1`] = ` -npm <command> - -Usage: - -npm install install all the dependencies in your project -npm install <foo> add the <foo> dependency to your project -npm test run this project's tests -npm run <foo> run the script named <foo> -npm <command> -h quick help on <command> -npm -l display usage info for all commands -npm help <term> search for help on <term> -npm help npm more involved overview - -All commands: - - access, adduser, audit, bin, bugs, cache, ci, completion, - config, dedupe, deprecate, diff, dist-tag, docs, doctor, - edit, exec, explain, explore, find-dupes, fund, get, help, - hook, init, install, install-ci-test, install-test, link, - ll, login, logout, ls, org, outdated, owner, pack, ping, - pkg, prefix, profile, prune, publish, rebuild, repo, - restart, root, run-script, search, set, set-script, - shrinkwrap, star, stars, start, stop, team, test, token, - uninstall, unpublish, unstar, update, version, view, whoami - -Specify configs in the ini-formatted file: - /some/config/file/.npmrc -or on the command line via: npm <command> --key=value - -More configuration info: npm help config -Configuration fields: npm help 7 config - -npm@{VERSION} {BASEDIR} -` - -exports[`test/lib/utils/npm-usage.js TAP usage with browser > must match snapshot 1`] = ` -npm <command> - -Usage: - -npm install install all the dependencies in your project -npm install <foo> add the <foo> dependency to your project -npm test run this project's tests -npm run <foo> run the script named <foo> -npm <command> -h quick help on <command> -npm -l display usage info for all commands -npm help <term> search for help on <term> (in a browser) -npm help npm more involved overview (in a browser) - -All commands: - - access, adduser, audit, bin, bugs, cache, ci, completion, - config, dedupe, deprecate, diff, dist-tag, docs, doctor, - edit, exec, explain, explore, find-dupes, fund, get, help, - hook, init, install, install-ci-test, install-test, link, - ll, login, logout, ls, org, outdated, owner, pack, ping, - pkg, prefix, profile, prune, publish, rebuild, repo, - restart, root, run-script, search, set, set-script, - shrinkwrap, star, stars, start, stop, team, test, token, - uninstall, unpublish, unstar, update, version, view, whoami - -Specify configs in the ini-formatted file: - /some/config/file/.npmrc -or on the command line via: npm <command> --key=value - -More configuration info: npm help config -Configuration fields: npm help 7 config - -npm@{VERSION} {BASEDIR} -` - -exports[`test/lib/utils/npm-usage.js TAP usage with long > must match snapshot 1`] = ` -npm <command> - -Usage: - -npm install install all the dependencies in your project -npm install <foo> add the <foo> dependency to your project -npm test run this project's tests -npm run <foo> run the script named <foo> -npm <command> -h quick help on <command> -npm -l display usage info for all commands -npm help <term> search for help on <term> -npm help npm more involved overview - -All commands: - - access npm access - - Set access level on published packages - - Usage: - npm access public [<package>] - npm access restricted [<package>] - npm access grant <read-only|read-write> <scope:team> [<package>] - npm access revoke <scope:team> [<package>] - npm access 2fa-required [<package>] - npm access 2fa-not-required [<package>] - npm access ls-packages [<user>|<scope>|<scope:team>] - npm access ls-collaborators [<package> [<user>]] - npm access edit [<package>] - - Options: - [--registry <registry>] [--otp <otp>] - - Run "npm help access" for more info - - adduser npm adduser - - Add a registry user account - - Usage: - npm adduser - - Options: - [--registry <registry>] [--scope <@scope>] - - aliases: login, add-user - - Run "npm help adduser" for more info - - audit npm audit - - Run a security audit - - Usage: - npm audit [fix] - - Options: - [--audit-level <info|low|moderate|high|critical|none>] [--dry-run] [-f|--force] - [--json] [--package-lock-only] - [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - Run "npm help audit" for more info - - bin npm bin - - Display npm bin folder - - Usage: - npm bin - - Options: - [-g|--global] - - Run "npm help bin" for more info - - bugs npm bugs - - Report bugs for a package in a web browser - - Usage: - npm bugs [<pkgname>] - - Options: - [--no-browser|--browser <browser>] [--registry <registry>] - - alias: issues - - Run "npm help bugs" for more info - - cache npm cache - - Manipulates packages cache - - Usage: - npm cache add <tarball file> - npm cache add <folder> - npm cache add <tarball url> - npm cache add <git url> - npm cache add <name>@<version> - npm cache clean [<key>] - npm cache ls [<name>@<version>] - npm cache verify - - Options: - [--cache <cache>] - - Run "npm help cache" for more info - - ci npm ci - - Install a project with a clean slate - - Usage: - npm ci - - Options: - [--no-audit] [--ignore-scripts] [--script-shell <script-shell>] - - aliases: clean-install, ic, install-clean, isntall-clean - - Run "npm help ci" for more info - - completion npm completion - - Tab Completion for npm - - Usage: - npm completion - - Run "npm help completion" for more info - - config npm config - - Manage the npm configuration files - - Usage: - npm config set <key>=<value> [<key>=<value> ...] - npm config get [<key> [<key> ...]] - npm config delete <key> [<key> ...] - npm config list [--json] - npm config edit - - Options: - [--json] [-g|--global] [--editor <editor>] [-L|--location <global|user|project>] - [-l|--long] - - alias: c - - Run "npm help config" for more info - - dedupe npm dedupe - - Reduce duplication in the package tree - - Usage: - npm dedupe - - Options: - [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] - [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] - [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - alias: ddp - - Run "npm help dedupe" for more info - - deprecate npm deprecate - - Deprecate a version of a package - - Usage: - npm deprecate <pkg>[@<version>] <message> - - Options: - [--registry <registry>] [--otp <otp>] - - Run "npm help deprecate" for more info - - diff npm diff - - The registry diff command - - Usage: - npm diff [...<paths>] - - Options: - [--diff <pkg-name|spec|version> [--diff <pkg-name|spec|version> ...]] - [--diff-name-only] [--diff-unified <number>] [--diff-ignore-all-space] - [--diff-no-prefix] [--diff-src-prefix <path>] [--diff-dst-prefix <path>] - [--diff-text] [-g|--global] [--tag <tag>] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - Run "npm help diff" for more info - - dist-tag npm dist-tag - - Modify package distribution tags - - Usage: - npm dist-tag add <pkg>@<version> [<tag>] - npm dist-tag rm <pkg> <tag> - npm dist-tag ls [<pkg>] - - Options: - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - alias: dist-tags - - Run "npm help dist-tag" for more info - - docs npm docs - - Open documentation for a package in a web browser - - Usage: - npm docs [<pkgname> [<pkgname> ...]] - - Options: - [--no-browser|--browser <browser>] [--registry <registry>] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - alias: home - - Run "npm help docs" for more info - - doctor npm doctor - - Check your npm environment - - Usage: - npm doctor - - Options: - [--registry <registry>] - - Run "npm help doctor" for more info - - edit npm edit - - Edit an installed package - - Usage: - npm edit <pkg>[/<subpkg>...] - - Options: - [--editor <editor>] - - Run "npm help edit" for more info - - exec npm exec - - Run a command from a local or remote npm package - - Usage: - npm exec -- <pkg>[@<version>] [args...] - npm exec --package=<pkg>[@<version>] -- <cmd> [args...] - npm exec -c '<cmd> [args...]' - npm exec --package=foo -c '<cmd> [args...]' - - Options: - [--package <pkg>[@<version>] [--package <pkg>[@<version>] ...]] - [-c|--call <call>] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - alias: x - - Run "npm help exec" for more info - - explain npm explain - - Explain installed packages - - Usage: - npm explain <folder | specifier> - - Options: - [--json] [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - - alias: why - - Run "npm help explain" for more info - - explore npm explore - - Browse an installed package - - Usage: - npm explore <pkg> [ -- <command>] - - Options: - [--shell <shell>] - - Run "npm help explore" for more info - - find-dupes npm find-dupes - - Find duplication in the package tree - - Usage: - npm find-dupes - - Options: - [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] - [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] - [--no-audit] [--no-bin-links] [--no-fund] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - Run "npm help find-dupes" for more info - - fund npm fund - - Retrieve funding information - - Usage: - npm fund [[<@scope>/]<pkg>] - - Options: - [--json] [--no-browser|--browser <browser>] [--unicode] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [--which <fundingSourceNumber>] - - Run "npm help fund" for more info - - get npm get - - Get a value from the npm configuration - - Usage: - npm get [<key> ...] (See \`npm config\`) - - Run "npm help get" for more info - - help npm help - - Get help on npm - - Usage: - npm help <term> [<terms..>] - - Options: - [--viewer <viewer>] - - alias: hlep - - Run "npm help help" for more info - - hook npm hook - - Manage registry hooks - - Usage: - npm hook add <pkg> <url> <secret> [--type=<type>] - npm hook ls [pkg] - npm hook rm <id> - npm hook update <id> <url> <secret> - - Options: - [--registry <registry>] [--otp <otp>] - - Run "npm help hook" for more info - - init npm init - - Create a package.json file - - Usage: - npm init [--force|-f|--yes|-y|--scope] - npm init <@scope> (same as \`npx <@scope>/create\`) - npm init [<@scope>/]<name> (same as \`npx [<@scope>/]create-<name>\`) - - Options: - [-y|--yes] [-f|--force] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - aliases: create, innit - - Run "npm help init" for more info - - install npm install - - Install a package - - Usage: - npm install [<@scope>/]<pkg> - npm install [<@scope>/]<pkg>@<tag> - npm install [<@scope>/]<pkg>@<version> - npm install [<@scope>/]<pkg>@<version range> - npm install <alias>@npm:<name> - npm install <folder> - npm install <tarball file> - npm install <tarball url> - npm install <git:// url> - npm install <github username>/<github project> - - Options: - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] - [-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] - [--strict-peer-deps] [--no-package-lock] - [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] - [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - aliases: i, in, ins, inst, insta, instal, isnt, isnta, isntal, add - - Run "npm help install" for more info - - install-ci-test npm install-ci-test - - Install a project with a clean slate and run tests - - Usage: - npm install-ci-test - - Options: - [--no-audit] [--ignore-scripts] [--script-shell <script-shell>] - - alias: cit - - Run "npm help install-ci-test" for more info - - install-test npm install-test - - Install package(s) and run tests - - Usage: - npm install-test [<@scope>/]<pkg> - npm install-test [<@scope>/]<pkg>@<tag> - npm install-test [<@scope>/]<pkg>@<version> - npm install-test [<@scope>/]<pkg>@<version range> - npm install-test <alias>@npm:<name> - npm install-test <folder> - npm install-test <tarball file> - npm install-test <tarball url> - npm install-test <git:// url> - npm install-test <github username>/<github project> - - Options: - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] - [-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] - [--strict-peer-deps] [--no-package-lock] - [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] - [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - alias: it - - Run "npm help install-test" for more info - - link npm link - - Symlink a package folder - - Usage: - npm link (in package dir) - npm link [<@scope>/]<pkg>[@<version>] - - Options: - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] - [-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] - [--strict-peer-deps] [--no-package-lock] - [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] - [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - alias: ln - - Run "npm help link" for more info - - ll npm ll - - List installed packages - - Usage: - npm ll [[<@scope>/]<pkg> ...] - - Options: - [-a|--all] [--json] [-l|--long] [-p|--parseable] [-g|--global] [--depth <depth>] - [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--link] - [--package-lock-only] [--unicode] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - alias: la - - Run "npm help ll" for more info - - login npm adduser - - Add a registry user account - - Usage: - npm adduser - - Options: - [--registry <registry>] [--scope <@scope>] - - aliases: login, add-user - - Run "npm help adduser" for more info - - logout npm logout - - Log out of the registry - - Usage: - npm logout - - Options: - [--registry <registry>] [--scope <@scope>] - - Run "npm help logout" for more info - - ls npm ls - - List installed packages - - Usage: - npm ls [[<@scope>/]<pkg> ...] - - Options: - [-a|--all] [--json] [-l|--long] [-p|--parseable] [-g|--global] [--depth <depth>] - [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--link] - [--package-lock-only] [--unicode] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - alias: list - - Run "npm help ls" for more info - - org npm org - - Manage orgs - - Usage: - npm org set orgname username [developer | admin | owner] - npm org rm orgname username - npm org ls orgname [<username>] - - Options: - [--registry <registry>] [--otp <otp>] [--json] [-p|--parseable] - - alias: ogr - - Run "npm help org" for more info - - outdated npm outdated - - Check for outdated packages - - Usage: - npm outdated [[<@scope>/]<pkg> ...] - - Options: - [-a|--all] [--json] [-l|--long] [-p|--parseable] [-g|--global] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - - Run "npm help outdated" for more info - - owner npm owner - - Manage package owners - - Usage: - npm owner add <user> [<@scope>/]<pkg> - npm owner rm <user> [<@scope>/]<pkg> - npm owner ls [<@scope>/]<pkg> - - Options: - [--registry <registry>] [--otp <otp>] - - alias: author - - Run "npm help owner" for more info - - pack npm pack - - Create a tarball from a package - - Usage: - npm pack [[<@scope>/]<pkg>...] - - Options: - [--dry-run] [--json] [--pack-destination <pack-destination>] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - Run "npm help pack" for more info - - ping npm ping - - Ping npm registry - - Usage: - npm ping - - Options: - [--registry <registry>] - - Run "npm help ping" for more info - - pkg npm pkg - - Manages your package.json - - Usage: - npm pkg set <key>=<value> [<key>=<value> ...] - npm pkg get [<key> [<key> ...]] - npm pkg delete <key> [<key> ...] - npm pkg set [<array>[<index>].<key>=<value> ...] - npm pkg set [<array>[].<key>=<value> ...] - - Options: - [-f|--force] [--json] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] - - Run "npm help pkg" for more info - - prefix npm prefix - - Display prefix - - Usage: - npm prefix [-g] - - Options: - [-g|--global] - - Run "npm help prefix" for more info - - profile npm profile - - Change settings on your registry profile - - Usage: - npm profile enable-2fa [auth-only|auth-and-writes] - npm profile disable-2fa - npm profile get [<key>] - npm profile set <key> <value> - - Options: - [--registry <registry>] [--json] [-p|--parseable] [--otp <otp>] - - Run "npm help profile" for more info - - prune npm prune - - Remove extraneous packages - - Usage: - npm prune [[<@scope>/]<pkg>...] - - Options: - [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--dry-run] - [--json] [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - Run "npm help prune" for more info - - publish npm publish - - Publish a package - - Usage: - npm publish [<folder>] - - Options: - [--tag <tag>] [--access <restricted|public>] [--dry-run] [--otp <otp>] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - Run "npm help publish" for more info - - rebuild npm rebuild - - Rebuild a package - - Usage: - npm rebuild [[<@scope>/]<name>[@<version>] ...] - - Options: - [-g|--global] [--no-bin-links] [--ignore-scripts] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - alias: rb - - Run "npm help rebuild" for more info - - repo npm repo - - Open package repository page in the browser - - Usage: - npm repo [<pkgname> [<pkgname> ...]] - - Options: - [--no-browser|--browser <browser>] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - Run "npm help repo" for more info - - restart npm restart - - Restart a package - - Usage: - npm restart [-- <args>] - - Options: - [--ignore-scripts] [--script-shell <script-shell>] - - Run "npm help restart" for more info - - root npm root - - Display npm root - - Usage: - npm root - - Options: - [-g|--global] - - Run "npm help root" for more info - - run-script npm run-script - - Run arbitrary package scripts - - Usage: - npm run-script <command> [-- <args>] - - Options: - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] [--if-present] [--ignore-scripts] - [--script-shell <script-shell>] - - aliases: run, rum, urn - - Run "npm help run-script" for more info - - search npm search - - Search for packages - - Usage: - npm search [search terms ...] - - Options: - [-l|--long] [--json] [--color|--no-color|--color always] [-p|--parseable] - [--no-description] [--searchopts <searchopts>] [--searchexclude <searchexclude>] - [--registry <registry>] [--prefer-online] [--prefer-offline] [--offline] - - aliases: s, se, find - - Run "npm help search" for more info - - set npm set - - Set a value in the npm configuration - - Usage: - npm set <key>=<value> [<key>=<value> ...] (See \`npm config\`) - - Run "npm help set" for more info - - set-script npm set-script - - Set tasks in the scripts section of package.json - - Usage: - npm set-script [<script>] [<command>] - - Options: - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - Run "npm help set-script" for more info - - shrinkwrap npm shrinkwrap - - Lock down dependency versions for publication - - Usage: - npm shrinkwrap - - Run "npm help shrinkwrap" for more info - - star npm star - - Mark your favorite packages - - Usage: - npm star [<pkg>...] - - Options: - [--registry <registry>] [--unicode] - - Run "npm help star" for more info - - stars npm stars - - View packages marked as favorites - - Usage: - npm stars [<user>] - - Options: - [--registry <registry>] - - Run "npm help stars" for more info - - start npm start - - Start a package - - Usage: - npm start [-- <args>] - - Options: - [--ignore-scripts] [--script-shell <script-shell>] - - Run "npm help start" for more info - - stop npm stop - - Stop a package - - Usage: - npm stop [-- <args>] - - Options: - [--ignore-scripts] [--script-shell <script-shell>] - - Run "npm help stop" for more info - - team npm team - - Manage organization teams and team memberships - - Usage: - npm team create <scope:team> [--otp <otpcode>] - npm team destroy <scope:team> [--otp <otpcode>] - npm team add <scope:team> <user> [--otp <otpcode>] - npm team rm <scope:team> <user> [--otp <otpcode>] - npm team ls <scope>|<scope:team> - - Options: - [--registry <registry>] [--otp <otp>] [-p|--parseable] [--json] - - Run "npm help team" for more info - - test npm test - - Test a package - - Usage: - npm test [-- <args>] - - Options: - [--ignore-scripts] [--script-shell <script-shell>] - - aliases: tst, t - - Run "npm help test" for more info - - token npm token - - Manage your authentication tokens - - Usage: - npm token list - npm token revoke <id|token> - npm token create [--read-only] [--cidr=list] - - Options: - [--read-only] [--cidr <cidr> [--cidr <cidr> ...]] [--registry <registry>] - [--otp <otp>] - - Run "npm help token" for more info - - uninstall npm uninstall - - Remove a package - - Usage: - npm uninstall [<@scope>/]<pkg>... - - Options: - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - aliases: un, unlink, remove, rm, r - - Run "npm help uninstall" for more info - - unpublish npm unpublish - - Remove a package from the registry - - Usage: - npm unpublish [<@scope>/]<pkg>[@<version>] - - Options: - [--dry-run] [-f|--force] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] - - Run "npm help unpublish" for more info - - unstar npm unstar - - Remove an item from your favorite packages - - Usage: - npm unstar [<pkg>...] - - Options: - [--registry <registry>] [--unicode] [--otp <otp>] - - Run "npm help unstar" for more info - - update npm update - - Update packages - - Usage: - npm update [<pkg>...] - - Options: - [-g|--global] [--global-style] [--legacy-bundling] [--strict-peer-deps] - [--no-package-lock] - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] - [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]] [--ignore-scripts] - [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - aliases: up, upgrade, udpate - - Run "npm help update" for more info - - version npm version - - Bump a package version - - Usage: - npm version [<newversion> | major | minor | patch | premajor | preminor | prepatch | prerelease | from-git] - - Options: - [--allow-same-version] [--no-commit-hooks] [--no-git-tag-version] [--json] - [--preid prerelease-id] [--sign-git-tag] - [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - alias: verison - - Run "npm help version" for more info - - view npm view - - View registry info - - Usage: - npm view [<@scope>/]<pkg>[@<version>] [<field>[.subfield]...] - - Options: - [--json] [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]] - [-ws|--workspaces] [--include-workspace-root] - - aliases: v, info, show - - Run "npm help view" for more info - - whoami npm whoami - - Display npm username - - Usage: - npm whoami - - Options: - [--registry <registry>] - - Run "npm help whoami" for more info - -Specify configs in the ini-formatted file: - /some/config/file/.npmrc -or on the command line via: npm <command> --key=value - -More configuration info: npm help config -Configuration fields: npm help 7 config - -npm@{VERSION} {BASEDIR} -` diff --git a/tap-snapshots/test/lib/utils/open-url-prompt.js.test.cjs b/tap-snapshots/test/lib/utils/open-url-prompt.js.test.cjs new file mode 100644 index 0000000..8af3c47 --- /dev/null +++ b/tap-snapshots/test/lib/utils/open-url-prompt.js.test.cjs @@ -0,0 +1,25 @@ +/* IMPORTANT + * This snapshot file is auto-generated, but designed for humans. + * It should be checked into source control and tracked carefully. + * Re-generate by setting TAP_SNAPSHOT=1 and running tests. + * Make sure to inspect the output below. Do not ignore changes! + */ +'use strict' +exports[`test/lib/utils/open-url-prompt.js TAP opens a url > must match snapshot 1`] = ` +Array [ + Array [ + String( + npm home: + https://www.npmjs.com + ), + ], +] +` + +exports[`test/lib/utils/open-url-prompt.js TAP prints json output > must match snapshot 1`] = ` +Array [ + Array [ + "{\\"title\\":\\"npm home\\",\\"url\\":\\"https://www.npmjs.com\\"}", + ], +] +` diff --git a/tap-snapshots/test/lib/utils/tar.js.test.cjs b/tap-snapshots/test/lib/utils/tar.js.test.cjs index d132d7a..e2b004f 100644 --- a/tap-snapshots/test/lib/utils/tar.js.test.cjs +++ b/tap-snapshots/test/lib/utils/tar.js.test.cjs @@ -11,10 +11,10 @@ exports[`test/lib/utils/tar.js TAP should log tarball contents > must match snap package: my-cool-pkg@1.0.0 === Tarball Contents === -4B cat -4B chai -4B dog -97B package.json +4B cat +4B chai +4B dog +114B package.json === Bundled Dependencies === bundle-dep @@ -23,10 +23,40 @@ bundle-dep name: my-cool-pkg version: 1.0.0 filename: my-cool-pkg-1.0.0.tgz -package size: 274 B -unpacked size: 113 B -shasum: cd0dfccff77dff944eb761854bc0b0497d974f67 -integrity: sha512-qeFip1jH05vkW[...]zHSdMdPpYogMA== +package size: 271 B +unpacked size: 126 B +shasum: 23e31c8ad422f96301c07730e61ff403b10306f1 +integrity: sha512-/Lg5tEGQv5A5y[...]gq8T9D5+Wat1A== +bundled deps: 1 +bundled files: 0 +own files: 5 +total files: 5 + + +` + +exports[`test/lib/utils/tar.js TAP should log tarball contents of a scoped package > must match snapshot 1`] = ` + + +package: @myscope/my-cool-pkg@1.0.0 +=== Tarball Contents === + +4B cat +4B chai +4B dog +123B package.json +=== Bundled Dependencies === + +bundle-dep +=== Tarball Details === + +name: @myscope/my-cool-pkg +version: 1.0.0 +filename: myscope-my-cool-pkg-1.0.0.tgz +package size: 280 B +unpacked size: 135 B +shasum: a4f63307f2211e8fde72cd39bc1176b4fe997b71 +integrity: sha512-b+RavF8JiErJt[...]YpwkJc8ycaabA== bundled deps: 1 bundled files: 0 own files: 5 diff --git a/test/bin/windows-shims.js b/test/bin/windows-shims.js index 8d08e60..e06e41b 100644 --- a/test/bin/windows-shims.js +++ b/test/bin/windows-shims.js @@ -100,7 +100,6 @@ for (const [name, bash] of bashes) { const result = await spawn(bash, args, { env: { PATH: path, npm_config_update_notifier: 'false' }, cwd: path, - stdioString: true, }) t.match(result, { cmd: bash, @@ -119,7 +118,6 @@ for (const [name, bash] of bashes) { const result = await spawn(bash, args, { env: { PATH: path, npm_config_update_notifier: 'false' }, cwd: path, - stdioString: true, }) t.match(result, { cmd: bash, diff --git a/test/coverage-map.js b/test/coverage-map.js deleted file mode 100644 index b29fcd8..0000000 --- a/test/coverage-map.js +++ /dev/null @@ -1,20 +0,0 @@ -const full = process.env.npm_lifecycle_event === 'check-coverage' -const coverageMap = (filename) => { - if (full && /load-all.js$/.test(filename)) { - const glob = require('glob') - const { resolve, relative } = require('path') - const dir = resolve(__dirname, '../lib') - return glob.sync(`${dir}/**/*.js`) - .map(f => relative(process.cwd(), f)) - } - if (/windows-shims\.js$/.test(filename)) { - // this one doesn't provide any coverage nyc can track - return [] - } - if (/^test\/(lib\/|bin\/|index\.js$)/.test(filename)) { - return filename.replace(/^test\//, '') - } - return [] -} - -module.exports = coverageMap diff --git a/test/fixtures/clean-snapshot.js b/test/fixtures/clean-snapshot.js index 037155e..b0ea28c 100644 --- a/test/fixtures/clean-snapshot.js +++ b/test/fixtures/clean-snapshot.js @@ -10,7 +10,7 @@ const cleanCwd = (path) => normalizePath(path) .replace(new RegExp(normalizePath(process.cwd()), 'g'), '{CWD}') const cleanDate = (str) => - str.replace(/\d{4}-\d{2}-\d{2}T\d{2}[_:]\d{2}[_:]\d{2}[_:]\d{3}Z/g, '{DATE}') + str.replace(/\d{4}-\d{2}-\d{2}T\d{2}[_:]\d{2}[_:]\d{2}[_:.]\d{3}Z/g, '{DATE}') module.exports = { normalizePath, diff --git a/test/fixtures/libnpmsearch-stream-result.js b/test/fixtures/libnpmsearch-stream-result.js index 4d3aca3..b2ec20f 100644 --- a/test/fixtures/libnpmsearch-stream-result.js +++ b/test/fixtures/libnpmsearch-stream-result.js @@ -5,7 +5,7 @@ module.exports = [ version: '3.0.1', description: 'Collection of programmatic APIs for the npm CLI', keywords: ['npm', 'api', 'package manager', 'lib'], - date: new Date('2019-07-16T17:50:00.572Z'), + date: '2019-07-16T17:50:00.572Z', links: { npm: 'https://www.npmjs.com/package/libnpm', homepage: 'https://github.com/npm/libnpm#readme', @@ -26,7 +26,8 @@ module.exports = [ scope: 'unscoped', version: '4.0.1', description: 'programmatic library for `npm access` commands', - date: new Date('2020-11-03T19:19:00.526Z'), + keywords: 'libnpmaccess', + date: '2020-11-03T19:19:00.526Z', links: { npm: 'https://www.npmjs.com/package/libnpmaccess', homepage: 'https://npmjs.com/package/libnpmaccess', @@ -47,7 +48,7 @@ module.exports = [ scope: 'evocateur', version: '3.1.2', description: 'programmatic library for `npm access` commands', - date: new Date('2019-07-16T19:43:33.959Z'), + date: '2019-07-16T19:43:33.959Z', links: { npm: 'https://www.npmjs.com/package/%40evocateur%2Flibnpmaccess', homepage: 'https://npmjs.com/package/@evocateur/libnpmaccess', @@ -63,7 +64,7 @@ module.exports = [ scope: 'evocateur', version: '1.2.2', description: 'Programmatic API for the bits behind npm publish and unpublish', - date: new Date('2019-07-16T19:40:40.850Z'), + date: '2019-07-16T19:40:40.850Z', links: { npm: 'https://www.npmjs.com/package/%40evocateur%2Flibnpmpublish', homepage: 'https://npmjs.com/package/@evocateur/libnpmpublish', @@ -80,7 +81,7 @@ module.exports = [ version: '2.0.1', description: 'Programmatic api for `npm org` commands', keywords: ['libnpm', 'npm', 'package manager', 'api', 'orgs', 'teams'], - date: new Date('2020-11-03T19:21:57.757Z'), + date: '2020-11-03T19:21:57.757Z', links: { npm: 'https://www.npmjs.com/package/libnpmorg', homepage: 'https://npmjs.com/package/libnpmorg', @@ -102,7 +103,7 @@ module.exports = [ version: '3.1.0', description: 'Programmatic API for searching in npm and compatible registries.', keywords: ['npm', 'search', 'api', 'libnpm'], - date: new Date('2020-12-08T23:54:18.374Z'), + date: '2020-12-08T23:54:18.374Z', links: { npm: 'https://www.npmjs.com/package/libnpmsearch', homepage: 'https://npmjs.com/package/libnpmsearch', @@ -123,7 +124,7 @@ module.exports = [ scope: 'unscoped', version: '2.0.2', description: 'npm Team management APIs', - date: new Date('2020-11-03T19:24:42.380Z'), + date: '2020-11-03T19:24:42.380Z', links: { npm: 'https://www.npmjs.com/package/libnpmteam', homepage: 'https://npmjs.com/package/libnpmteam', @@ -145,7 +146,7 @@ module.exports = [ version: '6.0.1', description: 'programmatic API for managing npm registry hooks', keywords: ['npm', 'hooks', 'registry', 'npm api'], - date: new Date('2020-11-03T19:20:45.818Z'), + date: '2020-11-03T19:20:45.818Z', links: { npm: 'https://www.npmjs.com/package/libnpmhook', homepage: 'https://github.com/npm/libnpmhook#readme', @@ -166,7 +167,7 @@ module.exports = [ scope: 'unscoped', version: '4.0.0', description: 'Programmatic API for the bits behind npm publish and unpublish', - date: new Date('2020-11-03T19:13:43.780Z'), + date: '2020-11-03T19:13:43.780Z', links: { npm: 'https://www.npmjs.com/package/libnpmpublish', homepage: 'https://npmjs.com/package/libnpmpublish', @@ -193,7 +194,7 @@ module.exports = [ 'git', 'fund', 'gitfund', ], - date: new Date('2020-12-08T23:22:00.213Z'), + date: '2020-12-08T23:22:00.213Z', links: { npm: 'https://www.npmjs.com/package/libnpmfund', homepage: 'https://github.com/npm/libnpmfund#readme', @@ -222,7 +223,7 @@ module.exports = [ 'workspaces', 'map-workspaces', ], - date: new Date('2020-09-30T15:16:29.017Z'), + date: '2020-09-30T15:16:29.017Z', links: { npm: 'https://www.npmjs.com/package/%40npmcli%2Fmap-workspaces', homepage: 'https://github.com/npm/map-workspaces#readme', @@ -243,7 +244,7 @@ module.exports = [ scope: 'unscoped', version: '1.0.7', description: "library to do the things that 'npm version' does", - date: new Date('2020-11-04T00:21:41.069Z'), + date: '2020-11-04T00:21:41.069Z', links: { npm: 'https://www.npmjs.com/package/libnpmversion', homepage: 'https://github.com/npm/libnpmversion#readme', @@ -269,7 +270,7 @@ module.exports = [ scope: 'types', version: '2.0.1', description: 'TypeScript definitions for libnpmsearch', - date: new Date('2019-09-26T22:24:28.713Z'), + date: '2019-09-26T22:24:28.713Z', links: { npm: 'https://www.npmjs.com/package/%40types%2Flibnpmsearch' }, publisher: { username: 'types', email: 'ts-npm-types@microsoft.com' }, maintainers: [{ username: 'types', email: 'ts-npm-types@microsoft.com' }], diff --git a/test/fixtures/mock-logs.js b/test/fixtures/mock-logs.js index 80037c6..c75de5e 100644 --- a/test/fixtures/mock-logs.js +++ b/test/fixtures/mock-logs.js @@ -2,6 +2,9 @@ const NPMLOG = require('npmlog') const { LEVELS } = require('proc-log') +const npmEmitLog = NPMLOG.emitLog.bind(NPMLOG) +const npmLog = NPMLOG.log.bind(NPMLOG) + const merge = (...objs) => objs.reduce((acc, obj) => ({ ...acc, ...obj })) const mockLogs = (otherMocks = {}) => { @@ -22,6 +25,25 @@ const mockLogs = (otherMocks = {}) => { }, {}) ) + // the above logs array is anything logged and it not filtered by level. + // this display array is filtered and will not include items that + // would not be shown in the terminal + const display = Object.defineProperties( + [], + ['timing', ...LEVELS].reduce((acc, level) => { + acc[level] = { + get () { + return this + .filter(([l]) => level === l) + .map(([l, ...args]) => args) + }, + } + return acc + }, {}) + ) + + const npmLogBuffer = [] + // This returns an object with mocked versions of all necessary // logging modules. It mocks them with methods that add logs // to an array which it also returns. The reason it also returns @@ -53,19 +75,57 @@ const mockLogs = (otherMocks = {}) => { // that reflected in the npmlog singleton. // XXX: remove with npmlog npmlog: Object.assign(NPMLOG, merge( - // no-op all npmlog methods by default so tests - // dont output anything to the terminal - Object.keys(NPMLOG.levels).reduce((acc, k) => { - acc[k] = () => {} - return acc - }, {}), - // except collect timing logs - { timing: (...args) => logs.push(['timing', ...args]) }, + { + log: (level, ...args) => { + // timing does not exist on proclog, so if it got logged + // with npmlog we need to push it to our logs + if (level === 'timing') { + logs.push([level, ...args]) + } + npmLog(level, ...args) + }, + write: (msg) => { + // npmlog.write is what outputs to the terminal. + // it writes in chunks so we push each chunk to an + // array that we will log and zero out + npmLogBuffer.push(msg) + }, + emitLog: (m) => { + // this calls the original emitLog method + // which will filter based on loglevel + npmEmitLog(m) + // if anything was logged then we push to our display + // array which we can assert against in tests + if (npmLogBuffer.length) { + // first two parts are 'npm' and a single space + display.push(npmLogBuffer.slice(2)) + } + npmLogBuffer.length = 0 + }, + newItem: () => { + return { + info: (...p) => { + logs.push(['info', ...p]) + }, + warn: (...p) => { + logs.push(['warn', ...p]) + }, + error: (...p) => { + logs.push(['error', ...p]) + }, + silly: (...p) => { + logs.push(['silly', ...p]) + }, + completeWork: () => {}, + finish: () => {}, + } + }, + }, otherMocks.npmlog )), } - return { logs, logMocks } + return { logs, logMocks, display } } module.exports = mockLogs diff --git a/test/fixtures/mock-npm.js b/test/fixtures/mock-npm.js index c3dc47f..8a744cd 100644 --- a/test/fixtures/mock-npm.js +++ b/test/fixtures/mock-npm.js @@ -4,15 +4,18 @@ const path = require('path') const mockLogs = require('./mock-logs') const mockGlobals = require('./mock-globals') const log = require('../../lib/utils/log-shim') +const envConfigKeys = Object.keys(require('../../lib/utils/config/definitions.js')) const RealMockNpm = (t, otherMocks = {}) => { const mock = { ...mockLogs(otherMocks), outputs: [], + outputErrors: [], joinedOutput: () => mock.outputs.map(o => o.join(' ')).join('\n'), } const Npm = t.mock('../../lib/npm.js', { + '../../lib/utils/update-notifier.js': async () => {}, ...otherMocks, ...mock.logMocks, }) @@ -23,28 +26,58 @@ const RealMockNpm = (t, otherMocks = {}) => { super.output(...args) } + originalOutputError (...args) { + super.outputError(...args) + } + output (...args) { mock.outputs.push(args) } + + outputError (...args) { + mock.outputErrors.push(args) + } } return mock } +const setLoglevel = (t, loglevel, reset = true) => { + if (t && reset) { + const _level = log.level + t.teardown(() => log.level = _level) + } + + if (loglevel) { + // Set log level on the npmlog singleton and shared across everything + log.level = loglevel + } +} + // Resolve some options to a function call with supplied args const result = (fn, ...args) => typeof fn === 'function' ? fn(...args) : fn const LoadMockNpm = async (t, { init = true, load = init, - testdir = {}, + prefixDir = {}, + homeDir = {}, + cacheDir = {}, + globalPrefixDir = { lib: {} }, config = {}, mocks = {}, + otherDirs = {}, globals = null, } = {}) => { // Mock some globals with their original values so they get torn down // back to the original at the end of the test since they are manipulated // by npm itself + const npmConfigEnv = {} + for (const key in process.env) { + if (key.startsWith('npm_config_')) { + npmConfigEnv[key] = undefined + } + } mockGlobals(t, { process: { title: process.title, @@ -52,62 +85,86 @@ const LoadMockNpm = async (t, { env: { npm_command: process.env.npm_command, COLOR: process.env.COLOR, + ...npmConfigEnv, }, }, }) const { Npm, ...rest } = RealMockNpm(t, mocks) + // We want to fail fast when writing tests. Default this to 0 unless it was + // explicitly set in a test. + config = { 'fetch-retries': 0, ...config } + if (!init && load) { throw new Error('cant `load` without `init`') } - const _level = log.level - t.teardown(() => log.level = _level) + // Set log level as early as possible since + setLoglevel(t, config.loglevel) - if (config.loglevel) { - // Set log level as early as possible since it is set - // on the npmlog singleton and shared across everything - log.level = config.loglevel + const dir = t.testdir({ + home: homeDir, + prefix: prefixDir, + cache: cacheDir, + global: globalPrefixDir, + other: otherDirs, + }) + const dirs = { + testdir: dir, + prefix: path.join(dir, 'prefix'), + cache: path.join(dir, 'cache'), + globalPrefix: path.join(dir, 'global'), + home: path.join(dir, 'home'), + other: path.join(dir, 'other'), } - const dir = t.testdir({ root: testdir, cache: {} }) - const prefix = path.join(dir, 'root') - const cache = path.join(dir, 'cache') - // Set cache to testdir via env var so it is available when load is run // XXX: remove this for a solution where cache argv is passed in mockGlobals(t, { - 'process.env.npm_config_cache': cache, + 'process.env.HOME': dirs.home, + 'process.env.npm_config_cache': dirs.cache, + ...(globals ? result(globals, { ...dirs }) : {}), + // Some configs don't work because they can't be set via npm.config.set until + // config is loaded. But some config items are needed before that. So this is + // an explicit set of configs that must be loaded as env vars. + // XXX(npm9): make this possible by passing in argv directly to npm/config + ...Object.entries(config) + .filter(([k]) => envConfigKeys.includes(k)) + .reduce((acc, [k, v]) => { + acc[`process.env.npm_config_${k.replace(/-/g, '_')}`] = + result(v, { ...dirs }).toString() + return acc + }, {}), }) - if (globals) { - mockGlobals(t, result(globals, { prefix, cache })) - } - const npm = init ? new Npm() : null - t.teardown(() => npm && npm.unload()) + t.teardown(() => { + npm && npm.unload() + }) if (load) { await npm.load() - for (const [k, v] of Object.entries(result(config, { npm, prefix, cache }))) { - npm.config.set(k, v) + for (const [k, v] of Object.entries(result(config, { npm, ...dirs }))) { + if (typeof v === 'object' && v.value && v.where) { + npm.config.set(k, v.value, v.where) + } else { + npm.config.set(k, v) + } } - if (config.loglevel) { - // Set global loglevel *again* since it possibly got reset during load - // XXX: remove with npmlog - log.level = config.loglevel - } - npm.prefix = prefix - npm.cache = cache + // Set global loglevel *again* since it possibly got reset during load + // XXX: remove with npmlog + setLoglevel(t, config.loglevel, false) + npm.prefix = dirs.prefix + npm.cache = dirs.cache + npm.globalPrefix = dirs.globalPrefix } return { ...rest, + ...dirs, Npm, npm, - prefix, - cache, debugFile: async () => { const readFiles = npm.logFiles.map(f => fs.readFile(f)) const logFiles = await Promise.all(readFiles) @@ -117,8 +174,8 @@ const LoadMockNpm = async (t, { .join('\n') }, timingFile: async () => { - const data = await fs.readFile(path.resolve(cache, '_timing.json'), 'utf8') - return JSON.parse(data) // XXX: this fails if multiple timings are written + const data = await fs.readFile(npm.timingFile, 'utf8') + return JSON.parse(data) }, } } @@ -129,7 +186,7 @@ const realConfig = require('../../lib/utils/config') // npm.config You still need a separate flatOptions. Tests should migrate to // using the real npm mock above class MockNpm { - constructor (base = {}) { + constructor (base = {}, t) { this._mockOutputs = [] this.isMockNpm = true this.base = base @@ -150,9 +207,29 @@ class MockNpm { // for now isDefault is going to just return false if a value was defined isDefault: (k) => !Object.prototype.hasOwnProperty.call(config, k), get: (k) => ({ ...realConfig.defaults, ...config })[k], - set: (k, v) => config[k] = v, + set: (k, v) => { + config[k] = v + // mock how real npm derives silent + if (k === 'loglevel') { + this.flatOptions.silent = v === 'silent' + this.silent = v === 'silent' + } + }, list: [{ ...realConfig.defaults, ...config }], + validate: () => {}, } + + if (t && config.loglevel) { + setLoglevel(t, config.loglevel) + } + + if (config.loglevel) { + this.config.set('loglevel', config.loglevel) + } + } + + get global () { + return this.config.get('global') || this.config.get('location') === 'global' } output (...msg) { @@ -161,10 +238,19 @@ class MockNpm { } this._mockOutputs.push(msg) } + + // with the older fake mock npm there is no + // difference between output and outputBuffer + // since it just collects the output and never + // calls the exit handler, so we just mock the + // method the same as output. + outputBuffer (...msg) { + this.output(...msg) + } } -const FakeMockNpm = (base = {}) => { - return new MockNpm(base) +const FakeMockNpm = (base = {}, t) => { + return new MockNpm(base, t) } module.exports = { diff --git a/test/fixtures/sandbox.js b/test/fixtures/sandbox.js index 701d9ce..c7bb821 100644 --- a/test/fixtures/sandbox.js +++ b/test/fixtures/sandbox.js @@ -3,9 +3,10 @@ const { EventEmitter } = require('events') const { homedir, tmpdir } = require('os') const { dirname, join } = require('path') const { promisify } = require('util') -const mkdirp = require('mkdirp-infer-owner') +const { mkdir } = require('fs/promises') const rimraf = promisify(require('rimraf')) const mockLogs = require('./mock-logs') +const pkg = require('../../package.json') const chain = new Map() const sandboxes = new Map() @@ -45,8 +46,6 @@ const _logs = Symbol('sandbox.logs') // these config keys can be redacted widely const redactedDefaults = [ - 'node-version', - 'npm-version', 'tmp', ] @@ -155,6 +154,8 @@ class Sandbox extends EventEmitter { .split(normalize(homedir())).join('{REALHOME}') .split(this[_proxy].platform).join('{PLATFORM}') .split(this[_proxy].arch).join('{ARCH}') + .replace(new RegExp(process.version, 'g'), '{NODE-VERSION}') + .replace(new RegExp(pkg.version, 'g'), '{NPM-VERSION}') // We do the defaults after everything else so that they don't cause the // other cleaners to miss values we would have clobbered here. For @@ -165,14 +166,14 @@ class Sandbox extends EventEmitter { // replace default config values with placeholders for (const name of redactedDefaults) { const value = this[_npm].config.defaults[name] - clean = clean.split(value).join(`{${name.toUpperCase()}}`) + clean = clean.split(normalize(value)).join(`{${name.toUpperCase()}}`) } // replace vague default config values that are present within quotes // with placeholders for (const name of vagueRedactedDefaults) { const value = this[_npm].config.defaults[name] - clean = clean.split(`"${value}"`).join(`"{${name.toUpperCase()}}"`) + clean = clean.split(`"${normalize(value)}"`).join(`"{${name.toUpperCase()}}"`) } } @@ -193,6 +194,8 @@ class Sandbox extends EventEmitter { // test.teardown hook teardown () { if (this[_parent]) { + const sandboxProcess = sandboxes.get(this[_parent]) + sandboxProcess.removeAllListeners('log') sandboxes.delete(this[_parent]) } if (this[_npm]) { @@ -211,20 +214,7 @@ class Sandbox extends EventEmitter { return Reflect.get(this, prop, this) } - const actual = Reflect.get(target, prop, receiver) - if (typeof actual === 'function') { - // in node 10.1 there's an interesting bug where if a function on process - // is called without explicitly forcing the 'this' arg to something, we - // get 'Illegal invocation' errors. wrapping function properties in their - // own proxy so that we can make sure the context is right fixes it - return new Proxy(actual, { - apply: (target, context, args) => { - return Reflect.apply(target, _process, args) - }, - }) - } - - return actual + return Reflect.get(target, prop, receiver) } // proxy set handler @@ -249,9 +239,9 @@ class Sandbox extends EventEmitter { async run (command, argv = []) { await Promise.all([ - mkdirp(this.project), - mkdirp(this.home), - mkdirp(this.global), + mkdir(this.project, { recursive: true }), + mkdir(this.home, { recursive: true }), + mkdir(this.global, { recursive: true }), ]) // attach the sandbox process now, doing it after the promise above is @@ -275,20 +265,19 @@ class Sandbox extends EventEmitter { const mockedLogs = mockLogs(this[_mocks]) this[_logs] = mockedLogs.logs const Npm = this[_test].mock('../../lib/npm.js', { + '../../lib/utils/update-notifier.js': async () => {}, ...this[_mocks], ...mockedLogs.logMocks, }) + this.process.on('log', (l, ...args) => { + if (l !== 'pause' && l !== 'resume') { + this[_logs].push([l, ...args]) + } + }) + this[_npm] = new Npm() this[_npm].output = (...args) => this[_output].push(args) await this[_npm].load() - // in some node versions (later 10.x) our executionAsyncId at this point - // will for some reason appear to have been triggered by a different parent - // so immediately after load, if we can see that we lost our ancestry, we - // fix it here with a hammer - if (chain.get(executionAsyncId()) !== this[_parent]) { - chain.set(executionAsyncId(), this[_parent]) - process = this[_proxy] - } const cmd = this[_npm].argv.shift() return this[_npm].exec(cmd, this[_npm].argv) @@ -301,9 +290,9 @@ class Sandbox extends EventEmitter { } await Promise.all([ - mkdirp(this.project), - mkdirp(this.home), - mkdirp(this.global), + mkdir(this.project, { recursive: true }), + mkdir(this.home, { recursive: true }), + mkdir(this.global, { recursive: true }), ]) // attach the sandbox process now, doing it after the promise above is @@ -327,20 +316,19 @@ class Sandbox extends EventEmitter { const mockedLogs = mockLogs(this[_mocks]) this[_logs] = mockedLogs.logs const Npm = this[_test].mock('../../lib/npm.js', { + '../../lib/utils/update-notifier.js': async () => {}, ...this[_mocks], ...mockedLogs.logMocks, }) + this.process.on('log', (l, ...args) => { + if (l !== 'pause' && l !== 'resume') { + this[_logs].push([l, ...args]) + } + }) + this[_npm] = new Npm() this[_npm].output = (...args) => this[_output].push(args) await this[_npm].load() - // in some node versions (later 10.x) our executionAsyncId at this point - // will for some reason appear to have been triggered by a different parent - // so immediately after load, if we can see that we lost our ancestry, we - // fix it here with a hammer - if (chain.get(executionAsyncId()) !== this[_parent]) { - chain.set(executionAsyncId(), this[_parent]) - process = this[_proxy] - } const impl = await this[_npm].cmd(command) return impl.completion({ diff --git a/test/fixtures/tnock.js b/test/fixtures/tnock.js new file mode 100644 index 0000000..8e23673 --- /dev/null +++ b/test/fixtures/tnock.js @@ -0,0 +1,17 @@ +'use strict' + +const nock = require('nock') + +// Uncomment this to find requests that aren't matching +// nock.emitter.on('no match', req => console.log(req.options)) + +module.exports = tnock +function tnock (t, host, opts) { + nock.disableNetConnect() + const server = nock(host, opts) + t.teardown(function () { + nock.enableNetConnect() + server.done() + }) + return server +} diff --git a/test/fixtures/tspawk.js b/test/fixtures/tspawk.js new file mode 100644 index 0000000..554a9d4 --- /dev/null +++ b/test/fixtures/tspawk.js @@ -0,0 +1,16 @@ +'use strict' + +const spawk = require('spawk') + +module.exports = tspawk + +function tspawk (t) { + spawk.preventUnmatched() + t.teardown(function () { + spawk.unload() + }) + t.afterEach(function () { + spawk.done() + }) + return spawk +} diff --git a/test/index.js b/test/index.js index 081c89c..747d75b 100644 --- a/test/index.js +++ b/test/index.js @@ -11,7 +11,17 @@ t.test('loading as main module will load the cli', t => { const cwd = t.testdir() const { spawn } = require('child_process') const LS = require('../lib/commands/ls.js') - const ls = new LS({}) + const ls = new LS({ + config: { + validate: () => {}, + get: (key) => { + if (key === 'location') { + return 'project' + } + }, + isDefault: () => {}, + }, + }) const p = spawn(process.execPath, [index, 'ls', '-h', '--cache', cwd]) const out = [] p.stdout.on('data', c => out.push(c)) diff --git a/test/lib/arborist-cmd.js b/test/lib/arborist-cmd.js index 91d8a7b..f3c1d25 100644 --- a/test/lib/arborist-cmd.js +++ b/test/lib/arborist-cmd.js @@ -2,6 +2,16 @@ const { resolve } = require('path') const t = require('tap') const ArboristCmd = require('../../lib/arborist-cmd.js') +const configMock = { + validate: () => {}, + get: (key) => { + if (key === 'location') { + return 'project' + } + }, + isDefault: () => {}, +} + t.test('arborist-cmd', async t => { const path = t.testdir({ 'package.json': JSON.stringify({ @@ -44,8 +54,7 @@ t.test('arborist-cmd', async t => { class TestCmd extends ArboristCmd {} - const cmd = new TestCmd() - cmd.npm = { localPrefix: path } + const cmd = new TestCmd({ localPrefix: path, config: configMock }) // check filtering for a single workspace name cmd.exec = async function (args) { @@ -97,8 +106,7 @@ t.test('handle getWorkspaces raising an error', async t => { }, }) class TestCmd extends ArboristCmd {} - const cmd = new TestCmd() - cmd.npm = { localPrefix: t.testdir() } + const cmd = new TestCmd({ localPrefix: t.testdir(), config: configMock }) await t.rejects( cmd.execWorkspaces(['foo'], ['a']), diff --git a/test/lib/auth/legacy.js b/test/lib/auth/legacy.js deleted file mode 100644 index 0c23f8b..0000000 --- a/test/lib/auth/legacy.js +++ /dev/null @@ -1,429 +0,0 @@ -const t = require('tap') - -let log = '' - -const token = '24528a24f240' -const profile = {} -const read = {} -const legacy = t.mock('../../../lib/auth/legacy.js', { - 'proc-log': { - info: (...msgs) => { - log += msgs.join(' ') - }, - }, - 'npm-profile': profile, - '../../../lib/utils/open-url.js': (npm, url, msg) => { - if (!url) { - throw Object.assign(new Error('failed open url'), { code: 'ERROR' }) - } - }, - '../../../lib/utils/read-user-info.js': read, -}) - -const npm = { - config: { - get: () => null, - }, -} - -t.test('login using username/password with token result', async (t) => { - profile.login = () => { - return { token } - } - - const { - message, - newCreds, - } = await legacy(npm, { - creds: { - username: 'u', - password: 'p', - email: 'u@npmjs.org', - alwaysAuth: false, - }, - registry: 'https://registry.npmjs.org/', - scope: '', - }) - - t.equal( - message, - 'Logged in as u on https://registry.npmjs.org/.', - 'should have correct message result' - ) - - t.equal( - log, - 'login Authorized user u', - 'should have correct message result' - ) - - t.same( - newCreds, - { token }, - 'should return expected obj from profile.login' - ) - - log = '' - delete profile.login -}) - -t.test('login using username/password with user info result', async (t) => { - profile.login = () => { - return null - } - - const { - message, - newCreds, - } = await legacy(npm, { - creds: { - username: 'u', - password: 'p', - email: 'u@npmjs.org', - alwaysAuth: false, - }, - registry: 'https://registry.npmjs.org/', - scope: '', - }) - - t.equal( - message, - 'Logged in as u on https://registry.npmjs.org/.', - 'should have correct message result' - ) - - t.same( - newCreds, - { - username: 'u', - password: 'p', - email: 'u@npmjs.org', - alwaysAuth: false, - }, - 'should return used credentials' - ) - - log = '' - delete profile.login -}) - -t.test('login otp requested', async (t) => { - t.plan(5) - - profile.login = () => Promise.reject(Object.assign( - new Error('needs otp'), - { code: 'EOTP' } - )) - profile.loginCouch = (username, password, { otp }) => { - t.equal(username, 'u', 'should use provided username to loginCouch') - t.equal(password, 'p', 'should use provided password to loginCouch') - t.equal(otp, '1234', 'should use provided otp code to loginCouch') - - return { token } - } - read.otp = () => Promise.resolve('1234') - - const { - message, - newCreds, - } = await legacy(npm, { - creds: { - username: 'u', - password: 'p', - email: 'u@npmjs.org', - alwaysAuth: false, - }, - registry: 'https://registry.npmjs.org/', - scope: '', - }) - - t.equal( - message, - 'Logged in as u on https://registry.npmjs.org/.', - 'should have correct message result' - ) - - t.same( - newCreds, - { token }, - 'should return token from loginCouch result' - ) - - log = '' - delete profile.login - delete profile.loginCouch - delete read.otp -}) - -t.test('login missing basic credential info', async (t) => { - profile.login = () => Promise.reject(Object.assign( - new Error('missing info'), - { code: 'ERROR' } - )) - - await t.rejects( - legacy(npm, { - creds: { - username: 'u', - password: 'p', - }, - registry: 'https://registry.npmjs.org/', - scope: '', - }), - { code: 'ERROR' }, - 'should throw server response error' - ) - - log = '' - delete profile.login -}) - -t.test('create new user when user not found', async (t) => { - t.plan(6) - - profile.login = () => Promise.reject(Object.assign( - new Error('User does not exist'), - { code: 'ERROR' } - )) - profile.adduserCouch = (username, email, password) => { - t.equal(username, 'u', 'should use provided username to adduserCouch') - t.equal(email, 'u@npmjs.org', 'should use provided email to adduserCouch') - t.equal(password, 'p', 'should use provided password to adduserCouch') - - return { token } - } - - const { - message, - newCreds, - } = await legacy(npm, { - creds: { - username: 'u', - password: 'p', - email: 'u@npmjs.org', - alwaysAuth: false, - }, - registry: 'https://registry.npmjs.org/', - scope: '', - }) - - t.equal( - message, - 'Logged in as u on https://registry.npmjs.org/.', - 'should have correct message result' - ) - - t.equal( - log, - 'login Authorized user u', - 'should have correct message result' - ) - - t.same( - newCreds, - { token }, - 'should return expected obj from profile.login' - ) - - log = '' - delete profile.adduserCouch - delete profile.login -}) - -t.test('prompts for user info if required', async (t) => { - t.plan(4) - - profile.login = async (opener, prompt, opts) => { - t.equal(opts.creds.alwaysAuth, true, 'should have refs to creds if any') - await opener('https://registry.npmjs.org/-/v1/login') - const creds = await prompt(opts.creds) - return creds - } - read.username = () => Promise.resolve('foo') - read.password = () => Promise.resolve('pass') - read.email = () => Promise.resolve('foo@npmjs.org') - - const { - message, - newCreds, - } = await legacy(npm, { - creds: { - alwaysAuth: true, - }, - registry: 'https://registry.npmjs.org/', - scope: '', - }) - - t.equal( - message, - 'Logged in as foo on https://registry.npmjs.org/.', - 'should have correct message result' - ) - - t.equal( - log, - 'login Authorized user foo', - 'should have correct message result' - ) - - t.same( - newCreds, - { - username: 'foo', - password: 'pass', - email: 'foo@npmjs.org', - alwaysAuth: true, - }, - 'should return result from profile.login containing prompt info' - ) - - log = '' - delete profile.login - delete read.username - delete read.password - delete read.email -}) - -t.test('request otp when creating new user', async (t) => { - t.plan(3) - - profile.login = () => Promise.reject(Object.assign( - new Error('User does not exist'), - { code: 'ERROR' } - )) - profile.adduserCouch = () => Promise.reject(Object.assign( - new Error('needs otp'), - { code: 'EOTP' } - )) - profile.loginCouch = (username, password, { otp }) => { - t.equal(username, 'u', 'should use provided username to loginCouch') - t.equal(password, 'p', 'should use provided password to loginCouch') - t.equal(otp, '1234', 'should now use provided otp code to loginCouch') - - return { token } - } - read.otp = () => Promise.resolve('1234') - - await legacy(npm, { - creds: { - username: 'u', - password: 'p', - email: 'u@npmjs.org', - alwaysAuth: false, - }, - registry: 'https://registry.npmjs.org/', - scope: '', - }) - - log = '' - delete profile.adduserCouch - delete profile.login - delete profile.loginCouch - delete read.otp -}) - -t.test('unknown error during user creation', async (t) => { - profile.login = () => Promise.reject(Object.assign( - new Error('missing info'), - { code: 'ERROR' } - )) - profile.adduserCouch = () => Promise.reject(Object.assign( - new Error('unkown error'), - { code: 'ERROR' } - )) - - await t.rejects( - legacy(npm, { - creds: { - username: 'u', - password: 'p', - email: 'u@npmjs.org', - alwaysAuth: false, - }, - registry: 'https://registry.npmjs.org/', - scope: '', - }), - { code: 'ERROR' }, - 'should throw unknown error' - ) - - log = '' - delete profile.adduserCouch - delete profile.login -}) - -t.test('open url error', async (t) => { - profile.login = async (opener, prompt, opts) => { - await opener() - } - - await t.rejects( - legacy(npm, { - creds: { - username: 'u', - password: 'p', - }, - registry: 'https://registry.npmjs.org/', - scope: '', - }), - { message: 'failed open url', code: 'ERROR' }, - 'should throw unknown error' - ) - - log = '' - delete profile.login -}) - -t.test('login no credentials provided', async (t) => { - profile.login = () => ({ token }) - - await legacy(npm, { - creds: { - username: undefined, - password: undefined, - email: undefined, - alwaysAuth: undefined, - }, - registry: 'https://registry.npmjs.org/', - scope: '', - }) - - t.equal( - log, - 'login Authorized', - 'should have correct message result' - ) - - log = '' - delete profile.login -}) - -t.test('scoped login', async (t) => { - profile.login = () => ({ token }) - - const { message } = await legacy(npm, { - creds: { - username: 'u', - password: 'p', - email: 'u@npmjs.org', - alwaysAuth: false, - }, - registry: 'https://diff-registry.npmjs.org/', - scope: 'myscope', - }) - - t.equal( - message, - 'Logged in as u to scope myscope on https://diff-registry.npmjs.org/.', - 'should have correct message result' - ) - - t.equal( - log, - 'login Authorized user u', - 'should have correct message result' - ) - - log = '' - delete profile.login -}) diff --git a/test/lib/auth/oauth.js b/test/lib/auth/oauth.js deleted file mode 100644 index 0c317fb..0000000 --- a/test/lib/auth/oauth.js +++ /dev/null @@ -1,28 +0,0 @@ -const t = require('tap') - -t.test('oauth login', (t) => { - t.plan(3) - const oauthOpts = { - creds: {}, - registry: 'https://diff-registry.npmjs.org/', - scope: 'myscope', - } - - const npm = { - config: { - set: (key, value) => { - t.equal(key, 'sso-type', 'should define sso-type') - t.equal(value, 'oauth', 'should set sso-type to oauth') - }, - }, - } - const oauth = t.mock('../../../lib/auth/oauth.js', { - '../../../lib/auth/sso.js': (npm, opts) => { - t.equal(opts, oauthOpts, 'should forward opts') - }, - }) - - oauth(npm, oauthOpts) - - t.end() -}) diff --git a/test/lib/auth/saml.js b/test/lib/auth/saml.js deleted file mode 100644 index 1558e0d..0000000 --- a/test/lib/auth/saml.js +++ /dev/null @@ -1,28 +0,0 @@ -const t = require('tap') - -t.test('saml login', (t) => { - t.plan(3) - const samlOpts = { - creds: {}, - registry: 'https://diff-registry.npmjs.org/', - scope: 'myscope', - } - - const npm = { - config: { - set: (key, value) => { - t.equal(key, 'sso-type', 'should define sso-type') - t.equal(value, 'saml', 'should set sso-type to saml') - }, - }, - } - const saml = t.mock('../../../lib/auth/saml.js', { - '../../../lib/auth/sso.js': (npm, opts) => { - t.equal(opts, samlOpts, 'should forward opts') - }, - }) - - saml(npm, samlOpts) - - t.end() -}) diff --git a/test/lib/auth/sso.js b/test/lib/auth/sso.js deleted file mode 100644 index 473c8cc..0000000 --- a/test/lib/auth/sso.js +++ /dev/null @@ -1,264 +0,0 @@ -const t = require('tap') - -let log = '' -let warn = '' - -const _flatOptions = { - ssoType: 'oauth', -} -const token = '24528a24f240' -const SSO_URL = 'https://registry.npmjs.org/{SSO_URL}' -const profile = {} -const npmFetch = {} -const sso = t.mock('../../../lib/auth/sso.js', { - 'proc-log': { - info: (...msgs) => { - log += msgs.join(' ') + '\n' - }, - warn: (...msgs) => { - warn += msgs.join(' ') - }, - }, - 'npm-profile': profile, - 'npm-registry-fetch': npmFetch, - '../../../lib/utils/open-url.js': async (npm, url, msg) => { - if (!url) { - throw Object.assign( - new Error('failed open url'), - { code: 'ERROR' } - ) - } - }, - '../../../lib/utils/otplease.js': (opts, fn) => { - if (opts) { - return fn({ ...opts, otp: '1234' }) - } else { - throw Object.assign( - new Error('failed retrieving otp'), - { code: 'ERROR' } - ) - } - }, -}) - -const npm = { - flatOptions: _flatOptions, -} - -t.test('empty login', async (t) => { - _flatOptions.ssoType = false - - await t.rejects( - sso(npm, {}), - { message: 'Missing option: sso-type' }, - 'should throw if no sso-type defined in flatOptions' - ) - - t.equal( - warn, - 'deprecated SSO --auth-type is deprecated', - 'should print deprecation warning' - ) - - _flatOptions.ssoType = 'oauth' - log = '' - warn = '' -}) - -t.test('simple login', async (t) => { - t.plan(6) - - profile.loginCouch = (username, password, opts) => { - t.equal(username, 'npm_oauth_auth_dummy_user', 'should use dummy user') - t.equal(password, 'placeholder', 'should use dummy password') - t.same( - opts, - { - creds: {}, - otp: '1234', - registry: 'https://registry.npmjs.org/', - scope: '', - ssoType: 'oauth', - }, - 'should use dummy password' - ) - - return { token, sso: SSO_URL } - } - npmFetch.json = () => Promise.resolve({ username: 'foo' }) - - const { - message, - newCreds, - } = await sso(npm, { - creds: {}, - registry: 'https://registry.npmjs.org/', - scope: '', - }) - - t.equal( - message, - 'Logged in as foo on https://registry.npmjs.org/.', - 'should have correct message result' - ) - - t.equal( - log, - 'adduser Polling for validated SSO session\nadduser Authorized user foo\n', - 'should have correct logged info msg' - ) - - t.same( - newCreds, - { token }, - 'should return expected resulting credentials' - ) - - log = '' - warn = '' - delete profile.loginCouch - delete npmFetch.json -}) - -t.test('polling retry', async (t) => { - t.plan(3) - - profile.loginCouch = () => ({ token, sso: SSO_URL }) - npmFetch.json = () => { - // assert expected values during retry - npmFetch.json = (url, { registry, forceAuth: { token: expected } }) => { - t.equal( - url, - '/-/whoami', - 'should reach for expected endpoint' - ) - - t.equal( - registry, - 'https://registry.npmjs.org/', - 'should use expected registry value' - ) - - t.equal( - expected, - token, - 'should use expected token retrieved from initial loginCouch' - ) - - return Promise.resolve({ username: 'foo' }) - } - - // initial fetch returns retry code - return Promise.reject(Object.assign( - new Error('nothing yet'), - { code: 'E401' } - )) - } - - await sso(npm, { - creds: {}, - registry: 'https://registry.npmjs.org/', - scope: '', - }) - - log = '' - warn = '' - delete profile.loginCouch - delete npmFetch.json -}) - -t.test('polling error', async (t) => { - profile.loginCouch = () => ({ token, sso: SSO_URL }) - npmFetch.json = () => Promise.reject(Object.assign( - new Error('unknown error'), - { code: 'ERROR' } - )) - - await t.rejects( - sso(npm, { - creds: {}, - registry: 'https://registry.npmjs.org/', - scope: '', - }), - { message: 'unknown error', code: 'ERROR' }, - 'should throw unknown error' - ) - - log = '' - warn = '' - delete profile.loginCouch - delete npmFetch.json -}) - -t.test('no token retrieved from loginCouch', async (t) => { - profile.loginCouch = () => ({}) - - await t.rejects( - sso(npm, { - creds: {}, - registry: 'https://registry.npmjs.org/', - scope: '', - }), - { message: 'no SSO token returned' }, - 'should throw no SSO token returned error' - ) - - log = '' - warn = '' - delete profile.loginCouch -}) - -t.test('no sso url retrieved from loginCouch', async (t) => { - profile.loginCouch = () => Promise.resolve({ token }) - - await t.rejects( - sso(npm, { - creds: {}, - registry: 'https://registry.npmjs.org/', - scope: '', - }), - { message: 'no SSO URL returned by services' }, - 'should throw no SSO url returned error' - ) - - log = '' - warn = '' - delete profile.loginCouch -}) - -t.test('scoped login', async (t) => { - profile.loginCouch = () => ({ token, sso: SSO_URL }) - npmFetch.json = () => Promise.resolve({ username: 'foo' }) - - const { - message, - newCreds, - } = await sso(npm, { - creds: {}, - registry: 'https://diff-registry.npmjs.org/', - scope: 'myscope', - }) - - t.equal( - message, - 'Logged in as foo to scope myscope on https://diff-registry.npmjs.org/.', - 'should have correct message result' - ) - - t.equal( - log, - 'adduser Polling for validated SSO session\nadduser Authorized user foo\n', - 'should have correct logged info msg' - ) - - t.same( - newCreds, - { token }, - 'should return expected resulting credentials' - ) - - log = '' - warn = '' - delete profile.loginCouch - delete npmFetch.json -}) diff --git a/test/lib/cli.js b/test/lib/cli.js index f02c57d..42a22a2 100644 --- a/test/lib/cli.js +++ b/test/lib/cli.js @@ -1,9 +1,8 @@ const t = require('tap') -const mockGlobals = require('../fixtures/mock-globals.js') const { load: loadMockNpm } = require('../fixtures/mock-npm.js') -const cliMock = async (t, mocks) => { +const cliMock = async (t, opts) => { let exitHandlerArgs = null let npm = null const exitHandlerMock = (...args) => { @@ -12,14 +11,9 @@ const cliMock = async (t, mocks) => { } exitHandlerMock.setNpm = _npm => npm = _npm - const { Npm, outputs, logMocks, logs } = await loadMockNpm(t, { mocks, init: false }) + const { Npm, outputs, logMocks, logs } = await loadMockNpm(t, { ...opts, init: false }) const cli = t.mock('../../lib/cli.js', { '../../lib/npm.js': Npm, - '../../lib/utils/update-notifier.js': async () => null, - '../../lib/utils/unsupported.js': { - checkForBrokenNode: () => {}, - checkForUnsupportedNode: () => {}, - }, '../../lib/utils/exit-handler.js': exitHandlerMock, ...logMocks, }) @@ -31,25 +25,24 @@ const cliMock = async (t, mocks) => { exitHandlerCalled: () => exitHandlerArgs, exitHandlerNpm: () => npm, logs, + logsBy: (title) => logs.verbose.filter(([p]) => p === title).map(([p, ...rest]) => rest), } } t.afterEach(() => { - delete process.exitCode + process.exitCode = undefined }) t.test('print the version, and treat npm_g as npm -g', async t => { - mockGlobals(t, { - 'process.argv': ['node', 'npm_g', '-v'], + const { logsBy, logs, cli, Npm, outputs, exitHandlerCalled } = await cliMock(t, { + globals: { 'process.argv': ['node', 'npm_g', '-v'] }, }) - - const { logs, cli, Npm, outputs, exitHandlerCalled } = await cliMock(t) await cli(process) t.strictSame(process.argv, ['node', 'npm', '-g', '-v'], 'system process.argv was rewritten') - t.strictSame(logs.verbose.filter(([p]) => p !== 'logfile'), [ - ['cli', process.argv], - ]) + t.strictSame(logsBy('cli'), [['node npm']]) + t.strictSame(logsBy('title'), [['npm']]) + t.strictSame(logsBy('argv'), [['"--global" "--version"']]) t.strictSame(logs.info, [ ['using', 'npm@%s', Npm.version], ['using', 'node@%s', process.version], @@ -59,68 +52,82 @@ t.test('print the version, and treat npm_g as npm -g', async t => { }) t.test('calling with --versions calls npm version with no args', async t => { - t.plan(6) - mockGlobals(t, { - 'process.argv': ['node', 'npm', 'install', 'or', 'whatever', '--versions'], - }) - const { logs, cli, Npm, outputs, exitHandlerCalled } = await cliMock(t, { - '../../lib/commands/version.js': class Version { - async exec (args) { - t.strictSame(args, []) - } + const { logsBy, cli, outputs, exitHandlerCalled } = await cliMock(t, { + mocks: { + '../../lib/commands/version.js': class Version { + async exec (args) { + t.strictSame(args, []) + } + }, + }, + globals: { + 'process.argv': ['node', 'npm', 'install', 'or', 'whatever', '--versions'], }, }) - await cli(process) - t.equal(process.title, 'npm install or whatever') - t.strictSame(logs.verbose.filter(([p]) => p !== 'logfile'), [ - ['cli', process.argv], - ]) - t.strictSame(logs.info, [ - ['using', 'npm@%s', Npm.version], - ['using', 'node@%s', process.version], - ]) + t.equal(process.title, 'npm install or whatever') + t.strictSame(logsBy('cli'), [['node npm']]) + t.strictSame(logsBy('title'), [['npm install or whatever']]) + t.strictSame(logsBy('argv'), [['"install" "or" "whatever" "--versions"']]) t.strictSame(outputs, []) t.strictSame(exitHandlerCalled(), []) }) t.test('logged argv is sanitized', async t => { - mockGlobals(t, { - 'process.argv': [ - 'node', - 'npm', - 'version', - 'https://username:password@npmjs.org/test_url_with_a_password', - ], - }) - const { logs, cli, Npm } = await cliMock(t, { - '../../lib/commands/version.js': class Version { - async exec (args) {} + const { logsBy, cli } = await cliMock(t, { + mocks: { + '../../lib/commands/version.js': class Version { + async exec () {} + }, + }, + globals: { + 'process.argv': [ + 'node', + 'npm', + 'version', + '--registry', + 'https://u:password@npmjs.org/password', + ], }, }) await cli(process) - t.ok(process.title.startsWith('npm version https://username:***@npmjs.org')) - t.strictSame(logs.verbose.filter(([p]) => p !== 'logfile'), [ - [ - 'cli', - ['node', 'npm', 'version', 'https://username:***@npmjs.org/test_url_with_a_password'], - ], - ]) - t.strictSame(logs.info, [ - ['using', 'npm@%s', Npm.version], - ['using', 'node@%s', process.version], - ]) + t.equal(process.title, 'npm version') + t.strictSame(logsBy('cli'), [['node npm']]) + t.strictSame(logsBy('title'), [['npm version']]) + t.strictSame(logsBy('argv'), [['"version" "--registry" "https://u:***@npmjs.org/password"']]) +}) + +t.test('logged argv is sanitized with equals', async t => { + const { logsBy, cli } = await cliMock(t, { + mocks: { + '../../lib/commands/version.js': class Version { + async exec () {} + }, + }, + globals: { + 'process.argv': [ + 'node', + 'npm', + 'version', + '--registry=https://u:password@npmjs.org', + ], + }, + }) + await cli(process) + + t.strictSame(logsBy('argv'), [['"version" "--registry" "https://u:***@npmjs.org"']]) }) t.test('print usage if no params provided', async t => { - mockGlobals(t, { - 'process.argv': ['node', 'npm'], + const { cli, outputs, exitHandlerCalled, exitHandlerNpm } = await cliMock(t, { + globals: { + 'process.argv': ['node', 'npm'], + }, }) - - const { cli, outputs, exitHandlerCalled, exitHandlerNpm } = await cliMock(t) await cli(process) + t.match(outputs[0][0], 'Usage:', 'outputs npm usage') t.match(exitHandlerCalled(), [], 'should call exitHandler with no args') t.ok(exitHandlerNpm(), 'exitHandler npm is set') @@ -128,12 +135,13 @@ t.test('print usage if no params provided', async t => { }) t.test('print usage if non-command param provided', async t => { - mockGlobals(t, { - 'process.argv': ['node', 'npm', 'tset'], + const { cli, outputs, exitHandlerCalled, exitHandlerNpm } = await cliMock(t, { + globals: { + 'process.argv': ['node', 'npm', 'tset'], + }, }) - - const { cli, outputs, exitHandlerCalled, exitHandlerNpm } = await cliMock(t) await cli(process) + t.match(outputs[0][0], 'Unknown command: "tset"') t.match(outputs[0][0], 'Did you mean this?') t.match(exitHandlerCalled(), [], 'should call exitHandler with no args') @@ -142,23 +150,37 @@ t.test('print usage if non-command param provided', async t => { }) t.test('load error calls error handler', async t => { - mockGlobals(t, { - 'process.argv': ['node', 'npm', 'asdf'], - }) - const err = new Error('test load error') const { cli, exitHandlerCalled } = await cliMock(t, { - '../../lib/utils/config/index.js': { - definitions: null, - flatten: null, - shorthands: null, + mocks: { + '../../lib/utils/config/index.js': { + definitions: null, + flatten: null, + shorthands: null, + }, + '@npmcli/config': class BadConfig { + async load () { + throw err + } + }, }, - '@npmcli/config': class BadConfig { - async load () { - throw err - } + globals: { + 'process.argv': ['node', 'npm', 'asdf'], }, }) await cli(process) t.strictSame(exitHandlerCalled(), [err]) }) + +t.test('unsupported node version', async t => { + const { cli, logs } = await cliMock(t, { + globals: { + 'process.version': '12.6.0', + }, + }) + await cli(process) + t.match( + logs.warn[0][1], + /npm v.* does not support Node\.js 12\.6\.0\./ + ) +}) diff --git a/test/lib/commands/access.js b/test/lib/commands/access.js index c4e6f31..b005754 100644 --- a/test/lib/commands/access.js +++ b/test/lib/commands/access.js @@ -1,6 +1,10 @@ const t = require('tap') const { load: loadMockNpm } = require('../../fixtures/mock-npm.js') +const MockRegistry = require('@npmcli/mock-registry') + +const token = 'test-auth-token' +const auth = { '//registry.npmjs.org/:_authToken': 'test-auth-token' } t.test('completion', async t => { const { npm } = await loadMockNpm(t) @@ -10,20 +14,21 @@ t.test('completion', async t => { t.resolves(res, expect, argv.join(' ')) } - testComp(['npm', 'access'], [ - 'public', 'restricted', 'grant', 'revoke', 'ls-packages', - 'ls-collaborators', 'edit', '2fa-required', '2fa-not-required', + testComp(['npm', 'access'], ['list', 'get', 'set', 'grant', 'revoke']) + testComp(['npm', 'access', 'list'], ['packages', 'collaborators']) + testComp(['npm', 'access', 'ls'], ['packages', 'collaborators']) + testComp(['npm', 'access', 'get'], ['status']) + testComp(['npm', 'access', 'set'], [ + 'status=public', + 'status=private', + 'mfa=none', + 'mfa=publish', + 'mfa=automation', + '2fa=none', + '2fa=publish', + '2fa=automation', ]) testComp(['npm', 'access', 'grant'], ['read-only', 'read-write']) - testComp(['npm', 'access', 'grant', 'read-only'], []) - testComp(['npm', 'access', 'public'], []) - testComp(['npm', 'access', 'restricted'], []) - testComp(['npm', 'access', 'revoke'], []) - testComp(['npm', 'access', 'ls-packages'], []) - testComp(['npm', 'access', 'ls-collaborators'], []) - testComp(['npm', 'access', 'edit'], []) - testComp(['npm', 'access', '2fa-required'], []) - testComp(['npm', 'access', '2fa-not-required'], []) testComp(['npm', 'access', 'revoke'], []) await t.rejects( @@ -32,404 +37,337 @@ t.test('completion', async t => { ) }) +t.test('command required', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects(npm.exec('access', []), { code: 'EUSAGE' }) +}) + +t.test('unrecognized command', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects( + npm.exec('access', ['blerg']), { code: 'EUSAGE' }) +}) + t.test('subcommand required', async t => { const { npm } = await loadMockNpm(t) - const access = await npm.cmd('access') - await t.rejects( - npm.exec('access', []), - access.usageError('Subcommand is required.') - ) + await t.rejects(npm.exec('access', ['get']), { code: 'EUSAGE' }) }) t.test('unrecognized subcommand', async t => { const { npm } = await loadMockNpm(t) - await t.rejects( - npm.exec('access', ['blerg']), - /Usage: blerg is not a recognized subcommand/, - 'should throw EUSAGE on missing subcommand' - ) + await t.rejects(npm.exec('access', ['list', 'blerg']), { code: 'EUSAGE' }) }) -t.test('edit', async t => { - const { npm } = await loadMockNpm(t) - await t.rejects( - npm.exec('access', ['edit', '@scoped/another']), - /edit subcommand is not implemented yet/, - 'should throw not implemented yet error' - ) -}) - -t.test('access public on unscoped package', async t => { - const { npm } = await loadMockNpm(t, { - testdir: { - 'package.json': JSON.stringify({ - name: 'npm-access-public-pkg', - }), - }, +t.test('grant', t => { + t.test('invalid permissions', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects(npm.exec('access', ['grant', 'other']), { code: 'EUSAGE' }) }) - await t.rejects( - npm.exec('access', ['public']), - /Usage: This command is only available for scoped packages/, - 'should throw scoped-restricted error' - ) + + t.test('no permissions', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects(npm.exec('access', ['grant', 'read-only']), { code: 'EUSAGE' }) + }) + + t.test('read-only', async t => { + const { npm } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const permissions = 'read-only' + registry.setPermissions({ spec: '@npmcli/test-package', team: '@npm:test-team', permissions }) + await npm.exec('access', ['grant', permissions, '@npm:test-team', '@npmcli/test-package']) + }) + t.end() }) -t.test('access public on scoped package', async t => { - t.plan(3) - const name = '@scoped/npm-access-public-pkg' - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmaccess: { - public: (pkg, { registry, log }) => { - t.ok(log, 'should pass a logger') - t.equal(pkg, name, 'should use pkg name ref') - t.equal( - registry, - 'https://registry.npmjs.org/', - 'should forward correct options' - ) - return true - }, +t.test('revoke', t => { + t.test('success', async t => { + const { npm } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.removePermissions({ spec: '@npmcli/test-package', team: '@npm:test-team' }) + await npm.exec('access', ['revoke', '@npm:test-team', '@npmcli/test-package']) + }) + t.end() +}) + +t.test('list', t => { + const packages = { + '@npmcli/test-package': 'read', + '@npmcli/other-package': 'write', + } + const collaborators = { + npm: 'write', + github: 'read', + } + t.test('invalid subcommand', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects(npm.exec('access', ['list', 'other'], { code: 'EUSAGE' })) + }) + + t.test('packages explicit user', async t => { + const { npm, outputs } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.getPackages({ team: '@npm:test-team', packages }) + await npm.exec('access', ['list', 'packages', '@npm:test-team']) + t.same(outputs, [ + ['@npmcli/other-package: read-write'], + ['@npmcli/test-package: read-only'], + ]) + }) + + t.test('packages infer user', async t => { + const { npm, outputs } = await loadMockNpm(t, { config: { ...auth } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, + }) + registry.whoami({ username: 'npm' }) + registry.getPackages({ team: 'npm', packages }) + await npm.exec('access', ['list', 'packages']) + t.same(outputs, [ + ['@npmcli/other-package: read-write'], + ['@npmcli/test-package: read-only'], + ]) + }) + + t.test('packages json', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: { json: true } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.getPackages({ team: '@npm:test-team', packages }) + await npm.exec('access', ['list', 'packages', '@npm:test-team']) + t.same(JSON.parse(joinedOutput()), { + '@npmcli/test-package': 'read-only', + '@npmcli/other-package': 'read-write', + }) + }) + + t.test('collaborators explicit package', async t => { + const { npm, outputs } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.getCollaborators({ spec: '@npmcli/test-package', collaborators }) + await npm.exec('access', ['list', 'collaborators', '@npmcli/test-package']) + t.same(outputs, [ + ['github: read-only'], + ['npm: read-write'], + ]) + }) + + t.test('collaborators user', async t => { + const { npm, outputs } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.getCollaborators({ spec: '@npmcli/test-package', collaborators }) + await npm.exec('access', ['list', 'collaborators', '@npmcli/test-package', 'npm']) + t.same(outputs, [ + ['npm: read-write'], + ]) + }) + t.end() +}) + +t.test('get', t => { + t.test('invalid subcommand', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects(npm.exec('access', ['get', 'other'], { code: 'EUSAGE' })) + }) + + t.test('status explicit package', async t => { + const { npm, outputs } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.getVisibility({ spec: '@npmcli/test-package', visibility: { public: true } }) + await npm.exec('access', ['get', 'status', '@npmcli/test-package']) + t.same(outputs, [['@npmcli/test-package: public']]) + }) + t.test('status implicit package', async t => { + const { npm, outputs } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ name: '@npmcli/test-package' }), }, - }, - testdir: { - 'package.json': JSON.stringify({ name }), - }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.getVisibility({ spec: '@npmcli/test-package', visibility: { public: true } }) + await npm.exec('access', ['get', 'status']) + t.same(outputs, [['@npmcli/test-package: public']]) }) - await npm.exec('access', ['public']) -}) - -t.test('access public on missing package.json', async t => { - const { npm } = await loadMockNpm(t) - await t.rejects( - npm.exec('access', ['public']), - /no package name passed to command and no package.json found/, - 'should throw no package.json found error' - ) -}) - -t.test('access public on invalid package.json', async t => { - const { npm } = await loadMockNpm(t, { - testdir: { - 'package.json': '{\n', - node_modules: {}, - }, + t.test('status no package', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects( + npm.exec('access', ['get', 'status']), + { code: 'ENOENT' } + ) }) - await t.rejects( - npm.exec('access', ['public']), - { code: 'EJSONPARSE' }, - 'should throw failed to parse package.json' - ) -}) - -t.test('access restricted on unscoped package', async t => { - const { npm } = await loadMockNpm(t, { - testdir: { - 'package.json': JSON.stringify({ - name: 'npm-access-restricted-pkg', - }), - }, + t.test('status invalid package', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: { 'package.json': '[not:valid_json}' }, + }) + await t.rejects( + npm.exec('access', ['get', 'status']), + { code: 'EJSONPARSE' } + ) }) - await t.rejects( - npm.exec('access', ['public']), - /Usage: This command is only available for scoped packages/, - 'should throw scoped-restricted error' - ) -}) - -t.test('access restricted on scoped package', async t => { - t.plan(2) - const name = '@scoped/npm-access-restricted-pkg' - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmaccess: { - restricted: (pkg, { registry }) => { - t.equal(pkg, name, 'should use pkg name ref') - t.equal( - registry, - 'https://registry.npmjs.org/', - 'should forward correct options' - ) - return true - }, - }, - }, - testdir: { - 'package.json': JSON.stringify({ name }), - }, + t.test('status json', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: { json: true } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.getVisibility({ spec: '@npmcli/test-package', visibility: { public: true } }) + await npm.exec('access', ['get', 'status', '@npmcli/test-package']) + t.same(JSON.parse(joinedOutput()), { '@npmcli/test-package': 'public' }) }) - await npm.exec('access', ['restricted']) + t.end() }) -t.test('access restricted on missing package.json', async t => { - const { npm } = await loadMockNpm(t) - await t.rejects( - npm.exec('access', ['restricted']), - /no package name passed to command and no package.json found/, - 'should throw no package.json found error' - ) -}) - -t.test('access restricted on invalid package.json', async t => { - const { npm } = await loadMockNpm(t, { - testdir: { - 'package.json': '{\n', - node_modules: {}, - }, +t.test('set', t => { + t.test('status=public', async t => { + const { npm, outputs } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.setAccess({ spec: '@npmcli/test-package', body: { access: 'public' } }) + registry.getVisibility({ spec: '@npmcli/test-package', visibility: { public: true } }) + await npm.exec('access', ['set', 'status=public', '@npmcli/test-package']) + t.same(outputs, [['@npmcli/test-package: public']]) }) - await t.rejects( - npm.exec('access', ['restricted']), - { code: 'EJSONPARSE' }, - 'should throw failed to parse package.json' - ) -}) - -t.test('access grant read-only', async t => { - t.plan(3) - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmaccess: { - grant: (spec, team, permissions) => { - t.equal(spec, '@scoped/another', 'should use expected spec') - t.equal(team, 'myorg:myteam', 'should use expected team') - t.equal(permissions, 'read-only', 'should forward permissions') - return true - }, - }, - }, + t.test('status=private', async t => { + const { npm, outputs } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.setAccess({ spec: '@npmcli/test-package', body: { access: 'restricted' } }) + registry.getVisibility({ spec: '@npmcli/test-package', visibility: { public: false } }) + await npm.exec('access', ['set', 'status=private', '@npmcli/test-package']) + t.same(outputs, [['@npmcli/test-package: private']]) }) - await npm.exec('access', [ - 'grant', - 'read-only', - 'myorg:myteam', - '@scoped/another', - ]) -}) - -t.test('access grant read-write', async t => { - t.plan(3) - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmaccess: { - grant: (spec, team, permissions) => { - t.equal(spec, '@scoped/another', 'should use expected spec') - t.equal(team, 'myorg:myteam', 'should use expected team') - t.equal(permissions, 'read-write', 'should forward permissions') - return true - }, - }, - }, + t.test('status=invalid', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects( + npm.exec('access', ['set', 'status=invalid', '@npmcli/test-package']), + { code: 'EUSAGE' } + ) }) - await npm.exec('access', [ - 'grant', - 'read-write', - 'myorg:myteam', - '@scoped/another', - ]) -}) - -t.test('access grant current cwd', async t => { - t.plan(3) - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmaccess: { - grant: (spec, team, permissions) => { - t.equal(spec, 'yargs', 'should use expected spec') - t.equal(team, 'myorg:myteam', 'should use expected team') - t.equal(permissions, 'read-write', 'should forward permissions') - return true - }, - }, - }, - testdir: { - 'package.json': JSON.stringify({ - name: 'yargs', - }), - }, + t.test('status non scoped package', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects( + npm.exec('access', ['set', 'status=public', 'npm']), + { code: 'EUSAGE' } + ) }) - await npm.exec('access', [ - 'grant', - 'read-write', - 'myorg:myteam', - ]) -}) - -t.test('access grant others', async t => { - const { npm } = await loadMockNpm(t) - await t.rejects( - npm.exec('access', [ - 'grant', - 'rerere', - 'myorg:myteam', - '@scoped/another', - ]), - /Usage: First argument must be either `read-only` or `read-write`./, - 'should throw unrecognized argument error' - ) -}) - -t.test('access grant missing team args', async t => { - const { npm } = await loadMockNpm(t) - await t.rejects( - npm.exec('access', [ - 'grant', - 'read-only', - undefined, - '@scoped/another', - ]), - /Usage: `<scope:team>` argument is required./, - 'should throw missing argument error' - ) -}) - -t.test('access grant malformed team arg', async t => { - const { npm } = await loadMockNpm(t) - await t.rejects( - npm.exec('access', [ - 'grant', - 'read-only', - 'foo', - '@scoped/another', - ]), - /Usage: Second argument used incorrect format.\n/, - 'should throw malformed arg error' - ) -}) - -t.test('access 2fa-required/2fa-not-required', async t => { - t.plan(2) - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmaccess: { - tfaRequired: (spec) => { - t.equal(spec, '@scope/pkg', 'should use expected spec') - return true - }, - tfaNotRequired: (spec) => { - t.equal(spec, 'unscoped-pkg', 'should use expected spec') - return true - }, - }, - }, + t.test('mfa=none', async t => { + const { npm } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.setAccess({ spec: '@npmcli/test-package', + body: { + publish_requires_tfa: false, + } }) + await npm.exec('access', ['set', 'mfa=none', '@npmcli/test-package']) }) - await npm.exec('access', ['2fa-required', '@scope/pkg']) - await npm.exec('access', ['2fa-not-required', 'unscoped-pkg']) -}) - -t.test('access revoke', async t => { - t.plan(2) - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmaccess: { - revoke: (spec, team) => { - t.equal(spec, '@scoped/another', 'should use expected spec') - t.equal(team, 'myorg:myteam', 'should use expected team') - return true - }, - }, - }, + t.test('mfa=publish', async t => { + const { npm } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.setAccess({ spec: '@npmcli/test-package', + body: { + publish_requires_tfa: true, + automation_token_overrides_tfa: false, + } }) + await npm.exec('access', ['set', 'mfa=publish', '@npmcli/test-package']) }) - await npm.exec('access', [ - 'revoke', - 'myorg:myteam', - '@scoped/another', - ]) -}) - -t.test('access revoke missing team args', async t => { - const { npm } = await loadMockNpm(t) - await t.rejects( - npm.exec('access', [ - 'revoke', - undefined, - '@scoped/another', - ]), - /Usage: `<scope:team>` argument is required./, - 'should throw missing argument error' - ) -}) - -t.test('access revoke malformed team arg', async t => { - const { npm } = await loadMockNpm(t) - await t.rejects( - npm.exec('access', [ - 'revoke', - 'foo', - '@scoped/another', - ]), - /Usage: First argument used incorrect format.\n/, - 'should throw malformed arg error' - ) -}) - -t.test('npm access ls-packages with no team', async t => { - t.plan(1) - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmaccess: { - lsPackages: (entity) => { - t.equal(entity, 'foo', 'should use expected entity') - return {} - }, - }, - '../../lib/utils/get-identity.js': () => Promise.resolve('foo'), - }, + t.test('mfa=automation', async t => { + const { npm } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.setAccess({ spec: '@npmcli/test-package', + body: { + publish_requires_tfa: true, + automation_token_overrides_tfa: true, + } }) + await npm.exec('access', ['set', 'mfa=automation', '@npmcli/test-package']) }) - await npm.exec('access', ['ls-packages']) -}) - -t.test('access ls-packages on team', async t => { - t.plan(1) - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmaccess: { - lsPackages: (entity) => { - t.equal(entity, 'myorg:myteam', 'should use expected entity') - return {} - }, - }, - }, + t.test('mfa=invalid', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects( + npm.exec('access', ['set', 'mfa=invalid']), + { code: 'EUSAGE' } + ) }) - await npm.exec('access', [ - 'ls-packages', - 'myorg:myteam', - ]) -}) - -t.test('access ls-collaborators on current', async t => { - t.plan(1) - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmaccess: { - lsCollaborators: (spec) => { - t.equal(spec, 'yargs', 'should use expected spec') - return {} - }, - }, - }, - testdir: { - 'package.json': JSON.stringify({ - name: 'yargs', - }), - }, + t.test('2fa=none', async t => { + const { npm } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.setAccess({ spec: '@npmcli/test-package', + body: { + publish_requires_tfa: false, + } }) + await npm.exec('access', ['set', '2fa=none', '@npmcli/test-package']) }) - await npm.exec('access', ['ls-collaborators']) -}) - -t.test('access ls-collaborators on spec', async t => { - t.plan(1) - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmaccess: { - lsCollaborators: (spec) => { - t.equal(spec, 'yargs', 'should use expected spec') - return {} - }, - }, - }, + t.test('2fa=publish', async t => { + const { npm } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.setAccess({ spec: '@npmcli/test-package', + body: { + publish_requires_tfa: true, + automation_token_overrides_tfa: false, + } }) + await npm.exec('access', ['set', '2fa=publish', '@npmcli/test-package']) }) - await npm.exec('access', [ - 'ls-collaborators', - 'yargs', - ]) + t.test('2fa=automation', async t => { + const { npm } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.setAccess({ spec: '@npmcli/test-package', + body: { + publish_requires_tfa: true, + automation_token_overrides_tfa: true, + } }) + await npm.exec('access', ['set', '2fa=automation', '@npmcli/test-package']) + }) + t.test('2fa=invalid', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects( + npm.exec('access', ['set', '2fa=invalid']), + { code: 'EUSAGE' } + ) + }) + + t.end() }) diff --git a/test/lib/commands/adduser.js b/test/lib/commands/adduser.js index 8a9358f..90ed10d 100644 --- a/test/lib/commands/adduser.js +++ b/test/lib/commands/adduser.js @@ -1,197 +1,178 @@ const t = require('tap') -const { getCredentialsByURI, setCredentialsByURI } = - require('@npmcli/config').prototype +const fs = require('fs') +const path = require('path') +const ini = require('ini') -let result = '' - -const _flatOptions = { - authType: 'legacy', - registry: 'https://registry.npmjs.org/', - scope: '', - fromFlatOptions: true, -} - -let failSave = false -let deletedConfig = {} -let registryOutput = '' -let setConfig = {} -const authDummy = (npm, options) => { - if (!options.fromFlatOptions) { - throw new Error('did not pass full flatOptions to auth function') - } - - if (!options.log) { - // A quick to test to make sure a log gets passed to auth - // XXX: should be refactored with change to real mock npm - // https://github.com/npm/statusboard/issues/411 - throw new Error('pass log to auth') - } - - return Promise.resolve({ - message: 'success', - newCreds: { - username: 'u', - password: 'p', - email: 'u@npmjs.org', - }, - }) -} - -const deleteMock = (key, where) => { - deletedConfig = { - ...deletedConfig, - [key]: where, - } -} -const npm = { - flatOptions: _flatOptions, - config: { - delete: deleteMock, - get (key, where) { - if (!where || where === 'user') { - return _flatOptions[key] - } - }, - getCredentialsByURI, - async save () { - if (failSave) { - throw new Error('error saving user config') - } - }, - set (key, value, where) { - setConfig = { - ...setConfig, - [key]: { - value, - where, - }, - } - }, - setCredentialsByURI, - }, - output: msg => { - result = msg - }, -} - -const AddUser = t.mock('../../../lib/commands/adduser.js', { - npmlog: { - clearProgress: () => null, - disableProgress: () => null, - }, - 'proc-log': { - notice: (_, msg) => { - registryOutput = msg - }, - }, - '../../../lib/auth/legacy.js': authDummy, -}) - -const adduser = new AddUser(npm) - -t.afterEach(() => { - _flatOptions.authType = 'legacy' - _flatOptions.scope = '' - registryOutput = '' - deletedConfig = {} - setConfig = {} - result = '' - failSave = false -}) +const { load: loadMockNpm } = require('../../fixtures/mock-npm.js') +const mockGlobals = require('../../fixtures/mock-globals.js') +const MockRegistry = require('@npmcli/mock-registry') +const stream = require('stream') t.test('usage', async t => { + const { npm } = await loadMockNpm(t) + const adduser = await npm.cmd('adduser') t.match(adduser.usage, 'adduser', 'usage has command name in it') }) -t.test('simple login', async t => { - await adduser.exec([]) - t.equal( - registryOutput, - 'Log in on https://registry.npmjs.org/', - 'should have correct message result' - ) - - t.same( - deletedConfig, - { - _token: 'user', - _password: 'user', - username: 'user', - _auth: 'user', - _authtoken: 'user', - '-authtoken': 'user', - _authToken: 'user', - '//registry.npmjs.org/:-authtoken': 'user', - '//registry.npmjs.org/:_authToken': 'user', - '//registry.npmjs.org/:_authtoken': 'user', - '//registry.npmjs.org/:always-auth': 'user', - '//registry.npmjs.org/:email': 'user', - }, - 'should delete token in user config' - ) - - t.same( - setConfig, - { - '//registry.npmjs.org/:_password': { value: 'cA==', where: 'user' }, - '//registry.npmjs.org/:username': { value: 'u', where: 'user' }, - email: { value: 'u@npmjs.org', where: 'user' }, - }, - 'should set expected user configs' - ) - - t.equal( - result, - 'success', - 'should output auth success msg' - ) -}) - -t.test('bad auth type', async t => { - _flatOptions.authType = 'foo' - - await t.rejects( - adduser.exec([]), - /no such auth module/, - 'should throw bad auth type error' - ) -}) - -t.test('scoped login', async t => { - _flatOptions.scope = '@myscope' - - await adduser.exec([]) - - t.same( - setConfig['@myscope:registry'], - { value: 'https://registry.npmjs.org/', where: 'user' }, - 'should set scoped registry config' - ) -}) - -t.test('scoped login with valid scoped registry config', async t => { - _flatOptions['@myscope:registry'] = 'https://diff-registry.npmjs.com/' - _flatOptions.scope = '@myscope' - - t.teardown(() => { - delete _flatOptions['@myscope:registry'] +t.test('legacy', async t => { + t.test('simple adduser', async t => { + const stdin = new stream.PassThrough() + stdin.write('test-user\n') + stdin.write('test-password\n') + stdin.write('test-email@npmjs.org\n') + mockGlobals(t, { + 'process.stdin': stdin, + 'process.stdout': new stream.PassThrough(), // to quiet readline + }, { replace: true }) + const { npm, home } = await loadMockNpm(t, { + config: { 'auth-type': 'legacy' }, + homeDir: { + '.npmrc': [ + '//registry.npmjs.org/:_authToken=user', + '//registry.npmjs.org/:always-auth=user', + '//registry.npmjs.org/:email=test-email-old@npmjs.org', + ].join('\n'), + }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.couchadduser({ + username: 'test-user', + password: 'test-password', + email: 'test-email@npmjs.org', + token: 'npm_test-token', + }) + await npm.exec('adduser', []) + t.same(npm.config.get('email'), 'test-email-old@npmjs.org') + t.same(npm.config.get('//registry.npmjs.org/:_authToken'), 'npm_test-token') + const rc = ini.parse(fs.readFileSync(path.join(home, '.npmrc'), 'utf8')) + t.same(rc, { + '//registry.npmjs.org/:_authToken': 'npm_test-token', + email: 'test-email-old@npmjs.org', + }, 'should only have token and un-nerfed old email') }) - await adduser.exec([]) + t.test('scoped adduser', async t => { + const stdin = new stream.PassThrough() + stdin.write('test-user\n') + stdin.write('test-password\n') + stdin.write('test-email@npmjs.org\n') + mockGlobals(t, { + 'process.stdin': stdin, + 'process.stdout': new stream.PassThrough(), // to quiet readline + }, { replace: true }) + const { npm, home } = await loadMockNpm(t, { + config: { + 'auth-type': 'legacy', + scope: '@myscope', + }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.couchadduser({ + username: 'test-user', + password: 'test-password', + email: 'test-email@npmjs.org', + token: 'npm_test-token', + }) + await npm.exec('adduser', []) + t.same(npm.config.get('//registry.npmjs.org/:_authToken'), 'npm_test-token') + t.same(npm.config.get('@myscope:registry'), 'https://registry.npmjs.org/') + const rc = ini.parse(fs.readFileSync(path.join(home, '.npmrc'), 'utf8')) + t.same(rc, { + '//registry.npmjs.org/:_authToken': 'npm_test-token', + '@myscope:registry': 'https://registry.npmjs.org/', + }, 'should only have token and scope:registry') + }) - t.same( - setConfig['@myscope:registry'], - { value: 'https://diff-registry.npmjs.com/', where: 'user' }, - 'should keep scoped registry config' - ) + t.test('scoped adduser with valid scoped registry config', async t => { + const stdin = new stream.PassThrough() + stdin.write('test-user\n') + stdin.write('test-password\n') + stdin.write('test-email@npmjs.org\n') + mockGlobals(t, { + 'process.stdin': stdin, + 'process.stdout': new stream.PassThrough(), // to quiet readline + }, { replace: true }) + const { npm, home } = await loadMockNpm(t, { + homeDir: { + '.npmrc': '@myscope:registry=https://diff-registry.npmjs.org', + }, + config: { + 'auth-type': 'legacy', + scope: '@myscope', + }, + }) + const registry = new MockRegistry({ + tap: t, + registry: 'https://diff-registry.npmjs.org', + }) + registry.couchadduser({ + username: 'test-user', + password: 'test-password', + email: 'test-email@npmjs.org', + token: 'npm_test-token', + }) + await npm.exec('adduser', []) + t.same(npm.config.get('//diff-registry.npmjs.org/:_authToken'), 'npm_test-token') + t.same(npm.config.get('@myscope:registry'), 'https://diff-registry.npmjs.org') + const rc = ini.parse(fs.readFileSync(path.join(home, '.npmrc'), 'utf8')) + t.same(rc, { + '@myscope:registry': 'https://diff-registry.npmjs.org', + '//diff-registry.npmjs.org/:_authToken': 'npm_test-token', + }, 'should only have token and scope:registry') + }) + + t.test('save config failure', async t => { + const stdin = new stream.PassThrough() + stdin.write('test-user\n') + stdin.write('test-password\n') + stdin.write('test-email@npmjs.org\n') + mockGlobals(t, { + 'process.stdin': stdin, + 'process.stdout': new stream.PassThrough(), // to quiet readline + }, { replace: true }) + const { npm } = await loadMockNpm(t, { + config: { 'auth-type': 'legacy' }, + homeDir: { + '.npmrc': {}, + }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.couchadduser({ + username: 'test-user', + password: 'test-password', + email: 'test-email@npmjs.org', + token: 'npm_test-token', + }) + await t.rejects(npm.exec('adduser', [])) + }) + t.end() }) -t.test('save config failure', async t => { - failSave = true - - await t.rejects( - adduser.exec([]), - /error saving user config/, - 'should throw config.save error' - ) +t.test('web', t => { + t.test('basic adduser', async t => { + const { npm, home } = await loadMockNpm(t, { + config: { 'auth-type': 'web' }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.webadduser({ token: 'npm_test-token' }) + await npm.exec('adduser', []) + t.same(npm.config.get('//registry.npmjs.org/:_authToken'), 'npm_test-token') + const rc = ini.parse(fs.readFileSync(path.join(home, '.npmrc'), 'utf8')) + t.same(rc, { + '//registry.npmjs.org/:_authToken': 'npm_test-token', + }) + }) + t.end() }) diff --git a/test/lib/commands/audit.js b/test/lib/commands/audit.js index 05f268d..02b00f7 100644 --- a/test/lib/commands/audit.js +++ b/test/lib/commands/audit.js @@ -1,139 +1,219 @@ +const fs = require('fs') +const zlib = require('zlib') +const path = require('path') const t = require('tap') -const { load: _loadMockNpm } = require('../../fixtures/mock-npm') -t.test('should audit using Arborist', async t => { - let ARB_ARGS = null - let AUDIT_CALLED = false - let REIFY_FINISH_CALLED = false - let AUDIT_REPORT_CALLED = false - let ARB_OBJ = null +const { load: loadMockNpm } = require('../../fixtures/mock-npm') +const MockRegistry = require('@npmcli/mock-registry') - const loadMockNpm = (t) => _loadMockNpm(t, { - mocks: { - 'npm-audit-report': () => { - AUDIT_REPORT_CALLED = true - return { - report: 'there are vulnerabilities', - exitCode: 0, - } +const gunzip = zlib.gunzipSync +const gzip = zlib.gzipSync + +t.cleanSnapshot = str => str.replace(/package(s)? in [0-9]+[a-z]+/g, 'package$1 in xxx') + +const tree = { + 'package.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + dependencies: { + 'test-dep-a': '*', + }, + }), + 'package-lock.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + lockfileVersion: 2, + requires: true, + packages: { + '': { + xname: 'scratch', + version: '1.0.0', + dependencies: { + 'test-dep-a': '*', + }, + devDependencies: {}, }, - '@npmcli/arborist': function (args) { - ARB_ARGS = args - ARB_OBJ = this - this.audit = () => { - AUDIT_CALLED = true - this.auditReport = {} - } - }, - '../../lib/utils/reify-finish.js': (npm, arb) => { - if (arb !== ARB_OBJ) { - throw new Error('got wrong object passed to reify-output') - } - - REIFY_FINISH_CALLED = true + 'node_modules/test-dep-a': { + name: 'test-dep-a', + version: '1.0.0', }, }, + dependencies: { + 'test-dep-a': { + version: '1.0.0', + }, + }, + }), + 'test-dep-a-vuln': { + 'package.json': JSON.stringify({ + name: 'test-dep-a', + version: '1.0.0', + }), + 'vulnerable.txt': 'vulnerable test-dep-a', + }, + 'test-dep-a-fixed': { + 'package.json': JSON.stringify({ + name: 'test-dep-a', + version: '1.0.1', + }), + 'fixed.txt': 'fixed test-dep-a', + }, +} + +t.test('normal audit', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: tree, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - t.test('audit', async t => { - const { npm, outputs } = await loadMockNpm(t) - await npm.exec('audit', []) - t.match(ARB_ARGS, { audit: true, path: npm.prefix }) - t.equal(AUDIT_CALLED, true, 'called audit') - t.equal(AUDIT_REPORT_CALLED, true, 'called audit report') - t.match(outputs, [['there are vulnerabilities']]) + const manifest = registry.manifest({ + name: 'test-dep-a', + packuments: [{ version: '1.0.0' }, { version: '1.0.1' }], }) + await registry.package({ manifest }) + const advisory = registry.advisory({ + id: 100, + vulnerable_versions: '<1.0.1', + }) + const bulkBody = gzip(JSON.stringify({ 'test-dep-a': ['1.0.0'] })) + registry.nock.post('/-/npm/v1/security/advisories/bulk', bulkBody) + .reply(200, { + 'test-dep-a': [advisory], + }) - t.test('audit fix', async t => { - const { npm } = await loadMockNpm(t) - await npm.exec('audit', ['fix']) - t.equal(REIFY_FINISH_CALLED, true, 'called reify output') - }) + await npm.exec('audit', []) + t.ok(process.exitCode, 'would have exited uncleanly') + process.exitCode = 0 + t.matchSnapshot(joinedOutput()) }) -t.test('should audit - json', async t => { - t.plan(1) - const { npm } = await _loadMockNpm(t, { - mocks: { - 'npm-audit-report': (_, opts) => { - t.match(opts.reporter, 'json') - return { - report: 'there are vulnerabilities', - exitCode: 0, - } +t.test('fallback audit ', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: tree, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifest = registry.manifest({ + name: 'test-dep-a', + packuments: [{ version: '1.0.0' }, { version: '1.0.1' }], + }) + await registry.package({ manifest }) + const advisory = registry.advisory({ + id: 100, + module_name: 'test-dep-a', + vulnerable_versions: '<1.0.1', + findings: [{ version: '1.0.0', paths: ['test-dep-a'] }], + }) + registry.nock + .post('/-/npm/v1/security/advisories/bulk').reply(404) + .post('/-/npm/v1/security/audits/quick', body => { + const unzipped = JSON.parse(gunzip(Buffer.from(body, 'hex'))) + return t.match(unzipped, { + name: 'test-dep', + version: '1.0.0', + requires: { 'test-dep-a': '*' }, + dependencies: { 'test-dep-a': { version: '1.0.0' } }, + }) + }).reply(200, { + actions: [], + muted: [], + advisories: { + 100: advisory, }, - '@npmcli/arborist': function () { - this.audit = () => { - this.auditReport = {} - } + metadata: { + vulnerabilities: { info: 0, low: 0, moderate: 0, high: 1, critical: 0 }, + dependencies: 1, + devDependencies: 0, + optionalDependencies: 0, + totalDependencies: 1, }, - '../../lib/utils/reify-output.js': () => {}, - }, + }) + await npm.exec('audit', []) + t.ok(process.exitCode, 'would have exited uncleanly') + process.exitCode = 0 + t.matchSnapshot(joinedOutput()) +}) + +t.test('json audit', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: tree, config: { json: true, }, }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + + const manifest = registry.manifest({ + name: 'test-dep-a', + packuments: [{ version: '1.0.0' }, { version: '1.0.1' }], + }) + await registry.package({ manifest }) + const advisory = registry.advisory({ id: 100 }) + const bulkBody = gzip(JSON.stringify({ 'test-dep-a': ['1.0.0'] })) + registry.nock.post('/-/npm/v1/security/advisories/bulk', bulkBody) + .reply(200, { + 'test-dep-a': [advisory], + }) + await npm.exec('audit', []) + t.ok(process.exitCode, 'would have exited uncleanly') + process.exitCode = 0 + t.matchSnapshot(joinedOutput()) }) -t.test('report endpoint error', async t => { - const loadMockNpm = (t, options) => _loadMockNpm(t, { - mocks: { - 'npm-audit-report': () => { - throw new Error('should not call audit report when there are errors') - }, - '@npmcli/arborist': function () { - this.audit = () => { - this.auditReport = { - error: { - message: 'hello, this didnt work', - method: 'POST', - uri: 'https://example.com/', - headers: { - head: ['ers'], - }, - statusCode: 420, - body: 'this is a string', - }, - } - } - }, - '../../lib/utils/reify-output.js': () => {}, +t.test('audit fix - bulk endpoint', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: tree, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifest = registry.manifest({ + name: 'test-dep-a', + packuments: [{ version: '1.0.0' }, { version: '1.0.1' }], + }) + await registry.package({ + manifest, + tarballs: { + '1.0.1': path.join(npm.prefix, 'test-dep-a-fixed'), }, - ...options, }) - - t.test('json=false', async t => { - const { npm, outputs, logs } = await loadMockNpm(t, { config: { json: false } }) - await t.rejects(npm.exec('audit', []), 'audit endpoint returned an error') - t.match(logs.warn, [['audit', 'hello, this didnt work']]) - t.strictSame(outputs, [['this is a string']]) - }) - - t.test('json=true', async t => { - const { npm, outputs, logs } = await loadMockNpm(t, { config: { json: true } }) - await t.rejects(npm.exec('audit', []), 'audit endpoint returned an error') - t.match(logs.warn, [['audit', 'hello, this didnt work']]) - t.strictSame(outputs, [[ - '{\n' + - ' "message": "hello, this didnt work",\n' + - ' "method": "POST",\n' + - ' "uri": "https://example.com/",\n' + - ' "headers": {\n' + - ' "head": [\n' + - ' "ers"\n' + - ' ]\n' + - ' },\n' + - ' "statusCode": 420,\n' + - ' "body": "this is a string"\n' + - '}', - ], - ]) + const advisory = registry.advisory({ id: 100, vulnerable_versions: '1.0.0' }) + registry.nock.post('/-/npm/v1/security/advisories/bulk', body => { + const unzipped = JSON.parse(gunzip(Buffer.from(body, 'hex'))) + return t.same(unzipped, { 'test-dep-a': ['1.0.0'] }) }) + .reply(200, { // first audit + 'test-dep-a': [advisory], + }) + .post('/-/npm/v1/security/advisories/bulk', body => { + const unzipped = JSON.parse(gunzip(Buffer.from(body, 'hex'))) + return t.same(unzipped, { 'test-dep-a': ['1.0.1'] }) + }) + .reply(200, { // after fix + 'test-dep-a': [], + }) + await npm.exec('audit', ['fix']) + t.matchSnapshot(joinedOutput()) + const pkg = fs.readFileSync(path.join(npm.prefix, 'package-lock.json'), 'utf8') + t.matchSnapshot(pkg, 'lockfile has test-dep-a@1.0.1') + t.ok( + fs.existsSync(path.join(npm.prefix, 'node_modules', 'test-dep-a', 'fixed.txt')), + 'has test-dep-a@1.0.1 on disk' + ) }) t.test('completion', async t => { - const { npm } = await _loadMockNpm(t) + const { npm } = await loadMockNpm(t) const audit = await npm.cmd('audit') t.test('fix', async t => { await t.resolveMatch( @@ -157,3 +237,1485 @@ t.test('completion', async t => { }) }) }) + +t.test('audit signatures', async t => { + const VALID_REGISTRY_KEYS = { + keys: [{ + expires: null, + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + keytype: 'ecdsa-sha2-nistp256', + scheme: 'ecdsa-sha2-nistp256', + key: 'MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE1Olb3zMAFFxXKHiIkQO5cJ3Yhl5i6UPp+' + + 'IhuteBJbuHcA5UogKo0EWtlWwW6KSaKoTNEYL7JlCQiVnkhBktUgg==', + }], + } + + const MISMATCHING_REGISTRY_KEYS = { + keys: [{ + expires: null, + keyid: 'SHA256:2l3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + keytype: 'ecdsa-sha2-nistp256', + scheme: 'ecdsa-sha2-nistp256', + key: 'MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE1Olb3zMAFFxXKHiIkQO5cJ3Yhl5i6UPp+' + + 'IhuteBJbuHcA5UogKo0EWtlWwW6KSaKoTNEYL7JlCQiVnkhBktUgg==', + }], + } + + const EXPIRED_REGISTRY_KEYS = { + keys: [{ + expires: '2021-01-11T15:45:42.144Z', + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + keytype: 'ecdsa-sha2-nistp256', + scheme: 'ecdsa-sha2-nistp256', + key: 'MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE1Olb3zMAFFxXKHiIkQO5cJ3Yhl5i6UPp+' + + 'IhuteBJbuHcA5UogKo0EWtlWwW6KSaKoTNEYL7JlCQiVnkhBktUgg==', + }], + } + + const installWithValidSigs = { + 'package.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + dependencies: { + 'kms-demo': '1.0.0', + }, + }), + node_modules: { + 'kms-demo': { + 'package.json': JSON.stringify({ + name: 'kms-demo', + version: '1.0.0', + }), + }, + }, + 'package-lock.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + lockfileVersion: 2, + requires: true, + packages: { + '': { + name: 'scratch', + version: '1.0.0', + dependencies: { + 'kms-demo': '^1.0.0', + }, + }, + 'node_modules/kms-demo': { + version: '1.0.0', + }, + }, + dependencies: { + 'kms-demo': { + version: '1.0.0', + }, + }, + }), + } + + const installWithAlias = { + 'package.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + dependencies: { + get: 'npm:node-fetch@^1.0.0', + }, + }), + node_modules: { + get: { + 'package.json': JSON.stringify({ + name: 'node-fetch', + version: '1.7.1', + }), + }, + }, + 'package-lock.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + lockfileVersion: 2, + requires: true, + packages: { + '': { + name: 'test-dep', + version: '1.0.0', + dependencies: { + get: 'npm:node-fetch@^1.0.0', + }, + }, + 'node_modules/demo': { + name: 'node-fetch', + version: '1.7.1', + }, + }, + dependencies: { + get: { + version: 'npm:node-fetch@1.7.1', + }, + }, + }), + } + + const noInstall = { + 'package.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + dependencies: { + 'kms-demo': '1.0.0', + }, + }), + 'package-lock.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + lockfileVersion: 2, + requires: true, + packages: { + '': { + name: 'scratch', + version: '1.0.0', + dependencies: { + 'kms-demo': '^1.0.0', + }, + }, + 'node_modules/kms-demo': { + version: '1.0.0', + }, + }, + dependencies: { + 'kms-demo': { + version: '1.0.0', + }, + }, + }), + } + + const workspaceInstall = { + 'package.json': JSON.stringify({ + name: 'workspaces-project', + version: '1.0.0', + workspaces: ['packages/*'], + dependencies: { + 'kms-demo': '^1.0.0', + }, + }), + node_modules: { + a: t.fixture('symlink', '../packages/a'), + b: t.fixture('symlink', '../packages/b'), + c: t.fixture('symlink', '../packages/c'), + 'kms-demo': { + 'package.json': JSON.stringify({ + name: 'kms-demo', + version: '1.0.0', + }), + }, + async: { + 'package.json': JSON.stringify({ + name: 'async', + version: '2.5.0', + }), + }, + 'light-cycle': { + 'package.json': JSON.stringify({ + name: 'light-cycle', + version: '1.4.2', + }), + }, + }, + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + dependencies: { + b: '^1.0.0', + async: '^2.0.0', + }, + }), + }, + b: { + 'package.json': JSON.stringify({ + name: 'b', + version: '1.0.0', + dependencies: { + 'light-cycle': '^1.0.0', + }, + }), + }, + c: { + 'package.json': JSON.stringify({ + name: 'c', + version: '1.0.0', + }), + }, + }, + } + + const installWithMultipleDeps = { + 'package.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + dependencies: { + 'kms-demo': '^1.0.0', + }, + devDependencies: { + async: '~1.1.0', + }, + }), + node_modules: { + 'kms-demo': { + 'package.json': JSON.stringify({ + name: 'kms-demo', + version: '1.0.0', + }), + }, + async: { + 'package.json': JSON.stringify({ + name: 'async', + version: '1.1.1', + dependencies: { + 'kms-demo': '^1.0.0', + }, + }), + }, + }, + 'package-lock.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + lockfileVersion: 2, + requires: true, + packages: { + '': { + name: 'scratch', + version: '1.0.0', + dependencies: { + 'kms-demo': '^1.0.0', + }, + devDependencies: { + async: '~1.0.0', + }, + }, + 'node_modules/kms-demo': { + version: '1.0.0', + }, + 'node_modules/async': { + version: '1.1.1', + }, + }, + dependencies: { + 'kms-demo': { + version: '1.0.0', + }, + async: { + version: '1.1.1', + dependencies: { + 'kms-demo': '^1.0.0', + }, + }, + }, + }), + } + + const installWithPeerDeps = { + 'package.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + peerDependencies: { + 'kms-demo': '^1.0.0', + }, + }), + node_modules: { + 'kms-demo': { + 'package.json': JSON.stringify({ + name: 'kms-demo', + version: '1.0.0', + }), + }, + }, + 'package-lock.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + lockfileVersion: 2, + requires: true, + packages: { + '': { + name: 'scratch', + version: '1.0.0', + peerDependencies: { + 'kms-demo': '^1.0.0', + }, + }, + 'node_modules/kms-demo': { + version: '1.0.0', + }, + }, + dependencies: { + 'kms-demo': { + version: '1.0.0', + }, + }, + }), + } + + const installWithOptionalDeps = { + 'package.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + dependencies: { + 'kms-demo': '^1.0.0', + }, + optionalDependencies: { + lorem: '^1.0.0', + }, + }, null, 2), + node_modules: { + 'kms-demo': { + 'package.json': JSON.stringify({ + name: 'kms-demo', + version: '1.0.0', + }), + }, + }, + 'package-lock.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + lockfileVersion: 2, + requires: true, + packages: { + '': { + name: 'scratch', + version: '1.0.0', + dependencies: { + 'kms-demo': '^1.0.0', + }, + optionalDependencies: { + lorem: '^1.0.0', + }, + }, + 'node_modules/kms-demo': { + version: '1.0.0', + }, + }, + dependencies: { + 'kms-demo': { + version: '1.0.0', + }, + }, + }), + } + + const installWithMultipleRegistries = { + 'package.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + dependencies: { + '@npmcli/arborist': '^1.0.0', + 'kms-demo': '^1.0.0', + }, + }), + node_modules: { + '@npmcli/arborist': { + 'package.json': JSON.stringify({ + name: '@npmcli/arborist', + version: '1.0.14', + }), + }, + 'kms-demo': { + 'package.json': JSON.stringify({ + name: 'kms-demo', + version: '1.0.0', + }), + }, + }, + 'package-lock.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + lockfileVersion: 2, + requires: true, + packages: { + '': { + name: 'test-dep', + version: '1.0.0', + dependencies: { + '@npmcli/arborist': '^1.0.0', + 'kms-demo': '^1.0.0', + }, + }, + 'node_modules/@npmcli/arborist': { + version: '1.0.14', + }, + 'node_modules/kms-demo': { + version: '1.0.0', + }, + }, + dependencies: { + '@npmcli/arborist': { + version: '1.0.14', + }, + 'kms-demo': { + version: '1.0.0', + }, + }, + }), + } + + const installWithThirdPartyRegistry = { + 'package.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + dependencies: { + '@npmcli/arborist': '^1.0.0', + }, + }), + node_modules: { + '@npmcli/arborist': { + 'package.json': JSON.stringify({ + name: '@npmcli/arborist', + version: '1.0.14', + }), + }, + }, + 'package-lock.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + lockfileVersion: 2, + requires: true, + packages: { + '': { + name: 'test-dep', + version: '1.0.0', + dependencies: { + '@npmcli/arborist': '^1.0.0', + }, + }, + 'node_modules/@npmcli/arborist': { + version: '1.0.14', + }, + }, + dependencies: { + '@npmcli/arborist': { + version: '1.0.14', + }, + }, + }), + } + + async function manifestWithValidSigs ({ registry }) { + const manifest = registry.manifest({ + name: 'kms-demo', + packuments: [{ + version: '1.0.0', + dist: { + tarball: 'https://registry.npmjs.org/kms-demo/-/kms-demo-1.0.0.tgz', + integrity: 'sha512-QqZ7VJ/8xPkS9s2IWB7Shj3qTJdcRyeXKbPQnsZjsPEwvutGv0EGeVchPca' + + 'uoiDFJlGbZMFq5GDCurAGNSghJQ==', + signatures: [ + { + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + sig: 'MEUCIDrLNspFeU5NZ6d55ycVBZIMXnPJi/XnI1Y2dlJvK8P1AiEAnXjn1IOMUd+U7YfPH' + + '+FNjwfLq+jCwfH8uaxocq+mpPk=', + }, + ], + }, + }], + }) + await registry.package({ manifest }) + } + + async function manifestWithInvalidSigs ({ registry, name = 'kms-demo', version = '1.0.0' }) { + const manifest = registry.manifest({ + name, + packuments: [{ + version, + dist: { + tarball: `https://registry.npmjs.org/${name}/-/${name}-${version}.tgz`, + integrity: 'sha512-QqZ7VJ/8xPkS9s2IWB7Shj3qTJdcRyeXKbPQnsZjsPEwvutGv0EGeVchPca' + + 'uoiDFJlGbZMFq5GDCurAGNSghJQ==', + signatures: [ + { + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + sig: 'bogus', + }, + ], + }, + }], + }) + await registry.package({ manifest }) + } + + async function manifestWithoutSigs ({ registry, name = 'kms-demo', version = '1.0.0' }) { + const manifest = registry.manifest({ + name, + packuments: [{ + version, + }], + }) + await registry.package({ manifest }) + } + + t.test('with valid signatures', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithValidSigs, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithValidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 0, 'should exit successfully') + process.exitCode = 0 + t.match(joinedOutput(), /audited 1 package/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('with valid signatures using alias', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithAlias, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + const manifest = registry.manifest({ + name: 'node-fetch', + packuments: [{ + version: '1.7.1', + dist: { + tarball: 'https://registry.npmjs.org/node-fetch/-/node-fetch-1.7.1.tgz', + integrity: 'sha512-j8XsFGCLw79vWXkZtMSmmLaOk9z5SQ9bV/tkbZVCqvgwzrjAGq6' + + '6igobLofHtF63NvMTp2WjytpsNTGKa+XRIQ==', + signatures: [ + { + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + sig: 'MEYCIQDEn2XrrMXlRm+wh2tOIUyb0Km3ZujfT+6Mf61OXGK9zQIhANnPauUwx3' + + 'N9RcQYQakDpOmLvYzNkySh7fmzmvyhk21j', + }, + ], + }, + }], + }) + await registry.package({ manifest }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 0, 'should exit successfully') + process.exitCode = 0 + t.match(joinedOutput(), /audited 1 package/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('with multiple valid signatures and one invalid', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + dependencies: { + 'kms-demo': '^1.0.0', + 'node-fetch': '^1.6.0', + }, + devDependencies: { + async: '~2.1.0', + }, + }), + node_modules: { + 'kms-demo': { + 'package.json': JSON.stringify({ + name: 'kms-demo', + version: '1.0.0', + }), + }, + async: { + 'package.json': JSON.stringify({ + name: 'async', + version: '2.5.0', + }), + }, + 'node-fetch': { + 'package.json': JSON.stringify({ + name: 'node-fetch', + version: '1.6.0', + }), + }, + }, + 'package-lock.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + lockfileVersion: 2, + requires: true, + packages: { + '': { + name: 'test-dep', + version: '1.0.0', + dependencies: { + 'kms-demo': '^1.0.0', + 'node-fetch': '^1.6.0', + }, + devDependencies: { + async: '~2.1.0', + }, + }, + 'node_modules/kms-demo': { + version: '1.0.0', + }, + 'node_modules/async': { + version: '2.5.0', + }, + 'node_modules/node-fetch': { + version: '1.6.0', + }, + }, + dependencies: { + 'kms-demo': { + version: '1.0.0', + }, + 'node-fetch': { + version: '1.6.0', + }, + async: { + version: '2.5.0', + }, + }, + }), + }, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithValidSigs({ registry }) + const asyncManifest = registry.manifest({ + name: 'async', + packuments: [{ + version: '2.5.0', + dist: { + tarball: 'https://registry.npmjs.org/async/-/async-2.5.0.tgz', + integrity: 'sha512-e+lJAJeNWuPCNyxZKOBdaJGyLGHugXVQtrAwtuAe2vhxTYxFT' + + 'KE73p8JuTmdH0qdQZtDvI4dhJwjZc5zsfIsYw==', + signatures: [ + { + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + sig: 'MEUCIQCM8cX2U3IVZKKhzQx1w5AlNSDUI+fVf4857K1qT0NTNgIgdT4qwEl' + + '/kg2vU1uIWUI0bGikRvVHCHlRs1rgjPMpRFA=', + }, + ], + }, + }], + }) + await registry.package({ manifest: asyncManifest }) + await manifestWithInvalidSigs({ registry, name: 'node-fetch', version: '1.6.0' }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.match(joinedOutput(), /audited 3 packages/) + t.match(joinedOutput(), /2 packages have verified registry signatures/) + t.match(joinedOutput(), /1 package has an invalid registry signature/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('with bundled and peer deps and no signatures', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithPeerDeps, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithValidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 0, 'should exit successfully') + process.exitCode = 0 + t.match(joinedOutput(), /audited 1 package/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('with invalid signatures', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithValidSigs, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithInvalidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.match(joinedOutput(), /invalid registry signature/) + t.match(joinedOutput(), /kms-demo@1.0.0/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('with valid and missing signatures', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithMultipleDeps, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithValidSigs({ registry }) + await manifestWithoutSigs({ registry, name: 'async', version: '1.1.1' }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.match(joinedOutput(), /audited 2 packages/) + t.match(joinedOutput(), /verified registry signature/) + t.match(joinedOutput(), /missing registry signature/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('with both invalid and missing signatures', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithMultipleDeps, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithInvalidSigs({ registry }) + await manifestWithoutSigs({ registry, name: 'async', version: '1.1.1' }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.match(joinedOutput(), /audited 2 packages/) + t.match(joinedOutput(), /invalid/) + t.match(joinedOutput(), /missing/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('with multiple invalid signatures', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithMultipleDeps, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithInvalidSigs({ registry, name: 'kms-demo', version: '1.0.0' }) + await manifestWithInvalidSigs({ registry, name: 'async', version: '1.1.1' }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.matchSnapshot(joinedOutput()) + }) + + t.test('with multiple missing signatures', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithMultipleDeps, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithoutSigs({ registry, name: 'kms-demo', version: '1.0.0' }) + await manifestWithoutSigs({ registry, name: 'async', version: '1.1.1' }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.matchSnapshot(joinedOutput()) + }) + + t.test('with signatures but no public keys', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: installWithValidSigs, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithValidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(404) + + await t.rejects( + npm.exec('audit', ['signatures']), + /no corresponding public key can be found/, + 'should throw with error' + ) + }) + + t.test('with signatures but the public keys are expired', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: installWithValidSigs, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithValidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, EXPIRED_REGISTRY_KEYS) + + await t.rejects( + npm.exec('audit', ['signatures']), + /the corresponding public key has expired/, + 'should throw with error' + ) + }) + + t.test('with signatures but the public keyid does not match', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: installWithValidSigs, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithValidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, MISMATCHING_REGISTRY_KEYS) + + await t.rejects( + npm.exec('audit', ['signatures']), + /no corresponding public key can be found/, + 'should throw with error' + ) + }) + + t.test('with keys but missing signature', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithValidSigs, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithoutSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.match( + joinedOutput(), + /registry is providing signing keys/ + ) + t.matchSnapshot(joinedOutput()) + }) + + t.test('output details about missing signatures', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithValidSigs, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithoutSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.match( + joinedOutput(), + /kms-demo/ + ) + t.matchSnapshot(joinedOutput()) + }) + + t.test('json output with valid signatures', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithValidSigs, + config: { + json: true, + }, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithValidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 0, 'should exit successfully') + process.exitCode = 0 + t.match(joinedOutput(), JSON.stringify({ invalid: [], missing: [] }, null, 2)) + t.matchSnapshot(joinedOutput()) + }) + + t.test('json output with invalid signatures', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithValidSigs, + config: { + json: true, + }, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithInvalidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.matchSnapshot(joinedOutput()) + }) + + t.test('json output with invalid and missing signatures', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithMultipleDeps, + config: { + json: true, + }, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithInvalidSigs({ registry }) + await manifestWithoutSigs({ registry, name: 'async', version: '1.1.1' }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.matchSnapshot(joinedOutput()) + }) + + t.test('omit dev dependencies with missing signature', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithMultipleDeps, + config: { + omit: ['dev'], + }, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithValidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 0, 'should exit successfully') + process.exitCode = 0 + t.match(joinedOutput(), /audited 1 package/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('third-party registry without keys (E404) does not verify', async t => { + const registryUrl = 'https://verdaccio-clone2.org' + const { npm } = await loadMockNpm(t, { + prefixDir: installWithThirdPartyRegistry, + config: { + '@npmcli:registry': registryUrl, + }, + }) + const registry = new MockRegistry({ tap: t, registry: registryUrl }) + const manifest = registry.manifest({ + name: '@npmcli/arborist', + packuments: [{ + version: '1.0.14', + dist: { + tarball: 'https://registry.npmjs.org/@npmcli/arborist/-/@npmcli/arborist-1.0.14.tgz', + integrity: 'sha512-caa8hv5rW9VpQKk6tyNRvSaVDySVjo9GkI7Wj/wcsFyxPm3tYrE' + + 'sFyTjSnJH8HCIfEGVQNjqqKXaXLFVp7UBag==', + }, + }], + }) + await registry.package({ manifest }) + registry.nock.get('/-/npm/v1/keys').reply(404) + + await t.rejects( + npm.exec('audit', ['signatures']), + /found no dependencies to audit that where installed from a supported registry/ + ) + }) + + t.test('third-party registry without keys (E400) does not verify', async t => { + const registryUrl = 'https://verdaccio-clone2.org' + const { npm } = await loadMockNpm(t, { + prefixDir: installWithThirdPartyRegistry, + config: { + '@npmcli:registry': registryUrl, + }, + }) + const registry = new MockRegistry({ tap: t, registry: registryUrl }) + const manifest = registry.manifest({ + name: '@npmcli/arborist', + packuments: [{ + version: '1.0.14', + dist: { + tarball: 'https://registry.npmjs.org/@npmcli/arborist/-/@npmcli/arborist-1.0.14.tgz', + integrity: 'sha512-caa8hv5rW9VpQKk6tyNRvSaVDySVjo9GkI7Wj/wcsFyxPm3tYrE' + + 'sFyTjSnJH8HCIfEGVQNjqqKXaXLFVp7UBag==', + }, + }], + }) + await registry.package({ manifest }) + registry.nock.get('/-/npm/v1/keys').reply(400) + + await t.rejects( + npm.exec('audit', ['signatures']), + /found no dependencies to audit that where installed from a supported registry/ + ) + }) + + t.test('third-party registry with keys and signatures', async t => { + const registryUrl = 'https://verdaccio-clone.org' + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithThirdPartyRegistry, + config: { + '@npmcli:registry': registryUrl, + }, + }) + const registry = new MockRegistry({ tap: t, registry: registryUrl }) + + const manifest = registry.manifest({ + name: '@npmcli/arborist', + packuments: [{ + version: '1.0.14', + dist: { + tarball: 'https://registry.npmjs.org/@npmcli/arborist/-/@npmcli/arborist-1.0.14.tgz', + integrity: 'sha512-caa8hv5rW9VpQKk6tyNRvSaVDySVjo9GkI7Wj/wcsFyxPm3tYrE' + + 'sFyTjSnJH8HCIfEGVQNjqqKXaXLFVp7UBag==', + signatures: [ + { + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + sig: 'MEUCIAvNpR3G0j7WOPUuVMhE0ZdM8PnDNcsoeFD8Iwz9YWIMAiEAn8cicDC2' + + 'Sf9MFQydqTv6S5XYsAh9Af1sig1nApNI11M=', + }, + ], + }, + }], + }) + await registry.package({ manifest }) + registry.nock.get('/-/npm/v1/keys') + .reply(200, { + keys: [{ + expires: null, + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + keytype: 'ecdsa-sha2-nistp256', + scheme: 'ecdsa-sha2-nistp256', + key: 'MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE1Olb3zMAFFxXKHiIkQO5cJ3Yhl5i6UPp+' + + 'IhuteBJbuHcA5UogKo0EWtlWwW6KSaKoTNEYL7JlCQiVnkhBktUgg==', + }], + }) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 0, 'should exit successfully') + process.exitCode = 0 + t.match(joinedOutput(), /audited 1 package/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('third-party registry with invalid signatures errors', async t => { + const registryUrl = 'https://verdaccio-clone.org' + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithThirdPartyRegistry, + config: { + '@npmcli:registry': registryUrl, + }, + }) + const registry = new MockRegistry({ tap: t, registry: registryUrl }) + + const manifest = registry.manifest({ + name: '@npmcli/arborist', + packuments: [{ + version: '1.0.14', + dist: { + tarball: 'https://registry.npmjs.org/@npmcli/arborist/-/@npmcli/arborist-1.0.14.tgz', + integrity: 'sha512-caa8hv5rW9VpQKk6tyNRvSaVDySVjo9GkI7Wj/wcsFyxPm3tYrE' + + 'sFyTjSnJH8HCIfEGVQNjqqKXaXLFVp7UBag==', + signatures: [ + { + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + sig: 'bogus', + }, + ], + }, + }], + }) + await registry.package({ manifest }) + registry.nock.get('/-/npm/v1/keys') + .reply(200, { + keys: [{ + expires: null, + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + keytype: 'ecdsa-sha2-nistp256', + scheme: 'ecdsa-sha2-nistp256', + key: 'MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE1Olb3zMAFFxXKHiIkQO5cJ3Yhl5i6UPp+' + + 'IhuteBJbuHcA5UogKo0EWtlWwW6KSaKoTNEYL7JlCQiVnkhBktUgg==', + }], + }) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.match(joinedOutput(), /https:\/\/verdaccio-clone.org/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('third-party registry with keys and missing signatures errors', async t => { + const registryUrl = 'https://verdaccio-clone.org' + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithThirdPartyRegistry, + config: { + '@npmcli:registry': registryUrl, + }, + }) + const registry = new MockRegistry({ tap: t, registry: registryUrl }) + + const manifest = registry.manifest({ + name: '@npmcli/arborist', + packuments: [{ + version: '1.0.14', + dist: { + tarball: 'https://registry.npmjs.org/@npmcli/arborist/-/@npmcli/arborist-1.0.14.tgz', + integrity: 'sha512-caa8hv5rW9VpQKk6tyNRvSaVDySVjo9GkI7Wj/wcsFyxPm3tYrE' + + 'sFyTjSnJH8HCIfEGVQNjqqKXaXLFVp7UBag==', + }, + }], + }) + await registry.package({ manifest }) + registry.nock.get('/-/npm/v1/keys') + .reply(200, { + keys: [{ + expires: null, + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + keytype: 'ecdsa-sha2-nistp256', + scheme: 'ecdsa-sha2-nistp256', + key: 'MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE1Olb3zMAFFxXKHiIkQO5cJ3Yhl5i6UPp+' + + 'IhuteBJbuHcA5UogKo0EWtlWwW6KSaKoTNEYL7JlCQiVnkhBktUgg==', + }], + }) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.match(joinedOutput(), /1 package has a missing registry signature/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('multiple registries with keys and signatures', async t => { + const registryUrl = 'https://verdaccio-clone.org' + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithMultipleRegistries, + config: { + '@npmcli:registry': registryUrl, + }, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + const thirdPartyRegistry = new MockRegistry({ + tap: t, + registry: registryUrl, + }) + await manifestWithValidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + const manifest = thirdPartyRegistry.manifest({ + name: '@npmcli/arborist', + packuments: [{ + version: '1.0.14', + dist: { + tarball: 'https://registry.npmjs.org/@npmcli/arborist/-/@npmcli/arborist-1.0.14.tgz', + integrity: 'sha512-caa8hv5rW9VpQKk6tyNRvSaVDySVjo9GkI7Wj/wcsFyxPm3tYrE' + + 'sFyTjSnJH8HCIfEGVQNjqqKXaXLFVp7UBag==', + signatures: [ + { + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + sig: 'MEUCIAvNpR3G0j7WOPUuVMhE0ZdM8PnDNcsoeFD8Iwz9YWIMAiEAn8cicDC2' + + 'Sf9MFQydqTv6S5XYsAh9Af1sig1nApNI11M=', + }, + ], + }, + }], + }) + await thirdPartyRegistry.package({ manifest }) + thirdPartyRegistry.nock.get('/-/npm/v1/keys') + .reply(200, { + keys: [{ + expires: null, + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + keytype: 'ecdsa-sha2-nistp256', + scheme: 'ecdsa-sha2-nistp256', + key: 'MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE1Olb3zMAFFxXKHiIkQO5cJ3Yhl5i6UPp+' + + 'IhuteBJbuHcA5UogKo0EWtlWwW6KSaKoTNEYL7JlCQiVnkhBktUgg==', + }], + }) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 0, 'should exit successfully') + process.exitCode = 0 + t.match(joinedOutput(), /audited 2 packages/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('errors with an empty install', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ + name: 'test-dep', + version: '1.0.0', + }), + }, + }) + + await t.rejects( + npm.exec('audit', ['signatures']), + /found no installed dependencies to audit/ + ) + }) + + t.test('errors when the keys endpoint errors', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: installWithMultipleDeps, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + registry.nock.get('/-/npm/v1/keys') + .reply(500, { error: 'keys broke' }) + + await t.rejects( + npm.exec('audit', ['signatures']), + /keys broke/ + ) + }) + + t.test('ignores optional dependencies', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithOptionalDeps, + }) + + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithValidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 0, 'should exit successfully') + process.exitCode = 0 + t.match(joinedOutput(), /audited 1 package/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('errors when no installed dependencies', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: noInstall, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await t.rejects( + npm.exec('audit', ['signatures']), + /found no dependencies to audit that where installed from a supported registry/ + ) + }) + + t.test('should skip missing non-prod deps', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ + name: 'delta', + version: '1.0.0', + devDependencies: { + chai: '^1.0.0', + }, + }, null, 2), + node_modules: {}, + }, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await t.rejects( + npm.exec('audit', ['signatures']), + /found no dependencies to audit that where installed from a supported registry/ + ) + }) + + t.test('should skip invalid pkg ranges', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ + name: 'delta', + version: '1.0.0', + dependencies: { + cat: '>=^2', + }, + }, null, 2), + node_modules: { + cat: { + 'package.json': JSON.stringify({ + name: 'cat', + version: '1.0.0', + }, null, 2), + }, + }, + }, + }) + + await t.rejects( + npm.exec('audit', ['signatures']), + /found no dependencies to audit that where installed from a supported registry/ + ) + }) + + t.test('should skip git specs', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ + name: 'delta', + version: '1.0.0', + dependencies: { + cat: 'github:username/foo', + }, + }, null, 2), + node_modules: { + cat: { + 'package.json': JSON.stringify({ + name: 'cat', + version: '1.0.0', + }, null, 2), + }, + }, + }, + }) + + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await t.rejects( + npm.exec('audit', ['signatures']), + /found no dependencies to audit that where installed from a supported registry/ + ) + }) + + t.test('errors for global packages', async t => { + const { npm } = await loadMockNpm(t, { + config: { global: true }, + }) + + await t.rejects( + npm.exec('audit', ['signatures']), + /`npm audit signatures` does not support global packages/, + { code: 'ECIGLOBAL' } + ) + }) + + t.test('with invalid signtaures and color output enabled', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: installWithValidSigs, + config: { color: 'always' }, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithInvalidSigs({ registry }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 1, 'should exit with error') + process.exitCode = 0 + t.match( + joinedOutput(), + // eslint-disable-next-line no-control-regex + /\u001b\[1m\u001b\[31minvalid\u001b\[39m\u001b\[22m registry signature/ + ) + t.matchSnapshot(joinedOutput()) + }) + + t.test('workspaces', async t => { + t.test('verifies registry deps and ignores local workspace deps', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: workspaceInstall, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + await manifestWithValidSigs({ registry }) + const asyncManifest = registry.manifest({ + name: 'async', + packuments: [{ + version: '2.5.0', + dist: { + tarball: 'https://registry.npmjs.org/async/-/async-2.5.0.tgz', + integrity: 'sha512-e+lJAJeNWuPCNyxZKOBdaJGyLGHugXVQtrAwtuAe2vhxTYxFT' + + 'KE73p8JuTmdH0qdQZtDvI4dhJwjZc5zsfIsYw==', + signatures: [ + { + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + sig: 'MEUCIQCM8cX2U3IVZKKhzQx1w5AlNSDUI+fVf4857K1qT0NTNgIgdT4qwEl' + + '/kg2vU1uIWUI0bGikRvVHCHlRs1rgjPMpRFA=', + }, + ], + }, + }], + }) + const lightCycleManifest = registry.manifest({ + name: 'light-cycle', + packuments: [{ + version: '1.4.2', + dist: { + tarball: 'https://registry.npmjs.org/light-cycle/-/light-cycle-1.4.2.tgz', + integrity: 'sha512-badZ3KMUaGwQfVcHjXTXSecYSXxT6f99bT+kVzBqmO10U1UNlE' + + 'thJ1XAok97E4gfDRTA2JJ3r0IeMPtKf0EJMw==', + signatures: [ + { + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + sig: 'MEUCIQDXjoxQz4MzPqaIuy2RJmBlcFp0UD3h9EhKZxxEz9IYZAIgLO0znG5' + + 'aGciTAg4u8fE0/UXBU4gU7JcvTZGxW2BmKGw=', + }, + ], + }, + }], + }) + await registry.package({ manifest: asyncManifest }) + await registry.package({ manifest: lightCycleManifest }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 0, 'should exit successfully') + process.exitCode = 0 + t.match(joinedOutput(), /audited 3 packages/) + t.matchSnapshot(joinedOutput()) + }) + + t.test('verifies registry deps when filtering by workspace name', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: workspaceInstall, + config: { workspace: ['./packages/a'] }, + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + const asyncManifest = registry.manifest({ + name: 'async', + packuments: [{ + version: '2.5.0', + dist: { + tarball: 'https://registry.npmjs.org/async/-/async-2.5.0.tgz', + integrity: 'sha512-e+lJAJeNWuPCNyxZKOBdaJGyLGHugXVQtrAwtuAe2vhxTYxFT' + + 'KE73p8JuTmdH0qdQZtDvI4dhJwjZc5zsfIsYw==', + signatures: [ + { + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + sig: 'MEUCIQCM8cX2U3IVZKKhzQx1w5AlNSDUI+fVf4857K1qT0NTNgIgdT4qwEl' + + '/kg2vU1uIWUI0bGikRvVHCHlRs1rgjPMpRFA=', + }, + ], + }, + }], + }) + const lightCycleManifest = registry.manifest({ + name: 'light-cycle', + packuments: [{ + version: '1.4.2', + dist: { + tarball: 'https://registry.npmjs.org/light-cycle/-/light-cycle-1.4.2.tgz', + integrity: 'sha512-badZ3KMUaGwQfVcHjXTXSecYSXxT6f99bT+kVzBqmO10U1UNlE' + + 'thJ1XAok97E4gfDRTA2JJ3r0IeMPtKf0EJMw==', + signatures: [ + { + keyid: 'SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA', + sig: 'MEUCIQDXjoxQz4MzPqaIuy2RJmBlcFp0UD3h9EhKZxxEz9IYZAIgLO0znG5' + + 'aGciTAg4u8fE0/UXBU4gU7JcvTZGxW2BmKGw=', + }, + ], + }, + }], + }) + await registry.package({ manifest: asyncManifest }) + await registry.package({ manifest: lightCycleManifest }) + registry.nock.get('/-/npm/v1/keys').reply(200, VALID_REGISTRY_KEYS) + + await npm.exec('audit', ['signatures']) + + t.equal(process.exitCode, 0, 'should exit successfully') + process.exitCode = 0 + t.match(joinedOutput(), /audited 2 packages/) + t.matchSnapshot(joinedOutput()) + }) + + // TODO: This should verify kms-demo, but doesn't because arborist filters + // workspace deps even if they're also root deps + t.test('verifies registry dep if workspaces is disabled', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: workspaceInstall, + config: { workspaces: false }, + }) + + await t.rejects( + npm.exec('audit', ['signatures']), + /found no installed dependencies to audit/ + ) + }) + }) +}) diff --git a/test/lib/commands/bin.js b/test/lib/commands/bin.js deleted file mode 100644 index 4de5a92..0000000 --- a/test/lib/commands/bin.js +++ /dev/null @@ -1,76 +0,0 @@ -const t = require('tap') -const { fake: mockNpm } = require('../../fixtures/mock-npm') - -t.test('bin', async t => { - t.plan(2) - const dir = '/bin/dir' - - const Bin = require('../../../lib/commands/bin.js') - - const npm = mockNpm({ - bin: dir, - config: { global: false }, - output: (output) => { - t.equal(output, dir, 'prints the correct directory') - }, - }) - const bin = new Bin(npm) - t.match(bin.usage, 'bin', 'usage has command name in it') - - await bin.exec([]) -}) - -t.test('bin -g', async t => { - t.plan(1) - const consoleError = console.error - t.teardown(() => { - console.error = consoleError - }) - - console.error = (output) => { - t.fail('should not have printed to console.error') - } - const dir = '/bin/dir' - - const Bin = t.mock('../../../lib/commands/bin.js', { - '../../../lib/utils/path.js': [dir], - }) - - const npm = mockNpm({ - bin: dir, - config: { global: true }, - output: (output) => { - t.equal(output, dir, 'prints the correct directory') - }, - }) - const bin = new Bin(npm) - - await bin.exec([]) -}) - -t.test('bin -g (not in path)', async t => { - t.plan(2) - const consoleError = console.error - t.teardown(() => { - console.error = consoleError - }) - - console.error = (output) => { - t.equal(output, '(not in PATH env variable)', 'prints env warning') - } - const dir = '/bin/dir' - - const Bin = t.mock('../../../lib/commands/bin.js', { - '../../../lib/utils/path.js': ['/not/my/dir'], - }) - const npm = mockNpm({ - bin: dir, - config: { global: true }, - output: (output) => { - t.equal(output, dir, 'prints the correct directory') - }, - }) - const bin = new Bin(npm) - - await bin.exec([]) -}) diff --git a/test/lib/commands/birthday.js b/test/lib/commands/birthday.js deleted file mode 100644 index 9156d3d..0000000 --- a/test/lib/commands/birthday.js +++ /dev/null @@ -1,15 +0,0 @@ -const t = require('tap') -const { load: loadMockNpm } = require('../../fixtures/mock-npm') - -t.test('birthday', async t => { - t.plan(2) - const { npm } = await loadMockNpm(t, { - mocks: { - libnpmexec: ({ args, yes }) => { - t.ok(yes) - t.match(args, ['@npmcli/npm-birthday']) - }, - }, - }) - await npm.exec('birthday', []) -}) diff --git a/test/lib/commands/bugs.js b/test/lib/commands/bugs.js index dbd618b..91d144b 100644 --- a/test/lib/commands/bugs.js +++ b/test/lib/commands/bugs.js @@ -62,7 +62,7 @@ const Bugs = t.mock('../../../lib/commands/bugs.js', { '../../../lib/utils/open-url.js': openUrl, }) -const bugs = new Bugs({ flatOptions: {} }) +const bugs = new Bugs({ flatOptions: {}, config: { validate: () => {} } }) t.test('usage', (t) => { t.match(bugs.usage, 'bugs', 'usage has command name in it') diff --git a/test/lib/commands/cache.js b/test/lib/commands/cache.js index fc92fac..fe2854f 100644 --- a/test/lib/commands/cache.js +++ b/test/lib/commands/cache.js @@ -1,442 +1,309 @@ const t = require('tap') -const { fake: mockNpm } = require('../../fixtures/mock-npm.js') +const { load: loadMockNpm } = require('../../fixtures/mock-npm.js') +const MockRegistry = require('@npmcli/mock-registry') +const mockGlobals = require('../../fixtures/mock-globals') + +const cacache = require('cacache') +const fs = require('fs') const path = require('path') -const npa = require('npm-package-arg') -let outputOutput = [] +const pkg = 'test-package' -let rimrafPath = '' -const rimraf = (path, cb) => { - rimrafPath = path - return cb() +t.cleanSnapshot = str => { + return str + .replace(/Finished in [0-9.s]+/g, 'Finished in xxxs') + .replace(/Cache verified and compressed (.*)/, 'Cache verified and compressed ({PATH})') } -let logOutput = [] - -let tarballStreamSpec = '' -let tarballStreamOpts = {} -const pacote = { - tarball: { - stream: (spec, handler, opts) => { - tarballStreamSpec = spec - tarballStreamOpts = opts - return handler({ - resume: () => {}, - promise: () => Promise.resolve(), - }) - }, - }, -} - -let cacacheEntries = {} -let cacacheContent = {} - -const setupCacacheFixture = () => { - cacacheEntries = {} - cacacheContent = {} - const pkgs = [ - ['webpack@4.44.1', 'https://registry.npmjs.org', true], - ['npm@1.2.0', 'https://registry.npmjs.org', true], - ['webpack@4.47.0', 'https://registry.npmjs.org', true], - ['foo@1.2.3-beta', 'https://registry.npmjs.org', true], - ['ape-ecs@2.1.7', 'https://registry.npmjs.org', true], - ['@fritzy/staydown@3.1.1', 'https://registry.npmjs.org', true], - ['@gar/npm-expansion@2.1.0', 'https://registry.npmjs.org', true], - ['@gar/npm-expansion@3.0.0-beta', 'https://registry.npmjs.org', true], - ['extemporaneously@44.2.2', 'https://somerepo.github.org', false], - ['corrupted@3.1.0', 'https://registry.npmjs.org', true], - ['missing-dist@23.0.0', 'https://registry.npmjs.org', true], - ['missing-version@16.2.0', 'https://registry.npmjs.org', true], - ] - pkgs.forEach(pkg => addCacachePkg(...pkg)) - // corrupt the packument - cacacheContent[ - /* eslint-disable-next-line max-len */ - [cacacheEntries['make-fetch-happen:request-cache:https://registry.npmjs.org/corrupted'].integrity] - ].data = Buffer.from('<>>>}"') - // nuke the version dist - cacacheContent[ - /* eslint-disable-next-line max-len */ - [cacacheEntries['make-fetch-happen:request-cache:https://registry.npmjs.org/missing-dist'].integrity] - ].data = Buffer.from(JSON.stringify({ versions: { '23.0.0': {} } })) - // make the version a non-object - cacacheContent[ - /* eslint-disable-next-line max-len */ - [cacacheEntries['make-fetch-happen:request-cache:https://registry.npmjs.org/missing-version'].integrity] - ].data = Buffer.from(JSON.stringify({ versions: 'hello' })) -} - -const packuments = {} - -let contentId = 0 -const cacacheVerifyStats = { - keptSize: 100, - verifiedContent: 1, - totalEntries: 1, - runTime: { total: 2000 }, -} - -const addCacacheKey = (key, content) => { - contentId++ - cacacheEntries[key] = { integrity: `${contentId}` } - cacacheContent[`${contentId}`] = {} -} -const addCacachePkg = (spec, registry, publicURL) => { - const parts = npa(spec) - const ver = parts.rawSpec || '1.0.0' - let url = `${registry}/${parts.name}/-/${parts.name}-${ver}.tgz` - if (!publicURL) { - url = `${registry}/aabbcc/${contentId}` - } - const key = `make-fetch-happen:request-cache:${url}` - const pkey = `make-fetch-happen:request-cache:${registry}/${parts.escapedName}` - if (!packuments[parts.escapedName]) { - packuments[parts.escapedName] = { - versions: {}, - } - addCacacheKey(pkey) - } - packuments[parts.escapedName].versions[ver] = { - dist: { - tarball: url, - }, - } - addCacacheKey(key) - cacacheContent[cacacheEntries[pkey].integrity] = { - data: Buffer.from(JSON.stringify(packuments[parts.escapedName])), - } -} - -const cacache = { - verify: (path) => { - return cacacheVerifyStats - }, - get: (path, key) => { - if (cacacheEntries[key] === undefined - || cacacheContent[cacacheEntries[key].integrity] === undefined) { - throw new Error() - } - return cacacheContent[cacacheEntries[key].integrity] - }, - rm: { - entry: (path, key) => { - if (cacacheEntries[key] === undefined) { - throw new Error() - } - delete cacacheEntries[key] - }, - content: (path, sha) => { - delete cacacheContent[sha] - }, - }, - ls: (path) => { - return cacacheEntries - }, -} - -const Cache = t.mock('../../../lib/commands/cache.js', { - cacache, - pacote, - rimraf, - 'proc-log': { - silly: (...args) => { - logOutput.push(['silly', ...args]) - }, - warn: (...args) => { - logOutput.push(['warn', ...args]) - }, - }, -}) - -const npm = mockNpm({ - cache: '/fake/path', - flatOptions: { force: false }, - config: { force: false }, - output: (msg) => { - outputOutput.push(msg) - }, -}) -const cache = new Cache(npm) - t.test('cache no args', async t => { + const { npm } = await loadMockNpm(t) await t.rejects( - cache.exec([]), + npm.exec('cache', []), { code: 'EUSAGE' }, 'should throw usage instructions' ) }) t.test('cache clean', async t => { + const { npm } = await loadMockNpm(t) await t.rejects( - cache.exec(['clean']), - 'the npm cache self-heals', + npm.exec('cache', ['clean']), + /the npm cache self-heals/, 'should throw warning' ) }) t.test('cache clean (force)', async t => { - npm.config.set('force', true) - npm.flatOptions.force = true - t.teardown(() => { - rimrafPath = '' - npm.config.force = false - npm.flatOptions.force = false + const { npm } = await loadMockNpm(t, { + cacheDir: { _cacache: {} }, + config: { force: true }, }) - - await cache.exec(['clear']) - t.equal(rimrafPath, path.join(npm.cache, '_cacache')) + const cache = path.join(npm.cache, '_cacache') + await npm.exec('cache', ['clean']) + t.notOk(fs.existsSync(cache), 'cache dir was removed') }) t.test('cache add no arg', async t => { - t.teardown(() => { - logOutput = [] - }) - + const { npm } = await loadMockNpm(t) await t.rejects( - cache.exec(['add']), + npm.exec('cache', ['add']), { code: 'EUSAGE', - message: 'Usage: First argument to `add` is required', + message: 'First argument to `add` is required', }, 'throws usage error' ) - t.strictSame(logOutput, [ - ['silly', 'cache add', 'args', []], - ], 'logs correctly') }) -t.test('cache add pkg only', async t => { - t.teardown(() => { - logOutput = [] - tarballStreamSpec = '' - tarballStreamOpts = {} +t.test('cache add single pkg', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: { + package: { + 'package.json': JSON.stringify({ + name: pkg, + version: '1.0.0', + }), + }, + }, }) - - await cache.exec(['add', 'mypkg']) - t.strictSame(logOutput, [ - ['silly', 'cache add', 'args', ['mypkg']], - ['silly', 'cache add', 'spec', 'mypkg'], - ], 'logs correctly') - t.equal(tarballStreamSpec, 'mypkg', 'passes the correct spec to pacote') - t.same(tarballStreamOpts, npm.flatOptions, 'passes the correct options to pacote') + const cache = path.join(npm.cache, '_cacache') + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifest = registry.manifest({ name: pkg }) + await registry.package({ manifest, tarballs: { '1.0.0': path.join(npm.prefix, 'package') } }) + await npm.exec('cache', ['add', pkg]) + t.equal(joinedOutput(), '') + // eslint-disable-next-line max-len + t.resolves(cacache.get(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package/-/test-package-1.0.0.tgz')) + // eslint-disable-next-line max-len + t.resolves(cacache.get(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package')) }) t.test('cache add multiple pkgs', async t => { - t.teardown(() => { - outputOutput = [] - tarballStreamSpec = '' - tarballStreamOpts = {} + const pkg2 = 'test-package-two' + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: { + package: { + 'package.json': JSON.stringify({ + name: pkg, + version: '1.0.0', + }), + }, + }, }) - - await cache.exec(['add', 'mypkg', 'anotherpkg']) - t.strictSame(logOutput, [ - ['silly', 'cache add', 'args', ['mypkg', 'anotherpkg']], - ['silly', 'cache add', 'spec', 'mypkg'], - ['silly', 'cache add', 'spec', 'anotherpkg'], - ], 'logs correctly') - t.equal(tarballStreamSpec, 'anotherpkg', 'passes the correct spec to pacote') - t.same(tarballStreamOpts, npm.flatOptions, 'passes the correct options to pacote') + const cache = path.join(npm.cache, '_cacache') + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifest = registry.manifest({ name: pkg }) + const manifest2 = registry.manifest({ name: pkg2 }) + await registry.package({ manifest, tarballs: { '1.0.0': path.join(npm.prefix, 'package') } }) + await registry.package({ + manifest: manifest2, tarballs: { '1.0.0': path.join(npm.prefix, 'package') }, + }) + await npm.exec('cache', ['add', pkg, pkg2]) + t.equal(joinedOutput(), '') + // eslint-disable-next-line max-len + t.resolves(cacache.get(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package/-/test-package-1.0.0.tgz')) + // eslint-disable-next-line max-len + t.resolves(cacache.get(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package')) + // eslint-disable-next-line max-len + t.resolves(cacache.get(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package-two/-/test-package-two-1.0.0.tgz')) + // eslint-disable-next-line max-len + t.resolves(cacache.get(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package-two')) }) t.test('cache ls', async t => { - t.teardown(() => { - outputOutput = [] - logOutput = [] - }) - setupCacacheFixture() - await cache.exec(['ls']) - t.strictSame(outputOutput, [ - /* eslint-disable-next-line max-len */ - 'make-fetch-happen:request-cache:https://registry.npmjs.org/@fritzy/staydown/-/@fritzy/staydown-3.1.1.tgz', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/@fritzy%2fstaydown', - /* eslint-disable-next-line max-len */ - 'make-fetch-happen:request-cache:https://registry.npmjs.org/@gar/npm-expansion/-/@gar/npm-expansion-2.1.0.tgz', - /* eslint-disable-next-line max-len */ - 'make-fetch-happen:request-cache:https://registry.npmjs.org/@gar/npm-expansion/-/@gar/npm-expansion-3.0.0-beta.tgz', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/@gar%2fnpm-expansion', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/ape-ecs', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/ape-ecs/-/ape-ecs-2.1.7.tgz', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/corrupted', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/corrupted/-/corrupted-3.1.0.tgz', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/foo', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/foo/-/foo-1.2.3-beta.tgz', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/missing-dist', - /* eslint-disable-next-line max-len */ - 'make-fetch-happen:request-cache:https://registry.npmjs.org/missing-dist/-/missing-dist-23.0.0.tgz', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/missing-version', - /* eslint-disable-next-line max-len */ - 'make-fetch-happen:request-cache:https://registry.npmjs.org/missing-version/-/missing-version-16.2.0.tgz', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/npm', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/npm/-/npm-1.2.0.tgz', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/webpack', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/webpack/-/webpack-4.44.1.tgz', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/webpack/-/webpack-4.47.0.tgz', - 'make-fetch-happen:request-cache:https://somerepo.github.org/aabbcc/14', - 'make-fetch-happen:request-cache:https://somerepo.github.org/extemporaneously', - ]) + const keys = [ + 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package', + // eslint-disable-next-line max-len + 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package/-/test-package-1.0.0.tgz', + ] + const { npm, joinedOutput } = await loadMockNpm(t) + const cache = path.join(npm.cache, '_cacache') + for (const key of keys) { + await cacache.put(cache, key, 'test data') + } + await npm.exec('cache', ['ls']) + t.matchSnapshot(joinedOutput(), 'logs cache entries') }) t.test('cache ls pkgs', async t => { - t.teardown(() => { - outputOutput = [] - }) - await cache.exec(['ls', 'webpack@>4.44.1', 'npm']) - t.strictSame(outputOutput, [ + const keys = [ 'make-fetch-happen:request-cache:https://registry.npmjs.org/npm', 'make-fetch-happen:request-cache:https://registry.npmjs.org/npm/-/npm-1.2.0.tgz', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/webpack', 'make-fetch-happen:request-cache:https://registry.npmjs.org/webpack/-/webpack-4.47.0.tgz', - ]) + 'make-fetch-happen:request-cache:https://registry.npmjs.org/webpack/-/webpack-4.40.0.tgz', + ] + const { npm, joinedOutput } = await loadMockNpm(t) + const cache = path.join(npm.cache, '_cacache') + for (const key of keys) { + await cacache.put(cache, key, 'test data') + } + await cacache.put(cache, + 'make-fetch-happen:request-cache:https://registry.npmjs.org/webpack', + JSON.stringify({ versions: { + '4.40.0': { dist: { tarball: 'https://registry.npmjs.org/webpack/-/webpack-4.40.0.tgz' } }, + '4.47.0': { dist: { tarball: 'https://registry.npmjs.org/webpack/-/webpack-4.47.0.tgz' } }, + } }) + ) + await npm.exec('cache', ['ls', 'webpack@>4.44.1', 'npm']) + t.matchSnapshot(joinedOutput(), 'logs cache entries for npm and webpack and one webpack tgz') }) t.test('cache ls special', async t => { - t.teardown(() => { - outputOutput = [] - }) - await cache.exec(['ls', 'foo@1.2.3-beta']) - t.strictSame(outputOutput, [ + const { npm, joinedOutput } = await loadMockNpm(t) + const cache = path.join(npm.cache, '_cacache') + await cacache.put(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/foo', + JSON.stringify({ versions: { '1.2.3-beta': {} } }) + ) + await cacache.put(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/foo/-/foo-1.2.3-beta.tgz', - ]) + 'test-data' + ) + await npm.exec('cache', ['ls', 'foo@1.2.3-beta']) + t.matchSnapshot(joinedOutput(), 'logs cache entries for foo') }) t.test('cache ls nonpublic registry', async t => { - t.teardown(() => { - outputOutput = [] - }) - await cache.exec(['ls', 'extemporaneously']) - t.strictSame(outputOutput, [ - 'make-fetch-happen:request-cache:https://somerepo.github.org/aabbcc/14', + const { npm, joinedOutput } = await loadMockNpm(t) + const cache = path.join(npm.cache, '_cacache') + await cacache.put(cache, 'make-fetch-happen:request-cache:https://somerepo.github.org/extemporaneously', - ]) + JSON.stringify({ + versions: { '1.0.0': { dist: { tarball: 'https://somerepo.github.org/aabbcc/' } } }, + }) + ) + await cacache.put(cache, + 'make-fetch-happen:request-cache:https://somerepo.github.org/aabbcc/', + 'test data' + ) + await npm.exec('cache', ['ls', 'extemporaneously']) + t.matchSnapshot(joinedOutput(), 'logs cache entry for extemporaneously and its tarball') }) t.test('cache ls tagged', async t => { - t.teardown(() => { - outputOutput = [] - }) + const { npm } = await loadMockNpm(t) await t.rejects( - cache.exec(['ls', 'webpack@latest']), - 'tagged package', - 'should throw warning' + npm.exec('cache', ['ls', 'webpack@latest']), + { code: 'EUSAGE' }, + 'should throw usage error' ) }) t.test('cache ls scoped and scoped slash', async t => { - t.teardown(() => { - outputOutput = [] - }) - await cache.exec(['ls', '@fritzy/staydown', '@gar/npm-expansion']) - t.strictSame(outputOutput, [ - /* eslint-disable-next-line max-len */ + const keys = [ + // eslint-disable-next-line max-len 'make-fetch-happen:request-cache:https://registry.npmjs.org/@fritzy/staydown/-/@fritzy/staydown-3.1.1.tgz', 'make-fetch-happen:request-cache:https://registry.npmjs.org/@fritzy%2fstaydown', - /* eslint-disable-next-line max-len */ + // eslint-disable-next-line max-len 'make-fetch-happen:request-cache:https://registry.npmjs.org/@gar/npm-expansion/-/@gar/npm-expansion-2.1.0.tgz', 'make-fetch-happen:request-cache:https://registry.npmjs.org/@gar%2fnpm-expansion', - ]) + ] + const { npm, joinedOutput } = await loadMockNpm(t) + const cache = path.join(npm.cache, '_cacache') + for (const key of keys) { + await cacache.put(cache, key, 'test data') + } + await npm.exec('cache', ['ls', '@fritzy/staydown', '@gar/npm-expansion']) + t.matchSnapshot(joinedOutput(), 'logs cache entries for @gar and @fritzy') }) t.test('cache ls corrupted', async t => { - t.teardown(() => { - outputOutput = [] - }) - await cache.exec(['ls', 'corrupted']) - t.strictSame(outputOutput, [ + const keys = [ 'make-fetch-happen:request-cache:https://registry.npmjs.org/corrupted', 'make-fetch-happen:request-cache:https://registry.npmjs.org/corrupted/-/corrupted-3.1.0.tgz', - ]) -}) - -t.test('cache ls missing packument dist', async t => { - t.teardown(() => { - outputOutput = [] - }) - await cache.exec(['ls', 'missing-dist']) - t.strictSame(outputOutput, [ - 'make-fetch-happen:request-cache:https://registry.npmjs.org/missing-dist', - /* eslint-disable-next-line max-len */ - 'make-fetch-happen:request-cache:https://registry.npmjs.org/missing-dist/-/missing-dist-23.0.0.tgz', - ]) + ] + const { npm, joinedOutput } = await loadMockNpm(t) + const cache = path.join(npm.cache, '_cacache') + for (const key of keys) { + await cacache.put(cache, key, Buffer.from('<>>>}"')) + } + await npm.exec('cache', ['ls', 'corrupted']) + t.matchSnapshot(joinedOutput(), 'logs cache entries with bad data') }) t.test('cache ls missing packument version not an object', async t => { - t.teardown(() => { - outputOutput = [] - }) - await cache.exec(['ls', 'missing-version']) - t.strictSame(outputOutput, [ + const { npm, joinedOutput } = await loadMockNpm(t) + const cache = path.join(npm.cache, '_cacache') + await cacache.put(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/missing-version', - /* eslint-disable-next-line max-len */ - 'make-fetch-happen:request-cache:https://registry.npmjs.org/missing-version/-/missing-version-16.2.0.tgz', - ]) + JSON.stringify({ versions: 'not an object' }) + ) + await npm.exec('cache', ['ls', 'missing-version']) + t.matchSnapshot(joinedOutput(), 'logs cache entry for packument') }) t.test('cache rm', async t => { - t.teardown(() => { - outputOutput = [] - }) - await cache.exec(['rm', - 'make-fetch-happen:request-cache:https://registry.npmjs.org/webpack/-/webpack-4.44.1.tgz']) - t.strictSame(outputOutput, [ - /* eslint-disable-next-line max-len */ - 'Deleted: make-fetch-happen:request-cache:https://registry.npmjs.org/webpack/-/webpack-4.44.1.tgz', - ]) + const { npm, joinedOutput } = await loadMockNpm(t) + const cache = path.join(npm.cache, '_cacache') + // eslint-disable-next-line max-len + await cacache.put(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package', '{}') + // eslint-disable-next-line max-len + await cacache.put(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package/-/test-package-1.0.0.tgz', 'test data') + // eslint-disable-next-line max-len + await npm.exec('cache', ['rm', 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package/-/test-package-1.0.0.tgz']) + t.matchSnapshot(joinedOutput(), 'logs deleting single entry') + // eslint-disable-next-line max-len + t.resolves(cacache.get(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package')) + // eslint-disable-next-line max-len + t.rejects(cacache.get(cache, 'make-fetch-happen:request-cache:https://registry.npmjs.org/test-package/-/test-package-1.0.0.tgz')) }) t.test('cache rm unfound', async t => { - t.teardown(() => { - outputOutput = [] - logOutput = [] - }) - await cache.exec(['rm', 'made-up-key']) - t.strictSame(logOutput, [ - ['warn', 'Not Found: made-up-key'], - ], 'logs correctly') + const { npm, joinedOutput } = await loadMockNpm(t) + await npm.exec('cache', ['rm', 'made-up-key']) + t.same(joinedOutput(), '', 'no errors, no output') }) t.test('cache verify', async t => { - t.teardown(() => { - outputOutput = [] - }) + const { npm, joinedOutput } = await loadMockNpm(t) + await npm.exec('cache', ['verify']) + t.matchSnapshot(joinedOutput(), 'shows verified cache output') +}) - await cache.exec(['verify']) - t.match(outputOutput, [ - `Cache verified and compressed (${path.join(npm.cache, '_cacache')})`, - 'Content verified: 1 (100 bytes)', - 'Index entries: 1', - 'Finished in 2s', - ], 'prints correct output') +t.test('cache verify as part of home', async t => { + const { npm, joinedOutput, prefix } = await loadMockNpm(t) + mockGlobals(t, { 'process.env.HOME': path.dirname(prefix) }) + await npm.exec('cache', ['verify']) + t.match(joinedOutput(), 'Cache verified and compressed (~', 'contains ~ shorthand') }) t.test('cache verify w/ extra output', async t => { - npm.cache = `${process.env.HOME}/fake/path` - cacacheVerifyStats.badContentCount = 1 - cacacheVerifyStats.reclaimedCount = 2 - cacacheVerifyStats.reclaimedSize = 200 - cacacheVerifyStats.missingContent = 3 - t.teardown(() => { - npm.cache = '/fake/path' - outputOutput = [] - delete cacacheVerifyStats.badContentCount - delete cacacheVerifyStats.reclaimedCount - delete cacacheVerifyStats.reclaimedSize - delete cacacheVerifyStats.missingContent + const verify = { + runTime: { + markStartTime: 0, + fixPerms: 3, + garbageCollect: 54982, + rebuildIndex: 62779, + cleanTmp: 62781, + writeVerifile: 62783, + markEndTime: 62783, + total: 62783, + }, + verifiedContent: 17057, + reclaimedCount: 1144, + reclaimedSize: 248164665, + badContentCount: 12345, + keptSize: 1644485260, + missingContent: 92, + rejectedEntries: 92, + totalEntries: 20175, + } + const { npm, joinedOutput } = await loadMockNpm(t, { + mocks: { cacache: { verify: () => verify } }, }) - - await cache.exec(['check']) - t.match(outputOutput, [ - `Cache verified and compressed (~${path.join('/fake/path', '_cacache')})`, - 'Content verified: 1 (100 bytes)', - 'Corrupted content removed: 1', - 'Content garbage-collected: 2 (200 bytes)', - 'Missing content: 3', - 'Index entries: 1', - 'Finished in 2s', - ], 'prints correct output') + await npm.exec('cache', ['verify']) + t.matchSnapshot(joinedOutput(), 'shows extra output') }) t.test('cache completion', async t => { + const { npm } = await loadMockNpm(t) + const cache = await npm.cmd('cache') const { completion } = cache const testComp = (argv, expect) => { diff --git a/test/lib/commands/ci.js b/test/lib/commands/ci.js index 978cd03..bd3fd9b 100644 --- a/test/lib/commands/ci.js +++ b/test/lib/commands/ci.js @@ -1,316 +1,189 @@ -const fs = require('fs') -const util = require('util') -const readdir = util.promisify(fs.readdir) - const t = require('tap') +const { load: _loadMockNpm } = require('../../fixtures/mock-npm') +const MockRegistry = require('@npmcli/mock-registry') -const { fake: mockNpm } = require('../../fixtures/mock-npm') +const path = require('path') +const fs = require('fs') -t.test('should ignore scripts with --ignore-scripts', async t => { - const SCRIPTS = [] - let REIFY_CALLED = false - const CI = t.mock('../../../lib/commands/ci.js', { - '../../../lib/utils/reify-finish.js': async () => {}, - '@npmcli/run-script': ({ event }) => { - SCRIPTS.push(event) +// t.cleanSnapshot = str => str.replace(/ in [0-9ms]+/g, ' in {TIME}') + +const loadMockNpm = async (t, opts) => { + const mock = await _loadMockNpm(t, opts) + const registry = new MockRegistry({ + tap: t, + registry: mock.npm.config.get('registry'), + }) + return { registry, ...mock } +} + +const packageJson = { + name: 'test-package', + version: '1.0.0', + dependencies: { + abbrev: '^1.0.0', + }, +} +const packageLock = { + name: 'test-package', + version: '1.0.0', + lockfileVersion: 2, + requires: true, + packages: { + '': { + name: 'test-package', + version: '1.0.0', + dependencies: { + abbrev: '^1.0.0', + }, }, - '@npmcli/arborist': function () { - this.loadVirtual = async () => {} - this.reify = () => { - REIFY_CALLED = true - } - this.buildIdealTree = () => {} - this.virtualTree = { - inventory: new Map([ - ['foo', { name: 'foo', version: '1.0.0' }], - ]), - } - this.idealTree = { - inventory: new Map([ - ['foo', { name: 'foo', version: '1.0.0' }], - ]), - } + 'node_modules/abbrev': { + version: '1.0.0', + resolved: 'https://registry.npmjs.org/abbrev/-/abbrev-1.0.0.tgz', + // integrity changes w/ each test cause the path is different? + }, + }, + dependencies: { + abbrev: { + version: '1.0.0', + resolved: 'https://registry.npmjs.org/abbrev/-/abbrev-1.0.0.tgz', + // integrity changes w/ each test cause the path is different? + }, + }, +} + +const abbrev = { + 'package.json': '{"name": "abbrev", "version": "1.0.0"}', + test: 'test file', +} + +t.test('reifies, audits, removes node_modules', async t => { + const { npm, joinedOutput, registry } = await loadMockNpm(t, { + prefixDir: { + abbrev: abbrev, + 'package.json': JSON.stringify(packageJson), + 'package-lock.json': JSON.stringify(packageLock), + node_modules: { test: 'test file that will be removed' }, }, }) - - const npm = mockNpm({ - globalDir: 'path/to/node_modules/', - prefix: 'foo', - config: { - global: false, - 'ignore-scripts': true, - }, + const manifest = registry.manifest({ name: 'abbrev' }) + await registry.tarball({ + manifest: manifest.versions['1.0.0'], + tarball: path.join(npm.prefix, 'abbrev'), }) - const ci = new CI(npm) - - await ci.exec([]) - t.equal(REIFY_CALLED, true, 'called reify') - t.strictSame(SCRIPTS, [], 'no scripts when running ci') + registry.nock.post('/-/npm/v1/security/advisories/bulk').reply(200, {}) + await npm.exec('ci', []) + t.match(joinedOutput(), 'added 1 package, and audited 2 packages in') + const nmTest = path.join(npm.prefix, 'node_modules', 'test') + t.equal(fs.existsSync(nmTest), false, 'existing node_modules is removed') + const nmAbbrev = path.join(npm.prefix, 'node_modules', 'abbrev') + t.equal(fs.existsSync(nmAbbrev), true, 'installs abbrev') }) -t.test('should use Arborist and run-script', async t => { - const scripts = [ +t.test('--no-audit and --ignore-scripts', async t => { + const { npm, joinedOutput, registry } = await loadMockNpm(t, { + config: { + 'ignore-scripts': true, + audit: false, + }, + prefixDir: { + abbrev: { + 'package.json': '{"name": "abbrev", "version": "1.0.0"}', + test: 'test-file', + }, + 'package.json': JSON.stringify({ + ...packageJson, + // Would make install fail + scripts: { install: 'echo "SHOULD NOT RUN" && exit 1' }, + }), + 'package-lock.json': JSON.stringify(packageLock), + }, + }) + require('nock').emitter.on('no match', req => { + t.fail('Should not audit') + }) + const manifest = registry.manifest({ name: 'abbrev' }) + await registry.tarball({ + manifest: manifest.versions['1.0.0'], + tarball: path.join(npm.prefix, 'abbrev'), + }) + await npm.exec('ci', []) + t.match(joinedOutput(), 'added 1 package in', 'would fail if install script ran') +}) + +t.test('lifecycle scripts', async t => { + const scripts = [] + const { npm, registry } = await loadMockNpm(t, { + prefixDir: { + abbrev: abbrev, + 'package.json': JSON.stringify(packageJson), + 'package-lock.json': JSON.stringify(packageLock), + }, + mocks: { + '@npmcli/run-script': (opts) => { + t.ok(opts.banner) + scripts.push(opts.event) + }, + }, + }) + const manifest = registry.manifest({ name: 'abbrev' }) + await registry.tarball({ + manifest: manifest.versions['1.0.0'], + tarball: path.join(npm.prefix, 'abbrev'), + }) + registry.nock.post('/-/npm/v1/security/advisories/bulk').reply(200, {}) + await npm.exec('ci', []) + t.same(scripts, [ 'preinstall', 'install', 'postinstall', - 'prepublish', // XXX should we remove this finally?? + 'prepublish', 'preprepare', 'prepare', 'postprepare', - ] - - // set to true when timer starts, false when it ends - // when the test is done, we assert that all timers ended - const timers = {} - const onTime = msg => { - if (timers[msg]) { - throw new Error(`saw duplicate timer: ${msg}`) - } - timers[msg] = true - } - const onTimeEnd = msg => { - if (!timers[msg]) { - throw new Error(`ended timer that was not started: ${msg}`) - } - timers[msg] = false - } - process.on('time', onTime) - process.on('timeEnd', onTimeEnd) - t.teardown(() => { - process.removeListener('time', onTime) - process.removeListener('timeEnd', onTimeEnd) - }) - - const path = t.testdir({ - node_modules: { - foo: { - 'package.json': JSON.stringify({ - name: 'foo', - version: '1.2.3', - }), - }, - '.dotdir': {}, - '.dotfile': 'a file with a dot', - }, - }) - const expectRimrafs = 3 - let actualRimrafs = 0 - - const CI = t.mock('../../../lib/commands/ci.js', { - '../../../lib/utils/reify-finish.js': async () => {}, - '@npmcli/run-script': opts => { - t.match(opts, { event: scripts.shift() }) - }, - '@npmcli/arborist': function (args) { - t.ok(args, 'gets options object') - this.loadVirtual = () => { - t.ok(true, 'loadVirtual is called') - return Promise.resolve(true) - } - this.reify = () => { - t.ok(true, 'reify is called') - } - this.buildIdealTree = () => {} - this.virtualTree = { - inventory: new Map([ - ['foo', { name: 'foo', version: '1.0.0' }], - ]), - } - this.idealTree = { - inventory: new Map([ - ['foo', { name: 'foo', version: '1.0.0' }], - ]), - } - }, - rimraf: (path, ...args) => { - actualRimrafs++ - t.ok(path, 'rimraf called with path') - // callback is always last arg - args.pop()() - }, - '../../../lib/utils/reify-output.js': function (arb) { - t.ok(arb, 'gets arborist tree') - }, - }) - - const npm = mockNpm({ - prefix: path, - config: { - global: false, - }, - }) - const ci = new CI(npm) - - await ci.exec(null) - for (const [msg, result] of Object.entries(timers)) { - t.notOk(result, `properly resolved ${msg} timer`) - } - t.match(timers, { 'npm-ci:rm': false }, 'saw the rimraf timer') - t.equal(actualRimrafs, expectRimrafs, 'removed the right number of things') - t.strictSame(scripts, [], 'called all scripts') -}) - -t.test('should pass flatOptions to Arborist.reify', async t => { - t.plan(1) - const CI = t.mock('../../../lib/commands/ci.js', { - '../../../lib/utils/reify-finish.js': async () => {}, - '@npmcli/run-script': opts => {}, - '@npmcli/arborist': function () { - this.loadVirtual = () => Promise.resolve(true) - this.reify = async (options) => { - t.equal(options.production, true, 'should pass flatOptions to Arborist.reify') - } - this.buildIdealTree = () => {} - this.virtualTree = { - inventory: new Map([ - ['foo', { name: 'foo', version: '1.0.0' }], - ]), - } - this.idealTree = { - inventory: new Map([ - ['foo', { name: 'foo', version: '1.0.0' }], - ]), - } - }, - }) - const npm = mockNpm({ - prefix: 'foo', - flatOptions: { - production: true, - }, - }) - const ci = new CI(npm) - await ci.exec(null) + ], 'runs appropriate scripts, in order') }) t.test('should throw if package-lock.json or npm-shrinkwrap missing', async t => { - const testDir = t.testdir({ - 'index.js': 'some contents', - 'package.json': 'some info', - }) - - const CI = t.mock('../../../lib/commands/ci.js', { - '@npmcli/run-script': opts => {}, - '../../../lib/utils/reify-finish.js': async () => {}, - 'proc-log': { - verbose: () => { - t.ok(true, 'log fn called') + const { npm } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify(packageJson), + node_modules: { + 'test-file': 'should not be removed', }, }, }) - const npm = mockNpm({ - prefix: testDir, - config: { - global: false, - }, - }) - const ci = new CI(npm) - await t.rejects( - ci.exec(null), - /package-lock.json/, - 'throws error when there is no package-lock' - ) + await t.rejects(npm.exec('ci', []), { code: 'EUSAGE', message: /package-lock.json/ }) + const nmTestFile = path.join(npm.prefix, 'node_modules', 'test-file') + t.equal(fs.existsSync(nmTestFile), true, 'does not remove node_modules') }) t.test('should throw ECIGLOBAL', async t => { - const CI = t.mock('../../../lib/commands/ci.js', { - '@npmcli/run-script': opts => {}, - '../../../lib/utils/reify-finish.js': async () => {}, + const { npm } = await loadMockNpm(t, { + config: { global: true }, }) - const npm = mockNpm({ - prefix: 'foo', - config: { - global: true, - }, - }) - const ci = new CI(npm) - await t.rejects( - ci.exec(null), - { code: 'ECIGLOBAL' }, - 'throws error with global packages' - ) -}) - -t.test('should remove existing node_modules before installing', async t => { - t.plan(3) - const testDir = t.testdir({ - node_modules: { - 'some-file': 'some contents', - }, - }) - - const CI = t.mock('../../../lib/commands/ci.js', { - '@npmcli/run-script': opts => {}, - '../../../lib/utils/reify-finish.js': async () => {}, - '@npmcli/arborist': function () { - this.loadVirtual = () => Promise.resolve(true) - this.reify = async (options) => { - t.equal(options.packageLock, true, 'npm ci should never ignore lock') - t.equal(options.save, false, 'npm ci should never save') - // check if node_modules was removed before reifying - const contents = await readdir(testDir) - const nodeModules = contents.filter((path) => path.startsWith('node_modules')) - t.same(nodeModules, ['node_modules'], 'should only have the node_modules directory') - } - this.buildIdealTree = () => {} - this.virtualTree = { - inventory: new Map([ - ['foo', { name: 'foo', version: '1.0.0' }], - ]), - } - this.idealTree = { - inventory: new Map([ - ['foo', { name: 'foo', version: '1.0.0' }], - ]), - } - }, - }) - - const npm = mockNpm({ - prefix: testDir, - config: { - global: false, - }, - }) - const ci = new CI(npm) - - await ci.exec(null) + await t.rejects(npm.exec('ci', []), { code: 'ECIGLOBAL' }) }) t.test('should throw error when ideal inventory mismatches virtual', async t => { - const CI = t.mock('../../../lib/commands/ci.js', { - '../../../lib/utils/reify-finish.js': async () => {}, - '@npmcli/run-script': ({ event }) => {}, - '@npmcli/arborist': function () { - this.loadVirtual = async () => {} - this.reify = () => {} - this.buildIdealTree = () => {} - this.virtualTree = { - inventory: new Map([ - ['foo', { name: 'foo', version: '1.0.0' }], - ]), - } - this.idealTree = { - inventory: new Map([ - ['foo', { name: 'foo', version: '2.0.0' }], - ]), - } + const { npm, registry } = await loadMockNpm(t, { + prefixDir: { + abbrev: abbrev, + 'package.json': JSON.stringify({ + ...packageJson, + dependencies: { notabbrev: '^1.0.0' }, + }), + 'package-lock.json': JSON.stringify(packageLock), + node_modules: { + 'test-file': 'should not be removed', + }, }, }) - - const npm = mockNpm({ - globalDir: 'path/to/node_modules/', - prefix: 'foo', - config: { - global: false, - 'ignore-scripts': true, - }, - }) - const ci = new CI(npm) - - try { - await ci.exec([]) - } catch (err) { - t.matchSnapshot(err.message) - } + const manifest = registry.manifest({ name: 'notabbrev' }) + await registry.package({ manifest }) + await t.rejects( + npm.exec('ci', []), + { code: 'EUSAGE', message: /in sync/ } + ) + const nmTestFile = path.join(npm.prefix, 'node_modules', 'test-file') + t.equal(fs.existsSync(nmTestFile), true, 'does not remove node_modules') }) diff --git a/test/lib/commands/completion.js b/test/lib/commands/completion.js index dd571ba..6cc1677 100644 --- a/test/lib/commands/completion.js +++ b/test/lib/commands/completion.js @@ -6,20 +6,19 @@ const completionScript = fs .readFileSync(path.resolve(__dirname, '../../../lib/utils/completion.sh'), { encoding: 'utf8' }) .replace(/^#!.*?\n/, '') -const { load: _loadMockNpm } = require('../../fixtures/mock-npm') +const { load: loadMockNpm } = require('../../fixtures/mock-npm') const mockGlobals = require('../../fixtures/mock-globals') const loadMockCompletion = async (t, o = {}) => { - const { globals, windows, ...options } = o + const { globals = {}, windows, ...options } = o let resetGlobals = {} - if (globals) { - resetGlobals = mockGlobals(t, globals).reset - } - const res = await _loadMockNpm(t, { - mocks: { - '../../lib/utils/is-windows-shell.js': !!windows, - ...options.mocks, - }, + resetGlobals = mockGlobals(t, { + 'process.platform': windows ? 'win32' : 'posix', + 'process.env.term': 'notcygwin', + 'process.env.msystem': 'nogmingw', + ...globals, + }).reset + const res = await loadMockNpm(t, { ...options, }) const completion = await res.npm.cmd('completion') @@ -42,7 +41,7 @@ const loadMockCompletionComp = async (t, word, line) => t.test('completion', async t => { t.test('completion completion', async t => { const { outputs, completion, prefix } = await loadMockCompletion(t, { - testdir: { + prefixDir: { '.bashrc': 'aaa', '.zshrc': 'aaa', }, diff --git a/test/lib/commands/config.js b/test/lib/commands/config.js index 8217131..35872e7 100644 --- a/test/lib/commands/config.js +++ b/test/lib/commands/config.js @@ -1,12 +1,10 @@ const { join } = require('path') -const { promisify } = require('util') -const fs = require('fs') -const spawk = require('spawk') +const fs = require('fs/promises') +const ini = require('ini') +const tspawk = require('../../fixtures/tspawk') const t = require('tap') -spawk.preventUnmatched() - -const readFile = promisify(fs.readFile) +const spawk = tspawk(t) const Sandbox = require('../../fixtures/sandbox.js') @@ -142,60 +140,100 @@ t.test('config delete no args', async t => { t.test('config delete single key', async t => { // location defaults to user, so we work with a userconfig const home = t.testdir({ - '.npmrc': 'foo=bar\nbar=baz', + '.npmrc': 'access=public\nall=true', }) const sandbox = new Sandbox(t) - await sandbox.run('config', ['delete', 'foo'], { home }) + await sandbox.run('config', ['delete', 'access'], { home }) - t.equal(sandbox.config.get('foo'), undefined, 'foo should no longer be set') + t.equal(sandbox.config.get('access'), null, 'acces should be defaulted') - const contents = await readFile(join(home, '.npmrc'), { encoding: 'utf8' }) - t.not(contents.includes('foo='), 'foo was removed on disk') + const contents = await fs.readFile(join(home, '.npmrc'), { encoding: 'utf8' }) + const rc = ini.parse(contents) + t.not(rc.access, 'access is not set') }) t.test('config delete multiple keys', async t => { const home = t.testdir({ - '.npmrc': 'foo=bar\nbar=baz\nbaz=buz', + '.npmrc': 'access=public\nall=true\naudit=false', }) const sandbox = new Sandbox(t) - await sandbox.run('config', ['delete', 'foo', 'bar'], { home }) + await sandbox.run('config', ['delete', 'access', 'all'], { home }) - t.equal(sandbox.config.get('foo'), undefined, 'foo should no longer be set') - t.equal(sandbox.config.get('bar'), undefined, 'bar should no longer be set') + t.equal(sandbox.config.get('access'), null, 'access should be defaulted') + t.equal(sandbox.config.get('all'), false, 'all should be defaulted') - const contents = await readFile(join(home, '.npmrc'), { encoding: 'utf8' }) - t.not(contents.includes('foo='), 'foo was removed on disk') - t.not(contents.includes('bar='), 'bar was removed on disk') + const contents = await fs.readFile(join(home, '.npmrc'), { encoding: 'utf8' }) + const rc = ini.parse(contents) + t.not(rc.access, 'access is not set') + t.not(rc.all, 'all is not set') }) t.test('config delete key --location=global', async t => { const global = t.testdir({ - npmrc: 'foo=bar\nbar=baz', + npmrc: 'access=public\nall=true', }) const sandbox = new Sandbox(t) - await sandbox.run('config', ['delete', 'foo', '--location=global'], { global }) + await sandbox.run('config', ['delete', 'access', '--location=global'], { global }) - t.equal(sandbox.config.get('foo', 'global'), undefined, 'foo should no longer be set') + t.equal(sandbox.config.get('access', 'global'), undefined, 'access should be defaulted') - const contents = await readFile(join(global, 'npmrc'), { encoding: 'utf8' }) - t.not(contents.includes('foo='), 'foo was removed on disk') + const contents = await fs.readFile(join(global, 'npmrc'), { encoding: 'utf8' }) + const rc = ini.parse(contents) + t.not(rc.access, 'access is not set') }) t.test('config delete key --global', async t => { const global = t.testdir({ - npmrc: 'foo=bar\nbar=baz', + npmrc: 'access=public\nall=true', }) const sandbox = new Sandbox(t) - await sandbox.run('config', ['delete', 'foo', '--global'], { global }) + await sandbox.run('config', ['delete', 'access', '--global'], { global }) - t.equal(sandbox.config.get('foo', 'global'), undefined, 'foo should no longer be set') + t.equal(sandbox.config.get('access', 'global'), undefined, 'access should no longer be set') - const contents = await readFile(join(global, 'npmrc'), { encoding: 'utf8' }) - t.not(contents.includes('foo='), 'foo was removed on disk') + const contents = await fs.readFile(join(global, 'npmrc'), { encoding: 'utf8' }) + const rc = ini.parse(contents) + t.not(rc.access, 'access is not set') +}) + +t.test('config set invalid option', async t => { + const sandbox = new Sandbox(t) + await t.rejects( + sandbox.run('config', ['set', 'nonexistantconfigoption', 'something']), + /not a valid npm option/ + ) +}) + +t.test('config set deprecated option', async t => { + const sandbox = new Sandbox(t) + await t.rejects( + sandbox.run('config', ['set', 'shrinkwrap', 'true']), + /deprecated/ + ) +}) + +t.test('config set nerf-darted option', async t => { + const sandbox = new Sandbox(t) + await sandbox.run('config', ['set', '//npm.pkg.github.com/:_authToken', '0xdeadbeef']) + t.equal( + sandbox.config.get('//npm.pkg.github.com/:_authToken'), + '0xdeadbeef', + 'nerf-darted config is set' + ) +}) + +t.test('config set scoped optoin', async t => { + const sandbox = new Sandbox(t) + await sandbox.run('config', ['set', '@npm:registry', 'https://registry.npmjs.org']) + t.equal( + sandbox.config.get('@npm:registry'), + 'https://registry.npmjs.org', + 'scoped config is set' + ) }) t.test('config set no args', async t => { @@ -212,65 +250,67 @@ t.test('config set no args', async t => { t.test('config set key', async t => { const home = t.testdir({ - '.npmrc': 'foo=bar', + '.npmrc': 'access=public', }) const sandbox = new Sandbox(t, { home }) - await sandbox.run('config', ['set', 'foo']) + await sandbox.run('config', ['set', 'access']) - t.equal(sandbox.config.get('foo'), '', 'set the value for foo') + t.equal(sandbox.config.get('access'), null, 'set the value for access') - const contents = await readFile(join(home, '.npmrc'), { encoding: 'utf8' }) - t.ok(contents.includes('foo='), 'wrote foo to disk') + await t.rejects(fs.stat(join(home, '.npmrc'), { encoding: 'utf8' }), 'removed empty config') }) t.test('config set key value', async t => { const home = t.testdir({ - '.npmrc': 'foo=bar', + '.npmrc': 'access=public', }) const sandbox = new Sandbox(t, { home }) - await sandbox.run('config', ['set', 'foo', 'baz']) + await sandbox.run('config', ['set', 'access', 'restricted']) - t.equal(sandbox.config.get('foo'), 'baz', 'set the value for foo') + t.equal(sandbox.config.get('access'), 'restricted', 'set the value for access') - const contents = await readFile(join(home, '.npmrc'), { encoding: 'utf8' }) - t.ok(contents.includes('foo=baz'), 'wrote foo to disk') + const contents = await fs.readFile(join(home, '.npmrc'), { encoding: 'utf8' }) + const rc = ini.parse(contents) + t.equal(rc.access, 'restricted', 'access is set to restricted') }) t.test('config set key=value', async t => { const home = t.testdir({ - '.npmrc': 'foo=bar', + '.npmrc': 'access=public', }) const sandbox = new Sandbox(t, { home }) - await sandbox.run('config', ['set', 'foo=baz']) + await sandbox.run('config', ['set', 'access=restricted']) - t.equal(sandbox.config.get('foo'), 'baz', 'set the value for foo') + t.equal(sandbox.config.get('access'), 'restricted', 'set the value for access') - const contents = await readFile(join(home, '.npmrc'), { encoding: 'utf8' }) - t.ok(contents.includes('foo=baz'), 'wrote foo to disk') + const contents = await fs.readFile(join(home, '.npmrc'), { encoding: 'utf8' }) + const rc = ini.parse(contents) + t.equal(rc.access, 'restricted', 'access is set to restricted') }) t.test('config set key1 value1 key2=value2 key3', async t => { const home = t.testdir({ - '.npmrc': 'foo=bar\nbar=baz\nbaz=foo', + '.npmrc': 'access=public\nall=true\naudit=true', }) const sandbox = new Sandbox(t, { home }) - await sandbox.run('config', ['set', 'foo', 'oof', 'bar=rab', 'baz']) + await sandbox.run('config', ['set', 'access', 'restricted', 'all=false', 'audit']) - t.equal(sandbox.config.get('foo'), 'oof', 'foo was set') - t.equal(sandbox.config.get('bar'), 'rab', 'bar was set') - t.equal(sandbox.config.get('baz'), '', 'baz was set') + t.equal(sandbox.config.get('access'), 'restricted', 'access was set') + t.equal(sandbox.config.get('all'), false, 'all was set') + t.equal(sandbox.config.get('audit'), false, 'audit was set') - const contents = await readFile(join(home, '.npmrc'), { encoding: 'utf8' }) - t.ok(contents.includes('foo=oof'), 'foo was written to disk') - t.ok(contents.includes('bar=rab'), 'bar was written to disk') - t.ok(contents.includes('baz='), 'baz was written to disk') + const contents = await fs.readFile(join(home, '.npmrc'), { encoding: 'utf8' }) + const rc = ini.parse(contents) + t.equal(rc.access, 'restricted', 'access is set to restricted') + t.equal(rc.all, false, 'all is set to false') + t.equal(rc.audit, false, 'audit is set to false') }) t.test('config set invalid key logs warning', async t => { @@ -287,30 +327,32 @@ t.test('config set invalid key logs warning', async t => { t.test('config set key=value --location=global', async t => { const global = t.testdir({ - npmrc: 'foo=bar\nbar=baz', + npmrc: 'access=public\nall=true', }) const sandbox = new Sandbox(t, { global }) - await sandbox.run('config', ['set', 'foo=buzz', '--location=global']) + await sandbox.run('config', ['set', 'access=restricted', '--location=global']) - t.equal(sandbox.config.get('foo', 'global'), 'buzz', 'foo should be set') + t.equal(sandbox.config.get('access', 'global'), 'restricted', 'foo should be set') - const contents = await readFile(join(global, 'npmrc'), { encoding: 'utf8' }) - t.not(contents.includes('foo=buzz'), 'foo was saved on disk') + const contents = await fs.readFile(join(global, 'npmrc'), { encoding: 'utf8' }) + const rc = ini.parse(contents) + t.equal(rc.access, 'restricted', 'access is set to restricted') }) t.test('config set key=value --global', async t => { const global = t.testdir({ - npmrc: 'foo=bar\nbar=baz', + npmrc: 'access=public\nall=true', }) const sandbox = new Sandbox(t, { global }) - await sandbox.run('config', ['set', 'foo=buzz', '--global']) + await sandbox.run('config', ['set', 'access=restricted', '--global']) - t.equal(sandbox.config.get('foo', 'global'), 'buzz', 'foo should be set') + t.equal(sandbox.config.get('access', 'global'), 'restricted', 'access should be set') - const contents = await readFile(join(global, 'npmrc'), { encoding: 'utf8' }) - t.not(contents.includes('foo=buzz'), 'foo was saved on disk') + const contents = await fs.readFile(join(global, 'npmrc'), { encoding: 'utf8' }) + const rc = ini.parse(contents) + t.equal(rc.access, 'restricted', 'access is set to restricted') }) t.test('config get no args', async t => { @@ -330,21 +372,21 @@ t.test('config get no args', async t => { t.test('config get single key', async t => { const sandbox = new Sandbox(t) - await sandbox.run('config', ['get', 'node-version']) - t.equal(sandbox.output, sandbox.config.get('node-version'), 'should get the value') + await sandbox.run('config', ['get', 'all']) + t.equal(sandbox.output, `${sandbox.config.get('all')}`, 'should get the value') }) t.test('config get multiple keys', async t => { const sandbox = new Sandbox(t) - await sandbox.run('config', ['get', 'node-version', 'npm-version']) + await sandbox.run('config', ['get', 'yes', 'all']) t.ok( - sandbox.output.includes(`node-version=${sandbox.config.get('node-version')}`), - 'outputs node-version' + sandbox.output.includes(`yes=${sandbox.config.get('yes')}`), + 'outputs yes' ) t.ok( - sandbox.output.includes(`npm-version=${sandbox.config.get('npm-version')}`), - 'outputs npm-version' + sandbox.output.includes(`all=${sandbox.config.get('all')}`), + 'outputs all' ) }) @@ -369,10 +411,6 @@ t.test('config edit', async t => { '.npmrc': 'foo=bar\nbar=baz', }) - t.teardown(() => { - spawk.clean() - }) - const EDITOR = 'vim' const editor = spawk.spawn(EDITOR).exit(0) @@ -387,17 +425,13 @@ t.test('config edit', async t => { 'editor opened the user config file' ) - const contents = await readFile(join(home, '.npmrc'), { encoding: 'utf8' }) + const contents = await fs.readFile(join(home, '.npmrc'), { encoding: 'utf8' }) t.ok(contents.includes('foo=bar'), 'kept foo') t.ok(contents.includes('bar=baz'), 'kept bar') t.ok(contents.includes('shown below with default values'), 'appends defaults to file') }) t.test('config edit - editor exits non-0', async t => { - t.teardown(() => { - spawk.clean() - }) - const EDITOR = 'vim' const editor = spawk.spawn(EDITOR).exit(1) @@ -419,6 +453,102 @@ t.test('config edit - editor exits non-0', async t => { ) }) +t.test('config fix', (t) => { + t.test('no problems', async (t) => { + const home = t.testdir({ + '.npmrc': '', + }) + + const sandbox = new Sandbox(t, { home }) + await sandbox.run('config', ['fix']) + t.equal(sandbox.output, '', 'printed nothing') + }) + + t.test('repairs all configs by default', async (t) => { + const root = t.testdir({ + global: { + npmrc: '_authtoken=notatoken\n_authToken=afaketoken', + }, + home: { + '.npmrc': '_authtoken=thisisinvalid\n_auth=beef', + }, + }) + const registry = `//registry.npmjs.org/` + + const sandbox = new Sandbox(t, { + global: join(root, 'global'), + home: join(root, 'home'), + }) + await sandbox.run('config', ['fix']) + + // global config fixes + t.match(sandbox.output, '`_authtoken` deleted from global config', + 'output has deleted global _authtoken') + t.match(sandbox.output, `\`_authToken\` renamed to \`${registry}:_authToken\` in global config`, + 'output has renamed global _authToken') + t.not(sandbox.config.get('_authtoken', 'global'), '_authtoken is not set globally') + t.not(sandbox.config.get('_authToken', 'global'), '_authToken is not set globally') + t.equal(sandbox.config.get(`${registry}:_authToken`, 'global'), 'afaketoken', + 'global _authToken was scoped') + const globalConfig = await fs.readFile(join(root, 'global', 'npmrc'), { encoding: 'utf8' }) + t.equal(globalConfig, `${registry}:_authToken=afaketoken\n`, 'global config was written') + + // user config fixes + t.match(sandbox.output, '`_authtoken` deleted from user config', + 'output has deleted user _authtoken') + t.match(sandbox.output, `\`_auth\` renamed to \`${registry}:_auth\` in user config`, + 'output has renamed user _auth') + t.not(sandbox.config.get('_authtoken', 'user'), '_authtoken is not set in user config') + t.not(sandbox.config.get('_auth'), '_auth is not set in user config') + t.equal(sandbox.config.get(`${registry}:_auth`, 'user'), 'beef', 'user _auth was scoped') + const userConfig = await fs.readFile(join(root, 'home', '.npmrc'), { encoding: 'utf8' }) + t.equal(userConfig, `${registry}:_auth=beef\n`, 'user config was written') + }) + + t.test('repairs only the config specified by --location if asked', async (t) => { + const root = t.testdir({ + global: { + npmrc: '_authtoken=notatoken\n_authToken=afaketoken', + }, + home: { + '.npmrc': '_authtoken=thisisinvalid\n_auth=beef', + }, + }) + const registry = `//registry.npmjs.org/` + + const sandbox = new Sandbox(t, { + global: join(root, 'global'), + home: join(root, 'home'), + }) + await sandbox.run('config', ['fix', '--location=user']) + + // global config should be untouched + t.notMatch(sandbox.output, '`_authtoken` deleted from global', + 'output has deleted global _authtoken') + t.notMatch(sandbox.output, `\`_authToken\` renamed to \`${registry}:_authToken\` in global`, + 'output has renamed global _authToken') + t.equal(sandbox.config.get('_authtoken', 'global'), 'notatoken', 'global _authtoken untouched') + t.equal(sandbox.config.get('_authToken', 'global'), 'afaketoken', 'global _authToken untouched') + t.not(sandbox.config.get(`${registry}:_authToken`, 'global'), 'global _authToken not scoped') + const globalConfig = await fs.readFile(join(root, 'global', 'npmrc'), { encoding: 'utf8' }) + t.equal(globalConfig, '_authtoken=notatoken\n_authToken=afaketoken', + 'global config was not written') + + // user config fixes + t.match(sandbox.output, '`_authtoken` deleted from user', + 'output has deleted user _authtoken') + t.match(sandbox.output, `\`_auth\` renamed to \`${registry}:_auth\` in user`, + 'output has renamed user _auth') + t.not(sandbox.config.get('_authtoken', 'user'), '_authtoken is not set in user config') + t.not(sandbox.config.get('_auth', 'user'), '_auth is not set in user config') + t.equal(sandbox.config.get(`${registry}:_auth`, 'user'), 'beef', 'user _auth was scoped') + const userConfig = await fs.readFile(join(root, 'home', '.npmrc'), { encoding: 'utf8' }) + t.equal(userConfig, `${registry}:_auth=beef\n`, 'user config was written') + }) + + t.end() +}) + t.test('completion', async t => { const sandbox = new Sandbox(t) @@ -431,13 +561,14 @@ t.test('completion', async t => { sandbox.reset() } - await testComp([], ['get', 'set', 'delete', 'ls', 'rm', 'edit', 'list']) + await testComp([], ['get', 'set', 'delete', 'ls', 'rm', 'edit', 'fix', 'list']) await testComp(['set', 'foo'], []) await testComp(['get'], allKeys) await testComp(['set'], allKeys) await testComp(['delete'], allKeys) await testComp(['rm'], allKeys) await testComp(['edit'], []) + await testComp(['fix'], []) await testComp(['list'], []) await testComp(['ls'], []) diff --git a/test/lib/commands/dedupe.js b/test/lib/commands/dedupe.js index bf69640..604ed21 100644 --- a/test/lib/commands/dedupe.js +++ b/test/lib/commands/dedupe.js @@ -1,5 +1,9 @@ const t = require('tap') +const path = require('path') +const fs = require('fs') + const { load: loadMockNpm } = require('../../fixtures/mock-npm') +const MockRegistry = require('@npmcli/mock-registry') t.test('should throw in global mode', async (t) => { const { npm } = await loadMockNpm(t, { @@ -14,45 +18,79 @@ t.test('should throw in global mode', async (t) => { ) }) -t.test('should remove dupes using Arborist', async (t) => { - t.plan(5) - const { npm } = await loadMockNpm(t, { - mocks: { - '@npmcli/arborist': function (args) { - t.ok(args, 'gets options object') - t.ok(args.path, 'gets path option') - t.ok(args.dryRun, 'gets dryRun from user') - this.dedupe = () => { - t.ok(true, 'dedupe is called') - } - }, - '../../lib/utils/reify-finish.js': (npm, arb) => { - t.ok(arb, 'gets arborist tree') +const treeWithDupes = { + 'package.json': JSON.stringify({ + name: 'test-top', + version: '1.0.0', + dependencies: { + 'test-dep-a': '*', + 'test-dep-b': '*', + }, + }), + node_modules: { + 'test-dep-a': { + 'package.json': JSON.stringify({ + name: 'test-dep-a', + version: '1.0.1', + dependencies: { 'test-sub': '*' }, + }), + node_modules: { + 'test-sub': { + 'package.json': JSON.stringify({ + name: 'test-sub', + version: '1.0.0', + }), + }, }, }, - config: { - 'dry-run': 'true', + 'test-dep-b': { + 'package.json': JSON.stringify({ + name: 'test-dep-b', + version: '1.0.0', + dependencies: { 'test-sub': '*' }, + }), + node_modules: { + 'test-sub': { + 'package.json': JSON.stringify({ + name: 'test-sub', + version: '1.0.0', + }), + }, + }, }, - }) - await npm.exec('dedupe', []) -}) + }, +} -t.test('should remove dupes using Arborist - no arguments', async (t) => { - t.plan(2) - const { npm } = await loadMockNpm(t, { - mocks: { - '@npmcli/arborist': function (args) { - t.ok(args.dryRun, 'gets dryRun from config') - t.ok(args.save, 'gets user-set save value from config') - this.dedupe = () => {} - }, - '../../lib/utils/reify-output.js': () => {}, - '../../lib/utils/reify-finish.js': () => {}, - }, - config: { - 'dry-run': true, - save: true, +t.test('dedupe', async (t) => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: treeWithDupes, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifestSub = registry.manifest({ + name: 'test-sub', + packuments: [{ version: '1.0.0' }], + }) + + await registry.package({ + manifest: manifestSub, + tarballs: { + '1.0.0': path.join(npm.prefix, 'node_modules', 'test-dep-a', 'node_modules', 'test-sub'), }, }) await npm.exec('dedupe', []) + t.match(joinedOutput(), /added 1 package, and removed 2 packages/) + t.ok( + fs.existsSync(path.join(npm.prefix, 'node_modules', 'test-sub')), + 'test-sub was hoisted' + ) + t.notOk( + fs.existsSync(path.join(npm.prefix, 'node_modules', 'test-dep-a', 'node_modules', 'test-sub')), + 'test-dep-a/test-sub was removed' + ) + t.notOk( + fs.existsSync(path.join(npm.prefix, 'node_modules', 'test-dep-b', 'node_modules', 'test-sub')), + 'test-dep-b/test-sub was removed') }) diff --git a/test/lib/commands/deprecate.js b/test/lib/commands/deprecate.js index aa158cc..22ddfe1 100644 --- a/test/lib/commands/deprecate.js +++ b/test/lib/commands/deprecate.js @@ -1,145 +1,155 @@ const t = require('tap') +const { load: loadMockNpm } = require('../../fixtures/mock-npm') -let getIdentityImpl = () => 'someperson' -let npmFetchBody = null -let npmFetchLog = null +const MockRegistry = require('@npmcli/mock-registry') -const npmFetch = async (uri, opts) => { - npmFetchBody = opts.body - npmFetchLog = opts.log -} +const user = 'test-user' +const token = 'test-auth-token' +const auth = { '//registry.npmjs.org/:_authToken': token } +const versions = ['1.0.0', '1.0.1', '1.0.1-pre'] -npmFetch.json = async (uri, opts) => { - npmFetchLog = opts.log - return { - versions: { - '1.0.0': {}, - '1.0.1': {}, - '1.0.1-pre': {}, - }, - } -} - -const Deprecate = t.mock('../../../lib/commands/deprecate.js', { - '../../../lib/utils/get-identity.js': async () => getIdentityImpl(), - '../../../lib/utils/otplease.js': async (opts, fn) => fn(opts), - libnpmaccess: { - lsPackages: async () => ({ foo: 'write', bar: 'write', baz: 'write', buzz: 'read' }), - }, - 'npm-registry-fetch': npmFetch, -}) - -const deprecate = new Deprecate({ - flatOptions: { registry: 'https://registry.npmjs.org' }, -}) +// libnpmaccess maps these to read-write and read-only +const packages = { foo: 'write', bar: 'write', baz: 'write', buzz: 'read' } t.test('completion', async t => { - const defaultIdentityImpl = getIdentityImpl - t.teardown(() => { - getIdentityImpl = defaultIdentityImpl + const { npm } = await loadMockNpm(t, { + config: { + ...auth, + }, }) + const deprecate = await npm.cmd('deprecate') const testComp = async (argv, expect) => { const res = await deprecate.completion({ conf: { argv: { remain: argv } } }) t.strictSame(res, expect, `completion: ${argv}`) } + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, + }) + + registry.whoami({ username: user, times: 4 }) + registry.getPackages({ team: user, packages, times: 4 }) await Promise.all([ testComp([], ['foo', 'bar', 'baz']), testComp(['b'], ['bar', 'baz']), testComp(['fo'], ['foo']), testComp(['g'], []), - testComp(['foo', 'something'], []), ]) - getIdentityImpl = () => { - throw new Error('deprecate test failure') - } + await testComp(['foo', 'something'], []) - t.rejects(testComp([], []), { message: 'deprecate test failure' }) + registry.whoami({ responseCode: 401, body: {} }) + + await t.rejects( + testComp([], []), + { code: 'E401' } + ) }) t.test('no args', async t => { + const { npm } = await loadMockNpm(t) await t.rejects( - deprecate.exec([]), - /Usage:/, + npm.exec('deprecate', []), + { code: 'EUSAGE' }, 'logs usage' ) }) t.test('only one arg', async t => { + const { npm } = await loadMockNpm(t) await t.rejects( - deprecate.exec(['foo']), - /Usage:/, + npm.exec('deprecate', ['foo']), + { code: 'EUSAGE' }, 'logs usage' ) }) t.test('invalid semver range', async t => { + const { npm } = await loadMockNpm(t) await t.rejects( - deprecate.exec(['foo@notaversion', 'this will fail']), + npm.exec('deprecate', ['foo@notaversion', 'this will fail']), /invalid version range/, 'logs semver error' ) }) t.test('undeprecate', async t => { - t.teardown(() => { - npmFetchBody = null - npmFetchLog = null + const { npm, joinedOutput } = await loadMockNpm(t, { config: { ...auth } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, }) - await deprecate.exec(['foo', '']) - t.ok(npmFetchLog, 'was passed a logger') - t.match(npmFetchBody, { - versions: { - '1.0.0': { deprecated: '' }, - '1.0.1': { deprecated: '' }, - '1.0.1-pre': { deprecated: '' }, - }, - }, 'undeprecates everything') + const manifest = registry.manifest({ + name: 'foo', + versions, + }) + await registry.package({ manifest, query: { write: true } }) + registry.nock.put('/foo', body => { + for (const version of versions) { + if (body.versions[version].deprecated !== '') { + return false + } + } + return true + }).reply(200, {}) + + await npm.exec('deprecate', ['foo', '']) + t.match(joinedOutput(), '') }) t.test('deprecates given range', async t => { - t.teardown(() => { - npmFetchBody = null - npmFetchLog = null + const { npm, joinedOutput } = await loadMockNpm(t, { config: { ...auth } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, }) - - await deprecate.exec(['foo@1.0.0', 'this version is deprecated']) - t.ok(npmFetchLog, 'was passed a logger') - t.match(npmFetchBody, { - versions: { - '1.0.0': { - deprecated: 'this version is deprecated', - }, - '1.0.1': { - // the undefined here is necessary to ensure that we absolutely - // did not assign this property - deprecated: undefined, - }, - }, + const manifest = registry.manifest({ + name: 'foo', + versions, }) + await registry.package({ manifest, query: { write: true } }) + const message = 'test deprecation message' + registry.nock.put('/foo', body => { + if (body.versions['1.0.1'].deprecated) { + return false + } + if (body.versions['1.0.1-pre'].deprecated) { + return false + } + return body.versions['1.0.0'].deprecated === message + }).reply(200, {}) + await npm.exec('deprecate', ['foo@1.0.0', message]) + t.match(joinedOutput(), '') }) t.test('deprecates all versions when no range is specified', async t => { - t.teardown(() => { - npmFetchBody = null + const { npm, joinedOutput } = await loadMockNpm(t, { config: { ...auth } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, }) - - await deprecate.exec(['foo', 'this version is deprecated']) - - t.match(npmFetchBody, { - versions: { - '1.0.0': { - deprecated: 'this version is deprecated', - }, - '1.0.1': { - deprecated: 'this version is deprecated', - }, - '1.0.1-pre': { - deprecated: 'this version is deprecated', - }, - }, + const manifest = registry.manifest({ + name: 'foo', + versions, }) + await registry.package({ manifest, query: { write: true } }) + const message = 'test deprecation message' + registry.nock.put('/foo', body => { + for (const version of versions) { + if (body.versions[version].deprecated !== message) { + return false + } + } + return true + }).reply(200, {}) + + await npm.exec('deprecate', ['foo', message]) + t.match(joinedOutput(), '') }) diff --git a/test/lib/commands/diff.js b/test/lib/commands/diff.js index f73a543..0ca9c3b 100644 --- a/test/lib/commands/diff.js +++ b/test/lib/commands/diff.js @@ -34,7 +34,6 @@ const mocks = { 'proc-log': { info: noop, verbose: noop }, libnpmdiff: (...args) => libnpmdiff(...args), 'npm-registry-fetch': async () => ({}), - '../../../lib/utils/usage.js': () => 'usage instructions', } t.afterEach(() => { @@ -61,10 +60,9 @@ const diff = new Diff(npm) t.test('no args', t => { t.test('in a project dir', async t => { - t.plan(4) + t.plan(3) libnpmdiff = async ([a, b], opts) => { - t.ok(opts.log, 'should be passed a logger') t.equal(a, 'foo@latest', 'should have default spec comparison') t.equal(b, `file:${fooPath}`, 'should compare to cwd') t.match(opts, npm.flatOptions, 'should forward flat options') @@ -218,7 +216,7 @@ t.test('single arg', t => { }) libnpmdiff = async ([a, b], opts) => { - t.equal(a, 'simple-output@latest', 'should forward single spec') + t.equal(a, 'simple-output@*', 'should forward single spec') t.equal(b, `file:${path}`, 'should compare to cwd') t.match(opts, npm.flatOptions, 'should forward flat options') } @@ -419,7 +417,6 @@ t.test('single arg', t => { const Diff = t.mock('../../../lib/commands/diff.js', { ...mocks, - '../../../lib/utils/read-package-name.js': async () => 'my-project', pacote: { packument: spec => { t.equal(spec.name, 'lorem', 'should have expected spec name') @@ -457,14 +454,13 @@ t.test('single arg', t => { const Diff = t.mock('../../../lib/commands/diff.js', { ...mocks, - '../../../lib/utils/read-package-name.js': async () => 'my-project', '@npmcli/arborist': class { constructor () { throw new Error('ERR') } }, libnpmdiff: async ([a, b], opts) => { - t.equal(a, 'lorem@latest', 'should target latest version of pkg name') + t.equal(a, 'lorem@*', 'should target any version of pkg name') t.equal(b, `file:${path}`, 'should target current cwd') }, }) @@ -483,7 +479,7 @@ t.test('single arg', t => { 'package.json': JSON.stringify({ version: '1.0.0' }), }) libnpmdiff = async ([a, b], opts) => { - t.equal(a, 'bar@latest', 'should target latest tag of name') + t.equal(a, 'bar@*', 'should target any version of pkg name') t.equal(b, `file:${path}`, 'should compare to cwd') } @@ -497,7 +493,7 @@ t.test('single arg', t => { t.plan(2) libnpmdiff = async ([a, b], opts) => { - t.equal(a, 'foo@latest', 'should target latest tag of name') + t.equal(a, 'foo@*', 'should target any version of pkg name') t.equal(b, `file:${fooPath}`, 'should compare to cwd') } @@ -596,7 +592,7 @@ t.test('first arg is a qualified spec', t => { libnpmdiff = async ([a, b], opts) => { t.equal(a, 'bar@1.0.0', 'should set expected first spec') - t.equal(b, 'bar-fork@latest', 'should target latest tag if not a dep') + t.equal(b, 'bar-fork@*', 'should target any version if not a dep') } config.diff = ['bar@1.0.0', 'bar-fork'] @@ -757,7 +753,7 @@ t.test('first arg is a known dependency name', async t => { `bar@file:${resolve(path, 'node_modules/bar')}`, 'should target local node_modules pkg' ) - t.equal(b, 'bar-fork@latest', 'should set expected second spec') + t.equal(b, 'bar-fork@*', 'should set expected second spec') } npm.prefix = path @@ -844,7 +840,7 @@ t.test('first arg is a valid semver range', t => { libnpmdiff = async ([a, b], opts) => { t.equal(a, 'bar@1.0.0', 'should use name from second arg') - t.equal(b, 'bar@latest', 'should compare against latest tag') + t.equal(b, 'bar@*', 'should compare against any version') } config.diff = ['1.0.0', 'bar'] @@ -888,7 +884,7 @@ t.test('first arg is an unknown dependency name', t => { t.plan(4) libnpmdiff = async ([a, b], opts) => { - t.equal(a, 'bar@latest', 'should set expected first spec') + t.equal(a, 'bar@*', 'should set expected first spec') t.equal(b, 'bar@2.0.0', 'should set expected second spec') t.match(opts, npm.flatOptions, 'should forward flat options') t.match(opts, { where: fooPath }, 'should forward pacote options') @@ -923,7 +919,7 @@ t.test('first arg is an unknown dependency name', t => { }) libnpmdiff = async ([a, b], opts) => { - t.equal(a, 'bar-fork@latest', 'should use latest tag') + t.equal(a, 'bar-fork@*', 'should use any version') t.equal( b, `bar@file:${resolve(path, 'node_modules/bar')}`, @@ -944,7 +940,7 @@ t.test('first arg is an unknown dependency name', t => { t.plan(2) libnpmdiff = async ([a, b], opts) => { - t.equal(a, 'bar@latest', 'should use latest tag') + t.equal(a, 'bar@*', 'should use any version') t.equal(b, 'bar@^1.0.0', 'should use name from first arg') } @@ -960,8 +956,8 @@ t.test('first arg is an unknown dependency name', t => { t.plan(2) libnpmdiff = async ([a, b], opts) => { - t.equal(a, 'bar@latest', 'should use latest tag') - t.equal(b, 'bar-fork@latest', 'should use latest tag') + t.equal(a, 'bar@*', 'should use any version') + t.equal(b, 'bar-fork@*', 'should use any version') } config.diff = ['bar', 'bar-fork'] @@ -977,8 +973,8 @@ t.test('first arg is an unknown dependency name', t => { const path = t.testdir({}) libnpmdiff = async ([a, b], opts) => { - t.equal(a, 'bar@latest', 'should use latest tag') - t.equal(b, 'bar-fork@latest', 'should use latest tag') + t.equal(a, 'bar@*', 'should use any version') + t.equal(b, 'bar-fork@*', 'should use any version') } config.diff = ['bar', 'bar-fork'] diff --git a/test/lib/commands/dist-tag.js b/test/lib/commands/dist-tag.js index b83c30e..464f5bc 100644 --- a/test/lib/commands/dist-tag.js +++ b/test/lib/commands/dist-tag.js @@ -43,7 +43,6 @@ const routeMap = { // XXX overriding this does not appear to do anything, adding t.plan to things // that use it fails the test let npmRegistryFetchMock = (url, opts) => { - npmRegistryFetchLog = opts.log if (url === '/-/package/foo/dist-tags') { throw new Error('no package found') } @@ -51,9 +50,7 @@ let npmRegistryFetchMock = (url, opts) => { return routeMap[url] } -let npmRegistryFetchLog npmRegistryFetchMock.json = async (url, opts) => { - npmRegistryFetchLog = opts.log return routeMap[url] } @@ -86,10 +83,6 @@ const npm = mockNpm({ }) const distTag = new DistTag(npm) -t.afterEach(() => { - npmRegistryFetchLog = null -}) - t.test('ls in current package', async t => { npm.prefix = t.testdir({ 'package.json': JSON.stringify({ @@ -97,7 +90,6 @@ t.test('ls in current package', async t => { }), }) await distTag.exec(['ls']) - t.ok(npmRegistryFetchLog, 'is passed a logger') t.matchSnapshot( result, 'should list available tags for current package' @@ -285,7 +277,7 @@ t.test('workspaces', t => { await distTag.execWorkspaces([], []) t.equal(process.exitCode, 1, 'set the error status') process.exitCode = 0 - t.match(log, 'dist-tag ls Couldn\'t get dist-tag data for workspace-d@latest', 'logs the error') + t.match(log, 'dist-tag ls Couldn\'t get dist-tag data for workspace-d@*', 'logs the error') t.matchSnapshot(result, 'printed the expected output') }) @@ -299,7 +291,6 @@ t.test('add new tag', async t => { }) npmRegistryFetchMock = async (url, opts) => { - t.ok(opts.log, 'is passed a logger') t.equal(opts.method, 'PUT', 'should trigger request to add new tag') t.equal(opts.body, '7.7.7', 'should point to expected version') } @@ -366,7 +357,6 @@ t.test('remove existing tag', async t => { } npm.prefix = t.testdir({}) await distTag.exec(['rm', '@scoped/another', 'c']) - t.ok(npmRegistryFetchLog, 'is passed a logger') t.matchSnapshot(log, 'should log remove info') t.matchSnapshot(result, 'should return success msg') }) diff --git a/test/lib/commands/docs.js b/test/lib/commands/docs.js index a3b31bd..b2a6578 100644 --- a/test/lib/commands/docs.js +++ b/test/lib/commands/docs.js @@ -35,6 +35,13 @@ const pkgDirs = t.testdir({ repository: { url: 'https://github.com/foo/repoobj' }, }), }, + repourlobj: { + 'package.json': JSON.stringify({ + name: 'repourlobj', + version: '1.2.3', + repository: { url: { works: false } }, + }), + }, workspaces: { 'package.json': JSON.stringify({ name: 'workspaces-test', @@ -81,14 +88,13 @@ const docs = new Docs(npm) t.afterEach(() => opened = {}) t.test('open docs urls', t => { - // XXX It is very odd that `where` is how pacote knows to look anywhere other - // than the cwd. I would think npm.localPrefix would factor in somehow - flatOptions.where = pkgDirs + npm.localPrefix = pkgDirs const expect = { nodocs: 'https://www.npmjs.com/package/nodocs', docsurl: 'https://bugzilla.localhost/docsurl', repourl: 'https://github.com/foo/repourl#readme', repoobj: 'https://github.com/foo/repoobj#readme', + repourlobj: 'https://www.npmjs.com/package/repourlobj', '.': 'https://example.com', } const keys = Object.keys(expect) @@ -110,7 +116,6 @@ t.test('open default package if none specified', async t => { }) t.test('workspaces', (t) => { - flatOptions.where = undefined npm.localPrefix = join(pkgDirs, 'workspaces') t.test('all workspaces', async t => { await docs.execWorkspaces([], []) diff --git a/test/lib/commands/doctor.js b/test/lib/commands/doctor.js index 51b6111..a460218 100644 --- a/test/lib/commands/doctor.js +++ b/test/lib/commands/doctor.js @@ -1,1018 +1,666 @@ const t = require('tap') - -const { join } = require('path') const fs = require('fs') -const ansiTrim = require('../../../lib/utils/ansi-trim.js') -const isWindows = require('../../../lib/utils/is-windows.js') +const path = require('path') + +const { load: loadMockNpm } = require('../../fixtures/mock-npm') +const tnock = require('../../fixtures/tnock.js') +const mockGlobals = require('../../fixtures/mock-globals') +const { cleanCwd, cleanDate } = require('../../fixtures/clean-snapshot.js') + +const cleanCacheSha = (str) => + str.replace(/content-v2\/sha512\/[^"]+/g, 'content-v2/sha512/{sha}') + +t.cleanSnapshot = p => cleanCacheSha(cleanDate(cleanCwd(p))) + +const npmManifest = (version) => { + return { + name: 'npm', + versions: { + [version]: { + name: 'npm', + version: version, + }, + }, + time: { + [version]: new Date(), + }, + 'dist-tags': { latest: version }, + } +} + +const nodeVersions = [ + { version: 'v2.0.1', lts: false }, + { version: 'v2.0.0', lts: false }, + { version: 'v1.0.0', lts: 'NpmTestium' }, +] + +const dirs = { + prefixDir: { + node_modules: { + testLink: t.fixture('symlink', './testDir'), + testDir: { + testFile: 'test contents', + }, + '.bin': {}, + }, + }, + globalPrefixDir: { + bin: {}, + lib: { + node_modules: { + }, + }, + }, +} + +const globals = ({ globalPrefix }) => { + return { + process: { + 'env.PATH': `${globalPrefix}:${path.join(globalPrefix, 'bin')}`, + platform: 'test-not-windows', + version: 'v1.0.0', + }, + } +} // getuid and getgid do not exist in windows, so we shim them // to return 0, as that is the value that lstat will assign the // gid and uid properties for fs.Stats objects -if (isWindows) { - process.getuid = () => 0 - process.getgid = () => 0 -} - -const output = [] - -let pingError -const ping = async () => { - if (pingError) { - throw pingError - } -} - -let whichError = null -const which = async () => { - if (whichError) { - throw whichError - } - return '/path/to/git' -} - -const nodeVersions = [ - { version: 'v14.0.0', lts: false }, - { version: 'v13.0.0', lts: false }, - // it's necessary to allow tests in node 10.x to not mark 12.x as lts - { version: 'v12.0.0', lts: false }, - { version: 'v10.13.0', lts: 'Dubnium' }, -] - -const fetch = async () => { - return { - json: async () => { - return nodeVersions +if (process.platform === 'win32') { + mockGlobals(t, { + process: { + getuid: () => 0, + getgid: () => 0, }, - } -} - -const logs = { - info: [], -} - -const clearLogs = () => { - output.length = 0 - for (const key in logs) { - if (Array.isArray(logs[key])) { - logs[key].length = 0 - } else { - delete logs[key] - } - } -} - -const npm = { - flatOptions: { - registry: 'https://registry.npmjs.org/', - }, - version: '7.1.0', - output: data => { - output.push(data) - }, -} - -let latestNpm = npm.version -const pacote = { - manifest: async () => { - return { version: latestNpm } - }, -} - -let verifyResponse = { verifiedCount: 1, verifiedContent: 1 } -const cacache = { - verify: async () => { - return verifyResponse - }, + }) } const mocks = { - '../../../lib/utils/is-windows.js': false, - '../../../lib/utils/ping.js': ping, - cacache, - pacote, - 'make-fetch-happen': fetch, - which, - 'proc-log': { - info: msg => { - logs.info.push(msg) + '../../package.json': { version: '1.0.0' }, + which: async () => '/path/to/git', + cacache: { + verify: () => { + return { badContentCount: 0, reclaimedCount: 0, missingContent: 0, verifiedContent: 0 } }, }, - npmlog: { - newItem: name => { - logs[name] = {} +} + +t.test('all clear', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await npm.exec('doctor', []) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('all clear in color', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + npm.config.set('color', 'always') + await npm.exec('doctor', []) + t.matchSnapshot(joinedOutput(), 'everything is ok in color') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('silent success', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + config: { + loglevel: 'silent', + }, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await npm.exec('doctor', []) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('silent errors', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + config: { + loglevel: 'silent', + }, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(404, '{}') + await t.rejects(npm.exec('doctor', ['ping']), { + message: /Check logs/, + }) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('ping 404', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(404, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', []), { + message: /See above/, + }) + t.matchSnapshot(joinedOutput(), 'ping 404') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('ping 404 in color', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(404, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + npm.config.set('color', 'always') + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'ping 404 in color') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('ping exception with code', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').replyWithError({ message: 'Test Error', code: 'TEST' }) + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'ping failure') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('ping exception without code', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').replyWithError({ message: 'Test Error', code: false }) + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'ping failure') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('npm out of date', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest('2.0.0')) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'npm is out of date') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('node out of date - lts', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals: (context) => { + const g = globals(context) return { - info: (_, msg) => { - if (!logs[name].info) { - logs[name].info = [] - } - logs[name].info.push(msg) - }, - warn: (_, msg) => { - if (!logs[name].warn) { - logs[name].warn = [] - } - logs[name].warn.push(msg) - }, - error: (_, msg) => { - if (!logs[name].error) { - logs[name].error = [] - } - logs[name].error.push(msg) - }, - silly: (_, msg) => { - if (!logs[name].silly) { - logs[name].silly = [] - } - logs[name].silly.push(msg) - }, - completeWork: () => {}, - finish: () => { - logs[name].finished = true + ...g, + process: { + ...g.process, + platform: 'test-not-windows', + version: 'v0.0.1', }, } }, - level: 'error', - levels: { - info: 1, - error: 0, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'node is out of date') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('node out of date - current', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals: (context) => { + const g = globals(context) + return { + ...g, + process: { + ...g.process, + version: 'v2.0.0', + }, + } }, - }, - -} - -const Doctor = t.mock('../../../lib/commands/doctor.js', { - ...mocks, -}) -const doctor = new Doctor(npm) - -const origVersion = process.version -t.test('node versions', t => { - t.plan(nodeVersions.length) - - nodeVersions.forEach(({ version }) => { - t.test(`${version}:`, vt => { - Object.defineProperty(process, 'version', { value: version }) - vt.teardown(() => { - Object.defineProperty(process, 'version', { value: origVersion }) - }) - - vt.test(`${version}: npm doctor checks ok`, async st => { - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - clearLogs() - }) - - await doctor.exec([]) - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match(output, /npm ping\s*ok/, 'ping output is ok') - st.match(output, /npm -v\s*ok/, 'npm -v output is ok') - st.match(output, /node -v\s*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry\s*ok\s*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git\s*ok/, 'which git output is ok') - st.match(output, /cached files\s*ok/, 'cached files are ok') - st.match(output, /local node_modules\s*ok/, 'local node_modules are ok') - st.match(output, /global node_modules\s*ok/, 'global node_modules are ok') - st.match(output, /local bin folder\s*ok/, 'local bin is ok') - st.match(output, /global bin folder\s*ok/, 'global bin is ok') - st.match(output, /cache contents\s*ok/, 'cache contents is ok') - }) - - vt.test('npm doctor supports silent', async st => { - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - mocks.npmlog.level = 'info' - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - mocks.npmlog.level = 'error' - clearLogs() - }) - - await doctor.exec([]) - - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.strictSame(output, [], 'did not print output') - }) - - vt.test('npm doctor supports color', async st => { - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - npm.color = true - pingError = { message: 'generic error' } - const _consoleError = console.error - console.error = () => {} - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - delete npm.color - pingError = null - console.error = _consoleError - clearLogs() - }) - - await st.rejects(doctor.exec([]), /Some problems found/, 'detected the ping error') - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match(output, /npm ping.*not ok/, 'ping output is ok') - st.match(output, /npm -v.*ok/, 'npm -v output is ok') - st.match(output, /node -v.*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry.*ok.*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git.*ok/, 'which git output is ok') - st.match(output, /cached files.*ok/, 'cached files are ok') - st.match(output, /local node_modules.*ok/, 'local node_modules are ok') - st.match(output, /global node_modules.*ok/, 'global node_modules are ok') - st.match(output, /local bin folder.*ok/, 'local bin is ok') - st.match(output, /global bin folder.*ok/, 'global bin is ok') - st.match(output, /cache contents.*ok/, 'cache contents is ok') - st.not(output[0], ansiTrim(output[0]), 'output should contain color codes') - }) - - vt.test('npm doctor skips some tests in windows', async st => { - const WinDoctor = t.mock('../../../lib/commands/doctor.js', { - ...mocks, - '../../../lib/utils/is-windows.js': true, - }) - const winDoctor = new WinDoctor(npm) - - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - clearLogs() - }) - - await winDoctor.exec([]) - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: undefined, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match(output, /npm ping\s*ok/, 'ping output is ok') - st.match(output, /npm -v\s*ok/, 'npm -v output is ok') - st.match(output, /node -v\s*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry\s*ok\s*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git\s*ok/, 'which git output is ok') - st.match(output, /cache contents\s*ok/, 'cache contents is ok') - }) - - vt.test('npm doctor ping error E{3}', async st => { - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - pingError = { code: 'E111', message: 'this error is 111' } - const consoleError = console.error - // we just print an empty line here, so swallow it and ignore - console.error = () => {} - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - pingError = null - console.error = consoleError - clearLogs() - }) - - await st.rejects(doctor.exec([]), /Some problems found/, 'detected the ping error') - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match( - output, - /npm ping\s*not ok\s*111 this error is 111/, - 'ping output contains trimmed error' - ) - st.match(output, /npm -v\s*ok/, 'npm -v output is ok') - st.match(output, /node -v\s*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry\s*ok\s*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git\s*ok/, 'which git output is ok') - st.match(output, /cached files\s*ok/, 'cached files are ok') - st.match(output, /local node_modules\s*ok/, 'local node_modules are ok') - st.match(output, /global node_modules\s*ok/, 'global node_modules are ok') - st.match(output, /local bin folder\s*ok/, 'local bin is ok') - st.match(output, /global bin folder\s*ok/, 'global bin is ok') - st.match(output, /cache contents\s*ok/, 'cache contents is ok') - }) - - vt.test('npm doctor generic ping error', async st => { - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - pingError = { message: 'generic error' } - const consoleError = console.error - // we just print an empty line here, so swallow it and ignore - console.error = () => {} - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - pingError = null - console.error = consoleError - clearLogs() - }) - - await st.rejects(doctor.exec([]), /Some problems found/, 'detected the ping error') - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match(output, /npm ping\s*not ok\s*generic error/, 'ping output contains trimmed error') - st.match(output, /npm -v\s*ok/, 'npm -v output is ok') - st.match(output, /node -v\s*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry\s*ok\s*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git\s*ok/, 'which git output is ok') - st.match(output, /cached files\s*ok/, 'cached files are ok') - st.match(output, /local node_modules\s*ok/, 'local node_modules are ok') - st.match(output, /global node_modules\s*ok/, 'global node_modules are ok') - st.match(output, /local bin folder\s*ok/, 'local bin is ok') - st.match(output, /global bin folder\s*ok/, 'global bin is ok') - st.match(output, /cache contents\s*ok/, 'cache contents is ok') - }) - - vt.test('npm doctor outdated npm version', async st => { - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - latestNpm = '7.1.1' - const consoleError = console.error - // we just print an empty line here, so swallow it and ignore - console.error = () => {} - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - latestNpm = npm.version - console.error = consoleError - clearLogs() - }) - - await st.rejects(doctor.exec([]), /Some problems found/, 'detected the out of date npm') - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match(output, /npm ping\s*ok/, 'ping output is ok') - st.match(output, /npm -v\s*not ok/, 'npm -v output is not ok') - st.match(output, /node -v\s*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry\s*ok\s*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git\s*ok/, 'which git output is ok') - st.match(output, /cached files\s*ok/, 'cached files are ok') - st.match(output, /local node_modules\s*ok/, 'local node_modules are ok') - st.match(output, /global node_modules\s*ok/, 'global node_modules are ok') - st.match(output, /local bin folder\s*ok/, 'local bin is ok') - st.match(output, /global bin folder\s*ok/, 'global bin is ok') - st.match(output, /cache contents\s*ok/, 'cache contents is ok') - }) - - vt.test('npm doctor file permission checks', async st => { - const dir = st.testdir({ - cache: { - one: 'one', - link: st.fixture('symlink', './baddir'), - unreadable: 'unreadable', - baddir: {}, - }, - local: { - two: 'two', - notmine: 'notmine', - }, - global: { - three: 'three', - broken: 'broken', - }, - localBin: { - four: 'four', - five: 'five', - }, - globalBin: { - six: 'six', - seven: 'seven', - }, - }) - - const _fsLstat = fs.lstat - fs.lstat = (p, cb) => { - let err = null - let stat = null - - try { - stat = fs.lstatSync(p) - } catch (err) { - return cb(err) - } - - switch (p) { - case join(dir, 'local', 'notmine'): - stat.uid += 1 - stat.gid += 1 - break - case join(dir, 'global', 'broken'): - err = new Error('broken') - break - } - - return cb(err, stat) - } - - const _fsReaddir = fs.readdir - fs.readdir = (p, cb) => { - let err = null - let result = null - - try { - result = fs.readdirSync(p) - } catch (err) { - return cb(err) - } - - if (p === join(dir, 'cache', 'baddir')) { - err = new Error('broken') - } - - return cb(err, result) - } - - const _fsAccess = fs.access - fs.access = (p, mask, cb) => { - const err = new Error('failed') - switch (p) { - case join(dir, 'cache', 'unreadable'): - case join(dir, 'localBin', 'four'): - case join(dir, 'globalBin', 'six'): - return cb(err) - default: - return cb(null) - } - } - - const Doctor = t.mock('../../../lib/commands/doctor.js', { - ...mocks, - fs, - }) - const doctor = new Doctor(npm) - // it's necessary to allow tests in node 10.x to not mark 12.x as lted - - npm.cache = npm.flatOptions.cache = join(dir, 'cache') - npm.localDir = join(dir, 'local') - npm.globalDir = join(dir, 'global') - npm.localBin = join(dir, 'localBin') - npm.globalBin = join(dir, 'globalBin') - const _consoleError = console.error - console.error = () => {} - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - console.error = _consoleError - fs.lstat = _fsLstat - fs.readdir = _fsReaddir - fs.access = _fsAccess - clearLogs() - }) - - await st.rejects(doctor.exec([]), /Some problems found/, 'identified problems') - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [join(dir, 'cache')]: { finished: true }, - [join(dir, 'local')]: { finished: true }, - [join(dir, 'global')]: { finished: true }, - [join(dir, 'localBin')]: { finished: true }, - [join(dir, 'globalBin')]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match(output, /npm ping\s*ok/, 'ping output is ok') - st.match(output, /npm -v\s*ok/, 'npm -v output is ok') - st.match(output, /node -v\s*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry\s*ok\s*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git\s*ok/, 'which git output is ok') - st.match(output, /cached files\s*not ok/, 'cached files are not ok') - st.match(output, /local node_modules\s*not ok/, 'local node_modules are not ok') - st.match(output, /global node_modules\s*not ok/, 'global node_modules are not ok') - st.match(output, /local bin folder\s*not ok/, 'local bin is not ok') - st.match(output, /global bin folder\s*not ok/, 'global bin is not ok') - st.match(output, /cache contents\s*ok/, 'cache contents is ok') - }) - - vt.test('npm doctor missing git', async st => { - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - whichError = new Error('boom') - const consoleError = console.error - // we just print an empty line here, so swallow it and ignore - console.error = () => {} - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - whichError = null - console.error = consoleError - clearLogs() - }) - - await st.rejects(doctor.exec([]), /Some problems found/, 'detected the missing git') - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match(output, /npm ping\s*ok/, 'ping output is ok') - st.match(output, /npm -v\s*ok/, 'npm -v output is ok') - st.match(output, /node -v\s*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry\s*ok\s*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git\s*not ok/, 'which git output is not ok') - st.match(output, /cached files\s*ok/, 'cached files are ok') - st.match(output, /local node_modules\s*ok/, 'local node_modules are ok') - st.match(output, /global node_modules\s*ok/, 'global node_modules are ok') - st.match(output, /local bin folder\s*ok/, 'local bin is ok') - st.match(output, /global bin folder\s*ok/, 'global bin is ok') - st.match(output, /cache contents\s*ok/, 'cache contents is ok') - }) - - vt.test('npm doctor cache verification showed bad content', async st => { - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - const _verifyResponse = verifyResponse - verifyResponse = { - ...verifyResponse, - badContentCount: 1, - } - const consoleError = console.error - // we just print an empty line here, so swallow it and ignore - console.error = () => {} - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - verifyResponse = _verifyResponse - console.error = consoleError - clearLogs() - }) - - // cache verification problems get fixed and so do not throw an error - await doctor.exec([]) - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match(output, /npm ping\s*ok/, 'ping output is ok') - st.match(output, /npm -v\s*ok/, 'npm -v output is ok') - st.match(output, /node -v\s*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry\s*ok\s*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git\s*ok/, 'which git output is ok') - st.match(output, /cached files\s*ok/, 'cached files are ok') - st.match(output, /local node_modules\s*ok/, 'local node_modules are ok') - st.match(output, /global node_modules\s*ok/, 'global node_modules are ok') - st.match(output, /local bin folder\s*ok/, 'local bin is ok') - st.match(output, /global bin folder\s*ok/, 'global bin is ok') - st.match(output, /cache contents\s*ok/, 'cache contents is not ok') - }) - - vt.test('npm doctor cache verification showed reclaimed content', async st => { - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - const _verifyResponse = verifyResponse - verifyResponse = { - ...verifyResponse, - reclaimedCount: 1, - reclaimedSize: 100, - } - const consoleError = console.error - // we just print an empty line here, so swallow it and ignore - console.error = () => {} - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - verifyResponse = _verifyResponse - console.error = consoleError - clearLogs() - }) - - // cache verification problems get fixed and so do not throw an error - await doctor.exec([]) - - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match(output, /npm ping\s*ok/, 'ping output is ok') - st.match(output, /npm -v\s*ok/, 'npm -v output is ok') - st.match(output, /node -v\s*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry\s*ok\s*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git\s*ok/, 'which git output is ok') - st.match(output, /cached files\s*ok/, 'cached files are ok') - st.match(output, /local node_modules\s*ok/, 'local node_modules are ok') - st.match(output, /global node_modules\s*ok/, 'global node_modules are ok') - st.match(output, /local bin folder\s*ok/, 'local bin is ok') - st.match(output, /global bin folder\s*ok/, 'global bin is ok') - st.match(output, /cache contents\s*ok/, 'cache contents is not ok') - }) - - vt.test('npm doctor cache verification showed missing content', async st => { - const dir = t.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - const _verifyResponse = verifyResponse - verifyResponse = { - ...verifyResponse, - missingContent: 1, - } - const consoleError = console.error - // we just print an empty line here, so swallow it and ignore - console.error = () => {} - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - verifyResponse = _verifyResponse - console.error = consoleError - clearLogs() - }) - - // cache verification problems get fixed and so do not throw an error - await doctor.exec([]) - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match(output, /npm ping\s*ok/, 'ping output is ok') - st.match(output, /npm -v\s*ok/, 'npm -v output is ok') - st.match(output, /node -v\s*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry\s*ok\s*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git\s*ok/, 'which git output is ok') - st.match(output, /cached files\s*ok/, 'cached files are ok') - st.match(output, /local node_modules\s*ok/, 'local node_modules are ok') - st.match(output, /global node_modules\s*ok/, 'global node_modules are ok') - st.match(output, /local bin folder\s*ok/, 'local bin is ok') - st.match(output, /global bin folder\s*ok/, 'global bin is ok') - st.match(output, /cache contents\s*ok/, 'cache contents is not ok') - }) - - vt.test('npm doctor not using default registry', async st => { - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - const _currentRegistry = npm.flatOptions.registry - npm.flatOptions.registry = 'https://google.com' - const consoleError = console.error - // we just print an empty line here, so swallow it and ignore - console.error = () => {} - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - npm.flatOptions.registry = _currentRegistry - console.error = consoleError - clearLogs() - }) - - await st.rejects( - doctor.exec([]), - /Some problems found/, - 'detected the non-default registry' - ) - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, - }, - 'trackers all finished' - ) - st.match(output, /npm ping\s*ok/, 'ping output is ok') - st.match(output, /npm -v\s*ok/, 'npm -v output is ok') - st.match(output, /node -v\s*ok/, 'node -v output is ok') - st.match( - output, - /npm config get registry\s*not ok/, - 'npm config get registry output is not ok' - ) - st.match(output, /which git\s*ok/, 'which git output is ok') - st.match(output, /cached files\s*ok/, 'cached files are ok') - st.match(output, /local node_modules\s*ok/, 'local node_modules are ok') - st.match(output, /global node_modules\s*ok/, 'global node_modules are ok') - st.match(output, /local bin folder\s*ok/, 'local bin is ok') - st.match(output, /global bin folder\s*ok/, 'global bin is ok') - st.match(output, /cache contents\s*ok/, 'cache contents is ok') - }) - - vt.end() - }) + ...dirs, }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'node is out of date') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') }) -t.test('outdated node version', vt => { - vt.plan(1) - const version = 'v10.0.0' - - Object.defineProperty(process, 'version', { value: version }) - vt.teardown(() => { - Object.defineProperty(process, 'version', { value: origVersion }) +t.test('non-default registry', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + config: { registry: 'http://some-other-url.npmjs.org' }, + ...dirs, }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'non default registry') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) - vt.test('npm doctor outdated nodejs version', async st => { - const dir = st.testdir() - npm.cache = npm.flatOptions.cache = dir - npm.localDir = dir - npm.globalDir = dir - npm.localBin = dir - npm.globalBin = dir - nodeVersions.push({ version: process.version.replace(/\d+(-.*)?$/, '999'), lts: false }) - const consoleError = console.error - // we just print an empty line here, so swallow it and ignore - console.error = () => {} - - st.teardown(() => { - delete npm.cache - delete npm.flatOptions.cache - delete npm.localDir - delete npm.globalDir - delete npm.localBin - delete npm.globalBin - nodeVersions.pop() - console.error = consoleError - clearLogs() - }) - - await st.rejects(doctor.exec([]), /Some problems found/, 'detected the out of date nodejs') - st.match( - logs, - { - checkPing: { finished: true }, - getLatestNpmVersion: { finished: true }, - getLatestNodejsVersion: { finished: true }, - getGitPath: { finished: true }, - [dir]: { finished: true }, - verifyCachedFiles: { finished: true }, +t.test('missing git', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks: { + ...mocks, + which: async () => { + throw new Error('test error') }, - 'trackers all finished' - ) - st.match(output, /npm ping\s*ok/, 'ping output is ok') - st.match(output, /npm -v\s*ok/, 'npm -v output is ok') - st.match(output, /node -v\s*not ok/, 'node -v output is not ok') - st.match( - output, - /npm config get registry\s*ok\s*using default/, - 'npm config get registry output is ok' - ) - st.match(output, /which git\s*ok/, 'which git output is ok') - st.match(output, /cached files\s*ok/, 'cached files are ok') - st.match(output, /local node_modules\s*ok/, 'local node_modules are ok') - st.match(output, /global node_modules\s*ok/, 'global node_modules are ok') - st.match(output, /local bin folder\s*ok/, 'local bin is ok') - st.match(output, /global bin folder\s*ok/, 'global bin is ok') - st.match(output, /cache contents\s*ok/, 'cache contents is ok') + }, + globals, + ...dirs, }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'missing git') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('windows skips permissions checks', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals: (context) => { + const g = globals(context) + return { + ...g, + process: { + ...g.process, + platform: 'win32', + }, + } + }, + prefixDir: {}, + globalPrefixDir: {}, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await npm.exec('doctor', []) + t.matchSnapshot(joinedOutput(), 'no permissions checks') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('missing global directories', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + prefixDir: dirs.prefixDir, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'missing global directories') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('missing local node_modules', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + globalPrefixDir: dirs.globalPrefixDir, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await npm.exec('doctor', []) + t.matchSnapshot(joinedOutput(), 'missing local node_modules') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('incorrect owner', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks: { + ...mocks, + fs: { + ...fs, + lstat: (p, cb) => { + const stat = fs.lstatSync(p) + if (p.endsWith('_cacache')) { + stat.uid += 1 + stat.gid += 1 + } + return cb(null, stat) + }, + }, + }, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'incorrect owner') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('incorrect permissions', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks: { + ...mocks, + fs: { + ...fs, + access: () => { + throw new Error('Test Error') + }, + }, + }, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'incorrect owner') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('error reading directory', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks: { + ...mocks, + fs: { + ...fs, + readdir: () => { + throw new Error('Test Error') + }, + }, + }, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'readdir error') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('cacache badContent', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks: { + ...mocks, + cacache: { + verify: async () => { + return { badContentCount: 1, reclaimedCount: 0, missingContent: 0, verifiedContent: 2 } + }, + }, + }, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await npm.exec('doctor', []) + t.matchSnapshot(joinedOutput(), 'corrupted cache content') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('cacache reclaimedCount', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks: { + ...mocks, + cacache: { + verify: async () => { + return { badContentCount: 0, reclaimedCount: 1, missingContent: 0, verifiedContent: 2 } + }, + }, + }, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await npm.exec('doctor', []) + t.matchSnapshot(joinedOutput(), 'content garbage collected') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('cacache missingContent', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks: { + ...mocks, + cacache: { + verify: async () => { + return { badContentCount: 0, reclaimedCount: 0, missingContent: 1, verifiedContent: 2 } + }, + }, + }, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await npm.exec('doctor', []) + t.matchSnapshot(joinedOutput(), 'missing content') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('bad proxy', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + config: { + proxy: 'ssh://npmjs.org', + }, + ...dirs, + }) + await t.rejects(npm.exec('doctor', [])) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') +}) + +t.test('discrete checks', t => { + t.test('ping', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + await npm.exec('doctor', ['ping']) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') + }) + + t.test('versions', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/npm').reply(200, npmManifest(npm.version)) + tnock(t, 'https://nodejs.org') + .get('/dist/index.json').reply(200, nodeVersions) + await npm.exec('doctor', ['versions']) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') + }) + + t.test('registry', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + tnock(t, npm.config.get('registry')) + .get('/-/ping?write=true').reply(200, '{}') + await npm.exec('doctor', ['registry']) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') + }) + + t.test('git', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + await npm.exec('doctor', ['git']) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') + }) + + t.test('permissions - not windows', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + await npm.exec('doctor', ['permissions']) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') + }) + + t.test('cache', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals, + ...dirs, + }) + await npm.exec('doctor', ['cache']) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') + }) + + t.test('permissions - windows', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals: (context) => { + const g = globals(context) + return { + ...g, + process: { + ...g.process, + platform: 'win32', + }, + } + }, + prefixDir: {}, + globalPrefixDir: {}, + }) + await npm.exec('doctor', ['permissions']) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') + }) + + t.test('invalid environment', async t => { + const { joinedOutput, logs, npm } = await loadMockNpm(t, { + mocks, + globals: (context) => { + const g = globals(context) + return { + ...g, + process: { + ...g.process, + 'env.PATH': '/nope', + }, + } + }, + prefixDir: {}, + globalPrefixDir: {}, + }) + await t.rejects(npm.exec('doctor', ['environment'])) + t.matchSnapshot(joinedOutput(), 'output') + t.matchSnapshot({ info: logs.info, warn: logs.warn, error: logs.error }, 'logs') + }) + + t.end() }) diff --git a/test/lib/commands/edit.js b/test/lib/commands/edit.js index 92754f2..dc71148 100644 --- a/test/lib/commands/edit.js +++ b/test/lib/commands/edit.js @@ -1,138 +1,131 @@ const t = require('tap') -const { resolve } = require('path') -const { EventEmitter } = require('events') +const path = require('path') +const tspawk = require('../../fixtures/tspawk') +const { load: loadMockNpm } = require('../../fixtures/mock-npm') -let editorBin = null -let editorArgs = null -let editorOpts = null -let EDITOR_CODE = 0 -const childProcess = { - spawn: (bin, args, opts) => { - // save for assertions - editorBin = bin - editorArgs = args - editorOpts = opts +const spawk = tspawk(t) - const editorEvents = new EventEmitter() - process.nextTick(() => { - editorEvents.emit('exit', EDITOR_CODE) - }) - return editorEvents - }, -} - -let rebuildArgs = null -let rebuildFail = null -let EDITOR = 'vim' -const npm = { +const npmConfig = { config: { - get: () => EDITOR, + 'ignore-scripts': false, + editor: 'testeditor', + scriptShell: process.platform === 'win32' ? process.env.COMSPEC : 'sh', }, - dir: resolve(__dirname, '../../../node_modules'), - exec: async (cmd, args) => { - rebuildArgs = args - if (rebuildFail) { - throw rebuildFail - } + prefixDir: { + node_modules: { + semver: { + 'package.json': JSON.stringify({ + scripts: { + install: 'testinstall', + }, + }), + node_modules: { + abbrev: {}, + }, + }, + '@npmcli': { + 'scoped-package': {}, + }, + }, }, } -const gracefulFs = require('graceful-fs') -const Edit = t.mock('../../../lib/commands/edit.js', { - child_process: childProcess, - 'graceful-fs': gracefulFs, -}) -const edit = new Edit(npm) +const isCmdRe = /(?:^|\\)cmd(?:\.exe)?$/i t.test('npm edit', async t => { - t.teardown(() => { - rebuildArgs = null - editorBin = null - editorArgs = null - editorOpts = null - }) + const { npm, joinedOutput } = await loadMockNpm(t, npmConfig) - await edit.exec(['semver']) - const path = resolve(__dirname, '../../../node_modules/semver') - t.strictSame(editorBin, EDITOR, 'used the correct editor') - t.strictSame(editorArgs, [path], 'edited the correct directory') - t.strictSame(editorOpts, { stdio: 'inherit' }, 'passed the correct opts') - t.strictSame(rebuildArgs, [path], 'passed the correct path to rebuild') + const semverPath = path.resolve(npm.prefix, 'node_modules', 'semver') + spawk.spawn('testeditor', [semverPath]) + + const scriptShell = npm.config.get('scriptShell') + const scriptArgs = isCmdRe.test(scriptShell) + ? ['/d', '/s', '/c', 'testinstall'] + : ['-c', 'testinstall'] + spawk.spawn(scriptShell, scriptArgs, { cwd: semverPath }) + + await npm.exec('edit', ['semver']) + t.match(joinedOutput(), 'rebuilt dependencies successfully') }) -t.test('rebuild fails', async t => { - t.teardown(() => { - rebuildFail = null - rebuildArgs = null - editorBin = null - editorArgs = null - editorOpts = null - }) +t.test('rebuild failure', async t => { + const { npm } = await loadMockNpm(t, npmConfig) - rebuildFail = new Error('test error') + const semverPath = path.resolve(npm.prefix, 'node_modules', 'semver') + spawk.spawn('testeditor', [semverPath]) + + const scriptShell = npm.config.get('scriptShell') + const scriptArgs = isCmdRe.test(scriptShell) + ? ['/d', '/s', '/c', 'testinstall'] + : ['-c', 'testinstall'] + spawk.spawn(scriptShell, scriptArgs, { cwd: semverPath }).exit(1).stdout('test error') await t.rejects( - edit.exec(['semver']), - { message: 'test error' } + npm.exec('edit', ['semver']), + { message: 'command failed' } + ) +}) + +t.test('editor failure', async t => { + const { npm } = await loadMockNpm(t, npmConfig) + + const semverPath = path.resolve(npm.prefix, 'node_modules', 'semver') + spawk.spawn('testeditor', [semverPath]).exit(1).stdout('test editor failure') + + await t.rejects( + npm.exec('edit', ['semver']), + { message: 'editor process exited with code: 1' } ) - const path = resolve(__dirname, '../../../node_modules/semver') - t.strictSame(editorBin, EDITOR, 'used the correct editor') - t.strictSame(editorArgs, [path], 'edited the correct directory') - t.strictSame(editorOpts, { stdio: 'inherit' }, 'passed the correct opts') - t.strictSame(rebuildArgs, [path], 'passed the correct path to rebuild') }) t.test('npm edit editor has flags', async t => { - EDITOR = 'code -w' - t.teardown(() => { - rebuildArgs = null - editorBin = null - editorArgs = null - editorOpts = null - EDITOR = 'vim' + const { npm } = await loadMockNpm(t, { + ...npmConfig, + config: { + ...npmConfig.config, + editor: 'testeditor --flag', + }, }) - await edit.exec(['semver']) + const semverPath = path.resolve(npm.prefix, 'node_modules', 'semver') + spawk.spawn('testeditor', ['--flag', semverPath]) - const path = resolve(__dirname, '../../../node_modules/semver') - t.strictSame(editorBin, 'code', 'used the correct editor') - t.strictSame(editorArgs, ['-w', path], 'edited the correct directory, keeping flags') - t.strictSame(editorOpts, { stdio: 'inherit' }, 'passed the correct opts') - t.strictSame(rebuildArgs, [path], 'passed the correct path to rebuild') + const scriptShell = npm.config.get('scriptShell') + const scriptArgs = isCmdRe.test(scriptShell) + ? ['/d', '/s', '/c', 'testinstall'] + : ['-c', 'testinstall'] + spawk.spawn(scriptShell, scriptArgs, { cwd: semverPath }) + + await npm.exec('edit', ['semver']) }) t.test('npm edit no args', async t => { + const { npm } = await loadMockNpm(t) await t.rejects( - edit.exec([]), - /npm edit/, + npm.exec('edit', []), + { code: 'EUSAGE' }, 'throws usage error' ) }) -t.test('npm edit lstat error propagates', async t => { - const _lstat = gracefulFs.lstat - gracefulFs.lstat = (dir, cb) => { - return cb(new Error('lstat failed')) - } - t.teardown(() => { - gracefulFs.lstat = _lstat - }) +t.test('npm edit nonexistent package', async t => { + const { npm } = await loadMockNpm(t, npmConfig) await t.rejects( - edit.exec(['semver']), - /lstat failed/, - 'user received correct error' + npm.exec('edit', ['abbrev']), + /lstat/ ) }) -t.test('npm edit editor exit code error propagates', async t => { - EDITOR_CODE = 137 - t.teardown(() => { - EDITOR_CODE = 0 - }) - - await t.rejects( - edit.exec(['semver']), - /exited with code: 137/, - 'user received correct error' - ) +t.test('scoped package', async t => { + const { npm } = await loadMockNpm(t, npmConfig) + const scopedPath = path.resolve(npm.prefix, 'node_modules', '@npmcli', 'scoped-package') + spawk.spawn('testeditor', [scopedPath]) + await npm.exec('edit', ['@npmcli/scoped-package']) +}) + +t.test('subdependency', async t => { + const { npm } = await loadMockNpm(t, npmConfig) + const subdepPath = path.resolve(npm.prefix, 'node_modules', 'semver', 'node_modules', 'abbrev') + spawk.spawn('testeditor', [subdepPath]) + await npm.exec('edit', ['semver/abbrev']) }) diff --git a/test/lib/commands/exec.js b/test/lib/commands/exec.js index 3c75c1d..1a03b1a 100644 --- a/test/lib/commands/exec.js +++ b/test/lib/commands/exec.js @@ -1,1228 +1,140 @@ const t = require('tap') -const { fake: mockNpm } = require('../../fixtures/mock-npm') -const { resolve, delimiter } = require('path') +const fs = require('fs/promises') +const path = require('path') +const { load: loadMockNpm } = require('../../fixtures/mock-npm.js') +const MockRegistry = require('@npmcli/mock-registry') -const ARB_CTOR = [] -const ARB_ACTUAL_TREE = {} -const ARB_REIFY = [] -class Arborist { - constructor (options) { - ARB_CTOR.push(options) - this.path = options.path - } - - async loadActual () { - return ARB_ACTUAL_TREE[this.path] - } - - async reify (options) { - ARB_REIFY.push(options) - } -} - -let PROGRESS_ENABLED = true -const LOG_WARN = [] -let PROGRESS_IGNORED = false -const flatOptions = { - npxCache: 'npx-cache-dir', - color: false, - cache: 'cache-dir', - legacyPeerDeps: false, - package: [], -} -const config = { - cache: 'bad-cache-dir', // this should never show up passed into libnpmexec - yes: true, - call: '', - package: [], - 'script-shell': 'shell-cmd', -} - -const npm = mockNpm({ - flatOptions, - config, - localPrefix: 'local-prefix', - localBin: 'local-bin', - globalBin: 'global-bin', -}) - -const RUN_SCRIPTS = [] -const runScript = async opt => { - RUN_SCRIPTS.push(opt) - if (!PROGRESS_IGNORED && PROGRESS_ENABLED) { - throw new Error('progress not disabled during run script!') - } -} - -const MANIFESTS = {} -const pacote = { - manifest: async (spec, options) => { - return MANIFESTS[spec] - }, -} - -const MKDIRPS = [] -const mkdirp = async path => MKDIRPS.push(path) - -let READ_RESULT = '' -let READ_ERROR = null -const READ = [] -const read = (options, cb) => { - READ.push(options) - process.nextTick(() => cb(READ_ERROR, READ_RESULT)) -} - -const PATH = require('../../../lib/utils/path.js') - -let CI_NAME = 'travis-ci' - -const log = { - 'proc-log': { - warn: (...args) => { - LOG_WARN.push(args) - }, - }, - npmlog: { - disableProgress: () => { - PROGRESS_ENABLED = false - }, - enableProgress: () => { - PROGRESS_ENABLED = true - }, - clearProgress: () => {}, - }, -} - -const mocks = { - libnpmexec: t.mock('libnpmexec', { - '@npmcli/arborist': Arborist, - '@npmcli/run-script': runScript, - '@npmcli/ci-detect': () => CI_NAME, - pacote, - read, - 'mkdirp-infer-owner': mkdirp, - ...log, - }), - ...log, -} -const Exec = t.mock('../../../lib/commands/exec.js', mocks) -const exec = new Exec(npm) - -t.afterEach(() => { - MKDIRPS.length = 0 - ARB_CTOR.length = 0 - ARB_REIFY.length = 0 - RUN_SCRIPTS.length = 0 - READ.length = 0 - READ_RESULT = '' - READ_ERROR = null - LOG_WARN.length = 0 - PROGRESS_IGNORED = false - flatOptions.legacyPeerDeps = false - flatOptions.color = false - config['script-shell'] = 'shell-cmd' - config.package = [] - flatOptions.package = [] - config.call = '' - config.yes = true - npm.color = false - npm.localBin = 'local-bin' - npm.globalBin = 'global-bin' -}) - -t.test('npx foo, bin already exists locally', async t => { - const path = t.testdir({ - node_modules: { - '.bin': { - foo: 'just some file', - }, +t.test('call with args', async t => { + const { npm } = await loadMockNpm(t, { + config: { + call: 'foo', }, }) - PROGRESS_IGNORED = true - npm.localBin = resolve(path, 'node_modules', '.bin') - - await exec.exec(['foo', 'one arg', 'two arg']) - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'foo' } }, - args: ['one arg', 'two arg'], - cache: flatOptions.cache, - npxCache: flatOptions.npxCache, - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { - PATH: [npm.localBin, ...PATH].join(delimiter), - }, - stdio: 'inherit', - }, - ]) -}) - -t.test('npx foo, bin already exists globally', async t => { - const path = t.testdir({ - node_modules: { - '.bin': { - foo: 'just some file', - }, - }, - }) - - PROGRESS_IGNORED = true - npm.globalBin = resolve(path, 'node_modules', '.bin') - - await exec.exec(['foo', 'one arg', 'two arg']) - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'foo' } }, - args: ['one arg', 'two arg'], - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { - PATH: [npm.globalBin, ...PATH].join(delimiter), - }, - stdio: 'inherit', - }, - ]) -}) - -t.test('npm exec foo, already present locally', async t => { - const path = t.testdir() - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map([['foo', { name: 'foo', version: '1.2.3' }]]), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - await exec.exec(['foo', 'one arg', 'two arg']) - t.strictSame(MKDIRPS, [], 'no need to make any dirs') - t.match(ARB_CTOR, [{ path }]) - t.strictSame(ARB_REIFY, [], 'no need to reify anything') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'foo' } }, - args: ['one arg', 'two arg'], - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH: process.env.PATH }, - stdio: 'inherit', - }, - ]) -}) - -t.test('npm exec <noargs>, run interactive shell', t => { - CI_NAME = null - const { isTTY } = process.stdin - process.stdin.isTTY = true - t.teardown(() => (process.stdin.isTTY = isTTY)) - - const run = async (t, doRun) => { - LOG_WARN.length = 0 - ARB_CTOR.length = 0 - MKDIRPS.length = 0 - ARB_REIFY.length = 0 - npm._mockOutputs.length = 0 - await exec.exec([]) - t.strictSame(MKDIRPS, [], 'no need to make any dirs') - t.strictSame(ARB_CTOR, [], 'no need to instantiate arborist') - t.strictSame(ARB_REIFY, [], 'no need to reify anything') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - if (doRun) { - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'shell-cmd' } }, - args: [], - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH: process.env.PATH }, - stdio: 'inherit', - }, - ]) - } else { - t.strictSame(RUN_SCRIPTS, []) - } - - RUN_SCRIPTS.length = 0 - } - t.test('print message when tty and not in CI', async t => { - CI_NAME = null - process.stdin.isTTY = true - await run(t, true) - t.strictSame(LOG_WARN, []) - t.strictSame( - npm._mockOutputs, - [ - [ - /* eslint-disable-next-line max-len */ - `\nEntering npm script environment at location:\n${process.cwd()}\nType 'exit' or ^D when finished\n`, - ], - ], - 'printed message about interactive shell' - ) - }) - - t.test('print message with color when tty and not in CI', async t => { - CI_NAME = null - process.stdin.isTTY = true - npm.color = true - flatOptions.color = true - - await run(t, true) - t.strictSame(LOG_WARN, []) - t.strictSame( - npm._mockOutputs, - [ - [ - /* eslint-disable-next-line max-len */ - `\u001b[0m\u001b[0m\n\u001b[0mEntering npm script environment\u001b[0m\u001b[0m at location:\u001b[0m\n\u001b[0m\u001b[2m${process.cwd()}\u001b[22m\u001b[0m\u001b[1m\u001b[22m\n\u001b[1mType 'exit' or ^D when finished\u001b[22m\n\u001b[1m\u001b[22m`, - ], - ], - 'printed message about interactive shell' - ) - }) - - t.test('no message when not TTY', async t => { - CI_NAME = null - process.stdin.isTTY = false - await run(t, true) - t.strictSame(LOG_WARN, []) - t.strictSame(npm._mockOutputs, [], 'no message about interactive shell') - }) - - t.test('print warning when in CI and interactive', async t => { - CI_NAME = 'travis-ci' - process.stdin.isTTY = true - await run(t, false) - t.strictSame(LOG_WARN, [['exec', 'Interactive mode disabled in CI environment']]) - t.strictSame(npm._mockOutputs, [], 'no message about interactive shell') - }) - - t.test('not defined script-shell config value', async t => { - CI_NAME = null - process.stdin.isTTY = true - config['script-shell'] = undefined - - await exec.exec([]) - - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: /sh|cmd/ } }, - }, - ]) - - LOG_WARN.length = 0 - ARB_CTOR.length = 0 - MKDIRPS.length = 0 - ARB_REIFY.length = 0 - npm._mockOutputs.length = 0 - RUN_SCRIPTS.length = 0 - }) - - t.end() -}) - -t.test('npm exec foo, not present locally or in central loc', async t => { - const path = t.testdir() - const installDir = resolve('npx-cache-dir/f7fbba6e0636f890') - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map(), - } - ARB_ACTUAL_TREE[installDir] = { - children: new Map(), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - await exec.exec(['foo', 'one arg', 'two arg']) - t.strictSame(MKDIRPS, [installDir], 'need to make install dir') - t.match(ARB_CTOR, [{ path }]) - t.match(ARB_REIFY, [{ add: ['foo@'], legacyPeerDeps: false }], 'need to install foo@') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - const PATH = `${resolve(installDir, 'node_modules', '.bin')}${delimiter}${process.env.PATH}` - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'foo' } }, - args: ['one arg', 'two arg'], - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH }, - stdio: 'inherit', - }, - ]) -}) - -t.test('npm exec foo, not present locally but in central loc', async t => { - const path = t.testdir() - const installDir = resolve('npx-cache-dir/f7fbba6e0636f890') - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map(), - } - ARB_ACTUAL_TREE[installDir] = { - children: new Map([['foo', { name: 'foo', version: '1.2.3' }]]), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - await exec.exec(['foo', 'one arg', 'two arg']) - t.strictSame(MKDIRPS, [installDir], 'need to make install dir') - t.match(ARB_CTOR, [{ path }]) - t.match(ARB_REIFY, [], 'no need to install again, already there') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - const PATH = `${resolve(installDir, 'node_modules', '.bin')}${delimiter}${process.env.PATH}` - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'foo' } }, - args: ['one arg', 'two arg'], - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH }, - stdio: 'inherit', - }, - ]) -}) - -t.test('npm exec foo, present locally but wrong version', async t => { - const path = t.testdir() - const installDir = resolve('npx-cache-dir/2badf4630f1cfaad') - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map(), - } - ARB_ACTUAL_TREE[installDir] = { - children: new Map([['foo', { name: 'foo', version: '1.2.3' }]]), - } - MANIFESTS['foo@2.x'] = { - name: 'foo', - version: '2.3.4', - bin: { - foo: 'foo', - }, - _from: 'foo@2.x', - } - await exec.exec(['foo@2.x', 'one arg', 'two arg']) - t.strictSame(MKDIRPS, [installDir], 'need to make install dir') - t.match(ARB_CTOR, [{ path }]) - t.match(ARB_REIFY, [{ add: ['foo@2.x'], legacyPeerDeps: false }], 'need to add foo@2.x') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - const PATH = `${resolve(installDir, 'node_modules', '.bin')}${delimiter}${process.env.PATH}` - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'foo' } }, - args: ['one arg', 'two arg'], - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH }, - stdio: 'inherit', - }, - ]) -}) - -t.test('npm exec --package=foo bar', async t => { - const path = t.testdir() - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map([['foo', { name: 'foo', version: '1.2.3' }]]), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - config.package = ['foo'] - flatOptions.package = ['foo'] - await exec.exec(['bar', 'one arg', 'two arg']) - t.strictSame(MKDIRPS, [], 'no need to make any dirs') - t.match(ARB_CTOR, [{ path }]) - t.strictSame(ARB_REIFY, [], 'no need to reify anything') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'bar' } }, - args: ['one arg', 'two arg'], - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH: process.env.PATH }, - stdio: 'inherit', - }, - ]) -}) - -t.test('npm exec @foo/bar -- --some=arg, locally installed', async t => { - const foobarManifest = { - name: '@foo/bar', - version: '1.2.3', - bin: { - foo: 'foo', - bar: 'bar', - }, - } - const path = t.testdir({ - node_modules: { - '@foo/bar': { - 'package.json': JSON.stringify(foobarManifest), - }, - }, - }) - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map([['@foo/bar', { name: '@foo/bar', version: '1.2.3' }]]), - } - MANIFESTS['@foo/bar'] = foobarManifest - await exec.exec(['@foo/bar', '--some=arg']) - t.strictSame(MKDIRPS, [], 'no need to make any dirs') - t.match(ARB_CTOR, [{ path }]) - t.strictSame(ARB_REIFY, [], 'no need to reify anything') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'bar' } }, - args: ['--some=arg'], - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH: process.env.PATH }, - stdio: 'inherit', - }, - ]) -}) - -t.test( - 'npm exec @foo/bar, with same bin alias and no unscoped named bin, locally installed', - async t => { - const foobarManifest = { - name: '@foo/bar', - version: '1.2.3', - bin: { - baz: 'corge', // pick the first one - qux: 'corge', - quux: 'corge', - }, - } - const path = t.testdir({ - node_modules: { - '@foo/bar': { - 'package.json': JSON.stringify(foobarManifest), - }, - }, - }) - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map([['@foo/bar', { name: '@foo/bar', version: '1.2.3' }]]), - } - MANIFESTS['@foo/bar'] = foobarManifest - await exec.exec(['@foo/bar', 'one arg', 'two arg']) - t.strictSame(MKDIRPS, [], 'no need to make any dirs') - t.match(ARB_CTOR, [{ path }]) - t.strictSame(ARB_REIFY, [], 'no need to reify anything') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'baz' } }, - args: ['one arg', 'two arg'], - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH: process.env.PATH }, - stdio: 'inherit', - }, - ]) - } -) - -t.test( - 'npm exec @foo/bar, with different bin alias and no unscoped named bin, locally installed', - async t => { - const path = t.testdir() - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map([['@foo/bar', { name: '@foo/bar', version: '1.2.3' }]]), - } - MANIFESTS['@foo/bar'] = { - name: '@foo/bar', - version: '1.2.3', - bin: { - foo: 'qux', - corge: 'qux', - baz: 'quux', - }, - _from: 'foo@', - _id: '@foo/bar@1.2.3', - } - await t.rejects(exec.exec(['@foo/bar']), { - message: 'could not determine executable to run', - pkgid: '@foo/bar@1.2.3', - }) - } -) - -t.test('run command with 2 packages, need install, verify sort', async t => { - // test both directions, should use same install dir both times - // also test the read() call here, verify that the prompts match - const cases = [ - ['foo', 'bar'], - ['bar', 'foo'], - ] - t.plan(cases.length) - for (const packages of cases) { - t.test(packages.join(', '), async t => { - config.package = packages - const add = packages.map(p => `${p}@`).sort((a, b) => a.localeCompare(b, 'en')) - const path = t.testdir() - const installDir = resolve('npx-cache-dir/07de77790e5f40f2') - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map(), - } - ARB_ACTUAL_TREE[installDir] = { - children: new Map(), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - MANIFESTS.bar = { - name: 'bar', - version: '1.2.3', - bin: { - bar: 'bar', - }, - _from: 'bar@', - } - await exec.exec(['foobar', 'one arg', 'two arg']) - t.strictSame(MKDIRPS, [installDir], 'need to make install dir') - t.match(ARB_CTOR, [{ path }]) - t.match(ARB_REIFY, [{ add, legacyPeerDeps: false }], 'need to install both packages') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - const PATH = `${resolve(installDir, 'node_modules', '.bin')}${delimiter}${process.env.PATH}` - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'foobar' } }, - args: ['one arg', 'two arg'], - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH }, - stdio: 'inherit', - }, - ]) - }) - } -}) - -t.test('npm exec foo, no bin in package', async t => { - const path = t.testdir() - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map([['foo', { name: 'foo', version: '1.2.3' }]]), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - _from: 'foo@', - _id: 'foo@1.2.3', - } - await t.rejects(exec.exec(['foo']), { - message: 'could not determine executable to run', - pkgid: 'foo@1.2.3', - }) -}) - -t.test('npm exec foo, many bins in package, none named foo', async t => { - const path = t.testdir() - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map([['foo', { name: 'foo', version: '1.2.3' }]]), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - bar: 'bar', - baz: 'baz', - }, - _from: 'foo@', - _id: 'foo@1.2.3', - } - await t.rejects(exec.exec(['foo']), { - message: 'could not determine executable to run', - pkgid: 'foo@1.2.3', - }) -}) - -t.test('npm exec -p foo -c "ls -laF"', async t => { - const path = t.testdir() - npm.localPrefix = path - config.package = ['foo'] - config.call = 'ls -laF' - ARB_ACTUAL_TREE[path] = { - children: new Map([['foo', { name: 'foo', version: '1.2.3' }]]), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - _from: 'foo@', - } - await exec.exec([]) - t.strictSame(MKDIRPS, [], 'no need to make any dirs') - t.match(ARB_CTOR, [{ path }]) - t.strictSame(ARB_REIFY, [], 'no need to reify anything') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'ls -laF' } }, - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH: process.env.PATH }, - stdio: 'inherit', - }, - ]) -}) - -t.test('positional args and --call together is an error', async t => { - config.call = 'true' - await t.rejects(exec.exec(['foo']), exec.usage) -}) - -t.test('prompt when installs are needed if not already present and shell is a TTY', async t => { - const stdoutTTY = process.stdout.isTTY - const stdinTTY = process.stdin.isTTY - t.teardown(() => { - process.stdout.isTTY = stdoutTTY - process.stdin.isTTY = stdinTTY - CI_NAME = 'travis-ci' - }) - process.stdout.isTTY = true - process.stdin.isTTY = true - CI_NAME = false - - const packages = ['foo', 'bar'] - READ_RESULT = 'yolo' - - config.package = packages - config.yes = undefined - - const add = packages.map(p => `${p}@`).sort((a, b) => a.localeCompare(b, 'en')) - const path = t.testdir() - const installDir = resolve('npx-cache-dir/07de77790e5f40f2') - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map(), - } - ARB_ACTUAL_TREE[installDir] = { - children: new Map(), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - MANIFESTS.bar = { - name: 'bar', - version: '1.2.3', - bin: { - bar: 'bar', - }, - _from: 'bar@', - } - await exec.exec(['foobar']) - t.strictSame(MKDIRPS, [installDir], 'need to make install dir') - t.match(ARB_CTOR, [{ path }]) - t.match(ARB_REIFY, [{ add, legacyPeerDeps: false }], 'need to install both packages') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - const PATH = `${resolve(installDir, 'node_modules', '.bin')}${delimiter}${process.env.PATH}` - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'foobar' } }, - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH }, - stdio: 'inherit', - }, - ]) - t.strictSame(READ, [ - { - prompt: 'Need to install the following packages:\n bar\n foo\nOk to proceed? ', - default: 'y', - }, - ]) -}) - -t.test( - /* eslint-disable-next-line max-len */ - 'skip prompt when installs are needed if not already present and shell is not a tty (multiple packages)', - async t => { - const stdoutTTY = process.stdout.isTTY - const stdinTTY = process.stdin.isTTY - t.teardown(() => { - process.stdout.isTTY = stdoutTTY - process.stdin.isTTY = stdinTTY - CI_NAME = 'travis-ci' - }) - process.stdout.isTTY = false - process.stdin.isTTY = false - CI_NAME = false - - const packages = ['foo', 'bar'] - READ_RESULT = 'yolo' - - config.package = packages - config.yes = undefined - - const add = packages.map(p => `${p}@`).sort((a, b) => a.localeCompare(b, 'en')) - const path = t.testdir() - const installDir = resolve('npx-cache-dir/07de77790e5f40f2') - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map(), - } - ARB_ACTUAL_TREE[installDir] = { - children: new Map(), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - MANIFESTS.bar = { - name: 'bar', - version: '1.2.3', - bin: { - bar: 'bar', - }, - _from: 'bar@', - } - await exec.exec(['foobar']) - t.strictSame(MKDIRPS, [installDir], 'need to make install dir') - t.match(ARB_CTOR, [{ path }]) - t.match(ARB_REIFY, [{ add, legacyPeerDeps: false }], 'need to install both packages') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - const PATH = `${resolve(installDir, 'node_modules', '.bin')}${delimiter}${process.env.PATH}` - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'foobar' } }, - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH }, - stdio: 'inherit', - }, - ]) - t.strictSame(READ, [], 'should not have prompted') - t.strictSame( - LOG_WARN, - [['exec', 'The following packages were not found and will be installed: bar, foo']], - 'should have printed a warning' - ) - } -) - -t.test( - /* eslint-disable-next-line max-len */ - 'skip prompt when installs are needed if not already present and shell is not a tty (single package)', - async t => { - const stdoutTTY = process.stdout.isTTY - const stdinTTY = process.stdin.isTTY - t.teardown(() => { - process.stdout.isTTY = stdoutTTY - process.stdin.isTTY = stdinTTY - CI_NAME = 'travis-ci' - }) - process.stdout.isTTY = false - process.stdin.isTTY = false - CI_NAME = false - - const packages = ['foo'] - READ_RESULT = 'yolo' - - config.package = packages - config.yes = undefined - - const add = packages.map(p => `${p}@`).sort((a, b) => a.localeCompare(b, 'en')) - const path = t.testdir() - const installDir = resolve('npx-cache-dir/f7fbba6e0636f890') - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map(), - } - ARB_ACTUAL_TREE[installDir] = { - children: new Map(), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - await exec.exec(['foobar']) - t.strictSame(MKDIRPS, [installDir], 'need to make install dir') - t.match(ARB_CTOR, [{ path }]) - t.match(ARB_REIFY, [{ add, legacyPeerDeps: false }], 'need to install the package') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - const PATH = `${resolve(installDir, 'node_modules', '.bin')}${delimiter}${process.env.PATH}` - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'foobar' } }, - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { PATH }, - stdio: 'inherit', - }, - ]) - t.strictSame(READ, [], 'should not have prompted') - t.strictSame( - LOG_WARN, - [['exec', 'The following package was not found and will be installed: foo']], - 'should have printed a warning' - ) - } -) - -t.test('abort if prompt rejected', async t => { - const stdoutTTY = process.stdout.isTTY - const stdinTTY = process.stdin.isTTY - t.teardown(() => { - process.stdout.isTTY = stdoutTTY - process.stdin.isTTY = stdinTTY - CI_NAME = 'travis-ci' - }) - process.stdout.isTTY = true - process.stdin.isTTY = true - CI_NAME = false - - const packages = ['foo', 'bar'] - READ_RESULT = 'no, why would I want such a thing??' - - config.package = packages - config.yes = undefined - - const path = t.testdir() - const installDir = resolve('npx-cache-dir/07de77790e5f40f2') - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map(), - } - ARB_ACTUAL_TREE[installDir] = { - children: new Map(), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - MANIFESTS.bar = { - name: 'bar', - version: '1.2.3', - bin: { - bar: 'bar', - }, - _from: 'bar@', - } - await t.rejects(exec.exec(['foobar']), /canceled/, 'should be canceled') - t.strictSame(MKDIRPS, [installDir], 'need to make install dir') - t.match(ARB_CTOR, [{ path }]) - t.strictSame(ARB_REIFY, [], 'no install performed') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - t.strictSame(RUN_SCRIPTS, []) - t.strictSame(READ, [ - { - prompt: 'Need to install the following packages:\n bar\n foo\nOk to proceed? ', - default: 'y', - }, - ]) -}) - -t.test('abort if prompt false', async t => { - const stdoutTTY = process.stdout.isTTY - const stdinTTY = process.stdin.isTTY - t.teardown(() => { - process.stdout.isTTY = stdoutTTY - process.stdin.isTTY = stdinTTY - CI_NAME = 'travis-ci' - }) - process.stdout.isTTY = true - process.stdin.isTTY = true - CI_NAME = false - - const packages = ['foo', 'bar'] - READ_ERROR = 'canceled' - - config.package = packages - config.yes = undefined - - const path = t.testdir() - const installDir = resolve('npx-cache-dir/07de77790e5f40f2') - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map(), - } - ARB_ACTUAL_TREE[installDir] = { - children: new Map(), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - MANIFESTS.bar = { - name: 'bar', - version: '1.2.3', - bin: { - bar: 'bar', - }, - _from: 'bar@', - } - await t.rejects(exec.exec(['foobar']), 'canceled', 'should be canceled') - t.strictSame(MKDIRPS, [installDir], 'need to make install dir') - t.match(ARB_CTOR, [{ path }]) - t.strictSame(ARB_REIFY, [], 'no install performed') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - t.strictSame(RUN_SCRIPTS, []) - t.strictSame(READ, [ - { - prompt: 'Need to install the following packages:\n bar\n foo\nOk to proceed? ', - default: 'y', - }, - ]) -}) - -t.test('abort if -n provided', async t => { - const stdoutTTY = process.stdout.isTTY - const stdinTTY = process.stdin.isTTY - t.teardown(() => { - process.stdout.isTTY = stdoutTTY - process.stdin.isTTY = stdinTTY - CI_NAME = 'travis-ci' - }) - process.stdout.isTTY = true - process.stdin.isTTY = true - CI_NAME = false - - const packages = ['foo', 'bar'] - - config.package = packages - config.yes = false - - const path = t.testdir() - const installDir = resolve('npx-cache-dir/07de77790e5f40f2') - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map(), - } - ARB_ACTUAL_TREE[installDir] = { - children: new Map(), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - MANIFESTS.bar = { - name: 'bar', - version: '1.2.3', - bin: { - bar: 'bar', - }, - _from: 'bar@', - } - await t.rejects(exec.exec(['foobar']), /canceled/, 'should be canceled') - t.strictSame(MKDIRPS, [installDir], 'need to make install dir') - t.match(ARB_CTOR, [{ path }]) - t.strictSame(ARB_REIFY, [], 'no install performed') - t.equal(PROGRESS_ENABLED, true, 'progress re-enabled') - t.strictSame(RUN_SCRIPTS, []) - t.strictSame(READ, []) -}) - -t.test('forward legacyPeerDeps opt', async t => { - const path = t.testdir() - const installDir = resolve('npx-cache-dir/f7fbba6e0636f890') - npm.localPrefix = path - ARB_ACTUAL_TREE[path] = { - children: new Map(), - } - ARB_ACTUAL_TREE[installDir] = { - children: new Map(), - } - MANIFESTS.foo = { - name: 'foo', - version: '1.2.3', - bin: { - foo: 'foo', - }, - _from: 'foo@', - } - config.yes = true - flatOptions.legacyPeerDeps = true - await exec.exec(['foo']) - t.match( - ARB_REIFY, - [{ add: ['foo@'], legacyPeerDeps: true }], - 'need to install foo@ using legacyPeerDeps opt' + await t.rejects( + npm.exec('exec', ['bar']), + { code: 'EUSAGE' } ) }) -t.test('workspaces', t => { - npm.localPrefix = t.testdir({ - node_modules: { - '.bin': { - foo: '', +t.test('registry package', async t => { + const registry = new MockRegistry({ + tap: t, + registry: 'https://registry.npmjs.org/', + }) + + const manifest = registry.manifest({ name: '@npmcli/npx-test' }) + manifest.versions['1.0.0'].bin = { 'npx-test': 'index.js' } + + const { npm } = await loadMockNpm(t, { + config: { + audit: false, + yes: true, + }, + prefixDir: { + 'npm-exec-test': { + 'package.json': JSON.stringify(manifest), + 'index.js': `#!/usr/bin/env node + require('fs').writeFileSync('npm-exec-test-success', '')`, }, }, - packages: { - a: { - 'package.json': JSON.stringify({ - name: 'a', - version: '1.0.0', - bin: 'cli.js', - }), - 'cli.js': '', - }, - b: { - 'package.json': JSON.stringify({ - name: 'b', - version: '1.0.0', - }), - }, - }, - 'package.json': JSON.stringify({ - name: 'root', - version: '1.0.0', - workspaces: ['packages/*'], + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, }), }) - PROGRESS_IGNORED = true - npm.localBin = resolve(npm.localPrefix, 'node_modules/.bin') + await registry.package({ + manifest, + tarballs: { + '1.0.0': path.join(npm.prefix, 'npm-exec-test'), + } }) - t.test('with args, run scripts in the context of a workspace', async t => { - await exec.execWorkspaces(['foo', 'one arg', 'two arg'], ['a', 'b']) - - t.match(RUN_SCRIPTS, [ - { - pkg: { scripts: { npx: 'foo' } }, - args: ['one arg', 'two arg'], - banner: false, - path: process.cwd(), - stdioString: true, - event: 'npx', - env: { - PATH: [npm.localBin, ...PATH].join(delimiter), - }, - stdio: 'inherit', - }, - ]) - }) - - t.test('no args, spawn interactive shell', async t => { - CI_NAME = null - process.stdin.isTTY = true - - await exec.execWorkspaces([], ['a']) - - t.strictSame(LOG_WARN, []) - t.strictSame( - npm._mockOutputs, - [ - [ - `\nEntering npm script environment in workspace a@1.0.0 at location:\n${resolve( - npm.localPrefix, - 'packages/a' - )}\nType 'exit' or ^D when finished\n`, - ], - ], - 'printed message about interactive shell' - ) - - npm.color = true - flatOptions.color = true - npm._mockOutputs.length = 0 - await exec.execWorkspaces([], ['a']) - - t.strictSame(LOG_WARN, []) - t.strictSame( - npm._mockOutputs, - [ - [ - /* eslint-disable-next-line max-len */ - `\u001b[0m\u001b[0m\n\u001b[0mEntering npm script environment\u001b[0m\u001b[0m in workspace \u001b[32ma@1.0.0\u001b[39m at location:\u001b[0m\n\u001b[0m\u001b[2m${resolve( - npm.localPrefix, - 'packages/a' - /* eslint-disable-next-line max-len */ - )}\u001b[22m\u001b[0m\u001b[1m\u001b[22m\n\u001b[1mType 'exit' or ^D when finished\u001b[22m\n\u001b[1m\u001b[22m`, - ], - ], - 'printed message about interactive shell' - ) - }) - - t.end() + await npm.exec('exec', ['@npmcli/npx-test']) + const exists = await fs.stat(path.join(npm.prefix, 'npm-exec-test-success')) + t.ok(exists.isFile(), 'bin ran, creating file') +}) + +t.test('--prefix', async t => { + const registry = new MockRegistry({ + tap: t, + registry: 'https://registry.npmjs.org/', + }) + + const manifest = registry.manifest({ name: '@npmcli/npx-test' }) + manifest.versions['1.0.0'].bin = { 'npx-test': 'index.js' } + + const { npm } = await loadMockNpm(t, { + config: { + audit: false, + yes: true, + }, + prefixDir: { + 'npm-exec-test': { + 'package.json': JSON.stringify(manifest), + 'index.js': `#!/usr/bin/env node + require('fs').writeFileSync('npm-exec-test-success', '')`, + }, + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + + // This is what `--prefix` does + npm.globalPrefix = npm.localPrefix + + await registry.package({ + manifest, + tarballs: { + '1.0.0': path.join(npm.prefix, 'npm-exec-test'), + } }) + + await npm.exec('exec', ['@npmcli/npx-test']) + const exists = await fs.stat(path.join(npm.prefix, 'npm-exec-test-success')) + t.ok(exists.isFile(), 'bin ran, creating file') +}) + +t.test('workspaces', async t => { + const registry = new MockRegistry({ + tap: t, + registry: 'https://registry.npmjs.org/', + }) + + const manifest = registry.manifest({ name: '@npmcli/npx-test' }) + manifest.versions['1.0.0'].bin = { 'npx-test': 'index.js' } + + const { npm } = await loadMockNpm(t, { + config: { + audit: false, + yes: true, + workspace: ['workspace-a'], + }, + prefixDir: { + 'npm-exec-test': { + 'package.json': JSON.stringify(manifest), + 'index.js': `#!/usr/bin/env node + require('fs').writeFileSync('npm-exec-test-success', '')`, + }, + 'package.json': JSON.stringify({ + name: '@npmcli/npx-workspace-test', + workspaces: ['workspace-a'], + }), + 'workspace-a': { + 'package.json': JSON.stringify({ + name: 'workspace-a', + }), + }, + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + + await registry.package({ manifest, + tarballs: { + '1.0.0': path.join(npm.prefix, 'npm-exec-test'), + } }) + await npm.exec('exec', ['@npmcli/npx-test']) + const exists = await fs.stat(path.join(npm.prefix, 'workspace-a', 'npm-exec-test-success')) + t.ok(exists.isFile(), 'bin ran, creating file inside workspace') }) diff --git a/test/lib/commands/explain.js b/test/lib/commands/explain.js index 63deb8b..71bb175 100644 --- a/test/lib/commands/explain.js +++ b/test/lib/commands/explain.js @@ -6,6 +6,15 @@ const npm = { output: (...args) => { OUTPUT.push(args) }, + config: { + validate: () => {}, + get: (key) => { + if (key === 'location') { + return 'project' + } + }, + isDefault: () => {}, + }, } const { resolve } = require('path') diff --git a/test/lib/commands/explore.js b/test/lib/commands/explore.js index d1355d7..af6f4df 100644 --- a/test/lib/commands/explore.js +++ b/test/lib/commands/explore.js @@ -47,7 +47,6 @@ const output = [] const logs = [] const getExplore = (windows) => { const Explore = t.mock('../../../lib/commands/explore.js', { - '../../../lib/utils/is-windows.js': windows, path: require('path')[windows ? 'win32' : 'posix'], 'read-package-json-fast': mockRPJ, '@npmcli/run-script': mockRunScript, @@ -68,6 +67,9 @@ const getExplore = (windows) => { output: out => { output.push(out) }, + config: { + validate: () => {}, + }, } return new Explore(npm) } diff --git a/test/lib/commands/find-dupes.js b/test/lib/commands/find-dupes.js index 06bd097..40022fa 100644 --- a/test/lib/commands/find-dupes.js +++ b/test/lib/commands/find-dupes.js @@ -1,28 +1,84 @@ const t = require('tap') +const path = require('path') +const fs = require('fs') const { load: loadMockNpm } = require('../../fixtures/mock-npm') +const MockRegistry = require('@npmcli/mock-registry') -t.test('should run dedupe in dryRun mode', async (t) => { - t.plan(5) - const { npm } = await loadMockNpm(t, { - mocks: { - '@npmcli/arborist': function (args) { - t.ok(args, 'gets options object') - t.ok(args.path, 'gets path option') - t.ok(args.dryRun, 'is called in dryRun mode') - this.dedupe = () => { - t.ok(true, 'dedupe is called') - } - }, - '../../lib/utils/reify-finish.js': (npm, arb) => { - t.ok(arb, 'gets arborist tree') +const treeWithDupes = { + 'package.json': JSON.stringify({ + name: 'test-top', + version: '1.0.0', + dependencies: { + 'test-dep-a': '*', + 'test-dep-b': '*', + }, + }), + node_modules: { + 'test-dep-a': { + 'package.json': JSON.stringify({ + name: 'test-dep-a', + version: '1.0.1', + dependencies: { 'test-sub': '*' }, + }), + node_modules: { + 'test-sub': { + 'package.json': JSON.stringify({ + name: 'test-sub', + version: '1.0.0', + }), + }, }, }, + 'test-dep-b': { + 'package.json': JSON.stringify({ + name: 'test-dep-b', + version: '1.0.0', + dependencies: { 'test-sub': '*' }, + }), + node_modules: { + 'test-sub': { + 'package.json': JSON.stringify({ + name: 'test-sub', + version: '1.0.0', + }), + }, + }, + }, + }, +} + +t.test('should run dedupe in dryRun mode', async (t) => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: treeWithDupes, config: { // explicitly set to false so we can be 100% sure it's always true when it // hits arborist 'dry-run': false, }, }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + + const manifestSub = registry.manifest({ + name: 'test-sub', + manifests: [{ name: 'test-sub', version: '1.0.0' }], + }) + + await registry.package({ manifest: manifestSub }) await npm.exec('find-dupes', []) + t.match(joinedOutput(), /added 1 package, and removed 2 packages/) + t.notOk( + fs.existsSync(path.join(npm.prefix, 'node_modules', 'test-sub')), + 'test-sub was not hoisted' + ) + t.ok( + fs.existsSync(path.join(npm.prefix, 'node_modules', 'test-dep-a', 'node_modules', 'test-sub')), + 'test-dep-a/test-sub was not removed' + ) + t.ok( + fs.existsSync(path.join(npm.prefix, 'node_modules', 'test-dep-b', 'node_modules', 'test-sub')), + 'test-dep-b/test-sub was not removed') }) diff --git a/test/lib/commands/help-search.js b/test/lib/commands/help-search.js index 8d13009..7fbeb19 100644 --- a/test/lib/commands/help-search.js +++ b/test/lib/commands/help-search.js @@ -1,7 +1,7 @@ const t = require('tap') const { join } = require('path') const { fake: mockNpm } = require('../../fixtures/mock-npm') -const ansicolors = require('ansicolors') +const chalk = require('chalk') const OUTPUT = [] const output = msg => { @@ -106,7 +106,7 @@ t.test('npm help-search long output with color', async t => { await helpSearch.exec(['help-search']) - const highlightedText = ansicolors.bgBlack(ansicolors.red('help-search')) + const highlightedText = chalk.bgBlack.red('help-search') t.equal( OUTPUT.some(line => line.includes(highlightedText)), true, diff --git a/test/lib/commands/help.js b/test/lib/commands/help.js index b76234d..1e623da 100644 --- a/test/lib/commands/help.js +++ b/test/lib/commands/help.js @@ -19,6 +19,7 @@ const npm = { parsedArgv: { cooked: [], }, + validate: () => {}, }, exec: async (cmd, args) => { if (cmd === 'help-search') { @@ -310,3 +311,41 @@ t.test('npm help with complex installation path finds proper help file', async t t.match(openUrlArg, /commands(\/|\\)npm-install.html$/, 'attempts to open the correct url') }) + +t.test('npm help - prefers npm help pages', async t => { + // Unusual ordering is to get full test coverage of all branches inside the + // sort function. + globResult = [ + '/root/man/man6/npm-install.6', + '/root/man/man1/install.1', + '/root/man/man5/npm-install.5', + ] + t.teardown(() => { + globResult = globDefaults + spawnBin = null + spawnArgs = null + }) + await help.exec(['install']) + + t.equal(spawnBin, 'man', 'calls man by default') + t.strictSame(spawnArgs, ['/root/man/man5/npm-install.5'], 'passes the correct arguments') +}) + +t.test('npm help - works in the presence of strange man pages', async t => { + // Unusual ordering is to get full test coverage of all branches inside the + // sort function. + globResult = [ + '/root/man/man6/config.6strange', + '/root/man/man1/config.1', + '/root/man/man5/config.5ssl', + ] + t.teardown(() => { + globResult = globDefaults + spawnBin = null + spawnArgs = null + }) + await help.exec(['config']) + + t.equal(spawnBin, 'man', 'calls man by default') + t.strictSame(spawnArgs, ['/root/man/man1/config.1'], 'passes the correct arguments') +}) diff --git a/test/lib/commands/hook.js b/test/lib/commands/hook.js index a4eee71..0cd6a74 100644 --- a/test/lib/commands/hook.js +++ b/test/lib/commands/hook.js @@ -1,18 +1,20 @@ const t = require('tap') +const { fake: mockNpm } = require('../../fixtures/mock-npm') const output = [] -const npm = { +const npm = mockNpm({ flatOptions: { json: false, parseable: false, - silent: false, - loglevel: 'info', unicode: false, }, + config: { + loglevel: 'info', + }, output: msg => { output.push(msg) }, -} +}) const pkgTypes = { semver: 'package', @@ -26,7 +28,7 @@ let hookArgs = null const libnpmhook = { add: async (pkg, uri, secret, opts) => { hookArgs = { pkg, uri, secret, opts } - return { id: 1, name: pkg.replace(/^@/, ''), type: pkgTypes[pkg], endpoint: uri } + return { id: 1, name: pkg, type: pkgTypes[pkg], endpoint: uri } }, ls: async opts => { hookArgs = opts @@ -37,7 +39,7 @@ const libnpmhook = { return Object.keys(pkgTypes).map(name => ({ id: ++id, - name: name.replace(/^@/, ''), + name, type: pkgTypes[name], endpoint: 'https://google.com', last_delivery: id % 2 === 0 ? now : undefined, @@ -48,7 +50,7 @@ const libnpmhook = { const pkg = Object.keys(pkgTypes)[0] return { id: 1, - name: pkg.replace(/^@/, ''), + name: pkg, type: pkgTypes[pkg], endpoint: 'https://google.com', } @@ -56,12 +58,11 @@ const libnpmhook = { update: async (id, uri, secret, opts) => { hookArgs = { id, uri, secret, opts } const pkg = Object.keys(pkgTypes)[0] - return { id, name: pkg.replace(/^@/, ''), type: pkgTypes[pkg], endpoint: uri } + return { id, name: pkg, type: pkgTypes[pkg], endpoint: uri } }, } const Hook = t.mock('../../../lib/commands/hook.js', { - '../../../lib/utils/otplease.js': async (opts, fn) => fn(opts), libnpmhook, }) const hook = new Hook(npm) @@ -78,7 +79,6 @@ t.test('npm hook add', async t => { await hook.exec(['add', 'semver', 'https://google.com', 'some-secret']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -92,6 +92,48 @@ t.test('npm hook add', async t => { t.strictSame(output, ['+ semver -> https://google.com'], 'prints the correct output') }) +t.test('npm hook add - correct owner hook output', async t => { + t.teardown(() => { + hookArgs = null + output.length = 0 + }) + + await hook.exec(['add', '~npm', 'https://google.com', 'some-secret']) + + t.match( + hookArgs, + { + pkg: '~npm', + uri: 'https://google.com', + secret: 'some-secret', + opts: npm.flatOptions, + }, + 'provided the correct arguments to libnpmhook' + ) + t.strictSame(output, ['+ ~npm -> https://google.com'], 'prints the correct output') +}) + +t.test('npm hook add - correct scope hook output', async t => { + t.teardown(() => { + hookArgs = null + output.length = 0 + }) + + await hook.exec(['add', '@npmcli', 'https://google.com', 'some-secret']) + + t.match( + hookArgs, + { + pkg: '@npmcli', + uri: 'https://google.com', + secret: 'some-secret', + opts: npm.flatOptions, + }, + 'provided the correct arguments to libnpmhook' + ) + t.strictSame(output, ['+ @npmcli -> https://google.com'], 'prints the correct output') +}) + t.test('npm hook add - unicode output', async t => { npm.flatOptions.unicode = true t.teardown(() => { @@ -102,7 +144,6 @@ t.test('npm hook add - unicode output', async t => { await hook.exec(['add', 'semver', 'https://google.com', 'some-secret']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -126,7 +167,6 @@ t.test('npm hook add - json output', async t => { await hook.exec(['add', '@npmcli', 'https://google.com', 'some-secret']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -141,7 +181,7 @@ t.test('npm hook add - json output', async t => { JSON.parse(output[0]), { id: 1, - name: 'npmcli', + name: '@npmcli', endpoint: 'https://google.com', type: 'scope', }, @@ -159,7 +199,6 @@ t.test('npm hook add - parseable output', async t => { await hook.exec(['add', '@npmcli', 'https://google.com', 'some-secret']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -177,22 +216,21 @@ t.test('npm hook add - parseable output', async t => { ) t.strictSame( output[1].split(/\t/), - ['1', 'npmcli', 'scope', 'https://google.com'], + ['1', '@npmcli', 'scope', 'https://google.com'], 'prints the correct parseable values' ) }) t.test('npm hook add - silent output', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') t.teardown(() => { - npm.flatOptions.silent = false + npm.config.set('loglevel', 'info') hookArgs = null output.length = 0 }) await hook.exec(['add', '@npmcli', 'https://google.com', 'some-secret']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -214,7 +252,6 @@ t.test('npm hook ls', async t => { await hook.exec(['ls']) - t.ok(hookArgs.log, 'is passed a logger') t.match( hookArgs, { @@ -240,7 +277,6 @@ t.test('npm hook ls, no results', async t => { await hook.exec(['ls']) - t.ok(hookArgs.log, 'is passed a logger') t.match( hookArgs, { @@ -270,7 +306,6 @@ t.test('npm hook ls, single result', async t => { await hook.exec(['ls']) - t.ok(hookArgs.log, 'is passed a logger') t.match( hookArgs, { @@ -294,7 +329,6 @@ t.test('npm hook ls - json output', async t => { await hook.exec(['ls']) - t.ok(hookArgs.log, 'is passed a logger') t.match( hookArgs, { @@ -340,7 +374,6 @@ t.test('npm hook ls - parseable output', async t => { await hook.exec(['ls']) - t.ok(hookArgs.log, 'is passed a logger') t.match( hookArgs, { @@ -354,7 +387,7 @@ t.test('npm hook ls - parseable output', async t => { [ ['id', 'name', 'type', 'endpoint', 'last_delivery'], ['1', 'semver', 'package', 'https://google.com', ''], - ['2', 'npmcli', 'scope', 'https://google.com', `${now}`], + ['2', '@npmcli', 'scope', 'https://google.com', `${now}`], ['3', 'npm', 'owner', 'https://google.com', ''], ], 'prints the correct result' @@ -362,16 +395,15 @@ t.test('npm hook ls - parseable output', async t => { }) t.test('npm hook ls - silent output', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') t.teardown(() => { - npm.flatOptions.silent = false + npm.config.set('loglevel', 'info') hookArgs = null output.length = 0 }) await hook.exec(['ls']) - t.ok(hookArgs.log, 'is passed a logger') t.match( hookArgs, { @@ -391,7 +423,6 @@ t.test('npm hook rm', async t => { await hook.exec(['rm', '1']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -413,7 +444,6 @@ t.test('npm hook rm - unicode output', async t => { await hook.exec(['rm', '1']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -426,16 +456,15 @@ t.test('npm hook rm - unicode output', async t => { }) t.test('npm hook rm - silent output', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') t.teardown(() => { - npm.flatOptions.silent = false + npm.config.set('loglevel', 'info') hookArgs = null output.length = 0 }) await hook.exec(['rm', '1']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -457,7 +486,6 @@ t.test('npm hook rm - json output', async t => { await hook.exec(['rm', '1']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -488,7 +516,6 @@ t.test('npm hook rm - parseable output', async t => { await hook.exec(['rm', '1']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -515,7 +542,6 @@ t.test('npm hook update', async t => { await hook.exec(['update', '1', 'https://google.com', 'some-secret']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -539,7 +565,6 @@ t.test('npm hook update - unicode', async t => { await hook.exec(['update', '1', 'https://google.com', 'some-secret']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -563,7 +588,6 @@ t.test('npm hook update - json output', async t => { await hook.exec(['update', '1', 'https://google.com', 'some-secret']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -596,7 +620,6 @@ t.test('npm hook update - parseable output', async t => { await hook.exec(['update', '1', 'https://google.com', 'some-secret']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { @@ -618,16 +641,15 @@ t.test('npm hook update - parseable output', async t => { }) t.test('npm hook update - silent output', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') t.teardown(() => { - npm.flatOptions.silent = false + npm.config.set('loglevel', 'info') hookArgs = null output.length = 0 }) await hook.exec(['update', '1', 'https://google.com', 'some-secret']) - t.ok(hookArgs.opts.log, 'is passed a logger') t.match( hookArgs, { diff --git a/test/lib/commands/init.js b/test/lib/commands/init.js index 215ebc5..d11e009 100644 --- a/test/lib/commands/init.js +++ b/test/lib/commands/init.js @@ -17,7 +17,6 @@ const npm = mockNpm({ config, }) const mocks = { - '../../../lib/utils/usage.js': () => 'usage instructions', npmlog: { disableProgress: () => null, enableProgress: () => null, @@ -86,7 +85,7 @@ t.test('npm init <arg>', async t => { libnpmexec: ({ args, cache, npxCache }) => { t.same( args, - ['create-react-app'], + ['create-react-app@*'], 'should npx with listed packages' ) t.same(cache, flatOptions.cache) @@ -107,7 +106,7 @@ t.test('npm init <arg> -- other-args', async t => { libnpmexec: ({ args }) => { t.same( args, - ['create-react-app', 'my-path', '--some-option', 'some-value'], + ['create-react-app@*', 'my-path', '--some-option', 'some-value'], 'should npm exec with expected args' ) }, @@ -126,7 +125,7 @@ t.test('npm init @scope/name', async t => { libnpmexec: ({ args }) => { t.same( args, - ['@npmcli/create-something'], + ['@npmcli/create-something@*'], 'should npx with scoped packages' ) }, @@ -137,6 +136,44 @@ t.test('npm init @scope/name', async t => { await init.exec(['@npmcli/something']) }) +t.test('npm init @scope@spec', async t => { + t.plan(1) + npm.localPrefix = t.testdir({}) + + const Init = t.mock('../../../lib/commands/init.js', { + libnpmexec: ({ args }) => { + t.same( + args, + ['@npmcli/create@foo'], + 'should npx with scoped packages' + ) + }, + }) + const init = new Init(npm) + + process.chdir(npm.localPrefix) + await init.exec(['@npmcli@foo']) +}) + +t.test('npm init @scope/name@spec', async t => { + t.plan(1) + npm.localPrefix = t.testdir({}) + + const Init = t.mock('../../../lib/commands/init.js', { + libnpmexec: ({ args }) => { + t.same( + args, + ['@npmcli/create-something@foo'], + 'should npx with scoped packages' + ) + }, + }) + const init = new Init(npm) + + process.chdir(npm.localPrefix) + await init.exec(['@npmcli/something@foo']) +}) + t.test('npm init git spec', async t => { t.plan(1) npm.localPrefix = t.testdir({}) @@ -231,7 +268,7 @@ t.test('should not rewrite flatOptions', async t => { libnpmexec: async ({ args }) => { t.same( args, - ['create-react-app', 'my-app'], + ['create-react-app@*', 'my-app'], 'should npx with extra args' ) }, @@ -289,6 +326,7 @@ t.test('workspaces', t => { t.teardown(() => { npm._mockOutputs.length = 0 }) + npm._mockOutputs.length = 0 npm.localPrefix = t.testdir({ 'package.json': JSON.stringify({ name: 'top-level', @@ -307,6 +345,39 @@ t.test('workspaces', t => { t.matchSnapshot(npm._mockOutputs, 'should print helper info') }) + t.test('post workspace-init reify', async t => { + const _consolelog = console.log + console.log = () => null + t.teardown(() => { + console.log = _consolelog + npm._mockOutputs.length = 0 + delete npm.flatOptions.workspacesUpdate + }) + npm.started = Date.now() + npm._mockOutputs.length = 0 + npm.flatOptions.workspacesUpdate = true + npm.localPrefix = t.testdir({ + 'package.json': JSON.stringify({ + name: 'top-level', + }), + }) + + const Init = t.mock('../../../lib/commands/init.js', { + ...mocks, + 'init-package-json': (dir, initFile, config, cb) => { + t.equal(dir, resolve(npm.localPrefix, 'a'), 'should use the ws path') + return require('init-package-json')(dir, initFile, config, cb) + }, + }) + const init = new Init(npm) + await init.execWorkspaces([], ['a']) + const output = npm._mockOutputs.map(arr => arr.map(i => i.replace(/[0-9]*m?s$/, '100ms'))) + t.matchSnapshot(output, 'should print helper info') + const lockFilePath = resolve(npm.localPrefix, 'package-lock.json') + const lockFile = fs.readFileSync(lockFilePath, { encoding: 'utf8' }) + t.matchSnapshot(lockFile, 'should reify tree on init ws complete') + }) + t.test('no args, existing folder', async t => { t.teardown(() => { npm._mockOutputs.length = 0 @@ -429,7 +500,7 @@ t.test('workspaces', t => { libnpmexec: ({ args, path }) => { t.same( args, - ['create-react-app'], + ['create-react-app@*'], 'should npx with listed packages' ) t.same( diff --git a/test/lib/commands/install-ci-test.js b/test/lib/commands/install-ci-test.js index 0828d2b..401113a 100644 --- a/test/lib/commands/install-ci-test.js +++ b/test/lib/commands/install-ci-test.js @@ -23,6 +23,15 @@ const installCITest = new InstallCITest({ testCalled = true } }, + config: { + validate: () => {}, + get: (key) => { + if (key === 'location') { + return 'project' + } + }, + isDefault: () => {}, + }, }) t.test('the install-ci-test command', t => { diff --git a/test/lib/commands/install-test.js b/test/lib/commands/install-test.js index 223bbe1..5776c7f 100644 --- a/test/lib/commands/install-test.js +++ b/test/lib/commands/install-test.js @@ -23,6 +23,15 @@ const installTest = new InstallTest({ testCalled = true } }, + config: { + validate: () => {}, + get: (key) => { + if (key === 'location') { + return 'project' + } + }, + isDefault: () => {}, + }, }) t.test('the install-test command', t => { diff --git a/test/lib/commands/install.js b/test/lib/commands/install.js index d5db3af..4c3251f 100644 --- a/test/lib/commands/install.js +++ b/test/lib/commands/install.js @@ -1,259 +1,263 @@ const t = require('tap') -const path = require('path') const { load: _loadMockNpm } = require('../../fixtures/mock-npm') // Make less churn in the test to pass in mocks only signature const loadMockNpm = (t, mocks) => _loadMockNpm(t, { mocks }) -t.test('with args, dev=true', async t => { - const SCRIPTS = [] - let ARB_ARGS = null - let REIFY_CALLED = false - let ARB_OBJ = null +t.test('exec commands', async t => { + await t.test('with args, dev=true', async t => { + const SCRIPTS = [] + let ARB_ARGS = null + let REIFY_CALLED = false + let ARB_OBJ = null - const { npm, logs } = await loadMockNpm(t, { - '@npmcli/run-script': ({ event }) => { - SCRIPTS.push(event) - }, - '@npmcli/arborist': function (args) { - ARB_ARGS = args - ARB_OBJ = this - this.reify = () => { - REIFY_CALLED = true - } - }, - '../../lib/utils/reify-finish.js': (npm, arb) => { - if (arb !== ARB_OBJ) { - throw new Error('got wrong object passed to reify-finish') - } - }, - }) - - // This is here because CI calls tests with `--ignore-scripts`, which config - // picks up from argv - npm.config.set('ignore-scripts', false) - npm.config.set('audit-level', 'low') - npm.config.set('dev', true) - // tap sets this to - // D:\\a\\cli\\cli\\test\\lib\\commands/tap-testdir-install-should-install-globally-using-Arborist - // which gets normalized elsewhere so comparative tests fail - npm.prefix = path.resolve(t.testdir({})) - - await npm.exec('install', ['fizzbuzz']) - t.match( - logs.warn, - [['install', 'Usage of the `--dev` option is deprecated. Use `--include=dev` instead.']] - ) - t.match( - ARB_ARGS, - { global: false, path: npm.prefix, auditLevel: null }, - 'Arborist gets correct args and ignores auditLevel' - ) - t.equal(REIFY_CALLED, true, 'called reify') - t.strictSame(SCRIPTS, [], 'no scripts when adding dep') -}) - -t.test('without args', async t => { - const SCRIPTS = [] - let ARB_ARGS = null - let REIFY_CALLED = false - let ARB_OBJ = null - - const { npm } = await loadMockNpm(t, { - '@npmcli/run-script': ({ event }) => { - SCRIPTS.push(event) - }, - '@npmcli/arborist': function (args) { - ARB_ARGS = args - ARB_OBJ = this - this.reify = () => { - REIFY_CALLED = true - } - }, - '../../lib/utils/reify-finish.js': (npm, arb) => { - if (arb !== ARB_OBJ) { - throw new Error('got wrong object passed to reify-finish') - } - }, - }) - - npm.prefix = path.resolve(t.testdir({})) - npm.config.set('ignore-scripts', false) - await npm.exec('install', []) - t.match(ARB_ARGS, { global: false, path: npm.prefix }) - t.equal(REIFY_CALLED, true, 'called reify') - t.strictSame(SCRIPTS, [ - 'preinstall', - 'install', - 'postinstall', - 'prepublish', - 'preprepare', - 'prepare', - 'postprepare', - ], 'exec scripts when doing local build') -}) - -t.test('should ignore scripts with --ignore-scripts', async t => { - const SCRIPTS = [] - let REIFY_CALLED = false - const { npm } = await loadMockNpm(t, { - '../../lib/utils/reify-finish.js': async () => {}, - '@npmcli/run-script': ({ event }) => { - SCRIPTS.push(event) - }, - '@npmcli/arborist': function () { - this.reify = () => { - REIFY_CALLED = true - } - }, - }) - npm.config.set('ignore-scripts', true) - npm.prefix = path.resolve(t.testdir({})) - await npm.exec('install', []) - t.equal(REIFY_CALLED, true, 'called reify') - t.strictSame(SCRIPTS, [], 'no scripts when adding dep') -}) - -t.test('should install globally using Arborist', async t => { - const SCRIPTS = [] - let ARB_ARGS = null - let REIFY_CALLED - const { npm } = await loadMockNpm(t, { - '@npmcli/run-script': ({ event }) => { - SCRIPTS.push(event) - }, - '../../lib/utils/reify-finish.js': async () => {}, - '@npmcli/arborist': function (args) { - ARB_ARGS = args - this.reify = () => { - REIFY_CALLED = true - } - }, - }) - npm.config.set('global', true) - npm.globalPrefix = path.resolve(t.testdir({})) - await npm.exec('install', []) - t.match( - ARB_ARGS, - { global: true, path: npm.globalPrefix } - ) - t.equal(REIFY_CALLED, true, 'called reify') - t.strictSame(SCRIPTS, [], 'no scripts when installing globally') -}) - -t.test('npm i -g npm engines check success', async t => { - const { npm } = await loadMockNpm(t, { - '../../lib/utils/reify-finish.js': async () => {}, - '@npmcli/arborist': function () { - this.reify = () => {} - }, - pacote: { - manifest: () => { - return { - version: '100.100.100', - engines: { - node: '>1', - }, + const { npm } = await loadMockNpm(t, { + '@npmcli/run-script': ({ event }) => { + SCRIPTS.push(event) + }, + '@npmcli/arborist': function (args) { + ARB_ARGS = args + ARB_OBJ = this + this.reify = () => { + REIFY_CALLED = true } }, - }, - }) - npm.globalDir = t.testdir({}) - npm.config.set('global', true) - await npm.exec('install', ['npm']) - t.ok('No exceptions happen') -}) - -t.test('npm i -g npm engines check failure', async t => { - const { npm } = await loadMockNpm(t, { - pacote: { - manifest: () => { - return { - _id: 'npm@1.2.3', - version: '100.100.100', - engines: { - node: '>1000', - }, + '../../lib/utils/reify-finish.js': (npm, arb) => { + if (arb !== ARB_OBJ) { + throw new Error('got wrong object passed to reify-finish') } }, - }, - }) - npm.globalDir = t.testdir({}) - npm.config.set('global', true) - await t.rejects( - npm.exec('install', ['npm']), - { - message: 'Unsupported engine', - pkgid: 'npm@1.2.3', - current: { - node: process.version, - npm: '100.100.100', - }, - required: { - node: '>1000', - }, - code: 'EBADENGINE', - } - ) -}) + }) -t.test('npm i -g npm engines check failure forced override', async t => { - const { npm } = await loadMockNpm(t, { - '../../lib/utils/reify-finish.js': async () => {}, - '@npmcli/arborist': function () { - this.reify = () => {} - }, - pacote: { - manifest: () => { - return { - _id: 'npm@1.2.3', - version: '100.100.100', - engines: { - node: '>1000', - }, + // This is here because CI calls tests with `--ignore-scripts`, which config + // picks up from argv + npm.config.set('ignore-scripts', false) + npm.config.set('audit-level', 'low') + npm.config.set('dev', true) + + await npm.exec('install', ['fizzbuzz']) + + t.match( + ARB_ARGS, + { global: false, path: npm.prefix, auditLevel: null }, + 'Arborist gets correct args and ignores auditLevel' + ) + t.equal(REIFY_CALLED, true, 'called reify') + t.strictSame(SCRIPTS, [], 'no scripts when adding dep') + }) + + await t.test('without args', async t => { + const SCRIPTS = [] + let ARB_ARGS = null + let REIFY_CALLED = false + let ARB_OBJ = null + + const { npm } = await loadMockNpm(t, { + '@npmcli/run-script': ({ event }) => { + SCRIPTS.push(event) + }, + '@npmcli/arborist': function (args) { + ARB_ARGS = args + ARB_OBJ = this + this.reify = () => { + REIFY_CALLED = true } }, - }, - }) - npm.globalDir = t.testdir({}) - npm.config.set('global', true) - npm.config.set('force', true) - await npm.exec('install', ['npm']) - t.ok('Does not throw') -}) - -t.test('npm i -g npm@version engines check failure', async t => { - const { npm } = await loadMockNpm(t, { - pacote: { - manifest: () => { - return { - _id: 'npm@1.2.3', - version: '100.100.100', - engines: { - node: '>1000', - }, + '../../lib/utils/reify-finish.js': (npm, arb) => { + if (arb !== ARB_OBJ) { + throw new Error('got wrong object passed to reify-finish') } }, - }, + }) + + npm.config.set('ignore-scripts', false) + await npm.exec('install', []) + t.match(ARB_ARGS, { global: false, path: npm.prefix }) + t.equal(REIFY_CALLED, true, 'called reify') + t.strictSame(SCRIPTS, [ + 'preinstall', + 'install', + 'postinstall', + 'prepublish', + 'preprepare', + 'prepare', + 'postprepare', + ], 'exec scripts when doing local build') }) - npm.globalDir = t.testdir({}) - npm.config.set('global', true) - await t.rejects( - npm.exec('install', ['npm@100']), - { - message: 'Unsupported engine', - pkgid: 'npm@1.2.3', - current: { - node: process.version, - npm: '100.100.100', + + await t.test('should ignore scripts with --ignore-scripts', async t => { + const SCRIPTS = [] + let REIFY_CALLED = false + const { npm } = await loadMockNpm(t, { + '../../lib/utils/reify-finish.js': async () => {}, + '@npmcli/run-script': ({ event }) => { + SCRIPTS.push(event) }, - required: { - node: '>1000', + '@npmcli/arborist': function () { + this.reify = () => { + REIFY_CALLED = true + } }, - code: 'EBADENGINE', - } - ) + }) + npm.config.set('ignore-scripts', true) + await npm.exec('install', []) + t.equal(REIFY_CALLED, true, 'called reify') + t.strictSame(SCRIPTS, [], 'no scripts when adding dep') + }) + + await t.test('should install globally using Arborist', async t => { + const SCRIPTS = [] + let ARB_ARGS = null + let REIFY_CALLED + const { npm } = await loadMockNpm(t, { + '@npmcli/run-script': ({ event }) => { + SCRIPTS.push(event) + }, + '../../lib/utils/reify-finish.js': async () => {}, + '@npmcli/arborist': function (args) { + ARB_ARGS = args + this.reify = () => { + REIFY_CALLED = true + } + }, + }) + npm.config.set('global', true) + await npm.exec('install', []) + t.match( + ARB_ARGS, + { global: true, path: npm.globalPrefix } + ) + t.equal(REIFY_CALLED, true, 'called reify') + t.strictSame(SCRIPTS, [], 'no scripts when installing globally') + t.equal(npm.config.get('audit', 'cli'), false) + }) + + await t.test('should not install invalid global package name', async t => { + const { npm } = await loadMockNpm(t, { + '@npmcli/run-script': () => {}, + '../../lib/utils/reify-finish.js': async () => {}, + '@npmcli/arborist': function (args) { + throw new Error('should not reify') + }, + }) + npm.config.set('global', true) + await t.rejects( + npm.exec('install', ['']), + /Usage:/, + 'should not install invalid package name' + ) + }) + + await t.test('npm i -g npm engines check success', async t => { + const { npm } = await loadMockNpm(t, { + '../../lib/utils/reify-finish.js': async () => {}, + '@npmcli/arborist': function () { + this.reify = () => {} + }, + pacote: { + manifest: () => { + return { + version: '100.100.100', + engines: { + node: '>1', + }, + } + }, + }, + }) + npm.config.set('global', true) + await npm.exec('install', ['npm']) + t.ok('No exceptions happen') + }) + + await t.test('npm i -g npm engines check failure', async t => { + const { npm } = await loadMockNpm(t, { + pacote: { + manifest: () => { + return { + _id: 'npm@1.2.3', + version: '100.100.100', + engines: { + node: '>1000', + }, + } + }, + }, + }) + npm.config.set('global', true) + await t.rejects( + npm.exec('install', ['npm']), + { + message: 'Unsupported engine', + pkgid: 'npm@1.2.3', + current: { + node: process.version, + npm: '100.100.100', + }, + required: { + node: '>1000', + }, + code: 'EBADENGINE', + } + ) + }) + + await t.test('npm i -g npm engines check failure forced override', async t => { + const { npm } = await loadMockNpm(t, { + '../../lib/utils/reify-finish.js': async () => {}, + '@npmcli/arborist': function () { + this.reify = () => {} + }, + pacote: { + manifest: () => { + return { + _id: 'npm@1.2.3', + version: '100.100.100', + engines: { + node: '>1000', + }, + } + }, + }, + }) + npm.config.set('global', true) + npm.config.set('force', true) + await npm.exec('install', ['npm']) + t.ok('Does not throw') + }) + + await t.test('npm i -g npm@version engines check failure', async t => { + const { npm } = await loadMockNpm(t, { + pacote: { + manifest: () => { + return { + _id: 'npm@1.2.3', + version: '100.100.100', + engines: { + node: '>1000', + }, + } + }, + }, + }) + npm.config.set('global', true) + await t.rejects( + npm.exec('install', ['npm@100']), + { + message: 'Unsupported engine', + pkgid: 'npm@1.2.3', + current: { + node: process.version, + npm: '100.100.100', + }, + required: { + node: '>1000', + }, + code: 'EBADENGINE', + } + ) + }) }) t.test('completion', async t => { @@ -324,3 +328,77 @@ t.test('completion', async t => { t.strictSame(res, []) }) }) + +t.test('location detection and audit', async () => { + t.test('audit false without package.json', async t => { + const { npm } = await _loadMockNpm(t, { + prefixDir: { + // no package.json + 'readme.txt': 'just a file', + other: {}, + }, + }) + const install = await npm.cmd('install') + t.equal(install.npm.config.get('location'), 'user') + t.equal(install.npm.config.get('audit'), false) + }) + t.test('audit true with package.json', async t => { + const { npm } = await _loadMockNpm(t, { + prefixDir: { + 'package.json': '{ "name": "testpkg", "version": "1.0.0" }', + 'readme.txt': 'just a file', + }, + }) + const install = await npm.cmd('install') + t.equal(install.npm.config.get('location'), 'project') + t.equal(install.npm.config.get('audit'), true) + }) + t.test('audit true without package.json when set', async t => { + const { npm } = await _loadMockNpm(t, { + prefixDir: { + // no package.json + 'readme.txt': 'just a file', + other: {}, + }, + config: { + audit: { value: true, where: 'cli' }, + }, + }) + const install = await npm.cmd('install') + t.equal(install.npm.config.get('location'), 'user') + t.equal(install.npm.config.get('audit'), true) + }) + t.test('audit true in root config without package.json', async t => { + const { npm } = await _loadMockNpm(t, { + prefixDir: { + // no package.json + 'readme.txt': 'just a file', + other: {}, + }, + config: { + audit: { value: true, where: 'builtin' }, + }, + }) + const install = await npm.cmd('install') + t.equal(install.npm.config.get('location'), 'user') + t.equal(install.npm.config.get('audit'), true) + }) + t.test('test for warning when --global & --audit', async t => { + const { npm, logs } = await _loadMockNpm(t, { + prefixDir: { + // no package.json + 'readme.txt': 'just a file', + other: {}, + }, + config: { + audit: { value: true, where: 'cli' }, + global: { value: true, where: 'cli' }, + }, + }) + const install = await npm.cmd('install') + t.equal(install.npm.config.get('location'), 'user') + t.equal(install.npm.config.get('audit'), true) + t.equal(logs.warn[0][0], 'config') + t.equal(logs.warn[0][1], 'includes both --global and --audit, which is currently unsupported.') + }) +}) diff --git a/test/lib/commands/link.js b/test/lib/commands/link.js index a01de0b..d908fa0 100644 --- a/test/lib/commands/link.js +++ b/test/lib/commands/link.js @@ -1,9 +1,9 @@ const t = require('tap') -const { resolve } = require('path') +const { resolve, join } = require('path') const fs = require('fs') const Arborist = require('@npmcli/arborist') -const { fake: mockNpm } = require('../../fixtures/mock-npm') +const { fake: mockNpm, load: fullMockNpm } = require('../../fixtures/mock-npm') const redactCwd = (path) => { const normalizePath = p => p @@ -72,7 +72,6 @@ t.test('link to globalDir when in current working dir of pkg and no args', async path: resolve(npm.globalDir, '..'), global: true, }) - t.matchSnapshot(links, 'should create a global link to current pkg') }) @@ -514,3 +513,70 @@ t.test('--global option', async t => { 'should throw an useful error' ) }) + +t.test('hash character in working directory path', async t => { + const testdir = t.testdir({ + 'global-prefix': { + lib: { + node_modules: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + }), + }, + }, + }, + }, + 'i_like_#_in_my_paths': { + 'test-pkg-link': { + 'package.json': JSON.stringify({ + name: 'test-pkg-link', + version: '1.0.0', + }), + }, + }, + }) + npm.globalDir = resolve(testdir, 'global-prefix', 'lib', 'node_modules') + npm.prefix = resolve(testdir, 'i_like_#_in_my_paths', 'test-pkg-link') + + link.workspacePaths = null + await link.exec([]) + const links = await printLinks({ + path: resolve(npm.globalDir, '..'), + global: true, + }) + + t.matchSnapshot(links, 'should create a global link to current pkg, even within path with hash') +}) + +t.test('test linked installed as symlinks', async t => { + // fakeMock is insufficient due to lack of flatOptions + const { npm } = await fullMockNpm(t, { + otherDirs: { + mylink: { + 'package.json': JSON.stringify({ + name: 'mylink', + version: '1.0.0', + }), + }, + }, + }) + + const _cwd = process.cwd() + process.chdir(npm.prefix) + + await npm.exec('link', [ + join('file:../other/mylink'), + ]) + process.chdir(_cwd) + const links = await printLinks({ + path: npm.prefix, + }) + + t.ok(fs.lstatSync(join(npm.prefix, 'node_modules', 'mylink')).isSymbolicLink(), + 'linked path should by symbolic link' + ) + + t.matchSnapshot(links, 'linked package should not be installed') +}) diff --git a/test/lib/commands/login.js b/test/lib/commands/login.js new file mode 100644 index 0000000..ae7e3ff --- /dev/null +++ b/test/lib/commands/login.js @@ -0,0 +1,143 @@ +const t = require('tap') +const fs = require('fs') +const path = require('path') +const ini = require('ini') + +const { load: loadMockNpm } = require('../../fixtures/mock-npm.js') +const mockGlobals = require('../../fixtures/mock-globals.js') +const MockRegistry = require('@npmcli/mock-registry') +const stream = require('stream') + +t.test('usage', async t => { + const { npm } = await loadMockNpm(t) + const login = await npm.cmd('login') + t.match(login.usage, 'login', 'usage has command name in it') +}) + +t.test('legacy', t => { + t.test('basic login', async t => { + const stdin = new stream.PassThrough() + stdin.write('test-user\n') + stdin.write('test-password\n') + mockGlobals(t, { + 'process.stdin': stdin, + 'process.stdout': new stream.PassThrough(), // to quiet readline + }, { replace: true }) + const { npm, home } = await loadMockNpm(t, { + config: { 'auth-type': 'legacy' }, + homeDir: { + '.npmrc': [ + '//registry.npmjs.org/:_authToken=user', + '//registry.npmjs.org/:always-auth=user', + '//registry.npmjs.org/:email=test-email-old@npmjs.org', + ].join('\n'), + }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.couchlogin({ + username: 'test-user', + password: 'test-password', + token: 'npm_test-token', + }) + await npm.exec('login', []) + t.same(npm.config.get('//registry.npmjs.org/:_authToken'), 'npm_test-token') + const rc = ini.parse(fs.readFileSync(path.join(home, '.npmrc'), 'utf8')) + t.same(rc, { + '//registry.npmjs.org/:_authToken': 'npm_test-token', + email: 'test-email-old@npmjs.org', + }, 'should only have token and un-nerfed old email') + }) + + t.test('scoped login default registry', async t => { + const stdin = new stream.PassThrough() + stdin.write('test-user\n') + stdin.write('test-password\n') + mockGlobals(t, { + 'process.stdin': stdin, + 'process.stdout': new stream.PassThrough(), // to quiet readline + }, { replace: true }) + const { npm, home } = await loadMockNpm(t, { + config: { + 'auth-type': 'legacy', + scope: '@npmcli', + }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.couchlogin({ + username: 'test-user', + password: 'test-password', + token: 'npm_test-token', + }) + await npm.exec('login', []) + t.same(npm.config.get('//registry.npmjs.org/:_authToken'), 'npm_test-token') + t.same(npm.config.get('@npmcli:registry'), 'https://registry.npmjs.org/') + const rc = ini.parse(fs.readFileSync(path.join(home, '.npmrc'), 'utf8')) + t.same(rc, { + '//registry.npmjs.org/:_authToken': 'npm_test-token', + '@npmcli:registry': 'https://registry.npmjs.org/', + }, 'should only have token and scope:registry') + }) + + t.test('scoped login scoped registry', async t => { + const stdin = new stream.PassThrough() + stdin.write('test-user\n') + stdin.write('test-password\n') + mockGlobals(t, { + 'process.stdin': stdin, + 'process.stdout': new stream.PassThrough(), // to quiet readline + }, { replace: true }) + const { npm, home } = await loadMockNpm(t, { + config: { + 'auth-type': 'legacy', + scope: '@npmcli', + }, + homeDir: { + '.npmrc': '@npmcli:registry=https://diff-registry.npmjs.org', + }, + }) + const registry = new MockRegistry({ + tap: t, + registry: 'https://diff-registry.npmjs.org', + }) + registry.couchlogin({ + username: 'test-user', + password: 'test-password', + token: 'npm_test-token', + }) + await npm.exec('login', []) + t.same(npm.config.get('//diff-registry.npmjs.org/:_authToken'), 'npm_test-token') + t.same(npm.config.get('@npmcli:registry'), 'https://diff-registry.npmjs.org') + const rc = ini.parse(fs.readFileSync(path.join(home, '.npmrc'), 'utf8')) + t.same(rc, { + '@npmcli:registry': 'https://diff-registry.npmjs.org', + '//diff-registry.npmjs.org/:_authToken': 'npm_test-token', + }, 'should only have token and scope:registry') + }) + t.end() +}) + +t.test('web', t => { + t.test('basic login', async t => { + const { npm, home } = await loadMockNpm(t, { + config: { 'auth-type': 'web' }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.weblogin({ token: 'npm_test-token' }) + await npm.exec('login', []) + t.same(npm.config.get('//registry.npmjs.org/:_authToken'), 'npm_test-token') + const rc = ini.parse(fs.readFileSync(path.join(home, '.npmrc'), 'utf8')) + t.same(rc, { + '//registry.npmjs.org/:_authToken': 'npm_test-token', + }) + }) + t.end() +}) diff --git a/test/lib/commands/logout.js b/test/lib/commands/logout.js index 1a1fbb7..73fe802 100644 --- a/test/lib/commands/logout.js +++ b/test/lib/commands/logout.js @@ -31,7 +31,7 @@ t.afterEach(() => { }) t.test('token logout', async t => { - t.plan(6) + t.plan(5) flatOptions['//registry.npmjs.org/:_authToken'] = '@foo/' @@ -62,7 +62,6 @@ t.test('token logout', async t => { await logout.exec([]) - t.ok(result.opts.log, 'should pass a logger') t.match( result, { @@ -92,7 +91,7 @@ t.test('token scoped logout', async t => { config.save = null }) - t.plan(8) + t.plan(7) flatOptions['//diff-registry.npmjs.com/:_authToken'] = '@bar/' flatOptions['//registry.npmjs.org/:_authToken'] = '@foo/' @@ -133,7 +132,6 @@ t.test('token scoped logout', async t => { await logout.exec([]) - t.ok(result.opts.log, 'should pass a logger') t.match( result, { @@ -204,7 +202,7 @@ t.test('ignore invalid scoped registry config', async t => { config.delete = null config.save = null }) - t.plan(5) + t.plan(4) flatOptions['//registry.npmjs.org/:_authToken'] = '@foo/' config.scope = '@myscope' @@ -236,7 +234,6 @@ t.test('ignore invalid scoped registry config', async t => { await logout.exec([]) - t.ok(result.opts.log, 'should pass a logger') t.match( result, { diff --git a/test/lib/commands/ls.js b/test/lib/commands/ls.js index 1cbcb59..b9278dd 100644 --- a/test/lib/commands/ls.js +++ b/test/lib/commands/ls.js @@ -99,14 +99,13 @@ const LS = t.mock('../../../lib/commands/ls.js', { const config = { all: true, color: false, - dev: false, depth: Infinity, global: false, json: false, link: false, - only: null, + location: 'project', + omit: [], parseable: false, - production: false, 'package-lock-only': false, } const flatOptions = { @@ -180,6 +179,44 @@ t.test('ls', t => { ) }) + t.test('workspace and missing optional dep', async t => { + npm.prefix = npm.localPrefix = t.testdir({ + 'package.json': JSON.stringify({ + name: 'root', + dependencies: { + foo: '^1.0.0', + }, + optionalDependencies: { + bar: '^1.0.0', + }, + workspaces: ['./baz'], + }), + baz: { + 'package.json': JSON.stringify({ + name: 'baz', + version: '1.0.0', + }), + }, + node_modules: { + baz: t.fixture('symlink', '../baz'), + foo: { + 'package.json': JSON.stringify({ + name: 'foo', + version: '1.0.0', + }), + }, + }, + }) + + npm.flatOptions.includeWorkspaceRoot = true + t.teardown(() => { + delete npm.flatOptions.includeWorkspaceRoot + }) + + await ls.execWorkspaces([], ['baz']) + t.matchSnapshot(redactCwd(result), 'should omit missing optional dep') + }) + t.test('extraneous deps', async t => { npm.prefix = t.testdir({ 'package.json': JSON.stringify({ @@ -195,6 +232,88 @@ t.test('ls', t => { t.matchSnapshot(redactCwd(result), 'should output containing problems info') }) + t.test('overridden dep', async t => { + config.all = true + t.teardown(() => { + config.all = false + }) + + npm.prefix = t.testdir({ + 'package.json': JSON.stringify({ + name: 'test-overridden', + version: '1.0.0', + dependencies: { + foo: '^1.0.0', + }, + overrides: { + bar: '1.0.0', + }, + }), + node_modules: { + foo: { + 'package.json': JSON.stringify({ + name: 'foo', + version: '1.0.0', + dependencies: { + bar: '^2.0.0', + }, + }), + }, + bar: { + 'package.json': JSON.stringify({ + name: 'bar', + version: '1.0.0', + }), + }, + }, + }) + + await ls.exec([]) + t.matchSnapshot(redactCwd(result), 'should contain overridden outout') + }) + + t.test('overridden dep w/ color', async t => { + config.all = true + npm.color = true + t.teardown(() => { + config.all = false + npm.color = false + }) + + npm.prefix = t.testdir({ + 'package.json': JSON.stringify({ + name: 'test-overridden', + version: '1.0.0', + dependencies: { + foo: '^1.0.0', + }, + overrides: { + bar: '1.0.0', + }, + }), + node_modules: { + foo: { + 'package.json': JSON.stringify({ + name: 'foo', + version: '1.0.0', + dependencies: { + bar: '^2.0.0', + }, + }), + }, + bar: { + 'package.json': JSON.stringify({ + name: 'bar', + version: '1.0.0', + }), + }, + }, + }) + + await ls.exec([]) + t.matchSnapshot(redactCwd(result), 'should contain overridden outout') + }) + t.test('with filter arg', async t => { npm.color = true npm.prefix = t.testdir({ @@ -456,7 +575,7 @@ t.test('ls', t => { }) t.test('--dev', async t => { - config.dev = true + flatOptions.omit = ['peer', 'prod', 'optional'] npm.prefix = t.testdir({ 'package.json': JSON.stringify({ name: 'test-npm-ls', @@ -479,34 +598,7 @@ t.test('ls', t => { }) await ls.exec([]) t.matchSnapshot(redactCwd(result), 'should output tree containing dev deps') - config.dev = false - }) - - t.test('--only=development', async t => { - config.only = 'development' - npm.prefix = t.testdir({ - 'package.json': JSON.stringify({ - name: 'test-npm-ls', - version: '1.0.0', - dependencies: { - 'prod-dep': '^1.0.0', - chai: '^1.0.0', - }, - devDependencies: { - 'dev-dep': '^1.0.0', - }, - optionalDependencies: { - 'optional-dep': '^1.0.0', - }, - peerDependencies: { - 'peer-dep': '^1.0.0', - }, - }), - ...diffDepTypesNmFixture, - }) - await ls.exec([]) - t.matchSnapshot(redactCwd(result), 'should output tree containing only development deps') - config.only = null + flatOptions.omit = [] }) t.test('--link', async t => { @@ -581,7 +673,7 @@ t.test('ls', t => { }) t.test('--production', async t => { - config.production = true + flatOptions.omit = ['dev', 'peer'] npm.prefix = t.testdir({ 'package.json': JSON.stringify({ name: 'test-npm-ls', @@ -604,34 +696,7 @@ t.test('ls', t => { }) await ls.exec([]) t.matchSnapshot(redactCwd(result), 'should output tree containing production deps') - config.production = false - }) - - t.test('--only=prod', async t => { - config.only = 'prod' - npm.prefix = t.testdir({ - 'package.json': JSON.stringify({ - name: 'test-npm-ls', - version: '1.0.0', - dependencies: { - 'prod-dep': '^1.0.0', - chai: '^1.0.0', - }, - devDependencies: { - 'dev-dep': '^1.0.0', - }, - optionalDependencies: { - 'optional-dep': '^1.0.0', - }, - peerDependencies: { - 'peer-dep': '^1.0.0', - }, - }), - ...diffDepTypesNmFixture, - }) - await ls.exec([]) - t.matchSnapshot(redactCwd(result), 'should output tree containing only prod deps') - config.only = null + flatOptions.omit = [] }) t.test('--long', async t => { @@ -1384,6 +1449,7 @@ t.test('ls', t => { name: 'workspaces-tree', version: '1.0.0', workspaces: ['./a', './b', './d', './group/*'], + dependencies: { pacote: '1.0.0' }, }), node_modules: { a: t.fixture('symlink', '../a'), @@ -1412,6 +1478,9 @@ t.test('ls', t => { baz: { 'package.json': JSON.stringify({ name: 'baz', version: '1.0.0' }), }, + pacote: { + 'package.json': JSON.stringify({ name: 'pacote', version: '1.0.0' }), + }, }, a: { 'package.json': JSON.stringify({ @@ -1469,6 +1538,7 @@ t.test('ls', t => { npm.flatOptions.workspacesEnabled = false await ls.exec([]) t.matchSnapshot(redactCwd(result), 'should not list workspaces with --no-workspaces') + config.all = true config.depth = Infinity npm.color = false @@ -1479,12 +1549,12 @@ t.test('ls', t => { t.matchSnapshot(redactCwd(result), 'should list --all workspaces properly') // --production - config.production = true + flatOptions.omit = ['dev', 'peer', 'optional'] await ls.exec([]) t.matchSnapshot(redactCwd(result), 'should list only prod deps of workspaces') - config.production = false + flatOptions.omit = [] // filter out a single workspace using args await ls.exec(['d']) @@ -1495,6 +1565,12 @@ t.test('ls', t => { t.matchSnapshot(redactCwd(result), 'should filter using workspace config') + // filter out a single workspace and include root + npm.flatOptions.includeWorkspaceRoot = true + await ls.execWorkspaces([], ['d']) + t.matchSnapshot(redactCwd(result), 'should inlude root and specified workspace') + npm.flatOptions.includeWorkspaceRoot = false + // filter out a workspace by parent path await ls.execWorkspaces([], ['./group']) @@ -1628,6 +1704,47 @@ t.test('ls --parseable', t => { t.matchSnapshot(redactCwd(result), 'should output containing problems info') }) + t.test('overridden dep', async t => { + config.all = true + config.long = true + t.teardown(() => { + config.all = false + config.long = false + }) + npm.prefix = t.testdir({ + 'package.json': JSON.stringify({ + name: 'test-overridden', + version: '1.0.0', + dependencies: { + foo: '^1.0.0', + }, + overrides: { + bar: '1.0.0', + }, + }), + node_modules: { + foo: { + 'package.json': JSON.stringify({ + name: 'foo', + version: '1.0.0', + dependencies: { + bar: '^2.0.0', + }, + }), + }, + bar: { + 'package.json': JSON.stringify({ + name: 'bar', + version: '1.0.0', + }), + }, + }, + }) + + await ls.exec([]) + t.matchSnapshot(redactCwd(result), 'should contain overridden outout') + }) + t.test('with filter arg', async t => { npm.prefix = t.testdir({ 'package.json': JSON.stringify({ @@ -1800,7 +1917,7 @@ t.test('ls --parseable', t => { }) t.test('--dev', async t => { - config.dev = true + flatOptions.omit = ['peer', 'prod', 'optional'] npm.prefix = t.testdir({ 'package.json': JSON.stringify({ name: 'test-npm-ls', @@ -1823,34 +1940,7 @@ t.test('ls --parseable', t => { }) await ls.exec([]) t.matchSnapshot(redactCwd(result), 'should output tree containing dev deps') - config.dev = false - }) - - t.test('--only=development', async t => { - config.only = 'development' - npm.prefix = t.testdir({ - 'package.json': JSON.stringify({ - name: 'test-npm-ls', - version: '1.0.0', - dependencies: { - 'prod-dep': '^1.0.0', - chai: '^1.0.0', - }, - devDependencies: { - 'dev-dep': '^1.0.0', - }, - optionalDependencies: { - 'optional-dep': '^1.0.0', - }, - peerDependencies: { - 'peer-dep': '^1.0.0', - }, - }), - ...diffDepTypesNmFixture, - }) - await ls.exec([]) - t.matchSnapshot(redactCwd(result), 'should output tree containing only development deps') - config.only = null + flatOptions.omit = [] }) t.test('--link', async t => { @@ -1891,7 +1981,7 @@ t.test('ls --parseable', t => { }) t.test('--production', async t => { - config.production = true + flatOptions.omit = ['dev', 'peer'] npm.prefix = t.testdir({ 'package.json': JSON.stringify({ name: 'test-npm-ls', @@ -1914,34 +2004,7 @@ t.test('ls --parseable', t => { }) await ls.exec([]) t.matchSnapshot(redactCwd(result), 'should output tree containing production deps') - config.production = false - }) - - t.test('--only=prod', async t => { - config.only = 'prod' - npm.prefix = t.testdir({ - 'package.json': JSON.stringify({ - name: 'test-npm-ls', - version: '1.0.0', - dependencies: { - 'prod-dep': '^1.0.0', - chai: '^1.0.0', - }, - devDependencies: { - 'dev-dep': '^1.0.0', - }, - optionalDependencies: { - 'optional-dep': '^1.0.0', - }, - peerDependencies: { - 'peer-dep': '^1.0.0', - }, - }), - ...diffDepTypesNmFixture, - }) - await ls.exec([]) - t.matchSnapshot(redactCwd(result), 'should output tree containing only prod deps') - config.only = null + flatOptions.omit = [] }) t.test('--long', async t => { @@ -2474,14 +2537,17 @@ t.test('ls --json', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -2509,6 +2575,7 @@ t.test('ls --json', t => { dog: { version: '1.0.0', extraneous: true, + overridden: false, problems: [ /* eslint-disable-next-line max-len */ 'extraneous: dog@1.0.0 {CWD}/tap-testdir-ls-ls---json-missing-package.json/node_modules/dog', @@ -2517,6 +2584,7 @@ t.test('ls --json', t => { foo: { version: '1.0.0', extraneous: true, + overridden: false, problems: [ /* eslint-disable-next-line max-len */ 'extraneous: foo@1.0.0 {CWD}/tap-testdir-ls-ls---json-missing-package.json/node_modules/foo', @@ -2530,6 +2598,7 @@ t.test('ls --json', t => { chai: { version: '1.0.0', extraneous: true, + overridden: false, problems: [ /* eslint-disable-next-line max-len */ 'extraneous: chai@1.0.0 {CWD}/tap-testdir-ls-ls---json-missing-package.json/node_modules/chai', @@ -2564,15 +2633,18 @@ t.test('ls --json', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, chai: { version: '1.0.0', extraneous: true, + overridden: false, problems: [ /* eslint-disable-next-line max-len */ 'extraneous: chai@1.0.0 {CWD}/tap-testdir-ls-ls---json-extraneous-deps/node_modules/chai', @@ -2584,6 +2656,58 @@ t.test('ls --json', t => { ) }) + t.test('overridden dep', async t => { + config.all = true + t.teardown(() => config.all = false) + npm.prefix = t.testdir({ + 'package.json': JSON.stringify({ + name: 'test-overridden', + version: '1.0.0', + dependencies: { + foo: '^1.0.0', + }, + overrides: { + bar: '1.0.0', + }, + }), + node_modules: { + foo: { + 'package.json': JSON.stringify({ + name: 'foo', + version: '1.0.0', + dependencies: { + bar: '^2.0.0', + }, + }), + }, + bar: { + 'package.json': JSON.stringify({ + name: 'bar', + version: '1.0.0', + }), + }, + }, + }) + + await ls.exec([]) + t.same(JSON.parse(result), { + name: 'test-overridden', + version: '1.0.0', + dependencies: { + foo: { + version: '1.0.0', + overridden: false, + dependencies: { + bar: { + version: '1.0.0', + overridden: true, + }, + }, + }, + }, + }) + }) + t.test('missing deps --long', async t => { t.plan(3) config.long = true @@ -2642,6 +2766,7 @@ t.test('ls --json', t => { dependencies: { chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -2671,9 +2796,11 @@ t.test('ls --json', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, @@ -2714,14 +2841,17 @@ t.test('ls --json', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -2778,9 +2908,11 @@ t.test('ls --json', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, }, chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -2813,9 +2945,11 @@ t.test('ls --json', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, }, chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -2848,14 +2982,17 @@ t.test('ls --json', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -2894,6 +3031,7 @@ t.test('ls --json', t => { foo: { version: '1.0.0', invalid: '"^2.0.0" from the root project', + overridden: false, problems: [ /* eslint-disable-next-line max-len */ 'invalid: foo@1.0.0 {CWD}/tap-testdir-ls-ls---json-missing-invalid-extraneous/node_modules/foo', @@ -2901,12 +3039,14 @@ t.test('ls --json', t => { dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, chai: { version: '1.0.0', extraneous: true, + overridden: false, problems: [ /* eslint-disable-next-line max-len */ 'extraneous: chai@1.0.0 {CWD}/tap-testdir-ls-ls---json-missing-invalid-extraneous/node_modules/chai', @@ -2924,7 +3064,7 @@ t.test('ls --json', t => { }) t.test('--dev', async t => { - config.dev = true + flatOptions.omit = ['prod', 'optional', 'peer'] npm.prefix = t.testdir({ 'package.json': JSON.stringify({ name: 'test-npm-ls', @@ -2954,10 +3094,17 @@ t.test('ls --json', t => { dependencies: { 'dev-dep': { version: '1.0.0', + overridden: false, dependencies: { foo: { version: '1.0.0', - dependencies: { dog: { version: '1.0.0' } }, + overridden: false, + dependencies: { + dog: { + version: '1.0.0', + overridden: false, + }, + }, }, }, }, @@ -2965,52 +3112,7 @@ t.test('ls --json', t => { }, 'should output json containing dev deps' ) - config.dev = false - }) - - t.test('--only=development', async t => { - config.only = 'development' - npm.prefix = t.testdir({ - 'package.json': JSON.stringify({ - name: 'test-npm-ls', - version: '1.0.0', - dependencies: { - 'prod-dep': '^1.0.0', - chai: '^1.0.0', - }, - devDependencies: { - 'dev-dep': '^1.0.0', - }, - optionalDependencies: { - 'optional-dep': '^1.0.0', - }, - peerDependencies: { - 'peer-dep': '^1.0.0', - }, - }), - ...diffDepTypesNmFixture, - }) - await ls.exec([]) - t.same( - jsonParse(result), - { - name: 'test-npm-ls', - version: '1.0.0', - dependencies: { - 'dev-dep': { - version: '1.0.0', - dependencies: { - foo: { - version: '1.0.0', - dependencies: { dog: { version: '1.0.0' } }, - }, - }, - }, - }, - }, - 'should output json containing only development deps' - ) - config.only = null + flatOptions.omit = [] }) t.test('--link', async t => { @@ -3055,6 +3157,7 @@ t.test('ls --json', t => { 'linked-dep': { version: '1.0.0', resolved: 'file:../linked-dep', + overridden: false, }, }, }, @@ -3064,7 +3167,7 @@ t.test('ls --json', t => { }) t.test('--production', async t => { - config.production = true + flatOptions.omit = ['dev', 'peer'] npm.prefix = t.testdir({ 'package.json': JSON.stringify({ name: 'test-npm-ls', @@ -3092,53 +3195,29 @@ t.test('ls --json', t => { name: 'test-npm-ls', version: '1.0.0', dependencies: { - chai: { version: '1.0.0' }, - 'optional-dep': { version: '1.0.0' }, - 'prod-dep': { version: '1.0.0', dependencies: { dog: { version: '2.0.0' } } }, + chai: { + version: '1.0.0', + overridden: false, + }, + 'optional-dep': { + version: '1.0.0', + overridden: false, + }, + 'prod-dep': { + version: '1.0.0', + overridden: false, + dependencies: { + dog: { + version: '2.0.0', + overridden: false, + }, + }, + }, }, }, 'should output json containing production deps' ) - config.production = false - }) - - t.test('--only=prod', async t => { - config.only = 'prod' - npm.prefix = t.testdir({ - 'package.json': JSON.stringify({ - name: 'test-npm-ls', - version: '1.0.0', - dependencies: { - 'prod-dep': '^1.0.0', - chai: '^1.0.0', - }, - devDependencies: { - 'dev-dep': '^1.0.0', - }, - optionalDependencies: { - 'optional-dep': '^1.0.0', - }, - peerDependencies: { - 'peer-dep': '^1.0.0', - }, - }), - ...diffDepTypesNmFixture, - }) - await ls.exec([]) - t.same( - jsonParse(result), - { - name: 'test-npm-ls', - version: '1.0.0', - dependencies: { - chai: { version: '1.0.0' }, - 'optional-dep': { version: '1.0.0' }, - 'prod-dep': { version: '1.0.0', dependencies: { dog: { version: '2.0.0' } } }, - }, - }, - 'should output json containing only prod deps' - ) - config.only = null + flatOptions.omit = [] }) t.test('from lockfile', async t => { @@ -3256,6 +3335,7 @@ t.test('ls --json', t => { dependencies: { '@isaacs/dedupe-tests-a': { version: '1.0.1', + overridden: false, resolved: 'https://registry.npmjs.org/@isaacs/dedupe-tests-a/-/dedupe-tests-a-1.0.1.tgz', dependencies: { @@ -3263,6 +3343,7 @@ t.test('ls --json', t => { resolved: 'https://registry.npmjs.org/@isaacs/dedupe-tests-b/-/dedupe-tests-b-1.0.0.tgz', extraneous: true, + overridden: false, problems: [ /* eslint-disable-next-line max-len */ 'extraneous: @isaacs/dedupe-tests-b@ {CWD}/tap-testdir-ls-ls---json-from-lockfile/node_modules/@isaacs/dedupe-tests-a/node_modules/@isaacs/dedupe-tests-b', @@ -3272,6 +3353,7 @@ t.test('ls --json', t => { }, '@isaacs/dedupe-tests-b': { version: '2.0.0', + overridden: false, resolved: 'https://registry.npmjs.org/@isaacs/dedupe-tests-b/-/dedupe-tests-b-2.0.0.tgz', }, @@ -3316,6 +3398,7 @@ t.test('ls --json', t => { dependencies: { 'peer-dep': { name: 'peer-dep', + overridden: false, description: 'Peer-dep description here', version: '1.0.0', _id: 'peer-dep@1.0.0', @@ -3327,15 +3410,18 @@ t.test('ls --json', t => { }, 'dev-dep': { name: 'dev-dep', + overridden: false, description: 'A DEV dep kind of dep', version: '1.0.0', dependencies: { foo: { name: 'foo', version: '1.0.0', + overridden: false, dependencies: { dog: { name: 'dog', + overridden: false, version: '1.0.0', _id: 'dog@1.0.0', devDependencies: {}, @@ -3362,6 +3448,7 @@ t.test('ls --json', t => { }, chai: { name: 'chai', + overridden: false, version: '1.0.0', _id: 'chai@1.0.0', devDependencies: {}, @@ -3372,6 +3459,7 @@ t.test('ls --json', t => { }, 'optional-dep': { name: 'optional-dep', + overridden: false, description: 'Maybe a dep?', version: '1.0.0', _id: 'optional-dep@1.0.0', @@ -3383,11 +3471,13 @@ t.test('ls --json', t => { }, 'prod-dep': { name: 'prod-dep', + overridden: false, description: 'A PROD dep kind of dep', version: '1.0.0', dependencies: { dog: { name: 'dog', + overridden: false, description: 'A dep that bars', version: '2.0.0', _id: 'dog@2.0.0', @@ -3453,6 +3543,7 @@ t.test('ls --json', t => { dependencies: { 'peer-dep': { name: 'peer-dep', + overridden: false, description: 'Peer-dep description here', version: '1.0.0', _id: 'peer-dep@1.0.0', @@ -3464,6 +3555,7 @@ t.test('ls --json', t => { }, 'dev-dep': { name: 'dev-dep', + overridden: false, description: 'A DEV dep kind of dep', version: '1.0.0', _id: 'dev-dep@1.0.0', @@ -3475,6 +3567,7 @@ t.test('ls --json', t => { }, chai: { name: 'chai', + overridden: false, version: '1.0.0', _id: 'chai@1.0.0', devDependencies: {}, @@ -3485,6 +3578,7 @@ t.test('ls --json', t => { }, 'optional-dep': { name: 'optional-dep', + overridden: false, description: 'Maybe a dep?', version: '1.0.0', _id: 'optional-dep@1.0.0', @@ -3496,6 +3590,7 @@ t.test('ls --json', t => { }, 'prod-dep': { name: 'prod-dep', + overridden: false, description: 'A PROD dep kind of dep', version: '1.0.0', _id: 'prod-dep@1.0.0', @@ -3584,6 +3679,7 @@ t.test('ls --json', t => { 'peer-dep': { version: '1.0.0', invalid: '"^2.0.0" from the root project', + overridden: false, problems: [ /* eslint-disable-next-line max-len */ 'invalid: peer-dep@1.0.0 {CWD}/tap-testdir-ls-ls---json-unmet-peer-dep/node_modules/peer-dep', @@ -3591,16 +3687,38 @@ t.test('ls --json', t => { }, 'dev-dep': { version: '1.0.0', + overridden: false, dependencies: { foo: { version: '1.0.0', - dependencies: { dog: { version: '1.0.0' } }, + overridden: false, + dependencies: { + dog: { + version: '1.0.0', + overridden: false, + }, + }, + }, + }, + }, + chai: { + version: '1.0.0', + overridden: false, + }, + 'optional-dep': { + version: '1.0.0', + overridden: false, + }, + 'prod-dep': { + version: '1.0.0', + overridden: false, + dependencies: { + dog: { + version: '2.0.0', + overridden: false, }, }, }, - chai: { version: '1.0.0' }, - 'optional-dep': { version: '1.0.0' }, - 'prod-dep': { version: '1.0.0', dependencies: { dog: { version: '2.0.0' } } }, }, }, 'should output json signaling missing peer dep in problems' @@ -3647,6 +3765,7 @@ t.test('ls --json', t => { 'optional-dep': { version: '1.0.0', invalid: '"^2.0.0" from the root project', + overridden: false, problems: [ /* eslint-disable-next-line max-len */ 'invalid: optional-dep@1.0.0 {CWD}/tap-testdir-ls-ls---json-unmet-optional-dep/node_modules/optional-dep', @@ -3654,18 +3773,38 @@ t.test('ls --json', t => { }, 'peer-dep': { version: '1.0.0', + overridden: false, }, 'dev-dep': { version: '1.0.0', + overridden: false, dependencies: { foo: { version: '1.0.0', - dependencies: { dog: { version: '1.0.0' } }, + overridden: false, + dependencies: { + dog: { + version: '1.0.0', + overridden: false, + }, + }, + }, + }, + }, + chai: { + version: '1.0.0', + overridden: false, + }, + 'prod-dep': { + version: '1.0.0', + overridden: false, + dependencies: { + dog: { + version: '2.0.0', + overridden: false, }, }, }, - chai: { version: '1.0.0' }, - 'prod-dep': { version: '1.0.0', dependencies: { dog: { version: '2.0.0' } } }, 'missing-optional-dep': {}, // missing optional dep has an empty entry in json output }, }, @@ -3712,11 +3851,15 @@ t.test('ls --json', t => { dependencies: { a: { version: '1.0.0', + overridden: false, dependencies: { b: { version: '1.0.0', + overridden: false, dependencies: { - a: { version: '1.0.0' }, + a: { + version: '1.0.0', + }, }, }, }, @@ -3768,6 +3911,7 @@ t.test('ls --json', t => { dependencies: { a: { version: '1.0.0', + overridden: false, resolved: 'https://localhost:8080/abbrev/-/abbrev-1.1.1.tgz', }, }, @@ -3828,6 +3972,7 @@ t.test('ls --json', t => { dependencies: { abbrev: { version: '1.1.1', + overridden: false, /* eslint-disable-next-line max-len */ resolved: 'git+ssh://git@github.com/isaacs/abbrev-js.git#b8f3a2fc0c3bb8ffd8b0d0072cc6b5a3667e963c', }, @@ -3905,6 +4050,7 @@ t.test('ls --json', t => { dependencies: { 'simple-output': { version: '2.1.1', + overridden: false, resolved: 'https://registry.npmjs.org/simple-output/-/simple-output-2.1.1.tgz', }, }, @@ -3968,12 +4114,15 @@ t.test('ls --json', t => { dependencies: { a: { version: '1.0.0', + overridden: false, }, b: { version: '1.0.0', + overridden: false, dependencies: { c: { version: '1.0.0', + overridden: false, }, }, }, @@ -4079,14 +4228,17 @@ t.test('ls --package-lock-only', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -4129,9 +4281,11 @@ t.test('ls --package-lock-only', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, @@ -4225,6 +4379,7 @@ t.test('ls --package-lock-only', t => { dependencies: { chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -4272,9 +4427,11 @@ t.test('ls --package-lock-only', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, @@ -4324,14 +4481,17 @@ t.test('ls --package-lock-only', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -4418,9 +4578,11 @@ t.test('ls --package-lock-only', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, }, chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -4468,9 +4630,11 @@ t.test('ls --package-lock-only', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, }, chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -4518,14 +4682,17 @@ t.test('ls --package-lock-only', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, chai: { version: '1.0.0', + overridden: false, }, }, }, @@ -4576,6 +4743,7 @@ t.test('ls --package-lock-only', t => { dependencies: { foo: { version: '1.0.0', + overridden: false, invalid: '"^2.0.0" from the root project', problems: [ /* eslint-disable-next-line max-len */ @@ -4584,6 +4752,7 @@ t.test('ls --package-lock-only', t => { dependencies: { dog: { version: '1.0.0', + overridden: false, }, }, }, @@ -4689,11 +4858,13 @@ t.test('ls --package-lock-only', t => { dependencies: { '@isaacs/dedupe-tests-a': { version: '1.0.1', + overridden: false, resolved: 'https://registry.npmjs.org/@isaacs/dedupe-tests-a/-/dedupe-tests-a-1.0.1.tgz', dependencies: { '@isaacs/dedupe-tests-b': { version: '1.0.0', + overridden: false, resolved: 'https://registry.npmjs.org/@isaacs/dedupe-tests-b/-/dedupe-tests-b-1.0.0.tgz', }, @@ -4701,6 +4872,7 @@ t.test('ls --package-lock-only', t => { }, '@isaacs/dedupe-tests-b': { version: '2.0.0', + overridden: false, resolved: 'https://registry.npmjs.org/@isaacs/dedupe-tests-b/-/dedupe-tests-b-2.0.0.tgz', }, @@ -4737,6 +4909,7 @@ t.test('ls --package-lock-only', t => { dependencies: { a: { version: '1.0.0', + overridden: false, resolved: 'https://localhost:8080/abbrev/-/abbrev-1.0.0.tgz', }, }, @@ -4779,6 +4952,7 @@ t.test('ls --package-lock-only', t => { abbrev: { /* eslint-disable-next-line max-len */ resolved: 'git+ssh://git@github.com/isaacs/abbrev-js.git#b8f3a2fc0c3bb8ffd8b0d0072cc6b5a3667e963c', + overridden: false, }, }, }, diff --git a/test/lib/commands/org.js b/test/lib/commands/org.js index b716adc..cd25fc2 100644 --- a/test/lib/commands/org.js +++ b/test/lib/commands/org.js @@ -1,18 +1,20 @@ const t = require('tap') const ansiTrim = require('../../../lib/utils/ansi-trim.js') +const { fake: mockNpm } = require('../../fixtures/mock-npm') const output = [] -const npm = { +const npm = mockNpm({ flatOptions: { json: false, parseable: false, - silent: false, + }, + config: { loglevel: 'info', }, output: msg => { output.push(msg) }, -} +}) let orgSize = 1 let orgSetArgs = null @@ -41,7 +43,6 @@ const libnpmorg = { } const Org = t.mock('../../../lib/commands/org.js', { - '../../../lib/utils/otplease.js': async (opts, fn) => fn(opts), libnpmorg, }) const org = new Org(npm) @@ -83,7 +84,6 @@ t.test('npm org add', async t => { await org.exec(['add', 'orgname', 'username']) - t.ok(orgSetArgs.opts.log, 'got passed a logger') t.match( orgSetArgs, { @@ -149,7 +149,6 @@ t.test('npm org add - more users', async t => { }) await org.exec(['add', 'orgname', 'username']) - t.ok(orgSetArgs.opts.log, 'got passed a logger') t.match( orgSetArgs, { @@ -177,7 +176,6 @@ t.test('npm org add - json output', async t => { await org.exec(['add', 'orgname', 'username']) - t.ok(orgSetArgs.opts.log, 'got passed a logger') t.match( orgSetArgs, { @@ -212,7 +210,6 @@ t.test('npm org add - parseable output', async t => { await org.exec(['add', 'orgname', 'username']) - t.ok(orgSetArgs.opts.log, 'got passed a logger') t.match( orgSetArgs, { @@ -234,16 +231,15 @@ t.test('npm org add - parseable output', async t => { }) t.test('npm org add - silent output', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') t.teardown(() => { - npm.flatOptions.silent = false + npm.config.set('loglevel', 'info') orgSetArgs = null output.length = 0 }) await org.exec(['add', 'orgname', 'username']) - t.ok(orgSetArgs.opts.log, 'got passed a logger') t.match( orgSetArgs, { @@ -266,7 +262,6 @@ t.test('npm org rm', async t => { await org.exec(['rm', 'orgname', 'username']) - t.ok(orgRmArgs.opts.log, 'got passed a logger') t.match( orgRmArgs, { @@ -276,7 +271,6 @@ t.test('npm org rm', async t => { }, 'libnpmorg.rm received the correct args' ) - t.ok(orgLsArgs.opts.log, 'got passed a logger') t.match( orgLsArgs, { @@ -330,7 +324,6 @@ t.test('npm org rm - one user left', async t => { await org.exec(['rm', 'orgname', 'username']) - t.ok(orgRmArgs.opts.log, 'got passed a logger') t.match( orgRmArgs, { @@ -340,7 +333,6 @@ t.test('npm org rm - one user left', async t => { }, 'libnpmorg.rm received the correct args' ) - t.ok(orgLsArgs.opts.log, 'got passed a logger') t.match( orgLsArgs, { @@ -367,7 +359,6 @@ t.test('npm org rm - json output', async t => { await org.exec(['rm', 'orgname', 'username']) - t.ok(orgRmArgs.opts.log, 'got passed a logger') t.match( orgRmArgs, { @@ -377,7 +368,6 @@ t.test('npm org rm - json output', async t => { }, 'libnpmorg.rm received the correct args' ) - t.ok(orgLsArgs.opts.log, 'got passed a logger') t.match( orgLsArgs, { @@ -409,7 +399,6 @@ t.test('npm org rm - parseable output', async t => { await org.exec(['rm', 'orgname', 'username']) - t.ok(orgRmArgs.opts.log, 'got passed a logger') t.match( orgRmArgs, { @@ -419,7 +408,6 @@ t.test('npm org rm - parseable output', async t => { }, 'libnpmorg.rm received the correct args' ) - t.ok(orgLsArgs.opts.log, 'got passed a logger') t.match( orgLsArgs, { @@ -439,9 +427,9 @@ t.test('npm org rm - parseable output', async t => { }) t.test('npm org rm - silent output', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') t.teardown(() => { - npm.flatOptions.silent = false + npm.config.set('loglevel', 'info') orgRmArgs = null orgLsArgs = null output.length = 0 @@ -449,7 +437,6 @@ t.test('npm org rm - silent output', async t => { await org.exec(['rm', 'orgname', 'username']) - t.ok(orgRmArgs.opts.log, 'got passed a logger') t.match( orgRmArgs, { @@ -459,7 +446,6 @@ t.test('npm org rm - silent output', async t => { }, 'libnpmorg.rm received the correct args' ) - t.ok(orgLsArgs.opts.log, 'got passed a logger') t.match( orgLsArgs, { @@ -485,7 +471,6 @@ t.test('npm org ls', async t => { await org.exec(['ls', 'orgname']) - t.ok(orgLsArgs.opts.log, 'got passed a logger') t.match( orgLsArgs, { @@ -513,7 +498,6 @@ t.test('npm org ls - user filter', async t => { await org.exec(['ls', 'orgname', 'username']) - t.ok(orgLsArgs.opts.log, 'got passed a logger') t.match( orgLsArgs, { @@ -539,7 +523,6 @@ t.test('npm org ls - user filter, missing user', async t => { await org.exec(['ls', 'orgname', 'username']) - t.ok(orgLsArgs.opts.log, 'got passed a logger') t.match( orgLsArgs, { @@ -578,7 +561,6 @@ t.test('npm org ls - json output', async t => { await org.exec(['ls', 'orgname']) - t.ok(orgLsArgs.opts.log, 'got passed a logger') t.match( orgLsArgs, { @@ -606,7 +588,6 @@ t.test('npm org ls - parseable output', async t => { await org.exec(['ls', 'orgname']) - t.ok(orgLsArgs.opts.log, 'got passed a logger') t.match( orgLsArgs, { @@ -628,14 +609,14 @@ t.test('npm org ls - parseable output', async t => { }) t.test('npm org ls - silent output', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') orgList = { one: 'developer', two: 'admin', three: 'owner', } t.teardown(() => { - npm.flatOptions.silent = false + npm.config.set('loglevel', 'info') orgList = {} orgLsArgs = null output.length = 0 @@ -643,7 +624,6 @@ t.test('npm org ls - silent output', async t => { await org.exec(['ls', 'orgname']) - t.ok(orgLsArgs.opts.log, 'got passed a logger') t.match( orgLsArgs, { diff --git a/test/lib/commands/outdated.js b/test/lib/commands/outdated.js index 3bf42b1..4803c7e 100644 --- a/test/lib/commands/outdated.js +++ b/test/lib/commands/outdated.js @@ -84,10 +84,6 @@ const globalDir = t.testdir({ }, }) -const flatOptions = { - workspacesEnabled: true, -} - const outdated = (dir, opts) => { logs = '' const Outdated = t.mock('../../../lib/commands/outdated.js', { @@ -95,11 +91,22 @@ const outdated = (dir, opts) => { packument, }, }) + if (opts.config && opts.config.omit) { + opts.flatOptions = { + omit: opts.config.omit, + ...opts.flatOptions, + } + delete opts.config.omit + } const npm = mockNpm({ ...opts, localPrefix: dir, prefix: dir, - flatOptions, + flatOptions: { + workspacesEnabled: true, + omit: [], + ...opts.flatOptions, + }, globalDir: `${globalDir}/node_modules`, output, }) @@ -336,7 +343,9 @@ t.test('should return if no outdated deps', async t => { }) await outdated(testDir, { - global: false, + config: { + global: false, + }, }).exec([]) t.equal(logs.length, 0, 'no logs') }) @@ -362,7 +371,9 @@ t.test('throws if error with a dep', async t => { await t.rejects( outdated(testDir, { - global: false, + config: { + global: false, + }, }).exec([]), 'There is an error with this package.' ) @@ -381,7 +392,9 @@ t.test('should skip missing non-prod deps', async t => { }) await outdated(testDir, { - global: false, + config: { + global: false, + }, }).exec([]) t.equal(logs.length, 0, 'no logs') }) @@ -529,14 +542,16 @@ t.test('workspaces', async t => { t.matchSnapshot(logs, 'should display ws outdated deps human output') t.equal(process.exitCode, 1) - flatOptions.workspacesEnabled = false - await outdated(testDir, {}).exec([]) + await outdated(testDir, { + flatOptions: { + workspacesEnabled: false, + }, + }).exec([]) // TODO: This should display dog, but doesn't because arborist filters // workspace deps even if they're also root deps // This will be fixed in a future arborist version t.matchSnapshot(logs, 'should display only root outdated when ws disabled') - flatOptions.workspacesEnabled = true await outdated(testDir, { config: { diff --git a/test/lib/commands/owner.js b/test/lib/commands/owner.js index a32a3df..5b6bb44 100644 --- a/test/lib/commands/owner.js +++ b/test/lib/commands/owner.js @@ -1,778 +1,691 @@ const t = require('tap') -const { fake: mockNpm } = require('../../fixtures/mock-npm.js') +const { load: loadMockNpm } = require('../../fixtures/mock-npm.js') +const MockRegistry = require('@npmcli/mock-registry') -let result = '' -let readPackageNamePrefix = null -let readPackageNameResponse = null +const path = require('path') +const npa = require('npm-package-arg') +const packageName = '@npmcli/test-package' +const spec = npa(packageName) +const auth = { '//registry.npmjs.org/:_authToken': 'test-auth-token' } -const noop = () => null - -const npm = mockNpm({ - output: (msg) => { - result = result ? `${result}\n${msg}` : msg - }, -}) - -const npmFetch = { json: noop } -const log = { error: noop, info: noop, verbose: noop } -const pacote = { packument: noop } - -const mocks = { - 'proc-log': log, - 'npm-registry-fetch': npmFetch, - pacote, - '../../../lib/utils/otplease.js': async (opts, fn) => fn({ otp: '123456', opts }), - '../../../lib/utils/read-package-name.js': async (prefix) => { - readPackageNamePrefix = prefix - return readPackageNameResponse - }, - '../../../lib/utils/usage.js': () => 'usage instructions', -} - -const npmcliMaintainers = [ - { email: 'quitlahok@gmail.com', name: 'nlf' }, - { email: 'ruyadorno@hotmail.com', name: 'ruyadorno' }, - { email: 'darcy@darcyclarke.me', name: 'darcyclarke' }, - { email: 'i@izs.me', name: 'isaacs' }, +const maintainers = [ + { email: 'test-user-a@npmjs.org', name: 'test-user-a' }, + { email: 'test-user-b@npmjs.org', name: 'test-user-b' }, ] -const Owner = t.mock('../../../lib/commands/owner.js', mocks) -const owner = new Owner(npm) +const workspaceFixture = { + 'package.json': JSON.stringify({ + name: packageName, + version: '1.2.3-test', + workspaces: ['workspace-a', 'workspace-b', 'workspace-c'], + }), + 'workspace-a': { + 'package.json': JSON.stringify({ + name: 'workspace-a', + version: '1.2.3-a', + }), + }, + 'workspace-b': { + 'package.json': JSON.stringify({ + name: 'workspace-b', + version: '1.2.3-n', + }), + }, + 'workspace-c': JSON.stringify({ + 'package.json': { + name: 'workspace-n', + version: '1.2.3-n', + }, + }), +} + +function registryPackage (t, registry, name) { + const mockRegistry = new MockRegistry({ tap: t, registry }) + + const manifest = mockRegistry.manifest({ + name, + packuments: [{ maintainers, version: '1.0.0' }], + }) + return mockRegistry.package({ manifest }) +} t.test('owner no args', async t => { - result = '' - t.teardown(() => { - result = '' - }) - + const { npm } = await loadMockNpm(t) await t.rejects( - owner.exec([]), - owner.usage) + npm.exec('owner', []), + { code: 'EUSAGE' }, + 'rejects with usage' + ) }) t.test('owner ls no args', async t => { - t.plan(5) - - result = '' - - readPackageNameResponse = '@npmcli/map-workspaces' - pacote.packument = async (spec, opts) => { - t.equal(spec.name, '@npmcli/map-workspaces', 'should use expect pkg name') - t.ok(opts.log, 'is passed a logger') - t.match( - opts, - { - ...npm.flatOptions, - fullMetadata: true, - }, - 'should forward expected options to pacote.packument' - ) - return { maintainers: npmcliMaintainers } - } - t.teardown(() => { - npm.prefix = null - result = '' - pacote.packument = noop - readPackageNameResponse = null + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ name: packageName }), + }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - npm.prefix = 'test-npm-prefix' - await owner.exec(['ls']) - t.matchSnapshot(result, 'should output owners of cwd package') - t.equal(readPackageNamePrefix, 'test-npm-prefix', 'read-package-name gets npm.prefix') + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers, version: '1.0.0' }], + }) + await registry.package({ manifest }) + + await npm.exec('owner', ['ls']) + t.match(joinedOutput(), maintainers.map(m => `${m.name} <${m.email}>`).join('\n')) +}) + +t.test('local package.json has no name', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ hello: 'world' }), + }, + }) + await t.rejects( + npm.exec('owner', ['ls']), + { code: 'EUSAGE' } + ) }) t.test('owner ls global', async t => { - t.teardown(() => { - npm.config.set('global', false) + const { npm } = await loadMockNpm(t, { + config: { global: true }, }) - npm.config.set('global', true) await t.rejects( - owner.exec(['ls']), - owner.usage + npm.exec('owner', ['ls']), + { code: 'EUSAGE' }, + 'rejects with usage' ) }) t.test('owner ls no args no cwd package', async t => { - result = '' - t.teardown(() => { - result = '' - log.error = noop - }) + const { npm } = await loadMockNpm(t) await t.rejects( - owner.exec(['ls']), - owner.usage + npm.exec('owner', ['ls']) ) }) t.test('owner ls fails to retrieve packument', async t => { - t.plan(4) - - result = '' - readPackageNameResponse = '@npmcli/map-workspaces' - pacote.packument = () => { - throw new Error('ERR') - } - log.error = (title, msg, pkgName) => { - t.equal(title, 'owner ls', 'should list npm owner ls title') - t.equal(msg, "Couldn't get owner data", 'should use expected msg') - t.equal(pkgName, '@npmcli/map-workspaces', 'should use pkg name') - } - t.teardown(() => { - result = '' - log.error = noop - pacote.packument = noop + const { npm, logs } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ name: packageName }), + }, }) - - await t.rejects( - owner.exec(['ls']), - /ERR/, - 'should throw unknown error' - ) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.nock.get(`/${spec.escapedName}`).reply(404) + await t.rejects(npm.exec('owner', ['ls'])) + t.match(logs.error, [['owner ls', "Couldn't get owner data", '@npmcli/test-package']]) }) t.test('owner ls <pkg>', async t => { - t.plan(3) - - result = '' - pacote.packument = async (spec, opts) => { - t.equal(spec.name, '@npmcli/map-workspaces', 'should use expect pkg name') - t.match( - opts, - { - ...npm.flatOptions, - fullMetadata: true, - }, - 'should forward expected options to pacote.packument' - ) - return { maintainers: npmcliMaintainers } - } - t.teardown(() => { - result = '' - pacote.packument = noop + const { npm, joinedOutput } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - await owner.exec(['ls', '@npmcli/map-workspaces']) - t.matchSnapshot(result, 'should output owners of <pkg>') + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers, version: '1.0.0' }], + }) + await registry.package({ manifest }) + + await npm.exec('owner', ['ls', packageName]) + t.match(joinedOutput(), maintainers.map(m => `${m.name} <${m.email}>`).join('\n')) }) t.test('owner ls <pkg> no maintainers', async t => { - result = '' - pacote.packument = async (spec, opts) => { - return { maintainers: [] } - } - t.teardown(() => { - result = '' - pacote.packument = noop + const { npm, joinedOutput } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) + const manifest = registry.manifest({ + name: packageName, + versions: ['1.0.0'], + }) + await registry.package({ manifest }) - await owner.exec(['ls', '@npmcli/map-workspaces']) - t.equal(result, 'no admin found', 'should output no admint found msg') + await npm.exec('owner', ['ls', packageName]) + t.equal(joinedOutput(), 'no admin found') }) t.test('owner add <user> <pkg>', async t => { - t.plan(11) - - result = '' - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - // retrieve user info from couchdb request - if (uri === '/-/user/org.couchdb.user:foo') { - t.ok('should request user info') - t.match(opts, { ...npm.flatOptions }, 'should use expected opts') - return { - _id: 'org.couchdb.user:foo', - email: 'foo@github.com', - name: 'foo', - } - } else if (uri === '/@npmcli%2fmap-workspaces/-rev/1-foobaaa1') { - t.ok('should put changed owner') - t.match(opts, { - ...npm.flatOptions, - method: 'PUT', - body: { - _rev: '1-foobaaa1', - maintainers: npmcliMaintainers, - }, - otp: '123456', - spec: { - name: '@npmcli/map-workspaces', - }, - }, 'should use expected opts') - t.same( - opts.body.maintainers, - [ - ...npmcliMaintainers, - { - name: 'foo', - email: 'foo@github.com', - }, - ], - 'should contain expected new owners, adding requested user' - ) - return {} - } else { - t.fail(`unexpected fetch json call to uri: ${uri}`) - } - } - pacote.packument = async (spec, opts) => { - t.ok(opts.log, 'is passed a logger') - t.equal(spec.name, '@npmcli/map-workspaces', 'should use expect pkg name') - t.match( - opts, - { - ...npm.flatOptions, - fullMetadata: true, - }, - 'should forward expected options to pacote.packument' - ) - return { - _rev: '1-foobaaa1', - maintainers: npmcliMaintainers, - } - } - t.teardown(() => { - result = '' - npmFetch.json = noop - pacote.packument = noop + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { ...auth }, }) - - await owner.exec(['add', 'foo', '@npmcli/map-workspaces']) - t.equal(result, '+ foo (@npmcli/map-workspaces)', 'should output add result') + const username = 'foo' + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers, version: '1.0.0' }], + }) + registry.couchuser({ username }) + await registry.package({ manifest }) + registry.nock.put(`/${spec.escapedName}/-rev/${manifest._rev}`, body => { + t.match(body, { + _id: manifest._id, + _rev: manifest._rev, + maintainers: [ + ...manifest.maintainers, + { name: username, email: '' }, + ], + }) + return true + }).reply(200, {}) + await npm.exec('owner', ['add', username, packageName]) + t.equal(joinedOutput(), `+ ${username} (${packageName})`) }) t.test('owner add <user> cwd package', async t => { - result = '' - readPackageNameResponse = '@npmcli/map-workspaces' - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - // retrieve user info from couchdb request - if (uri === '/-/user/org.couchdb.user:foo') { - return { - _id: 'org.couchdb.user:foo', - email: 'foo@github.com', - name: 'foo', - } - } else if (uri === '/@npmcli%2fmap-workspaces/-rev/1-foobaaa1') { - return {} - } else { - t.fail(`unexpected fetch json call to uri: ${uri}`) - } - } - pacote.packument = async (spec, opts) => ({ - _rev: '1-foobaaa1', - maintainers: npmcliMaintainers, + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ name: packageName }), + }, + config: { ...auth }, }) - t.teardown(() => { - result = '' - readPackageNameResponse = null - npmFetch.json = noop - pacote.packument = noop + const username = 'foo' + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - - await owner.exec(['add', 'foo']) - t.equal(result, '+ foo (@npmcli/map-workspaces)', 'should output add result') + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers, version: '1.0.0' }], + }) + registry.couchuser({ username }) + await registry.package({ manifest }) + registry.nock.put(`/${spec.escapedName}/-rev/${manifest._rev}`, body => { + t.match(body, { + _id: manifest._id, + _rev: manifest._rev, + maintainers: [ + ...manifest.maintainers, + { name: username, email: '' }, + ], + }) + return true + }).reply(200, {}) + await npm.exec('owner', ['add', username]) + t.equal(joinedOutput(), `+ ${username} (${packageName})`) }) t.test('owner add <user> <pkg> already an owner', async t => { - t.plan(3) - - result = '' - log.info = (title, msg) => { - t.equal(title, 'owner add', 'should use expected title') - t.equal( - msg, - 'Already a package owner: ruyadorno <ruyadorno@hotmail.com>', - 'should log already package owner info message' - ) - } - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - // retrieve user info from couchdb request - if (uri === '/-/user/org.couchdb.user:ruyadorno') { - return { - _id: 'org.couchdb.user:ruyadorno', - email: 'ruyadorno@hotmail.com', - name: 'ruyadorno', - } - } else { - t.fail(`unexpected fetch json call to uri: ${uri}`) - } - } - pacote.packument = async (spec, opts) => { - return { - _rev: '1-foobaaa1', - maintainers: npmcliMaintainers, - } - } - t.teardown(() => { - result = '' - log.info = noop - npmFetch.json = noop - pacote.packument = noop + const { npm, joinedOutput, logs } = await loadMockNpm(t, { + config: { ...auth }, }) - - await owner.exec(['add', 'ruyadorno', '@npmcli/map-workspaces']) + const username = maintainers[0].name + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers, version: '1.0.0' }], + }) + registry.couchuser({ username }) + await registry.package({ manifest }) + await npm.exec('owner', ['add', username, packageName]) + t.equal(joinedOutput(), '') + t.match( + logs.info, + [['owner add', 'Already a package owner: test-user-a <test-user-a@npmjs.org>']] + ) }) t.test('owner add <user> <pkg> fails to retrieve user', async t => { - result = '' - readPackageNameResponse = - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - // retrieve borked user info from couchdb request - if (uri === '/-/user/org.couchdb.user:foo') { - return { ok: false } - } else if (uri === '/@npmcli%2fmap-workspaces/-rev/1-foobaaa1') { - return {} - } else { - t.fail(`unexpected fetch json call to uri: ${uri}`) - } - } - pacote.packument = async (spec, opts) => ({ - _rev: '1-foobaaa1', - maintainers: npmcliMaintainers, + const { npm, logs } = await loadMockNpm(t, { + config: { ...auth }, }) - t.teardown(() => { - result = '' - readPackageNameResponse = null - npmFetch.json = noop - pacote.packument = noop + const username = 'foo' + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - - await t.rejects( - owner.exec(['add', 'foo', '@npmcli/map-workspaces']), - { code: 'EOWNERUSER', message: /Couldn't get user data for foo: {"ok":false}/ }, - 'should throw user data error' - ) + registry.couchuser({ username, responseCode: 404, body: {} }) + await t.rejects(npm.exec('owner', ['add', username, packageName])) + t.match(logs.error, [['owner mutate', `Error getting user data for ${username}`]]) }) t.test('owner add <user> <pkg> fails to PUT updates', async t => { - result = '' - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - // retrieve user info from couchdb request - if (uri === '/-/user/org.couchdb.user:foo') { - return { - _id: 'org.couchdb.user:foo', - email: 'foo@github.com', - name: 'foo', - } - } else if (uri === '/@npmcli%2fmap-workspaces/-rev/1-foobaaa1') { - return { - error: { - status: '418', - message: "I'm a teapot", - }, - } - } else { - t.fail(`unexpected fetch json call to uri: ${uri}`) - } - } - pacote.packument = async (spec, opts) => ({ - _rev: '1-foobaaa1', - maintainers: npmcliMaintainers, + const { npm } = await loadMockNpm(t, { + config: { ...auth }, }) - t.teardown(() => { - result = '' - npmFetch.json = noop - pacote.packument = noop + const username = 'foo' + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers, version: '1.0.0' }], + }) + registry.couchuser({ username }) + await registry.package({ manifest }) + registry.nock.put(`/${spec.escapedName}/-rev/${manifest._rev}`).reply(404, {}) await t.rejects( - owner.exec(['add', 'foo', '@npmcli/map-workspaces']), - { code: 'EOWNERMUTATE', message: /Failed to update package/ }, - 'should throw failed to update package error' - ) -}) - -t.test('owner add <user> <pkg> fails to retrieve user info', async t => { - t.plan(4) - - result = '' - log.error = (title, msg) => { - t.equal(title, 'owner mutate', 'should use expected title') - t.equal(msg, 'Error getting user data for foo') - } - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - // retrieve user info from couchdb request - if (uri === '/-/user/org.couchdb.user:foo') { - throw Object.assign( - new Error("I'm a teapot"), - { status: 418 } - ) - } else { - t.fail(`unexpected fetch json call to uri: ${uri}`) - } - } - pacote.packument = async (spec, opts) => ({ - _rev: '1-foobaaa1', - maintainers: npmcliMaintainers, - }) - t.teardown(() => { - result = '' - log.error = noop - npmFetch.json = noop - pacote.packument = noop - }) - - await t.rejects( - owner.exec(['add', 'foo', '@npmcli/map-workspaces']), - "I'm a teapot", - 'should throw server error response' + npm.exec('owner', ['add', username, packageName]), + { code: 'EOWNERMUTATE' } ) }) t.test('owner add <user> <pkg> no previous maintainers property from server', async t => { - result = '' - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - // retrieve user info from couchdb request - if (uri === '/-/user/org.couchdb.user:foo') { - return { - _id: 'org.couchdb.user:foo', - email: 'foo@github.com', - name: 'foo', - } - } else if (uri === '/@npmcli%2fno-owners-pkg/-rev/1-foobaaa1') { - return {} - } else { - t.fail(`unexpected fetch json call to uri: ${uri}`) - } - } - pacote.packument = async (spec, opts) => { - return { - _rev: '1-foobaaa1', - maintainers: null, - } - } - t.teardown(() => { - result = '' - npmFetch.json = noop - pacote.packument = noop + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { ...auth }, }) - - await owner.exec(['add', 'foo', '@npmcli/no-owners-pkg']) - t.equal(result, '+ foo (@npmcli/no-owners-pkg)', 'should output add result') + const username = 'foo' + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers: undefined, version: '1.0.0' }], + }) + registry.couchuser({ username }) + await registry.package({ manifest }) + registry.nock.put(`/${spec.escapedName}/-rev/${manifest._rev}`, body => { + t.match(body, { + _id: manifest._id, + _rev: manifest._rev, + maintainers: [{ name: username, email: '' }], + }) + return true + }).reply(200, {}) + await npm.exec('owner', ['add', username, packageName]) + t.equal(joinedOutput(), `+ ${username} (${packageName})`) }) t.test('owner add no user', async t => { - result = '' - t.teardown(() => { - result = '' - }) + const { npm } = await loadMockNpm(t) await t.rejects( - owner.exec(['add']), - owner.usage + npm.exec('owner', ['add']), + { code: 'EUSAGE' } ) }) -t.test('owner add no pkg global', async t => { - t.teardown(() => { - npm.config.set('global', false) +t.test('owner add <user> no pkg global', async t => { + const { npm } = await loadMockNpm(t, { + config: { global: true }, }) - npm.config.set('global', true) await t.rejects( - owner.exec(['add', 'gar']), - owner.usage + npm.exec('owner', ['add', 'foo']), + { code: 'EUSAGE' } ) }) t.test('owner add <user> no cwd package', async t => { - result = '' - t.teardown(() => { - result = '' - }) + const { npm } = await loadMockNpm(t) await t.rejects( - owner.exec(['add', 'foo']), - owner.usage + npm.exec('owner', ['add', 'foo']), + { code: 'EUSAGE' } ) }) t.test('owner rm <user> <pkg>', async t => { - t.plan(11) - - result = '' - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - // retrieve user info from couchdb request - if (uri === '/-/user/org.couchdb.user:ruyadorno') { - t.ok('should request user info') - t.match(opts, { ...npm.flatOptions }, 'should use expected opts') - return { - _id: 'org.couchdb.user:ruyadorno', - email: 'ruyadorno@hotmail.com', - name: 'ruyadorno', - } - } else if (uri === '/@npmcli%2fmap-workspaces/-rev/1-foobaaa1') { - t.ok('should put changed owner') - t.match(opts, { - ...npm.flatOptions, - method: 'PUT', - body: { - _rev: '1-foobaaa1', - }, - otp: '123456', - spec: { - name: '@npmcli/map-workspaces', - }, - }, 'should use expected opts') - t.same( - opts.body.maintainers, - npmcliMaintainers.filter(m => m.name !== 'ruyadorno'), - 'should contain expected new owners, removing requested user' - ) - return {} - } else { - t.fail(`unexpected fetch json call to: ${uri}`) - } - } - pacote.packument = async (spec, opts) => { - t.ok(opts.log, 'is passed a logger') - t.equal(spec.name, '@npmcli/map-workspaces', 'should use expect pkg name') - t.match( - opts, - { - ...npm.flatOptions, - fullMetadata: true, - }, - 'should forward expected options to pacote.packument' - ) - return { - _rev: '1-foobaaa1', - maintainers: npmcliMaintainers, - } - } - t.teardown(() => { - result = '' - npmFetch.json = noop - pacote.packument = noop + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { ...auth }, }) - - await owner.exec(['rm', 'ruyadorno', '@npmcli/map-workspaces']) - t.equal(result, '- ruyadorno (@npmcli/map-workspaces)', 'should output rm result') + const username = maintainers[0].name + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers, version: '1.0.0' }], + }) + registry.couchuser({ username }) + await registry.package({ manifest }) + registry.nock.put(`/${spec.escapedName}/-rev/${manifest._rev}`, body => { + t.match(body, { + _id: manifest._id, + _rev: manifest._rev, + maintainers: maintainers.slice(1), + }) + return true + }).reply(200, {}) + await npm.exec('owner', ['rm', username, packageName]) + t.equal(joinedOutput(), `- ${username} (${packageName})`) }) t.test('owner rm <user> <pkg> not a current owner', async t => { - t.plan(3) - - result = '' - log.info = (title, msg) => { - t.equal(title, 'owner rm', 'should log expected title') - t.equal(msg, 'Not a package owner: foo', 'should log.info not a package owner msg') - } - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - // retrieve user info from couchdb request - if (uri === '/-/user/org.couchdb.user:foo') { - return { - _id: 'org.couchdb.user:foo', - email: 'foo@github.com', - name: 'foo', - } - } else if (uri === '/@npmcli%2fmap-workspaces/-rev/1-foobaaa1') { - return {} - } else { - t.fail(`unexpected fetch json call to: ${uri}`) - } - } - pacote.packument = async (spec, opts) => { - return { - _rev: '1-foobaaa1', - maintainers: npmcliMaintainers, - } - } - t.teardown(() => { - result = '' - log.info = noop - npmFetch.json = noop - pacote.packument = noop + const { npm, logs } = await loadMockNpm(t, { + config: { ...auth }, }) - - await owner.exec(['rm', 'foo', '@npmcli/map-workspaces']) + const username = 'foo' + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers, version: '1.0.0' }], + }) + registry.couchuser({ username }) + await registry.package({ manifest }) + await npm.exec('owner', ['rm', username, packageName]) + t.match(logs.info, [['owner rm', `Not a package owner: ${username}`]]) }) t.test('owner rm <user> cwd package', async t => { - result = '' - readPackageNameResponse = '@npmcli/map-workspaces' - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - // retrieve user info from couchdb request - if (uri === '/-/user/org.couchdb.user:ruyadorno') { - return { - _id: 'org.couchdb.user:ruyadorno', - email: 'ruyadorno@hotmail.com', - name: 'ruyadorno', - } - } else if (uri === '/@npmcli%2fmap-workspaces/-rev/1-foobaaa1') { - return {} - } else { - t.fail(`unexpected fetch json call to uri: ${uri}`) - } - } - pacote.packument = async (spec, opts) => ({ - _rev: '1-foobaaa1', - maintainers: npmcliMaintainers, + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ name: packageName }), + }, + config: { ...auth }, }) - t.teardown(() => { - result = '' - readPackageNameResponse = null - npmFetch.json = noop - pacote.packument = noop + const username = maintainers[0].name + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - - await owner.exec(['rm', 'ruyadorno']) - t.equal(result, '- ruyadorno (@npmcli/map-workspaces)', 'should output rm result') + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers, version: '1.0.0' }], + }) + registry.couchuser({ username }) + await registry.package({ manifest }) + registry.nock.put(`/${spec.escapedName}/-rev/${manifest._rev}`, body => { + t.match(body, { + _id: manifest._id, + _rev: manifest._rev, + maintainers: maintainers.slice(1), + }) + return true + }).reply(200, {}) + await npm.exec('owner', ['rm', username]) + t.equal(joinedOutput(), `- ${username} (${packageName})`) }) t.test('owner rm <user> only user', async t => { - result = '' - readPackageNameResponse = 'ipt' - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - // retrieve user info from couchdb request - if (uri === '/-/user/org.couchdb.user:ruyadorno') { - return { - _id: 'org.couchdb.user:ruyadorno', - email: 'ruyadorno@hotmail.com', - name: 'ruyadorno', - } - } else { - t.fail(`unexpected fetch json call to uri: ${uri}`) - } - } - pacote.packument = async (spec, opts) => ({ - _rev: '1-foobaaa1', - maintainers: [{ - name: 'ruyadorno', - email: 'ruyadorno@hotmail.com', - }], + const { npm } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ name: packageName }), + }, + config: { ...auth }, }) - t.teardown(() => { - result = '' - readPackageNameResponse = null - npmFetch.json = noop - pacote.packument = noop + const username = maintainers[0].name + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers: maintainers.slice(0, 1), version: '1.0.0' }], + }) + registry.couchuser({ username }) + await registry.package({ manifest }) await t.rejects( - owner.exec(['rm', 'ruyadorno']), - { code: 'EOWNERRM', message: 'Cannot remove all owners of a package. Add someone else first.' }, - 'should throw unable to remove unique owner message' + npm.exec('owner', ['rm', username]), + { + code: 'EOWNERRM', + message: 'Cannot remove all owners of a package. Add someone else first.', + } ) }) t.test('owner rm no user', async t => { - result = '' - t.teardown(() => { - result = '' - }) - + const { npm } = await loadMockNpm(t) await t.rejects( - owner.exec(['rm']), - owner.usage + npm.exec('owner', ['rm']), + { code: 'EUSAGE' } ) }) t.test('owner rm no pkg global', async t => { - t.teardown(() => { - npm.config.set('global', false) + const { npm } = await loadMockNpm(t, { + config: { global: true }, }) - npm.config.set('global', true) - await t.rejects( - owner.exec(['rm', 'foo']), - owner.usage + npm.exec('owner', ['rm', 'foo']), + { code: 'EUSAGE' } ) }) t.test('owner rm <user> no cwd package', async t => { - result = '' - t.teardown(() => { - result = '' - }) - + const { npm } = await loadMockNpm(t) await t.rejects( - owner.exec(['rm', 'foo']), - owner.usage + npm.exec('owner', ['rm', 'foo']), + { code: 'EUSAGE' } ) }) -t.test('completion', async t => { - const testComp = async (argv, expect) => { - const res = await owner.completion({ conf: { argv: { remain: argv } } }) - t.strictSame(res, expect, argv.join(' ')) - } - - await Promise.all([ - testComp(['npm', 'foo'], []), - testComp(['npm', 'owner'], ['add', 'rm', 'ls']), - testComp(['npm', 'owner', 'add'], []), - testComp(['npm', 'owner', 'ls'], []), - testComp(['npm', 'owner', 'rm', 'foo'], []), - ]) - - // npm owner rm completion is async - t.test('completion npm owner rm', async t => { - t.plan(2) - readPackageNameResponse = '@npmcli/map-workspaces' - pacote.packument = async spec => { - t.equal(spec.name, readPackageNameResponse, 'should use package spec') - return { - maintainers: npmcliMaintainers, - } - } - t.teardown(() => { - readPackageNameResponse = null - pacote.packument = noop +t.test('workspaces', async t => { + t.test('owner no args --workspace', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: workspaceFixture, }) - - const res = await owner.completion({ conf: { argv: { remain: ['npm', 'owner', 'rm'] } } }) - t.strictSame(res, - ['nlf', 'ruyadorno', 'darcyclarke', 'isaacs'], - 'should return list of current owners' + npm.config.set('workspace', ['workspace-a']) + await t.rejects( + npm.exec('owner', []), + { code: 'EUSAGE' }, + 'rejects with usage' ) }) + t.test('owner ls implicit workspace', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: workspaceFixture, + globals: ({ prefix }) => ({ + 'process.cwd': () => path.join(prefix, 'workspace-a'), + }), + }) + await registryPackage(t, npm.config.get('registry'), 'workspace-a') + await npm.exec('owner', ['ls']) + t.match(joinedOutput(), maintainers.map(m => `${m.name} <${m.email}>`).join('\n')) + }) + + t.test('owner ls explicit workspace', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: workspaceFixture, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + npm.config.set('workspace', ['workspace-a']) + await registryPackage(t, npm.config.get('registry'), 'workspace-a') + await npm.exec('owner', ['ls']) + t.match(joinedOutput(), maintainers.map(m => `${m.name} <${m.email}>`).join('\n')) + }) + + t.test('owner ls <pkg> implicit workspace', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: workspaceFixture, + globals: ({ prefix }) => ({ + 'process.cwd': () => path.join(prefix, 'workspace-a'), + }), + }) + await registryPackage(t, npm.config.get('registry'), packageName) + await npm.exec('owner', ['ls', packageName]) + t.match(joinedOutput(), maintainers.map(m => `${m.name} <${m.email}>`).join('\n')) + }) + + t.test('owner ls <pkg> explicit workspace', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: workspaceFixture, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + npm.config.set('workspace', ['workspace-a']) + await registryPackage(t, npm.config.get('registry'), packageName) + await npm.exec('owner', ['ls', packageName]) + t.match(joinedOutput(), maintainers.map(m => `${m.name} <${m.email}>`).join('\n')) + }) + + t.test('owner add implicit workspace', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: workspaceFixture, + globals: ({ prefix }) => ({ + 'process.cwd': () => path.join(prefix, 'workspace-a'), + }), + }) + const username = 'foo' + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + + const manifest = registry.manifest({ + name: 'workspace-a', + packuments: [{ maintainers, version: '1.0.0' }], + }) + await registry.package({ manifest }) + registry.couchuser({ username }) + registry.nock.put(`/workspace-a/-rev/${manifest._rev}`, body => { + t.match(body, { + _id: manifest._id, + _rev: manifest._rev, + maintainers: [ + ...manifest.maintainers, + { name: username, email: '' }, + ], + }) + return true + }).reply(200, {}) + await npm.exec('owner', ['add', username]) + t.equal(joinedOutput(), `+ ${username} (workspace-a)`) + }) + + t.test('owner add --workspace', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: workspaceFixture, + }) + npm.config.set('workspace', ['workspace-a']) + const username = 'foo' + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + + const manifest = registry.manifest({ + name: 'workspace-a', + packuments: [{ maintainers, version: '1.0.0' }], + }) + await registry.package({ manifest }) + registry.couchuser({ username }) + registry.nock.put(`/workspace-a/-rev/${manifest._rev}`, body => { + t.match(body, { + _id: manifest._id, + _rev: manifest._rev, + maintainers: [ + ...manifest.maintainers, + { name: username, email: '' }, + ], + }) + return true + }).reply(200, {}) + await npm.exec('owner', ['add', username]) + t.equal(joinedOutput(), `+ ${username} (workspace-a)`) + }) + + t.test('owner rm --workspace', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: workspaceFixture, + globals: ({ prefix }) => ({ + 'process.cwd': () => path.join(prefix, 'workspace-a'), + }), + }) + const registry = new MockRegistry({ tap: t, registry: npm.config.get('registry') }) + + const username = maintainers[0].name + const manifest = registry.manifest({ + name: 'workspace-a', + packuments: [{ maintainers, version: '1.0.0' }], + }) + await registry.package({ manifest }) + registry.couchuser({ username }) + registry.nock.put(`/workspace-a/-rev/${manifest._rev}`, body => { + t.match(body, { + _id: manifest._id, + _rev: manifest._rev, + maintainers: maintainers.slice(1), + }) + return true + }).reply(200, {}) + await npm.exec('owner', ['rm', username]) + t.equal(joinedOutput(), `- ${username} (workspace-a)`) + }) +}) + +t.test('completion', async t => { + t.test('basic commands', async t => { + const { npm } = await loadMockNpm(t) + const owner = await npm.cmd('owner') + const testComp = async (argv, expect) => { + const res = await owner.completion({ conf: { argv: { remain: argv } } }) + t.strictSame(res, expect, argv.join(' ')) + } + + await Promise.all([ + testComp(['npm', 'foo'], []), + testComp(['npm', 'owner'], ['add', 'rm', 'ls']), + testComp(['npm', 'owner', 'add'], []), + testComp(['npm', 'owner', 'ls'], []), + testComp(['npm', 'owner', 'rm', 'foo'], []), + ]) + }) + + t.test('completion npm owner rm', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: { 'package.json': JSON.stringify({ name: packageName }) }, + }) + const owner = await npm.cmd('owner') + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers, version: '1.0.0' }], + }) + await registry.package({ manifest }) + const res = await owner.completion({ conf: { argv: { remain: ['npm', 'owner', 'rm'] } } }) + t.strictSame(res, maintainers.map(m => m.name), 'should return list of current owners') + }) + t.test('completion npm owner rm no cwd package', async t => { + const { npm } = await loadMockNpm(t) + const owner = await npm.cmd('owner') const res = await owner.completion({ conf: { argv: { remain: ['npm', 'owner', 'rm'] } } }) t.strictSame(res, [], 'should have no owners to autocomplete if not cwd package') - t.end() }) t.test('completion npm owner rm global', async t => { - t.teardown(() => { - npm.config.set('global', false) + const { npm } = await loadMockNpm(t, { + config: { global: true }, }) - npm.config.set('global', true) + const owner = await npm.cmd('owner') const res = await owner.completion({ conf: { argv: { remain: ['npm', 'owner', 'rm'] } } }) t.strictSame(res, [], 'should have no owners to autocomplete if global') - t.end() }) t.test('completion npm owner rm no owners found', async t => { - t.plan(2) - readPackageNameResponse = '@npmcli/map-workspaces' - pacote.packument = async spec => { - t.equal(spec.name, readPackageNameResponse, 'should use package spec') - return { - maintainers: [], - } - } - t.teardown(() => { - readPackageNameResponse = null - pacote.packument = noop + const { npm } = await loadMockNpm(t, { + prefixDir: { 'package.json': JSON.stringify({ name: packageName }) }, }) + const owner = await npm.cmd('owner') + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + const manifest = registry.manifest({ + name: packageName, + packuments: [{ maintainers: [], version: '1.0.0' }], + }) + await registry.package({ manifest }) const res = await owner.completion({ conf: { argv: { remain: ['npm', 'owner', 'rm'] } } }) t.strictSame(res, [], 'should return no owners if not found') }) - - t.end() }) diff --git a/test/lib/commands/pack.js b/test/lib/commands/pack.js index 51453da..199afc6 100644 --- a/test/lib/commands/pack.js +++ b/test/lib/commands/pack.js @@ -10,7 +10,7 @@ t.afterEach(t => { t.test('should pack current directory with no arguments', async t => { const { npm, outputs, logs } = await loadMockNpm(t, { - testdir: { + prefixDir: { 'package.json': JSON.stringify({ name: 'test-package', version: '1.0.0', @@ -27,7 +27,7 @@ t.test('should pack current directory with no arguments', async t => { t.test('follows pack-destination config', async t => { const { npm, outputs } = await loadMockNpm(t, { - testdir: { + prefixDir: { 'package.json': JSON.stringify({ name: 'test-package', version: '1.0.0', @@ -45,7 +45,7 @@ t.test('follows pack-destination config', async t => { t.test('should pack given directory for scoped package', async t => { const { npm, outputs } = await loadMockNpm(t, { - testdir: { + prefixDir: { 'package.json': JSON.stringify({ name: '@npm/test-package', version: '1.0.0', @@ -61,7 +61,7 @@ t.test('should pack given directory for scoped package', async t => { t.test('should log output as valid json', async t => { const { npm, outputs, logs } = await loadMockNpm(t, { - testdir: { + prefixDir: { 'package.json': JSON.stringify({ name: 'test-package', version: '1.0.0', @@ -77,9 +77,27 @@ t.test('should log output as valid json', async t => { t.ok(fs.statSync(path.resolve(npm.prefix, filename))) }) +t.test('should log scoped package output as valid json', async t => { + const { npm, outputs, logs } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify({ + name: '@myscope/test-package', + version: '1.0.0', + }), + }, + }) + process.chdir(npm.prefix) + npm.config.set('json', true) + await npm.exec('pack', []) + const filename = 'myscope-test-package-1.0.0.tgz' + t.matchSnapshot(outputs.map(JSON.parse), 'outputs as json') + t.matchSnapshot(logs.notice.map(([, m]) => m), 'logs pack contents') + t.ok(fs.statSync(path.resolve(npm.prefix, filename))) +}) + t.test('dry run', async t => { const { npm, outputs, logs } = await loadMockNpm(t, { - testdir: { + prefixDir: { 'package.json': JSON.stringify({ name: 'test-package', version: '1.0.0', @@ -97,7 +115,7 @@ t.test('dry run', async t => { t.test('invalid packument', async t => { const { npm, outputs } = await loadMockNpm(t, { - testdir: { + prefixDir: { 'package.json': '{}', }, }) @@ -111,7 +129,7 @@ t.test('invalid packument', async t => { t.test('workspaces', async t => { const loadWorkspaces = (t) => loadMockNpm(t, { - testdir: { + prefixDir: { 'package.json': JSON.stringify( { name: 'workspaces-test', diff --git a/test/lib/commands/ping.js b/test/lib/commands/ping.js index 19ba9d5..7720195 100644 --- a/test/lib/commands/ping.js +++ b/test/lib/commands/ping.js @@ -1,116 +1,67 @@ const t = require('tap') -const { fake: mockNpm } = require('../../fixtures/mock-npm') +const { load: loadMockNpm } = require('../../fixtures/mock-npm.js') +const MockRegistry = require('@npmcli/mock-registry') -t.test('pings', async t => { - t.plan(7) - - const registry = 'https://registry.npmjs.org' - let noticeCalls = 0 - const Ping = t.mock('../../../lib/commands/ping.js', { - '../../../lib/utils/ping.js': function (spec) { - t.ok(spec.log, 'is passed a logger') - t.equal(spec.registry, registry, 'passes flatOptions') - return {} - }, - 'proc-log': { - notice: (type, spec) => { - ++noticeCalls - if (noticeCalls === 1) { - t.equal(type, 'PING', 'should log a PING') - t.equal(spec, registry, 'should log the registry url') - } else { - t.equal(type, 'PONG', 'should log a PONG') - t.match(spec, /\d+ms/, 'should log the elapsed milliseconds') - } - }, - }, +t.test('no details', async t => { + const { npm, logs, joinedOutput } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - const npm = mockNpm({ - config: { registry }, - flatOptions: { registry }, - }) - const ping = new Ping(npm) - - await ping.exec([]) - t.equal(noticeCalls, 2, 'should have logged 2 lines') + registry.ping() + await npm.exec('ping', []) + t.match(logs.notice, [['PING', 'https://registry.npmjs.org/'], ['PONG', /[0-9]+ms/]]) + t.equal(joinedOutput(), '') }) -t.test('pings and logs details', async t => { - t.plan(9) - - const registry = 'https://registry.npmjs.org' - const details = { extra: 'data' } - let noticeCalls = 0 - const Ping = t.mock('../../../lib/commands/ping.js', { - '../../../lib/utils/ping.js': function (spec) { - t.ok(spec.log, 'is passed a logger') - t.equal(spec.registry, registry, 'passes flatOptions') - return details - }, - 'proc-log': { - notice: (type, spec) => { - ++noticeCalls - if (noticeCalls === 1) { - t.equal(type, 'PING', 'should log a PING') - t.equal(spec, registry, 'should log the registry url') - } else if (noticeCalls === 2) { - t.equal(type, 'PONG', 'should log a PONG') - t.match(spec, /\d+ms/, 'should log the elapsed milliseconds') - } else { - t.equal(type, 'PONG', 'should log a PONG') - const parsed = JSON.parse(spec) - t.match(parsed, details, 'should log JSON stringified details') - } - }, - }, +t.test('with details', async t => { + const { npm, logs, joinedOutput } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - const npm = mockNpm({ - config: { registry }, - flatOptions: { registry }, - }) - const ping = new Ping(npm) - - await ping.exec([]) - t.equal(noticeCalls, 3, 'should have logged 3 lines') + registry.ping({ body: { test: true } }) + await npm.exec('ping', []) + t.match(logs.notice, [ + ['PING', 'https://registry.npmjs.org/'], + ['PONG', /[0-9]+ms/], + ['PONG', '{\n "test": true\n}'], + ]) + t.match(joinedOutput(), '') }) -t.test('pings and returns json', async t => { - t.plan(10) - - const registry = 'https://registry.npmjs.org' - const details = { extra: 'data' } - let noticeCalls = 0 - const Ping = t.mock('../../../lib/commands/ping.js', { - '../../../lib/utils/ping.js': function (spec) { - t.ok(spec.log, 'is passed a logger') - t.equal(spec.registry, registry, 'passes flatOptions') - return details - }, - 'proc-log': { - notice: (type, spec) => { - ++noticeCalls - if (noticeCalls === 1) { - t.equal(type, 'PING', 'should log a PING') - t.equal(spec, registry, 'should log the registry url') - } else { - t.equal(type, 'PONG', 'should log a PONG') - t.match(spec, /\d+ms/, 'should log the elapsed milliseconds') - } - }, - }, +t.test('valid json', async t => { + const { npm, logs, joinedOutput } = await loadMockNpm(t, { + config: { json: true }, }) - const npm = mockNpm({ - config: { registry, json: true }, - flatOptions: { registry }, - output: function (spec) { - const parsed = JSON.parse(spec) - t.equal(parsed.registry, registry, 'returns the correct registry url') - t.match(parsed.details, details, 'prints returned details') - t.type(parsed.time, 'number', 'returns time as a number') - }, + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.ping() + await npm.exec('ping', []) + t.match(logs.notice, [['PING', 'https://registry.npmjs.org/'], ['PONG', /[0-9]+ms/]]) + t.match(JSON.parse(joinedOutput()), { + registry: npm.config.get('registry'), + time: /[0-9]+/, + details: {}, + }) +}) + +t.test('invalid json', async t => { + const { npm, logs, joinedOutput } = await loadMockNpm(t, { + config: { json: true }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.ping({ body: '{not: real"json]' }) + await npm.exec('ping', []) + t.match(logs.notice, [['PING', 'https://registry.npmjs.org/'], ['PONG', /[0-9]+ms/]]) + t.match(JSON.parse(joinedOutput()), { + registry: npm.config.get('registry'), + time: /[0-9]+/, + details: {}, }) - const ping = new Ping(npm) - - await ping.exec([]) - t.equal(noticeCalls, 2, 'should have logged 2 lines') }) diff --git a/test/lib/commands/profile.js b/test/lib/commands/profile.js index 3d55a37..09fd08c 100644 --- a/test/lib/commands/profile.js +++ b/test/lib/commands/profile.js @@ -19,7 +19,6 @@ const npm = mockNpm({ }, }) const mocks = { - ansistyles: { bright: a => a }, npmlog: { gauge: { show () {} }, }, @@ -41,11 +40,6 @@ const mocks = { .join('\n') } }, - '../../../lib/utils/pulse-till-done.js': { - withPromise: async a => a, - }, - '../../../lib/utils/otplease.js': async (opts, fn) => fn(opts), - '../../../lib/utils/usage.js': () => 'usage instructions', '../../../lib/utils/read-user-info.js': { async password () {}, async otp () {}, diff --git a/test/lib/commands/publish.js b/test/lib/commands/publish.js index 52d4c1b..496c023 100644 --- a/test/lib/commands/publish.js +++ b/test/lib/commands/publish.js @@ -1,555 +1,394 @@ const t = require('tap') -const { fake: mockNpm } = require('../../fixtures/mock-npm') +const { load: loadMockNpm } = require('../../fixtures/mock-npm') +const MockRegistry = require('@npmcli/mock-registry') +const pacote = require('pacote') +const Arborist = require('@npmcli/arborist') +const path = require('path') const fs = require('fs') -const log = require('../../../lib/utils/log-shim') +const npa = require('npm-package-arg') -// The way we set loglevel is kind of convoluted, and there is no way to affect -// it from these tests, which only interact with lib/publish.js, which assumes -// that the code that is requiring and calling lib/publish.js has already -// taken care of the loglevel -const _level = log.level -t.beforeEach(() => (log.level = 'silent')) -t.teardown(() => (log.level = _level)) +const pkg = 'test-package' +const token = 'test-auth-token' +const auth = { '//registry.npmjs.org/:_authToken': token } +const alternateRegistry = 'https://other.registry.npmjs.org' +const basic = Buffer.from('test-user:test-password').toString('base64') -t.cleanSnapshot = data => { - return data.replace(/^ *"gitHead": .*$\n/gm, '') +const pkgJson = { + name: pkg, + description: 'npm test package', + version: '1.0.0', } -const { definitions } = require('../../../lib/utils/config') -const defaults = Object.entries(definitions).reduce((defaults, [key, def]) => { - defaults[key] = def.default - return defaults -}, {}) +t.cleanSnapshot = data => { + return data.replace(/shasum:.*/g, 'shasum:{sha}') + .replace(/integrity:.*/g, 'integrity:{sha}') + .replace(/"shasum": ".*",/g, '"shasum": "{sha}",') + .replace(/"integrity": ".*",/g, '"integrity": "{sha}",') +} -t.test( - /* eslint-disable-next-line max-len */ - 'should publish with libnpmpublish, passing through flatOptions and respecting publishConfig.registry', - async t => { - t.plan(7) - - const registry = 'https://some.registry' - const publishConfig = { registry } - const testDir = t.testdir({ - 'package.json': JSON.stringify( - { - name: 'my-cool-pkg', +t.test('respects publishConfig.registry, runs appropriate scripts', async t => { + const { npm, joinedOutput, prefix } = await loadMockNpm(t, { + config: { + loglevel: 'silent', + [`${alternateRegistry.slice(6)}/:_authToken`]: 'test-other-token', + }, + prefixDir: { + 'package.json': JSON.stringify({ + ...pkgJson, + scripts: { + prepublishOnly: 'touch scripts-prepublishonly', + prepublish: 'touch scripts-prepublish', // should NOT run this one + publish: 'touch scripts-publish', + postpublish: 'touch scripts-postpublish', + }, + publishConfig: { registry: alternateRegistry }, + }, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + const registry = new MockRegistry({ + tap: t, + registry: alternateRegistry, + authorization: 'test-other-token', + }) + registry.nock.put(`/${pkg}`, body => { + return t.match(body, { + _id: pkg, + name: pkg, + 'dist-tags': { latest: '1.0.0' }, + access: null, + versions: { + '1.0.0': { + name: pkg, version: '1.0.0', - publishConfig, - }, - null, - 2 - ), - }) - - const Publish = t.mock('../../../lib/commands/publish.js', { - // verify that we do NOT remove publishConfig if it was there originally - // and then removed during the script/pack process - libnpmpack: async () => { - fs.writeFileSync( - `${testDir}/package.json`, - JSON.stringify({ - name: 'my-cool-pkg', - version: '1.0.0', - }) - ) - return Buffer.from('') - }, - libnpmpublish: { - publish: (manifest, tarData, opts) => { - t.match(manifest, { name: 'my-cool-pkg', version: '1.0.0' }, 'gets manifest') - t.type(tarData, Buffer, 'tarData is a buffer') - t.ok(opts, 'gets opts object') - t.ok(opts.log, 'gets passed a logger') - t.same(opts.customValue, true, 'flatOptions values are passed through') - t.same(opts.registry, registry, 'publishConfig.registry is passed through') + _id: `${pkg}@1.0.0`, + dist: { + shasum: /\.*/, + tarball: `http:${alternateRegistry.slice(6)}/test-package/-/test-package-1.0.0.tgz`, + }, + publishConfig: { + registry: alternateRegistry, + }, }, }, - }) - const npm = mockNpm({ - flatOptions: { - customValue: true, - workspacesEnabled: true, + _attachments: { + [`${pkg}-1.0.0.tgz`]: {}, }, }) - npm.config.getCredentialsByURI = uri => { - t.same(uri, registry, 'gets credentials for expected registry') - return { token: 'some.registry.token' } - } - const publish = new Publish(npm) - - await publish.exec([testDir]) - } -) + }).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'new package version') + t.equal(fs.existsSync(path.join(prefix, 'scripts-prepublishonly')), true, 'ran prepublishOnly') + t.equal(fs.existsSync(path.join(prefix, 'scripts-prepublish')), false, 'did not run prepublish') + t.equal(fs.existsSync(path.join(prefix, 'scripts-publish')), true, 'ran publish') + t.equal(fs.existsSync(path.join(prefix, 'scripts-postpublish')), true, 'ran postpublish') +}) t.test('re-loads publishConfig.registry if added during script process', async t => { - t.plan(6) - const registry = 'https://some.registry' - const publishConfig = { registry } - const testDir = t.testdir({ - 'package.json': JSON.stringify( - { - name: 'my-cool-pkg', - version: '1.0.0', - }, - null, - 2 - ), - }) - - const Publish = t.mock('../../../lib/commands/publish.js', { - libnpmpack: async () => { - fs.writeFileSync( - `${testDir}/package.json`, - JSON.stringify({ - name: 'my-cool-pkg', - version: '1.0.0', - publishConfig, - }) - ) - return Buffer.from('') + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + [`${alternateRegistry.slice(6)}/:_authToken`]: 'test-other-token', }, - libnpmpublish: { - publish: (manifest, tarData, opts) => { - t.match(manifest, { name: 'my-cool-pkg', version: '1.0.0' }, 'gets manifest') - t.type(tarData, Buffer, 'tarData is a buffer') - t.ok(opts, 'gets opts object') - t.ok(opts.log, 'gets passed a logger') - t.same(opts.registry, registry, 'publishConfig.registry is passed through') - }, - }, - }) - const npm = mockNpm() - npm.config.getCredentialsByURI = uri => { - t.same(uri, registry, 'gets credentials for expected registry') - return { token: 'some.registry.token' } - } - const publish = new Publish(npm) - - await publish.exec([testDir]) -}) - -t.test('if loglevel=info and json, should not output package contents', async t => { - t.plan(3) - - const testDir = t.testdir({ - 'package.json': JSON.stringify( - { - name: 'my-cool-pkg', - version: '1.0.0', - }, - null, - 2 - ), - }) - - log.level = 'info' - const Publish = t.mock('../../../lib/commands/publish.js', { - '../../../lib/utils/tar.js': { - getContents: () => ({ - id: 'someid', + prefixDir: { + 'package.json': JSON.stringify({ + ...pkgJson, + scripts: { + prepare: 'cp new.json package.json', + }, + }, null, 2), + 'new.json': JSON.stringify({ + ...pkgJson, + publishConfig: { registry: alternateRegistry }, }), - logTar: () => { - t.fail('logTar is not called in json mode') - }, - }, - libnpmpublish: { - publish: () => { - t.pass('publish called') - }, }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), }) - const npm = mockNpm({ - config: { json: true }, - output: () => { - t.pass('output is called') - }, + const registry = new MockRegistry({ + tap: t, + registry: alternateRegistry, + authorization: 'test-other-token', }) - npm.config.getCredentialsByURI = uri => { - t.same(uri, npm.config.get('registry'), 'gets credentials for expected registry') - return { token: 'some.registry.token' } - } - const publish = new Publish(npm) - - await publish.exec([testDir]) + registry.nock.put(`/${pkg}`, body => { + return t.match(body, { + _id: pkg, + name: pkg, + 'dist-tags': { latest: '1.0.0' }, + access: null, + versions: { + '1.0.0': { + name: pkg, + version: '1.0.0', + _id: `${pkg}@1.0.0`, + dist: { + shasum: /\.*/, + tarball: `http:${alternateRegistry.slice(6)}/test-package/-/test-package-1.0.0.tgz`, + }, + publishConfig: { + registry: alternateRegistry, + }, + }, + }, + _attachments: { + [`${pkg}-1.0.0.tgz`]: {}, + }, + }) + }).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'new package version') }) -t.test( - /* eslint-disable-next-line max-len */ - 'if loglevel=silent and dry-run, should not output package contents or publish or validate credentials, should log tarball contents', - async t => { - t.plan(1) +t.test('json', async t => { + const { joinedOutput, npm, logs } = await loadMockNpm(t, { + config: { + json: true, + ...auth, + }, + prefixDir: { + 'package.json': JSON.stringify(pkgJson, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, + }) + registry.nock.put(`/${pkg}`).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(logs.notice) + t.matchSnapshot(joinedOutput(), 'new package json') +}) - const testDir = t.testdir({ - 'package.json': JSON.stringify( - { - name: 'my-cool-pkg', - version: '1.0.0', - }, - null, - 2 - ), - }) - - const Publish = t.mock('../../../lib/commands/publish.js', { - '../../../lib/utils/tar.js': { - getContents: () => ({ - id: 'someid', - }), - logTar: () => { - t.pass('logTar is called') - }, - }, - libnpmpublish: { - publish: () => { - throw new Error('should not call libnpmpublish in dry run') - }, - }, - }) - const npm = mockNpm({ - config: { 'dry-run': true }, - output: () => { - throw new Error('should not output in dry run mode') - }, - }) - npm.config.getCredentialsByURI = () => { - throw new Error('should not call getCredentialsByURI in dry run') - } - - const publish = new Publish(npm) - - await publish.exec([testDir]) - } -) - -t.test( - /* eslint-disable-next-line max-len */ - 'if loglevel=info and dry-run, should not publish, should log package contents and log tarball contents', - async t => { - t.plan(2) - - const testDir = t.testdir({ - 'package.json': JSON.stringify( - { - name: 'my-cool-pkg', - version: '1.0.0', - }, - null, - 2 - ), - }) - - log.level = 'info' - const Publish = t.mock('../../../lib/commands/publish.js', { - '../../../lib/utils/tar.js': { - getContents: () => ({ - id: 'someid', - }), - logTar: () => { - t.pass('logTar is called') - }, - }, - libnpmpublish: { - publish: () => { - throw new Error('should not call libnpmpublish in dry run') - }, - }, - }) - const npm = mockNpm({ - config: { 'dry-run': true }, - output: () => { - t.pass('output fn is called') - }, - }) - npm.config.getCredentialsByURI = () => { - throw new Error('should not call getCredentialsByURI in dry run') - } - const publish = new Publish(npm) - - await publish.exec([testDir]) - } -) +t.test('dry-run', async t => { + const { joinedOutput, npm, logs } = await loadMockNpm(t, { + config: { + 'dry-run': true, + ...auth, + }, + prefixDir: { + 'package.json': JSON.stringify(pkgJson, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + await npm.exec('publish', []) + t.equal(joinedOutput(), `+ ${pkg}@1.0.0`) + t.matchSnapshot(logs.notice) +}) t.test('shows usage with wrong set of arguments', async t => { t.plan(1) const Publish = t.mock('../../../lib/commands/publish.js') - const publish = new Publish({}) + const publish = new Publish({ config: { validate: () => {} } }) await t.rejects(publish.exec(['a', 'b', 'c']), publish.usage) }) t.test('throws when invalid tag', async t => { - t.plan(1) - - const Publish = t.mock('../../../lib/commands/publish.js') - const npm = mockNpm({ - config: { tag: '0.0.13' }, - }) - const publish = new Publish(npm) - - await t.rejects( - publish.exec([]), - /Tag name must not be a valid SemVer range: /, - 'throws when tag name is a valid SemVer range' - ) -}) - -t.test('can publish a tarball', async t => { - t.plan(4) - - const testDir = t.testdir({ - tarball: {}, - package: { - 'package.json': JSON.stringify({ - name: 'my-cool-tarball', - version: '1.2.3', - }), - }, - }) - const tar = require('tar') - tar.c( - { - cwd: testDir, - file: `${testDir}/tarball/package.tgz`, - sync: true, - }, - ['package'] - ) - - const tarFile = fs.readFileSync(`${testDir}/tarball/package.tgz`) - const Publish = t.mock('../../../lib/commands/publish.js', { - libnpmpublish: { - publish: (manifest, tarData, opts) => { - t.ok(opts.log, 'gets passed a logger') - t.match( - manifest, - { - name: 'my-cool-tarball', - version: '1.2.3', - }, - 'sent manifest to lib pub' - ) - t.strictSame(tarData, tarFile, 'sent the tarball data to lib pub') - }, - }, - }) - const npm = mockNpm() - npm.config.getCredentialsByURI = uri => { - t.same(uri, npm.config.get('registry'), 'gets credentials for expected registry') - return { token: 'some.registry.token' } - } - const publish = new Publish(npm) - - await publish.exec([`${testDir}/tarball/package.tgz`]) -}) - -t.test('should check auth for default registry', async t => { - t.plan(2) - const npm = mockNpm() - const registry = npm.config.get('registry') - const errorMessage = `This command requires you to be logged in to ${registry}` - const Publish = t.mock('../../../lib/commands/publish.js') - npm.config.getCredentialsByURI = uri => { - t.same(uri, npm.config.get('registry'), 'gets credentials for expected registry') - return {} - } - const publish = new Publish(npm) - - await t.rejects( - publish.exec([]), - { message: errorMessage, code: 'ENEEDAUTH' }, - 'throws when not logged in' - ) -}) - -t.test('should check auth for configured registry', async t => { - t.plan(2) - const registry = 'https://some.registry' - const errorMessage = 'This command requires you to be logged in to https://some.registry' - const Publish = t.mock('../../../lib/commands/publish.js') - const npm = mockNpm({ - flatOptions: { registry }, - }) - npm.config.getCredentialsByURI = uri => { - t.same(uri, registry, 'gets credentials for expected registry') - return {} - } - const publish = new Publish(npm) - - await t.rejects( - publish.exec([]), - { message: errorMessage, code: 'ENEEDAUTH' }, - 'throws when not logged in' - ) -}) - -t.test('should check auth for scope specific registry', async t => { - t.plan(2) - const registry = 'https://some.registry' - const errorMessage = 'This command requires you to be logged in to https://some.registry' - const testDir = t.testdir({ - 'package.json': JSON.stringify( - { - name: '@npm/my-cool-pkg', - version: '1.0.0', - }, - null, - 2 - ), - }) - - const Publish = t.mock('../../../lib/commands/publish.js') - const npm = mockNpm({ - flatOptions: { '@npm:registry': registry }, - }) - npm.config.getCredentialsByURI = uri => { - t.same(uri, registry, 'gets credentials for expected registry') - return {} - } - const publish = new Publish(npm) - - await t.rejects( - publish.exec([testDir]), - { message: errorMessage, code: 'ENEEDAUTH' }, - 'throws when not logged in' - ) -}) - -t.test('should use auth for scope specific registry', async t => { - t.plan(4) - const registry = 'https://some.registry' - const testDir = t.testdir({ - 'package.json': JSON.stringify( - { - name: '@npm/my-cool-pkg', - version: '1.0.0', - }, - null, - 2 - ), - }) - - const Publish = t.mock('../../../lib/commands/publish.js', { - libnpmpublish: { - publish: (manifest, tarData, opts) => { - t.ok(opts, 'gets opts object') - t.ok(opts.log, 'gets passed a logger') - t.same(opts['@npm:registry'], registry, 'scope specific registry is passed through') - }, - }, - }) - const npm = mockNpm({ - flatOptions: { '@npm:registry': registry }, - }) - npm.config.getCredentialsByURI = uri => { - t.same(uri, registry, 'gets credentials for expected registry') - return { token: 'some.registry.token' } - } - const publish = new Publish(npm) - - await publish.exec([testDir]) -}) - -t.test('read registry only from publishConfig', async t => { - t.plan(4) - - const registry = 'https://some.registry' - const publishConfig = { registry } - const testDir = t.testdir({ - 'package.json': JSON.stringify( - { - name: 'my-cool-pkg', - version: '1.0.0', - publishConfig, - }, - null, - 2 - ), - }) - - const Publish = t.mock('../../../lib/commands/publish.js', { - libnpmpublish: { - publish: (manifest, tarData, opts) => { - t.ok(opts.log, 'gets passed a logger') - t.match(manifest, { name: 'my-cool-pkg', version: '1.0.0' }, 'gets manifest') - t.same(opts.registry, registry, 'publishConfig is passed through') - }, - }, - }) - const npm = mockNpm() - npm.config.getCredentialsByURI = uri => { - t.same(uri, registry, 'gets credentials for expected registry') - return { token: 'some.registry.token' } - } - const publish = new Publish(npm) - - await publish.exec([testDir]) -}) - -t.test('able to publish after if encountered multiple configs', async t => { - t.plan(3) - - const registry = 'https://some.registry' - const tag = 'better-tag' - const publishConfig = { registry } - const testDir = t.testdir({ - 'package.json': JSON.stringify( - { - name: 'my-cool-pkg', - version: '1.0.0', - publishConfig, - }, - null, - 2 - ), - }) - - const configList = [defaults] - configList.unshift( - Object.assign(Object.create(configList[0]), { - registry: `https://other.registry`, - tag: 'some-tag', - }) - ) - configList.unshift(Object.assign(Object.create(configList[0]), { tag })) - - const Publish = t.mock('../../../lib/commands/publish.js', { - libnpmpublish: { - publish: (manifest, tarData, opts) => { - t.ok(opts.log, 'gets passed a logger') - t.same(opts.defaultTag, tag, 'gets option for expected tag') - }, - }, - }) - const publish = new Publish({ - // what would be flattened by the configList created above - flatOptions: { - defaultTag: 'better-tag', - registry: 'https://other.registry', - }, + const { npm } = await loadMockNpm(t, { config: { - get: key => configList[0][key], - list: configList, - getCredentialsByURI: uri => { - t.same(uri, registry, 'gets credentials for expected registry') - return { token: 'some.registry.token' } - }, + tag: '0.0.13', + }, + prefixDir: { + 'package.json': JSON.stringify(pkgJson, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + await t.rejects( + npm.exec('publish', []), + { message: 'Tag name must not be a valid SemVer range: 0.0.13' } + ) +}) + +t.test('tarball', async t => { + const { npm, joinedOutput, logs, home } = await loadMockNpm(t, { + config: { + 'fetch-retries': 0, + ...auth, + }, + homeDir: { + 'package.json': JSON.stringify({ + name: 'test-tar-package', + description: 'this was from a tarball', + version: '1.0.0', + }, null, 2), + 'index.js': 'console.log("hello world"}', }, }) + const tarball = await pacote.tarball(home, { Arborist }) + const tarFilename = path.join(home, 'tarball.tgz') + fs.writeFileSync(tarFilename, tarball) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, + }) + registry.nock.put('/test-tar-package', body => { + return t.match(body, { + name: 'test-tar-package', + }) + }).reply(200, {}) + await npm.exec('publish', [tarFilename]) + t.matchSnapshot(logs.notice) + t.matchSnapshot(joinedOutput(), 'new package json') +}) - await publish.exec([testDir]) +t.test('no auth default registry', async t => { + const { npm } = await loadMockNpm(t, { + prefixDir: { + 'package.json': JSON.stringify(pkgJson, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + await t.rejects( + npm.exec('publish', []), + { + message: 'This command requires you to be logged in to https://registry.npmjs.org/', + code: 'ENEEDAUTH', + } + ) +}) + +t.test('no auth dry-run', async t => { + const { npm, joinedOutput, logs } = await loadMockNpm(t, { + config: { + 'dry-run': true, + }, + prefixDir: { + 'package.json': JSON.stringify(pkgJson, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput()) + t.matchSnapshot(logs.warn, 'warns about auth being needed') +}) + +t.test('no auth for configured registry', async t => { + const { npm } = await loadMockNpm(t, { + config: { + registry: alternateRegistry, + ...auth, + }, + prefixDir: { + 'package.json': JSON.stringify(pkgJson, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + await t.rejects( + npm.exec('publish', []), + { + message: `This command requires you to be logged in to ${alternateRegistry}`, + code: 'ENEEDAUTH', + } + ) +}) + +t.test('no auth for scope configured registry', async t => { + const { npm } = await loadMockNpm(t, { + config: { + '@npm:registry': alternateRegistry, + ...auth, + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: '@npm/test-package', + version: '1.0.0', + }, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + await t.rejects( + npm.exec('publish', []), + { + message: `This command requires you to be logged in to ${alternateRegistry}`, + code: 'ENEEDAUTH', + } + ) +}) + +t.test('has token auth for scope configured registry', async t => { + const spec = npa('@npm/test-package') + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { + '@npm:registry': alternateRegistry, + [`${alternateRegistry.slice(6)}/:_authToken`]: 'test-scope-token', + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: '@npm/test-package', + version: '1.0.0', + }, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + const registry = new MockRegistry({ + tap: t, + registry: alternateRegistry, + authorization: 'test-scope-token', + }) + registry.nock.put(`/${spec.escapedName}`, body => { + return t.match(body, { name: '@npm/test-package' }) + }).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'new package version') +}) + +t.test('has mTLS auth for scope configured registry', async t => { + const spec = npa('@npm/test-package') + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { + '@npm:registry': alternateRegistry, + [`${alternateRegistry.slice(6)}/:certfile`]: '/some.cert', + [`${alternateRegistry.slice(6)}/:keyfile`]: '/some.key', + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: '@npm/test-package', + version: '1.0.0', + }, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + const registry = new MockRegistry({ + tap: t, + registry: alternateRegistry, + }) + registry.nock.put(`/${spec.escapedName}`, body => { + return t.match(body, { name: '@npm/test-package' }) + }).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'new package version') }) t.test('workspaces', t => { - const testDir = t.testdir({ + const dir = { 'package.json': JSON.stringify( { - name: 'my-cool-pkg', - version: '1.0.0', - workspaces: ['workspace-a', 'workspace-b', 'workspace-c'], - }, - null, - 2 - ), + ...pkgJson, + workspaces: ['workspace-a', 'workspace-b', 'workspace-c', 'workspace-p'], + }, null, 2), 'workspace-a': { 'package.json': JSON.stringify({ name: 'workspace-a', @@ -570,310 +409,383 @@ t.test('workspaces', t => { version: '1.2.3-n', }), }, - }) - - const publishes = [] - const outputs = [] - t.beforeEach(() => { - npm.config.set('json', false) - outputs.length = 0 - publishes.length = 0 - }) - const Publish = t.mock('../../../lib/commands/publish.js', { - '../../../lib/utils/tar.js': { - getContents: manifest => ({ - id: manifest._id, + 'workspace-p': { + 'package.json': JSON.stringify({ + name: 'workspace-p', + version: '1.2.3-p', + private: true, }), - logTar: () => {}, }, - libnpmpublish: { - publish: (manifest, tarballData, opts) => { - publishes.push(manifest) - }, - }, - }) - const npm = mockNpm({ - output: o => { - outputs.push(o) - }, - }) - npm.localPrefix = testDir - npm.config.getCredentialsByURI = uri => { - return { token: 'some.registry.token' } } - const publish = new Publish(npm) - t.test('all workspaces', async t => { - log.level = 'info' - await publish.execWorkspaces([], []) - t.matchSnapshot(publishes, 'should publish all workspaces') - t.matchSnapshot(outputs, 'should output all publishes') + t.test('all workspaces - no color', async t => { + const { npm, joinedOutput, logs } = await loadMockNpm(t, { + config: { + color: false, + ...auth, + workspaces: true, + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + prefixDir: dir, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, + }) + registry.nock + .put('/workspace-a', body => { + return t.match(body, { name: 'workspace-a' }) + }).reply(200, {}) + .put('/workspace-b', body => { + return t.match(body, { name: 'workspace-b' }) + }).reply(200, {}) + .put('/workspace-n', body => { + return t.match(body, { name: 'workspace-n' }) + }).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'all public workspaces') + t.matchSnapshot(logs.warn, 'warns about skipped private workspace') }) - t.test('one workspace', async t => { - log.level = 'info' - await publish.execWorkspaces([], ['workspace-a']) - t.matchSnapshot(publishes, 'should publish given workspace') - t.matchSnapshot(outputs, 'should output one publish') + t.test('all workspaces - color', async t => { + const { npm, joinedOutput, logs } = await loadMockNpm(t, { + config: { + ...auth, + color: 'always', + workspaces: true, + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + prefixDir: dir, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, + }) + registry.nock + .put('/workspace-a', body => { + return t.match(body, { name: 'workspace-a' }) + }).reply(200, {}) + .put('/workspace-b', body => { + return t.match(body, { name: 'workspace-b' }) + }).reply(200, {}) + .put('/workspace-n', body => { + return t.match(body, { name: 'workspace-n' }) + }).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'all public workspaces') + t.matchSnapshot(logs.warn, 'warns about skipped private workspace in color') + }) + + t.test('one workspace - success', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { + ...auth, + workspace: ['workspace-a'], + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + prefixDir: dir, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, + }) + registry.nock + .put('/workspace-a', body => { + return t.match(body, { name: 'workspace-a' }) + }).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'single workspace') + }) + + t.test('one workspace - failure', async t => { + const { npm } = await loadMockNpm(t, { + config: { + ...auth, + workspace: ['workspace-a'], + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + prefixDir: dir, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, + }) + registry.nock + .put('/workspace-a', body => { + return t.match(body, { name: 'workspace-a' }) + }).reply(404, {}) + await t.rejects(npm.exec('publish', []), { code: 'E404' }) }) t.test('invalid workspace', async t => { - await t.rejects(publish.execWorkspaces([], ['workspace-x']), /No workspaces found/) - await t.rejects(publish.execWorkspaces([], ['workspace-x']), /workspace-x/) + const { npm } = await loadMockNpm(t, { + config: { + ...auth, + workspace: ['workspace-x'], + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + prefixDir: dir, + }) + await t.rejects( + npm.exec('publish', []), + { message: 'No workspaces found:\n --workspace=workspace-x' } + ) }) t.test('json', async t => { - log.level = 'info' - npm.config.set('json', true) - await publish.execWorkspaces([], []) - t.matchSnapshot(publishes, 'should publish all workspaces') - t.matchSnapshot(outputs, 'should output all publishes as json') - }) - t.end() -}) - -t.test('private workspaces', async t => { - const testDir = t.testdir({ - 'package.json': JSON.stringify({ - name: 'workspaces-project', - version: '1.0.0', - workspaces: ['packages/*'], - }), - packages: { - a: { - 'package.json': JSON.stringify({ - name: '@npmcli/a', - version: '1.0.0', - private: true, - }), + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { + ...auth, + workspaces: true, + json: true, }, - b: { - 'package.json': JSON.stringify({ - name: '@npmcli/b', - version: '1.0.0', - }), - }, - }, - }) - - const publishes = [] - const outputs = [] - t.beforeEach(() => { - npm.config.set('json', false) - outputs.length = 0 - publishes.length = 0 - }) - const mocks = { - '../../../lib/utils/tar.js': { - getContents: manifest => ({ - id: manifest._id, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, }), - logTar: () => {}, - }, - libnpmpublish: { - publish: (manifest, tarballData, opts) => { - if (manifest.private) { - throw Object.assign(new Error('private pkg'), { code: 'EPRIVATE' }) - } - publishes.push(manifest) - }, - }, - } - const npm = mockNpm({ - output: o => { - outputs.push(o) - }, - }) - npm.localPrefix = testDir - npm.config.getCredentialsByURI = uri => { - return { token: 'some.registry.token' } - } - - t.test('with color', async t => { - t.plan(4) - - log.level = 'info' - const Publish = t.mock('../../../lib/commands/publish.js', { - ...mocks, - 'proc-log': { - notice () {}, - verbose () {}, - warn (title, msg) { - t.equal(title, 'publish', 'should use publish warn title') - t.match( - msg, - /* eslint-disable-next-line max-len */ - 'Skipping workspace \u001b[32m@npmcli/a\u001b[39m, marked as \u001b[1mprivate\u001b[22m', - 'should display skip private workspace warn msg' - ) - }, - }, + prefixDir: dir, }) - const publish = new Publish(npm) - - npm.color = true - await publish.execWorkspaces([], []) - t.matchSnapshot(publishes, 'should publish all non-private workspaces') - t.matchSnapshot(outputs, 'should output all publishes') - npm.color = false - }) - - t.test('colorless', async t => { - t.plan(4) - - log.level = 'info' - const Publish = t.mock('../../../lib/commands/publish.js', { - ...mocks, - 'proc-log': { - notice () {}, - verbose () {}, - warn (title, msg) { - t.equal(title, 'publish', 'should use publish warn title') - t.equal( - msg, - 'Skipping workspace @npmcli/a, marked as private', - 'should display skip private workspace warn msg' - ) - }, - }, + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, }) - const publish = new Publish(npm) - - await publish.execWorkspaces([], []) - t.matchSnapshot(publishes, 'should publish all non-private workspaces') - t.matchSnapshot(outputs, 'should output all publishes') + registry.nock + .put('/workspace-a', body => { + return t.match(body, { name: 'workspace-a' }) + }).reply(200, {}) + .put('/workspace-b', body => { + return t.match(body, { name: 'workspace-b' }) + }).reply(200, {}) + .put('/workspace-n', body => { + return t.match(body, { name: 'workspace-n' }) + }).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'all workspaces in json') }) - - t.test('unexpected error', async t => { - t.plan(2) - - const Publish = t.mock('../../../lib/commands/publish.js', { - ...mocks, - libnpmpublish: { - publish: (manifest, tarballData, opts) => { - if (manifest.private) { - throw new Error('ERR') - } - t.ok(opts.log, 'gets passed a logger') - publishes.push(manifest) - }, - }, - 'proc-log': { - notice (__, msg) { - t.match(msg, 'Publishing to https://registry.npmjs.org/') - }, - verbose () {}, - }, - }) - const publish = new Publish(npm) - - await t.rejects(publish.execWorkspaces([], []), /ERR/, 'should throw unexpected error') - }) - t.end() }) -t.test('runs correct lifecycle scripts', async t => { - t.plan(5) - - const testDir = t.testdir({ - 'package.json': JSON.stringify( - { - name: 'my-cool-pkg', - version: '1.0.0', +t.test('ignore-scripts', async t => { + const { npm, joinedOutput, prefix } = await loadMockNpm(t, { + config: { + ...auth, + 'ignore-scripts': true, + }, + prefixDir: { + 'package.json': JSON.stringify({ + ...pkgJson, scripts: { - prepublishOnly: 'echo test prepublishOnly', - prepublish: 'echo test prepublish', // should NOT run this one - publish: 'echo test publish', - postpublish: 'echo test postpublish', + prepublishOnly: 'touch scripts-prepublishonly', + prepublish: 'touch scripts-prepublish', // should NOT run this one + publish: 'touch scripts-publish', + postpublish: 'touch scripts-postpublish', }, - }, - null, - 2 - ), + }, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), }) - - const scripts = [] - log.level = 'info' - const Publish = t.mock('../../../lib/commands/publish.js', { - '@npmcli/run-script': args => { - scripts.push(args) - }, - '../../../lib/utils/tar.js': { - getContents: () => ({ - id: 'someid', - }), - logTar: () => { - t.pass('logTar is called') - }, - }, - libnpmpublish: { - publish: () => { - t.pass('publish called') - }, - }, + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, }) - const npm = mockNpm({ - output: () => { - t.pass('output is called') - }, - }) - npm.config.getCredentialsByURI = uri => { - t.same(uri, npm.config.get('registry'), 'gets credentials for expected registry') - return { token: 'some.registry.token' } - } - const publish = new Publish(npm) - await publish.exec([testDir]) - t.same( - scripts.map(s => s.event), - ['prepublishOnly', 'publish', 'postpublish'], - 'runs only expected scripts, in order' + registry.nock.put(`/${pkg}`).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'new package version') + t.equal( + fs.existsSync(path.join(prefix, 'scripts-prepublishonly')), + false, + 'did not run prepublishOnly' + ) + t.equal( + fs.existsSync(path.join(prefix, 'scripts-prepublish')), + false, + 'did not run prepublish' + ) + t.equal( + fs.existsSync(path.join(prefix, 'scripts-publish')), + false, + 'did not run publish' + ) + t.equal( + fs.existsSync(path.join(prefix, 'scripts-postpublish')), + false, + 'did not run postpublish' ) }) -t.test('does not run scripts on --ignore-scripts', async t => { - t.plan(4) - - const testDir = t.testdir({ - 'package.json': JSON.stringify( - { - name: 'my-cool-pkg', - version: '1.0.0', - }, - null, - 2 - ), +t.test('_auth config default registry', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { + '//registry.npmjs.org/:_auth': basic, + }, + prefixDir: { + 'package.json': JSON.stringify(pkgJson), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), }) - - log.level = 'info' - const Publish = t.mock('../../../lib/commands/publish.js', { - '@npmcli/run-script': () => { - t.fail('should not call run-script') - }, - '../../../lib/utils/tar.js': { - getContents: () => ({ - id: 'someid', - }), - logTar: () => { - t.pass('logTar is called') - }, - }, - libnpmpublish: { - publish: () => { - t.pass('publish called') - }, - }, + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + basic, }) - const npm = mockNpm({ - config: { 'ignore-scripts': true }, - output: () => { - t.pass('output is called') - }, - }) - npm.config.getCredentialsByURI = uri => { - t.same(uri, npm.config.get('registry'), 'gets credentials for expected registry') - return { token: 'some.registry.token' } - } - const publish = new Publish(npm) - await publish.exec([testDir]) + registry.nock.put(`/${pkg}`).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'new package version') +}) + +t.test('bare _auth and registry config', async t => { + const spec = npa('@npm/test-package') + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { + registry: alternateRegistry, + '//other.registry.npmjs.org/:_auth': basic, + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: '@npm/test-package', + version: '1.0.0', + }, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + const registry = new MockRegistry({ + tap: t, + registry: alternateRegistry, + basic, + }) + registry.nock.put(`/${spec.escapedName}`).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'new package version') +}) + +t.test('bare _auth config scoped registry', async t => { + const { npm } = await loadMockNpm(t, { + config: { + '@npm:registry': alternateRegistry, + _auth: basic, + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: '@npm/test-package', + version: '1.0.0', + }, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + await t.rejects( + npm.exec('publish', []), + { message: `This command requires you to be logged in to ${alternateRegistry}` } + ) +}) + +t.test('scoped _auth config scoped registry', async t => { + const spec = npa('@npm/test-package') + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { + '@npm:registry': alternateRegistry, + [`${alternateRegistry.slice(6)}/:_auth`]: basic, + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: '@npm/test-package', + version: '1.0.0', + }, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + const registry = new MockRegistry({ + tap: t, + registry: alternateRegistry, + basic, + }) + registry.nock.put(`/${spec.escapedName}`).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'new package version') +}) + +t.test('restricted access', async t => { + const spec = npa('@npm/test-package') + const { npm, joinedOutput, logs } = await loadMockNpm(t, { + config: { + ...auth, + access: 'restricted', + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: '@npm/test-package', + version: '1.0.0', + }, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, + }) + registry.nock.put(`/${spec.escapedName}`, body => { + t.equal(body.access, 'restricted', 'access is explicitly set to restricted') + return true + }).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'new package version') + t.matchSnapshot(logs.notice) +}) + +t.test('public access', async t => { + const spec = npa('@npm/test-package') + const { npm, joinedOutput, logs } = await loadMockNpm(t, { + config: { + ...auth, + access: 'public', + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: '@npm/test-package', + version: '1.0.0', + }, null, 2), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => prefix, + }), + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: token, + }) + registry.nock.put(`/${spec.escapedName}`, body => { + t.equal(body.access, 'public', 'access is explicitly set to public') + return true + }).reply(200, {}) + await npm.exec('publish', []) + t.matchSnapshot(joinedOutput(), 'new package version') + t.matchSnapshot(logs.notice) }) diff --git a/test/lib/commands/query.js b/test/lib/commands/query.js new file mode 100644 index 0000000..fb5b484 --- /dev/null +++ b/test/lib/commands/query.js @@ -0,0 +1,199 @@ +const t = require('tap') +const { load: loadMockNpm } = require('../../fixtures/mock-npm') + +t.cleanSnapshot = (str) => { + const normalizePath = p => p + .replace(/\\+/g, '/') + .replace(/\r\n/g, '\n') + return normalizePath(str) + .replace(new RegExp(normalizePath(process.cwd()), 'g'), '{CWD}') + // normalize between windows and posix + .replace(new RegExp('lib/node_modules', 'g'), 'node_modules') +} + +t.test('simple query', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: { + node_modules: { + a: { + name: 'a', + version: '1.0.0', + }, + b: { + name: 'b', + version: '^2.0.0', + }, + }, + 'package.json': JSON.stringify({ + name: 'project', + dependencies: { + a: '^1.0.0', + b: '^1.0.0', + }, + peerDependencies: { + c: '1.0.0', + }, + }), + }, + }) + await npm.exec('query', [':root, :root > *']) + t.matchSnapshot(joinedOutput(), 'should return root object and direct children') +}) + +t.test('recursive tree', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: { + node_modules: { + a: { + name: 'a', + version: '1.0.0', + }, + b: { + name: 'b', + version: '^2.0.0', + dependencies: { + a: '1.0.0', + }, + }, + }, + 'package.json': JSON.stringify({ + name: 'project', + dependencies: { + a: '^1.0.0', + b: '^1.0.0', + }, + }), + }, + }) + await npm.exec('query', ['*']) + t.matchSnapshot(joinedOutput(), 'should return everything in the tree, accounting for recursion') +}) +t.test('workspace query', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { + workspaces: ['c'], + }, + prefixDir: { + node_modules: { + a: { + name: 'a', + version: '1.0.0', + }, + b: { + name: 'b', + version: '^2.0.0', + }, + c: t.fixture('symlink', '../c'), + }, + c: { + 'package.json': JSON.stringify({ + name: 'c', + version: '1.0.0', + }), + }, + 'package.json': JSON.stringify({ + name: 'project', + workspaces: ['c'], + dependencies: { + a: '^1.0.0', + b: '^1.0.0', + }, + }), + }, + }) + await npm.exec('query', [':scope'], ['c']) + t.matchSnapshot(joinedOutput(), 'should return workspace object') +}) + +t.test('include-workspace-root', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { + 'include-workspace-root': true, + workspaces: ['c'], + }, + prefixDir: { + node_modules: { + a: { + name: 'a', + version: '1.0.0', + }, + b: { + name: 'b', + version: '^2.0.0', + }, + c: t.fixture('symlink', '../c'), + }, + c: { + 'package.json': JSON.stringify({ + name: 'c', + version: '1.0.0', + }), + }, + 'package.json': JSON.stringify({ + name: 'project', + workspaces: ['c'], + dependencies: { + a: '^1.0.0', + b: '^1.0.0', + }, + }), + }, + }) + await npm.exec('query', [':scope'], ['c']) + t.matchSnapshot(joinedOutput(), 'should return workspace object and root object') +}) +t.test('linked node', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + prefixDir: { + node_modules: { + a: t.fixture('symlink', '../a'), + }, + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + }), + }, + 'package.json': JSON.stringify({ + name: 'project', + dependencies: { + a: 'file:./a', + }, + }), + }, + }) + await npm.exec('query', ['[name=a]']) + t.matchSnapshot(joinedOutput(), 'should return linked node res') +}) + +t.test('global', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { + global: true, + }, + // This is a global dir that works in both windows and non-windows, that's + // why it has two node_modules folders + globalPrefixDir: { + node_modules: { + lorem: { + 'package.json': JSON.stringify({ + name: 'lorem', + version: '2.0.0', + }), + }, + }, + lib: { + node_modules: { + lorem: { + 'package.json': JSON.stringify({ + name: 'lorem', + version: '2.0.0', + }), + }, + }, + }, + }, + }) + await npm.exec('query', ['[name=lorem]']) + t.matchSnapshot(joinedOutput(), 'should return global package') +}) diff --git a/test/lib/commands/repo.js b/test/lib/commands/repo.js index 93eb6d0..86f1b8e 100644 --- a/test/lib/commands/repo.js +++ b/test/lib/commands/repo.js @@ -188,10 +188,10 @@ const openUrl = async (npm, url, errMsg) => { } t.afterEach(() => opened = {}) -const loadMockNpm = async (t, prefix) => { +const loadMockNpm = async (t, prefixDir) => { const res = await _loadMockNpm(t, { mocks: { '../../lib/utils/open-url.js': openUrl }, - testdir: prefix, + prefixDir, }) return res } @@ -221,7 +221,7 @@ t.test('open repo urls', async t => { unhostedgitsshobj: 'https://gothib.com/foo/unhostedgitsshobj', unhostedgithttpobj: 'http://gothib.com/foo/unhostedgithttpobj', unhostedgithttpsobj: 'https://gothib.com/foo/unhostedgithttpsobj', - directory: 'https://github.com/foo/test-repo-with-directory/tree/master/some/directory', + directory: 'https://github.com/foo/test-repo-with-directory/tree/HEAD/some/directory', '.': 'https://example.com/thispkg', } const keys = Object.keys(expect) @@ -311,4 +311,12 @@ t.test('workspaces', async t => { ) t.match({}, opened, 'opened no repo urls') }) + + t.test('package arg and workspace', async (t) => { + npm.config.set('workspace', ['workspace-a']) + await npm.exec('repo', ['.']) + t.match({ + 'https://github.com/npm/workspaces-test': 1, + }, opened, 'opened url for package arg, not workspace') + }) }) diff --git a/test/lib/commands/restart.js b/test/lib/commands/restart.js index 7730f1a..f9745ac 100644 --- a/test/lib/commands/restart.js +++ b/test/lib/commands/restart.js @@ -1,20 +1,14 @@ const t = require('tap') -const spawk = require('spawk') +const tspawk = require('../../fixtures/tspawk') const { load: loadMockNpm } = require('../../fixtures/mock-npm') -spawk.preventUnmatched() -t.teardown(() => { - spawk.unload() -}) +const spawk = tspawk(t) -// TODO this ... smells. npm "script-shell" config mentions defaults but those -// are handled by run-script, not npm. So for now we have to tie tests to some -// pretty specific internals of runScript -const makeSpawnArgs = require('@npmcli/run-script/lib/make-spawn-args.js') +const isCmdRe = /(?:^|\\)cmd(?:\.exe)?$/i t.test('should run restart script from package.json', async t => { const { npm } = await loadMockNpm(t, { - testdir: { + prefixDir: { 'package.json': JSON.stringify({ name: 'x', version: '1.2.3', @@ -25,13 +19,15 @@ t.test('should run restart script from package.json', async t => { }, config: { loglevel: 'silent', + scriptShell: process.platform === 'win32' ? process.env.COMSPEC : 'sh', }, }) - const [scriptShell] = makeSpawnArgs({ path: npm.prefix }) - const script = spawk.spawn(scriptShell, (args) => { - t.ok(args.includes('node ./test-restart.js "foo"'), 'ran restart script with extra args') - return true - }) + + const scriptShell = npm.config.get('scriptShell') + const scriptArgs = isCmdRe.test(scriptShell) + ? ['/d', '/s', '/c', 'node ./test-restart.js foo'] + : ['-c', 'node ./test-restart.js foo'] + const script = spawk.spawn(scriptShell, scriptArgs) await npm.exec('restart', ['foo']) t.ok(script.called, 'script ran') }) diff --git a/test/lib/commands/run-script.js b/test/lib/commands/run-script.js index ea0227c..8aafebc 100644 --- a/test/lib/commands/run-script.js +++ b/test/lib/commands/run-script.js @@ -10,10 +10,12 @@ const RUN_SCRIPTS = [] const flatOptions = { scriptShell: undefined, } +const defaultLoglevel = 'info' const config = { json: false, parseable: false, 'if-present': false, + loglevel: defaultLoglevel, } const npm = mockNpm({ @@ -26,20 +28,21 @@ const npm = mockNpm({ output: (...msg) => output.push(msg), }) -const output = [] - -const npmlog = { - disableProgress: () => null, - level: 'warn', +const setLoglevel = (t, level) => { + npm.config.set('loglevel', level) + t.teardown(() => { + npm.config.set('loglevel', defaultLoglevel) + }) } +const output = [] + const log = { error: () => null, } t.afterEach(() => { npm.color = false - npmlog.level = 'warn' log.error = () => null output.length = 0 RUN_SCRIPTS.length = 0 @@ -58,9 +61,8 @@ const getRS = windows => { isServerPackage: require('@npmcli/run-script').isServerPackage, } ), - npmlog, 'proc-log': log, - '../../../lib/utils/is-windows-shell.js': windows, + '../../../lib/utils/is-windows.js': { isWindowsShell: windows }, }) return new RunScript(npm) } @@ -123,7 +125,6 @@ t.test('default env, start, and restart scripts', t => { args: [], scriptShell: undefined, stdio: 'inherit', - stdioString: true, pkg: { name: 'x', version: '1.2.3', _id: 'x@1.2.3', scripts: {} }, event: 'start', }, @@ -138,7 +139,6 @@ t.test('default env, start, and restart scripts', t => { args: [], scriptShell: undefined, stdio: 'inherit', - stdioString: true, pkg: { name: 'x', version: '1.2.3', @@ -160,7 +160,6 @@ t.test('default env, start, and restart scripts', t => { args: [], scriptShell: undefined, stdio: 'inherit', - stdioString: true, pkg: { name: 'x', version: '1.2.3', @@ -183,7 +182,6 @@ t.test('default env, start, and restart scripts', t => { args: [], scriptShell: undefined, stdio: 'inherit', - stdioString: true, pkg: { name: 'x', version: '1.2.3', @@ -218,7 +216,6 @@ t.test('non-default env script', t => { args: [], scriptShell: undefined, stdio: 'inherit', - stdioString: true, pkg: { name: 'x', version: '1.2.3', @@ -240,7 +237,6 @@ t.test('non-default env script', t => { args: [], scriptShell: undefined, stdio: 'inherit', - stdioString: true, pkg: { name: 'x', version: '1.2.3', @@ -303,7 +299,6 @@ t.test('run pre/post hooks', async t => { args: [], scriptShell: undefined, stdio: 'inherit', - stdioString: true, pkg: { name: 'x', version: '1.2.3', @@ -340,7 +335,6 @@ t.test('skip pre/post hooks when using ignoreScripts', async t => { args: [], scriptShell: undefined, stdio: 'inherit', - stdioString: true, pkg: { name: 'x', version: '1.2.3', @@ -359,10 +353,7 @@ t.test('skip pre/post hooks when using ignoreScripts', async t => { }) t.test('run silent', async t => { - npmlog.level = 'silent' - t.teardown(() => { - npmlog.level = 'warn' - }) + setLoglevel(t, 'silent') npm.localPrefix = t.testdir({ 'package.json': JSON.stringify({ @@ -386,7 +377,6 @@ t.test('run silent', async t => { args: [], scriptShell: undefined, stdio: 'inherit', - stdioString: true, pkg: { name: 'x', version: '1.2.3', @@ -440,12 +430,11 @@ t.test('list scripts', t => { }) t.test('silent', async t => { - npmlog.level = 'silent' + setLoglevel(t, 'silent') await runScript.exec([]) t.strictSame(output, []) }) t.test('warn json', async t => { - npmlog.level = 'warn' config.json = true await runScript.exec([]) t.strictSame(output, [[JSON.stringify(scripts, 0, 2)]], 'json report') @@ -723,7 +712,7 @@ t.test('workspaces', t => { }) t.test('list no scripts --loglevel=silent', async t => { - npmlog.level = 'silent' + setLoglevel(t, 'silent') await runScript.execWorkspaces([], []) t.strictSame(output, []) }) @@ -860,9 +849,8 @@ t.test('workspaces', t => { '@npmcli/run-script': () => { throw new Error('err') }, - npmlog, 'proc-log': log, - '../../../lib/utils/is-windows-shell.js': false, + '../../../lib/utils/is-windows.js': { isWindowsShell: false }, }) const runScript = new RunScript(npm) @@ -879,9 +867,8 @@ t.test('workspaces', t => { RUN_SCRIPTS.push(opts) }, - npmlog, 'proc-log': log, - '../../../lib/utils/is-windows-shell.js': false, + '../../../lib/utils/is-windows.js': { isWindowsShell: false }, }) const runScript = new RunScript(npm) diff --git a/test/lib/commands/search.js b/test/lib/commands/search.js index c8dbc1b..596c849 100644 --- a/test/lib/commands/search.js +++ b/test/lib/commands/search.js @@ -1,170 +1,92 @@ const t = require('tap') -const Minipass = require('minipass') -const { fake: mockNpm } = require('../../fixtures/mock-npm') +const { load: loadMockNpm } = require('../../fixtures/mock-npm.js') +const MockRegistry = require('@npmcli/mock-registry') const libnpmsearchResultFixture = require('../../fixtures/libnpmsearch-stream-result.js') -let result = '' -const flatOptions = { - search: { - exclude: null, - limit: 20, - opts: '', - }, -} -const config = { - json: false, - parseable: false, -} -const npm = mockNpm({ - config, - flatOptions: { ...flatOptions }, - output: (...msg) => { - result += msg.join('\n') - }, -}) -const npmlog = { - silly () {}, - clearProgress () {}, -} -const libnpmsearch = { - stream () {}, -} -const mocks = { - npmlog, - libnpmsearch, - '../../../lib/utils/usage.js': () => 'usage instructions', -} - -t.afterEach(() => { - result = '' - config.json = false - config.parseable = false - npm.flatOptions = { ...flatOptions } -}) - -const Search = t.mock('../../../lib/commands/search.js', mocks) -const search = new Search(npm) - t.test('no args', async t => { + const { npm } = await loadMockNpm(t) await t.rejects( - search.exec([]), + npm.exec('search', []), /search must be called with arguments/, 'should throw usage instructions' ) }) -t.test('search <name>', async t => { - const src = new Minipass() - src.objectMode = true - const libnpmsearch = { - stream () { - return src - }, - } - - const Search = t.mock('../../../lib/commands/search.js', { - ...mocks, - libnpmsearch, +t.test('search <name> text', async t => { + const { npm, joinedOutput } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - const search = new Search(npm) - for (const i of libnpmsearchResultFixture) { - src.write(i) - } - - src.end() - - await search.exec(['libnpm']) - t.matchSnapshot(result, 'should have expected search results') + registry.search({ results: libnpmsearchResultFixture }) + await npm.exec('search', ['libnpm']) + t.matchSnapshot(joinedOutput(), 'should have expected search results') }) t.test('search <name> --json', async t => { - const src = new Minipass() - src.objectMode = true - - npm.flatOptions.json = true - config.json = true - const libnpmsearch = { - stream () { - return src - }, - } - - const Search = t.mock('../../../lib/commands/search.js', { - ...mocks, - libnpmsearch, + const { npm, joinedOutput } = await loadMockNpm(t, { config: { json: true } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - const search = new Search(npm) - for (const i of libnpmsearchResultFixture) { - src.write(i) - } + registry.search({ results: libnpmsearchResultFixture }) - src.end() - await search.exec(['libnpm']) - - const parsedResult = JSON.parse(result) - parsedResult.forEach((entry) => { - entry.date = new Date(entry.date) - }) + await npm.exec('search', ['libnpm']) t.same( - parsedResult, + JSON.parse(joinedOutput()), libnpmsearchResultFixture, 'should have expected search results as json' ) - - config.json = false }) -t.test('search <invalid-module> --json', async t => { - const src = new Minipass() - src.objectMode = true - - npm.flatOptions.json = true - config.json = true - const libnpmsearch = { - stream () { - return src - }, - } - - const Search = t.mock('../../../lib/commands/search.js', { - ...mocks, - libnpmsearch, +t.test('search <name> --parseable', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: { parseable: true } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - const search = new Search(npm) - src.end() - await search.exec(['foo']) - - t.equal(result, '\n[]\n', 'should have expected empty square brackets') - - config.json = false + registry.search({ results: libnpmsearchResultFixture }) + await npm.exec('search', ['libnpm']) + t.matchSnapshot(joinedOutput(), 'should have expected search results as parseable') }) -t.test('search <name> --searchexclude --searchopts', async t => { - npm.flatOptions.search = { - ...flatOptions.search, - exclude: '', - } - - const src = new Minipass() - src.objectMode = true - const libnpmsearch = { - stream () { - return src - }, - } - - const Search = t.mock('../../../lib/commands/search.js', { - ...mocks, - libnpmsearch, +t.test('search <name> --color', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: { color: 'always' } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - const search = new Search(npm) - src.write({ + registry.search({ results: libnpmsearchResultFixture }) + await npm.exec('search', ['libnpm']) + t.matchSnapshot(joinedOutput(), 'should have expected search results with color') +}) + +t.test('search /<name>/--color', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: { color: 'always' } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + + registry.search({ results: libnpmsearchResultFixture }) + await npm.exec('search', ['/libnpm/']) + t.matchSnapshot(joinedOutput(), 'should have expected search results with color') +}) + +t.test('search <name>', async t => { + const { npm, joinedOutput } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + + registry.search({ results: [{ name: 'foo', scope: 'unscoped', version: '1.0.0', @@ -176,8 +98,7 @@ t.test('search <name> --searchexclude --searchopts', async t => { maintainers: [ { username: 'foo', email: 'foo@npmjs.com' }, ], - }) - src.write({ + }, { name: 'libnpmversion', scope: 'unscoped', version: '1.0.0', @@ -189,58 +110,100 @@ t.test('search <name> --searchexclude --searchopts', async t => { maintainers: [ { username: 'foo', email: 'foo@npmjs.com' }, ], - }) + }] }) - src.end() - await search.exec(['foo']) + await npm.exec('search', ['foo']) - t.matchSnapshot(result, 'should have filtered expected search results') + t.matchSnapshot(joinedOutput(), 'should have filtered expected search results') }) t.test('empty search results', async t => { - const src = new Minipass() - src.objectMode = true - const libnpmsearch = { - stream () { - return src - }, - } - - const Search = t.mock('../../../lib/commands/search.js', { - ...mocks, - libnpmsearch, + const { npm, joinedOutput } = await loadMockNpm(t) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - const search = new Search(npm) - src.end() - await search.exec(['foo']) + registry.search({ results: [] }) + await npm.exec('search', ['foo']) - t.matchSnapshot(result, 'should have expected search results') + t.matchSnapshot(joinedOutput(), 'should have expected search results') +}) + +t.test('empty search results --json', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: { json: true } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + + registry.search({ results: [] }) + + await npm.exec('search', ['foo']) + t.equal(joinedOutput(), '\n[]\n', 'should have expected empty square brackets') }) t.test('search api response error', async t => { - const src = new Minipass() - src.objectMode = true - const libnpmsearch = { - stream () { - return src - }, - } + const { npm } = await loadMockNpm(t) - const Search = t.mock('../../../lib/commands/search.js', { - ...mocks, - libnpmsearch, + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), }) - const search = new Search(npm) - setImmediate(() => { - src.emit('error', new Error('ERR')) - src.end() - }) + registry.search({ error: 'ERR' }) await t.rejects( - search.exec(['foo']), + npm.exec('search', ['foo']), /ERR/, 'should throw response error' ) }) + +t.test('search exclude string', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: { searchexclude: 'libnpmversion' } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + + registry.search({ results: libnpmsearchResultFixture }) + await npm.exec('search', ['libnpm']) + t.matchSnapshot(joinedOutput(), 'results should not have libnpmversion') +}) + +t.test('search exclude username with upper case letters', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: { searchexclude: 'NLF' } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + + registry.search({ results: libnpmsearchResultFixture }) + await npm.exec('search', ['libnpm']) + t.matchSnapshot(joinedOutput(), 'results should not have nlf') +}) + +t.test('search exclude regex', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: { searchexclude: '/version/' } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + + registry.search({ results: libnpmsearchResultFixture }) + await npm.exec('search', ['libnpm']) + t.matchSnapshot(joinedOutput(), 'results should not have libnpmversion') +}) + +t.test('search exclude forward slash', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: { searchexclude: '/version' } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + + registry.search({ results: libnpmsearchResultFixture }) + await npm.exec('search', ['libnpm']) + t.matchSnapshot(joinedOutput(), 'results should not have libnpmversion') +}) diff --git a/test/lib/commands/set-script.js b/test/lib/commands/set-script.js deleted file mode 100644 index 2c4fe57..0000000 --- a/test/lib/commands/set-script.js +++ /dev/null @@ -1,188 +0,0 @@ -const t = require('tap') -const fs = require('fs') -const parseJSON = require('json-parse-even-better-errors') -const { fake: mockNpm } = require('../../fixtures/mock-npm') -const { resolve } = require('path') - -const flatOptions = {} -const npm = mockNpm(flatOptions) - -const ERROR_OUTPUT = [] -const WARN_OUTPUT = [] -const SetScript = t.mock('../../../lib/commands/set-script.js', { - 'proc-log': { - error: (...args) => { - ERROR_OUTPUT.push(args) - }, - warn: (...args) => { - WARN_OUTPUT.push(args) - }, - }, -}) -const setScript = new SetScript(npm) - -t.test('completion', t => { - t.test('already have a script name', async t => { - npm.localPrefix = t.testdir({}) - const res = await setScript.completion({ conf: { argv: { remain: ['npm', 'run', 'x'] } } }) - t.equal(res, undefined) - t.end() - }) - - t.test('no package.json', async t => { - npm.localPrefix = t.testdir({}) - const res = await setScript.completion({ conf: { argv: { remain: ['npm', 'run'] } } }) - t.strictSame(res, []) - t.end() - }) - - t.test('has package.json, no scripts', async t => { - npm.localPrefix = t.testdir({ - 'package.json': JSON.stringify({}), - }) - const res = await setScript.completion({ conf: { argv: { remain: ['npm', 'run'] } } }) - t.strictSame(res, []) - t.end() - }) - - t.test('has package.json, with scripts', async t => { - npm.localPrefix = t.testdir({ - 'package.json': JSON.stringify({ - scripts: { hello: 'echo hello', world: 'echo world' }, - }), - }) - const res = await setScript.completion({ conf: { argv: { remain: ['npm', 'run'] } } }) - t.strictSame(res, ['hello', 'world']) - t.end() - }) - - t.end() -}) - -t.test('fails on invalid arguments', async t => { - t.plan(3) - await t.rejects( - setScript.exec(['arg1']), - /Expected 2 arguments: got 1/ - ) - await t.rejects( - setScript.exec(['arg1', 'arg2', 'arg3']), - /Expected 2 arguments: got 3/ - ) - await t.rejects( - setScript.exec(['arg1', 'arg2', 'arg3', 'arg4']), - /Expected 2 arguments: got 4/ - ) -}) - -t.test('fails if run in postinstall script', async t => { - const lifecycleEvent = process.env.npm_lifecycle_event - t.teardown(() => { - process.env.npm_lifecycle_event = lifecycleEvent - }) - - process.env.npm_lifecycle_event = 'postinstall' - t.plan(1) - await t.rejects( - setScript.exec(['arg1', 'arg2']), - /Scripts can’t set from the postinstall script/ - ) -}) - -t.test('fails when package.json not found', async t => { - t.plan(1) - await t.rejects( - setScript.exec(['arg1', 'arg2']), - /package.json not found/ - ) -}) - -t.test('fails on invalid JSON', async t => { - npm.localPrefix = t.testdir({ - 'package.json': 'iamnotjson', - }) - - t.plan(1) - await t.rejects( - setScript.exec(['arg1', 'arg2']), - /Invalid package.json: JSONParseError/ - ) -}) - -t.test('creates scripts object', async t => { - npm.localPrefix = t.testdir({ - 'package.json': '{}', - }) - - await setScript.exec(['arg1', 'arg2']) - const contents = fs.readFileSync(resolve(npm.localPrefix, 'package.json')) - t.ok(parseJSON(contents), { scripts: { arg1: 'arg2' } }) -}) - -t.test('warns when overwriting', async t => { - WARN_OUTPUT.length = 0 - npm.localPrefix = t.testdir({ - 'package.json': JSON.stringify({ - scripts: { - arg1: 'blah', - }, - }), - }) - - await setScript.exec(['arg1', 'arg2']) - t.hasStrict(WARN_OUTPUT[0], ['set-script', 'Script "arg1" was overwritten'], 'warning was logged') -}) - -t.test('workspaces', async t => { - ERROR_OUTPUT.length = 0 - WARN_OUTPUT.length = 0 - npm.localPrefix = t.testdir({ - 'package.json': JSON.stringify({ - name: 'workspaces-test', - version: '1.0.0', - workspaces: ['workspace-a', 'workspace-b', 'workspace-c'], - }), - 'workspace-a': { - 'package.json': '{}', - }, - 'workspace-b': { - 'package.json': '"notajsonobject"', - }, - 'workspace-c': { - 'package.json': JSON.stringify({ - scripts: { - arg1: 'test', - }, - }, null, ' '.repeat(6)).replace(/\n/g, '\r\n'), - }, - }) - - await setScript.execWorkspaces(['arg1', 'arg2'], []) - t.equal(process.exitCode, 1, 'did set the exitCode to 1') - // force the exitCode back to 0 to make tap happy - process.exitCode = 0 - - // workspace-a had the script added - const contentsA = fs.readFileSync(resolve(npm.localPrefix, 'workspace-a', 'package.json')) - const dataA = parseJSON(contentsA) - t.hasStrict(dataA, { scripts: { arg1: 'arg2' } }, 'defined the script') - - // workspace-b logged an error - t.strictSame(ERROR_OUTPUT, [ - ['set-script', `Can't update invalid package.json data`], - [' in workspace: workspace-b'], - [` at location: ${resolve(npm.localPrefix, 'workspace-b')}`], - ], 'logged workspace-b error') - - // workspace-c overwrite a script and logged a warning - const contentsC = fs.readFileSync(resolve(npm.localPrefix, 'workspace-c', 'package.json')) - const dataC = parseJSON(contentsC) - t.hasStrict(dataC, { scripts: { arg1: 'arg2' } }, 'defined the script') - t.equal(dataC[Symbol.for('indent')], ' '.repeat(6), 'kept the correct indent') - t.equal(dataC[Symbol.for('newline')], '\r\n', 'kept the correct newline') - t.match(WARN_OUTPUT, [ - ['set-script', 'Script "arg1" was overwritten'], - [' in workspace: workspace-c'], - [` at location: ${resolve(npm.localPrefix, 'workspace-c')}`], - ], 'logged workspace-c warning') -}) diff --git a/test/lib/commands/set.js b/test/lib/commands/set.js index feeb901..ce59870 100644 --- a/test/lib/commands/set.js +++ b/test/lib/commands/set.js @@ -40,6 +40,10 @@ const npm = { configArgs = args } }, + config: { + validate: () => {}, + isDefault: () => {}, + }, } const Set = t.mock('../../../lib/commands/set.js') diff --git a/test/lib/commands/shrinkwrap.js b/test/lib/commands/shrinkwrap.js index 2b9e46c..604a7db 100644 --- a/test/lib/commands/shrinkwrap.js +++ b/test/lib/commands/shrinkwrap.js @@ -13,20 +13,22 @@ t.formatSnapshot = obj => (k, v) => { try { return JSON.parse(v) - } catch {} + } catch { + // leave invalid JSON as a string + } return v }, 2 ) -// Run shrinkwrap against a specified testdir with config items +// Run shrinkwrap against a specified prefixDir with config items // and make some assertions that should always be true. Sets // the results on t.context for use in child tests -const shrinkwrap = async (t, testdir = {}, config = {}, mocks = {}) => { +const shrinkwrap = async (t, prefixDir = {}, config = {}, mocks = {}) => { const { npm, logs } = await loadMockNpm(t, { mocks, config, - testdir, + prefixDir, }) await npm.exec('shrinkwrap', []) @@ -38,7 +40,7 @@ const shrinkwrap = async (t, testdir = {}, config = {}, mocks = {}) => { t.same(logs.warn, [], 'no warnings') t.teardown(() => delete t.context) t.context = { - localPrefix: testdir, + localPrefix: prefixDir, config, shrinkwrap: JSON.parse(fs.readFileSync(newFile)), logs: logs.notice.map(([, m]) => m), @@ -110,8 +112,8 @@ const NOTICES = { t.test('with nothing', t => shrinkwrapMatrix(t, null, { ancient: { - shrinkwrap: { lockfileVersion: 2 }, - logs: NOTICES.CREATED(2), + shrinkwrap: { lockfileVersion: 3 }, + logs: NOTICES.CREATED(3), }, ancientUpgrade: { shrinkwrap: { lockfileVersion: 3 }, @@ -123,8 +125,8 @@ t.test('with nothing', t => t.test('with package-lock.json', t => shrinkwrapMatrix(t, 'package-lock', { ancient: { - shrinkwrap: { lockfileVersion: 2 }, - logs: NOTICES.RENAMED(2), + shrinkwrap: { lockfileVersion: 3 }, + logs: NOTICES.RENAMED(3), }, ancientUpgrade: { shrinkwrap: { lockfileVersion: 3 }, @@ -148,8 +150,8 @@ t.test('with package-lock.json', t => t.test('with npm-shrinkwrap.json', t => shrinkwrapMatrix(t, 'npm-shrinkwrap', { ancient: { - shrinkwrap: { lockfileVersion: 2 }, - logs: NOTICES.UPDATED(2), + shrinkwrap: { lockfileVersion: 3 }, + logs: NOTICES.UPDATED(3), }, ancientUpgrade: { shrinkwrap: { lockfileVersion: 3 }, diff --git a/test/lib/commands/star.js b/test/lib/commands/star.js index 2f4ddc9..c5f233f 100644 --- a/test/lib/commands/star.js +++ b/test/lib/commands/star.js @@ -1,136 +1,61 @@ const t = require('tap') -const { fake: mockNpm } = require('../../fixtures/mock-npm') +const { load: loadMockNpm } = require('../../fixtures/mock-npm.js') +const MockRegistry = require('@npmcli/mock-registry') -let result = '' - -const noop = () => null -const config = { - unicode: false, - 'star.unstar': false, -} -const npm = mockNpm({ - config, - output: (...msg) => { - result += msg.join('\n') - }, -}) -const npmFetch = { json: noop } -const log = { error: noop, info: noop, verbose: noop } -const mocks = { - 'proc-log': log, - 'npm-registry-fetch': npmFetch, - '../../../lib/utils/get-identity.js': async () => 'foo', - '../../../lib/utils/usage.js': () => 'usage instructions', -} - -const Star = t.mock('../../../lib/commands/star.js', mocks) -const star = new Star(npm) - -t.afterEach(() => { - config.unicode = false - config['star.unstar'] = false - log.info = noop - result = '' -}) +const pkgName = '@npmcli/test-package' +const authToken = 'test-auth-token' +const username = 'test-user' +const auth = { '//registry.npmjs.org/:_authToken': authToken } t.test('no args', async t => { + const { npm } = await loadMockNpm(t) await t.rejects( - star.exec([]), - /usage instructions/, - 'should throw usage instructions' + npm.exec('star', []), + { code: 'EUSAGE' }, + 'should throw usage error' ) }) -t.test('star a package', async t => { - t.plan(6) - const pkgName = '@npmcli/arborist' - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - return { - _id: pkgName, - _rev: 'hash', - users: ( - opts.method === 'PUT' - ? { foo: true } - : {} - ), - } - } - log.info = (title, msg, id) => { - t.equal(title, 'star', 'should use expected title') - t.equal(msg, 'starring', 'should use expected msg') - t.equal(id, pkgName, 'should use expected id') - } - await star.exec([pkgName]) +t.test('first person to star a package unicode:false', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { unicode: false, ...auth }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: authToken, + }) + const manifest = registry.manifest({ name: pkgName }) + await registry.package({ manifest, query: { write: true } }) + registry.whoami({ username }) + registry.star(manifest, { [username]: true }) + + await npm.exec('star', [pkgName]) t.equal( - result, - '(*) @npmcli/arborist', + joinedOutput(), + '(*) @npmcli/test-package', 'should output starred package msg' ) }) -t.test('unstar a package', async t => { - t.plan(6) - const pkgName = '@npmcli/arborist' - config['star.unstar'] = true - npmFetch.json = async (uri, opts) => { - t.ok(opts.log, 'is passed a logger') - return { - _id: pkgName, - _rev: 'hash', - ...(opts.method === 'PUT' - ? {} - : { foo: true } - ), - } - } - log.info = (title, msg, id) => { - t.equal(title, 'unstar', 'should use expected title') - t.equal(msg, 'unstarring', 'should use expected msg') - t.equal(id, pkgName, 'should use expected id') - } - await star.exec([pkgName]) +t.test('second person to star a package unicode:true', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { unicode: true, ...auth }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: authToken, + }) + const manifest = registry.manifest({ name: pkgName, users: { otheruser: true } }) + await registry.package({ manifest, query: { write: true } }) + registry.whoami({ username }) + registry.star(manifest, { otheruser: true, [username]: true }) + + await npm.exec('star', [pkgName]) t.equal( - result, - '( ) @npmcli/arborist', - 'should output unstarred package msg' - ) -}) - -t.test('unicode', async t => { - t.test('star a package', async t => { - config.unicode = true - npmFetch.json = async (uri, opts) => ({}) - await star.exec(['pkg']) - t.equal( - result, - '\u2605 pkg', - 'should output unicode starred package msg' - ) - }) - - t.test('unstar a package', async t => { - config.unicode = true - config['star.unstar'] = true - npmFetch.json = async (uri, opts) => ({}) - await star.exec(['pkg']) - t.equal( - result, - '\u2606 pkg', - 'should output unstarred package msg' - ) - }) -}) - -t.test('logged out user', async t => { - const Star = t.mock('../../../lib/commands/star.js', { - ...mocks, - '../../../lib/utils/get-identity.js': async () => undefined, - }) - const star = new Star(npm) - await t.rejects( - star.exec(['@npmcli/arborist']), - /You need to be logged in/, - 'should throw login required error' + joinedOutput(), + '★ @npmcli/test-package', + 'should output starred package msg' ) }) diff --git a/test/lib/commands/stars.js b/test/lib/commands/stars.js index 9597396..44de6ba 100644 --- a/test/lib/commands/stars.js +++ b/test/lib/commands/stars.js @@ -4,7 +4,7 @@ let result = '' const noop = () => null const npm = { - config: { get () {} }, + config: { get () {}, validate: () => {} }, flatOptions: {}, output: (...msg) => { result = [result, ...msg].join('\n') @@ -16,7 +16,6 @@ const mocks = { 'proc-log': log, 'npm-registry-fetch': npmFetch, '../../../lib/utils/get-identity.js': async () => 'foo', - '../../../lib/utils/usage.js': () => 'usage instructions', } const Stars = t.mock('../../../lib/commands/stars.js', mocks) diff --git a/test/lib/commands/start.js b/test/lib/commands/start.js index 4f7dc36..47f7f1a 100644 --- a/test/lib/commands/start.js +++ b/test/lib/commands/start.js @@ -1,21 +1,14 @@ const t = require('tap') -const spawk = require('spawk') +const tspawk = require('../../fixtures/tspawk') const { load: loadMockNpm } = require('../../fixtures/mock-npm') -spawk.preventUnmatched() -t.teardown(() => { - spawk.unload() -}) +const spawk = tspawk(t) -// TODO this ... smells. npm "script-shell" config mentions defaults but those -// are handled by run-script, not npm. So for now we have to tie tests to some -// pretty specific internals of runScript -const makeSpawnArgs = require('@npmcli/run-script/lib/make-spawn-args.js') +const isCmdRe = /(?:^|\\)cmd(?:\.exe)?$/i t.test('should run start script from package.json', async t => { - t.plan(2) const { npm } = await loadMockNpm(t, { - testdir: { + prefixDir: { 'package.json': JSON.stringify({ name: 'x', version: '1.2.3', @@ -26,13 +19,15 @@ t.test('should run start script from package.json', async t => { }, config: { loglevel: 'silent', + scriptShell: process.platform === 'win32' ? process.env.COMSPEC : 'sh', }, }) - const [scriptShell] = makeSpawnArgs({ path: npm.prefix }) - const script = spawk.spawn(scriptShell, (args) => { - t.ok(args.includes('node ./test-start.js "foo"'), 'ran start script with extra args') - return true - }) + + const scriptShell = npm.config.get('scriptShell') + const scriptArgs = isCmdRe.test(scriptShell) + ? ['/d', '/s', '/c', 'node ./test-start.js foo'] + : ['-c', 'node ./test-start.js foo'] + const script = spawk.spawn(scriptShell, scriptArgs) await npm.exec('start', ['foo']) t.ok(script.called, 'script ran') }) diff --git a/test/lib/commands/stop.js b/test/lib/commands/stop.js index 53d057b..9ca7742 100644 --- a/test/lib/commands/stop.js +++ b/test/lib/commands/stop.js @@ -1,20 +1,14 @@ const t = require('tap') -const spawk = require('spawk') +const tspawk = require('../../fixtures/tspawk') const { load: loadMockNpm } = require('../../fixtures/mock-npm') -spawk.preventUnmatched() -t.teardown(() => { - spawk.unload() -}) +const spawk = tspawk(t) -// TODO this ... smells. npm "script-shell" config mentions defaults but those -// are handled by run-script, not npm. So for now we have to tie tests to some -// pretty specific internals of runScript -const makeSpawnArgs = require('@npmcli/run-script/lib/make-spawn-args.js') +const isCmdRe = /(?:^|\\)cmd(?:\.exe)?$/i t.test('should run stop script from package.json', async t => { const { npm } = await loadMockNpm(t, { - testdir: { + prefixDir: { 'package.json': JSON.stringify({ name: 'x', version: '1.2.3', @@ -25,13 +19,15 @@ t.test('should run stop script from package.json', async t => { }, config: { loglevel: 'silent', + scriptShell: process.platform === 'win32' ? process.env.COMSPEC : 'sh', }, }) - const [scriptShell] = makeSpawnArgs({ path: npm.prefix }) - const script = spawk.spawn(scriptShell, (args) => { - t.ok(args.includes('node ./test-stop.js "foo"'), 'ran stop script with extra args') - return true - }) + + const scriptShell = npm.config.get('scriptShell') + const scriptArgs = isCmdRe.test(scriptShell) + ? ['/d', '/s', '/c', 'node ./test-stop.js foo'] + : ['-c', 'node ./test-stop.js foo'] + const script = spawk.spawn(scriptShell, scriptArgs) await npm.exec('stop', ['foo']) t.ok(script.called, 'script ran') }) diff --git a/test/lib/commands/team.js b/test/lib/commands/team.js index 9626083..7924187 100644 --- a/test/lib/commands/team.js +++ b/test/lib/commands/team.js @@ -1,4 +1,5 @@ const t = require('tap') +const { fake: mockNpm } = require('../../fixtures/mock-npm') let result = '' const libnpmteam = { @@ -9,22 +10,24 @@ const libnpmteam = { async lsUsers () {}, async rm () {}, } -const npm = { +const npm = mockNpm({ flatOptions: {}, + config: { + loglevel: 'info', + }, output: (...msg) => { result += msg.join('\n') }, -} +}) const mocks = { libnpmteam, 'cli-columns': a => a.join(' '), - '../../../lib/utils/otplease.js': async (opts, fn) => fn(opts), - '../../../lib/utils/usage.js': () => 'usage instructions', } t.afterEach(() => { result = '' npm.flatOptions = {} + npm.config.set('loglevel', 'info') }) const Team = t.mock('../../../lib/commands/team.js', mocks) @@ -73,7 +76,7 @@ t.test('team add <scope:team> <user>', async t => { }) t.test('--silent', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') await team.exec(['add', '@npmcli:developers', 'foo']) @@ -115,7 +118,7 @@ t.test('team create <scope:team>', async t => { }) t.test('--silent', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') await team.exec(['create', '@npmcli:newteam']) @@ -149,7 +152,7 @@ t.test('team destroy <scope:team>', async t => { }) t.test('--silent', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') await team.exec(['destroy', '@npmcli:newteam']) t.same(result, '', 'should not output destroy if silent') }) @@ -198,7 +201,7 @@ t.test('team ls <scope>', async t => { }) t.test('--silent', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') await team.exec(['ls', '@npmcli']) t.same(result, '', 'should not list teams if silent') }) @@ -278,7 +281,7 @@ t.test('team ls <scope:team>', async t => { }) t.test('--silent', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') await team.exec(['ls', '@npmcli:developers']) t.same(result, '', 'should not output users if silent') }) @@ -345,7 +348,7 @@ t.test('team rm <scope:team> <user>', async t => { }) t.test('--silent', async t => { - npm.flatOptions.silent = true + npm.config.set('loglevel', 'silent') await team.exec(['rm', '@npmcli:newteam', 'foo']) t.same(result, '', 'should not output rm result if silent') }) diff --git a/test/lib/commands/test.js b/test/lib/commands/test.js index a3dbd3f..3a62b6a 100644 --- a/test/lib/commands/test.js +++ b/test/lib/commands/test.js @@ -1,20 +1,14 @@ const t = require('tap') -const spawk = require('spawk') +const tspawk = require('../../fixtures/tspawk') const { load: loadMockNpm } = require('../../fixtures/mock-npm') -spawk.preventUnmatched() -t.teardown(() => { - spawk.unload() -}) +const spawk = tspawk(t) -// TODO this ... smells. npm "script-shell" config mentions defaults but those -// are handled by run-script, not npm. So for now we have to tie tests to some -// pretty specific internals of runScript -const makeSpawnArgs = require('@npmcli/run-script/lib/make-spawn-args.js') +const isCmdRe = /(?:^|\\)cmd(?:\.exe)?$/i t.test('should run test script from package.json', async t => { const { npm } = await loadMockNpm(t, { - testdir: { + prefixDir: { 'package.json': JSON.stringify({ name: 'x', version: '1.2.3', @@ -25,13 +19,15 @@ t.test('should run test script from package.json', async t => { }, config: { loglevel: 'silent', + scriptShell: process.platform === 'win32' ? process.env.COMSPEC : 'sh', }, }) - const [scriptShell] = makeSpawnArgs({ path: npm.prefix }) - const script = spawk.spawn(scriptShell, (args) => { - t.ok(args.includes('node ./test-test.js "foo"'), 'ran test script with extra args') - return true - }) + + const scriptShell = npm.config.get('scriptShell') + const scriptArgs = isCmdRe.test(scriptShell) + ? ['/d', '/s', '/c', 'node ./test-test.js foo'] + : ['-c', 'node ./test-test.js foo'] + const script = spawk.spawn(scriptShell, scriptArgs) await npm.exec('test', ['foo']) t.ok(script.called, 'script ran') }) diff --git a/test/lib/commands/token.js b/test/lib/commands/token.js index 65a094a..af53f49 100644 --- a/test/lib/commands/token.js +++ b/test/lib/commands/token.js @@ -7,12 +7,10 @@ const mocks = { } const npm = { output: (...args) => mocks.output(...args), + config: { validate: () => {} }, } const mockToken = (otherMocks) => t.mock('../../../lib/commands/token.js', { - '../../../lib/utils/otplease.js': (opts, fn) => { - return Promise.resolve().then(() => fn(opts)) - }, '../../../lib/utils/read-user-info.js': mocks.readUserInfo, 'npm-profile': mocks.profile, ...otherMocks, @@ -24,6 +22,7 @@ const tokenWithMocks = (options = {}) => { for (const mod in mockRequests) { if (mod === 'npm') { mockRequests.npm = { ...npm, ...mockRequests.npm } + mockRequests.npm.config.validate = () => {} } else { if (typeof mockRequests[mod] === 'function') { mocks[mod] = mockRequests[mod] diff --git a/test/lib/commands/unpublish.js b/test/lib/commands/unpublish.js index 99d5529..cba7298 100644 --- a/test/lib/commands/unpublish.js +++ b/test/lib/commands/unpublish.js @@ -1,265 +1,211 @@ const t = require('tap') -const { fake: mockNpm } = require('../../fixtures/mock-npm') +const { load: loadMockNpm } = require('../../fixtures/mock-npm') -let result = '' -const noop = () => null -const versions = async () => { - return { - versions: { - '1.0.0': {}, - '1.0.1': {}, +const MockRegistry = require('@npmcli/mock-registry') +const user = 'test-user' +const pkg = 'test-package' +const auth = { '//registry.npmjs.org/:_authToken': 'test-auth-token' } + +t.test('no args --force success', async t => { + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + force: true, + ...auth, }, - } -} - -const singleVersion = async () => { - return { - versions: { - '1.0.0': {}, + prefixDir: { + 'package.json': JSON.stringify({ + name: pkg, + version: '1.0.0', + }, null, 2), }, - } -} - -const config = { - force: false, - loglevel: 'silly', -} - -const testDir = t.testdir({ - 'package.json': JSON.stringify({ - name: 'pkg', - version: '1.0.0', - }, null, 2), -}) - -const npm = mockNpm({ - localPrefix: testDir, - config, - output: (...msg) => { - result += msg.join('\n') - }, -}) - -const mocks = { - libnpmaccess: { lsPackages: noop }, - libnpmpublish: { unpublish: noop }, - 'npm-registry-fetch': { json: versions }, - '../../../lib/utils/otplease.js': async (opts, fn) => fn(opts), - '../../../lib/utils/get-identity.js': async () => 'foo', - 'proc-log': { silly () {}, verbose () {} }, -} - -t.afterEach(() => { - npm.localPrefix = testDir - result = '' - config['dry-run'] = false - config.force = false - config.loglevel = 'silly' -}) - -t.test('no args --force', async t => { - config.force = true - - const log = { - silly (title) { - t.equal(title, 'unpublish', 'should silly log args') - }, - verbose (title, msg) { - t.equal(title, 'unpublish', 'should have expected title') - t.match( - msg, - { name: 'pkg', version: '1.0.0' }, - 'should have msg printing package.json contents' - ) - }, - } - - const libnpmpublish = { - unpublish (spec, opts) { - t.ok(opts.log, 'gets passed a logger') - t.equal(spec.raw, 'pkg@1.0.0', 'should unpublish expected spec') - t.match( - opts, - { - publishConfig: undefined, - }, - 'should unpublish with expected opts' - ) - }, - } - - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - libnpmpublish, - 'proc-log': log, }) - const unpublish = new Unpublish(npm) - - await unpublish.exec([]) - - t.equal( - result, - '- pkg@1.0.0', - 'should output removed pkg@version on success' - ) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', + }) + const manifest = registry.manifest({ name: pkg }) + await registry.package({ manifest, query: { write: true } }) + registry.nock.delete(`/${pkg}/-rev/${manifest._rev}`).reply(201) + await npm.exec('unpublish', []) + t.equal(joinedOutput(), '- test-package@1.0.0') }) t.test('no args --force missing package.json', async t => { - config.force = true - - const testDir = t.testdir({}) - npm.localPrefix = testDir - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, + const { npm } = await loadMockNpm(t, { + config: { + force: true, + }, }) - const unpublish = new Unpublish(npm) await t.rejects( - unpublish.exec([]), - /Usage: npm unpublish/, + npm.exec('unpublish', []), + { code: 'EUSAGE' }, 'should throw usage instructions on missing package.json' ) }) -t.test('no args --force unknown error reading package.json', async t => { - config.force = true - - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - 'read-package-json': (path, cb) => cb(new Error('ERR')), +t.test('no args --force error reading package.json', async t => { + const { npm } = await loadMockNpm(t, { + config: { + force: true, + }, + prefixDir: { + 'package.json': '{ not valid json ]', + }, }) - const unpublish = new Unpublish(npm) await t.rejects( - unpublish.exec([]), - /ERR/, - 'should throw unknown error from reading package.json' + npm.exec('unpublish', []), + /Failed to parse json/, + 'should throw error from reading package.json' ) }) -t.test('no args', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - }) - const unpublish = new Unpublish(npm) +t.test('no args entire project', async t => { + const { npm } = await loadMockNpm(t) await t.rejects( - unpublish.exec([]), - /Refusing to delete entire project/, - 'should throw --force required error on no args' + npm.exec('unpublish', []), + /Refusing to delete entire project/ ) }) t.test('too many args', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - }) - const unpublish = new Unpublish(npm) + const { npm } = await loadMockNpm(t) await t.rejects( - unpublish.exec(['a', 'b']), - /Usage: npm unpublish/, + npm.exec('unpublish', ['a', 'b']), + { code: 'EUSAGE' }, 'should throw usage instructions if too many args' ) }) -t.test('unpublish <pkg>@version', async t => { - const log = { - silly (title, key, value) { - t.equal(title, 'unpublish', 'should silly log args') - if (key === 'spec') { - t.match(value, { name: 'pkg', rawSpec: '1.0.0' }) - } else { - t.equal(value, 'pkg@1.0.0', 'should log originally passed arg') - } +t.test('unpublish <pkg>@version not the last version', async t => { + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + force: true, + ...auth, }, - } - - const libnpmpublish = { - unpublish (spec, opts) { - t.ok(opts.log, 'gets passed a logger') - t.equal(spec.raw, 'pkg@1.0.0', 'should unpublish expected parsed spec') - }, - } - - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - libnpmpublish, - 'proc-log': log, }) - const unpublish = new Unpublish(npm) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', + }) + const manifest = registry.manifest({ + name: pkg, + packuments: ['1.0.0', '1.0.1'], + }) + await registry.package({ manifest, query: { write: true }, times: 3 }) + registry.nock.put(`/${pkg}/-rev/${manifest._rev}`, body => { + // sets latest and deletes version 1.0.1 + return body['dist-tags'].latest === '1.0.0' && body.versions['1.0.1'] === undefined + }).reply(201) + .intercept(`/${pkg}/-/${pkg}-1.0.1.tgz/-rev/${manifest._rev}`, 'DELETE').reply(201) - await unpublish.exec(['pkg@1.0.0']) + await npm.exec('unpublish', ['test-package@1.0.1']) + t.equal(joinedOutput(), '- test-package@1.0.1') +}) - t.equal( - result, - '- pkg@1.0.0', - 'should output removed pkg@version on success' +t.test('unpublish <pkg>@version last version', async t => { + const { npm } = await loadMockNpm(t, { + config: { + ...auth, + }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', + }) + const manifest = registry.manifest({ name: pkg }) + await registry.package({ manifest, query: { write: true } }) + + await t.rejects( + npm.exec('unpublish', ['test-package@1.0.0']), + /Refusing to delete the last version of the package/ ) }) t.test('no version found in package.json', async t => { - config.force = true - - const testDir = t.testdir({ - 'package.json': JSON.stringify({ - name: 'pkg', - }, null, 2), + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + force: true, + ...auth, + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: pkg, + }, null, 2), + }, }) - npm.localPrefix = testDir - - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', }) - const unpublish = new Unpublish(npm) + const manifest = registry.manifest({ name: pkg }) + await registry.package({ manifest, query: { write: true } }) + registry.nock.delete(`/${pkg}/-rev/${manifest._rev}`).reply(201) - await unpublish.exec([]) - t.equal( - result, - '- pkg', - 'should output removed pkg on success' - ) + await npm.exec('unpublish', []) + t.equal(joinedOutput(), '- test-package') }) t.test('unpublish <pkg> --force no version set', async t => { - config.force = true - - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + force: true, + ...auth, + }, }) - const unpublish = new Unpublish(npm) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', + }) + const manifest = registry.manifest({ name: pkg }) + await registry.package({ manifest, query: { write: true }, times: 2 }) + registry.nock.delete(`/${pkg}/-rev/${manifest._rev}`).reply(201) - await unpublish.exec(['pkg']) - - t.equal( - result, - '- pkg', - 'should output pkg removed' - ) + await npm.exec('unpublish', ['test-package']) + t.equal(joinedOutput(), '- test-package') }) t.test('silent', async t => { - config.loglevel = 'silent' - - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + force: true, + loglevel: 'silent', + ...auth, + }, }) - const unpublish = new Unpublish(npm) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', + }) + const manifest = registry.manifest({ + name: pkg, + packuments: ['1.0.0', '1.0.1'], + }) + await registry.package({ manifest, query: { write: true }, times: 3 }) + registry.nock.put(`/${pkg}/-rev/${manifest._rev}`, body => { + // sets latest and deletes version 1.0.1 + return body['dist-tags'].latest === '1.0.0' && body.versions['1.0.1'] === undefined + }).reply(201) + .delete(`/${pkg}/-/${pkg}-1.0.1.tgz/-rev/${manifest._rev}`).reply(201) - await unpublish.exec(['pkg@1.0.0']) - - t.equal( - result, - '', - 'should have no output' - ) + await npm.exec('unpublish', ['test-package@1.0.1']) + t.equal(joinedOutput(), '') }) t.test('workspaces', async t => { - const testDir = t.testdir({ + const prefixDir = { 'package.json': JSON.stringify({ - name: 'my-cool-pkg', + name: pkg, version: '1.0.0', workspaces: ['workspace-a', 'workspace-b', 'workspace-c'], }, null, 2), @@ -283,75 +229,183 @@ t.test('workspaces', async t => { version: '1.2.3-n', }), }, - }) - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - }) - const unpublish = new Unpublish(npm) + } t.test('no force', async t => { - npm.localPrefix = testDir + const { npm } = await loadMockNpm(t, { + config: { + workspaces: true, + }, + prefixDir, + }) await t.rejects( - unpublish.execWorkspaces([], []), - /--force/, - 'should require force' + npm.exec('unpublish', []), + /Refusing to delete entire project/ ) }) t.test('all workspaces --force', async t => { - npm.localPrefix = testDir - config.force = true - await unpublish.execWorkspaces([], []) - t.matchSnapshot(result, 'should output all workspaces') + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + workspaces: true, + force: true, + ...auth, + }, + prefixDir, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', + }) + const manifestA = registry.manifest({ name: 'workspace-a' }) + const manifestB = registry.manifest({ name: 'workspace-b' }) + const manifestN = registry.manifest({ name: 'workspace-n' }) + await registry.package({ manifest: manifestA, query: { write: true }, times: 2 }) + await registry.package({ manifest: manifestB, query: { write: true }, times: 2 }) + await registry.package({ manifest: manifestN, query: { write: true }, times: 2 }) + registry.nock.delete(`/workspace-a/-rev/${manifestA._rev}`).reply(201) + .delete(`/workspace-b/-rev/${manifestB._rev}`).reply(201) + .delete(`/workspace-n/-rev/${manifestN._rev}`).reply(201) + + await npm.exec('unpublish', []) + t.equal(joinedOutput(), '- workspace-a\n- workspace-b\n- workspace-n') }) t.test('one workspace --force', async t => { - npm.localPrefix = testDir - config.force = true - await unpublish.execWorkspaces([], ['workspace-a']) - t.matchSnapshot(result, 'should output one workspaces') + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + workspace: ['workspace-a'], + force: true, + ...auth, + }, + prefixDir, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', + }) + const manifestA = registry.manifest({ name: 'workspace-a' }) + await registry.package({ manifest: manifestA, query: { write: true }, times: 2 }) + registry.nock.delete(`/workspace-a/-rev/${manifestA._rev}`).reply(201) + + await npm.exec('unpublish', []) + t.equal(joinedOutput(), '- workspace-a') }) }) t.test('dryRun with spec', async t => { - config['dry-run'] = true - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - libnpmpublish: { unpublish: () => { - throw new Error('should not be called') - } }, + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + 'dry-run': true, + ...auth, + }, }) - const unpublish = new Unpublish(npm) - await unpublish.exec(['pkg@1.0.0']) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', + }) + const manifest = registry.manifest({ + name: pkg, + packuments: ['1.0.0', '1.0.1'], + }) + await registry.package({ manifest, query: { write: true } }) - t.equal( - result, - '- pkg@1.0.0', - 'should output removed pkg@version on success' - ) + await npm.exec('unpublish', ['test-package@1.0.1']) + t.equal(joinedOutput(), '- test-package@1.0.1') }) -t.test('dryRun with local package', async t => { - config['dry-run'] = true - config.force = true - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - libnpmpublish: { unpublish: () => { - throw new Error('should not be called') - } }, +t.test('dryRun with no args', async t => { + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + force: true, + 'dry-run': true, + ...auth, + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: pkg, + version: '1.0.0', + }, null, 2), + }, }) - const unpublish = new Unpublish(npm) - await unpublish.exec([]) - t.equal( - result, - '- pkg@1.0.0', - 'should output removed pkg@1.0.0 on success' - ) + + await npm.exec('unpublish', []) + t.equal(joinedOutput(), '- test-package@1.0.0') +}) + +t.test('publishConfig no spec', async t => { + const alternateRegistry = 'https://other.registry.npmjs.org' + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + force: true, + '//other.registry.npmjs.org/:_authToken': 'test-other-token', + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: pkg, + version: '1.0.0', + publishConfig: { + registry: alternateRegistry, + }, + }, null, 2), + }, + }) + + const registry = new MockRegistry({ + tap: t, + registry: alternateRegistry, + authorization: 'test-other-token', + }) + const manifest = registry.manifest({ name: pkg }) + await registry.package({ manifest, query: { write: true } }) + registry.nock.delete(`/${pkg}/-rev/${manifest._rev}`).reply(201) + await npm.exec('unpublish', []) + t.equal(joinedOutput(), '- test-package@1.0.0') +}) + +t.test('publishConfig with spec', async t => { + const alternateRegistry = 'https://other.registry.npmjs.org' + const { joinedOutput, npm } = await loadMockNpm(t, { + config: { + force: true, + '//other.registry.npmjs.org/:_authToken': 'test-other-token', + }, + prefixDir: { + 'package.json': JSON.stringify({ + name: pkg, + version: '1.0.0', + publishConfig: { + registry: alternateRegistry, + }, + }, null, 2), + }, + }) + + const registry = new MockRegistry({ + tap: t, + registry: alternateRegistry, + authorization: 'test-other-token', + }) + const manifest = registry.manifest({ name: pkg }) + await registry.package({ manifest, query: { write: true }, times: 2 }) + registry.nock.delete(`/${pkg}/-rev/${manifest._rev}`).reply(201) + await npm.exec('unpublish', ['test-package']) + t.equal(joinedOutput(), '- test-package') }) t.test('completion', async t => { + const { npm } = await loadMockNpm(t, { + config: { + ...auth, + }, + }) + + const unpublish = await npm.cmd('unpublish') const testComp = - async (t, { unpublish, argv, partialWord, expect, title }) => { + async (t, { argv, partialWord, expect, title }) => { const res = await unpublish.completion( { conf: { argv: { remain: argv } }, partialWord } ) @@ -359,114 +413,86 @@ t.test('completion', async t => { } t.test('completing with multiple versions from the registry', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - libnpmaccess: { - async lsPackages () { - return { - pkg: 'write', - bar: 'write', - } - }, - }, - 'npm-registry-fetch': { - async json () { - return { - versions: { - '1.0.0': {}, - '1.0.1': {}, - '2.0.0': {}, - }, - } - }, - }, + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', }) - const unpublish = new Unpublish(npm) + const manifest = registry.manifest({ + name: pkg, + packuments: ['1.0.0', '1.0.1'], + }) + await registry.package({ manifest, query: { write: true } }) + registry.whoami({ username: user }) + registry.getPackages({ team: user, packages: { [pkg]: 'write' } }) await testComp(t, { - unpublish, argv: ['npm', 'unpublish'], - partialWord: 'pkg', + partialWord: 'test-package', expect: [ - 'pkg@1.0.0', - 'pkg@1.0.1', - 'pkg@2.0.0', + 'test-package@1.0.0', + 'test-package@1.0.1', ], }) }) t.test('no versions retrieved', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - libnpmaccess: { - async lsPackages () { - return { - pkg: 'write', - bar: 'write', - } - }, - }, - 'npm-registry-fetch': { - async json () { - return { - versions: {}, - } - }, - }, + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', }) - const unpublish = new Unpublish(npm) + const manifest = registry.manifest({ name: pkg }) + manifest.versions = {} + await registry.package({ manifest, query: { write: true } }) + registry.whoami({ username: user }) + registry.getPackages({ team: user, packages: { [pkg]: 'write' } }) await testComp(t, { - unpublish, argv: ['npm', 'unpublish'], - partialWord: 'pkg', + partialWord: pkg, expect: [ - 'pkg', + pkg, ], title: 'should autocomplete package name only', }) }) t.test('packages starting with same letters', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - libnpmaccess: { - async lsPackages () { - return { - pkg: 'write', - pkga: 'write', - pkgb: 'write', - } - }, - }, + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', }) - const unpublish = new Unpublish(npm) + registry.whoami({ username: user }) + registry.getPackages({ team: user, + packages: { + [pkg]: 'write', + [`${pkg}a`]: 'write', + [`${pkg}b`]: 'write', + } }) await testComp(t, { - unpublish, argv: ['npm', 'unpublish'], - partialWord: 'pkg', + partialWord: pkg, expect: [ - 'pkg', - 'pkga', - 'pkgb', + pkg, + `${pkg}a`, + `${pkg}b`, ], }) }) t.test('no packages retrieved', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - libnpmaccess: { - async lsPackages () { - return {} - }, - }, + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', }) - const unpublish = new Unpublish(npm) + registry.whoami({ username: user }) + registry.getPackages({ team: user, packages: {} }) await testComp(t, { - unpublish, argv: ['npm', 'unpublish'], partialWord: 'pkg', expect: [], @@ -475,101 +501,46 @@ t.test('completion', async t => { }) t.test('no pkg name to complete', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - libnpmaccess: { - async lsPackages () { - return { - pkg: {}, - bar: {}, - } - }, - }, + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', }) - const unpublish = new Unpublish(npm) + registry.whoami({ username: user }) + registry.getPackages({ team: user, + packages: { + [pkg]: 'write', + [`${pkg}a`]: 'write', + } }) await testComp(t, { - unpublish, argv: ['npm', 'unpublish'], partialWord: undefined, - expect: ['pkg', 'bar'], + expect: [pkg, `${pkg}a`], title: 'should autocomplete with available package names from user', }) }) - t.test('no pkg names retrieved from user account', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - libnpmaccess: { - async lsPackages () { - return null - }, - }, - }) - const unpublish = new Unpublish(npm) - - await testComp(t, { - unpublish, - argv: ['npm', 'unpublish'], - partialWord: 'pkg', - expect: [], - title: 'should have no autocomplete', - }) - }) - t.test('logged out user', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - '../../../lib/utils/get-identity.js': () => Promise.reject(new Error('ERR')), + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', }) - const unpublish = new Unpublish(npm) + registry.whoami({ responseCode: 404 }) await testComp(t, { - unpublish, argv: ['npm', 'unpublish'], - partialWord: 'pkg', + partialWord: pkg, expect: [], }) }) t.test('too many args', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', mocks) - const unpublish = new Unpublish(npm) - await testComp(t, { - unpublish, argv: ['npm', 'unpublish', 'foo'], partialWord: undefined, expect: [], }) }) }) - -t.test('show error on unpublish <pkg>@version with package.json and the last version', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - 'npm-registry-fetch': { json: singleVersion }, - path: { resolve: () => testDir, join: () => testDir + '/package.json' }, - }) - const unpublish = new Unpublish(npm) - await t.rejects( - unpublish.exec(['pkg@1.0.0']), - 'Refusing to delete the last version of the package. ' + - 'It will block from republishing a new version for 24 hours.\n' + - 'Run with --force to do this.' - ) -}) - -t.test('show error on unpublish <pkg>@version when the last version', async t => { - const Unpublish = t.mock('../../../lib/commands/unpublish.js', { - ...mocks, - 'npm-registry-fetch': { json: singleVersion }, - }) - const unpublish = new Unpublish(npm) - await t.rejects( - unpublish.exec(['pkg@1.0.0']), - 'Refusing to delete the last version of the package. ' + - 'It will block from republishing a new version for 24 hours.\n' + - 'Run with --force to do this.' - ) -}) diff --git a/test/lib/commands/unstar.js b/test/lib/commands/unstar.js index fb3c269..ee31428 100644 --- a/test/lib/commands/unstar.js +++ b/test/lib/commands/unstar.js @@ -1,29 +1,62 @@ const t = require('tap') +const { load: loadMockNpm } = require('../../fixtures/mock-npm.js') +const MockRegistry = require('@npmcli/mock-registry') -t.test('unstar', async t => { - t.plan(3) +const pkgName = '@npmcli/test-package' +const authToken = 'test-auth-token' +const username = 'test-user' +const auth = { '//registry.npmjs.org/:_authToken': authToken } - class Star { - constructor (npm) { - this.npm = npm - } - - async exec (args) { - t.same(args, ['pkg'], 'should forward packages') - } - } - const Unstar = t.mock('../../../lib/commands/unstar.js', { - '../../../lib/commands/star.js': Star, - }) - - const unstar = new Unstar({ - config: { - set: (key, value) => { - t.equal(key, 'star.unstar', 'should set unstar config value') - t.equal(value, true, 'should set a truthy value') - }, - }, - }) - - await unstar.exec(['pkg']) +t.test('no args', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects( + npm.exec('unstar', []), + { code: 'EUSAGE' }, + 'should throw usage error' + ) +}) + +t.test('unstar a package unicode:false', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { unicode: false, ...auth }, + }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: authToken, + }) + const manifest = registry.manifest({ name: pkgName, users: { [username]: true } }) + await registry.package({ manifest, query: { write: true } }) + registry.whoami({ username }) + registry.star(manifest, {}) + + await npm.exec('unstar', [pkgName]) + t.equal( + joinedOutput(), + '( ) @npmcli/test-package', + 'should output unstarred package msg' + ) +}) + +t.test('unstar a package unicode:true', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { unicode: true, ...auth }, + }) + + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: authToken, + }) + const manifest = registry.manifest({ name: pkgName, users: { [username]: true } }) + await registry.package({ manifest, query: { write: true } }) + registry.whoami({ username }) + registry.star(manifest, {}) + + await npm.exec('unstar', [pkgName]) + t.equal( + joinedOutput(), + '☆ @npmcli/test-package', + 'should output unstarred package msg' + ) }) diff --git a/test/lib/commands/update.js b/test/lib/commands/update.js index 2b464bf..fe52554 100644 --- a/test/lib/commands/update.js +++ b/test/lib/commands/update.js @@ -17,7 +17,6 @@ const mocks = { reify () {} }, '../../../lib/utils/reify-finish.js': noop, - '../../../lib/utils/usage.js': () => 'usage instructions', } t.afterEach(() => { @@ -27,7 +26,7 @@ t.afterEach(() => { }) t.test('no args', async t => { - t.plan(5) + t.plan(4) npm.prefix = '/project/a' @@ -44,7 +43,6 @@ t.test('no args', async t => { }, 'should call arborist contructor with expected args' ) - t.match(log, {}, 'log is passed in') } reify ({ save, update }) { @@ -66,7 +64,7 @@ t.test('no args', async t => { }) t.test('with args', async t => { - t.plan(5) + t.plan(4) npm.prefix = '/project/a' config.save = true @@ -84,7 +82,6 @@ t.test('with args', async t => { }, 'should call arborist contructor with expected args' ) - t.match(log, {}, 'log is passed in') } reify ({ save, update }) { @@ -130,7 +127,7 @@ t.test('update --depth=<number>', async t => { }) t.test('update --global', async t => { - t.plan(3) + t.plan(2) const normalizePath = p => p.replace(/\\+/g, '/') const redactCwd = (path) => normalizePath(path) @@ -149,8 +146,6 @@ t.test('update --global', async t => { 'should call arborist contructor with expected options' ) - t.match(log, {}, 'log is passed in') - t.equal( redactCwd(path), '{CWD}/global/lib', diff --git a/test/lib/commands/version.js b/test/lib/commands/version.js index 9803538..154f6a6 100644 --- a/test/lib/commands/version.js +++ b/test/lib/commands/version.js @@ -1,3 +1,5 @@ +const { readFileSync, statSync } = require('fs') +const { resolve } = require('path') const t = require('tap') const { fake: mockNpm } = require('../../fixtures/mock-npm') const mockGlobals = require('../../fixtures/mock-globals.js') @@ -10,8 +12,13 @@ const config = { 'tag-version-prefix': 'v', json: false, } +const flatOptions = { + workspacesUpdate: true, +} const npm = mockNpm({ config, + flatOptions, + localPrefix: '', prefix: '', version: '1.0.0', output: (...msg) => { @@ -21,14 +28,16 @@ const npm = mockNpm({ }, }) const mocks = { - libnpmversion: noop, + '../../../lib/utils/reify-finish.js': noop, } const Version = t.mock('../../../lib/commands/version.js', mocks) const version = new Version(npm) t.afterEach(() => { + flatOptions.workspacesUpdate = true config.json = false + npm.localPrefix = '' npm.prefix = '' result = [] }) @@ -120,7 +129,7 @@ t.test('empty versions', t => { ...mocks, libnpmversion: (arg, opts) => { t.equal(arg, 'major', 'should forward expected value') - t.same( + t.match( opts, { path: '', @@ -271,6 +280,103 @@ t.test('empty versions', t => { }) t.test('with one arg, all workspaces', async t => { + const testDir = t.testdir({ + 'package.json': JSON.stringify( + { + name: 'workspaces-test', + version: '1.0.0', + workspaces: ['workspace-a', 'workspace-b'], + }, + null, + 2 + ), + 'workspace-a': { + 'package.json': JSON.stringify({ + name: 'workspace-a', + version: '1.0.0', + }), + }, + 'workspace-b': { + 'package.json': JSON.stringify({ + name: 'workspace-b', + version: '1.0.0', + }), + }, + }) + const Version = t.mock('../../../lib/commands/version.js', { + '../../../lib/utils/reify-finish.js': noop, + }) + npm.localPrefix = testDir + npm.prefix = testDir + const version = new Version(npm) + + await version.execWorkspaces(['major'], []) + t.same( + result, + ['workspace-a', 'v2.0.0', 'workspace-b', 'v2.0.0'], + 'outputs the new version for only the workspaces prefixed by the tagVersionPrefix' + ) + + t.matchSnapshot(readFileSync(resolve(testDir, 'package-lock.json'), 'utf8')) + }) + + t.test('with one arg, all workspaces, saves package.json', async t => { + const testDir = t.testdir({ + 'package.json': JSON.stringify( + { + name: 'workspaces-test', + version: '1.0.0', + workspaces: ['workspace-a', 'workspace-b'], + dependencies: { + 'workspace-a': '^1.0.0', + 'workspace-b': '^1.0.0', + }, + }, + null, + 2 + ), + 'workspace-a': { + 'package.json': JSON.stringify({ + name: 'workspace-a', + version: '1.0.0', + }), + }, + 'workspace-b': { + 'package.json': JSON.stringify({ + name: 'workspace-b', + version: '1.0.0', + }), + }, + }) + const Version = t.mock('../../../lib/commands/version.js', { + '../../../lib/utils/reify-finish.js': noop, + }) + config.save = true + npm.localPrefix = testDir + npm.prefix = testDir + const version = new Version(npm) + + await version.execWorkspaces(['major'], []) + t.same( + result, + ['workspace-a', 'v2.0.0', 'workspace-b', 'v2.0.0'], + 'outputs the new version for only the workspaces prefixed by the tagVersionPrefix' + ) + + t.matchSnapshot(readFileSync(resolve(testDir, 'package-lock.json'), 'utf8')) + }) + + t.test('too many args', async t => { + await t.rejects( + version.execWorkspaces(['foo', 'bar'], []), + /npm version/, + 'should throw usage instructions error' + ) + }) + + t.test('no workspaces-update', async t => { + flatOptions.workspacesUpdate = false + const libNpmVersionArgs = [] const testDir = t.testdir({ 'package.json': JSON.stringify( @@ -312,13 +418,10 @@ t.test('empty versions', t => { ['workspace-a', 'v2.0.0', 'workspace-b', 'v2.0.0'], 'outputs the new version for only the workspaces prefixed by the tagVersionPrefix' ) - }) - t.test('too many args', async t => { - await t.rejects( - version.execWorkspaces(['foo', 'bar'], []), - /npm version/, - 'should throw usage instructions error' + t.throws( + () => statSync(resolve(testDir, 'package-lock.json')), + 'should not have a lockfile since have not reified' ) }) }) diff --git a/test/lib/commands/view.js b/test/lib/commands/view.js index 035490a..d347bc9 100644 --- a/test/lib/commands/view.js +++ b/test/lib/commands/view.js @@ -1,4 +1,5 @@ const t = require('tap') +const { load: _loadMockNpm } = require('../../fixtures/mock-npm.js') t.cleanSnapshot = str => str .replace(/(published ).*?( ago)/g, '$1{TIME}$2') @@ -6,18 +7,6 @@ t.cleanSnapshot = str => str // run the same as tap does when running directly with node process.stdout.columns = undefined -const { fake: mockNpm } = require('../../fixtures/mock-npm') - -let logs -const cleanLogs = () => { - logs = '' - const fn = (...args) => { - logs += '\n' - args.map(el => logs += el) - } - console.log = fn -} - // 3 days. its never yesterday and never a week ago const yesterday = new Date(Date.now() - 1000 * 60 * 60 * 24 * 3) @@ -32,15 +21,19 @@ const packument = (nv, opts) => { const mocks = { red: { + _id: 'red@1.0.1', name: 'red', 'dist-tags': { '1.0.1': {}, }, time: { - unpublished: new Date(), + unpublished: { + time: '2012-12-20T00:00:00.000Z', + }, }, }, blue: { + _id: 'blue', name: 'blue', 'dist-tags': { latest: '1.0.0', @@ -68,7 +61,7 @@ const packument = (nv, opts) => { tarball: 'http://hm.blue.com/1.0.1.tgz', integrity: '---', fileCount: 1, - unpackedSize: 1, + unpackedSize: 1000, }, }, }, @@ -91,7 +84,7 @@ const packument = (nv, opts) => { tarball: 'http://hm.cyan.com/1.0.0.tgz', integrity: '---', fileCount: 1, - unpackedSize: 1, + unpackedSize: 1000000, }, }, '1.0.1': {}, @@ -177,7 +170,7 @@ const packument = (nv, opts) => { tarball: 'http://hm.green.com/1.0.0.tgz', integrity: '---', fileCount: 1, - unpackedSize: 1, + unpackedSize: 1000000000, }, }, '1.0.1': {}, @@ -262,287 +255,226 @@ const packument = (nv, opts) => { if (nv.type === 'git') { return mocks[nv.hosted.project] } + if (nv.raw === './blue') { + return mocks.blue + } return mocks[nv.name] } -t.beforeEach(cleanLogs) - -t.test('should log package info', async t => { - const View = t.mock('../../../lib/commands/view.js', { - pacote: { - packument, +const loadMockNpm = async function (t, opts = {}) { + const consoleLogs = [] + const mockNpm = await _loadMockNpm(t, { + mocks: { + pacote: { + packument, + }, }, - }) - const npm = mockNpm({ - config: { unicode: false }, - }) - const view = new View(npm) - - const ViewJson = t.mock('../../../lib/commands/view.js', { - pacote: { - packument, + globals: { + 'console.log': (...args) => { + consoleLogs.push(args) + }, }, + ...opts, }) - const jsonNpm = mockNpm({ - config: { - json: true, - tag: 'latest', - }, - }) - const viewJson = new ViewJson(jsonNpm) + return { ...mockNpm, consoleLogs } +} - const ViewUnicode = t.mock('../../../lib/commands/view.js', { - pacote: { - packument, - }, - }) - const unicodeNpm = mockNpm({ - config: { unicode: true }, - }) - const viewUnicode = new ViewUnicode(unicodeNpm) - - t.test('package from git', async t => { - await view.exec(['https://github.com/npm/green']) - t.matchSnapshot(logs) - }) - - t.test('package with license, bugs, repository and other fields', async t => { - await view.exec(['green@1.0.0']) - t.matchSnapshot(logs) - }) - - t.test('package with more than 25 deps', async t => { - await view.exec(['black@1.0.0']) - t.matchSnapshot(logs) - }) - - t.test('package with maintainers info as object', async t => { - await view.exec(['pink@1.0.0']) - t.matchSnapshot(logs) - }) - - t.test('package with homepage', async t => { - await view.exec(['orange@1.0.0']) - t.matchSnapshot(logs) - }) - - t.test('package with no versions', async t => { - await view.exec(['brown']) - t.equal(logs, '', 'no info to display') - }) - - t.test('package with no repo or homepage', async t => { - await view.exec(['blue@1.0.0']) - t.matchSnapshot(logs) - }) - - t.test('package with semver range', async t => { - await view.exec(['blue@^1.0.0']) - t.matchSnapshot(logs) - }) - - t.test('package with no modified time', async t => { - await viewUnicode.exec(['cyan@1.0.0']) - t.matchSnapshot(logs) - }) - - t.test('package with --json and semver range', async t => { - await viewJson.exec(['cyan@^1.0.0']) - t.matchSnapshot(logs) - }) - - t.test('package with --json and no versions', async t => { - await viewJson.exec(['brown']) - t.equal(logs, '', 'no info to display') - }) +t.test('package from git', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { unicode: false } }) + await npm.exec('view', ['https://github.com/npm/green']) + t.matchSnapshot(consoleLogs.join('\n')) }) -t.test('should log info of package in current working dir', async t => { - const testDir = t.testdir({ +t.test('deprecated package with license, bugs, repository and other fields', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { unicode: false } }) + await npm.exec('view', ['green@1.0.0']) + t.matchSnapshot(consoleLogs.join('\n')) +}) + +t.test('deprecated package with unicode', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { unicode: true } }) + await npm.exec('view', ['green@1.0.0']) + t.matchSnapshot(consoleLogs.join('\n')) +}) + +t.test('package with more than 25 deps', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { unicode: false } }) + await npm.exec('view', ['black@1.0.0']) + t.matchSnapshot(consoleLogs.join('\n')) +}) + +t.test('package with maintainers info as object', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { unicode: false } }) + await npm.exec('view', ['pink@1.0.0']) + t.matchSnapshot(consoleLogs.join('\n')) +}) + +t.test('package with homepage', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { unicode: false } }) + await npm.exec('view', ['orange@1.0.0']) + t.matchSnapshot(consoleLogs.join('\n')) +}) + +t.test('package with no versions', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { unicode: false } }) + await npm.exec('view', ['brown']) + t.equal(consoleLogs.join('\n'), '', 'no info to display') +}) + +t.test('package with no repo or homepage', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { unicode: false } }) + await npm.exec('view', ['blue@1.0.0']) + t.matchSnapshot(consoleLogs.join('\n')) +}) + +t.test('package with semver range', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { unicode: false } }) + await npm.exec('view', ['blue@^1.0.0']) + t.matchSnapshot(consoleLogs.join('\n')) +}) + +t.test('package with no modified time', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { unicode: false } }) + await npm.exec('view', ['cyan@1.0.0']) + t.matchSnapshot(consoleLogs.join('\n')) +}) + +t.test('package with --json and semver range', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { json: true } }) + await npm.exec('view', ['cyan@^1.0.0']) + t.matchSnapshot(consoleLogs.join('\n')) +}) + +t.test('package with --json and no versions', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { config: { json: true } }) + await npm.exec('view', ['brown']) + t.equal(consoleLogs.join('\n'), '', 'no info to display') +}) + +t.test('package in cwd', async t => { + const prefixDir = { 'package.json': JSON.stringify({ name: 'blue', version: '1.0.0', }, null, 2), - }) - - const View = t.mock('../../../lib/commands/view.js', { - pacote: { - packument, - }, - }) - const npm = mockNpm({ - prefix: testDir, - config: { - tag: '1.0.0', - }, - }) - const view = new View(npm) + } t.test('specific version', async t => { - await view.exec(['.@1.0.0']) - t.matchSnapshot(logs) + const { npm, consoleLogs } = await loadMockNpm(t, { prefixDir }) + await npm.exec('view', ['.@1.0.0']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('non-specific version', async t => { - await view.exec(['.']) - t.matchSnapshot(logs) + const { npm, consoleLogs } = await loadMockNpm(t, { prefixDir }) + await npm.exec('view', ['.']) + t.matchSnapshot(consoleLogs.join('\n')) + }) + + t.test('directory', async t => { + const { npm, consoleLogs } = await loadMockNpm(t, { prefixDir }) + await npm.exec('view', ['./blue']) + t.matchSnapshot(consoleLogs.join('\n')) }) }) -t.test('should log info by field name', async t => { - const ViewJson = t.mock('../../../lib/commands/view.js', { - pacote: { - packument, - }, +t.test('specific field names', async t => { + const { npm, consoleLogs } = await loadMockNpm(t) + t.afterEach(() => { + consoleLogs.length = 0 }) - const jsonNpm = mockNpm({ - config: { - tag: 'latest', - json: true, - }, - }) - - const viewJson = new ViewJson(jsonNpm) - - const View = t.mock('../../../lib/commands/view.js', { - pacote: { - packument, - }, - }) - const npm = mockNpm() - const view = new View(npm) - t.test('readme', async t => { - await view.exec(['yellow@1.0.0', 'readme']) - t.matchSnapshot(logs) + await npm.exec('view', ['yellow@1.0.0', 'readme']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('several fields', async t => { - await viewJson.exec(['yellow@1.0.0', 'name', 'version', 'foo[bar]']) - t.matchSnapshot(logs) + await npm.exec('view', ['yellow@1.0.0', 'name', 'version', 'foo[bar]']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('several fields with several versions', async t => { - await view.exec(['yellow@1.x.x', 'author']) - t.matchSnapshot(logs) + await npm.exec('view', ['yellow@1.x.x', 'author']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('nested field with brackets', async t => { - await viewJson.exec(['orange@1.0.0', 'dist[shasum]']) - t.matchSnapshot(logs) + await npm.exec('view', ['orange@1.0.0', 'dist[shasum]']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('maintainers with email', async t => { - await viewJson.exec(['yellow@1.0.0', 'maintainers', 'name']) - t.matchSnapshot(logs) + await npm.exec('view', ['yellow@1.0.0', 'maintainers', 'name']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('maintainers with url', async t => { - await viewJson.exec(['pink@1.0.0', 'maintainers']) - t.matchSnapshot(logs) + await npm.exec('view', ['pink@1.0.0', 'maintainers']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('unknown nested field ', async t => { - await view.exec(['yellow@1.0.0', 'dist.foobar']) - t.equal(logs, '', 'no info to display') + await npm.exec('view', ['yellow@1.0.0', 'dist.foobar']) + t.equal(consoleLogs.join('\n'), '', 'no info to display') }) t.test('array field - 1 element', async t => { - await view.exec(['purple@1.0.0', 'maintainers.name']) - t.matchSnapshot(logs) + await npm.exec('view', ['purple@1.0.0', 'maintainers.name']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('array field - 2 elements', async t => { - await view.exec(['yellow@1.x.x', 'maintainers.name']) - t.matchSnapshot(logs) + await npm.exec('view', ['yellow@1.x.x', 'maintainers.name']) + t.matchSnapshot(consoleLogs.join('\n')) }) }) t.test('throw error if global mode', async t => { - const View = t.mock('../../../lib/commands/view.js') - const npm = mockNpm({ - config: { - global: true, - tag: 'latest', - }, - }) - const view = new View(npm) + const { npm } = await loadMockNpm(t, { config: { global: true } }) await t.rejects( - view.exec([]), + npm.exec('view', []), /Cannot use view command in global mode./ ) }) t.test('throw ENOENT error if package.json missing', async t => { - const testDir = t.testdir({}) - - const View = t.mock('../../../lib/commands/view.js') - const npm = mockNpm({ - prefix: testDir, - }) - const view = new View(npm) + const { npm } = await loadMockNpm(t) await t.rejects( - view.exec([]), + npm.exec('view', []), { code: 'ENOENT' } ) }) -t.test('throw EJSONPARSE error if package.json not json', async t => { - const testDir = t.testdir({ - 'package.json': 'not json, nope, not even a little bit!', - }) - - const View = t.mock('../../../lib/commands/view.js') - const npm = mockNpm({ - prefix: testDir, - }) - const view = new View(npm) - await t.rejects( - view.exec([]), - { code: 'EJSONPARSE' } - ) -}) - t.test('throw error if package.json has no name', async t => { - const testDir = t.testdir({ - 'package.json': '{}', + const { npm } = await loadMockNpm(t, { + prefixDir: { + 'package.json': '{}', + }, }) - - const View = t.mock('../../../lib/commands/view.js') - const npm = mockNpm({ - prefix: testDir, - }) - const view = new View(npm) await t.rejects( - view.exec([]), + npm.exec('view', []), /Invalid package.json, no "name" field/ ) }) t.test('throws when unpublished', async t => { - const View = t.mock('../../../lib/commands/view.js', { - pacote: { - packument, - }, - }) - const npm = mockNpm({ - config: { - tag: '1.0.1', - }, - }) - const view = new View(npm) + const { npm } = await loadMockNpm(t) await t.rejects( - view.exec(['red']), - { code: 'E404' } + npm.exec('view', ['red']), + { code: 'E404', pkgid: 'red@1.0.1', message: 'Unpublished on 2012-12-20T00:00:00.000Z' } + ) +}) + +t.test('throws when version not matched', async t => { + const { npm } = await loadMockNpm(t) + await t.rejects( + npm.exec('view', ['blue@2.0.0']), + { code: 'E404', pkgid: 'blue@2.0.0', message: 'No match found for version 2.0.0' } ) }) t.test('workspaces', async t => { - t.beforeEach(() => { - warnMsg = undefined - config.json = false - }) - const testDir = t.testdir({ + const prefixDir = { 'package.json': JSON.stringify({ name: 'workspaces-test-package', version: '1.2.3', @@ -560,106 +492,103 @@ t.test('workspaces', async t => { version: '1.2.3', }), }, - }) - const View = t.mock('../../../lib/commands/view.js', { - pacote: { - packument, - }, - 'proc-log': { - warn: (msg) => { - warnMsg = msg - }, - silly: () => {}, - }, - }) - const config = { - unicode: false, - tag: 'latest', } - let warnMsg - const npm = mockNpm({ - config, - localPrefix: testDir, - }) - const view = new View(npm) t.test('all workspaces', async t => { - await view.execWorkspaces([], []) - t.matchSnapshot(logs) + const { npm, consoleLogs } = await loadMockNpm(t, { + prefixDir, + config: { unicode: false, workspaces: true }, + }) + await npm.exec('view', []) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('one specific workspace', async t => { - await view.execWorkspaces([], ['green']) - t.matchSnapshot(logs) + const { npm, consoleLogs } = await loadMockNpm(t, { + prefixDir, + config: { unicode: false, workspace: ['green'] }, + }) + await npm.exec('view', []) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('all workspaces --json', async t => { - config.json = true - await view.execWorkspaces([], []) - t.matchSnapshot(logs) + const { npm, consoleLogs } = await loadMockNpm(t, { + prefixDir, + config: { unicode: false, workspaces: true, json: true }, + }) + await npm.exec('view', []) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('all workspaces single field', async t => { - await view.execWorkspaces(['.', 'name'], []) - t.matchSnapshot(logs) + const { npm, consoleLogs } = await loadMockNpm(t, { + prefixDir, + config: { unicode: false, workspaces: true }, + }) + await npm.exec('view', ['.', 'name']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('all workspaces nonexistent field', async t => { - await view.execWorkspaces(['.', 'foo'], []) - t.matchSnapshot(logs) + const { npm, consoleLogs } = await loadMockNpm(t, { + prefixDir, + config: { unicode: false, workspaces: true }, + }) + await npm.exec('view', ['.', 'foo']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('all workspaces nonexistent field --json', async t => { - config.json = true - await view.execWorkspaces(['.', 'foo'], []) - t.matchSnapshot(logs) + const { npm, consoleLogs } = await loadMockNpm(t, { + prefixDir, + config: { unicode: false, workspaces: true, json: true }, + }) + await npm.exec('view', ['.', 'foo']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('all workspaces single field --json', async t => { - config.json = true - await view.execWorkspaces(['.', 'name'], []) - t.matchSnapshot(logs) + const { npm, consoleLogs } = await loadMockNpm(t, { + prefixDir, + config: { unicode: false, workspaces: true, json: true }, + }) + await npm.exec('view', ['.', 'name']) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('single workspace --json', async t => { - config.json = true - await view.execWorkspaces([], ['green']) - t.matchSnapshot(logs) + const { npm, consoleLogs } = await loadMockNpm(t, { + prefixDir, + config: { unicode: false, workspace: ['green'], json: true }, + }) + await npm.exec('view', []) + t.matchSnapshot(consoleLogs.join('\n')) }) t.test('remote package name', async t => { - await view.execWorkspaces(['pink'], []) - t.matchSnapshot(warnMsg) - t.matchSnapshot(logs) + const { npm, logs, consoleLogs } = await loadMockNpm(t, { + prefixDir, + config: { unicode: false, workspaces: true }, + }) + await npm.exec('view', ['pink']) + t.matchSnapshot(consoleLogs.join('\n')) + t.matchSnapshot(logs.warn, 'should have warning of ignoring workspaces') }) }) t.test('completion', async t => { - const View = t.mock('../../../lib/commands/view.js', { - pacote: { - packument, - }, - }) - const npm = mockNpm({ - config: { - tag: '1.0.1', - }, - }) - const view = new View(npm) + const { npm } = await loadMockNpm(t) + const view = await npm.cmd('view') const res = await view.completion({ conf: { argv: { remain: ['npm', 'view', 'green@1.0.0'] } }, }) t.ok(res, 'returns back fields') }) -t.test('no registry completion', async t => { - const View = t.mock('../../../lib/commands/view.js') - const npm = mockNpm({ - config: { - tag: '1.0.1', - }, - }) - const view = new View(npm) +t.test('no package completion', async t => { + const { npm } = await loadMockNpm(t) + const view = await npm.cmd('view') const res = await view.completion({ conf: { argv: { remain: ['npm', 'view'] } } }) t.notOk(res, 'there is no package completion') t.end() diff --git a/test/lib/commands/whoami.js b/test/lib/commands/whoami.js index 66c3f0c..8291b09 100644 --- a/test/lib/commands/whoami.js +++ b/test/lib/commands/whoami.js @@ -1,24 +1,94 @@ const t = require('tap') -const { load: _loadMockNpm } = require('../../fixtures/mock-npm') +const { load: loadMockNpm } = require('../../fixtures/mock-npm') +const MockRegistry = require('@npmcli/mock-registry') +const nock = require('nock') const username = 'foo' -const loadMockNpm = (t, options) => _loadMockNpm(t, { - mocks: { - '../../lib/utils/get-identity.js': () => Promise.resolve(username), - }, - ...options, -}) +const auth = { '//registry.npmjs.org/:_authToken': 'test-auth-token' } -t.test('npm whoami', async (t) => { - const { npm, joinedOutput } = await loadMockNpm(t) +t.test('npm whoami', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: auth }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', + }) + registry.whoami({ username }) await npm.exec('whoami', []) t.equal(joinedOutput(), username, 'should print username') }) -t.test('npm whoami --json', async (t) => { +t.test('npm whoami --json', async t => { const { npm, joinedOutput } = await loadMockNpm(t, { - config: { json: true }, + config: { + json: true, + ...auth, + }, }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + authorization: 'test-auth-token', + }) + registry.whoami({ username }) await npm.exec('whoami', []) t.equal(JSON.parse(joinedOutput()), username, 'should print username') }) + +t.test('npm whoami using mTLS', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { config: { + '//registry.npmjs.org/:certfile': '/some.cert', + '//registry.npmjs.org/:keyfile': '/some.key', + } }) + const registry = new MockRegistry({ + tap: t, + registry: npm.config.get('registry'), + }) + registry.whoami({ username }) + await npm.exec('whoami', []) + t.equal(joinedOutput(), username, 'should print username') +}) + +t.test('credentials from token', async t => { + const { npm, joinedOutput } = await loadMockNpm(t, { + config: { + '//registry.npmjs.org/:username': username, + '//registry.npmjs.org/:_password': 'hunter2', + }, + }) + await npm.exec('whoami', []) + t.equal(joinedOutput(), username, 'should print username') +}) + +t.test('not logged in', async t => { + const { npm } = await loadMockNpm(t, { + config: { + json: true, + }, + }) + await t.rejects(npm.exec('whoami', []), { code: 'ENEEDAUTH' }) +}) + +t.test('non-string username in response', async t => { + nock.disableNetConnect() + t.teardown(() => { + nock.enableNetConnect() + }) + + const server = nock('https://registry.npmjs.org', { + reqheaders: { + authorization: 'Bearer abcd1234', + }, + }) + .get('/-/whoami') + .reply(200, { username: null }) + + const { npm } = await loadMockNpm(t, { + config: { + '//registry.npmjs.org/:_authToken': 'abcd1234', + }, + }) + + await t.rejects(npm.exec('whoami', []), { code: 'ENEEDAUTH' }) + t.ok(server.isDone()) +}) diff --git a/test/lib/docs.js b/test/lib/docs.js new file mode 100644 index 0000000..166651f --- /dev/null +++ b/test/lib/docs.js @@ -0,0 +1,98 @@ +const t = require('tap') +const { join, resolve, basename, extname, dirname } = require('path') +const fs = require('fs/promises') +const localeCompare = require('@isaacs/string-locale-compare')('en') +const docs = require('@npmcli/docs') + +const { load: loadMockNpm } = require('../fixtures/mock-npm.js') +const mockGlobals = require('../fixtures/mock-globals.js') +const { definitions } = require('../../lib/utils/config/index.js') +const cmdList = require('../../lib/utils/cmd-list.js') +const pkg = require('../../package.json') + +t.test('command list', async t => { + for (const [key, value] of Object.entries(cmdList)) { + t.matchSnapshot(value, key) + } +}) + +t.test('shorthands', async t => { + t.matchSnapshot(docs.shorthands(docs.TAGS.SHORTHANDS, {}), 'docs') +}) + +t.test('config', async t => { + const keys = Object.keys(definitions) + const flat = Object.entries(definitions).filter(([_, d]) => d.flatten).map(([k]) => k) + const notFlat = keys.filter(k => !flat.includes(k)) + t.matchSnapshot(keys, 'all keys') + t.matchSnapshot(flat, 'keys that are flattened') + t.matchSnapshot(notFlat, 'keys that are not flattened') + t.matchSnapshot(docs.config(docs.TAGS.CONFIG, {}), 'all definitions') +}) + +t.test('basic usage', async t => { + mockGlobals(t, { process: { platform: 'posix' } }) + + t.cleanSnapshot = str => str + .split(dirname(dirname(__dirname))).join('{BASEDIR}') + .split(pkg.version).join('{VERSION}') + + // snapshot basic usage without commands since all the command snapshots + // are generated in the following test + const { npm } = await loadMockNpm(t, { + mocks: { + '../../lib/utils/cmd-list.js': { commands: [] }, + }, + }) + + npm.config.set('userconfig', '/some/config/file/.npmrc') + t.matchSnapshot(await npm.usage) +}) + +t.test('usage', async t => { + const readdir = async (dir, ext) => { + const files = await fs.readdir(dir) + return files.filter(f => extname(f) === ext).map(f => basename(f, ext)) + } + + const fsCommands = await readdir(resolve(__dirname, '../../lib/commands'), '.js') + const docsCommands = await readdir(join(docs.paths.content, 'commands'), docs.DOC_EXT) + const bareCommands = ['npm', 'npx'] + + // XXX: These extra commands exist as js files but not as docs pages + const allDocs = docsCommands.concat(['get', 'set', 'll']).map(n => n.replace('npm-', '')) + + // ensure that the list of js files in commands, docs files, and the command list + // are all in sync. eg, this will error if a command is removed but not its docs file + t.strictSame( + fsCommands.sort(localeCompare), + cmdList.allCommands, + 'command list and fs are the same' + ) + t.strictSame( + allDocs.filter(f => !bareCommands.includes(f)).sort(localeCompare), + cmdList.allCommands, + 'command list and docs files are the same' + ) + + // use the list of files from the docs since those include the special cases + // for the bare npm and npx usage + for (const cmd of allDocs) { + t.test(cmd, async t => { + let output = null + if (!bareCommands.includes(cmd)) { + const { npm } = await loadMockNpm(t) + const impl = await npm.cmd(cmd) + output = impl.usage + } + + const usage = docs.usage(docs.TAGS.USAGE, { path: cmd }) + const params = docs.params(docs.TAGS.CONFIG, { path: cmd }) + .split('\n') + .filter(l => l.startsWith('#### ')) + .join('\n') || 'NO PARAMS' + + t.matchSnapshot([output, usage, params].filter(Boolean).join('\n\n')) + }) + } +}) diff --git a/test/lib/lifecycle-cmd.js b/test/lib/lifecycle-cmd.js index eb03f19..2201119 100644 --- a/test/lib/lifecycle-cmd.js +++ b/test/lib/lifecycle-cmd.js @@ -8,6 +8,9 @@ const npm = { return 'called the right thing' } }, + config: { + validate: () => {}, + }, } t.test('create a lifecycle command', async t => { t.plan(5) diff --git a/test/lib/load-all-commands.js b/test/lib/load-all-commands.js index 248c81a..aaf6a69 100644 --- a/test/lib/load-all-commands.js +++ b/test/lib/load-all-commands.js @@ -5,11 +5,10 @@ const t = require('tap') const util = require('util') const { load: loadMockNpm } = require('../fixtures/mock-npm.js') -const { cmdList } = require('../../lib/utils/cmd-list.js') +const { allCommands } = require('../../lib/utils/cmd-list.js') t.test('load each command', async t => { - t.plan(cmdList.length) - for (const cmd of cmdList.sort((a, b) => a.localeCompare(b, 'en'))) { + for (const cmd of allCommands) { t.test(cmd, async t => { const { npm, outputs } = await loadMockNpm(t, { config: { usage: true }, @@ -28,12 +27,11 @@ t.test('load each command', async t => { ) t.ok(impl.description, 'implementation has a description') t.ok(impl.name, 'implementation has a name') + t.equal(cmd, impl.name, 'command list and name are the same') + t.ok(impl.ignoreImplicitWorkspace !== undefined, 'implementation has ignoreImplictWorkspace') t.match(impl.usage, cmd, 'usage contains the command') await npm.exec(cmd, []) t.match(outputs[0][0], impl.usage, 'usage is what is output') - // This ties usage to a snapshot so we have to re-run snap if usage - // changes, which rebuilds the man pages - t.matchSnapshot(outputs[0][0]) }) } }) diff --git a/test/lib/load-all.js b/test/lib/load-all.js deleted file mode 100644 index e5d7b55..0000000 --- a/test/lib/load-all.js +++ /dev/null @@ -1,31 +0,0 @@ -const t = require('tap') -const glob = require('glob') -const { resolve } = require('path') -const { load: loadMockNpm } = require('../fixtures/mock-npm') - -const full = process.env.npm_lifecycle_event === 'check-coverage' - -if (!full) { - t.pass('nothing to do here, not checking for full coverage') -} else { - t.test('load all', async (t) => { - const { npm } = await loadMockNpm(t, { }) - - t.teardown(() => { - const exitHandler = require('../../lib/utils/exit-handler.js') - exitHandler.setNpm(npm) - exitHandler() - }) - - t.test('load all the files', t => { - // just load all the files so we measure coverage for the missing tests - const dir = resolve(__dirname, '../../lib') - for (const f of glob.sync(`${dir}/**/*.js`)) { - require(f) - t.pass('loaded ' + f) - } - t.pass('loaded all files') - t.end() - }) - }) -} diff --git a/test/lib/npm.js b/test/lib/npm.js index 2a0c5a8..f850ff6 100644 --- a/test/lib/npm.js +++ b/test/lib/npm.js @@ -1,8 +1,10 @@ const t = require('tap') -const { resolve, dirname } = require('path') +const { resolve, dirname, join } = require('path') +const fs = require('fs') const { load: loadMockNpm } = require('../fixtures/mock-npm.js') const mockGlobals = require('../fixtures/mock-globals') +const { commands } = require('../../lib/utils/cmd-list.js') // delete this so that we don't have configs from the fact that it // is being run by 'npm test' @@ -43,16 +45,14 @@ t.test('not yet loaded', async t => { set: Function, }, version: String, - shelloutCommands: Array, }) t.throws(() => npm.config.set('foo', 'bar')) t.throws(() => npm.config.get('foo')) t.same(logs, []) - t.end() }) t.test('npm.load', async t => { - t.test('load error', async t => { + await t.test('load error', async t => { const { npm } = await loadMockNpm(t, { load: false }) const loadError = new Error('load error') npm.config.load = async () => { @@ -75,9 +75,12 @@ t.test('npm.load', async t => { t.equal(npm.loadErr, loadError) }) - t.test('basic loading', async t => { - const { npm, logs, prefix: dir, cache } = await loadMockNpm(t, { - testdir: { node_modules: {} }, + await t.test('basic loading', async t => { + const { npm, logs, prefix: dir, cache, other } = await loadMockNpm(t, { + prefixDir: { node_modules: {} }, + otherDirs: { + newCache: {}, + }, }) t.equal(npm.loaded, true) @@ -94,10 +97,9 @@ t.test('npm.load', async t => { mockGlobals(t, { process: { platform: 'posix' } }) t.equal(resolve(npm.cache), resolve(cache), 'cache is cache') - const newCache = t.testdir() - npm.cache = newCache - t.equal(npm.config.get('cache'), newCache, 'cache setter sets config') - t.equal(npm.cache, newCache, 'cache getter gets new config') + npm.cache = other.newCache + t.equal(npm.config.get('cache'), other.newCache, 'cache setter sets config') + t.equal(npm.cache, other.newCache, 'cache getter gets new config') t.equal(npm.lockfileVersion, 2, 'lockfileVersion getter') t.equal(npm.prefix, npm.localPrefix, 'prefix is local prefix') t.not(npm.prefix, npm.globalPrefix, 'prefix is not global prefix') @@ -138,11 +140,12 @@ t.test('npm.load', async t => { t.equal(tmp, npm.tmp, 'getter only generates it once') }) - t.test('forceful loading', async t => { - mockGlobals(t, { - 'process.argv': [...process.argv, '--force', '--color', 'always'], + await t.test('forceful loading', async t => { + const { logs } = await loadMockNpm(t, { + globals: { + 'process.argv': [...process.argv, '--force', '--color', 'always'], + }, }) - const { logs } = await loadMockNpm(t) t.match(logs.warn, [ [ 'using --force', @@ -151,25 +154,23 @@ t.test('npm.load', async t => { ]) }) - t.test('node is a symlink', async t => { + await t.test('node is a symlink', async t => { const node = process.platform === 'win32' ? 'node.exe' : 'node' - mockGlobals(t, { - 'process.argv': [ - node, - process.argv[1], - '--usage', - '--scope=foo', - 'token', - 'revoke', - 'blergggg', - ], - }) const { npm, logs, outputs, prefix } = await loadMockNpm(t, { - testdir: { + prefixDir: { bin: t.fixture('symlink', dirname(process.execPath)), }, globals: ({ prefix }) => ({ 'process.env.PATH': resolve(prefix, 'bin'), + 'process.argv': [ + node, + process.argv[1], + '--usage', + '--scope=foo', + 'token', + 'revoke', + 'blergggg', + ], }), }) @@ -181,6 +182,9 @@ t.test('npm.load', async t => { ], [ ['npm:load:whichnode', /Completed in [0-9.]+ms/], ['node symlink', resolve(prefix, 'bin', node)], + ['title', 'npm token revoke blergggg'], + ['argv', '"--usage" "--scope" "foo" "token" "revoke" "blergggg"'], + ['logfile', /logs-max:\d+ dir:.*/], ['logfile', /.*-debug-0.log/], ['npm:load', /Completed in [0-9.]+ms/], ]) @@ -225,19 +229,10 @@ t.test('npm.load', async t => { t.same(outputs, [['scope=@foo\n\u2010not-a-dash=undefined']]) }) - t.test('--no-workspaces with --workspace', async t => { - mockGlobals(t, { - 'process.argv': [ - process.execPath, - process.argv[1], - '--color', 'false', - '--workspaces', 'false', - '--workspace', 'a', - ], - }) + await t.test('--no-workspaces with --workspace', async t => { const { npm } = await loadMockNpm(t, { load: false, - testdir: { + prefixDir: { packages: { a: { 'package.json': JSON.stringify({ @@ -253,6 +248,15 @@ t.test('npm.load', async t => { workspaces: ['./packages/*'], }), }, + globals: { + 'process.argv': [ + process.execPath, + process.argv[1], + '--color', 'false', + '--workspaces', 'false', + '--workspace', 'a', + ], + }, }) await t.rejects( npm.exec('run', []), @@ -260,17 +264,9 @@ t.test('npm.load', async t => { ) }) - t.test('workspace-aware configs and commands', async t => { - mockGlobals(t, { - 'process.argv': [ - process.execPath, - process.argv[1], - '--color', 'false', - '--workspaces', 'true', - ], - }) + await t.test('workspace-aware configs and commands', async t => { const { npm, outputs } = await loadMockNpm(t, { - testdir: { + prefixDir: { packages: { a: { 'package.json': JSON.stringify({ @@ -293,6 +289,14 @@ t.test('npm.load', async t => { workspaces: ['./packages/*'], }), }, + globals: { + 'process.argv': [ + process.execPath, + process.argv[1], + '--color', 'false', + '--workspaces', 'true', + ], + }, }) // verify that calling the command with a short name still sets @@ -316,20 +320,9 @@ t.test('npm.load', async t => { ) }) - t.test('workspaces in global mode', async t => { - mockGlobals(t, { - 'process.argv': [ - process.execPath, - process.argv[1], - '--color', - 'false', - '--workspaces', - '--global', - 'true', - ], - }) + await t.test('workspaces in global mode', async t => { const { npm } = await loadMockNpm(t, { - testdir: { + prefixDir: { packages: { a: { 'package.json': JSON.stringify({ @@ -352,6 +345,17 @@ t.test('npm.load', async t => { workspaces: ['./packages/*'], }), }, + globals: { + 'process.argv': [ + process.execPath, + process.argv[1], + '--color', + 'false', + '--workspaces', + '--global', + 'true', + ], + }, }) // verify that calling the command with a short name still sets // the npm.command property to the full canonical name of the cmd. @@ -365,68 +369,112 @@ t.test('npm.load', async t => { t.test('set process.title', async t => { t.test('basic title setting', async t => { - mockGlobals(t, { - 'process.argv': [ - process.execPath, - process.argv[1], - '--usage', - '--scope=foo', - 'ls', - ], + const { npm } = await loadMockNpm(t, { + globals: { + 'process.argv': [ + process.execPath, + process.argv[1], + '--usage', + '--scope=foo', + 'ls', + ], + }, }) - const { npm } = await loadMockNpm(t) t.equal(npm.title, 'npm ls') t.equal(process.title, 'npm ls') }) t.test('do not expose token being revoked', async t => { - mockGlobals(t, { - 'process.argv': [ - process.execPath, - process.argv[1], - '--usage', - '--scope=foo', - 'token', - 'revoke', - 'deadbeefcafebad', - ], + const { npm } = await loadMockNpm(t, { + globals: { + 'process.argv': [ + process.execPath, + process.argv[1], + '--usage', + '--scope=foo', + 'token', + 'revoke', + `npm_${'a'.repeat(36)}`, + ], + }, }) - const { npm } = await loadMockNpm(t) - t.equal(npm.title, 'npm token revoke ***') - t.equal(process.title, 'npm token revoke ***') + t.equal(npm.title, 'npm token revoke npm_***') + t.equal(process.title, 'npm token revoke npm_***') }) t.test('do show *** unless a token is actually being revoked', async t => { - mockGlobals(t, { - 'process.argv': [ - process.execPath, - process.argv[1], - '--usage', - '--scope=foo', - 'token', - 'revoke', - ], + const { npm } = await loadMockNpm(t, { + globals: { + 'process.argv': [ + process.execPath, + process.argv[1], + '--usage', + '--scope=foo', + 'token', + 'revoke', + 'notatoken', + ], + }, }) - const { npm } = await loadMockNpm(t) - t.equal(npm.title, 'npm token revoke') - t.equal(process.title, 'npm token revoke') + t.equal(npm.title, 'npm token revoke notatoken') + t.equal(process.title, 'npm token revoke notatoken') }) }) -t.test('debug-log', async t => { - const { npm, debugFile } = await loadMockNpm(t, { load: false }) +t.test('debug log', async t => { + t.test('writes log file', async t => { + const { npm, debugFile } = await loadMockNpm(t, { load: false }) - const log1 = ['silly', 'test', 'before load'] - const log2 = ['silly', 'test', 'after load'] + const log1 = ['silly', 'test', 'before load'] + const log2 = ['silly', 'test', 'after load'] - process.emit('log', ...log1) - await npm.load() - process.emit('log', ...log2) + process.emit('log', ...log1) + await npm.load() + process.emit('log', ...log2) - const debug = await debugFile() - t.equal(npm.logFiles.length, 1, 'one debug file') - t.match(debug, log1.join(' '), 'before load appears') - t.match(debug, log2.join(' '), 'after load log appears') + const debug = await debugFile() + t.equal(npm.logFiles.length, 1, 'one debug file') + t.match(debug, log1.join(' '), 'before load appears') + t.match(debug, log2.join(' '), 'after load log appears') + }) + + t.test('can load with bad dir', async t => { + const { npm, testdir } = await loadMockNpm(t, { + load: false, + config: { + 'logs-dir': (c) => join(c.testdir, 'my_logs_dir'), + }, + }) + const logsDir = join(testdir, 'my_logs_dir') + + // make logs dir a file before load so it files + fs.writeFileSync(logsDir, 'A_TEXT_FILE') + await t.resolves(npm.load(), 'loads with invalid logs dir') + + t.equal(npm.logFiles.length, 0, 'no log files array') + t.strictSame(fs.readFileSync(logsDir, 'utf-8'), 'A_TEXT_FILE') + }) +}) + +t.test('cache dir', async t => { + t.test('creates a cache dir', async t => { + const { npm } = await loadMockNpm(t) + + t.ok(fs.existsSync(npm.cache), 'cache dir exists') + }) + + t.test('can load with a bad cache dir', async t => { + const { npm, cache } = await loadMockNpm(t, { + load: false, + // The easiest way to make mkdir(cache) fail is to make it a file. + // This will have the same effect as if its read only or inaccessible. + cacheDir: 'A_TEXT_FILE', + }) + + await t.resolves(npm.load(), 'loads with cache dir as a file') + + t.equal(fs.readFileSync(cache, 'utf-8'), 'A_TEXT_FILE') + }) }) t.test('timings', async t => { @@ -454,51 +502,65 @@ t.test('timings', async t => { t.notOk(npm.unfinishedTimers.has('foo'), 'foo timer is gone') t.notOk(npm.unfinishedTimers.has('bar'), 'bar timer is gone') t.match(npm.finishedTimers, { foo: Number, bar: Number, npm: Number }) - t.end() }) t.test('writes timings file', async t => { - const { npm, timingFile } = await loadMockNpm(t, { + const { npm, cache, timingFile } = await loadMockNpm(t, { config: { timing: true }, }) process.emit('time', 'foo') process.emit('timeEnd', 'foo') process.emit('time', 'bar') - npm.unload() + npm.writeTimingFile() + t.match(npm.timingFile, cache) + t.match(npm.timingFile, /-timing.json$/) const timings = await timingFile() t.match(timings, { - command: [], - logfile: String, - logfiles: [String], - version: String, - unfinished: { + metadata: { + command: [], + logfiles: [String], + version: String, + }, + unfinishedTimers: { bar: [Number, Number], npm: [Number, Number], }, - foo: Number, - 'npm:load': Number, + timers: { + foo: Number, + 'npm:load': Number, + }, }) }) t.test('does not write timings file with timers:false', async t => { const { npm, timingFile } = await loadMockNpm(t, { - config: { false: true }, + config: { timing: false }, }) - npm.unload() + npm.writeTimingFile() await t.rejects(() => timingFile()) }) + + const timingDisplay = [ + [{ loglevel: 'silly' }, true, false], + [{ loglevel: 'silly', timing: true }, true, true], + [{ loglevel: 'silent', timing: true }, false, false], + ] + + for (const [config, expectedDisplay, expectedTiming] of timingDisplay) { + const msg = `${JSON.stringify(config)}, display:${expectedDisplay}, timing:${expectedTiming}` + await t.test(`timing display: ${msg}`, async t => { + const { display } = await loadMockNpm(t, { config }) + t.equal(!!display.length, expectedDisplay, 'display') + t.equal(!!display.timing.length, expectedTiming, 'timing display') + }) + } }) t.test('output clears progress and console.logs the message', async t => { - t.plan(2) + t.plan(4) let showingProgress = true const logs = [] - mockGlobals(t, { - 'console.log': (...args) => { - t.equal(showingProgress, false, 'should not be showing progress right now') - logs.push(args) - }, - }) + const errors = [] const { npm } = await loadMockNpm(t, { load: false, mocks: { @@ -507,16 +569,211 @@ t.test('output clears progress and console.logs the message', async t => { showProgress: () => showingProgress = true, }, }, + globals: { + 'console.log': (...args) => { + t.equal(showingProgress, false, 'should not be showing progress right now') + logs.push(args) + }, + 'console.error': (...args) => { + t.equal(showingProgress, false, 'should not be showing progress right now') + errors.push(args) + }, + }, }) npm.originalOutput('hello') + npm.originalOutputError('error') + t.match(logs, [['hello']]) - t.end() + t.match(errors, [['error']]) }) -t.test('unknown command', async t => { +t.test('aliases and typos', async t => { const { npm } = await loadMockNpm(t, { load: false }) + await t.rejects(npm.cmd('thisisnotacommand'), { code: 'EUNKNOWNCOMMAND' }) + await t.rejects(npm.cmd(''), { code: 'EUNKNOWNCOMMAND' }) + await t.rejects(npm.cmd('birthday'), { code: 'EUNKNOWNCOMMAND' }) + await t.resolves(npm.cmd('it'), { name: 'install-test' }) + await t.resolves(npm.cmd('installTe'), { name: 'install-test' }) + await t.resolves(npm.cmd('access'), { name: 'access' }) +}) + +t.test('explicit workspace rejection', async t => { + const mock = await loadMockNpm(t, { + prefixDir: { + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + scripts: { test: 'echo test a' }, + }), + }, + }, + 'package.json': JSON.stringify({ + name: 'root', + version: '1.0.0', + workspaces: ['./packages/a'], + }), + }, + globals: { + 'process.argv': [ + process.execPath, + process.argv[1], + '--color', 'false', + '--workspace', './packages/a', + ], + }, + }) await t.rejects( - npm.cmd('thisisnotacommand'), - { code: 'EUNKNOWNCOMMAND' } + mock.npm.exec('ping', []), + /This command does not support workspaces/ ) }) + +t.test('implicit workspace rejection', async t => { + const mock = await loadMockNpm(t, { + prefixDir: { + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + scripts: { test: 'echo test a' }, + }), + }, + }, + 'package.json': JSON.stringify({ + name: 'root', + version: '1.0.0', + workspaces: ['./packages/a'], + }), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => join(prefix, 'packages', 'a'), + 'process.argv': [ + process.execPath, + process.argv[1], + '--color', 'false', + '--workspace', './packages/a', + ], + }), + }) + await t.rejects( + mock.npm.exec('team', []), + /This command does not support workspaces/ + ) +}) + +t.test('implicit workspace accept', async t => { + const mock = await loadMockNpm(t, { + prefixDir: { + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + scripts: { test: 'echo test a' }, + }), + }, + }, + 'package.json': JSON.stringify({ + name: 'root', + version: '1.0.0', + workspaces: ['./packages/a'], + }), + }, + globals: ({ prefix }) => ({ + 'process.cwd': () => join(prefix, 'packages', 'a'), + 'process.argv': [ + process.execPath, + process.argv[1], + '--color', 'false', + ], + }), + }) + await t.rejects(mock.npm.exec('org', []), /.*Usage/) +}) + +t.test('usage', async t => { + t.test('with browser', async t => { + mockGlobals(t, { process: { platform: 'posix' } }) + const { npm } = await loadMockNpm(t) + const usage = await npm.usage + npm.config.set('viewer', 'browser') + const browserUsage = await npm.usage + t.notMatch(usage, '(in a browser)') + t.match(browserUsage, '(in a browser)') + }) + + t.test('windows always uses browser', async t => { + mockGlobals(t, { process: { platform: 'win32' } }) + const { npm } = await loadMockNpm(t) + const usage = await npm.usage + npm.config.set('viewer', 'browser') + const browserUsage = await npm.usage + t.match(usage, '(in a browser)') + t.match(browserUsage, '(in a browser)') + }) + + t.test('includes commands', async t => { + const { npm } = await loadMockNpm(t) + const usage = await npm.usage + npm.config.set('long', true) + const longUsage = await npm.usage + + const lastCmd = commands[commands.length - 1] + for (const cmd of commands) { + const isLast = cmd === lastCmd + const shortCmd = new RegExp(`\\s${cmd}${isLast ? '\\n' : ',[\\s\\n]'}`) + const longCmd = new RegExp(`^\\s+${cmd}\\s+\\w.*\n\\s+Usage:\\n`, 'm') + + t.match(usage, shortCmd, `usage includes ${cmd}`) + t.notMatch(usage, longCmd, `usage does not include long ${cmd}`) + + t.match(longUsage, longCmd, `long usage includes ${cmd}`) + if (!isLast) { + // long usage includes false positives for the last command since it is + // not followed by a comma + t.notMatch(longUsage, shortCmd, `long usage does not include short ${cmd}`) + } + } + }) + + t.test('set process.stdout.columns', async t => { + const { npm } = await loadMockNpm(t) + + const colUsage = async (cols) => { + const usages = [] + for (const col of cols) { + mockGlobals(t, { 'process.stdout.columns': col }) + const usage = await npm.usage + usages.push(usage) + } + return usages + } + + t.test('max size', async t => { + const usages = await colUsage([0, 76, 90, 100]) + t.equal(usages.filter(Boolean).length, 4) + t.equal(new Set([...usages]).size, 1) + }) + + t.test('across max boundary', async t => { + const usages = await colUsage([75, 76]) + t.equal(usages.filter(Boolean).length, 2) + t.equal(new Set([...usages]).size, 2) + }) + + t.test('min size', async t => { + const usages = await colUsage([1, 10, 24, 40]) + t.equal(usages.filter(Boolean).length, 4) + t.equal(new Set([...usages]).size, 1) + }) + + t.test('different cols within min/max', async t => { + const usages = await colUsage([40, 41]) + t.equal(usages.filter(Boolean).length, 2) + t.equal(new Set([...usages]).size, 2) + }) + }) +}) diff --git a/test/lib/utils/cmd-list.js b/test/lib/utils/cmd-list.js deleted file mode 100644 index 8e93694..0000000 --- a/test/lib/utils/cmd-list.js +++ /dev/null @@ -1,4 +0,0 @@ -const t = require('tap') -const cmdList = require('../../../lib/utils/cmd-list.js') -// just snapshot it so we are made aware if it changes unexpectedly -t.matchSnapshot(cmdList) diff --git a/test/lib/utils/config/definitions.js b/test/lib/utils/config/definitions.js index bf4b487..dca584e 100644 --- a/test/lib/utils/config/definitions.js +++ b/test/lib/utils/config/definitions.js @@ -1,37 +1,19 @@ const t = require('tap') const { resolve } = require('path') const mockGlobals = require('../../../fixtures/mock-globals') +const pkg = require('../../../../package.json') // have to fake the node version, or else it'll only pass on this one mockGlobals(t, { 'process.version': 'v14.8.0', 'process.env.NODE_ENV': undefined }) -// also fake the npm version, so that it doesn't get reset every time -const pkg = require('../../../../package.json') +const mockDefs = (mocks = {}) => t.mock('../../../../lib/utils/config/definitions.js', mocks) -// this is a pain to keep typing -const defpath = '../../../../lib/utils/config/definitions.js' - -const definitions = require(defpath) - -// Tie the definitions to a snapshot so that if they change we are forced to -// update snapshots, which rebuilds the docs -for (const key of Object.keys(definitions)) { - t.matchSnapshot(definitions[key].describe(), `config description for ${key}`) -} - -const isWin = '../../../../lib/utils/is-windows.js' - -// snapshot these just so we note when they change -t.matchSnapshot(Object.keys(definitions), 'all config keys') -t.matchSnapshot(Object.keys(definitions).filter(d => d.flatten), - 'all config keys that are shared to flatOptions') - -t.equal(definitions['npm-version'].default, pkg.version, 'npm-version default') -t.equal(definitions['node-version'].default, process.version, 'node-version default') +const isWin = (isWindows) => ({ '../../../../lib/utils/is-windows.js': { isWindows } }) t.test('basic flattening function camelCases from css-case', t => { const flat = {} const obj = { 'prefer-online': true } + const definitions = mockDefs() definitions['prefer-online'].flatten('prefer-online', obj, flat) t.strictSame(flat, { preferOnline: true }) t.end() @@ -40,25 +22,27 @@ t.test('basic flattening function camelCases from css-case', t => { t.test('editor', t => { t.test('has EDITOR and VISUAL, use EDITOR', t => { mockGlobals(t, { 'process.env': { EDITOR: 'vim', VISUAL: 'mate' } }) - const defs = t.mock(defpath) + const defs = mockDefs() t.equal(defs.editor.default, 'vim') t.end() }) t.test('has VISUAL but no EDITOR, use VISUAL', t => { mockGlobals(t, { 'process.env': { EDITOR: undefined, VISUAL: 'mate' } }) - const defs = t.mock(defpath) + const defs = mockDefs() t.equal(defs.editor.default, 'mate') t.end() }) t.test('has neither EDITOR nor VISUAL, system specific', t => { - mockGlobals(t, { 'process.env': { EDITOR: undefined, VISUAL: undefined } }) - const defsWin = t.mock(defpath, { - [isWin]: true, - }) - t.equal(defsWin.editor.default, 'notepad.exe') - const defsNix = t.mock(defpath, { - [isWin]: false, + mockGlobals(t, { + 'process.env': { + EDITOR: undefined, + VISUAL: undefined, + SYSTEMROOT: 'C:\\Windows', + }, }) + const defsWin = mockDefs(isWin(true)) + t.equal(defsWin.editor.default, 'C:\\Windows\\notepad.exe') + const defsNix = mockDefs(isWin(false)) t.equal(defsNix.editor.default, 'vi') t.end() }) @@ -68,28 +52,20 @@ t.test('editor', t => { t.test('shell', t => { t.test('windows, env.ComSpec then cmd.exe', t => { mockGlobals(t, { 'process.env.ComSpec': 'command.com' }) - const defsComSpec = t.mock(defpath, { - [isWin]: true, - }) + const defsComSpec = mockDefs(isWin(true)) t.equal(defsComSpec.shell.default, 'command.com') mockGlobals(t, { 'process.env.ComSpec': undefined }) - const defsNoComSpec = t.mock(defpath, { - [isWin]: true, - }) + const defsNoComSpec = mockDefs(isWin(true)) t.equal(defsNoComSpec.shell.default, 'cmd') t.end() }) t.test('nix, SHELL then sh', t => { mockGlobals(t, { 'process.env.SHELL': '/usr/local/bin/bash' }) - const defsShell = t.mock(defpath, { - [isWin]: false, - }) + const defsShell = mockDefs(isWin(false)) t.equal(defsShell.shell.default, '/usr/local/bin/bash') mockGlobals(t, { 'process.env.SHELL': undefined }) - const defsNoShell = t.mock(defpath, { - [isWin]: false, - }) + const defsNoShell = mockDefs(isWin(false)) t.equal(defsNoShell.shell.default, 'sh') t.end() }) @@ -106,7 +82,7 @@ t.test('local-address allowed types', t => { eth69: [{ address: 'no place like home' }], }), } - const defs = t.mock(defpath, { os }) + const defs = mockDefs({ os }) t.same(defs['local-address'].type, [ null, '127.0.0.1', @@ -121,7 +97,7 @@ t.test('local-address allowed types', t => { throw new Error('no network interfaces for some reason') }, } - const defs = t.mock(defpath, { os }) + const defs = mockDefs({ os }) t.same(defs['local-address'].type, [null]) t.end() }) @@ -133,44 +109,38 @@ t.test('unicode allowed?', t => { setGlobal({ LC_ALL: 'utf8', LC_CTYPE: 'UTF-8', LANG: 'Unicode utf-8' }) - const lcAll = t.mock(defpath) + const lcAll = mockDefs() t.equal(lcAll.unicode.default, true) setGlobal({ LC_ALL: 'no unicode for youUUUU!' }) - const noLcAll = t.mock(defpath) + const noLcAll = mockDefs() t.equal(noLcAll.unicode.default, false) setGlobal({ LC_ALL: undefined }) - const lcCtype = t.mock(defpath) + const lcCtype = mockDefs() t.equal(lcCtype.unicode.default, true) setGlobal({ LC_CTYPE: 'something other than unicode version 8' }) - const noLcCtype = t.mock(defpath) + const noLcCtype = mockDefs() t.equal(noLcCtype.unicode.default, false) setGlobal({ LC_CTYPE: undefined }) - const lang = t.mock(defpath) + const lang = mockDefs() t.equal(lang.unicode.default, true) setGlobal({ LANG: 'ISO-8859-1' }) - const noLang = t.mock(defpath) + const noLang = mockDefs() t.equal(noLang.unicode.default, false) t.end() }) t.test('cache', t => { mockGlobals(t, { 'process.env.LOCALAPPDATA': 'app/data/local' }) - const defsWinLocalAppData = t.mock(defpath, { - [isWin]: true, - }) + const defsWinLocalAppData = mockDefs(isWin(true)) t.equal(defsWinLocalAppData.cache.default, 'app/data/local/npm-cache') mockGlobals(t, { 'process.env.LOCALAPPDATA': undefined }) - const defsWinNoLocalAppData = t.mock(defpath, { - [isWin]: true, - }) + const defsWinNoLocalAppData = mockDefs(isWin(true)) t.equal(defsWinNoLocalAppData.cache.default, '~/npm-cache') - const defsNix = t.mock(defpath, { - [isWin]: false, - }) + const defsNix = mockDefs(isWin(false)) t.equal(defsNix.cache.default, '~/.npm') const flat = {} @@ -189,12 +159,12 @@ t.test('flatteners that populate flat.omit array', t => { // ignored if setting is not dev or development obj.also = 'ignored' - definitions.also.flatten('also', obj, flat) + mockDefs().also.flatten('also', obj, flat) t.strictSame(obj, { also: 'ignored', omit: [], include: [] }, 'nothing done') t.strictSame(flat, { omit: [] }, 'nothing done') obj.also = 'development' - definitions.also.flatten('also', obj, flat) + mockDefs().also.flatten('also', obj, flat) t.strictSame(obj, { also: 'development', omit: [], @@ -204,7 +174,7 @@ t.test('flatteners that populate flat.omit array', t => { obj.omit = ['dev', 'optional'] obj.include = [] - definitions.also.flatten('also', obj, flat) + mockDefs().also.flatten('also', obj, flat) t.strictSame(obj, { also: 'development', omit: ['optional'], @@ -217,10 +187,10 @@ t.test('flatteners that populate flat.omit array', t => { t.test('include', t => { const flat = {} const obj = { include: ['dev'] } - definitions.include.flatten('include', obj, flat) + mockDefs().include.flatten('include', obj, flat) t.strictSame(flat, { omit: [] }, 'not omitting anything') obj.omit = ['optional', 'dev'] - definitions.include.flatten('include', obj, flat) + mockDefs().include.flatten('include', obj, flat) t.strictSame(flat, { omit: ['optional'] }, 'only omitting optional') t.end() }) @@ -228,11 +198,11 @@ t.test('flatteners that populate flat.omit array', t => { t.test('omit', t => { const flat = {} const obj = { include: ['dev'], omit: ['dev', 'optional'] } - definitions.omit.flatten('omit', obj, flat) + mockDefs().omit.flatten('omit', obj, flat) t.strictSame(flat, { omit: ['optional'] }, 'do not omit what is included') mockGlobals(t, { 'process.env.NODE_ENV': 'production' }) - const defProdEnv = t.mock(defpath) + const defProdEnv = mockDefs() t.strictSame(defProdEnv.omit.default, ['dev'], 'omit dev in production') t.end() }) @@ -240,16 +210,16 @@ t.test('flatteners that populate flat.omit array', t => { t.test('only', t => { const flat = {} const obj = { only: 'asdf' } - definitions.only.flatten('only', obj, flat) + mockDefs().only.flatten('only', obj, flat) t.strictSame(flat, { omit: [] }, 'ignored if value is not production') obj.only = 'prod' - definitions.only.flatten('only', obj, flat) + mockDefs().only.flatten('only', obj, flat) t.strictSame(flat, { omit: ['dev'] }, 'omit dev when --only=prod') obj.include = ['dev'] flat.omit = [] - definitions.only.flatten('only', obj, flat) + mockDefs().only.flatten('only', obj, flat) t.strictSame(flat, { omit: [] }, 'do not omit when included') t.end() @@ -259,7 +229,7 @@ t.test('flatteners that populate flat.omit array', t => { const flat = {} const obj = { optional: null } - definitions.optional.flatten('optional', obj, flat) + mockDefs().optional.flatten('optional', obj, flat) t.strictSame(obj, { optional: null, omit: [], @@ -268,7 +238,7 @@ t.test('flatteners that populate flat.omit array', t => { t.strictSame(flat, { omit: [] }, 'do nothing by default') obj.optional = true - definitions.optional.flatten('optional', obj, flat) + mockDefs().optional.flatten('optional', obj, flat) t.strictSame(obj, { omit: [], optional: true, @@ -278,7 +248,7 @@ t.test('flatteners that populate flat.omit array', t => { delete obj.include obj.optional = false - definitions.optional.flatten('optional', obj, flat) + mockDefs().optional.flatten('optional', obj, flat) t.strictSame(obj, { omit: ['optional'], optional: false, @@ -292,7 +262,7 @@ t.test('flatteners that populate flat.omit array', t => { t.test('production', t => { const flat = {} const obj = { production: true } - definitions.production.flatten('production', obj, flat) + mockDefs().production.flatten('production', obj, flat) t.strictSame(obj, { production: true, omit: ['dev'], @@ -303,7 +273,7 @@ t.test('flatteners that populate flat.omit array', t => { delete obj.omit obj.production = false delete flat.omit - definitions.production.flatten('production', obj, flat) + mockDefs().production.flatten('production', obj, flat) t.strictSame(obj, { production: false, include: ['dev'], @@ -313,7 +283,7 @@ t.test('flatteners that populate flat.omit array', t => { obj.production = true obj.include = ['dev'] - definitions.production.flatten('production', obj, flat) + mockDefs().production.flatten('production', obj, flat) t.strictSame(obj, { production: true, include: ['dev'], @@ -327,7 +297,7 @@ t.test('flatteners that populate flat.omit array', t => { t.test('dev', t => { const flat = {} const obj = { dev: true } - definitions.dev.flatten('dev', obj, flat) + mockDefs().dev.flatten('dev', obj, flat) t.strictSame(obj, { dev: true, omit: [], @@ -342,10 +312,10 @@ t.test('flatteners that populate flat.omit array', t => { t.test('cache-max', t => { const flat = {} const obj = { 'cache-max': 10342 } - definitions['cache-max'].flatten('cache-max', obj, flat) + mockDefs()['cache-max'].flatten('cache-max', obj, flat) t.strictSame(flat, {}, 'no effect if not <= 0') obj['cache-max'] = 0 - definitions['cache-max'].flatten('cache-max', obj, flat) + mockDefs()['cache-max'].flatten('cache-max', obj, flat) t.strictSame(flat, { preferOnline: true }, 'preferOnline if <= 0') t.end() }) @@ -353,10 +323,10 @@ t.test('cache-max', t => { t.test('cache-min', t => { const flat = {} const obj = { 'cache-min': 123 } - definitions['cache-min'].flatten('cache-min', obj, flat) + mockDefs()['cache-min'].flatten('cache-min', obj, flat) t.strictSame(flat, {}, 'no effect if not >= 9999') obj['cache-min'] = 9999 - definitions['cache-min'].flatten('cache-min', obj, flat) + mockDefs()['cache-min'].flatten('cache-min', obj, flat) t.strictSame(flat, { preferOffline: true }, 'preferOffline if >=9999') t.end() }) @@ -367,43 +337,44 @@ t.test('color', t => { const flat = {} const obj = { color: 'always' } - definitions.color.flatten('color', obj, flat) + mockDefs().color.flatten('color', obj, flat) t.strictSame(flat, { color: true, logColor: true }, 'true when --color=always') obj.color = false - definitions.color.flatten('color', obj, flat) + mockDefs().color.flatten('color', obj, flat) t.strictSame(flat, { color: false, logColor: false }, 'true when --no-color') setTTY('stdout', false) + setTTY('stderr', false) + obj.color = true - definitions.color.flatten('color', obj, flat) + mockDefs().color.flatten('color', obj, flat) t.strictSame(flat, { color: false, logColor: false }, 'no color when stdout not tty') setTTY('stdout', true) - definitions.color.flatten('color', obj, flat) + mockDefs().color.flatten('color', obj, flat) t.strictSame(flat, { color: true, logColor: false }, '--color turns on color when stdout is tty') setTTY('stdout', false) - setTTY('stderr', false) obj.color = true - definitions.color.flatten('color', obj, flat) + mockDefs().color.flatten('color', obj, flat) t.strictSame(flat, { color: false, logColor: false }, 'no color when stderr not tty') setTTY('stderr', true) - definitions.color.flatten('color', obj, flat) + mockDefs().color.flatten('color', obj, flat) t.strictSame(flat, { color: false, logColor: true }, '--color turns on color when stderr is tty') setTTY('stderr', false) const setColor = (value) => mockGlobals(t, { 'process.env.NO_COLOR': value }) setColor(undefined) - const defsAllowColor = t.mock(defpath) + const defsAllowColor = mockDefs() t.equal(defsAllowColor.color.default, true, 'default true when no NO_COLOR env') setColor('0') - const defsNoColor0 = t.mock(defpath) + const defsNoColor0 = mockDefs() t.equal(defsNoColor0.color.default, true, 'default true when no NO_COLOR=0') setColor('1') - const defsNoColor1 = t.mock(defpath) + const defsNoColor1 = mockDefs() t.equal(defsNoColor1.color.default, false, 'default false when no NO_COLOR=1') t.end() @@ -417,19 +388,19 @@ t.test('progress', t => { const flat = {} - definitions.progress.flatten('progress', {}, flat) + mockDefs().progress.flatten('progress', {}, flat) t.strictSame(flat, { progress: false }) setEnv({ tty: true, term: 'notdumb' }) - definitions.progress.flatten('progress', { progress: true }, flat) + mockDefs().progress.flatten('progress', { progress: true }, flat) t.strictSame(flat, { progress: true }) setEnv({ tty: false, term: 'notdumb' }) - definitions.progress.flatten('progress', { progress: true }, flat) + mockDefs().progress.flatten('progress', { progress: true }, flat) t.strictSame(flat, { progress: false }) setEnv({ tty: true, term: 'dumb' }) - definitions.progress.flatten('progress', { progress: true }, flat) + mockDefs().progress.flatten('progress', { progress: true }, flat) t.strictSame(flat, { progress: false }) t.end() @@ -448,7 +419,7 @@ t.test('retry options', t => { const msg = `${config} -> retry.${option}` const flat = {} obj[config] = 99 - definitions[config].flatten(config, obj, flat) + mockDefs()[config].flatten(config, obj, flat) t.strictSame(flat, { retry: { [option]: 99 } }, msg) delete obj[config] } @@ -456,6 +427,13 @@ t.test('retry options', t => { }) t.test('search options', t => { + const vals = { + description: 'test description', + exclude: 'test search exclude', + limit: 99, + staleneess: 99, + + } const obj = {} // <config>: flat.search[<option>] const mapping = { @@ -468,15 +446,15 @@ t.test('search options', t => { for (const [config, option] of Object.entries(mapping)) { const msg = `${config} -> search.${option}` const flat = {} - obj[config] = 99 - definitions[config].flatten(config, obj, flat) - t.strictSame(flat, { search: { limit: 20, [option]: 99 } }, msg) + obj[config] = vals[option] + mockDefs()[config].flatten(config, obj, flat) + t.strictSame(flat, { search: { limit: 20, [option]: vals[option] } }, msg) delete obj[config] } const flat = {} obj.searchopts = 'a=b&b=c' - definitions.searchopts.flatten('searchopts', obj, flat) + mockDefs().searchopts.flatten('searchopts', obj, flat) t.strictSame(flat, { search: { limit: 20, @@ -494,7 +472,7 @@ t.test('search options', t => { t.test('noProxy - array', t => { const obj = { noproxy: ['1.2.3.4,2.3.4.5', '3.4.5.6'] } const flat = {} - definitions.noproxy.flatten('noproxy', obj, flat) + mockDefs().noproxy.flatten('noproxy', obj, flat) t.strictSame(flat, { noProxy: '1.2.3.4,2.3.4.5,3.4.5.6' }) t.end() }) @@ -502,7 +480,7 @@ t.test('noProxy - array', t => { t.test('noProxy - string', t => { const obj = { noproxy: '1.2.3.4,2.3.4.5,3.4.5.6' } const flat = {} - definitions.noproxy.flatten('noproxy', obj, flat) + mockDefs().noproxy.flatten('noproxy', obj, flat) t.strictSame(flat, { noProxy: '1.2.3.4,2.3.4.5,3.4.5.6' }) t.end() }) @@ -510,7 +488,7 @@ t.test('noProxy - string', t => { t.test('maxSockets', t => { const obj = { maxsockets: 123 } const flat = {} - definitions.maxsockets.flatten('maxsockets', obj, flat) + mockDefs().maxsockets.flatten('maxsockets', obj, flat) t.strictSame(flat, { maxSockets: 123 }) t.end() }) @@ -518,11 +496,11 @@ t.test('maxSockets', t => { t.test('scope', t => { const obj = { scope: 'asdf' } const flat = {} - definitions.scope.flatten('scope', obj, flat) + mockDefs().scope.flatten('scope', obj, flat) t.strictSame(flat, { scope: '@asdf', projectScope: '@asdf' }, 'prepend @ if needed') obj.scope = '@asdf' - definitions.scope.flatten('scope', obj, flat) + mockDefs().scope.flatten('scope', obj, flat) t.strictSame(flat, { scope: '@asdf', projectScope: '@asdf' }, 'leave untouched if has @') t.end() @@ -531,10 +509,10 @@ t.test('scope', t => { t.test('strictSSL', t => { const obj = { 'strict-ssl': false } const flat = {} - definitions['strict-ssl'].flatten('strict-ssl', obj, flat) + mockDefs()['strict-ssl'].flatten('strict-ssl', obj, flat) t.strictSame(flat, { strictSSL: false }) obj['strict-ssl'] = true - definitions['strict-ssl'].flatten('strict-ssl', obj, flat) + mockDefs()['strict-ssl'].flatten('strict-ssl', obj, flat) t.strictSame(flat, { strictSSL: true }) t.end() }) @@ -542,18 +520,18 @@ t.test('strictSSL', t => { t.test('shrinkwrap/package-lock', t => { const obj = { shrinkwrap: false } const flat = {} - definitions.shrinkwrap.flatten('shrinkwrap', obj, flat) + mockDefs().shrinkwrap.flatten('shrinkwrap', obj, flat) t.strictSame(flat, { packageLock: false }) obj.shrinkwrap = true - definitions.shrinkwrap.flatten('shrinkwrap', obj, flat) + mockDefs().shrinkwrap.flatten('shrinkwrap', obj, flat) t.strictSame(flat, { packageLock: true }) delete obj.shrinkwrap obj['package-lock'] = false - definitions['package-lock'].flatten('package-lock', obj, flat) + mockDefs()['package-lock'].flatten('package-lock', obj, flat) t.strictSame(flat, { packageLock: false }) obj['package-lock'] = true - definitions['package-lock'].flatten('package-lock', obj, flat) + mockDefs()['package-lock'].flatten('package-lock', obj, flat) t.strictSame(flat, { packageLock: true }) t.end() @@ -562,13 +540,13 @@ t.test('shrinkwrap/package-lock', t => { t.test('scriptShell', t => { const obj = { 'script-shell': null } const flat = {} - definitions['script-shell'].flatten('script-shell', obj, flat) + mockDefs()['script-shell'].flatten('script-shell', obj, flat) t.ok(Object.prototype.hasOwnProperty.call(flat, 'scriptShell'), 'should set it to undefined explicitly') t.strictSame(flat, { scriptShell: undefined }, 'no other fields') obj['script-shell'] = 'asdf' - definitions['script-shell'].flatten('script-shell', obj, flat) + mockDefs()['script-shell'].flatten('script-shell', obj, flat) t.strictSame(flat, { scriptShell: 'asdf' }, 'sets if not falsey') t.end() @@ -577,7 +555,7 @@ t.test('scriptShell', t => { t.test('defaultTag', t => { const obj = { tag: 'next' } const flat = {} - definitions.tag.flatten('tag', obj, flat) + mockDefs().tag.flatten('tag', obj, flat) t.strictSame(flat, { defaultTag: 'next' }) t.end() }) @@ -585,7 +563,7 @@ t.test('defaultTag', t => { t.test('timeout', t => { const obj = { 'fetch-timeout': 123 } const flat = {} - definitions['fetch-timeout'].flatten('fetch-timeout', obj, flat) + mockDefs()['fetch-timeout'].flatten('fetch-timeout', obj, flat) t.strictSame(flat, { timeout: 123 }) t.end() }) @@ -594,16 +572,16 @@ t.test('saveType', t => { t.test('save-prod', t => { const obj = { 'save-prod': false } const flat = {} - definitions['save-prod'].flatten('save-prod', obj, flat) + mockDefs()['save-prod'].flatten('save-prod', obj, flat) t.strictSame(flat, {}, 'no effect if false and missing') flat.saveType = 'prod' - definitions['save-prod'].flatten('save-prod', obj, flat) + mockDefs()['save-prod'].flatten('save-prod', obj, flat) t.strictSame(flat, {}, 'remove if false and set to prod') flat.saveType = 'dev' - definitions['save-prod'].flatten('save-prod', obj, flat) + mockDefs()['save-prod'].flatten('save-prod', obj, flat) t.strictSame(flat, { saveType: 'dev' }, 'ignore if false and not already prod') obj['save-prod'] = true - definitions['save-prod'].flatten('save-prod', obj, flat) + mockDefs()['save-prod'].flatten('save-prod', obj, flat) t.strictSame(flat, { saveType: 'prod' }, 'set to prod if true') t.end() }) @@ -611,17 +589,17 @@ t.test('saveType', t => { t.test('save-dev', t => { const obj = { 'save-dev': false } const flat = {} - definitions['save-dev'].flatten('save-dev', obj, flat) + mockDefs()['save-dev'].flatten('save-dev', obj, flat) t.strictSame(flat, {}, 'no effect if false and missing') flat.saveType = 'dev' - definitions['save-dev'].flatten('save-dev', obj, flat) + mockDefs()['save-dev'].flatten('save-dev', obj, flat) t.strictSame(flat, {}, 'remove if false and set to dev') flat.saveType = 'prod' obj['save-dev'] = false - definitions['save-dev'].flatten('save-dev', obj, flat) + mockDefs()['save-dev'].flatten('save-dev', obj, flat) t.strictSame(flat, { saveType: 'prod' }, 'ignore if false and not already dev') obj['save-dev'] = true - definitions['save-dev'].flatten('save-dev', obj, flat) + mockDefs()['save-dev'].flatten('save-dev', obj, flat) t.strictSame(flat, { saveType: 'dev' }, 'set to dev if true') t.end() }) @@ -629,16 +607,16 @@ t.test('saveType', t => { t.test('save-bundle', t => { const obj = { 'save-bundle': true } const flat = {} - definitions['save-bundle'].flatten('save-bundle', obj, flat) + mockDefs()['save-bundle'].flatten('save-bundle', obj, flat) t.strictSame(flat, { saveBundle: true }, 'set the saveBundle flag') obj['save-bundle'] = false - definitions['save-bundle'].flatten('save-bundle', obj, flat) + mockDefs()['save-bundle'].flatten('save-bundle', obj, flat) t.strictSame(flat, { saveBundle: false }, 'unset the saveBundle flag') obj['save-bundle'] = true obj['save-peer'] = true - definitions['save-bundle'].flatten('save-bundle', obj, flat) + mockDefs()['save-bundle'].flatten('save-bundle', obj, flat) t.strictSame(flat, { saveBundle: false }, 'false if save-peer is set') t.end() @@ -647,27 +625,27 @@ t.test('saveType', t => { t.test('save-peer', t => { const obj = { 'save-peer': false } const flat = {} - definitions['save-peer'].flatten('save-peer', obj, flat) + mockDefs()['save-peer'].flatten('save-peer', obj, flat) t.strictSame(flat, {}, 'no effect if false and not yet set') obj['save-peer'] = true - definitions['save-peer'].flatten('save-peer', obj, flat) + mockDefs()['save-peer'].flatten('save-peer', obj, flat) t.strictSame(flat, { saveType: 'peer' }, 'set saveType to peer if unset') flat.saveType = 'optional' - definitions['save-peer'].flatten('save-peer', obj, flat) + mockDefs()['save-peer'].flatten('save-peer', obj, flat) t.strictSame(flat, { saveType: 'peerOptional' }, 'set to peerOptional if optional already') - definitions['save-peer'].flatten('save-peer', obj, flat) + mockDefs()['save-peer'].flatten('save-peer', obj, flat) t.strictSame(flat, { saveType: 'peerOptional' }, 'no effect if already peerOptional') obj['save-peer'] = false - definitions['save-peer'].flatten('save-peer', obj, flat) + mockDefs()['save-peer'].flatten('save-peer', obj, flat) t.strictSame(flat, { saveType: 'optional' }, 'switch peerOptional to optional if false') obj['save-peer'] = false flat.saveType = 'peer' - definitions['save-peer'].flatten('save-peer', obj, flat) + mockDefs()['save-peer'].flatten('save-peer', obj, flat) t.strictSame(flat, {}, 'remove saveType if peer and setting false') t.end() @@ -676,26 +654,26 @@ t.test('saveType', t => { t.test('save-optional', t => { const obj = { 'save-optional': false } const flat = {} - definitions['save-optional'].flatten('save-optional', obj, flat) + mockDefs()['save-optional'].flatten('save-optional', obj, flat) t.strictSame(flat, {}, 'no effect if false and not yet set') obj['save-optional'] = true - definitions['save-optional'].flatten('save-optional', obj, flat) + mockDefs()['save-optional'].flatten('save-optional', obj, flat) t.strictSame(flat, { saveType: 'optional' }, 'set saveType to optional if unset') flat.saveType = 'peer' - definitions['save-optional'].flatten('save-optional', obj, flat) + mockDefs()['save-optional'].flatten('save-optional', obj, flat) t.strictSame(flat, { saveType: 'peerOptional' }, 'set to peerOptional if peer already') - definitions['save-optional'].flatten('save-optional', obj, flat) + mockDefs()['save-optional'].flatten('save-optional', obj, flat) t.strictSame(flat, { saveType: 'peerOptional' }, 'no effect if already peerOptional') obj['save-optional'] = false - definitions['save-optional'].flatten('save-optional', obj, flat) + mockDefs()['save-optional'].flatten('save-optional', obj, flat) t.strictSame(flat, { saveType: 'peer' }, 'switch peerOptional to peer if false') flat.saveType = 'optional' - definitions['save-optional'].flatten('save-optional', obj, flat) + mockDefs()['save-optional'].flatten('save-optional', obj, flat) t.strictSame(flat, {}, 'remove saveType if optional and setting false') t.end() @@ -721,13 +699,13 @@ YYYY\r const obj = {} const flat = {} - definitions.cafile.flatten('cafile', obj, flat) + mockDefs().cafile.flatten('cafile', obj, flat) t.strictSame(flat, {}, 'no effect if no cafile set') obj.cafile = resolve(path, 'no/cafile/here') - definitions.cafile.flatten('cafile', obj, flat) + mockDefs().cafile.flatten('cafile', obj, flat) t.strictSame(flat, {}, 'no effect if cafile not found') obj.cafile = cafile - definitions.cafile.flatten('cafile', obj, flat) + mockDefs().cafile.flatten('cafile', obj, flat) t.strictSame(flat, { ca: [ '-----BEGIN CERTIFICATE-----\nXXXX\nXXXX\n-----END CERTIFICATE-----', @@ -736,7 +714,7 @@ YYYY\r }) t.test('error other than ENOENT gets thrown', t => { const poo = new Error('poo') - const defnReadFileThrows = t.mock(defpath, { + const defnReadFileThrows = mockDefs({ fs: { ...require('fs'), readFileSync: () => { @@ -752,11 +730,11 @@ YYYY\r }) t.test('detect CI', t => { - const defnNoCI = t.mock(defpath, { - '@npmcli/ci-detect': () => false, + const defnNoCI = mockDefs({ + 'ci-info': { isCI: false, name: null }, }) - const defnCIFoo = t.mock(defpath, { - '@npmcli/ci-detect': () => 'foo', + const defnCIFoo = mockDefs({ + 'ci-info': { isCI: false, name: 'foo' }, }) t.equal(defnNoCI['ci-name'].default, null, 'null when not in CI') t.equal(defnCIFoo['ci-name'].default, 'foo', 'name of CI when in CI') @@ -765,39 +743,37 @@ t.test('detect CI', t => { t.test('user-agent', t => { const obj = { - 'user-agent': definitions['user-agent'].default, - 'npm-version': '1.2.3', - 'node-version': '9.8.7', + 'user-agent': mockDefs()['user-agent'].default, } const flat = {} - const expectNoCI = `npm/1.2.3 node/9.8.7 ` + + const expectNoCI = `npm/${pkg.version} node/${process.version} ` + `${process.platform} ${process.arch} workspaces/false` - definitions['user-agent'].flatten('user-agent', obj, flat) + mockDefs()['user-agent'].flatten('user-agent', obj, flat) t.equal(flat.userAgent, expectNoCI) t.equal(process.env.npm_config_user_agent, flat.userAgent, 'npm_user_config environment is set') t.not(obj['user-agent'], flat.userAgent, 'config user-agent template is not translated') obj['ci-name'] = 'foo' - obj['user-agent'] = definitions['user-agent'].default + obj['user-agent'] = mockDefs()['user-agent'].default const expectCI = `${expectNoCI} ci/foo` - definitions['user-agent'].flatten('user-agent', obj, flat) + mockDefs()['user-agent'].flatten('user-agent', obj, flat) t.equal(flat.userAgent, expectCI) t.equal(process.env.npm_config_user_agent, flat.userAgent, 'npm_user_config environment is set') t.not(obj['user-agent'], flat.userAgent, 'config user-agent template is not translated') delete obj['ci-name'] obj.workspaces = true - obj['user-agent'] = definitions['user-agent'].default + obj['user-agent'] = mockDefs()['user-agent'].default const expectWorkspaces = expectNoCI.replace('workspaces/false', 'workspaces/true') - definitions['user-agent'].flatten('user-agent', obj, flat) + mockDefs()['user-agent'].flatten('user-agent', obj, flat) t.equal(flat.userAgent, expectWorkspaces) t.equal(process.env.npm_config_user_agent, flat.userAgent, 'npm_user_config environment is set') t.not(obj['user-agent'], flat.userAgent, 'config user-agent template is not translated') delete obj.workspaces obj.workspace = ['foo'] - obj['user-agent'] = definitions['user-agent'].default - definitions['user-agent'].flatten('user-agent', obj, flat) + obj['user-agent'] = mockDefs()['user-agent'].default + mockDefs()['user-agent'].flatten('user-agent', obj, flat) t.equal(flat.userAgent, expectWorkspaces) t.equal(process.env.npm_config_user_agent, flat.userAgent, 'npm_user_config environment is set') t.not(obj['user-agent'], flat.userAgent, 'config user-agent template is not translated') @@ -810,10 +786,10 @@ t.test('save-prefix', t => { 'save-prefix': '~1.2.3', } const flat = {} - definitions['save-prefix'] + mockDefs()['save-prefix'] .flatten('save-prefix', { ...obj, 'save-exact': true }, flat) t.strictSame(flat, { savePrefix: '' }) - definitions['save-prefix'] + mockDefs()['save-prefix'] .flatten('save-prefix', { ...obj, 'save-exact': false }, flat) t.strictSame(flat, { savePrefix: '~1.2.3' }) t.end() @@ -825,10 +801,10 @@ t.test('save-exact', t => { 'save-prefix': '~1.2.3', } const flat = {} - definitions['save-exact'] + mockDefs()['save-exact'] .flatten('save-exact', { ...obj, 'save-exact': true }, flat) t.strictSame(flat, { savePrefix: '' }) - definitions['save-exact'] + mockDefs()['save-exact'] .flatten('save-exact', { ...obj, 'save-exact': false }, flat) t.strictSame(flat, { savePrefix: '~1.2.3' }) t.end() @@ -841,8 +817,8 @@ t.test('location', t => { } const flat = {} // the global flattener is what sets location, so run that - definitions.global.flatten('global', obj, flat) - definitions.location.flatten('location', obj, flat) + mockDefs().global.flatten('global', obj, flat) + mockDefs().location.flatten('location', obj, flat) // global = true sets location in both places to global t.strictSame(flat, { global: true, location: 'global' }) // location here is still 'user' because flattening doesn't modify the object @@ -853,8 +829,8 @@ t.test('location', t => { delete flat.global delete flat.location - definitions.global.flatten('global', obj, flat) - definitions.location.flatten('location', obj, flat) + mockDefs().global.flatten('global', obj, flat) + mockDefs().location.flatten('location', obj, flat) // global = false leaves location unaltered t.strictSame(flat, { global: false, location: 'user' }) t.strictSame(obj, { global: false, location: 'user' }) @@ -868,16 +844,16 @@ t.test('package-lock-only', t => { } const flat = {} - definitions['package-lock-only'].flatten('package-lock-only', obj, flat) - definitions['package-lock'].flatten('package-lock', obj, flat) + mockDefs()['package-lock-only'].flatten('package-lock-only', obj, flat) + mockDefs()['package-lock'].flatten('package-lock', obj, flat) t.strictSame(flat, { packageLock: true, packageLockOnly: true }) obj['package-lock-only'] = false delete flat.packageLock delete flat.packageLockOnly - definitions['package-lock-only'].flatten('package-lock-only', obj, flat) - definitions['package-lock'].flatten('package-lock', obj, flat) + mockDefs()['package-lock-only'].flatten('package-lock-only', obj, flat) + mockDefs()['package-lock'].flatten('package-lock', obj, flat) t.strictSame(flat, { packageLock: false, packageLockOnly: false }) t.end() }) @@ -885,10 +861,10 @@ t.test('package-lock-only', t => { t.test('workspaces', t => { const obj = { workspaces: true, - 'user-agent': definitions['user-agent'].default, + 'user-agent': mockDefs()['user-agent'].default, } const flat = {} - definitions.workspaces.flatten('workspaces', obj, flat) + mockDefs().workspaces.flatten('workspaces', obj, flat) t.match(flat.userAgent, /workspaces\/true/) t.end() }) @@ -896,10 +872,10 @@ t.test('workspaces', t => { t.test('workspace', t => { const obj = { workspace: ['workspace-a'], - 'user-agent': definitions['user-agent'].default, + 'user-agent': mockDefs()['user-agent'].default, } const flat = {} - definitions.workspace.flatten('workspaces', obj, flat) + mockDefs().workspace.flatten('workspaces', obj, flat) t.match(flat.userAgent, /workspaces\/true/) t.end() }) @@ -907,25 +883,50 @@ t.test('workspace', t => { t.test('workspaces derived', t => { const obj = { workspaces: ['a'], - 'user-agent': definitions['user-agent'].default, + 'user-agent': mockDefs()['user-agent'].default, } const flat = {} - definitions.workspaces.flatten('workspaces', obj, flat) + mockDefs().workspaces.flatten('workspaces', obj, flat) t.equal(flat.workspacesEnabled, true) obj.workspaces = null - definitions.workspaces.flatten('workspaces', obj, flat) + mockDefs().workspaces.flatten('workspaces', obj, flat) t.equal(flat.workspacesEnabled, true) obj.workspaces = false - definitions.workspaces.flatten('workspaces', obj, flat) + mockDefs().workspaces.flatten('workspaces', obj, flat) t.equal(flat.workspacesEnabled, false) t.end() }) t.test('lockfile version', t => { const flat = {} - definitions['lockfile-version'].flatten('lockfile-version', { + mockDefs()['lockfile-version'].flatten('lockfile-version', { 'lockfile-version': '3', }, flat) t.match(flat.lockfileVersion, 3, 'flattens to a number') t.end() }) + +t.test('loglevel silent', t => { + const flat = {} + mockDefs().loglevel.flatten('loglevel', { + loglevel: 'silent', + }, flat) + t.match(flat.silent, true, 'flattens to assign silent') + t.end() +}) + +t.test('remap legacy-bundling', t => { + const obj = { 'legacy-bundling': true } + const flat = {} + mockDefs()['legacy-bundling'].flatten('legacy-bundling', obj, flat) + t.strictSame(flat, { installStrategy: 'nested' }) + t.end() +}) + +t.test('remap global-style', t => { + const obj = { 'global-style': true } + const flat = {} + mockDefs()['global-style'].flatten('global-style', obj, flat) + t.strictSame(flat, { installStrategy: 'shallow' }) + t.end() +}) diff --git a/test/lib/utils/config/describe-all.js b/test/lib/utils/config/describe-all.js deleted file mode 100644 index 814d92a..0000000 --- a/test/lib/utils/config/describe-all.js +++ /dev/null @@ -1,6 +0,0 @@ -const t = require('tap') -const describeAll = require('../../../../lib/utils/config/describe-all.js') -// this basically ends up being a duplicate of the helpdoc dumped into -// a snapshot, but it verifies that we get the same help output on every -// platform where we run CI. -t.matchSnapshot(describeAll()) diff --git a/test/lib/utils/config/flatten.js b/test/lib/utils/config/flatten.js deleted file mode 100644 index 7e13563..0000000 --- a/test/lib/utils/config/flatten.js +++ /dev/null @@ -1,38 +0,0 @@ -const t = require('tap') -const flatten = require('../../../../lib/utils/config/flatten.js') - -require.main.filename = '/path/to/npm' -delete process.env.NODE -process.execPath = '/path/to/node' - -const obj = { - 'save-exact': true, - 'save-prefix': 'ignored', - 'save-dev': true, - '@foobar:registry': 'https://foo.bar.com/', - '//foo.bar.com:_authToken': 'foobarbazquuxasdf', - userconfig: '/path/to/.npmrc', -} - -const flat = flatten(obj) -t.strictSame(flat, { - saveType: 'dev', - savePrefix: '', - '@foobar:registry': 'https://foo.bar.com/', - '//foo.bar.com:_authToken': 'foobarbazquuxasdf', - npmBin: '/path/to/npm', - nodeBin: '/path/to/node', - hashAlgorithm: 'sha1', -}) - -// now flatten something else on top of it. -process.env.NODE = '/usr/local/bin/node.exe' -flatten({ 'save-dev': false }, flat) -t.strictSame(flat, { - savePrefix: '', - '@foobar:registry': 'https://foo.bar.com/', - '//foo.bar.com:_authToken': 'foobarbazquuxasdf', - npmBin: '/path/to/npm', - nodeBin: '/usr/local/bin/node.exe', - hashAlgorithm: 'sha1', -}) diff --git a/test/lib/utils/config/index.js b/test/lib/utils/config/index.js index 75d72e7..90931a9 100644 --- a/test/lib/utils/config/index.js +++ b/test/lib/utils/config/index.js @@ -1,24 +1,63 @@ const t = require('tap') const config = require('../../../../lib/utils/config/index.js') -const flatten = require('../../../../lib/utils/config/flatten.js') const definitions = require('../../../../lib/utils/config/definitions.js') -const describeAll = require('../../../../lib/utils/config/describe-all.js') -t.matchSnapshot(config.shorthands, 'shorthands') +const mockGlobals = require('../../../fixtures/mock-globals.js') -// just spot check a few of these to show that we got defaults assembled -t.match(config.defaults, { - registry: definitions.registry.default, - 'init-module': definitions['init-module'].default, +t.test('defaults', t => { + // just spot check a few of these to show that we got defaults assembled + t.match(config.defaults, { + registry: definitions.registry.default, + 'init-module': definitions['init-module'].default, + }) + + // is a getter, so changes are reflected + definitions.registry.default = 'https://example.com' + t.strictSame(config.defaults.registry, 'https://example.com') + + t.end() }) -// is a getter, so changes are reflected -definitions.registry.default = 'https://example.com' -t.strictSame(config.defaults.registry, 'https://example.com') +t.test('flatten', t => { + // cant use mockGlobals since its not a configurable property + require.main.filename = '/path/to/npm' + mockGlobals(t, { process: { execPath: '/path/to/node', 'env.NODE': undefined } }) -t.strictSame(config, { - defaults: config.defaults, - shorthands: config.shorthands, - flatten, - definitions, - describeAll, + const obj = { + 'save-exact': true, + 'save-prefix': 'ignored', + 'save-dev': true, + '@foobar:registry': 'https://foo.bar.com/', + '//foo.bar.com:_authToken': 'foobarbazquuxasdf', + userconfig: '/path/to/.npmrc', + } + + const flat = config.flatten(obj) + + t.strictSame(flat, { + saveType: 'dev', + savePrefix: '', + '@foobar:registry': 'https://foo.bar.com/', + '//foo.bar.com:_authToken': 'foobarbazquuxasdf', + npmBin: '/path/to/npm', + nodeBin: '/path/to/node', + hashAlgorithm: 'sha1', + }) + + mockGlobals(t, { + 'process.env.NODE': '/usr/local/bin/node.exe', + }) + + // now flatten something else on top of it. + config.flatten({ 'save-dev': false }, flat) + + t.strictSame(flat, { + savePrefix: '', + '@foobar:registry': 'https://foo.bar.com/', + '//foo.bar.com:_authToken': 'foobarbazquuxasdf', + npmBin: '/path/to/npm', + nodeBin: '/usr/local/bin/node.exe', + hashAlgorithm: 'sha1', + }) + + t.end() }) diff --git a/test/lib/utils/deref-command.js b/test/lib/utils/deref-command.js deleted file mode 100644 index 474488c..0000000 --- a/test/lib/utils/deref-command.js +++ /dev/null @@ -1,9 +0,0 @@ -const t = require('tap') -const deref = require('../../../lib/utils/deref-command.js') - -t.equal(deref(null), '') -t.equal(deref(8), '') -t.equal(deref('it'), 'install-test') -t.equal(deref('installTe'), 'install-test') -t.equal(deref('birthday'), 'birthday') -t.equal(deref('birt'), '') diff --git a/test/lib/utils/display.js b/test/lib/utils/display.js index 30cd2cc..c7332bc 100644 --- a/test/lib/utils/display.js +++ b/test/lib/utils/display.js @@ -18,7 +18,7 @@ t.test('setup', async (t) => { const { display } = mockDisplay(t) display.load({ timing: true, loglevel: 'notice' }) - t.equal(log.level, 'timing') + t.equal(log.level, 'notice') display.load({ timing: false, loglevel: 'notice' }) t.equal(log.level, 'notice') diff --git a/test/lib/utils/error-message.js b/test/lib/utils/error-message.js index ddc88c1..29753c3 100644 --- a/test/lib/utils/error-message.js +++ b/test/lib/utils/error-message.js @@ -4,6 +4,12 @@ const { load: _loadMockNpm } = require('../../fixtures/mock-npm.js') const mockGlobals = require('../../fixtures/mock-globals.js') const { cleanCwd, cleanDate } = require('../../fixtures/clean-snapshot.js') +t.formatSnapshot = (p) => { + if (Array.isArray(p.files) && !p.files.length) { + delete p.files + } + return p +} t.cleanSnapshot = p => cleanDate(cleanCwd(p)) mockGlobals(t, { @@ -16,10 +22,10 @@ mockGlobals(t, { }, }) -const loadMockNpm = async (t, { load, command, testdir, config } = {}) => { +const loadMockNpm = async (t, { load, command, prefixDir, config } = {}) => { const { npm, ...rest } = await _loadMockNpm(t, { load, - testdir, + prefixDir, config, mocks: { '../../package.json': { @@ -210,7 +216,7 @@ t.test('json parse', t => { mockGlobals(t, { 'process.argv': ['arg', 'v'] }) t.test('merge conflict in package.json', async t => { - const testdir = { + const prefixDir = { 'package.json': ` { "array": [ @@ -250,7 +256,7 @@ t.test('json parse', t => { } `, } - const npm = await loadMockNpm(t, { testdir }) + const npm = await loadMockNpm(t, { prefixDir }) t.matchSnapshot(errorMessage(Object.assign(new Error('conflicted'), { code: 'EJSONPARSE', path: path.resolve(npm.prefix, 'package.json'), @@ -259,10 +265,10 @@ t.test('json parse', t => { }) t.test('just regular bad json in package.json', async t => { - const testdir = { + const prefixDir = { 'package.json': 'not even slightly json', } - const npm = await loadMockNpm(t, { testdir }) + const npm = await loadMockNpm(t, { prefixDir }) t.matchSnapshot(errorMessage(Object.assign(new Error('not json'), { code: 'EJSONPARSE', path: path.resolve(npm.prefix, 'package.json'), @@ -271,10 +277,10 @@ t.test('json parse', t => { }) t.test('json somewhere else', async t => { - const testdir = { + const prefixDir = { 'blerg.json': 'not even slightly json', } - const npm = await loadMockNpm(t, { testdir }) + const npm = await loadMockNpm(t, { prefixDir }) t.matchSnapshot(errorMessage(Object.assign(new Error('not json'), { code: 'EJSONPARSE', path: path.resolve(npm.prefix, 'blerg.json'), @@ -420,7 +426,7 @@ t.test('bad platform', async t => { }) t.test('explain ERESOLVE errors', async t => { - const npm = await loadMockNpm(t) + const { npm, ...rest } = await loadMockNpm(t) const EXPLAIN_CALLED = [] const er = Object.assign(new Error('could not resolve'), { @@ -428,19 +434,16 @@ t.test('explain ERESOLVE errors', async t => { }) t.matchSnapshot(errorMessage(er, { - ...npm, + npm, + ...rest, mocks: { '../../../lib/utils/explain-eresolve.js': { report: (...args) => { EXPLAIN_CALLED.push(args) - return 'explanation' + return { explanation: 'explanation', file: 'report' } }, }, }, })) - t.match(EXPLAIN_CALLED, [[ - er, - false, - path.resolve(npm.cache, 'eresolve-report.txt'), - ]]) + t.match(EXPLAIN_CALLED, [[er, false]]) }) diff --git a/test/lib/utils/exit-handler.js b/test/lib/utils/exit-handler.js index 54bf48f..d22ec4d 100644 --- a/test/lib/utils/exit-handler.js +++ b/test/lib/utils/exit-handler.js @@ -1,5 +1,8 @@ const t = require('tap') const os = require('os') +const fs = require('fs') +const fsMiniPass = require('fs-minipass') +const { join } = require('path') const EventEmitter = require('events') const { format } = require('../../../lib/utils/log-file') const { load: loadMockNpm } = require('../../fixtures/mock-npm') @@ -21,9 +24,10 @@ t.formatSnapshot = (obj) => { } t.cleanSnapshot = (path) => cleanDate(cleanCwd(path)) -// Config loading is dependent on env so strip those from snapshots + // Config loading is dependent on env so strip those from snapshots .replace(/.*timing config:load:.*\n/gm, '') .replace(/(Completed in )\d+(ms)/g, '$1{TIME}$2') + .replace(/(removing )\d+( files)/g, '$1${NUM}2') // cut off process from script so that it won't quit the test runner // while trying to run through the myriad of cases. need to make it @@ -31,7 +35,7 @@ t.cleanSnapshot = (path) => cleanDate(cleanCwd(path)) // nerf itself, thinking global.process is broken or gone. mockGlobals(t, { process: Object.assign(new EventEmitter(), { - ...pick(process, 'execPath', 'stdout', 'stderr', 'cwd', 'env'), + ...pick(process, 'execPath', 'stdout', 'stderr', 'cwd', 'env', 'umask'), argv: ['/node', ...process.argv.slice(1)], version: 'v1.0.0', kill: () => {}, @@ -44,9 +48,8 @@ mockGlobals(t, { }), }, { replace: true }) -const mockExitHandler = async (t, { init, load, testdir, config } = {}) => { +const mockExitHandler = async (t, { init, load, testdir, config, mocks, files } = {}) => { const errors = [] - mockGlobals(t, { 'console.error': (err) => errors.push(err) }) const { npm, logMocks, ...rest } = await loadMockNpm(t, { init, @@ -56,24 +59,29 @@ const mockExitHandler = async (t, { init, load, testdir, config } = {}) => { '../../package.json': { version: '1.0.0', }, + ...mocks, }, config: { loglevel: 'notice', ...config, }, + globals: { + 'console.error': (err) => errors.push(err), + }, }) const exitHandler = t.mock('../../../lib/utils/exit-handler.js', { '../../../lib/utils/error-message.js': (err) => ({ - ...err, summary: [['ERR SUMMARY', err.message]], detail: [['ERR DETAIL', err.message]], + ...(files ? { files } : {}), }), os: { type: () => 'Foo', release: () => '1.0.0', }, ...logMocks, + ...mocks, }) if (npm) { @@ -89,13 +97,14 @@ const mockExitHandler = async (t, { init, load, testdir, config } = {}) => { ...rest, errors, npm, - // // Make it async to make testing ergonomics a little - // // easier so we dont need to t.plan() every test to - // // make sure we get process.exit called - exitHandler: (...args) => new Promise(resolve => { + // Make it async to make testing ergonomics a little easier so we dont need + // to t.plan() every test to make sure we get process.exit called. Also + // introduce a small artificial delay so the logs are consistently finished + // by the time the exit handler forces process.exit + exitHandler: (...args) => new Promise(resolve => setTimeout(() => { process.once('exit', resolve) exitHandler(...args) - }), + }, 50)), } } @@ -199,17 +208,15 @@ t.test('exit handler called - no npm with error without stack', async (t) => { }) t.test('console.log output using --json', async (t) => { - const { exitHandler, errors } = await mockExitHandler(t, { - config: { - json: true, - }, + const { exitHandler, outputs } = await mockExitHandler(t, { + config: { json: true }, }) await exitHandler(err('Error: EBADTHING Something happened')) t.equal(process.exitCode, 1) t.same( - JSON.parse(errors[0]), + JSON.parse(outputs[0]), { error: { code: 'EBADTHING', // should default error code to E[A-Z]+ @@ -221,6 +228,50 @@ t.test('console.log output using --json', async (t) => { ) }) +t.test('merges output buffers errors with --json', async (t) => { + const { exitHandler, outputs, npm } = await mockExitHandler(t, { + config: { json: true }, + }) + + npm.outputBuffer({ output_data: 1 }) + npm.outputBuffer(JSON.stringify({ more_data: 2 })) + npm.outputBuffer('not json, will be ignored') + + await exitHandler(err('Error: EBADTHING Something happened')) + + t.equal(process.exitCode, 1) + t.same( + JSON.parse(outputs[0]), + { + output_data: 1, + more_data: 2, + error: { + code: 'EBADTHING', // should default error code to E[A-Z]+ + summary: 'Error: EBADTHING Something happened', + detail: 'Error: EBADTHING Something happened', + }, + }, + 'should output expected json output' + ) +}) + +t.test('output buffer without json', async (t) => { + const { exitHandler, outputs, npm, logs } = await mockExitHandler(t) + + npm.outputBuffer('output_data') + npm.outputBuffer('more_data') + + await exitHandler(err('Error: EBADTHING Something happened')) + + t.equal(process.exitCode, 1) + t.same( + outputs, + [['output_data'], ['more_data']], + 'should output expected output' + ) + t.match(logs.error, [['code', 'EBADTHING']]) +}) + t.test('throw a non-error obj', async (t) => { const { exitHandler, logs } = await mockExitHandler(t) @@ -273,11 +324,127 @@ t.test('npm.config not ready', async (t) => { ], 'should exit with config error msg') }) -t.test('timing with no error', async (t) => { - const { exitHandler, timingFile, npm, logs } = await mockExitHandler(t, { +t.test('no logs dir', async (t) => { + const { exitHandler, logs } = await mockExitHandler(t, { + config: { 'logs-max': 0 }, + }) + + await exitHandler(new Error()) + + t.match(logs.error.filter(([t]) => t === ''), [ + ['', 'Log files were not written due to the config logs-max=0'], + ]) +}) + +t.test('timers fail to write', async (t) => { + // we want the fs.writeFileSync in the Timers class to fail + const mockTimers = t.mock('../../../lib/utils/timers.js', { + fs: { + ...fs, + writeFileSync: (file, ...rest) => { + if (file.includes('LOGS_DIR')) { + throw new Error('err') + } + + return fs.writeFileSync(file, ...rest) + }, + }, + }) + + const { exitHandler, logs } = await mockExitHandler(t, { config: { + 'logs-dir': 'LOGS_DIR', timing: true, }, + mocks: { + // note, this is relative to test/fixtures/mock-npm.js not this file + '../../lib/utils/timers.js': mockTimers, + }, + }) + + await exitHandler(new Error()) + + t.match(logs.error.filter(([t]) => t === ''), [['', `error writing to the directory`]]) +}) + +t.test('log files fail to write', async (t) => { + // we want the fsMiniPass.WriteStreamSync in the LogFile class to fail + const mockLogFile = t.mock('../../../lib/utils/log-file.js', { + 'fs-minipass': { + ...fsMiniPass, + WriteStreamSync: (file, ...rest) => { + if (file.includes('LOGS_DIR')) { + throw new Error('err') + } + }, + }, + }) + + const { exitHandler, logs } = await mockExitHandler(t, { + config: { + 'logs-dir': 'LOGS_DIR', + }, + mocks: { + // note, this is relative to test/fixtures/mock-npm.js not this file + '../../lib/utils/log-file.js': mockLogFile, + }, + }) + + await exitHandler(new Error()) + + t.match(logs.error.filter(([t]) => t === ''), [['', `error writing to the directory`]]) +}) + +t.test('files from error message', async (t) => { + const { exitHandler, logs, cache } = await mockExitHandler(t, { + files: [ + ['error-file.txt', '# error file content'], + ], + }) + + await exitHandler(err('Error message')) + + const logFiles = fs.readdirSync(join(cache, '_logs')) + const errorFileName = logFiles.find(f => f.endsWith('error-file.txt')) + const errorFile = fs.readFileSync(join(cache, '_logs', errorFileName)).toString() + + const [log] = logs.error.filter(([t]) => t === '') + + t.match(log[1], /For a full report see:\n.*-error-file\.txt/) + t.match(errorFile, '# error file content') + t.match(errorFile, 'Log files:') +}) + +t.test('files from error message with error', async (t) => { + const { exitHandler, logs } = await mockExitHandler(t, { + config: { + 'logs-dir': 'LOGS_DIR', + }, + files: [ + ['error-file.txt', '# error file content'], + ], + mocks: { + fs: { + ...fs, + writeFileSync: (dir) => { + if (dir.includes('LOGS_DIR') && dir.endsWith('error-file.txt')) { + throw new Error('err') + } + }, + }, + }, + }) + + await exitHandler(err('Error message')) + + const [log] = logs.warn.filter(([t]) => t === '') + + t.match(log[1], /Could not write error message to.*error-file\.txt.*err/) +}) + +t.test('timing with no error', async (t) => { + const { exitHandler, timingFile, npm, logs } = await mockExitHandler(t, { + config: { timing: true }, }) await exitHandler() @@ -285,12 +452,12 @@ t.test('timing with no error', async (t) => { t.equal(process.exitCode, 0) - t.match(logs.error, [ - ['', /A complete log of this run can be found in:[\s\S]*-debug-\d\.log/], - ]) + const msg = logs.info.filter(([t]) => t === '')[0][1] + t.match(msg, /A complete log of this run can be found in:/) + t.match(msg, /Timing info written to:/) t.match( - timingFileData, + timingFileData.timers, Object.keys(npm.finishedTimers).reduce((acc, k) => { acc[k] = Number return acc @@ -298,19 +465,20 @@ t.test('timing with no error', async (t) => { ) t.strictSame(npm.unfinishedTimers, new Map()) t.match(timingFileData, { - command: [], - version: '1.0.0', - npm: Number, - logfile: String, - logfiles: [String], + metadata: { + command: [], + version: '1.0.0', + logfiles: [String], + }, + timers: { + npm: Number, + }, }) }) t.test('unfinished timers', async (t) => { const { exitHandler, timingFile, npm } = await mockExitHandler(t, { - config: { - timing: true, - }, + config: { timing: true }, }) process.emit('time', 'foo') @@ -322,12 +490,15 @@ t.test('unfinished timers', async (t) => { t.equal(process.exitCode, 0) t.match(npm.unfinishedTimers, new Map([['foo', Number], ['bar', Number]])) t.match(timingFileData, { - command: [], - version: '1.0.0', - npm: Number, - logfile: String, - logfiles: [String], - unfinished: { + metadata: { + command: [], + version: '1.0.0', + logfiles: [String], + }, + timers: { + npm: Number, + }, + unfinishedTimers: { foo: [Number, Number], bar: [Number, Number], }, @@ -376,7 +547,7 @@ t.test('verbose logs replace info on err props', async t => { await exitHandler(err('Error with code type number', properties)) t.equal(process.exitCode, 1) t.match( - logs.verbose.filter(([p]) => p !== 'logfile'), + logs.verbose.filter(([p]) => !['logfile', 'title', 'argv'].includes(p)), keys.map((k) => [k, `${k}-https://user:***@registry.npmjs.org/`]), 'all special keys get replaced' ) @@ -416,7 +587,10 @@ t.test('exits uncleanly when only emitting exit event', async (t) => { t.test('do no fancy handling for shellouts', async t => { const { exitHandler, npm, logs } = await mockExitHandler(t) + const exec = await npm.cmd('exec') + npm.command = 'exec' + npm.commandInstance = exec const loudNoises = () => logs.filter(([level]) => ['warn', 'error'].includes(level)) diff --git a/test/lib/utils/explain-dep.js b/test/lib/utils/explain-dep.js index 000f5b8..ed006c0 100644 --- a/test/lib/utils/explain-dep.js +++ b/test/lib/utils/explain-dep.js @@ -129,6 +129,23 @@ const cases = { dependents: [], extraneous: true, }, + + overridden: { + name: 'overridden-root', + version: '1.0.0', + location: 'node_modules/overridden-root', + overridden: true, + dependents: [{ + type: 'prod', + name: 'overridden-dep', + spec: '1.0.0', + rawSpec: '^2.0.0', + overridden: true, + from: { + location: '/path/to/project', + }, + }], + }, } cases.manyDeps = { diff --git a/test/lib/utils/explain-eresolve.js b/test/lib/utils/explain-eresolve.js index f9710ee..2c1fed7 100644 --- a/test/lib/utils/explain-eresolve.js +++ b/test/lib/utils/explain-eresolve.js @@ -1,41 +1,32 @@ const t = require('tap') -const npm = {} -const { explain, report } = require('../../../lib/utils/explain-eresolve.js') -const { statSync, readFileSync, unlinkSync } = require('fs') -// strip out timestamps from reports -const read = f => readFileSync(f, 'utf8') - .replace(/\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}.\d{3}Z/g, '${TIME}') - const { resolve } = require('path') +const { explain, report } = require('../../../lib/utils/explain-eresolve.js') const cases = require('../../fixtures/eresolve-explanations.js') +const { cleanDate } = require('../../fixtures/clean-snapshot.js') for (const [name, expl] of Object.entries(cases)) { // no sense storing the whole contents of each object in the snapshot // we can trust that JSON.stringify still works just fine. - expl.toJSON = () => { - return { name, json: true } - } + expl.toJSON = () => ({ name, json: true }) t.test(name, t => { - npm.cache = t.testdir() - const reportFile = resolve(npm.cache, 'eresolve-report.txt') - t.cleanSnapshot = str => str.split(reportFile).join('${REPORT}') + const dir = t.testdir() + const fileReport = resolve(dir, 'eresolve-report.txt') + const opts = { file: fileReport, date: new Date().toISOString() } - npm.color = true - t.matchSnapshot(report(expl, true, reportFile), 'report with color') - const reportData = read(reportFile) - t.matchSnapshot(reportData, 'report') - unlinkSync(reportFile) + t.cleanSnapshot = str => cleanDate(str.split(fileReport).join('${REPORT}')) - t.matchSnapshot(report(expl, false, reportFile), 'report with no color') - t.equal(read(reportFile), reportData, 'same report written for object') - unlinkSync(reportFile) + const color = report(expl, true, opts) + t.matchSnapshot(color.explanation, 'report with color') + t.matchSnapshot(color.file, 'report from color') + + const noColor = report(expl, false, opts) + t.matchSnapshot(noColor.explanation, 'report with no color') + t.equal(noColor.file, color.file, 'same report written for object') t.matchSnapshot(explain(expl, true, 2), 'explain with color, depth of 2') - t.throws(() => statSync(reportFile), { code: 'ENOENT' }, 'no report') t.matchSnapshot(explain(expl, false, 6), 'explain with no color, depth of 6') - t.throws(() => statSync(reportFile), { code: 'ENOENT' }, 'no report') t.end() }) diff --git a/test/lib/utils/file-exists.js b/test/lib/utils/file-exists.js deleted file mode 100644 index c8edf4d..0000000 --- a/test/lib/utils/file-exists.js +++ /dev/null @@ -1,30 +0,0 @@ -const t = require('tap') -const fileExists = require('../../../lib/utils/file-exists.js') - -t.test('returns true when arg is a file', async (t) => { - const path = t.testdir({ - foo: 'just some file', - }) - - const result = await fileExists(`${path}/foo`) - t.equal(result, true, 'file exists') - t.end() -}) - -t.test('returns false when arg is not a file', async (t) => { - const path = t.testdir({ - foo: {}, - }) - - const result = await fileExists(`${path}/foo`) - t.equal(result, false, 'file does not exist') - t.end() -}) - -t.test('returns false when arg does not exist', async (t) => { - const path = t.testdir() - - const result = await fileExists(`${path}/foo`) - t.equal(result, false, 'file does not exist') - t.end() -}) diff --git a/test/lib/utils/get-identity.js b/test/lib/utils/get-identity.js deleted file mode 100644 index 5e6de9c..0000000 --- a/test/lib/utils/get-identity.js +++ /dev/null @@ -1,103 +0,0 @@ -const t = require('tap') - -t.test('throws ENOREGISTRY when no registry option is provided', async (t) => { - t.plan(2) - const getIdentity = t.mock('../../../lib/utils/get-identity.js') - - try { - await getIdentity({}) - } catch (err) { - t.equal(err.code, 'ENOREGISTRY', 'assigns the appropriate error code') - t.equal(err.message, 'No registry specified.', 'returns the correct error message') - } -}) - -t.test('returns username from uri when provided', async (t) => { - t.plan(1) - - const getIdentity = t.mock('../../../lib/utils/get-identity.js') - const npm = { - config: { - getCredentialsByURI: () => { - return { username: 'foo' } - }, - }, - } - - const identity = await getIdentity(npm, { registry: 'https://registry.npmjs.org' }) - t.equal(identity, 'foo', 'returns username from uri') -}) - -t.test('calls registry whoami when token is provided', async (t) => { - t.plan(3) - - const options = { - registry: 'https://registry.npmjs.org', - token: 'thisisnotreallyatoken', - } - - const getIdentity = t.mock('../../../lib/utils/get-identity.js', { - 'npm-registry-fetch': { - json: (path, opts) => { - t.equal(path, '/-/whoami', 'calls whoami') - t.same(opts, options, 'passes through provided options') - return { username: 'foo' } - }, - }, - }) - const npm = { - config: { - getCredentialsByURI: () => options, - }, - } - - const identity = await getIdentity(npm, options) - t.equal(identity, 'foo', 'fetched username from registry') -}) - -t.test('throws ENEEDAUTH when response does not include a username', async (t) => { - t.plan(3) - - const options = { - registry: 'https://registry.npmjs.org', - token: 'thisisnotreallyatoken', - } - - const getIdentity = t.mock('../../../lib/utils/get-identity.js', { - 'npm-registry-fetch': { - json: (path, opts) => { - t.equal(path, '/-/whoami', 'calls whoami') - t.same(opts, options, 'passes through provided options') - return {} - }, - }, - }) - const npm = { - config: { - getCredentialsByURI: () => options, - }, - } - - try { - await getIdentity(npm, options) - } catch (err) { - t.equal(err.code, 'ENEEDAUTH', 'throws correct error code') - } -}) - -t.test('throws ENEEDAUTH when neither username nor token is configured', async (t) => { - t.plan(1) - const getIdentity = t.mock('../../../lib/utils/get-identity.js', { - }) - const npm = { - config: { - getCredentialsByURI: () => ({}), - }, - } - - try { - await getIdentity(npm, { registry: 'https://registry.npmjs.org' }) - } catch (err) { - t.equal(err.code, 'ENEEDAUTH', 'throws correct error code') - } -}) diff --git a/test/lib/utils/hosted-git-info-from-manifest.js b/test/lib/utils/hosted-git-info-from-manifest.js deleted file mode 100644 index 516d3d5..0000000 --- a/test/lib/utils/hosted-git-info-from-manifest.js +++ /dev/null @@ -1,21 +0,0 @@ -const t = require('tap') -const hostedFromMani = require('../../../lib/utils/hosted-git-info-from-manifest.js') -const hostedGitInfo = require('hosted-git-info') - -t.equal(hostedFromMani({}), null) -t.equal(hostedFromMani({ repository: { no: 'url' } }), null) -t.equal(hostedFromMani({ repository: 123 }), null) -t.equal(hostedFromMani({ repository: 'not hosted anywhere' }), null) -t.equal(hostedFromMani({ repository: { url: 'not hosted anywhere' } }), null) - -t.match(hostedFromMani({ - repository: 'git+https://github.com/isaacs/abbrev-js', -}), hostedGitInfo.fromUrl('git+https://github.com/isaacs/abbrev-js')) - -t.match(hostedFromMani({ - repository: { url: 'git+https://github.com/isaacs/abbrev-js' }, -}), hostedGitInfo.fromUrl('https://github.com/isaacs/abbrev-js')) - -t.match(hostedFromMani({ - repository: { url: 'git+ssh://git@github.com/isaacs/abbrev-js' }, -}), hostedGitInfo.fromUrl('ssh://git@github.com/isaacs/abbrev-js')) diff --git a/test/lib/utils/is-windows-bash.js b/test/lib/utils/is-windows-bash.js deleted file mode 100644 index 0fbebdf..0000000 --- a/test/lib/utils/is-windows-bash.js +++ /dev/null @@ -1,30 +0,0 @@ -const t = require('tap') -const mockGlobal = require('../../fixtures/mock-globals.js') - -const isWindowsBash = () => { - delete require.cache[require.resolve('../../../lib/utils/is-windows-bash.js')] - delete require.cache[require.resolve('../../../lib/utils/is-windows.js')] - return require('../../../lib/utils/is-windows-bash.js') -} - -t.test('posix', (t) => { - mockGlobal(t, { 'process.platform': 'posix' }) - t.equal(isWindowsBash(), false, 'false when not windows') - - t.end() -}) - -t.test('win32', (t) => { - mockGlobal(t, { 'process.platform': 'win32' }) - - mockGlobal(t, { 'process.env': { TERM: 'dumb', MSYSTEM: undefined } }) - t.equal(isWindowsBash(), false, 'false when not mingw or cygwin') - - mockGlobal(t, { 'process.env.TERM': 'cygwin' }) - t.equal(isWindowsBash(), true, 'true when cygwin') - - mockGlobal(t, { 'process.env': { TERM: 'dumb', MSYSTEM: 'MINGW64' } }) - t.equal(isWindowsBash(), true, 'true when mingw') - - t.end() -}) diff --git a/test/lib/utils/is-windows-shell.js b/test/lib/utils/is-windows-shell.js deleted file mode 100644 index 9551992..0000000 --- a/test/lib/utils/is-windows-shell.js +++ /dev/null @@ -1,8 +0,0 @@ -const t = require('tap') -Object.defineProperty(process, 'platform', { - value: 'win32', -}) -const isWindows = require('../../../lib/utils/is-windows.js') -const isWindowsBash = require('../../../lib/utils/is-windows-bash.js') -const isWindowsShell = require('../../../lib/utils/is-windows-shell.js') -t.equal(isWindowsShell, isWindows && !isWindowsBash) diff --git a/test/lib/utils/is-windows.js b/test/lib/utils/is-windows.js deleted file mode 100644 index f8f2999..0000000 --- a/test/lib/utils/is-windows.js +++ /dev/null @@ -1,8 +0,0 @@ -const t = require('tap') -const actuallyWindows = process.platform === 'win32' -t.equal(actuallyWindows, require('../../../lib/utils/is-windows.js')) -Object.defineProperty(process, 'platform', { - value: actuallyWindows ? 'posix' : 'win32', -}) -delete require.cache[require.resolve('../../../lib/utils/is-windows.js')] -t.equal(!actuallyWindows, require('../../../lib/utils/is-windows.js')) diff --git a/test/lib/utils/log-file.js b/test/lib/utils/log-file.js index 007ce22..4be5231 100644 --- a/test/lib/utils/log-file.js +++ b/test/lib/utils/log-file.js @@ -6,10 +6,11 @@ const os = require('os') const fsMiniPass = require('fs-minipass') const rimraf = require('rimraf') const LogFile = require('../../../lib/utils/log-file.js') -const { cleanCwd } = require('../../fixtures/clean-snapshot') +const { cleanCwd, cleanDate } = require('../../fixtures/clean-snapshot') -t.cleanSnapshot = (path) => cleanCwd(path) +t.cleanSnapshot = (path) => cleanDate(cleanCwd(path)) +const getId = (d = new Date()) => d.toISOString().replace(/[.:]/g, '_') const last = arr => arr[arr.length - 1] const range = (n) => Array.from(Array(n).keys()) const makeOldLogs = (count, oldStyle) => { @@ -19,7 +20,7 @@ const makeOldLogs = (count, oldStyle) => { return range(oldStyle ? count : (count / 2)).reduce((acc, i) => { const cloneDate = new Date(d.getTime()) cloneDate.setSeconds(i) - const dateId = LogFile.logId(cloneDate) + const dateId = getId(cloneDate) if (oldStyle) { acc[`${dateId}-debug.log`] = 'hello' } else { @@ -41,10 +42,15 @@ const cleanErr = (message) => { const loadLogFile = async (t, { buffer = [], mocks, testdir = {}, ...options } = {}) => { const root = t.testdir(testdir) + const MockLogFile = t.mock('../../../lib/utils/log-file.js', mocks) const logFile = new MockLogFile(Object.keys(options).length ? options : undefined) + buffer.forEach((b) => logFile.log(...b)) - await logFile.load({ dir: root, ...options }) + + const id = getId() + await logFile.load({ path: path.join(root, `${id}-`), ...options }) + t.teardown(() => logFile.off()) return { root, @@ -116,12 +122,12 @@ t.test('max files per process', async t => { } for (const i of range(5)) { - logFile.log('verbose', `log ${i}`) + logFile.log('verbose', `ignored after maxlogs hit ${i}`) } const logs = await readLogs() t.equal(logs.length, maxFilesPerProcess, 'total log files') - t.equal(last(last(logs).logs), '49 error log 49') + t.match(last(last(logs).logs), /49 error log \d+/) }) t.test('stream error', async t => { @@ -182,8 +188,7 @@ t.test('turns off', async t => { logFile.load() const logs = await readLogs() - t.equal(logs.length, 1) - t.equal(logs[0].logs[0], '0 error test') + t.match(last(last(logs).logs), /^\d+ error test$/) }) t.test('cleans logs', async t => { @@ -198,7 +203,7 @@ t.test('cleans logs', async t => { }) t.test('doesnt clean current log by default', async t => { - const logsMax = 0 + const logsMax = 1 const { readLogs, logFile } = await loadLogFile(t, { logsMax, testdir: makeOldLogs(10), @@ -207,7 +212,6 @@ t.test('doesnt clean current log by default', async t => { logFile.log('error', 'test') const logs = await readLogs() - t.equal(logs.length, 1) t.match(last(logs).content, /\d+ error test/) }) @@ -221,8 +225,7 @@ t.test('negative logs max', async t => { logFile.log('error', 'test') const logs = await readLogs() - t.equal(logs.length, 1) - t.match(last(logs).content, /\d+ error test/) + t.equal(logs.length, 0) }) t.test('doesnt need to clean', async t => { @@ -257,7 +260,7 @@ t.test('cleans old style logs too', async t => { const oldLogs = 10 const { readLogs } = await loadLogFile(t, { logsMax, - testdir: makeOldLogs(oldLogs, false), + testdir: makeOldLogs(oldLogs, true), }) const logs = await readLogs() @@ -304,7 +307,7 @@ t.test('delete log file while open', async t => { }) t.test('snapshot', async t => { - const { logFile, readLogs } = await loadLogFile(t) + const { logFile, readLogs } = await loadLogFile(t, { logsMax: 10 }) logFile.log('error', '', 'no prefix') logFile.log('error', 'prefix', 'with prefix') diff --git a/test/lib/utils/npm-usage.js b/test/lib/utils/npm-usage.js deleted file mode 100644 index 035d4bb..0000000 --- a/test/lib/utils/npm-usage.js +++ /dev/null @@ -1,60 +0,0 @@ -const t = require('tap') -const { load: loadMockNpm } = require('../../fixtures/mock-npm.js') - -t.test('usage', async t => { - const { npm } = await loadMockNpm(t) - t.afterEach(() => { - npm.config.set('viewer', null) - npm.config.set('long', false) - npm.config.set('userconfig', '/some/config/file/.npmrc') - }) - const { dirname } = require('path') - const basedir = dirname(dirname(dirname(__dirname))) - t.cleanSnapshot = str => str.split(basedir).join('{BASEDIR}') - .split(require('../../../package.json').version).join('{VERSION}') - - npm.config.set('viewer', null) - npm.config.set('long', false) - npm.config.set('userconfig', '/some/config/file/.npmrc') - - t.test('basic usage', async t => { - t.matchSnapshot(await npm.usage) - t.end() - }) - - t.test('with browser', async t => { - npm.config.set('viewer', 'browser') - t.matchSnapshot(await npm.usage) - t.end() - }) - - t.test('with long', async t => { - npm.config.set('long', true) - t.matchSnapshot(await npm.usage) - t.end() - }) - - t.test('set process.stdout.columns', async t => { - const { columns } = process.stdout - t.teardown(() => { - Object.defineProperty(process.stdout, 'columns', { - value: columns, - enumerable: true, - configurable: true, - writable: true, - }) - }) - const cases = [0, 90] - for (const cols of cases) { - t.test(`columns=${cols}`, async t => { - Object.defineProperty(process.stdout, 'columns', { - value: cols, - enumerable: true, - configurable: true, - writable: true, - }) - t.matchSnapshot(await npm.usage) - }) - } - }) -}) diff --git a/test/lib/utils/open-url-prompt.js b/test/lib/utils/open-url-prompt.js new file mode 100644 index 0000000..a18fe85 --- /dev/null +++ b/test/lib/utils/open-url-prompt.js @@ -0,0 +1,184 @@ +const t = require('tap') +const mockGlobals = require('../../fixtures/mock-globals.js') +const EventEmitter = require('events') + +const OUTPUT = [] +const output = (...args) => OUTPUT.push(args) +const npm = { + _config: { + json: false, + browser: true, + }, + config: { + get: k => npm._config[k], + set: (k, v) => { + npm._config[k] = v + }, + }, + output, +} + +let openerUrl = null +let openerOpts = null +let openerResult = null + +const open = async (url, options) => { + openerUrl = url + openerOpts = options + if (openerResult) { + throw openerResult + } +} + +let questionShouldResolve = true +let openUrlPromptInterrupted = false + +const readline = { + createInterface: () => ({ + question: (_q, cb) => { + if (questionShouldResolve === true) { + cb() + } + }, + close: () => {}, + on: (_signal, cb) => { + if (openUrlPromptInterrupted && _signal === 'SIGINT') { + cb() + } + }, + }), +} + +const openUrlPrompt = t.mock('../../../lib/utils/open-url-prompt.js', { + '@npmcli/promise-spawn': { + open, + }, + readline, +}) + +mockGlobals(t, { + 'process.stdin.isTTY': true, + 'process.stdout.isTTY': true, +}) + +t.test('does not open a url in non-interactive environments', async t => { + t.teardown(() => { + openerUrl = null + openerOpts = null + OUTPUT.length = 0 + }) + + mockGlobals(t, { + 'process.stdin.isTTY': false, + 'process.stdout.isTTY': false, + }) + + await openUrlPrompt(npm, 'https://www.npmjs.com', 'npm home', 'prompt') + t.equal(openerUrl, null, 'did not open') + t.same(openerOpts, null, 'did not open') +}) + +t.test('opens a url', async t => { + t.teardown(() => { + openerUrl = null + openerOpts = null + OUTPUT.length = 0 + npm._config.browser = true + }) + + npm._config.browser = 'browser' + await openUrlPrompt(npm, 'https://www.npmjs.com', 'npm home', 'prompt') + t.equal(openerUrl, 'https://www.npmjs.com', 'opened the given url') + t.same(openerOpts, { command: 'browser' }, 'passed command as null (the default)') + t.matchSnapshot(OUTPUT) +}) + +t.test('prints json output', async t => { + t.teardown(() => { + openerUrl = null + openerOpts = null + OUTPUT.length = 0 + npm._config.json = false + }) + + npm._config.json = true + await openUrlPrompt(npm, 'https://www.npmjs.com', 'npm home', 'prompt') + t.matchSnapshot(OUTPUT) +}) + +t.test('returns error for non-https url', async t => { + t.teardown(() => { + openerUrl = null + openerOpts = null + OUTPUT.length = 0 + }) + await t.rejects( + openUrlPrompt(npm, 'ftp://www.npmjs.com', 'npm home', 'prompt'), + /Invalid URL/, + 'got the correct error' + ) + t.equal(openerUrl, null, 'did not open') + t.same(openerOpts, null, 'did not open') + t.same(OUTPUT, [], 'printed no output') +}) + +t.test('does not open url if canceled', async t => { + t.teardown(() => { + openerUrl = null + openerOpts = null + OUTPUT.length = 0 + questionShouldResolve = true + }) + + questionShouldResolve = false + const emitter = new EventEmitter() + + const open = openUrlPrompt(npm, 'https://www.npmjs.com', 'npm home', 'prompt', emitter) + + emitter.emit('abort') + + await open + + t.equal(openerUrl, null, 'did not open') + t.same(openerOpts, null, 'did not open') +}) + +t.test('returns error when opener errors', async t => { + t.teardown(() => { + openerUrl = null + openerOpts = null + openerResult = null + OUTPUT.length = 0 + }) + + openerResult = new Error('Opener failed') + + await t.rejects( + openUrlPrompt(npm, 'https://www.npmjs.com', 'npm home', 'prompt'), + /Opener failed/, + 'got the correct error' + ) + t.equal(openerUrl, 'https://www.npmjs.com', 'did not open') +}) + +t.test('throws "canceled" error on SIGINT', async t => { + t.teardown(() => { + openerUrl = null + openerOpts = null + OUTPUT.length = 0 + questionShouldResolve = true + openUrlPromptInterrupted = false + }) + + questionShouldResolve = false + openUrlPromptInterrupted = true + const emitter = new EventEmitter() + + const open = openUrlPrompt(npm, 'https://www.npmjs.com', 'npm home', 'prompt', emitter) + + try { + await open + } catch (err) { + t.equal(err.message, 'canceled') + } +}) diff --git a/test/lib/utils/open-url.js b/test/lib/utils/open-url.js index 1bf47d8..70afd55 100644 --- a/test/lib/utils/open-url.js +++ b/test/lib/utils/open-url.js @@ -19,14 +19,19 @@ const npm = { let openerUrl = null let openerOpts = null let openerResult = null -const opener = (url, opts, cb) => { + +const open = async (url, options) => { openerUrl = url - openerOpts = opts - return cb(openerResult) + openerOpts = options + if (openerResult) { + throw openerResult + } } const openUrl = t.mock('../../../lib/utils/open-url.js', { - opener, + '@npmcli/promise-spawn': { + open, + }, }) t.test('opens a url', async t => { diff --git a/test/lib/utils/otplease.js b/test/lib/utils/otplease.js index b371196..79eaa79 100644 --- a/test/lib/utils/otplease.js +++ b/test/lib/utils/otplease.js @@ -1,11 +1,41 @@ const t = require('tap') +const { fake: mockNpm } = require('../../fixtures/mock-npm') +const mockGlobals = require('../../fixtures/mock-globals') + const readUserInfo = { otp: async () => '1234', } +const webAuth = async (opener) => { + opener() + return '1234' +} const otplease = t.mock('../../../lib/utils/otplease.js', { '../../../lib/utils/read-user-info.js': readUserInfo, + '../../../lib/utils/open-url-prompt.js': () => {}, + '../../../lib/utils/web-auth': webAuth, +}) + +t.test('returns function results on success', async (t) => { + const fn = () => 'test string' + const result = await otplease(null, {}, fn) + t.equal('test string', result) +}) + +t.test('returns function results on otp success', async (t) => { + mockGlobals(t, { + 'process.stdin': { isTTY: true }, + 'process.stdout': { isTTY: true }, + }) + const fn = ({ otp }) => { + if (otp) { + return 'success' + } + throw Object.assign(new Error('nope'), { code: 'EOTP' }) + } + const result = await otplease(null, {}, fn) + t.equal('success', result) }) t.test('prompts for otp for EOTP', async (t) => { @@ -29,7 +59,31 @@ t.test('prompts for otp for EOTP', async (t) => { t.end() } - await otplease({ some: 'prop' }, fn) + await otplease(null, { some: 'prop' }, fn) +}) + +t.test('returns function results on webauth success', async (t) => { + mockGlobals(t, { + 'process.stdin': { isTTY: true }, + 'process.stdout': { isTTY: true }, + }) + + const npm = mockNpm({ config: { browser: 'firefox' } }) + const fn = ({ otp }) => { + if (otp) { + return 'success' + } + throw Object.assign(new Error('nope'), { + code: 'EOTP', + body: { + authUrl: 'https://www.example.com/auth', + doneUrl: 'https://www.example.com/done', + }, + }) + } + + const result = await otplease(npm, {}, fn) + t.equal('success', result) }) t.test('prompts for otp for 401', async (t) => { @@ -56,7 +110,7 @@ t.test('prompts for otp for 401', async (t) => { t.end() } - await otplease({ some: 'prop' }, fn) + await otplease(null, { some: 'prop' }, fn) }) t.test('does not prompt for non-otp errors', async (t) => { @@ -73,7 +127,11 @@ t.test('does not prompt for non-otp errors', async (t) => { throw new Error('nope') } - t.rejects(otplease({ some: 'prop' }, fn), { message: 'nope' }, 'rejects with the original error') + t.rejects( + otplease(null, { some: 'prop' }, fn), + { message: 'nope' }, + 'rejects with the original error' + ) }) t.test('does not prompt if stdin or stdout is not a tty', async (t) => { @@ -90,5 +148,9 @@ t.test('does not prompt if stdin or stdout is not a tty', async (t) => { throw Object.assign(new Error('nope'), { code: 'EOTP' }) } - t.rejects(otplease({ some: 'prop' }, fn), { message: 'nope' }, 'rejects with the original error') + t.rejects( + otplease(null, { some: 'prop' }, fn), + { message: 'nope' }, + 'rejects with the original error' + ) }) diff --git a/test/lib/utils/path.js b/test/lib/utils/path.js deleted file mode 100644 index 0a7846d..0000000 --- a/test/lib/utils/path.js +++ /dev/null @@ -1,12 +0,0 @@ -const t = require('tap') -const mod = '../../../lib/utils/path.js' -const delim = require('../../../lib/utils/is-windows.js') ? ';' : ':' -Object.defineProperty(process, 'env', { - value: {}, -}) -process.env.path = ['foo', 'bar', 'baz'].join(delim) -t.strictSame(t.mock(mod), ['foo', 'bar', 'baz']) -process.env.Path = ['a', 'b', 'c'].join(delim) -t.strictSame(t.mock(mod), ['a', 'b', 'c']) -process.env.PATH = ['x', 'y', 'z'].join(delim) -t.strictSame(t.mock(mod), ['x', 'y', 'z']) diff --git a/test/lib/utils/ping.js b/test/lib/utils/ping.js deleted file mode 100644 index 1bebfa6..0000000 --- a/test/lib/utils/ping.js +++ /dev/null @@ -1,35 +0,0 @@ -const t = require('tap') - -t.test('pings', async (t) => { - t.plan(3) - - const options = { fake: 'options' } - const response = { some: 'details' } - const ping = t.mock('../../../lib/utils/ping.js', { - 'npm-registry-fetch': (url, opts) => { - t.equal(url, '/-/ping?write=true', 'calls the correct url') - t.equal(opts, options, 'passes through options') - return { json: () => Promise.resolve(response) } - }, - }) - - const res = await ping(options) - t.match(res, response, 'returns json response') -}) - -t.test('catches errors and returns empty json', async (t) => { - t.plan(3) - - const options = { fake: 'options' } - const response = { some: 'details' } - const ping = t.mock('../../../lib/utils/ping.js', { - 'npm-registry-fetch': (url, opts) => { - t.equal(url, '/-/ping?write=true', 'calls the correct url') - t.equal(opts, options, 'passes through options') - return { json: () => Promise.reject(response) } - }, - }) - - const res = await ping(options) - t.match(res, {}, 'returns empty json response') -}) diff --git a/test/lib/utils/read-package-name.js b/test/lib/utils/read-package-name.js deleted file mode 100644 index a1a1b4a..0000000 --- a/test/lib/utils/read-package-name.js +++ /dev/null @@ -1,33 +0,0 @@ -const t = require('tap') - -const readPackageName = require('../../../lib/utils/read-package-name.js') - -t.test('read local package.json', async (t) => { - const prefix = t.testdir({ - 'package.json': JSON.stringify({ - name: 'my-local-package', - version: '1.0.0', - }), - }) - const packageName = await readPackageName(prefix) - t.equal( - packageName, - 'my-local-package', - 'should retrieve current package name' - ) -}) - -t.test('read local scoped-package.json', async (t) => { - const prefix = t.testdir({ - 'package.json': JSON.stringify({ - name: '@my-scope/my-local-package', - version: '1.0.0', - }), - }) - const packageName = await readPackageName(prefix) - t.equal( - packageName, - '@my-scope/my-local-package', - 'should retrieve scoped package name' - ) -}) diff --git a/test/lib/utils/reify-output.js b/test/lib/utils/reify-output.js index 4e9ed71..b38a14d 100644 --- a/test/lib/utils/reify-output.js +++ b/test/lib/utils/reify-output.js @@ -1,9 +1,4 @@ const t = require('tap') -const log = require('../../../lib/utils/log-shim') - -const _level = log.level -t.beforeEach(() => log.level = 'warn') -t.teardown(() => log.level = _level) t.cleanSnapshot = str => str.replace(/in [0-9]+m?s/g, 'in {TIME}') @@ -13,6 +8,7 @@ const settings = { const npm = { started: Date.now(), flatOptions: settings, + silent: false, } const reifyOutput = require('../../../lib/utils/reify-output.js') t.test('missing info', (t) => { @@ -236,10 +232,13 @@ t.test('showing and not showing audit report', async t => { } t.test('no output when silent', t => { + t.teardown(() => { + delete npm.silent + }) + npm.silent = true npm.output = out => { t.fail('should not get output when silent', { actual: out }) } - log.level = 'silent' reifyOutput(npm, { actualTree: { inventory: { size: 999 }, children: [] }, auditReport, diff --git a/test/lib/utils/replace-info.js b/test/lib/utils/replace-info.js index e4b8378..c7fffdb 100644 --- a/test/lib/utils/replace-info.js +++ b/test/lib/utils/replace-info.js @@ -19,12 +19,30 @@ t.equal( 'should return numbers' ) +t.equal( + replaceInfo(' == = = '), + ' == = = ', + 'should return same string with only separators' +) + +t.equal( + replaceInfo(''), + '', + 'should return empty string' +) + t.equal( replaceInfo('https://user:pass@registry.npmjs.org/'), 'https://user:***@registry.npmjs.org/', 'should replace single item' ) +t.equal( + replaceInfo(`https://registry.npmjs.org/path/npm_${'a'.repeat('36')}`), + 'https://registry.npmjs.org/path/npm_***', + 'should replace single item token' +) + t.equal( replaceInfo('https://example.npmjs.org'), 'https://example.npmjs.org', @@ -49,6 +67,12 @@ t.equal( 'should replace single item within a phrase' ) +t.equal( + replaceInfo('Something --x=https://user:pass@registry.npmjs.org/ foo bar'), + 'Something --x=https://user:***@registry.npmjs.org/ foo bar', + 'should replace single item within a phrase separated by =' +) + t.same( replaceInfo([ 'Something https://user:pass@registry.npmjs.org/ foo bar', @@ -60,7 +84,21 @@ t.same( 'http://foo:***@registry.npmjs.org', 'http://example.npmjs.org', ], - 'should replace single item within a phrase' + 'should replace items in an array' +) + +t.same( + replaceInfo([ + 'Something --x=https://user:pass@registry.npmjs.org/ foo bar', + '--url=http://foo:bar@registry.npmjs.org', + '--url=http://example.npmjs.org', + ]), + [ + 'Something --x=https://user:***@registry.npmjs.org/ foo bar', + '--url=http://foo:***@registry.npmjs.org', + '--url=http://example.npmjs.org', + ], + 'should replace items in an array with equals' ) t.same( diff --git a/test/lib/utils/split-package-names.js b/test/lib/utils/split-package-names.js deleted file mode 100644 index 5fe1e6c..0000000 --- a/test/lib/utils/split-package-names.js +++ /dev/null @@ -1,18 +0,0 @@ -'use strict' - -const t = require('tap') -const splitPackageNames = require('../../../lib/utils/split-package-names.js') - -t.test('splitPackageNames', t => { - const assertions = [ - ['semver', 'semver'], - ['read-pkg/semver', 'read-pkg/node_modules/semver'], - ['@npmcli/one/@npmcli/two', '@npmcli/one/node_modules/@npmcli/two'], - ['@npmcli/one/semver', '@npmcli/one/node_modules/semver'], - ] - - for (const [input, expected] of assertions) { - t.equal(splitPackageNames(input), expected, `split ${input} correctly`) - } - t.end() -}) diff --git a/test/lib/utils/tar.js b/test/lib/utils/tar.js index adc5cb3..f72b143 100644 --- a/test/lib/utils/tar.js +++ b/test/lib/utils/tar.js @@ -27,12 +27,17 @@ t.test('should log tarball contents', async (t) => { bundleDependencies: [ 'bundle-dep', ], - }, null, 2), + dependencies: { + 'bundle-dep': '1.0.0', + }, + }), cat: 'meow', chai: 'blub', dog: 'woof', node_modules: { - 'bundle-dep': 'toto', + 'bundle-dep': { + 'package.json': '', + }, }, }) @@ -46,6 +51,38 @@ t.test('should log tarball contents', async (t) => { t.matchSnapshot(printLogs(tarballContents)) }) +t.test('should log tarball contents of a scoped package', async (t) => { + const testDir = t.testdir({ + 'package.json': JSON.stringify({ + name: '@myscope/my-cool-pkg', + version: '1.0.0', + bundleDependencies: [ + 'bundle-dep', + ], + dependencies: { + 'bundle-dep': '1.0.0', + }, + }), + cat: 'meow', + chai: 'blub', + dog: 'woof', + node_modules: { + 'bundle-dep': { + 'package.json': '', + }, + }, + }) + + const tarball = await pack(testDir) + const tarballContents = await getContents({ + _id: '1', + name: '@myscope/my-cool-pkg', + version: '1.0.0', + }, tarball) + + t.matchSnapshot(printLogs(tarballContents)) +}) + t.test('should log tarball contents with unicode', async (t) => { const { logTar } = mockTar({ notice: (str) => { diff --git a/test/lib/utils/timers.js b/test/lib/utils/timers.js index 6127f34..23d8eb6 100644 --- a/test/lib/utils/timers.js +++ b/test/lib/utils/timers.js @@ -1,5 +1,5 @@ const t = require('tap') -const { resolve } = require('path') +const { resolve, join } = require('path') const fs = require('graceful-fs') const mockLogs = require('../../fixtures/mock-logs') @@ -31,6 +31,17 @@ t.test('listens/stops on process', async (t) => { t.notOk(timers.unfinished.get('baz')) }) +t.test('convenience time method', async (t) => { + const { timers } = mockTimers(t) + + const end = timers.time('later') + timers.time('sync', () => {}) + await timers.time('async', () => new Promise(r => setTimeout(r, 10))) + end() + + t.match(timers.finished, { later: Number, sync: Number, async: Number }) +}) + t.test('initial timer', async (t) => { const { timers } = mockTimers(t, { start: 'foo' }) process.emit('timeEnd', 'foo') @@ -61,13 +72,13 @@ t.test('writes file', async (t) => { const dir = t.testdir() process.emit('time', 'foo') process.emit('timeEnd', 'foo') - timers.load({ dir }) + timers.load({ path: resolve(dir, `TIMING_FILE-`) }) timers.writeFile({ some: 'data' }) - const data = JSON.parse(fs.readFileSync(resolve(dir, '_timing.json'))) + const data = JSON.parse(fs.readFileSync(resolve(dir, 'TIMING_FILE-timing.json'))) t.match(data, { - some: 'data', - foo: Number, - unfinished: { + metadata: { some: 'data' }, + timers: { foo: Number }, + unfinishedTimers: { npm: [Number, Number], }, }) @@ -75,8 +86,21 @@ t.test('writes file', async (t) => { t.test('fails to write file', async (t) => { const { logs, timers } = mockTimers(t) + const dir = t.testdir() + + timers.load({ path: join(dir, 'does', 'not', 'exist') }) timers.writeFile() - t.match(logs.warn, [ - ['timing', 'could not write timing file', Error], - ]) + + t.match(logs.warn, [['timing', 'could not write timing file']]) + t.equal(timers.file, null) +}) + +t.test('no dir and no file', async (t) => { + const { logs, timers } = mockTimers(t) + + timers.load() + timers.writeFile() + + t.strictSame(logs, []) + t.equal(timers.file, null) }) diff --git a/test/lib/utils/unsupported.js b/test/lib/utils/unsupported.js deleted file mode 100644 index 2703044..0000000 --- a/test/lib/utils/unsupported.js +++ /dev/null @@ -1,102 +0,0 @@ -const t = require('tap') -const unsupported = require('../../../lib/utils/unsupported.js') -const mockGlobals = require('../../fixtures/mock-globals.js') - -const versions = [ - // broken unsupported - ['v0.1.103', true, true], - ['v0.2.0', true, true], - ['v0.3.5', true, true], - ['v0.4.7', true, true], - ['v0.5.3', true, true], - ['v0.6.17', true, true], - ['v0.7.8', true, true], - ['v0.8.28', true, true], - ['v0.9.6', true, true], - ['v0.10.48', true, true], - ['v0.11.16', true, true], - ['v0.12.9', true, true], - ['v1.0.1', true, true], - ['v1.6.0', true, true], - ['v2.3.1', true, true], - ['v3.0.0', true, true], - ['v4.5.0', true, true], - ['v4.8.4', true, true], - ['v5.7.1', true, true], - ['v6.8.1', false, true], - ['v7.0.0-beta23', false, true], - ['v7.2.3', false, true], - ['v8.4.0', false, true], - ['v9.3.0', false, true], - ['v10.0.0-0', false, true], - ['v11.0.0-0', false, true], - ['v12.0.0-0', false, true], - ['v12.13.0-0', false, false], - ['v13.0.0-0', false, true], - ['v14.0.0-0', false, true], - ['v14.15.0-0', false, false], - ['v15.0.0-0', false, true], - ['v16.0.0-0', false, false], -] - -t.test('versions', function (t) { - t.plan(versions.length * 2) - versions.forEach(function (verinfo) { - const version = verinfo[0] - const broken = verinfo[1] - const unsupp = verinfo[2] - const nodejs = unsupported.checkVersion(version) - t.equal(nodejs.broken, broken, version + ' ' + (broken ? '' : 'not ') + 'broken') - t.equal(nodejs.unsupported, unsupp, version + ' ' + (unsupp ? 'unsupported' : 'supported')) - }) - t.end() -}) - -t.test('checkForBrokenNode', t => { - // run it once to not fail - unsupported.checkForBrokenNode() - - const logs = [] - const expectLogs = [ - 'ERROR: npm is known not to run on Node.js 1.2.3', - "You'll need to upgrade to a newer Node.js version in order to use this", - 'version of npm. You can find the latest version at https://nodejs.org/', - ] - - // then make it a thing that fails - mockGlobals(t, { - 'console.error': msg => logs.push(msg), - 'process.version': '1.2.3', - 'process.exit': (code) => { - t.equal(code, 1) - t.strictSame(logs, expectLogs) - t.end() - }, - }) - - unsupported.checkForBrokenNode() -}) - -t.test('checkForUnsupportedNode', t => { - // run it once to not fail or warn - unsupported.checkForUnsupportedNode() - - const logs = [] - const expectLogs = [ - 'npm does not support Node.js 8.0.0', - 'You should probably upgrade to a newer version of node as we', - "can't make any promises that npm will work with this version.", - 'You can find the latest version at https://nodejs.org/', - ] - - // then make it a thing that fails - mockGlobals(t, { - 'console.error': msg => logs.push(msg), - 'process.version': '8.0.0', - }) - - unsupported.checkForUnsupportedNode() - - t.strictSame(logs, expectLogs) - t.end() -}) diff --git a/test/lib/utils/update-notifier.js b/test/lib/utils/update-notifier.js index a7a800c..fa4a04b 100644 --- a/test/lib/utils/update-notifier.js +++ b/test/lib/utils/update-notifier.js @@ -1,5 +1,5 @@ const t = require('tap') -let ciMock = null +let ciMock = {} const flatOptions = { global: false, cache: t.testdir() + '/_cacache' } const MANIFEST_REQUEST = [] @@ -84,14 +84,12 @@ t.afterEach(() => { }) const runUpdateNotifier = async ({ color = true, ...npmOptions } = {}) => { - const _npm = { ...defaultNpm, ...npmOptions } - await t.mock('../../../lib/utils/update-notifier.js', { - '@npmcli/ci-detect': () => ciMock, + const _npm = { ...defaultNpm, ...npmOptions, logColor: color } + return t.mock('../../../lib/utils/update-notifier.js', { + 'ci-info': ciMock, pacote, fs, - npmlog: { useColor: () => color }, })(_npm) - return _npm.updateNotification } t.test('situations in which we do not notify', t => { @@ -161,9 +159,9 @@ t.test('situations in which we do not notify', t => { t.test('do not update in CI', async t => { t.teardown(() => { - ciMock = null + ciMock = {} }) - ciMock = 'something' + ciMock = { isCI: true, name: 'something' } t.equal(await runUpdateNotifier(), null) t.strictSame(MANIFEST_REQUEST, [], 'no requests for manifests') }) diff --git a/test/lib/utils/web-auth.js b/test/lib/utils/web-auth.js new file mode 100644 index 0000000..ee8a17e --- /dev/null +++ b/test/lib/utils/web-auth.js @@ -0,0 +1,32 @@ +const t = require('tap') + +const webAuthCheckLogin = async () => { + return { token: 'otp-token' } +} + +const webauth = t.mock('../../../lib/utils/web-auth.js', { + 'npm-profile': { webAuthCheckLogin }, +}) + +const initialUrl = 'https://example.com/auth' +const doneUrl = 'https://example.com/done' +const opts = {} + +t.test('returns token on success', async (t) => { + const opener = async () => {} + const result = await webauth(opener, initialUrl, doneUrl, opts) + t.equal(result, 'otp-token') +}) + +t.test('closes opener when auth check finishes', async (t) => { + const opener = (_url, emitter) => { + return new Promise((resolve, reject) => { + // the only way to finish this promise is to emit aboter on the emitter + emitter.addListener('abort', () => { + resolve() + }) + }) + } + const result = await webauth(opener, initialUrl, doneUrl, opts) + t.equal(result, 'otp-token') +}) diff --git a/test/lib/workspaces/get-workspaces.js b/test/lib/workspaces/get-workspaces.js index 0d1bba3..4e48b1c 100644 --- a/test/lib/workspaces/get-workspaces.js +++ b/test/lib/workspaces/get-workspaces.js @@ -17,67 +17,67 @@ const clean = (res, path) => { return cleaned } -t.test('get-workspaces', async t => { - const path = t.testdir({ - packages: { - a: { - 'package.json': JSON.stringify({ - name: 'a', - version: '1.0.0', - scripts: { glorp: 'echo a doing the glerp glop' }, - }), - }, - b: { - 'package.json': JSON.stringify({ - name: 'b', - version: '2.0.0', - scripts: { glorp: 'echo b doing the glerp glop' }, - }), - }, - c: { - 'package.json': JSON.stringify({ - name: 'c', - version: '1.0.0', - scripts: { - test: 'exit 0', - posttest: 'echo posttest', - lorem: 'echo c lorem', - }, - }), - }, - d: { - 'package.json': JSON.stringify({ - name: 'd', - version: '1.0.0', - scripts: { - test: 'exit 0', - posttest: 'echo posttest', - }, - }), - }, - e: { - 'package.json': JSON.stringify({ - name: 'e', - scripts: { test: 'exit 0', start: 'echo start something' }, - }), - }, - noscripts: { - 'package.json': JSON.stringify({ - name: 'noscripts', - version: '1.0.0', - }), - }, +const path = t.testdir({ + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + scripts: { glorp: 'echo a doing the glerp glop' }, + }), }, - 'package.json': JSON.stringify({ - name: 'x', - version: '1.2.3', - workspaces: ['packages/*'], - }), - }) + b: { + 'package.json': JSON.stringify({ + name: 'b', + version: '2.0.0', + scripts: { glorp: 'echo b doing the glerp glop' }, + }), + }, + c: { + 'package.json': JSON.stringify({ + name: 'c', + version: '1.0.0', + scripts: { + test: 'exit 0', + posttest: 'echo posttest', + lorem: 'echo c lorem', + }, + }), + }, + d: { + 'package.json': JSON.stringify({ + name: 'd', + version: '1.0.0', + scripts: { + test: 'exit 0', + posttest: 'echo posttest', + }, + }), + }, + e: { + 'package.json': JSON.stringify({ + name: 'e', + scripts: { test: 'exit 0', start: 'echo start something' }, + }), + }, + noscripts: { + 'package.json': JSON.stringify({ + name: 'noscripts', + version: '1.0.0', + }), + }, + }, + 'package.json': JSON.stringify({ + name: 'x', + version: '1.2.3', + workspaces: ['packages/*'], + }), +}) - let workspaces +let workspaces - workspaces = await getWorkspaces(['a', 'b'], { path }) +t.test('filter by package name', async t => { + workspaces = await getWorkspaces(['a', 'b'], { path, relativeFrom: path }) t.same( clean(workspaces, path), new Map(Object.entries({ @@ -86,8 +86,11 @@ t.test('get-workspaces', async t => { })), 'should filter by package name' ) +}) - workspaces = await getWorkspaces(['a', 'b'], { path, includeWorkspaceRoot: true }) +t.test('include workspace root', async t => { + workspaces = await getWorkspaces(['a', 'b'], + { path, includeWorkspaceRoot: true, relativeFrom: path }) t.same( clean(workspaces, path), new Map(Object.entries({ @@ -97,8 +100,10 @@ t.test('get-workspaces', async t => { })), 'include rootspace root' ) +}) - workspaces = await getWorkspaces(['./packages/c'], { path }) +t.test('filter by package directory', async t => { + workspaces = await getWorkspaces(['./packages/c'], { path, relativeFrom: path }) t.same( clean(workspaces, path), new Map(Object.entries({ @@ -106,8 +111,10 @@ t.test('get-workspaces', async t => { })), 'should filter by package directory' ) +}) - workspaces = await getWorkspaces(['packages/c'], { path }) +t.test('filter by rel package directory', async t => { + workspaces = await getWorkspaces(['packages/c'], { path, relativeFrom: path }) t.same( clean(workspaces, path), new Map(Object.entries({ @@ -115,8 +122,10 @@ t.test('get-workspaces', async t => { })), 'should filter by rel package directory' ) +}) - workspaces = await getWorkspaces([resolve(path, 'packages/c')], { path }) +t.test('filter by absolute package directory', async t => { + workspaces = await getWorkspaces([resolve(path, 'packages/c')], { path, relativeFrom: path }) t.same( clean(workspaces, path), new Map(Object.entries({ @@ -124,8 +133,10 @@ t.test('get-workspaces', async t => { })), 'should filter by absolute package directory' ) +}) - workspaces = await getWorkspaces(['packages'], { path }) +t.test('filter by parent directory name', async t => { + workspaces = await getWorkspaces(['packages'], { path, relativeFrom: path }) t.same( clean(workspaces, path), new Map(Object.entries({ @@ -138,8 +149,10 @@ t.test('get-workspaces', async t => { })), 'should filter by parent directory name' ) +}) - workspaces = await getWorkspaces(['./packages/'], { path }) +t.test('filter by parent directory path', async t => { + workspaces = await getWorkspaces(['./packages/'], { path, relativeFrom: path }) t.same( clean(workspaces, path), new Map(Object.entries({ @@ -152,8 +165,10 @@ t.test('get-workspaces', async t => { })), 'should filter by parent directory path' ) +}) - workspaces = await getWorkspaces([resolve(path, './packages')], { path }) +t.test('filter by absolute parent directory path', async t => { + workspaces = await getWorkspaces([resolve(path, './packages')], { path, relativeFrom: path }) t.same( clean(workspaces, path), new Map(Object.entries({ @@ -166,8 +181,10 @@ t.test('get-workspaces', async t => { })), 'should filter by absolute parent directory path' ) +}) - workspaces = await getWorkspaces([], { path }) +t.test('no filter set', async t => { + workspaces = await getWorkspaces([], { path, relativeFrom: path }) t.same( clean(workspaces, path), new Map(Object.entries({ @@ -180,32 +197,26 @@ t.test('get-workspaces', async t => { })), 'should return all workspaces if no filter set' ) +}) - try { - await getWorkspaces(['missing'], { path }) - throw new Error('missed throw') - } catch (err) { - t.match( - err, - /No workspaces found/, - 'should throw no workspaces found error' - ) - } +t.test('missing workspace', async t => { + await t.rejects( + getWorkspaces(['missing'], { path, relativeFrom: path }), + /No workspaces found/, + 'should throw no workspaces found error' + ) +}) +t.test('no workspaces configured', async t => { const unconfiguredWorkspaces = t.testdir({ 'package.json': JSON.stringify({ name: 'no-configured-workspaces', version: '1.0.0', }), }) - try { - await getWorkspaces([], { path: unconfiguredWorkspaces }) - throw new Error('missed throw') - } catch (err) { - t.match( - err, - /No workspaces found/, - 'should throw no workspaces found error' - ) - } + await t.rejects( + getWorkspaces([], { path: unconfiguredWorkspaces, relativeFrom: path }), + /No workspaces found/, + 'should throw no workspaces found error' + ) }) diff --git a/workspaces/arborist/.eslintrc.js b/workspaces/arborist/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/arborist/.eslintrc.js +++ b/workspaces/arborist/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/arborist/.eslintrc.local.json b/workspaces/arborist/.eslintrc.local.json index 9542f52..a3fa657 100644 --- a/workspaces/arborist/.eslintrc.local.json +++ b/workspaces/arborist/.eslintrc.local.json @@ -1,5 +1,10 @@ { + "ignorePatterns": [ + "test/fixtures/", + "!test/fixtures/*.js" + ], "rules": { - "max-len": 0 + "max-len": "off", + "no-shadow": "off" } } diff --git a/workspaces/arborist/.gitignore b/workspaces/arborist/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/arborist/.gitignore +++ b/workspaces/arborist/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/arborist/.npmrc b/workspaces/arborist/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/arborist/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/arborist/CHANGELOG.md b/workspaces/arborist/CHANGELOG.md index 3cd36d0..8fcc8a3 100644 --- a/workspaces/arborist/CHANGELOG.md +++ b/workspaces/arborist/CHANGELOG.md @@ -1,6 +1,369 @@ -# CHANGELOG +# Changelog -## 2.0 +## [6.1.5](https://github.com/npm/cli/compare/arborist-v6.1.4...arborist-v6.1.5) (2022-12-07) + +### Bug Fixes + +* [`83fb125`](https://github.com/npm/cli/commit/83fb125446a9fb217eedf53ca98c203d7d48527b) [#5923](https://github.com/npm/cli/pull/5923) audit package mismatch in special case (@fritzy) + +### Dependencies + +* [`372d158`](https://github.com/npm/cli/commit/372d158d2637120600a95abee64355ed1cb6f990) [#5935](https://github.com/npm/cli/pull/5935) `minimatch@5.1.1` (#5935) +* [`0a3fe00`](https://github.com/npm/cli/commit/0a3fe000e2723ae6fdb8b1d3154fd3835057c992) [#5933](https://github.com/npm/cli/pull/5933) `minipass@4.0.0` +* [`cf0a174`](https://github.com/npm/cli/commit/cf0a17407abc577c27420a1c8a4a0c08c7cefce9) `ssri@10.0.1` +* [`3da9a1a`](https://github.com/npm/cli/commit/3da9a1a4ebcf1779035b5f9ae985c087f617efe3) `pacote@15.0.7` +* [`fee9b66`](https://github.com/npm/cli/commit/fee9b6686892a1c7f976c36ddd5d89b70c416817) `npm-registry-fetch@14.0.3` +* [`e940917`](https://github.com/npm/cli/commit/e940917befcdaf44ee7e24d31b540f4de8507734) `cacache@17.0.3` +* [`875bd56`](https://github.com/npm/cli/commit/875bd56c33ca5eef80c2a50a11808445f2a39a2a) `npm-package-arg@10.1.0` + +## [6.1.4](https://github.com/npm/cli/compare/arborist-v6.1.3...arborist-v6.1.4) (2022-11-30) + +### Bug Fixes + +* [`80c6c4a`](https://github.com/npm/cli/commit/80c6c4a5111ab1779256a779a2cba41eb2c8675f) [#5907](https://github.com/npm/cli/pull/5907) do not reset hidden lockfile data before saving (#5907) (@nlf) + +## [6.1.3](https://github.com/npm/cli/compare/arborist-v6.1.2...arborist-v6.1.3) (2022-11-16) + +### Bug Fixes + +* [`3f13818`](https://github.com/npm/cli/commit/3f1381898ad6c8a477d32765d7304dd55a2c8c9d) [#5859](https://github.com/npm/cli/pull/5859) refactor / inline single use code (#5859) (@wraithgar) + +## [6.1.2](https://github.com/npm/cli/compare/arborist-v6.1.1...arborist-v6.1.2) (2022-11-09) + +### Dependencies + +* [`335c7e4`](https://github.com/npm/cli/commit/335c7e4348f5505fad33b8a78348a02a82b91426) [#5813](https://github.com/npm/cli/pull/5813) `cacache@17.0.2` +* [`878ddfb`](https://github.com/npm/cli/commit/878ddfb5b68c03bdcd7d7da8dae92c4947942801) `@npmcli/fs@3.1.0` + +## [6.1.1](https://github.com/npm/cli/compare/arborist-v6.1.0...arborist-v6.1.1) (2022-11-02) + +### Bug Fixes + +* [`1f5382d`](https://github.com/npm/cli/commit/1f5382dada181cda41f1504974de1e69a6c1ad7f) [#5789](https://github.com/npm/cli/pull/5789) don't set `stdioString` for any spawn/run-script calls (@lukekarrys) +* [`0c5834e`](https://github.com/npm/cli/commit/0c5834ed635833ef49fe10cc888025a5debebe21) [#5758](https://github.com/npm/cli/pull/5758) use hosted-git-info to parse registry urls (#5758) (@lukekarrys) + +### Dependencies + +* [`b89c19e`](https://github.com/npm/cli/commit/b89c19e9a7674b0bd9d336c14dee1bf381843648) [#5795](https://github.com/npm/cli/pull/5795) `cli-table3@0.6.3` +* [`66f9bcd`](https://github.com/npm/cli/commit/66f9bcd10b8d8cb635593c526727056581c7955d) `nopt@7.0.0` +* [`abfb28b`](https://github.com/npm/cli/commit/abfb28b249183b8c033f8e7acc1546150cdac137) `@npmcli/run-script@6.0.0` + +## [6.1.0](https://github.com/npm/cli/compare/arborist-v6.0.0...arborist-v6.1.0) (2022-10-26) + +### Features + +* [`3dd8d68`](https://github.com/npm/cli/commit/3dd8d68577817f65ea148629905acdee3a9b1902) [#5751](https://github.com/npm/cli/pull/5751) sort and quote yarn lock keys according to yarn rules (#5751) (@wraithgar, @shalvah) + +### Dependencies + +* [`de6618e`](https://github.com/npm/cli/commit/de6618e93182ba00b4be516db1efb3c51efa17ba) [#5757](https://github.com/npm/cli/pull/5757) `@npmcli/promise-spawn@5.0.0` (#5757) + +## [6.0.0](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.5...arborist-v6.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +## [6.0.0-pre.5](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.4...arborist-v6.0.0-pre.5) (2022-10-19) + +### ⚠️ BREAKING CHANGES + +* deprecate boolean install flags in favor of `--install-strategy` + * deprecate --global-style, --global now sets --install-strategy=shallow + * deprecate --legacy-bundling, now sets --install-strategy=nested +* this package no longer attempts to change file ownership automatically + +### Features + +* [`de2d33f`](https://github.com/npm/cli/commit/de2d33f3ed42e187803bdd31db4f7a12f08f353c) add --install-strategy=hoisted|nested|shallow, deprecate --global-style, --legacy-bundling (#5709) (@fritzy) +* [`475e9b6`](https://github.com/npm/cli/commit/475e9b6c0c978a104dd2ee47bde22b0a031a95f9) [#5703](https://github.com/npm/cli/pull/5703) do not alter file ownership (@nlf) + +### Bug Fixes + +* [`1afe5ba`](https://github.com/npm/cli/commit/1afe5ba9647d1f0f55bf0a4bace543965d05daed) account for new npm-package-arg behavior (@wraithgar) + +### Dependencies + +* [`88137a3`](https://github.com/npm/cli/commit/88137a329c8ad418db265dd465768a7cf5ebccb1) `npmlog@7.0.1` +* [`2008ea6`](https://github.com/npm/cli/commit/2008ea6a807acbd97912799adfe97f276202cea6) `npm-package-arg@10.0.0`, `pacote@15.0.2` +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies + +## [6.0.0-pre.4](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.3...arborist-v6.0.0-pre.4) (2022-10-05) + +### Features + +* [`9609e9e`](https://github.com/npm/cli/commit/9609e9eed87c735f0319ac0af265f4d406cbf800) [#5605](https://github.com/npm/cli/pull/5605) use v3 lockfiles by default (#5605) (@fritzy) + +### Dependencies + +* [`5344d2c`](https://github.com/npm/cli/commit/5344d2ca9ffd1f6db473fd58b46b50179f899ff5) [#5644](https://github.com/npm/cli/pull/5644) `pacote@14.0.0` +* [`6a43b31`](https://github.com/npm/cli/commit/6a43b31eab8bd392ed684d2f906259ddfe0f26b5) `@npmcli/metavuln-calculator@4.0.0` + +## [6.0.0-pre.3](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.2...arborist-v6.0.0-pre.3) (2022-09-30) + +### ⚠️ BREAKING CHANGES + +* `npm pack` now follows a strict order of operations when applying ignore rules. If a files array is present in the package.json, then rules in .gitignore and .npmignore files from the root will be ignored. + +### Features + +* [`3ae796d`](https://github.com/npm/cli/commit/3ae796d937bd36a5b1b9fd6e9e8473b4f2ddc32d) implement new `npm-packlist` behavior (@lukekarrys) + +## [6.0.0-pre.2](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.1...arborist-v6.0.0-pre.2) (2022-09-23) + +### Features + +* [`ebf167b`](https://github.com/npm/cli/commit/ebf167b621ed14933826f617077ab5890e72bf83) add `:outdated` pseudo selector (@nlf) + +### Documentation + +* [`8402fd8`](https://github.com/npm/cli/commit/8402fd8780c5e0461850da882dca024f7df1a681) [#5547](https://github.com/npm/cli/pull/5547) add `:outdated` pseudo selector to docs (@nlf) + +### Dependencies + +* [`d030f10`](https://github.com/npm/cli/commit/d030f10fd535433e5a824df1b099f500a71075dd) `@npmcli/query@2.0.0` + +## [6.0.0-pre.1](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.0...arborist-v6.0.0-pre.1) (2022-09-14) + +### Bug Fixes + +* [`f3b0c43`](https://github.com/npm/cli/commit/f3b0c438d5b62b267f36c21d7b9fa57ae9507ef5) keep saveTypes separate for each `add` (@wraithgar) + +## [6.0.0-pre.0](https://github.com/npm/cli/compare/arborist-v5.6.1...arborist-v6.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + * [`09c46e8`](https://github.com/npm/cli/commit/09c46e815fe1b44658d32dd760a689e8b2c8d92f) [#5324](https://github.com/npm/cli/pull/5324) feat(arborist): allow for selectors and function names with :semver pseudo selector (@nlf) + +### Bug Fixes + + * [`fe926ed`](https://github.com/npm/cli/commit/fe926eddf98459e1fcb0ffd011ce7703da14928c) [#5484](https://github.com/npm/cli/pull/5484) fix: don't mark workspaces as invalid if installing links (@wraithgar) + * [`548e70e`](https://github.com/npm/cli/commit/548e70e0f87167fb96929b29787620391a77b826) [#5376](https://github.com/npm/cli/pull/5376) fix: link.target setter (@wraithgar) + * [`2db6c08`](https://github.com/npm/cli/commit/2db6c085ea08ee639767d37e6fd83a1ca0fbd9ce) [#5376](https://github.com/npm/cli/pull/5376) fix: loadActual cleanup (@wraithgar) + +### Documentation + + * [`285b39f`](https://github.com/npm/cli/commit/285b39f8d6915823fb424cca7161a0b445b86bd3) [#5324](https://github.com/npm/cli/pull/5324) docs: add documentation for expanded :semver selector (@nlf) + +## [5.6.1](https://github.com/npm/cli/compare/arborist-v5.6.0...arborist-v5.6.1) (2022-08-31) + +### Bug Fixes + + * [`1e84102`](https://github.com/npm/cli/commit/1e841029917817556207c39d25be1ea91e2959e7) [#5350](https://github.com/npm/cli/pull/5350) fix: create links relative to the target (@wraithgar) + * [`ea5e3a3`](https://github.com/npm/cli/commit/ea5e3a319a7c1b5f7f2a66284227a34b79b2c831) [#5350](https://github.com/npm/cli/pull/5350) fix: inline single-use functions (@wraithgar) + * [`645c680`](https://github.com/npm/cli/commit/645c6804c09014b96c2d1eff191b174d12a2b7c0) [#5329](https://github.com/npm/cli/pull/5329) fix: update `index.js` spelling error in comment (@KevinBrother) + * [`bd2ae5d`](https://github.com/npm/cli/commit/bd2ae5d79eb8807bfca6075e98432c545a9ededa) [#5323](https://github.com/npm/cli/pull/5323) fix: linting (@wraithgar) + +### Dependencies + + * [`1286f03`](https://github.com/npm/cli/commit/1286f03fe73dee9a447b13b662f0c5622ab6ec9e) [#5381](https://github.com/npm/cli/pull/5381) deps: `unique-filename@2.0.1` + * [`2c4e387`](https://github.com/npm/cli/commit/2c4e38728f25fd32624df2eb5bbf61c2c40c8ad5) [#5381](https://github.com/npm/cli/pull/5381) deps: `hosted-git-info@5.1.0` + * [`b12ac01`](https://github.com/npm/cli/commit/b12ac013226b7d86b5b1847d58eabbac2846b153) [#5381](https://github.com/npm/cli/pull/5381) deps: `npm-pick-manifest@7.0.2` + * [`7fbf6f7`](https://github.com/npm/cli/commit/7fbf6f7825f76906ecdec79ab15595f9e2f7b784) [#5381](https://github.com/npm/cli/pull/5381) deps: `bin-links@3.0.3` + * [`26d2e55`](https://github.com/npm/cli/commit/26d2e551b250972caa550d56127810648a1663a1) [#5381](https://github.com/npm/cli/pull/5381) deps: `@npmcli/query@1.2.0` + * [`a79ee00`](https://github.com/npm/cli/commit/a79ee00b530b765ed219e81de77c37057c373adf) [#5381](https://github.com/npm/cli/pull/5381) deps: `cacache@16.1.3` + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` + +## [5.6.0](https://github.com/npm/cli/compare/arborist-v5.5.0...arborist-v5.6.0) (2022-08-17) + + +### Features + +* **arborist:** add :overridden pseudo selector ([d221f72](https://github.com/npm/cli/commit/d221f72c00e13258469a748227a1d6f9953a5948)) +* **arborist:** add overridden getter to Node class ([e6d4304](https://github.com/npm/cli/commit/e6d4304bbd03e38dcf2c7467bb1e61b5740a4c73)) +* **query:** support :overridden pseudo selector ([0d4ed0f](https://github.com/npm/cli/commit/0d4ed0fb1cd86edd827cac0b5367b73bb864a9bf)) + +## [5.5.0](https://github.com/npm/cli/compare/arborist-v5.4.0...arborist-v5.5.0) (2022-08-10) + + +### Features + +* **arborist:** add option to forcibly skip loading a virtual tree ([96b6781](https://github.com/npm/cli/commit/96b6781086143d7285c2c5bf7808c24b2c87e4dd)) + + +### Bug Fixes + +* **query:** tell arborist to load an actual tree, not a virtual one ([9078e27](https://github.com/npm/cli/commit/9078e27cef0233d6fc81e0ca824a34fd7685d93c)) + + +### Dependencies + +* nopt@6.0.0 ([7f31b85](https://github.com/npm/cli/commit/7f31b85db650c7a2b3b0577840251f5e25e63a01)) + +## [5.4.0](https://github.com/npm/cli/compare/arborist-v5.3.1...arborist-v5.4.0) (2022-08-03) + + +### Features + +* add --replace-registry-host=<npmjs|always|never> ([#4860](https://github.com/npm/cli/issues/4860)) ([703dbbf](https://github.com/npm/cli/commit/703dbbf2a8149dff72c848d60600889a76779828)) +* add --replace-registry-host=<npmjs|always|never>|<hostname> ([703dbbf](https://github.com/npm/cli/commit/703dbbf2a8149dff72c848d60600889a76779828)) +* add npm query cmd ([#5000](https://github.com/npm/cli/issues/5000)) ([3c024ac](https://github.com/npm/cli/commit/3c024ace60904c69e61da00e1fb56c0c1735804a)) + + +### Bug Fixes + +* **arborist:** fix bare attribute queries ([#5248](https://github.com/npm/cli/issues/5248)) ([8233fca](https://github.com/npm/cli/commit/8233fca44321186c485964d26aa3c7c43eafff3d)) +* **arborist:** pass the edge to fromPath in order to determine correct path ([#5233](https://github.com/npm/cli/issues/5233)) ([050284d](https://github.com/npm/cli/commit/050284d2abb6aa91a0f9ffad5b0c4f074e5dbf6d)) +* **arborist:** use the sourceReference root rather than the node root for overrides ([#5227](https://github.com/npm/cli/issues/5227)) ([47cc95d](https://github.com/npm/cli/commit/47cc95d9ffb37fc8ff62a1d5554eab16d303aa43)), closes [#4395](https://github.com/npm/cli/issues/4395) + + +### Dependencies + +* @npmcli/query@1.1.1 ([#5247](https://github.com/npm/cli/issues/5247)) ([d55007d](https://github.com/npm/cli/commit/d55007d9c535b17612a07a7a58cb6be94eedf77a)) + +## [5.3.1](https://github.com/npm/cli/compare/arborist-v5.3.0...arborist-v5.3.1) (2022-07-27) + + +### Bug Fixes + +* allow hash character in paths ([#5122](https://github.com/npm/cli/issues/5122)) ([62b95a0](https://github.com/npm/cli/commit/62b95a04337661e3fa17093708b57000054442d9)) + +## [5.3.0](https://github.com/npm/cli/compare/arborist-v5.2.3...arborist-v5.3.0) (2022-07-11) + + +### Features + +* **arborist:** add support for dependencies script ([#5094](https://github.com/npm/cli/issues/5094)) ([e9b4214](https://github.com/npm/cli/commit/e9b4214e1ddb1ad79fe6826cf2ce7ba385f0c274)) + +## [5.2.3](https://github.com/npm/cli/compare/arborist-v5.2.2...arborist-v5.2.3) (2022-06-23) + + +### Dependencies + +* @npmcli/run-script@4.1.3 ([#5064](https://github.com/npm/cli/issues/5064)) ([f59a114](https://github.com/npm/cli/commit/f59a114ffe3d1f86ccb2e52a4432292ab76852cc)) + +## [5.2.2](https://github.com/npm/cli/compare/arborist-v5.2.1...arborist-v5.2.2) (2022-06-22) + + +### Bug Fixes + +* Add space to SemVer log message ([#5042](https://github.com/npm/cli/issues/5042)) ([e03009f](https://github.com/npm/cli/commit/e03009f4b423e85e498f1b1851fae785de91a73d)) + + +### Dependencies + +* @npmcli/run-script@4.1.0 ([2c06cee](https://github.com/npm/cli/commit/2c06ceee82dd813c0ae84cc0b09e6941cfc5533e)) +* pacote@13.6.1 ([2e50cb8](https://github.com/npm/cli/commit/2e50cb83e84cf25fee93ba0ca5a0343fbdb33c41)) + +### [5.2.1](https://github.com/npm/cli/compare/arborist-v5.2.0...arborist-v5.2.1) (2022-06-01) + + +### Bug Fixes + +* **arborist:** use rawSpec for bundled and shrinkwrapped deps ([#4963](https://github.com/npm/cli/issues/4963)) ([646b6b5](https://github.com/npm/cli/commit/646b6b5d05de937beb8202e5fd8b8daf3e58e902)) + +## [5.2.0](https://github.com/npm/cli/compare/arborist-v5.1.1...arborist-v5.2.0) (2022-05-10) + + +### Features + +* add flag --omit-lockfile-registry-resolved ([#4874](https://github.com/npm/cli/issues/4874)) ([bfb8bcc](https://github.com/npm/cli/commit/bfb8bccbe83753e527b43c8a3889696087dbe8f1)) + + +### Bug Fixes + +* **arborist:** link deps lifecycle scripts ([#4875](https://github.com/npm/cli/issues/4875)) ([5a50762](https://github.com/npm/cli/commit/5a50762faa37ae5964ae6f12595b20b367056c0a)) + +### [5.1.1](https://github.com/npm/cli/compare/arborist-v5.1.0...arborist-v5.1.1) (2022-04-26) + + +### Dependencies + +* @npmcli/map-workspaces@2.0.3 ([3f2b24a](https://github.com/npm/cli/commit/3f2b24afe205547dbbadf5a6313e95f6b565fb49)) +* cacache@16.0.6 ([532883f](https://github.com/npm/cli/commit/532883ffc35fc1cc9aec09f03bf5ee0f256b94a4)) +* npmlog@6.0.2 ([5e31322](https://github.com/npm/cli/commit/5e313223100db1207818d756b081eaba3468b273)) +* semver@7.3.7 ([c51e553](https://github.com/npm/cli/commit/c51e553a32315e4f1b703ca9030eb7ade91d1a85)) + +## [5.1.0](https://github.com/npm/cli/compare/arborist-v5.0.6...arborist-v5.1.0) (2022-04-19) + + +### Features + +* **arborist:** add support for installLinks ([0ebadf5](https://github.com/npm/cli/commit/0ebadf5b603368557e9e837a46ea5c59c2677a81)) + + +### Bug Fixes + +* **arborist:** when replacing a Link with a Node, make sure to remove the Link target from the root ([3d96494](https://github.com/npm/cli/commit/3d964940f410052918e37a9b05818fe9dc4cd86a)) + +### [5.0.6](https://github.com/npm/cli/compare/arborist-v5.0.5...arborist-v5.0.6) (2022-04-13) + + +### Bug Fixes + +* **arborist:** dont skip adding advisories to audit based on name/range ([aa4a4da](https://github.com/npm/cli/commit/aa4a4da336a6ec1963394fdbd06acb173c842d26)), closes [#4681](https://github.com/npm/cli/issues/4681) +* **arborist:** when reloading an edge, also refresh overrides ([4d676e3](https://github.com/npm/cli/commit/4d676e31a68f081b8553eff4e79db1f29acf47e1)) + +### [5.0.5](https://github.com/npm/cli/compare/arborist-v5.0.4...arborist-v5.0.5) (2022-04-06) + + +### Bug Fixes + +* replace deprecated String.prototype.substr() ([#4667](https://github.com/npm/cli/issues/4667)) ([e3da5df](https://github.com/npm/cli/commit/e3da5df4152fbe547f7871547165328e1bf06262)) +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/arborist@5.0.4 ([679e569](https://github.com/npm/cli/commit/679e569d5778aef312b37c1ba3bda0171366c9fb)) +* @npmcli/move-file@2.0.0 ([e9b25cd](https://github.com/npm/cli/commit/e9b25cd66bef17e807a84e7b10384f5f4d0064b7)) +* @npmcli/node-gyp@2.0.0 ([0e87cac](https://github.com/npm/cli/commit/0e87cac8b6f09692f6bd1bf086aadbe323d127b5)) +* @npmcli/package-json@2.0.0 ([4a9a705](https://github.com/npm/cli/commit/4a9a705de6992a3e9eefecc6c0cf8da45a527c7a)) +* npm-install-checks@5.0.0 ([ad99360](https://github.com/npm/cli/commit/ad9936063f20829eb9d5358d056593883f17a57b)) +* ssri@9.0.0 ([a2781a3](https://github.com/npm/cli/commit/a2781a367d62328d7f870de878f1b63d66593f4f)) +* treeverse@2.0.0 ([1a90b9e](https://github.com/npm/cli/commit/1a90b9e9ebe98cce83591e11312aaf41c830f835)) + +### [5.0.4](https://github.com/npm/cli/compare/arborist-v5.0.3...arborist-v5.0.4) (2022-03-31) + + +### Bug Fixes + +* **arborist:** handle link nodes in old lockfiles correctly ([6f9cb49](https://github.com/npm/cli/commit/6f9cb490e7299976c43c6a118036c130671fe188)) +* **arborist:** identify and repair invalid nodes in the virtual tree ([bd96ae4](https://github.com/npm/cli/commit/bd96ae4071f9cc8a65e741f414db12e98537971d)) +* **arborist:** make sure resolveParent exists before checking props ([18b8b94](https://github.com/npm/cli/commit/18b8b94357d8f57301fbaa0f1e5dc2cf1128bf3e)) +* make sure we loadOverrides on the root node in loadVirtual() ([99d8845](https://github.com/npm/cli/commit/99d88454248f950b82652b592fe2b4d019c1060b)) +* only call npmlog progress methods if explicitly requested ([#4644](https://github.com/npm/cli/issues/4644)) ([668ec7f](https://github.com/npm/cli/commit/668ec7f33b7a76f5e86a59f7e5a6c0e068a242b1)), closes [#3314](https://github.com/npm/cli/issues/3314) + +### [5.0.3](https://www.github.com/npm/cli/compare/arborist-v5.0.2...arborist-v5.0.3) (2022-03-17) + + +### Bug Fixes + +* **arborist:** _findMissingEdges missing dependency due to inconsistent path separators ([#4261](https://www.github.com/npm/cli/issues/4261)) ([0e7511d](https://www.github.com/npm/cli/commit/0e7511d144bdb6624e4c0fdfb31b4b42ed2954c9)) +* **arborist:** save workspace version ([#4578](https://www.github.com/npm/cli/issues/4578)) ([e9a2981](https://www.github.com/npm/cli/commit/e9a2981f55f84ff521ef597883a4e732d08ce1c1)) + + +### Dependencies + +* @npmcli/metavuln-calculator@3.0.1 ([fcc6acf](https://www.github.com/npm/cli/commit/fcc6acfa808aa556748544edf4e9b73262f77608)) +* cacache@16.0.0 ([e26548f](https://www.github.com/npm/cli/commit/e26548fb12a3bb23fbe32a336f1305e083aa51c0)) +* pacote@13.0.5 ([340fa51](https://www.github.com/npm/cli/commit/340fa51f423a518a96c8015a67d8f6144a2e8051)) + +### [5.0.2](https://www.github.com/npm/cli/compare/arborist-v5.0.1...arborist-v5.0.2) (2022-03-10) + + +### Bug Fixes + +* **rebuild:** don't run lifecycle scripts twice on linked deps ([#4529](https://www.github.com/npm/cli/issues/4529)) ([fbdb431](https://www.github.com/npm/cli/commit/fbdb43138ab8e682efb7668767465e7066d43b9f)) + + +### Documentation + +* standardize changelog heading ([#4510](https://www.github.com/npm/cli/issues/4510)) ([91f03ee](https://www.github.com/npm/cli/commit/91f03ee618bc635f9cfbded735fe98bbfa9d643f)) + +### [5.0.1](https://www.github.com/npm/cli/compare/arborist-v5.0.0...arborist-v5.0.1) (2022-03-08) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) + +## 2.0.0 * BREAKING CHANGE: root node is now included in inventory * All parent/target/fsParent/etc. references set in `root` setter, rather @@ -8,12 +371,12 @@ * `treeCheck` function added, to enforce strict correctness guarantees when `ARBORIST_DEBUG=1` in the environment (on by default in Arborist tests). -## 1.0 +## 1.0.0 * Release for npm v7 beta * Fully functional -## 0.0 +## 0.0.0 * Proof of concept * Before this, it was [`read-package-tree`](http://npm.im/read-package-tree) diff --git a/workspaces/arborist/README.md b/workspaces/arborist/README.md index 8722b7a..81d79cb 100644 --- a/workspaces/arborist/README.md +++ b/workspaces/arborist/README.md @@ -1,11 +1,15 @@ # @npmcli/arborist +[![npm version](https://img.shields.io/npm/v/@npmcli/arborist.svg)](https://npm.im/@npmcli/arborist) +[![license](https://img.shields.io/npm/l/@npmcli/arborist.svg)](https://npm.im/@npmcli/arborist) +[![CI - @npmcli/arborist](https://github.com/npm/cli/actions/workflows/ci-npmcli-arborist.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-npmcli-arborist.yml) + Inspect and manage `node_modules` trees. ![a tree with the word ARBORIST superimposed on it](https://raw.githubusercontent.com/npm/arborist/main/docs/logo.svg?sanitize=true) There's more documentation [in the docs -folder](https://github.com/npm/arborist/tree/main/docs). +folder](https://github.com/npm/cli/tree/latest/workspaces/arborist/docs). ## USAGE @@ -333,3 +337,13 @@ pruning nodes from the tree. Note: `devOptional` is only set in the shrinkwrap/package-lock file if _neither_ `dev` nor `optional` are set, as it would be redundant. + +## BIN + +Arborist ships with a cli that can be used to run arborist specific commands outside of the context of the npm CLI. This script is currently not part of the public API and is subject to breaking changes outside of major version bumps. + +To see the usage run: + +``` +npx @npmcli/arborist --help +``` diff --git a/workspaces/arborist/SECURITY.md b/workspaces/arborist/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/arborist/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/arborist/bin/actual.js b/workspaces/arborist/bin/actual.js index eb04959..866b2cd 100644 --- a/workspaces/arborist/bin/actual.js +++ b/workspaces/arborist/bin/actual.js @@ -1,23 +1,19 @@ const Arborist = require('../') -const print = require('./lib/print-tree.js') -const options = require('./lib/options.js') -require('./lib/logging.js') -require('./lib/timers.js') -const start = process.hrtime() -new Arborist(options).loadActual(options).then(tree => { - const end = process.hrtime(start) - if (!process.argv.includes('--quiet')) { - print(tree) - } +const printTree = require('./lib/print-tree.js') - console.error(`read ${tree.inventory.size} deps in ${end[0] * 1000 + end[1] / 1e6}ms`) - if (options.save) { - tree.meta.save() - } - if (options.saveHidden) { - tree.meta.hiddenLockfile = true - tree.meta.filename = options.path + '/node_modules/.package-lock.json' - tree.meta.save() - } -}).catch(er => console.error(er)) +module.exports = (options, time) => new Arborist(options) + .loadActual(options) + .then(time) + .then(async ({ timing, result: tree }) => { + printTree(tree) + if (options.save) { + await tree.meta.save() + } + if (options.saveHidden) { + tree.meta.hiddenLockfile = true + tree.meta.filename = options.path + '/node_modules/.package-lock.json' + await tree.meta.save() + } + return `read ${tree.inventory.size} deps in ${timing.ms}` + }) diff --git a/workspaces/arborist/bin/audit.js b/workspaces/arborist/bin/audit.js index d9ac532..0e32833 100644 --- a/workspaces/arborist/bin/audit.js +++ b/workspaces/arborist/bin/audit.js @@ -1,19 +1,17 @@ const Arborist = require('../') -const print = require('./lib/print-tree.js') -const options = require('./lib/options.js') -require('./lib/timers.js') -require('./lib/logging.js') +const printTree = require('./lib/print-tree.js') +const log = require('./lib/logging.js') const Vuln = require('../lib/vuln.js') const printReport = report => { for (const vuln of report.values()) { - console.log(printVuln(vuln)) + log.info(printVuln(vuln)) } if (report.topVulns.size) { - console.log('\n# top-level vulnerabilities') + log.info('\n# top-level vulnerabilities') for (const vuln of report.topVulns.values()) { - console.log(printVuln(vuln)) + log.info(printVuln(vuln)) } } } @@ -33,22 +31,21 @@ const printVuln = vuln => { const printAdvisory = a => `${a.title}${a.url ? ' ' + a.url : ''}` -const start = process.hrtime() -process.emit('time', 'audit script') -const arb = new Arborist(options) -arb.audit(options).then(tree => { - process.emit('timeEnd', 'audit script') - const end = process.hrtime(start) - if (options.fix) { - print(tree) - } - if (!options.quiet) { - printReport(arb.auditReport) - } - if (options.fix) { - console.error(`resolved ${tree.inventory.size} deps in ${end[0] + end[1] / 1e9}s`) - } - if (tree.meta && options.save) { - tree.meta.save() - } -}).catch(er => console.error(er)) +module.exports = (options, time) => { + const arb = new Arborist(options) + return arb + .audit(options) + .then(time) + .then(async ({ timing, result: tree }) => { + if (options.fix) { + printTree(tree) + } + printReport(arb.auditReport) + if (tree.meta && options.save) { + await tree.meta.save() + } + return options.fix + ? `resolved ${tree.inventory.size} deps in ${timing.seconds}` + : `done in ${timing.seconds}` + }) +} diff --git a/workspaces/arborist/bin/funding.js b/workspaces/arborist/bin/funding.js index d0f4f31..cf25976 100644 --- a/workspaces/arborist/bin/funding.js +++ b/workspaces/arborist/bin/funding.js @@ -1,34 +1,38 @@ -const options = require('./lib/options.js') -require('./lib/logging.js') -require('./lib/timers.js') - const Arborist = require('../') -const a = new Arborist(options) -const query = options._.shift() -const start = process.hrtime() -a.loadVirtual().then(tree => { - // only load the actual tree if the virtual one doesn't have modern metadata - if (!tree.meta || !(tree.meta.originalLockfileVersion >= 2)) { - console.error('old metadata, load actual') - throw 'load actual' - } else { - console.error('meta ok, return virtual tree') - return tree - } -}).catch(() => a.loadActual()).then(tree => { - const end = process.hrtime(start) - if (!query) { - for (const node of tree.inventory.values()) { - if (node.package.funding) { - console.log(node.name, node.location, node.package.funding) + +const log = require('./lib/logging.js') + +module.exports = (options, time) => { + const query = options._.shift() + const a = new Arborist(options) + return a + .loadVirtual() + .then(tree => { + // only load the actual tree if the virtual one doesn't have modern metadata + if (!tree.meta || !(tree.meta.originalLockfileVersion >= 2)) { + log.error('old metadata, load actual') + throw 'load actual' + } else { + log.error('meta ok, return virtual tree') + return tree } - } - } else { - for (const node of tree.inventory.query('name', query)) { - if (node.package.funding) { - console.log(node.name, node.location, node.package.funding) + }) + .catch(() => a.loadActual()) + .then(time) + .then(({ timing, result: tree }) => { + if (!query) { + for (const node of tree.inventory.values()) { + if (node.package.funding) { + log.info(node.name, node.location, node.package.funding) + } + } + } else { + for (const node of tree.inventory.query('name', query)) { + if (node.package.funding) { + log.info(node.name, node.location, node.package.funding) + } + } } - } - } - console.error(`read ${tree.inventory.size} deps in ${end[0] * 1000 + end[1] / 1e6}ms`) -}) + return `read ${tree.inventory.size} deps in ${timing.ms}` + }) +} diff --git a/workspaces/arborist/bin/ideal.js b/workspaces/arborist/bin/ideal.js index 5d1ed0d..1dd206e 100644 --- a/workspaces/arborist/bin/ideal.js +++ b/workspaces/arborist/bin/ideal.js @@ -1,21 +1,14 @@ const Arborist = require('../') -const { inspect } = require('util') -const options = require('./lib/options.js') -const print = require('./lib/print-tree.js') -require('./lib/logging.js') -require('./lib/timers.js') +const printTree = require('./lib/print-tree.js') -const start = process.hrtime() -new Arborist(options).buildIdealTree(options).then(tree => { - const end = process.hrtime(start) - print(tree) - console.error(`resolved ${tree.inventory.size} deps in ${end[0] + end[1] / 10e9}s`) - if (tree.meta && options.save) { - tree.meta.save() - } -}).catch(er => { - const opt = { depth: Infinity, color: true } - console.error(er.code === 'ERESOLVE' ? inspect(er, opt) : er) - process.exitCode = 1 -}) +module.exports = (options, time) => new Arborist(options) + .buildIdealTree(options) + .then(time) + .then(async ({ timing, result: tree }) => { + printTree(tree) + if (tree.meta && options.save) { + await tree.meta.save() + } + return `resolved ${tree.inventory.size} deps in ${timing.seconds}` + }) diff --git a/workspaces/arborist/bin/index.js b/workspaces/arborist/bin/index.js index 5449a50..ff356fa 100755 --- a/workspaces/arborist/bin/index.js +++ b/workspaces/arborist/bin/index.js @@ -1,81 +1,111 @@ #!/usr/bin/env node -const [cmd] = process.argv.splice(2, 1) -const usage = () => `Arborist - the npm tree doctor +const fs = require('fs') +const path = require('path') -Version: ${require('../package.json').version} +const { bin, arb: options } = require('./lib/options') +const version = require('../package.json').version +const usage = (message = '') => `Arborist - the npm tree doctor + +Version: ${version} +${message && '\n' + message + '\n'} # USAGE arborist <cmd> [path] [options...] # COMMANDS -* reify: reify ideal tree to node_modules (install, update, rm, ...) -* prune: prune the ideal tree and reify (like npm prune) -* ideal: generate and print the ideal tree -* actual: read and print the actual tree in node_modules -* virtual: read and print the virtual tree in the local shrinkwrap file -* shrinkwrap: load a local shrinkwrap and print its data -* audit: perform a security audit on project dependencies -* funding: query funding information in the local package tree. A second - positional argument after the path name can limit to a package name. -* license: query license information in the local package tree. A second - positional argument after the path name can limit to a license type. -* help: print this text + * reify: reify ideal tree to node_modules (install, update, rm, ...) + * prune: prune the ideal tree and reify (like npm prune) + * ideal: generate and print the ideal tree + * actual: read and print the actual tree in node_modules + * virtual: read and print the virtual tree in the local shrinkwrap file + * shrinkwrap: load a local shrinkwrap and print its data + * audit: perform a security audit on project dependencies + * funding: query funding information in the local package tree. A second + positional argument after the path name can limit to a package name. + * license: query license information in the local package tree. A second + positional argument after the path name can limit to a license type. + * help: print this text + * version: print the version # OPTIONS -Most npm options are supported, but in camelCase rather than css-case. For -example, instead of '--dry-run', use '--dryRun'. + Most npm options are supported, but in camelCase rather than css-case. For + example, instead of '--dry-run', use '--dryRun'. -Additionally: + Additionally: -* --quiet will supppress the printing of package trees -* Instead of 'npm install <pkg>', use 'arborist reify --add=<pkg>'. - The '--add=<pkg>' option can be specified multiple times. -* Instead of 'npm rm <pkg>', use 'arborist reify --rm=<pkg>'. - The '--rm=<pkg>' option can be specified multiple times. -* Instead of 'npm update', use 'arborist reify --update-all'. -* 'npm audit fix' is 'arborist audit --fix' + * --loglevel=warn|--quiet will supppress the printing of package trees + * --logfile <file|bool> will output logs to a file + * --timing will show timing information + * Instead of 'npm install <pkg>', use 'arborist reify --add=<pkg>'. + The '--add=<pkg>' option can be specified multiple times. + * Instead of 'npm rm <pkg>', use 'arborist reify --rm=<pkg>'. + The '--rm=<pkg>' option can be specified multiple times. + * Instead of 'npm update', use 'arborist reify --update-all'. + * 'npm audit fix' is 'arborist audit --fix' ` -const help = () => console.log(usage()) - -switch (cmd) { - case 'actual': - require('./actual.js') - break - case 'virtual': - require('./virtual.js') - break - case 'ideal': - require('./ideal.js') - break - case 'prune': - require('./prune.js') - break - case 'reify': - require('./reify.js') - break - case 'audit': - require('./audit.js') - break - case 'funding': - require('./funding.js') - break - case 'license': - require('./license.js') - break - case 'shrinkwrap': - require('./shrinkwrap.js') - break - case 'help': - case '-h': - case '--help': - help() - break - default: +const commands = { + version: () => console.log(version), + help: () => console.log(usage()), + exit: () => { process.exitCode = 1 - console.error(usage()) - break + console.error( + usage(`Error: command '${bin.command}' does not exist.`) + ) + }, +} + +const commandFiles = fs.readdirSync(__dirname).filter((f) => path.extname(f) === '.js' && f !== __filename) + +for (const file of commandFiles) { + const command = require(`./${file}`) + const name = path.basename(file, '.js') + const totalTime = `bin:${name}:init` + const scriptTime = `bin:${name}:script` + + commands[name] = () => { + const timers = require('./lib/timers') + const log = require('./lib/logging') + + log.info(name, options) + + process.emit('time', totalTime) + process.emit('time', scriptTime) + + return command(options, (result) => { + process.emit('timeEnd', scriptTime) + return { + result, + timing: { + seconds: `${timers.get(scriptTime) / 1e9}s`, + ms: `${timers.get(scriptTime) / 1e6}ms`, + }, + } + }) + .then((result) => { + log.info(result) + return result + }) + .catch((err) => { + process.exitCode = 1 + log.error(err) + return err + }) + .then((r) => { + process.emit('timeEnd', totalTime) + if (bin.loglevel !== 'silent') { + console[process.exitCode ? 'error' : 'log'](r) + } + return r + }) + } +} + +if (commands[bin.command]) { + commands[bin.command]() +} else { + commands.exit() } diff --git a/workspaces/arborist/bin/lib/logging.js b/workspaces/arborist/bin/lib/logging.js index 8183ece..ffb5544 100644 --- a/workspaces/arborist/bin/lib/logging.js +++ b/workspaces/arborist/bin/lib/logging.js @@ -1,42 +1,77 @@ -const options = require('./options.js') -const { quiet = false } = options -const { loglevel = quiet ? 'warn' : 'silly' } = options +const log = require('proc-log') +const fs = require('fs') +const { dirname } = require('path') +const os = require('os') +const { inspect, format } = require('util') -const levels = [ +const { bin: options } = require('./options.js') + +// add a meta method to proc-log for passing optional +// metadata through to log handlers +const META = Symbol('meta') +const parseArgs = (...args) => { + const { [META]: isMeta } = args[args.length - 1] || {} + return isMeta + ? [args[args.length - 1], ...args.slice(0, args.length - 1)] + : [{}, ...args] +} +log.meta = (meta = {}) => ({ [META]: true, ...meta }) + +const levels = new Map([ 'silly', 'verbose', 'info', - 'timing', 'http', 'notice', 'warn', 'error', 'silent', -] +].map((level, index) => [level, index])) -const levelMap = new Map(levels.reduce((set, level, index) => { - set.push([level, index], [index, level]) - return set -}, [])) +const addLogListener = (write, { eol = os.EOL, loglevel = 'silly', colors = false } = {}) => { + const levelIndex = levels.get(loglevel) -const { inspect, format } = require('util') -const colors = process.stderr.isTTY -const magenta = colors ? msg => `\x1B[35m${msg}\x1B[39m` : m => m -if (loglevel !== 'silent') { - process.on('log', (level, ...args) => { - if (levelMap.get(level) < levelMap.get(loglevel)) { - return + const magenta = m => colors ? `\x1B[35m${m}\x1B[39m` : m + const dim = m => colors ? `\x1B[2m${m}\x1B[22m` : m + const red = m => colors ? `\x1B[31m${m}\x1B[39m` : m + + const formatter = (level, ...args) => { + const depth = level === 'error' && args[0] && args[0].code === 'ERESOLVE' ? Infinity : 10 + + if (level === 'info' && args[0] === 'timeEnd') { + args[1] = dim(args[1]) + } else if (level === 'error' && args[0] === 'timeError') { + args[1] = red(args[1]) } + + const messages = args.map(a => typeof a === 'string' ? a : inspect(a, { depth, colors })) const pref = `${process.pid} ${magenta(level)} ` - if (level === 'warn' && args[0] === 'ERESOLVE') { - args[2] = inspect(args[2], { depth: 10, colors }) - } else { - args = args.map(a => { - return typeof a === 'string' ? a - : inspect(a, { depth: 10, colors }) - }) + + return pref + format(...messages).trim().split('\n').join(`${eol}${pref}`) + eol + } + + process.on('log', (...args) => { + const [meta, level, ...logArgs] = parseArgs(...args) + + if (levelIndex <= levels.get(level) || meta.force) { + write(formatter(level, ...logArgs)) } - const msg = pref + format(...args).trim().split('\n').join(`\n${pref}`) - console.error(msg) }) } + +if (options.loglevel !== 'silent') { + addLogListener((v) => process.stderr.write(v), { + eol: '\n', + colors: options.colors, + loglevel: options.loglevel, + }) +} + +if (options.logfile) { + log.silly('logfile', options.logfile) + fs.mkdirSync(dirname(options.logfile), { recursive: true }) + const fd = fs.openSync(options.logfile, 'a') + addLogListener((str) => fs.writeSync(fd, str)) +} + +module.exports = log diff --git a/workspaces/arborist/bin/lib/options.js b/workspaces/arborist/bin/lib/options.js index 23e89dd..8dbaf13 100644 --- a/workspaces/arborist/bin/lib/options.js +++ b/workspaces/arborist/bin/lib/options.js @@ -1,59 +1,123 @@ -const options = module.exports = { - path: undefined, - cache: `${process.env.HOME}/.npm/_cacache`, - _: [], +const nopt = require('nopt') +const path = require('path') + +const has = (o, k) => Object.prototype.hasOwnProperty.call(o, k) + +const cleanPath = (val) => { + const k = Symbol('key') + const data = {} + nopt.typeDefs.path.validate(data, k, val) + return data[k] } -for (const arg of process.argv.slice(2)) { - if (/^--add=/.test(arg)) { - options.add = options.add || [] - options.add.push(arg.substr('--add='.length)) - } else if (/^--rm=/.test(arg)) { - options.rm = options.rm || [] - options.rm.push(arg.substr('--rm='.length)) - } else if (arg === '--global') { - options.global = true - } else if (arg === '--global-style') { - options.globalStyle = true - } else if (arg === '--prefer-dedupe') { - options.preferDedupe = true - } else if (arg === '--legacy-peer-deps') { - options.legacyPeerDeps = true - } else if (arg === '--force') { - options.force = true - } else if (arg === '--update-all') { - options.update = options.update || {} - options.update.all = true - } else if (/^--update=/.test(arg)) { - options.update = options.update || {} - options.update.names = options.update.names || [] - options.update.names.push(arg.substr('--update='.length)) - } else if (/^--omit=/.test(arg)) { - options.omit = options.omit || [] - options.omit.push(arg.substr('--omit='.length)) - } else if (/^--before=/.test(arg)) { - options.before = new Date(arg.substr('--before='.length)) - } else if (/^-w.+/.test(arg)) { - options.workspaces = options.workspaces || [] - options.workspaces.push(arg.replace(/^-w/, '')) - } else if (/^--workspace=/.test(arg)) { - options.workspaces = options.workspaces || [] - options.workspaces.push(arg.replace(/^--workspace=/, '')) - } else if (/^--[^=]+=/.test(arg)) { - const [key, ...v] = arg.replace(/^--/, '').split('=') - const val = v.join('=') - options[key] = val === 'false' ? false : val === 'true' ? true : val - } else if (/^--.+/.test(arg)) { - options[arg.replace(/^--/, '')] = true - } else if (options.path === undefined) { - options.path = arg - } else { - options._.push(arg) +const parse = (...noptArgs) => { + const binOnlyOpts = { + command: String, + loglevel: String, + colors: Boolean, + timing: ['always', Boolean], + logfile: String, } + + const arbOpts = { + add: Array, + rm: Array, + omit: Array, + update: Array, + workspaces: Array, + global: Boolean, + force: Boolean, + 'global-style': Boolean, + 'prefer-dedupe': Boolean, + 'legacy-peer-deps': Boolean, + 'update-all': Boolean, + before: Date, + path: path, + cache: path, + ...binOnlyOpts, + } + + const short = { + quiet: ['--loglevel', 'warn'], + logs: ['--logfile', 'true'], + w: '--workspaces', + g: '--global', + f: '--force', + } + + const defaults = { + // key order is important for command and path + // since they shift positional args + // command is 1st, path is 2nd + command: (o) => o.argv.remain.shift(), + path: (o) => cleanPath(o.argv.remain.shift() || '.'), + colors: has(process.env, 'NO_COLOR') ? false : !!process.stderr.isTTY, + loglevel: 'silly', + timing: (o) => o.loglevel === 'silly', + cache: `${process.env.HOME}/.npm/_cacache`, + } + + const derived = [ + // making update either `all` or an array of names but not both + ({ updateAll: all, update: names, ...o }) => { + if (all || names) { + o.update = all != null ? { all } : { names } + } + return o + }, + ({ logfile, ...o }) => { + // logfile is parsed as a string so if its true or set but empty + // then set the default logfile + if (logfile === 'true' || logfile === '') { + logfile = `arb-log-${new Date().toISOString().replace(/[.:]/g, '_')}.log` + } + // then parse it the same as nopt parses other paths + if (logfile) { + o.logfile = cleanPath(logfile) + } + return o + }, + ] + + const transforms = [ + // Camelcase all top level keys + (o) => { + const entries = Object.entries(o).map(([k, v]) => [ + k.replace(/-./g, s => s[1].toUpperCase()), + v, + ]) + return Object.fromEntries(entries) + }, + // Set defaults on unset keys + (o) => { + for (const [k, v] of Object.entries(defaults)) { + if (!has(o, k)) { + o[k] = typeof v === 'function' ? v(o) : v + } + } + return o + }, + // Set/unset derived values + ...derived.map((derive) => (o) => derive(o) || o), + // Separate bin and arborist options + ({ argv: { remain: _ }, ...o }) => { + const bin = { _ } + for (const k of Object.keys(binOnlyOpts)) { + if (has(o, k)) { + bin[k] = o[k] + delete o[k] + } + } + return { bin, arb: o } + }, + ] + + let options = nopt(arbOpts, short, ...noptArgs) + for (const t of transforms) { + options = t(options) + } + + return options } -if (options.path === undefined) { - options.path = '.' -} - -console.error(options) +module.exports = parse() diff --git a/workspaces/arborist/bin/lib/print-tree.js b/workspaces/arborist/bin/lib/print-tree.js index 1ea2a72..5539819 100644 --- a/workspaces/arborist/bin/lib/print-tree.js +++ b/workspaces/arborist/bin/lib/print-tree.js @@ -1,5 +1,4 @@ const { inspect } = require('util') -const { quiet } = require('./options.js') +const log = require('./logging.js') -module.exports = quiet ? () => {} - : tree => console.log(inspect(tree.toJSON(), { depth: Infinity })) +module.exports = tree => log.info(inspect(tree.toJSON(), { depth: Infinity })) diff --git a/workspaces/arborist/bin/lib/timers.js b/workspaces/arborist/bin/lib/timers.js index 2424319..586dee7 100644 --- a/workspaces/arborist/bin/lib/timers.js +++ b/workspaces/arborist/bin/lib/timers.js @@ -1,31 +1,33 @@ -const timers = Object.create(null) -const { format } = require('util') -const options = require('./options.js') +const { bin: options } = require('./options.js') +const log = require('./logging.js') + +const timers = new Map() +const finished = new Map() process.on('time', name => { - if (timers[name]) { + if (timers.has(name)) { throw new Error('conflicting timer! ' + name) } - timers[name] = process.hrtime() + timers.set(name, process.hrtime.bigint()) }) -const dim = process.stderr.isTTY ? msg => `\x1B[2m${msg}\x1B[22m` : m => m -const red = process.stderr.isTTY ? msg => `\x1B[31m${msg}\x1B[39m` : m => m process.on('timeEnd', name => { - if (!timers[name]) { + if (!timers.has(name)) { throw new Error('timer not started! ' + name) } - const res = process.hrtime(timers[name]) - delete timers[name] - const msg = format(`${process.pid} ${name}`, res[0] * 1e3 + res[1] / 1e6) - if (options.timers !== false) { - console.error(dim(msg)) + const elapsed = Number(process.hrtime.bigint() - timers.get(name)) + timers.delete(name) + finished.set(name, elapsed) + if (options.timing) { + log.info('timeEnd', `${name} ${elapsed / 1e9}s`, log.meta({ force: options.timing === 'always' })) } }) process.on('exit', () => { - for (const name of Object.keys(timers)) { - console.error(red('Dangling timer:'), name) + for (const name of timers.keys()) { + log.error('timeError', 'Dangling timer:', name) process.exitCode = 1 } }) + +module.exports = finished diff --git a/workspaces/arborist/bin/license.js b/workspaces/arborist/bin/license.js index 7fc08dd..77d5796 100644 --- a/workspaces/arborist/bin/license.js +++ b/workspaces/arborist/bin/license.js @@ -1,38 +1,48 @@ +const localeCompare = require('@isaacs/string-locale-compare')('en') const Arborist = require('../') -const options = require('./lib/options.js') -require('./lib/logging.js') -require('./lib/timers.js') +const log = require('./lib/logging.js') -const a = new Arborist(options) -const query = options._.shift() +module.exports = (options, time) => { + const query = options._.shift() + const a = new Arborist(options) + return a + .loadVirtual() + .then(tree => { + // only load the actual tree if the virtual one doesn't have modern metadata + if (!tree.meta || !(tree.meta.originalLockfileVersion >= 2)) { + throw 'load actual' + } else { + return tree + } + }).catch((er) => { + log.error('loading actual tree', er) + return a.loadActual() + }) + .then(time) + .then(({ result: tree }) => { + const output = [] + if (!query) { + const set = [] + for (const license of tree.inventory.query('license')) { + set.push([tree.inventory.query('license', license).size, license]) + } -a.loadVirtual().then(tree => { - // only load the actual tree if the virtual one doesn't have modern metadata - if (!tree.meta || !(tree.meta.originalLockfileVersion >= 2)) { - throw 'load actual' - } else { - return tree - } -}).catch((er) => { - console.error('loading actual tree', er) - return a.loadActual() -}).then(tree => { - if (!query) { - const set = [] - for (const license of tree.inventory.query('license')) { - set.push([tree.inventory.query('license', license).size, license]) - } + for (const [count, license] of set.sort((a, b) => + a[1] && b[1] ? b[0] - a[0] || localeCompare(a[1], b[1]) + : a[1] ? -1 + : b[1] ? 1 + : 0)) { + output.push(`${count} ${license}`) + log.info(count, license) + } + } else { + for (const node of tree.inventory.query('license', query === 'undefined' ? undefined : query)) { + const msg = `${node.name} ${node.location} ${node.package.description || ''}` + output.push(msg) + log.info(msg) + } + } - for (const [count, license] of set.sort((a, b) => - a[1] && b[1] ? b[0] - a[0] || a[1].localeCompare(b[1], 'en') - : a[1] ? -1 - : b[1] ? 1 - : 0)) { - console.log(count, license) - } - } else { - for (const node of tree.inventory.query('license', query === 'undefined' ? undefined : query)) { - console.log(`${node.name} ${node.location} ${node.package.description || ''}`) - } - } -}) + return output.join('\n') + }) +} diff --git a/workspaces/arborist/bin/prune.js b/workspaces/arborist/bin/prune.js index e11858c..3c52bc1 100644 --- a/workspaces/arborist/bin/prune.js +++ b/workspaces/arborist/bin/prune.js @@ -1,9 +1,7 @@ const Arborist = require('../') -const options = require('./lib/options.js') -const print = require('./lib/print-tree.js') -require('./lib/logging.js') -require('./lib/timers.js') +const printTree = require('./lib/print-tree.js') +const log = require('./lib/logging.js') const printDiff = diff => { const { depth } = require('treeverse') @@ -15,13 +13,13 @@ const printDiff = diff => { } switch (d.action) { case 'REMOVE': - console.error('REMOVE', d.actual.location) + log.info('REMOVE', d.actual.location) break case 'ADD': - console.error('ADD', d.ideal.location, d.ideal.resolved) + log.info('ADD', d.ideal.location, d.ideal.resolved) break case 'CHANGE': - console.error('CHANGE', d.actual.location, { + log.info('CHANGE', d.actual.location, { from: d.actual.resolved, to: d.ideal.resolved, }) @@ -32,18 +30,19 @@ const printDiff = diff => { }) } -const start = process.hrtime() -process.emit('time', 'install') -const arb = new Arborist(options) -arb.prune(options).then(tree => { - process.emit('timeEnd', 'install') - const end = process.hrtime(start) - print(tree) - if (options.dryRun) { - printDiff(arb.diff) - } - console.error(`resolved ${tree.inventory.size} deps in ${end[0] + end[1] / 1e9}s`) - if (tree.meta && options.save) { - tree.meta.save() - } -}).catch(er => console.error(require('util').inspect(er, { depth: Infinity }))) +module.exports = (options, time) => { + const arb = new Arborist(options) + return arb + .prune(options) + .then(time) + .then(async ({ timing, result: tree }) => { + printTree(tree) + if (options.dryRun) { + printDiff(arb.diff) + } + if (tree.meta && options.save) { + await tree.meta.save() + } + return `resolved ${tree.inventory.size} deps in ${timing.seconds}` + }) +} diff --git a/workspaces/arborist/bin/reify.js b/workspaces/arborist/bin/reify.js index 9dc26d2..3f3aafe 100644 --- a/workspaces/arborist/bin/reify.js +++ b/workspaces/arborist/bin/reify.js @@ -1,9 +1,7 @@ const Arborist = require('../') -const options = require('./lib/options.js') -const print = require('./lib/print-tree.js') -require('./lib/logging.js') -require('./lib/timers.js') +const printTree = require('./lib/print-tree.js') +const log = require('./lib/logging.js') const printDiff = diff => { const { depth } = require('treeverse') @@ -15,13 +13,13 @@ const printDiff = diff => { } switch (d.action) { case 'REMOVE': - console.error('REMOVE', d.actual.location) + log.info('REMOVE', d.actual.location) break case 'ADD': - console.error('ADD', d.ideal.location, d.ideal.resolved) + log.info('ADD', d.ideal.location, d.ideal.resolved) break case 'CHANGE': - console.error('CHANGE', d.actual.location, { + log.info('CHANGE', d.actual.location, { from: d.actual.resolved, to: d.ideal.resolved, }) @@ -32,18 +30,19 @@ const printDiff = diff => { }) } -const start = process.hrtime() -process.emit('time', 'install') -const arb = new Arborist(options) -arb.reify(options).then(tree => { - process.emit('timeEnd', 'install') - const end = process.hrtime(start) - print(tree) - if (options.dryRun) { - printDiff(arb.diff) - } - console.error(`resolved ${tree.inventory.size} deps in ${end[0] + end[1] / 1e9}s`) - if (tree.meta && options.save) { - tree.meta.save() - } -}).catch(er => console.error(require('util').inspect(er, { depth: Infinity }))) +module.exports = (options, time) => { + const arb = new Arborist(options) + return arb + .reify(options) + .then(time) + .then(async ({ timing, result: tree }) => { + printTree(tree) + if (options.dryRun) { + printDiff(arb.diff) + } + if (tree.meta && options.save) { + await tree.meta.save() + } + return `resolved ${tree.inventory.size} deps in ${timing.seconds}` + }) +} diff --git a/workspaces/arborist/bin/shrinkwrap.js b/workspaces/arborist/bin/shrinkwrap.js index b40416b..5660322 100644 --- a/workspaces/arborist/bin/shrinkwrap.js +++ b/workspaces/arborist/bin/shrinkwrap.js @@ -1,12 +1,7 @@ const Shrinkwrap = require('../lib/shrinkwrap.js') -const options = require('./lib/options.js') -require('./lib/logging.js') -require('./lib/timers.js') -const { quiet } = options -Shrinkwrap.load(options) - .then(s => quiet || console.log(JSON.stringify(s.commit(), 0, 2))) - .catch(er => { - console.error('shrinkwrap load failure', er) - process.exit(1) - }) +module.exports = (options, time) => Shrinkwrap + .load(options) + .then((s) => s.commit()) + .then(time) + .then(({ result: s }) => JSON.stringify(s, 0, 2)) diff --git a/workspaces/arborist/bin/virtual.js b/workspaces/arborist/bin/virtual.js index 457c945..95b1de2 100644 --- a/workspaces/arborist/bin/virtual.js +++ b/workspaces/arborist/bin/virtual.js @@ -1,18 +1,14 @@ const Arborist = require('../') -const print = require('./lib/print-tree.js') -const options = require('./lib/options.js') -require('./lib/logging.js') -require('./lib/timers.js') +const printTree = require('./lib/print-tree.js') -const start = process.hrtime() -new Arborist(options).loadVirtual().then(tree => { - const end = process.hrtime(start) - if (!options.quiet) { - print(tree) - } - if (options.save) { - tree.meta.save() - } - console.error(`read ${tree.inventory.size} deps in ${end[0] * 1000 + end[1] / 1e6}ms`) -}).catch(er => console.error(er)) +module.exports = (options, time) => new Arborist(options) + .loadVirtual() + .then(time) + .then(async ({ timing, result: tree }) => { + printTree(tree) + if (options.save) { + await tree.meta.save() + } + return `read ${tree.inventory.size} deps in ${timing.ms}` + }) diff --git a/workspaces/arborist/docs/reify.md b/workspaces/arborist/docs/reify.md index 15b0472..ac607ef 100644 --- a/workspaces/arborist/docs/reify.md +++ b/workspaces/arborist/docs/reify.md @@ -87,7 +87,7 @@ Fail: rename each retired `.${name}-hash` folder back to `${name}` ### step 2: create sparse tree -Now that the shallowest changing nodes are retired, `mkdirp` all leaf +Now that the shallowest changing nodes are retired, `mkdir` all leaf nodes. ``` diff --git a/workspaces/arborist/lib/add-rm-pkg-deps.js b/workspaces/arborist/lib/add-rm-pkg-deps.js index ae81318..c5cdc09 100644 --- a/workspaces/arborist/lib/add-rm-pkg-deps.js +++ b/workspaces/arborist/lib/add-rm-pkg-deps.js @@ -1,10 +1,71 @@ // add and remove dependency specs to/from pkg manifest +const log = require('proc-log') const localeCompare = require('@isaacs/string-locale-compare')('en') -const add = ({ pkg, add, saveBundle, saveType, log }) => { - for (const spec of add) { - addSingle({ pkg, spec, saveBundle, saveType, log }) +const add = ({ pkg, add, saveBundle, saveType }) => { + for (const { name, rawSpec } of add) { + let addSaveType = saveType + // if the user does not give us a type, we infer which type(s) + // to keep based on the same order of priority we do when + // building the tree as defined in the _loadDeps method of + // the node class. + if (!addSaveType) { + addSaveType = inferSaveType(pkg, name) + } + + if (addSaveType === 'prod') { + // a production dependency can only exist as production (rpj ensures it + // doesn't coexist w/ optional) + deleteSubKey(pkg, 'devDependencies', name, 'dependencies') + deleteSubKey(pkg, 'peerDependencies', name, 'dependencies') + } else if (addSaveType === 'dev') { + // a dev dependency may co-exist as peer, or optional, but not production + deleteSubKey(pkg, 'dependencies', name, 'devDependencies') + } else if (addSaveType === 'optional') { + // an optional dependency may co-exist as dev (rpj ensures it doesn't + // coexist w/ prod) + deleteSubKey(pkg, 'peerDependencies', name, 'optionalDependencies') + } else { // peer or peerOptional is all that's left + // a peer dependency may coexist as dev + deleteSubKey(pkg, 'dependencies', name, 'peerDependencies') + deleteSubKey(pkg, 'optionalDependencies', name, 'peerDependencies') + } + + const depType = saveTypeMap.get(addSaveType) + + pkg[depType] = pkg[depType] || {} + if (rawSpec !== '*' || pkg[depType][name] === undefined) { + pkg[depType][name] = rawSpec + } + if (addSaveType === 'optional') { + // Affordance for previous npm versions that require this behaviour + pkg.dependencies = pkg.dependencies || {} + pkg.dependencies[name] = pkg.optionalDependencies[name] + } + + if (addSaveType === 'peer' || addSaveType === 'peerOptional') { + const pdm = pkg.peerDependenciesMeta || {} + if (addSaveType === 'peer' && pdm[name] && pdm[name].optional) { + pdm[name].optional = false + } else if (addSaveType === 'peerOptional') { + pdm[name] = pdm[name] || {} + pdm[name].optional = true + pkg.peerDependenciesMeta = pdm + } + // peerDeps are often also a devDep, so that they can be tested when + // using package managers that don't auto-install peer deps + if (pkg.devDependencies && pkg.devDependencies[name] !== undefined) { + pkg.devDependencies[name] = pkg.peerDependencies[name] + } + } + + if (saveBundle && addSaveType !== 'peer' && addSaveType !== 'peerOptional') { + // keep it sorted, keep it unique + const bd = new Set(pkg.bundleDependencies || []) + bd.add(name) + pkg.bundleDependencies = [...bd].sort(localeCompare) + } } return pkg @@ -20,71 +81,6 @@ const saveTypeMap = new Map([ ['peer', 'peerDependencies'], ]) -const addSingle = ({ pkg, spec, saveBundle, saveType, log }) => { - const { name, rawSpec } = spec - - // if the user does not give us a type, we infer which type(s) - // to keep based on the same order of priority we do when - // building the tree as defined in the _loadDeps method of - // the node class. - if (!saveType) { - saveType = inferSaveType(pkg, spec.name) - } - - if (saveType === 'prod') { - // a production dependency can only exist as production (rpj ensures it - // doesn't coexist w/ optional) - deleteSubKey(pkg, 'devDependencies', name, 'dependencies', log) - deleteSubKey(pkg, 'peerDependencies', name, 'dependencies', log) - } else if (saveType === 'dev') { - // a dev dependency may co-exist as peer, or optional, but not production - deleteSubKey(pkg, 'dependencies', name, 'devDependencies', log) - } else if (saveType === 'optional') { - // an optional dependency may co-exist as dev (rpj ensures it doesn't - // coexist w/ prod) - deleteSubKey(pkg, 'peerDependencies', name, 'optionalDependencies', log) - } else { // peer or peerOptional is all that's left - // a peer dependency may coexist as dev - deleteSubKey(pkg, 'dependencies', name, 'peerDependencies', log) - deleteSubKey(pkg, 'optionalDependencies', name, 'peerDependencies', log) - } - - const depType = saveTypeMap.get(saveType) - - pkg[depType] = pkg[depType] || {} - if (rawSpec !== '' || pkg[depType][name] === undefined) { - pkg[depType][name] = rawSpec || '*' - } - if (saveType === 'optional') { - // Affordance for previous npm versions that require this behaviour - pkg.dependencies = pkg.dependencies || {} - pkg.dependencies[name] = pkg.optionalDependencies[name] - } - - if (saveType === 'peer' || saveType === 'peerOptional') { - const pdm = pkg.peerDependenciesMeta || {} - if (saveType === 'peer' && pdm[name] && pdm[name].optional) { - pdm[name].optional = false - } else if (saveType === 'peerOptional') { - pdm[name] = pdm[name] || {} - pdm[name].optional = true - pkg.peerDependenciesMeta = pdm - } - // peerDeps are often also a devDep, so that they can be tested when - // using package managers that don't auto-install peer deps - if (pkg.devDependencies && pkg.devDependencies[name] !== undefined) { - pkg.devDependencies[name] = pkg.peerDependencies[name] - } - } - - if (saveBundle && saveType !== 'peer' && saveType !== 'peerOptional') { - // keep it sorted, keep it unique - const bd = new Set(pkg.bundleDependencies || []) - bd.add(spec.name) - pkg.bundleDependencies = [...bd].sort(localeCompare) - } -} - // Finds where the package is already in the spec and infers saveType from that const inferSaveType = (pkg, name) => { for (const saveType of saveTypeMap.keys()) { @@ -102,15 +98,14 @@ const inferSaveType = (pkg, name) => { return 'prod' } -const { hasOwnProperty } = Object.prototype const hasSubKey = (pkg, depType, name) => { - return pkg[depType] && hasOwnProperty.call(pkg[depType], name) + return pkg[depType] && Object.prototype.hasOwnProperty.call(pkg[depType], name) } // Removes a subkey and warns about it if it's being replaced -const deleteSubKey = (pkg, depType, name, replacedBy, log) => { +const deleteSubKey = (pkg, depType, name, replacedBy) => { if (hasSubKey(pkg, depType, name)) { - if (replacedBy && log) { + if (replacedBy) { log.warn('idealTree', `Removing ${depType}.${name} in favor of ${replacedBy}.${name}`) } delete pkg[depType][name] diff --git a/workspaces/arborist/lib/arborist/build-ideal-tree.js b/workspaces/arborist/lib/arborist/build-ideal-tree.js index b7bc56f..89584e5 100644 --- a/workspaces/arborist/lib/arborist/build-ideal-tree.js +++ b/workspaces/arborist/lib/arborist/build-ideal-tree.js @@ -7,13 +7,11 @@ const cacache = require('cacache') const promiseCallLimit = require('promise-call-limit') const realpath = require('../../lib/realpath.js') const { resolve, dirname } = require('path') -const { promisify } = require('util') const treeCheck = require('../tree-check.js') -const readdir = promisify(require('readdir-scoped-modules')) -const fs = require('fs') -const lstat = promisify(fs.lstat) -const readlink = promisify(fs.readlink) +const { readdirScoped } = require('@npmcli/fs') +const { lstat, readlink } = require('fs/promises') const { depth } = require('treeverse') +const log = require('proc-log') const { OK, @@ -47,7 +45,6 @@ const _flagsSuspect = Symbol.for('flagsSuspect') const _workspaces = Symbol.for('workspaces') const _prune = Symbol('prune') const _preferDedupe = Symbol('preferDedupe') -const _legacyBundling = Symbol('legacyBundling') const _parseSettings = Symbol('parseSettings') const _initTree = Symbol('initTree') const _applyUserRequests = Symbol('applyUserRequests') @@ -78,20 +75,13 @@ const _loadFailures = Symbol('loadFailures') const _pruneFailedOptional = Symbol('pruneFailedOptional') const _linkNodes = Symbol('linkNodes') const _follow = Symbol('follow') -const _globalStyle = Symbol('globalStyle') +const _installStrategy = Symbol('installStrategy') const _globalRootNode = Symbol('globalRootNode') -const _isVulnerable = Symbol.for('isVulnerable') const _usePackageLock = Symbol.for('usePackageLock') const _rpcache = Symbol.for('realpathCache') const _stcache = Symbol.for('statCache') -const _updateFilePath = Symbol('updateFilePath') -const _followSymlinkPath = Symbol('followSymlinkPath') -const _getRelpathSpec = Symbol('getRelpathSpec') -const _retrieveSpecName = Symbol('retrieveSpecName') const _strictPeerDeps = Symbol('strictPeerDeps') const _checkEngineAndPlatform = Symbol('checkEngineAndPlatform') -const _checkEngine = Symbol('checkEngine') -const _checkPlatform = Symbol('checkPlatform') const _virtualRoots = Symbol('virtualRoots') const _virtualRoot = Symbol('virtualRoot') const _includeWorkspaceRoot = Symbol.for('includeWorkspaceRoot') @@ -120,9 +110,10 @@ module.exports = cls => class IdealTreeBuilder extends cls { follow = false, force = false, global = false, - globalStyle = false, + installStrategy = 'hoisted', idealTree = null, includeWorkspaceRoot = false, + installLinks = false, legacyPeerDeps = false, packageLock = true, strictPeerDeps = false, @@ -134,11 +125,12 @@ module.exports = cls => class IdealTreeBuilder extends cls { this[_strictPeerDeps] = !!strictPeerDeps this.idealTree = idealTree + this.installLinks = installLinks this.legacyPeerDeps = legacyPeerDeps this[_usePackageLock] = packageLock this[_global] = !!global - this[_globalStyle] = this[_global] || globalStyle + this[_installStrategy] = global ? 'shallow' : installStrategy this[_follow] = !!follow if (this[_workspaces].length && this[_global]) { @@ -147,7 +139,6 @@ module.exports = cls => class IdealTreeBuilder extends cls { this[_explicitRequests] = new Set() this[_preferDedupe] = false - this[_legacyBundling] = false this[_depsSeen] = new Set() this[_depsQueue] = [] this[_currentDep] = null @@ -225,34 +216,22 @@ module.exports = cls => class IdealTreeBuilder extends cls { } async [_checkEngineAndPlatform] () { + const { engineStrict, npmVersion, nodeVersion } = this.options for (const node of this.idealTree.inventory.values()) { if (!node.optional) { - this[_checkEngine](node) - this[_checkPlatform](node) - } - } - } - - [_checkPlatform] (node) { - checkPlatform(node.package, this[_force]) - } - - [_checkEngine] (node) { - const { engineStrict, npmVersion, nodeVersion } = this.options - const c = () => - checkEngine(node.package, npmVersion, nodeVersion, this[_force]) - - if (engineStrict) { - c() - } else { - try { - c() - } catch (er) { - this.log.warn(er.code, er.message, { - package: er.pkgid, - required: er.required, - current: er.current, - }) + try { + checkEngine(node.package, npmVersion, nodeVersion, this[_force]) + } catch (err) { + if (engineStrict) { + throw err + } + log.warn(err.code, err.message, { + package: err.pkgid, + required: err.required, + current: err.current, + }) + } + checkPlatform(node.package, this[_force]) } } } @@ -268,20 +247,18 @@ module.exports = cls => class IdealTreeBuilder extends cls { this[_complete] = !!options.complete this[_preferDedupe] = !!options.preferDedupe - this[_legacyBundling] = !!options.legacyBundling // validates list of update names, they must // be dep names only, no semver ranges are supported for (const name of update.names) { const spec = npa(name) const validationError = - new TypeError(`Update arguments must not contain package version specifiers - -Try using the package name instead, e.g: + new TypeError(`Update arguments must only contain package names, eg: npm update ${spec.name}`) validationError.code = 'EUPDATEARGS' - if (spec.fetchSpec !== 'latest') { + // If they gave us anything other than a bare package name + if (spec.raw !== spec.name) { throw validationError } } @@ -326,6 +303,7 @@ Try using the package name instead, e.g: ? Shrinkwrap.reset({ path: this.path, lockfileVersion: this.options.lockfileVersion, + resolveOptions: this.options, }).then(meta => Object.assign(root, { meta })) : this.loadVirtual({ root })) @@ -345,8 +323,7 @@ Try using the package name instead, e.g: if (tree.children.size) { root.meta.loadedFromDisk = true // set these so that we don't try to ancient lockfile reload it - root.meta.originalLockfileVersion = defaultLockfileVersion - root.meta.lockfileVersion = defaultLockfileVersion + root.meta.originalLockfileVersion = root.meta.lockfileVersion = this.options.lockfileVersion || defaultLockfileVersion } } root.meta.inferFormattingOptions(root.package) @@ -354,11 +331,27 @@ Try using the package name instead, e.g: }) .then(tree => { + // search the virtual tree for invalid edges, if any are found add their source to + // the depsQueue so that we'll fix it later + depth({ + tree, + getChildren: (node) => [...node.edgesOut.values()].map(edge => edge.to), + filter: node => node, + visit: node => { + for (const edge of node.edgesOut.values()) { + if (!edge.valid) { + this[_depsQueue].push(node) + break // no need to continue the loop after the first hit + } + } + }, + }) // null the virtual tree, because we're about to hack away at it // if you want another one, load another copy. this.idealTree = tree this.virtualTree = null process.emit('timeEnd', 'idealTree:init') + return tree }) } @@ -370,6 +363,7 @@ Try using the package name instead, e.g: const meta = new Shrinkwrap({ path: this.path, lockfileVersion: this.options.lockfileVersion, + resolveOptions: this.options, }) meta.reset() root.meta = meta @@ -394,6 +388,7 @@ Try using the package name instead, e.g: peer: false, optional: false, global: this[_global], + installLinks: this.installLinks, legacyPeerDeps: this.legacyPeerDeps, loadOverrides: true, }) @@ -408,6 +403,7 @@ Try using the package name instead, e.g: peer: false, optional: false, global: this[_global], + installLinks: this.installLinks, legacyPeerDeps: this.legacyPeerDeps, root, }) @@ -450,7 +446,8 @@ Try using the package name instead, e.g: const globalExplicitUpdateNames = [] if (this[_global] && (this[_updateAll] || this[_updateNames].length)) { const nm = resolve(this.path, 'node_modules') - for (const name of await readdir(nm).catch(() => [])) { + const paths = await readdirScoped(nm).catch(() => []) + for (const name of paths.map((p) => p.replace(/\\/g, '/'))) { tree.package.dependencies = tree.package.dependencies || {} const updateName = this[_updateNames].includes(name) if (this[_updateAll] || updateName) { @@ -462,7 +459,7 @@ Try using the package name instead, e.g: .catch(/* istanbul ignore next */ er => null) if (st && st.isSymbolicLink()) { const target = await readlink(dir) - const real = resolve(dirname(dir), target) + const real = resolve(dirname(dir), target).replace(/#/g, '%23') tree.package.dependencies[name] = `file:${real}` } else { tree.package.dependencies[name] = '*' @@ -507,85 +504,59 @@ Try using the package name instead, e.g: this[_depsQueue].push(tree) } - // This returns a promise because we might not have the name yet, - // and need to call pacote.manifest to find the name. - [_add] (tree, { add, saveType = null, saveBundle = false }) { + // This returns a promise because we might not have the name yet, and need to + // call pacote.manifest to find the name. + async [_add] (tree, { add, saveType = null, saveBundle = false }) { + // If we have a link it will need to be added relative to the target's path + const path = tree.target.path + // get the name for each of the specs in the list. - // ie, doing `foo@bar` we just return foo - // but if it's a url or git, we don't know the name until we - // fetch it and look in its manifest. - return Promise.all(add.map(async rawSpec => { - // We do NOT provide the path to npa here, because user-additions - // need to be resolved relative to the CWD the user is in. - const spec = await this[_retrieveSpecName](npa(rawSpec)) - .then(spec => this[_updateFilePath](spec)) - .then(spec => this[_followSymlinkPath](spec)) - spec.tree = tree - return spec - })).then(add => { - this[_resolvedAdd].push(...add) - // now add is a list of spec objects with names. - // find a home for each of them! - addRmPkgDeps.add({ - pkg: tree.package, - add, - saveBundle, - saveType, - path: this.path, - log: this.log, - }) - }) - } + // ie, doing `foo@bar` we just return foo but if it's a url or git, we + // don't know the name until we fetch it and look in its manifest. + await Promise.all(add.map(async rawSpec => { + // We do NOT provide the path to npa here, because user-additions need to + // be resolved relative to the tree being added to. + let spec = npa(rawSpec) - async [_retrieveSpecName] (spec) { - // if it's just @'' then we reload whatever's there, or get latest - // if it's an explicit tag, we need to install that specific tag version - const isTag = spec.rawSpec && spec.type === 'tag' + // if it's just @'' then we reload whatever's there, or get latest + // if it's an explicit tag, we need to install that specific tag version + const isTag = spec.rawSpec && spec.type === 'tag' - if (spec.name && !isTag) { - return spec - } + // look up the names of file/directory/git specs + if (!spec.name || isTag) { + const mani = await pacote.manifest(spec, { ...this.options }) + if (isTag) { + // translate tag to a version + spec = npa(`${mani.name}@${mani.version}`) + } + spec.name = mani.name + } - const mani = await pacote.manifest(spec, { ...this.options }) - // if it's a tag type, then we need to run it down to an actual version - if (isTag) { - return npa(`${mani.name}@${mani.version}`) - } - - spec.name = mani.name - return spec - } - - async [_updateFilePath] (spec) { - if (spec.type === 'file') { - return this[_getRelpathSpec](spec, spec.fetchSpec) - } - - return spec - } - - async [_followSymlinkPath] (spec) { - if (spec.type === 'directory') { - const real = await ( - realpath(spec.fetchSpec, this[_rpcache], this[_stcache]) - // TODO: create synthetic test case to simulate realpath failure - .catch(/* istanbul ignore next */() => null) - ) - - return this[_getRelpathSpec](spec, real) - } - return spec - } - - [_getRelpathSpec] (spec, filepath) { - /* istanbul ignore else - should also be covered by realpath failure */ - if (filepath) { const { name } = spec - const tree = this.idealTree.target - spec = npa(`file:${relpath(tree.path, filepath)}`, tree.path) - spec.name = name - } - return spec + if (spec.type === 'file') { + spec = npa(`file:${relpath(path, spec.fetchSpec).replace(/#/g, '%23')}`, path) + spec.name = name + } else if (spec.type === 'directory') { + try { + const real = await realpath(spec.fetchSpec, this[_rpcache], this[_stcache]) + spec = npa(`file:${relpath(path, real).replace(/#/g, '%23')}`, path) + spec.name = name + } catch { + // TODO: create synthetic test case to simulate realpath failure + } + } + spec.tree = tree + this[_resolvedAdd].push(spec) + })) + + // now this._resolvedAdd is a list of spec objects with names. + // find a home for each of them! + addRmPkgDeps.add({ + pkg: tree.package, + add: this[_resolvedAdd], + saveBundle, + saveType, + }) } // TODO: provide a way to fix bundled deps by exposing metadata about @@ -602,7 +573,7 @@ Try using the package name instead, e.g: // be printed by npm-audit-report as if they can be fixed, because // they can't. if (bundler) { - this.log.warn(`audit fix ${node.name}@${node.version}`, + log.warn(`audit fix ${node.name}@${node.version}`, `${node.location}\nis a bundled dependency of\n${ bundler.name}@${bundler.version} at ${bundler.location}\n` + 'It cannot be fixed automatically.\n' + @@ -637,25 +608,27 @@ Try using the package name instead, e.g: if (!node.isProjectRoot && !node.isWorkspace) { // not something we're going to fix, sorry. have to cd into // that directory and fix it yourself. - this.log.warn('audit', 'Manual fix required in linked project ' + + log.warn('audit', 'Manual fix required in linked project ' + `at ./${node.location} for ${name}@${simpleRange}.\n` + `'cd ./${node.location}' and run 'npm audit' for details.`) continue } if (!fixAvailable) { - this.log.warn('audit', `No fix available for ${name}@${simpleRange}`) + log.warn('audit', `No fix available for ${name}@${simpleRange}`) continue } - const { isSemVerMajor, version } = fixAvailable + // name may be different if parent fixes the dep + // see Vuln fixAvailable setter + const { isSemVerMajor, version, name: fixName } = fixAvailable const breakingMessage = isSemVerMajor ? 'a SemVer major change' : 'outside your stated dependency range' - this.log.warn('audit', `Updating ${name} to ${version},` + + log.warn('audit', `Updating ${fixName} to ${version}, ` + `which is ${breakingMessage}.`) - await this[_add](node, { add: [`${name}@${version}`] }) + await this[_add](node, { add: [`${fixName}@${version}`] }) nodesTouched.add(node) } } @@ -665,10 +638,6 @@ Try using the package name instead, e.g: } } - [_isVulnerable] (node) { - return this.auditReport && this.auditReport.isVulnerable(node) - } - [_avoidRange] (name) { if (!this.auditReport) { return null @@ -727,7 +696,7 @@ Try using the package name instead, e.g: const heading = ancient ? 'ancient lockfile' : 'old lockfile' if (ancient || !this.options.lockfileVersion || this.options.lockfileVersion >= defaultLockfileVersion) { - this.log.warn(heading, + log.warn(heading, ` The ${meta.type} file was created with an old version of npm, so supplemental metadata must be fetched from the registry. @@ -743,30 +712,35 @@ This is a one-time fix-up, please be patient... continue } + // if the node's location isn't within node_modules then this is actually + // a link target, so skip it. the link node itself will be queued later. + if (!node.location.startsWith('node_modules')) { + continue + } + queue.push(async () => { - this.log.silly('inflate', node.location) + log.silly('inflate', node.location) const { resolved, version, path, name, location, integrity } = node // don't try to hit the registry for linked deps const useResolved = resolved && ( !version || resolved.startsWith('file:') ) - const id = useResolved ? resolved - : version || `file:${node.path}` + const id = useResolved ? resolved : version const spec = npa.resolve(name, id, dirname(path)) - const sloc = location.substr('node_modules/'.length) - const t = `idealTree:inflate:${sloc}` + const t = `idealTree:inflate:${location}` this.addTracker(t) - await pacote.manifest(spec, { - ...this.options, - resolved: resolved, - integrity: integrity, - fullMetadata: false, - }).then(mani => { + try { + const mani = await pacote.manifest(spec, { + ...this.options, + resolved: resolved, + integrity: integrity, + fullMetadata: false, + }) node.package = { ...mani, _id: `${mani.name}@${mani.version}` } - }).catch((er) => { + } catch (er) { const warning = `Could not fetch metadata for ${name}@${id}` - this.log.warn(heading, warning, er) - }) + log.warn(heading, warning, er) + } this.finishTracker(t) }) } @@ -779,7 +753,9 @@ This is a one-time fix-up, please be patient... // yes, yes, this isn't the "original" version, but now that it's been // upgraded, we need to make sure we don't do the work to upgrade it // again, since it's now as new as can be. - meta.originalLockfileVersion = defaultLockfileVersion + if (!this.options.lockfileVersion && !meta.hiddenLockfile) { + meta.originalLockfileVersion = defaultLockfileVersion + } this.finishTracker('idealTree:inflate') process.emit('timeEnd', 'idealTree:inflate') } @@ -794,7 +770,7 @@ This is a one-time fix-up, please be patient... this[_depsQueue].push(tree) // XXX also push anything that depends on a node with a name // in the override list - this.log.silly('idealTree', 'buildDeps') + log.silly('idealTree', 'buildDeps') this.addTracker('idealTree', tree.name, '') return this[_buildDepStep]() .then(() => process.emit('timeEnd', 'idealTree:buildDeps')) @@ -854,6 +830,7 @@ This is a one-time fix-up, please be patient... await cacache.tmp.withTmp(this.cache, opt, async path => { await pacote.extract(node.resolved, path, { ...opt, + Arborist, resolved: node.resolved, integrity: node.integrity, }) @@ -966,15 +943,15 @@ This is a one-time fix-up, please be patient... edge, dep, - explicitRequest: this[_explicitRequests].has(edge), - updateNames: this[_updateNames], auditReport: this.auditReport, + explicitRequest: this[_explicitRequests].has(edge), force: this[_force], - preferDedupe: this[_preferDedupe], - legacyBundling: this[_legacyBundling], - strictPeerDeps: this[_strictPeerDeps], + installLinks: this.installLinks, + installStrategy: this[_installStrategy], legacyPeerDeps: this.legacyPeerDeps, - globalStyle: this[_globalStyle], + preferDedupe: this[_preferDedupe], + strictPeerDeps: this[_strictPeerDeps], + updateNames: this[_updateNames], })) const promises = [] @@ -1050,9 +1027,8 @@ This is a one-time fix-up, please be patient... // if it fails at this point, though, dont' worry because it // may well be an optional dep that has gone missing. it'll // fail later anyway. - const from = fromPath(placed) promises.push(...this[_problemEdges](placed).map(e => - this[_fetchManifest](npa.resolve(e.name, e.spec, from)) + this[_fetchManifest](npa.resolve(e.name, e.spec, fromPath(placed, e))) .catch(er => null))) }, }) @@ -1132,6 +1108,7 @@ This is a one-time fix-up, please be patient... const vr = new Node({ path: node.realpath, sourceReference: node, + installLinks: this.installLinks, legacyPeerDeps: this.legacyPeerDeps, overrides: node.overrides, }) @@ -1207,7 +1184,7 @@ This is a one-time fix-up, please be patient... } // fixing a security vulnerability with this package, problem - if (this[_isVulnerable](edge.to)) { + if (this.auditReport && this.auditReport.isVulnerable(edge.to)) { return true } @@ -1233,7 +1210,7 @@ This is a one-time fix-up, please be patient... if (this[_manifests].has(spec.raw)) { return this[_manifests].get(spec.raw) } else { - this.log.silly('fetch manifest', spec.raw) + log.silly('fetch manifest', spec.raw) const p = pacote.manifest(spec, options) .then(mani => { this[_manifests].set(spec.raw, mani) @@ -1249,17 +1226,18 @@ This is a one-time fix-up, please be patient... // the object so it doesn't get mutated. // Don't bother to load the manifest for link deps, because the target // might be within another package that doesn't exist yet. - const { legacyPeerDeps } = this + const { installLinks, legacyPeerDeps } = this + const isWorkspace = this.idealTree.workspaces && this.idealTree.workspaces.has(spec.name) - // spec is a directory, link it - if (spec.type === 'directory') { + // spec is a directory, link it unless installLinks is set or it's a workspace + if (spec.type === 'directory' && (isWorkspace || !installLinks)) { return this[_linkFromSpec](name, spec, parent, edge) } // if the spec matches a workspace name, then see if the workspace node will // satisfy the edge. if it does, we return the workspace node to make sure it // takes priority. - if (this.idealTree.workspaces && this.idealTree.workspaces.has(spec.name)) { + if (isWorkspace) { const existingNode = this.idealTree.edgesOut.get(spec.name).to if (existingNode && existingNode.isWorkspace && existingNode.satisfies(edge)) { return edge.to @@ -1269,7 +1247,7 @@ This is a one-time fix-up, please be patient... // spec isn't a directory, and either isn't a workspace or the workspace we have // doesn't satisfy the edge. try to fetch a manifest and build a node from that. return this[_fetchManifest](spec) - .then(pkg => new Node({ name, pkg, parent, legacyPeerDeps }), error => { + .then(pkg => new Node({ name, pkg, parent, installLinks, legacyPeerDeps }), error => { error.requiredBy = edge.from.location || '.' // failed to load the spec, either because of enotarget or @@ -1279,6 +1257,7 @@ This is a one-time fix-up, please be patient... name, parent, error, + installLinks, legacyPeerDeps, }) this[_loadFailures].add(n) @@ -1288,9 +1267,9 @@ This is a one-time fix-up, please be patient... [_linkFromSpec] (name, spec, parent, edge) { const realpath = spec.fetchSpec - const { legacyPeerDeps } = this + const { installLinks, legacyPeerDeps } = this return rpj(realpath + '/package.json').catch(() => ({})).then(pkg => { - const link = new Link({ name, parent, realpath, pkg, legacyPeerDeps }) + const link = new Link({ name, parent, realpath, pkg, installLinks, legacyPeerDeps }) this[_linkNodes].add(link) return link }) diff --git a/workspaces/arborist/lib/arborist/index.js b/workspaces/arborist/lib/arborist/index.js index de625e9..091e0b4 100644 --- a/workspaces/arborist/lib/arborist/index.js +++ b/workspaces/arborist/lib/arborist/index.js @@ -28,7 +28,6 @@ const { resolve } = require('path') const { homedir } = require('os') -const procLog = require('proc-log') const { depth } = require('treeverse') const { saveTypeMap } = require('../add-rm-pkg-deps.js') @@ -74,10 +73,14 @@ class Arborist extends Base { path: options.path || '.', cache: options.cache || `${homedir()}/.npm/_cacache`, packumentCache: options.packumentCache || new Map(), - log: options.log || procLog, workspacesEnabled: options.workspacesEnabled !== false, + replaceRegistryHost: options.replaceRegistryHost, lockfileVersion: lockfileVersion(options.lockfileVersion), + installStrategy: options.global ? 'shallow' : (options.installStrategy ? options.installStrategy : 'hoisted'), } + this.replaceRegistryHost = this.options.replaceRegistryHost = + (!this.options.replaceRegistryHost || this.options.replaceRegistryHost === 'npmjs') ? + 'registry.npmjs.org' : this.options.replaceRegistryHost this[_workspacesEnabled] = this.options.workspacesEnabled @@ -94,7 +97,7 @@ class Arborist extends Base { // returns an array of the actual nodes for all the workspaces workspaceNodes (tree, workspaces) { - return getWorkspaceNodes(tree, workspaces, this.log) + return getWorkspaceNodes(tree, workspaces) } // returns a set of workspace nodes and all their deps @@ -132,7 +135,7 @@ class Arborist extends Base { return wsDepSet } - // returns a set of root dependencies, excluding depdencies that are + // returns a set of root dependencies, excluding dependencies that are // exclusively workspace dependencies excludeWorkspacesDependencySet (tree) { const rootDepSet = new Set() diff --git a/workspaces/arborist/lib/arborist/load-actual.js b/workspaces/arborist/lib/arborist/load-actual.js index c06ed80..6c3f917 100644 --- a/workspaces/arborist/lib/arborist/load-actual.js +++ b/workspaces/arborist/lib/arborist/load-actual.js @@ -3,8 +3,7 @@ const { relative, dirname, resolve, join, normalize } = require('path') const rpj = require('read-package-json-fast') -const { promisify } = require('util') -const readdir = promisify(require('readdir-scoped-modules')) +const { readdirScoped } = require('@npmcli/fs') const walkUp = require('walk-up-path') const ancestorPath = require('common-ancestor-path') const treeCheck = require('../tree-check.js') @@ -15,34 +14,30 @@ const Node = require('../node.js') const Link = require('../link.js') const realpath = require('../realpath.js') -const _loadFSNode = Symbol('loadFSNode') -const _newNode = Symbol('newNode') -const _newLink = Symbol('newLink') -const _loadFSTree = Symbol('loadFSTree') -const _loadFSChildren = Symbol('loadFSChildren') -const _findMissingEdges = Symbol('findMissingEdges') -const _findFSParents = Symbol('findFSParents') -const _resetDepFlags = Symbol('resetDepFlags') - -const _actualTreeLoaded = Symbol('actualTreeLoaded') +// public symbols +const _changePath = Symbol.for('_changePath') +const _global = Symbol.for('global') +const _loadWorkspaces = Symbol.for('loadWorkspaces') const _rpcache = Symbol.for('realpathCache') const _stcache = Symbol.for('statCache') -const _topNodes = Symbol('linkTargets') -const _cache = Symbol('nodeLoadingCache') -const _loadActual = Symbol('loadActual') -const _loadActualVirtually = Symbol('loadActualVirtually') -const _loadActualActually = Symbol('loadActualActually') -const _loadWorkspaces = Symbol.for('loadWorkspaces') -const _loadWorkspaceTargets = Symbol('loadWorkspaceTargets') -const _actualTreePromise = Symbol('actualTreePromise') + +// private symbols const _actualTree = Symbol('actualTree') +const _actualTreeLoaded = Symbol('actualTreeLoaded') +const _actualTreePromise = Symbol('actualTreePromise') +const _cache = Symbol('nodeLoadingCache') +const _filter = Symbol('filter') +const _findMissingEdges = Symbol('findMissingEdges') +const _loadActual = Symbol('loadActual') +const _loadFSChildren = Symbol('loadFSChildren') +const _loadFSNode = Symbol('loadFSNode') +const _loadFSTree = Symbol('loadFSTree') +const _newLink = Symbol('newLink') +const _newNode = Symbol('newNode') +const _topNodes = Symbol('linkTargets') const _transplant = Symbol('transplant') const _transplantFilter = Symbol('transplantFilter') -const _filter = Symbol('filter') -const _global = Symbol.for('global') -const _changePath = Symbol.for('_changePath') - module.exports = cls => class ActualLoader extends cls { constructor (options) { super(options) @@ -75,37 +70,44 @@ module.exports = cls => class ActualLoader extends cls { this[_topNodes] = new Set() } - [_resetDepFlags] (tree, root) { - // reset all deps to extraneous prior to recalc - if (!root) { - for (const node of tree.inventory.values()) { - node.extraneous = true - } - } - - // only reset root flags if we're not re-rooting, - // otherwise leave as-is - calcDepFlags(tree, !root) - return tree - } - // public method async loadActual (options = {}) { - // allow the user to set options on the ctor as well. - // XXX: deprecate separate method options objects. - options = { ...this.options, ...options } + // In the past this.actualTree was set as a promise that eventually + // resolved, and overwrite this.actualTree with the resolved value. This + // was a problem because virtually no other code expects this.actualTree to + // be a promise. Instead we only set it once resolved, and also return it + // from the promise so that it is what's returned from this function when + // awaited. + if (this.actualTree) { + return this.actualTree + } + if (!this[_actualTreePromise]) { + // allow the user to set options on the ctor as well. + // XXX: deprecate separate method options objects. + options = { ...this.options, ...options } - // stash the promise so that we don't ever have more than one - // going at the same time. This is so that buildIdealTree can - // default to the actualTree if no shrinkwrap present, but - // reify() can still call buildIdealTree and loadActual in parallel - // safely. - return this.actualTree ? this.actualTree - : this[_actualTreePromise] ? this[_actualTreePromise] - : this[_actualTreePromise] = this[_loadActual](options) - .then(tree => this[_resetDepFlags](tree, options.root)) - .then(tree => this.actualTree = treeCheck(tree)) + this[_actualTreePromise] = this[_loadActual](options) + .then(tree => { + // reset all deps to extraneous prior to recalc + if (!options.root) { + for (const node of tree.inventory.values()) { + node.extraneous = true + } + } + + // only reset root flags if we're not re-rooting, + // otherwise leave as-is + calcDepFlags(tree, !options.root) + this.actualTree = treeCheck(tree) + return this.actualTree + }) + } + return this[_actualTreePromise] } + // return the promise so that we don't ever have more than one going at the + // same time. This is so that buildIdealTree can default to the actualTree + // if no shrinkwrap present, but reify() can still call buildIdealTree and + // loadActual in parallel safely. async [_loadActual] (options) { // mostly realpath to throw if the root doesn't exist @@ -115,75 +117,109 @@ module.exports = cls => class ActualLoader extends cls { root = null, transplantFilter = () => true, ignoreMissing = false, + forceActual = false, } = options this[_filter] = filter this[_transplantFilter] = transplantFilter if (global) { const real = await realpath(this.path, this[_rpcache], this[_stcache]) - const newNodeOrLink = this.path === real ? _newNode : _newLink - this[_actualTree] = await this[newNodeOrLink]({ + const params = { path: this.path, realpath: real, pkg: {}, global, loadOverrides: true, - }) - return this[_loadActualActually]({ root, ignoreMissing, global }) - } - - // not in global mode, hidden lockfile is allowed, load root pkg too - this[_actualTree] = await this[_loadFSNode]({ - path: this.path, - real: await realpath(this.path, this[_rpcache], this[_stcache]), - loadOverrides: true, - }) - - this[_actualTree].assertRootOverrides() - - // Note: hidden lockfile will be rejected if it's not the latest thing - // in the folder, or if any of the entries in the hidden lockfile are - // missing. - const meta = await Shrinkwrap.load({ - path: this[_actualTree].path, - hiddenLockfile: true, - }) - if (meta.loadedFromDisk) { - this[_actualTree].meta = meta - return this[_loadActualVirtually]({ root }) + } + if (this.path === real) { + this[_actualTree] = this[_newNode](params) + } else { + this[_actualTree] = await this[_newLink](params) + } } else { + // not in global mode, hidden lockfile is allowed, load root pkg too + this[_actualTree] = await this[_loadFSNode]({ + path: this.path, + real: await realpath(this.path, this[_rpcache], this[_stcache]), + loadOverrides: true, + }) + + this[_actualTree].assertRootOverrides() + + // if forceActual is set, don't even try the hidden lockfile + if (!forceActual) { + // Note: hidden lockfile will be rejected if it's not the latest thing + // in the folder, or if any of the entries in the hidden lockfile are + // missing. + const meta = await Shrinkwrap.load({ + path: this[_actualTree].path, + hiddenLockfile: true, + resolveOptions: this.options, + }) + + if (meta.loadedFromDisk) { + this[_actualTree].meta = meta + // have to load on a new Arborist object, so we don't assign + // the virtualTree on this one! Also, the weird reference is because + // we can't easily get a ref to Arborist in this module, without + // creating a circular reference, since this class is a mixin used + // to build up the Arborist class itself. + await new this.constructor({ ...this.options }).loadVirtual({ + root: this[_actualTree], + }) + await this[_loadWorkspaces](this[_actualTree]) + + this[_transplant](root) + return this[_actualTree] + } + } + const meta = await Shrinkwrap.load({ path: this[_actualTree].path, lockfileVersion: this.options.lockfileVersion, + resolveOptions: this.options, }) this[_actualTree].meta = meta - return this[_loadActualActually]({ root, ignoreMissing }) } - } - async [_loadActualVirtually] ({ root }) { - // have to load on a new Arborist object, so we don't assign - // the virtualTree on this one! Also, the weird reference is because - // we can't easily get a ref to Arborist in this module, without - // creating a circular reference, since this class is a mixin used - // to build up the Arborist class itself. - await new this.constructor({ ...this.options }).loadVirtual({ - root: this[_actualTree], - }) - await this[_loadWorkspaces](this[_actualTree]) - - this[_transplant](root) - return this[_actualTree] - } - - async [_loadActualActually] ({ root, ignoreMissing, global }) { await this[_loadFSTree](this[_actualTree]) await this[_loadWorkspaces](this[_actualTree]) - await this[_loadWorkspaceTargets](this[_actualTree]) + + // if there are workspace targets without Link nodes created, load + // the targets, so that we know what they are. + if (this[_actualTree].workspaces && this[_actualTree].workspaces.size) { + const promises = [] + for (const path of this[_actualTree].workspaces.values()) { + if (!this[_cache].has(path)) { + // workspace overrides use the root overrides + const p = this[_loadFSNode]({ path, root: this[_actualTree], useRootOverrides: true }) + .then(node => this[_loadFSTree](node)) + promises.push(p) + } + } + await Promise.all(promises) + } + if (!ignoreMissing) { await this[_findMissingEdges]() } - this[_findFSParents]() + + // try to find a node that is the parent in a fs tree sense, but not a + // node_modules tree sense, of any link targets. this allows us to + // resolve deps that node will find, but a legacy npm view of the + // world would not have noticed. + for (const path of this[_topNodes]) { + const node = this[_cache].get(path) + if (node && !node.parent && !node.fsParent) { + for (const p of walkUp(dirname(path))) { + if (this[_cache].has(p)) { + node.fsParent = this[_cache].get(p) + break + } + } + } + } + this[_transplant](root) if (global) { @@ -194,7 +230,7 @@ module.exports = cls => class ActualLoader extends cls { const actualRoot = tree.isLink ? tree.target : tree const { dependencies = {} } = actualRoot.package for (const [name, kid] of actualRoot.children.entries()) { - const def = kid.isLink ? `file:${kid.realpath}` : '*' + const def = kid.isLink ? `file:${kid.realpath.replace(/#/g, '%23')}` : '*' dependencies[name] = dependencies[name] || def } actualRoot.package = { ...actualRoot.package, dependencies } @@ -202,25 +238,6 @@ module.exports = cls => class ActualLoader extends cls { return this[_actualTree] } - // if there are workspace targets without Link nodes created, load - // the targets, so that we know what they are. - async [_loadWorkspaceTargets] (tree) { - if (!tree.workspaces || !tree.workspaces.size) { - return - } - - const promises = [] - for (const path of tree.workspaces.values()) { - if (!this[_cache].has(path)) { - // workspace overrides use the root overrides - const p = this[_loadFSNode]({ path, root: this[_actualTree], useRootOverrides: true }) - .then(node => this[_loadFSTree](node)) - promises.push(p) - } - } - await Promise.all(promises) - } - [_transplant] (root) { if (!root || root === this[_actualTree]) { return @@ -241,79 +258,63 @@ module.exports = cls => class ActualLoader extends cls { this[_actualTree] = root } - [_loadFSNode] ({ path, parent, real, root, loadOverrides, useRootOverrides }) { + async [_loadFSNode] ({ path, parent, real, root, loadOverrides, useRootOverrides }) { if (!real) { - return realpath(path, this[_rpcache], this[_stcache]) - .then( - real => this[_loadFSNode]({ - path, - parent, - real, - root, - loadOverrides, - useRootOverrides, - }), - // if realpath fails, just provide a dummy error node - error => new Node({ - error, - path, - realpath: path, - parent, - root, - loadOverrides, - }) - ) - } - - // cache temporarily holds a promise placeholder so we don't try to create - // the same node multiple times. this is rare to encounter, given the - // aggressive caching on realpath and lstat calls, but it's possible that - // it's already loaded as a tree top, and then gets its parent loaded - // later, if a symlink points deeper in the tree. - const cached = this[_cache].get(path) - if (cached && !cached.dummy) { - return Promise.resolve(cached).then(node => { - node.parent = parent - return node - }) - } - - const p = rpj(join(real, 'package.json')) - // soldier on if read-package-json raises an error - .then(pkg => [pkg, null], error => [null, error]) - .then(([pkg, error]) => { - return this[normalize(path) === real ? _newNode : _newLink]({ - legacyPeerDeps: this.legacyPeerDeps, - path, - realpath: real, - pkg, + try { + real = await realpath(path, this[_rpcache], this[_stcache]) + } catch (error) { + // if realpath fails, just provide a dummy error node + return new Node({ error, + path, + realpath: path, parent, root, loadOverrides, - ...(useRootOverrides && root.overrides - ? { overrides: root.overrides.getNodeRule({ name: pkg.name, version: pkg.version }) } - : {}), }) - }) - .then(node => { - this[_cache].set(path, node) - return node - }) + } + } - this[_cache].set(path, p) - return p + const cached = this[_cache].get(path) + let node + // missing edges get a dummy node, assign the parent and return it + if (cached && !cached.dummy) { + cached.parent = parent + return cached + } else { + const params = { + installLinks: this.installLinks, + legacyPeerDeps: this.legacyPeerDeps, + path, + realpath: real, + parent, + root, + loadOverrides, + } + + try { + const pkg = await rpj(join(real, 'package.json')) + params.pkg = pkg + if (useRootOverrides && root.overrides) { + params.overrides = root.overrides.getNodeRule({ name: pkg.name, version: pkg.version }) + } + } catch (err) { + params.error = err + } + + // soldier on if read-package-json raises an error, passing it to the + // Node which will attach it to its errors array (Link passes it along to + // its target node) + if (normalize(path) === real) { + node = this[_newNode](params) + } else { + node = await this[_newLink](params) + } + } + this[_cache].set(path, node) + return node } - // this is the way it is to expose a timing issue which is difficult to - // test otherwise. The creation of a Node may take slightly longer than - // the creation of a Link that targets it. If the Node has _begun_ its - // creation phase (and put a Promise in the cache) then the Link will - // get a Promise as its cachedTarget instead of an actual Node object. - // This is not a problem, because it gets resolved prior to returning - // the tree or attempting to load children. However, it IS remarkably - // difficult to get to happen in a test environment to verify reliably. - // Hence this kludge. [_newNode] (options) { // check it for an fsParent if it's a tree top. there's a decent chance // it'll get parented later, making the fsParent scan a no-op, but better @@ -322,69 +323,56 @@ module.exports = cls => class ActualLoader extends cls { if (!parent) { this[_topNodes].add(realpath) } - return process.env._TEST_ARBORIST_SLOW_LINK_TARGET_ === '1' - ? new Promise(res => setTimeout(() => res(new Node(options)), 100)) - : new Node(options) + return new Node(options) } - [_newLink] (options) { + async [_newLink] (options) { const { realpath } = options this[_topNodes].add(realpath) const target = this[_cache].get(realpath) const link = new Link({ ...options, target }) if (!target) { + // Link set its target itself in this case this[_cache].set(realpath, link.target) // if a link target points at a node outside of the root tree's // node_modules hierarchy, then load that node as well. - return this[_loadFSTree](link.target).then(() => link) - } else if (target.then) { - target.then(node => link.target = node) + await this[_loadFSTree](link.target) } return link } - [_loadFSTree] (node) { + async [_loadFSTree] (node) { const did = this[_actualTreeLoaded] - node = node.target - - // if a Link target has started, but not completed, then - // a Promise will be in the cache to indicate this. - if (node.then) { - return node.then(node => this[_loadFSTree](node)) - } - - // impossible except in pathological ELOOP cases - /* istanbul ignore if */ - if (did.has(node.realpath)) { - return Promise.resolve(node) - } - - did.add(node.realpath) - return this[_loadFSChildren](node) - .then(() => Promise.all( - [...node.children.entries()] + if (!did.has(node.target.realpath)) { + did.add(node.target.realpath) + await this[_loadFSChildren](node.target) + return Promise.all( + [...node.target.children.entries()] .filter(([name, kid]) => !did.has(kid.realpath)) - .map(([name, kid]) => this[_loadFSTree](kid)))) + .map(([name, kid]) => this[_loadFSTree](kid)) + ) + } } // create child nodes for all the entries in node_modules // and attach them to the node as a parent - [_loadFSChildren] (node) { + async [_loadFSChildren] (node) { const nm = resolve(node.realpath, 'node_modules') - return readdir(nm).then(kids => { + try { + const kids = await readdirScoped(nm).then(paths => paths.map(p => p.replace(/\\/g, '/'))) return Promise.all( - // ignore . dirs and retired scoped package folders + // ignore . dirs and retired scoped package folders kids.filter(kid => !/^(@[^/]+\/)?\./.test(kid)) .filter(kid => this[_filter](node, kid)) .map(kid => this[_loadFSNode]({ parent: node, path: resolve(nm, kid), }))) - }, - // error in the readdir is not fatal, just means no kids - () => {}) + } catch { + // error in the readdir is not fatal, just means no kids + } } async [_findMissingEdges] () { @@ -422,8 +410,8 @@ module.exports = cls => class ActualLoader extends cls { break } - const entries = nmContents.get(p) || - await readdir(p + '/node_modules').catch(() => []) + const entries = nmContents.get(p) || await readdirScoped(p + '/node_modules') + .catch(() => []).then(paths => paths.map(p => p.replace(/\\/g, '/'))) nmContents.set(p, entries) if (!entries.includes(name)) { continue @@ -431,11 +419,12 @@ module.exports = cls => class ActualLoader extends cls { const d = this[_cache].has(p) ? await this[_cache].get(p) : new Node({ path: p, root: node.root, dummy: true }) + // not a promise this[_cache].set(p, d) if (d.dummy) { // it's a placeholder, so likely would not have loaded this dep, // unless another dep in the tree also needs it. - const depPath = `${p}/node_modules/${name}` + const depPath = normalize(`${p}/node_modules/${name}`) const cached = this[_cache].get(depPath) if (!cached || cached.dummy) { depPromises.push(this[_loadFSNode]({ @@ -451,22 +440,4 @@ module.exports = cls => class ActualLoader extends cls { await Promise.all(depPromises) } } - - // try to find a node that is the parent in a fs tree sense, but not a - // node_modules tree sense, of any link targets. this allows us to - // resolve deps that node will find, but a legacy npm view of the - // world would not have noticed. - [_findFSParents] () { - for (const path of this[_topNodes]) { - const node = this[_cache].get(path) - if (node && !node.parent && !node.fsParent) { - for (const p of walkUp(dirname(path))) { - if (this[_cache].has(p)) { - node.fsParent = this[_cache].get(p) - break - } - } - } - } - } } diff --git a/workspaces/arborist/lib/arborist/load-virtual.js b/workspaces/arborist/lib/arborist/load-virtual.js index 4d65e3d..947659f 100644 --- a/workspaces/arborist/lib/arborist/load-virtual.js +++ b/workspaces/arborist/lib/arborist/load-virtual.js @@ -57,6 +57,7 @@ module.exports = cls => class VirtualLoader extends cls { const s = await Shrinkwrap.load({ path: this.path, lockfileVersion: this.options.lockfileVersion, + resolveOptions: this.options, }) if (!s.loadedFromDisk && !options.root) { const er = new Error('loadVirtual requires existing shrinkwrap file') @@ -79,7 +80,7 @@ module.exports = cls => class VirtualLoader extends cls { async [loadRoot] (s) { const pj = this.path + '/package.json' const pkg = await rpj(pj).catch(() => s.data.packages['']) || {} - return this[loadWorkspaces](this[loadNode]('', pkg)) + return this[loadWorkspaces](this[loadNode]('', pkg, true)) } async [loadFromShrinkwrap] (s, root) { @@ -161,7 +162,7 @@ module.exports = cls => class VirtualLoader extends cls { lockfile: s.data, }) for (const [name, path] of workspaces.entries()) { - lockWS.push(['workspace', name, `file:${path}`]) + lockWS.push(['workspace', name, `file:${path.replace(/#/g, '%23')}`]) } const lockEdges = [ @@ -264,7 +265,7 @@ module.exports = cls => class VirtualLoader extends cls { } } - [loadNode] (location, sw) { + [loadNode] (location, sw, loadOverrides) { const p = this.virtualTree ? this.virtualTree.realpath : this.path const path = resolve(p, location) // shrinkwrap doesn't include package name unless necessary @@ -278,6 +279,7 @@ module.exports = cls => class VirtualLoader extends cls { const peer = sw.peer const node = new Node({ + installLinks: this.installLinks, legacyPeerDeps: this.legacyPeerDeps, root: this.virtualTree, path, @@ -290,6 +292,7 @@ module.exports = cls => class VirtualLoader extends cls { optional, devOptional, peer, + loadOverrides, }) // cast to boolean because they're undefined in the lock file when false node.extraneous = !!sw.extraneous @@ -303,6 +306,7 @@ module.exports = cls => class VirtualLoader extends cls { [loadLink] (location, targetLoc, target, meta) { const path = resolve(this.path, location) const link = new Link({ + installLinks: this.installLinks, legacyPeerDeps: this.legacyPeerDeps, path, realpath: resolve(this.path, targetLoc), diff --git a/workspaces/arborist/lib/arborist/rebuild.js b/workspaces/arborist/lib/arborist/rebuild.js index 1a05e52..6a67532 100644 --- a/workspaces/arborist/lib/arborist/rebuild.js +++ b/workspaces/arborist/lib/arborist/rebuild.js @@ -13,6 +13,7 @@ const { isNodeGypPackage, defaultGypInstallScript, } = require('@npmcli/node-gyp') +const log = require('proc-log') const boolEnv = b => b ? '1' : '' const sortNodes = (a, b) => @@ -20,6 +21,8 @@ const sortNodes = (a, b) => const _workspaces = Symbol.for('workspaces') const _build = Symbol('build') +const _loadDefaultNodes = Symbol('loadDefaultNodes') +const _retrieveNodesByType = Symbol('retrieveNodesByType') const _resetQueues = Symbol('resetQueues') const _rebuildBundle = Symbol('rebuildBundle') const _ignoreScripts = Symbol('ignoreScripts') @@ -38,6 +41,7 @@ const _includeWorkspaceRoot = Symbol.for('includeWorkspaceRoot') const _workspacesEnabled = Symbol.for('workspacesEnabled') const _force = Symbol.for('force') +const _global = Symbol.for('global') // defined by reify mixin const _handleOptionalFailure = Symbol.for('handleOptionalFailure') @@ -74,36 +78,60 @@ module.exports = cls => class Builder extends cls { // running JUST a rebuild, we treat optional failures as real fails this[_doHandleOptionalFailure] = handleOptionalFailure - // if we don't have a set of nodes, then just rebuild - // the actual tree on disk. if (!nodes) { - const tree = await this.loadActual() - let filterSet - if (!this[_workspacesEnabled]) { - filterSet = this.excludeWorkspacesDependencySet(tree) - nodes = tree.inventory.filter(node => - filterSet.has(node) || node.isProjectRoot - ) - } else if (this[_workspaces] && this[_workspaces].length) { - filterSet = this.workspaceDependencySet( - tree, - this[_workspaces], - this[_includeWorkspaceRoot] - ) - nodes = tree.inventory.filter(node => filterSet.has(node)) - } else { - nodes = tree.inventory.values() - } + nodes = await this[_loadDefaultNodes]() } // separates links nodes so that it can run // prepare scripts and link bins in the expected order process.emit('time', 'build') + + const { + depNodes, + linkNodes, + } = this[_retrieveNodesByType](nodes) + + // build regular deps + await this[_build](depNodes, {}) + + // build link deps + if (linkNodes.size) { + this[_resetQueues]() + await this[_build](linkNodes, { type: 'links' }) + } + + process.emit('timeEnd', 'build') + } + + // if we don't have a set of nodes, then just rebuild + // the actual tree on disk. + async [_loadDefaultNodes] () { + let nodes + const tree = await this.loadActual() + let filterSet + if (!this[_workspacesEnabled]) { + filterSet = this.excludeWorkspacesDependencySet(tree) + nodes = tree.inventory.filter(node => + filterSet.has(node) || node.isProjectRoot + ) + } else if (this[_workspaces] && this[_workspaces].length) { + filterSet = this.workspaceDependencySet( + tree, + this[_workspaces], + this[_includeWorkspaceRoot] + ) + nodes = tree.inventory.filter(node => filterSet.has(node)) + } else { + nodes = tree.inventory.values() + } + return nodes + } + + [_retrieveNodesByType] (nodes) { const depNodes = new Set() const linkNodes = new Set() + for (const node of nodes) { - // we skip the target nodes to that workspace in order to make sure - // we only run lifecycle scripts / place bin links once per workspace if (node.isLink) { linkNodes.add(node) } else { @@ -111,14 +139,22 @@ module.exports = cls => class Builder extends cls { } } - await this[_build](depNodes, {}) - - if (linkNodes.size) { - this[_resetQueues]() - await this[_build](linkNodes, { type: 'links' }) + // deduplicates link nodes and their targets, avoids + // calling lifecycle scripts twice when running `npm rebuild` + // ref: https://github.com/npm/cli/issues/2905 + // + // we avoid doing so if global=true since `bin-links` relies + // on having the target nodes available in global mode. + if (!this[_global]) { + for (const node of linkNodes) { + depNodes.delete(node.target) + } } - process.emit('timeEnd', 'build') + return { + depNodes, + linkNodes, + } } [_resetQueues] () { @@ -135,20 +171,17 @@ module.exports = cls => class Builder extends cls { process.emit('time', `build:${type}`) await this[_buildQueues](nodes) + if (!this[_ignoreScripts]) { await this[_runScripts]('preinstall') } - if (this[_binLinks] && type !== 'links') { - await this[_linkAllBins]() - } - // links should also run prepare scripts and only link bins after that + // links should run prepare scripts and only link bins after that if (type === 'links') { await this[_runScripts]('prepare') - - if (this[_binLinks]) { - await this[_linkAllBins]() - } + } + if (this[_binLinks]) { + await this[_linkAllBins]() } if (!this[_ignoreScripts]) { @@ -297,7 +330,7 @@ module.exports = cls => class Builder extends cls { const timer = `build:run:${event}:${location}` process.emit('time', timer) - this.log.info('run', pkg._id, event, location, pkg.scripts[event]) + log.info('run', pkg._id, event, location, pkg.scripts[event]) const env = { npm_package_resolved: resolved, npm_package_integrity: integrity, @@ -312,20 +345,22 @@ module.exports = cls => class Builder extends cls { event, path, pkg, - stdioString: true, stdio, env, scriptShell: this[_scriptShell], } const p = runScript(runOpts).catch(er => { const { code, signal } = er - this.log.info('run', pkg._id, event, { code, signal }) + log.info('run', pkg._id, event, { code, signal }) throw er }).then(({ args, code, signal, stdout, stderr }) => { this.scriptsRun.add({ pkg, path, event, + // I do not know why this needs to be on THIS line but refactoring + // this function would be quite a process + // eslint-disable-next-line promise/always-return cmd: args && args[args.length - 1], env, code, @@ -333,7 +368,7 @@ module.exports = cls => class Builder extends cls { stdout, stderr, }) - this.log.info('run', pkg._id, event, { code, signal }) + log.info('run', pkg._id, event, { code, signal }) }) await (this[_doHandleOptionalFailure] diff --git a/workspaces/arborist/lib/arborist/reify.js b/workspaces/arborist/lib/arborist/reify.js index 91507fd..e5ccec5 100644 --- a/workspaces/arborist/lib/arborist/reify.js +++ b/workspaces/arborist/lib/arborist/reify.js @@ -8,19 +8,21 @@ const npa = require('npm-package-arg') const semver = require('semver') const debug = require('../debug.js') const walkUp = require('walk-up-path') +const log = require('proc-log') +const hgi = require('hosted-git-info') const { dirname, resolve, relative } = require('path') const { depth: dfwalk } = require('treeverse') -const fs = require('fs') -const { promisify } = require('util') -const lstat = promisify(fs.lstat) -const symlink = promisify(fs.symlink) -const mkdirp = require('mkdirp-infer-owner') -const justMkdirp = require('mkdirp') -const moveFile = require('@npmcli/move-file') -const rimraf = promisify(require('rimraf')) +const { + lstat, + mkdir, + rm, + symlink, +} = require('fs/promises') +const { moveFile } = require('@npmcli/fs') const PackageJson = require('@npmcli/package-json') const packageContents = require('@npmcli/installed-package-contents') +const runScript = require('@npmcli/run-script') const { checkEngine, checkPlatform } = require('npm-install-checks') const _force = Symbol.for('force') @@ -33,6 +35,9 @@ const optionalSet = require('../optional-set.js') const calcDepFlags = require('../calc-dep-flags.js') const { saveTypeMap, hasSubKey } = require('../add-rm-pkg-deps.js') +const Shrinkwrap = require('../shrinkwrap.js') +const { defaultLockfileVersion } = Shrinkwrap + const _retiredPaths = Symbol('retiredPaths') const _retiredUnchanged = Symbol('retiredUnchanged') const _sparseTreeDirs = Symbol('sparseTreeDirs') @@ -67,7 +72,6 @@ const _symlink = Symbol('symlink') const _warnDeprecated = Symbol('warnDeprecated') const _loadBundlesAndUpdateTrees = Symbol.for('loadBundlesAndUpdateTrees') const _submitQuickAudit = Symbol('submitQuickAudit') -const _awaitQuickAudit = Symbol('awaitQuickAudit') const _unpackNewModules = Symbol.for('unpackNewModules') const _moveContents = Symbol.for('moveContents') const _moveBackRetiredUnchanged = Symbol.for('moveBackRetiredUnchanged') @@ -154,7 +158,8 @@ module.exports = cls => class Reifier extends cls { await this[_reifyPackages]() await this[_saveIdealTree](options) await this[_copyIdealToActual]() - await this[_awaitQuickAudit]() + // This is a very bad pattern and I can't wait to stop doing it + this.auditReport = await this.auditReport this.finishTracker('reify') process.emit('timeEnd', 'reify') @@ -170,7 +175,7 @@ module.exports = cls => class Reifier extends cls { // we do NOT want to set ownership on this folder, especially // recursively, because it can have other side effects to do that // in a project directory. We just want to make it if it's missing. - await justMkdirp(resolve(this.path)) + await mkdir(resolve(this.path), { recursive: true }) // do not allow the top-level node_modules to be a symlink await this[_validateNodeModules](resolve(this.path, 'node_modules')) @@ -390,7 +395,7 @@ module.exports = cls => class Reifier extends cls { [_addNodeToTrashList] (node, retire = false) { const paths = [node.path, ...node.binPaths] const moves = this[_retiredPaths] - this.log.silly('reify', 'mark', retire ? 'retired' : 'deleted', paths) + log.silly('reify', 'mark', retire ? 'retired' : 'deleted', paths) for (const path of paths) { if (retire) { const retired = retirePath(path) @@ -413,7 +418,7 @@ module.exports = cls => class Reifier extends cls { this[_addNodeToTrashList](diff.actual, true) } } - this.log.silly('reify', 'moves', moves) + log.silly('reify', 'moves', moves) const movePromises = Object.entries(moves) .map(([from, to]) => this[_renamePath](from, to)) return promiseAllRejectLate(movePromises) @@ -428,10 +433,10 @@ module.exports = cls => class Reifier extends cls { // handled the most common cause of ENOENT (dir doesn't exist yet), // then just ignore any ENOENT. if (er.code === 'ENOENT') { - return didMkdirp ? null : mkdirp(dirname(to)).then(() => + return didMkdirp ? null : mkdir(dirname(to), { recursive: true }).then(() => this[_renamePath](from, to, true)) } else if (er.code === 'EEXIST') { - return rimraf(to).then(() => moveFile(from, to)) + return rm(to, { recursive: true, force: true }).then(() => moveFile(from, to)) } else { throw er } @@ -513,7 +518,7 @@ module.exports = cls => class Reifier extends cls { await this[_renamePath](d, retired) } } - const made = await mkdirp(node.path) + const made = await mkdir(node.path, { recursive: true }) this[_sparseTreeDirs].add(node.path) this[_sparseTreeRoots].add(made) })) @@ -528,13 +533,13 @@ module.exports = cls => class Reifier extends cls { const failures = [] const targets = [...roots, ...Object.keys(this[_retiredPaths])] const unlinks = targets - .map(path => rimraf(path).catch(er => failures.push([path, er]))) - return promiseAllRejectLate(unlinks) - .then(() => { - if (failures.length) { - this.log.warn('cleanup', 'Failed to remove some directories', failures) - } - }) + .map(path => rm(path, { recursive: true, force: true }).catch(er => failures.push([path, er]))) + return promiseAllRejectLate(unlinks).then(() => { + // eslint-disable-next-line promise/always-return + if (failures.length) { + log.warn('cleanup', 'Failed to remove some directories', failures) + } + }) .then(() => process.emit('timeEnd', 'reify:rollback:createSparse')) .then(() => this[_rollbackRetireShallowNodes](er)) } @@ -590,21 +595,21 @@ module.exports = cls => class Reifier extends cls { this.addTracker('reify', node.name, node.location) const { npmVersion, nodeVersion } = this.options - const p = Promise.resolve() - .then(async () => { - // when we reify an optional node, check the engine and platform - // first. be sure to ignore the --force and --engine-strict flags, - // since we always want to skip any optional packages we can't install. - // these checks throwing will result in a rollback and removal - // of the mismatches - if (node.optional) { - checkEngine(node.package, npmVersion, nodeVersion, false) - checkPlatform(node.package, false) - } - await this[_checkBins](node) - await this[_extractOrLink](node) - await this[_warnDeprecated](node) - }) + const p = Promise.resolve().then(async () => { + // when we reify an optional node, check the engine and platform + // first. be sure to ignore the --force and --engine-strict flags, + // since we always want to skip any optional packages we can't install. + // these checks throwing will result in a rollback and removal + // of the mismatches + // eslint-disable-next-line promise/always-return + if (node.optional) { + checkEngine(node.package, npmVersion, nodeVersion, false) + checkPlatform(node.package, false) + } + await this[_checkBins](node) + await this[_extractOrLink](node) + await this[_warnDeprecated](node) + }) return this[_handleOptionalFailure](node, p) .then(() => { @@ -624,8 +629,8 @@ module.exports = cls => class Reifier extends cls { this[_nmValidated].add(nm) return } - this.log.warn('reify', 'Removing non-directory', nm) - await rimraf(nm) + log.warn('reify', 'Removing non-directory', nm) + await rm(nm, { recursive: true, force: true }) } async [_extractOrLink] (node) { @@ -636,10 +641,15 @@ module.exports = cls => class Reifier extends cls { // and no 'bundled: true' setting. // Do the best with what we have, or else remove it from the tree // entirely, since we can't possibly reify it. - const res = node.resolved ? `${node.name}@${this[_registryResolved](node.resolved)}` - : node.packageName && node.version - ? `${node.packageName}@${node.version}` - : null + let res = null + if (node.resolved) { + const registryResolved = this[_registryResolved](node.resolved) + if (registryResolved) { + res = `${node.name}@${registryResolved}` + } + } else if (node.packageName && node.version) { + res = `${node.packageName}@${node.version}` + } // no idea what this thing is. remove it from the tree. if (!res) { @@ -647,8 +657,8 @@ module.exports = cls => class Reifier extends cls { 'please re-try this operation once it completes\n' + 'so that the damage can be corrected, or perform\n' + 'a fresh install with no lockfile if the problem persists.' - this.log.warn('reify', warning) - this.log.verbose('reify', 'unrecognized node in tree', node.path) + log.warn('reify', warning) + log.verbose('reify', 'unrecognized node in tree', node.path) node.parent = null node.fsParent = null this[_addNodeToTrashList](node) @@ -659,7 +669,7 @@ module.exports = cls => class Reifier extends cls { await this[_validateNodeModules](nm) if (node.isLink) { - await rimraf(node.path) + await rm(node.path, { recursive: true, force: true }) await this[_symlink](node) } else { await debug(async () => { @@ -674,6 +684,7 @@ module.exports = cls => class Reifier extends cls { }) await pacote.extract(res, node.path, { ...this.options, + Arborist: this.constructor, resolved: node.resolved, integrity: node.integrity, }) @@ -684,14 +695,14 @@ module.exports = cls => class Reifier extends cls { const dir = dirname(node.path) const target = node.realpath const rel = relative(dir, target) - await mkdirp(dir) + await mkdir(dir, { recursive: true }) return symlink(rel, node.path, 'junction') } [_warnDeprecated] (node) { const { _id, deprecated } = node.package if (deprecated) { - this.log.warn('deprecated', `${_id}: ${deprecated}`) + log.warn('deprecated', `${_id}: ${deprecated}`) } } @@ -701,7 +712,7 @@ module.exports = cls => class Reifier extends cls { return (node.optional ? p.catch(er => { const set = optionalSet(node) for (node of set) { - this.log.verbose('reify', 'failed optional dependency', node.path) + log.verbose('reify', 'failed optional dependency', node.path) this[_addNodeToTrashList](node) } }) : p).then(() => node) @@ -710,13 +721,27 @@ module.exports = cls => class Reifier extends cls { [_registryResolved] (resolved) { // the default registry url is a magic value meaning "the currently // configured registry". + // `resolved` must never be falsey. // // XXX: use a magic string that isn't also a valid value, like // ${REGISTRY} or something. This has to be threaded through the // Shrinkwrap and Node classes carefully, so for now, just treat // the default reg as the magical animal that it has been. - return resolved && resolved - .replace(/^https?:\/\/registry.npmjs.org\//, this.registry) + const resolvedURL = hgi.parseUrl(resolved) + + if (!resolvedURL) { + // if we could not parse the url at all then returning nothing + // here means it will get removed from the tree in the next step + return + } + + if ((this.options.replaceRegistryHost === resolvedURL.hostname) + || this.options.replaceRegistryHost === 'always') { + // this.registry always has a trailing slash + return `${this.registry.slice(0, -1)}${resolvedURL.pathname}${resolvedURL.searchParams}` + } + + return resolved } // bundles are *sort of* like shrinkwraps, in that the branch is defined @@ -908,9 +933,10 @@ module.exports = cls => class Reifier extends cls { } } - [_submitQuickAudit] () { + async [_submitQuickAudit] () { if (this.options.audit === false) { - return this.auditReport = null + this.auditReport = null + return } // we submit the quick audit at this point in the process, as soon as @@ -932,21 +958,15 @@ module.exports = cls => class Reifier extends cls { ) } - this.auditReport = AuditReport.load(tree, options) - .then(res => { - process.emit('timeEnd', 'reify:audit') - this.auditReport = res - }) - } - - // return the promise if we're waiting for it, or the replaced result - [_awaitQuickAudit] () { - return this.auditReport + this.auditReport = AuditReport.load(tree, options).then(res => { + process.emit('timeEnd', 'reify:audit') + return res + }) } // ok! actually unpack stuff into their target locations! // The sparse tree has already been created, so we walk the diff - // kicking off each unpack job. If any fail, we rimraf the sparse + // kicking off each unpack job. If any fail, we rm the sparse // tree entirely and try to put everything back where it was. [_unpackNewModules] () { process.emit('time', 'reify:unpack') @@ -1027,7 +1047,8 @@ module.exports = cls => class Reifier extends cls { return promiseAllRejectLate(diff.unchanged.map(node => { // no need to roll back links, since we'll just delete them anyway if (node.isLink) { - return mkdirp(dirname(node.path)).then(() => this[_reifyNode](node)) + return mkdir(dirname(node.path), { recursive: true, force: true }) + .then(() => this[_reifyNode](node)) } // will have been moved/unpacked along with bundler @@ -1043,7 +1064,7 @@ module.exports = cls => class Reifier extends cls { // skip it. const bd = node.package.bundleDependencies const dir = bd && bd.length ? node.path + '/node_modules' : node.path - return mkdirp(dir).then(() => this[_moveContents](node, fromPath)) + return mkdir(dir, { recursive: true }).then(() => this[_moveContents](node, fromPath)) })) })) .then(() => process.emit('timeEnd', 'reify:unretire')) @@ -1104,7 +1125,8 @@ module.exports = cls => class Reifier extends cls { // skip links that only live within node_modules as they are most // likely managed by packages we installed, we only want to rebuild // unchanged links we directly manage - if (node.isLink && node.target.fsTop === tree) { + const linkedFromRoot = node.parent === tree || node.target.fsTop === tree + if (node.isLink && linkedFromRoot) { nodes.push(node) } } @@ -1116,23 +1138,22 @@ module.exports = cls => class Reifier extends cls { // the tree is pretty much built now, so it's cleanup time. // remove the retired folders, and any deleted nodes // If this fails, there isn't much we can do but tell the user about it. - // Thankfully, it's pretty unlikely that it'll fail, since rimraf is a tank. - [_removeTrash] () { + // Thankfully, it's pretty unlikely that it'll fail, since rm is a node builtin. + async [_removeTrash] () { process.emit('time', 'reify:trash') const promises = [] const failures = [] - const rm = path => rimraf(path).catch(er => failures.push([path, er])) + const _rm = path => rm(path, { recursive: true, force: true }).catch(er => failures.push([path, er])) for (const path of this[_trashList]) { - promises.push(rm(path)) + promises.push(_rm(path)) } - return promiseAllRejectLate(promises).then(() => { - if (failures.length) { - this.log.warn('cleanup', 'Failed to remove some directories', failures) - } - }) - .then(() => process.emit('timeEnd', 'reify:trash')) + await promiseAllRejectLate(promises) + if (failures.length) { + log.warn('cleanup', 'Failed to remove some directories', failures) + } + process.emit('timeEnd', 'reify:trash') } // last but not least, we save the ideal tree metadata to the package-lock @@ -1224,14 +1245,23 @@ module.exports = cls => class Reifier extends cls { newSpec = h.shortcut(opt) } } else if (isLocalDep) { - // save the relative path in package.json - // Normally saveSpec is updated with the proper relative - // path already, but it's possible to specify a full absolute - // path initially, in which case we can end up with the wrong - // thing, so just get the ultimate fetchSpec and relativize it. - const p = req.fetchSpec.replace(/^file:/, '') - const rel = relpath(addTree.realpath, p) - newSpec = `file:${rel}` + // when finding workspace nodes, make sure that + // we save them using their version instead of + // using their relative path + if (edge.type === 'workspace') { + const { version } = edge.to.target + const prefixRange = version ? this[_savePrefix] + version : '*' + newSpec = prefixRange + } else { + // save the relative path in package.json + // Normally saveSpec is updated with the proper relative + // path already, but it's possible to specify a full absolute + // path initially, in which case we can end up with the wrong + // thing, so just get the ultimate fetchSpec and relativize it. + const p = req.fetchSpec.replace(/^file:/, '') + const rel = relpath(addTree.realpath, p).replace(/#/g, '%23') + newSpec = `file:${rel}` + } } else { newSpec = req.saveSpec } @@ -1284,7 +1314,9 @@ module.exports = cls => class Reifier extends cls { if (semver.subset(edge.spec, node.version)) { return false } - } catch {} + } catch { + // ignore errors + } } return true } @@ -1298,7 +1330,7 @@ module.exports = cls => class Reifier extends cls { // to only names that are found in this list const retrieveUpdatedNodes = names => { const filterDirectDependencies = node => - !node.isRoot && node.resolveParent.isRoot + !node.isRoot && node.resolveParent && node.resolveParent.isRoot && (!names || names.includes(node.name)) && exactVersion(node) // skip update for exact ranges @@ -1499,12 +1531,36 @@ module.exports = cls => class Reifier extends cls { this.idealTree.meta.filename = this.idealTree.realpath + '/node_modules/.package-lock.json' this.idealTree.meta.hiddenLockfile = true + this.idealTree.meta.lockfileVersion = defaultLockfileVersion this.actualTree = this.idealTree this.idealTree = null if (!this[_global]) { await this.actualTree.meta.save() + const ignoreScripts = !!this.options.ignoreScripts + // if we aren't doing a dry run or ignoring scripts and we actually made changes to the dep + // tree, then run the dependencies scripts + if (!this[_dryRun] && !ignoreScripts && this.diff && this.diff.children.length) { + const { path, package: pkg } = this.actualTree.target + const stdio = this.options.foregroundScripts ? 'inherit' : 'pipe' + const { scripts = {} } = pkg + for (const event of ['predependencies', 'dependencies', 'postdependencies']) { + if (Object.prototype.hasOwnProperty.call(scripts, event)) { + const timer = `reify:run:${event}` + process.emit('time', timer) + log.info('run', pkg._id, event, scripts[event]) + await runScript({ + event, + path, + pkg, + stdio, + scriptShell: this.options.scriptShell, + }) + process.emit('timeEnd', timer) + } + } + } } } } diff --git a/workspaces/arborist/lib/audit-report.js b/workspaces/arborist/lib/audit-report.js index b7d8249..387919f 100644 --- a/workspaces/arborist/lib/audit-report.js +++ b/workspaces/arborist/lib/audit-report.js @@ -13,7 +13,7 @@ const _fixAvailable = Symbol('fixAvailable') const _checkTopNode = Symbol('checkTopNode') const _init = Symbol('init') const _omit = Symbol('omit') -const procLog = require('proc-log') +const log = require('proc-log') const fetch = require('npm-registry-fetch') @@ -98,14 +98,13 @@ class AuditReport extends Map { this.calculator = new Calculator(opts) this.error = null this.options = opts - this.log = opts.log || procLog this.tree = tree this.filterSet = opts.filterSet } async run () { this.report = await this[_getReport]() - this.log.silly('audit report', this.report) + log.silly('audit report', this.report) if (this.report) { await this[_init]() } @@ -135,16 +134,7 @@ class AuditReport extends Map { const seen = new Set() for (const advisory of advisories) { const { name, range } = advisory - - // don't flag the exact same name/range more than once - // adding multiple advisories with the same range is fine, but no - // need to search for nodes we already would have added. const k = `${name}@${range}` - if (seen.has(k)) { - continue - } - - seen.add(k) const vuln = this.get(name) || new Vuln({ name, advisory }) if (this.has(name)) { @@ -152,44 +142,52 @@ class AuditReport extends Map { } super.set(name, vuln) - const p = [] - for (const node of this.tree.inventory.query('packageName', name)) { - if (!shouldAudit(node, this[_omit], this.filterSet)) { - continue - } + // don't flag the exact same name/range more than once + // adding multiple advisories with the same range is fine, but no + // need to search for nodes we already would have added. + if (!seen.has(k)) { + const p = [] + for (const node of this.tree.inventory.query('packageName', name)) { + if (!shouldAudit(node, this[_omit], this.filterSet)) { + continue + } - // if not vulnerable by this advisory, keep searching - if (!advisory.testVersion(node.version)) { - continue - } + // if not vulnerable by this advisory, keep searching + if (!advisory.testVersion(node.version)) { + continue + } - // we will have loaded the source already if this is a metavuln - if (advisory.type === 'metavuln') { - vuln.addVia(this.get(advisory.dependency)) - } + // we will have loaded the source already if this is a metavuln + if (advisory.type === 'metavuln') { + vuln.addVia(this.get(advisory.dependency)) + } - // already marked this one, no need to do it again - if (vuln.nodes.has(node)) { - continue - } + // already marked this one, no need to do it again + if (vuln.nodes.has(node)) { + continue + } - // haven't marked this one yet. get its dependents. - vuln.nodes.add(node) - for (const { from: dep, spec } of node.edgesIn) { - if (dep.isTop && !vuln.topNodes.has(dep)) { - this[_checkTopNode](dep, vuln, spec) - } else { + // haven't marked this one yet. get its dependents. + vuln.nodes.add(node) + for (const { from: dep, spec } of node.edgesIn) { + if (dep.isTop && !vuln.topNodes.has(dep)) { + this[_checkTopNode](dep, vuln, spec) + } else { // calculate a metavuln, if necessary - const calc = this.calculator.calculate(dep.packageName, advisory) - p.push(calc.then(meta => { - if (meta.testVersion(dep.version, spec)) { - advisories.add(meta) - } - })) + const calc = this.calculator.calculate(dep.packageName, advisory) + // eslint-disable-next-line promise/always-return + p.push(calc.then(meta => { + // eslint-disable-next-line promise/always-return + if (meta.testVersion(dep.version, spec)) { + advisories.add(meta) + } + })) + } } } + await Promise.all(p) + seen.add(k) } - await Promise.all(p) // make sure we actually got something. if not, remove it // this can happen if you are loading from a lockfile created by @@ -313,7 +311,7 @@ class AuditReport extends Map { try { // first try the super fast bulk advisory listing const body = prepareBulkData(this.tree, this[_omit], this.filterSet) - this.log.silly('audit', 'bulk request', body) + log.silly('audit', 'bulk request', body) // no sense asking if we don't have anything to audit, // we know it'll be empty @@ -331,7 +329,7 @@ class AuditReport extends Map { return await res.json() } catch (er) { - this.log.silly('audit', 'bulk request failed', String(er.body)) + log.silly('audit', 'bulk request failed', String(er.body)) // that failed, try the quick audit endpoint const body = prepareData(this.tree, this.options) const res = await fetch('/-/npm/v1/security/audits/quick', { @@ -344,8 +342,8 @@ class AuditReport extends Map { return AuditReport.auditToBulk(await res.json()) } } catch (er) { - this.log.verbose('audit error', er) - this.log.silly('audit error', String(er.body)) + log.verbose('audit error', er) + log.silly('audit error', String(er.body)) this.error = er return null } finally { diff --git a/workspaces/arborist/lib/consistent-resolve.js b/workspaces/arborist/lib/consistent-resolve.js index e34e40a..7c98804 100644 --- a/workspaces/arborist/lib/consistent-resolve.js +++ b/workspaces/arborist/lib/consistent-resolve.js @@ -19,17 +19,23 @@ const consistentResolve = (resolved, fromPath, toPath, relPaths = false) => { rawSpec, raw, } = npa(resolved, fromPath) - const isPath = type === 'file' || type === 'directory' - return isPath && !relPaths ? `file:${fetchSpec}` - : isPath ? 'file:' + (toPath ? relpath(toPath, fetchSpec) : fetchSpec) - : hosted ? `git+${ - hosted.auth ? hosted.https(hostedOpt) : hosted.sshurl(hostedOpt) - }` - : type === 'git' ? saveSpec - // always return something. 'foo' is interpreted as 'foo@' otherwise. - : rawSpec === '' && raw.slice(-1) !== '@' ? raw - // just strip off the name, but otherwise return as-is - : rawSpec + if (type === 'file' || type === 'directory') { + const cleanFetchSpec = fetchSpec.replace(/#/g, '%23') + if (relPaths && toPath) { + return `file:${relpath(toPath, cleanFetchSpec)}` + } + return `file:${cleanFetchSpec}` + } + if (hosted) { + return `git+${hosted.auth ? hosted.https(hostedOpt) : hosted.sshurl(hostedOpt)}` + } + if (type === 'git') { + return saveSpec + } + if (rawSpec === '*') { + return raw + } + return rawSpec } catch (_) { // whatever we passed in was not acceptable to npa. // leave it 100% untouched. diff --git a/workspaces/arborist/lib/dep-valid.js b/workspaces/arborist/lib/dep-valid.js index 2c837ae..9c1bc7d 100644 --- a/workspaces/arborist/lib/dep-valid.js +++ b/workspaces/arborist/lib/dep-valid.js @@ -20,7 +20,7 @@ const depValid = (child, requested, requestor) => { // file: deps that depend on other files/dirs, we must resolve the // location based on the *requestor* file/dir, not where it ends up. // '' is equivalent to '*' - requested = npa.resolve(child.name, requested || '*', fromPath(requestor)) + requested = npa.resolve(child.name, requested || '*', fromPath(requestor, requestor.edgesOut.get(child.name))) } catch (er) { // Not invalid because the child doesn't match, but because // the spec itself is not supported. Nothing would match, @@ -53,9 +53,7 @@ const depValid = (child, requested, requestor) => { return semver.satisfies(child.version, requested.fetchSpec, true) case 'directory': - // directory must be a link to the specified folder - return !!child.isLink && - relative(child.realpath, requested.fetchSpec) === '' + return linkValid(child, requested, requestor) case 'file': return tarballValid(child, requested, requestor) @@ -108,6 +106,18 @@ const depValid = (child, requested, requestor) => { return false } +const linkValid = (child, requested, requestor) => { + const isLink = !!child.isLink + // if we're installing links and the node is a link, then it's invalid because we want + // a real node to be there. Except for workspaces. They are always links. + if (requestor.installLinks && !child.isWorkspace) { + return !isLink + } + + // directory must be a link to the specified folder + return isLink && relative(child.realpath, requested.fetchSpec) === '' +} + const tarballValid = (child, requested, requestor) => { if (child.isLink) { return false diff --git a/workspaces/arborist/lib/edge.js b/workspaces/arborist/lib/edge.js index 87439e7..84078ba 100644 --- a/workspaces/arborist/lib/edge.js +++ b/workspaces/arborist/lib/edge.js @@ -92,7 +92,12 @@ class Edge { return false } - return depValid(node, this.spec, this.accept, this.from) + // NOTE: this condition means we explicitly do not support overriding + // bundled or shrinkwrapped dependencies + const spec = (node.hasShrinkwrap || node.inShrinkwrap || node.inBundle) + ? this.rawSpec + : this.spec + return depValid(node, spec, this.accept, this.from) } explain (seen = []) { @@ -161,10 +166,14 @@ class Edge { } get spec () { - if (this.overrides && this.overrides.value && this.overrides.name === this.name) { + if (this.overrides?.value && this.overrides.value !== '*' && this.overrides.name === this.name) { if (this.overrides.value.startsWith('$')) { const ref = this.overrides.value.slice(1) - const pkg = this.from.root.package + // we may be a virtual root, if we are we want to resolve reference overrides + // from the real root, not the virtual one + const pkg = this.from.sourceReference + ? this.from.sourceReference.root.package + : this.from.root.package const overrideSpec = (pkg.devDependencies && pkg.devDependencies[ref]) || (pkg.optionalDependencies && pkg.optionalDependencies[ref]) || (pkg.dependencies && pkg.dependencies[ref]) || @@ -215,6 +224,11 @@ class Edge { reload (hard = false) { this[_explanation] = null + if (this[_from].overrides) { + this.overrides = this[_from].overrides.getEdgeRule(this) + } else { + delete this.overrides + } const newTo = this[_from].resolve(this.name) if (newTo !== this[_to]) { if (this[_to]) { diff --git a/workspaces/arborist/lib/from-path.js b/workspaces/arborist/lib/from-path.js index 2a36178..1006f73 100644 --- a/workspaces/arborist/lib/from-path.js +++ b/workspaces/arborist/lib/from-path.js @@ -6,8 +6,19 @@ const { dirname } = require('path') const npa = require('npm-package-arg') -const fromPath = (node, spec) => - spec && spec.type === 'file' ? dirname(spec.fetchSpec) - : node.realpath +const fromPath = (node, spec, edge) => { + if (edge && edge.overrides && edge.overrides.name === edge.name && edge.overrides.value) { + // fromPath could be called with a node that has a virtual root, if that happens + // we want to make sure we get the real root node when overrides are in use. this + // is to allow things like overriding a dependency with a tarball file that's a + // relative path from the project root + return node.sourceReference + ? node.sourceReference.root.realpath + : node.root.realpath + } -module.exports = node => fromPath(node, node.resolved && npa(node.resolved)) + return spec && spec.type === 'file' ? dirname(spec.fetchSpec) + : node.realpath +} + +module.exports = (node, edge) => fromPath(node, node.resolved && npa(node.resolved), edge) diff --git a/workspaces/arborist/lib/get-workspace-nodes.js b/workspaces/arborist/lib/get-workspace-nodes.js index 6db489f..91002da 100644 --- a/workspaces/arborist/lib/get-workspace-nodes.js +++ b/workspaces/arborist/lib/get-workspace-nodes.js @@ -1,7 +1,10 @@ // Get the actual nodes corresponding to a root node's child workspaces, // given a list of workspace names. + +const log = require('proc-log') const relpath = require('./relpath.js') -const getWorkspaceNodes = (tree, workspaces, log) => { + +const getWorkspaceNodes = (tree, workspaces) => { const wsMap = tree.workspaces if (!wsMap) { log.warn('workspaces', 'filter set, but no workspaces present') diff --git a/workspaces/arborist/lib/link.js b/workspaces/arborist/lib/link.js index dcce8c0..ebdbc94 100644 --- a/workspaces/arborist/lib/link.js +++ b/workspaces/arborist/lib/link.js @@ -1,4 +1,3 @@ -const debug = require('./debug.js') const relpath = require('./relpath.js') const Node = require('./node.js') const _loadDeps = Symbol.for('Arborist.Node._loadDeps') @@ -53,26 +52,6 @@ class Link extends Node { return } - if (current && current.then) { - debug(() => { - throw Object.assign(new Error('cannot set target while awaiting'), { - path: this.path, - realpath: this.realpath, - }) - }) - } - - if (target && target.then) { - // can set to a promise during an async tree build operation - // wait until then to assign it. - this[_target] = target - target.then(node => { - this[_target] = null - this.target = node - }) - return - } - if (!target) { if (current && current.linksIn) { current.linksIn.delete(this) @@ -118,7 +97,7 @@ class Link extends Node { // the path/realpath guard is there for the benefit of setting // these things in the "wrong" order return this.path && this.realpath - ? `file:${relpath(dirname(this.path), this.realpath)}` + ? `file:${relpath(dirname(this.path), this.realpath).replace(/#/g, '%23')}` : null } diff --git a/workspaces/arborist/lib/node.js b/workspaces/arborist/lib/node.js index 45c288b..b90a2ac 100644 --- a/workspaces/arborist/lib/node.js +++ b/workspaces/arborist/lib/node.js @@ -69,6 +69,8 @@ const consistentResolve = require('./consistent-resolve.js') const printableTree = require('./printable.js') const CaseInsensitiveMap = require('./case-insensitive-map.js') +const querySelectorAll = require('./query-selector-all.js') + class Node { constructor (options) { // NB: path can be null if it's a link target @@ -86,6 +88,7 @@ class Node { name, children, fsChildren, + installLinks = false, legacyPeerDeps = false, linksIn, hasShrinkwrap, @@ -100,6 +103,9 @@ class Node { dummy = false, sourceReference = null, } = options + // this object gives querySelectorAll somewhere to stash context about a node + // while processing a query + this.queryContext = {} // true if part of a global install this[_global] = global @@ -152,6 +158,7 @@ class Node { } this.integrity = integrity || pkg._integrity || null this.hasShrinkwrap = hasShrinkwrap || pkg._hasShrinkwrap || false + this.installLinks = installLinks this.legacyPeerDeps = legacyPeerDeps this.children = new CaseInsensitiveMap() @@ -330,6 +337,10 @@ class Node { return `${myname}@${alias}${version}` } + get overridden () { + return !!(this.overrides && this.overrides.value && this.overrides.name === this.name) + } + get package () { return this[_package] } @@ -522,6 +533,18 @@ class Node { return this === this.root || this === this.root.target } + get isRegistryDependency () { + if (this.edgesIn.size === 0) { + return false + } + for (const edge of this.edgesIn) { + if (!npa(edge.spec).registry) { + return false + } + } + return true + } + * ancestry () { for (let anc = this; anc; anc = anc.resolveParent) { yield anc @@ -544,7 +567,8 @@ class Node { // this allows us to do new Node({...}) and then set the root later. // just make the assignment so we don't lose it, and move on. if (!this.path || !root.realpath || !root.path) { - return this[_root] = root + this[_root] = root + return } // temporarily become a root node @@ -792,6 +816,9 @@ class Node { target.root = root } + if (!this.overrides && this.parent && this.parent.overrides) { + this.overrides = this.parent.overrides.getNodeRule(this) + } // tree should always be valid upon root setter completion. treeCheck(this) treeCheck(root) @@ -807,7 +834,7 @@ class Node { } for (const [name, path] of this[_workspaces].entries()) { - new Edge({ from: this, name, spec: `file:${path}`, type: 'workspace' }) + new Edge({ from: this, name, spec: `file:${path.replace(/#/g, '%23')}`, type: 'workspace' }) } } @@ -1146,6 +1173,9 @@ class Node { for (const kid of node.children.values()) { kid.parent = this } + if (node.isLink && node.target) { + node.target.root = null + } } if (!node.isRoot) { @@ -1426,6 +1456,12 @@ class Node { return base === name && basename(nm) === 'node_modules' ? dir : false } + // maybe accept both string value or array of strings + // seems to be what dom API does + querySelectorAll (query, opts) { + return querySelectorAll(this, query, opts) + } + toJSON () { return printableTree(this) } diff --git a/workspaces/arborist/lib/override-resolves.js b/workspaces/arborist/lib/override-resolves.js new file mode 100644 index 0000000..794b2c3 --- /dev/null +++ b/workspaces/arborist/lib/override-resolves.js @@ -0,0 +1,11 @@ +function overrideResolves (resolved, opts = {}) { + const { omitLockfileRegistryResolved = false } = opts + + if (omitLockfileRegistryResolved) { + return undefined + } + + return resolved +} + +module.exports = { overrideResolves } diff --git a/workspaces/arborist/lib/override-set.js b/workspaces/arborist/lib/override-set.js index e2e04e0..742e3f0 100644 --- a/workspaces/arborist/lib/override-set.js +++ b/workspaces/arborist/lib/override-set.js @@ -25,7 +25,7 @@ class OverrideSet { this.name = spec.name spec.name = '' this.key = key - this.keySpec = spec.rawSpec === '' ? '' : spec.toString() + this.keySpec = spec.toString() this.value = overrides['.'] || this.keySpec } @@ -50,8 +50,7 @@ class OverrideSet { continue } - if (rule.keySpec === '' || - semver.intersects(edge.spec, rule.keySpec)) { + if (semver.intersects(edge.spec, rule.keySpec)) { return rule } } @@ -65,8 +64,7 @@ class OverrideSet { continue } - if (rule.keySpec === '' || - semver.satisfies(node.version, rule.keySpec) || + if (semver.satisfies(node.version, rule.keySpec) || semver.satisfies(node.version, rule.value)) { return rule } @@ -81,8 +79,7 @@ class OverrideSet { continue } - if (rule.keySpec === '' || - semver.satisfies(node.version, rule.keySpec) || + if (semver.satisfies(node.version, rule.keySpec) || semver.satisfies(node.version, rule.value)) { return rule } diff --git a/workspaces/arborist/lib/place-dep.js b/workspaces/arborist/lib/place-dep.js index c0cbe91..16a0095 100644 --- a/workspaces/arborist/lib/place-dep.js +++ b/workspaces/arborist/lib/place-dep.js @@ -23,72 +23,39 @@ const peerEntrySets = require('./peer-entry-sets.js') class PlaceDep { constructor (options) { - const { - dep, - edge, - parent = null, - } = options - this.name = edge.name - this.dep = dep - this.edge = edge + this.auditReport = options.auditReport + this.dep = options.dep + this.edge = options.edge + this.explicitRequest = options.explicitRequest + this.force = options.force + this.installLinks = options.installLinks + this.installStrategy = options.installStrategy + this.legacyPeerDeps = options.legacyPeerDeps + this.parent = options.parent || null + this.preferDedupe = options.preferDedupe + this.strictPeerDeps = options.strictPeerDeps + this.updateNames = options.updateNames + this.canPlace = null - - this.target = null - this.placed = null - - // inherit all these fields from the parent to ensure consistency. - const { - preferDedupe, - force, - explicitRequest, - updateNames, - auditReport, - legacyBundling, - strictPeerDeps, - legacyPeerDeps, - globalStyle, - } = parent || options - Object.assign(this, { - preferDedupe, - force, - explicitRequest, - updateNames, - auditReport, - legacyBundling, - strictPeerDeps, - legacyPeerDeps, - globalStyle, - }) - - this.children = [] - this.parent = parent - this.peerConflict = null - - this.needEvaluation = new Set() - + this.canPlaceSelf = null + // XXX this only appears to be used by tests this.checks = new Map() + this.children = [] + this.needEvaluation = new Set() + this.peerConflict = null + this.placed = null + this.target = null - this.place() - } - - place () { - const { - edge, - dep, - preferDedupe, - globalStyle, - legacyBundling, - explicitRequest, - updateNames, - checks, - } = this + this.current = this.edge.to + this.name = this.edge.name + this.top = this.parent?.top || this // nothing to do if the edge is fine as it is - if (edge.to && - !edge.error && - !explicitRequest && - !updateNames.includes(edge.name) && - !this.isVulnerable(edge.to)) { + if (this.edge.to && + !this.edge.error && + !this.explicitRequest && + !this.updateNames.includes(this.edge.name) && + !this.auditReport?.isVulnerable(this.edge.to)) { return } @@ -96,8 +63,6 @@ class PlaceDep { // where the dep is not a peer dep. const start = this.getStartNode() - let canPlace = null - let canPlaceSelf = null for (const target of start.ancestry()) { // if the current location has a peerDep on it, then we can't place here // this is pretty rare to hit, since we always prefer deduping peers, @@ -113,14 +78,14 @@ class PlaceDep { // Then we check under b, and can't, because of the optional peer dep. // but we CAN place it under a, so the correct thing to do is keep // walking up the tree. - const targetEdge = target.edgesOut.get(edge.name) + const targetEdge = target.edgesOut.get(this.edge.name) if (!target.isTop && targetEdge && targetEdge.peer) { continue } const cpd = new CanPlaceDep({ - dep, - edge, + dep: this.dep, + edge: this.edge, // note: this sets the parent's canPlace as the parent of this // canPlace, but it does NOT add this canPlace to the parent's // children. This way, we can know that it's a peer dep, and @@ -128,10 +93,10 @@ class PlaceDep { // tree of checks that factored into the original decision. parent: this.parent && this.parent.canPlace, target, - preferDedupe, + preferDedupe: this.preferDedupe, explicitRequest: this.explicitRequest, }) - checks.set(target, cpd) + this.checks.set(target, cpd) // It's possible that a "conflict" is a conflict among the *peers* of // a given node we're trying to place, but there actually is no current @@ -147,13 +112,13 @@ class PlaceDep { // where they did not themselves conflict, and skip c@2 if conflict // is ok by virtue of being forced or not ours and not strict. if (cpd.canPlaceSelf !== CONFLICT) { - canPlaceSelf = cpd + this.canPlaceSelf = cpd } // we found a place this can go, along with all its peer friends. // we break when we get the first conflict if (cpd.canPlace !== CONFLICT) { - canPlace = cpd + this.canPlace = cpd } else { break } @@ -162,19 +127,19 @@ class PlaceDep { // since we're going to crash the build or prune it out anyway. // but, this will frequently NOT be a successful canPlace, because // it'll have no version or other information. - if (dep.errors.length) { + if (this.dep.errors.length) { break } // nest packages like npm v1 and v2 // very disk-inefficient - if (legacyBundling) { + if (this.installStrategy === 'nested') { break } // when installing globally, or just in global style, we never place // deps above the first level. - if (globalStyle) { + if (this.installStrategy === 'shallow') { const rp = target.resolveParent if (rp && rp.isProjectRoot) { break @@ -182,18 +147,12 @@ class PlaceDep { } } - Object.assign(this, { - canPlace, - canPlaceSelf, - }) - this.current = edge.to - // if we can't find a target, that means that the last place checked, // and all the places before it, had a conflict. - if (!canPlace) { - // if not forced, or it's our dep, or strictPeerDeps is set, then + if (!this.canPlace) { + // if not forced, and it's our dep, or strictPeerDeps is set, then // this is an ERESOLVE error. - if (!this.conflictOk) { + if (!this.force && (this.isMine || this.strictPeerDeps)) { return this.failPeerConflict() } @@ -201,54 +160,45 @@ class PlaceDep { // if we have a current, then we treat CONFLICT as a KEEP. // otherwise, we just skip it. Only warn on the one that actually // could not be placed somewhere. - if (!canPlaceSelf) { + if (!this.canPlaceSelf) { this.warnPeerConflict() return } - this.canPlace = canPlaceSelf + this.canPlace = this.canPlaceSelf } // now we have a target, a tree of CanPlaceDep results for the peer group, // and we are ready to go - this.placeInTree() - } - - placeInTree () { - const { - dep, - canPlace, - edge, - } = this /* istanbul ignore next */ - if (!canPlace) { + if (!this.canPlace) { debug(() => { throw new Error('canPlace not set, but trying to place in tree') }) return } - const { target } = canPlace + const { target } = this.canPlace log.silly( 'placeDep', target.location || 'ROOT', - `${dep.name}@${dep.version}`, - canPlace.description, + `${this.dep.name}@${this.dep.version}`, + this.canPlace.description, `for: ${this.edge.from.package._id || this.edge.from.location}`, - `want: ${edge.spec || '*'}` + `want: ${this.edge.spec || '*'}` ) - const placementType = canPlace.canPlace === CONFLICT - ? canPlace.canPlaceSelf - : canPlace.canPlace + const placementType = this.canPlace.canPlace === CONFLICT + ? this.canPlace.canPlaceSelf + : this.canPlace.canPlace // if we're placing in the tree with --force, we can get here even though // it's a conflict. Treat it as a KEEP, but warn and move on. if (placementType === KEEP) { // this was a peerConflicted peer dep - if (edge.peer && !edge.valid) { + if (this.edge.peer && !this.edge.valid) { this.warnPeerConflict() } @@ -277,7 +227,7 @@ class PlaceDep { // instead of nesting forever, when the loop occurs, create // a symbolic link to the earlier instance for (let p = target; p; p = p.resolveParent) { - if (p.matches(dep) && !p.isTop) { + if (p.matches(this.dep) && !p.isTop) { this.placed = new Link({ parent: target, target: p }) return } @@ -287,16 +237,17 @@ class PlaceDep { // remove any that are not being replaced and will now be invalid, and // re-evaluate them deeper into the tree. - const virtualRoot = dep.parent - this.placed = new dep.constructor({ - name: dep.name, - pkg: dep.package, - resolved: dep.resolved, - integrity: dep.integrity, + const virtualRoot = this.dep.parent + this.placed = new this.dep.constructor({ + name: this.dep.name, + pkg: this.dep.package, + resolved: this.dep.resolved, + integrity: this.dep.integrity, + installLinks: this.installLinks, legacyPeerDeps: this.legacyPeerDeps, - error: dep.errors[0], - ...(dep.overrides ? { overrides: dep.overrides } : {}), - ...(dep.isLink ? { target: dep.target, realpath: dep.realpath } : {}), + error: this.dep.errors[0], + ...(this.dep.overrides ? { overrides: this.dep.overrides } : {}), + ...(this.dep.isLink ? { target: this.dep.target, realpath: this.dep.realpath } : {}), }) this.oldDep = target.children.get(this.name) @@ -307,7 +258,7 @@ class PlaceDep { } // if it's a peerConflicted peer dep, warn about it - if (edge.peer && !this.placed.satisfies(edge)) { + if (this.edge.peer && !this.placed.satisfies(this.edge)) { this.warnPeerConflict() } @@ -315,8 +266,8 @@ class PlaceDep { // MAY end up putting a better/identical node further up the tree in // a way that causes an unnecessary duplication. If so, remove the // now-unnecessary node. - if (edge.valid && edge.to && edge.to !== this.placed) { - this.pruneDedupable(edge.to, false) + if (this.edge.valid && this.edge.to && this.edge.to !== this.placed) { + this.pruneDedupable(this.edge.to, false) } // in case we just made some duplicates that can be removed, @@ -360,6 +311,15 @@ class PlaceDep { } this.children.push(new PlaceDep({ + auditReport: this.auditReport, + explicitRequest: this.explicitRequest, + force: this.force, + installLinks: this.installLinks, + installStrategy: this.installStrategy, + legacyPeerDeps: this.legaycPeerDeps, + preferDedupe: this.preferDedupe, + strictPeerDeps: this.strictPeerDeps, + updateNames: this.updateName, parent: this, dep: peer, node: this.placed, @@ -460,7 +420,7 @@ class PlaceDep { // prune all the nodes in a branch of the tree that can be safely removed // This is only the most basic duplication detection; it finds if there // is another satisfying node further up the tree, and if so, dedupes. - // Even in legacyBundling mode, we do this amount of deduplication. + // Even in installStategy is nested, we do this amount of deduplication. pruneDedupable (node, descend = true) { if (node.canDedupe(this.preferDedupe)) { // gather up all deps that have no valid edges in from outside @@ -492,10 +452,6 @@ class PlaceDep { } } - get conflictOk () { - return this.force || (!this.isMine && !this.strictPeerDeps) - } - get isMine () { const { edge } = this.top const { from: node } = edge @@ -550,10 +506,15 @@ class PlaceDep { const { from: node } = edge const curNode = node.resolve(edge.name) + // XXX decorate more with this.canPlace and this.canPlaceSelf, + // this.checks, this.children, walk over conflicted peers, etc. const expl = { code: 'ERESOLVE', edge: edge.explain(), dep: dep.explain(edge), + force: this.force, + isMine: this.isMine, + strictPeerDeps: this.strictPeerDeps, } if (this.parent) { @@ -582,37 +543,17 @@ class PlaceDep { } } - const { - strictPeerDeps, - force, - isMine, - } = this - Object.assign(expl, { - strictPeerDeps, - force, - isMine, - }) - - // XXX decorate more with this.canPlace and this.canPlaceSelf, - // this.checks, this.children, walk over conflicted peers, etc. return expl } getStartNode () { - // if we are a peer, then we MUST be at least as shallow as the - // peer dependent - const from = this.parent ? this.parent.getStartNode() : this.edge.from + // if we are a peer, then we MUST be at least as shallow as the peer + // dependent + const from = this.parent?.getStartNode() || this.edge.from return deepestNestingTarget(from, this.name) } - get top () { - return this.parent ? this.parent.top : this - } - - isVulnerable (node) { - return this.auditReport && this.auditReport.isVulnerable(node) - } - + // XXX this only appears to be used by tests get allChildren () { const set = new Set(this.children) for (const child of set) { diff --git a/workspaces/arborist/lib/query-selector-all.js b/workspaces/arborist/lib/query-selector-all.js new file mode 100644 index 0000000..5d21c92 --- /dev/null +++ b/workspaces/arborist/lib/query-selector-all.js @@ -0,0 +1,850 @@ +'use strict' + +const { resolve } = require('path') +const { parser, arrayDelimiter } = require('@npmcli/query') +const localeCompare = require('@isaacs/string-locale-compare')('en') +const log = require('proc-log') +const minimatch = require('minimatch') +const npa = require('npm-package-arg') +const pacote = require('pacote') +const semver = require('semver') + +// handle results for parsed query asts, results are stored in a map that has a +// key that points to each ast selector node and stores the resulting array of +// arborist nodes as its value, that is essential to how we handle multiple +// query selectors, e.g: `#a, #b, #c` <- 3 diff ast selector nodes +class Results { + #currentAstSelector + #initialItems + #inventory + #outdatedCache = new Map() + #pendingCombinator + #results = new Map() + #targetNode + + constructor (opts) { + this.#currentAstSelector = opts.rootAstNode.nodes[0] + this.#inventory = opts.inventory + this.#initialItems = opts.initialItems + this.#targetNode = opts.targetNode + + this.currentResults = this.#initialItems + + // We get this when first called and need to pass it to pacote + this.flatOptions = opts.flatOptions || {} + + // reset by rootAstNode walker + this.currentAstNode = opts.rootAstNode + } + + get currentResults () { + return this.#results.get(this.#currentAstSelector) + } + + set currentResults (value) { + this.#results.set(this.#currentAstSelector, value) + } + + // retrieves the initial items to which start the filtering / matching + // for most of the different types of recognized ast nodes, e.g: class (aka + // depType), id, *, etc in different contexts we need to start with the + // current list of filtered results, for example a query for `.workspace` + // actually means the same as `*.workspace` so we want to start with the full + // inventory if that's the first ast node we're reading but if it appears in + // the middle of a query it should respect the previous filtered results, + // combinators are a special case in which we always want to have the + // complete inventory list in order to use the left-hand side ast node as a + // filter combined with the element on its right-hand side + get initialItems () { + const firstParsed = + (this.currentAstNode.parent.nodes[0] === this.currentAstNode) && + (this.currentAstNode.parent.parent.type === 'root') + + if (firstParsed) { + return this.#initialItems + } + + if (this.currentAstNode.prev().type === 'combinator') { + return this.#inventory + } + return this.currentResults + } + + // combinators need information about previously filtered items along + // with info of the items parsed / retrieved from the selector right + // past the combinator, for this reason combinators are stored and + // only ran as the last part of each selector logic + processPendingCombinator (nextResults) { + if (this.#pendingCombinator) { + const res = this.#pendingCombinator(this.currentResults, nextResults) + this.#pendingCombinator = null + this.currentResults = res + } else { + this.currentResults = nextResults + } + } + + // when collecting results to a root astNode, we traverse the list of child + // selector nodes and collect all of their resulting arborist nodes into a + // single/flat Set of items, this ensures we also deduplicate items + collect (rootAstNode) { + return new Set(rootAstNode.nodes.flatMap(n => this.#results.get(n))) + } + + // selector types map to the '.type' property of the ast nodes via `${astNode.type}Type` + // + // attribute selector [name=value], etc + attributeType () { + const nextResults = this.initialItems.filter(node => + attributeMatch(this.currentAstNode, node.package) + ) + this.processPendingCombinator(nextResults) + } + + // dependency type selector (i.e. .prod, .dev, etc) + // css calls this class, we interpret is as dependency type + classType () { + const depTypeFn = depTypes[String(this.currentAstNode)] + if (!depTypeFn) { + throw Object.assign( + new Error(`\`${String(this.currentAstNode)}\` is not a supported dependency type.`), + { code: 'EQUERYNODEPTYPE' } + ) + } + const nextResults = depTypeFn(this.initialItems) + this.processPendingCombinator(nextResults) + } + + // combinators (i.e. '>', ' ', '~') + combinatorType () { + this.#pendingCombinator = combinators[String(this.currentAstNode)] + } + + // name selectors (i.e. #foo) + // css calls this id, we interpret it as name + idType () { + const name = this.currentAstNode.value + const nextResults = this.initialItems.filter(node => + (name === node.name) || (name === node.package.name) + ) + this.processPendingCombinator(nextResults) + } + + // pseudo selectors (prefixed with :) + async pseudoType () { + const pseudoFn = `${this.currentAstNode.value.slice(1)}Pseudo` + if (!this[pseudoFn]) { + throw Object.assign( + new Error(`\`${this.currentAstNode.value + }\` is not a supported pseudo selector.`), + { code: 'EQUERYNOPSEUDO' } + ) + } + const nextResults = await this[pseudoFn]() + this.processPendingCombinator(nextResults) + } + + selectorType () { + this.#currentAstSelector = this.currentAstNode + // starts a new array in which resulting items + // can be stored for each given ast selector + if (!this.currentResults) { + this.currentResults = [] + } + } + + universalType () { + this.processPendingCombinator(this.initialItems) + } + + // pseudo selectors map to the 'value' property of the pseudo selectors in the ast nodes + // via selectors via `${value.slice(1)}Pseudo` + attrPseudo () { + const { lookupProperties, attributeMatcher } = this.currentAstNode + + return this.initialItems.filter(node => { + let objs = [node.package] + for (const prop of lookupProperties) { + // if an isArray symbol is found that means we'll need to iterate + // over the previous found array to basically make sure we traverse + // all its indexes testing for possible objects that may eventually + // hold more keys specified in a selector + if (prop === arrayDelimiter) { + objs = objs.flat() + continue + } + + // otherwise just maps all currently found objs + // to the next prop from the lookup properties list, + // filters out any empty key lookup + objs = objs.flatMap(obj => obj[prop] || []) + + // in case there's no property found in the lookup + // just filters that item out + const noAttr = objs.every(obj => !obj) + if (noAttr) { + return false + } + } + + // if any of the potential object matches + // that item should be in the final result + return objs.some(obj => attributeMatch(attributeMatcher, obj)) + }) + } + + emptyPseudo () { + return this.initialItems.filter(node => node.edgesOut.size === 0) + } + + extraneousPseudo () { + return this.initialItems.filter(node => node.extraneous) + } + + async hasPseudo () { + const found = [] + for (const item of this.initialItems) { + // This is the one time initialItems differs from inventory + const res = await retrieveNodesFromParsedAst({ + flatOptions: this.flatOptions, + initialItems: [item], + inventory: this.#inventory, + rootAstNode: this.currentAstNode.nestedNode, + targetNode: item, + }) + if (res.size > 0) { + found.push(item) + } + } + return found + } + + invalidPseudo () { + const found = [] + for (const node of this.initialItems) { + for (const edge of node.edgesIn) { + if (edge.invalid) { + found.push(node) + break + } + } + } + return found + } + + async isPseudo () { + const res = await retrieveNodesFromParsedAst({ + flatOptions: this.flatOptions, + initialItems: this.initialItems, + inventory: this.#inventory, + rootAstNode: this.currentAstNode.nestedNode, + targetNode: this.currentAstNode, + }) + return [...res] + } + + linkPseudo () { + return this.initialItems.filter(node => node.isLink || (node.isTop && !node.isRoot)) + } + + missingPseudo () { + return this.#inventory.reduce((res, node) => { + for (const edge of node.edgesOut.values()) { + if (edge.missing) { + const pkg = { name: edge.name, version: edge.spec } + res.push(new this.#targetNode.constructor({ pkg })) + } + } + return res + }, []) + } + + async notPseudo () { + const res = await retrieveNodesFromParsedAst({ + flatOptions: this.flatOptions, + initialItems: this.initialItems, + inventory: this.#inventory, + rootAstNode: this.currentAstNode.nestedNode, + targetNode: this.currentAstNode, + }) + const internalSelector = new Set(res) + return this.initialItems.filter(node => + !internalSelector.has(node)) + } + + overriddenPseudo () { + return this.initialItems.filter(node => node.overridden) + } + + pathPseudo () { + return this.initialItems.filter(node => { + if (!this.currentAstNode.pathValue) { + return true + } + return minimatch( + node.realpath.replace(/\\+/g, '/'), + resolve(node.root.realpath, this.currentAstNode.pathValue).replace(/\\+/g, '/') + ) + }) + } + + privatePseudo () { + return this.initialItems.filter(node => node.package.private) + } + + rootPseudo () { + return this.initialItems.filter(node => node === this.#targetNode.root) + } + + scopePseudo () { + return this.initialItems.filter(node => node === this.#targetNode) + } + + semverPseudo () { + const { + attributeMatcher, + lookupProperties, + semverFunc = 'infer', + semverValue, + } = this.currentAstNode + const { qualifiedAttribute } = attributeMatcher + + if (!semverValue) { + // DEPRECATED: remove this warning and throw an error as part of @npmcli/arborist@6 + log.warn('query', 'usage of :semver() with no parameters is deprecated') + return this.initialItems + } + + if (!semver.valid(semverValue) && !semver.validRange(semverValue)) { + throw Object.assign( + new Error(`\`${semverValue}\` is not a valid semver version or range`), + { code: 'EQUERYINVALIDSEMVER' }) + } + + const valueIsVersion = !!semver.valid(semverValue) + + const nodeMatches = (node, obj) => { + // if we already have an operator, the user provided some test as part of the selector + // we evaluate that first because if it fails we don't want this node anyway + if (attributeMatcher.operator) { + if (!attributeMatch(attributeMatcher, obj)) { + // if the initial operator doesn't match, we're done + return false + } + } + + const attrValue = obj[qualifiedAttribute] + // both valid and validRange return null for undefined, so this will skip both nodes that + // do not have the attribute defined as well as those where the attribute value is invalid + // and those where the value from the package.json is not a string + if ((!semver.valid(attrValue) && !semver.validRange(attrValue)) || + typeof attrValue !== 'string') { + return false + } + + const attrIsVersion = !!semver.valid(attrValue) + + let actualFunc = semverFunc + + // if we're asked to infer, we examine outputs to make a best guess + if (actualFunc === 'infer') { + if (valueIsVersion && attrIsVersion) { + // two versions -> semver.eq + actualFunc = 'eq' + } else if (!valueIsVersion && !attrIsVersion) { + // two ranges -> semver.intersects + actualFunc = 'intersects' + } else { + // anything else -> semver.satisfies + actualFunc = 'satisfies' + } + } + + if (['eq', 'neq', 'gt', 'gte', 'lt', 'lte'].includes(actualFunc)) { + // both sides must be versions, but one is not + if (!valueIsVersion || !attrIsVersion) { + return false + } + + return semver[actualFunc](attrValue, semverValue) + } else if (['gtr', 'ltr', 'satisfies'].includes(actualFunc)) { + // at least one side must be a version, but neither is + if (!valueIsVersion && !attrIsVersion) { + return false + } + + return valueIsVersion + ? semver[actualFunc](semverValue, attrValue) + : semver[actualFunc](attrValue, semverValue) + } else if (['intersects', 'subset'].includes(actualFunc)) { + // these accept two ranges and since a version is also a range, anything goes + return semver[actualFunc](attrValue, semverValue) + } else { + // user provided a function we don't know about, throw an error + throw Object.assign(new Error(`\`semver.${actualFunc}\` is not a supported operator.`), + { code: 'EQUERYINVALIDOPERATOR' }) + } + } + + return this.initialItems.filter((node) => { + // no lookupProperties just means its a top level property, see if it matches + if (!lookupProperties.length) { + return nodeMatches(node, node.package) + } + + // this code is mostly duplicated from attrPseudo to traverse into the package until we get + // to our deepest requested object + let objs = [node.package] + for (const prop of lookupProperties) { + if (prop === arrayDelimiter) { + objs = objs.flat() + continue + } + + objs = objs.flatMap(obj => obj[prop] || []) + const noAttr = objs.every(obj => !obj) + if (noAttr) { + return false + } + + return objs.some(obj => nodeMatches(node, obj)) + } + }) + } + + typePseudo () { + if (!this.currentAstNode.typeValue) { + return this.initialItems + } + return this.initialItems + .flatMap(node => { + const found = [] + for (const edge of node.edgesIn) { + if (npa(`${edge.name}@${edge.spec}`).type === this.currentAstNode.typeValue) { + found.push(edge.to) + } + } + return found + }) + } + + dedupedPseudo () { + return this.initialItems.filter(node => node.target.edgesIn.size > 1) + } + + async outdatedPseudo () { + const { outdatedKind = 'any' } = this.currentAstNode + + // filter the initialItems + // NOTE: this uses a Promise.all around a map without in-line concurrency handling + // since the only async action taken is retrieving the packument, which is limited + // based on the max-sockets config in make-fetch-happen + const initialResults = await Promise.all(this.initialItems.map(async (node) => { + // the root can't be outdated, skip it + if (node.isProjectRoot) { + return false + } + + // we cache the promise representing the full versions list, this helps reduce the + // number of requests we send by keeping population of the cache in a single tick + // making it less likely that multiple requests for the same package will be inflight + if (!this.#outdatedCache.has(node.name)) { + this.#outdatedCache.set(node.name, getPackageVersions(node.name, this.flatOptions)) + } + const availableVersions = await this.#outdatedCache.get(node.name) + + // we attach _all_ versions to the queryContext to allow consumers to do their own + // filtering and comparisons + node.queryContext.versions = availableVersions + + // next we further reduce the set to versions that are greater than the current one + const greaterVersions = availableVersions.filter((available) => { + return semver.gt(available, node.version) + }) + + // no newer versions than the current one, drop this node from the result set + if (!greaterVersions.length) { + return false + } + + // if we got here, we know that newer versions exist, if the kind is 'any' we're done + if (outdatedKind === 'any') { + return node + } + + // look for newer versions that differ from current by a specific part of the semver version + if (['major', 'minor', 'patch'].includes(outdatedKind)) { + // filter the versions greater than our current one based on semver.diff + const filteredVersions = greaterVersions.filter((version) => { + return semver.diff(node.version, version) === outdatedKind + }) + + // no available versions are of the correct diff type + if (!filteredVersions.length) { + return false + } + + return node + } + + // look for newer versions that satisfy at least one edgeIn to this node + if (outdatedKind === 'in-range') { + const inRangeContext = [] + for (const edge of node.edgesIn) { + const inRangeVersions = greaterVersions.filter((version) => { + return semver.satisfies(version, edge.spec) + }) + + // this edge has no in-range candidates, just move on + if (!inRangeVersions.length) { + continue + } + + inRangeContext.push({ + from: edge.from.location, + versions: inRangeVersions, + }) + } + + // if we didn't find at least one match, drop this node + if (!inRangeContext.length) { + return false + } + + // now add to the context each version that is in-range for each edgeIn + node.queryContext.outdated = { + ...node.queryContext.outdated, + inRange: inRangeContext, + } + + return node + } + + // look for newer versions that _do not_ satisfy at least one edgeIn + if (outdatedKind === 'out-of-range') { + const outOfRangeContext = [] + for (const edge of node.edgesIn) { + const outOfRangeVersions = greaterVersions.filter((version) => { + return !semver.satisfies(version, edge.spec) + }) + + // this edge has no out-of-range candidates, skip it + if (!outOfRangeVersions.length) { + continue + } + + outOfRangeContext.push({ + from: edge.from.location, + versions: outOfRangeVersions, + }) + } + + // if we didn't add at least one thing to the context, this node is not a match + if (!outOfRangeContext.length) { + return false + } + + // attach the out-of-range context to the node + node.queryContext.outdated = { + ...node.queryContext.outdated, + outOfRange: outOfRangeContext, + } + + return node + } + + // any other outdatedKind is unknown and will never match + return false + })) + + // return an array with the holes for non-matching nodes removed + return initialResults.filter(Boolean) + } +} + +// operators for attribute selectors +const attributeOperators = { + // attribute value is equivalent + '=' ({ attr, value, insensitive }) { + return attr === value + }, + // attribute value contains word + '~=' ({ attr, value, insensitive }) { + return (attr.match(/\w+/g) || []).includes(value) + }, + // attribute value contains string + '*=' ({ attr, value, insensitive }) { + return attr.includes(value) + }, + // attribute value is equal or starts with + '|=' ({ attr, value, insensitive }) { + return attr.startsWith(`${value}-`) + }, + // attribute value starts with + '^=' ({ attr, value, insensitive }) { + return attr.startsWith(value) + }, + // attribute value ends with + '$=' ({ attr, value, insensitive }) { + return attr.endsWith(value) + }, +} + +const attributeOperator = ({ attr, value, insensitive, operator }) => { + if (typeof attr === 'number') { + attr = String(attr) + } + if (typeof attr !== 'string') { + // It's an object or an array, bail + return false + } + if (insensitive) { + attr = attr.toLowerCase() + } + + return attributeOperators[operator]({ + attr, + insensitive, + value, + }) +} + +const attributeMatch = (matcher, obj) => { + const insensitive = !!matcher.insensitive + const operator = matcher.operator || '' + const attribute = matcher.qualifiedAttribute + let value = matcher.value || '' + // return early if checking existence + if (operator === '') { + return Boolean(obj[attribute]) + } + if (insensitive) { + value = value.toLowerCase() + } + // in case the current object is an array + // then we try to match every item in the array + if (Array.isArray(obj[attribute])) { + return obj[attribute].find((i, index) => { + const attr = obj[attribute][index] || '' + return attributeOperator({ attr, value, insensitive, operator }) + }) + } else { + const attr = obj[attribute] || '' + return attributeOperator({ attr, value, insensitive, operator }) + } +} + +const edgeIsType = (node, type, seen = new Set()) => { + for (const edgeIn of node.edgesIn) { + // TODO Need a test with an infinite loop + if (seen.has(edgeIn)) { + continue + } + seen.add(edgeIn) + if (edgeIn.type === type || edgeIn.from[type] || edgeIsType(edgeIn.from, type, seen)) { + return true + } + } + return false +} + +const filterByType = (nodes, type) => { + const found = [] + for (const node of nodes) { + if (node[type] || edgeIsType(node, type)) { + found.push(node) + } + } + return found +} + +const depTypes = { + // dependency + '.prod' (prevResults) { + const found = [] + for (const node of prevResults) { + if (!node.dev) { + found.push(node) + } + } + return found + }, + // devDependency + '.dev' (prevResults) { + return filterByType(prevResults, 'dev') + }, + // optionalDependency + '.optional' (prevResults) { + return filterByType(prevResults, 'optional') + }, + // peerDependency + '.peer' (prevResults) { + return filterByType(prevResults, 'peer') + }, + // workspace + '.workspace' (prevResults) { + return prevResults.filter(node => node.isWorkspace) + }, + // bundledDependency + '.bundled' (prevResults) { + return prevResults.filter(node => node.inBundle) + }, +} + +// checks if a given node has a direct parent in any of the nodes provided in +// the compare nodes array +const hasParent = (node, compareNodes) => { + // All it takes is one so we loop and return on the first hit + for (const compareNode of compareNodes) { + // follows logical parent for link anscestors + if (node.isTop && (node.resolveParent === compareNode)) { + return true + } + // follows edges-in to check if they match a possible parent + for (const edge of node.edgesIn) { + if (edge && edge.from === compareNode) { + return true + } + } + } + return false +} + +// checks if a given node is a descendant of any of the nodes provided in the +// compareNodes array +const hasAscendant = (node, compareNodes, seen = new Set()) => { + // TODO (future) loop over ancestry property + if (hasParent(node, compareNodes)) { + return true + } + + if (node.isTop && node.resolveParent) { + return hasAscendant(node.resolveParent, compareNodes) + } + for (const edge of node.edgesIn) { + // TODO Need a test with an infinite loop + if (seen.has(edge)) { + continue + } + seen.add(edge) + if (edge && edge.from && hasAscendant(edge.from, compareNodes, seen)) { + return true + } + } + return false +} + +const combinators = { + // direct descendant + '>' (prevResults, nextResults) { + return nextResults.filter(node => hasParent(node, prevResults)) + }, + // any descendant + ' ' (prevResults, nextResults) { + return nextResults.filter(node => hasAscendant(node, prevResults)) + }, + // sibling + '~' (prevResults, nextResults) { + // Return any node in nextResults that is a sibling of (aka shares a + // parent with) a node in prevResults + const parentNodes = new Set() // Parents of everything in prevResults + for (const node of prevResults) { + for (const edge of node.edgesIn) { + // edge.from always exists cause it's from another node's edgesIn + parentNodes.add(edge.from) + } + } + return nextResults.filter(node => + !prevResults.includes(node) && hasParent(node, [...parentNodes]) + ) + }, +} + +// get a list of available versions of a package filtered to respect --before +// NOTE: this runs over each node and should not throw +const getPackageVersions = async (name, opts) => { + let packument + try { + packument = await pacote.packument(name, { + ...opts, + fullMetadata: false, // we only need the corgi + }) + } catch (err) { + // if the fetch fails, log a warning and pretend there are no versions + log.warn('query', `could not retrieve packument for ${name}: ${err.message}`) + return [] + } + + // start with a sorted list of all versions (lowest first) + let candidates = Object.keys(packument.versions).sort(semver.compare) + + // if the packument has a time property, and the user passed a before flag, then + // we filter this list down to only those versions that existed before the specified date + if (packument.time && opts.before) { + candidates = candidates.filter((version) => { + // this version isn't found in the times at all, drop it + if (!packument.time[version]) { + return false + } + + return Date.parse(packument.time[version]) <= opts.before + }) + } + + return candidates +} + +const retrieveNodesFromParsedAst = async (opts) => { + // when we first call this it's the parsed query. all other times it's + // results.currentNode.nestedNode + const rootAstNode = opts.rootAstNode + + if (!rootAstNode.nodes) { + return new Set() + } + + const results = new Results(opts) + + const astNodeQueue = new Set() + // walk is sync, so we have to build up our async functions and then await them later + rootAstNode.walk((nextAstNode) => { + astNodeQueue.add(nextAstNode) + }) + + for (const nextAstNode of astNodeQueue) { + // This is the only place we reset currentAstNode + results.currentAstNode = nextAstNode + const updateFn = `${results.currentAstNode.type}Type` + if (typeof results[updateFn] !== 'function') { + throw Object.assign( + new Error(`\`${results.currentAstNode.type}\` is not a supported selector.`), + { code: 'EQUERYNOSELECTOR' } + ) + } + await results[updateFn]() + } + + return results.collect(rootAstNode) +} + +// We are keeping this async in the event that we do add async operators, we +// won't have to have a breaking change on this function signature. +const querySelectorAll = async (targetNode, query, flatOptions) => { + // This never changes ever we just pass it around. But we can't scope it to + // this whole file if we ever want to support concurrent calls to this + // function. + const inventory = [...targetNode.root.inventory.values()] + // res is a Set of items returned for each parsed css ast selector + const res = await retrieveNodesFromParsedAst({ + initialItems: inventory, + inventory, + flatOptions, + rootAstNode: parser(query), + targetNode, + }) + + // returns nodes ordered by realpath + return [...res].sort((a, b) => localeCompare(a.location, b.location)) +} + +module.exports = querySelectorAll diff --git a/workspaces/arborist/lib/realpath.js b/workspaces/arborist/lib/realpath.js index bc4bbbc..8dc20ab 100644 --- a/workspaces/arborist/lib/realpath.js +++ b/workspaces/arborist/lib/realpath.js @@ -5,10 +5,7 @@ // built-in fs.realpath, because we only care about symbolic links, // so we can handle many fewer edge cases. -const fs = require('fs') -const promisify = require('util').promisify -const readlink = promisify(fs.readlink) -const lstat = promisify(fs.lstat) +const { lstat, readlink } = require('fs/promises') const { resolve, basename, dirname } = require('path') const realpathCached = (path, rpcache, stcache, depth) => { diff --git a/workspaces/arborist/lib/retire-path.js b/workspaces/arborist/lib/retire-path.js index 5d583b1..0c7a4a3 100644 --- a/workspaces/arborist/lib/retire-path.js +++ b/workspaces/arborist/lib/retire-path.js @@ -7,7 +7,7 @@ const pathSafeHash = s => .update(s) .digest('base64') .replace(/[^a-zA-Z0-9]+/g, '') - .substr(0, 8) + .slice(0, 8) const retirePath = from => { const d = dirname(from) diff --git a/workspaces/arborist/lib/shrinkwrap.js b/workspaces/arborist/lib/shrinkwrap.js index bb6971f..a0fda5a 100644 --- a/workspaces/arborist/lib/shrinkwrap.js +++ b/workspaces/arborist/lib/shrinkwrap.js @@ -10,7 +10,7 @@ // definitely not before npm v8. const localeCompare = require('@isaacs/string-locale-compare')('en') -const defaultLockfileVersion = 2 +const defaultLockfileVersion = 3 // for comparing nodes to yarn.lock entries const mismatch = (a, b) => a && b && a !== b @@ -33,34 +33,18 @@ const mismatch = (a, b) => a && b && a !== b // After calling this.commit(), any nodes not present in the tree will have // been removed from the shrinkwrap data as well. -const procLog = require('proc-log') +const log = require('proc-log') const YarnLock = require('./yarn-lock.js') -const { promisify } = require('util') -const rimraf = promisify(require('rimraf')) -const fs = require('fs') -const readFile = promisify(fs.readFile) -const writeFile = promisify(fs.writeFile) -const stat = promisify(fs.stat) -const readdir_ = promisify(fs.readdir) -const readlink = promisify(fs.readlink) +const { + readFile, + readdir, + readlink, + rm, + stat, + writeFile, +} = require('fs/promises') -// XXX remove when drop support for node v10 -const lstat = promisify(fs.lstat) -/* istanbul ignore next - version specific polyfill */ -const readdir = async (path, opt) => { - if (!opt || !opt.withFileTypes) { - return readdir_(path, opt) - } - const ents = await readdir_(path, opt) - if (typeof ents[0] === 'string') { - return Promise.all(ents.map(async ent => { - return Object.assign(await lstat(path + '/' + ent), { name: ent }) - })) - } - return ents -} - -const { resolve, basename } = require('path') +const { resolve, basename, relative } = require('path') const specFromLock = require('./spec-from-lock.js') const versionFromTgz = require('./version-from-tgz.js') const npa = require('npm-package-arg') @@ -80,8 +64,8 @@ const swKeyOrder = [ ] // used to rewrite from yarn registry to npm registry -const yarnRegRe = /^https?:\/\/registry.yarnpkg.com\// -const npmRegRe = /^https?:\/\/registry.npmjs.org\// +const yarnRegRe = /^https?:\/\/registry\.yarnpkg\.com\// +const npmRegRe = /^https?:\/\/registry\.npmjs\.org\// // sometimes resolved: is weird or broken, or something npa can't handle const specFromResolved = resolved => { @@ -95,6 +79,7 @@ const specFromResolved = resolved => { const relpath = require('./relpath.js') const consistentResolve = require('./consistent-resolve.js') +const { overrideResolves } = require('./override-resolves.js') const maybeReadFile = file => { return readFile(file, 'utf8').then(d => d, er => { @@ -183,34 +168,32 @@ const assertNoNewer = async (path, data, lockTime, dir = path, seen = null) => { ? Promise.resolve([{ name: 'node_modules', isDirectory: () => true }]) : readdir(parent, { withFileTypes: true }) - return children.catch(() => []) - .then(ents => Promise.all(ents.map(async ent => { - const child = resolve(parent, ent.name) - if (ent.isDirectory() && !/^\./.test(ent.name)) { - await assertNoNewer(path, data, lockTime, child, seen) - } else if (ent.isSymbolicLink()) { - const target = resolve(parent, await readlink(child)) - const tstat = await stat(target).catch( - /* istanbul ignore next - windows */ () => null) - seen.add(relpath(path, child)) - /* istanbul ignore next - windows cannot do this */ - if (tstat && tstat.isDirectory() && !seen.has(relpath(path, target))) { - await assertNoNewer(path, data, lockTime, target, seen) - } - } - }))) - .then(() => { - if (dir !== path) { - return + const ents = await children.catch(() => []) + await Promise.all(ents.map(async ent => { + const child = resolve(parent, ent.name) + if (ent.isDirectory() && !/^\./.test(ent.name)) { + await assertNoNewer(path, data, lockTime, child, seen) + } else if (ent.isSymbolicLink()) { + const target = resolve(parent, await readlink(child)) + const tstat = await stat(target).catch( + /* istanbul ignore next - windows */ () => null) + seen.add(relpath(path, child)) + /* istanbul ignore next - windows cannot do this */ + if (tstat && tstat.isDirectory() && !seen.has(relpath(path, target))) { + await assertNoNewer(path, data, lockTime, target, seen) } + } + })) + if (dir !== path) { + return + } - // assert that all the entries in the lockfile were seen - for (const loc of new Set(Object.keys(data.packages))) { - if (!seen.has(loc)) { - throw 'missing from node_modules: ' + loc - } - } - }) + // assert that all the entries in the lockfile were seen + for (const loc of new Set(Object.keys(data.packages))) { + if (!seen.has(loc)) { + throw 'missing from node_modules: ' + loc + } + } } const _awaitingUpdate = Symbol('_awaitingUpdate') @@ -225,6 +208,7 @@ const _buildLegacyLockfile = Symbol('_buildLegacyLockfile') const _filenameSet = Symbol('_filenameSet') const _maybeRead = Symbol('_maybeRead') const _maybeStat = Symbol('_maybeStat') + class Shrinkwrap { static get defaultLockfileVersion () { return defaultLockfileVersion @@ -253,19 +237,10 @@ class Shrinkwrap { s.loadedFromDisk = !!(sw || lock) s.type = basename(s.filename) - try { - if (s.loadedFromDisk && !s.lockfileVersion) { - const json = parseJSON(await maybeReadFile(s.filename)) - if (json.lockfileVersion > defaultLockfileVersion) { - s.lockfileVersion = json.lockfileVersion - } - } - } catch (e) {} - return s } - static metaFromNode (node, path) { + static metaFromNode (node, path, options = {}) { if (node.isLink) { return { resolved: relpath(path, node.realpath), @@ -299,7 +274,12 @@ class Shrinkwrap { }) const resolved = consistentResolve(node.resolved, node.path, path, true) - if (resolved) { + // hide resolved from registry dependencies. + if (!resolved) { + // no-op + } else if (node.isRegistryDependency) { + meta.resolved = overrideResolves(resolved, options) + } else { meta.resolved = resolved } @@ -329,14 +309,14 @@ class Shrinkwrap { newline = '\n', shrinkwrapOnly = false, hiddenLockfile = false, - log = procLog, lockfileVersion, + resolveOptions = {}, } = options this.lockfileVersion = hiddenLockfile ? 3 : lockfileVersion ? parseInt(lockfileVersion, 10) : null - this.log = log + this[_awaitingUpdate] = new Map() this.tree = null this.path = resolve(path || '.') @@ -349,6 +329,7 @@ class Shrinkwrap { this.yarnLock = null this.hiddenLockfile = hiddenLockfile this.loadingError = null + this.resolveOptions = resolveOptions // only load npm-shrinkwrap.json in dep trees, not package-lock this.shrinkwrapOnly = shrinkwrapOnly } @@ -392,6 +373,7 @@ class Shrinkwrap { this[_awaitingUpdate] = new Map() const lockfileVersion = this.lockfileVersion || defaultLockfileVersion this.originalLockfileVersion = lockfileVersion + this.data = { lockfileVersion, requires: true, @@ -436,7 +418,7 @@ class Shrinkwrap { this.newline = newline !== undefined ? newline : this.newline } - load () { + async load () { // we don't need to load package-lock.json except for top of tree nodes, // only npm-shrinkwrap.json. return this[_maybeRead]().then(([sw, lock, yarn]) => { @@ -458,7 +440,9 @@ class Shrinkwrap { // ignore invalid yarn data. we'll likely clobber it later anyway. try { this.yarnLock.parse(yarn) - } catch (_) {} + } catch { + // ignore errors + } } return data ? parseJSON(data) : {} @@ -479,17 +463,23 @@ class Shrinkwrap { /* istanbul ignore else */ if (typeof this.filename === 'string') { const rel = relpath(this.path, this.filename) - this.log.verbose('shrinkwrap', `failed to load ${rel}`, er) + log.verbose('shrinkwrap', `failed to load ${rel}`, er) } else { - this.log.verbose('shrinkwrap', `failed to load ${this.path}`, er) + log.verbose('shrinkwrap', `failed to load ${this.path}`, er) } this.loadingError = er this.loadedFromDisk = false this.ancientLockfile = false return {} }).then(lock => { - const lockfileVersion = this.lockfileVersion ? this.lockfileVersion - : Math.max(lock.lockfileVersion || 0, defaultLockfileVersion) + // auto convert v1 lockfiles to v3 + // leave v2 in place unless configured + // v3 by default + const lockfileVersion = + this.lockfileVersion ? this.lockfileVersion + : lock.lockfileVersion === 1 ? defaultLockfileVersion + : lock.lockfileVersion || defaultLockfileVersion + this.data = { ...lock, lockfileVersion: lockfileVersion, @@ -499,6 +489,7 @@ class Shrinkwrap { } this.originalLockfileVersion = lock.lockfileVersion + // use default if it wasn't explicitly set, and the current file is // less than our default. otherwise, keep whatever is in the file, // unless we had an explicit setting already. @@ -509,8 +500,10 @@ class Shrinkwrap { !(lock.lockfileVersion >= 2) && !lock.requires // load old lockfile deps into the packages listing + // eslint-disable-next-line promise/always-return if (lock.dependencies && !lock.packages) { return rpj(this.path + '/package.json').then(pkg => pkg, er => ({})) + // eslint-disable-next-line promise/always-return .then(pkg => { this[_loadAll]('', null, this.data) this[_fixDependencies](pkg) @@ -809,7 +802,7 @@ class Shrinkwrap { const pathFixed = !resolved ? null : !/^file:/.test(resolved) ? resolved // resolve onto the metadata path - : `file:${resolve(this.path, resolved.substr(5))}` + : `file:${resolve(this.path, resolved.slice(5)).replace(/#/g, '%23')}` // if we have one, only set the other if it matches // otherwise it could be for a completely different thing. @@ -832,7 +825,7 @@ class Shrinkwrap { resolved, integrity, hasShrinkwrap, - } = Shrinkwrap.metaFromNode(node, this.path) + } = Shrinkwrap.metaFromNode(node, this.path, this.resolveOptions) node.resolved = node.resolved || resolved || null node.integrity = node.integrity || integrity || null node.hasShrinkwrap = node.hasShrinkwrap || hasShrinkwrap || false @@ -888,7 +881,10 @@ class Shrinkwrap { [_updateWaitingNode] (loc) { const node = this[_awaitingUpdate].get(loc) this[_awaitingUpdate].delete(loc) - this.data.packages[loc] = Shrinkwrap.metaFromNode(node, this.path) + this.data.packages[loc] = Shrinkwrap.metaFromNode( + node, + this.path, + this.resolveOptions) } commit () { @@ -896,7 +892,10 @@ class Shrinkwrap { if (this.yarnLock) { this.yarnLock.fromTree(this.tree) } - const root = Shrinkwrap.metaFromNode(this.tree.target, this.path) + const root = Shrinkwrap.metaFromNode( + this.tree.target, + this.path, + this.resolveOptions) this.data.packages = {} if (Object.keys(root).length) { this.data.packages[''] = root @@ -907,7 +906,10 @@ class Shrinkwrap { continue } const loc = relpath(this.path, node.path) - this.data.packages[loc] = Shrinkwrap.metaFromNode(node, this.path) + this.data.packages[loc] = Shrinkwrap.metaFromNode( + node, + this.path, + this.resolveOptions) } } else if (this[_awaitingUpdate].size > 0) { for (const loc of this[_awaitingUpdate].keys()) { @@ -981,7 +983,7 @@ class Shrinkwrap { : npa.resolve(node.name, edge.spec, edge.from.realpath) if (node.isLink) { - lock.version = `file:${relpath(this.path, node.realpath)}` + lock.version = `file:${relpath(this.path, node.realpath).replace(/#/g, '%23')}` } else if (spec && (spec.type === 'file' || spec.type === 'remote')) { lock.version = spec.saveSpec } else if (spec && spec.type === 'git' || rSpec.type === 'git') { @@ -1015,7 +1017,7 @@ class Shrinkwrap { spec.type !== 'git' && spec.type !== 'file' && spec.type !== 'remote') { - lock.resolved = node.resolved + lock.resolved = overrideResolves(node.resolved, this.resolveOptions) } if (node.integrity) { @@ -1058,8 +1060,8 @@ class Shrinkwrap { // turn absolute file: paths into relative paths from the node // this especially shows up with workspace edges when the root // node is also a workspace in the set. - const p = resolve(node.realpath, spec.substr('file:'.length)) - set[k] = `file:${relpath(node.realpath, p)}` + const p = resolve(node.realpath, spec.slice('file:'.length)) + set[k] = `file:${relpath(node.realpath, p).replace(/#/g, '%23')}` } else { set[k] = spec } @@ -1116,7 +1118,17 @@ class Shrinkwrap { if (!this.data) { throw new Error('run load() before saving data') } + const json = this.toString(options) + if ( + !this.hiddenLockfile + && this.originalLockfileVersion !== undefined + && this.originalLockfileVersion !== this.lockfileVersion + ) { + log.warn( + `Converting lock file (${relative(process.cwd(), this.filename)}) from v${this.originalLockfileVersion} -> v${this.lockfileVersion}` + ) + } return Promise.all([ writeFile(this.filename, json).catch(er => { if (this.hiddenLockfile) { @@ -1125,7 +1137,7 @@ class Shrinkwrap { // a node_modules folder, but then the lockfile is not important. // Remove the file, so that in case there WERE deps, but we just // failed to update the file for some reason, it's not out of sync. - return rimraf(this.filename) + return rm(this.filename, { recursive: true, force: true }) } throw er }), diff --git a/workspaces/arborist/lib/signal-handling.js b/workspaces/arborist/lib/signal-handling.js index 0afbb05..18841d9 100644 --- a/workspaces/arborist/lib/signal-handling.js +++ b/workspaces/arborist/lib/signal-handling.js @@ -19,7 +19,9 @@ const setup = fn => { for (const sig of signals) { try { process.removeListener(sig, sigListeners[sig]) - } catch (er) {} + } catch { + // ignore errors + } } process.removeListener('beforeExit', onBeforeExit) sigListeners.loaded = false @@ -62,7 +64,9 @@ const setup = fn => { process.setMaxListeners(length + 1) } process.on(sig, sigListeners[sig]) - } catch (er) {} + } catch { + // ignore errors + } } sigListeners.loaded = true diff --git a/workspaces/arborist/lib/spec-from-lock.js b/workspaces/arborist/lib/spec-from-lock.js index 7897419..49b53c8 100644 --- a/workspaces/arborist/lib/spec-from-lock.js +++ b/workspaces/arborist/lib/spec-from-lock.js @@ -21,10 +21,12 @@ const specFromLock = (name, lock, where) => { if (lock.resolved) { return npa.resolve(name, lock.resolved, where) } - } catch (_) { } + } catch { + // ignore errors + } try { return npa.resolve(name, lock.version, where) - } catch (_) { + } catch { return {} } } diff --git a/workspaces/arborist/lib/tracker.js b/workspaces/arborist/lib/tracker.js index b50f06e..42c401e 100644 --- a/workspaces/arborist/lib/tracker.js +++ b/workspaces/arborist/lib/tracker.js @@ -1,20 +1,16 @@ const _progress = Symbol('_progress') const _onError = Symbol('_onError') -const procLog = require('proc-log') +const _setProgress = Symbol('_setProgess') +const npmlog = require('npmlog') module.exports = cls => class Tracker extends cls { constructor (options = {}) { super(options) - this.log = options.log || procLog + this[_setProgress] = !!options.progress this[_progress] = new Map() } addTracker (section, subsection = null, key = null) { - // TrackerGroup type object not found - if (!this.log.newGroup) { - return - } - if (section === null || section === undefined) { this[_onError](`Tracker can't be null or undefined`) } @@ -31,13 +27,13 @@ module.exports = cls => class Tracker extends cls { this[_onError](`Tracker "${section}" already exists`) } else if (!hasTracker && subsection === null) { // 1. no existing tracker, no subsection - // Create a new tracker from this.log + // Create a new tracker from npmlog // starts progress bar - if (this[_progress].size === 0) { - this.log.enableProgress() + if (this[_setProgress] && this[_progress].size === 0) { + npmlog.enableProgress() } - this[_progress].set(section, this.log.newGroup(section)) + this[_progress].set(section, npmlog.newGroup(section)) } else if (!hasTracker && subsection !== null) { // 2. no parent tracker and subsection this[_onError](`Parent tracker "${section}" does not exist`) @@ -53,11 +49,6 @@ module.exports = cls => class Tracker extends cls { } finishTracker (section, subsection = null, key = null) { - // TrackerGroup type object not found - if (!this.log.newGroup) { - return - } - if (section === null || section === undefined) { this[_onError](`Tracker can't be null or undefined`) } @@ -87,8 +78,8 @@ module.exports = cls => class Tracker extends cls { // remove progress bar if all // trackers are finished - if (this[_progress].size === 0) { - this.log.disableProgress() + if (this[_setProgress] && this[_progress].size === 0) { + npmlog.disableProgress() } } else if (!hasTracker && subsection === null) { // 1. no existing parent tracker, no subsection @@ -103,7 +94,9 @@ module.exports = cls => class Tracker extends cls { } [_onError] (msg) { - this.log.disableProgress() + if (this[_setProgress]) { + npmlog.disableProgress() + } throw new Error(msg) } } diff --git a/workspaces/arborist/lib/version-from-tgz.js b/workspaces/arborist/lib/version-from-tgz.js index cdb59b7..be4405c 100644 --- a/workspaces/arborist/lib/version-from-tgz.js +++ b/workspaces/arborist/lib/version-from-tgz.js @@ -16,7 +16,7 @@ module.exports = (name, tgz) => { // basename checking. Note that registries can // be mounted below the root url, so /a/b/-/x/y/foo/-/foo-1.2.3.tgz // is a potential option. - const tfsplit = u.path.substr(1).split('/-/') + const tfsplit = u.path.slice(1).split('/-/') if (tfsplit.length > 1) { const afterTF = tfsplit.pop() if (afterTF === base) { diff --git a/workspaces/arborist/lib/vuln.js b/workspaces/arborist/lib/vuln.js index 5b1483e..81b921d 100644 --- a/workspaces/arborist/lib/vuln.js +++ b/workspaces/arborist/lib/vuln.js @@ -65,6 +65,9 @@ class Vuln { // - {name, version, isSemVerMajor} fix requires -f, is semver major // - {name, version} fix requires -f, not semver major // - true: fix does not require -f + // TODO: duped entries may require different fixes but the current + // structure does not support this, so the case were a top level fix + // corrects a duped entry may mean you have to run fix more than once for (const v of this.via) { // don't blow up on loops if (v.fixAvailable === f) { diff --git a/workspaces/arborist/lib/yarn-lock.js b/workspaces/arborist/lib/yarn-lock.js index 5119a75..887d776 100644 --- a/workspaces/arborist/lib/yarn-lock.js +++ b/workspaces/arborist/lib/yarn-lock.js @@ -7,9 +7,8 @@ // <key> <value> // // Assume that any key or value might be quoted, though that's only done -// in practice if certain chars are in the string. Quoting unnecessarily -// does not cause problems for yarn, so that's what we do when we write -// it back. +// in practice if certain chars are in the string. When writing back, we follow +// Yarn's rules for quoting, to cause minimal friction. // // The data format would support nested objects, but at this time, it // appears that yarn does not use that for anything, so in the interest @@ -33,10 +32,44 @@ const consistentResolve = require('./consistent-resolve.js') const { dirname } = require('path') const { breadth } = require('treeverse') +// Sort Yarn entries respecting the yarn.lock sort order +const yarnEntryPriorities = { + name: 1, + version: 2, + uid: 3, + resolved: 4, + integrity: 5, + registry: 6, + dependencies: 7, +} + +const priorityThenLocaleCompare = (a, b) => { + if (!yarnEntryPriorities[a] && !yarnEntryPriorities[b]) { + return localeCompare(a, b) + } + /* istanbul ignore next */ + return (yarnEntryPriorities[a] || 100) > (yarnEntryPriorities[b] || 100) ? 1 : -1 +} + +const quoteIfNeeded = val => { + if ( + typeof val === 'boolean' || + typeof val === 'number' || + val.startsWith('true') || + val.startsWith('false') || + /[:\s\n\\",[\]]/g.test(val) || + !/^[a-zA-Z]/g.test(val) + ) { + return JSON.stringify(val) + } + + return val +} + // sort a key/value object into a string of JSON stringified keys and vals const sortKV = obj => Object.keys(obj) .sort(localeCompare) - .map(k => ` ${JSON.stringify(k)} ${JSON.stringify(obj[k])}`) + .map(k => ` ${quoteIfNeeded(k)} ${quoteIfNeeded(obj[k])}`) .join('\n') // for checking against previous entries @@ -171,7 +204,7 @@ class YarnLock { toString () { return prefix + [...new Set([...this.entries.values()])] .map(e => e.toString()) - .sort(localeCompare).join('\n\n') + '\n' + .sort((a, b) => localeCompare(a.replace(/"/g, ''), b.replace(/"/g, ''))).join('\n\n') + '\n' } fromTree (tree) { @@ -323,19 +356,14 @@ class YarnLockEntry { // sort objects to the bottom, then alphabetical return ([...this[_specs]] .sort(localeCompare) - .map(JSON.stringify).join(', ') + + .map(quoteIfNeeded).join(', ') + ':\n' + Object.getOwnPropertyNames(this) .filter(prop => this[prop] !== null) - .sort( - (a, b) => - /* istanbul ignore next - sort call order is unpredictable */ - (typeof this[a] === 'object') === (typeof this[b] === 'object') - ? localeCompare(a, b) - : typeof this[a] === 'object' ? 1 : -1) + .sort(priorityThenLocaleCompare) .map(prop => typeof this[prop] !== 'object' - ? ` ${JSON.stringify(prop)} ${JSON.stringify(this[prop])}\n` + ? ` ${prop} ${prop === 'integrity' ? this[prop] : JSON.stringify(this[prop])}\n` : Object.keys(this[prop]).length === 0 ? '' : ` ${prop}:\n` + sortKV(this[prop]) + '\n') .join('')).trim() diff --git a/workspaces/arborist/package.json b/workspaces/arborist/package.json index a915c9d..5b923f3 100644 --- a/workspaces/arborist/package.json +++ b/workspaces/arborist/package.json @@ -1,76 +1,77 @@ { "name": "@npmcli/arborist", - "version": "4.3.1", + "version": "6.1.5", "description": "Manage node_modules trees", "dependencies": { "@isaacs/string-locale-compare": "^1.1.0", - "@npmcli/installed-package-contents": "^1.0.7", - "@npmcli/map-workspaces": "^2.0.0", - "@npmcli/metavuln-calculator": "^2.0.0", - "@npmcli/move-file": "^1.1.0", + "@npmcli/fs": "^3.1.0", + "@npmcli/installed-package-contents": "^2.0.0", + "@npmcli/map-workspaces": "^3.0.0", + "@npmcli/metavuln-calculator": "^5.0.0", "@npmcli/name-from-folder": "^1.0.1", - "@npmcli/node-gyp": "^1.0.3", - "@npmcli/package-json": "^1.0.1", - "@npmcli/run-script": "^2.0.0", - "bin-links": "^3.0.0", - "cacache": "^15.0.3", + "@npmcli/node-gyp": "^3.0.0", + "@npmcli/package-json": "^3.0.0", + "@npmcli/query": "^3.0.0", + "@npmcli/run-script": "^6.0.0", + "bin-links": "^4.0.1", + "cacache": "^17.0.3", "common-ancestor-path": "^1.0.1", - "json-parse-even-better-errors": "^2.3.1", + "hosted-git-info": "^6.1.1", + "json-parse-even-better-errors": "^3.0.0", "json-stringify-nice": "^1.1.4", - "mkdirp": "^1.0.4", - "mkdirp-infer-owner": "^2.0.0", - "npm-install-checks": "^4.0.0", - "npm-package-arg": "^8.1.5", - "npm-pick-manifest": "^6.1.0", - "npm-registry-fetch": "^12.0.1", - "pacote": "^12.0.2", - "parse-conflict-json": "^2.0.1", - "proc-log": "^1.0.0", + "minimatch": "^5.1.1", + "nopt": "^7.0.0", + "npm-install-checks": "^6.0.0", + "npm-package-arg": "^10.1.0", + "npm-pick-manifest": "^8.0.1", + "npm-registry-fetch": "^14.0.3", + "npmlog": "^7.0.1", + "pacote": "^15.0.7", + "parse-conflict-json": "^3.0.0", + "proc-log": "^3.0.0", "promise-all-reject-late": "^1.0.0", "promise-call-limit": "^1.0.1", - "read-package-json-fast": "^2.0.2", - "readdir-scoped-modules": "^1.1.0", - "rimraf": "^3.0.2", - "semver": "^7.3.5", - "ssri": "^8.0.1", - "treeverse": "^1.0.4", + "read-package-json-fast": "^3.0.1", + "semver": "^7.3.7", + "ssri": "^10.0.1", + "treeverse": "^3.0.0", "walk-up-path": "^1.0.0" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", "benchmark": "^2.1.4", "chalk": "^4.1.0", - "minify-registry-metadata": "^2.1.0", + "minify-registry-metadata": "^3.0.0", "nock": "^13.2.0", - "tap": "^15.1.2", + "tap": "^16.3.2", "tcompare": "^5.0.6" }, "scripts": { "test": "tap", - "posttest": "npm run lint", + "posttest": "node ../.. run lint", "snap": "tap", "postsnap": "npm run lintfix", "test-proxy": "ARBORIST_TEST_PROXY=1 tap --snapshot", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", "eslint": "eslint", - "lint": "eslint '**/*.js'", - "lintfix": "npm run lint -- --fix", + "lint": "eslint \"**/*.js\"", + "lintfix": "node ../.. run lint -- --fix", "benchmark": "node scripts/benchmark.js", "benchclean": "rm -rf scripts/benchmark/*/", "npmclilint": "npmcli-lint", - "postlint": "npm-template-check" + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force" }, "repository": { "type": "git", - "url": "https://github.com/npm/arborist" + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/arborist" }, "author": "GitHub Inc.", "license": "ISC", "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "main": "lib/index.js", "bin": { @@ -89,16 +90,18 @@ "--no-warnings", "--no-deprecation" ], - "timeout": "360" + "timeout": "360", + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, - "eslintIgnore": [ - "test/fixtures/", - "!test/fixtures/*.js" - ], "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" } } diff --git a/workspaces/arborist/scripts/benchmark.js b/workspaces/arborist/scripts/benchmark.js index 3f6be3e..75f32e3 100644 --- a/workspaces/arborist/scripts/benchmark.js +++ b/workspaces/arborist/scripts/benchmark.js @@ -1,14 +1,13 @@ process.env.ARBORIST_DEBUG = '0' const { Suite } = require('benchmark') const { relative, resolve } = require('path') -const rimraf = require('rimraf') +const { mkdir, rm } = require('fs/promises') const { execSync } = require('child_process') const shaCmd = 'git show --no-patch --pretty=%H HEAD' const dirty = !!String(execSync('git status -s -uno')).trim() const currentSha = String(execSync(shaCmd)).trim() + (dirty ? '-dirty' : '') const { green, red } = require('chalk') const lastBenchmark = resolve(__dirname, 'benchmark/saved/last-benchmark.json') -const mkdirp = require('mkdirp') const { linkSync, writeFileSync, readdirSync } = require('fs') const registryServer = require('../test/fixtures/registry-mocks/server.js') @@ -63,13 +62,13 @@ Options: for (let i = 2; i < process.argv.length; i++) { const arg = process.argv[i] if (/^--previous=/.test(arg)) { - options.previous = arg.substr('--previous='.length) + options.previous = arg.slice('--previous='.length) } else if (/^--warn-range=[0-9]+/.test(arg)) { - options.warnRange = +arg.substr('--warn-range='.length) + options.warnRange = +arg.slice('--warn-range='.length) } else if (/^--cache=/.test(arg)) { - options.cache = resolve(arg.substr('--cache='.length)) + options.cache = resolve(arg.slice('--cache='.length)) } else if (/^--save=/.test(arg)) { - const save = arg.substr('--save='.length) + const save = arg.slice('--save='.length) if (/[/\\]|^\.\.?$/.test(save)) { throw new Error('save cannot have slashes or be . or ..') } @@ -151,9 +150,9 @@ const suite = new Suite({ } }, - onComplete () { - rimraf.sync(lastBenchmark) - mkdirp.sync(resolve(__dirname, 'benchmark/saved')) + async onComplete () { + await rm(lastBenchmark, { recursive: true, force: true }) + await mkdir(resolve(__dirname, 'benchmark/saved'), { recursive: true }) // always save with sha const saveThis = resolve(__dirname, `benchmark/saved/${this.sha}.json`) const data = JSON.stringify(this.reduce((acc, bench) => { @@ -168,12 +167,11 @@ const suite = new Suite({ } linkSync(saveThis, lastBenchmark) - teardown().then(() => Promise.all([ + await teardown() + await Promise.all([ registryServer.stop(), - new Promise((res, rej) => { - rimraf(this.cache, er => er ? rej(er) : res()) - }), - ])) + rm(this.cache, { recursive: true, force: true }), + ]) }, }) diff --git a/workspaces/arborist/scripts/benchmark/load-actual.js b/workspaces/arborist/scripts/benchmark/load-actual.js index fc15dd2..6194098 100644 --- a/workspaces/arborist/scripts/benchmark/load-actual.js +++ b/workspaces/arborist/scripts/benchmark/load-actual.js @@ -1,14 +1,16 @@ const Arborist = require('../..') const { resolve, basename } = require('path') const { writeFileSync } = require('fs') -const mkdirp = require('mkdirp') +const { + mkdir, + rm, +} = require('fs/promises') const dir = resolve(__dirname, basename(__filename, '.js')) -const rimraf = require('rimraf') const suite = async (suite, { registry, cache }) => { // setup two folders, one with a hidden lockfile, one without - await mkdirp(resolve(dir, 'with-hidden-lockfile')) - await mkdirp(resolve(dir, 'no-hidden-lockfile')) + await mkdir(resolve(dir, 'with-hidden-lockfile'), { recursive: true }) + await mkdir(resolve(dir, 'no-hidden-lockfile'), { recursive: true }) const dependencies = { 'flow-parser': '0.114.0', @@ -43,7 +45,7 @@ const suite = async (suite, { registry, cache }) => { dependencies, })) promises.push(await arb.reify().then(() => - rimraf.sync(resolve(arb.path, 'node_modules', '.package-lock.json')))) + rm(resolve(arb.path, 'node_modules', '.package-lock.json'), { recursive: true, force: true }))) } await Promise.all(promises) diff --git a/workspaces/arborist/scripts/benchmark/reify.js b/workspaces/arborist/scripts/benchmark/reify.js index b826533..84c7ab4 100644 --- a/workspaces/arborist/scripts/benchmark/reify.js +++ b/workspaces/arborist/scripts/benchmark/reify.js @@ -1,9 +1,9 @@ const Arborist = require('../..') const { resolve, basename } = require('path') const { writeFileSync } = require('fs') -const mkdirp = require('mkdirp') +const { mkdir } = require('fs/promises') +const { rmSync } = require('fs') const dir = resolve(__dirname, basename(__filename, '.js')) -const rimraf = require('rimraf') // these are not arbitrary, the empty/full and no-* bits matter const folders = [ @@ -19,7 +19,7 @@ const folders = [ const suite = async (suite, { registry, cache }) => { // setup two folders, one with a hidden lockfile, one without - await Promise.all(folders.map(f => mkdirp(f))) + await Promise.all(folders.map(f => mkdir(f, { recursive: true }))) const dependencies = { 'flow-parser': '0.114.0', @@ -49,10 +49,9 @@ const suite = async (suite, { registry, cache }) => { version: '1.0.0', dependencies, })) - await arb.reify().then(() => { - // grab this so we can make setup faster - packageLock = require(resolve(path, 'package-lock.json')) - }) + await arb.reify() + // grab this so we can make setup faster + packageLock = require(resolve(path, 'package-lock.json')) } // just reify them all fast. we'll remove the bits we don't want later. @@ -87,23 +86,22 @@ const suite = async (suite, { registry, cache }) => { defer: true, setup () { if (/no-lockfile/.test(path)) { - rimraf.sync(resolve(path, 'package-lock.json')) + rmSync(resolve(path, 'package-lock.json'), { recursive: true, force: true }) } if (/empty/.test(path)) { - rimraf.sync(resolve(path, 'node_modules')) + rmSync(resolve(path, 'node_modules'), { recursive: true, force: true }) } if (/no-cache/.test(path)) { - rimraf.sync(resolve(path, 'cache')) + rmSync(resolve(path, 'cache'), { recursive: true, force: true }) } }, - fn (d) { - new Arborist({ + async fn (d) { + await new Arborist({ path, registry, cache: /no-cache/.test(path) ? resolve(path, 'cache') : cache, - }).reify().then(() => d.resolve(), er => { - throw er - }) + }).reify() + d.resolve() }, }) } diff --git a/workspaces/arborist/tap-snapshots/test/arborist/build-ideal-tree.js.test.cjs b/workspaces/arborist/tap-snapshots/test/arborist/build-ideal-tree.js.test.cjs index b743dab..3559497 100644 --- a/workspaces/arborist/tap-snapshots/test/arborist/build-ideal-tree.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/arborist/build-ideal-tree.js.test.cjs @@ -1470,6 +1470,207 @@ ArboristNode { } ` +exports[`test/arborist/build-ideal-tree.js TAP add one workspace to another > tree with workspace a added to workspace c 1`] = ` +ArboristNode { + "children": Map { + "a" => ArboristLink { + "edgesIn": Set { + EdgeIn { + "from": "", + "name": "a", + "spec": "file:{CWD}/test/fixtures/workspaces-not-root/packages/a", + "type": "workspace", + }, + EdgeIn { + "from": "packages/c", + "name": "a", + "spec": "file:../a", + "type": "prod", + }, + }, + "isWorkspace": true, + "location": "node_modules/a", + "name": "a", + "path": "{CWD}/test/fixtures/workspaces-not-root/node_modules/a", + "realpath": "{CWD}/test/fixtures/workspaces-not-root/packages/a", + "resolved": "file:../packages/a", + "target": ArboristNode { + "location": "packages/a", + }, + "version": "1.2.3", + }, + "abbrev" => ArboristNode { + "edgesIn": Set { + EdgeIn { + "from": "", + "name": "abbrev", + "spec": "*", + "type": "prod", + }, + EdgeIn { + "from": "packages/b", + "name": "abbrev", + "spec": "*", + "type": "prod", + }, + EdgeIn { + "from": "packages/c", + "name": "abbrev", + "spec": "*", + "type": "prod", + }, + }, + "location": "node_modules/abbrev", + "name": "abbrev", + "path": "{CWD}/test/fixtures/workspaces-not-root/node_modules/abbrev", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", + "version": "1.1.1", + }, + "b" => ArboristLink { + "edgesIn": Set { + EdgeIn { + "from": "", + "name": "b", + "spec": "file:{CWD}/test/fixtures/workspaces-not-root/packages/b", + "type": "workspace", + }, + }, + "isWorkspace": true, + "location": "node_modules/b", + "name": "b", + "path": "{CWD}/test/fixtures/workspaces-not-root/node_modules/b", + "realpath": "{CWD}/test/fixtures/workspaces-not-root/packages/b", + "resolved": "file:../packages/b", + "target": ArboristNode { + "location": "packages/b", + }, + "version": "1.2.3", + }, + "c" => ArboristLink { + "edgesIn": Set { + EdgeIn { + "from": "", + "name": "c", + "spec": "file:{CWD}/test/fixtures/workspaces-not-root/packages/c", + "type": "workspace", + }, + }, + "isWorkspace": true, + "location": "node_modules/c", + "name": "c", + "path": "{CWD}/test/fixtures/workspaces-not-root/node_modules/c", + "realpath": "{CWD}/test/fixtures/workspaces-not-root/packages/c", + "resolved": "file:../packages/c", + "target": ArboristNode { + "location": "packages/c", + }, + "version": "1.2.3", + }, + "wrappy" => ArboristNode { + "edgesIn": Set { + EdgeIn { + "from": "", + "name": "wrappy", + "spec": "1.0.0", + "type": "prod", + }, + }, + "location": "node_modules/wrappy", + "name": "wrappy", + "path": "{CWD}/test/fixtures/workspaces-not-root/node_modules/wrappy", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.0.tgz", + "version": "1.0.0", + }, + }, + "edgesOut": Map { + "a" => EdgeOut { + "name": "a", + "spec": "file:{CWD}/test/fixtures/workspaces-not-root/packages/a", + "to": "node_modules/a", + "type": "workspace", + }, + "abbrev" => EdgeOut { + "name": "abbrev", + "spec": "*", + "to": "node_modules/abbrev", + "type": "prod", + }, + "b" => EdgeOut { + "name": "b", + "spec": "file:{CWD}/test/fixtures/workspaces-not-root/packages/b", + "to": "node_modules/b", + "type": "workspace", + }, + "c" => EdgeOut { + "name": "c", + "spec": "file:{CWD}/test/fixtures/workspaces-not-root/packages/c", + "to": "node_modules/c", + "type": "workspace", + }, + "wrappy" => EdgeOut { + "name": "wrappy", + "spec": "1.0.0", + "to": "node_modules/wrappy", + "type": "prod", + }, + }, + "fsChildren": Set { + ArboristNode { + "isWorkspace": true, + "location": "packages/a", + "name": "a", + "path": "{CWD}/test/fixtures/workspaces-not-root/packages/a", + "version": "1.2.3", + }, + ArboristNode { + "edgesOut": Map { + "abbrev" => EdgeOut { + "name": "abbrev", + "spec": "*", + "to": "node_modules/abbrev", + "type": "prod", + }, + }, + "isWorkspace": true, + "location": "packages/b", + "name": "b", + "path": "{CWD}/test/fixtures/workspaces-not-root/packages/b", + "version": "1.2.3", + }, + ArboristNode { + "edgesOut": Map { + "a" => EdgeOut { + "name": "a", + "spec": "file:../a", + "to": "node_modules/a", + "type": "prod", + }, + "abbrev" => EdgeOut { + "name": "abbrev", + "spec": "*", + "to": "node_modules/abbrev", + "type": "prod", + }, + }, + "isWorkspace": true, + "location": "packages/c", + "name": "c", + "path": "{CWD}/test/fixtures/workspaces-not-root/packages/c", + "version": "1.2.3", + }, + }, + "isProjectRoot": true, + "location": "", + "name": "workspaces-not-root", + "path": "{CWD}/test/fixtures/workspaces-not-root", + "workspaces": Map { + "a" => "packages/a", + "b" => "packages/b", + "c" => "packages/c", + }, +} +` + exports[`test/arborist/build-ideal-tree.js TAP add packages to workspaces, not root > tree with abbrev removed from a and b 1`] = ` ArboristNode { "children": Map { @@ -36919,6 +37120,53 @@ ArboristNode { } ` +exports[`test/arborist/build-ideal-tree.js TAP inflating a link node in an old lockfile skips registry > must match snapshot 1`] = ` +ArboristNode { + "children": Map { + "link-dep" => ArboristLink { + "edgesIn": Set { + EdgeIn { + "from": "", + "name": "link-dep", + "spec": "file:./link-dep", + "type": "prod", + }, + }, + "location": "node_modules/link-dep", + "name": "link-dep", + "path": "{CWD}/test/fixtures/old-lock-with-link/node_modules/link-dep", + "realpath": "{CWD}/test/fixtures/old-lock-with-link/link-dep", + "resolved": "file:../link-dep", + "target": ArboristNode { + "location": "link-dep", + }, + "version": "1.0.0", + }, + }, + "edgesOut": Map { + "link-dep" => EdgeOut { + "name": "link-dep", + "spec": "file:./link-dep", + "to": "node_modules/link-dep", + "type": "prod", + }, + }, + "fsChildren": Set { + ArboristNode { + "location": "link-dep", + "name": "link-dep", + "path": "{CWD}/test/fixtures/old-lock-with-link/link-dep", + "version": "1.0.0", + }, + }, + "isProjectRoot": true, + "location": "", + "name": "old-lock-with-link", + "path": "{CWD}/test/fixtures/old-lock-with-link", + "version": "1.0.0", +} +` + exports[`test/arborist/build-ideal-tree.js TAP link dep with a link dep > link metadeps with lockfile 1`] = ` ArboristNode { "children": Map { @@ -97677,7 +97925,7 @@ exports[`test/arborist/build-ideal-tree.js TAP store files with a custom indenti { "name": "tab-indented-package-json", "version": "1.0.0", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -97692,13 +97940,6 @@ exports[`test/arborist/build-ideal-tree.js TAP store files with a custom indenti "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" } - }, - "dependencies": { - "abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - } } } @@ -121519,7 +121760,7 @@ ArboristNode { } ` -exports[`test/arborist/build-ideal-tree.js TAP update global > update a single dep 1`] = ` +exports[`test/arborist/build-ideal-tree.js TAP update global > update a single dep, also fixes the invalid node 1`] = ` ArboristNode { "children": Map { "@isaacs/testing-dev-optional-flags" => ArboristNode { @@ -121541,7 +121782,6 @@ ArboristNode { "wrappy" => ArboristNode { "edgesIn": Set { EdgeIn { - "error": "INVALID", "from": "node_modules/@isaacs/testing-dev-optional-flags", "name": "wrappy", "spec": "^1.0.2", @@ -121551,7 +121791,8 @@ ArboristNode { "location": "node_modules/@isaacs/testing-dev-optional-flags/node_modules/wrappy", "name": "wrappy", "path": "{CWD}/test/arborist/tap-testdir-build-ideal-tree-update-global/node_modules/@isaacs/testing-dev-optional-flags/node_modules/wrappy", - "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "version": "1.0.2", }, }, "edgesIn": Set { @@ -121570,7 +121811,6 @@ ArboristNode { "type": "prod", }, "wrappy" => EdgeOut { - "error": "INVALID", "name": "wrappy", "spec": "^1.0.2", "to": "node_modules/@isaacs/testing-dev-optional-flags/node_modules/wrappy", @@ -121771,7 +122011,7 @@ ArboristNode { } ` -exports[`test/arborist/build-ideal-tree.js TAP update global > updating missing dep should have no effect 1`] = ` +exports[`test/arborist/build-ideal-tree.js TAP update global > updating missing dep should have no effect, but fix the invalid node 1`] = ` ArboristNode { "children": Map { "@isaacs/testing-dev-optional-flags" => ArboristNode { @@ -121793,7 +122033,6 @@ ArboristNode { "wrappy" => ArboristNode { "edgesIn": Set { EdgeIn { - "error": "INVALID", "from": "node_modules/@isaacs/testing-dev-optional-flags", "name": "wrappy", "spec": "^1.0.2", @@ -121803,7 +122042,8 @@ ArboristNode { "location": "node_modules/@isaacs/testing-dev-optional-flags/node_modules/wrappy", "name": "wrappy", "path": "{CWD}/test/arborist/tap-testdir-build-ideal-tree-update-global/node_modules/@isaacs/testing-dev-optional-flags/node_modules/wrappy", - "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "version": "1.0.2", }, }, "edgesIn": Set { @@ -121822,7 +122062,6 @@ ArboristNode { "type": "prod", }, "wrappy" => EdgeOut { - "error": "INVALID", "name": "wrappy", "spec": "^1.0.2", "to": "node_modules/@isaacs/testing-dev-optional-flags/node_modules/wrappy", @@ -121894,7 +122133,7 @@ ArboristNode { } ` -exports[`test/arborist/build-ideal-tree.js TAP update global > updating sub-dep has no effect 1`] = ` +exports[`test/arborist/build-ideal-tree.js TAP update global > updating sub-dep has no effect, but fixes the invalid node 1`] = ` ArboristNode { "children": Map { "@isaacs/testing-dev-optional-flags" => ArboristNode { @@ -121916,7 +122155,6 @@ ArboristNode { "wrappy" => ArboristNode { "edgesIn": Set { EdgeIn { - "error": "INVALID", "from": "node_modules/@isaacs/testing-dev-optional-flags", "name": "wrappy", "spec": "^1.0.2", @@ -121926,7 +122164,8 @@ ArboristNode { "location": "node_modules/@isaacs/testing-dev-optional-flags/node_modules/wrappy", "name": "wrappy", "path": "{CWD}/test/arborist/tap-testdir-build-ideal-tree-update-global/node_modules/@isaacs/testing-dev-optional-flags/node_modules/wrappy", - "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "version": "1.0.2", }, }, "edgesIn": Set { @@ -121945,7 +122184,6 @@ ArboristNode { "type": "prod", }, "wrappy" => EdgeOut { - "error": "INVALID", "name": "wrappy", "spec": "^1.0.2", "to": "node_modules/@isaacs/testing-dev-optional-flags/node_modules/wrappy", diff --git a/workspaces/arborist/tap-snapshots/test/arborist/load-actual.js.test.cjs b/workspaces/arborist/tap-snapshots/test/arborist/load-actual.js.test.cjs index b7177c7..35ba9f7 100644 --- a/workspaces/arborist/tap-snapshots/test/arborist/load-actual.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/arborist/load-actual.js.test.cjs @@ -1084,6 +1084,39 @@ ArboristNode { } ` +exports[`test/arborist/load-actual.js TAP do not load from a hidden lockfile when forceActual is set > must match snapshot 1`] = ` +ArboristNode { + "children": Map { + "abbrev" => ArboristNode { + "edgesIn": Set { + EdgeIn { + "from": "", + "name": "abbrev", + "spec": "^1.1.1", + "type": "prod", + }, + }, + "location": "node_modules/abbrev", + "name": "abbrev", + "path": "hidden-lockfile/node_modules/abbrev", + "version": "1.1.1", + }, + }, + "edgesOut": Map { + "abbrev" => EdgeOut { + "name": "abbrev", + "spec": "^1.1.1", + "to": "node_modules/abbrev", + "type": "prod", + }, + }, + "isProjectRoot": true, + "location": "", + "name": "hidden-lockfile", + "path": "hidden-lockfile", +} +` + exports[`test/arborist/load-actual.js TAP external-dep/root > loaded tree 1`] = ` ArboristNode { "edgesOut": Map { @@ -3760,7 +3793,7 @@ ArboristNode { } ` -exports[`test/arborist/load-actual.js TAP load from a hidden lockfile > expect resolving Promise 1`] = ` +exports[`test/arborist/load-actual.js TAP load from a hidden lockfile > must match snapshot 1`] = ` ArboristNode { "children": Map { "abbrev" => ArboristNode { diff --git a/workspaces/arborist/tap-snapshots/test/arborist/pruner.js.test.cjs b/workspaces/arborist/tap-snapshots/test/arborist/pruner.js.test.cjs index 6a814fe..16c732a 100644 --- a/workspaces/arborist/tap-snapshots/test/arborist/pruner.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/arborist/pruner.js.test.cjs @@ -18,20 +18,7 @@ ArboristNode { exports[`test/arborist/pruner.js TAP prune with actual tree omit dev > should keep dev dependencies in package-lock.json 1`] = ` Object { - "dependencies": Object { - "once": Object { - "dev": true, - "requires": Object { - "wrappy": "1", - }, - "version": "1.4.0", - }, - "wrappy": Object { - "dev": true, - "version": "1.0.2", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "prune-actual", "packages": Object { "": Object { diff --git a/workspaces/arborist/tap-snapshots/test/arborist/rebuild.js.test.cjs b/workspaces/arborist/tap-snapshots/test/arborist/rebuild.js.test.cjs index 3a500be..8cd2cfd 100644 --- a/workspaces/arborist/tap-snapshots/test/arborist/rebuild.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/arborist/rebuild.js.test.cjs @@ -26,8 +26,8 @@ Array [ "version": "1.0.0", }, "signal": null, - "stderr": "stderr\\n", - "stdout": "npm_package_dev\\n", + "stderr": "stderr", + "stdout": "npm_package_dev", }, Object { "cmd": "node ../../env.js", @@ -42,8 +42,8 @@ Array [ "version": "1.0.0", }, "signal": null, - "stderr": "stderr\\n", - "stdout": "npm_package_dev_optional\\n", + "stderr": "stderr", + "stdout": "npm_package_dev_optional", }, Object { "cmd": "node ../../env.js", @@ -58,11 +58,10 @@ Array [ "version": "1.0.0", }, "signal": null, - "stderr": "stderr\\n", + "stderr": "stderr", "stdout": String( npm_package_dev npm_package_optional - ), }, Object { @@ -81,8 +80,8 @@ Array [ "version": "1.0.0", }, "signal": null, - "stderr": "stderr\\n", - "stdout": "npm_package_optional\\n", + "stderr": "stderr", + "stdout": "npm_package_optional", }, ] ` diff --git a/workspaces/arborist/tap-snapshots/test/arborist/reify.js.test.cjs b/workspaces/arborist/tap-snapshots/test/arborist/reify.js.test.cjs index ffd568c..4c5a3bc 100644 --- a/workspaces/arborist/tap-snapshots/test/arborist/reify.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/arborist/reify.js.test.cjs @@ -206,7 +206,7 @@ ArboristNode { exports[`test/arborist/reify.js TAP add a new pkg to a prefix that needs to be mkdirpd > should place expected lockfile file into place 1`] = ` { "name": "root", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -219,13 +219,6 @@ exports[`test/arborist/reify.js TAP add a new pkg to a prefix that needs to be m "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" } - }, - "dependencies": { - "abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - } } } @@ -240,58 +233,238 @@ exports[`test/arborist/reify.js TAP add a new pkg to a prefix that needs to be m ` -exports[`test/arborist/reify.js TAP add deps to workspaces add mkdirp 0.5.0 to b > lockfile 1`] = ` +exports[`test/arborist/reify.js TAP add deps to workspaces add a to root > lockfile added workspace as dep 1`] = ` Object { - "dependencies": Object { - "a": Object { + "lockfileVersion": 3, + "name": "tap-testdir-reify-add-deps-to-workspaces-add-a-to-root", + "packages": Object { + "": Object { "dependencies": Object { - "mkdirp": Object { - "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", - "requires": Object { - "minimist": "^1.2.5", - }, - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", - "version": "0.5.5", - }, + "a": "^1.2.3", + "mkdirp": "^1.0.4", }, - "requires": Object { - "mkdirp": "^0.5.0", - }, - "version": "file:packages/a", + "workspaces": Array [ + "packages/*", + ], }, - "b": Object { - "dependencies": Object { - "minimist": Object { - "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", - "version": "0.0.8", - }, - "mkdirp": Object { - "integrity": "sha1-HXMHam35hs2TROFecfzAWkyavxI=", - "requires": Object { - "minimist": "0.0.8", - }, - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.0.tgz", - "version": "0.5.0", - }, - }, - "requires": Object { - "mkdirp": "0.5.0", - }, - "version": "file:packages/b", + "node_modules/a": Object { + "link": true, + "resolved": "packages/a", }, - "minimist": Object { + "node_modules/b": Object { + "link": true, + "resolved": "packages/b", + }, + "node_modules/minimist": Object { "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", "version": "1.2.5", }, - "mkdirp": Object { + "node_modules/mkdirp": Object { + "bin": Object { + "mkdirp": "bin/cmd.js", + }, + "engines": Object { + "node": ">=10", + }, "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", "version": "1.0.4", }, + "packages/a": Object { + "dependencies": Object { + "mkdirp": "^0.5.0", + }, + "version": "1.2.3", + }, + "packages/a/node_modules/mkdirp": Object { + "bin": Object { + "mkdirp": "bin/cmd.js", + }, + "dependencies": Object { + "minimist": "^1.2.5", + }, + "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", + "version": "0.5.5", + }, + "packages/b": Object { + "version": "1.2.3", + }, }, - "lockfileVersion": 2, + "requires": true, +} +` + +exports[`test/arborist/reify.js TAP add deps to workspaces add a to root > package.json added workspace as dep 1`] = ` +Object { + "dependencies": Object { + "a": "^1.2.3", + "mkdirp": "^1.0.4", + }, + "workspaces": Array [ + "packages/*", + ], +} +` + +exports[`test/arborist/reify.js TAP add deps to workspaces add a to root > returned tree 1`] = ` +ArboristNode { + "children": Map { + "a" => ArboristLink { + "edgesIn": Set { + EdgeIn { + "from": "", + "name": "a", + "spec": "file:{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/packages/a", + "type": "workspace", + }, + }, + "isWorkspace": true, + "location": "node_modules/a", + "name": "a", + "path": "{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/node_modules/a", + "realpath": "{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/packages/a", + "resolved": "file:../packages/a", + "target": ArboristNode { + "location": "packages/a", + }, + "version": "1.2.3", + }, + "b" => ArboristLink { + "edgesIn": Set { + EdgeIn { + "from": "", + "name": "b", + "spec": "file:{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/packages/b", + "type": "workspace", + }, + }, + "isWorkspace": true, + "location": "node_modules/b", + "name": "b", + "path": "{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/node_modules/b", + "realpath": "{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/packages/b", + "resolved": "file:../packages/b", + "target": ArboristNode { + "location": "packages/b", + }, + "version": "1.2.3", + }, + "minimist" => ArboristNode { + "edgesIn": Set { + EdgeIn { + "from": "packages/a/node_modules/mkdirp", + "name": "minimist", + "spec": "^1.2.5", + "type": "prod", + }, + }, + "location": "node_modules/minimist", + "name": "minimist", + "path": "{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/node_modules/minimist", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", + "version": "1.2.5", + }, + "mkdirp" => ArboristNode { + "edgesIn": Set { + EdgeIn { + "from": "", + "name": "mkdirp", + "spec": "^1.0.4", + "type": "prod", + }, + }, + "location": "node_modules/mkdirp", + "name": "mkdirp", + "path": "{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/node_modules/mkdirp", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", + "version": "1.0.4", + }, + }, + "edgesOut": Map { + "a" => EdgeOut { + "name": "a", + "spec": "file:{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/packages/a", + "to": "node_modules/a", + "type": "workspace", + }, + "b" => EdgeOut { + "name": "b", + "spec": "file:{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/packages/b", + "to": "node_modules/b", + "type": "workspace", + }, + "mkdirp" => EdgeOut { + "name": "mkdirp", + "spec": "^1.0.4", + "to": "node_modules/mkdirp", + "type": "prod", + }, + }, + "fsChildren": Set { + ArboristNode { + "children": Map { + "mkdirp" => ArboristNode { + "edgesIn": Set { + EdgeIn { + "from": "packages/a", + "name": "mkdirp", + "spec": "^0.5.0", + "type": "prod", + }, + }, + "edgesOut": Map { + "minimist" => EdgeOut { + "name": "minimist", + "spec": "^1.2.5", + "to": "node_modules/minimist", + "type": "prod", + }, + }, + "location": "packages/a/node_modules/mkdirp", + "name": "mkdirp", + "path": "{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/packages/a/node_modules/mkdirp", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", + "version": "0.5.5", + }, + }, + "edgesOut": Map { + "mkdirp" => EdgeOut { + "name": "mkdirp", + "spec": "^0.5.0", + "to": "packages/a/node_modules/mkdirp", + "type": "prod", + }, + }, + "isWorkspace": true, + "location": "packages/a", + "name": "a", + "path": "{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/packages/a", + "version": "1.2.3", + }, + ArboristNode { + "isWorkspace": true, + "location": "packages/b", + "name": "b", + "path": "{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root/packages/b", + "version": "1.2.3", + }, + }, + "isProjectRoot": true, + "location": "", + "name": "tap-testdir-reify-add-deps-to-workspaces-add-a-to-root", + "path": "{CWD}/test/arborist/tap-testdir-reify-add-deps-to-workspaces-add-a-to-root", + "workspaces": Map { + "a" => "packages/a", + "b" => "packages/b", + }, +} +` + +exports[`test/arborist/reify.js TAP add deps to workspaces add mkdirp 0.5.0 to b > lockfile 1`] = ` +Object { + "lockfileVersion": 3, "name": "tap-testdir-reify-add-deps-to-workspaces-add-mkdirp-0.5.0-to-b", "packages": Object { "": Object { @@ -585,56 +758,7 @@ ArboristNode { exports[`test/arborist/reify.js TAP add deps to workspaces add mkdirp 0.5.0 to b, empty start > lockfile 1`] = ` Object { - "dependencies": Object { - "a": Object { - "dependencies": Object { - "mkdirp": Object { - "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", - "requires": Object { - "minimist": "^1.2.5", - }, - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", - "version": "0.5.5", - }, - }, - "requires": Object { - "mkdirp": "^0.5.0", - }, - "version": "file:packages/a", - }, - "b": Object { - "dependencies": Object { - "minimist": Object { - "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", - "version": "0.0.8", - }, - "mkdirp": Object { - "integrity": "sha1-HXMHam35hs2TROFecfzAWkyavxI=", - "requires": Object { - "minimist": "0.0.8", - }, - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.0.tgz", - "version": "0.5.0", - }, - }, - "requires": Object { - "mkdirp": "0.5.0", - }, - "version": "file:packages/b", - }, - "minimist": Object { - "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", - "version": "1.2.5", - }, - "mkdirp": Object { - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "version": "1.0.4", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "tap-testdir-reify-add-deps-to-workspaces-add-mkdirp-0.5.0-to-b-empty-start", "packages": Object { "": Object { @@ -840,38 +964,7 @@ ArboristNode { exports[`test/arborist/reify.js TAP add deps to workspaces no args > lockfile 1`] = ` Object { - "dependencies": Object { - "a": Object { - "dependencies": Object { - "mkdirp": Object { - "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", - "requires": Object { - "minimist": "^1.2.5", - }, - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", - "version": "0.5.5", - }, - }, - "requires": Object { - "mkdirp": "^0.5.0", - }, - "version": "file:packages/a", - }, - "b": Object { - "version": "file:packages/b", - }, - "minimist": Object { - "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", - "version": "1.2.5", - }, - "mkdirp": Object { - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "version": "1.0.4", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "tap-testdir-reify-add-deps-to-workspaces-no-args", "packages": Object { "": Object { @@ -1087,20 +1180,7 @@ ArboristNode { exports[`test/arborist/reify.js TAP add deps to workspaces remove mkdirp from a > lockfile 1`] = ` Object { - "dependencies": Object { - "a": Object { - "version": "file:packages/a", - }, - "b": Object { - "version": "file:packages/b", - }, - "mkdirp": Object { - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "version": "1.0.4", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "tap-testdir-reify-add-deps-to-workspaces-remove-mkdirp-from-a", "packages": Object { "": Object { @@ -1256,20 +1336,7 @@ ArboristNode { exports[`test/arborist/reify.js TAP add deps to workspaces remove mkdirp from a, empty start > lockfile 1`] = ` Object { - "dependencies": Object { - "a": Object { - "version": "file:packages/a", - }, - "b": Object { - "version": "file:packages/b", - }, - "mkdirp": Object { - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "version": "1.0.4", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "tap-testdir-reify-add-deps-to-workspaces-remove-mkdirp-from-a-empty-start", "packages": Object { "": Object { @@ -1385,23 +1452,7 @@ ArboristNode { exports[`test/arborist/reify.js TAP add deps to workspaces upgrade mkdirp in a, dedupe on root > lockfile 1`] = ` Object { - "dependencies": Object { - "a": Object { - "requires": Object { - "mkdirp": "1", - }, - "version": "file:packages/a", - }, - "b": Object { - "version": "file:packages/b", - }, - "mkdirp": Object { - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "version": "1.0.4", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "tap-testdir-reify-add-deps-to-workspaces-upgrade-mkdirp-in-a-dedupe-on-root", "packages": Object { "": Object { @@ -1577,23 +1628,7 @@ ArboristNode { exports[`test/arborist/reify.js TAP add deps to workspaces upgrade mkdirp in a, dedupe on root, empty start > lockfile 1`] = ` Object { - "dependencies": Object { - "a": Object { - "requires": Object { - "mkdirp": "1", - }, - "version": "file:packages/a", - }, - "b": Object { - "version": "file:packages/b", - }, - "mkdirp": Object { - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "version": "1.0.4", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "tap-testdir-reify-add-deps-to-workspaces-upgrade-mkdirp-in-a-dedupe-on-root-empty-start", "packages": Object { "": Object { @@ -1999,19 +2034,6 @@ ArboristNode { "type": "prod", }, }, - "fsChildren": Set { - ArboristNode { - "dev": true, - "extraneous": true, - "location": "target", - "name": "target", - "optional": true, - "packageName": "ABBREV", - "path": "{CWD}/test/arborist/tap-testdir-reify-collide-case-variant-dep-names/target", - "peer": true, - "version": "1.0.0", - }, - }, "isProjectRoot": true, "location": "", "name": "tap-testdir-reify-collide-case-variant-dep-names", @@ -2046,19 +2068,6 @@ ArboristNode { "type": "prod", }, }, - "fsChildren": Set { - ArboristNode { - "dev": true, - "extraneous": true, - "location": "target", - "name": "target", - "optional": true, - "packageName": "ABBREV", - "path": "{CWD}/test/arborist/tap-testdir-reify-collide-case-variant-dep-names/target", - "peer": true, - "version": "1.0.0", - }, - }, "isProjectRoot": true, "location": "", "name": "tap-testdir-reify-collide-case-variant-dep-names", @@ -2409,7 +2418,7 @@ exports[`test/arborist/reify.js TAP do not excessively duplicate bundled metadep { "name": "@isaacs/bundle-metadep-duplication-root", "version": "1.0.0", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "node_modules/@isaacs/bundle-metadep-duplication-x": { @@ -2460,7 +2469,7 @@ exports[`test/arborist/reify.js TAP do not excessively duplicate bundled metadep { "name": "@isaacs/bundle-metadep-duplication-root", "version": "1.0.0", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -2509,46 +2518,6 @@ exports[`test/arborist/reify.js TAP do not excessively duplicate bundled metadep "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" } - }, - "dependencies": { - "@isaacs/bundle-metadep-duplication-x": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@isaacs/bundle-metadep-duplication-x/-/bundle-metadep-duplication-x-1.0.2.tgz", - "integrity": "sha512-mlCA3lXLaraoJFrnZ1sBZeXy4qdYpubKH8jZB5KIjCCwcWPgOui/EWTWnf/wf0Q08V0qr8xmG63wGQgEa+hkSw==", - "requires": { - "@isaacs/bundle-metadep-duplication-y": "1", - "@isaacs/bundle-metadep-duplication-z": "1", - "abbrev": "1" - }, - "dependencies": { - "@isaacs/bundle-metadep-duplication-a": { - "version": "1.0.0", - "bundled": true, - "requires": { - "@isaacs/bundle-metadep-duplication-z": "1" - } - }, - "@isaacs/bundle-metadep-duplication-y": { - "version": "1.0.0", - "bundled": true, - "requires": { - "@isaacs/bundle-metadep-duplication-z": "1" - } - }, - "@isaacs/bundle-metadep-duplication-z": { - "version": "1.0.0", - "bundled": true, - "requires": { - "@isaacs/bundle-metadep-duplication-a": "1" - } - } - } - }, - "abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - } } } @@ -3339,7 +3308,7 @@ ArboristNode { exports[`test/arborist/reify.js TAP filtered reification in workspaces > hidden lockfile - c 1`] = ` { "name": "tap-testdir-reify-filtered-reification-in-workspaces", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "node_modules/c": { @@ -3365,7 +3334,7 @@ exports[`test/arborist/reify.js TAP filtered reification in workspaces > hidden exports[`test/arborist/reify.js TAP filtered reification in workspaces > hidden lockfile - c, old x, removed a 1`] = ` { "name": "tap-testdir-reify-filtered-reification-in-workspaces", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "apps/x": { @@ -3398,7 +3367,7 @@ exports[`test/arborist/reify.js TAP filtered reification in workspaces > hidden exports[`test/arborist/reify.js TAP filtered reification in workspaces > hidden lockfile - c, x 1`] = ` { "name": "tap-testdir-reify-filtered-reification-in-workspaces", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "apps/x": { @@ -3431,7 +3400,7 @@ exports[`test/arborist/reify.js TAP filtered reification in workspaces > hidden exports[`test/arborist/reify.js TAP filtered reification in workspaces > hidden lockfile - c, x, a 1`] = ` { "name": "tap-testdir-reify-filtered-reification-in-workspaces", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "apps/x": { @@ -3488,7 +3457,7 @@ exports[`test/arborist/reify.js TAP filtered reification in workspaces > hidden exports[`test/arborist/reify.js TAP filtered reification in workspaces > hidden lockfile - foo/x linked, c, old x, removed a 1`] = ` { "name": "tap-testdir-reify-filtered-reification-in-workspaces", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "apps/x": { @@ -4349,7 +4318,7 @@ ArboristNode { exports[`test/arborist/reify.js TAP just the shrinkwrap cli-750-fresh > must match snapshot 1`] = ` { "name": "monorepo", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -4372,17 +4341,6 @@ exports[`test/arborist/reify.js TAP just the shrinkwrap cli-750-fresh > must mat "resolved": "lib", "link": true } - }, - "dependencies": { - "app": { - "version": "file:app", - "requires": { - "lib": "file:../lib" - } - }, - "lib": { - "version": "file:lib" - } } } @@ -4391,7 +4349,7 @@ exports[`test/arborist/reify.js TAP just the shrinkwrap cli-750-fresh > must mat exports[`test/arborist/reify.js TAP just the shrinkwrap yarn-lock-mkdirp > must match snapshot 1`] = ` { "name": "tap-testdir-reify-just-the-shrinkwrap-yarn-lock-mkdirp", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -4410,13 +4368,6 @@ exports[`test/arborist/reify.js TAP just the shrinkwrap yarn-lock-mkdirp > must "node": ">=10" } } - }, - "dependencies": { - "mkdirp": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.2.tgz", - "integrity": "sha512-N2REVrJ/X/jGPfit2d7zea2J1pf7EAR5chIUcfHffAZ7gmlam5U65sAm76+o4ntQbSRdTjYf7qZz3chuHlwXEA==" - } } } @@ -17541,7 +17492,7 @@ exports[`test/arborist/reify.js TAP packageLockOnly can add deps > must match sn exports[`test/arborist/reify.js TAP packageLockOnly can add deps > must match snapshot 2`] = ` { "name": "tap-testdir-reify-packageLockOnly-can-add-deps", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -17554,13 +17505,6 @@ exports[`test/arborist/reify.js TAP packageLockOnly can add deps > must match sn "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" } - }, - "dependencies": { - "abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - } } } @@ -17718,14 +17662,7 @@ ArboristNode { exports[`test/arborist/reify.js TAP reify from old package-lock with bins > should add bins entry to package-lock packages entry 1`] = ` Object { - "dependencies": Object { - "ruy": Object { - "integrity": "sha512-VYppDTCM6INWUMKlWiKws4nVMuCNU5h+xjF6lj/0y90rLq017/m8aEpNy4zQSZFV2qz66U/hRZwwlSLJ5l5JMQ==", - "resolved": "https://registry.npmjs.org/ruy/-/ruy-1.0.0.tgz", - "version": "1.0.0", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "old-package-lock-with-bins", "packages": Object { "": Object { @@ -32618,7 +32555,7 @@ exports[`test/arborist/reify.js TAP save complete lockfile on update-all > shoul { "name": "save-package-lock-after-update-test", "version": "1.0.0", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -32633,13 +32570,6 @@ exports[`test/arborist/reify.js TAP save complete lockfile on update-all > shoul "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.4.tgz", "integrity": "sha1-vVWuXkE7oXIu5Mq6H26hBBSlns0=" } - }, - "dependencies": { - "abbrev": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.4.tgz", - "integrity": "sha1-vVWuXkE7oXIu5Mq6H26hBBSlns0=" - } } } @@ -32649,7 +32579,7 @@ exports[`test/arborist/reify.js TAP save complete lockfile on update-all > shoul { "name": "save-package-lock-after-update-test", "version": "1.0.0", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -32664,13 +32594,6 @@ exports[`test/arborist/reify.js TAP save complete lockfile on update-all > shoul "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" } - }, - "dependencies": { - "abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - } } } @@ -32735,7 +32658,7 @@ exports[`test/arborist/reify.js TAP save package.json on update should not save exports[`test/arborist/reify.js TAP save package.json on update should not save many deps in multiple package.json when using save=false > should update lockfile with many deps updated package.json save=false 1`] = ` { "name": "tap-testdir-reify-save-package.json-on-update-should-not-save-many-deps-in-multiple-package.json-when-using-save-false", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -32784,39 +32707,6 @@ exports[`test/arborist/reify.js TAP save package.json on update should not save "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" } - }, - "dependencies": { - "a": { - "version": "file:a", - "requires": { - "abbrev": "^1.0.4", - "once": "^1.3.2" - } - }, - "abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - }, - "b": { - "version": "file:b", - "requires": { - "abbrev": "^1.0.4" - } - }, - "once": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", - "requires": { - "wrappy": "1" - } - }, - "wrappy": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" - } } } @@ -32825,7 +32715,7 @@ exports[`test/arborist/reify.js TAP save package.json on update should not save exports[`test/arborist/reify.js TAP save package.json on update should save many deps in multiple package.json when using save=true > should update lockfile with many deps updated package.json save=true 1`] = ` { "name": "tap-testdir-reify-save-package.json-on-update-should-save-many-deps-in-multiple-package.json-when-using-save-true", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -32874,39 +32764,6 @@ exports[`test/arborist/reify.js TAP save package.json on update should save many "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" } - }, - "dependencies": { - "a": { - "version": "file:a", - "requires": { - "abbrev": "^1.0.4", - "once": "^1.3.2" - } - }, - "abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - }, - "b": { - "version": "file:b", - "requires": { - "abbrev": "^1.0.4" - } - }, - "once": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", - "requires": { - "wrappy": "1" - } - }, - "wrappy": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" - } } } @@ -33095,7 +32952,7 @@ exports[`test/arborist/reify.js TAP save package.json on update should update si exports[`test/arborist/reify.js TAP save proper lockfile with bins when upgrading lockfile complete=false > should upgrade, with bins in place 1`] = ` { "name": "tap-testdir-reify-save-proper-lockfile-with-bins-when-upgrading-lockfile-complete-false", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -33114,13 +32971,6 @@ exports[`test/arborist/reify.js TAP save proper lockfile with bins when upgradin "node": ">=10" } } - }, - "dependencies": { - "semver": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.2.tgz", - "integrity": "sha512-OrOb32TeeambH6UrhtShmF7CRDqhL6/5XpPNp2DuRH6+9QLw/orhp72j87v8Qa1ScDkvrrBNpZcDejAirJmfXQ==" - } } } @@ -33129,7 +32979,7 @@ exports[`test/arborist/reify.js TAP save proper lockfile with bins when upgradin exports[`test/arborist/reify.js TAP save proper lockfile with bins when upgrading lockfile complete=true > should upgrade, with bins in place 1`] = ` { "name": "tap-testdir-reify-save-proper-lockfile-with-bins-when-upgrading-lockfile-complete-true", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -33148,13 +32998,6 @@ exports[`test/arborist/reify.js TAP save proper lockfile with bins when upgradin "node": ">=10" } } - }, - "dependencies": { - "semver": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.2.tgz", - "integrity": "sha512-OrOb32TeeambH6UrhtShmF7CRDqhL6/5XpPNp2DuRH6+9QLw/orhp72j87v8Qa1ScDkvrrBNpZcDejAirJmfXQ==" - } } } @@ -33170,46 +33013,7 @@ exports[`test/arborist/reify.js TAP saveBundle > must match snapshot 1`] = ` exports[`test/arborist/reify.js TAP saving the ideal tree save some stuff > lock after save 1`] = ` Object { - "dependencies": Object { - "a": Object { - "extraneous": true, - "from": "a@git+ssh://git@github.com:foo/bar#baz", - "version": "git+ssh://git@github.com:foo/bar#71f3ccfefba85d2048484569dba8c1829f6f41d7", - }, - "b": Object { - "extraneous": true, - "resolved": "https://registry.npmjs.org/b/-/b-1.2.3.tgz", - "version": "1.2.3", - }, - "c": Object { - "extraneous": true, - "from": "c@git+ssh://git@githost.com:a/b/c.git#master", - "version": "git+ssh://git@githost.com:a/b/c.git#71f3ccfefba85d2048484569dba8c1829f6f41d7", - }, - "d": Object { - "extraneous": true, - "resolved": "https://registry.npmjs.org/c/-/c-1.2.3.tgz", - "version": "npm:c@1.2.3", - }, - "e": Object { - "version": "file:e", - }, - "f": Object { - "extraneous": true, - "from": "f@git+https://user:pass@github.com/baz/quux#asdf", - "version": "git+https://user:pass@github.com/baz/quux#71f3ccfefba85d2048484569dba8c1829f6f41d7", - }, - "g": Object { - "extraneous": true, - "resolved": "https://registry.npmjs.org/g/-/g-1.2.3.tgz", - }, - "h": Object { - "extraneous": true, - "resolved": "https://registry.npmjs.org/h/-/h-1.2.3.tgz", - "version": "1.2.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "tap-testdir-reify-saving-the-ideal-tree-save-some-stuff", "packages": Object { "": Object { @@ -33222,7 +33026,7 @@ Object { "a": "github:foo/bar#baz", "b": "^1.2.3", "d": "npm:c@1.x <1.9.9", - "e": "file:e", + "e": "*", "f": "git+https://user:pass@github.com/baz/quux.git#asdf", "g": "*", "h": "~1.2.3", @@ -33320,7 +33124,7 @@ exports[`test/arborist/reify.js TAP store files with a custom indenting > must m { "name": "tab-indented-package-json", "version": "1.0.0", - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, "packages": { "": { @@ -33335,13 +33139,6 @@ exports[`test/arborist/reify.js TAP store files with a custom indenting > must m "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" } - }, - "dependencies": { - "abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - } } } @@ -34389,16 +34186,6 @@ ArboristNode { } ` -exports[`test/arborist/reify.js TAP update a bundling node without updating all of its deps > contains fsevents in lockfile 1`] = ` -Object { - "dev": true, - "integrity": "sha512-R4wDiBwZ0KzpgOWetKDug1FZcYhqYnUYKtfZYt4mD5SBz76q0KR4Q9o7GIPamsVPGmW3EYPPJ0dOOjvx32ldZA==", - "optional": true, - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.2.tgz", - "version": "2.1.2", -} -` - exports[`test/arborist/reify.js TAP update a bundling node without updating all of its deps > expect resolving Promise 1`] = ` ArboristNode { "children": Map { @@ -46832,15 +46619,15 @@ exports[`test/arborist/reify.js TAP update a yarn.lock file > updated yarn lock # yarn lockfile v1 -"abbrev@^1.1.1": - "integrity" "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - "resolved" "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" - "version" "1.1.1" +abbrev@^1.1.1: + version "1.1.1" + resolved "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" + integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== -"mkdirp@^1.0.2": - "integrity" "sha512-N2REVrJ/X/jGPfit2d7zea2J1pf7EAR5chIUcfHffAZ7gmlam5U65sAm76+o4ntQbSRdTjYf7qZz3chuHlwXEA==" - "resolved" "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.2.tgz" - "version" "1.0.2" +mkdirp@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.2.tgz" + integrity sha512-N2REVrJ/X/jGPfit2d7zea2J1pf7EAR5chIUcfHffAZ7gmlam5U65sAm76+o4ntQbSRdTjYf7qZz3chuHlwXEA== ` @@ -53553,18 +53340,7 @@ ArboristNode { exports[`test/arborist/reify.js TAP workspaces reify workspaces lockfile > should lock workspaces config 1`] = ` Object { - "dependencies": Object { - "a": Object { - "requires": Object { - "b": "^1.0.0", - }, - "version": "file:a", - }, - "b": Object { - "version": "file:b", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "workspace-simple", "packages": Object { "": Object { @@ -53598,47 +53374,7 @@ Object { exports[`test/arborist/reify.js TAP workspaces root as-a-workspace > should produce expected package-lock file 1`] = ` Object { - "dependencies": Object { - "a": Object { - "requires": Object { - "abbrev": "^1.0.0", - }, - "version": "file:a", - }, - "abbrev": Object { - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "version": "1.1.1", - }, - "b": Object { - "version": "file:b", - }, - "workspaces-root-linked": Object { - "dependencies": Object { - "a": Object { - "requires": Object { - "abbrev": "^1.0.0", - }, - "version": "file:a", - }, - "abbrev": Object { - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "version": "1.1.1", - }, - "b": Object { - "version": "file:b", - }, - }, - "requires": Object { - "a": "file:a", - "b": "file:b", - "workspaces-root-linked": "file:", - }, - "version": "file:", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "workspaces-root-linked", "packages": Object { "": Object { diff --git a/workspaces/arborist/tap-snapshots/test/audit-report.js.test.cjs b/workspaces/arborist/tap-snapshots/test/audit-report.js.test.cjs index 3fe331a..cc1354e 100644 --- a/workspaces/arborist/tap-snapshots/test/audit-report.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/audit-report.js.test.cjs @@ -123,6 +123,15 @@ exports[`test/audit-report.js TAP all severity levels > json version 1`] = ` "severity": "high", "range": "<3.0.8 || >=4.0.0 <4.5.3" }, + { + "source": 1325, + "name": "handlebars", + "dependency": "handlebars", + "title": "Prototype Pollution", + "url": "https://npmjs.com/advisories/1325", + "severity": "high", + "range": "<3.0.8 || >=4.0.0 <4.5.3" + }, { "source": 755, "name": "handlebars", @@ -448,6 +457,15 @@ exports[`test/audit-report.js TAP all severity levels > json version 1`] = ` "url": "https://npmjs.com/advisories/1478", "severity": "high", "range": ">=4.1.0" + }, + { + "source": 1479, + "name": "subtext", + "dependency": "subtext", + "title": "Prototype Pollution", + "url": "https://npmjs.com/advisories/1479", + "severity": "high", + "range": ">=0.0.0" } ], "effects": [], @@ -558,6 +576,15 @@ exports[`test/audit-report.js TAP audit outdated nyc and mkdirp > json version 1 "severity": "high", "range": "<3.0.8 || >=4.0.0 <4.5.3" }, + { + "source": 1325, + "name": "handlebars", + "dependency": "handlebars", + "title": "Prototype Pollution", + "url": "https://npmjs.com/advisories/1325", + "severity": "high", + "range": "<3.0.8 || >=4.0.0 <4.5.3" + }, { "source": 755, "name": "handlebars", @@ -918,6 +945,15 @@ exports[`test/audit-report.js TAP audit outdated nyc and mkdirp with before: opt "severity": "high", "range": "<3.0.8 || >=4.0.0 <4.5.3" }, + { + "source": 1325, + "name": "handlebars", + "dependency": "handlebars", + "title": "Prototype Pollution", + "url": "https://npmjs.com/advisories/1325", + "severity": "high", + "range": "<3.0.8 || >=4.0.0 <4.5.3" + }, { "source": 755, "name": "handlebars", @@ -1278,6 +1314,15 @@ exports[`test/audit-report.js TAP audit outdated nyc and mkdirp with newer endpo "severity": "high", "range": "<3.0.8 || >=4.0.0 <4.5.3" }, + { + "source": 1325, + "name": "handlebars", + "dependency": "handlebars", + "title": "Prototype Pollution", + "url": "https://npmjs.com/advisories/1325", + "severity": "high", + "range": "<3.0.8 || >=4.0.0 <4.5.3" + }, { "source": 755, "name": "handlebars", @@ -1627,6 +1672,8 @@ Object { "severity": "moderate", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "acorn", "id": undefined, "name": "acorn", @@ -1652,6 +1699,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "js-yaml", "id": undefined, "name": "js-yaml", @@ -1664,6 +1713,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "js-yaml", "id": undefined, "name": "js-yaml", @@ -1689,6 +1740,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -1701,6 +1754,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -1713,6 +1768,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -1740,6 +1797,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "minimist", "id": undefined, "name": "minimist", @@ -2075,6 +2134,8 @@ Object { "severity": "critical", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2087,6 +2148,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2099,6 +2162,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2111,6 +2176,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2123,6 +2190,22 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, + "dependency": "handlebars", + "id": undefined, + "name": "handlebars", + "range": "<3.0.8 || >=4.0.0 <4.5.3", + "severity": "high", + "source": 1325, + "title": "Prototype Pollution", + "url": "https://npmjs.com/advisories/1325", + "versions": undefined, + "vulnerableVersions": undefined, + }, + Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2156,6 +2239,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "kind-of", "id": undefined, "name": "kind-of", @@ -2181,6 +2266,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -2193,6 +2280,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -2205,6 +2294,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -2236,6 +2327,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "mem", "id": undefined, "name": "mem", @@ -2269,6 +2362,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "minimist", "id": undefined, "name": "minimist", @@ -2294,6 +2389,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "mixin-deep", "id": undefined, "name": "mixin-deep", @@ -2403,6 +2500,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "set-value", "id": undefined, "name": "set-value", @@ -2471,6 +2570,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "yargs-parser", "id": undefined, "name": "yargs-parser", @@ -2526,6 +2627,8 @@ Object { "severity": "critical", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2538,6 +2641,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2550,6 +2655,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2562,6 +2669,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2574,6 +2683,22 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, + "dependency": "handlebars", + "id": undefined, + "name": "handlebars", + "range": "<3.0.8 || >=4.0.0 <4.5.3", + "severity": "high", + "source": 1325, + "title": "Prototype Pollution", + "url": "https://npmjs.com/advisories/1325", + "versions": undefined, + "vulnerableVersions": undefined, + }, + Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2606,6 +2731,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "minimist", "id": undefined, "name": "minimist", @@ -2682,6 +2809,8 @@ Object { "severity": "critical", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2694,6 +2823,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2706,6 +2837,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2718,6 +2851,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2730,6 +2865,22 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, + "dependency": "handlebars", + "id": undefined, + "name": "handlebars", + "range": "<3.0.8 || >=4.0.0 <4.5.3", + "severity": "high", + "source": 1325, + "title": "Prototype Pollution", + "url": "https://npmjs.com/advisories/1325", + "versions": undefined, + "vulnerableVersions": undefined, + }, + Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -2763,6 +2914,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "kind-of", "id": undefined, "name": "kind-of", @@ -2788,6 +2941,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -2800,6 +2955,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -2812,6 +2969,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -2843,6 +3002,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "mem", "id": undefined, "name": "mem", @@ -2876,6 +3037,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "minimist", "id": undefined, "name": "minimist", @@ -2901,6 +3064,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "mixin-deep", "id": undefined, "name": "mixin-deep", @@ -3010,6 +3175,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "set-value", "id": undefined, "name": "set-value", @@ -3078,6 +3245,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "yargs-parser", "id": undefined, "name": "yargs-parser", @@ -3133,6 +3302,8 @@ Object { "severity": "critical", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3145,6 +3316,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3157,6 +3330,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3169,6 +3344,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3181,6 +3358,22 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, + "dependency": "handlebars", + "id": undefined, + "name": "handlebars", + "range": "<3.0.8 || >=4.0.0 <4.5.3", + "severity": "high", + "source": 1325, + "title": "Prototype Pollution", + "url": "https://npmjs.com/advisories/1325", + "versions": undefined, + "vulnerableVersions": undefined, + }, + Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3213,6 +3406,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "minimist", "id": undefined, "name": "minimist", @@ -3309,6 +3504,8 @@ Object { "severity": "critical", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3321,6 +3518,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3333,6 +3532,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3345,6 +3546,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3357,6 +3560,22 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, + "dependency": "handlebars", + "id": undefined, + "name": "handlebars", + "range": "<3.0.8 || >=4.0.0 <4.5.3", + "severity": "high", + "source": 1325, + "title": "Prototype Pollution", + "url": "https://npmjs.com/advisories/1325", + "versions": undefined, + "vulnerableVersions": undefined, + }, + Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3390,6 +3609,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "kind-of", "id": undefined, "name": "kind-of", @@ -3415,6 +3636,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -3427,6 +3650,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -3439,6 +3664,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -3470,6 +3697,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "mem", "id": undefined, "name": "mem", @@ -3502,6 +3731,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "minimist", "id": undefined, "name": "minimist", @@ -3527,6 +3758,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "mixin-deep", "id": undefined, "name": "mixin-deep", @@ -3631,6 +3864,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "set-value", "id": undefined, "name": "set-value", @@ -3699,6 +3934,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "yargs-parser", "id": undefined, "name": "yargs-parser", @@ -3750,6 +3987,8 @@ Object { "severity": "critical", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3762,6 +4001,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3774,6 +4015,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3786,6 +4029,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3798,6 +4043,22 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, + "dependency": "handlebars", + "id": undefined, + "name": "handlebars", + "range": "<3.0.8 || >=4.0.0 <4.5.3", + "severity": "high", + "source": 1325, + "title": "Prototype Pollution", + "url": "https://npmjs.com/advisories/1325", + "versions": undefined, + "vulnerableVersions": undefined, + }, + Object { + "cvss": undefined, + "cwe": undefined, "dependency": "handlebars", "id": undefined, "name": "handlebars", @@ -3831,6 +4092,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "kind-of", "id": undefined, "name": "kind-of", @@ -3856,6 +4119,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -3868,6 +4133,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -3880,6 +4147,8 @@ Object { "vulnerableVersions": undefined, }, Object { + "cvss": undefined, + "cwe": undefined, "dependency": "lodash", "id": undefined, "name": "lodash", @@ -3911,6 +4180,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "mem", "id": undefined, "name": "mem", @@ -3943,6 +4214,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "minimist", "id": undefined, "name": "minimist", @@ -3968,6 +4241,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "mixin-deep", "id": undefined, "name": "mixin-deep", @@ -4072,6 +4347,8 @@ Object { "severity": "high", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "set-value", "id": undefined, "name": "set-value", @@ -4140,6 +4417,8 @@ Object { "severity": "low", "via": Array [ Object { + "cvss": undefined, + "cwe": undefined, "dependency": "yargs-parser", "id": undefined, "name": "yargs-parser", diff --git a/workspaces/arborist/tap-snapshots/test/edge.js.test.cjs b/workspaces/arborist/tap-snapshots/test/edge.js.test.cjs index 6feae28..17dc0b0 100644 --- a/workspaces/arborist/tap-snapshots/test/edge.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/edge.js.test.cjs @@ -88,6 +88,27 @@ Edge { "version": "1.2.3", }, "resolve": Function resolve(n), + "root": Object { + "addEdgeIn": Function addEdgeIn(edge), + "addEdgeOut": Function addEdgeOut(edge), + "edgesIn": Set {}, + "edgesOut": Map { + "missing" => Edge { + "peerConflicted": false, + }, + }, + "explain": Function explain(), + "isTop": true, + "name": "top", + "package": Object { + "name": "top", + "version": "1.2.3", + }, + "packageName": "top", + "parent": null, + "resolve": Function resolve(n), + "version": "1.2.3", + }, "version": "1.2.3", }, "invalid": false, @@ -188,6 +209,27 @@ Edge { "version": "1.2.3", }, "resolve": Function resolve(n), + "root": Object { + "addEdgeIn": Function addEdgeIn(edge), + "addEdgeOut": Function addEdgeOut(edge), + "edgesIn": Set {}, + "edgesOut": Map { + "missing" => Edge { + "peerConflicted": false, + }, + }, + "explain": Function explain(), + "isTop": true, + "name": "top", + "package": Object { + "name": "top", + "version": "1.2.3", + }, + "packageName": "top", + "parent": null, + "resolve": Function resolve(n), + "version": "1.2.3", + }, "version": "1.2.3", }, "invalid": true, @@ -345,6 +387,27 @@ Edge { "version": "1.2.3", }, "resolve": Function resolve(n), + "root": Object { + "addEdgeIn": Function addEdgeIn(edge), + "addEdgeOut": Function addEdgeOut(edge), + "edgesIn": Set {}, + "edgesOut": Map { + "missing" => Edge { + "peerConflicted": false, + }, + }, + "explain": Function explain(), + "isTop": true, + "name": "top", + "package": Object { + "name": "top", + "version": "1.2.3", + }, + "packageName": "top", + "parent": null, + "resolve": Function resolve(n), + "version": "1.2.3", + }, "version": "1.2.3", }, "resolve": Function resolve(n), @@ -414,6 +477,27 @@ Edge { "version": "1.2.3", }, "resolve": Function resolve(n), + "root": Object { + "addEdgeIn": Function addEdgeIn(edge), + "addEdgeOut": Function addEdgeOut(edge), + "edgesIn": Set {}, + "edgesOut": Map { + "missing" => Edge { + "peerConflicted": false, + }, + }, + "explain": Function explain(), + "isTop": true, + "name": "top", + "package": Object { + "name": "top", + "version": "1.2.3", + }, + "packageName": "top", + "parent": null, + "resolve": Function resolve(n), + "version": "1.2.3", + }, "version": "1.2.3", }, "resolve": Function resolve(n), @@ -614,6 +698,27 @@ Edge { "version": "1.2.3", }, "resolve": Function resolve(n), + "root": Object { + "addEdgeIn": Function addEdgeIn(edge), + "addEdgeOut": Function addEdgeOut(edge), + "edgesIn": Set {}, + "edgesOut": Map { + "missing" => Edge { + "peerConflicted": false, + }, + }, + "explain": Function explain(), + "isTop": true, + "name": "top", + "package": Object { + "name": "top", + "version": "1.2.3", + }, + "packageName": "top", + "parent": null, + "resolve": Function resolve(n), + "version": "1.2.3", + }, "version": "1.2.3", }, "resolve": Function resolve(n), @@ -697,6 +802,27 @@ Edge { "version": "1.2.3", }, "resolve": Function resolve(n), + "root": Object { + "addEdgeIn": Function addEdgeIn(edge), + "addEdgeOut": Function addEdgeOut(edge), + "edgesIn": Set {}, + "edgesOut": Map { + "a" => Edge { + "peerConflicted": false, + }, + }, + "explain": Function explain(), + "isTop": true, + "name": "top", + "package": Object { + "name": "top", + "version": "1.2.3", + }, + "packageName": "top", + "parent": null, + "resolve": Function resolve(n), + "version": "1.2.3", + }, "version": "1.2.3", }, "type": "peer", @@ -748,6 +874,27 @@ Edge { "version": "1.2.3", }, "resolve": Function resolve(n), + "root": Object { + "addEdgeIn": Function addEdgeIn(edge), + "addEdgeOut": Function addEdgeOut(edge), + "edgesIn": Set {}, + "edgesOut": Map { + "missing" => Edge { + "peerConflicted": false, + }, + }, + "explain": Function explain(), + "isTop": true, + "name": "top", + "package": Object { + "name": "top", + "version": "1.2.3", + }, + "packageName": "top", + "parent": null, + "resolve": Function resolve(n), + "version": "1.2.3", + }, "version": "1.2.3", }, "invalid": false, @@ -814,6 +961,27 @@ Edge { "version": "1.2.3", }, "resolve": Function resolve(n), + "root": Object { + "addEdgeIn": Function addEdgeIn(edge), + "addEdgeOut": Function addEdgeOut(edge), + "edgesIn": Set {}, + "edgesOut": Map { + "missing" => Edge { + "peerConflicted": false, + }, + }, + "explain": Function explain(), + "isTop": true, + "name": "top", + "package": Object { + "name": "top", + "version": "1.2.3", + }, + "packageName": "top", + "parent": null, + "resolve": Function resolve(n), + "version": "1.2.3", + }, "version": "1.2.3", }, "resolve": Function resolve(n), @@ -868,6 +1036,27 @@ Edge { "version": "1.2.3", }, "resolve": Function resolve(n), + "root": Object { + "addEdgeIn": Function addEdgeIn(edge), + "addEdgeOut": Function addEdgeOut(edge), + "edgesIn": Set {}, + "edgesOut": Map { + "missing" => Edge { + "peerConflicted": false, + }, + }, + "explain": Function explain(), + "isTop": true, + "name": "top", + "package": Object { + "name": "top", + "version": "1.2.3", + }, + "packageName": "top", + "parent": null, + "resolve": Function resolve(n), + "version": "1.2.3", + }, "version": "1.2.3", }, "invalid": false, diff --git a/workspaces/arborist/tap-snapshots/test/link.js.test.cjs b/workspaces/arborist/tap-snapshots/test/link.js.test.cjs index a1b4d87..adffc18 100644 --- a/workspaces/arborist/tap-snapshots/test/link.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/link.js.test.cjs @@ -16,6 +16,7 @@ Link { "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -25,6 +26,7 @@ Link { "optional": true, "path": "/home/user/some/other/path", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/some/kind/of/path", "sourceReference": null, "tops": Set {}, @@ -42,6 +44,7 @@ exports[`test/link.js TAP > instantiate without providing target 1`] = ` "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "../../../../../some/other/path" => <*ref_1>, @@ -56,6 +59,7 @@ exports[`test/link.js TAP > instantiate without providing target 1`] = ` "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -67,6 +71,7 @@ exports[`test/link.js TAP > instantiate without providing target 1`] = ` "optional": true, "path": "/home/user/projects/some/kind/of/path", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/some/kind/of/path", "resolved": null, "sourceReference": null, @@ -80,6 +85,7 @@ exports[`test/link.js TAP > instantiate without providing target 1`] = ` "optional": true, "path": "/home/user/some/other/path", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/some/kind/of/path", "sourceReference": null, "tops": Set { @@ -94,6 +100,7 @@ exports[`test/link.js TAP > instantiate without providing target 1`] = ` "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -105,6 +112,7 @@ exports[`test/link.js TAP > instantiate without providing target 1`] = ` "optional": true, "path": "/home/user/projects/some/kind/of/path", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/some/kind/of/path", "resolved": null, "sourceReference": null, diff --git a/workspaces/arborist/tap-snapshots/test/node.js.test.cjs b/workspaces/arborist/tap-snapshots/test/node.js.test.cjs index cc83ba8..bc571fc 100644 --- a/workspaces/arborist/tap-snapshots/test/node.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/node.js.test.cjs @@ -17,6 +17,7 @@ exports[`test/node.js TAP basic instantiation > just a lone root node 1`] = ` "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -31,7 +32,7 @@ exports[`test/node.js TAP basic instantiation > just a lone root node 1`] = ` "foo" => OverrideSet { "children": Map {}, "key": "foo", - "keySpec": "", + "keySpec": "*", "name": "foo", "parent": <*ref_2>, "value": "1", @@ -41,6 +42,7 @@ exports[`test/node.js TAP basic instantiation > just a lone root node 1`] = ` }, "path": "/home/user/projects/root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root", "resolved": null, "sourceReference": null, @@ -204,6 +206,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -213,6 +216,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/node_modules/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/foo", "sourceReference": null, "tops": Set {}, @@ -227,6 +231,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -236,6 +241,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/node_modules/unknown", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/unknown", "sourceReference": null, "tops": Set {}, @@ -267,6 +273,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -285,6 +292,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -294,6 +302,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/node_modules/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/foo", "sourceReference": null, "tops": Set {}, @@ -304,6 +313,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/foo", "resolved": null, "sourceReference": null, @@ -320,6 +330,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -334,6 +345,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -343,6 +355,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/node_modules/unknown", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/unknown", "sourceReference": null, "tops": Set {}, @@ -353,6 +366,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/unknown", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/unknown", "resolved": null, "sourceReference": null, @@ -360,6 +374,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -377,6 +392,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -386,6 +402,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/node_modules/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/foo", "sourceReference": null, "tops": Set {}, @@ -401,6 +418,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -419,6 +437,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -428,6 +447,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/node_modules/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/foo", "sourceReference": null, "tops": Set {}, @@ -438,6 +458,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/foo", "resolved": null, "sourceReference": null, @@ -453,6 +474,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -462,6 +484,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/node_modules/unknown", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/unknown", "sourceReference": null, "tops": Set {}, @@ -477,6 +500,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -491,6 +515,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -500,6 +525,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/node_modules/unknown", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/unknown", "sourceReference": null, "tops": Set {}, @@ -510,6 +536,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/unknown", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/unknown", "resolved": null, "sourceReference": null, @@ -523,6 +550,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root", "resolved": null, "sourceReference": null, @@ -538,6 +566,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -556,6 +585,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -565,6 +595,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/node_modules/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/foo", "sourceReference": null, "tops": Set {}, @@ -575,6 +606,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/foo", "resolved": null, "sourceReference": null, @@ -591,6 +623,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -605,6 +638,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -614,6 +648,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/node_modules/unknown", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/unknown", "sourceReference": null, "tops": Set {}, @@ -624,6 +659,7 @@ exports[`test/node.js TAP set workspaces > should setup edges out for each works "optional": true, "path": "/home/user/projects/workspaces_root/unknown", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/workspaces_root/unknown", "resolved": null, "sourceReference": null, @@ -650,6 +686,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -659,6 +696,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -684,6 +722,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -693,6 +732,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -733,6 +773,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -742,6 +783,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -749,6 +791,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -758,6 +801,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -785,6 +829,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -794,6 +839,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -814,6 +860,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -823,6 +870,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -843,6 +891,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -852,6 +901,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -872,6 +922,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -881,6 +932,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -897,6 +949,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -906,6 +959,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -930,6 +984,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -944,6 +999,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -953,6 +1009,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -963,6 +1020,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -1000,6 +1058,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -1017,6 +1076,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1026,6 +1086,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -1051,6 +1112,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1060,6 +1122,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -1100,6 +1163,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1109,6 +1173,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -1116,6 +1181,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1125,6 +1191,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -1145,6 +1212,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1154,6 +1222,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -1181,6 +1250,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1190,6 +1260,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -1210,6 +1281,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1219,6 +1291,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -1239,6 +1312,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1248,6 +1322,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -1268,6 +1343,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1277,6 +1353,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -1293,6 +1370,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1302,6 +1380,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -1326,6 +1405,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1340,6 +1420,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1349,6 +1430,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -1359,6 +1441,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -1376,6 +1459,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1385,6 +1469,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -1410,6 +1495,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1419,6 +1505,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -1434,6 +1521,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1443,6 +1531,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -1455,6 +1544,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root", "resolved": null, "sourceReference": null, @@ -1474,6 +1564,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1483,6 +1574,7 @@ exports[`test/node.js TAP testing with dep tree with meta > add new meta under p "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -1519,6 +1611,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1528,6 +1621,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -1568,6 +1662,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1577,6 +1672,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -1584,6 +1680,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1593,6 +1690,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -1620,6 +1718,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1629,6 +1728,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -1649,6 +1749,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1658,6 +1759,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -1678,6 +1780,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1687,6 +1790,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -1707,6 +1811,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1716,6 +1821,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -1732,6 +1838,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1741,6 +1848,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -1778,6 +1886,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -1805,6 +1914,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1814,6 +1924,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -1854,6 +1965,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1863,6 +1975,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -1870,6 +1983,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1879,6 +1993,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -1899,6 +2014,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1908,6 +2024,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -1935,6 +2052,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1944,6 +2062,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -1971,6 +2090,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -1980,6 +2100,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -2000,6 +2121,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2009,6 +2131,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -2029,6 +2152,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2038,6 +2162,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -2058,6 +2183,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2067,6 +2193,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -2083,6 +2210,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2092,6 +2220,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -2105,6 +2234,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root", "resolved": null, "sourceReference": null, @@ -2124,6 +2254,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2133,6 +2264,7 @@ exports[`test/node.js TAP testing with dep tree with meta > initial load with so "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -2181,6 +2313,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2190,6 +2323,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -2197,6 +2331,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2206,6 +2341,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -2233,6 +2369,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2242,6 +2379,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -2262,6 +2400,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2271,6 +2410,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -2291,6 +2431,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2300,6 +2441,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -2320,6 +2462,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2329,6 +2472,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -2345,6 +2489,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2354,6 +2499,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -2384,6 +2530,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2393,6 +2540,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -2430,6 +2578,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -2469,6 +2618,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2478,6 +2628,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -2485,6 +2636,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2494,6 +2646,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -2514,6 +2667,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2523,6 +2677,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -2550,6 +2705,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2559,6 +2715,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -2579,6 +2736,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2588,6 +2746,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -2608,6 +2767,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2617,6 +2777,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -2637,6 +2798,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2646,6 +2808,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -2662,6 +2825,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2671,6 +2835,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -2701,6 +2866,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2710,6 +2876,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -2723,6 +2890,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root", "resolved": null, "sourceReference": null, @@ -2742,6 +2910,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2751,6 +2920,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move meta to top lev "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -2799,6 +2969,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2808,6 +2979,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -2815,6 +2987,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2824,6 +2997,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -2848,6 +3022,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2857,6 +3032,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -2877,6 +3053,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2886,6 +3063,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -2906,6 +3084,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2915,6 +3094,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -2935,6 +3115,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2944,6 +3125,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -2960,6 +3142,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2969,6 +3152,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -2986,6 +3170,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -2995,6 +3180,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -3023,6 +3209,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3037,6 +3224,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3046,6 +3234,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -3056,6 +3245,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -3093,6 +3283,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -3132,6 +3323,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3141,6 +3333,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -3148,6 +3341,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3157,6 +3351,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -3177,6 +3372,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3186,6 +3382,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -3210,6 +3407,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3219,6 +3417,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -3239,6 +3438,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3248,6 +3448,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -3268,6 +3469,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3277,6 +3479,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -3297,6 +3500,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3306,6 +3510,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -3322,6 +3527,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3331,6 +3537,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -3346,6 +3553,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3355,6 +3563,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -3371,6 +3580,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3380,6 +3590,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -3408,6 +3619,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3422,6 +3634,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3431,6 +3644,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -3441,6 +3655,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -3454,6 +3669,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root", "resolved": null, "sourceReference": null, @@ -3473,6 +3689,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3482,6 +3699,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -3530,6 +3748,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3539,6 +3758,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -3546,6 +3766,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3555,6 +3776,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -3579,6 +3801,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3588,6 +3811,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -3608,6 +3832,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3617,6 +3842,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -3637,6 +3863,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3646,6 +3873,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -3666,6 +3894,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3675,6 +3904,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -3691,6 +3921,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3700,6 +3931,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -3717,6 +3949,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3726,6 +3959,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -3754,6 +3988,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3768,6 +4003,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3777,6 +4013,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -3787,6 +4024,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -3824,6 +4062,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -3863,6 +4102,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3872,6 +4112,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -3879,6 +4120,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3888,6 +4130,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -3908,6 +4151,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3917,6 +4161,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -3941,6 +4186,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3950,6 +4196,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -3970,6 +4217,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -3979,6 +4227,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -3999,6 +4248,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4008,6 +4258,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -4028,6 +4279,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4037,6 +4289,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -4053,6 +4306,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4062,6 +4316,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -4077,6 +4332,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4086,6 +4342,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -4102,6 +4359,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4111,6 +4369,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -4139,6 +4398,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4153,6 +4413,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4162,6 +4423,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -4172,6 +4434,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -4185,6 +4448,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root", "resolved": null, "sourceReference": null, @@ -4204,6 +4468,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4213,6 +4478,7 @@ exports[`test/node.js TAP testing with dep tree with meta > move new meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -4239,6 +4505,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4248,6 +4515,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -4273,6 +4541,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4282,6 +4551,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -4322,6 +4592,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4331,6 +4602,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -4338,6 +4610,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4347,6 +4620,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -4374,6 +4648,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4383,6 +4658,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -4403,6 +4679,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4412,6 +4689,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -4432,6 +4710,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4441,6 +4720,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -4461,6 +4741,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4470,6 +4751,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -4486,6 +4768,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4495,6 +4778,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -4519,6 +4803,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4533,6 +4818,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4542,6 +4828,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -4552,6 +4839,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -4589,6 +4877,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -4606,6 +4895,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4615,6 +4905,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -4640,6 +4931,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4649,6 +4941,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -4689,6 +4982,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4698,6 +4992,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -4705,6 +5000,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4714,6 +5010,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -4734,6 +5031,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4743,6 +5041,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -4770,6 +5069,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4779,6 +5079,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -4799,6 +5100,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4808,6 +5110,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -4828,6 +5131,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4837,6 +5141,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -4857,6 +5162,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4866,6 +5172,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -4882,6 +5189,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4891,6 +5199,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -4915,6 +5224,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4929,6 +5239,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4938,6 +5249,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -4948,6 +5260,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -4965,6 +5278,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -4974,6 +5288,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -4999,6 +5314,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5008,6 +5324,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -5023,6 +5340,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5032,6 +5350,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -5044,6 +5363,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root", "resolved": null, "sourceReference": null, @@ -5063,6 +5383,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5072,6 +5393,7 @@ exports[`test/node.js TAP testing with dep tree without meta > add new meta unde "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -5108,6 +5430,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5117,6 +5440,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -5157,6 +5481,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5166,6 +5491,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -5173,6 +5499,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5182,6 +5509,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -5209,6 +5537,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5218,6 +5547,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -5238,6 +5568,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5247,6 +5578,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -5267,6 +5599,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5276,6 +5609,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -5296,6 +5630,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5305,6 +5640,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -5321,6 +5657,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5330,6 +5667,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -5367,6 +5705,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -5394,6 +5733,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5403,6 +5743,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -5443,6 +5784,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5452,6 +5794,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -5459,6 +5802,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5468,6 +5812,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -5488,6 +5833,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5497,6 +5843,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -5524,6 +5871,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5533,6 +5881,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/prod/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -5560,6 +5909,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5569,6 +5919,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -5589,6 +5940,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5598,6 +5950,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -5618,6 +5971,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5627,6 +5981,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -5647,6 +6002,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5656,6 +6012,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -5672,6 +6029,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5681,6 +6039,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -5694,6 +6053,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root", "resolved": null, "sourceReference": null, @@ -5713,6 +6073,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5722,6 +6083,7 @@ exports[`test/node.js TAP testing with dep tree without meta > initial load with "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -5770,6 +6132,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5779,6 +6142,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -5786,6 +6150,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5795,6 +6160,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -5822,6 +6188,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5831,6 +6198,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -5851,6 +6219,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5860,6 +6229,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -5880,6 +6250,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5889,6 +6260,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -5909,6 +6281,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5918,6 +6291,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -5934,6 +6308,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5943,6 +6318,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -5973,6 +6349,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -5982,6 +6359,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -6019,6 +6397,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -6058,6 +6437,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6067,6 +6447,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -6074,6 +6455,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6083,6 +6465,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -6103,6 +6486,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6112,6 +6496,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -6139,6 +6524,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6148,6 +6534,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -6168,6 +6555,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6177,6 +6565,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -6197,6 +6586,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6206,6 +6596,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -6226,6 +6617,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6235,6 +6627,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -6251,6 +6644,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6260,6 +6654,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -6290,6 +6685,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "meta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6299,6 +6695,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "meta", "sourceReference": null, @@ -6312,6 +6709,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root", "resolved": null, "sourceReference": null, @@ -6331,6 +6729,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6340,6 +6739,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move meta to top "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -6388,6 +6788,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6397,6 +6798,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -6404,6 +6806,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6413,6 +6816,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -6437,6 +6841,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6446,6 +6851,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -6466,6 +6872,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6475,6 +6882,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -6495,6 +6903,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6504,6 +6913,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -6524,6 +6934,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6533,6 +6944,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -6549,6 +6961,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6558,6 +6971,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -6575,6 +6989,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6584,6 +6999,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -6612,6 +7028,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6626,6 +7043,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6635,6 +7053,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -6645,6 +7064,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -6682,6 +7102,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -6721,6 +7142,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6730,6 +7152,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -6737,6 +7160,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6746,6 +7170,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -6766,6 +7191,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6775,6 +7201,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -6799,6 +7226,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6808,6 +7236,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -6828,6 +7257,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6837,6 +7267,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -6857,6 +7288,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6866,6 +7298,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -6886,6 +7319,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6895,6 +7329,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -6911,6 +7346,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6920,6 +7356,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -6935,6 +7372,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6944,6 +7382,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -6960,6 +7399,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -6969,6 +7409,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -6997,6 +7438,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7011,6 +7453,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7020,6 +7463,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -7030,6 +7474,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -7043,6 +7488,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root", "resolved": null, "sourceReference": null, @@ -7062,6 +7508,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7071,6 +7518,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -7119,6 +7567,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7128,6 +7577,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -7135,6 +7585,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7144,6 +7595,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -7168,6 +7620,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7177,6 +7630,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -7197,6 +7651,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7206,6 +7661,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -7226,6 +7682,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7235,6 +7692,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -7255,6 +7713,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7264,6 +7723,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -7280,6 +7740,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7289,6 +7750,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -7306,6 +7768,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7315,6 +7778,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -7343,6 +7807,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7357,6 +7822,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7366,6 +7832,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -7376,6 +7843,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -7413,6 +7881,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory { "" => <*ref_1>, @@ -7452,6 +7921,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7461,6 +7931,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -7468,6 +7939,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to }, }, "hasShrinkwrap": false, + "installLinks": false, "integrity": "prod", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7477,6 +7949,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod", "resolved": "prod", "sourceReference": null, @@ -7497,6 +7970,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7506,6 +7980,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, @@ -7530,6 +8005,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "bundled", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7539,6 +8015,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/bundled", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/bundled", "resolved": "bundled", "sourceReference": null, @@ -7559,6 +8036,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "dev", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7568,6 +8046,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/dev", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/dev", "resolved": "dev", "sourceReference": null, @@ -7588,6 +8067,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "opt", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7597,6 +8077,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/optional", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/optional", "resolved": "opt", "sourceReference": null, @@ -7617,6 +8098,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "peer", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7626,6 +8108,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/peer", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/peer", "resolved": "peer", "sourceReference": null, @@ -7642,6 +8125,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "extraneous", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7651,6 +8135,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/extraneous", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/extraneous", "resolved": "extraneous", "sourceReference": null, @@ -7666,6 +8151,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7675,6 +8161,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -7691,6 +8178,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7700,6 +8188,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -7728,6 +8217,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "newMeta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7742,6 +8232,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": "metameta", "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7751,6 +8242,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta/node_modules/metameta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "sourceReference": null, "tops": Set {}, @@ -7761,6 +8253,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/meta", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/meta", "resolved": "newMeta", "sourceReference": null, @@ -7774,6 +8267,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root", "resolved": null, "sourceReference": null, @@ -7793,6 +8287,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "extraneous": true, "fsChildren": Set {}, "hasShrinkwrap": false, + "installLinks": false, "integrity": null, "inventory": Inventory {}, "legacyPeerDeps": false, @@ -7802,6 +8297,7 @@ exports[`test/node.js TAP testing with dep tree without meta > move new meta to "optional": true, "path": "/home/user/projects/root/node_modules/prod/foo", "peer": true, + "queryContext": Object {}, "realpath": "/home/user/projects/root/node_modules/prod/foo", "resolved": null, "sourceReference": null, diff --git a/workspaces/arborist/tap-snapshots/test/place-dep.js.test.cjs b/workspaces/arborist/tap-snapshots/test/place-dep.js.test.cjs index 9929906..99acc59 100644 --- a/workspaces/arborist/tap-snapshots/test/place-dep.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/place-dep.js.test.cjs @@ -15,7 +15,7 @@ exports[`test/place-dep.js TAP placement tests accept an older transitive depend Array [ Object { "canPlace": null, - "canPlaceSelf": undefined, + "canPlaceSelf": null, "checks": Map {}, "dep": "bar@1.0.1", "edge": "{ node_modules/foo prod bar@1 }", @@ -3553,7 +3553,7 @@ exports[`test/place-dep.js TAP placement tests fail with ERESOLVE on deep peer d Array [ Object { "canPlace": null, - "canPlaceSelf": undefined, + "canPlaceSelf": null, "checks": Map {}, "dep": "b@2.0.0", "edge": "{ ROOT prod b@2 }", @@ -6629,7 +6629,7 @@ exports[`test/place-dep.js TAP placement tests prod dep directly on conflicted p Array [ Object { "canPlace": null, - "canPlaceSelf": undefined, + "canPlaceSelf": null, "checks": Map {}, "dep": "b@2.0.0", "edge": "{ ROOT prod b@2 }", @@ -8136,7 +8136,7 @@ exports[`test/place-dep.js TAP placement tests prod dep directly on conflicted p Array [ Object { "canPlace": null, - "canPlaceSelf": undefined, + "canPlaceSelf": null, "checks": Map {}, "dep": "b@1.0.0", "edge": "{ ROOT prod b@1 }", @@ -10627,7 +10627,7 @@ exports[`test/place-dep.js TAP placement tests upgrade a transitive dependency > Array [ Object { "canPlace": null, - "canPlaceSelf": undefined, + "canPlaceSelf": null, "checks": Map {}, "dep": "bar@1.0.1", "edge": "{ node_modules/foo prod bar@1 }", diff --git a/workspaces/arborist/tap-snapshots/test/printable.js.test.cjs b/workspaces/arborist/tap-snapshots/test/printable.js.test.cjs index 3a9a283..ce2396d 100644 --- a/workspaces/arborist/tap-snapshots/test/printable.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/printable.js.test.cjs @@ -564,24 +564,24 @@ version:'1.0.0', location:'', path:'/some/path', isProjectRoot:true, -overrides:Map{'foo@1' => '2.0.0', 'bar' => '2.0.0'}, -edgesOut:Map{ -'bar' =>{prod bar@^1.0.0 overridden:2.0.0 -> node_modules/bar}, -'foo' =>{prod foo@^1.0.0 overridden:2.0.0 -> node_modules/foo}}, +overrides:Map{'bar' => '2.0.0'}, +edgesOut:Map{'foo' =>{prod foo@^1.0.0 -> node_modules/foo}}, children:Map{ 'bar' =>{ name:'bar', version:'2.0.0', location:'node_modules/bar', path:'/some/path/node_modules/bar', -overrides:Map{'bar' => '2.0.0', 'foo@1' => '2.0.0'}, -edgesIn:Set{{"" prod bar@^1.0.0}}}, +overrides:Map{'bar' => '2.0.0'}, +edgesIn:Set{{node_modules/foo prod bar@^1.0.0}}}, 'foo' =>{ name:'foo', -version:'2.0.0', +version:'1.0.0', location:'node_modules/foo', path:'/some/path/node_modules/foo', -overrides:Map{'foo@1' => '2.0.0', 'bar' => '2.0.0'}, +overrides:Map{'bar' => '2.0.0'}, +edgesOut:Map{ +'bar' =>{prod bar@^1.0.0 overridden:2.0.0 -> node_modules/bar}}, edgesIn:Set{{"" prod foo@^1.0.0}}}}} ` diff --git a/workspaces/arborist/tap-snapshots/test/shrinkwrap.js.test.cjs b/workspaces/arborist/tap-snapshots/test/shrinkwrap.js.test.cjs index 93f6e8a..1b5a393 100644 --- a/workspaces/arborist/tap-snapshots/test/shrinkwrap.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/shrinkwrap.js.test.cjs @@ -13,7 +13,7 @@ Object { "version": "file:mkdirp", }, }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -42,9 +42,9 @@ exports[`test/shrinkwrap.js TAP a yarn.lock entry with file: resolved > yarn.loc "mkdirp@file:mkdirp": - "integrity" "sha512-N2REVrJ/X/jGPfit2d7zea2J1pf7EAR5chIUcfHffAZ7gmlam5U65sAm76+o4ntQbSRdTjYf7qZz3chuHlwXEA==" - "resolved" "file:mkdirp" - "version" "1.0.2" + version "1.0.2" + resolved "file:mkdirp" + integrity sha512-N2REVrJ/X/jGPfit2d7zea2J1pf7EAR5chIUcfHffAZ7gmlam5U65sAm76+o4ntQbSRdTjYf7qZz3chuHlwXEA== ` @@ -57,7 +57,7 @@ Object { "version": "1.0.2", }, }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -83,10 +83,10 @@ exports[`test/shrinkwrap.js TAP a yarn.lock entry with integrity mismatch > yarn # yarn lockfile v1 -"mkdirp@^1.0.2": - "integrity" "sha512-N2REVrJ/X/jGPfit2d7zea2J1pf7EAR5chIUcfHffAZ7gmlam5U65sAm76+o4ntQbSRdTjYf7qZz3chuHlwXEA==" - "resolved" "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.2.tgz" - "version" "1.0.2" +mkdirp@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.2.tgz" + integrity sha512-N2REVrJ/X/jGPfit2d7zea2J1pf7EAR5chIUcfHffAZ7gmlam5U65sAm76+o4ntQbSRdTjYf7qZz3chuHlwXEA== ` @@ -98,7 +98,7 @@ Object { "version": "1.0.2", }, }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -123,9 +123,9 @@ exports[`test/shrinkwrap.js TAP a yarn.lock entry with no integrity > yarn.lock # yarn lockfile v1 -"mkdirp@^1.0.2": - "resolved" "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.2.tgz" - "version" "1.0.2" +mkdirp@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.2.tgz" ` @@ -137,7 +137,7 @@ Object { "version": "1.0.2", }, }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -162,9 +162,9 @@ exports[`test/shrinkwrap.js TAP a yarn.lock entry with no resolved > yarn.lock 1 # yarn lockfile v1 -"mkdirp@^1.0.2": - "integrity" "sha512-N2REVrJ/X/jGPfit2d7zea2J1pf7EAR5chIUcfHffAZ7gmlam5U65sAm76+o4ntQbSRdTjYf7qZz3chuHlwXEA==" - "version" "1.0.2" +mkdirp@^1.0.2: + version "1.0.2" + integrity sha512-N2REVrJ/X/jGPfit2d7zea2J1pf7EAR5chIUcfHffAZ7gmlam5U65sAm76+o4ntQbSRdTjYf7qZz3chuHlwXEA== ` @@ -175,7 +175,7 @@ Object { "version": "1.0.4", }, }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -199,8 +199,8 @@ exports[`test/shrinkwrap.js TAP a yarn.lock entry with version mismatch > yarn.l # yarn lockfile v1 -"mkdirp@^1.0.2": - "version" "1.0.4" +mkdirp@^1.0.2: + version "1.0.4" ` @@ -211,7 +211,7 @@ Object { "version": "1.0.4", }, }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -235,8 +235,8 @@ exports[`test/shrinkwrap.js TAP a yarn.lock with no entries > yarn.lock 1`] = ` # yarn lockfile v1 -"mkdirp@^1.0.2": - "version" "1.0.4" +mkdirp@^1.0.2: + version "1.0.4" ` @@ -272,93 +272,7 @@ Object { exports[`test/shrinkwrap.js TAP construct metadata from node and package data > data calculated from nodes themselves 1`] = ` Object { - "dependencies": Object { - "a": Object { - "integrity": "sha512-helloyesthisisdog", - "resolved": "https://example.com/a.tgz", - "version": "1.2.3", - }, - "d": Object { - "dependencies": Object { - "bundled": Object { - "bundled": true, - "dev": true, - "version": "npm:not-bundled-tho@1.2.3", - }, - "git-dep": Object { - "dev": true, - "from": "git-dep@github:foo/bar", - "version": "git+ssh://git@github.com/foo/bar.git#0000000000000000000000000000000000000000", - }, - }, - "dev": true, - "requires": Object { - "bundled": "npm:not-bundled-tho@*", - "e": "1.2.3", - "git-dep": "github:foo/bar", - }, - "version": "1.2.3", - }, - "devit": Object { - "dev": true, - "requires": Object { - "devo": "", - }, - "version": "1.2.3", - }, - "devo": Object { - "devOptional": true, - "version": "1.2.3", - }, - "e": Object { - "dev": true, - "requires": Object { - "tgz": "", - "tgz-pkg-resolved": "", - }, - "version": "https://foo.com/e.tgz", - }, - "link": Object { - "version": "file:target", - }, - "nopkg": Object { - "extraneous": true, - }, - "optin": Object { - "optional": true, - "requires": Object { - "devo": "", - }, - "version": "1.2.3", - }, - "peer": Object { - "dependencies": Object { - "peerdep": Object { - "integrity": "sha512-peerdeppeerdep", - "peer": true, - "resolved": "https://peer.com/peerdep.tgz", - "version": "1.2.3", - }, - }, - "integrity": "sha512-peerpeerpeer", - "peer": true, - "requires": Object { - "peerdep": "", - }, - "resolved": "https://peer.com/peer.tgz", - "version": "1.2.3", - }, - "tgz": Object { - "dev": true, - "version": "1.2.3", - }, - "tgz-pkg-resolved": Object { - "dev": true, - "integrity": "sha512-tarball/package/resolved/integrity", - "version": "1.2.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -678,13 +592,7 @@ Object { exports[`test/shrinkwrap.js TAP handle missing dependencies object without borking > must match snapshot 1`] = ` Object { - "dependencies": Object { - "foo": Object { - "integrity": "foo integrity", - "resolved": "http://foo.com", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "packages": Object { "node_modules/foo": Object {}, }, @@ -916,7 +824,7 @@ Object { "version": "1.0.2", }, }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "a", "packages": Object { "": Object { @@ -1168,7 +1076,7 @@ Object { "version": "1.0.2", }, }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "dev-deps", "packages": Object { "": Object { @@ -1228,10 +1136,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests bundle > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "dep": Object {}, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "bundle", "packages": Object { "": Object { @@ -1253,71 +1158,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests deepmixedloop > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "a": Object { - "optional": true, - "requires": Object { - "b": "", - }, - "version": "1.2.3", - }, - "b": Object { - "optional": true, - "requires": Object { - "c": "", - }, - "version": "1.2.3", - }, - "c": Object { - "optional": true, - "requires": Object { - "d": "", - }, - "version": "1.2.3", - }, - "d": Object { - "optional": true, - "requires": Object { - "e": "", - }, - "version": "1.2.3", - }, - "e": Object { - "optional": true, - "version": "1.2.3", - }, - "i": Object { - "dev": true, - "requires": Object { - "j": "", - }, - }, - "j": Object { - "dev": true, - "requires": Object { - "k": "", - }, - }, - "k": Object { - "dev": true, - }, - "x": Object { - "requires": Object { - "y": "", - }, - }, - "y": Object { - "requires": Object { - "z": "", - }, - }, - "z": Object { - "requires": Object { - "a": "", - }, - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -1398,72 +1239,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests deeproot/root > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "@scope/x": Object { - "dependencies": Object { - "glob": Object { - "dependencies": Object { - "graceful-fs": Object { - "version": "3.0.2", - }, - "inherits": Object { - "version": "2.0.1", - }, - "minimatch": Object { - "dependencies": Object { - "lru-cache": Object { - "version": "2.5.0", - }, - "sigmund": Object { - "version": "1.0.0", - }, - }, - "requires": Object { - "lru-cache": "", - "once": "", - "sigmund": "", - }, - "version": "1.0.0", - }, - "once": Object { - "version": "1.3.0", - }, - }, - "requires": Object { - "graceful-fs": "", - "inherits": "", - "minimatch": "", - "once": "", - }, - "version": "4.0.5", - }, - }, - "requires": Object { - "@scope/y": "", - "glob": "4", - }, - "version": "1.2.3", - }, - "@scope/y": Object { - "requires": Object { - "foo": "99.x", - }, - "version": "1.2.3", - }, - "foo": Object { - "dependencies": Object { - "express": Object { - "version": "npm:abbrev@1.1.1", - }, - }, - "requires": Object { - "@scope/x": "", - "express": "npm:abbrev@*", - }, - "version": "1.2.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -1554,32 +1330,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests devloop > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "a": Object { - "dev": true, - "requires": Object { - "b": "", - "d": "", - }, - "version": "1.2.3", - }, - "b": Object { - "version": "1.2.3", - }, - "c": Object { - "requires": Object { - "d": "", - }, - "version": "1.2.3", - }, - "d": Object { - "requires": Object { - "b": "", - }, - "version": "1.2.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "devloop", "packages": Object { "": Object { @@ -1621,7 +1372,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests external-dep/root > shrinkwrap data 1`] = ` Object { - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -1639,21 +1390,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests external-link-cached-dummy-dep/root > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "x": Object { - "requires": Object { - "y": "", - }, - "version": "file:../a/node_modules/b/node_modules/x", - }, - "z": Object { - "requires": Object { - "b": "", - }, - "version": "file:../a/t/u/v/w/x/y/z", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -1813,185 +1550,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests install-types > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "abbrev": Object { - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "version": "1.1.1", - }, - "balanced-match": Object { - "extraneous": true, - "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", - "version": "1.0.0", - }, - "brace-expansion": Object { - "extraneous": true, - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "requires": Object { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1", - }, - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "version": "1.1.11", - }, - "bundler": Object { - "dependencies": Object { - "a": Object { - "bundled": true, - "integrity": "sha1-3Klr13/Wjfd5OnMDajug1UBdR3s=", - "requires": Object { - "b": "", - }, - "resolved": "https://registry.internal/a/-/a-1.2.3.tgz", - "version": "1.2.3", - }, - "b": Object { - "bundled": true, - "integrity": "sha1-4Klr13/Wjfd5OnMDajug1UBdR3s=", - "requires": Object { - "c": "", - }, - "resolved": "https://registry.internal/b/-/b-1.2.3.tgz", - "version": "1.2.3", - }, - "c": Object { - "bundled": true, - "integrity": "sha1-5Klr13/Wjfd5OnMDajug1UBdR3s=", - "resolved": "https://registry.internal/c/-/c-1.2.3.tgz", - "version": "1.2.3", - }, - }, - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", - "requires": Object { - "a": "", - }, - "resolved": "https://registry.internal/bundler/-/bundler-1.2.3.tgz", - "version": "1.2.3", - }, - "concat-map": Object { - "extraneous": true, - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "version": "0.0.1", - }, - "fs.realpath": Object { - "extraneous": true, - "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "version": "1.0.0", - }, - "full-git-url": Object { - "from": "full-git-url@git+https://github.com/isaacs/abbrev-js.git", - "version": "git+ssh://git@github.com/isaacs/abbrev-js.git#a9ee72ebc8fe3975f1b0c7aeb3a8f2a806a432eb", - }, - "ghshort": Object { - "from": "ghshort@github:isaacs/abbrev-js", - "version": "git+ssh://git@github.com/isaacs/abbrev-js.git#a9ee72ebc8fe3975f1b0c7aeb3a8f2a806a432eb", - }, - "ghtgz": Object { - "extraneous": true, - "integrity": "sha512-yowslMd9y/lGBCDVO0RwZoXRK5X0zMsf6XECM6DdeqN7qwVnFQ6IAwJai7BD4mVe1xOdWWqWNkuzyuStvSBnHw==", - "version": "https://codeload.github.com/isaacs/abbrev-js/tar.gz/a9ee72ebc8fe3975f1b0c7aeb3a8f2a806a432eb", - }, - "glob": Object { - "extraneous": true, - "integrity": "sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A==", - "requires": Object { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.4.tgz", - "version": "7.1.4", - }, - "inflight": Object { - "extraneous": true, - "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", - "requires": Object { - "once": "^1.3.0", - "wrappy": "1", - }, - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "version": "1.0.6", - }, - "inherits": Object { - "extraneous": true, - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "version": "2.0.4", - }, - "minimatch": Object { - "extraneous": true, - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "requires": Object { - "brace-expansion": "^1.1.7", - }, - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "version": "3.0.4", - }, - "old": Object { - "integrity": "sha1-qgScln+ZkiKqQuFENPDFYu9GgkE=", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.3.tgz", - "version": "npm:abbrev@1.0.3", - }, - "once": Object { - "extraneous": true, - "integrity": "sha512-oic2VxBO6ZRyhk4W/amcN3D4tGpSELjpXwShWPBHNVDvVXo2+JcNnNx6Dth+Y961vfz7SmCCc6RP2oNQE2yVwQ==", - "requires": Object { - "wrappy": "1", - }, - "version": "1.4.0", - }, - "path-is-absolute": Object { - "extraneous": true, - "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "version": "1.0.1", - }, - "pinned": Object { - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "version": "npm:abbrev@1.1.1", - }, - "reg": Object { - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", - "resolved": "https://localhost:8080/abbrev/-/abbrev-1.1.1.tgz", - "version": "npm:abbrev@1.1.1", - }, - "remote": Object { - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", - "version": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - }, - "rimraf": Object { - "extraneous": true, - "integrity": "sha512-hKCr1HweNbIu6JN4K8WYBwikeg2ISRHU2D7OTX0fivTb+2dOM7mITni0cAjgWCsNGUQDFI+4BTNeGBVp/WbBow==", - "requires": Object { - "glob": "^7.1.3", - }, - "version": "file:rimraf-2.6.3.tgz", - }, - "symlink": Object { - "requires": Object { - "tap": "^14.4.1", - }, - "version": "file:abbrev-link-target", - }, - "tarball": Object { - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", - "version": "file:abbrev-1.1.1.tgz", - }, - "wrappy": Object { - "extraneous": true, - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", - "resolved": "https://localhost:8080/wrappy/-/wrappy-1.0.2.tgz", - "version": "1.0.2", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "a", "packages": Object { "": Object { @@ -2249,37 +1808,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests link-dep-cycle > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "a": Object { - "dependencies": Object { - "b": Object { - "requires": Object { - "a": "file:../a", - }, - "version": "file:b", - }, - }, - "requires": Object { - "b": "file:../b", - }, - "version": "file:a", - }, - "b": Object { - "dependencies": Object { - "a": Object { - "requires": Object { - "b": "file:../b", - }, - "version": "file:a", - }, - }, - "requires": Object { - "a": "file:../a", - }, - "version": "file:b", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "link-dep-cycle", "packages": Object { "": Object { @@ -2321,33 +1850,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests link-dep-nested > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "foo": Object { - "dependencies": Object { - "wrappy": Object { - "version": "1.0.2", - }, - }, - "requires": Object { - "tap": "^7.0.1", - "wrappy": "1", - }, - "version": "file:once", - }, - "once": Object { - "dependencies": Object { - "wrappy": Object { - "version": "1.0.2", - }, - }, - "requires": Object { - "tap": "^7.0.1", - "wrappy": "1", - }, - "version": "file:once", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "nested-thingies", "packages": Object { "": Object { @@ -2388,42 +1891,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests link-dep-nested/root > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "bork": Object { - "dependencies": Object { - "foo": Object { - "dependencies": Object { - "wrappy": Object { - "version": "1.0.2", - }, - }, - "requires": Object { - "tap": "^7.0.1", - "wrappy": "1", - }, - "version": "file:../once", - }, - "once": Object { - "dependencies": Object { - "wrappy": Object { - "version": "1.0.2", - }, - }, - "requires": Object { - "tap": "^7.0.1", - "wrappy": "1", - }, - "version": "file:../once", - }, - }, - "requires": Object { - "foo": "file:once", - "once": "file:once", - }, - "version": "file:..", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -2475,72 +1943,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests linkedroot > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "@scope/x": Object { - "dependencies": Object { - "glob": Object { - "dependencies": Object { - "graceful-fs": Object { - "version": "3.0.2", - }, - "inherits": Object { - "version": "2.0.1", - }, - "minimatch": Object { - "dependencies": Object { - "lru-cache": Object { - "version": "2.5.0", - }, - "sigmund": Object { - "version": "1.0.0", - }, - }, - "requires": Object { - "lru-cache": "", - "once": "", - "sigmund": "", - }, - "version": "1.0.0", - }, - "once": Object { - "version": "1.3.0", - }, - }, - "requires": Object { - "graceful-fs": "", - "inherits": "", - "minimatch": "", - "once": "", - }, - "version": "4.0.5", - }, - }, - "requires": Object { - "@scope/y": "", - "glob": "4", - }, - "version": "1.2.3", - }, - "@scope/y": Object { - "requires": Object { - "foo": "99.x", - }, - "version": "1.2.3", - }, - "foo": Object { - "dependencies": Object { - "express": Object { - "version": "npm:abbrev@1.1.1", - }, - }, - "requires": Object { - "@scope/x": "", - "express": "npm:abbrev@*", - }, - "version": "1.2.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -2631,98 +2034,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests links-all-over > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "link-deep": Object { - "dependencies": Object { - "deep-a": Object { - "version": "1.2.3", - }, - }, - "requires": Object { - "a": "", - "deep-a": "", - }, - "version": "file:node_modules/nest/node_modules/a/node_modules/b/node_modules/c/node_modules/d/node_modules/deep", - }, - "link-link": Object { - "dependencies": Object { - "deep-a": Object { - "version": "1.2.3", - }, - }, - "requires": Object { - "a": "", - "deep-a": "", - }, - "version": "file:node_modules/nest/node_modules/a/node_modules/b/node_modules/c/node_modules/d/node_modules/deep", - }, - "link-outside-nest": Object { - "requires": Object { - "link-link": "", - }, - "version": "file:real", - }, - "nest": Object { - "dependencies": Object { - "a": Object { - "dependencies": Object { - "b": Object { - "dependencies": Object { - "c": Object { - "dependencies": Object { - "d": Object { - "dependencies": Object { - "deep": Object { - "dependencies": Object { - "deep-a": Object { - "version": "1.2.3", - }, - }, - "requires": Object { - "a": "", - "deep-a": "", - }, - "version": "1.2.3", - }, - }, - "requires": Object { - "deep": "", - }, - "version": "1.2.3", - }, - }, - "requires": Object { - "d": "", - }, - "version": "1.2.3", - }, - }, - "requires": Object { - "c": "", - }, - "version": "1.2.3", - }, - }, - "requires": Object { - "b": "", - }, - "version": "1.2.3", - }, - "link-in-nest": Object { - "requires": Object { - "link-link": "", - }, - "version": "file:real", - }, - }, - "requires": Object { - "a": "", - "link-in-nest": "", - }, - "version": "1.2.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "links-all-over", "packages": Object { "": Object { @@ -2806,41 +2118,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests mixedloop > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "a": Object { - "optional": true, - "requires": Object { - "b": "", - }, - "version": "1.1.1", - }, - "b": Object { - "optional": true, - "requires": Object { - "c": "", - }, - "version": "1.2.3", - }, - "c": Object { - "devOptional": true, - "requires": Object { - "d": "", - }, - "version": "1.2.3", - }, - "d": Object { - "devOptional": true, - "requires": Object { - "e": "", - }, - "version": "1.2.3", - }, - "e": Object { - "devOptional": true, - "version": "1.2.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -2891,74 +2169,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests mixedmidway > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "a": Object { - "optional": true, - "requires": Object { - "b": "", - }, - "version": "1.2.3", - }, - "b": Object { - "optional": true, - "requires": Object { - "c": "", - "j": "", - }, - "version": "1.2.3", - }, - "c": Object { - "devOptional": true, - "version": "1.2.3", - }, - "i": Object { - "dev": true, - "requires": Object { - "j": "", - }, - }, - "j": Object { - "devOptional": true, - "requires": Object { - "k": "", - }, - }, - "k": Object { - "devOptional": true, - "requires": Object { - "c": "", - }, - }, - "l": Object { - "requires": Object { - "m": "", - }, - }, - "m": Object {}, - "n": Object { - "extraneous": true, - "requires": Object { - "b": "", - "j": "", - }, - }, - "x": Object { - "requires": Object { - "y": "", - }, - }, - "y": Object { - "requires": Object { - "z": "", - }, - }, - "z": Object { - "requires": Object { - "l": "", - }, - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -3051,12 +2262,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests noname > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "foo": Object { - "extraneous": true, - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "noname", "packages": Object { "node_modules/foo": Object { @@ -3069,32 +2275,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests optionalloop > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "a": Object { - "optional": true, - "requires": Object { - "b": "", - "d": "", - }, - "version": "1.2.3", - }, - "b": Object { - "version": "1.2.3", - }, - "c": Object { - "requires": Object { - "d": "", - }, - "version": "1.2.3", - }, - "d": Object { - "requires": Object { - "b": "", - }, - "version": "1.2.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "optionalloop", "packages": Object { "": Object { @@ -3136,39 +2317,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests optofdev > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "a": Object { - "dev": true, - "requires": Object { - "b": "", - "d": "", - }, - }, - "b": Object { - "dev": true, - "optional": true, - "requires": Object { - "c": "", - }, - }, - "c": Object { - "dev": true, - "optional": true, - "requires": Object { - "e": "", - }, - }, - "d": Object { - "dev": true, - "requires": Object { - "e": "", - }, - }, - "e": Object { - "dev": true, - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "optofdev", "packages": Object { "": Object { @@ -3216,52 +2365,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests other > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "glob": Object { - "dependencies": Object { - "graceful-fs": Object { - "extraneous": true, - "version": "3.0.2", - }, - "inherits": Object { - "extraneous": true, - "version": "2.0.1", - }, - "minimatch": Object { - "dependencies": Object { - "lru-cache": Object { - "extraneous": true, - "version": "2.5.0", - }, - "sigmund": Object { - "extraneous": true, - "version": "1.0.0", - }, - }, - "extraneous": true, - "requires": Object { - "lru-cache": "", - "once": "", - "sigmund": "", - }, - "version": "1.0.0", - }, - "once": Object { - "extraneous": true, - "version": "1.3.0", - }, - }, - "extraneous": true, - "requires": Object { - "graceful-fs": "", - "inherits": "", - "minimatch": "", - "once": "", - }, - "version": "file:../root/node_modules/@scope/x/node_modules/glob", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "other", "packages": Object { "../root/node_modules/@scope/x/node_modules/glob": Object { @@ -3417,72 +2521,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests root > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "@scope/x": Object { - "dependencies": Object { - "glob": Object { - "dependencies": Object { - "graceful-fs": Object { - "version": "3.0.2", - }, - "inherits": Object { - "version": "2.0.1", - }, - "minimatch": Object { - "dependencies": Object { - "lru-cache": Object { - "version": "2.5.0", - }, - "sigmund": Object { - "version": "1.0.0", - }, - }, - "requires": Object { - "lru-cache": "", - "once": "", - "sigmund": "", - }, - "version": "1.0.0", - }, - "once": Object { - "version": "1.3.0", - }, - }, - "requires": Object { - "graceful-fs": "", - "inherits": "", - "minimatch": "", - "once": "", - }, - "version": "4.0.5", - }, - }, - "requires": Object { - "@scope/y": "", - "glob": "4", - }, - "version": "1.2.3", - }, - "@scope/y": Object { - "requires": Object { - "foo": "99.x", - }, - "version": "1.2.3", - }, - "foo": Object { - "dependencies": Object { - "express": Object { - "version": "npm:abbrev@1.1.1", - }, - }, - "requires": Object { - "@scope/x": "", - "express": "npm:abbrev@*", - }, - "version": "1.2.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "root", "packages": Object { "": Object { @@ -3574,96 +2613,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests selflink > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "@scope/y": Object { - "requires": Object { - "foo": "*", - }, - "version": "1.2.3", - }, - "@scope/z": Object { - "dependencies": Object { - "glob": Object { - "dependencies": Object { - "graceful-fs": Object { - "extraneous": true, - "version": "3.0.2", - }, - "inherits": Object { - "extraneous": true, - "version": "2.0.1", - }, - "minimatch": Object { - "dependencies": Object { - "lru-cache": Object { - "extraneous": true, - "version": "2.5.0", - }, - "sigmund": Object { - "extraneous": true, - "version": "1.0.0", - }, - }, - "extraneous": true, - "version": "1.0.0", - }, - "once": Object { - "extraneous": true, - "version": "1.3.0", - }, - }, - "extraneous": true, - "version": "file:node_modules/foo/node_modules/glob", - }, - }, - "extraneous": true, - "requires": Object { - "glob": "4", - }, - "version": "1.2.3", - }, - "foo": Object { - "dependencies": Object { - "glob": Object { - "dependencies": Object { - "graceful-fs": Object { - "extraneous": true, - "version": "3.0.2", - }, - "inherits": Object { - "extraneous": true, - "version": "2.0.1", - }, - "minimatch": Object { - "dependencies": Object { - "lru-cache": Object { - "extraneous": true, - "version": "2.5.0", - }, - "sigmund": Object { - "extraneous": true, - "version": "1.0.0", - }, - }, - "extraneous": true, - "version": "1.0.0", - }, - "once": Object { - "extraneous": true, - "version": "1.3.0", - }, - }, - "version": "4.0.5", - }, - }, - "requires": Object { - "glob": "4", - "selflink": "*", - }, - "version": "1.2.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "selflink", "packages": Object { "": Object { @@ -3738,17 +2688,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests symlinked-node-modules/example > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "bar": Object { - "extraneous": true, - "version": "file:../bar", - }, - "foo": Object { - "extraneous": true, - "version": "file:../linked-node-modules/foo", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "example", "packages": Object { "": Object { @@ -3779,3006 +2719,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests tap-with-yarn-lock > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "@babel/code-frame": Object { - "integrity": "sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA==", - "requires": Object { - "@babel/highlight": "^7.0.0", - }, - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.0.0.tgz", - "version": "7.0.0", - }, - "@babel/generator": Object { - "dependencies": Object { - "jsesc": Object { - "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", - "version": "2.5.2", - }, - "source-map": Object { - "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", - "version": "0.5.7", - }, - }, - "integrity": "sha512-1TTVrt7J9rcG5PMjvO7VEG3FrEoEJNHxumRq66GemPmzboLWtIjjcJgk8rokuAS7IiRSpgVSu5Vb9lc99iJkOA==", - "requires": Object { - "@babel/types": "^7.5.0", - "jsesc": "^2.5.1", - "lodash": "^4.17.11", - "source-map": "^0.5.0", - "trim-right": "^1.0.1", - }, - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.5.0.tgz", - "version": "7.5.0", - }, - "@babel/helper-function-name": Object { - "integrity": "sha512-A95XEoCpb3TO+KZzJ4S/5uW5fNe26DjBGqf1o9ucyLyCmi1dXq/B3c8iaWTfBk3VvetUxl16e8tIrd5teOCfGw==", - "requires": Object { - "@babel/helper-get-function-arity": "^7.0.0", - "@babel/template": "^7.1.0", - "@babel/types": "^7.0.0", - }, - "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.1.0.tgz", - "version": "7.1.0", - }, - "@babel/helper-get-function-arity": Object { - "integrity": "sha512-r2DbJeg4svYvt3HOS74U4eWKsUAMRH01Z1ds1zx8KNTPtpTL5JAsdFv8BNyOpVqdFhHkkRDIg5B4AsxmkjAlmQ==", - "requires": Object { - "@babel/types": "^7.0.0", - }, - "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz", - "version": "7.0.0", - }, - "@babel/helper-split-export-declaration": Object { - "integrity": "sha512-Ro/XkzLf3JFITkW6b+hNxzZ1n5OQ80NvIUdmHspih1XAhtN3vPTuUFT4eQnela+2MaZ5ulH+iyP513KJrxbN7Q==", - "requires": Object { - "@babel/types": "^7.4.4", - }, - "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.4.4.tgz", - "version": "7.4.4", - }, - "@babel/highlight": Object { - "integrity": "sha512-7dV4eu9gBxoM0dAnj/BCFDW9LFU0zvTrkq0ugM7pnHEgguOEeOz1so2ZghEdzviYzQEED0r4EAgpsBChKy1TRQ==", - "requires": Object { - "chalk": "^2.0.0", - "esutils": "^2.0.2", - "js-tokens": "^4.0.0", - }, - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.5.0.tgz", - "version": "7.5.0", - }, - "@babel/parser": Object { - "integrity": "sha512-I5nW8AhGpOXGCCNYGc+p7ExQIBxRFnS2fd/d862bNOKvmoEPjYPcfIjsfdy0ujagYOIYPczKgD9l3FsgTkAzKA==", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.5.0.tgz", - "version": "7.5.0", - }, - "@babel/runtime": Object { - "integrity": "sha512-9M29wrrP7//JBGX70+IrDuD1w4iOYhUGpJNMQJVNAXue+cFeFlMTqBECouIziXPUphlgrfjcfiEpGX4t0WGK4g==", - "requires": Object { - "regenerator-runtime": "^0.13.2", - }, - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.5.2.tgz", - "version": "7.5.2", - }, - "@babel/template": Object { - "integrity": "sha512-CiGzLN9KgAvgZsnivND7rkA+AeJ9JB0ciPOD4U59GKbQP2iQl+olF1l76kJOupqidozfZ32ghwBEJDhnk9MEcw==", - "requires": Object { - "@babel/code-frame": "^7.0.0", - "@babel/parser": "^7.4.4", - "@babel/types": "^7.4.4", - }, - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.4.4.tgz", - "version": "7.4.4", - }, - "@babel/traverse": Object { - "dependencies": Object { - "debug": Object { - "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", - "requires": Object { - "ms": "^2.1.1", - }, - "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", - "version": "4.1.1", - }, - }, - "integrity": "sha512-SnA9aLbyOCcnnbQEGwdfBggnc142h/rbqqsXcaATj2hZcegCl903pUD/lfpsNBlBSuWow/YDfRyJuWi2EPR5cg==", - "requires": Object { - "@babel/code-frame": "^7.0.0", - "@babel/generator": "^7.5.0", - "@babel/helper-function-name": "^7.1.0", - "@babel/helper-split-export-declaration": "^7.4.4", - "@babel/parser": "^7.5.0", - "@babel/types": "^7.5.0", - "debug": "^4.1.0", - "globals": "^11.1.0", - "lodash": "^4.17.11", - }, - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.5.0.tgz", - "version": "7.5.0", - }, - "@babel/types": Object { - "dependencies": Object { - "to-fast-properties": Object { - "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", - "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", - "version": "2.0.0", - }, - }, - "integrity": "sha512-UFpDVqRABKsW01bvw7/wSUe56uy6RXM5+VJibVVAybDGxEW25jdwiFJEf7ASvSaC7sN7rbE/l3cLp2izav+CtQ==", - "requires": Object { - "esutils": "^2.0.2", - "lodash": "^4.17.11", - "to-fast-properties": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.5.0.tgz", - "version": "7.5.0", - }, - "@types/prop-types": Object { - "integrity": "sha512-CFzn9idOEpHrgdw8JsoTkaDDyRWk1jrzIV8djzcgpq0y9tG4B4lFT+Nxh52DVpDXV+n4+NPNv7M1Dj5uMp6XFg==", - "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.1.tgz", - "version": "15.7.1", - }, - "@types/react": Object { - "integrity": "sha512-abkEOIeljniUN9qB5onp++g0EY38h7atnDHxwKUFz1r3VH1+yG1OKi2sNPTyObL40goBmfKFpdii2lEzwLX1cA==", - "requires": Object { - "@types/prop-types": "*", - "csstype": "^2.2.0", - }, - "resolved": "https://registry.npmjs.org/@types/react/-/react-16.8.23.tgz", - "version": "16.8.23", - }, - "ajv": Object { - "integrity": "sha512-w1YQaVGNC6t2UCPjEawK/vo/dG8OOrVtUmhBT1uJJYxbl5kU2Tj3v6LGqBcsysN1yhuCStJCCA3GqdvKY8sqXQ==", - "requires": Object { - "fast-deep-equal": "^2.0.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2", - }, - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.10.1.tgz", - "version": "6.10.1", - }, - "ansi-escapes": Object { - "integrity": "sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ==", - "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-3.2.0.tgz", - "version": "3.2.0", - }, - "ansi-regex": Object { - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "version": "2.1.1", - }, - "ansi-styles": Object { - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "requires": Object { - "color-convert": "^1.9.0", - }, - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "version": "3.2.1", - }, - "ansicolors": Object { - "integrity": "sha1-ZlWX3oap/+Oqm/vmyuXG6kJrSXk=", - "resolved": "https://registry.npmjs.org/ansicolors/-/ansicolors-0.3.2.tgz", - "version": "0.3.2", - }, - "anymatch": Object { - "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", - "requires": Object { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4", - }, - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", - "version": "3.1.1", - }, - "append-transform": Object { - "integrity": "sha512-P009oYkeHyU742iSZJzZZywj4QRJdnTWffaKuJQLablCZ1uz6/cW4yaRgcDaoQ+uwOxxnt0gRUcwfsNP2ri0gw==", - "requires": Object { - "default-require-extensions": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/append-transform/-/append-transform-1.0.0.tgz", - "version": "1.0.0", - }, - "archy": Object { - "integrity": "sha1-+cjBN1fMHde8N5rHeyxipcKGjEA=", - "resolved": "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz", - "version": "1.0.0", - }, - "arg": Object { - "integrity": "sha512-ZWc51jO3qegGkVh8Hwpv636EkbesNV5ZNQPCtRa+0qytRYPEs9IYT9qITY9buezqUH5uqyzlWLcufrzU2rffdg==", - "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.0.tgz", - "version": "4.1.0", - }, - "argparse": Object { - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", - "requires": Object { - "sprintf-js": "~1.0.2", - }, - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "version": "1.0.10", - }, - "arrify": Object { - "integrity": "sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0=", - "resolved": "https://registry.npmjs.org/arrify/-/arrify-1.0.1.tgz", - "version": "1.0.1", - }, - "asn1": Object { - "integrity": "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==", - "requires": Object { - "safer-buffer": "~2.1.0", - }, - "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz", - "version": "0.2.4", - }, - "assert-plus": Object { - "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=", - "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", - "version": "1.0.0", - }, - "astral-regex": Object { - "integrity": "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==", - "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz", - "version": "1.0.0", - }, - "async-hook-domain": Object { - "dependencies": Object { - "source-map-support": Object { - "integrity": "sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ==", - "requires": Object { - "buffer-from": "^1.0.0", - "source-map": "^0.6.0", - }, - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.12.tgz", - "version": "0.5.12", - }, - }, - "integrity": "sha512-ZovMxSbADV3+biB7oR1GL5lGyptI24alp0LWHlmz1OFc5oL47pz3EiIF6nXOkDW7yLqih4NtsiYduzdDW0i+Wg==", - "requires": Object { - "source-map-support": "^0.5.11", - }, - "resolved": "https://registry.npmjs.org/async-hook-domain/-/async-hook-domain-1.1.3.tgz", - "version": "1.1.3", - }, - "asynckit": Object { - "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "version": "0.4.0", - }, - "auto-bind": Object { - "integrity": "sha512-qZuFvkes1eh9lB2mg8/HG18C+5GIO51r+RrCSst/lh+i5B1CtVlkhTE488M805Nr3dKl0sM/pIFKSKUIlg3zUg==", - "requires": Object { - "@types/react": "^16.8.12", - }, - "resolved": "https://registry.npmjs.org/auto-bind/-/auto-bind-2.1.0.tgz", - "version": "2.1.0", - }, - "aws-sign2": Object { - "integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=", - "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", - "version": "0.7.0", - }, - "aws4": Object { - "integrity": "sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ==", - "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.8.0.tgz", - "version": "1.8.0", - }, - "babel-code-frame": Object { - "dependencies": Object { - "ansi-styles": Object { - "integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", - "version": "2.2.1", - }, - "chalk": Object { - "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", - "requires": Object { - "ansi-styles": "^2.2.1", - "escape-string-regexp": "^1.0.2", - "has-ansi": "^2.0.0", - "strip-ansi": "^3.0.0", - "supports-color": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", - "version": "1.1.3", - }, - "js-tokens": Object { - "integrity": "sha1-mGbfOVECEw449/mWvOtlRDIJwls=", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-3.0.2.tgz", - "version": "3.0.2", - }, - "supports-color": Object { - "integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", - "version": "2.0.0", - }, - }, - "integrity": "sha1-Y/1D99weO7fONZR9uP42mj9Yx0s=", - "requires": Object { - "chalk": "^1.1.3", - "esutils": "^2.0.2", - "js-tokens": "^3.0.2", - }, - "resolved": "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.26.0.tgz", - "version": "6.26.0", - }, - "babel-core": Object { - "dependencies": Object { - "source-map": Object { - "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", - "version": "0.5.7", - }, - }, - "integrity": "sha512-6jyFLuDmeidKmUEb3NM+/yawG0M2bDZ9Z1qbZP59cyHLz8kYGKYwpJP0UwUKKUiTRNvxfLesJnTedqczP7cTDA==", - "requires": Object { - "babel-code-frame": "^6.26.0", - "babel-generator": "^6.26.0", - "babel-helpers": "^6.24.1", - "babel-messages": "^6.23.0", - "babel-register": "^6.26.0", - "babel-runtime": "^6.26.0", - "babel-template": "^6.26.0", - "babel-traverse": "^6.26.0", - "babel-types": "^6.26.0", - "babylon": "^6.18.0", - "convert-source-map": "^1.5.1", - "debug": "^2.6.9", - "json5": "^0.5.1", - "lodash": "^4.17.4", - "minimatch": "^3.0.4", - "path-is-absolute": "^1.0.1", - "private": "^0.1.8", - "slash": "^1.0.0", - "source-map": "^0.5.7", - }, - "resolved": "https://registry.npmjs.org/babel-core/-/babel-core-6.26.3.tgz", - "version": "6.26.3", - }, - "babel-generator": Object { - "dependencies": Object { - "source-map": Object { - "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", - "version": "0.5.7", - }, - }, - "integrity": "sha512-HyfwY6ApZj7BYTcJURpM5tznulaBvyio7/0d4zFOeMPUmfxkCjHocCuoLa2SAGzBI8AREcH3eP3758F672DppA==", - "requires": Object { - "babel-messages": "^6.23.0", - "babel-runtime": "^6.26.0", - "babel-types": "^6.26.0", - "detect-indent": "^4.0.0", - "jsesc": "^1.3.0", - "lodash": "^4.17.4", - "source-map": "^0.5.7", - "trim-right": "^1.0.1", - }, - "resolved": "https://registry.npmjs.org/babel-generator/-/babel-generator-6.26.1.tgz", - "version": "6.26.1", - }, - "babel-helper-builder-react-jsx": Object { - "integrity": "sha1-Of+DE7dci2Xc7/HzHTg+D/KkCKA=", - "requires": Object { - "babel-runtime": "^6.26.0", - "babel-types": "^6.26.0", - "esutils": "^2.0.2", - }, - "resolved": "https://registry.npmjs.org/babel-helper-builder-react-jsx/-/babel-helper-builder-react-jsx-6.26.0.tgz", - "version": "6.26.0", - }, - "babel-helpers": Object { - "integrity": "sha1-NHHenK7DiOXIUOWX5Yom3fN2ArI=", - "requires": Object { - "babel-runtime": "^6.22.0", - "babel-template": "^6.24.1", - }, - "resolved": "https://registry.npmjs.org/babel-helpers/-/babel-helpers-6.24.1.tgz", - "version": "6.24.1", - }, - "babel-messages": Object { - "integrity": "sha1-8830cDhYA1sqKVHG7F7fbGLyYw4=", - "requires": Object { - "babel-runtime": "^6.22.0", - }, - "resolved": "https://registry.npmjs.org/babel-messages/-/babel-messages-6.23.0.tgz", - "version": "6.23.0", - }, - "babel-plugin-syntax-jsx": Object { - "integrity": "sha1-CvMqmm4Tyno/1QaeYtew9Y0NiUY=", - "resolved": "https://registry.npmjs.org/babel-plugin-syntax-jsx/-/babel-plugin-syntax-jsx-6.18.0.tgz", - "version": "6.18.0", - }, - "babel-plugin-syntax-object-rest-spread": Object { - "integrity": "sha1-/WU28rzhODb/o6VFjEkDpZe7O/U=", - "resolved": "https://registry.npmjs.org/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz", - "version": "6.13.0", - }, - "babel-plugin-transform-es2015-destructuring": Object { - "integrity": "sha1-mXux8auWf2gtKwh2/jWNYOdlxW0=", - "requires": Object { - "babel-runtime": "^6.22.0", - }, - "resolved": "https://registry.npmjs.org/babel-plugin-transform-es2015-destructuring/-/babel-plugin-transform-es2015-destructuring-6.23.0.tgz", - "version": "6.23.0", - }, - "babel-plugin-transform-object-rest-spread": Object { - "integrity": "sha1-DzZpLVD+9rfi1LOsFHgTepY7ewY=", - "requires": Object { - "babel-plugin-syntax-object-rest-spread": "^6.8.0", - "babel-runtime": "^6.26.0", - }, - "resolved": "https://registry.npmjs.org/babel-plugin-transform-object-rest-spread/-/babel-plugin-transform-object-rest-spread-6.26.0.tgz", - "version": "6.26.0", - }, - "babel-plugin-transform-react-jsx": Object { - "integrity": "sha1-hAoCjn30YN/DotKfDA2R9jduZqM=", - "requires": Object { - "babel-helper-builder-react-jsx": "^6.24.1", - "babel-plugin-syntax-jsx": "^6.8.0", - "babel-runtime": "^6.22.0", - }, - "resolved": "https://registry.npmjs.org/babel-plugin-transform-react-jsx/-/babel-plugin-transform-react-jsx-6.24.1.tgz", - "version": "6.24.1", - }, - "babel-register": Object { - "dependencies": Object { - "source-map": Object { - "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", - "version": "0.5.7", - }, - "source-map-support": Object { - "integrity": "sha512-try0/JqxPLF9nOjvSta7tVondkP5dwgyLDjVoyMDlmjugT2lRZ1OfsrYTkCd2hkDnJTKRbO/Rl3orm8vlsUzbA==", - "requires": Object { - "source-map": "^0.5.6", - }, - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.4.18.tgz", - "version": "0.4.18", - }, - }, - "integrity": "sha1-btAhFz4vy0htestFxgCahW9kcHE=", - "requires": Object { - "babel-core": "^6.26.0", - "babel-runtime": "^6.26.0", - "core-js": "^2.5.0", - "home-or-tmp": "^2.0.0", - "lodash": "^4.17.4", - "mkdirp": "^0.5.1", - "source-map-support": "^0.4.15", - }, - "resolved": "https://registry.npmjs.org/babel-register/-/babel-register-6.26.0.tgz", - "version": "6.26.0", - }, - "babel-runtime": Object { - "dependencies": Object { - "regenerator-runtime": Object { - "integrity": "sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg==", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz", - "version": "0.11.1", - }, - }, - "integrity": "sha1-llxwWGaOgrVde/4E/yM3vItWR/4=", - "requires": Object { - "core-js": "^2.4.0", - "regenerator-runtime": "^0.11.0", - }, - "resolved": "https://registry.npmjs.org/babel-runtime/-/babel-runtime-6.26.0.tgz", - "version": "6.26.0", - }, - "babel-template": Object { - "integrity": "sha1-3gPi0WOWsGn0bdn/+FIfsaDjXgI=", - "requires": Object { - "babel-runtime": "^6.26.0", - "babel-traverse": "^6.26.0", - "babel-types": "^6.26.0", - "babylon": "^6.18.0", - "lodash": "^4.17.4", - }, - "resolved": "https://registry.npmjs.org/babel-template/-/babel-template-6.26.0.tgz", - "version": "6.26.0", - }, - "babel-traverse": Object { - "dependencies": Object { - "globals": Object { - "integrity": "sha512-S0nG3CLEQiY/ILxqtztTWH/3iRRdyBLw6KMDxnKMchrtbj2OFmehVh0WUCfW3DUrIgx/qFrJPICrq4Z4sTR9UQ==", - "resolved": "https://registry.npmjs.org/globals/-/globals-9.18.0.tgz", - "version": "9.18.0", - }, - }, - "integrity": "sha1-RqnL1+3MYsjlwGTi0tjQ9ANXZu4=", - "requires": Object { - "babel-code-frame": "^6.26.0", - "babel-messages": "^6.23.0", - "babel-runtime": "^6.26.0", - "babel-types": "^6.26.0", - "babylon": "^6.18.0", - "debug": "^2.6.8", - "globals": "^9.18.0", - "invariant": "^2.2.2", - "lodash": "^4.17.4", - }, - "resolved": "https://registry.npmjs.org/babel-traverse/-/babel-traverse-6.26.0.tgz", - "version": "6.26.0", - }, - "babel-types": Object { - "integrity": "sha1-o7Bz+Uq0nrb6Vc1lInozQ4BjJJc=", - "requires": Object { - "babel-runtime": "^6.26.0", - "esutils": "^2.0.2", - "lodash": "^4.17.4", - "to-fast-properties": "^1.0.3", - }, - "resolved": "https://registry.npmjs.org/babel-types/-/babel-types-6.26.0.tgz", - "version": "6.26.0", - }, - "babylon": Object { - "integrity": "sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ==", - "resolved": "https://registry.npmjs.org/babylon/-/babylon-6.18.0.tgz", - "version": "6.18.0", - }, - "balanced-match": Object { - "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", - "version": "1.0.0", - }, - "bcrypt-pbkdf": Object { - "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=", - "requires": Object { - "tweetnacl": "^0.14.3", - }, - "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", - "version": "1.0.2", - }, - "binary-extensions": Object { - "integrity": "sha512-Phlt0plgpIIBOGTT/ehfFnbNlfsDEiqmzE2KRXoX1bLIlir4X/MR+zSyBEkL05ffWgnRSf/DXv+WrUAVr93/ow==", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.0.0.tgz", - "version": "2.0.0", - }, - "bind-obj-methods": Object { - "integrity": "sha512-3/qRXczDi2Cdbz6jE+W3IflJOutRVica8frpBn14de1mBOkzDo+6tY33kNhvkw54Kn3PzRRD2VnGbGPcTAk4sw==", - "resolved": "https://registry.npmjs.org/bind-obj-methods/-/bind-obj-methods-2.0.0.tgz", - "version": "2.0.0", - }, - "brace-expansion": Object { - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "requires": Object { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1", - }, - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "version": "1.1.11", - }, - "braces": Object { - "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", - "requires": Object { - "fill-range": "^7.0.1", - }, - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", - "version": "3.0.2", - }, - "browser-process-hrtime": Object { - "integrity": "sha512-9o5UecI3GhkpM6DrXr69PblIuWxPKk9Y0jHBRhdocZ2y7YECBFCsHm79Pr3OyR2AvjhDkabFJaDJMYRazHgsow==", - "resolved": "https://registry.npmjs.org/browser-process-hrtime/-/browser-process-hrtime-1.0.0.tgz", - "version": "1.0.0", - }, - "buffer-from": Object { - "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==", - "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", - "version": "1.1.1", - }, - "caching-transform": Object { - "dependencies": Object { - "write-file-atomic": Object { - "integrity": "sha512-GaETH5wwsX+GcnzhPgKcKjJ6M2Cq3/iZp1WyY/X1CSqrW+jVNM9Y7D8EC2sM4ZG/V8wZlSniJnCKWPmBYAucRQ==", - "requires": Object { - "graceful-fs": "^4.1.11", - "imurmurhash": "^0.1.4", - "signal-exit": "^3.0.2", - }, - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.4.3.tgz", - "version": "2.4.3", - }, - }, - "integrity": "sha512-Mtgcv3lh3U0zRii/6qVgQODdPA4G3zhG+jtbCWj39RXuUFTMzH0vcdMtaJS1jPowd+It2Pqr6y3NJMQqOqCE2w==", - "requires": Object { - "hasha": "^3.0.0", - "make-dir": "^2.0.0", - "package-hash": "^3.0.0", - "write-file-atomic": "^2.4.2", - }, - "resolved": "https://registry.npmjs.org/caching-transform/-/caching-transform-3.0.2.tgz", - "version": "3.0.2", - }, - "caller-callsite": Object { - "integrity": "sha1-hH4PzgoiN1CpoCfFSzNzGtMVQTQ=", - "requires": Object { - "callsites": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/caller-callsite/-/caller-callsite-2.0.0.tgz", - "version": "2.0.0", - }, - "caller-path": Object { - "integrity": "sha1-Ro+DBE42mrIBD6xfBs7uFbsssfQ=", - "requires": Object { - "caller-callsite": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/caller-path/-/caller-path-2.0.0.tgz", - "version": "2.0.0", - }, - "callsites": Object { - "integrity": "sha1-BuuE8A7qQT2oav/vrL/7Ngk7PFA=", - "resolved": "https://registry.npmjs.org/callsites/-/callsites-2.0.0.tgz", - "version": "2.0.0", - }, - "camelcase": Object { - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "version": "5.3.1", - }, - "cardinal": Object { - "integrity": "sha1-fMEFXYItISlU0HsIXeolHMe8VQU=", - "requires": Object { - "ansicolors": "~0.3.2", - "redeyed": "~2.1.0", - }, - "resolved": "https://registry.npmjs.org/cardinal/-/cardinal-2.1.1.tgz", - "version": "2.1.1", - }, - "caseless": Object { - "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=", - "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", - "version": "0.12.0", - }, - "chalk": Object { - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "requires": Object { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0", - }, - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "version": "2.4.2", - }, - "chokidar": Object { - "integrity": "sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A==", - "requires": Object { - "anymatch": "~3.1.1", - "braces": "~3.0.2", - "fsevents": "~2.1.1", - "glob-parent": "~5.1.0", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.2.0", - }, - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.3.0.tgz", - "version": "3.3.0", - }, - "ci-info": Object { - "integrity": "sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ==", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-2.0.0.tgz", - "version": "2.0.0", - }, - "cli-cursor": Object { - "integrity": "sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU=", - "requires": Object { - "restore-cursor": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-2.1.0.tgz", - "version": "2.1.0", - }, - "cli-truncate": Object { - "integrity": "sha512-bAtZo0u82gCfaAGfSNxUdTI9mNyza7D8w4CVCcaOsy7sgwDzvx6ekr6cuWJqY3UGzgnQ1+4wgENup5eIhgxEYA==", - "requires": Object { - "slice-ansi": "^1.0.0", - "string-width": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/cli-truncate/-/cli-truncate-1.1.0.tgz", - "version": "1.1.0", - }, - "cliui": Object { - "dependencies": Object { - "ansi-regex": Object { - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "version": "3.0.0", - }, - "is-fullwidth-code-point": Object { - "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", - "requires": Object { - "number-is-nan": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", - "version": "1.0.0", - }, - "strip-ansi": Object { - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "requires": Object { - "ansi-regex": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "version": "4.0.0", - }, - "wrap-ansi": Object { - "dependencies": Object { - "ansi-regex": Object { - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "version": "2.1.1", - }, - "string-width": Object { - "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", - "requires": Object { - "code-point-at": "^1.0.0", - "is-fullwidth-code-point": "^1.0.0", - "strip-ansi": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", - "version": "1.0.2", - }, - "strip-ansi": Object { - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", - "requires": Object { - "ansi-regex": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "version": "3.0.1", - }, - }, - "integrity": "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=", - "requires": Object { - "string-width": "^1.0.1", - "strip-ansi": "^3.0.1", - }, - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz", - "version": "2.1.0", - }, - }, - "integrity": "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==", - "requires": Object { - "string-width": "^2.1.1", - "strip-ansi": "^4.0.0", - "wrap-ansi": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz", - "version": "4.1.0", - }, - "code-point-at": Object { - "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", - "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", - "version": "1.1.0", - }, - "color-convert": Object { - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", - "requires": Object { - "color-name": "1.1.3", - }, - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "version": "1.9.3", - }, - "color-name": Object { - "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "version": "1.1.3", - }, - "color-support": Object { - "integrity": "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg==", - "resolved": "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz", - "version": "1.1.3", - }, - "combined-stream": Object { - "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", - "requires": Object { - "delayed-stream": "~1.0.0", - }, - "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", - "version": "1.0.8", - }, - "commander": Object { - "integrity": "sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ==", - "optional": true, - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.0.tgz", - "version": "2.20.0", - }, - "commondir": Object { - "integrity": "sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs=", - "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", - "version": "1.0.1", - }, - "concat-map": Object { - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "version": "0.0.1", - }, - "convert-source-map": Object { - "integrity": "sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A==", - "requires": Object { - "safe-buffer": "~5.1.1", - }, - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.6.0.tgz", - "version": "1.6.0", - }, - "core-js": Object { - "integrity": "sha512-HOpZf6eXmnl7la+cUdMnLvUxKNqLUzJvgIziQ0DiF3JwSImNphIqdGqzj6hIKyX04MmV0poclQ7+wjWvxQyR2A==", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.9.tgz", - "version": "2.6.9", - }, - "core-util-is": Object { - "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", - "version": "1.0.2", - }, - "coveralls": Object { - "dependencies": Object { - "minimist": Object { - "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", - "version": "1.2.0", - }, - }, - "integrity": "sha512-mUuH2MFOYB2oBaA4D4Ykqi9LaEYpMMlsiOMJOrv358yAjP6enPIk55fod2fNJ8AvwoYXStWQls37rA+s5e7boA==", - "requires": Object { - "growl": "~> 1.10.0", - "js-yaml": "^3.13.1", - "lcov-parse": "^0.0.10", - "log-driver": "^1.2.7", - "minimist": "^1.2.0", - "request": "^2.86.0", - }, - "resolved": "https://registry.npmjs.org/coveralls/-/coveralls-3.0.7.tgz", - "version": "3.0.7", - }, - "cp-file": Object { - "dependencies": Object { - "pify": Object { - "integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==", - "resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz", - "version": "4.0.1", - }, - "safe-buffer": Object { - "integrity": "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz", - "version": "5.2.0", - }, - }, - "integrity": "sha512-fmvV4caBnofhPe8kOcitBwSn2f39QLjnAnGq3gO9dfd75mUytzKNZB1hde6QHunW2Rt+OwuBOMc3i1tNElbszA==", - "requires": Object { - "graceful-fs": "^4.1.2", - "make-dir": "^2.0.0", - "nested-error-stacks": "^2.0.0", - "pify": "^4.0.1", - "safe-buffer": "^5.0.1", - }, - "resolved": "https://registry.npmjs.org/cp-file/-/cp-file-6.2.0.tgz", - "version": "6.2.0", - }, - "cross-spawn": Object { - "dependencies": Object { - "which": Object { - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "requires": Object { - "isexe": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "version": "1.3.1", - }, - }, - "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", - "requires": Object { - "nice-try": "^1.0.4", - "path-key": "^2.0.1", - "semver": "^5.5.0", - "shebang-command": "^1.2.0", - "which": "^1.2.9", - }, - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", - "version": "6.0.5", - }, - "csstype": Object { - "integrity": "sha512-RpFbQGUE74iyPgvr46U9t1xoQBM8T4BL8SxrN66Le2xYAPSaDJJKeztV3awugusb3g3G9iL8StmkBBXhcbbXhg==", - "resolved": "https://registry.npmjs.org/csstype/-/csstype-2.6.6.tgz", - "version": "2.6.6", - }, - "dashdash": Object { - "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", - "requires": Object { - "assert-plus": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", - "version": "1.14.1", - }, - "debug": Object { - "dependencies": Object { - "ms": Object { - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "version": "2.0.0", - }, - }, - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", - "requires": Object { - "ms": "2.0.0", - }, - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "version": "2.6.9", - }, - "decamelize": Object { - "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", - "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", - "version": "1.2.0", - }, - "default-require-extensions": Object { - "integrity": "sha1-9fj7sYp9bVCyH2QfZJ67Uiz+JPc=", - "requires": Object { - "strip-bom": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/default-require-extensions/-/default-require-extensions-2.0.0.tgz", - "version": "2.0.0", - }, - "delayed-stream": Object { - "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=", - "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "version": "1.0.0", - }, - "detect-indent": Object { - "integrity": "sha1-920GQ1LN9Docts5hnE7jqUdd4gg=", - "requires": Object { - "repeating": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/detect-indent/-/detect-indent-4.0.0.tgz", - "version": "4.0.0", - }, - "diff": Object { - "integrity": "sha512-s2+XdvhPCOF01LRQBC8hf4vhbVmI2CGS5aZnxLJlT5FtdhPCDFq80q++zK2KlrVorVDdL5BOGZ/VfLrVtYNF+Q==", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.1.tgz", - "version": "4.0.1", - }, - "ecc-jsbn": Object { - "integrity": "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=", - "requires": Object { - "jsbn": "~0.1.0", - "safer-buffer": "^2.1.0", - }, - "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", - "version": "0.1.2", - }, - "emoji-regex": Object { - "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", - "version": "7.0.3", - }, - "end-of-stream": Object { - "integrity": "sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q==", - "requires": Object { - "once": "^1.4.0", - }, - "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.1.tgz", - "version": "1.4.1", - }, - "error-ex": Object { - "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", - "requires": Object { - "is-arrayish": "^0.2.1", - }, - "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", - "version": "1.3.2", - }, - "es6-error": Object { - "integrity": "sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg==", - "resolved": "https://registry.npmjs.org/es6-error/-/es6-error-4.1.1.tgz", - "version": "4.1.1", - }, - "escape-string-regexp": Object { - "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "version": "1.0.5", - }, - "esm": Object { - "integrity": "sha512-U1suiZ2oDVWv4zPO56S0NcR5QriEahGtdN2OR6FiOG4WJvcjBVFB0qI4+eKoWFH483PKGuLuu6V8Z4T5g63UVA==", - "resolved": "https://registry.npmjs.org/esm/-/esm-3.2.25.tgz", - "version": "3.2.25", - }, - "esprima": Object { - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "version": "4.0.1", - }, - "esutils": Object { - "integrity": "sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs=", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.2.tgz", - "version": "2.0.2", - }, - "events-to-array": Object { - "integrity": "sha1-LUH1Y+H+QA7Uli/hpNXGp1Od9/Y=", - "resolved": "https://registry.npmjs.org/events-to-array/-/events-to-array-1.1.2.tgz", - "version": "1.1.2", - }, - "execa": Object { - "integrity": "sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==", - "requires": Object { - "cross-spawn": "^6.0.0", - "get-stream": "^4.0.0", - "is-stream": "^1.1.0", - "npm-run-path": "^2.0.0", - "p-finally": "^1.0.0", - "signal-exit": "^3.0.0", - "strip-eof": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz", - "version": "1.0.0", - }, - "extend": Object { - "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==", - "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", - "version": "3.0.2", - }, - "extsprintf": Object { - "integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=", - "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", - "version": "1.3.0", - }, - "fast-deep-equal": Object { - "integrity": "sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk=", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz", - "version": "2.0.1", - }, - "fast-json-stable-stringify": Object { - "integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=", - "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz", - "version": "2.0.0", - }, - "fill-range": Object { - "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", - "requires": Object { - "to-regex-range": "^5.0.1", - }, - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", - "version": "7.0.1", - }, - "find-cache-dir": Object { - "integrity": "sha512-Tq6PixE0w/VMFfCgbONnkiQIVol/JJL7nRMi20fqzA4NRs9AfeqMGeRdPi3wIhYkxjeBaWh2rxwapn5Tu3IqOQ==", - "requires": Object { - "commondir": "^1.0.1", - "make-dir": "^2.0.0", - "pkg-dir": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-2.1.0.tgz", - "version": "2.1.0", - }, - "find-up": Object { - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", - "requires": Object { - "locate-path": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "version": "3.0.0", - }, - "findit": Object { - "integrity": "sha1-ZQnwEmr0wXhVHPqZOU4DLhOk1W4=", - "resolved": "https://registry.npmjs.org/findit/-/findit-2.0.0.tgz", - "version": "2.0.0", - }, - "flow-parser": Object { - "integrity": "sha512-sxjnwhR76B/fUN6n/XerYzn8R1HvtVo3SM8Il3WiZ4nkAlb2BBzKe1TSVKGSyZgD6FW9Bsxom/57ktkqrqmXGA==", - "resolved": "https://registry.npmjs.org/flow-parser/-/flow-parser-0.112.0.tgz", - "version": "0.112.0", - }, - "flow-remove-types": Object { - "integrity": "sha512-h3bwcfh41nR9kvlhZFr5ySGmzzOyG4VUsnN4OBl9R6anbWAiX4H5lPhKTwZ7AelWF8Rtqmw/Vnq+VLEMg7PdAw==", - "requires": Object { - "flow-parser": "^0.112.0", - "pirates": "^3.0.2", - "vlq": "^0.2.1", - }, - "resolved": "https://registry.npmjs.org/flow-remove-types/-/flow-remove-types-2.112.0.tgz", - "version": "2.112.0", - }, - "foreground-child": Object { - "dependencies": Object { - "cross-spawn": Object { - "integrity": "sha1-e5JHYhwjrf3ThWAEqCPL45dCTUE=", - "requires": Object { - "lru-cache": "^4.0.1", - "which": "^1.2.9", - }, - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-4.0.2.tgz", - "version": "4.0.2", - }, - "which": Object { - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "requires": Object { - "isexe": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "version": "1.3.1", - }, - }, - "integrity": "sha1-T9ca0t/elnibmApcCilZN8svXOk=", - "requires": Object { - "cross-spawn": "^4", - "signal-exit": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-1.5.6.tgz", - "version": "1.5.6", - }, - "forever-agent": Object { - "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=", - "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", - "version": "0.6.1", - }, - "form-data": Object { - "integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==", - "requires": Object { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.6", - "mime-types": "^2.1.12", - }, - "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz", - "version": "2.3.3", - }, - "fs-exists-cached": Object { - "integrity": "sha1-zyVVTKBQ3EmuZla0HeQiWJidy84=", - "resolved": "https://registry.npmjs.org/fs-exists-cached/-/fs-exists-cached-1.0.0.tgz", - "version": "1.0.0", - }, - "fs.realpath": Object { - "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "version": "1.0.0", - }, - "fsevents": Object { - "integrity": "sha512-R4wDiBwZ0KzpgOWetKDug1FZcYhqYnUYKtfZYt4mD5SBz76q0KR4Q9o7GIPamsVPGmW3EYPPJ0dOOjvx32ldZA==", - "optional": true, - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.2.tgz", - "version": "2.1.2", - }, - "function-loop": Object { - "integrity": "sha512-Iw4MzMfS3udk/rqxTiDDCllhGwlOrsr50zViTOO/W6lS/9y6B1J0BD2VZzrnWUYBJsl3aeqjgR5v7bWWhZSYbA==", - "resolved": "https://registry.npmjs.org/function-loop/-/function-loop-1.0.2.tgz", - "version": "1.0.2", - }, - "get-caller-file": Object { - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "version": "2.0.5", - }, - "get-stream": Object { - "integrity": "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==", - "requires": Object { - "pump": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz", - "version": "4.1.0", - }, - "getpass": Object { - "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", - "requires": Object { - "assert-plus": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", - "version": "0.1.7", - }, - "glob": Object { - "integrity": "sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A==", - "requires": Object { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.4.tgz", - "version": "7.1.4", - }, - "glob-parent": Object { - "integrity": "sha512-qjtRgnIVmOfnKUE3NJAQEdk+lKrxfw8t5ke7SXtfMTHcjsBfOfWXCQfdb30zfDoZQ2IRSIiidmjtbHZPZ++Ihw==", - "requires": Object { - "is-glob": "^4.0.1", - }, - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.0.tgz", - "version": "5.1.0", - }, - "globals": Object { - "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", - "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", - "version": "11.12.0", - }, - "graceful-fs": Object { - "integrity": "sha512-jpSvDPV4Cq/bgtpndIWbI5hmYxhQGHPC4d4cqBPb4DLniCfhJokdXhwhaDuLBGLQdvvRum/UiX6ECVIPvDXqdg==", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.0.tgz", - "version": "4.2.0", - }, - "growl": Object { - "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==", - "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", - "version": "1.10.5", - }, - "handlebars": Object { - "integrity": "sha512-nvfrjqvt9xQ8Z/w0ijewdD/vvWDTOweBUm96NTr66Wfvo1mJenBLwcYmPs3TIBP5ruzYGD7Hx/DaM9RmhroGPw==", - "requires": Object { - "neo-async": "^2.6.0", - "optimist": "^0.6.1", - "source-map": "^0.6.1", - "uglify-js": "^3.1.4", - }, - "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.1.2.tgz", - "version": "4.1.2", - }, - "har-schema": Object { - "integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=", - "resolved": "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz", - "version": "2.0.0", - }, - "har-validator": Object { - "integrity": "sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g==", - "requires": Object { - "ajv": "^6.5.5", - "har-schema": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz", - "version": "5.1.3", - }, - "has-ansi": Object { - "integrity": "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=", - "requires": Object { - "ansi-regex": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", - "version": "2.0.0", - }, - "has-flag": Object { - "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "version": "3.0.0", - }, - "hasha": Object { - "integrity": "sha1-UqMvq4Vp1BymmmH/GiFPjrfIvTk=", - "requires": Object { - "is-stream": "^1.0.1", - }, - "resolved": "https://registry.npmjs.org/hasha/-/hasha-3.0.0.tgz", - "version": "3.0.0", - }, - "home-or-tmp": Object { - "integrity": "sha1-42w/LSyufXRqhX440Y1fMqeILbg=", - "requires": Object { - "os-homedir": "^1.0.0", - "os-tmpdir": "^1.0.1", - }, - "resolved": "https://registry.npmjs.org/home-or-tmp/-/home-or-tmp-2.0.0.tgz", - "version": "2.0.0", - }, - "hosted-git-info": Object { - "integrity": "sha512-7T/BxH19zbcCTa8XkMlbK5lTo1WtgkFi3GvdWEyNuc4Vex7/9Dqbnpsf4JMydcfj9HCg4zUWFTL3Za6lapg5/w==", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.7.1.tgz", - "version": "2.7.1", - }, - "http-signature": Object { - "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=", - "requires": Object { - "assert-plus": "^1.0.0", - "jsprim": "^1.2.2", - "sshpk": "^1.7.0", - }, - "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz", - "version": "1.2.0", - }, - "import-jsx": Object { - "integrity": "sha512-xmrgtiRnAdjIaRzKwsHut54FA8nx59WqN4MpQvPFr/8yD6BamavkmKHrA5dotAlnIiF4uqMzg/lA5yhPdpIXsA==", - "requires": Object { - "babel-core": "^6.25.0", - "babel-plugin-transform-es2015-destructuring": "^6.23.0", - "babel-plugin-transform-object-rest-spread": "^6.23.0", - "babel-plugin-transform-react-jsx": "^6.24.1", - "caller-path": "^2.0.0", - "resolve-from": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/import-jsx/-/import-jsx-2.0.0.tgz", - "version": "2.0.0", - }, - "imurmurhash": Object { - "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "version": "0.1.4", - }, - "inflight": Object { - "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", - "requires": Object { - "once": "^1.3.0", - "wrappy": "1", - }, - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "version": "1.0.6", - }, - "inherits": Object { - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "version": "2.0.4", - }, - "ink": Object { - "integrity": "sha512-931rgXHAS3hM++8ygWPOBeHOFwTzHh3pDAVZtiBVOUH6tVvJijym43ODUy22ySo2NwYUFeR/Zj3xuWzBEKMiHw==", - "requires": Object { - "@types/react": "^16.8.6", - "arrify": "^1.0.1", - "auto-bind": "^2.0.0", - "chalk": "^2.4.1", - "cli-cursor": "^2.1.0", - "cli-truncate": "^1.1.0", - "is-ci": "^2.0.0", - "lodash.throttle": "^4.1.1", - "log-update": "^3.0.0", - "prop-types": "^15.6.2", - "react-reconciler": "^0.20.0", - "scheduler": "^0.13.2", - "signal-exit": "^3.0.2", - "slice-ansi": "^1.0.0", - "string-length": "^2.0.0", - "widest-line": "^2.0.0", - "wrap-ansi": "^5.0.0", - "yoga-layout-prebuilt": "^1.9.3", - }, - "resolved": "https://registry.npmjs.org/ink/-/ink-2.3.0.tgz", - "version": "2.3.0", - }, - "invariant": Object { - "integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==", - "requires": Object { - "loose-envify": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", - "version": "2.2.4", - }, - "invert-kv": Object { - "integrity": "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==", - "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz", - "version": "2.0.0", - }, - "is-arrayish": Object { - "integrity": "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=", - "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", - "version": "0.2.1", - }, - "is-binary-path": Object { - "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", - "requires": Object { - "binary-extensions": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", - "version": "2.1.0", - }, - "is-ci": Object { - "integrity": "sha512-YfJT7rkpQB0updsdHLGWrvhBJfcfzNNawYDNIyQXJz0IViGf75O8EBPKSdvw2rF+LGCsX4FZ8tcr3b19LcZq4w==", - "requires": Object { - "ci-info": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/is-ci/-/is-ci-2.0.0.tgz", - "version": "2.0.0", - }, - "is-extglob": Object { - "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "version": "2.1.1", - }, - "is-finite": Object { - "integrity": "sha1-zGZ3aVYCvlUO8R6LSqYwU0K20Ko=", - "requires": Object { - "number-is-nan": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.0.2.tgz", - "version": "1.0.2", - }, - "is-fullwidth-code-point": Object { - "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", - "version": "2.0.0", - }, - "is-glob": Object { - "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", - "requires": Object { - "is-extglob": "^2.1.1", - }, - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", - "version": "4.0.1", - }, - "is-number": Object { - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "version": "7.0.0", - }, - "is-stream": Object { - "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", - "version": "1.1.0", - }, - "is-typedarray": Object { - "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=", - "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", - "version": "1.0.0", - }, - "isarray": Object { - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", - "optional": true, - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "version": "1.0.0", - }, - "isexe": Object { - "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "version": "2.0.0", - }, - "isstream": Object { - "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=", - "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", - "version": "0.1.2", - }, - "istanbul-lib-coverage": Object { - "integrity": "sha512-8aXznuEPCJvGnMSRft4udDRDtb1V3pkQkMMI5LI+6HuQz5oQ4J2UFn1H82raA3qJtyOLkkwVqICBQkjnGtn5mA==", - "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.5.tgz", - "version": "2.0.5", - }, - "istanbul-lib-hook": Object { - "integrity": "sha512-vrRztU9VRRFDyC+aklfLoeXyNdTfga2EI3udDGn4cZ6fpSXpHLV9X6CHvfoMCPtggg8zvDDmC4b9xfu0z6/llA==", - "requires": Object { - "append-transform": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/istanbul-lib-hook/-/istanbul-lib-hook-2.0.7.tgz", - "version": "2.0.7", - }, - "istanbul-lib-instrument": Object { - "dependencies": Object { - "semver": Object { - "integrity": "sha512-jdFC1VdUGT/2Scgbimf7FSx9iJLXoqfglSF+gJeuNWVpiE37OIbc1jywR/GJyFdz3mnkz2/id0L0J/cr0izR5A==", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.2.0.tgz", - "version": "6.2.0", - }, - }, - "integrity": "sha512-5nnIN4vo5xQZHdXno/YDXJ0G+I3dAm4XgzfSVTPLQpj/zAV2dV6Juy0yaf10/zrJOJeHoN3fraFe+XRq2bFVZA==", - "requires": Object { - "@babel/generator": "^7.4.0", - "@babel/parser": "^7.4.3", - "@babel/template": "^7.4.0", - "@babel/traverse": "^7.4.3", - "@babel/types": "^7.4.0", - "istanbul-lib-coverage": "^2.0.5", - "semver": "^6.0.0", - }, - "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-3.3.0.tgz", - "version": "3.3.0", - }, - "istanbul-lib-processinfo": Object { - "dependencies": Object { - "rimraf": Object { - "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", - "requires": Object { - "glob": "^7.1.3", - }, - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", - "version": "2.6.3", - }, - }, - "integrity": "sha512-FY0cPmWa4WoQNlvB8VOcafiRoB5nB+l2Pz2xGuXHRSy1KM8QFOYfz/rN+bGMCAeejrY3mrpF5oJHcN0s/garCg==", - "requires": Object { - "archy": "^1.0.0", - "cross-spawn": "^6.0.5", - "istanbul-lib-coverage": "^2.0.3", - "rimraf": "^2.6.3", - "uuid": "^3.3.2", - }, - "resolved": "https://registry.npmjs.org/istanbul-lib-processinfo/-/istanbul-lib-processinfo-1.0.0.tgz", - "version": "1.0.0", - }, - "istanbul-lib-report": Object { - "dependencies": Object { - "supports-color": Object { - "integrity": "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==", - "requires": Object { - "has-flag": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.1.0.tgz", - "version": "6.1.0", - }, - }, - "integrity": "sha512-fHBeG573EIihhAblwgxrSenp0Dby6tJMFR/HvlerBsrCTD5bkUuoNtn3gVh29ZCS824cGGBPn7Sg7cNk+2xUsQ==", - "requires": Object { - "istanbul-lib-coverage": "^2.0.5", - "make-dir": "^2.1.0", - "supports-color": "^6.1.0", - }, - "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-2.0.8.tgz", - "version": "2.0.8", - }, - "istanbul-lib-source-maps": Object { - "dependencies": Object { - "debug": Object { - "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", - "requires": Object { - "ms": "^2.1.1", - }, - "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", - "version": "4.1.1", - }, - "rimraf": Object { - "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", - "requires": Object { - "glob": "^7.1.3", - }, - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", - "version": "2.6.3", - }, - }, - "integrity": "sha512-R47KzMtDJH6X4/YW9XTx+jrLnZnscW4VpNN+1PViSYTejLVPWv7oov+Duf8YQSPyVRUvueQqz1TcsC6mooZTXw==", - "requires": Object { - "debug": "^4.1.1", - "istanbul-lib-coverage": "^2.0.5", - "make-dir": "^2.1.0", - "rimraf": "^2.6.3", - "source-map": "^0.6.1", - }, - "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-3.0.6.tgz", - "version": "3.0.6", - }, - "istanbul-reports": Object { - "integrity": "sha512-SKi4rnMyLBKe0Jy2uUdx28h8oG7ph2PPuQPvIAh31d+Ci+lSiEu4C+h3oBPuJ9+mPKhOyW0M8gY4U5NM1WLeXA==", - "requires": Object { - "handlebars": "^4.1.2", - }, - "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-2.2.6.tgz", - "version": "2.2.6", - }, - "jackspeak": Object { - "integrity": "sha512-VDcSunT+wcccoG46FtzuBAyQKlzhHjli4q31e1fIHGOsRspqNUFjVzGb+7eIFDlTvqLygxapDHPHS0ouT2o/tw==", - "requires": Object { - "cliui": "^4.1.0", - }, - "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-1.4.0.tgz", - "version": "1.4.0", - }, - "js-tokens": Object { - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "version": "4.0.0", - }, - "js-yaml": Object { - "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", - "requires": Object { - "argparse": "^1.0.7", - "esprima": "^4.0.0", - }, - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", - "version": "3.13.1", - }, - "jsbn": Object { - "integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=", - "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", - "version": "0.1.1", - }, - "jsesc": Object { - "integrity": "sha1-RsP+yMGJKxKwgz25vHYiF226s0s=", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-1.3.0.tgz", - "version": "1.3.0", - }, - "json-parse-better-errors": Object { - "integrity": "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==", - "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz", - "version": "1.0.2", - }, - "json-schema": Object { - "integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=", - "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz", - "version": "0.2.3", - }, - "json-schema-traverse": Object { - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "version": "0.4.1", - }, - "json-stringify-safe": Object { - "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=", - "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", - "version": "5.0.1", - }, - "json5": Object { - "integrity": "sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE=", - "resolved": "https://registry.npmjs.org/json5/-/json5-0.5.1.tgz", - "version": "0.5.1", - }, - "jsprim": Object { - "integrity": "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=", - "requires": Object { - "assert-plus": "1.0.0", - "extsprintf": "1.3.0", - "json-schema": "0.2.3", - "verror": "1.10.0", - }, - "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz", - "version": "1.4.1", - }, - "lcid": Object { - "integrity": "sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA==", - "requires": Object { - "invert-kv": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz", - "version": "2.0.0", - }, - "lcov-parse": Object { - "integrity": "sha1-GwuP+ayceIklBYK3C3ExXZ2m2aM=", - "resolved": "https://registry.npmjs.org/lcov-parse/-/lcov-parse-0.0.10.tgz", - "version": "0.0.10", - }, - "load-json-file": Object { - "integrity": "sha1-L19Fq5HjMhYjT9U62rZo607AmTs=", - "requires": Object { - "graceful-fs": "^4.1.2", - "parse-json": "^4.0.0", - "pify": "^3.0.0", - "strip-bom": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-4.0.0.tgz", - "version": "4.0.0", - }, - "locate-path": Object { - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", - "requires": Object { - "p-locate": "^3.0.0", - "path-exists": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "version": "3.0.0", - }, - "lodash": Object { - "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", - "version": "4.17.11", - }, - "lodash.flattendeep": Object { - "integrity": "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=", - "resolved": "https://registry.npmjs.org/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz", - "version": "4.4.0", - }, - "lodash.throttle": Object { - "integrity": "sha1-wj6RtxAkKscMN/HhzaknTMOb8vQ=", - "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", - "version": "4.1.1", - }, - "log-driver": Object { - "integrity": "sha512-U7KCmLdqsGHBLeWqYlFA0V0Sl6P08EE1ZrmA9cxjUE0WVqT9qnyVDPz1kzpFEP0jdJuFnasWIfSd7fsaNXkpbg==", - "resolved": "https://registry.npmjs.org/log-driver/-/log-driver-1.2.7.tgz", - "version": "1.2.7", - }, - "log-update": Object { - "integrity": "sha512-KJ6zAPIHWo7Xg1jYror6IUDFJBq1bQ4Bi4wAEp2y/0ScjBBVi/g0thr0sUVhuvuXauWzczt7T2QHghPDNnKBuw==", - "requires": Object { - "ansi-escapes": "^3.2.0", - "cli-cursor": "^2.1.0", - "wrap-ansi": "^5.0.0", - }, - "resolved": "https://registry.npmjs.org/log-update/-/log-update-3.2.0.tgz", - "version": "3.2.0", - }, - "loose-envify": Object { - "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", - "requires": Object { - "js-tokens": "^3.0.0 || ^4.0.0", - }, - "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", - "version": "1.4.0", - }, - "lru-cache": Object { - "dependencies": Object { - "yallist": Object { - "integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz", - "version": "2.1.2", - }, - }, - "integrity": "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==", - "requires": Object { - "pseudomap": "^1.0.2", - "yallist": "^2.1.2", - }, - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.5.tgz", - "version": "4.1.5", - }, - "make-dir": Object { - "dependencies": Object { - "pify": Object { - "integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==", - "resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz", - "version": "4.0.1", - }, - }, - "integrity": "sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA==", - "requires": Object { - "pify": "^4.0.1", - "semver": "^5.6.0", - }, - "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-2.1.0.tgz", - "version": "2.1.0", - }, - "make-error": Object { - "integrity": "sha512-c3sIjNUow0+8swNwVpqoH4YCShKNFkMaw6oH1mNS2haDZQqkeZFlHS3dhoeEbKKmJB4vXpJucU6oH75aDYeE9g==", - "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.5.tgz", - "version": "1.3.5", - }, - "map-age-cleaner": Object { - "integrity": "sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w==", - "requires": Object { - "p-defer": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz", - "version": "0.1.3", - }, - "mem": Object { - "dependencies": Object { - "mimic-fn": Object { - "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", - "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", - "version": "2.1.0", - }, - }, - "integrity": "sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w==", - "requires": Object { - "map-age-cleaner": "^0.1.1", - "mimic-fn": "^2.0.0", - "p-is-promise": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/mem/-/mem-4.3.0.tgz", - "version": "4.3.0", - }, - "merge-source-map": Object { - "integrity": "sha512-Qkcp7P2ygktpMPh2mCQZaf3jhN6D3Z/qVZHSdWvQ+2Ef5HgRAPBO57A77+ENm0CPx2+1Ce/MYKi3ymqdfuqibw==", - "requires": Object { - "source-map": "^0.6.1", - }, - "resolved": "https://registry.npmjs.org/merge-source-map/-/merge-source-map-1.1.0.tgz", - "version": "1.1.0", - }, - "mime-db": Object { - "integrity": "sha512-jYdeOMPy9vnxEqFRRo6ZvTZ8d9oPb+k18PKoYNYUe2stVEBPPwsln/qWzdbmaIvnhZ9v2P+CuecK+fpUfsV2mA==", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.40.0.tgz", - "version": "1.40.0", - }, - "mime-types": Object { - "integrity": "sha512-WaFHS3MCl5fapm3oLxU4eYDw77IQM2ACcxQ9RIxfaC3ooc6PFuBMGZZsYpvoXS5D5QTWPieo1jjLdAm3TBP3cQ==", - "requires": Object { - "mime-db": "1.40.0", - }, - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.24.tgz", - "version": "2.1.24", - }, - "mimic-fn": Object { - "integrity": "sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ==", - "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-1.2.0.tgz", - "version": "1.2.0", - }, - "minimatch": Object { - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "requires": Object { - "brace-expansion": "^1.1.7", - }, - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "version": "3.0.4", - }, - "minimist": Object { - "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", - "version": "0.0.8", - }, - "minipass": Object { - "integrity": "sha512-UFqVihv6PQgwj8/yTGvl9kPz7xIAY+R5z6XYjRInD3Gk3qx6QGSD6zEcpeG4Dy/lQnv1J6zv8ejV90hyYIKf3w==", - "requires": Object { - "yallist": "^4.0.0", - }, - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.1.1.tgz", - "version": "3.1.1", - }, - "mkdirp": Object { - "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", - "requires": Object { - "minimist": "0.0.8", - }, - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", - "version": "0.5.1", - }, - "ms": Object { - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "version": "2.1.2", - }, - "neo-async": Object { - "integrity": "sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw==", - "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.1.tgz", - "version": "2.6.1", - }, - "nested-error-stacks": Object { - "integrity": "sha512-AO81vsIO1k1sM4Zrd6Hu7regmJN1NSiAja10gc4bX3F0wd+9rQmcuHQaHVQCYIEC8iFXnE+mavh23GOt7wBgug==", - "resolved": "https://registry.npmjs.org/nested-error-stacks/-/nested-error-stacks-2.1.0.tgz", - "version": "2.1.0", - }, - "nice-try": Object { - "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", - "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", - "version": "1.0.5", - }, - "node-modules-regexp": Object { - "integrity": "sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA=", - "resolved": "https://registry.npmjs.org/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz", - "version": "1.0.0", - }, - "normalize-package-data": Object { - "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", - "requires": Object { - "hosted-git-info": "^2.1.4", - "resolve": "^1.10.0", - "semver": "2 || 3 || 4 || 5", - "validate-npm-package-license": "^3.0.1", - }, - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz", - "version": "2.5.0", - }, - "normalize-path": Object { - "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", - "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", - "version": "3.0.0", - }, - "npm-run-path": Object { - "integrity": "sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8=", - "requires": Object { - "path-key": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz", - "version": "2.0.2", - }, - "number-is-nan": Object { - "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", - "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", - "version": "1.0.1", - }, - "nyc": Object { - "dependencies": Object { - "resolve-from": Object { - "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", - "version": "4.0.0", - }, - "rimraf": Object { - "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", - "requires": Object { - "glob": "^7.1.3", - }, - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", - "version": "2.6.3", - }, - }, - "integrity": "sha512-OI0vm6ZGUnoGZv/tLdZ2esSVzDwUC88SNs+6JoSOMVxA+gKMB8Tk7jBwgemLx4O40lhhvZCVw1C+OYLOBOPXWw==", - "requires": Object { - "archy": "^1.0.0", - "caching-transform": "^3.0.2", - "convert-source-map": "^1.6.0", - "cp-file": "^6.2.0", - "find-cache-dir": "^2.1.0", - "find-up": "^3.0.0", - "foreground-child": "^1.5.6", - "glob": "^7.1.3", - "istanbul-lib-coverage": "^2.0.5", - "istanbul-lib-hook": "^2.0.7", - "istanbul-lib-instrument": "^3.3.0", - "istanbul-lib-report": "^2.0.8", - "istanbul-lib-source-maps": "^3.0.6", - "istanbul-reports": "^2.2.4", - "js-yaml": "^3.13.1", - "make-dir": "^2.1.0", - "merge-source-map": "^1.1.0", - "resolve-from": "^4.0.0", - "rimraf": "^2.6.3", - "signal-exit": "^3.0.2", - "spawn-wrap": "^1.4.2", - "test-exclude": "^5.2.3", - "uuid": "^3.3.2", - "yargs": "^13.2.2", - "yargs-parser": "^13.0.0", - }, - "resolved": "https://registry.npmjs.org/nyc/-/nyc-14.1.1.tgz", - "version": "14.1.1", - }, - "oauth-sign": Object { - "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==", - "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz", - "version": "0.9.0", - }, - "object-assign": Object { - "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", - "version": "4.1.1", - }, - "once": Object { - "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", - "requires": Object { - "wrappy": "1", - }, - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "version": "1.4.0", - }, - "onetime": Object { - "integrity": "sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ=", - "requires": Object { - "mimic-fn": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/onetime/-/onetime-2.0.1.tgz", - "version": "2.0.1", - }, - "opener": Object { - "integrity": "sha512-goYSy5c2UXE4Ra1xixabeVh1guIX/ZV/YokJksb6q2lubWu6UbvPQ20p542/sFIll1nl8JnCyK9oBaOcCWXwvA==", - "resolved": "https://registry.npmjs.org/opener/-/opener-1.5.1.tgz", - "version": "1.5.1", - }, - "optimist": Object { - "dependencies": Object { - "minimist": Object { - "integrity": "sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8=", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.10.tgz", - "version": "0.0.10", - }, - }, - "integrity": "sha1-2j6nRob6IaGaERwybpDrFaAZZoY=", - "requires": Object { - "minimist": "~0.0.1", - "wordwrap": "~0.0.2", - }, - "resolved": "https://registry.npmjs.org/optimist/-/optimist-0.6.1.tgz", - "version": "0.6.1", - }, - "os-homedir": Object { - "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", - "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", - "version": "1.0.2", - }, - "os-locale": Object { - "integrity": "sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q==", - "requires": Object { - "execa": "^1.0.0", - "lcid": "^2.0.0", - "mem": "^4.0.0", - }, - "resolved": "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz", - "version": "3.1.0", - }, - "os-tmpdir": Object { - "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", - "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", - "version": "1.0.2", - }, - "own-or": Object { - "integrity": "sha1-Tod/vtqaLsgAD7wLyuOWRe6L+Nw=", - "resolved": "https://registry.npmjs.org/own-or/-/own-or-1.0.0.tgz", - "version": "1.0.0", - }, - "own-or-env": Object { - "integrity": "sha512-y8qULRbRAlL6x2+M0vIe7jJbJx/kmUTzYonRAa2ayesR2qWLswninkVyeJe4x3IEXhdgoNodzjQRKAoEs6Fmrw==", - "requires": Object { - "own-or": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/own-or-env/-/own-or-env-1.0.1.tgz", - "version": "1.0.1", - }, - "p-defer": Object { - "integrity": "sha1-n26xgvbJqozXQwBKfU+WsZaw+ww=", - "resolved": "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz", - "version": "1.0.0", - }, - "p-finally": Object { - "integrity": "sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4=", - "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", - "version": "1.0.0", - }, - "p-is-promise": Object { - "integrity": "sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg==", - "resolved": "https://registry.npmjs.org/p-is-promise/-/p-is-promise-2.1.0.tgz", - "version": "2.1.0", - }, - "p-limit": Object { - "integrity": "sha512-pZbTJpoUsCzV48Mc9Nh51VbwO0X9cuPFE8gYwx9BTCt9SF8/b7Zljd2fVgOxhIF/HDTKgpVzs+GPhyKfjLLFRQ==", - "requires": Object { - "p-try": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.2.0.tgz", - "version": "2.2.0", - }, - "p-locate": Object { - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", - "requires": Object { - "p-limit": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "version": "3.0.0", - }, - "p-try": Object { - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "version": "2.2.0", - }, - "package-hash": Object { - "integrity": "sha512-lOtmukMDVvtkL84rJHI7dpTYq+0rli8N2wlnqUcBuDWCfVhRUfOmnR9SsoHFMLpACvEV60dX7rd0rFaYDZI+FA==", - "requires": Object { - "graceful-fs": "^4.1.15", - "hasha": "^3.0.0", - "lodash.flattendeep": "^4.4.0", - "release-zalgo": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/package-hash/-/package-hash-3.0.0.tgz", - "version": "3.0.0", - }, - "parse-json": Object { - "integrity": "sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA=", - "requires": Object { - "error-ex": "^1.3.1", - "json-parse-better-errors": "^1.0.1", - }, - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz", - "version": "4.0.0", - }, - "path-exists": Object { - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "version": "3.0.0", - }, - "path-is-absolute": Object { - "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "version": "1.0.1", - }, - "path-key": Object { - "integrity": "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", - "version": "2.0.1", - }, - "path-parse": Object { - "integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==", - "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz", - "version": "1.0.6", - }, - "path-type": Object { - "integrity": "sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg==", - "requires": Object { - "pify": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/path-type/-/path-type-3.0.0.tgz", - "version": "3.0.0", - }, - "performance-now": Object { - "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=", - "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", - "version": "2.1.0", - }, - "picomatch": Object { - "integrity": "sha512-oLHIdio3tZ0qH76NybpeneBhYVj0QFTfXEFTc/B3zKQspYfYYkWYgFsmzo+4kvId/bQRcNkVeguI3y+CD22BtA==", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.0.7.tgz", - "version": "2.0.7", - }, - "pify": Object { - "integrity": "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=", - "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", - "version": "3.0.0", - }, - "pirates": Object { - "integrity": "sha512-c5CgUJq6H2k6MJz72Ak1F5sN9n9wlSlJyEnwvpm9/y3WB4E3pHBDT2c6PEiS1vyJvq2bUxUAIu0EGf8Cx4Ic7Q==", - "requires": Object { - "node-modules-regexp": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/pirates/-/pirates-3.0.2.tgz", - "version": "3.0.2", - }, - "pkg-dir": Object { - "integrity": "sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw==", - "requires": Object { - "find-up": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-3.0.0.tgz", - "version": "3.0.0", - }, - "private": Object { - "integrity": "sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg==", - "resolved": "https://registry.npmjs.org/private/-/private-0.1.8.tgz", - "version": "0.1.8", - }, - "process-nextick-args": Object { - "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", - "optional": true, - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", - "version": "2.0.1", - }, - "prop-types": Object { - "integrity": "sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ==", - "requires": Object { - "loose-envify": "^1.4.0", - "object-assign": "^4.1.1", - "react-is": "^16.8.1", - }, - "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.7.2.tgz", - "version": "15.7.2", - }, - "pseudomap": Object { - "integrity": "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=", - "resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz", - "version": "1.0.2", - }, - "psl": Object { - "integrity": "sha512-GEn74ZffufCmkDDLNcl3uuyF/aSD6exEyh1v/ZSdAomB82t6G9hzJVRx0jBmLDW+VfZqks3aScmMw9DszwUalA==", - "resolved": "https://registry.npmjs.org/psl/-/psl-1.2.0.tgz", - "version": "1.2.0", - }, - "pump": Object { - "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", - "requires": Object { - "end-of-stream": "^1.1.0", - "once": "^1.3.1", - }, - "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", - "version": "3.0.0", - }, - "punycode": Object { - "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", - "version": "1.4.1", - }, - "qs": Object { - "integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", - "version": "6.5.2", - }, - "react": Object { - "integrity": "sha512-fglqy3k5E+81pA8s+7K0/T3DBCF0ZDOher1elBFzF7O6arXJgzyu/FW+COxFvAWXJoJN9KIZbT2LXlukwphYTA==", - "requires": Object { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1", - "prop-types": "^15.6.2", - }, - "resolved": "https://registry.npmjs.org/react/-/react-16.12.0.tgz", - "version": "16.12.0", - }, - "react-is": Object { - "integrity": "sha512-aUk3bHfZ2bRSVFFbbeVS4i+lNPZr3/WM5jT2J5omUVV1zzcs1nAaf3l51ctA5FFvCRbhrH0bdAsRRQddFJZPtA==", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.8.6.tgz", - "version": "16.8.6", - }, - "react-reconciler": Object { - "integrity": "sha512-kxERc4H32zV2lXMg/iMiwQHOtyqf15qojvkcZ5Ja2CPkjVohHw9k70pdDBwrnQhLVetUJBSYyqU3yqrlVTOajA==", - "requires": Object { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1", - "prop-types": "^15.6.2", - "scheduler": "^0.13.6", - }, - "resolved": "https://registry.npmjs.org/react-reconciler/-/react-reconciler-0.20.4.tgz", - "version": "0.20.4", - }, - "read-pkg": Object { - "integrity": "sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k=", - "requires": Object { - "load-json-file": "^4.0.0", - "normalize-package-data": "^2.3.2", - "path-type": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-3.0.0.tgz", - "version": "3.0.0", - }, - "read-pkg-up": Object { - "integrity": "sha512-6etQSH7nJGsK0RbG/2TeDzZFa8shjQ1um+SwQQ5cwKy0dhSXdOncEhb1CPpvQG4h7FyOV6EB6YlV0yJvZQNAkA==", - "requires": Object { - "find-up": "^3.0.0", - "read-pkg": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-4.0.0.tgz", - "version": "4.0.0", - }, - "readable-stream": Object { - "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", - "optional": true, - "requires": Object { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1", - }, - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", - "version": "2.3.6", - }, - "readdirp": Object { - "integrity": "sha512-crk4Qu3pmXwgxdSgGhgA/eXiJAPQiX4GMOZZMXnqKxHX7TaoL+3gQVo/WeuAiogr07DpnfjIMpXXa+PAIvwPGQ==", - "requires": Object { - "picomatch": "^2.0.4", - }, - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.2.0.tgz", - "version": "3.2.0", - }, - "redeyed": Object { - "integrity": "sha1-iYS1gV2ZyyIEacme7v/jiRPmzAs=", - "requires": Object { - "esprima": "~4.0.0", - }, - "resolved": "https://registry.npmjs.org/redeyed/-/redeyed-2.1.1.tgz", - "version": "2.1.1", - }, - "regenerator-runtime": Object { - "integrity": "sha512-S/TQAZJO+D3m9xeN1WTI8dLKBBiRgXBlTJvbWjCThHWZj9EvHK70Ff50/tYj2J/fvBY6JtFVwRuazHN2E7M9BA==", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.2.tgz", - "version": "0.13.2", - }, - "release-zalgo": Object { - "integrity": "sha1-CXALflB0Mpc5Mw5TXFqQ+2eFFzA=", - "requires": Object { - "es6-error": "^4.0.1", - }, - "resolved": "https://registry.npmjs.org/release-zalgo/-/release-zalgo-1.0.0.tgz", - "version": "1.0.0", - }, - "repeating": Object { - "integrity": "sha1-UhTFOpJtNVJwdSf7q0FdvAjQbdo=", - "requires": Object { - "is-finite": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/repeating/-/repeating-2.0.1.tgz", - "version": "2.0.1", - }, - "request": Object { - "dependencies": Object { - "safe-buffer": Object { - "integrity": "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz", - "version": "5.2.0", - }, - }, - "integrity": "sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg==", - "requires": Object { - "aws-sign2": "~0.7.0", - "aws4": "^1.8.0", - "caseless": "~0.12.0", - "combined-stream": "~1.0.6", - "extend": "~3.0.2", - "forever-agent": "~0.6.1", - "form-data": "~2.3.2", - "har-validator": "~5.1.0", - "http-signature": "~1.2.0", - "is-typedarray": "~1.0.0", - "isstream": "~0.1.2", - "json-stringify-safe": "~5.0.1", - "mime-types": "~2.1.19", - "oauth-sign": "~0.9.0", - "performance-now": "^2.1.0", - "qs": "~6.5.2", - "safe-buffer": "^5.1.2", - "tough-cookie": "~2.4.3", - "tunnel-agent": "^0.6.0", - "uuid": "^3.3.2", - }, - "resolved": "https://registry.npmjs.org/request/-/request-2.88.0.tgz", - "version": "2.88.0", - }, - "require-directory": Object { - "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "version": "2.1.1", - }, - "require-main-filename": Object { - "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", - "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", - "version": "2.0.0", - }, - "resolve": Object { - "integrity": "sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw==", - "requires": Object { - "path-parse": "^1.0.6", - }, - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.11.1.tgz", - "version": "1.11.1", - }, - "resolve-from": Object { - "integrity": "sha1-six699nWiBvItuZTM17rywoYh0g=", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-3.0.0.tgz", - "version": "3.0.0", - }, - "restore-cursor": Object { - "integrity": "sha1-n37ih/gv0ybU/RYpI9YhKe7g368=", - "requires": Object { - "onetime": "^2.0.0", - "signal-exit": "^3.0.2", - }, - "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-2.0.0.tgz", - "version": "2.0.0", - }, - "rimraf": Object { - "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", - "requires": Object { - "glob": "^7.1.3", - }, - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", - "version": "2.7.1", - }, - "safe-buffer": Object { - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "version": "5.1.2", - }, - "safer-buffer": Object { - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "version": "2.1.2", - }, - "scheduler": Object { - "integrity": "sha512-IWnObHt413ucAYKsD9J1QShUKkbKLQQHdxRyw73sw4FN26iWr3DY/H34xGPe4nmL1DwXyWmSWmMrA9TfQbE/XQ==", - "requires": Object { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1", - }, - "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.13.6.tgz", - "version": "0.13.6", - }, - "semver": Object { - "integrity": "sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA==", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.0.tgz", - "version": "5.7.0", - }, - "set-blocking": Object { - "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "version": "2.0.0", - }, - "shebang-command": Object { - "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", - "requires": Object { - "shebang-regex": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", - "version": "1.2.0", - }, - "shebang-regex": Object { - "integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", - "version": "1.0.0", - }, - "signal-exit": Object { - "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", - "version": "3.0.2", - }, - "slash": Object { - "integrity": "sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU=", - "resolved": "https://registry.npmjs.org/slash/-/slash-1.0.0.tgz", - "version": "1.0.0", - }, - "slice-ansi": Object { - "integrity": "sha512-POqxBK6Lb3q6s047D/XsDVNPnF9Dl8JSaqe9h9lURl0OdNqy/ujDrOiIHtsqXMGbWWTIomRzAMaTyawAU//Reg==", - "requires": Object { - "is-fullwidth-code-point": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-1.0.0.tgz", - "version": "1.0.0", - }, - "source-map": Object { - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "version": "0.6.1", - }, - "source-map-support": Object { - "integrity": "sha512-efyLRJDr68D9hBBNIPWFjhpFzURh+KJykQwvMyW5UiZzYwoF6l4YMMDIJJEyFWxWCqfyxLzz6tSfUFR+kXXsVQ==", - "requires": Object { - "buffer-from": "^1.0.0", - "source-map": "^0.6.0", - }, - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.16.tgz", - "version": "0.5.16", - }, - "spawn-wrap": Object { - "dependencies": Object { - "rimraf": Object { - "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", - "requires": Object { - "glob": "^7.1.3", - }, - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", - "version": "2.6.3", - }, - "which": Object { - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "requires": Object { - "isexe": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "version": "1.3.1", - }, - }, - "integrity": "sha512-vMwR3OmmDhnxCVxM8M+xO/FtIp6Ju/mNaDfCMMW7FDcLRTPFWUswec4LXJHTJE2hwTI9O0YBfygu4DalFl7Ylg==", - "requires": Object { - "foreground-child": "^1.5.6", - "mkdirp": "^0.5.0", - "os-homedir": "^1.0.1", - "rimraf": "^2.6.2", - "signal-exit": "^3.0.2", - "which": "^1.3.0", - }, - "resolved": "https://registry.npmjs.org/spawn-wrap/-/spawn-wrap-1.4.2.tgz", - "version": "1.4.2", - }, - "spdx-correct": Object { - "integrity": "sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q==", - "requires": Object { - "spdx-expression-parse": "^3.0.0", - "spdx-license-ids": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.0.tgz", - "version": "3.1.0", - }, - "spdx-exceptions": Object { - "integrity": "sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA==", - "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz", - "version": "2.2.0", - }, - "spdx-expression-parse": Object { - "integrity": "sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg==", - "requires": Object { - "spdx-exceptions": "^2.1.0", - "spdx-license-ids": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz", - "version": "3.0.0", - }, - "spdx-license-ids": Object { - "integrity": "sha512-7j8LYJLeY/Yb6ACbQ7F76qy5jHkp0U6jgBfJsk97bwWlVUnUWsAgpyaCvo17h0/RQGnQ036tVDomiwoI4pDkQA==", - "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.4.tgz", - "version": "3.0.4", - }, - "sprintf-js": Object { - "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "version": "1.0.3", - }, - "sshpk": Object { - "integrity": "sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==", - "requires": Object { - "asn1": "~0.2.3", - "assert-plus": "^1.0.0", - "bcrypt-pbkdf": "^1.0.0", - "dashdash": "^1.12.0", - "ecc-jsbn": "~0.1.1", - "getpass": "^0.1.1", - "jsbn": "~0.1.0", - "safer-buffer": "^2.0.2", - "tweetnacl": "~0.14.0", - }, - "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz", - "version": "1.16.1", - }, - "stack-utils": Object { - "integrity": "sha512-MTX+MeG5U994cazkjd/9KNAapsHnibjMLnfXodlkXw76JEea0UiNzrqidzo1emMwk7w5Qhc9jd4Bn9TBb1MFwA==", - "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-1.0.2.tgz", - "version": "1.0.2", - }, - "string_decoder": Object { - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "optional": true, - "requires": Object { - "safe-buffer": "~5.1.0", - }, - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "version": "1.1.1", - }, - "string-length": Object { - "dependencies": Object { - "ansi-regex": Object { - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "version": "3.0.0", - }, - "strip-ansi": Object { - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "requires": Object { - "ansi-regex": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "version": "4.0.0", - }, - }, - "integrity": "sha1-1A27aGo6zpYMHP/KVivyxF+DY+0=", - "requires": Object { - "astral-regex": "^1.0.0", - "strip-ansi": "^4.0.0", - }, - "resolved": "https://registry.npmjs.org/string-length/-/string-length-2.0.0.tgz", - "version": "2.0.0", - }, - "string-width": Object { - "dependencies": Object { - "ansi-regex": Object { - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "version": "3.0.0", - }, - "strip-ansi": Object { - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "requires": Object { - "ansi-regex": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "version": "4.0.0", - }, - }, - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", - "requires": Object { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0", - }, - "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "version": "2.1.1", - }, - "strip-ansi": Object { - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", - "requires": Object { - "ansi-regex": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "version": "3.0.1", - }, - "strip-bom": Object { - "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=", - "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", - "version": "3.0.0", - }, - "strip-eof": Object { - "integrity": "sha1-u0P/VZim6wXYm1n80SnJgzE2Br8=", - "resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", - "version": "1.0.0", - }, - "supports-color": Object { - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "requires": Object { - "has-flag": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "version": "5.5.0", - }, - "tap-mocha-reporter": Object { - "dependencies": Object { - "diff": Object { - "integrity": "sha1-fyjS657nsVqX79ic5j3P2qPMur8=", - "resolved": "https://registry.npmjs.org/diff/-/diff-1.4.0.tgz", - "version": "1.4.0", - }, - }, - "integrity": "sha512-8HlAtdmYGlDZuW83QbF/dc46L7cN+AGhLZcanX3I9ILvxUAl+G2/mtucNPSXecTlG/4iP1hv6oMo0tMhkn3Tsw==", - "requires": Object { - "color-support": "^1.1.0", - "debug": "^2.1.3", - "diff": "^1.3.2", - "escape-string-regexp": "^1.0.3", - "glob": "^7.0.5", - "readable-stream": "^2.1.5", - "tap-parser": "^10.0.0", - "tap-yaml": "^1.0.0", - "unicode-length": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/tap-mocha-reporter/-/tap-mocha-reporter-5.0.0.tgz", - "version": "5.0.0", - }, - "tap-parser": Object { - "integrity": "sha512-qdT15H0DoJIi7zOqVXDn9X0gSM68JjNy1w3VemwTJlDnETjbi6SutnqmBfjDJAwkFS79NJ97gZKqie00ZCGmzg==", - "requires": Object { - "events-to-array": "^1.0.1", - "minipass": "^3.0.0", - "tap-yaml": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/tap-parser/-/tap-parser-10.0.1.tgz", - "version": "10.0.1", - }, - "tap-yaml": Object { - "integrity": "sha512-Rxbx4EnrWkYk0/ztcm5u3/VznbyFJpyXO12dDBHKWiDVxy7O2Qw6MRrwO5H6Ww0U5YhRY/4C/VzWmFPhBQc4qQ==", - "requires": Object { - "yaml": "^1.5.0", - }, - "resolved": "https://registry.npmjs.org/tap-yaml/-/tap-yaml-1.0.0.tgz", - "version": "1.0.0", - }, - "tcompare": Object { - "integrity": "sha512-fAfA73uFtFGybWGt4+IYT6UPLYVZQ4NfsP+IXEZGY0vh8e2IF7LVKafcQNMRBLqP0wzEA65LM9Tqj+FSmO8GLw==", - "resolved": "https://registry.npmjs.org/tcompare/-/tcompare-2.3.0.tgz", - "version": "2.3.0", - }, - "test-exclude": Object { - "integrity": "sha512-M+oxtseCFO3EDtAaGH7iiej3CBkzXqFMbzqYAACdzKui4eZA+pq3tZEwChvOdNfa7xxy8BfbmgJSIr43cC/+2g==", - "requires": Object { - "glob": "^7.1.3", - "minimatch": "^3.0.4", - "read-pkg-up": "^4.0.0", - "require-main-filename": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-5.2.3.tgz", - "version": "5.2.3", - }, - "to-fast-properties": Object { - "integrity": "sha1-uDVx+k2MJbguIxsG46MFXeTKGkc=", - "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-1.0.3.tgz", - "version": "1.0.3", - }, - "to-regex-range": Object { - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", - "requires": Object { - "is-number": "^7.0.0", - }, - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "version": "5.0.1", - }, - "tough-cookie": Object { - "integrity": "sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ==", - "requires": Object { - "psl": "^1.1.24", - "punycode": "^1.4.1", - }, - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.4.3.tgz", - "version": "2.4.3", - }, - "treport": Object { - "dependencies": Object { - "punycode": Object { - "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", - "version": "2.1.1", - }, - "react": Object { - "integrity": "sha512-pC0uMkhLaHm11ZSJULfOBqV4tIZkx87ZLvbbQYunNixAAvjnC+snJCg0XQXn9VIsttVsbZP/H/ewzgsd5fxKXw==", - "requires": Object { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1", - "prop-types": "^15.6.2", - "scheduler": "^0.13.6", - }, - "resolved": "https://registry.npmjs.org/react/-/react-16.8.6.tgz", - "version": "16.8.6", - }, - "unicode-length": Object { - "integrity": "sha512-Ph/j1VbS3/r77nhoY2WU0GWGjVYOHL3xpKp0y/Eq2e5r0mT/6b649vm7KFO6RdAdrZkYLdxphYVgvODxPB+Ebg==", - "requires": Object { - "punycode": "^2.0.0", - "strip-ansi": "^3.0.1", - }, - "resolved": "https://registry.npmjs.org/unicode-length/-/unicode-length-2.0.2.tgz", - "version": "2.0.2", - }, - }, - "integrity": "sha512-Po8pQ/rmu4lVNmZWBgqyiHoIWXFeWaMA3H/WoCKw+DiS0xFn43UYRH6hYnjmrWCp0rkLItELQP/maO9uHDe/7A==", - "requires": Object { - "cardinal": "^2.1.1", - "chalk": "^2.4.2", - "import-jsx": "^2.0.0", - "ink": "^2.1.1", - "ms": "^2.1.1", - "react": "^16.8.6", - "string-length": "^2.0.0", - "tap-parser": "^10.0.1", - "unicode-length": "^2.0.1", - }, - "resolved": "https://registry.npmjs.org/treport/-/treport-0.4.2.tgz", - "version": "0.4.2", - }, - "trim-right": Object { - "integrity": "sha1-yy4SAwZ+DI3h9hQJS5/kVwTqYAM=", - "resolved": "https://registry.npmjs.org/trim-right/-/trim-right-1.0.1.tgz", - "version": "1.0.1", - }, - "trivial-deferred": Object { - "integrity": "sha1-N21NKdlR1jaKb3oK6FwvTV4GWPM=", - "resolved": "https://registry.npmjs.org/trivial-deferred/-/trivial-deferred-1.0.1.tgz", - "version": "1.0.1", - }, - "ts-node": Object { - "dependencies": Object { - "source-map-support": Object { - "integrity": "sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ==", - "requires": Object { - "buffer-from": "^1.0.0", - "source-map": "^0.6.0", - }, - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.12.tgz", - "version": "0.5.12", - }, - }, - "integrity": "sha512-dyNS/RqyVTDcmNM4NIBAeDMpsAdaQ+ojdf0GOLqE6nwJOgzEkdRNzJywhDfwnuvB10oa6NLVG1rUJQCpRN7qoQ==", - "requires": Object { - "arg": "^4.1.0", - "diff": "^4.0.1", - "make-error": "^1.1.1", - "source-map-support": "^0.5.6", - "yn": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.3.0.tgz", - "version": "8.3.0", - }, - "tunnel-agent": Object { - "dependencies": Object { - "safe-buffer": Object { - "integrity": "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz", - "version": "5.2.0", - }, - }, - "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", - "requires": Object { - "safe-buffer": "^5.0.1", - }, - "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", - "version": "0.6.0", - }, - "tweetnacl": Object { - "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=", - "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", - "version": "0.14.5", - }, - "typedarray-to-buffer": Object { - "integrity": "sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==", - "requires": Object { - "is-typedarray": "^1.0.0", - }, - "resolved": "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz", - "version": "3.1.5", - }, - "typescript": Object { - "integrity": "sha512-ml7V7JfiN2Xwvcer+XAf2csGO1bPBdRbFCkYBczNZggrBZ9c7G3riSUeJmqEU5uOtXNPMhE3n+R4FA/3YOAWOQ==", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.7.2.tgz", - "version": "3.7.2", - }, - "uglify-js": Object { - "integrity": "sha512-W+jrUHJr3DXKhrsS7NUVxn3zqMOFn0hL/Ei6v0anCIMoKC93TjcflTagwIHLW7SfMFfiQuktQyFVCFHGUE0+yg==", - "optional": true, - "requires": Object { - "commander": "~2.20.0", - "source-map": "~0.6.1", - }, - "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.6.0.tgz", - "version": "3.6.0", - }, - "unicode-length": Object { - "integrity": "sha1-Wtp6f+1RhBpBijKM8UlHisg1irs=", - "requires": Object { - "punycode": "^1.3.2", - "strip-ansi": "^3.0.1", - }, - "resolved": "https://registry.npmjs.org/unicode-length/-/unicode-length-1.0.3.tgz", - "version": "1.0.3", - }, - "uri-js": Object { - "dependencies": Object { - "punycode": Object { - "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", - "version": "2.1.1", - }, - }, - "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==", - "requires": Object { - "punycode": "^2.1.0", - }, - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", - "version": "4.2.2", - }, - "util-deprecate": Object { - "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", - "optional": true, - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "version": "1.0.2", - }, - "uuid": Object { - "integrity": "sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA==", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.3.2.tgz", - "version": "3.3.2", - }, - "validate-npm-package-license": Object { - "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==", - "requires": Object { - "spdx-correct": "^3.0.0", - "spdx-expression-parse": "^3.0.0", - }, - "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz", - "version": "3.0.4", - }, - "verror": Object { - "dependencies": Object { - "extsprintf": Object { - "integrity": "sha1-4mifjzVvrWLMplo6kcXfX5VRaS8=", - "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.4.0.tgz", - "version": "1.4.0", - }, - }, - "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=", - "requires": Object { - "assert-plus": "^1.0.0", - "core-util-is": "1.0.2", - "extsprintf": "^1.2.0", - }, - "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", - "version": "1.10.0", - }, - "vlq": Object { - "integrity": "sha512-DRibZL6DsNhIgYQ+wNdWDL2SL3bKPlVrRiBqV5yuMm++op8W4kGFtaQfCs4KEJn0wBZcHVHJ3eoywX8983k1ow==", - "resolved": "https://registry.npmjs.org/vlq/-/vlq-0.2.3.tgz", - "version": "0.2.3", - }, - "which": Object { - "integrity": "sha512-N7GBZOTswtB9lkQBZA4+zAXrjEIWAUOB93AvzUiudRzRxhUdLURQ7D/gAIMY1gatT/LTbmbcv8SiYazy3eYB7w==", - "requires": Object { - "isexe": "^2.0.0", - }, - "resolved": "https://registry.npmjs.org/which/-/which-2.0.1.tgz", - "version": "2.0.1", - }, - "which-module": Object { - "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", - "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", - "version": "2.0.0", - }, - "widest-line": Object { - "integrity": "sha512-Ba5m9/Fa4Xt9eb2ELXt77JxVDV8w7qQrH0zS/TWSJdLyAwQjWoOzpzj5lwVftDz6n/EOu3tNACS84v509qwnJA==", - "requires": Object { - "string-width": "^2.1.1", - }, - "resolved": "https://registry.npmjs.org/widest-line/-/widest-line-2.0.1.tgz", - "version": "2.0.1", - }, - "wordwrap": Object { - "integrity": "sha1-o9XabNXAvAAI03I0u68b7WMFkQc=", - "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.3.tgz", - "version": "0.0.3", - }, - "wrap-ansi": Object { - "dependencies": Object { - "ansi-regex": Object { - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "version": "4.1.0", - }, - "string-width": Object { - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "requires": Object { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0", - }, - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "version": "3.1.0", - }, - "strip-ansi": Object { - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "requires": Object { - "ansi-regex": "^4.1.0", - }, - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "version": "5.2.0", - }, - }, - "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", - "requires": Object { - "ansi-styles": "^3.2.0", - "string-width": "^3.0.0", - "strip-ansi": "^5.0.0", - }, - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", - "version": "5.1.0", - }, - "wrappy": Object { - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "version": "1.0.2", - }, - "write-file-atomic": Object { - "integrity": "sha512-EIgkf60l2oWsffja2Sf2AL384dx328c0B+cIYPTQq5q2rOYuDV00/iPFBOUiDKKwKMOhkymH8AidPaRvzfxY+Q==", - "requires": Object { - "imurmurhash": "^0.1.4", - "is-typedarray": "^1.0.0", - "signal-exit": "^3.0.2", - "typedarray-to-buffer": "^3.1.5", - }, - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-3.0.0.tgz", - "version": "3.0.0", - }, - "y18n": Object { - "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", - "version": "4.0.0", - }, - "yallist": Object { - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "version": "4.0.0", - }, - "yaml": Object { - "integrity": "sha512-iZfse3lwrJRoSlfs/9KQ9iIXxs9++RvBFVzAqbbBiFT+giYtyanevreF9r61ZTbGMgWQBxAua3FzJiniiJXWWw==", - "requires": Object { - "@babel/runtime": "^7.4.5", - }, - "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.6.0.tgz", - "version": "1.6.0", - }, - "yapool": Object { - "integrity": "sha1-9pPymjFbUNmp2iZGp6ZkXJaYW2o=", - "resolved": "https://registry.npmjs.org/yapool/-/yapool-1.0.0.tgz", - "version": "1.0.0", - }, - "yargs": Object { - "dependencies": Object { - "ansi-regex": Object { - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "version": "4.1.0", - }, - "cliui": Object { - "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", - "requires": Object { - "string-width": "^3.1.0", - "strip-ansi": "^5.2.0", - "wrap-ansi": "^5.1.0", - }, - "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", - "version": "5.0.0", - }, - "string-width": Object { - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "requires": Object { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0", - }, - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "version": "3.1.0", - }, - "strip-ansi": Object { - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "requires": Object { - "ansi-regex": "^4.1.0", - }, - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "version": "5.2.0", - }, - }, - "integrity": "sha512-HG/DWAJa1PAnHT9JAhNa8AbAv3FPaiLzioSjCcmuXXhP8MlpHO5vwls4g4j6n30Z74GVQj8Xa62dWVx1QCGklg==", - "requires": Object { - "cliui": "^5.0.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "os-locale": "^3.1.0", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^13.1.0", - }, - "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.2.4.tgz", - "version": "13.2.4", - }, - "yargs-parser": Object { - "integrity": "sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ==", - "requires": Object { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0", - }, - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.1.tgz", - "version": "13.1.1", - }, - "yn": Object { - "integrity": "sha512-kKfnnYkbTfrAdd0xICNFw7Atm8nKpLcLv9AZGEt+kczL/WQVai4e2V6ZN8U/O+iI6WrNuJjNNOyu4zfhl9D3Hg==", - "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.0.tgz", - "version": "3.1.0", - }, - "yoga-layout-prebuilt": Object { - "integrity": "sha512-9SNQpwuEh2NucU83i2KMZnONVudZ86YNcFk9tq74YaqrQfgJWO3yB9uzH1tAg8iqh5c9F5j0wuyJ2z72wcum2w==", - "resolved": "https://registry.npmjs.org/yoga-layout-prebuilt/-/yoga-layout-prebuilt-1.9.3.tgz", - "version": "1.9.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "tap", "packages": Object { "": Object { @@ -11022,80 +6963,80 @@ exports[`test/shrinkwrap.js TAP loadActual tests tap-with-yarn-lock > yarn.lock "@babel/code-frame@^7.0.0": - "integrity" "sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA==" - "resolved" "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.0.0.tgz" - "version" "7.0.0" + version "7.0.0" + resolved "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.0.0.tgz" + integrity sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA== dependencies: "@babel/highlight" "^7.0.0" "@babel/generator@^7.4.0", "@babel/generator@^7.5.0": - "integrity" "sha512-1TTVrt7J9rcG5PMjvO7VEG3FrEoEJNHxumRq66GemPmzboLWtIjjcJgk8rokuAS7IiRSpgVSu5Vb9lc99iJkOA==" - "resolved" "https://registry.npmjs.org/@babel/generator/-/generator-7.5.0.tgz" - "version" "7.5.0" + version "7.5.0" + resolved "https://registry.npmjs.org/@babel/generator/-/generator-7.5.0.tgz" + integrity sha512-1TTVrt7J9rcG5PMjvO7VEG3FrEoEJNHxumRq66GemPmzboLWtIjjcJgk8rokuAS7IiRSpgVSu5Vb9lc99iJkOA== dependencies: "@babel/types" "^7.5.0" - "jsesc" "^2.5.1" - "lodash" "^4.17.11" - "source-map" "^0.5.0" - "trim-right" "^1.0.1" + jsesc "^2.5.1" + lodash "^4.17.11" + source-map "^0.5.0" + trim-right "^1.0.1" "@babel/helper-function-name@^7.1.0": - "integrity" "sha512-A95XEoCpb3TO+KZzJ4S/5uW5fNe26DjBGqf1o9ucyLyCmi1dXq/B3c8iaWTfBk3VvetUxl16e8tIrd5teOCfGw==" - "resolved" "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.1.0.tgz" - "version" "7.1.0" + version "7.1.0" + resolved "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.1.0.tgz" + integrity sha512-A95XEoCpb3TO+KZzJ4S/5uW5fNe26DjBGqf1o9ucyLyCmi1dXq/B3c8iaWTfBk3VvetUxl16e8tIrd5teOCfGw== dependencies: "@babel/helper-get-function-arity" "^7.0.0" "@babel/template" "^7.1.0" "@babel/types" "^7.0.0" "@babel/helper-get-function-arity@^7.0.0": - "integrity" "sha512-r2DbJeg4svYvt3HOS74U4eWKsUAMRH01Z1ds1zx8KNTPtpTL5JAsdFv8BNyOpVqdFhHkkRDIg5B4AsxmkjAlmQ==" - "resolved" "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz" - "version" "7.0.0" + version "7.0.0" + resolved "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz" + integrity sha512-r2DbJeg4svYvt3HOS74U4eWKsUAMRH01Z1ds1zx8KNTPtpTL5JAsdFv8BNyOpVqdFhHkkRDIg5B4AsxmkjAlmQ== dependencies: "@babel/types" "^7.0.0" "@babel/helper-split-export-declaration@^7.4.4": - "integrity" "sha512-Ro/XkzLf3JFITkW6b+hNxzZ1n5OQ80NvIUdmHspih1XAhtN3vPTuUFT4eQnela+2MaZ5ulH+iyP513KJrxbN7Q==" - "resolved" "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.4.4.tgz" - "version" "7.4.4" + version "7.4.4" + resolved "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.4.4.tgz" + integrity sha512-Ro/XkzLf3JFITkW6b+hNxzZ1n5OQ80NvIUdmHspih1XAhtN3vPTuUFT4eQnela+2MaZ5ulH+iyP513KJrxbN7Q== dependencies: "@babel/types" "^7.4.4" "@babel/highlight@^7.0.0": - "integrity" "sha512-7dV4eu9gBxoM0dAnj/BCFDW9LFU0zvTrkq0ugM7pnHEgguOEeOz1so2ZghEdzviYzQEED0r4EAgpsBChKy1TRQ==" - "resolved" "https://registry.npmjs.org/@babel/highlight/-/highlight-7.5.0.tgz" - "version" "7.5.0" + version "7.5.0" + resolved "https://registry.npmjs.org/@babel/highlight/-/highlight-7.5.0.tgz" + integrity sha512-7dV4eu9gBxoM0dAnj/BCFDW9LFU0zvTrkq0ugM7pnHEgguOEeOz1so2ZghEdzviYzQEED0r4EAgpsBChKy1TRQ== dependencies: - "chalk" "^2.0.0" - "esutils" "^2.0.2" - "js-tokens" "^4.0.0" + chalk "^2.0.0" + esutils "^2.0.2" + js-tokens "^4.0.0" "@babel/parser@^7.4.3", "@babel/parser@^7.4.4", "@babel/parser@^7.5.0": - "integrity" "sha512-I5nW8AhGpOXGCCNYGc+p7ExQIBxRFnS2fd/d862bNOKvmoEPjYPcfIjsfdy0ujagYOIYPczKgD9l3FsgTkAzKA==" - "resolved" "https://registry.npmjs.org/@babel/parser/-/parser-7.5.0.tgz" - "version" "7.5.0" + version "7.5.0" + resolved "https://registry.npmjs.org/@babel/parser/-/parser-7.5.0.tgz" + integrity sha512-I5nW8AhGpOXGCCNYGc+p7ExQIBxRFnS2fd/d862bNOKvmoEPjYPcfIjsfdy0ujagYOIYPczKgD9l3FsgTkAzKA== "@babel/runtime@^7.4.5": - "integrity" "sha512-9M29wrrP7//JBGX70+IrDuD1w4iOYhUGpJNMQJVNAXue+cFeFlMTqBECouIziXPUphlgrfjcfiEpGX4t0WGK4g==" - "resolved" "https://registry.npmjs.org/@babel/runtime/-/runtime-7.5.2.tgz" - "version" "7.5.2" + version "7.5.2" + resolved "https://registry.npmjs.org/@babel/runtime/-/runtime-7.5.2.tgz" + integrity sha512-9M29wrrP7//JBGX70+IrDuD1w4iOYhUGpJNMQJVNAXue+cFeFlMTqBECouIziXPUphlgrfjcfiEpGX4t0WGK4g== dependencies: - "regenerator-runtime" "^0.13.2" + regenerator-runtime "^0.13.2" "@babel/template@^7.1.0", "@babel/template@^7.4.0": - "integrity" "sha512-CiGzLN9KgAvgZsnivND7rkA+AeJ9JB0ciPOD4U59GKbQP2iQl+olF1l76kJOupqidozfZ32ghwBEJDhnk9MEcw==" - "resolved" "https://registry.npmjs.org/@babel/template/-/template-7.4.4.tgz" - "version" "7.4.4" + version "7.4.4" + resolved "https://registry.npmjs.org/@babel/template/-/template-7.4.4.tgz" + integrity sha512-CiGzLN9KgAvgZsnivND7rkA+AeJ9JB0ciPOD4U59GKbQP2iQl+olF1l76kJOupqidozfZ32ghwBEJDhnk9MEcw== dependencies: "@babel/code-frame" "^7.0.0" "@babel/parser" "^7.4.4" "@babel/types" "^7.4.4" "@babel/traverse@^7.4.3": - "integrity" "sha512-SnA9aLbyOCcnnbQEGwdfBggnc142h/rbqqsXcaATj2hZcegCl903pUD/lfpsNBlBSuWow/YDfRyJuWi2EPR5cg==" - "resolved" "https://registry.npmjs.org/@babel/traverse/-/traverse-7.5.0.tgz" - "version" "7.5.0" + version "7.5.0" + resolved "https://registry.npmjs.org/@babel/traverse/-/traverse-7.5.0.tgz" + integrity sha512-SnA9aLbyOCcnnbQEGwdfBggnc142h/rbqqsXcaATj2hZcegCl903pUD/lfpsNBlBSuWow/YDfRyJuWi2EPR5cg== dependencies: "@babel/code-frame" "^7.0.0" "@babel/generator" "^7.5.0" @@ -11103,2674 +7044,2549 @@ exports[`test/shrinkwrap.js TAP loadActual tests tap-with-yarn-lock > yarn.lock "@babel/helper-split-export-declaration" "^7.4.4" "@babel/parser" "^7.5.0" "@babel/types" "^7.5.0" - "debug" "^4.1.0" - "globals" "^11.1.0" - "lodash" "^4.17.11" + debug "^4.1.0" + globals "^11.1.0" + lodash "^4.17.11" "@babel/types@^7.0.0", "@babel/types@^7.4.0", "@babel/types@^7.4.4", "@babel/types@^7.5.0": - "integrity" "sha512-UFpDVqRABKsW01bvw7/wSUe56uy6RXM5+VJibVVAybDGxEW25jdwiFJEf7ASvSaC7sN7rbE/l3cLp2izav+CtQ==" - "resolved" "https://registry.npmjs.org/@babel/types/-/types-7.5.0.tgz" - "version" "7.5.0" + version "7.5.0" + resolved "https://registry.npmjs.org/@babel/types/-/types-7.5.0.tgz" + integrity sha512-UFpDVqRABKsW01bvw7/wSUe56uy6RXM5+VJibVVAybDGxEW25jdwiFJEf7ASvSaC7sN7rbE/l3cLp2izav+CtQ== dependencies: - "esutils" "^2.0.2" - "lodash" "^4.17.11" - "to-fast-properties" "^2.0.0" + esutils "^2.0.2" + lodash "^4.17.11" + to-fast-properties "^2.0.0" "@types/prop-types@*": - "integrity" "sha512-CFzn9idOEpHrgdw8JsoTkaDDyRWk1jrzIV8djzcgpq0y9tG4B4lFT+Nxh52DVpDXV+n4+NPNv7M1Dj5uMp6XFg==" - "resolved" "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.1.tgz" - "version" "15.7.1" + version "15.7.1" + resolved "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.1.tgz" + integrity sha512-CFzn9idOEpHrgdw8JsoTkaDDyRWk1jrzIV8djzcgpq0y9tG4B4lFT+Nxh52DVpDXV+n4+NPNv7M1Dj5uMp6XFg== "@types/react@^16.8.12", "@types/react@^16.8.6": - "integrity" "sha512-abkEOIeljniUN9qB5onp++g0EY38h7atnDHxwKUFz1r3VH1+yG1OKi2sNPTyObL40goBmfKFpdii2lEzwLX1cA==" - "resolved" "https://registry.npmjs.org/@types/react/-/react-16.8.23.tgz" - "version" "16.8.23" + version "16.8.23" + resolved "https://registry.npmjs.org/@types/react/-/react-16.8.23.tgz" + integrity sha512-abkEOIeljniUN9qB5onp++g0EY38h7atnDHxwKUFz1r3VH1+yG1OKi2sNPTyObL40goBmfKFpdii2lEzwLX1cA== dependencies: "@types/prop-types" "*" - "csstype" "^2.2.0" + csstype "^2.2.0" -"ajv@^6.5.5": - "integrity" "sha512-w1YQaVGNC6t2UCPjEawK/vo/dG8OOrVtUmhBT1uJJYxbl5kU2Tj3v6LGqBcsysN1yhuCStJCCA3GqdvKY8sqXQ==" - "resolved" "https://registry.npmjs.org/ajv/-/ajv-6.10.1.tgz" - "version" "6.10.1" +ajv@^6.5.5: + version "6.10.1" + resolved "https://registry.npmjs.org/ajv/-/ajv-6.10.1.tgz" + integrity sha512-w1YQaVGNC6t2UCPjEawK/vo/dG8OOrVtUmhBT1uJJYxbl5kU2Tj3v6LGqBcsysN1yhuCStJCCA3GqdvKY8sqXQ== dependencies: - "fast-deep-equal" "^2.0.1" - "fast-json-stable-stringify" "^2.0.0" - "json-schema-traverse" "^0.4.1" - "uri-js" "^4.2.2" + fast-deep-equal "^2.0.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.2" -"ansi-escapes@^3.2.0": - "integrity" "sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ==" - "resolved" "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-3.2.0.tgz" - "version" "3.2.0" +ansi-escapes@^3.2.0: + version "3.2.0" + resolved "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-3.2.0.tgz" + integrity sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ== -"ansi-regex@^2.0.0": - "integrity" "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=" - "resolved" "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz" - "version" "2.1.1" +ansi-regex@^2.0.0: + version "2.1.1" + resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz" + integrity sha1-w7M6te42DYbg5ijwRorn7yfWVN8= -"ansi-regex@^3.0.0": - "integrity" "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" - "resolved" "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz" - "version" "3.0.0" +ansi-regex@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz" + integrity sha1-7QMXwyIGT3lGbAKWa922Bas32Zg= -"ansi-regex@^4.1.0": - "integrity" "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" - "resolved" "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz" - "version" "4.1.0" +ansi-regex@^4.1.0: + version "4.1.0" + resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz" + integrity sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg== -"ansi-styles@^2.2.1": - "integrity" "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=" - "resolved" "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz" - "version" "2.2.1" +ansi-styles@^2.2.1: + version "2.2.1" + resolved "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz" + integrity sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4= -"ansi-styles@^3.2.0", "ansi-styles@^3.2.1": - "integrity" "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==" - "resolved" "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz" - "version" "3.2.1" +ansi-styles@^3.2.0, ansi-styles@^3.2.1: + version "3.2.1" + resolved "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz" + integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== dependencies: - "color-convert" "^1.9.0" + color-convert "^1.9.0" -"ansicolors@~0.3.2": - "integrity" "sha1-ZlWX3oap/+Oqm/vmyuXG6kJrSXk=" - "resolved" "https://registry.npmjs.org/ansicolors/-/ansicolors-0.3.2.tgz" - "version" "0.3.2" +ansicolors@~0.3.2: + version "0.3.2" + resolved "https://registry.npmjs.org/ansicolors/-/ansicolors-0.3.2.tgz" + integrity sha1-ZlWX3oap/+Oqm/vmyuXG6kJrSXk= -"anymatch@~3.1.1": - "integrity" "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==" - "resolved" "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz" - "version" "3.1.1" +anymatch@~3.1.1: + version "3.1.1" + resolved "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz" + integrity sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg== dependencies: - "normalize-path" "^3.0.0" - "picomatch" "^2.0.4" + normalize-path "^3.0.0" + picomatch "^2.0.4" -"append-transform@^1.0.0": - "integrity" "sha512-P009oYkeHyU742iSZJzZZywj4QRJdnTWffaKuJQLablCZ1uz6/cW4yaRgcDaoQ+uwOxxnt0gRUcwfsNP2ri0gw==" - "resolved" "https://registry.npmjs.org/append-transform/-/append-transform-1.0.0.tgz" - "version" "1.0.0" +append-transform@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/append-transform/-/append-transform-1.0.0.tgz" + integrity sha512-P009oYkeHyU742iSZJzZZywj4QRJdnTWffaKuJQLablCZ1uz6/cW4yaRgcDaoQ+uwOxxnt0gRUcwfsNP2ri0gw== dependencies: - "default-require-extensions" "^2.0.0" + default-require-extensions "^2.0.0" -"archy@^1.0.0": - "integrity" "sha1-+cjBN1fMHde8N5rHeyxipcKGjEA=" - "resolved" "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz" - "version" "1.0.0" +archy@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz" + integrity sha1-+cjBN1fMHde8N5rHeyxipcKGjEA= -"arg@^4.1.0": - "integrity" "sha512-ZWc51jO3qegGkVh8Hwpv636EkbesNV5ZNQPCtRa+0qytRYPEs9IYT9qITY9buezqUH5uqyzlWLcufrzU2rffdg==" - "resolved" "https://registry.npmjs.org/arg/-/arg-4.1.0.tgz" - "version" "4.1.0" +arg@^4.1.0: + version "4.1.0" + resolved "https://registry.npmjs.org/arg/-/arg-4.1.0.tgz" + integrity sha512-ZWc51jO3qegGkVh8Hwpv636EkbesNV5ZNQPCtRa+0qytRYPEs9IYT9qITY9buezqUH5uqyzlWLcufrzU2rffdg== -"argparse@^1.0.7": - "integrity" "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==" - "resolved" "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz" - "version" "1.0.10" +argparse@^1.0.7: + version "1.0.10" + resolved "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz" + integrity sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg== dependencies: - "sprintf-js" "~1.0.2" + sprintf-js "~1.0.2" -"arrify@^1.0.1": - "integrity" "sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0=" - "resolved" "https://registry.npmjs.org/arrify/-/arrify-1.0.1.tgz" - "version" "1.0.1" +arrify@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/arrify/-/arrify-1.0.1.tgz" + integrity sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0= -"asn1@~0.2.3": - "integrity" "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==" - "resolved" "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz" - "version" "0.2.4" +asn1@~0.2.3: + version "0.2.4" + resolved "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz" + integrity sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg== dependencies: - "safer-buffer" "~2.1.0" + safer-buffer "~2.1.0" -"assert-plus@^1.0.0", "assert-plus@1.0.0": - "integrity" "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=" - "resolved" "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz" - "version" "1.0.0" +assert-plus@^1.0.0, assert-plus@1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz" + integrity sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU= -"astral-regex@^1.0.0": - "integrity" "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==" - "resolved" "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz" - "version" "1.0.0" +astral-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz" + integrity sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg== -"async-hook-domain@^1.1.2": - "integrity" "sha512-ZovMxSbADV3+biB7oR1GL5lGyptI24alp0LWHlmz1OFc5oL47pz3EiIF6nXOkDW7yLqih4NtsiYduzdDW0i+Wg==" - "resolved" "https://registry.npmjs.org/async-hook-domain/-/async-hook-domain-1.1.3.tgz" - "version" "1.1.3" +async-hook-domain@^1.1.2: + version "1.1.3" + resolved "https://registry.npmjs.org/async-hook-domain/-/async-hook-domain-1.1.3.tgz" + integrity sha512-ZovMxSbADV3+biB7oR1GL5lGyptI24alp0LWHlmz1OFc5oL47pz3EiIF6nXOkDW7yLqih4NtsiYduzdDW0i+Wg== dependencies: - "source-map-support" "^0.5.11" + source-map-support "^0.5.11" -"asynckit@^0.4.0": - "integrity" "sha1-x57Zf380y48robyXkLzDZkdLS3k=" - "resolved" "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz" - "version" "0.4.0" +asynckit@^0.4.0: + version "0.4.0" + resolved "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz" + integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= -"auto-bind@^2.0.0": - "integrity" "sha512-qZuFvkes1eh9lB2mg8/HG18C+5GIO51r+RrCSst/lh+i5B1CtVlkhTE488M805Nr3dKl0sM/pIFKSKUIlg3zUg==" - "resolved" "https://registry.npmjs.org/auto-bind/-/auto-bind-2.1.0.tgz" - "version" "2.1.0" +auto-bind@^2.0.0: + version "2.1.0" + resolved "https://registry.npmjs.org/auto-bind/-/auto-bind-2.1.0.tgz" + integrity sha512-qZuFvkes1eh9lB2mg8/HG18C+5GIO51r+RrCSst/lh+i5B1CtVlkhTE488M805Nr3dKl0sM/pIFKSKUIlg3zUg== dependencies: "@types/react" "^16.8.12" -"aws-sign2@~0.7.0": - "integrity" "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=" - "resolved" "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz" - "version" "0.7.0" +aws-sign2@~0.7.0: + version "0.7.0" + resolved "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz" + integrity sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg= -"aws4@^1.8.0": - "integrity" "sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ==" - "resolved" "https://registry.npmjs.org/aws4/-/aws4-1.8.0.tgz" - "version" "1.8.0" +aws4@^1.8.0: + version "1.8.0" + resolved "https://registry.npmjs.org/aws4/-/aws4-1.8.0.tgz" + integrity sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ== -"babel-code-frame@^6.26.0": - "integrity" "sha1-Y/1D99weO7fONZR9uP42mj9Yx0s=" - "resolved" "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.26.0.tgz" - "version" "6.26.0" +babel-code-frame@^6.26.0: + version "6.26.0" + resolved "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.26.0.tgz" + integrity sha1-Y/1D99weO7fONZR9uP42mj9Yx0s= dependencies: - "chalk" "^1.1.3" - "esutils" "^2.0.2" - "js-tokens" "^3.0.2" + chalk "^1.1.3" + esutils "^2.0.2" + js-tokens "^3.0.2" -"babel-core@^6.25.0", "babel-core@^6.26.0": - "integrity" "sha512-6jyFLuDmeidKmUEb3NM+/yawG0M2bDZ9Z1qbZP59cyHLz8kYGKYwpJP0UwUKKUiTRNvxfLesJnTedqczP7cTDA==" - "resolved" "https://registry.npmjs.org/babel-core/-/babel-core-6.26.3.tgz" - "version" "6.26.3" +babel-core@^6.25.0, babel-core@^6.26.0: + version "6.26.3" + resolved "https://registry.npmjs.org/babel-core/-/babel-core-6.26.3.tgz" + integrity sha512-6jyFLuDmeidKmUEb3NM+/yawG0M2bDZ9Z1qbZP59cyHLz8kYGKYwpJP0UwUKKUiTRNvxfLesJnTedqczP7cTDA== dependencies: - "babel-code-frame" "^6.26.0" - "babel-generator" "^6.26.0" - "babel-helpers" "^6.24.1" - "babel-messages" "^6.23.0" - "babel-register" "^6.26.0" - "babel-runtime" "^6.26.0" - "babel-template" "^6.26.0" - "babel-traverse" "^6.26.0" - "babel-types" "^6.26.0" - "babylon" "^6.18.0" - "convert-source-map" "^1.5.1" - "debug" "^2.6.9" - "json5" "^0.5.1" - "lodash" "^4.17.4" - "minimatch" "^3.0.4" - "path-is-absolute" "^1.0.1" - "private" "^0.1.8" - "slash" "^1.0.0" - "source-map" "^0.5.7" + babel-code-frame "^6.26.0" + babel-generator "^6.26.0" + babel-helpers "^6.24.1" + babel-messages "^6.23.0" + babel-register "^6.26.0" + babel-runtime "^6.26.0" + babel-template "^6.26.0" + babel-traverse "^6.26.0" + babel-types "^6.26.0" + babylon "^6.18.0" + convert-source-map "^1.5.1" + debug "^2.6.9" + json5 "^0.5.1" + lodash "^4.17.4" + minimatch "^3.0.4" + path-is-absolute "^1.0.1" + private "^0.1.8" + slash "^1.0.0" + source-map "^0.5.7" -"babel-generator@^6.26.0": - "integrity" "sha512-HyfwY6ApZj7BYTcJURpM5tznulaBvyio7/0d4zFOeMPUmfxkCjHocCuoLa2SAGzBI8AREcH3eP3758F672DppA==" - "resolved" "https://registry.npmjs.org/babel-generator/-/babel-generator-6.26.1.tgz" - "version" "6.26.1" +babel-generator@^6.26.0: + version "6.26.1" + resolved "https://registry.npmjs.org/babel-generator/-/babel-generator-6.26.1.tgz" + integrity sha512-HyfwY6ApZj7BYTcJURpM5tznulaBvyio7/0d4zFOeMPUmfxkCjHocCuoLa2SAGzBI8AREcH3eP3758F672DppA== dependencies: - "babel-messages" "^6.23.0" - "babel-runtime" "^6.26.0" - "babel-types" "^6.26.0" - "detect-indent" "^4.0.0" - "jsesc" "^1.3.0" - "lodash" "^4.17.4" - "source-map" "^0.5.7" - "trim-right" "^1.0.1" + babel-messages "^6.23.0" + babel-runtime "^6.26.0" + babel-types "^6.26.0" + detect-indent "^4.0.0" + jsesc "^1.3.0" + lodash "^4.17.4" + source-map "^0.5.7" + trim-right "^1.0.1" -"babel-helper-builder-react-jsx@^6.24.1": - "integrity" "sha1-Of+DE7dci2Xc7/HzHTg+D/KkCKA=" - "resolved" "https://registry.npmjs.org/babel-helper-builder-react-jsx/-/babel-helper-builder-react-jsx-6.26.0.tgz" - "version" "6.26.0" +babel-helper-builder-react-jsx@^6.24.1: + version "6.26.0" + resolved "https://registry.npmjs.org/babel-helper-builder-react-jsx/-/babel-helper-builder-react-jsx-6.26.0.tgz" + integrity sha1-Of+DE7dci2Xc7/HzHTg+D/KkCKA= dependencies: - "babel-runtime" "^6.26.0" - "babel-types" "^6.26.0" - "esutils" "^2.0.2" + babel-runtime "^6.26.0" + babel-types "^6.26.0" + esutils "^2.0.2" -"babel-helpers@^6.24.1": - "integrity" "sha1-NHHenK7DiOXIUOWX5Yom3fN2ArI=" - "resolved" "https://registry.npmjs.org/babel-helpers/-/babel-helpers-6.24.1.tgz" - "version" "6.24.1" +babel-helpers@^6.24.1: + version "6.24.1" + resolved "https://registry.npmjs.org/babel-helpers/-/babel-helpers-6.24.1.tgz" + integrity sha1-NHHenK7DiOXIUOWX5Yom3fN2ArI= dependencies: - "babel-runtime" "^6.22.0" - "babel-template" "^6.24.1" + babel-runtime "^6.22.0" + babel-template "^6.24.1" -"babel-messages@^6.23.0": - "integrity" "sha1-8830cDhYA1sqKVHG7F7fbGLyYw4=" - "resolved" "https://registry.npmjs.org/babel-messages/-/babel-messages-6.23.0.tgz" - "version" "6.23.0" +babel-messages@^6.23.0: + version "6.23.0" + resolved "https://registry.npmjs.org/babel-messages/-/babel-messages-6.23.0.tgz" + integrity sha1-8830cDhYA1sqKVHG7F7fbGLyYw4= dependencies: - "babel-runtime" "^6.22.0" + babel-runtime "^6.22.0" -"babel-plugin-syntax-jsx@^6.8.0": - "integrity" "sha1-CvMqmm4Tyno/1QaeYtew9Y0NiUY=" - "resolved" "https://registry.npmjs.org/babel-plugin-syntax-jsx/-/babel-plugin-syntax-jsx-6.18.0.tgz" - "version" "6.18.0" +babel-plugin-syntax-jsx@^6.8.0: + version "6.18.0" + resolved "https://registry.npmjs.org/babel-plugin-syntax-jsx/-/babel-plugin-syntax-jsx-6.18.0.tgz" + integrity sha1-CvMqmm4Tyno/1QaeYtew9Y0NiUY= -"babel-plugin-syntax-object-rest-spread@^6.8.0": - "integrity" "sha1-/WU28rzhODb/o6VFjEkDpZe7O/U=" - "resolved" "https://registry.npmjs.org/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz" - "version" "6.13.0" +babel-plugin-syntax-object-rest-spread@^6.8.0: + version "6.13.0" + resolved "https://registry.npmjs.org/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz" + integrity sha1-/WU28rzhODb/o6VFjEkDpZe7O/U= -"babel-plugin-transform-es2015-destructuring@^6.23.0": - "integrity" "sha1-mXux8auWf2gtKwh2/jWNYOdlxW0=" - "resolved" "https://registry.npmjs.org/babel-plugin-transform-es2015-destructuring/-/babel-plugin-transform-es2015-destructuring-6.23.0.tgz" - "version" "6.23.0" +babel-plugin-transform-es2015-destructuring@^6.23.0: + version "6.23.0" + resolved "https://registry.npmjs.org/babel-plugin-transform-es2015-destructuring/-/babel-plugin-transform-es2015-destructuring-6.23.0.tgz" + integrity sha1-mXux8auWf2gtKwh2/jWNYOdlxW0= dependencies: - "babel-runtime" "^6.22.0" + babel-runtime "^6.22.0" -"babel-plugin-transform-object-rest-spread@^6.23.0": - "integrity" "sha1-DzZpLVD+9rfi1LOsFHgTepY7ewY=" - "resolved" "https://registry.npmjs.org/babel-plugin-transform-object-rest-spread/-/babel-plugin-transform-object-rest-spread-6.26.0.tgz" - "version" "6.26.0" +babel-plugin-transform-object-rest-spread@^6.23.0: + version "6.26.0" + resolved "https://registry.npmjs.org/babel-plugin-transform-object-rest-spread/-/babel-plugin-transform-object-rest-spread-6.26.0.tgz" + integrity sha1-DzZpLVD+9rfi1LOsFHgTepY7ewY= dependencies: - "babel-plugin-syntax-object-rest-spread" "^6.8.0" - "babel-runtime" "^6.26.0" + babel-plugin-syntax-object-rest-spread "^6.8.0" + babel-runtime "^6.26.0" -"babel-plugin-transform-react-jsx@^6.24.1": - "integrity" "sha1-hAoCjn30YN/DotKfDA2R9jduZqM=" - "resolved" "https://registry.npmjs.org/babel-plugin-transform-react-jsx/-/babel-plugin-transform-react-jsx-6.24.1.tgz" - "version" "6.24.1" +babel-plugin-transform-react-jsx@^6.24.1: + version "6.24.1" + resolved "https://registry.npmjs.org/babel-plugin-transform-react-jsx/-/babel-plugin-transform-react-jsx-6.24.1.tgz" + integrity sha1-hAoCjn30YN/DotKfDA2R9jduZqM= dependencies: - "babel-helper-builder-react-jsx" "^6.24.1" - "babel-plugin-syntax-jsx" "^6.8.0" - "babel-runtime" "^6.22.0" + babel-helper-builder-react-jsx "^6.24.1" + babel-plugin-syntax-jsx "^6.8.0" + babel-runtime "^6.22.0" -"babel-register@^6.26.0": - "integrity" "sha1-btAhFz4vy0htestFxgCahW9kcHE=" - "resolved" "https://registry.npmjs.org/babel-register/-/babel-register-6.26.0.tgz" - "version" "6.26.0" +babel-register@^6.26.0: + version "6.26.0" + resolved "https://registry.npmjs.org/babel-register/-/babel-register-6.26.0.tgz" + integrity sha1-btAhFz4vy0htestFxgCahW9kcHE= dependencies: - "babel-core" "^6.26.0" - "babel-runtime" "^6.26.0" - "core-js" "^2.5.0" - "home-or-tmp" "^2.0.0" - "lodash" "^4.17.4" - "mkdirp" "^0.5.1" - "source-map-support" "^0.4.15" + babel-core "^6.26.0" + babel-runtime "^6.26.0" + core-js "^2.5.0" + home-or-tmp "^2.0.0" + lodash "^4.17.4" + mkdirp "^0.5.1" + source-map-support "^0.4.15" -"babel-runtime@^6.22.0", "babel-runtime@^6.26.0": - "integrity" "sha1-llxwWGaOgrVde/4E/yM3vItWR/4=" - "resolved" "https://registry.npmjs.org/babel-runtime/-/babel-runtime-6.26.0.tgz" - "version" "6.26.0" +babel-runtime@^6.22.0, babel-runtime@^6.26.0: + version "6.26.0" + resolved "https://registry.npmjs.org/babel-runtime/-/babel-runtime-6.26.0.tgz" + integrity sha1-llxwWGaOgrVde/4E/yM3vItWR/4= dependencies: - "core-js" "^2.4.0" - "regenerator-runtime" "^0.11.0" + core-js "^2.4.0" + regenerator-runtime "^0.11.0" -"babel-template@^6.24.1", "babel-template@^6.26.0": - "integrity" "sha1-3gPi0WOWsGn0bdn/+FIfsaDjXgI=" - "resolved" "https://registry.npmjs.org/babel-template/-/babel-template-6.26.0.tgz" - "version" "6.26.0" +babel-template@^6.24.1, babel-template@^6.26.0: + version "6.26.0" + resolved "https://registry.npmjs.org/babel-template/-/babel-template-6.26.0.tgz" + integrity sha1-3gPi0WOWsGn0bdn/+FIfsaDjXgI= dependencies: - "babel-runtime" "^6.26.0" - "babel-traverse" "^6.26.0" - "babel-types" "^6.26.0" - "babylon" "^6.18.0" - "lodash" "^4.17.4" + babel-runtime "^6.26.0" + babel-traverse "^6.26.0" + babel-types "^6.26.0" + babylon "^6.18.0" + lodash "^4.17.4" -"babel-traverse@^6.26.0": - "integrity" "sha1-RqnL1+3MYsjlwGTi0tjQ9ANXZu4=" - "resolved" "https://registry.npmjs.org/babel-traverse/-/babel-traverse-6.26.0.tgz" - "version" "6.26.0" +babel-traverse@^6.26.0: + version "6.26.0" + resolved "https://registry.npmjs.org/babel-traverse/-/babel-traverse-6.26.0.tgz" + integrity sha1-RqnL1+3MYsjlwGTi0tjQ9ANXZu4= dependencies: - "babel-code-frame" "^6.26.0" - "babel-messages" "^6.23.0" - "babel-runtime" "^6.26.0" - "babel-types" "^6.26.0" - "babylon" "^6.18.0" - "debug" "^2.6.8" - "globals" "^9.18.0" - "invariant" "^2.2.2" - "lodash" "^4.17.4" + babel-code-frame "^6.26.0" + babel-messages "^6.23.0" + babel-runtime "^6.26.0" + babel-types "^6.26.0" + babylon "^6.18.0" + debug "^2.6.8" + globals "^9.18.0" + invariant "^2.2.2" + lodash "^4.17.4" -"babel-types@^6.26.0": - "integrity" "sha1-o7Bz+Uq0nrb6Vc1lInozQ4BjJJc=" - "resolved" "https://registry.npmjs.org/babel-types/-/babel-types-6.26.0.tgz" - "version" "6.26.0" +babel-types@^6.26.0: + version "6.26.0" + resolved "https://registry.npmjs.org/babel-types/-/babel-types-6.26.0.tgz" + integrity sha1-o7Bz+Uq0nrb6Vc1lInozQ4BjJJc= dependencies: - "babel-runtime" "^6.26.0" - "esutils" "^2.0.2" - "lodash" "^4.17.4" - "to-fast-properties" "^1.0.3" + babel-runtime "^6.26.0" + esutils "^2.0.2" + lodash "^4.17.4" + to-fast-properties "^1.0.3" -"babylon@^6.18.0": - "integrity" "sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ==" - "resolved" "https://registry.npmjs.org/babylon/-/babylon-6.18.0.tgz" - "version" "6.18.0" +babylon@^6.18.0: + version "6.18.0" + resolved "https://registry.npmjs.org/babylon/-/babylon-6.18.0.tgz" + integrity sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ== -"balanced-match@^1.0.0": - "integrity" "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" - "resolved" "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz" - "version" "1.0.0" +balanced-match@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz" + integrity sha1-ibTRmasr7kneFk6gK4nORi1xt2c= -"bcrypt-pbkdf@^1.0.0": - "integrity" "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=" - "resolved" "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz" - "version" "1.0.2" +bcrypt-pbkdf@^1.0.0: + version "1.0.2" + resolved "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz" + integrity sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4= dependencies: - "tweetnacl" "^0.14.3" + tweetnacl "^0.14.3" -"binary-extensions@^2.0.0": - "integrity" "sha512-Phlt0plgpIIBOGTT/ehfFnbNlfsDEiqmzE2KRXoX1bLIlir4X/MR+zSyBEkL05ffWgnRSf/DXv+WrUAVr93/ow==" - "resolved" "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.0.0.tgz" - "version" "2.0.0" +binary-extensions@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.0.0.tgz" + integrity sha512-Phlt0plgpIIBOGTT/ehfFnbNlfsDEiqmzE2KRXoX1bLIlir4X/MR+zSyBEkL05ffWgnRSf/DXv+WrUAVr93/ow== -"bind-obj-methods@^2.0.0": - "integrity" "sha512-3/qRXczDi2Cdbz6jE+W3IflJOutRVica8frpBn14de1mBOkzDo+6tY33kNhvkw54Kn3PzRRD2VnGbGPcTAk4sw==" - "resolved" "https://registry.npmjs.org/bind-obj-methods/-/bind-obj-methods-2.0.0.tgz" - "version" "2.0.0" +bind-obj-methods@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/bind-obj-methods/-/bind-obj-methods-2.0.0.tgz" + integrity sha512-3/qRXczDi2Cdbz6jE+W3IflJOutRVica8frpBn14de1mBOkzDo+6tY33kNhvkw54Kn3PzRRD2VnGbGPcTAk4sw== -"brace-expansion@^1.1.7": - "integrity" "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==" - "resolved" "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" - "version" "1.1.11" +brace-expansion@^1.1.7: + version "1.1.11" + resolved "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" + integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== dependencies: - "balanced-match" "^1.0.0" - "concat-map" "0.0.1" + balanced-match "^1.0.0" + concat-map "0.0.1" -"braces@~3.0.2": - "integrity" "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==" - "resolved" "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz" - "version" "3.0.2" +braces@~3.0.2: + version "3.0.2" + resolved "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz" + integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== dependencies: - "fill-range" "^7.0.1" + fill-range "^7.0.1" -"browser-process-hrtime@^1.0.0": - "integrity" "sha512-9o5UecI3GhkpM6DrXr69PblIuWxPKk9Y0jHBRhdocZ2y7YECBFCsHm79Pr3OyR2AvjhDkabFJaDJMYRazHgsow==" - "resolved" "https://registry.npmjs.org/browser-process-hrtime/-/browser-process-hrtime-1.0.0.tgz" - "version" "1.0.0" +browser-process-hrtime@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/browser-process-hrtime/-/browser-process-hrtime-1.0.0.tgz" + integrity sha512-9o5UecI3GhkpM6DrXr69PblIuWxPKk9Y0jHBRhdocZ2y7YECBFCsHm79Pr3OyR2AvjhDkabFJaDJMYRazHgsow== -"buffer-from@^1.0.0": - "integrity" "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==" - "resolved" "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz" - "version" "1.1.1" +buffer-from@^1.0.0: + version "1.1.1" + resolved "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz" + integrity sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A== -"caching-transform@^3.0.2": - "integrity" "sha512-Mtgcv3lh3U0zRii/6qVgQODdPA4G3zhG+jtbCWj39RXuUFTMzH0vcdMtaJS1jPowd+It2Pqr6y3NJMQqOqCE2w==" - "resolved" "https://registry.npmjs.org/caching-transform/-/caching-transform-3.0.2.tgz" - "version" "3.0.2" +caching-transform@^3.0.2: + version "3.0.2" + resolved "https://registry.npmjs.org/caching-transform/-/caching-transform-3.0.2.tgz" + integrity sha512-Mtgcv3lh3U0zRii/6qVgQODdPA4G3zhG+jtbCWj39RXuUFTMzH0vcdMtaJS1jPowd+It2Pqr6y3NJMQqOqCE2w== dependencies: - "hasha" "^3.0.0" - "make-dir" "^2.0.0" - "package-hash" "^3.0.0" - "write-file-atomic" "^2.4.2" + hasha "^3.0.0" + make-dir "^2.0.0" + package-hash "^3.0.0" + write-file-atomic "^2.4.2" -"caller-callsite@^2.0.0": - "integrity" "sha1-hH4PzgoiN1CpoCfFSzNzGtMVQTQ=" - "resolved" "https://registry.npmjs.org/caller-callsite/-/caller-callsite-2.0.0.tgz" - "version" "2.0.0" +caller-callsite@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/caller-callsite/-/caller-callsite-2.0.0.tgz" + integrity sha1-hH4PzgoiN1CpoCfFSzNzGtMVQTQ= dependencies: - "callsites" "^2.0.0" + callsites "^2.0.0" -"caller-path@^2.0.0": - "integrity" "sha1-Ro+DBE42mrIBD6xfBs7uFbsssfQ=" - "resolved" "https://registry.npmjs.org/caller-path/-/caller-path-2.0.0.tgz" - "version" "2.0.0" +caller-path@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/caller-path/-/caller-path-2.0.0.tgz" + integrity sha1-Ro+DBE42mrIBD6xfBs7uFbsssfQ= dependencies: - "caller-callsite" "^2.0.0" + caller-callsite "^2.0.0" -"callsites@^2.0.0": - "integrity" "sha1-BuuE8A7qQT2oav/vrL/7Ngk7PFA=" - "resolved" "https://registry.npmjs.org/callsites/-/callsites-2.0.0.tgz" - "version" "2.0.0" +callsites@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/callsites/-/callsites-2.0.0.tgz" + integrity sha1-BuuE8A7qQT2oav/vrL/7Ngk7PFA= -"camelcase@^5.0.0": - "integrity" "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==" - "resolved" "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz" - "version" "5.3.1" +camelcase@^5.0.0: + version "5.3.1" + resolved "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz" + integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== -"cardinal@^2.1.1": - "integrity" "sha1-fMEFXYItISlU0HsIXeolHMe8VQU=" - "resolved" "https://registry.npmjs.org/cardinal/-/cardinal-2.1.1.tgz" - "version" "2.1.1" +cardinal@^2.1.1: + version "2.1.1" + resolved "https://registry.npmjs.org/cardinal/-/cardinal-2.1.1.tgz" + integrity sha1-fMEFXYItISlU0HsIXeolHMe8VQU= dependencies: - "ansicolors" "~0.3.2" - "redeyed" "~2.1.0" + ansicolors "~0.3.2" + redeyed "~2.1.0" -"caseless@~0.12.0": - "integrity" "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=" - "resolved" "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz" - "version" "0.12.0" +caseless@~0.12.0: + version "0.12.0" + resolved "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz" + integrity sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw= -"chalk@^1.1.3": - "integrity" "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=" - "resolved" "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz" - "version" "1.1.3" +chalk@^1.1.3: + version "1.1.3" + resolved "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz" + integrity sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg= dependencies: - "ansi-styles" "^2.2.1" - "escape-string-regexp" "^1.0.2" - "has-ansi" "^2.0.0" - "strip-ansi" "^3.0.0" - "supports-color" "^2.0.0" + ansi-styles "^2.2.1" + escape-string-regexp "^1.0.2" + has-ansi "^2.0.0" + strip-ansi "^3.0.0" + supports-color "^2.0.0" -"chalk@^2.0.0", "chalk@^2.4.1", "chalk@^2.4.2": - "integrity" "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==" - "resolved" "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz" - "version" "2.4.2" +chalk@^2.0.0, chalk@^2.4.1, chalk@^2.4.2: + version "2.4.2" + resolved "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz" + integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== dependencies: - "ansi-styles" "^3.2.1" - "escape-string-regexp" "^1.0.5" - "supports-color" "^5.3.0" + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" -"chokidar@^3.0.2": - "integrity" "sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A==" - "resolved" "https://registry.npmjs.org/chokidar/-/chokidar-3.3.0.tgz" - "version" "3.3.0" +chokidar@^3.0.2: + version "3.3.0" + resolved "https://registry.npmjs.org/chokidar/-/chokidar-3.3.0.tgz" + integrity sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A== dependencies: - "anymatch" "~3.1.1" - "braces" "~3.0.2" - "glob-parent" "~5.1.0" - "is-binary-path" "~2.1.0" - "is-glob" "~4.0.1" - "normalize-path" "~3.0.0" - "readdirp" "~3.2.0" + anymatch "~3.1.1" + braces "~3.0.2" + glob-parent "~5.1.0" + is-binary-path "~2.1.0" + is-glob "~4.0.1" + normalize-path "~3.0.0" + readdirp "~3.2.0" optionalDependencies: - "fsevents" "~2.1.1" + fsevents "~2.1.1" -"ci-info@^2.0.0": - "integrity" "sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ==" - "resolved" "https://registry.npmjs.org/ci-info/-/ci-info-2.0.0.tgz" - "version" "2.0.0" +ci-info@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/ci-info/-/ci-info-2.0.0.tgz" + integrity sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ== -"cli-cursor@^2.1.0": - "integrity" "sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU=" - "resolved" "https://registry.npmjs.org/cli-cursor/-/cli-cursor-2.1.0.tgz" - "version" "2.1.0" +cli-cursor@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/cli-cursor/-/cli-cursor-2.1.0.tgz" + integrity sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU= dependencies: - "restore-cursor" "^2.0.0" + restore-cursor "^2.0.0" -"cli-truncate@^1.1.0": - "integrity" "sha512-bAtZo0u82gCfaAGfSNxUdTI9mNyza7D8w4CVCcaOsy7sgwDzvx6ekr6cuWJqY3UGzgnQ1+4wgENup5eIhgxEYA==" - "resolved" "https://registry.npmjs.org/cli-truncate/-/cli-truncate-1.1.0.tgz" - "version" "1.1.0" +cli-truncate@^1.1.0: + version "1.1.0" + resolved "https://registry.npmjs.org/cli-truncate/-/cli-truncate-1.1.0.tgz" + integrity sha512-bAtZo0u82gCfaAGfSNxUdTI9mNyza7D8w4CVCcaOsy7sgwDzvx6ekr6cuWJqY3UGzgnQ1+4wgENup5eIhgxEYA== dependencies: - "slice-ansi" "^1.0.0" - "string-width" "^2.0.0" + slice-ansi "^1.0.0" + string-width "^2.0.0" -"cliui@^4.1.0": - "integrity" "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==" - "resolved" "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz" - "version" "4.1.0" +cliui@^4.1.0: + version "4.1.0" + resolved "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz" + integrity sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ== dependencies: - "string-width" "^2.1.1" - "strip-ansi" "^4.0.0" - "wrap-ansi" "^2.0.0" + string-width "^2.1.1" + strip-ansi "^4.0.0" + wrap-ansi "^2.0.0" -"cliui@^5.0.0": - "integrity" "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==" - "resolved" "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz" - "version" "5.0.0" +cliui@^5.0.0: + version "5.0.0" + resolved "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz" + integrity sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA== dependencies: - "string-width" "^3.1.0" - "strip-ansi" "^5.2.0" - "wrap-ansi" "^5.1.0" + string-width "^3.1.0" + strip-ansi "^5.2.0" + wrap-ansi "^5.1.0" -"code-point-at@^1.0.0": - "integrity" "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=" - "resolved" "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz" - "version" "1.1.0" +code-point-at@^1.0.0: + version "1.1.0" + resolved "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz" + integrity sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c= -"color-convert@^1.9.0": - "integrity" "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==" - "resolved" "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz" - "version" "1.9.3" +color-convert@^1.9.0: + version "1.9.3" + resolved "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz" + integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== dependencies: - "color-name" "1.1.3" + color-name "1.1.3" -"color-name@1.1.3": - "integrity" "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=" - "resolved" "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz" - "version" "1.1.3" +color-name@1.1.3: + version "1.1.3" + resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz" + integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= -"color-support@^1.1.0": - "integrity" "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg==" - "resolved" "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz" - "version" "1.1.3" +color-support@^1.1.0: + version "1.1.3" + resolved "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz" + integrity sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg== -"combined-stream@^1.0.6", "combined-stream@~1.0.6": - "integrity" "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==" - "resolved" "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz" - "version" "1.0.8" +combined-stream@^1.0.6, combined-stream@~1.0.6: + version "1.0.8" + resolved "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz" + integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== dependencies: - "delayed-stream" "~1.0.0" + delayed-stream "~1.0.0" -"commander@~2.20.0": - "integrity" "sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ==" - "resolved" "https://registry.npmjs.org/commander/-/commander-2.20.0.tgz" - "version" "2.20.0" +commander@~2.20.0: + version "2.20.0" + resolved "https://registry.npmjs.org/commander/-/commander-2.20.0.tgz" + integrity sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ== -"commondir@^1.0.1": - "integrity" "sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs=" - "resolved" "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz" - "version" "1.0.1" +commondir@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz" + integrity sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs= -"concat-map@0.0.1": - "integrity" "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" - "resolved" "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" - "version" "0.0.1" +concat-map@0.0.1: + version "0.0.1" + resolved "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" + integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= -"convert-source-map@^1.5.1", "convert-source-map@^1.6.0": - "integrity" "sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A==" - "resolved" "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.6.0.tgz" - "version" "1.6.0" +convert-source-map@^1.5.1, convert-source-map@^1.6.0: + version "1.6.0" + resolved "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.6.0.tgz" + integrity sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A== dependencies: - "safe-buffer" "~5.1.1" + safe-buffer "~5.1.1" -"core-js@^2.4.0", "core-js@^2.5.0": - "integrity" "sha512-HOpZf6eXmnl7la+cUdMnLvUxKNqLUzJvgIziQ0DiF3JwSImNphIqdGqzj6hIKyX04MmV0poclQ7+wjWvxQyR2A==" - "resolved" "https://registry.npmjs.org/core-js/-/core-js-2.6.9.tgz" - "version" "2.6.9" +core-js@^2.4.0, core-js@^2.5.0: + version "2.6.9" + resolved "https://registry.npmjs.org/core-js/-/core-js-2.6.9.tgz" + integrity sha512-HOpZf6eXmnl7la+cUdMnLvUxKNqLUzJvgIziQ0DiF3JwSImNphIqdGqzj6hIKyX04MmV0poclQ7+wjWvxQyR2A== -"core-util-is@~1.0.0", "core-util-is@1.0.2": - "integrity" "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" - "resolved" "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz" - "version" "1.0.2" +core-util-is@~1.0.0, core-util-is@1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz" + integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= -"coveralls@^3.0.6": - "integrity" "sha512-mUuH2MFOYB2oBaA4D4Ykqi9LaEYpMMlsiOMJOrv358yAjP6enPIk55fod2fNJ8AvwoYXStWQls37rA+s5e7boA==" - "resolved" "https://registry.npmjs.org/coveralls/-/coveralls-3.0.7.tgz" - "version" "3.0.7" +coveralls@^3.0.6: + version "3.0.7" + resolved "https://registry.npmjs.org/coveralls/-/coveralls-3.0.7.tgz" + integrity sha512-mUuH2MFOYB2oBaA4D4Ykqi9LaEYpMMlsiOMJOrv358yAjP6enPIk55fod2fNJ8AvwoYXStWQls37rA+s5e7boA== dependencies: - "growl" "~> 1.10.0" - "js-yaml" "^3.13.1" - "lcov-parse" "^0.0.10" - "log-driver" "^1.2.7" - "minimist" "^1.2.0" - "request" "^2.86.0" + growl "~> 1.10.0" + js-yaml "^3.13.1" + lcov-parse "^0.0.10" + log-driver "^1.2.7" + minimist "^1.2.0" + request "^2.86.0" -"cp-file@^6.2.0": - "integrity" "sha512-fmvV4caBnofhPe8kOcitBwSn2f39QLjnAnGq3gO9dfd75mUytzKNZB1hde6QHunW2Rt+OwuBOMc3i1tNElbszA==" - "resolved" "https://registry.npmjs.org/cp-file/-/cp-file-6.2.0.tgz" - "version" "6.2.0" +cp-file@^6.2.0: + version "6.2.0" + resolved "https://registry.npmjs.org/cp-file/-/cp-file-6.2.0.tgz" + integrity sha512-fmvV4caBnofhPe8kOcitBwSn2f39QLjnAnGq3gO9dfd75mUytzKNZB1hde6QHunW2Rt+OwuBOMc3i1tNElbszA== dependencies: - "graceful-fs" "^4.1.2" - "make-dir" "^2.0.0" - "nested-error-stacks" "^2.0.0" - "pify" "^4.0.1" - "safe-buffer" "^5.0.1" + graceful-fs "^4.1.2" + make-dir "^2.0.0" + nested-error-stacks "^2.0.0" + pify "^4.0.1" + safe-buffer "^5.0.1" -"cross-spawn@^4": - "integrity" "sha1-e5JHYhwjrf3ThWAEqCPL45dCTUE=" - "resolved" "https://registry.npmjs.org/cross-spawn/-/cross-spawn-4.0.2.tgz" - "version" "4.0.2" +cross-spawn@^4: + version "4.0.2" + resolved "https://registry.npmjs.org/cross-spawn/-/cross-spawn-4.0.2.tgz" + integrity sha1-e5JHYhwjrf3ThWAEqCPL45dCTUE= dependencies: - "lru-cache" "^4.0.1" - "which" "^1.2.9" + lru-cache "^4.0.1" + which "^1.2.9" -"cross-spawn@^6.0.0", "cross-spawn@^6.0.5": - "integrity" "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==" - "resolved" "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz" - "version" "6.0.5" +cross-spawn@^6.0.0, cross-spawn@^6.0.5: + version "6.0.5" + resolved "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz" + integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== dependencies: - "nice-try" "^1.0.4" - "path-key" "^2.0.1" - "semver" "^5.5.0" - "shebang-command" "^1.2.0" - "which" "^1.2.9" + nice-try "^1.0.4" + path-key "^2.0.1" + semver "^5.5.0" + shebang-command "^1.2.0" + which "^1.2.9" -"csstype@^2.2.0": - "integrity" "sha512-RpFbQGUE74iyPgvr46U9t1xoQBM8T4BL8SxrN66Le2xYAPSaDJJKeztV3awugusb3g3G9iL8StmkBBXhcbbXhg==" - "resolved" "https://registry.npmjs.org/csstype/-/csstype-2.6.6.tgz" - "version" "2.6.6" +csstype@^2.2.0: + version "2.6.6" + resolved "https://registry.npmjs.org/csstype/-/csstype-2.6.6.tgz" + integrity sha512-RpFbQGUE74iyPgvr46U9t1xoQBM8T4BL8SxrN66Le2xYAPSaDJJKeztV3awugusb3g3G9iL8StmkBBXhcbbXhg== -"dashdash@^1.12.0": - "integrity" "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=" - "resolved" "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz" - "version" "1.14.1" +dashdash@^1.12.0: + version "1.14.1" + resolved "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz" + integrity sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA= dependencies: - "assert-plus" "^1.0.0" + assert-plus "^1.0.0" -"debug@^2.1.3", "debug@^2.6.8", "debug@^2.6.9": - "integrity" "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==" - "resolved" "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz" - "version" "2.6.9" +debug@^2.1.3, debug@^2.6.8, debug@^2.6.9: + version "2.6.9" + resolved "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz" + integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== dependencies: - "ms" "2.0.0" + ms "2.0.0" -"debug@^4.1.0": - "integrity" "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==" - "resolved" "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz" - "version" "4.1.1" +debug@^4.1.0: + version "4.1.1" + resolved "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz" + integrity sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw== dependencies: - "ms" "^2.1.1" + ms "^2.1.1" -"debug@^4.1.1": - "integrity" "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==" - "resolved" "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz" - "version" "4.1.1" +debug@^4.1.1: + version "4.1.1" + resolved "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz" + integrity sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw== dependencies: - "ms" "^2.1.1" + ms "^2.1.1" -"decamelize@^1.2.0": - "integrity" "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=" - "resolved" "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz" - "version" "1.2.0" +decamelize@^1.2.0: + version "1.2.0" + resolved "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz" + integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= -"default-require-extensions@^2.0.0": - "integrity" "sha1-9fj7sYp9bVCyH2QfZJ67Uiz+JPc=" - "resolved" "https://registry.npmjs.org/default-require-extensions/-/default-require-extensions-2.0.0.tgz" - "version" "2.0.0" +default-require-extensions@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/default-require-extensions/-/default-require-extensions-2.0.0.tgz" + integrity sha1-9fj7sYp9bVCyH2QfZJ67Uiz+JPc= dependencies: - "strip-bom" "^3.0.0" + strip-bom "^3.0.0" -"delayed-stream@~1.0.0": - "integrity" "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=" - "resolved" "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz" - "version" "1.0.0" +delayed-stream@~1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz" + integrity sha1-3zrhmayt+31ECqrgsp4icrJOxhk= -"detect-indent@^4.0.0": - "integrity" "sha1-920GQ1LN9Docts5hnE7jqUdd4gg=" - "resolved" "https://registry.npmjs.org/detect-indent/-/detect-indent-4.0.0.tgz" - "version" "4.0.0" +detect-indent@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/detect-indent/-/detect-indent-4.0.0.tgz" + integrity sha1-920GQ1LN9Docts5hnE7jqUdd4gg= dependencies: - "repeating" "^2.0.0" + repeating "^2.0.0" -"diff@^1.3.2": - "integrity" "sha1-fyjS657nsVqX79ic5j3P2qPMur8=" - "resolved" "https://registry.npmjs.org/diff/-/diff-1.4.0.tgz" - "version" "1.4.0" +diff@^1.3.2: + version "1.4.0" + resolved "https://registry.npmjs.org/diff/-/diff-1.4.0.tgz" + integrity sha1-fyjS657nsVqX79ic5j3P2qPMur8= -"diff@^4.0.1": - "integrity" "sha512-s2+XdvhPCOF01LRQBC8hf4vhbVmI2CGS5aZnxLJlT5FtdhPCDFq80q++zK2KlrVorVDdL5BOGZ/VfLrVtYNF+Q==" - "resolved" "https://registry.npmjs.org/diff/-/diff-4.0.1.tgz" - "version" "4.0.1" +diff@^4.0.1: + version "4.0.1" + resolved "https://registry.npmjs.org/diff/-/diff-4.0.1.tgz" + integrity sha512-s2+XdvhPCOF01LRQBC8hf4vhbVmI2CGS5aZnxLJlT5FtdhPCDFq80q++zK2KlrVorVDdL5BOGZ/VfLrVtYNF+Q== -"ecc-jsbn@~0.1.1": - "integrity" "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=" - "resolved" "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz" - "version" "0.1.2" +ecc-jsbn@~0.1.1: + version "0.1.2" + resolved "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz" + integrity sha1-OoOpBOVDUyh4dMVkt1SThoSamMk= dependencies: - "jsbn" "~0.1.0" - "safer-buffer" "^2.1.0" + jsbn "~0.1.0" + safer-buffer "^2.1.0" -"emoji-regex@^7.0.1": - "integrity" "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==" - "resolved" "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz" - "version" "7.0.3" +emoji-regex@^7.0.1: + version "7.0.3" + resolved "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz" + integrity sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA== -"end-of-stream@^1.1.0": - "integrity" "sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q==" - "resolved" "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.1.tgz" - "version" "1.4.1" +end-of-stream@^1.1.0: + version "1.4.1" + resolved "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.1.tgz" + integrity sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q== dependencies: - "once" "^1.4.0" + once "^1.4.0" -"error-ex@^1.3.1": - "integrity" "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==" - "resolved" "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz" - "version" "1.3.2" +error-ex@^1.3.1: + version "1.3.2" + resolved "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz" + integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== dependencies: - "is-arrayish" "^0.2.1" + is-arrayish "^0.2.1" -"es6-error@^4.0.1": - "integrity" "sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg==" - "resolved" "https://registry.npmjs.org/es6-error/-/es6-error-4.1.1.tgz" - "version" "4.1.1" +es6-error@^4.0.1: + version "4.1.1" + resolved "https://registry.npmjs.org/es6-error/-/es6-error-4.1.1.tgz" + integrity sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg== -"escape-string-regexp@^1.0.2", "escape-string-regexp@^1.0.3", "escape-string-regexp@^1.0.5": - "integrity" "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=" - "resolved" "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" - "version" "1.0.5" +escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.3, escape-string-regexp@^1.0.5: + version "1.0.5" + resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" + integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= -"esm@^3.2.25": - "integrity" "sha512-U1suiZ2oDVWv4zPO56S0NcR5QriEahGtdN2OR6FiOG4WJvcjBVFB0qI4+eKoWFH483PKGuLuu6V8Z4T5g63UVA==" - "resolved" "https://registry.npmjs.org/esm/-/esm-3.2.25.tgz" - "version" "3.2.25" +esm@^3.2.25: + version "3.2.25" + resolved "https://registry.npmjs.org/esm/-/esm-3.2.25.tgz" + integrity sha512-U1suiZ2oDVWv4zPO56S0NcR5QriEahGtdN2OR6FiOG4WJvcjBVFB0qI4+eKoWFH483PKGuLuu6V8Z4T5g63UVA== -"esprima@^4.0.0", "esprima@~4.0.0": - "integrity" "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==" - "resolved" "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz" - "version" "4.0.1" +esprima@^4.0.0, esprima@~4.0.0: + version "4.0.1" + resolved "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz" + integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== -"esutils@^2.0.2": - "integrity" "sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs=" - "resolved" "https://registry.npmjs.org/esutils/-/esutils-2.0.2.tgz" - "version" "2.0.2" +esutils@^2.0.2: + version "2.0.2" + resolved "https://registry.npmjs.org/esutils/-/esutils-2.0.2.tgz" + integrity sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs= -"events-to-array@^1.0.1": - "integrity" "sha1-LUH1Y+H+QA7Uli/hpNXGp1Od9/Y=" - "resolved" "https://registry.npmjs.org/events-to-array/-/events-to-array-1.1.2.tgz" - "version" "1.1.2" +events-to-array@^1.0.1: + version "1.1.2" + resolved "https://registry.npmjs.org/events-to-array/-/events-to-array-1.1.2.tgz" + integrity sha1-LUH1Y+H+QA7Uli/hpNXGp1Od9/Y= -"execa@^1.0.0": - "integrity" "sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==" - "resolved" "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz" - "version" "1.0.0" +execa@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz" + integrity sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA== dependencies: - "cross-spawn" "^6.0.0" - "get-stream" "^4.0.0" - "is-stream" "^1.1.0" - "npm-run-path" "^2.0.0" - "p-finally" "^1.0.0" - "signal-exit" "^3.0.0" - "strip-eof" "^1.0.0" + cross-spawn "^6.0.0" + get-stream "^4.0.0" + is-stream "^1.1.0" + npm-run-path "^2.0.0" + p-finally "^1.0.0" + signal-exit "^3.0.0" + strip-eof "^1.0.0" -"extend@~3.0.2": - "integrity" "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==" - "resolved" "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz" - "version" "3.0.2" +extend@~3.0.2: + version "3.0.2" + resolved "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz" + integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g== -"extsprintf@^1.2.0": - "integrity" "sha1-4mifjzVvrWLMplo6kcXfX5VRaS8=" - "resolved" "https://registry.npmjs.org/extsprintf/-/extsprintf-1.4.0.tgz" - "version" "1.4.0" +extsprintf@^1.2.0: + version "1.4.0" + resolved "https://registry.npmjs.org/extsprintf/-/extsprintf-1.4.0.tgz" + integrity sha1-4mifjzVvrWLMplo6kcXfX5VRaS8= -"extsprintf@1.3.0": - "integrity" "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=" - "resolved" "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz" - "version" "1.3.0" +extsprintf@1.3.0: + version "1.3.0" + resolved "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz" + integrity sha1-lpGEQOMEGnpBT4xS48V06zw+HgU= -"fast-deep-equal@^2.0.1": - "integrity" "sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk=" - "resolved" "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz" - "version" "2.0.1" +fast-deep-equal@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz" + integrity sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk= -"fast-json-stable-stringify@^2.0.0": - "integrity" "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=" - "resolved" "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz" - "version" "2.0.0" +fast-json-stable-stringify@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz" + integrity sha1-1RQsDK7msRifh9OnYREGT4bIu/I= -"fill-range@^7.0.1": - "integrity" "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==" - "resolved" "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz" - "version" "7.0.1" +fill-range@^7.0.1: + version "7.0.1" + resolved "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz" + integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ== dependencies: - "to-regex-range" "^5.0.1" + to-regex-range "^5.0.1" -"find-cache-dir@^2.1.0": - "integrity" "sha512-Tq6PixE0w/VMFfCgbONnkiQIVol/JJL7nRMi20fqzA4NRs9AfeqMGeRdPi3wIhYkxjeBaWh2rxwapn5Tu3IqOQ==" - "resolved" "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-2.1.0.tgz" - "version" "2.1.0" +find-cache-dir@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-2.1.0.tgz" + integrity sha512-Tq6PixE0w/VMFfCgbONnkiQIVol/JJL7nRMi20fqzA4NRs9AfeqMGeRdPi3wIhYkxjeBaWh2rxwapn5Tu3IqOQ== dependencies: - "commondir" "^1.0.1" - "make-dir" "^2.0.0" - "pkg-dir" "^3.0.0" + commondir "^1.0.1" + make-dir "^2.0.0" + pkg-dir "^3.0.0" -"find-up@^3.0.0": - "integrity" "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==" - "resolved" "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz" - "version" "3.0.0" +find-up@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz" + integrity sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg== dependencies: - "locate-path" "^3.0.0" + locate-path "^3.0.0" -"findit@^2.0.0": - "integrity" "sha1-ZQnwEmr0wXhVHPqZOU4DLhOk1W4=" - "resolved" "https://registry.npmjs.org/findit/-/findit-2.0.0.tgz" - "version" "2.0.0" +findit@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/findit/-/findit-2.0.0.tgz" + integrity sha1-ZQnwEmr0wXhVHPqZOU4DLhOk1W4= -"flow-parser@^0.112.0": - "integrity" "sha512-sxjnwhR76B/fUN6n/XerYzn8R1HvtVo3SM8Il3WiZ4nkAlb2BBzKe1TSVKGSyZgD6FW9Bsxom/57ktkqrqmXGA==" - "resolved" "https://registry.npmjs.org/flow-parser/-/flow-parser-0.112.0.tgz" - "version" "0.112.0" +flow-parser@^0.112.0: + version "0.112.0" + resolved "https://registry.npmjs.org/flow-parser/-/flow-parser-0.112.0.tgz" + integrity sha512-sxjnwhR76B/fUN6n/XerYzn8R1HvtVo3SM8Il3WiZ4nkAlb2BBzKe1TSVKGSyZgD6FW9Bsxom/57ktkqrqmXGA== -"flow-remove-types@^2.107.0": - "integrity" "sha512-h3bwcfh41nR9kvlhZFr5ySGmzzOyG4VUsnN4OBl9R6anbWAiX4H5lPhKTwZ7AelWF8Rtqmw/Vnq+VLEMg7PdAw==" - "resolved" "https://registry.npmjs.org/flow-remove-types/-/flow-remove-types-2.112.0.tgz" - "version" "2.112.0" +flow-remove-types@^2.107.0: + version "2.112.0" + resolved "https://registry.npmjs.org/flow-remove-types/-/flow-remove-types-2.112.0.tgz" + integrity sha512-h3bwcfh41nR9kvlhZFr5ySGmzzOyG4VUsnN4OBl9R6anbWAiX4H5lPhKTwZ7AelWF8Rtqmw/Vnq+VLEMg7PdAw== dependencies: - "flow-parser" "^0.112.0" - "pirates" "^3.0.2" - "vlq" "^0.2.1" + flow-parser "^0.112.0" + pirates "^3.0.2" + vlq "^0.2.1" -"foreground-child@^1.3.3", "foreground-child@^1.5.6": - "integrity" "sha1-T9ca0t/elnibmApcCilZN8svXOk=" - "resolved" "https://registry.npmjs.org/foreground-child/-/foreground-child-1.5.6.tgz" - "version" "1.5.6" +foreground-child@^1.3.3, foreground-child@^1.5.6: + version "1.5.6" + resolved "https://registry.npmjs.org/foreground-child/-/foreground-child-1.5.6.tgz" + integrity sha1-T9ca0t/elnibmApcCilZN8svXOk= dependencies: - "cross-spawn" "^4" - "signal-exit" "^3.0.0" + cross-spawn "^4" + signal-exit "^3.0.0" -"forever-agent@~0.6.1": - "integrity" "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=" - "resolved" "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz" - "version" "0.6.1" +forever-agent@~0.6.1: + version "0.6.1" + resolved "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz" + integrity sha1-+8cfDEGt6zf5bFd60e1C2P2sypE= -"form-data@~2.3.2": - "integrity" "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==" - "resolved" "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz" - "version" "2.3.3" +form-data@~2.3.2: + version "2.3.3" + resolved "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz" + integrity sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ== dependencies: - "asynckit" "^0.4.0" - "combined-stream" "^1.0.6" - "mime-types" "^2.1.12" + asynckit "^0.4.0" + combined-stream "^1.0.6" + mime-types "^2.1.12" -"fs-exists-cached@^1.0.0": - "integrity" "sha1-zyVVTKBQ3EmuZla0HeQiWJidy84=" - "resolved" "https://registry.npmjs.org/fs-exists-cached/-/fs-exists-cached-1.0.0.tgz" - "version" "1.0.0" +fs-exists-cached@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/fs-exists-cached/-/fs-exists-cached-1.0.0.tgz" + integrity sha1-zyVVTKBQ3EmuZla0HeQiWJidy84= -"fs.realpath@^1.0.0": - "integrity" "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" - "resolved" "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" - "version" "1.0.0" +fs.realpath@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" + integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= -"fsevents@~2.1.1": - "integrity" "sha512-R4wDiBwZ0KzpgOWetKDug1FZcYhqYnUYKtfZYt4mD5SBz76q0KR4Q9o7GIPamsVPGmW3EYPPJ0dOOjvx32ldZA==" - "resolved" "https://registry.npmjs.org/fsevents/-/fsevents-2.1.2.tgz" - "version" "2.1.2" +fsevents@~2.1.1: + version "2.1.2" + resolved "https://registry.npmjs.org/fsevents/-/fsevents-2.1.2.tgz" + integrity sha512-R4wDiBwZ0KzpgOWetKDug1FZcYhqYnUYKtfZYt4mD5SBz76q0KR4Q9o7GIPamsVPGmW3EYPPJ0dOOjvx32ldZA== -"function-loop@^1.0.2": - "integrity" "sha512-Iw4MzMfS3udk/rqxTiDDCllhGwlOrsr50zViTOO/W6lS/9y6B1J0BD2VZzrnWUYBJsl3aeqjgR5v7bWWhZSYbA==" - "resolved" "https://registry.npmjs.org/function-loop/-/function-loop-1.0.2.tgz" - "version" "1.0.2" +function-loop@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/function-loop/-/function-loop-1.0.2.tgz" + integrity sha512-Iw4MzMfS3udk/rqxTiDDCllhGwlOrsr50zViTOO/W6lS/9y6B1J0BD2VZzrnWUYBJsl3aeqjgR5v7bWWhZSYbA== -"get-caller-file@^2.0.1": - "integrity" "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==" - "resolved" "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz" - "version" "2.0.5" +get-caller-file@^2.0.1: + version "2.0.5" + resolved "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz" + integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== -"get-stream@^4.0.0": - "integrity" "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==" - "resolved" "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz" - "version" "4.1.0" +get-stream@^4.0.0: + version "4.1.0" + resolved "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz" + integrity sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w== dependencies: - "pump" "^3.0.0" + pump "^3.0.0" -"getpass@^0.1.1": - "integrity" "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=" - "resolved" "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz" - "version" "0.1.7" +getpass@^0.1.1: + version "0.1.7" + resolved "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz" + integrity sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo= dependencies: - "assert-plus" "^1.0.0" + assert-plus "^1.0.0" -"glob-parent@~5.1.0": - "integrity" "sha512-qjtRgnIVmOfnKUE3NJAQEdk+lKrxfw8t5ke7SXtfMTHcjsBfOfWXCQfdb30zfDoZQ2IRSIiidmjtbHZPZ++Ihw==" - "resolved" "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.0.tgz" - "version" "5.1.0" +glob-parent@~5.1.0: + version "5.1.0" + resolved "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.0.tgz" + integrity sha512-qjtRgnIVmOfnKUE3NJAQEdk+lKrxfw8t5ke7SXtfMTHcjsBfOfWXCQfdb30zfDoZQ2IRSIiidmjtbHZPZ++Ihw== dependencies: - "is-glob" "^4.0.1" + is-glob "^4.0.1" -"glob@^7.0.5", "glob@^7.1.3", "glob@^7.1.4": - "integrity" "sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A==" - "resolved" "https://registry.npmjs.org/glob/-/glob-7.1.4.tgz" - "version" "7.1.4" +glob@^7.0.5, glob@^7.1.3, glob@^7.1.4: + version "7.1.4" + resolved "https://registry.npmjs.org/glob/-/glob-7.1.4.tgz" + integrity sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A== dependencies: - "fs.realpath" "^1.0.0" - "inflight" "^1.0.4" - "inherits" "2" - "minimatch" "^3.0.4" - "once" "^1.3.0" - "path-is-absolute" "^1.0.0" + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" -"globals@^11.1.0": - "integrity" "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==" - "resolved" "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz" - "version" "11.12.0" +globals@^11.1.0: + version "11.12.0" + resolved "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz" + integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== -"globals@^9.18.0": - "integrity" "sha512-S0nG3CLEQiY/ILxqtztTWH/3iRRdyBLw6KMDxnKMchrtbj2OFmehVh0WUCfW3DUrIgx/qFrJPICrq4Z4sTR9UQ==" - "resolved" "https://registry.npmjs.org/globals/-/globals-9.18.0.tgz" - "version" "9.18.0" +globals@^9.18.0: + version "9.18.0" + resolved "https://registry.npmjs.org/globals/-/globals-9.18.0.tgz" + integrity sha512-S0nG3CLEQiY/ILxqtztTWH/3iRRdyBLw6KMDxnKMchrtbj2OFmehVh0WUCfW3DUrIgx/qFrJPICrq4Z4sTR9UQ== -"graceful-fs@^4.1.11", "graceful-fs@^4.1.15", "graceful-fs@^4.1.2": - "integrity" "sha512-jpSvDPV4Cq/bgtpndIWbI5hmYxhQGHPC4d4cqBPb4DLniCfhJokdXhwhaDuLBGLQdvvRum/UiX6ECVIPvDXqdg==" - "resolved" "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.0.tgz" - "version" "4.2.0" +graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1.2: + version "4.2.0" + resolved "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.0.tgz" + integrity sha512-jpSvDPV4Cq/bgtpndIWbI5hmYxhQGHPC4d4cqBPb4DLniCfhJokdXhwhaDuLBGLQdvvRum/UiX6ECVIPvDXqdg== "growl@~> 1.10.0": - "integrity" "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==" - "resolved" "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz" - "version" "1.10.5" + version "1.10.5" + resolved "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz" + integrity sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA== -"handlebars@^4.1.2": - "integrity" "sha512-nvfrjqvt9xQ8Z/w0ijewdD/vvWDTOweBUm96NTr66Wfvo1mJenBLwcYmPs3TIBP5ruzYGD7Hx/DaM9RmhroGPw==" - "resolved" "https://registry.npmjs.org/handlebars/-/handlebars-4.1.2.tgz" - "version" "4.1.2" +handlebars@^4.1.2: + version "4.1.2" + resolved "https://registry.npmjs.org/handlebars/-/handlebars-4.1.2.tgz" + integrity sha512-nvfrjqvt9xQ8Z/w0ijewdD/vvWDTOweBUm96NTr66Wfvo1mJenBLwcYmPs3TIBP5ruzYGD7Hx/DaM9RmhroGPw== dependencies: - "neo-async" "^2.6.0" - "optimist" "^0.6.1" - "source-map" "^0.6.1" + neo-async "^2.6.0" + optimist "^0.6.1" + source-map "^0.6.1" optionalDependencies: - "uglify-js" "^3.1.4" + uglify-js "^3.1.4" -"har-schema@^2.0.0": - "integrity" "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=" - "resolved" "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz" - "version" "2.0.0" +har-schema@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz" + integrity sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI= -"har-validator@~5.1.0": - "integrity" "sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g==" - "resolved" "https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz" - "version" "5.1.3" +har-validator@~5.1.0: + version "5.1.3" + resolved "https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz" + integrity sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g== dependencies: - "ajv" "^6.5.5" - "har-schema" "^2.0.0" + ajv "^6.5.5" + har-schema "^2.0.0" -"has-ansi@^2.0.0": - "integrity" "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=" - "resolved" "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz" - "version" "2.0.0" +has-ansi@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz" + integrity sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE= dependencies: - "ansi-regex" "^2.0.0" + ansi-regex "^2.0.0" -"has-flag@^3.0.0": - "integrity" "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=" - "resolved" "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz" - "version" "3.0.0" +has-flag@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz" + integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= -"hasha@^3.0.0": - "integrity" "sha1-UqMvq4Vp1BymmmH/GiFPjrfIvTk=" - "resolved" "https://registry.npmjs.org/hasha/-/hasha-3.0.0.tgz" - "version" "3.0.0" +hasha@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/hasha/-/hasha-3.0.0.tgz" + integrity sha1-UqMvq4Vp1BymmmH/GiFPjrfIvTk= dependencies: - "is-stream" "^1.0.1" + is-stream "^1.0.1" -"home-or-tmp@^2.0.0": - "integrity" "sha1-42w/LSyufXRqhX440Y1fMqeILbg=" - "resolved" "https://registry.npmjs.org/home-or-tmp/-/home-or-tmp-2.0.0.tgz" - "version" "2.0.0" +home-or-tmp@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/home-or-tmp/-/home-or-tmp-2.0.0.tgz" + integrity sha1-42w/LSyufXRqhX440Y1fMqeILbg= dependencies: - "os-homedir" "^1.0.0" - "os-tmpdir" "^1.0.1" + os-homedir "^1.0.0" + os-tmpdir "^1.0.1" -"hosted-git-info@^2.1.4": - "integrity" "sha512-7T/BxH19zbcCTa8XkMlbK5lTo1WtgkFi3GvdWEyNuc4Vex7/9Dqbnpsf4JMydcfj9HCg4zUWFTL3Za6lapg5/w==" - "resolved" "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.7.1.tgz" - "version" "2.7.1" +hosted-git-info@^2.1.4: + version "2.7.1" + resolved "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.7.1.tgz" + integrity sha512-7T/BxH19zbcCTa8XkMlbK5lTo1WtgkFi3GvdWEyNuc4Vex7/9Dqbnpsf4JMydcfj9HCg4zUWFTL3Za6lapg5/w== -"http-signature@~1.2.0": - "integrity" "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=" - "resolved" "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz" - "version" "1.2.0" +http-signature@~1.2.0: + version "1.2.0" + resolved "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz" + integrity sha1-muzZJRFHcvPZW2WmCruPfBj7rOE= dependencies: - "assert-plus" "^1.0.0" - "jsprim" "^1.2.2" - "sshpk" "^1.7.0" + assert-plus "^1.0.0" + jsprim "^1.2.2" + sshpk "^1.7.0" -"import-jsx@^2.0.0": - "integrity" "sha512-xmrgtiRnAdjIaRzKwsHut54FA8nx59WqN4MpQvPFr/8yD6BamavkmKHrA5dotAlnIiF4uqMzg/lA5yhPdpIXsA==" - "resolved" "https://registry.npmjs.org/import-jsx/-/import-jsx-2.0.0.tgz" - "version" "2.0.0" +import-jsx@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/import-jsx/-/import-jsx-2.0.0.tgz" + integrity sha512-xmrgtiRnAdjIaRzKwsHut54FA8nx59WqN4MpQvPFr/8yD6BamavkmKHrA5dotAlnIiF4uqMzg/lA5yhPdpIXsA== dependencies: - "babel-core" "^6.25.0" - "babel-plugin-transform-es2015-destructuring" "^6.23.0" - "babel-plugin-transform-object-rest-spread" "^6.23.0" - "babel-plugin-transform-react-jsx" "^6.24.1" - "caller-path" "^2.0.0" - "resolve-from" "^3.0.0" + babel-core "^6.25.0" + babel-plugin-transform-es2015-destructuring "^6.23.0" + babel-plugin-transform-object-rest-spread "^6.23.0" + babel-plugin-transform-react-jsx "^6.24.1" + caller-path "^2.0.0" + resolve-from "^3.0.0" -"imurmurhash@^0.1.4": - "integrity" "sha1-khi5srkoojixPcT7a21XbyMUU+o=" - "resolved" "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz" - "version" "0.1.4" +imurmurhash@^0.1.4: + version "0.1.4" + resolved "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz" + integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= -"inflight@^1.0.4": - "integrity" "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=" - "resolved" "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" - "version" "1.0.6" +inflight@^1.0.4: + version "1.0.6" + resolved "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" + integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk= dependencies: - "once" "^1.3.0" - "wrappy" "1" + once "^1.3.0" + wrappy "1" -"inherits@~2.0.3", "inherits@2": - "integrity" "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" - "resolved" "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" - "version" "2.0.4" +inherits@~2.0.3, inherits@2: + version "2.0.4" + resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== -"ink@^2.1.1", "ink@^2.3.0": - "integrity" "sha512-931rgXHAS3hM++8ygWPOBeHOFwTzHh3pDAVZtiBVOUH6tVvJijym43ODUy22ySo2NwYUFeR/Zj3xuWzBEKMiHw==" - "resolved" "https://registry.npmjs.org/ink/-/ink-2.3.0.tgz" - "version" "2.3.0" +ink@^2.1.1, ink@^2.3.0: + version "2.3.0" + resolved "https://registry.npmjs.org/ink/-/ink-2.3.0.tgz" + integrity sha512-931rgXHAS3hM++8ygWPOBeHOFwTzHh3pDAVZtiBVOUH6tVvJijym43ODUy22ySo2NwYUFeR/Zj3xuWzBEKMiHw== dependencies: "@types/react" "^16.8.6" - "arrify" "^1.0.1" - "auto-bind" "^2.0.0" - "chalk" "^2.4.1" - "cli-cursor" "^2.1.0" - "cli-truncate" "^1.1.0" - "is-ci" "^2.0.0" - "lodash.throttle" "^4.1.1" - "log-update" "^3.0.0" - "prop-types" "^15.6.2" - "react-reconciler" "^0.20.0" - "scheduler" "^0.13.2" - "signal-exit" "^3.0.2" - "slice-ansi" "^1.0.0" - "string-length" "^2.0.0" - "widest-line" "^2.0.0" - "wrap-ansi" "^5.0.0" - "yoga-layout-prebuilt" "^1.9.3" + arrify "^1.0.1" + auto-bind "^2.0.0" + chalk "^2.4.1" + cli-cursor "^2.1.0" + cli-truncate "^1.1.0" + is-ci "^2.0.0" + lodash.throttle "^4.1.1" + log-update "^3.0.0" + prop-types "^15.6.2" + react-reconciler "^0.20.0" + scheduler "^0.13.2" + signal-exit "^3.0.2" + slice-ansi "^1.0.0" + string-length "^2.0.0" + widest-line "^2.0.0" + wrap-ansi "^5.0.0" + yoga-layout-prebuilt "^1.9.3" -"invariant@^2.2.2": - "integrity" "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==" - "resolved" "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz" - "version" "2.2.4" +invariant@^2.2.2: + version "2.2.4" + resolved "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz" + integrity sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA== dependencies: - "loose-envify" "^1.0.0" + loose-envify "^1.0.0" -"invert-kv@^2.0.0": - "integrity" "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==" - "resolved" "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz" - "version" "2.0.0" +invert-kv@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz" + integrity sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA== -"is-arrayish@^0.2.1": - "integrity" "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=" - "resolved" "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz" - "version" "0.2.1" +is-arrayish@^0.2.1: + version "0.2.1" + resolved "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz" + integrity sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0= -"is-binary-path@~2.1.0": - "integrity" "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==" - "resolved" "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz" - "version" "2.1.0" +is-binary-path@~2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz" + integrity sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw== dependencies: - "binary-extensions" "^2.0.0" + binary-extensions "^2.0.0" -"is-ci@^2.0.0": - "integrity" "sha512-YfJT7rkpQB0updsdHLGWrvhBJfcfzNNawYDNIyQXJz0IViGf75O8EBPKSdvw2rF+LGCsX4FZ8tcr3b19LcZq4w==" - "resolved" "https://registry.npmjs.org/is-ci/-/is-ci-2.0.0.tgz" - "version" "2.0.0" +is-ci@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/is-ci/-/is-ci-2.0.0.tgz" + integrity sha512-YfJT7rkpQB0updsdHLGWrvhBJfcfzNNawYDNIyQXJz0IViGf75O8EBPKSdvw2rF+LGCsX4FZ8tcr3b19LcZq4w== dependencies: - "ci-info" "^2.0.0" + ci-info "^2.0.0" -"is-extglob@^2.1.1": - "integrity" "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=" - "resolved" "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz" - "version" "2.1.1" +is-extglob@^2.1.1: + version "2.1.1" + resolved "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz" + integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= -"is-finite@^1.0.0": - "integrity" "sha1-zGZ3aVYCvlUO8R6LSqYwU0K20Ko=" - "resolved" "https://registry.npmjs.org/is-finite/-/is-finite-1.0.2.tgz" - "version" "1.0.2" +is-finite@^1.0.0: + version "1.0.2" + resolved "https://registry.npmjs.org/is-finite/-/is-finite-1.0.2.tgz" + integrity sha1-zGZ3aVYCvlUO8R6LSqYwU0K20Ko= dependencies: - "number-is-nan" "^1.0.0" + number-is-nan "^1.0.0" -"is-fullwidth-code-point@^1.0.0": - "integrity" "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=" - "resolved" "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz" - "version" "1.0.0" +is-fullwidth-code-point@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz" + integrity sha1-754xOG8DGn8NZDr4L95QxFfvAMs= dependencies: - "number-is-nan" "^1.0.0" + number-is-nan "^1.0.0" -"is-fullwidth-code-point@^2.0.0": - "integrity" "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=" - "resolved" "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz" - "version" "2.0.0" +is-fullwidth-code-point@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz" + integrity sha1-o7MKXE8ZkYMWeqq5O+764937ZU8= -"is-glob@^4.0.1", "is-glob@~4.0.1": - "integrity" "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==" - "resolved" "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz" - "version" "4.0.1" +is-glob@^4.0.1, is-glob@~4.0.1: + version "4.0.1" + resolved "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz" + integrity sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg== dependencies: - "is-extglob" "^2.1.1" + is-extglob "^2.1.1" -"is-number@^7.0.0": - "integrity" "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" - "resolved" "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz" - "version" "7.0.0" +is-number@^7.0.0: + version "7.0.0" + resolved "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz" + integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== -"is-stream@^1.0.1", "is-stream@^1.1.0": - "integrity" "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=" - "resolved" "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz" - "version" "1.1.0" +is-stream@^1.0.1, is-stream@^1.1.0: + version "1.1.0" + resolved "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz" + integrity sha1-EtSj3U5o4Lec6428hBc66A2RykQ= -"is-typedarray@^1.0.0", "is-typedarray@~1.0.0": - "integrity" "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=" - "resolved" "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz" - "version" "1.0.0" +is-typedarray@^1.0.0, is-typedarray@~1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz" + integrity sha1-5HnICFjfDBsR3dppQPlgEfzaSpo= -"isarray@~1.0.0": - "integrity" "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" - "resolved" "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz" - "version" "1.0.0" +isarray@~1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz" + integrity sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE= -"isexe@^2.0.0": - "integrity" "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=" - "resolved" "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz" - "version" "2.0.0" +isexe@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz" + integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= -"isstream@~0.1.2": - "integrity" "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=" - "resolved" "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz" - "version" "0.1.2" +isstream@~0.1.2: + version "0.1.2" + resolved "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz" + integrity sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo= -"istanbul-lib-coverage@^2.0.3", "istanbul-lib-coverage@^2.0.5": - "integrity" "sha512-8aXznuEPCJvGnMSRft4udDRDtb1V3pkQkMMI5LI+6HuQz5oQ4J2UFn1H82raA3qJtyOLkkwVqICBQkjnGtn5mA==" - "resolved" "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.5.tgz" - "version" "2.0.5" +istanbul-lib-coverage@^2.0.3, istanbul-lib-coverage@^2.0.5: + version "2.0.5" + resolved "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.5.tgz" + integrity sha512-8aXznuEPCJvGnMSRft4udDRDtb1V3pkQkMMI5LI+6HuQz5oQ4J2UFn1H82raA3qJtyOLkkwVqICBQkjnGtn5mA== -"istanbul-lib-hook@^2.0.7": - "integrity" "sha512-vrRztU9VRRFDyC+aklfLoeXyNdTfga2EI3udDGn4cZ6fpSXpHLV9X6CHvfoMCPtggg8zvDDmC4b9xfu0z6/llA==" - "resolved" "https://registry.npmjs.org/istanbul-lib-hook/-/istanbul-lib-hook-2.0.7.tgz" - "version" "2.0.7" +istanbul-lib-hook@^2.0.7: + version "2.0.7" + resolved "https://registry.npmjs.org/istanbul-lib-hook/-/istanbul-lib-hook-2.0.7.tgz" + integrity sha512-vrRztU9VRRFDyC+aklfLoeXyNdTfga2EI3udDGn4cZ6fpSXpHLV9X6CHvfoMCPtggg8zvDDmC4b9xfu0z6/llA== dependencies: - "append-transform" "^1.0.0" + append-transform "^1.0.0" -"istanbul-lib-instrument@^3.3.0": - "integrity" "sha512-5nnIN4vo5xQZHdXno/YDXJ0G+I3dAm4XgzfSVTPLQpj/zAV2dV6Juy0yaf10/zrJOJeHoN3fraFe+XRq2bFVZA==" - "resolved" "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-3.3.0.tgz" - "version" "3.3.0" +istanbul-lib-instrument@^3.3.0: + version "3.3.0" + resolved "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-3.3.0.tgz" + integrity sha512-5nnIN4vo5xQZHdXno/YDXJ0G+I3dAm4XgzfSVTPLQpj/zAV2dV6Juy0yaf10/zrJOJeHoN3fraFe+XRq2bFVZA== dependencies: "@babel/generator" "^7.4.0" "@babel/parser" "^7.4.3" "@babel/template" "^7.4.0" "@babel/traverse" "^7.4.3" "@babel/types" "^7.4.0" - "istanbul-lib-coverage" "^2.0.5" - "semver" "^6.0.0" - -"istanbul-lib-processinfo@^1.0.0": - "integrity" "sha512-FY0cPmWa4WoQNlvB8VOcafiRoB5nB+l2Pz2xGuXHRSy1KM8QFOYfz/rN+bGMCAeejrY3mrpF5oJHcN0s/garCg==" - "resolved" "https://registry.npmjs.org/istanbul-lib-processinfo/-/istanbul-lib-processinfo-1.0.0.tgz" - "version" "1.0.0" - dependencies: - "archy" "^1.0.0" - "cross-spawn" "^6.0.5" - "istanbul-lib-coverage" "^2.0.3" - "rimraf" "^2.6.3" - "uuid" "^3.3.2" - -"istanbul-lib-report@^2.0.8": - "integrity" "sha512-fHBeG573EIihhAblwgxrSenp0Dby6tJMFR/HvlerBsrCTD5bkUuoNtn3gVh29ZCS824cGGBPn7Sg7cNk+2xUsQ==" - "resolved" "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-2.0.8.tgz" - "version" "2.0.8" - dependencies: - "istanbul-lib-coverage" "^2.0.5" - "make-dir" "^2.1.0" - "supports-color" "^6.1.0" - -"istanbul-lib-source-maps@^3.0.6": - "integrity" "sha512-R47KzMtDJH6X4/YW9XTx+jrLnZnscW4VpNN+1PViSYTejLVPWv7oov+Duf8YQSPyVRUvueQqz1TcsC6mooZTXw==" - "resolved" "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-3.0.6.tgz" - "version" "3.0.6" - dependencies: - "debug" "^4.1.1" - "istanbul-lib-coverage" "^2.0.5" - "make-dir" "^2.1.0" - "rimraf" "^2.6.3" - "source-map" "^0.6.1" - -"istanbul-reports@^2.2.4": - "integrity" "sha512-SKi4rnMyLBKe0Jy2uUdx28h8oG7ph2PPuQPvIAh31d+Ci+lSiEu4C+h3oBPuJ9+mPKhOyW0M8gY4U5NM1WLeXA==" - "resolved" "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-2.2.6.tgz" - "version" "2.2.6" - dependencies: - "handlebars" "^4.1.2" - -"jackspeak@^1.4.0": - "integrity" "sha512-VDcSunT+wcccoG46FtzuBAyQKlzhHjli4q31e1fIHGOsRspqNUFjVzGb+7eIFDlTvqLygxapDHPHS0ouT2o/tw==" - "resolved" "https://registry.npmjs.org/jackspeak/-/jackspeak-1.4.0.tgz" - "version" "1.4.0" - dependencies: - "cliui" "^4.1.0" - -"js-tokens@^3.0.0 || ^4.0.0", "js-tokens@^4.0.0": - "integrity" "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==" - "resolved" "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz" - "version" "4.0.0" - -"js-tokens@^3.0.2": - "integrity" "sha1-mGbfOVECEw449/mWvOtlRDIJwls=" - "resolved" "https://registry.npmjs.org/js-tokens/-/js-tokens-3.0.2.tgz" - "version" "3.0.2" - -"js-yaml@^3.13.1": - "integrity" "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==" - "resolved" "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz" - "version" "3.13.1" - dependencies: - "argparse" "^1.0.7" - "esprima" "^4.0.0" - -"jsbn@~0.1.0": - "integrity" "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=" - "resolved" "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz" - "version" "0.1.1" - -"jsesc@^1.3.0": - "integrity" "sha1-RsP+yMGJKxKwgz25vHYiF226s0s=" - "resolved" "https://registry.npmjs.org/jsesc/-/jsesc-1.3.0.tgz" - "version" "1.3.0" - -"jsesc@^2.5.1": - "integrity" "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==" - "resolved" "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz" - "version" "2.5.2" - -"json-parse-better-errors@^1.0.1": - "integrity" "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==" - "resolved" "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz" - "version" "1.0.2" - -"json-schema-traverse@^0.4.1": - "integrity" "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==" - "resolved" "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz" - "version" "0.4.1" - -"json-schema@0.2.3": - "integrity" "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=" - "resolved" "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz" - "version" "0.2.3" - -"json-stringify-safe@~5.0.1": - "integrity" "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=" - "resolved" "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz" - "version" "5.0.1" - -"json5@^0.5.1": - "integrity" "sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE=" - "resolved" "https://registry.npmjs.org/json5/-/json5-0.5.1.tgz" - "version" "0.5.1" - -"jsprim@^1.2.2": - "integrity" "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=" - "resolved" "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz" - "version" "1.4.1" - dependencies: - "assert-plus" "1.0.0" - "extsprintf" "1.3.0" - "json-schema" "0.2.3" - "verror" "1.10.0" - -"lcid@^2.0.0": - "integrity" "sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA==" - "resolved" "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz" - "version" "2.0.0" - dependencies: - "invert-kv" "^2.0.0" - -"lcov-parse@^0.0.10": - "integrity" "sha1-GwuP+ayceIklBYK3C3ExXZ2m2aM=" - "resolved" "https://registry.npmjs.org/lcov-parse/-/lcov-parse-0.0.10.tgz" - "version" "0.0.10" - -"load-json-file@^4.0.0": - "integrity" "sha1-L19Fq5HjMhYjT9U62rZo607AmTs=" - "resolved" "https://registry.npmjs.org/load-json-file/-/load-json-file-4.0.0.tgz" - "version" "4.0.0" - dependencies: - "graceful-fs" "^4.1.2" - "parse-json" "^4.0.0" - "pify" "^3.0.0" - "strip-bom" "^3.0.0" - -"locate-path@^3.0.0": - "integrity" "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==" - "resolved" "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "p-locate" "^3.0.0" - "path-exists" "^3.0.0" - -"lodash.flattendeep@^4.4.0": - "integrity" "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=" - "resolved" "https://registry.npmjs.org/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz" - "version" "4.4.0" - -"lodash.throttle@^4.1.1": - "integrity" "sha1-wj6RtxAkKscMN/HhzaknTMOb8vQ=" - "resolved" "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz" - "version" "4.1.1" - -"lodash@^4.17.11", "lodash@^4.17.4": - "integrity" "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" - "resolved" "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz" - "version" "4.17.11" - -"log-driver@^1.2.7": - "integrity" "sha512-U7KCmLdqsGHBLeWqYlFA0V0Sl6P08EE1ZrmA9cxjUE0WVqT9qnyVDPz1kzpFEP0jdJuFnasWIfSd7fsaNXkpbg==" - "resolved" "https://registry.npmjs.org/log-driver/-/log-driver-1.2.7.tgz" - "version" "1.2.7" - -"log-update@^3.0.0": - "integrity" "sha512-KJ6zAPIHWo7Xg1jYror6IUDFJBq1bQ4Bi4wAEp2y/0ScjBBVi/g0thr0sUVhuvuXauWzczt7T2QHghPDNnKBuw==" - "resolved" "https://registry.npmjs.org/log-update/-/log-update-3.2.0.tgz" - "version" "3.2.0" - dependencies: - "ansi-escapes" "^3.2.0" - "cli-cursor" "^2.1.0" - "wrap-ansi" "^5.0.0" - -"loose-envify@^1.0.0", "loose-envify@^1.1.0", "loose-envify@^1.4.0": - "integrity" "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==" - "resolved" "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz" - "version" "1.4.0" - dependencies: - "js-tokens" "^3.0.0 || ^4.0.0" - -"lru-cache@^4.0.1": - "integrity" "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==" - "resolved" "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.5.tgz" - "version" "4.1.5" - dependencies: - "pseudomap" "^1.0.2" - "yallist" "^2.1.2" - -"make-dir@^2.0.0", "make-dir@^2.1.0": - "integrity" "sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA==" - "resolved" "https://registry.npmjs.org/make-dir/-/make-dir-2.1.0.tgz" - "version" "2.1.0" - dependencies: - "pify" "^4.0.1" - "semver" "^5.6.0" - -"make-error@^1.1.1": - "integrity" "sha512-c3sIjNUow0+8swNwVpqoH4YCShKNFkMaw6oH1mNS2haDZQqkeZFlHS3dhoeEbKKmJB4vXpJucU6oH75aDYeE9g==" - "resolved" "https://registry.npmjs.org/make-error/-/make-error-1.3.5.tgz" - "version" "1.3.5" - -"map-age-cleaner@^0.1.1": - "integrity" "sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w==" - "resolved" "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz" - "version" "0.1.3" - dependencies: - "p-defer" "^1.0.0" - -"mem@^4.0.0": - "integrity" "sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w==" - "resolved" "https://registry.npmjs.org/mem/-/mem-4.3.0.tgz" - "version" "4.3.0" - dependencies: - "map-age-cleaner" "^0.1.1" - "mimic-fn" "^2.0.0" - "p-is-promise" "^2.0.0" - -"merge-source-map@^1.1.0": - "integrity" "sha512-Qkcp7P2ygktpMPh2mCQZaf3jhN6D3Z/qVZHSdWvQ+2Ef5HgRAPBO57A77+ENm0CPx2+1Ce/MYKi3ymqdfuqibw==" - "resolved" "https://registry.npmjs.org/merge-source-map/-/merge-source-map-1.1.0.tgz" - "version" "1.1.0" - dependencies: - "source-map" "^0.6.1" - -"mime-db@1.40.0": - "integrity" "sha512-jYdeOMPy9vnxEqFRRo6ZvTZ8d9oPb+k18PKoYNYUe2stVEBPPwsln/qWzdbmaIvnhZ9v2P+CuecK+fpUfsV2mA==" - "resolved" "https://registry.npmjs.org/mime-db/-/mime-db-1.40.0.tgz" - "version" "1.40.0" - -"mime-types@^2.1.12", "mime-types@~2.1.19": - "integrity" "sha512-WaFHS3MCl5fapm3oLxU4eYDw77IQM2ACcxQ9RIxfaC3ooc6PFuBMGZZsYpvoXS5D5QTWPieo1jjLdAm3TBP3cQ==" - "resolved" "https://registry.npmjs.org/mime-types/-/mime-types-2.1.24.tgz" - "version" "2.1.24" - dependencies: - "mime-db" "1.40.0" - -"mimic-fn@^1.0.0": - "integrity" "sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ==" - "resolved" "https://registry.npmjs.org/mimic-fn/-/mimic-fn-1.2.0.tgz" - "version" "1.2.0" - -"mimic-fn@^2.0.0": - "integrity" "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==" - "resolved" "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz" - "version" "2.1.0" - -"minimatch@^3.0.4": - "integrity" "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==" - "resolved" "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz" - "version" "3.0.4" - dependencies: - "brace-expansion" "^1.1.7" - -"minimist@^1.2.0": - "integrity" "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=" - "resolved" "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz" - "version" "1.2.0" - -"minimist@~0.0.1": - "integrity" "sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8=" - "resolved" "https://registry.npmjs.org/minimist/-/minimist-0.0.10.tgz" - "version" "0.0.10" - -"minimist@0.0.8": - "integrity" "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=" - "resolved" "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz" - "version" "0.0.8" - -"minipass@^3.0.0": - "integrity" "sha512-UFqVihv6PQgwj8/yTGvl9kPz7xIAY+R5z6XYjRInD3Gk3qx6QGSD6zEcpeG4Dy/lQnv1J6zv8ejV90hyYIKf3w==" - "resolved" "https://registry.npmjs.org/minipass/-/minipass-3.1.1.tgz" - "version" "3.1.1" - dependencies: - "yallist" "^4.0.0" - -"mkdirp@^0.5.0", "mkdirp@^0.5.1": - "integrity" "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=" - "resolved" "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz" - "version" "0.5.1" - dependencies: - "minimist" "0.0.8" - -"ms@^2.1.1": - "integrity" "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" - "resolved" "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" - "version" "2.1.2" - -"ms@2.0.0": - "integrity" "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" - "resolved" "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz" - "version" "2.0.0" - -"neo-async@^2.6.0": - "integrity" "sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw==" - "resolved" "https://registry.npmjs.org/neo-async/-/neo-async-2.6.1.tgz" - "version" "2.6.1" - -"nested-error-stacks@^2.0.0": - "integrity" "sha512-AO81vsIO1k1sM4Zrd6Hu7regmJN1NSiAja10gc4bX3F0wd+9rQmcuHQaHVQCYIEC8iFXnE+mavh23GOt7wBgug==" - "resolved" "https://registry.npmjs.org/nested-error-stacks/-/nested-error-stacks-2.1.0.tgz" - "version" "2.1.0" - -"nice-try@^1.0.4": - "integrity" "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==" - "resolved" "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz" - "version" "1.0.5" - -"node-modules-regexp@^1.0.0": - "integrity" "sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA=" - "resolved" "https://registry.npmjs.org/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz" - "version" "1.0.0" - -"normalize-package-data@^2.3.2": - "integrity" "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==" - "resolved" "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz" - "version" "2.5.0" - dependencies: - "hosted-git-info" "^2.1.4" - "resolve" "^1.10.0" - "semver" "2 || 3 || 4 || 5" - "validate-npm-package-license" "^3.0.1" - -"normalize-path@^3.0.0", "normalize-path@~3.0.0": - "integrity" "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==" - "resolved" "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz" - "version" "3.0.0" - -"npm-run-path@^2.0.0": - "integrity" "sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8=" - "resolved" "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz" - "version" "2.0.2" - dependencies: - "path-key" "^2.0.0" - -"number-is-nan@^1.0.0": - "integrity" "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=" - "resolved" "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz" - "version" "1.0.1" - -"nyc@^14.1.1": - "integrity" "sha512-OI0vm6ZGUnoGZv/tLdZ2esSVzDwUC88SNs+6JoSOMVxA+gKMB8Tk7jBwgemLx4O40lhhvZCVw1C+OYLOBOPXWw==" - "resolved" "https://registry.npmjs.org/nyc/-/nyc-14.1.1.tgz" - "version" "14.1.1" - dependencies: - "archy" "^1.0.0" - "caching-transform" "^3.0.2" - "convert-source-map" "^1.6.0" - "cp-file" "^6.2.0" - "find-cache-dir" "^2.1.0" - "find-up" "^3.0.0" - "foreground-child" "^1.5.6" - "glob" "^7.1.3" - "istanbul-lib-coverage" "^2.0.5" - "istanbul-lib-hook" "^2.0.7" - "istanbul-lib-instrument" "^3.3.0" - "istanbul-lib-report" "^2.0.8" - "istanbul-lib-source-maps" "^3.0.6" - "istanbul-reports" "^2.2.4" - "js-yaml" "^3.13.1" - "make-dir" "^2.1.0" - "merge-source-map" "^1.1.0" - "resolve-from" "^4.0.0" - "rimraf" "^2.6.3" - "signal-exit" "^3.0.2" - "spawn-wrap" "^1.4.2" - "test-exclude" "^5.2.3" - "uuid" "^3.3.2" - "yargs" "^13.2.2" - "yargs-parser" "^13.0.0" - -"oauth-sign@~0.9.0": - "integrity" "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==" - "resolved" "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz" - "version" "0.9.0" - -"object-assign@^4.1.1": - "integrity" "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" - "resolved" "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz" - "version" "4.1.1" - -"once@^1.3.0", "once@^1.3.1", "once@^1.4.0": - "integrity" "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=" - "resolved" "https://registry.npmjs.org/once/-/once-1.4.0.tgz" - "version" "1.4.0" - dependencies: - "wrappy" "1" - -"onetime@^2.0.0": - "integrity" "sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ=" - "resolved" "https://registry.npmjs.org/onetime/-/onetime-2.0.1.tgz" - "version" "2.0.1" - dependencies: - "mimic-fn" "^1.0.0" - -"opener@^1.5.1": - "integrity" "sha512-goYSy5c2UXE4Ra1xixabeVh1guIX/ZV/YokJksb6q2lubWu6UbvPQ20p542/sFIll1nl8JnCyK9oBaOcCWXwvA==" - "resolved" "https://registry.npmjs.org/opener/-/opener-1.5.1.tgz" - "version" "1.5.1" - -"optimist@^0.6.1": - "integrity" "sha1-2j6nRob6IaGaERwybpDrFaAZZoY=" - "resolved" "https://registry.npmjs.org/optimist/-/optimist-0.6.1.tgz" - "version" "0.6.1" - dependencies: - "minimist" "~0.0.1" - "wordwrap" "~0.0.2" - -"os-homedir@^1.0.0", "os-homedir@^1.0.1": - "integrity" "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=" - "resolved" "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz" - "version" "1.0.2" - -"os-locale@^3.1.0": - "integrity" "sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q==" - "resolved" "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz" - "version" "3.1.0" - dependencies: - "execa" "^1.0.0" - "lcid" "^2.0.0" - "mem" "^4.0.0" - -"os-tmpdir@^1.0.1": - "integrity" "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=" - "resolved" "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz" - "version" "1.0.2" - -"own-or-env@^1.0.1": - "integrity" "sha512-y8qULRbRAlL6x2+M0vIe7jJbJx/kmUTzYonRAa2ayesR2qWLswninkVyeJe4x3IEXhdgoNodzjQRKAoEs6Fmrw==" - "resolved" "https://registry.npmjs.org/own-or-env/-/own-or-env-1.0.1.tgz" - "version" "1.0.1" - dependencies: - "own-or" "^1.0.0" - -"own-or@^1.0.0": - "integrity" "sha1-Tod/vtqaLsgAD7wLyuOWRe6L+Nw=" - "resolved" "https://registry.npmjs.org/own-or/-/own-or-1.0.0.tgz" - "version" "1.0.0" - -"p-defer@^1.0.0": - "integrity" "sha1-n26xgvbJqozXQwBKfU+WsZaw+ww=" - "resolved" "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz" - "version" "1.0.0" - -"p-finally@^1.0.0": - "integrity" "sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4=" - "resolved" "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz" - "version" "1.0.0" - -"p-is-promise@^2.0.0": - "integrity" "sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg==" - "resolved" "https://registry.npmjs.org/p-is-promise/-/p-is-promise-2.1.0.tgz" - "version" "2.1.0" - -"p-limit@^2.0.0": - "integrity" "sha512-pZbTJpoUsCzV48Mc9Nh51VbwO0X9cuPFE8gYwx9BTCt9SF8/b7Zljd2fVgOxhIF/HDTKgpVzs+GPhyKfjLLFRQ==" - "resolved" "https://registry.npmjs.org/p-limit/-/p-limit-2.2.0.tgz" - "version" "2.2.0" - dependencies: - "p-try" "^2.0.0" - -"p-locate@^3.0.0": - "integrity" "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==" - "resolved" "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "p-limit" "^2.0.0" - -"p-try@^2.0.0": - "integrity" "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==" - "resolved" "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz" - "version" "2.2.0" - -"package-hash@^3.0.0": - "integrity" "sha512-lOtmukMDVvtkL84rJHI7dpTYq+0rli8N2wlnqUcBuDWCfVhRUfOmnR9SsoHFMLpACvEV60dX7rd0rFaYDZI+FA==" - "resolved" "https://registry.npmjs.org/package-hash/-/package-hash-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "graceful-fs" "^4.1.15" - "hasha" "^3.0.0" - "lodash.flattendeep" "^4.4.0" - "release-zalgo" "^1.0.0" - -"parse-json@^4.0.0": - "integrity" "sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA=" - "resolved" "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz" - "version" "4.0.0" - dependencies: - "error-ex" "^1.3.1" - "json-parse-better-errors" "^1.0.1" - -"path-exists@^3.0.0": - "integrity" "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" - "resolved" "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz" - "version" "3.0.0" - -"path-is-absolute@^1.0.0", "path-is-absolute@^1.0.1": - "integrity" "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" - "resolved" "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz" - "version" "1.0.1" - -"path-key@^2.0.0", "path-key@^2.0.1": - "integrity" "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=" - "resolved" "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz" - "version" "2.0.1" - -"path-parse@^1.0.6": - "integrity" "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==" - "resolved" "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz" - "version" "1.0.6" - -"path-type@^3.0.0": - "integrity" "sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg==" - "resolved" "https://registry.npmjs.org/path-type/-/path-type-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "pify" "^3.0.0" - -"performance-now@^2.1.0": - "integrity" "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=" - "resolved" "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz" - "version" "2.1.0" - -"picomatch@^2.0.4": - "integrity" "sha512-oLHIdio3tZ0qH76NybpeneBhYVj0QFTfXEFTc/B3zKQspYfYYkWYgFsmzo+4kvId/bQRcNkVeguI3y+CD22BtA==" - "resolved" "https://registry.npmjs.org/picomatch/-/picomatch-2.0.7.tgz" - "version" "2.0.7" - -"pify@^3.0.0": - "integrity" "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=" - "resolved" "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz" - "version" "3.0.0" - -"pify@^4.0.1": - "integrity" "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==" - "resolved" "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz" - "version" "4.0.1" - -"pirates@^3.0.2": - "integrity" "sha512-c5CgUJq6H2k6MJz72Ak1F5sN9n9wlSlJyEnwvpm9/y3WB4E3pHBDT2c6PEiS1vyJvq2bUxUAIu0EGf8Cx4Ic7Q==" - "resolved" "https://registry.npmjs.org/pirates/-/pirates-3.0.2.tgz" - "version" "3.0.2" - dependencies: - "node-modules-regexp" "^1.0.0" - -"pkg-dir@^3.0.0": - "integrity" "sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw==" - "resolved" "https://registry.npmjs.org/pkg-dir/-/pkg-dir-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "find-up" "^3.0.0" - -"private@^0.1.8": - "integrity" "sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg==" - "resolved" "https://registry.npmjs.org/private/-/private-0.1.8.tgz" - "version" "0.1.8" - -"process-nextick-args@~2.0.0": - "integrity" "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" - "resolved" "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz" - "version" "2.0.1" - -"prop-types@^15.6.2": - "integrity" "sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ==" - "resolved" "https://registry.npmjs.org/prop-types/-/prop-types-15.7.2.tgz" - "version" "15.7.2" - dependencies: - "loose-envify" "^1.4.0" - "object-assign" "^4.1.1" - "react-is" "^16.8.1" - -"pseudomap@^1.0.2": - "integrity" "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=" - "resolved" "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz" - "version" "1.0.2" - -"psl@^1.1.24": - "integrity" "sha512-GEn74ZffufCmkDDLNcl3uuyF/aSD6exEyh1v/ZSdAomB82t6G9hzJVRx0jBmLDW+VfZqks3aScmMw9DszwUalA==" - "resolved" "https://registry.npmjs.org/psl/-/psl-1.2.0.tgz" - "version" "1.2.0" - -"pump@^3.0.0": - "integrity" "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==" - "resolved" "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "end-of-stream" "^1.1.0" - "once" "^1.3.1" - -"punycode@^1.3.2", "punycode@^1.4.1": - "integrity" "sha1-wNWmOycYgArY4esPpSachN1BhF4=" - "resolved" "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz" - "version" "1.4.1" - -"punycode@^2.0.0": - "integrity" "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==" - "resolved" "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz" - "version" "2.1.1" - -"punycode@^2.1.0": - "integrity" "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==" - "resolved" "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz" - "version" "2.1.1" - -"qs@~6.5.2": - "integrity" "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==" - "resolved" "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz" - "version" "6.5.2" - -"react-is@^16.8.1": - "integrity" "sha512-aUk3bHfZ2bRSVFFbbeVS4i+lNPZr3/WM5jT2J5omUVV1zzcs1nAaf3l51ctA5FFvCRbhrH0bdAsRRQddFJZPtA==" - "resolved" "https://registry.npmjs.org/react-is/-/react-is-16.8.6.tgz" - "version" "16.8.6" - -"react-reconciler@^0.20.0": - "integrity" "sha512-kxERc4H32zV2lXMg/iMiwQHOtyqf15qojvkcZ5Ja2CPkjVohHw9k70pdDBwrnQhLVetUJBSYyqU3yqrlVTOajA==" - "resolved" "https://registry.npmjs.org/react-reconciler/-/react-reconciler-0.20.4.tgz" - "version" "0.20.4" - dependencies: - "loose-envify" "^1.1.0" - "object-assign" "^4.1.1" - "prop-types" "^15.6.2" - "scheduler" "^0.13.6" - -"react@^16.0.0", "react@^16.9.0", "react@>=16.8.0": - "integrity" "sha512-fglqy3k5E+81pA8s+7K0/T3DBCF0ZDOher1elBFzF7O6arXJgzyu/FW+COxFvAWXJoJN9KIZbT2LXlukwphYTA==" - "resolved" "https://registry.npmjs.org/react/-/react-16.12.0.tgz" - "version" "16.12.0" - dependencies: - "loose-envify" "^1.1.0" - "object-assign" "^4.1.1" - "prop-types" "^15.6.2" - -"react@^16.8.6": - "integrity" "sha512-pC0uMkhLaHm11ZSJULfOBqV4tIZkx87ZLvbbQYunNixAAvjnC+snJCg0XQXn9VIsttVsbZP/H/ewzgsd5fxKXw==" - "resolved" "https://registry.npmjs.org/react/-/react-16.8.6.tgz" - "version" "16.8.6" - dependencies: - "loose-envify" "^1.1.0" - "object-assign" "^4.1.1" - "prop-types" "^15.6.2" - "scheduler" "^0.13.6" - -"read-pkg-up@^4.0.0": - "integrity" "sha512-6etQSH7nJGsK0RbG/2TeDzZFa8shjQ1um+SwQQ5cwKy0dhSXdOncEhb1CPpvQG4h7FyOV6EB6YlV0yJvZQNAkA==" - "resolved" "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-4.0.0.tgz" - "version" "4.0.0" - dependencies: - "find-up" "^3.0.0" - "read-pkg" "^3.0.0" - -"read-pkg@^3.0.0": - "integrity" "sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k=" - "resolved" "https://registry.npmjs.org/read-pkg/-/read-pkg-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "load-json-file" "^4.0.0" - "normalize-package-data" "^2.3.2" - "path-type" "^3.0.0" - -"readable-stream@^2.1.5": - "integrity" "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==" - "resolved" "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz" - "version" "2.3.6" - dependencies: - "core-util-is" "~1.0.0" - "inherits" "~2.0.3" - "isarray" "~1.0.0" - "process-nextick-args" "~2.0.0" - "safe-buffer" "~5.1.1" - "string_decoder" "~1.1.1" - "util-deprecate" "~1.0.1" - -"readdirp@~3.2.0": - "integrity" "sha512-crk4Qu3pmXwgxdSgGhgA/eXiJAPQiX4GMOZZMXnqKxHX7TaoL+3gQVo/WeuAiogr07DpnfjIMpXXa+PAIvwPGQ==" - "resolved" "https://registry.npmjs.org/readdirp/-/readdirp-3.2.0.tgz" - "version" "3.2.0" - dependencies: - "picomatch" "^2.0.4" - -"redeyed@~2.1.0": - "integrity" "sha1-iYS1gV2ZyyIEacme7v/jiRPmzAs=" - "resolved" "https://registry.npmjs.org/redeyed/-/redeyed-2.1.1.tgz" - "version" "2.1.1" - dependencies: - "esprima" "~4.0.0" - -"regenerator-runtime@^0.11.0": - "integrity" "sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg==" - "resolved" "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz" - "version" "0.11.1" - -"regenerator-runtime@^0.13.2": - "integrity" "sha512-S/TQAZJO+D3m9xeN1WTI8dLKBBiRgXBlTJvbWjCThHWZj9EvHK70Ff50/tYj2J/fvBY6JtFVwRuazHN2E7M9BA==" - "resolved" "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.2.tgz" - "version" "0.13.2" - -"release-zalgo@^1.0.0": - "integrity" "sha1-CXALflB0Mpc5Mw5TXFqQ+2eFFzA=" - "resolved" "https://registry.npmjs.org/release-zalgo/-/release-zalgo-1.0.0.tgz" - "version" "1.0.0" - dependencies: - "es6-error" "^4.0.1" - -"repeating@^2.0.0": - "integrity" "sha1-UhTFOpJtNVJwdSf7q0FdvAjQbdo=" - "resolved" "https://registry.npmjs.org/repeating/-/repeating-2.0.1.tgz" - "version" "2.0.1" - dependencies: - "is-finite" "^1.0.0" - -"request@^2.86.0": - "integrity" "sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg==" - "resolved" "https://registry.npmjs.org/request/-/request-2.88.0.tgz" - "version" "2.88.0" - dependencies: - "aws-sign2" "~0.7.0" - "aws4" "^1.8.0" - "caseless" "~0.12.0" - "combined-stream" "~1.0.6" - "extend" "~3.0.2" - "forever-agent" "~0.6.1" - "form-data" "~2.3.2" - "har-validator" "~5.1.0" - "http-signature" "~1.2.0" - "is-typedarray" "~1.0.0" - "isstream" "~0.1.2" - "json-stringify-safe" "~5.0.1" - "mime-types" "~2.1.19" - "oauth-sign" "~0.9.0" - "performance-now" "^2.1.0" - "qs" "~6.5.2" - "safe-buffer" "^5.1.2" - "tough-cookie" "~2.4.3" - "tunnel-agent" "^0.6.0" - "uuid" "^3.3.2" - -"require-directory@^2.1.1": - "integrity" "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=" - "resolved" "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz" - "version" "2.1.1" - -"require-main-filename@^2.0.0": - "integrity" "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==" - "resolved" "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz" - "version" "2.0.0" - -"resolve-from@^3.0.0": - "integrity" "sha1-six699nWiBvItuZTM17rywoYh0g=" - "resolved" "https://registry.npmjs.org/resolve-from/-/resolve-from-3.0.0.tgz" - "version" "3.0.0" - -"resolve-from@^4.0.0": - "integrity" "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==" - "resolved" "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz" - "version" "4.0.0" - -"resolve@^1.10.0": - "integrity" "sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw==" - "resolved" "https://registry.npmjs.org/resolve/-/resolve-1.11.1.tgz" - "version" "1.11.1" - dependencies: - "path-parse" "^1.0.6" - -"restore-cursor@^2.0.0": - "integrity" "sha1-n37ih/gv0ybU/RYpI9YhKe7g368=" - "resolved" "https://registry.npmjs.org/restore-cursor/-/restore-cursor-2.0.0.tgz" - "version" "2.0.0" - dependencies: - "onetime" "^2.0.0" - "signal-exit" "^3.0.2" - -"rimraf@^2.6.2": - "integrity" "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==" - "resolved" "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz" - "version" "2.6.3" - dependencies: - "glob" "^7.1.3" - -"rimraf@^2.6.3": - "integrity" "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==" - "resolved" "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz" - "version" "2.6.3" - dependencies: - "glob" "^7.1.3" - -"rimraf@^2.7.1": - "integrity" "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==" - "resolved" "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz" - "version" "2.7.1" - dependencies: - "glob" "^7.1.3" - -"safe-buffer@^5.0.1": - "integrity" "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==" - "resolved" "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz" - "version" "5.2.0" - -"safe-buffer@^5.1.2": - "integrity" "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==" - "resolved" "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz" - "version" "5.2.0" - -"safe-buffer@~5.1.0", "safe-buffer@~5.1.1": - "integrity" "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" - "resolved" "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz" - "version" "5.1.2" - -"safer-buffer@^2.0.2", "safer-buffer@^2.1.0", "safer-buffer@~2.1.0": - "integrity" "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" - "resolved" "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz" - "version" "2.1.2" - -"scheduler@^0.13.2", "scheduler@^0.13.6": - "integrity" "sha512-IWnObHt413ucAYKsD9J1QShUKkbKLQQHdxRyw73sw4FN26iWr3DY/H34xGPe4nmL1DwXyWmSWmMrA9TfQbE/XQ==" - "resolved" "https://registry.npmjs.org/scheduler/-/scheduler-0.13.6.tgz" - "version" "0.13.6" - dependencies: - "loose-envify" "^1.1.0" - "object-assign" "^4.1.1" - -"semver@^5.5.0", "semver@^5.6.0", "semver@2 || 3 || 4 || 5": - "integrity" "sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA==" - "resolved" "https://registry.npmjs.org/semver/-/semver-5.7.0.tgz" - "version" "5.7.0" - -"semver@^6.0.0": - "integrity" "sha512-jdFC1VdUGT/2Scgbimf7FSx9iJLXoqfglSF+gJeuNWVpiE37OIbc1jywR/GJyFdz3mnkz2/id0L0J/cr0izR5A==" - "resolved" "https://registry.npmjs.org/semver/-/semver-6.2.0.tgz" - "version" "6.2.0" - -"set-blocking@^2.0.0": - "integrity" "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=" - "resolved" "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz" - "version" "2.0.0" - -"shebang-command@^1.2.0": - "integrity" "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=" - "resolved" "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz" - "version" "1.2.0" - dependencies: - "shebang-regex" "^1.0.0" - -"shebang-regex@^1.0.0": - "integrity" "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=" - "resolved" "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz" - "version" "1.0.0" - -"signal-exit@^3.0.0", "signal-exit@^3.0.2": - "integrity" "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=" - "resolved" "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz" - "version" "3.0.2" - -"slash@^1.0.0": - "integrity" "sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU=" - "resolved" "https://registry.npmjs.org/slash/-/slash-1.0.0.tgz" - "version" "1.0.0" - -"slice-ansi@^1.0.0": - "integrity" "sha512-POqxBK6Lb3q6s047D/XsDVNPnF9Dl8JSaqe9h9lURl0OdNqy/ujDrOiIHtsqXMGbWWTIomRzAMaTyawAU//Reg==" - "resolved" "https://registry.npmjs.org/slice-ansi/-/slice-ansi-1.0.0.tgz" - "version" "1.0.0" - dependencies: - "is-fullwidth-code-point" "^2.0.0" - -"source-map-support@^0.4.15": - "integrity" "sha512-try0/JqxPLF9nOjvSta7tVondkP5dwgyLDjVoyMDlmjugT2lRZ1OfsrYTkCd2hkDnJTKRbO/Rl3orm8vlsUzbA==" - "resolved" "https://registry.npmjs.org/source-map-support/-/source-map-support-0.4.18.tgz" - "version" "0.4.18" - dependencies: - "source-map" "^0.5.6" - -"source-map-support@^0.5.11": - "integrity" "sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ==" - "resolved" "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.12.tgz" - "version" "0.5.12" - dependencies: - "buffer-from" "^1.0.0" - "source-map" "^0.6.0" - -"source-map-support@^0.5.16": - "integrity" "sha512-efyLRJDr68D9hBBNIPWFjhpFzURh+KJykQwvMyW5UiZzYwoF6l4YMMDIJJEyFWxWCqfyxLzz6tSfUFR+kXXsVQ==" - "resolved" "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.16.tgz" - "version" "0.5.16" - dependencies: - "buffer-from" "^1.0.0" - "source-map" "^0.6.0" - -"source-map-support@^0.5.6": - "integrity" "sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ==" - "resolved" "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.12.tgz" - "version" "0.5.12" - dependencies: - "buffer-from" "^1.0.0" - "source-map" "^0.6.0" - -"source-map@^0.5.0": - "integrity" "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=" - "resolved" "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz" - "version" "0.5.7" - -"source-map@^0.5.6": - "integrity" "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=" - "resolved" "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz" - "version" "0.5.7" - -"source-map@^0.5.7": - "integrity" "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=" - "resolved" "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz" - "version" "0.5.7" - -"source-map@^0.6.0", "source-map@^0.6.1", "source-map@~0.6.1": - "integrity" "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==" - "resolved" "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz" - "version" "0.6.1" - -"spawn-wrap@^1.4.2": - "integrity" "sha512-vMwR3OmmDhnxCVxM8M+xO/FtIp6Ju/mNaDfCMMW7FDcLRTPFWUswec4LXJHTJE2hwTI9O0YBfygu4DalFl7Ylg==" - "resolved" "https://registry.npmjs.org/spawn-wrap/-/spawn-wrap-1.4.2.tgz" - "version" "1.4.2" - dependencies: - "foreground-child" "^1.5.6" - "mkdirp" "^0.5.0" - "os-homedir" "^1.0.1" - "rimraf" "^2.6.2" - "signal-exit" "^3.0.2" - "which" "^1.3.0" - -"spdx-correct@^3.0.0": - "integrity" "sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q==" - "resolved" "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.0.tgz" - "version" "3.1.0" - dependencies: - "spdx-expression-parse" "^3.0.0" - "spdx-license-ids" "^3.0.0" - -"spdx-exceptions@^2.1.0": - "integrity" "sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA==" - "resolved" "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz" - "version" "2.2.0" - -"spdx-expression-parse@^3.0.0": - "integrity" "sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg==" - "resolved" "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "spdx-exceptions" "^2.1.0" - "spdx-license-ids" "^3.0.0" - -"spdx-license-ids@^3.0.0": - "integrity" "sha512-7j8LYJLeY/Yb6ACbQ7F76qy5jHkp0U6jgBfJsk97bwWlVUnUWsAgpyaCvo17h0/RQGnQ036tVDomiwoI4pDkQA==" - "resolved" "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.4.tgz" - "version" "3.0.4" - -"sprintf-js@~1.0.2": - "integrity" "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=" - "resolved" "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz" - "version" "1.0.3" - -"sshpk@^1.7.0": - "integrity" "sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==" - "resolved" "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz" - "version" "1.16.1" - dependencies: - "asn1" "~0.2.3" - "assert-plus" "^1.0.0" - "bcrypt-pbkdf" "^1.0.0" - "dashdash" "^1.12.0" - "ecc-jsbn" "~0.1.1" - "getpass" "^0.1.1" - "jsbn" "~0.1.0" - "safer-buffer" "^2.0.2" - "tweetnacl" "~0.14.0" - -"stack-utils@^1.0.2": - "integrity" "sha512-MTX+MeG5U994cazkjd/9KNAapsHnibjMLnfXodlkXw76JEea0UiNzrqidzo1emMwk7w5Qhc9jd4Bn9TBb1MFwA==" - "resolved" "https://registry.npmjs.org/stack-utils/-/stack-utils-1.0.2.tgz" - "version" "1.0.2" - -"string_decoder@~1.1.1": - "integrity" "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==" - "resolved" "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz" - "version" "1.1.1" - dependencies: - "safe-buffer" "~5.1.0" - -"string-length@^2.0.0": - "integrity" "sha1-1A27aGo6zpYMHP/KVivyxF+DY+0=" - "resolved" "https://registry.npmjs.org/string-length/-/string-length-2.0.0.tgz" - "version" "2.0.0" - dependencies: - "astral-regex" "^1.0.0" - "strip-ansi" "^4.0.0" - -"string-width@^1.0.1": - "integrity" "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=" - "resolved" "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz" - "version" "1.0.2" - dependencies: - "code-point-at" "^1.0.0" - "is-fullwidth-code-point" "^1.0.0" - "strip-ansi" "^3.0.0" - -"string-width@^2.0.0", "string-width@^2.1.1": - "integrity" "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==" - "resolved" "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz" - "version" "2.1.1" - dependencies: - "is-fullwidth-code-point" "^2.0.0" - "strip-ansi" "^4.0.0" - -"string-width@^3.0.0", "string-width@^3.1.0": - "integrity" "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==" - "resolved" "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz" - "version" "3.1.0" - dependencies: - "emoji-regex" "^7.0.1" - "is-fullwidth-code-point" "^2.0.0" - "strip-ansi" "^5.1.0" - -"strip-ansi@^3.0.0", "strip-ansi@^3.0.1": - "integrity" "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=" - "resolved" "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz" - "version" "3.0.1" - dependencies: - "ansi-regex" "^2.0.0" - -"strip-ansi@^4.0.0": - "integrity" "sha1-qEeQIusaw2iocTibY1JixQXuNo8=" - "resolved" "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz" - "version" "4.0.0" - dependencies: - "ansi-regex" "^3.0.0" - -"strip-ansi@^5.0.0", "strip-ansi@^5.1.0", "strip-ansi@^5.2.0": - "integrity" "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==" - "resolved" "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz" - "version" "5.2.0" - dependencies: - "ansi-regex" "^4.1.0" - -"strip-bom@^3.0.0": - "integrity" "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=" - "resolved" "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz" - "version" "3.0.0" - -"strip-eof@^1.0.0": - "integrity" "sha1-u0P/VZim6wXYm1n80SnJgzE2Br8=" - "resolved" "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz" - "version" "1.0.0" - -"supports-color@^2.0.0": - "integrity" "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=" - "resolved" "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz" - "version" "2.0.0" - -"supports-color@^5.3.0": - "integrity" "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==" - "resolved" "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz" - "version" "5.5.0" - dependencies: - "has-flag" "^3.0.0" - -"supports-color@^6.1.0": - "integrity" "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==" - "resolved" "https://registry.npmjs.org/supports-color/-/supports-color-6.1.0.tgz" - "version" "6.1.0" - dependencies: - "has-flag" "^3.0.0" - -"tap-mocha-reporter@^5.0.0": - "integrity" "sha512-8HlAtdmYGlDZuW83QbF/dc46L7cN+AGhLZcanX3I9ILvxUAl+G2/mtucNPSXecTlG/4iP1hv6oMo0tMhkn3Tsw==" - "resolved" "https://registry.npmjs.org/tap-mocha-reporter/-/tap-mocha-reporter-5.0.0.tgz" - "version" "5.0.0" - dependencies: - "color-support" "^1.1.0" - "debug" "^2.1.3" - "diff" "^1.3.2" - "escape-string-regexp" "^1.0.3" - "glob" "^7.0.5" - "tap-parser" "^10.0.0" - "tap-yaml" "^1.0.0" - "unicode-length" "^1.0.0" + istanbul-lib-coverage "^2.0.5" + semver "^6.0.0" + +istanbul-lib-processinfo@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/istanbul-lib-processinfo/-/istanbul-lib-processinfo-1.0.0.tgz" + integrity sha512-FY0cPmWa4WoQNlvB8VOcafiRoB5nB+l2Pz2xGuXHRSy1KM8QFOYfz/rN+bGMCAeejrY3mrpF5oJHcN0s/garCg== + dependencies: + archy "^1.0.0" + cross-spawn "^6.0.5" + istanbul-lib-coverage "^2.0.3" + rimraf "^2.6.3" + uuid "^3.3.2" + +istanbul-lib-report@^2.0.8: + version "2.0.8" + resolved "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-2.0.8.tgz" + integrity sha512-fHBeG573EIihhAblwgxrSenp0Dby6tJMFR/HvlerBsrCTD5bkUuoNtn3gVh29ZCS824cGGBPn7Sg7cNk+2xUsQ== + dependencies: + istanbul-lib-coverage "^2.0.5" + make-dir "^2.1.0" + supports-color "^6.1.0" + +istanbul-lib-source-maps@^3.0.6: + version "3.0.6" + resolved "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-3.0.6.tgz" + integrity sha512-R47KzMtDJH6X4/YW9XTx+jrLnZnscW4VpNN+1PViSYTejLVPWv7oov+Duf8YQSPyVRUvueQqz1TcsC6mooZTXw== + dependencies: + debug "^4.1.1" + istanbul-lib-coverage "^2.0.5" + make-dir "^2.1.0" + rimraf "^2.6.3" + source-map "^0.6.1" + +istanbul-reports@^2.2.4: + version "2.2.6" + resolved "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-2.2.6.tgz" + integrity sha512-SKi4rnMyLBKe0Jy2uUdx28h8oG7ph2PPuQPvIAh31d+Ci+lSiEu4C+h3oBPuJ9+mPKhOyW0M8gY4U5NM1WLeXA== + dependencies: + handlebars "^4.1.2" + +jackspeak@^1.4.0: + version "1.4.0" + resolved "https://registry.npmjs.org/jackspeak/-/jackspeak-1.4.0.tgz" + integrity sha512-VDcSunT+wcccoG46FtzuBAyQKlzhHjli4q31e1fIHGOsRspqNUFjVzGb+7eIFDlTvqLygxapDHPHS0ouT2o/tw== + dependencies: + cliui "^4.1.0" + +"js-tokens@^3.0.0 || ^4.0.0", js-tokens@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz" + integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== + +js-tokens@^3.0.2: + version "3.0.2" + resolved "https://registry.npmjs.org/js-tokens/-/js-tokens-3.0.2.tgz" + integrity sha1-mGbfOVECEw449/mWvOtlRDIJwls= + +js-yaml@^3.13.1: + version "3.13.1" + resolved "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz" + integrity sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw== + dependencies: + argparse "^1.0.7" + esprima "^4.0.0" + +jsbn@~0.1.0: + version "0.1.1" + resolved "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz" + integrity sha1-peZUwuWi3rXyAdls77yoDA7y9RM= + +jsesc@^1.3.0: + version "1.3.0" + resolved "https://registry.npmjs.org/jsesc/-/jsesc-1.3.0.tgz" + integrity sha1-RsP+yMGJKxKwgz25vHYiF226s0s= + +jsesc@^2.5.1: + version "2.5.2" + resolved "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz" + integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== + +json-parse-better-errors@^1.0.1: + version "1.0.2" + resolved "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz" + integrity sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw== + +json-schema-traverse@^0.4.1: + version "0.4.1" + resolved "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz" + integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg== + +json-schema@0.2.3: + version "0.2.3" + resolved "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz" + integrity sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM= + +json-stringify-safe@~5.0.1: + version "5.0.1" + resolved "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz" + integrity sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus= + +json5@^0.5.1: + version "0.5.1" + resolved "https://registry.npmjs.org/json5/-/json5-0.5.1.tgz" + integrity sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE= + +jsprim@^1.2.2: + version "1.4.1" + resolved "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz" + integrity sha1-MT5mvB5cwG5Di8G3SZwuXFastqI= + dependencies: + assert-plus "1.0.0" + extsprintf "1.3.0" + json-schema "0.2.3" + verror "1.10.0" + +lcid@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz" + integrity sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA== + dependencies: + invert-kv "^2.0.0" + +lcov-parse@^0.0.10: + version "0.0.10" + resolved "https://registry.npmjs.org/lcov-parse/-/lcov-parse-0.0.10.tgz" + integrity sha1-GwuP+ayceIklBYK3C3ExXZ2m2aM= + +load-json-file@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/load-json-file/-/load-json-file-4.0.0.tgz" + integrity sha1-L19Fq5HjMhYjT9U62rZo607AmTs= + dependencies: + graceful-fs "^4.1.2" + parse-json "^4.0.0" + pify "^3.0.0" + strip-bom "^3.0.0" + +locate-path@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz" + integrity sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A== + dependencies: + p-locate "^3.0.0" + path-exists "^3.0.0" + +lodash.flattendeep@^4.4.0: + version "4.4.0" + resolved "https://registry.npmjs.org/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz" + integrity sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI= + +lodash.throttle@^4.1.1: + version "4.1.1" + resolved "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz" + integrity sha1-wj6RtxAkKscMN/HhzaknTMOb8vQ= + +lodash@^4.17.11, lodash@^4.17.4: + version "4.17.11" + resolved "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz" + integrity sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg== + +log-driver@^1.2.7: + version "1.2.7" + resolved "https://registry.npmjs.org/log-driver/-/log-driver-1.2.7.tgz" + integrity sha512-U7KCmLdqsGHBLeWqYlFA0V0Sl6P08EE1ZrmA9cxjUE0WVqT9qnyVDPz1kzpFEP0jdJuFnasWIfSd7fsaNXkpbg== + +log-update@^3.0.0: + version "3.2.0" + resolved "https://registry.npmjs.org/log-update/-/log-update-3.2.0.tgz" + integrity sha512-KJ6zAPIHWo7Xg1jYror6IUDFJBq1bQ4Bi4wAEp2y/0ScjBBVi/g0thr0sUVhuvuXauWzczt7T2QHghPDNnKBuw== + dependencies: + ansi-escapes "^3.2.0" + cli-cursor "^2.1.0" + wrap-ansi "^5.0.0" + +loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.4.0: + version "1.4.0" + resolved "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz" + integrity sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q== + dependencies: + js-tokens "^3.0.0 || ^4.0.0" + +lru-cache@^4.0.1: + version "4.1.5" + resolved "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.5.tgz" + integrity sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g== + dependencies: + pseudomap "^1.0.2" + yallist "^2.1.2" + +make-dir@^2.0.0, make-dir@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/make-dir/-/make-dir-2.1.0.tgz" + integrity sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA== + dependencies: + pify "^4.0.1" + semver "^5.6.0" + +make-error@^1.1.1: + version "1.3.5" + resolved "https://registry.npmjs.org/make-error/-/make-error-1.3.5.tgz" + integrity sha512-c3sIjNUow0+8swNwVpqoH4YCShKNFkMaw6oH1mNS2haDZQqkeZFlHS3dhoeEbKKmJB4vXpJucU6oH75aDYeE9g== + +map-age-cleaner@^0.1.1: + version "0.1.3" + resolved "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz" + integrity sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w== + dependencies: + p-defer "^1.0.0" + +mem@^4.0.0: + version "4.3.0" + resolved "https://registry.npmjs.org/mem/-/mem-4.3.0.tgz" + integrity sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w== + dependencies: + map-age-cleaner "^0.1.1" + mimic-fn "^2.0.0" + p-is-promise "^2.0.0" + +merge-source-map@^1.1.0: + version "1.1.0" + resolved "https://registry.npmjs.org/merge-source-map/-/merge-source-map-1.1.0.tgz" + integrity sha512-Qkcp7P2ygktpMPh2mCQZaf3jhN6D3Z/qVZHSdWvQ+2Ef5HgRAPBO57A77+ENm0CPx2+1Ce/MYKi3ymqdfuqibw== + dependencies: + source-map "^0.6.1" + +mime-db@1.40.0: + version "1.40.0" + resolved "https://registry.npmjs.org/mime-db/-/mime-db-1.40.0.tgz" + integrity sha512-jYdeOMPy9vnxEqFRRo6ZvTZ8d9oPb+k18PKoYNYUe2stVEBPPwsln/qWzdbmaIvnhZ9v2P+CuecK+fpUfsV2mA== + +mime-types@^2.1.12, mime-types@~2.1.19: + version "2.1.24" + resolved "https://registry.npmjs.org/mime-types/-/mime-types-2.1.24.tgz" + integrity sha512-WaFHS3MCl5fapm3oLxU4eYDw77IQM2ACcxQ9RIxfaC3ooc6PFuBMGZZsYpvoXS5D5QTWPieo1jjLdAm3TBP3cQ== + dependencies: + mime-db "1.40.0" + +mimic-fn@^1.0.0: + version "1.2.0" + resolved "https://registry.npmjs.org/mimic-fn/-/mimic-fn-1.2.0.tgz" + integrity sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ== + +mimic-fn@^2.0.0: + version "2.1.0" + resolved "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz" + integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== + +minimatch@^3.0.4: + version "3.0.4" + resolved "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz" + integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== + dependencies: + brace-expansion "^1.1.7" + +minimist@^1.2.0: + version "1.2.0" + resolved "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz" + integrity sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ= + +minimist@~0.0.1: + version "0.0.10" + resolved "https://registry.npmjs.org/minimist/-/minimist-0.0.10.tgz" + integrity sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8= + +minimist@0.0.8: + version "0.0.8" + resolved "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz" + integrity sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0= + +minipass@^3.0.0: + version "3.1.1" + resolved "https://registry.npmjs.org/minipass/-/minipass-3.1.1.tgz" + integrity sha512-UFqVihv6PQgwj8/yTGvl9kPz7xIAY+R5z6XYjRInD3Gk3qx6QGSD6zEcpeG4Dy/lQnv1J6zv8ejV90hyYIKf3w== + dependencies: + yallist "^4.0.0" + +mkdirp@^0.5.0, mkdirp@^0.5.1: + version "0.5.1" + resolved "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz" + integrity sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM= + dependencies: + minimist "0.0.8" + +ms@^2.1.1: + version "2.1.2" + resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" + integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== + +ms@2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz" + integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= + +neo-async@^2.6.0: + version "2.6.1" + resolved "https://registry.npmjs.org/neo-async/-/neo-async-2.6.1.tgz" + integrity sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw== + +nested-error-stacks@^2.0.0: + version "2.1.0" + resolved "https://registry.npmjs.org/nested-error-stacks/-/nested-error-stacks-2.1.0.tgz" + integrity sha512-AO81vsIO1k1sM4Zrd6Hu7regmJN1NSiAja10gc4bX3F0wd+9rQmcuHQaHVQCYIEC8iFXnE+mavh23GOt7wBgug== + +nice-try@^1.0.4: + version "1.0.5" + resolved "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz" + integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== + +node-modules-regexp@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz" + integrity sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA= + +normalize-package-data@^2.3.2: + version "2.5.0" + resolved "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz" + integrity sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA== + dependencies: + hosted-git-info "^2.1.4" + resolve "^1.10.0" + semver "2 || 3 || 4 || 5" + validate-npm-package-license "^3.0.1" + +normalize-path@^3.0.0, normalize-path@~3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz" + integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== + +npm-run-path@^2.0.0: + version "2.0.2" + resolved "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz" + integrity sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8= + dependencies: + path-key "^2.0.0" + +number-is-nan@^1.0.0: + version "1.0.1" + resolved "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz" + integrity sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0= + +nyc@^14.1.1: + version "14.1.1" + resolved "https://registry.npmjs.org/nyc/-/nyc-14.1.1.tgz" + integrity sha512-OI0vm6ZGUnoGZv/tLdZ2esSVzDwUC88SNs+6JoSOMVxA+gKMB8Tk7jBwgemLx4O40lhhvZCVw1C+OYLOBOPXWw== + dependencies: + archy "^1.0.0" + caching-transform "^3.0.2" + convert-source-map "^1.6.0" + cp-file "^6.2.0" + find-cache-dir "^2.1.0" + find-up "^3.0.0" + foreground-child "^1.5.6" + glob "^7.1.3" + istanbul-lib-coverage "^2.0.5" + istanbul-lib-hook "^2.0.7" + istanbul-lib-instrument "^3.3.0" + istanbul-lib-report "^2.0.8" + istanbul-lib-source-maps "^3.0.6" + istanbul-reports "^2.2.4" + js-yaml "^3.13.1" + make-dir "^2.1.0" + merge-source-map "^1.1.0" + resolve-from "^4.0.0" + rimraf "^2.6.3" + signal-exit "^3.0.2" + spawn-wrap "^1.4.2" + test-exclude "^5.2.3" + uuid "^3.3.2" + yargs "^13.2.2" + yargs-parser "^13.0.0" + +oauth-sign@~0.9.0: + version "0.9.0" + resolved "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz" + integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== + +object-assign@^4.1.1: + version "4.1.1" + resolved "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz" + integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= + +once@^1.3.0, once@^1.3.1, once@^1.4.0: + version "1.4.0" + resolved "https://registry.npmjs.org/once/-/once-1.4.0.tgz" + integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= + dependencies: + wrappy "1" + +onetime@^2.0.0: + version "2.0.1" + resolved "https://registry.npmjs.org/onetime/-/onetime-2.0.1.tgz" + integrity sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ= + dependencies: + mimic-fn "^1.0.0" + +opener@^1.5.1: + version "1.5.1" + resolved "https://registry.npmjs.org/opener/-/opener-1.5.1.tgz" + integrity sha512-goYSy5c2UXE4Ra1xixabeVh1guIX/ZV/YokJksb6q2lubWu6UbvPQ20p542/sFIll1nl8JnCyK9oBaOcCWXwvA== + +optimist@^0.6.1: + version "0.6.1" + resolved "https://registry.npmjs.org/optimist/-/optimist-0.6.1.tgz" + integrity sha1-2j6nRob6IaGaERwybpDrFaAZZoY= + dependencies: + minimist "~0.0.1" + wordwrap "~0.0.2" + +os-homedir@^1.0.0, os-homedir@^1.0.1: + version "1.0.2" + resolved "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz" + integrity sha1-/7xJiDNuDoM94MFox+8VISGqf7M= + +os-locale@^3.1.0: + version "3.1.0" + resolved "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz" + integrity sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q== + dependencies: + execa "^1.0.0" + lcid "^2.0.0" + mem "^4.0.0" + +os-tmpdir@^1.0.1: + version "1.0.2" + resolved "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz" + integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= + +own-or-env@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/own-or-env/-/own-or-env-1.0.1.tgz" + integrity sha512-y8qULRbRAlL6x2+M0vIe7jJbJx/kmUTzYonRAa2ayesR2qWLswninkVyeJe4x3IEXhdgoNodzjQRKAoEs6Fmrw== + dependencies: + own-or "^1.0.0" + +own-or@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/own-or/-/own-or-1.0.0.tgz" + integrity sha1-Tod/vtqaLsgAD7wLyuOWRe6L+Nw= + +p-defer@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz" + integrity sha1-n26xgvbJqozXQwBKfU+WsZaw+ww= + +p-finally@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz" + integrity sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4= + +p-is-promise@^2.0.0: + version "2.1.0" + resolved "https://registry.npmjs.org/p-is-promise/-/p-is-promise-2.1.0.tgz" + integrity sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg== + +p-limit@^2.0.0: + version "2.2.0" + resolved "https://registry.npmjs.org/p-limit/-/p-limit-2.2.0.tgz" + integrity sha512-pZbTJpoUsCzV48Mc9Nh51VbwO0X9cuPFE8gYwx9BTCt9SF8/b7Zljd2fVgOxhIF/HDTKgpVzs+GPhyKfjLLFRQ== + dependencies: + p-try "^2.0.0" + +p-locate@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz" + integrity sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ== + dependencies: + p-limit "^2.0.0" + +p-try@^2.0.0: + version "2.2.0" + resolved "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz" + integrity sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ== + +package-hash@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/package-hash/-/package-hash-3.0.0.tgz" + integrity sha512-lOtmukMDVvtkL84rJHI7dpTYq+0rli8N2wlnqUcBuDWCfVhRUfOmnR9SsoHFMLpACvEV60dX7rd0rFaYDZI+FA== + dependencies: + graceful-fs "^4.1.15" + hasha "^3.0.0" + lodash.flattendeep "^4.4.0" + release-zalgo "^1.0.0" + +parse-json@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz" + integrity sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA= + dependencies: + error-ex "^1.3.1" + json-parse-better-errors "^1.0.1" + +path-exists@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz" + integrity sha1-zg6+ql94yxiSXqfYENe1mwEP1RU= + +path-is-absolute@^1.0.0, path-is-absolute@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz" + integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= + +path-key@^2.0.0, path-key@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz" + integrity sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A= + +path-parse@^1.0.6: + version "1.0.6" + resolved "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz" + integrity sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw== + +path-type@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/path-type/-/path-type-3.0.0.tgz" + integrity sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg== + dependencies: + pify "^3.0.0" + +performance-now@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz" + integrity sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns= + +picomatch@^2.0.4: + version "2.0.7" + resolved "https://registry.npmjs.org/picomatch/-/picomatch-2.0.7.tgz" + integrity sha512-oLHIdio3tZ0qH76NybpeneBhYVj0QFTfXEFTc/B3zKQspYfYYkWYgFsmzo+4kvId/bQRcNkVeguI3y+CD22BtA== + +pify@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz" + integrity sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY= + +pify@^4.0.1: + version "4.0.1" + resolved "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz" + integrity sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g== + +pirates@^3.0.2: + version "3.0.2" + resolved "https://registry.npmjs.org/pirates/-/pirates-3.0.2.tgz" + integrity sha512-c5CgUJq6H2k6MJz72Ak1F5sN9n9wlSlJyEnwvpm9/y3WB4E3pHBDT2c6PEiS1vyJvq2bUxUAIu0EGf8Cx4Ic7Q== + dependencies: + node-modules-regexp "^1.0.0" + +pkg-dir@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/pkg-dir/-/pkg-dir-3.0.0.tgz" + integrity sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw== + dependencies: + find-up "^3.0.0" + +private@^0.1.8: + version "0.1.8" + resolved "https://registry.npmjs.org/private/-/private-0.1.8.tgz" + integrity sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg== + +process-nextick-args@~2.0.0: + version "2.0.1" + resolved "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz" + integrity sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag== + +prop-types@^15.6.2: + version "15.7.2" + resolved "https://registry.npmjs.org/prop-types/-/prop-types-15.7.2.tgz" + integrity sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ== + dependencies: + loose-envify "^1.4.0" + object-assign "^4.1.1" + react-is "^16.8.1" + +pseudomap@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz" + integrity sha1-8FKijacOYYkX7wqKw0wa5aaChrM= + +psl@^1.1.24: + version "1.2.0" + resolved "https://registry.npmjs.org/psl/-/psl-1.2.0.tgz" + integrity sha512-GEn74ZffufCmkDDLNcl3uuyF/aSD6exEyh1v/ZSdAomB82t6G9hzJVRx0jBmLDW+VfZqks3aScmMw9DszwUalA== + +pump@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz" + integrity sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww== + dependencies: + end-of-stream "^1.1.0" + once "^1.3.1" + +punycode@^1.3.2, punycode@^1.4.1: + version "1.4.1" + resolved "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz" + integrity sha1-wNWmOycYgArY4esPpSachN1BhF4= + +punycode@^2.0.0: + version "2.1.1" + resolved "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz" + integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== + +punycode@^2.1.0: + version "2.1.1" + resolved "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz" + integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== + +qs@~6.5.2: + version "6.5.2" + resolved "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz" + integrity sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA== + +react-is@^16.8.1: + version "16.8.6" + resolved "https://registry.npmjs.org/react-is/-/react-is-16.8.6.tgz" + integrity sha512-aUk3bHfZ2bRSVFFbbeVS4i+lNPZr3/WM5jT2J5omUVV1zzcs1nAaf3l51ctA5FFvCRbhrH0bdAsRRQddFJZPtA== + +react-reconciler@^0.20.0: + version "0.20.4" + resolved "https://registry.npmjs.org/react-reconciler/-/react-reconciler-0.20.4.tgz" + integrity sha512-kxERc4H32zV2lXMg/iMiwQHOtyqf15qojvkcZ5Ja2CPkjVohHw9k70pdDBwrnQhLVetUJBSYyqU3yqrlVTOajA== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + prop-types "^15.6.2" + scheduler "^0.13.6" + +react@^16.0.0, react@^16.9.0, react@>=16.8.0: + version "16.12.0" + resolved "https://registry.npmjs.org/react/-/react-16.12.0.tgz" + integrity sha512-fglqy3k5E+81pA8s+7K0/T3DBCF0ZDOher1elBFzF7O6arXJgzyu/FW+COxFvAWXJoJN9KIZbT2LXlukwphYTA== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + prop-types "^15.6.2" + +react@^16.8.6: + version "16.8.6" + resolved "https://registry.npmjs.org/react/-/react-16.8.6.tgz" + integrity sha512-pC0uMkhLaHm11ZSJULfOBqV4tIZkx87ZLvbbQYunNixAAvjnC+snJCg0XQXn9VIsttVsbZP/H/ewzgsd5fxKXw== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + prop-types "^15.6.2" + scheduler "^0.13.6" + +read-pkg-up@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-4.0.0.tgz" + integrity sha512-6etQSH7nJGsK0RbG/2TeDzZFa8shjQ1um+SwQQ5cwKy0dhSXdOncEhb1CPpvQG4h7FyOV6EB6YlV0yJvZQNAkA== + dependencies: + find-up "^3.0.0" + read-pkg "^3.0.0" + +read-pkg@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/read-pkg/-/read-pkg-3.0.0.tgz" + integrity sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k= + dependencies: + load-json-file "^4.0.0" + normalize-package-data "^2.3.2" + path-type "^3.0.0" + +readable-stream@^2.1.5: + version "2.3.6" + resolved "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz" + integrity sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw== + dependencies: + core-util-is "~1.0.0" + inherits "~2.0.3" + isarray "~1.0.0" + process-nextick-args "~2.0.0" + safe-buffer "~5.1.1" + string_decoder "~1.1.1" + util-deprecate "~1.0.1" + +readdirp@~3.2.0: + version "3.2.0" + resolved "https://registry.npmjs.org/readdirp/-/readdirp-3.2.0.tgz" + integrity sha512-crk4Qu3pmXwgxdSgGhgA/eXiJAPQiX4GMOZZMXnqKxHX7TaoL+3gQVo/WeuAiogr07DpnfjIMpXXa+PAIvwPGQ== + dependencies: + picomatch "^2.0.4" + +redeyed@~2.1.0: + version "2.1.1" + resolved "https://registry.npmjs.org/redeyed/-/redeyed-2.1.1.tgz" + integrity sha1-iYS1gV2ZyyIEacme7v/jiRPmzAs= + dependencies: + esprima "~4.0.0" + +regenerator-runtime@^0.11.0: + version "0.11.1" + resolved "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz" + integrity sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg== + +regenerator-runtime@^0.13.2: + version "0.13.2" + resolved "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.2.tgz" + integrity sha512-S/TQAZJO+D3m9xeN1WTI8dLKBBiRgXBlTJvbWjCThHWZj9EvHK70Ff50/tYj2J/fvBY6JtFVwRuazHN2E7M9BA== + +release-zalgo@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/release-zalgo/-/release-zalgo-1.0.0.tgz" + integrity sha1-CXALflB0Mpc5Mw5TXFqQ+2eFFzA= + dependencies: + es6-error "^4.0.1" + +repeating@^2.0.0: + version "2.0.1" + resolved "https://registry.npmjs.org/repeating/-/repeating-2.0.1.tgz" + integrity sha1-UhTFOpJtNVJwdSf7q0FdvAjQbdo= + dependencies: + is-finite "^1.0.0" + +request@^2.86.0: + version "2.88.0" + resolved "https://registry.npmjs.org/request/-/request-2.88.0.tgz" + integrity sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg== + dependencies: + aws-sign2 "~0.7.0" + aws4 "^1.8.0" + caseless "~0.12.0" + combined-stream "~1.0.6" + extend "~3.0.2" + forever-agent "~0.6.1" + form-data "~2.3.2" + har-validator "~5.1.0" + http-signature "~1.2.0" + is-typedarray "~1.0.0" + isstream "~0.1.2" + json-stringify-safe "~5.0.1" + mime-types "~2.1.19" + oauth-sign "~0.9.0" + performance-now "^2.1.0" + qs "~6.5.2" + safe-buffer "^5.1.2" + tough-cookie "~2.4.3" + tunnel-agent "^0.6.0" + uuid "^3.3.2" + +require-directory@^2.1.1: + version "2.1.1" + resolved "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz" + integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= + +require-main-filename@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz" + integrity sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg== + +resolve-from@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/resolve-from/-/resolve-from-3.0.0.tgz" + integrity sha1-six699nWiBvItuZTM17rywoYh0g= + +resolve-from@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz" + integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== + +resolve@^1.10.0: + version "1.11.1" + resolved "https://registry.npmjs.org/resolve/-/resolve-1.11.1.tgz" + integrity sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw== + dependencies: + path-parse "^1.0.6" + +restore-cursor@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/restore-cursor/-/restore-cursor-2.0.0.tgz" + integrity sha1-n37ih/gv0ybU/RYpI9YhKe7g368= + dependencies: + onetime "^2.0.0" + signal-exit "^3.0.2" + +rimraf@^2.6.2: + version "2.6.3" + resolved "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz" + integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA== + dependencies: + glob "^7.1.3" + +rimraf@^2.6.3: + version "2.6.3" + resolved "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz" + integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA== + dependencies: + glob "^7.1.3" + +rimraf@^2.7.1: + version "2.7.1" + resolved "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz" + integrity sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w== + dependencies: + glob "^7.1.3" + +safe-buffer@^5.0.1: + version "5.2.0" + resolved "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz" + integrity sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg== + +safe-buffer@^5.1.2: + version "5.2.0" + resolved "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz" + integrity sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg== + +safe-buffer@~5.1.0, safe-buffer@~5.1.1: + version "5.1.2" + resolved "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz" + integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== + +safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: + version "2.1.2" + resolved "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz" + integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== + +scheduler@^0.13.2, scheduler@^0.13.6: + version "0.13.6" + resolved "https://registry.npmjs.org/scheduler/-/scheduler-0.13.6.tgz" + integrity sha512-IWnObHt413ucAYKsD9J1QShUKkbKLQQHdxRyw73sw4FN26iWr3DY/H34xGPe4nmL1DwXyWmSWmMrA9TfQbE/XQ== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + +semver@^5.5.0, semver@^5.6.0, "semver@2 || 3 || 4 || 5": + version "5.7.0" + resolved "https://registry.npmjs.org/semver/-/semver-5.7.0.tgz" + integrity sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA== + +semver@^6.0.0: + version "6.2.0" + resolved "https://registry.npmjs.org/semver/-/semver-6.2.0.tgz" + integrity sha512-jdFC1VdUGT/2Scgbimf7FSx9iJLXoqfglSF+gJeuNWVpiE37OIbc1jywR/GJyFdz3mnkz2/id0L0J/cr0izR5A== + +set-blocking@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz" + integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc= + +shebang-command@^1.2.0: + version "1.2.0" + resolved "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz" + integrity sha1-RKrGW2lbAzmJaMOfNj/uXer98eo= + dependencies: + shebang-regex "^1.0.0" + +shebang-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz" + integrity sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM= + +signal-exit@^3.0.0, signal-exit@^3.0.2: + version "3.0.2" + resolved "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz" + integrity sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0= + +slash@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/slash/-/slash-1.0.0.tgz" + integrity sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU= + +slice-ansi@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/slice-ansi/-/slice-ansi-1.0.0.tgz" + integrity sha512-POqxBK6Lb3q6s047D/XsDVNPnF9Dl8JSaqe9h9lURl0OdNqy/ujDrOiIHtsqXMGbWWTIomRzAMaTyawAU//Reg== + dependencies: + is-fullwidth-code-point "^2.0.0" + +source-map-support@^0.4.15: + version "0.4.18" + resolved "https://registry.npmjs.org/source-map-support/-/source-map-support-0.4.18.tgz" + integrity sha512-try0/JqxPLF9nOjvSta7tVondkP5dwgyLDjVoyMDlmjugT2lRZ1OfsrYTkCd2hkDnJTKRbO/Rl3orm8vlsUzbA== + dependencies: + source-map "^0.5.6" + +source-map-support@^0.5.11: + version "0.5.12" + resolved "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.12.tgz" + integrity sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + +source-map-support@^0.5.16: + version "0.5.16" + resolved "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.16.tgz" + integrity sha512-efyLRJDr68D9hBBNIPWFjhpFzURh+KJykQwvMyW5UiZzYwoF6l4YMMDIJJEyFWxWCqfyxLzz6tSfUFR+kXXsVQ== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + +source-map-support@^0.5.6: + version "0.5.12" + resolved "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.12.tgz" + integrity sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + +source-map@^0.5.0: + version "0.5.7" + resolved "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz" + integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= + +source-map@^0.5.6: + version "0.5.7" + resolved "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz" + integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= + +source-map@^0.5.7: + version "0.5.7" + resolved "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz" + integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= + +source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1: + version "0.6.1" + resolved "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz" + integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== + +spawn-wrap@^1.4.2: + version "1.4.2" + resolved "https://registry.npmjs.org/spawn-wrap/-/spawn-wrap-1.4.2.tgz" + integrity sha512-vMwR3OmmDhnxCVxM8M+xO/FtIp6Ju/mNaDfCMMW7FDcLRTPFWUswec4LXJHTJE2hwTI9O0YBfygu4DalFl7Ylg== + dependencies: + foreground-child "^1.5.6" + mkdirp "^0.5.0" + os-homedir "^1.0.1" + rimraf "^2.6.2" + signal-exit "^3.0.2" + which "^1.3.0" + +spdx-correct@^3.0.0: + version "3.1.0" + resolved "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.0.tgz" + integrity sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q== + dependencies: + spdx-expression-parse "^3.0.0" + spdx-license-ids "^3.0.0" + +spdx-exceptions@^2.1.0: + version "2.2.0" + resolved "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz" + integrity sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA== + +spdx-expression-parse@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz" + integrity sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg== + dependencies: + spdx-exceptions "^2.1.0" + spdx-license-ids "^3.0.0" + +spdx-license-ids@^3.0.0: + version "3.0.4" + resolved "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.4.tgz" + integrity sha512-7j8LYJLeY/Yb6ACbQ7F76qy5jHkp0U6jgBfJsk97bwWlVUnUWsAgpyaCvo17h0/RQGnQ036tVDomiwoI4pDkQA== + +sprintf-js@~1.0.2: + version "1.0.3" + resolved "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz" + integrity sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw= + +sshpk@^1.7.0: + version "1.16.1" + resolved "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz" + integrity sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg== + dependencies: + asn1 "~0.2.3" + assert-plus "^1.0.0" + bcrypt-pbkdf "^1.0.0" + dashdash "^1.12.0" + ecc-jsbn "~0.1.1" + getpass "^0.1.1" + jsbn "~0.1.0" + safer-buffer "^2.0.2" + tweetnacl "~0.14.0" + +stack-utils@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/stack-utils/-/stack-utils-1.0.2.tgz" + integrity sha512-MTX+MeG5U994cazkjd/9KNAapsHnibjMLnfXodlkXw76JEea0UiNzrqidzo1emMwk7w5Qhc9jd4Bn9TBb1MFwA== + +string_decoder@~1.1.1: + version "1.1.1" + resolved "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz" + integrity sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg== + dependencies: + safe-buffer "~5.1.0" + +string-length@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/string-length/-/string-length-2.0.0.tgz" + integrity sha1-1A27aGo6zpYMHP/KVivyxF+DY+0= + dependencies: + astral-regex "^1.0.0" + strip-ansi "^4.0.0" + +string-width@^1.0.1: + version "1.0.2" + resolved "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz" + integrity sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M= + dependencies: + code-point-at "^1.0.0" + is-fullwidth-code-point "^1.0.0" + strip-ansi "^3.0.0" + +string-width@^2.0.0, string-width@^2.1.1: + version "2.1.1" + resolved "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz" + integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== + dependencies: + is-fullwidth-code-point "^2.0.0" + strip-ansi "^4.0.0" + +string-width@^3.0.0, string-width@^3.1.0: + version "3.1.0" + resolved "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz" + integrity sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w== + dependencies: + emoji-regex "^7.0.1" + is-fullwidth-code-point "^2.0.0" + strip-ansi "^5.1.0" + +strip-ansi@^3.0.0, strip-ansi@^3.0.1: + version "3.0.1" + resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz" + integrity sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8= + dependencies: + ansi-regex "^2.0.0" + +strip-ansi@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz" + integrity sha1-qEeQIusaw2iocTibY1JixQXuNo8= + dependencies: + ansi-regex "^3.0.0" + +strip-ansi@^5.0.0, strip-ansi@^5.1.0, strip-ansi@^5.2.0: + version "5.2.0" + resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz" + integrity sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA== + dependencies: + ansi-regex "^4.1.0" + +strip-bom@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz" + integrity sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM= + +strip-eof@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz" + integrity sha1-u0P/VZim6wXYm1n80SnJgzE2Br8= + +supports-color@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz" + integrity sha1-U10EXOa2Nj+kARcIRimZXp3zJMc= + +supports-color@^5.3.0: + version "5.5.0" + resolved "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz" + integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== + dependencies: + has-flag "^3.0.0" + +supports-color@^6.1.0: + version "6.1.0" + resolved "https://registry.npmjs.org/supports-color/-/supports-color-6.1.0.tgz" + integrity sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ== + dependencies: + has-flag "^3.0.0" + +tap-mocha-reporter@^5.0.0: + version "5.0.0" + resolved "https://registry.npmjs.org/tap-mocha-reporter/-/tap-mocha-reporter-5.0.0.tgz" + integrity sha512-8HlAtdmYGlDZuW83QbF/dc46L7cN+AGhLZcanX3I9ILvxUAl+G2/mtucNPSXecTlG/4iP1hv6oMo0tMhkn3Tsw== + dependencies: + color-support "^1.1.0" + debug "^2.1.3" + diff "^1.3.2" + escape-string-regexp "^1.0.3" + glob "^7.0.5" + tap-parser "^10.0.0" + tap-yaml "^1.0.0" + unicode-length "^1.0.0" optionalDependencies: - "readable-stream" "^2.1.5" + readable-stream "^2.1.5" -"tap-parser@^10.0.0", "tap-parser@^10.0.1": - "integrity" "sha512-qdT15H0DoJIi7zOqVXDn9X0gSM68JjNy1w3VemwTJlDnETjbi6SutnqmBfjDJAwkFS79NJ97gZKqie00ZCGmzg==" - "resolved" "https://registry.npmjs.org/tap-parser/-/tap-parser-10.0.1.tgz" - "version" "10.0.1" +tap-parser@^10.0.0, tap-parser@^10.0.1: + version "10.0.1" + resolved "https://registry.npmjs.org/tap-parser/-/tap-parser-10.0.1.tgz" + integrity sha512-qdT15H0DoJIi7zOqVXDn9X0gSM68JjNy1w3VemwTJlDnETjbi6SutnqmBfjDJAwkFS79NJ97gZKqie00ZCGmzg== dependencies: - "events-to-array" "^1.0.1" - "minipass" "^3.0.0" - "tap-yaml" "^1.0.0" + events-to-array "^1.0.1" + minipass "^3.0.0" + tap-yaml "^1.0.0" -"tap-yaml@^1.0.0": - "integrity" "sha512-Rxbx4EnrWkYk0/ztcm5u3/VznbyFJpyXO12dDBHKWiDVxy7O2Qw6MRrwO5H6Ww0U5YhRY/4C/VzWmFPhBQc4qQ==" - "resolved" "https://registry.npmjs.org/tap-yaml/-/tap-yaml-1.0.0.tgz" - "version" "1.0.0" +tap-yaml@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/tap-yaml/-/tap-yaml-1.0.0.tgz" + integrity sha512-Rxbx4EnrWkYk0/ztcm5u3/VznbyFJpyXO12dDBHKWiDVxy7O2Qw6MRrwO5H6Ww0U5YhRY/4C/VzWmFPhBQc4qQ== dependencies: - "yaml" "^1.5.0" + yaml "^1.5.0" -"tcompare@^2.3.0": - "integrity" "sha512-fAfA73uFtFGybWGt4+IYT6UPLYVZQ4NfsP+IXEZGY0vh8e2IF7LVKafcQNMRBLqP0wzEA65LM9Tqj+FSmO8GLw==" - "resolved" "https://registry.npmjs.org/tcompare/-/tcompare-2.3.0.tgz" - "version" "2.3.0" +tcompare@^2.3.0: + version "2.3.0" + resolved "https://registry.npmjs.org/tcompare/-/tcompare-2.3.0.tgz" + integrity sha512-fAfA73uFtFGybWGt4+IYT6UPLYVZQ4NfsP+IXEZGY0vh8e2IF7LVKafcQNMRBLqP0wzEA65LM9Tqj+FSmO8GLw== -"test-exclude@^5.2.3": - "integrity" "sha512-M+oxtseCFO3EDtAaGH7iiej3CBkzXqFMbzqYAACdzKui4eZA+pq3tZEwChvOdNfa7xxy8BfbmgJSIr43cC/+2g==" - "resolved" "https://registry.npmjs.org/test-exclude/-/test-exclude-5.2.3.tgz" - "version" "5.2.3" +test-exclude@^5.2.3: + version "5.2.3" + resolved "https://registry.npmjs.org/test-exclude/-/test-exclude-5.2.3.tgz" + integrity sha512-M+oxtseCFO3EDtAaGH7iiej3CBkzXqFMbzqYAACdzKui4eZA+pq3tZEwChvOdNfa7xxy8BfbmgJSIr43cC/+2g== dependencies: - "glob" "^7.1.3" - "minimatch" "^3.0.4" - "read-pkg-up" "^4.0.0" - "require-main-filename" "^2.0.0" + glob "^7.1.3" + minimatch "^3.0.4" + read-pkg-up "^4.0.0" + require-main-filename "^2.0.0" -"to-fast-properties@^1.0.3": - "integrity" "sha1-uDVx+k2MJbguIxsG46MFXeTKGkc=" - "resolved" "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-1.0.3.tgz" - "version" "1.0.3" +to-fast-properties@^1.0.3: + version "1.0.3" + resolved "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-1.0.3.tgz" + integrity sha1-uDVx+k2MJbguIxsG46MFXeTKGkc= -"to-fast-properties@^2.0.0": - "integrity" "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=" - "resolved" "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz" - "version" "2.0.0" +to-fast-properties@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz" + integrity sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4= -"to-regex-range@^5.0.1": - "integrity" "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==" - "resolved" "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz" - "version" "5.0.1" +to-regex-range@^5.0.1: + version "5.0.1" + resolved "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz" + integrity sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ== dependencies: - "is-number" "^7.0.0" + is-number "^7.0.0" -"tough-cookie@~2.4.3": - "integrity" "sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ==" - "resolved" "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.4.3.tgz" - "version" "2.4.3" +tough-cookie@~2.4.3: + version "2.4.3" + resolved "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.4.3.tgz" + integrity sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ== dependencies: - "psl" "^1.1.24" - "punycode" "^1.4.1" + psl "^1.1.24" + punycode "^1.4.1" -"treport@^0.4.2": - "integrity" "sha512-Po8pQ/rmu4lVNmZWBgqyiHoIWXFeWaMA3H/WoCKw+DiS0xFn43UYRH6hYnjmrWCp0rkLItELQP/maO9uHDe/7A==" - "resolved" "https://registry.npmjs.org/treport/-/treport-0.4.2.tgz" - "version" "0.4.2" +treport@^0.4.2: + version "0.4.2" + resolved "https://registry.npmjs.org/treport/-/treport-0.4.2.tgz" + integrity sha512-Po8pQ/rmu4lVNmZWBgqyiHoIWXFeWaMA3H/WoCKw+DiS0xFn43UYRH6hYnjmrWCp0rkLItELQP/maO9uHDe/7A== dependencies: - "cardinal" "^2.1.1" - "chalk" "^2.4.2" - "import-jsx" "^2.0.0" - "ink" "^2.1.1" - "ms" "^2.1.1" - "react" "^16.8.6" - "string-length" "^2.0.0" - "tap-parser" "^10.0.1" - "unicode-length" "^2.0.1" + cardinal "^2.1.1" + chalk "^2.4.2" + import-jsx "^2.0.0" + ink "^2.1.1" + ms "^2.1.1" + react "^16.8.6" + string-length "^2.0.0" + tap-parser "^10.0.1" + unicode-length "^2.0.1" -"trim-right@^1.0.1": - "integrity" "sha1-yy4SAwZ+DI3h9hQJS5/kVwTqYAM=" - "resolved" "https://registry.npmjs.org/trim-right/-/trim-right-1.0.1.tgz" - "version" "1.0.1" +trim-right@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/trim-right/-/trim-right-1.0.1.tgz" + integrity sha1-yy4SAwZ+DI3h9hQJS5/kVwTqYAM= -"trivial-deferred@^1.0.1": - "integrity" "sha1-N21NKdlR1jaKb3oK6FwvTV4GWPM=" - "resolved" "https://registry.npmjs.org/trivial-deferred/-/trivial-deferred-1.0.1.tgz" - "version" "1.0.1" +trivial-deferred@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/trivial-deferred/-/trivial-deferred-1.0.1.tgz" + integrity sha1-N21NKdlR1jaKb3oK6FwvTV4GWPM= -"ts-node@^8.3.0": - "integrity" "sha512-dyNS/RqyVTDcmNM4NIBAeDMpsAdaQ+ojdf0GOLqE6nwJOgzEkdRNzJywhDfwnuvB10oa6NLVG1rUJQCpRN7qoQ==" - "resolved" "https://registry.npmjs.org/ts-node/-/ts-node-8.3.0.tgz" - "version" "8.3.0" +ts-node@^8.3.0: + version "8.3.0" + resolved "https://registry.npmjs.org/ts-node/-/ts-node-8.3.0.tgz" + integrity sha512-dyNS/RqyVTDcmNM4NIBAeDMpsAdaQ+ojdf0GOLqE6nwJOgzEkdRNzJywhDfwnuvB10oa6NLVG1rUJQCpRN7qoQ== dependencies: - "arg" "^4.1.0" - "diff" "^4.0.1" - "make-error" "^1.1.1" - "source-map-support" "^0.5.6" - "yn" "^3.0.0" + arg "^4.1.0" + diff "^4.0.1" + make-error "^1.1.1" + source-map-support "^0.5.6" + yn "^3.0.0" -"tunnel-agent@^0.6.0": - "integrity" "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=" - "resolved" "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz" - "version" "0.6.0" +tunnel-agent@^0.6.0: + version "0.6.0" + resolved "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz" + integrity sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0= dependencies: - "safe-buffer" "^5.0.1" + safe-buffer "^5.0.1" -"tweetnacl@^0.14.3", "tweetnacl@~0.14.0": - "integrity" "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=" - "resolved" "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz" - "version" "0.14.5" +tweetnacl@^0.14.3, tweetnacl@~0.14.0: + version "0.14.5" + resolved "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz" + integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q= -"typedarray-to-buffer@^3.1.5": - "integrity" "sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==" - "resolved" "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz" - "version" "3.1.5" +typedarray-to-buffer@^3.1.5: + version "3.1.5" + resolved "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz" + integrity sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q== dependencies: - "is-typedarray" "^1.0.0" + is-typedarray "^1.0.0" -"typescript@^3.6.3", "typescript@>=2.0": - "integrity" "sha512-ml7V7JfiN2Xwvcer+XAf2csGO1bPBdRbFCkYBczNZggrBZ9c7G3riSUeJmqEU5uOtXNPMhE3n+R4FA/3YOAWOQ==" - "resolved" "https://registry.npmjs.org/typescript/-/typescript-3.7.2.tgz" - "version" "3.7.2" +typescript@^3.6.3, typescript@>=2.0: + version "3.7.2" + resolved "https://registry.npmjs.org/typescript/-/typescript-3.7.2.tgz" + integrity sha512-ml7V7JfiN2Xwvcer+XAf2csGO1bPBdRbFCkYBczNZggrBZ9c7G3riSUeJmqEU5uOtXNPMhE3n+R4FA/3YOAWOQ== -"uglify-js@^3.1.4": - "integrity" "sha512-W+jrUHJr3DXKhrsS7NUVxn3zqMOFn0hL/Ei6v0anCIMoKC93TjcflTagwIHLW7SfMFfiQuktQyFVCFHGUE0+yg==" - "resolved" "https://registry.npmjs.org/uglify-js/-/uglify-js-3.6.0.tgz" - "version" "3.6.0" +uglify-js@^3.1.4: + version "3.6.0" + resolved "https://registry.npmjs.org/uglify-js/-/uglify-js-3.6.0.tgz" + integrity sha512-W+jrUHJr3DXKhrsS7NUVxn3zqMOFn0hL/Ei6v0anCIMoKC93TjcflTagwIHLW7SfMFfiQuktQyFVCFHGUE0+yg== dependencies: - "commander" "~2.20.0" - "source-map" "~0.6.1" + commander "~2.20.0" + source-map "~0.6.1" -"unicode-length@^1.0.0": - "integrity" "sha1-Wtp6f+1RhBpBijKM8UlHisg1irs=" - "resolved" "https://registry.npmjs.org/unicode-length/-/unicode-length-1.0.3.tgz" - "version" "1.0.3" +unicode-length@^1.0.0: + version "1.0.3" + resolved "https://registry.npmjs.org/unicode-length/-/unicode-length-1.0.3.tgz" + integrity sha1-Wtp6f+1RhBpBijKM8UlHisg1irs= dependencies: - "punycode" "^1.3.2" - "strip-ansi" "^3.0.1" + punycode "^1.3.2" + strip-ansi "^3.0.1" -"unicode-length@^2.0.1": - "integrity" "sha512-Ph/j1VbS3/r77nhoY2WU0GWGjVYOHL3xpKp0y/Eq2e5r0mT/6b649vm7KFO6RdAdrZkYLdxphYVgvODxPB+Ebg==" - "resolved" "https://registry.npmjs.org/unicode-length/-/unicode-length-2.0.2.tgz" - "version" "2.0.2" +unicode-length@^2.0.1: + version "2.0.2" + resolved "https://registry.npmjs.org/unicode-length/-/unicode-length-2.0.2.tgz" + integrity sha512-Ph/j1VbS3/r77nhoY2WU0GWGjVYOHL3xpKp0y/Eq2e5r0mT/6b649vm7KFO6RdAdrZkYLdxphYVgvODxPB+Ebg== dependencies: - "punycode" "^2.0.0" - "strip-ansi" "^3.0.1" + punycode "^2.0.0" + strip-ansi "^3.0.1" -"uri-js@^4.2.2": - "integrity" "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==" - "resolved" "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz" - "version" "4.2.2" +uri-js@^4.2.2: + version "4.2.2" + resolved "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz" + integrity sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ== dependencies: - "punycode" "^2.1.0" + punycode "^2.1.0" -"util-deprecate@~1.0.1": - "integrity" "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" - "resolved" "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz" - "version" "1.0.2" +util-deprecate@~1.0.1: + version "1.0.2" + resolved "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz" + integrity sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8= -"uuid@^3.3.2": - "integrity" "sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA==" - "resolved" "https://registry.npmjs.org/uuid/-/uuid-3.3.2.tgz" - "version" "3.3.2" +uuid@^3.3.2: + version "3.3.2" + resolved "https://registry.npmjs.org/uuid/-/uuid-3.3.2.tgz" + integrity sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA== -"validate-npm-package-license@^3.0.1": - "integrity" "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==" - "resolved" "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz" - "version" "3.0.4" +validate-npm-package-license@^3.0.1: + version "3.0.4" + resolved "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz" + integrity sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew== dependencies: - "spdx-correct" "^3.0.0" - "spdx-expression-parse" "^3.0.0" + spdx-correct "^3.0.0" + spdx-expression-parse "^3.0.0" -"verror@1.10.0": - "integrity" "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=" - "resolved" "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz" - "version" "1.10.0" +verror@1.10.0: + version "1.10.0" + resolved "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz" + integrity sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA= dependencies: - "assert-plus" "^1.0.0" - "core-util-is" "1.0.2" - "extsprintf" "^1.2.0" + assert-plus "^1.0.0" + core-util-is "1.0.2" + extsprintf "^1.2.0" -"vlq@^0.2.1": - "integrity" "sha512-DRibZL6DsNhIgYQ+wNdWDL2SL3bKPlVrRiBqV5yuMm++op8W4kGFtaQfCs4KEJn0wBZcHVHJ3eoywX8983k1ow==" - "resolved" "https://registry.npmjs.org/vlq/-/vlq-0.2.3.tgz" - "version" "0.2.3" +vlq@^0.2.1: + version "0.2.3" + resolved "https://registry.npmjs.org/vlq/-/vlq-0.2.3.tgz" + integrity sha512-DRibZL6DsNhIgYQ+wNdWDL2SL3bKPlVrRiBqV5yuMm++op8W4kGFtaQfCs4KEJn0wBZcHVHJ3eoywX8983k1ow== -"which-module@^2.0.0": - "integrity" "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=" - "resolved" "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz" - "version" "2.0.0" +which-module@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz" + integrity sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho= -"which@^1.2.9": - "integrity" "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==" - "resolved" "https://registry.npmjs.org/which/-/which-1.3.1.tgz" - "version" "1.3.1" +which@^1.2.9: + version "1.3.1" + resolved "https://registry.npmjs.org/which/-/which-1.3.1.tgz" + integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== dependencies: - "isexe" "^2.0.0" + isexe "^2.0.0" -"which@^1.3.0": - "integrity" "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==" - "resolved" "https://registry.npmjs.org/which/-/which-1.3.1.tgz" - "version" "1.3.1" +which@^1.3.0: + version "1.3.1" + resolved "https://registry.npmjs.org/which/-/which-1.3.1.tgz" + integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== dependencies: - "isexe" "^2.0.0" + isexe "^2.0.0" -"which@^2.0.1": - "integrity" "sha512-N7GBZOTswtB9lkQBZA4+zAXrjEIWAUOB93AvzUiudRzRxhUdLURQ7D/gAIMY1gatT/LTbmbcv8SiYazy3eYB7w==" - "resolved" "https://registry.npmjs.org/which/-/which-2.0.1.tgz" - "version" "2.0.1" +which@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/which/-/which-2.0.1.tgz" + integrity sha512-N7GBZOTswtB9lkQBZA4+zAXrjEIWAUOB93AvzUiudRzRxhUdLURQ7D/gAIMY1gatT/LTbmbcv8SiYazy3eYB7w== dependencies: - "isexe" "^2.0.0" + isexe "^2.0.0" -"widest-line@^2.0.0": - "integrity" "sha512-Ba5m9/Fa4Xt9eb2ELXt77JxVDV8w7qQrH0zS/TWSJdLyAwQjWoOzpzj5lwVftDz6n/EOu3tNACS84v509qwnJA==" - "resolved" "https://registry.npmjs.org/widest-line/-/widest-line-2.0.1.tgz" - "version" "2.0.1" +widest-line@^2.0.0: + version "2.0.1" + resolved "https://registry.npmjs.org/widest-line/-/widest-line-2.0.1.tgz" + integrity sha512-Ba5m9/Fa4Xt9eb2ELXt77JxVDV8w7qQrH0zS/TWSJdLyAwQjWoOzpzj5lwVftDz6n/EOu3tNACS84v509qwnJA== dependencies: - "string-width" "^2.1.1" + string-width "^2.1.1" -"wordwrap@~0.0.2": - "integrity" "sha1-o9XabNXAvAAI03I0u68b7WMFkQc=" - "resolved" "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.3.tgz" - "version" "0.0.3" +wordwrap@~0.0.2: + version "0.0.3" + resolved "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.3.tgz" + integrity sha1-o9XabNXAvAAI03I0u68b7WMFkQc= -"wrap-ansi@^2.0.0": - "integrity" "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=" - "resolved" "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz" - "version" "2.1.0" +wrap-ansi@^2.0.0: + version "2.1.0" + resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz" + integrity sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU= dependencies: - "string-width" "^1.0.1" - "strip-ansi" "^3.0.1" + string-width "^1.0.1" + strip-ansi "^3.0.1" -"wrap-ansi@^5.0.0", "wrap-ansi@^5.1.0": - "integrity" "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==" - "resolved" "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz" - "version" "5.1.0" +wrap-ansi@^5.0.0, wrap-ansi@^5.1.0: + version "5.1.0" + resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz" + integrity sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q== dependencies: - "ansi-styles" "^3.2.0" - "string-width" "^3.0.0" - "strip-ansi" "^5.0.0" + ansi-styles "^3.2.0" + string-width "^3.0.0" + strip-ansi "^5.0.0" -"wrappy@1": - "integrity" "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" - "resolved" "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz" - "version" "1.0.2" +wrappy@1: + version "1.0.2" + resolved "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz" + integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= -"write-file-atomic@^2.4.2": - "integrity" "sha512-GaETH5wwsX+GcnzhPgKcKjJ6M2Cq3/iZp1WyY/X1CSqrW+jVNM9Y7D8EC2sM4ZG/V8wZlSniJnCKWPmBYAucRQ==" - "resolved" "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.4.3.tgz" - "version" "2.4.3" +write-file-atomic@^2.4.2: + version "2.4.3" + resolved "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.4.3.tgz" + integrity sha512-GaETH5wwsX+GcnzhPgKcKjJ6M2Cq3/iZp1WyY/X1CSqrW+jVNM9Y7D8EC2sM4ZG/V8wZlSniJnCKWPmBYAucRQ== dependencies: - "graceful-fs" "^4.1.11" - "imurmurhash" "^0.1.4" - "signal-exit" "^3.0.2" + graceful-fs "^4.1.11" + imurmurhash "^0.1.4" + signal-exit "^3.0.2" -"write-file-atomic@^3.0.0": - "integrity" "sha512-EIgkf60l2oWsffja2Sf2AL384dx328c0B+cIYPTQq5q2rOYuDV00/iPFBOUiDKKwKMOhkymH8AidPaRvzfxY+Q==" - "resolved" "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-3.0.0.tgz" - "version" "3.0.0" +write-file-atomic@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-3.0.0.tgz" + integrity sha512-EIgkf60l2oWsffja2Sf2AL384dx328c0B+cIYPTQq5q2rOYuDV00/iPFBOUiDKKwKMOhkymH8AidPaRvzfxY+Q== dependencies: - "imurmurhash" "^0.1.4" - "is-typedarray" "^1.0.0" - "signal-exit" "^3.0.2" - "typedarray-to-buffer" "^3.1.5" + imurmurhash "^0.1.4" + is-typedarray "^1.0.0" + signal-exit "^3.0.2" + typedarray-to-buffer "^3.1.5" -"y18n@^4.0.0": - "integrity" "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==" - "resolved" "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz" - "version" "4.0.0" +y18n@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz" + integrity sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w== -"yallist@^2.1.2": - "integrity" "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=" - "resolved" "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz" - "version" "2.1.2" +yallist@^2.1.2: + version "2.1.2" + resolved "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz" + integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI= -"yallist@^4.0.0": - "integrity" "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" - "resolved" "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz" - "version" "4.0.0" +yallist@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz" + integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== -"yaml@^1.5.0", "yaml@^1.6.0": - "integrity" "sha512-iZfse3lwrJRoSlfs/9KQ9iIXxs9++RvBFVzAqbbBiFT+giYtyanevreF9r61ZTbGMgWQBxAua3FzJiniiJXWWw==" - "resolved" "https://registry.npmjs.org/yaml/-/yaml-1.6.0.tgz" - "version" "1.6.0" +yaml@^1.5.0, yaml@^1.6.0: + version "1.6.0" + resolved "https://registry.npmjs.org/yaml/-/yaml-1.6.0.tgz" + integrity sha512-iZfse3lwrJRoSlfs/9KQ9iIXxs9++RvBFVzAqbbBiFT+giYtyanevreF9r61ZTbGMgWQBxAua3FzJiniiJXWWw== dependencies: "@babel/runtime" "^7.4.5" -"yapool@^1.0.0": - "integrity" "sha1-9pPymjFbUNmp2iZGp6ZkXJaYW2o=" - "resolved" "https://registry.npmjs.org/yapool/-/yapool-1.0.0.tgz" - "version" "1.0.0" +yapool@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/yapool/-/yapool-1.0.0.tgz" + integrity sha1-9pPymjFbUNmp2iZGp6ZkXJaYW2o= -"yargs-parser@^13.0.0", "yargs-parser@^13.1.0": - "integrity" "sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ==" - "resolved" "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.1.tgz" - "version" "13.1.1" +yargs-parser@^13.0.0, yargs-parser@^13.1.0: + version "13.1.1" + resolved "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.1.tgz" + integrity sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ== dependencies: - "camelcase" "^5.0.0" - "decamelize" "^1.2.0" + camelcase "^5.0.0" + decamelize "^1.2.0" -"yargs@^13.2.2": - "integrity" "sha512-HG/DWAJa1PAnHT9JAhNa8AbAv3FPaiLzioSjCcmuXXhP8MlpHO5vwls4g4j6n30Z74GVQj8Xa62dWVx1QCGklg==" - "resolved" "https://registry.npmjs.org/yargs/-/yargs-13.2.4.tgz" - "version" "13.2.4" +yargs@^13.2.2: + version "13.2.4" + resolved "https://registry.npmjs.org/yargs/-/yargs-13.2.4.tgz" + integrity sha512-HG/DWAJa1PAnHT9JAhNa8AbAv3FPaiLzioSjCcmuXXhP8MlpHO5vwls4g4j6n30Z74GVQj8Xa62dWVx1QCGklg== dependencies: - "cliui" "^5.0.0" - "find-up" "^3.0.0" - "get-caller-file" "^2.0.1" - "os-locale" "^3.1.0" - "require-directory" "^2.1.1" - "require-main-filename" "^2.0.0" - "set-blocking" "^2.0.0" - "string-width" "^3.0.0" - "which-module" "^2.0.0" - "y18n" "^4.0.0" - "yargs-parser" "^13.1.0" + cliui "^5.0.0" + find-up "^3.0.0" + get-caller-file "^2.0.1" + os-locale "^3.1.0" + require-directory "^2.1.1" + require-main-filename "^2.0.0" + set-blocking "^2.0.0" + string-width "^3.0.0" + which-module "^2.0.0" + y18n "^4.0.0" + yargs-parser "^13.1.0" -"yn@^3.0.0": - "integrity" "sha512-kKfnnYkbTfrAdd0xICNFw7Atm8nKpLcLv9AZGEt+kczL/WQVai4e2V6ZN8U/O+iI6WrNuJjNNOyu4zfhl9D3Hg==" - "resolved" "https://registry.npmjs.org/yn/-/yn-3.1.0.tgz" - "version" "3.1.0" +yn@^3.0.0: + version "3.1.0" + resolved "https://registry.npmjs.org/yn/-/yn-3.1.0.tgz" + integrity sha512-kKfnnYkbTfrAdd0xICNFw7Atm8nKpLcLv9AZGEt+kczL/WQVai4e2V6ZN8U/O+iI6WrNuJjNNOyu4zfhl9D3Hg== -"yoga-layout-prebuilt@^1.9.3": - "integrity" "sha512-9SNQpwuEh2NucU83i2KMZnONVudZ86YNcFk9tq74YaqrQfgJWO3yB9uzH1tAg8iqh5c9F5j0wuyJ2z72wcum2w==" - "resolved" "https://registry.npmjs.org/yoga-layout-prebuilt/-/yoga-layout-prebuilt-1.9.3.tgz" - "version" "1.9.3" +yoga-layout-prebuilt@^1.9.3: + version "1.9.3" + resolved "https://registry.npmjs.org/yoga-layout-prebuilt/-/yoga-layout-prebuilt-1.9.3.tgz" + integrity sha512-9SNQpwuEh2NucU83i2KMZnONVudZ86YNcFk9tq74YaqrQfgJWO3yB9uzH1tAg8iqh5c9F5j0wuyJ2z72wcum2w== ` exports[`test/shrinkwrap.js TAP loadActual tests workspace > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "a": Object { - "dependencies": Object { - "b": Object { - "dependencies": Object { - "c": Object { - "requires": Object { - "a": "", - "b": "", - }, - "version": "file:packages/c", - }, - }, - "requires": Object { - "a": "", - "c": "", - }, - "version": "file:packages/b", - }, - "c": Object { - "dependencies": Object { - "b": Object { - "requires": Object { - "a": "", - "c": "", - }, - "version": "file:packages/b", - }, - }, - "requires": Object { - "a": "", - "b": "", - }, - "version": "file:packages/c", - }, - }, - "requires": Object { - "b": "", - "c": "", - }, - "version": "file:packages/a", - }, - "b": Object { - "dependencies": Object { - "a": Object { - "dependencies": Object { - "c": Object { - "requires": Object { - "a": "", - "b": "", - }, - "version": "file:packages/c", - }, - }, - "requires": Object { - "b": "", - "c": "", - }, - "version": "file:packages/a", - }, - "c": Object { - "dependencies": Object { - "a": Object { - "requires": Object { - "b": "", - "c": "", - }, - "version": "file:packages/a", - }, - }, - "requires": Object { - "a": "", - "b": "", - }, - "version": "file:packages/c", - }, - }, - "requires": Object { - "a": "", - "c": "", - }, - "version": "file:packages/b", - }, - "c": Object { - "dependencies": Object { - "a": Object { - "dependencies": Object { - "b": Object { - "requires": Object { - "a": "", - "c": "", - }, - "version": "file:packages/b", - }, - }, - "requires": Object { - "b": "", - "c": "", - }, - "version": "file:packages/a", - }, - "b": Object { - "dependencies": Object { - "a": Object { - "requires": Object { - "b": "", - "c": "", - }, - "version": "file:packages/a", - }, - }, - "requires": Object { - "a": "", - "c": "", - }, - "version": "file:packages/b", - }, - }, - "requires": Object { - "a": "", - "b": "", - }, - "version": "file:packages/c", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "workspace", "packages": Object { "": Object { @@ -13842,44 +9658,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests workspace2 > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "b": Object { - "dependencies": Object { - "d": Object { - "requires": Object { - "b": "", - }, - "version": "1.2.3", - }, - }, - "requires": Object { - "d": "", - }, - "version": "1.2.3", - }, - "c": Object { - "dependencies": Object { - "d": Object { - "requires": Object { - "b": "", - }, - "version": "file:node_modules/b/node_modules/d", - }, - "x": Object { - "requires": Object { - "b": "", - }, - "version": "file:x", - }, - }, - "requires": Object { - "d": "", - "x": "", - }, - "version": "1.2.3", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "a", "packages": Object { "": Object { @@ -13931,70 +9710,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests workspace3 > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "a": Object { - "dependencies": Object { - "x": Object { - "extraneous": true, - "version": "1.2.3", - }, - }, - "extraneous": true, - "requires": Object { - "b": "", - "c": "", - "x": "", - }, - "version": "file:packages/a", - }, - "app": Object { - "dependencies": Object { - "i": Object { - "extraneous": true, - "version": "1.2.3", - }, - }, - "extraneous": true, - "requires": Object { - "a": "", - "b": "", - "c": "", - "i": "", - }, - "version": "file:app", - }, - "b": Object { - "dependencies": Object { - "y": Object { - "extraneous": true, - "version": "1.2.3", - }, - }, - "extraneous": true, - "requires": Object { - "a": "", - "c": "", - "y": "", - }, - "version": "file:packages/b", - }, - "c": Object { - "dependencies": Object { - "z": Object { - "extraneous": true, - "version": "1.2.3", - }, - }, - "extraneous": true, - "requires": Object { - "a": "", - "b": "", - "z": "", - }, - "version": "file:packages/c", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "workspace3", "packages": Object { "": Object { @@ -14076,18 +9792,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests workspaces-simple > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "a": Object { - "requires": Object { - "b": "^1.0.0", - }, - "version": "file:a", - }, - "b": Object { - "version": "file:b", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "workspace-simple", "packages": Object { "": Object { @@ -14121,12 +9826,7 @@ Object { exports[`test/shrinkwrap.js TAP loadActual tests yarn-lock-mkdirp-file-dep > shrinkwrap data 1`] = ` Object { - "dependencies": Object { - "mkdirp": Object { - "version": "1.0.2", - }, - }, - "lockfileVersion": 2, + "lockfileVersion": 3, "name": "yarn-lock-mkdirp-file-dep", "packages": Object { "": Object { @@ -14155,7 +9855,7 @@ exports[`test/shrinkwrap.js TAP loadActual tests yarn-lock-mkdirp-file-dep > yar "mkdirp@file:mkdirp": - "version" "1.0.2" + version "1.0.2" ` @@ -14232,18 +9932,16 @@ Object { exports[`test/shrinkwrap.js TAP saving dependency-free shrinkwrap object load file, and save it with a custom format > custom indented json output 1`] = ` { - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, - "packages": {}, - "dependencies": {} + "packages": {} } ` exports[`test/shrinkwrap.js TAP saving dependency-free shrinkwrap object load the unindented file, and generate expected contents > indented json object output 1`] = ` Object { - "dependencies": Object {}, - "lockfileVersion": 2, + "lockfileVersion": 3, "packages": Object {}, "requires": true, } @@ -14251,26 +9949,24 @@ Object { exports[`test/shrinkwrap.js TAP saving dependency-free shrinkwrap object load the unindented file, and generate expected contents > indented json string output 1`] = ` { - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, - "packages": {}, - "dependencies": {} + "packages": {} } ` exports[`test/shrinkwrap.js TAP saving dependency-free shrinkwrap object load the unindented file, and save it back default > indented json output 1`] = ` { - "lockfileVersion": 2, + "lockfileVersion": 3, "requires": true, - "packages": {}, - "dependencies": {} + "packages": {} } ` exports[`test/shrinkwrap.js TAP saving dependency-free shrinkwrap object save lockfile to root directory > no indent json output 1`] = ` -{"lockfileVersion":2,"requires":true,"packages":{},"dependencies":{}} +{"lockfileVersion":3,"requires":true,"packages":{}} ` exports[`test/shrinkwrap.js TAP shrinkwrap key order > must match snapshot 1`] = ` diff --git a/workspaces/arborist/tap-snapshots/test/spec-from-lock.js.test.cjs b/workspaces/arborist/tap-snapshots/test/spec-from-lock.js.test.cjs index 840f0ea..8a95e23 100644 --- a/workspaces/arborist/tap-snapshots/test/spec-from-lock.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/spec-from-lock.js.test.cjs @@ -15,6 +15,7 @@ Result { "fetchSpec": "{..}/some/path", "gitCommittish": undefined, "gitRange": undefined, + "gitSubdir": undefined, "hosted": undefined, "name": "x", "raw": "x@file:../some/path", @@ -33,6 +34,7 @@ Result { "fetchSpec": "{CWD}/x-1.2.3.tgz", "gitCommittish": undefined, "gitRange": undefined, + "gitSubdir": undefined, "hosted": undefined, "name": "x", "raw": "x@x-1.2.3.tgz", @@ -51,6 +53,7 @@ Result { "fetchSpec": "/path/to/x-1.2.3.tgz", "gitCommittish": undefined, "gitRange": undefined, + "gitSubdir": undefined, "hosted": undefined, "name": "x", "raw": "x@/path/to/x-1.2.3.tgz", @@ -69,6 +72,7 @@ Result { "fetchSpec": "/path/to/x-1.2.3.tgz", "gitCommittish": undefined, "gitRange": undefined, + "gitSubdir": undefined, "hosted": undefined, "name": "x", "raw": "x@/path/to/x-1.2.3.tgz", @@ -87,15 +91,20 @@ Result { "fetchSpec": "ssh://git@github.com/isaacs/abbrev-js.git", "gitCommittish": "a9ee72ebc8fe3975f1b0c7aeb3a8f2a806a432eb", "gitRange": undefined, + "gitSubdir": undefined, "hosted": GitHost { "auth": null, - "browsefiletemplate": "function browsefiletemplate", + "blobpath": "blob", + "browseblobtemplate": "function browseblobtemplate", "browsetemplate": "function browsetemplate", + "browsetreetemplate": "function browsetreetemplate", "bugstemplate": "function bugstemplate", "committish": "a9ee72ebc8fe3975f1b0c7aeb3a8f2a806a432eb", "default": "sshurl", "docstemplate": "function docstemplate", "domain": "github.com", + "editpath": "edit", + "edittemplate": "function edittemplate", "extract": "function extract", "filetemplate": "function filetemplate", "gittemplate": "function gittemplate", @@ -140,6 +149,7 @@ Result { "fetchSpec": "1.2.3", "gitCommittish": undefined, "gitRange": undefined, + "gitSubdir": undefined, "hosted": undefined, "name": "legacy", "raw": "legacy@1.2.3", @@ -158,6 +168,7 @@ Result { "fetchSpec": "{CWD}/foo.tgz", "gitCommittish": undefined, "gitRange": undefined, + "gitSubdir": undefined, "hosted": undefined, "name": "x", "raw": "x@foo.tgz", @@ -176,6 +187,7 @@ Result { "fetchSpec": "1.2.3", "gitCommittish": undefined, "gitRange": undefined, + "gitSubdir": undefined, "hosted": undefined, "name": "x", "raw": "x@1.2.3", @@ -194,6 +206,7 @@ Result { "fetchSpec": "1.2.3", "gitCommittish": undefined, "gitRange": undefined, + "gitSubdir": undefined, "hosted": undefined, "name": "x", "raw": "x@1.2.3", diff --git a/workspaces/arborist/tap-snapshots/test/yarn-lock.js.test.cjs b/workspaces/arborist/tap-snapshots/test/yarn-lock.js.test.cjs index 025aa20..020a88f 100644 --- a/workspaces/arborist/tap-snapshots/test/yarn-lock.js.test.cjs +++ b/workspaces/arborist/tap-snapshots/test/yarn-lock.js.test.cjs @@ -10,54 +10,54 @@ exports[`test/yarn-lock.js TAP deduped prior entries that dont match one another # yarn lockfile v1 -"a@": +a@: dependencies: - "i" "" - "x" "1.x" - "y" "1.x" - "z" "1.x" + i "" + x "1.x" + y "1.x" + z "1.x" -"b@": +b@: dependencies: - "j" "" - "x" "1.x" - "y" "1.x" - "z" "1.x" + j "" + x "1.x" + y "1.x" + z "1.x" -"i@": - "version" "1.0.0" +i@: + version "1.0.0" dependencies: - "x" "1.2.0" + x "1.2.0" -"j@": - "version" "1.0.0" +j@: + version "1.0.0" dependencies: - "x" "1.3.0" + x "1.3.0" -"x@1.1": - "version" "1.1.0" +x@1.1: + version "1.1.0" -"x@1.2.0", "x@1.x": - "integrity" "x120" - "version" "1.2.0" +x@1.2.0, x@1.x: + version "1.2.0" + integrity x120 -"x@1.3.0": - "integrity" "x130" - "version" "1.3.0" +x@1.3.0: + version "1.3.0" + integrity x130 -"y@1.x": - "version" "1.0.0" +y@1.x: + version "1.0.0" dependencies: - "x" "1.1" - "z" "2.x" + x "1.1" + z "2.x" -"z@1.x": - "version" "1.0.0" +z@1.x: + version "1.0.0" -"z@2.x": - "version" "2.0.0" +z@2.x: + version "2.0.0" dependencies: - "x" "1.x" + x "1.x" ` @@ -66,145 +66,145 @@ exports[`test/yarn-lock.js TAP load a yarn lock from an actual tree install-type # yarn lockfile v1 -"a@": - "integrity" "sha1-3Klr13/Wjfd5OnMDajug1UBdR3s=" - "resolved" "https://registry.internal/a/-/a-1.2.3.tgz" - "version" "1.2.3" +a@: + version "1.2.3" + resolved "https://registry.internal/a/-/a-1.2.3.tgz" + integrity sha1-3Klr13/Wjfd5OnMDajug1UBdR3s= dependencies: - "b" "" + b "" -"abbrev@^1.1.1": - "integrity" "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - "resolved" "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" - "version" "1.1.1" +abbrev@^1.1.1: + version "1.1.1" + resolved "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" + integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== -"b@": - "integrity" "sha1-4Klr13/Wjfd5OnMDajug1UBdR3s=" - "resolved" "https://registry.internal/b/-/b-1.2.3.tgz" - "version" "1.2.3" +b@: + version "1.2.3" + resolved "https://registry.internal/b/-/b-1.2.3.tgz" + integrity sha1-4Klr13/Wjfd5OnMDajug1UBdR3s= dependencies: - "c" "" + c "" -"balanced-match@^1.0.0": - "integrity" "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" - "resolved" "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz" - "version" "1.0.0" +balanced-match@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz" + integrity sha1-ibTRmasr7kneFk6gK4nORi1xt2c= -"brace-expansion@^1.1.7": - "integrity" "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==" - "resolved" "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" - "version" "1.1.11" +brace-expansion@^1.1.7: + version "1.1.11" + resolved "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" + integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== dependencies: - "balanced-match" "^1.0.0" - "concat-map" "0.0.1" + balanced-match "^1.0.0" + concat-map "0.0.1" -"bundler@1.2.3": - "integrity" "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" - "resolved" "https://registry.internal/bundler/-/bundler-1.2.3.tgz" - "version" "1.2.3" +bundler@1.2.3: + version "1.2.3" + resolved "https://registry.internal/bundler/-/bundler-1.2.3.tgz" + integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= dependencies: - "a" "" + a "" -"c@": - "integrity" "sha1-5Klr13/Wjfd5OnMDajug1UBdR3s=" - "resolved" "https://registry.internal/c/-/c-1.2.3.tgz" - "version" "1.2.3" +c@: + version "1.2.3" + resolved "https://registry.internal/c/-/c-1.2.3.tgz" + integrity sha1-5Klr13/Wjfd5OnMDajug1UBdR3s= -"concat-map@0.0.1": - "integrity" "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" - "resolved" "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" - "version" "0.0.1" +concat-map@0.0.1: + version "0.0.1" + resolved "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" + integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= -"fs.realpath@^1.0.0": - "integrity" "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" - "resolved" "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" - "version" "1.0.0" +fs.realpath@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" + integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= "full-git-url@git+https://github.com/isaacs/abbrev-js.git": - "resolved" "git+ssh://git@github.com/isaacs/abbrev-js.git#a9ee72ebc8fe3975f1b0c7aeb3a8f2a806a432eb" - "version" "1.1.1" + version "1.1.1" + resolved "git+ssh://git@github.com/isaacs/abbrev-js.git#a9ee72ebc8fe3975f1b0c7aeb3a8f2a806a432eb" "ghshort@github:isaacs/abbrev-js": - "resolved" "git+ssh://git@github.com/isaacs/abbrev-js.git#a9ee72ebc8fe3975f1b0c7aeb3a8f2a806a432eb" - "version" "1.1.1" + version "1.1.1" + resolved "git+ssh://git@github.com/isaacs/abbrev-js.git#a9ee72ebc8fe3975f1b0c7aeb3a8f2a806a432eb" -"glob@^7.1.3": - "integrity" "sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A==" - "resolved" "https://registry.npmjs.org/glob/-/glob-7.1.4.tgz" - "version" "7.1.4" +glob@^7.1.3: + version "7.1.4" + resolved "https://registry.npmjs.org/glob/-/glob-7.1.4.tgz" + integrity sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A== dependencies: - "fs.realpath" "^1.0.0" - "inflight" "^1.0.4" - "inherits" "2" - "minimatch" "^3.0.4" - "once" "^1.3.0" - "path-is-absolute" "^1.0.0" + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" -"inflight@^1.0.4": - "integrity" "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=" - "resolved" "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" - "version" "1.0.6" +inflight@^1.0.4: + version "1.0.6" + resolved "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" + integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk= dependencies: - "once" "^1.3.0" - "wrappy" "1" + once "^1.3.0" + wrappy "1" -"inherits@2": - "integrity" "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" - "resolved" "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" - "version" "2.0.4" +inherits@2: + version "2.0.4" + resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== -"minimatch@^3.0.4": - "integrity" "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==" - "resolved" "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz" - "version" "3.0.4" +minimatch@^3.0.4: + version "3.0.4" + resolved "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz" + integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== dependencies: - "brace-expansion" "^1.1.7" + brace-expansion "^1.1.7" "old@npm:abbrev@^1.0.3": - "integrity" "sha1-qgScln+ZkiKqQuFENPDFYu9GgkE=" - "resolved" "https://registry.npmjs.org/abbrev/-/abbrev-1.0.3.tgz" - "version" "1.0.3" + version "1.0.3" + resolved "https://registry.npmjs.org/abbrev/-/abbrev-1.0.3.tgz" + integrity sha1-qgScln+ZkiKqQuFENPDFYu9GgkE= -"once@^1.3.0": - "integrity" "sha512-oic2VxBO6ZRyhk4W/amcN3D4tGpSELjpXwShWPBHNVDvVXo2+JcNnNx6Dth+Y961vfz7SmCCc6RP2oNQE2yVwQ==" - "resolved" "file:once-1.4.0.tgz" - "version" "1.4.0" +once@^1.3.0: + version "1.4.0" + resolved "file:once-1.4.0.tgz" + integrity sha512-oic2VxBO6ZRyhk4W/amcN3D4tGpSELjpXwShWPBHNVDvVXo2+JcNnNx6Dth+Y961vfz7SmCCc6RP2oNQE2yVwQ== dependencies: - "wrappy" "1" + wrappy "1" -"path-is-absolute@^1.0.0": - "integrity" "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" - "resolved" "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz" - "version" "1.0.1" +path-is-absolute@^1.0.0: + version "1.0.1" + resolved "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz" + integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= "pinned@npm:abbrev@^1.1.1": - "integrity" "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - "resolved" "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" - "version" "1.1.1" + version "1.1.1" + resolved "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" + integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== "reg@npm:abbrev@^1.1.1": - "integrity" "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - "resolved" "https://localhost:8080/abbrev/-/abbrev-1.1.1.tgz" - "version" "1.1.1" + version "1.1.1" + resolved "https://localhost:8080/abbrev/-/abbrev-1.1.1.tgz" + integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== "remote@https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz": - "integrity" "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - "resolved" "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" - "version" "1.1.1" + version "1.1.1" + resolved "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" + integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== "symlink@file:./abbrev-link-target": - "resolved" "file:abbrev-link-target" - "version" "1.1.1" + version "1.1.1" + resolved "file:abbrev-link-target" "tarball@file:abbrev-1.1.1.tgz": - "integrity" "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - "resolved" "file:abbrev-1.1.1.tgz" - "version" "1.1.1" + version "1.1.1" + resolved "file:abbrev-1.1.1.tgz" + integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== -"wrappy@1": - "integrity" "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" - "resolved" "https://localhost:8080/wrappy/-/wrappy-1.0.2.tgz" - "version" "1.0.2" +wrappy@1: + version "1.0.2" + resolved "https://localhost:8080/wrappy/-/wrappy-1.0.2.tgz" + integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= ` @@ -213,66 +213,66 @@ exports[`test/yarn-lock.js TAP load a yarn lock from an actual tree links-all-ov # yarn lockfile v1 -"a@": - "version" "1.2.3" +a@: + version "1.2.3" dependencies: - "b" "" + b "" -"b@": - "version" "1.2.3" +b@: + version "1.2.3" dependencies: - "c" "" + c "" -"c@": - "version" "1.2.3" +c@: + version "1.2.3" dependencies: - "d" "" + d "" -"d@": - "version" "1.2.3" +d@: + version "1.2.3" dependencies: - "deep" "" + deep "" -"deep-a@": - "version" "1.2.3" +deep-a@: + version "1.2.3" -"deep@": - "version" "1.2.3" +deep@: + version "1.2.3" dependencies: - "a" "" - "deep-a" "" + a "" + deep-a "" -"link-deep@": - "resolved" "file:node_modules/nest/node_modules/a/node_modules/b/node_modules/c/node_modules/d/node_modules/deep" - "version" "1.2.3" +link-deep@: + version "1.2.3" + resolved "file:node_modules/nest/node_modules/a/node_modules/b/node_modules/c/node_modules/d/node_modules/deep" dependencies: - "a" "" - "deep-a" "" + a "" + deep-a "" -"link-in-nest@": - "resolved" "file:real" - "version" "1.2.3" +link-in-nest@: + version "1.2.3" + resolved "file:real" dependencies: - "link-link" "" + link-link "" -"link-link@": - "resolved" "file:node_modules/nest/node_modules/a/node_modules/b/node_modules/c/node_modules/d/node_modules/deep" - "version" "1.2.3" +link-link@: + version "1.2.3" + resolved "file:node_modules/nest/node_modules/a/node_modules/b/node_modules/c/node_modules/d/node_modules/deep" dependencies: - "a" "" - "deep-a" "" + a "" + deep-a "" -"link-outside-nest@": - "resolved" "file:real" - "version" "1.2.3" +link-outside-nest@: + version "1.2.3" + resolved "file:real" dependencies: - "link-link" "" + link-link "" -"nest@": - "version" "1.2.3" +nest@: + version "1.2.3" dependencies: - "a" "" - "link-in-nest" "" + a "" + link-in-nest "" ` @@ -281,134 +281,134 @@ exports[`test/yarn-lock.js TAP more nesting tree complications > yarn.lock with # yarn lockfile v1 -"a@": +a@: dependencies: - "g" "" - "h" "" - "i" "" - "j" "" - "k" "" - "x" "" + g "" + h "" + i "" + j "" + k "" + x "" -"b@": +b@: dependencies: - "l" "" - "m" "" - "n" "" - "n2" "" - "o" "" - "p" "" - "x" "" + l "" + m "" + n "" + n2 "" + o "" + p "" + x "" -"c@": +c@: dependencies: - "d" "" - "e" "" - "f" "" + d "" + e "" + f "" -"c2@": +c2@: dependencies: - "d2" "" - "e2" "" - "f2" "" + d2 "" + e2 "" + f2 "" -"d@": - "version" "1.0.0" +d@: + version "1.0.0" dependencies: - "x" "^1.0.1" + x "^1.0.1" -"d2@": - "version" "1.0.0" +d2@: + version "1.0.0" dependencies: - "x" "^1.0.0-x" + x "^1.0.0-x" -"d3@": +d3@: dependencies: - "x" "" + x "" -"e@": - "version" "1.0.0" +e@: + version "1.0.0" dependencies: - "x" ">=1.0.1 <2" + x ">=1.0.1 <2" -"e2@": - "version" "1.0.0" +e2@: + version "1.0.0" dependencies: - "x" ">=1.0.0" + x ">=1.0.0" -"f@": - "version" "1.0.0" +f@: + version "1.0.0" dependencies: - "x" ">=1.0" + x ">=1.0" -"f2@": - "version" "1.0.0" +f2@: + version "1.0.0" dependencies: - "x" "1.0.1" + x "1.0.1" -"g@": - "version" "1.0.0" +g@: + version "1.0.0" dependencies: - "x" "^1.0.0" + x "^1.0.0" -"h@": - "version" "1.0.0" +h@: + version "1.0.0" dependencies: - "x" "1.0.0" + x "1.0.0" -"i@": - "version" "1.0.0" +i@: + version "1.0.0" dependencies: - "x" "1.0" + x "1.0" -"j@": - "version" "1.0.0" +j@: + version "1.0.0" dependencies: - "x" "1" + x "1" -"k@": - "version" "1.0.0" +k@: + version "1.0.0" dependencies: - "x" "" + x "" -"l@": - "version" "1.0.0" +l@: + version "1.0.0" dependencies: - "x" "^1.0.1" + x "^1.0.1" -"m@": - "version" "1.0.0" +m@: + version "1.0.0" dependencies: - "x" "1.0.1" + x "1.0.1" -"n@": - "version" "1.0.0" +n@: + version "1.0.0" dependencies: - "x" "1.0" + x "1.0" -"n2@": - "version" "1.0.0" +n2@: + version "1.0.0" dependencies: - "x" ">=1.0" + x ">=1.0" -"o@": - "version" "1.0.0" +o@: + version "1.0.0" dependencies: - "x" "1" + x "1" -"p@": - "version" "1.0.0" +p@: + version "1.0.0" dependencies: - "x" "" + x "" -"x@", "x@^1.0.0", "x@1", "x@1.0", "x@1.0.0": - "resolved" "https://x100.xyz" - "version" "1.0.0" +x@, x@^1.0.0, x@1, x@1.0, x@1.0.0: + version "1.0.0" + resolved "https://x100.xyz" -"x@^1.0.0-x", "x@^1.0.1", "x@>=1.0", "x@>=1.0.0", "x@>=1.0.1 <2", "x@1.0.1": - "integrity" "x101" - "resolved" "https://x101.xyz" - "version" "1.0.1" +x@^1.0.0-x, x@^1.0.1, x@>=1.0, x@>=1.0.0, "x@>=1.0.1 <2", x@1.0.1: + version "1.0.1" + resolved "https://x101.xyz" + integrity x101 ` @@ -418,80 +418,80 @@ exports[`test/yarn-lock.js TAP tap-with-yarn-lock > generated output from input "@babel/code-frame@^7.0.0": - "integrity" "sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA==" - "resolved" "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0.tgz" - "version" "7.0.0" + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0.tgz" + integrity sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA== dependencies: "@babel/highlight" "^7.0.0" "@babel/generator@^7.4.0", "@babel/generator@^7.5.0": - "integrity" "sha512-1TTVrt7J9rcG5PMjvO7VEG3FrEoEJNHxumRq66GemPmzboLWtIjjcJgk8rokuAS7IiRSpgVSu5Vb9lc99iJkOA==" - "resolved" "https://registry.yarnpkg.com/@babel/generator/-/generator-7.5.0.tgz" - "version" "7.5.0" + version "7.5.0" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.5.0.tgz" + integrity sha512-1TTVrt7J9rcG5PMjvO7VEG3FrEoEJNHxumRq66GemPmzboLWtIjjcJgk8rokuAS7IiRSpgVSu5Vb9lc99iJkOA== dependencies: "@babel/types" "^7.5.0" - "jsesc" "^2.5.1" - "lodash" "^4.17.11" - "source-map" "^0.5.0" - "trim-right" "^1.0.1" + jsesc "^2.5.1" + lodash "^4.17.11" + source-map "^0.5.0" + trim-right "^1.0.1" "@babel/helper-function-name@^7.1.0": - "integrity" "sha512-A95XEoCpb3TO+KZzJ4S/5uW5fNe26DjBGqf1o9ucyLyCmi1dXq/B3c8iaWTfBk3VvetUxl16e8tIrd5teOCfGw==" - "resolved" "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.1.0.tgz" - "version" "7.1.0" + version "7.1.0" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.1.0.tgz" + integrity sha512-A95XEoCpb3TO+KZzJ4S/5uW5fNe26DjBGqf1o9ucyLyCmi1dXq/B3c8iaWTfBk3VvetUxl16e8tIrd5teOCfGw== dependencies: "@babel/helper-get-function-arity" "^7.0.0" "@babel/template" "^7.1.0" "@babel/types" "^7.0.0" "@babel/helper-get-function-arity@^7.0.0": - "integrity" "sha512-r2DbJeg4svYvt3HOS74U4eWKsUAMRH01Z1ds1zx8KNTPtpTL5JAsdFv8BNyOpVqdFhHkkRDIg5B4AsxmkjAlmQ==" - "resolved" "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz" - "version" "7.0.0" + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz" + integrity sha512-r2DbJeg4svYvt3HOS74U4eWKsUAMRH01Z1ds1zx8KNTPtpTL5JAsdFv8BNyOpVqdFhHkkRDIg5B4AsxmkjAlmQ== dependencies: "@babel/types" "^7.0.0" "@babel/helper-split-export-declaration@^7.4.4": - "integrity" "sha512-Ro/XkzLf3JFITkW6b+hNxzZ1n5OQ80NvIUdmHspih1XAhtN3vPTuUFT4eQnela+2MaZ5ulH+iyP513KJrxbN7Q==" - "resolved" "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.4.4.tgz" - "version" "7.4.4" + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.4.4.tgz" + integrity sha512-Ro/XkzLf3JFITkW6b+hNxzZ1n5OQ80NvIUdmHspih1XAhtN3vPTuUFT4eQnela+2MaZ5ulH+iyP513KJrxbN7Q== dependencies: "@babel/types" "^7.4.4" "@babel/highlight@^7.0.0": - "integrity" "sha512-7dV4eu9gBxoM0dAnj/BCFDW9LFU0zvTrkq0ugM7pnHEgguOEeOz1so2ZghEdzviYzQEED0r4EAgpsBChKy1TRQ==" - "resolved" "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.5.0.tgz" - "version" "7.5.0" + version "7.5.0" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.5.0.tgz" + integrity sha512-7dV4eu9gBxoM0dAnj/BCFDW9LFU0zvTrkq0ugM7pnHEgguOEeOz1so2ZghEdzviYzQEED0r4EAgpsBChKy1TRQ== dependencies: - "chalk" "^2.0.0" - "esutils" "^2.0.2" - "js-tokens" "^4.0.0" + chalk "^2.0.0" + esutils "^2.0.2" + js-tokens "^4.0.0" "@babel/parser@^7.4.3", "@babel/parser@^7.4.4", "@babel/parser@^7.5.0": - "integrity" "sha512-I5nW8AhGpOXGCCNYGc+p7ExQIBxRFnS2fd/d862bNOKvmoEPjYPcfIjsfdy0ujagYOIYPczKgD9l3FsgTkAzKA==" - "resolved" "https://registry.yarnpkg.com/@babel/parser/-/parser-7.5.0.tgz" - "version" "7.5.0" + version "7.5.0" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.5.0.tgz" + integrity sha512-I5nW8AhGpOXGCCNYGc+p7ExQIBxRFnS2fd/d862bNOKvmoEPjYPcfIjsfdy0ujagYOIYPczKgD9l3FsgTkAzKA== "@babel/runtime@^7.4.5": - "integrity" "sha512-9M29wrrP7//JBGX70+IrDuD1w4iOYhUGpJNMQJVNAXue+cFeFlMTqBECouIziXPUphlgrfjcfiEpGX4t0WGK4g==" - "resolved" "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.5.2.tgz" - "version" "7.5.2" + version "7.5.2" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.5.2.tgz" + integrity sha512-9M29wrrP7//JBGX70+IrDuD1w4iOYhUGpJNMQJVNAXue+cFeFlMTqBECouIziXPUphlgrfjcfiEpGX4t0WGK4g== dependencies: - "regenerator-runtime" "^0.13.2" + regenerator-runtime "^0.13.2" "@babel/template@^7.1.0", "@babel/template@^7.4.0": - "integrity" "sha512-CiGzLN9KgAvgZsnivND7rkA+AeJ9JB0ciPOD4U59GKbQP2iQl+olF1l76kJOupqidozfZ32ghwBEJDhnk9MEcw==" - "resolved" "https://registry.yarnpkg.com/@babel/template/-/template-7.4.4.tgz" - "version" "7.4.4" + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.4.4.tgz" + integrity sha512-CiGzLN9KgAvgZsnivND7rkA+AeJ9JB0ciPOD4U59GKbQP2iQl+olF1l76kJOupqidozfZ32ghwBEJDhnk9MEcw== dependencies: "@babel/code-frame" "^7.0.0" "@babel/parser" "^7.4.4" "@babel/types" "^7.4.4" "@babel/traverse@^7.4.3": - "integrity" "sha512-SnA9aLbyOCcnnbQEGwdfBggnc142h/rbqqsXcaATj2hZcegCl903pUD/lfpsNBlBSuWow/YDfRyJuWi2EPR5cg==" - "resolved" "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.5.0.tgz" - "version" "7.5.0" + version "7.5.0" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.5.0.tgz" + integrity sha512-SnA9aLbyOCcnnbQEGwdfBggnc142h/rbqqsXcaATj2hZcegCl903pUD/lfpsNBlBSuWow/YDfRyJuWi2EPR5cg== dependencies: "@babel/code-frame" "^7.0.0" "@babel/generator" "^7.5.0" @@ -499,2494 +499,2494 @@ exports[`test/yarn-lock.js TAP tap-with-yarn-lock > generated output from input "@babel/helper-split-export-declaration" "^7.4.4" "@babel/parser" "^7.5.0" "@babel/types" "^7.5.0" - "debug" "^4.1.0" - "globals" "^11.1.0" - "lodash" "^4.17.11" + debug "^4.1.0" + globals "^11.1.0" + lodash "^4.17.11" "@babel/types@^7.0.0", "@babel/types@^7.4.0", "@babel/types@^7.4.4", "@babel/types@^7.5.0": - "integrity" "sha512-UFpDVqRABKsW01bvw7/wSUe56uy6RXM5+VJibVVAybDGxEW25jdwiFJEf7ASvSaC7sN7rbE/l3cLp2izav+CtQ==" - "resolved" "https://registry.yarnpkg.com/@babel/types/-/types-7.5.0.tgz" - "version" "7.5.0" + version "7.5.0" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.5.0.tgz" + integrity sha512-UFpDVqRABKsW01bvw7/wSUe56uy6RXM5+VJibVVAybDGxEW25jdwiFJEf7ASvSaC7sN7rbE/l3cLp2izav+CtQ== dependencies: - "esutils" "^2.0.2" - "lodash" "^4.17.11" - "to-fast-properties" "^2.0.0" + esutils "^2.0.2" + lodash "^4.17.11" + to-fast-properties "^2.0.0" "@types/prop-types@*": - "integrity" "sha512-CFzn9idOEpHrgdw8JsoTkaDDyRWk1jrzIV8djzcgpq0y9tG4B4lFT+Nxh52DVpDXV+n4+NPNv7M1Dj5uMp6XFg==" - "resolved" "https://registry.yarnpkg.com/@types/prop-types/-/prop-types-15.7.1.tgz" - "version" "15.7.1" + version "15.7.1" + resolved "https://registry.yarnpkg.com/@types/prop-types/-/prop-types-15.7.1.tgz" + integrity sha512-CFzn9idOEpHrgdw8JsoTkaDDyRWk1jrzIV8djzcgpq0y9tG4B4lFT+Nxh52DVpDXV+n4+NPNv7M1Dj5uMp6XFg== "@types/react@^16.8.12", "@types/react@^16.8.6": - "integrity" "sha512-abkEOIeljniUN9qB5onp++g0EY38h7atnDHxwKUFz1r3VH1+yG1OKi2sNPTyObL40goBmfKFpdii2lEzwLX1cA==" - "resolved" "https://registry.yarnpkg.com/@types/react/-/react-16.8.23.tgz" - "version" "16.8.23" + version "16.8.23" + resolved "https://registry.yarnpkg.com/@types/react/-/react-16.8.23.tgz" + integrity sha512-abkEOIeljniUN9qB5onp++g0EY38h7atnDHxwKUFz1r3VH1+yG1OKi2sNPTyObL40goBmfKFpdii2lEzwLX1cA== dependencies: "@types/prop-types" "*" - "csstype" "^2.2.0" + csstype "^2.2.0" -"ajv@^6.5.5": - "integrity" "sha512-w1YQaVGNC6t2UCPjEawK/vo/dG8OOrVtUmhBT1uJJYxbl5kU2Tj3v6LGqBcsysN1yhuCStJCCA3GqdvKY8sqXQ==" - "resolved" "https://registry.yarnpkg.com/ajv/-/ajv-6.10.1.tgz" - "version" "6.10.1" +ajv@^6.5.5: + version "6.10.1" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.10.1.tgz" + integrity sha512-w1YQaVGNC6t2UCPjEawK/vo/dG8OOrVtUmhBT1uJJYxbl5kU2Tj3v6LGqBcsysN1yhuCStJCCA3GqdvKY8sqXQ== dependencies: - "fast-deep-equal" "^2.0.1" - "fast-json-stable-stringify" "^2.0.0" - "json-schema-traverse" "^0.4.1" - "uri-js" "^4.2.2" + fast-deep-equal "^2.0.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.2" -"ansi-escapes@^3.2.0": - "integrity" "sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ==" - "resolved" "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.2.0.tgz" - "version" "3.2.0" +ansi-escapes@^3.2.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.2.0.tgz" + integrity sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ== -"ansi-regex@^2.0.0": - "integrity" "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=" - "resolved" "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz" - "version" "2.1.1" +ansi-regex@^2.0.0: + version "2.1.1" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz" + integrity sha1-w7M6te42DYbg5ijwRorn7yfWVN8= -"ansi-regex@^3.0.0": - "integrity" "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" - "resolved" "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz" - "version" "3.0.0" +ansi-regex@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz" + integrity sha1-7QMXwyIGT3lGbAKWa922Bas32Zg= -"ansi-regex@^4.1.0": - "integrity" "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" - "resolved" "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.0.tgz" - "version" "4.1.0" +ansi-regex@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.0.tgz" + integrity sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg== -"ansi-styles@^2.2.1": - "integrity" "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=" - "resolved" "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz" - "version" "2.2.1" +ansi-styles@^2.2.1: + version "2.2.1" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz" + integrity sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4= -"ansi-styles@^3.2.0", "ansi-styles@^3.2.1": - "integrity" "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==" - "resolved" "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz" - "version" "3.2.1" +ansi-styles@^3.2.0, ansi-styles@^3.2.1: + version "3.2.1" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz" + integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== dependencies: - "color-convert" "^1.9.0" + color-convert "^1.9.0" -"ansicolors@~0.3.2": - "integrity" "sha1-ZlWX3oap/+Oqm/vmyuXG6kJrSXk=" - "resolved" "https://registry.yarnpkg.com/ansicolors/-/ansicolors-0.3.2.tgz" - "version" "0.3.2" +ansicolors@~0.3.2: + version "0.3.2" + resolved "https://registry.yarnpkg.com/ansicolors/-/ansicolors-0.3.2.tgz" + integrity sha1-ZlWX3oap/+Oqm/vmyuXG6kJrSXk= -"anymatch@~3.1.1": - "integrity" "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==" - "resolved" "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.1.tgz" - "version" "3.1.1" +anymatch@~3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.1.tgz" + integrity sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg== dependencies: - "normalize-path" "^3.0.0" - "picomatch" "^2.0.4" + normalize-path "^3.0.0" + picomatch "^2.0.4" -"append-transform@^1.0.0": - "integrity" "sha512-P009oYkeHyU742iSZJzZZywj4QRJdnTWffaKuJQLablCZ1uz6/cW4yaRgcDaoQ+uwOxxnt0gRUcwfsNP2ri0gw==" - "resolved" "https://registry.yarnpkg.com/append-transform/-/append-transform-1.0.0.tgz" - "version" "1.0.0" +append-transform@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/append-transform/-/append-transform-1.0.0.tgz" + integrity sha512-P009oYkeHyU742iSZJzZZywj4QRJdnTWffaKuJQLablCZ1uz6/cW4yaRgcDaoQ+uwOxxnt0gRUcwfsNP2ri0gw== dependencies: - "default-require-extensions" "^2.0.0" + default-require-extensions "^2.0.0" -"archy@^1.0.0": - "integrity" "sha1-+cjBN1fMHde8N5rHeyxipcKGjEA=" - "resolved" "https://registry.yarnpkg.com/archy/-/archy-1.0.0.tgz" - "version" "1.0.0" +archy@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/archy/-/archy-1.0.0.tgz" + integrity sha1-+cjBN1fMHde8N5rHeyxipcKGjEA= -"arg@^4.1.0": - "integrity" "sha512-ZWc51jO3qegGkVh8Hwpv636EkbesNV5ZNQPCtRa+0qytRYPEs9IYT9qITY9buezqUH5uqyzlWLcufrzU2rffdg==" - "resolved" "https://registry.yarnpkg.com/arg/-/arg-4.1.0.tgz" - "version" "4.1.0" +arg@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/arg/-/arg-4.1.0.tgz" + integrity sha512-ZWc51jO3qegGkVh8Hwpv636EkbesNV5ZNQPCtRa+0qytRYPEs9IYT9qITY9buezqUH5uqyzlWLcufrzU2rffdg== -"argparse@^1.0.7": - "integrity" "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==" - "resolved" "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz" - "version" "1.0.10" +argparse@^1.0.7: + version "1.0.10" + resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz" + integrity sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg== dependencies: - "sprintf-js" "~1.0.2" + sprintf-js "~1.0.2" -"arrify@^1.0.1": - "integrity" "sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0=" - "resolved" "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz" - "version" "1.0.1" +arrify@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz" + integrity sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0= -"asn1@~0.2.3": - "integrity" "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==" - "resolved" "https://registry.yarnpkg.com/asn1/-/asn1-0.2.4.tgz" - "version" "0.2.4" +asn1@~0.2.3: + version "0.2.4" + resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.4.tgz" + integrity sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg== dependencies: - "safer-buffer" "~2.1.0" + safer-buffer "~2.1.0" -"assert-plus@^1.0.0", "assert-plus@1.0.0": - "integrity" "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=" - "resolved" "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz" - "version" "1.0.0" +assert-plus@^1.0.0, assert-plus@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz" + integrity sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU= -"astral-regex@^1.0.0": - "integrity" "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==" - "resolved" "https://registry.yarnpkg.com/astral-regex/-/astral-regex-1.0.0.tgz" - "version" "1.0.0" +astral-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-1.0.0.tgz" + integrity sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg== -"async-hook-domain@^1.1.2": - "integrity" "sha512-ZovMxSbADV3+biB7oR1GL5lGyptI24alp0LWHlmz1OFc5oL47pz3EiIF6nXOkDW7yLqih4NtsiYduzdDW0i+Wg==" - "resolved" "https://registry.yarnpkg.com/async-hook-domain/-/async-hook-domain-1.1.3.tgz" - "version" "1.1.3" +async-hook-domain@^1.1.2: + version "1.1.3" + resolved "https://registry.yarnpkg.com/async-hook-domain/-/async-hook-domain-1.1.3.tgz" + integrity sha512-ZovMxSbADV3+biB7oR1GL5lGyptI24alp0LWHlmz1OFc5oL47pz3EiIF6nXOkDW7yLqih4NtsiYduzdDW0i+Wg== dependencies: - "source-map-support" "^0.5.11" + source-map-support "^0.5.11" -"asynckit@^0.4.0": - "integrity" "sha1-x57Zf380y48robyXkLzDZkdLS3k=" - "resolved" "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz" - "version" "0.4.0" +asynckit@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz" + integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= -"auto-bind@^2.0.0": - "integrity" "sha512-qZuFvkes1eh9lB2mg8/HG18C+5GIO51r+RrCSst/lh+i5B1CtVlkhTE488M805Nr3dKl0sM/pIFKSKUIlg3zUg==" - "resolved" "https://registry.yarnpkg.com/auto-bind/-/auto-bind-2.1.0.tgz" - "version" "2.1.0" +auto-bind@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/auto-bind/-/auto-bind-2.1.0.tgz" + integrity sha512-qZuFvkes1eh9lB2mg8/HG18C+5GIO51r+RrCSst/lh+i5B1CtVlkhTE488M805Nr3dKl0sM/pIFKSKUIlg3zUg== dependencies: "@types/react" "^16.8.12" -"aws-sign2@~0.7.0": - "integrity" "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=" - "resolved" "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz" - "version" "0.7.0" +aws-sign2@~0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz" + integrity sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg= -"aws4@^1.8.0": - "integrity" "sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ==" - "resolved" "https://registry.yarnpkg.com/aws4/-/aws4-1.8.0.tgz" - "version" "1.8.0" +aws4@^1.8.0: + version "1.8.0" + resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.8.0.tgz" + integrity sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ== -"babel-code-frame@^6.26.0": - "integrity" "sha1-Y/1D99weO7fONZR9uP42mj9Yx0s=" - "resolved" "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz" - "version" "6.26.0" +babel-code-frame@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz" + integrity sha1-Y/1D99weO7fONZR9uP42mj9Yx0s= dependencies: - "chalk" "^1.1.3" - "esutils" "^2.0.2" - "js-tokens" "^3.0.2" + chalk "^1.1.3" + esutils "^2.0.2" + js-tokens "^3.0.2" -"babel-core@^6.25.0", "babel-core@^6.26.0": - "integrity" "sha512-6jyFLuDmeidKmUEb3NM+/yawG0M2bDZ9Z1qbZP59cyHLz8kYGKYwpJP0UwUKKUiTRNvxfLesJnTedqczP7cTDA==" - "resolved" "https://registry.yarnpkg.com/babel-core/-/babel-core-6.26.3.tgz" - "version" "6.26.3" +babel-core@^6.25.0, babel-core@^6.26.0: + version "6.26.3" + resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.26.3.tgz" + integrity sha512-6jyFLuDmeidKmUEb3NM+/yawG0M2bDZ9Z1qbZP59cyHLz8kYGKYwpJP0UwUKKUiTRNvxfLesJnTedqczP7cTDA== dependencies: - "babel-code-frame" "^6.26.0" - "babel-generator" "^6.26.0" - "babel-helpers" "^6.24.1" - "babel-messages" "^6.23.0" - "babel-register" "^6.26.0" - "babel-runtime" "^6.26.0" - "babel-template" "^6.26.0" - "babel-traverse" "^6.26.0" - "babel-types" "^6.26.0" - "babylon" "^6.18.0" - "convert-source-map" "^1.5.1" - "debug" "^2.6.9" - "json5" "^0.5.1" - "lodash" "^4.17.4" - "minimatch" "^3.0.4" - "path-is-absolute" "^1.0.1" - "private" "^0.1.8" - "slash" "^1.0.0" - "source-map" "^0.5.7" + babel-code-frame "^6.26.0" + babel-generator "^6.26.0" + babel-helpers "^6.24.1" + babel-messages "^6.23.0" + babel-register "^6.26.0" + babel-runtime "^6.26.0" + babel-template "^6.26.0" + babel-traverse "^6.26.0" + babel-types "^6.26.0" + babylon "^6.18.0" + convert-source-map "^1.5.1" + debug "^2.6.9" + json5 "^0.5.1" + lodash "^4.17.4" + minimatch "^3.0.4" + path-is-absolute "^1.0.1" + private "^0.1.8" + slash "^1.0.0" + source-map "^0.5.7" -"babel-generator@^6.26.0": - "integrity" "sha512-HyfwY6ApZj7BYTcJURpM5tznulaBvyio7/0d4zFOeMPUmfxkCjHocCuoLa2SAGzBI8AREcH3eP3758F672DppA==" - "resolved" "https://registry.yarnpkg.com/babel-generator/-/babel-generator-6.26.1.tgz" - "version" "6.26.1" +babel-generator@^6.26.0: + version "6.26.1" + resolved "https://registry.yarnpkg.com/babel-generator/-/babel-generator-6.26.1.tgz" + integrity sha512-HyfwY6ApZj7BYTcJURpM5tznulaBvyio7/0d4zFOeMPUmfxkCjHocCuoLa2SAGzBI8AREcH3eP3758F672DppA== dependencies: - "babel-messages" "^6.23.0" - "babel-runtime" "^6.26.0" - "babel-types" "^6.26.0" - "detect-indent" "^4.0.0" - "jsesc" "^1.3.0" - "lodash" "^4.17.4" - "source-map" "^0.5.7" - "trim-right" "^1.0.1" + babel-messages "^6.23.0" + babel-runtime "^6.26.0" + babel-types "^6.26.0" + detect-indent "^4.0.0" + jsesc "^1.3.0" + lodash "^4.17.4" + source-map "^0.5.7" + trim-right "^1.0.1" -"babel-helper-builder-react-jsx@^6.24.1": - "integrity" "sha1-Of+DE7dci2Xc7/HzHTg+D/KkCKA=" - "resolved" "https://registry.yarnpkg.com/babel-helper-builder-react-jsx/-/babel-helper-builder-react-jsx-6.26.0.tgz" - "version" "6.26.0" +babel-helper-builder-react-jsx@^6.24.1: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-helper-builder-react-jsx/-/babel-helper-builder-react-jsx-6.26.0.tgz" + integrity sha1-Of+DE7dci2Xc7/HzHTg+D/KkCKA= dependencies: - "babel-runtime" "^6.26.0" - "babel-types" "^6.26.0" - "esutils" "^2.0.2" + babel-runtime "^6.26.0" + babel-types "^6.26.0" + esutils "^2.0.2" -"babel-helpers@^6.24.1": - "integrity" "sha1-NHHenK7DiOXIUOWX5Yom3fN2ArI=" - "resolved" "https://registry.yarnpkg.com/babel-helpers/-/babel-helpers-6.24.1.tgz" - "version" "6.24.1" +babel-helpers@^6.24.1: + version "6.24.1" + resolved "https://registry.yarnpkg.com/babel-helpers/-/babel-helpers-6.24.1.tgz" + integrity sha1-NHHenK7DiOXIUOWX5Yom3fN2ArI= dependencies: - "babel-runtime" "^6.22.0" - "babel-template" "^6.24.1" + babel-runtime "^6.22.0" + babel-template "^6.24.1" -"babel-messages@^6.23.0": - "integrity" "sha1-8830cDhYA1sqKVHG7F7fbGLyYw4=" - "resolved" "https://registry.yarnpkg.com/babel-messages/-/babel-messages-6.23.0.tgz" - "version" "6.23.0" +babel-messages@^6.23.0: + version "6.23.0" + resolved "https://registry.yarnpkg.com/babel-messages/-/babel-messages-6.23.0.tgz" + integrity sha1-8830cDhYA1sqKVHG7F7fbGLyYw4= dependencies: - "babel-runtime" "^6.22.0" + babel-runtime "^6.22.0" -"babel-plugin-syntax-jsx@^6.8.0": - "integrity" "sha1-CvMqmm4Tyno/1QaeYtew9Y0NiUY=" - "resolved" "https://registry.yarnpkg.com/babel-plugin-syntax-jsx/-/babel-plugin-syntax-jsx-6.18.0.tgz" - "version" "6.18.0" +babel-plugin-syntax-jsx@^6.8.0: + version "6.18.0" + resolved "https://registry.yarnpkg.com/babel-plugin-syntax-jsx/-/babel-plugin-syntax-jsx-6.18.0.tgz" + integrity sha1-CvMqmm4Tyno/1QaeYtew9Y0NiUY= -"babel-plugin-syntax-object-rest-spread@^6.8.0": - "integrity" "sha1-/WU28rzhODb/o6VFjEkDpZe7O/U=" - "resolved" "https://registry.yarnpkg.com/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz" - "version" "6.13.0" +babel-plugin-syntax-object-rest-spread@^6.8.0: + version "6.13.0" + resolved "https://registry.yarnpkg.com/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz" + integrity sha1-/WU28rzhODb/o6VFjEkDpZe7O/U= -"babel-plugin-transform-es2015-destructuring@^6.23.0": - "integrity" "sha1-mXux8auWf2gtKwh2/jWNYOdlxW0=" - "resolved" "https://registry.yarnpkg.com/babel-plugin-transform-es2015-destructuring/-/babel-plugin-transform-es2015-destructuring-6.23.0.tgz" - "version" "6.23.0" +babel-plugin-transform-es2015-destructuring@^6.23.0: + version "6.23.0" + resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-destructuring/-/babel-plugin-transform-es2015-destructuring-6.23.0.tgz" + integrity sha1-mXux8auWf2gtKwh2/jWNYOdlxW0= dependencies: - "babel-runtime" "^6.22.0" + babel-runtime "^6.22.0" -"babel-plugin-transform-object-rest-spread@^6.23.0": - "integrity" "sha1-DzZpLVD+9rfi1LOsFHgTepY7ewY=" - "resolved" "https://registry.yarnpkg.com/babel-plugin-transform-object-rest-spread/-/babel-plugin-transform-object-rest-spread-6.26.0.tgz" - "version" "6.26.0" +babel-plugin-transform-object-rest-spread@^6.23.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-plugin-transform-object-rest-spread/-/babel-plugin-transform-object-rest-spread-6.26.0.tgz" + integrity sha1-DzZpLVD+9rfi1LOsFHgTepY7ewY= dependencies: - "babel-plugin-syntax-object-rest-spread" "^6.8.0" - "babel-runtime" "^6.26.0" + babel-plugin-syntax-object-rest-spread "^6.8.0" + babel-runtime "^6.26.0" -"babel-plugin-transform-react-jsx@^6.24.1": - "integrity" "sha1-hAoCjn30YN/DotKfDA2R9jduZqM=" - "resolved" "https://registry.yarnpkg.com/babel-plugin-transform-react-jsx/-/babel-plugin-transform-react-jsx-6.24.1.tgz" - "version" "6.24.1" +babel-plugin-transform-react-jsx@^6.24.1: + version "6.24.1" + resolved "https://registry.yarnpkg.com/babel-plugin-transform-react-jsx/-/babel-plugin-transform-react-jsx-6.24.1.tgz" + integrity sha1-hAoCjn30YN/DotKfDA2R9jduZqM= dependencies: - "babel-helper-builder-react-jsx" "^6.24.1" - "babel-plugin-syntax-jsx" "^6.8.0" - "babel-runtime" "^6.22.0" + babel-helper-builder-react-jsx "^6.24.1" + babel-plugin-syntax-jsx "^6.8.0" + babel-runtime "^6.22.0" -"babel-register@^6.26.0": - "integrity" "sha1-btAhFz4vy0htestFxgCahW9kcHE=" - "resolved" "https://registry.yarnpkg.com/babel-register/-/babel-register-6.26.0.tgz" - "version" "6.26.0" +babel-register@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-register/-/babel-register-6.26.0.tgz" + integrity sha1-btAhFz4vy0htestFxgCahW9kcHE= dependencies: - "babel-core" "^6.26.0" - "babel-runtime" "^6.26.0" - "core-js" "^2.5.0" - "home-or-tmp" "^2.0.0" - "lodash" "^4.17.4" - "mkdirp" "^0.5.1" - "source-map-support" "^0.4.15" + babel-core "^6.26.0" + babel-runtime "^6.26.0" + core-js "^2.5.0" + home-or-tmp "^2.0.0" + lodash "^4.17.4" + mkdirp "^0.5.1" + source-map-support "^0.4.15" -"babel-runtime@^6.22.0", "babel-runtime@^6.26.0": - "integrity" "sha1-llxwWGaOgrVde/4E/yM3vItWR/4=" - "resolved" "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.26.0.tgz" - "version" "6.26.0" +babel-runtime@^6.22.0, babel-runtime@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.26.0.tgz" + integrity sha1-llxwWGaOgrVde/4E/yM3vItWR/4= dependencies: - "core-js" "^2.4.0" - "regenerator-runtime" "^0.11.0" + core-js "^2.4.0" + regenerator-runtime "^0.11.0" -"babel-template@^6.24.1", "babel-template@^6.26.0": - "integrity" "sha1-3gPi0WOWsGn0bdn/+FIfsaDjXgI=" - "resolved" "https://registry.yarnpkg.com/babel-template/-/babel-template-6.26.0.tgz" - "version" "6.26.0" +babel-template@^6.24.1, babel-template@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-template/-/babel-template-6.26.0.tgz" + integrity sha1-3gPi0WOWsGn0bdn/+FIfsaDjXgI= dependencies: - "babel-runtime" "^6.26.0" - "babel-traverse" "^6.26.0" - "babel-types" "^6.26.0" - "babylon" "^6.18.0" - "lodash" "^4.17.4" + babel-runtime "^6.26.0" + babel-traverse "^6.26.0" + babel-types "^6.26.0" + babylon "^6.18.0" + lodash "^4.17.4" -"babel-traverse@^6.26.0": - "integrity" "sha1-RqnL1+3MYsjlwGTi0tjQ9ANXZu4=" - "resolved" "https://registry.yarnpkg.com/babel-traverse/-/babel-traverse-6.26.0.tgz" - "version" "6.26.0" +babel-traverse@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-traverse/-/babel-traverse-6.26.0.tgz" + integrity sha1-RqnL1+3MYsjlwGTi0tjQ9ANXZu4= dependencies: - "babel-code-frame" "^6.26.0" - "babel-messages" "^6.23.0" - "babel-runtime" "^6.26.0" - "babel-types" "^6.26.0" - "babylon" "^6.18.0" - "debug" "^2.6.8" - "globals" "^9.18.0" - "invariant" "^2.2.2" - "lodash" "^4.17.4" + babel-code-frame "^6.26.0" + babel-messages "^6.23.0" + babel-runtime "^6.26.0" + babel-types "^6.26.0" + babylon "^6.18.0" + debug "^2.6.8" + globals "^9.18.0" + invariant "^2.2.2" + lodash "^4.17.4" -"babel-types@^6.26.0": - "integrity" "sha1-o7Bz+Uq0nrb6Vc1lInozQ4BjJJc=" - "resolved" "https://registry.yarnpkg.com/babel-types/-/babel-types-6.26.0.tgz" - "version" "6.26.0" +babel-types@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-types/-/babel-types-6.26.0.tgz" + integrity sha1-o7Bz+Uq0nrb6Vc1lInozQ4BjJJc= dependencies: - "babel-runtime" "^6.26.0" - "esutils" "^2.0.2" - "lodash" "^4.17.4" - "to-fast-properties" "^1.0.3" + babel-runtime "^6.26.0" + esutils "^2.0.2" + lodash "^4.17.4" + to-fast-properties "^1.0.3" -"babylon@^6.18.0": - "integrity" "sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ==" - "resolved" "https://registry.yarnpkg.com/babylon/-/babylon-6.18.0.tgz" - "version" "6.18.0" +babylon@^6.18.0: + version "6.18.0" + resolved "https://registry.yarnpkg.com/babylon/-/babylon-6.18.0.tgz" + integrity sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ== -"balanced-match@^1.0.0": - "integrity" "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" - "resolved" "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz" - "version" "1.0.0" +balanced-match@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz" + integrity sha1-ibTRmasr7kneFk6gK4nORi1xt2c= -"bcrypt-pbkdf@^1.0.0": - "integrity" "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=" - "resolved" "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz" - "version" "1.0.2" +bcrypt-pbkdf@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz" + integrity sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4= dependencies: - "tweetnacl" "^0.14.3" + tweetnacl "^0.14.3" -"binary-extensions@^2.0.0": - "integrity" "sha512-Phlt0plgpIIBOGTT/ehfFnbNlfsDEiqmzE2KRXoX1bLIlir4X/MR+zSyBEkL05ffWgnRSf/DXv+WrUAVr93/ow==" - "resolved" "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.0.0.tgz" - "version" "2.0.0" +binary-extensions@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.0.0.tgz" + integrity sha512-Phlt0plgpIIBOGTT/ehfFnbNlfsDEiqmzE2KRXoX1bLIlir4X/MR+zSyBEkL05ffWgnRSf/DXv+WrUAVr93/ow== -"bind-obj-methods@^2.0.0": - "integrity" "sha512-3/qRXczDi2Cdbz6jE+W3IflJOutRVica8frpBn14de1mBOkzDo+6tY33kNhvkw54Kn3PzRRD2VnGbGPcTAk4sw==" - "resolved" "https://registry.yarnpkg.com/bind-obj-methods/-/bind-obj-methods-2.0.0.tgz" - "version" "2.0.0" +bind-obj-methods@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/bind-obj-methods/-/bind-obj-methods-2.0.0.tgz" + integrity sha512-3/qRXczDi2Cdbz6jE+W3IflJOutRVica8frpBn14de1mBOkzDo+6tY33kNhvkw54Kn3PzRRD2VnGbGPcTAk4sw== -"brace-expansion@^1.1.7": - "integrity" "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==" - "resolved" "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz" - "version" "1.1.11" +brace-expansion@^1.1.7: + version "1.1.11" + resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz" + integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== dependencies: - "balanced-match" "^1.0.0" - "concat-map" "0.0.1" + balanced-match "^1.0.0" + concat-map "0.0.1" -"braces@~3.0.2": - "integrity" "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==" - "resolved" "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz" - "version" "3.0.2" +braces@~3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz" + integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== dependencies: - "fill-range" "^7.0.1" + fill-range "^7.0.1" -"browser-process-hrtime@^1.0.0": - "integrity" "sha512-9o5UecI3GhkpM6DrXr69PblIuWxPKk9Y0jHBRhdocZ2y7YECBFCsHm79Pr3OyR2AvjhDkabFJaDJMYRazHgsow==" - "resolved" "https://registry.yarnpkg.com/browser-process-hrtime/-/browser-process-hrtime-1.0.0.tgz" - "version" "1.0.0" +browser-process-hrtime@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/browser-process-hrtime/-/browser-process-hrtime-1.0.0.tgz" + integrity sha512-9o5UecI3GhkpM6DrXr69PblIuWxPKk9Y0jHBRhdocZ2y7YECBFCsHm79Pr3OyR2AvjhDkabFJaDJMYRazHgsow== -"buffer-from@^1.0.0": - "integrity" "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==" - "resolved" "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.1.tgz" - "version" "1.1.1" +buffer-from@^1.0.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.1.tgz" + integrity sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A== -"caching-transform@^3.0.2": - "integrity" "sha512-Mtgcv3lh3U0zRii/6qVgQODdPA4G3zhG+jtbCWj39RXuUFTMzH0vcdMtaJS1jPowd+It2Pqr6y3NJMQqOqCE2w==" - "resolved" "https://registry.yarnpkg.com/caching-transform/-/caching-transform-3.0.2.tgz" - "version" "3.0.2" +caching-transform@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/caching-transform/-/caching-transform-3.0.2.tgz" + integrity sha512-Mtgcv3lh3U0zRii/6qVgQODdPA4G3zhG+jtbCWj39RXuUFTMzH0vcdMtaJS1jPowd+It2Pqr6y3NJMQqOqCE2w== dependencies: - "hasha" "^3.0.0" - "make-dir" "^2.0.0" - "package-hash" "^3.0.0" - "write-file-atomic" "^2.4.2" + hasha "^3.0.0" + make-dir "^2.0.0" + package-hash "^3.0.0" + write-file-atomic "^2.4.2" -"caller-callsite@^2.0.0": - "integrity" "sha1-hH4PzgoiN1CpoCfFSzNzGtMVQTQ=" - "resolved" "https://registry.yarnpkg.com/caller-callsite/-/caller-callsite-2.0.0.tgz" - "version" "2.0.0" +caller-callsite@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/caller-callsite/-/caller-callsite-2.0.0.tgz" + integrity sha1-hH4PzgoiN1CpoCfFSzNzGtMVQTQ= dependencies: - "callsites" "^2.0.0" + callsites "^2.0.0" -"caller-path@^2.0.0": - "integrity" "sha1-Ro+DBE42mrIBD6xfBs7uFbsssfQ=" - "resolved" "https://registry.yarnpkg.com/caller-path/-/caller-path-2.0.0.tgz" - "version" "2.0.0" +caller-path@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/caller-path/-/caller-path-2.0.0.tgz" + integrity sha1-Ro+DBE42mrIBD6xfBs7uFbsssfQ= dependencies: - "caller-callsite" "^2.0.0" + caller-callsite "^2.0.0" -"callsites@^2.0.0": - "integrity" "sha1-BuuE8A7qQT2oav/vrL/7Ngk7PFA=" - "resolved" "https://registry.yarnpkg.com/callsites/-/callsites-2.0.0.tgz" - "version" "2.0.0" +callsites@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-2.0.0.tgz" + integrity sha1-BuuE8A7qQT2oav/vrL/7Ngk7PFA= -"camelcase@^5.0.0": - "integrity" "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==" - "resolved" "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz" - "version" "5.3.1" +camelcase@^5.0.0: + version "5.3.1" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz" + integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== -"cardinal@^2.1.1": - "integrity" "sha1-fMEFXYItISlU0HsIXeolHMe8VQU=" - "resolved" "https://registry.yarnpkg.com/cardinal/-/cardinal-2.1.1.tgz" - "version" "2.1.1" +cardinal@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/cardinal/-/cardinal-2.1.1.tgz" + integrity sha1-fMEFXYItISlU0HsIXeolHMe8VQU= dependencies: - "ansicolors" "~0.3.2" - "redeyed" "~2.1.0" + ansicolors "~0.3.2" + redeyed "~2.1.0" -"caseless@~0.12.0": - "integrity" "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=" - "resolved" "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz" - "version" "0.12.0" +caseless@~0.12.0: + version "0.12.0" + resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz" + integrity sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw= -"chalk@^1.1.3": - "integrity" "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=" - "resolved" "https://registry.yarnpkg.com/chalk/-/chalk-1.1.3.tgz" - "version" "1.1.3" +chalk@^1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-1.1.3.tgz" + integrity sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg= dependencies: - "ansi-styles" "^2.2.1" - "escape-string-regexp" "^1.0.2" - "has-ansi" "^2.0.0" - "strip-ansi" "^3.0.0" - "supports-color" "^2.0.0" + ansi-styles "^2.2.1" + escape-string-regexp "^1.0.2" + has-ansi "^2.0.0" + strip-ansi "^3.0.0" + supports-color "^2.0.0" -"chalk@^2.0.0", "chalk@^2.4.1", "chalk@^2.4.2": - "integrity" "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==" - "resolved" "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz" - "version" "2.4.2" +chalk@^2.0.0, chalk@^2.4.1, chalk@^2.4.2: + version "2.4.2" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz" + integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== dependencies: - "ansi-styles" "^3.2.1" - "escape-string-regexp" "^1.0.5" - "supports-color" "^5.3.0" + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" -"chokidar@^3.0.2": - "integrity" "sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A==" - "resolved" "https://registry.yarnpkg.com/chokidar/-/chokidar-3.3.0.tgz" - "version" "3.3.0" +chokidar@^3.0.2: + version "3.3.0" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.3.0.tgz" + integrity sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A== dependencies: - "anymatch" "~3.1.1" - "braces" "~3.0.2" - "glob-parent" "~5.1.0" - "is-binary-path" "~2.1.0" - "is-glob" "~4.0.1" - "normalize-path" "~3.0.0" - "readdirp" "~3.2.0" + anymatch "~3.1.1" + braces "~3.0.2" + glob-parent "~5.1.0" + is-binary-path "~2.1.0" + is-glob "~4.0.1" + normalize-path "~3.0.0" + readdirp "~3.2.0" optionalDependencies: - "fsevents" "~2.1.1" + fsevents "~2.1.1" -"ci-info@^2.0.0": - "integrity" "sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ==" - "resolved" "https://registry.yarnpkg.com/ci-info/-/ci-info-2.0.0.tgz" - "version" "2.0.0" +ci-info@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-2.0.0.tgz" + integrity sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ== -"cli-cursor@^2.1.0": - "integrity" "sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU=" - "resolved" "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz" - "version" "2.1.0" +cli-cursor@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz" + integrity sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU= dependencies: - "restore-cursor" "^2.0.0" + restore-cursor "^2.0.0" -"cli-truncate@^1.1.0": - "integrity" "sha512-bAtZo0u82gCfaAGfSNxUdTI9mNyza7D8w4CVCcaOsy7sgwDzvx6ekr6cuWJqY3UGzgnQ1+4wgENup5eIhgxEYA==" - "resolved" "https://registry.yarnpkg.com/cli-truncate/-/cli-truncate-1.1.0.tgz" - "version" "1.1.0" +cli-truncate@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/cli-truncate/-/cli-truncate-1.1.0.tgz" + integrity sha512-bAtZo0u82gCfaAGfSNxUdTI9mNyza7D8w4CVCcaOsy7sgwDzvx6ekr6cuWJqY3UGzgnQ1+4wgENup5eIhgxEYA== dependencies: - "slice-ansi" "^1.0.0" - "string-width" "^2.0.0" + slice-ansi "^1.0.0" + string-width "^2.0.0" -"cliui@^4.1.0": - "integrity" "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==" - "resolved" "https://registry.yarnpkg.com/cliui/-/cliui-4.1.0.tgz" - "version" "4.1.0" +cliui@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-4.1.0.tgz" + integrity sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ== dependencies: - "string-width" "^2.1.1" - "strip-ansi" "^4.0.0" - "wrap-ansi" "^2.0.0" + string-width "^2.1.1" + strip-ansi "^4.0.0" + wrap-ansi "^2.0.0" -"cliui@^5.0.0": - "integrity" "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==" - "resolved" "https://registry.yarnpkg.com/cliui/-/cliui-5.0.0.tgz" - "version" "5.0.0" +cliui@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-5.0.0.tgz" + integrity sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA== dependencies: - "string-width" "^3.1.0" - "strip-ansi" "^5.2.0" - "wrap-ansi" "^5.1.0" + string-width "^3.1.0" + strip-ansi "^5.2.0" + wrap-ansi "^5.1.0" -"code-point-at@^1.0.0": - "integrity" "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=" - "resolved" "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz" - "version" "1.1.0" +code-point-at@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz" + integrity sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c= -"color-convert@^1.9.0": - "integrity" "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==" - "resolved" "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz" - "version" "1.9.3" +color-convert@^1.9.0: + version "1.9.3" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz" + integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== dependencies: - "color-name" "1.1.3" + color-name "1.1.3" -"color-name@1.1.3": - "integrity" "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=" - "resolved" "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz" - "version" "1.1.3" +color-name@1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz" + integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= -"color-support@^1.1.0": - "integrity" "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg==" - "resolved" "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz" - "version" "1.1.3" +color-support@^1.1.0: + version "1.1.3" + resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz" + integrity sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg== -"combined-stream@^1.0.6", "combined-stream@~1.0.6": - "integrity" "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==" - "resolved" "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz" - "version" "1.0.8" +combined-stream@^1.0.6, combined-stream@~1.0.6: + version "1.0.8" + resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz" + integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== dependencies: - "delayed-stream" "~1.0.0" + delayed-stream "~1.0.0" -"commander@~2.20.0": - "integrity" "sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ==" - "resolved" "https://registry.yarnpkg.com/commander/-/commander-2.20.0.tgz" - "version" "2.20.0" +commander@~2.20.0: + version "2.20.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.0.tgz" + integrity sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ== -"commondir@^1.0.1": - "integrity" "sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs=" - "resolved" "https://registry.yarnpkg.com/commondir/-/commondir-1.0.1.tgz" - "version" "1.0.1" +commondir@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/commondir/-/commondir-1.0.1.tgz" + integrity sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs= -"concat-map@0.0.1": - "integrity" "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" - "resolved" "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz" - "version" "0.0.1" +concat-map@0.0.1: + version "0.0.1" + resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz" + integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= -"convert-source-map@^1.5.1", "convert-source-map@^1.6.0": - "integrity" "sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A==" - "resolved" "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.6.0.tgz" - "version" "1.6.0" +convert-source-map@^1.5.1, convert-source-map@^1.6.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.6.0.tgz" + integrity sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A== dependencies: - "safe-buffer" "~5.1.1" + safe-buffer "~5.1.1" -"core-js@^2.4.0", "core-js@^2.5.0": - "integrity" "sha512-HOpZf6eXmnl7la+cUdMnLvUxKNqLUzJvgIziQ0DiF3JwSImNphIqdGqzj6hIKyX04MmV0poclQ7+wjWvxQyR2A==" - "resolved" "https://registry.yarnpkg.com/core-js/-/core-js-2.6.9.tgz" - "version" "2.6.9" +core-js@^2.4.0, core-js@^2.5.0: + version "2.6.9" + resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.6.9.tgz" + integrity sha512-HOpZf6eXmnl7la+cUdMnLvUxKNqLUzJvgIziQ0DiF3JwSImNphIqdGqzj6hIKyX04MmV0poclQ7+wjWvxQyR2A== -"core-util-is@~1.0.0", "core-util-is@1.0.2": - "integrity" "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" - "resolved" "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz" - "version" "1.0.2" +core-util-is@~1.0.0, core-util-is@1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz" + integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= -"coveralls@^3.0.6": - "integrity" "sha512-mUuH2MFOYB2oBaA4D4Ykqi9LaEYpMMlsiOMJOrv358yAjP6enPIk55fod2fNJ8AvwoYXStWQls37rA+s5e7boA==" - "resolved" "https://registry.yarnpkg.com/coveralls/-/coveralls-3.0.7.tgz" - "version" "3.0.7" +coveralls@^3.0.6: + version "3.0.7" + resolved "https://registry.yarnpkg.com/coveralls/-/coveralls-3.0.7.tgz" + integrity sha512-mUuH2MFOYB2oBaA4D4Ykqi9LaEYpMMlsiOMJOrv358yAjP6enPIk55fod2fNJ8AvwoYXStWQls37rA+s5e7boA== dependencies: - "growl" "~>1.10.0" - "js-yaml" "^3.13.1" - "lcov-parse" "^0.0.10" - "log-driver" "^1.2.7" - "minimist" "^1.2.0" - "request" "^2.86.0" + growl "~>1.10.0" + js-yaml "^3.13.1" + lcov-parse "^0.0.10" + log-driver "^1.2.7" + minimist "^1.2.0" + request "^2.86.0" -"cp-file@^6.2.0": - "integrity" "sha512-fmvV4caBnofhPe8kOcitBwSn2f39QLjnAnGq3gO9dfd75mUytzKNZB1hde6QHunW2Rt+OwuBOMc3i1tNElbszA==" - "resolved" "https://registry.yarnpkg.com/cp-file/-/cp-file-6.2.0.tgz" - "version" "6.2.0" +cp-file@^6.2.0: + version "6.2.0" + resolved "https://registry.yarnpkg.com/cp-file/-/cp-file-6.2.0.tgz" + integrity sha512-fmvV4caBnofhPe8kOcitBwSn2f39QLjnAnGq3gO9dfd75mUytzKNZB1hde6QHunW2Rt+OwuBOMc3i1tNElbszA== dependencies: - "graceful-fs" "^4.1.2" - "make-dir" "^2.0.0" - "nested-error-stacks" "^2.0.0" - "pify" "^4.0.1" - "safe-buffer" "^5.0.1" + graceful-fs "^4.1.2" + make-dir "^2.0.0" + nested-error-stacks "^2.0.0" + pify "^4.0.1" + safe-buffer "^5.0.1" -"cross-spawn@^4": - "integrity" "sha1-e5JHYhwjrf3ThWAEqCPL45dCTUE=" - "resolved" "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-4.0.2.tgz" - "version" "4.0.2" +cross-spawn@^4: + version "4.0.2" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-4.0.2.tgz" + integrity sha1-e5JHYhwjrf3ThWAEqCPL45dCTUE= dependencies: - "lru-cache" "^4.0.1" - "which" "^1.2.9" + lru-cache "^4.0.1" + which "^1.2.9" -"cross-spawn@^6.0.0", "cross-spawn@^6.0.5": - "integrity" "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==" - "resolved" "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz" - "version" "6.0.5" +cross-spawn@^6.0.0, cross-spawn@^6.0.5: + version "6.0.5" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz" + integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== dependencies: - "nice-try" "^1.0.4" - "path-key" "^2.0.1" - "semver" "^5.5.0" - "shebang-command" "^1.2.0" - "which" "^1.2.9" + nice-try "^1.0.4" + path-key "^2.0.1" + semver "^5.5.0" + shebang-command "^1.2.0" + which "^1.2.9" -"csstype@^2.2.0": - "integrity" "sha512-RpFbQGUE74iyPgvr46U9t1xoQBM8T4BL8SxrN66Le2xYAPSaDJJKeztV3awugusb3g3G9iL8StmkBBXhcbbXhg==" - "resolved" "https://registry.yarnpkg.com/csstype/-/csstype-2.6.6.tgz" - "version" "2.6.6" +csstype@^2.2.0: + version "2.6.6" + resolved "https://registry.yarnpkg.com/csstype/-/csstype-2.6.6.tgz" + integrity sha512-RpFbQGUE74iyPgvr46U9t1xoQBM8T4BL8SxrN66Le2xYAPSaDJJKeztV3awugusb3g3G9iL8StmkBBXhcbbXhg== -"dashdash@^1.12.0": - "integrity" "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=" - "resolved" "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz" - "version" "1.14.1" +dashdash@^1.12.0: + version "1.14.1" + resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz" + integrity sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA= dependencies: - "assert-plus" "^1.0.0" + assert-plus "^1.0.0" -"debug@^2.1.3", "debug@^2.6.8", "debug@^2.6.9": - "integrity" "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==" - "resolved" "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz" - "version" "2.6.9" +debug@^2.1.3, debug@^2.6.8, debug@^2.6.9: + version "2.6.9" + resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz" + integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== dependencies: - "ms" "2.0.0" + ms "2.0.0" -"debug@^4.1.0", "debug@^4.1.1": - "integrity" "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==" - "resolved" "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz" - "version" "4.1.1" +debug@^4.1.0, debug@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz" + integrity sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw== dependencies: - "ms" "^2.1.1" + ms "^2.1.1" -"decamelize@^1.2.0": - "integrity" "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=" - "resolved" "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz" - "version" "1.2.0" +decamelize@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz" + integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= -"default-require-extensions@^2.0.0": - "integrity" "sha1-9fj7sYp9bVCyH2QfZJ67Uiz+JPc=" - "resolved" "https://registry.yarnpkg.com/default-require-extensions/-/default-require-extensions-2.0.0.tgz" - "version" "2.0.0" +default-require-extensions@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/default-require-extensions/-/default-require-extensions-2.0.0.tgz" + integrity sha1-9fj7sYp9bVCyH2QfZJ67Uiz+JPc= dependencies: - "strip-bom" "^3.0.0" + strip-bom "^3.0.0" -"delayed-stream@~1.0.0": - "integrity" "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=" - "resolved" "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz" - "version" "1.0.0" +delayed-stream@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz" + integrity sha1-3zrhmayt+31ECqrgsp4icrJOxhk= -"detect-indent@^4.0.0": - "integrity" "sha1-920GQ1LN9Docts5hnE7jqUdd4gg=" - "resolved" "https://registry.yarnpkg.com/detect-indent/-/detect-indent-4.0.0.tgz" - "version" "4.0.0" +detect-indent@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/detect-indent/-/detect-indent-4.0.0.tgz" + integrity sha1-920GQ1LN9Docts5hnE7jqUdd4gg= dependencies: - "repeating" "^2.0.0" + repeating "^2.0.0" -"diff@^1.3.2": - "integrity" "sha1-fyjS657nsVqX79ic5j3P2qPMur8=" - "resolved" "https://registry.yarnpkg.com/diff/-/diff-1.4.0.tgz" - "version" "1.4.0" +diff@^1.3.2: + version "1.4.0" + resolved "https://registry.yarnpkg.com/diff/-/diff-1.4.0.tgz" + integrity sha1-fyjS657nsVqX79ic5j3P2qPMur8= -"diff@^4.0.1": - "integrity" "sha512-s2+XdvhPCOF01LRQBC8hf4vhbVmI2CGS5aZnxLJlT5FtdhPCDFq80q++zK2KlrVorVDdL5BOGZ/VfLrVtYNF+Q==" - "resolved" "https://registry.yarnpkg.com/diff/-/diff-4.0.1.tgz" - "version" "4.0.1" +diff@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/diff/-/diff-4.0.1.tgz" + integrity sha512-s2+XdvhPCOF01LRQBC8hf4vhbVmI2CGS5aZnxLJlT5FtdhPCDFq80q++zK2KlrVorVDdL5BOGZ/VfLrVtYNF+Q== -"ecc-jsbn@~0.1.1": - "integrity" "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=" - "resolved" "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz" - "version" "0.1.2" +ecc-jsbn@~0.1.1: + version "0.1.2" + resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz" + integrity sha1-OoOpBOVDUyh4dMVkt1SThoSamMk= dependencies: - "jsbn" "~0.1.0" - "safer-buffer" "^2.1.0" + jsbn "~0.1.0" + safer-buffer "^2.1.0" -"emoji-regex@^7.0.1": - "integrity" "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==" - "resolved" "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-7.0.3.tgz" - "version" "7.0.3" +emoji-regex@^7.0.1: + version "7.0.3" + resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-7.0.3.tgz" + integrity sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA== -"end-of-stream@^1.1.0": - "integrity" "sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q==" - "resolved" "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.1.tgz" - "version" "1.4.1" +end-of-stream@^1.1.0: + version "1.4.1" + resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.1.tgz" + integrity sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q== dependencies: - "once" "^1.4.0" + once "^1.4.0" -"error-ex@^1.3.1": - "integrity" "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==" - "resolved" "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz" - "version" "1.3.2" +error-ex@^1.3.1: + version "1.3.2" + resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz" + integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== dependencies: - "is-arrayish" "^0.2.1" + is-arrayish "^0.2.1" -"es6-error@^4.0.1": - "integrity" "sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg==" - "resolved" "https://registry.yarnpkg.com/es6-error/-/es6-error-4.1.1.tgz" - "version" "4.1.1" +es6-error@^4.0.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/es6-error/-/es6-error-4.1.1.tgz" + integrity sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg== -"escape-string-regexp@^1.0.2", "escape-string-regexp@^1.0.3", "escape-string-regexp@^1.0.5": - "integrity" "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=" - "resolved" "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" - "version" "1.0.5" +escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.3, escape-string-regexp@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" + integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= -"esm@^3.2.25": - "integrity" "sha512-U1suiZ2oDVWv4zPO56S0NcR5QriEahGtdN2OR6FiOG4WJvcjBVFB0qI4+eKoWFH483PKGuLuu6V8Z4T5g63UVA==" - "resolved" "https://registry.yarnpkg.com/esm/-/esm-3.2.25.tgz" - "version" "3.2.25" +esm@^3.2.25: + version "3.2.25" + resolved "https://registry.yarnpkg.com/esm/-/esm-3.2.25.tgz" + integrity sha512-U1suiZ2oDVWv4zPO56S0NcR5QriEahGtdN2OR6FiOG4WJvcjBVFB0qI4+eKoWFH483PKGuLuu6V8Z4T5g63UVA== -"esprima@^4.0.0", "esprima@~4.0.0": - "integrity" "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==" - "resolved" "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz" - "version" "4.0.1" +esprima@^4.0.0, esprima@~4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz" + integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== -"esutils@^2.0.2": - "integrity" "sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs=" - "resolved" "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz" - "version" "2.0.2" +esutils@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz" + integrity sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs= -"events-to-array@^1.0.1": - "integrity" "sha1-LUH1Y+H+QA7Uli/hpNXGp1Od9/Y=" - "resolved" "https://registry.yarnpkg.com/events-to-array/-/events-to-array-1.1.2.tgz" - "version" "1.1.2" +events-to-array@^1.0.1: + version "1.1.2" + resolved "https://registry.yarnpkg.com/events-to-array/-/events-to-array-1.1.2.tgz" + integrity sha1-LUH1Y+H+QA7Uli/hpNXGp1Od9/Y= -"execa@^1.0.0": - "integrity" "sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==" - "resolved" "https://registry.yarnpkg.com/execa/-/execa-1.0.0.tgz" - "version" "1.0.0" +execa@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/execa/-/execa-1.0.0.tgz" + integrity sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA== dependencies: - "cross-spawn" "^6.0.0" - "get-stream" "^4.0.0" - "is-stream" "^1.1.0" - "npm-run-path" "^2.0.0" - "p-finally" "^1.0.0" - "signal-exit" "^3.0.0" - "strip-eof" "^1.0.0" + cross-spawn "^6.0.0" + get-stream "^4.0.0" + is-stream "^1.1.0" + npm-run-path "^2.0.0" + p-finally "^1.0.0" + signal-exit "^3.0.0" + strip-eof "^1.0.0" -"extend@~3.0.2": - "integrity" "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==" - "resolved" "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz" - "version" "3.0.2" +extend@~3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz" + integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g== -"extsprintf@^1.2.0": - "integrity" "sha1-4mifjzVvrWLMplo6kcXfX5VRaS8=" - "resolved" "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.4.0.tgz" - "version" "1.4.0" +extsprintf@^1.2.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.4.0.tgz" + integrity sha1-4mifjzVvrWLMplo6kcXfX5VRaS8= -"extsprintf@1.3.0": - "integrity" "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=" - "resolved" "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz" - "version" "1.3.0" +extsprintf@1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz" + integrity sha1-lpGEQOMEGnpBT4xS48V06zw+HgU= -"fast-deep-equal@^2.0.1": - "integrity" "sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk=" - "resolved" "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz" - "version" "2.0.1" +fast-deep-equal@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz" + integrity sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk= -"fast-json-stable-stringify@^2.0.0": - "integrity" "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=" - "resolved" "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz" - "version" "2.0.0" +fast-json-stable-stringify@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz" + integrity sha1-1RQsDK7msRifh9OnYREGT4bIu/I= -"fill-range@^7.0.1": - "integrity" "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==" - "resolved" "https://registry.yarnpkg.com/fill-range/-/fill-range-7.0.1.tgz" - "version" "7.0.1" +fill-range@^7.0.1: + version "7.0.1" + resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.0.1.tgz" + integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ== dependencies: - "to-regex-range" "^5.0.1" + to-regex-range "^5.0.1" -"find-cache-dir@^2.1.0": - "integrity" "sha512-Tq6PixE0w/VMFfCgbONnkiQIVol/JJL7nRMi20fqzA4NRs9AfeqMGeRdPi3wIhYkxjeBaWh2rxwapn5Tu3IqOQ==" - "resolved" "https://registry.yarnpkg.com/find-cache-dir/-/find-cache-dir-2.1.0.tgz" - "version" "2.1.0" +find-cache-dir@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/find-cache-dir/-/find-cache-dir-2.1.0.tgz" + integrity sha512-Tq6PixE0w/VMFfCgbONnkiQIVol/JJL7nRMi20fqzA4NRs9AfeqMGeRdPi3wIhYkxjeBaWh2rxwapn5Tu3IqOQ== dependencies: - "commondir" "^1.0.1" - "make-dir" "^2.0.0" - "pkg-dir" "^3.0.0" + commondir "^1.0.1" + make-dir "^2.0.0" + pkg-dir "^3.0.0" -"find-up@^3.0.0": - "integrity" "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==" - "resolved" "https://registry.yarnpkg.com/find-up/-/find-up-3.0.0.tgz" - "version" "3.0.0" +find-up@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-3.0.0.tgz" + integrity sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg== dependencies: - "locate-path" "^3.0.0" + locate-path "^3.0.0" -"findit@^2.0.0": - "integrity" "sha1-ZQnwEmr0wXhVHPqZOU4DLhOk1W4=" - "resolved" "https://registry.yarnpkg.com/findit/-/findit-2.0.0.tgz" - "version" "2.0.0" +findit@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/findit/-/findit-2.0.0.tgz" + integrity sha1-ZQnwEmr0wXhVHPqZOU4DLhOk1W4= -"flow-parser@^0.112.0": - "integrity" "sha512-sxjnwhR76B/fUN6n/XerYzn8R1HvtVo3SM8Il3WiZ4nkAlb2BBzKe1TSVKGSyZgD6FW9Bsxom/57ktkqrqmXGA==" - "resolved" "https://registry.yarnpkg.com/flow-parser/-/flow-parser-0.112.0.tgz" - "version" "0.112.0" +flow-parser@^0.112.0: + version "0.112.0" + resolved "https://registry.yarnpkg.com/flow-parser/-/flow-parser-0.112.0.tgz" + integrity sha512-sxjnwhR76B/fUN6n/XerYzn8R1HvtVo3SM8Il3WiZ4nkAlb2BBzKe1TSVKGSyZgD6FW9Bsxom/57ktkqrqmXGA== -"flow-remove-types@^2.107.0": - "integrity" "sha512-h3bwcfh41nR9kvlhZFr5ySGmzzOyG4VUsnN4OBl9R6anbWAiX4H5lPhKTwZ7AelWF8Rtqmw/Vnq+VLEMg7PdAw==" - "resolved" "https://registry.yarnpkg.com/flow-remove-types/-/flow-remove-types-2.112.0.tgz" - "version" "2.112.0" +flow-remove-types@^2.107.0: + version "2.112.0" + resolved "https://registry.yarnpkg.com/flow-remove-types/-/flow-remove-types-2.112.0.tgz" + integrity sha512-h3bwcfh41nR9kvlhZFr5ySGmzzOyG4VUsnN4OBl9R6anbWAiX4H5lPhKTwZ7AelWF8Rtqmw/Vnq+VLEMg7PdAw== dependencies: - "flow-parser" "^0.112.0" - "pirates" "^3.0.2" - "vlq" "^0.2.1" + flow-parser "^0.112.0" + pirates "^3.0.2" + vlq "^0.2.1" -"foreground-child@^1.3.3", "foreground-child@^1.5.6": - "integrity" "sha1-T9ca0t/elnibmApcCilZN8svXOk=" - "resolved" "https://registry.yarnpkg.com/foreground-child/-/foreground-child-1.5.6.tgz" - "version" "1.5.6" +foreground-child@^1.3.3, foreground-child@^1.5.6: + version "1.5.6" + resolved "https://registry.yarnpkg.com/foreground-child/-/foreground-child-1.5.6.tgz" + integrity sha1-T9ca0t/elnibmApcCilZN8svXOk= dependencies: - "cross-spawn" "^4" - "signal-exit" "^3.0.0" + cross-spawn "^4" + signal-exit "^3.0.0" -"forever-agent@~0.6.1": - "integrity" "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=" - "resolved" "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz" - "version" "0.6.1" +forever-agent@~0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz" + integrity sha1-+8cfDEGt6zf5bFd60e1C2P2sypE= -"form-data@~2.3.2": - "integrity" "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==" - "resolved" "https://registry.yarnpkg.com/form-data/-/form-data-2.3.3.tgz" - "version" "2.3.3" +form-data@~2.3.2: + version "2.3.3" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.3.tgz" + integrity sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ== dependencies: - "asynckit" "^0.4.0" - "combined-stream" "^1.0.6" - "mime-types" "^2.1.12" + asynckit "^0.4.0" + combined-stream "^1.0.6" + mime-types "^2.1.12" -"fs-exists-cached@^1.0.0": - "integrity" "sha1-zyVVTKBQ3EmuZla0HeQiWJidy84=" - "resolved" "https://registry.yarnpkg.com/fs-exists-cached/-/fs-exists-cached-1.0.0.tgz" - "version" "1.0.0" +fs-exists-cached@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/fs-exists-cached/-/fs-exists-cached-1.0.0.tgz" + integrity sha1-zyVVTKBQ3EmuZla0HeQiWJidy84= -"fs.realpath@^1.0.0": - "integrity" "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" - "resolved" "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz" - "version" "1.0.0" +fs.realpath@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz" + integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= -"fsevents@~2.1.1": - "integrity" "sha512-R4wDiBwZ0KzpgOWetKDug1FZcYhqYnUYKtfZYt4mD5SBz76q0KR4Q9o7GIPamsVPGmW3EYPPJ0dOOjvx32ldZA==" - "resolved" "https://registry.yarnpkg.com/fsevents/-/fsevents-2.1.2.tgz" - "version" "2.1.2" +fsevents@~2.1.1: + version "2.1.2" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.1.2.tgz" + integrity sha512-R4wDiBwZ0KzpgOWetKDug1FZcYhqYnUYKtfZYt4mD5SBz76q0KR4Q9o7GIPamsVPGmW3EYPPJ0dOOjvx32ldZA== -"function-loop@^1.0.2": - "integrity" "sha512-Iw4MzMfS3udk/rqxTiDDCllhGwlOrsr50zViTOO/W6lS/9y6B1J0BD2VZzrnWUYBJsl3aeqjgR5v7bWWhZSYbA==" - "resolved" "https://registry.yarnpkg.com/function-loop/-/function-loop-1.0.2.tgz" - "version" "1.0.2" +function-loop@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/function-loop/-/function-loop-1.0.2.tgz" + integrity sha512-Iw4MzMfS3udk/rqxTiDDCllhGwlOrsr50zViTOO/W6lS/9y6B1J0BD2VZzrnWUYBJsl3aeqjgR5v7bWWhZSYbA== -"get-caller-file@^2.0.1": - "integrity" "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==" - "resolved" "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz" - "version" "2.0.5" +get-caller-file@^2.0.1: + version "2.0.5" + resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz" + integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== -"get-stream@^4.0.0": - "integrity" "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==" - "resolved" "https://registry.yarnpkg.com/get-stream/-/get-stream-4.1.0.tgz" - "version" "4.1.0" +get-stream@^4.0.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-4.1.0.tgz" + integrity sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w== dependencies: - "pump" "^3.0.0" + pump "^3.0.0" -"getpass@^0.1.1": - "integrity" "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=" - "resolved" "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz" - "version" "0.1.7" +getpass@^0.1.1: + version "0.1.7" + resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz" + integrity sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo= dependencies: - "assert-plus" "^1.0.0" + assert-plus "^1.0.0" -"glob-parent@~5.1.0": - "integrity" "sha512-qjtRgnIVmOfnKUE3NJAQEdk+lKrxfw8t5ke7SXtfMTHcjsBfOfWXCQfdb30zfDoZQ2IRSIiidmjtbHZPZ++Ihw==" - "resolved" "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.0.tgz" - "version" "5.1.0" +glob-parent@~5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.0.tgz" + integrity sha512-qjtRgnIVmOfnKUE3NJAQEdk+lKrxfw8t5ke7SXtfMTHcjsBfOfWXCQfdb30zfDoZQ2IRSIiidmjtbHZPZ++Ihw== dependencies: - "is-glob" "^4.0.1" + is-glob "^4.0.1" -"glob@^7.0.5", "glob@^7.1.3", "glob@^7.1.4": - "integrity" "sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A==" - "resolved" "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz" - "version" "7.1.4" +glob@^7.0.5, glob@^7.1.3, glob@^7.1.4: + version "7.1.4" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz" + integrity sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A== dependencies: - "fs.realpath" "^1.0.0" - "inflight" "^1.0.4" - "inherits" "2" - "minimatch" "^3.0.4" - "once" "^1.3.0" - "path-is-absolute" "^1.0.0" + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" -"globals@^11.1.0": - "integrity" "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==" - "resolved" "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz" - "version" "11.12.0" +globals@^11.1.0: + version "11.12.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz" + integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== -"globals@^9.18.0": - "integrity" "sha512-S0nG3CLEQiY/ILxqtztTWH/3iRRdyBLw6KMDxnKMchrtbj2OFmehVh0WUCfW3DUrIgx/qFrJPICrq4Z4sTR9UQ==" - "resolved" "https://registry.yarnpkg.com/globals/-/globals-9.18.0.tgz" - "version" "9.18.0" +globals@^9.18.0: + version "9.18.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-9.18.0.tgz" + integrity sha512-S0nG3CLEQiY/ILxqtztTWH/3iRRdyBLw6KMDxnKMchrtbj2OFmehVh0WUCfW3DUrIgx/qFrJPICrq4Z4sTR9UQ== -"graceful-fs@^4.1.11", "graceful-fs@^4.1.15", "graceful-fs@^4.1.2": - "integrity" "sha512-jpSvDPV4Cq/bgtpndIWbI5hmYxhQGHPC4d4cqBPb4DLniCfhJokdXhwhaDuLBGLQdvvRum/UiX6ECVIPvDXqdg==" - "resolved" "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.0.tgz" - "version" "4.2.0" +graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1.2: + version "4.2.0" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.0.tgz" + integrity sha512-jpSvDPV4Cq/bgtpndIWbI5hmYxhQGHPC4d4cqBPb4DLniCfhJokdXhwhaDuLBGLQdvvRum/UiX6ECVIPvDXqdg== "growl@~> 1.10.0": - "integrity" "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==" - "resolved" "https://registry.yarnpkg.com/growl/-/growl-1.10.5.tgz" - "version" "1.10.5" + version "1.10.5" + resolved "https://registry.yarnpkg.com/growl/-/growl-1.10.5.tgz" + integrity sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA== -"handlebars@^4.1.2": - "integrity" "sha512-nvfrjqvt9xQ8Z/w0ijewdD/vvWDTOweBUm96NTr66Wfvo1mJenBLwcYmPs3TIBP5ruzYGD7Hx/DaM9RmhroGPw==" - "resolved" "https://registry.yarnpkg.com/handlebars/-/handlebars-4.1.2.tgz" - "version" "4.1.2" +handlebars@^4.1.2: + version "4.1.2" + resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.1.2.tgz" + integrity sha512-nvfrjqvt9xQ8Z/w0ijewdD/vvWDTOweBUm96NTr66Wfvo1mJenBLwcYmPs3TIBP5ruzYGD7Hx/DaM9RmhroGPw== dependencies: - "neo-async" "^2.6.0" - "optimist" "^0.6.1" - "source-map" "^0.6.1" + neo-async "^2.6.0" + optimist "^0.6.1" + source-map "^0.6.1" optionalDependencies: - "uglify-js" "^3.1.4" + uglify-js "^3.1.4" -"har-schema@^2.0.0": - "integrity" "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=" - "resolved" "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz" - "version" "2.0.0" +har-schema@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz" + integrity sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI= -"har-validator@~5.1.0": - "integrity" "sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g==" - "resolved" "https://registry.yarnpkg.com/har-validator/-/har-validator-5.1.3.tgz" - "version" "5.1.3" +har-validator@~5.1.0: + version "5.1.3" + resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.1.3.tgz" + integrity sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g== dependencies: - "ajv" "^6.5.5" - "har-schema" "^2.0.0" + ajv "^6.5.5" + har-schema "^2.0.0" -"has-ansi@^2.0.0": - "integrity" "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=" - "resolved" "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz" - "version" "2.0.0" +has-ansi@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz" + integrity sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE= dependencies: - "ansi-regex" "^2.0.0" + ansi-regex "^2.0.0" -"has-flag@^3.0.0": - "integrity" "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=" - "resolved" "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz" - "version" "3.0.0" +has-flag@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz" + integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= -"hasha@^3.0.0": - "integrity" "sha1-UqMvq4Vp1BymmmH/GiFPjrfIvTk=" - "resolved" "https://registry.yarnpkg.com/hasha/-/hasha-3.0.0.tgz" - "version" "3.0.0" +hasha@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/hasha/-/hasha-3.0.0.tgz" + integrity sha1-UqMvq4Vp1BymmmH/GiFPjrfIvTk= dependencies: - "is-stream" "^1.0.1" + is-stream "^1.0.1" -"home-or-tmp@^2.0.0": - "integrity" "sha1-42w/LSyufXRqhX440Y1fMqeILbg=" - "resolved" "https://registry.yarnpkg.com/home-or-tmp/-/home-or-tmp-2.0.0.tgz" - "version" "2.0.0" +home-or-tmp@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/home-or-tmp/-/home-or-tmp-2.0.0.tgz" + integrity sha1-42w/LSyufXRqhX440Y1fMqeILbg= dependencies: - "os-homedir" "^1.0.0" - "os-tmpdir" "^1.0.1" + os-homedir "^1.0.0" + os-tmpdir "^1.0.1" -"hosted-git-info@^2.1.4": - "integrity" "sha512-7T/BxH19zbcCTa8XkMlbK5lTo1WtgkFi3GvdWEyNuc4Vex7/9Dqbnpsf4JMydcfj9HCg4zUWFTL3Za6lapg5/w==" - "resolved" "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.7.1.tgz" - "version" "2.7.1" +hosted-git-info@^2.1.4: + version "2.7.1" + resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.7.1.tgz" + integrity sha512-7T/BxH19zbcCTa8XkMlbK5lTo1WtgkFi3GvdWEyNuc4Vex7/9Dqbnpsf4JMydcfj9HCg4zUWFTL3Za6lapg5/w== -"http-signature@~1.2.0": - "integrity" "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=" - "resolved" "https://registry.yarnpkg.com/http-signature/-/http-signature-1.2.0.tgz" - "version" "1.2.0" +http-signature@~1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.2.0.tgz" + integrity sha1-muzZJRFHcvPZW2WmCruPfBj7rOE= dependencies: - "assert-plus" "^1.0.0" - "jsprim" "^1.2.2" - "sshpk" "^1.7.0" + assert-plus "^1.0.0" + jsprim "^1.2.2" + sshpk "^1.7.0" -"import-jsx@^2.0.0": - "integrity" "sha512-xmrgtiRnAdjIaRzKwsHut54FA8nx59WqN4MpQvPFr/8yD6BamavkmKHrA5dotAlnIiF4uqMzg/lA5yhPdpIXsA==" - "resolved" "https://registry.yarnpkg.com/import-jsx/-/import-jsx-2.0.0.tgz" - "version" "2.0.0" +import-jsx@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/import-jsx/-/import-jsx-2.0.0.tgz" + integrity sha512-xmrgtiRnAdjIaRzKwsHut54FA8nx59WqN4MpQvPFr/8yD6BamavkmKHrA5dotAlnIiF4uqMzg/lA5yhPdpIXsA== dependencies: - "babel-core" "^6.25.0" - "babel-plugin-transform-es2015-destructuring" "^6.23.0" - "babel-plugin-transform-object-rest-spread" "^6.23.0" - "babel-plugin-transform-react-jsx" "^6.24.1" - "caller-path" "^2.0.0" - "resolve-from" "^3.0.0" + babel-core "^6.25.0" + babel-plugin-transform-es2015-destructuring "^6.23.0" + babel-plugin-transform-object-rest-spread "^6.23.0" + babel-plugin-transform-react-jsx "^6.24.1" + caller-path "^2.0.0" + resolve-from "^3.0.0" -"imurmurhash@^0.1.4": - "integrity" "sha1-khi5srkoojixPcT7a21XbyMUU+o=" - "resolved" "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz" - "version" "0.1.4" +imurmurhash@^0.1.4: + version "0.1.4" + resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz" + integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= -"inflight@^1.0.4": - "integrity" "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=" - "resolved" "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz" - "version" "1.0.6" +inflight@^1.0.4: + version "1.0.6" + resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz" + integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk= dependencies: - "once" "^1.3.0" - "wrappy" "1" + once "^1.3.0" + wrappy "1" -"inherits@~2.0.3", "inherits@2": - "integrity" "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" - "resolved" "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz" - "version" "2.0.4" +inherits@~2.0.3, inherits@2: + version "2.0.4" + resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== -"ink@^2.1.1", "ink@^2.3.0": - "integrity" "sha512-931rgXHAS3hM++8ygWPOBeHOFwTzHh3pDAVZtiBVOUH6tVvJijym43ODUy22ySo2NwYUFeR/Zj3xuWzBEKMiHw==" - "resolved" "https://registry.yarnpkg.com/ink/-/ink-2.3.0.tgz" - "version" "2.3.0" +ink@^2.1.1, ink@^2.3.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/ink/-/ink-2.3.0.tgz" + integrity sha512-931rgXHAS3hM++8ygWPOBeHOFwTzHh3pDAVZtiBVOUH6tVvJijym43ODUy22ySo2NwYUFeR/Zj3xuWzBEKMiHw== dependencies: "@types/react" "^16.8.6" - "arrify" "^1.0.1" - "auto-bind" "^2.0.0" - "chalk" "^2.4.1" - "cli-cursor" "^2.1.0" - "cli-truncate" "^1.1.0" - "is-ci" "^2.0.0" - "lodash.throttle" "^4.1.1" - "log-update" "^3.0.0" - "prop-types" "^15.6.2" - "react-reconciler" "^0.20.0" - "scheduler" "^0.13.2" - "signal-exit" "^3.0.2" - "slice-ansi" "^1.0.0" - "string-length" "^2.0.0" - "widest-line" "^2.0.0" - "wrap-ansi" "^5.0.0" - "yoga-layout-prebuilt" "^1.9.3" + arrify "^1.0.1" + auto-bind "^2.0.0" + chalk "^2.4.1" + cli-cursor "^2.1.0" + cli-truncate "^1.1.0" + is-ci "^2.0.0" + lodash.throttle "^4.1.1" + log-update "^3.0.0" + prop-types "^15.6.2" + react-reconciler "^0.20.0" + scheduler "^0.13.2" + signal-exit "^3.0.2" + slice-ansi "^1.0.0" + string-length "^2.0.0" + widest-line "^2.0.0" + wrap-ansi "^5.0.0" + yoga-layout-prebuilt "^1.9.3" -"invariant@^2.2.2": - "integrity" "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==" - "resolved" "https://registry.yarnpkg.com/invariant/-/invariant-2.2.4.tgz" - "version" "2.2.4" +invariant@^2.2.2: + version "2.2.4" + resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.4.tgz" + integrity sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA== dependencies: - "loose-envify" "^1.0.0" + loose-envify "^1.0.0" -"invert-kv@^2.0.0": - "integrity" "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==" - "resolved" "https://registry.yarnpkg.com/invert-kv/-/invert-kv-2.0.0.tgz" - "version" "2.0.0" +invert-kv@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-2.0.0.tgz" + integrity sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA== -"is-arrayish@^0.2.1": - "integrity" "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=" - "resolved" "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz" - "version" "0.2.1" +is-arrayish@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz" + integrity sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0= -"is-binary-path@~2.1.0": - "integrity" "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==" - "resolved" "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-2.1.0.tgz" - "version" "2.1.0" +is-binary-path@~2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-2.1.0.tgz" + integrity sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw== dependencies: - "binary-extensions" "^2.0.0" + binary-extensions "^2.0.0" -"is-ci@^2.0.0": - "integrity" "sha512-YfJT7rkpQB0updsdHLGWrvhBJfcfzNNawYDNIyQXJz0IViGf75O8EBPKSdvw2rF+LGCsX4FZ8tcr3b19LcZq4w==" - "resolved" "https://registry.yarnpkg.com/is-ci/-/is-ci-2.0.0.tgz" - "version" "2.0.0" +is-ci@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/is-ci/-/is-ci-2.0.0.tgz" + integrity sha512-YfJT7rkpQB0updsdHLGWrvhBJfcfzNNawYDNIyQXJz0IViGf75O8EBPKSdvw2rF+LGCsX4FZ8tcr3b19LcZq4w== dependencies: - "ci-info" "^2.0.0" + ci-info "^2.0.0" -"is-extglob@^2.1.1": - "integrity" "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=" - "resolved" "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz" - "version" "2.1.1" +is-extglob@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz" + integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= -"is-finite@^1.0.0": - "integrity" "sha1-zGZ3aVYCvlUO8R6LSqYwU0K20Ko=" - "resolved" "https://registry.yarnpkg.com/is-finite/-/is-finite-1.0.2.tgz" - "version" "1.0.2" +is-finite@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/is-finite/-/is-finite-1.0.2.tgz" + integrity sha1-zGZ3aVYCvlUO8R6LSqYwU0K20Ko= dependencies: - "number-is-nan" "^1.0.0" + number-is-nan "^1.0.0" -"is-fullwidth-code-point@^1.0.0": - "integrity" "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=" - "resolved" "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz" - "version" "1.0.0" +is-fullwidth-code-point@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz" + integrity sha1-754xOG8DGn8NZDr4L95QxFfvAMs= dependencies: - "number-is-nan" "^1.0.0" + number-is-nan "^1.0.0" -"is-fullwidth-code-point@^2.0.0": - "integrity" "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=" - "resolved" "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz" - "version" "2.0.0" +is-fullwidth-code-point@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz" + integrity sha1-o7MKXE8ZkYMWeqq5O+764937ZU8= -"is-glob@^4.0.1", "is-glob@~4.0.1": - "integrity" "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==" - "resolved" "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz" - "version" "4.0.1" +is-glob@^4.0.1, is-glob@~4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz" + integrity sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg== dependencies: - "is-extglob" "^2.1.1" + is-extglob "^2.1.1" -"is-number@^7.0.0": - "integrity" "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" - "resolved" "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz" - "version" "7.0.0" +is-number@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz" + integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== -"is-stream@^1.0.1", "is-stream@^1.1.0": - "integrity" "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=" - "resolved" "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz" - "version" "1.1.0" +is-stream@^1.0.1, is-stream@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz" + integrity sha1-EtSj3U5o4Lec6428hBc66A2RykQ= -"is-typedarray@^1.0.0", "is-typedarray@~1.0.0": - "integrity" "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=" - "resolved" "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz" - "version" "1.0.0" +is-typedarray@^1.0.0, is-typedarray@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz" + integrity sha1-5HnICFjfDBsR3dppQPlgEfzaSpo= -"isarray@~1.0.0": - "integrity" "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" - "resolved" "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz" - "version" "1.0.0" +isarray@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz" + integrity sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE= -"isexe@^2.0.0": - "integrity" "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=" - "resolved" "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz" - "version" "2.0.0" +isexe@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz" + integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= -"isstream@~0.1.2": - "integrity" "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=" - "resolved" "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz" - "version" "0.1.2" +isstream@~0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz" + integrity sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo= -"istanbul-lib-coverage@^2.0.3", "istanbul-lib-coverage@^2.0.5": - "integrity" "sha512-8aXznuEPCJvGnMSRft4udDRDtb1V3pkQkMMI5LI+6HuQz5oQ4J2UFn1H82raA3qJtyOLkkwVqICBQkjnGtn5mA==" - "resolved" "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.5.tgz" - "version" "2.0.5" +istanbul-lib-coverage@^2.0.3, istanbul-lib-coverage@^2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.5.tgz" + integrity sha512-8aXznuEPCJvGnMSRft4udDRDtb1V3pkQkMMI5LI+6HuQz5oQ4J2UFn1H82raA3qJtyOLkkwVqICBQkjnGtn5mA== -"istanbul-lib-hook@^2.0.7": - "integrity" "sha512-vrRztU9VRRFDyC+aklfLoeXyNdTfga2EI3udDGn4cZ6fpSXpHLV9X6CHvfoMCPtggg8zvDDmC4b9xfu0z6/llA==" - "resolved" "https://registry.yarnpkg.com/istanbul-lib-hook/-/istanbul-lib-hook-2.0.7.tgz" - "version" "2.0.7" +istanbul-lib-hook@^2.0.7: + version "2.0.7" + resolved "https://registry.yarnpkg.com/istanbul-lib-hook/-/istanbul-lib-hook-2.0.7.tgz" + integrity sha512-vrRztU9VRRFDyC+aklfLoeXyNdTfga2EI3udDGn4cZ6fpSXpHLV9X6CHvfoMCPtggg8zvDDmC4b9xfu0z6/llA== dependencies: - "append-transform" "^1.0.0" + append-transform "^1.0.0" -"istanbul-lib-instrument@^3.3.0": - "integrity" "sha512-5nnIN4vo5xQZHdXno/YDXJ0G+I3dAm4XgzfSVTPLQpj/zAV2dV6Juy0yaf10/zrJOJeHoN3fraFe+XRq2bFVZA==" - "resolved" "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-3.3.0.tgz" - "version" "3.3.0" +istanbul-lib-instrument@^3.3.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-3.3.0.tgz" + integrity sha512-5nnIN4vo5xQZHdXno/YDXJ0G+I3dAm4XgzfSVTPLQpj/zAV2dV6Juy0yaf10/zrJOJeHoN3fraFe+XRq2bFVZA== dependencies: "@babel/generator" "^7.4.0" "@babel/parser" "^7.4.3" "@babel/template" "^7.4.0" "@babel/traverse" "^7.4.3" "@babel/types" "^7.4.0" - "istanbul-lib-coverage" "^2.0.5" - "semver" "^6.0.0" - -"istanbul-lib-processinfo@^1.0.0": - "integrity" "sha512-FY0cPmWa4WoQNlvB8VOcafiRoB5nB+l2Pz2xGuXHRSy1KM8QFOYfz/rN+bGMCAeejrY3mrpF5oJHcN0s/garCg==" - "resolved" "https://registry.yarnpkg.com/istanbul-lib-processinfo/-/istanbul-lib-processinfo-1.0.0.tgz" - "version" "1.0.0" - dependencies: - "archy" "^1.0.0" - "cross-spawn" "^6.0.5" - "istanbul-lib-coverage" "^2.0.3" - "rimraf" "^2.6.3" - "uuid" "^3.3.2" - -"istanbul-lib-report@^2.0.8": - "integrity" "sha512-fHBeG573EIihhAblwgxrSenp0Dby6tJMFR/HvlerBsrCTD5bkUuoNtn3gVh29ZCS824cGGBPn7Sg7cNk+2xUsQ==" - "resolved" "https://registry.yarnpkg.com/istanbul-lib-report/-/istanbul-lib-report-2.0.8.tgz" - "version" "2.0.8" - dependencies: - "istanbul-lib-coverage" "^2.0.5" - "make-dir" "^2.1.0" - "supports-color" "^6.1.0" - -"istanbul-lib-source-maps@^3.0.6": - "integrity" "sha512-R47KzMtDJH6X4/YW9XTx+jrLnZnscW4VpNN+1PViSYTejLVPWv7oov+Duf8YQSPyVRUvueQqz1TcsC6mooZTXw==" - "resolved" "https://registry.yarnpkg.com/istanbul-lib-source-maps/-/istanbul-lib-source-maps-3.0.6.tgz" - "version" "3.0.6" - dependencies: - "debug" "^4.1.1" - "istanbul-lib-coverage" "^2.0.5" - "make-dir" "^2.1.0" - "rimraf" "^2.6.3" - "source-map" "^0.6.1" - -"istanbul-reports@^2.2.4": - "integrity" "sha512-SKi4rnMyLBKe0Jy2uUdx28h8oG7ph2PPuQPvIAh31d+Ci+lSiEu4C+h3oBPuJ9+mPKhOyW0M8gY4U5NM1WLeXA==" - "resolved" "https://registry.yarnpkg.com/istanbul-reports/-/istanbul-reports-2.2.6.tgz" - "version" "2.2.6" - dependencies: - "handlebars" "^4.1.2" - -"jackspeak@^1.4.0": - "integrity" "sha512-VDcSunT+wcccoG46FtzuBAyQKlzhHjli4q31e1fIHGOsRspqNUFjVzGb+7eIFDlTvqLygxapDHPHS0ouT2o/tw==" - "resolved" "https://registry.yarnpkg.com/jackspeak/-/jackspeak-1.4.0.tgz" - "version" "1.4.0" - dependencies: - "cliui" "^4.1.0" - -"js-tokens@^3.0.0 || ^4.0.0", "js-tokens@^4.0.0": - "integrity" "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==" - "resolved" "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz" - "version" "4.0.0" - -"js-tokens@^3.0.2": - "integrity" "sha1-mGbfOVECEw449/mWvOtlRDIJwls=" - "resolved" "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz" - "version" "3.0.2" - -"js-yaml@^3.13.1": - "integrity" "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==" - "resolved" "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz" - "version" "3.13.1" - dependencies: - "argparse" "^1.0.7" - "esprima" "^4.0.0" - -"jsbn@~0.1.0": - "integrity" "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=" - "resolved" "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz" - "version" "0.1.1" - -"jsesc@^1.3.0": - "integrity" "sha1-RsP+yMGJKxKwgz25vHYiF226s0s=" - "resolved" "https://registry.yarnpkg.com/jsesc/-/jsesc-1.3.0.tgz" - "version" "1.3.0" - -"jsesc@^2.5.1": - "integrity" "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==" - "resolved" "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz" - "version" "2.5.2" - -"json-parse-better-errors@^1.0.1": - "integrity" "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==" - "resolved" "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz" - "version" "1.0.2" - -"json-schema-traverse@^0.4.1": - "integrity" "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==" - "resolved" "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz" - "version" "0.4.1" - -"json-schema@0.2.3": - "integrity" "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=" - "resolved" "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz" - "version" "0.2.3" - -"json-stringify-safe@~5.0.1": - "integrity" "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=" - "resolved" "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz" - "version" "5.0.1" - -"json5@^0.5.1": - "integrity" "sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE=" - "resolved" "https://registry.yarnpkg.com/json5/-/json5-0.5.1.tgz" - "version" "0.5.1" - -"jsprim@^1.2.2": - "integrity" "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=" - "resolved" "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz" - "version" "1.4.1" - dependencies: - "assert-plus" "1.0.0" - "extsprintf" "1.3.0" - "json-schema" "0.2.3" - "verror" "1.10.0" - -"lcid@^2.0.0": - "integrity" "sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA==" - "resolved" "https://registry.yarnpkg.com/lcid/-/lcid-2.0.0.tgz" - "version" "2.0.0" - dependencies: - "invert-kv" "^2.0.0" - -"lcov-parse@^0.0.10": - "integrity" "sha1-GwuP+ayceIklBYK3C3ExXZ2m2aM=" - "resolved" "https://registry.yarnpkg.com/lcov-parse/-/lcov-parse-0.0.10.tgz" - "version" "0.0.10" - -"load-json-file@^4.0.0": - "integrity" "sha1-L19Fq5HjMhYjT9U62rZo607AmTs=" - "resolved" "https://registry.yarnpkg.com/load-json-file/-/load-json-file-4.0.0.tgz" - "version" "4.0.0" - dependencies: - "graceful-fs" "^4.1.2" - "parse-json" "^4.0.0" - "pify" "^3.0.0" - "strip-bom" "^3.0.0" - -"locate-path@^3.0.0": - "integrity" "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==" - "resolved" "https://registry.yarnpkg.com/locate-path/-/locate-path-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "p-locate" "^3.0.0" - "path-exists" "^3.0.0" - -"lodash.flattendeep@^4.4.0": - "integrity" "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=" - "resolved" "https://registry.yarnpkg.com/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz" - "version" "4.4.0" - -"lodash.throttle@^4.1.1": - "integrity" "sha1-wj6RtxAkKscMN/HhzaknTMOb8vQ=" - "resolved" "https://registry.yarnpkg.com/lodash.throttle/-/lodash.throttle-4.1.1.tgz" - "version" "4.1.1" - -"lodash@^4.17.11", "lodash@^4.17.4": - "integrity" "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" - "resolved" "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz" - "version" "4.17.11" - -"log-driver@^1.2.7": - "integrity" "sha512-U7KCmLdqsGHBLeWqYlFA0V0Sl6P08EE1ZrmA9cxjUE0WVqT9qnyVDPz1kzpFEP0jdJuFnasWIfSd7fsaNXkpbg==" - "resolved" "https://registry.yarnpkg.com/log-driver/-/log-driver-1.2.7.tgz" - "version" "1.2.7" - -"log-update@^3.0.0": - "integrity" "sha512-KJ6zAPIHWo7Xg1jYror6IUDFJBq1bQ4Bi4wAEp2y/0ScjBBVi/g0thr0sUVhuvuXauWzczt7T2QHghPDNnKBuw==" - "resolved" "https://registry.yarnpkg.com/log-update/-/log-update-3.2.0.tgz" - "version" "3.2.0" - dependencies: - "ansi-escapes" "^3.2.0" - "cli-cursor" "^2.1.0" - "wrap-ansi" "^5.0.0" - -"loose-envify@^1.0.0", "loose-envify@^1.1.0", "loose-envify@^1.4.0": - "integrity" "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==" - "resolved" "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.4.0.tgz" - "version" "1.4.0" - dependencies: - "js-tokens" "^3.0.0||^4.0.0" - -"lru-cache@^4.0.1": - "integrity" "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==" - "resolved" "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.5.tgz" - "version" "4.1.5" - dependencies: - "pseudomap" "^1.0.2" - "yallist" "^2.1.2" - -"make-dir@^2.0.0", "make-dir@^2.1.0": - "integrity" "sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA==" - "resolved" "https://registry.yarnpkg.com/make-dir/-/make-dir-2.1.0.tgz" - "version" "2.1.0" - dependencies: - "pify" "^4.0.1" - "semver" "^5.6.0" - -"make-error@^1.1.1": - "integrity" "sha512-c3sIjNUow0+8swNwVpqoH4YCShKNFkMaw6oH1mNS2haDZQqkeZFlHS3dhoeEbKKmJB4vXpJucU6oH75aDYeE9g==" - "resolved" "https://registry.yarnpkg.com/make-error/-/make-error-1.3.5.tgz" - "version" "1.3.5" - -"map-age-cleaner@^0.1.1": - "integrity" "sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w==" - "resolved" "https://registry.yarnpkg.com/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz" - "version" "0.1.3" - dependencies: - "p-defer" "^1.0.0" - -"mem@^4.0.0": - "integrity" "sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w==" - "resolved" "https://registry.yarnpkg.com/mem/-/mem-4.3.0.tgz" - "version" "4.3.0" - dependencies: - "map-age-cleaner" "^0.1.1" - "mimic-fn" "^2.0.0" - "p-is-promise" "^2.0.0" - -"merge-source-map@^1.1.0": - "integrity" "sha512-Qkcp7P2ygktpMPh2mCQZaf3jhN6D3Z/qVZHSdWvQ+2Ef5HgRAPBO57A77+ENm0CPx2+1Ce/MYKi3ymqdfuqibw==" - "resolved" "https://registry.yarnpkg.com/merge-source-map/-/merge-source-map-1.1.0.tgz" - "version" "1.1.0" - dependencies: - "source-map" "^0.6.1" - -"mime-db@1.40.0": - "integrity" "sha512-jYdeOMPy9vnxEqFRRo6ZvTZ8d9oPb+k18PKoYNYUe2stVEBPPwsln/qWzdbmaIvnhZ9v2P+CuecK+fpUfsV2mA==" - "resolved" "https://registry.yarnpkg.com/mime-db/-/mime-db-1.40.0.tgz" - "version" "1.40.0" - -"mime-types@^2.1.12", "mime-types@~2.1.19": - "integrity" "sha512-WaFHS3MCl5fapm3oLxU4eYDw77IQM2ACcxQ9RIxfaC3ooc6PFuBMGZZsYpvoXS5D5QTWPieo1jjLdAm3TBP3cQ==" - "resolved" "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.24.tgz" - "version" "2.1.24" - dependencies: - "mime-db" "1.40.0" - -"mimic-fn@^1.0.0": - "integrity" "sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ==" - "resolved" "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz" - "version" "1.2.0" - -"mimic-fn@^2.0.0": - "integrity" "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==" - "resolved" "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz" - "version" "2.1.0" - -"minimatch@^3.0.4": - "integrity" "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==" - "resolved" "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz" - "version" "3.0.4" - dependencies: - "brace-expansion" "^1.1.7" - -"minimist@^1.2.0": - "integrity" "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=" - "resolved" "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz" - "version" "1.2.0" - -"minimist@~0.0.1": - "integrity" "sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8=" - "resolved" "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz" - "version" "0.0.10" - -"minimist@0.0.8": - "integrity" "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=" - "resolved" "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz" - "version" "0.0.8" - -"minipass@^3.0.0": - "integrity" "sha512-UFqVihv6PQgwj8/yTGvl9kPz7xIAY+R5z6XYjRInD3Gk3qx6QGSD6zEcpeG4Dy/lQnv1J6zv8ejV90hyYIKf3w==" - "resolved" "https://registry.yarnpkg.com/minipass/-/minipass-3.1.1.tgz" - "version" "3.1.1" - dependencies: - "yallist" "^4.0.0" - -"mkdirp@^0.5.0", "mkdirp@^0.5.1": - "integrity" "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=" - "resolved" "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz" - "version" "0.5.1" - dependencies: - "minimist" "0.0.8" - -"ms@^2.1.1": - "integrity" "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" - "resolved" "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz" - "version" "2.1.2" - -"ms@2.0.0": - "integrity" "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" - "resolved" "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz" - "version" "2.0.0" - -"neo-async@^2.6.0": - "integrity" "sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw==" - "resolved" "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.1.tgz" - "version" "2.6.1" - -"nested-error-stacks@^2.0.0": - "integrity" "sha512-AO81vsIO1k1sM4Zrd6Hu7regmJN1NSiAja10gc4bX3F0wd+9rQmcuHQaHVQCYIEC8iFXnE+mavh23GOt7wBgug==" - "resolved" "https://registry.yarnpkg.com/nested-error-stacks/-/nested-error-stacks-2.1.0.tgz" - "version" "2.1.0" - -"nice-try@^1.0.4": - "integrity" "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==" - "resolved" "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.5.tgz" - "version" "1.0.5" - -"node-modules-regexp@^1.0.0": - "integrity" "sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA=" - "resolved" "https://registry.yarnpkg.com/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz" - "version" "1.0.0" - -"normalize-package-data@^2.3.2": - "integrity" "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==" - "resolved" "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.5.0.tgz" - "version" "2.5.0" - dependencies: - "hosted-git-info" "^2.1.4" - "resolve" "^1.10.0" - "semver" "2||3||4||5" - "validate-npm-package-license" "^3.0.1" - -"normalize-path@^3.0.0", "normalize-path@~3.0.0": - "integrity" "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==" - "resolved" "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz" - "version" "3.0.0" - -"npm-run-path@^2.0.0": - "integrity" "sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8=" - "resolved" "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-2.0.2.tgz" - "version" "2.0.2" - dependencies: - "path-key" "^2.0.0" - -"number-is-nan@^1.0.0": - "integrity" "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=" - "resolved" "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz" - "version" "1.0.1" - -"nyc@^14.1.1": - "integrity" "sha512-OI0vm6ZGUnoGZv/tLdZ2esSVzDwUC88SNs+6JoSOMVxA+gKMB8Tk7jBwgemLx4O40lhhvZCVw1C+OYLOBOPXWw==" - "resolved" "https://registry.yarnpkg.com/nyc/-/nyc-14.1.1.tgz" - "version" "14.1.1" - dependencies: - "archy" "^1.0.0" - "caching-transform" "^3.0.2" - "convert-source-map" "^1.6.0" - "cp-file" "^6.2.0" - "find-cache-dir" "^2.1.0" - "find-up" "^3.0.0" - "foreground-child" "^1.5.6" - "glob" "^7.1.3" - "istanbul-lib-coverage" "^2.0.5" - "istanbul-lib-hook" "^2.0.7" - "istanbul-lib-instrument" "^3.3.0" - "istanbul-lib-report" "^2.0.8" - "istanbul-lib-source-maps" "^3.0.6" - "istanbul-reports" "^2.2.4" - "js-yaml" "^3.13.1" - "make-dir" "^2.1.0" - "merge-source-map" "^1.1.0" - "resolve-from" "^4.0.0" - "rimraf" "^2.6.3" - "signal-exit" "^3.0.2" - "spawn-wrap" "^1.4.2" - "test-exclude" "^5.2.3" - "uuid" "^3.3.2" - "yargs" "^13.2.2" - "yargs-parser" "^13.0.0" - -"oauth-sign@~0.9.0": - "integrity" "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==" - "resolved" "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz" - "version" "0.9.0" - -"object-assign@^4.1.1": - "integrity" "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" - "resolved" "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz" - "version" "4.1.1" - -"once@^1.3.0", "once@^1.3.1", "once@^1.4.0": - "integrity" "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=" - "resolved" "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz" - "version" "1.4.0" - dependencies: - "wrappy" "1" - -"onetime@^2.0.0": - "integrity" "sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ=" - "resolved" "https://registry.yarnpkg.com/onetime/-/onetime-2.0.1.tgz" - "version" "2.0.1" - dependencies: - "mimic-fn" "^1.0.0" - -"opener@^1.5.1": - "integrity" "sha512-goYSy5c2UXE4Ra1xixabeVh1guIX/ZV/YokJksb6q2lubWu6UbvPQ20p542/sFIll1nl8JnCyK9oBaOcCWXwvA==" - "resolved" "https://registry.yarnpkg.com/opener/-/opener-1.5.1.tgz" - "version" "1.5.1" - -"optimist@^0.6.1": - "integrity" "sha1-2j6nRob6IaGaERwybpDrFaAZZoY=" - "resolved" "https://registry.yarnpkg.com/optimist/-/optimist-0.6.1.tgz" - "version" "0.6.1" - dependencies: - "minimist" "~0.0.1" - "wordwrap" "~0.0.2" - -"os-homedir@^1.0.0", "os-homedir@^1.0.1": - "integrity" "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=" - "resolved" "https://registry.yarnpkg.com/os-homedir/-/os-homedir-1.0.2.tgz" - "version" "1.0.2" - -"os-locale@^3.1.0": - "integrity" "sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q==" - "resolved" "https://registry.yarnpkg.com/os-locale/-/os-locale-3.1.0.tgz" - "version" "3.1.0" - dependencies: - "execa" "^1.0.0" - "lcid" "^2.0.0" - "mem" "^4.0.0" - -"os-tmpdir@^1.0.1": - "integrity" "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=" - "resolved" "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz" - "version" "1.0.2" - -"own-or-env@^1.0.1": - "integrity" "sha512-y8qULRbRAlL6x2+M0vIe7jJbJx/kmUTzYonRAa2ayesR2qWLswninkVyeJe4x3IEXhdgoNodzjQRKAoEs6Fmrw==" - "resolved" "https://registry.yarnpkg.com/own-or-env/-/own-or-env-1.0.1.tgz" - "version" "1.0.1" - dependencies: - "own-or" "^1.0.0" - -"own-or@^1.0.0": - "integrity" "sha1-Tod/vtqaLsgAD7wLyuOWRe6L+Nw=" - "resolved" "https://registry.yarnpkg.com/own-or/-/own-or-1.0.0.tgz" - "version" "1.0.0" - -"p-defer@^1.0.0": - "integrity" "sha1-n26xgvbJqozXQwBKfU+WsZaw+ww=" - "resolved" "https://registry.yarnpkg.com/p-defer/-/p-defer-1.0.0.tgz" - "version" "1.0.0" - -"p-finally@^1.0.0": - "integrity" "sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4=" - "resolved" "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz" - "version" "1.0.0" - -"p-is-promise@^2.0.0": - "integrity" "sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg==" - "resolved" "https://registry.yarnpkg.com/p-is-promise/-/p-is-promise-2.1.0.tgz" - "version" "2.1.0" - -"p-limit@^2.0.0": - "integrity" "sha512-pZbTJpoUsCzV48Mc9Nh51VbwO0X9cuPFE8gYwx9BTCt9SF8/b7Zljd2fVgOxhIF/HDTKgpVzs+GPhyKfjLLFRQ==" - "resolved" "https://registry.yarnpkg.com/p-limit/-/p-limit-2.2.0.tgz" - "version" "2.2.0" - dependencies: - "p-try" "^2.0.0" - -"p-locate@^3.0.0": - "integrity" "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==" - "resolved" "https://registry.yarnpkg.com/p-locate/-/p-locate-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "p-limit" "^2.0.0" - -"p-try@^2.0.0": - "integrity" "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==" - "resolved" "https://registry.yarnpkg.com/p-try/-/p-try-2.2.0.tgz" - "version" "2.2.0" - -"package-hash@^3.0.0": - "integrity" "sha512-lOtmukMDVvtkL84rJHI7dpTYq+0rli8N2wlnqUcBuDWCfVhRUfOmnR9SsoHFMLpACvEV60dX7rd0rFaYDZI+FA==" - "resolved" "https://registry.yarnpkg.com/package-hash/-/package-hash-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "graceful-fs" "^4.1.15" - "hasha" "^3.0.0" - "lodash.flattendeep" "^4.4.0" - "release-zalgo" "^1.0.0" - -"parse-json@^4.0.0": - "integrity" "sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA=" - "resolved" "https://registry.yarnpkg.com/parse-json/-/parse-json-4.0.0.tgz" - "version" "4.0.0" - dependencies: - "error-ex" "^1.3.1" - "json-parse-better-errors" "^1.0.1" - -"path-exists@^3.0.0": - "integrity" "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" - "resolved" "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz" - "version" "3.0.0" - -"path-is-absolute@^1.0.0", "path-is-absolute@^1.0.1": - "integrity" "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" - "resolved" "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz" - "version" "1.0.1" - -"path-key@^2.0.0", "path-key@^2.0.1": - "integrity" "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=" - "resolved" "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz" - "version" "2.0.1" - -"path-parse@^1.0.6": - "integrity" "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==" - "resolved" "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.6.tgz" - "version" "1.0.6" - -"path-type@^3.0.0": - "integrity" "sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg==" - "resolved" "https://registry.yarnpkg.com/path-type/-/path-type-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "pify" "^3.0.0" - -"performance-now@^2.1.0": - "integrity" "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=" - "resolved" "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz" - "version" "2.1.0" - -"picomatch@^2.0.4": - "integrity" "sha512-oLHIdio3tZ0qH76NybpeneBhYVj0QFTfXEFTc/B3zKQspYfYYkWYgFsmzo+4kvId/bQRcNkVeguI3y+CD22BtA==" - "resolved" "https://registry.yarnpkg.com/picomatch/-/picomatch-2.0.7.tgz" - "version" "2.0.7" - -"pify@^3.0.0": - "integrity" "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=" - "resolved" "https://registry.yarnpkg.com/pify/-/pify-3.0.0.tgz" - "version" "3.0.0" - -"pify@^4.0.1": - "integrity" "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==" - "resolved" "https://registry.yarnpkg.com/pify/-/pify-4.0.1.tgz" - "version" "4.0.1" - -"pirates@^3.0.2": - "integrity" "sha512-c5CgUJq6H2k6MJz72Ak1F5sN9n9wlSlJyEnwvpm9/y3WB4E3pHBDT2c6PEiS1vyJvq2bUxUAIu0EGf8Cx4Ic7Q==" - "resolved" "https://registry.yarnpkg.com/pirates/-/pirates-3.0.2.tgz" - "version" "3.0.2" - dependencies: - "node-modules-regexp" "^1.0.0" - -"pkg-dir@^3.0.0": - "integrity" "sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw==" - "resolved" "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "find-up" "^3.0.0" - -"private@^0.1.8": - "integrity" "sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg==" - "resolved" "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz" - "version" "0.1.8" - -"process-nextick-args@~2.0.0": - "integrity" "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" - "resolved" "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz" - "version" "2.0.1" - -"prop-types@^15.6.2": - "integrity" "sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ==" - "resolved" "https://registry.yarnpkg.com/prop-types/-/prop-types-15.7.2.tgz" - "version" "15.7.2" - dependencies: - "loose-envify" "^1.4.0" - "object-assign" "^4.1.1" - "react-is" "^16.8.1" - -"pseudomap@^1.0.2": - "integrity" "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=" - "resolved" "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz" - "version" "1.0.2" - -"psl@^1.1.24": - "integrity" "sha512-GEn74ZffufCmkDDLNcl3uuyF/aSD6exEyh1v/ZSdAomB82t6G9hzJVRx0jBmLDW+VfZqks3aScmMw9DszwUalA==" - "resolved" "https://registry.yarnpkg.com/psl/-/psl-1.2.0.tgz" - "version" "1.2.0" - -"pump@^3.0.0": - "integrity" "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==" - "resolved" "https://registry.yarnpkg.com/pump/-/pump-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "end-of-stream" "^1.1.0" - "once" "^1.3.1" - -"punycode@^1.3.2", "punycode@^1.4.1": - "integrity" "sha1-wNWmOycYgArY4esPpSachN1BhF4=" - "resolved" "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz" - "version" "1.4.1" - -"punycode@^2.0.0", "punycode@^2.1.0": - "integrity" "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==" - "resolved" "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz" - "version" "2.1.1" - -"qs@~6.5.2": - "integrity" "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==" - "resolved" "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz" - "version" "6.5.2" - -"react-is@^16.8.1": - "integrity" "sha512-aUk3bHfZ2bRSVFFbbeVS4i+lNPZr3/WM5jT2J5omUVV1zzcs1nAaf3l51ctA5FFvCRbhrH0bdAsRRQddFJZPtA==" - "resolved" "https://registry.yarnpkg.com/react-is/-/react-is-16.8.6.tgz" - "version" "16.8.6" - -"react-reconciler@^0.20.0": - "integrity" "sha512-kxERc4H32zV2lXMg/iMiwQHOtyqf15qojvkcZ5Ja2CPkjVohHw9k70pdDBwrnQhLVetUJBSYyqU3yqrlVTOajA==" - "resolved" "https://registry.yarnpkg.com/react-reconciler/-/react-reconciler-0.20.4.tgz" - "version" "0.20.4" - dependencies: - "loose-envify" "^1.1.0" - "object-assign" "^4.1.1" - "prop-types" "^15.6.2" - "scheduler" "^0.13.6" - -"react@^16.8.6": - "integrity" "sha512-pC0uMkhLaHm11ZSJULfOBqV4tIZkx87ZLvbbQYunNixAAvjnC+snJCg0XQXn9VIsttVsbZP/H/ewzgsd5fxKXw==" - "resolved" "https://registry.yarnpkg.com/react/-/react-16.8.6.tgz" - "version" "16.8.6" - dependencies: - "loose-envify" "^1.1.0" - "object-assign" "^4.1.1" - "prop-types" "^15.6.2" - "scheduler" "^0.13.6" - -"react@^16.9.0": - "integrity" "sha512-fglqy3k5E+81pA8s+7K0/T3DBCF0ZDOher1elBFzF7O6arXJgzyu/FW+COxFvAWXJoJN9KIZbT2LXlukwphYTA==" - "resolved" "https://registry.yarnpkg.com/react/-/react-16.12.0.tgz" - "version" "16.12.0" - dependencies: - "loose-envify" "^1.1.0" - "object-assign" "^4.1.1" - "prop-types" "^15.6.2" - -"read-pkg-up@^4.0.0": - "integrity" "sha512-6etQSH7nJGsK0RbG/2TeDzZFa8shjQ1um+SwQQ5cwKy0dhSXdOncEhb1CPpvQG4h7FyOV6EB6YlV0yJvZQNAkA==" - "resolved" "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-4.0.0.tgz" - "version" "4.0.0" - dependencies: - "find-up" "^3.0.0" - "read-pkg" "^3.0.0" - -"read-pkg@^3.0.0": - "integrity" "sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k=" - "resolved" "https://registry.yarnpkg.com/read-pkg/-/read-pkg-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "load-json-file" "^4.0.0" - "normalize-package-data" "^2.3.2" - "path-type" "^3.0.0" - -"readable-stream@^2.1.5": - "integrity" "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==" - "resolved" "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz" - "version" "2.3.6" - dependencies: - "core-util-is" "~1.0.0" - "inherits" "~2.0.3" - "isarray" "~1.0.0" - "process-nextick-args" "~2.0.0" - "safe-buffer" "~5.1.1" - "string_decoder" "~1.1.1" - "util-deprecate" "~1.0.1" - -"readdirp@~3.2.0": - "integrity" "sha512-crk4Qu3pmXwgxdSgGhgA/eXiJAPQiX4GMOZZMXnqKxHX7TaoL+3gQVo/WeuAiogr07DpnfjIMpXXa+PAIvwPGQ==" - "resolved" "https://registry.yarnpkg.com/readdirp/-/readdirp-3.2.0.tgz" - "version" "3.2.0" - dependencies: - "picomatch" "^2.0.4" - -"redeyed@~2.1.0": - "integrity" "sha1-iYS1gV2ZyyIEacme7v/jiRPmzAs=" - "resolved" "https://registry.yarnpkg.com/redeyed/-/redeyed-2.1.1.tgz" - "version" "2.1.1" - dependencies: - "esprima" "~4.0.0" - -"regenerator-runtime@^0.11.0": - "integrity" "sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg==" - "resolved" "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz" - "version" "0.11.1" - -"regenerator-runtime@^0.13.2": - "integrity" "sha512-S/TQAZJO+D3m9xeN1WTI8dLKBBiRgXBlTJvbWjCThHWZj9EvHK70Ff50/tYj2J/fvBY6JtFVwRuazHN2E7M9BA==" - "resolved" "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.2.tgz" - "version" "0.13.2" - -"release-zalgo@^1.0.0": - "integrity" "sha1-CXALflB0Mpc5Mw5TXFqQ+2eFFzA=" - "resolved" "https://registry.yarnpkg.com/release-zalgo/-/release-zalgo-1.0.0.tgz" - "version" "1.0.0" - dependencies: - "es6-error" "^4.0.1" - -"repeating@^2.0.0": - "integrity" "sha1-UhTFOpJtNVJwdSf7q0FdvAjQbdo=" - "resolved" "https://registry.yarnpkg.com/repeating/-/repeating-2.0.1.tgz" - "version" "2.0.1" - dependencies: - "is-finite" "^1.0.0" - -"request@^2.86.0": - "integrity" "sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg==" - "resolved" "https://registry.yarnpkg.com/request/-/request-2.88.0.tgz" - "version" "2.88.0" - dependencies: - "aws-sign2" "~0.7.0" - "aws4" "^1.8.0" - "caseless" "~0.12.0" - "combined-stream" "~1.0.6" - "extend" "~3.0.2" - "forever-agent" "~0.6.1" - "form-data" "~2.3.2" - "har-validator" "~5.1.0" - "http-signature" "~1.2.0" - "is-typedarray" "~1.0.0" - "isstream" "~0.1.2" - "json-stringify-safe" "~5.0.1" - "mime-types" "~2.1.19" - "oauth-sign" "~0.9.0" - "performance-now" "^2.1.0" - "qs" "~6.5.2" - "safe-buffer" "^5.1.2" - "tough-cookie" "~2.4.3" - "tunnel-agent" "^0.6.0" - "uuid" "^3.3.2" - -"require-directory@^2.1.1": - "integrity" "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=" - "resolved" "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz" - "version" "2.1.1" - -"require-main-filename@^2.0.0": - "integrity" "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==" - "resolved" "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-2.0.0.tgz" - "version" "2.0.0" - -"resolve-from@^3.0.0": - "integrity" "sha1-six699nWiBvItuZTM17rywoYh0g=" - "resolved" "https://registry.yarnpkg.com/resolve-from/-/resolve-from-3.0.0.tgz" - "version" "3.0.0" - -"resolve-from@^4.0.0": - "integrity" "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==" - "resolved" "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz" - "version" "4.0.0" - -"resolve@^1.10.0": - "integrity" "sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw==" - "resolved" "https://registry.yarnpkg.com/resolve/-/resolve-1.11.1.tgz" - "version" "1.11.1" - dependencies: - "path-parse" "^1.0.6" - -"restore-cursor@^2.0.0": - "integrity" "sha1-n37ih/gv0ybU/RYpI9YhKe7g368=" - "resolved" "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz" - "version" "2.0.0" - dependencies: - "onetime" "^2.0.0" - "signal-exit" "^3.0.2" - -"rimraf@^2.6.2", "rimraf@^2.6.3": - "integrity" "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==" - "resolved" "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz" - "version" "2.6.3" - dependencies: - "glob" "^7.1.3" - -"rimraf@^2.7.1": - "integrity" "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==" - "resolved" "https://registry.yarnpkg.com/rimraf/-/rimraf-2.7.1.tgz" - "version" "2.7.1" - dependencies: - "glob" "^7.1.3" - -"safe-buffer@^5.0.1", "safe-buffer@^5.1.2": - "integrity" "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==" - "resolved" "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.0.tgz" - "version" "5.2.0" - -"safe-buffer@~5.1.0", "safe-buffer@~5.1.1": - "integrity" "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" - "resolved" "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz" - "version" "5.1.2" - -"safer-buffer@^2.0.2", "safer-buffer@^2.1.0", "safer-buffer@~2.1.0": - "integrity" "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" - "resolved" "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz" - "version" "2.1.2" - -"scheduler@^0.13.2", "scheduler@^0.13.6": - "integrity" "sha512-IWnObHt413ucAYKsD9J1QShUKkbKLQQHdxRyw73sw4FN26iWr3DY/H34xGPe4nmL1DwXyWmSWmMrA9TfQbE/XQ==" - "resolved" "https://registry.yarnpkg.com/scheduler/-/scheduler-0.13.6.tgz" - "version" "0.13.6" - dependencies: - "loose-envify" "^1.1.0" - "object-assign" "^4.1.1" - -"semver@^5.5.0", "semver@^5.6.0", "semver@2 || 3 || 4 || 5": - "integrity" "sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA==" - "resolved" "https://registry.yarnpkg.com/semver/-/semver-5.7.0.tgz" - "version" "5.7.0" - -"semver@^6.0.0": - "integrity" "sha512-jdFC1VdUGT/2Scgbimf7FSx9iJLXoqfglSF+gJeuNWVpiE37OIbc1jywR/GJyFdz3mnkz2/id0L0J/cr0izR5A==" - "resolved" "https://registry.yarnpkg.com/semver/-/semver-6.2.0.tgz" - "version" "6.2.0" - -"set-blocking@^2.0.0": - "integrity" "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=" - "resolved" "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz" - "version" "2.0.0" - -"shebang-command@^1.2.0": - "integrity" "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=" - "resolved" "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz" - "version" "1.2.0" - dependencies: - "shebang-regex" "^1.0.0" - -"shebang-regex@^1.0.0": - "integrity" "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=" - "resolved" "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz" - "version" "1.0.0" - -"signal-exit@^3.0.0", "signal-exit@^3.0.2": - "integrity" "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=" - "resolved" "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz" - "version" "3.0.2" - -"slash@^1.0.0": - "integrity" "sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU=" - "resolved" "https://registry.yarnpkg.com/slash/-/slash-1.0.0.tgz" - "version" "1.0.0" - -"slice-ansi@^1.0.0": - "integrity" "sha512-POqxBK6Lb3q6s047D/XsDVNPnF9Dl8JSaqe9h9lURl0OdNqy/ujDrOiIHtsqXMGbWWTIomRzAMaTyawAU//Reg==" - "resolved" "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-1.0.0.tgz" - "version" "1.0.0" - dependencies: - "is-fullwidth-code-point" "^2.0.0" - -"source-map-support@^0.4.15": - "integrity" "sha512-try0/JqxPLF9nOjvSta7tVondkP5dwgyLDjVoyMDlmjugT2lRZ1OfsrYTkCd2hkDnJTKRbO/Rl3orm8vlsUzbA==" - "resolved" "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.4.18.tgz" - "version" "0.4.18" - dependencies: - "source-map" "^0.5.6" - -"source-map-support@^0.5.11", "source-map-support@^0.5.6": - "integrity" "sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ==" - "resolved" "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.12.tgz" - "version" "0.5.12" - dependencies: - "buffer-from" "^1.0.0" - "source-map" "^0.6.0" - -"source-map-support@^0.5.16": - "integrity" "sha512-efyLRJDr68D9hBBNIPWFjhpFzURh+KJykQwvMyW5UiZzYwoF6l4YMMDIJJEyFWxWCqfyxLzz6tSfUFR+kXXsVQ==" - "resolved" "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.16.tgz" - "version" "0.5.16" - dependencies: - "buffer-from" "^1.0.0" - "source-map" "^0.6.0" - -"source-map@^0.5.0", "source-map@^0.5.6", "source-map@^0.5.7": - "integrity" "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=" - "resolved" "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz" - "version" "0.5.7" - -"source-map@^0.6.0", "source-map@^0.6.1", "source-map@~0.6.1": - "integrity" "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==" - "resolved" "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz" - "version" "0.6.1" - -"spawn-wrap@^1.4.2": - "integrity" "sha512-vMwR3OmmDhnxCVxM8M+xO/FtIp6Ju/mNaDfCMMW7FDcLRTPFWUswec4LXJHTJE2hwTI9O0YBfygu4DalFl7Ylg==" - "resolved" "https://registry.yarnpkg.com/spawn-wrap/-/spawn-wrap-1.4.2.tgz" - "version" "1.4.2" - dependencies: - "foreground-child" "^1.5.6" - "mkdirp" "^0.5.0" - "os-homedir" "^1.0.1" - "rimraf" "^2.6.2" - "signal-exit" "^3.0.2" - "which" "^1.3.0" - -"spdx-correct@^3.0.0": - "integrity" "sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q==" - "resolved" "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.0.tgz" - "version" "3.1.0" - dependencies: - "spdx-expression-parse" "^3.0.0" - "spdx-license-ids" "^3.0.0" - -"spdx-exceptions@^2.1.0": - "integrity" "sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA==" - "resolved" "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz" - "version" "2.2.0" - -"spdx-expression-parse@^3.0.0": - "integrity" "sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg==" - "resolved" "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "spdx-exceptions" "^2.1.0" - "spdx-license-ids" "^3.0.0" - -"spdx-license-ids@^3.0.0": - "integrity" "sha512-7j8LYJLeY/Yb6ACbQ7F76qy5jHkp0U6jgBfJsk97bwWlVUnUWsAgpyaCvo17h0/RQGnQ036tVDomiwoI4pDkQA==" - "resolved" "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.4.tgz" - "version" "3.0.4" - -"sprintf-js@~1.0.2": - "integrity" "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=" - "resolved" "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz" - "version" "1.0.3" - -"sshpk@^1.7.0": - "integrity" "sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==" - "resolved" "https://registry.yarnpkg.com/sshpk/-/sshpk-1.16.1.tgz" - "version" "1.16.1" - dependencies: - "asn1" "~0.2.3" - "assert-plus" "^1.0.0" - "bcrypt-pbkdf" "^1.0.0" - "dashdash" "^1.12.0" - "ecc-jsbn" "~0.1.1" - "getpass" "^0.1.1" - "jsbn" "~0.1.0" - "safer-buffer" "^2.0.2" - "tweetnacl" "~0.14.0" - -"stack-utils@^1.0.2": - "integrity" "sha512-MTX+MeG5U994cazkjd/9KNAapsHnibjMLnfXodlkXw76JEea0UiNzrqidzo1emMwk7w5Qhc9jd4Bn9TBb1MFwA==" - "resolved" "https://registry.yarnpkg.com/stack-utils/-/stack-utils-1.0.2.tgz" - "version" "1.0.2" - -"string_decoder@~1.1.1": - "integrity" "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==" - "resolved" "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz" - "version" "1.1.1" - dependencies: - "safe-buffer" "~5.1.0" - -"string-length@^2.0.0": - "integrity" "sha1-1A27aGo6zpYMHP/KVivyxF+DY+0=" - "resolved" "https://registry.yarnpkg.com/string-length/-/string-length-2.0.0.tgz" - "version" "2.0.0" - dependencies: - "astral-regex" "^1.0.0" - "strip-ansi" "^4.0.0" - -"string-width@^1.0.1": - "integrity" "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=" - "resolved" "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz" - "version" "1.0.2" - dependencies: - "code-point-at" "^1.0.0" - "is-fullwidth-code-point" "^1.0.0" - "strip-ansi" "^3.0.0" - -"string-width@^2.0.0", "string-width@^2.1.1": - "integrity" "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==" - "resolved" "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz" - "version" "2.1.1" - dependencies: - "is-fullwidth-code-point" "^2.0.0" - "strip-ansi" "^4.0.0" - -"string-width@^3.0.0", "string-width@^3.1.0": - "integrity" "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==" - "resolved" "https://registry.yarnpkg.com/string-width/-/string-width-3.1.0.tgz" - "version" "3.1.0" - dependencies: - "emoji-regex" "^7.0.1" - "is-fullwidth-code-point" "^2.0.0" - "strip-ansi" "^5.1.0" - -"strip-ansi@^3.0.0", "strip-ansi@^3.0.1": - "integrity" "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=" - "resolved" "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz" - "version" "3.0.1" - dependencies: - "ansi-regex" "^2.0.0" - -"strip-ansi@^4.0.0": - "integrity" "sha1-qEeQIusaw2iocTibY1JixQXuNo8=" - "resolved" "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-4.0.0.tgz" - "version" "4.0.0" - dependencies: - "ansi-regex" "^3.0.0" - -"strip-ansi@^5.0.0", "strip-ansi@^5.1.0", "strip-ansi@^5.2.0": - "integrity" "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==" - "resolved" "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-5.2.0.tgz" - "version" "5.2.0" - dependencies: - "ansi-regex" "^4.1.0" - -"strip-bom@^3.0.0": - "integrity" "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=" - "resolved" "https://registry.yarnpkg.com/strip-bom/-/strip-bom-3.0.0.tgz" - "version" "3.0.0" - -"strip-eof@^1.0.0": - "integrity" "sha1-u0P/VZim6wXYm1n80SnJgzE2Br8=" - "resolved" "https://registry.yarnpkg.com/strip-eof/-/strip-eof-1.0.0.tgz" - "version" "1.0.0" - -"supports-color@^2.0.0": - "integrity" "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=" - "resolved" "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz" - "version" "2.0.0" - -"supports-color@^5.3.0": - "integrity" "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==" - "resolved" "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz" - "version" "5.5.0" - dependencies: - "has-flag" "^3.0.0" - -"supports-color@^6.1.0": - "integrity" "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==" - "resolved" "https://registry.yarnpkg.com/supports-color/-/supports-color-6.1.0.tgz" - "version" "6.1.0" - dependencies: - "has-flag" "^3.0.0" - -"tap-mocha-reporter@^5.0.0": - "integrity" "sha512-8HlAtdmYGlDZuW83QbF/dc46L7cN+AGhLZcanX3I9ILvxUAl+G2/mtucNPSXecTlG/4iP1hv6oMo0tMhkn3Tsw==" - "resolved" "https://registry.yarnpkg.com/tap-mocha-reporter/-/tap-mocha-reporter-5.0.0.tgz" - "version" "5.0.0" - dependencies: - "color-support" "^1.1.0" - "debug" "^2.1.3" - "diff" "^1.3.2" - "escape-string-regexp" "^1.0.3" - "glob" "^7.0.5" - "tap-parser" "^10.0.0" - "tap-yaml" "^1.0.0" - "unicode-length" "^1.0.0" + istanbul-lib-coverage "^2.0.5" + semver "^6.0.0" + +istanbul-lib-processinfo@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/istanbul-lib-processinfo/-/istanbul-lib-processinfo-1.0.0.tgz" + integrity sha512-FY0cPmWa4WoQNlvB8VOcafiRoB5nB+l2Pz2xGuXHRSy1KM8QFOYfz/rN+bGMCAeejrY3mrpF5oJHcN0s/garCg== + dependencies: + archy "^1.0.0" + cross-spawn "^6.0.5" + istanbul-lib-coverage "^2.0.3" + rimraf "^2.6.3" + uuid "^3.3.2" + +istanbul-lib-report@^2.0.8: + version "2.0.8" + resolved "https://registry.yarnpkg.com/istanbul-lib-report/-/istanbul-lib-report-2.0.8.tgz" + integrity sha512-fHBeG573EIihhAblwgxrSenp0Dby6tJMFR/HvlerBsrCTD5bkUuoNtn3gVh29ZCS824cGGBPn7Sg7cNk+2xUsQ== + dependencies: + istanbul-lib-coverage "^2.0.5" + make-dir "^2.1.0" + supports-color "^6.1.0" + +istanbul-lib-source-maps@^3.0.6: + version "3.0.6" + resolved "https://registry.yarnpkg.com/istanbul-lib-source-maps/-/istanbul-lib-source-maps-3.0.6.tgz" + integrity sha512-R47KzMtDJH6X4/YW9XTx+jrLnZnscW4VpNN+1PViSYTejLVPWv7oov+Duf8YQSPyVRUvueQqz1TcsC6mooZTXw== + dependencies: + debug "^4.1.1" + istanbul-lib-coverage "^2.0.5" + make-dir "^2.1.0" + rimraf "^2.6.3" + source-map "^0.6.1" + +istanbul-reports@^2.2.4: + version "2.2.6" + resolved "https://registry.yarnpkg.com/istanbul-reports/-/istanbul-reports-2.2.6.tgz" + integrity sha512-SKi4rnMyLBKe0Jy2uUdx28h8oG7ph2PPuQPvIAh31d+Ci+lSiEu4C+h3oBPuJ9+mPKhOyW0M8gY4U5NM1WLeXA== + dependencies: + handlebars "^4.1.2" + +jackspeak@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/jackspeak/-/jackspeak-1.4.0.tgz" + integrity sha512-VDcSunT+wcccoG46FtzuBAyQKlzhHjli4q31e1fIHGOsRspqNUFjVzGb+7eIFDlTvqLygxapDHPHS0ouT2o/tw== + dependencies: + cliui "^4.1.0" + +"js-tokens@^3.0.0 || ^4.0.0", js-tokens@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz" + integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== + +js-tokens@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz" + integrity sha1-mGbfOVECEw449/mWvOtlRDIJwls= + +js-yaml@^3.13.1: + version "3.13.1" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz" + integrity sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw== + dependencies: + argparse "^1.0.7" + esprima "^4.0.0" + +jsbn@~0.1.0: + version "0.1.1" + resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz" + integrity sha1-peZUwuWi3rXyAdls77yoDA7y9RM= + +jsesc@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-1.3.0.tgz" + integrity sha1-RsP+yMGJKxKwgz25vHYiF226s0s= + +jsesc@^2.5.1: + version "2.5.2" + resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz" + integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== + +json-parse-better-errors@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz" + integrity sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw== + +json-schema-traverse@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz" + integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg== + +json-schema@0.2.3: + version "0.2.3" + resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz" + integrity sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM= + +json-stringify-safe@~5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz" + integrity sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus= + +json5@^0.5.1: + version "0.5.1" + resolved "https://registry.yarnpkg.com/json5/-/json5-0.5.1.tgz" + integrity sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE= + +jsprim@^1.2.2: + version "1.4.1" + resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz" + integrity sha1-MT5mvB5cwG5Di8G3SZwuXFastqI= + dependencies: + assert-plus "1.0.0" + extsprintf "1.3.0" + json-schema "0.2.3" + verror "1.10.0" + +lcid@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/lcid/-/lcid-2.0.0.tgz" + integrity sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA== + dependencies: + invert-kv "^2.0.0" + +lcov-parse@^0.0.10: + version "0.0.10" + resolved "https://registry.yarnpkg.com/lcov-parse/-/lcov-parse-0.0.10.tgz" + integrity sha1-GwuP+ayceIklBYK3C3ExXZ2m2aM= + +load-json-file@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-4.0.0.tgz" + integrity sha1-L19Fq5HjMhYjT9U62rZo607AmTs= + dependencies: + graceful-fs "^4.1.2" + parse-json "^4.0.0" + pify "^3.0.0" + strip-bom "^3.0.0" + +locate-path@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-3.0.0.tgz" + integrity sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A== + dependencies: + p-locate "^3.0.0" + path-exists "^3.0.0" + +lodash.flattendeep@^4.4.0: + version "4.4.0" + resolved "https://registry.yarnpkg.com/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz" + integrity sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI= + +lodash.throttle@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/lodash.throttle/-/lodash.throttle-4.1.1.tgz" + integrity sha1-wj6RtxAkKscMN/HhzaknTMOb8vQ= + +lodash@^4.17.11, lodash@^4.17.4: + version "4.17.11" + resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz" + integrity sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg== + +log-driver@^1.2.7: + version "1.2.7" + resolved "https://registry.yarnpkg.com/log-driver/-/log-driver-1.2.7.tgz" + integrity sha512-U7KCmLdqsGHBLeWqYlFA0V0Sl6P08EE1ZrmA9cxjUE0WVqT9qnyVDPz1kzpFEP0jdJuFnasWIfSd7fsaNXkpbg== + +log-update@^3.0.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/log-update/-/log-update-3.2.0.tgz" + integrity sha512-KJ6zAPIHWo7Xg1jYror6IUDFJBq1bQ4Bi4wAEp2y/0ScjBBVi/g0thr0sUVhuvuXauWzczt7T2QHghPDNnKBuw== + dependencies: + ansi-escapes "^3.2.0" + cli-cursor "^2.1.0" + wrap-ansi "^5.0.0" + +loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.4.0.tgz" + integrity sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q== + dependencies: + js-tokens "^3.0.0||^4.0.0" + +lru-cache@^4.0.1: + version "4.1.5" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.5.tgz" + integrity sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g== + dependencies: + pseudomap "^1.0.2" + yallist "^2.1.2" + +make-dir@^2.0.0, make-dir@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-2.1.0.tgz" + integrity sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA== + dependencies: + pify "^4.0.1" + semver "^5.6.0" + +make-error@^1.1.1: + version "1.3.5" + resolved "https://registry.yarnpkg.com/make-error/-/make-error-1.3.5.tgz" + integrity sha512-c3sIjNUow0+8swNwVpqoH4YCShKNFkMaw6oH1mNS2haDZQqkeZFlHS3dhoeEbKKmJB4vXpJucU6oH75aDYeE9g== + +map-age-cleaner@^0.1.1: + version "0.1.3" + resolved "https://registry.yarnpkg.com/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz" + integrity sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w== + dependencies: + p-defer "^1.0.0" + +mem@^4.0.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/mem/-/mem-4.3.0.tgz" + integrity sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w== + dependencies: + map-age-cleaner "^0.1.1" + mimic-fn "^2.0.0" + p-is-promise "^2.0.0" + +merge-source-map@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/merge-source-map/-/merge-source-map-1.1.0.tgz" + integrity sha512-Qkcp7P2ygktpMPh2mCQZaf3jhN6D3Z/qVZHSdWvQ+2Ef5HgRAPBO57A77+ENm0CPx2+1Ce/MYKi3ymqdfuqibw== + dependencies: + source-map "^0.6.1" + +mime-db@1.40.0: + version "1.40.0" + resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.40.0.tgz" + integrity sha512-jYdeOMPy9vnxEqFRRo6ZvTZ8d9oPb+k18PKoYNYUe2stVEBPPwsln/qWzdbmaIvnhZ9v2P+CuecK+fpUfsV2mA== + +mime-types@^2.1.12, mime-types@~2.1.19: + version "2.1.24" + resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.24.tgz" + integrity sha512-WaFHS3MCl5fapm3oLxU4eYDw77IQM2ACcxQ9RIxfaC3ooc6PFuBMGZZsYpvoXS5D5QTWPieo1jjLdAm3TBP3cQ== + dependencies: + mime-db "1.40.0" + +mimic-fn@^1.0.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz" + integrity sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ== + +mimic-fn@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz" + integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== + +minimatch@^3.0.4: + version "3.0.4" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz" + integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== + dependencies: + brace-expansion "^1.1.7" + +minimist@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz" + integrity sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ= + +minimist@~0.0.1: + version "0.0.10" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz" + integrity sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8= + +minimist@0.0.8: + version "0.0.8" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz" + integrity sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0= + +minipass@^3.0.0: + version "3.1.1" + resolved "https://registry.yarnpkg.com/minipass/-/minipass-3.1.1.tgz" + integrity sha512-UFqVihv6PQgwj8/yTGvl9kPz7xIAY+R5z6XYjRInD3Gk3qx6QGSD6zEcpeG4Dy/lQnv1J6zv8ejV90hyYIKf3w== + dependencies: + yallist "^4.0.0" + +mkdirp@^0.5.0, mkdirp@^0.5.1: + version "0.5.1" + resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz" + integrity sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM= + dependencies: + minimist "0.0.8" + +ms@^2.1.1: + version "2.1.2" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz" + integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== + +ms@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz" + integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= + +neo-async@^2.6.0: + version "2.6.1" + resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.1.tgz" + integrity sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw== + +nested-error-stacks@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/nested-error-stacks/-/nested-error-stacks-2.1.0.tgz" + integrity sha512-AO81vsIO1k1sM4Zrd6Hu7regmJN1NSiAja10gc4bX3F0wd+9rQmcuHQaHVQCYIEC8iFXnE+mavh23GOt7wBgug== + +nice-try@^1.0.4: + version "1.0.5" + resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.5.tgz" + integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== + +node-modules-regexp@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz" + integrity sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA= + +normalize-package-data@^2.3.2: + version "2.5.0" + resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.5.0.tgz" + integrity sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA== + dependencies: + hosted-git-info "^2.1.4" + resolve "^1.10.0" + semver "2||3||4||5" + validate-npm-package-license "^3.0.1" + +normalize-path@^3.0.0, normalize-path@~3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz" + integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== + +npm-run-path@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-2.0.2.tgz" + integrity sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8= + dependencies: + path-key "^2.0.0" + +number-is-nan@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz" + integrity sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0= + +nyc@^14.1.1: + version "14.1.1" + resolved "https://registry.yarnpkg.com/nyc/-/nyc-14.1.1.tgz" + integrity sha512-OI0vm6ZGUnoGZv/tLdZ2esSVzDwUC88SNs+6JoSOMVxA+gKMB8Tk7jBwgemLx4O40lhhvZCVw1C+OYLOBOPXWw== + dependencies: + archy "^1.0.0" + caching-transform "^3.0.2" + convert-source-map "^1.6.0" + cp-file "^6.2.0" + find-cache-dir "^2.1.0" + find-up "^3.0.0" + foreground-child "^1.5.6" + glob "^7.1.3" + istanbul-lib-coverage "^2.0.5" + istanbul-lib-hook "^2.0.7" + istanbul-lib-instrument "^3.3.0" + istanbul-lib-report "^2.0.8" + istanbul-lib-source-maps "^3.0.6" + istanbul-reports "^2.2.4" + js-yaml "^3.13.1" + make-dir "^2.1.0" + merge-source-map "^1.1.0" + resolve-from "^4.0.0" + rimraf "^2.6.3" + signal-exit "^3.0.2" + spawn-wrap "^1.4.2" + test-exclude "^5.2.3" + uuid "^3.3.2" + yargs "^13.2.2" + yargs-parser "^13.0.0" + +oauth-sign@~0.9.0: + version "0.9.0" + resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz" + integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== + +object-assign@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz" + integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= + +once@^1.3.0, once@^1.3.1, once@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz" + integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= + dependencies: + wrappy "1" + +onetime@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/onetime/-/onetime-2.0.1.tgz" + integrity sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ= + dependencies: + mimic-fn "^1.0.0" + +opener@^1.5.1: + version "1.5.1" + resolved "https://registry.yarnpkg.com/opener/-/opener-1.5.1.tgz" + integrity sha512-goYSy5c2UXE4Ra1xixabeVh1guIX/ZV/YokJksb6q2lubWu6UbvPQ20p542/sFIll1nl8JnCyK9oBaOcCWXwvA== + +optimist@^0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/optimist/-/optimist-0.6.1.tgz" + integrity sha1-2j6nRob6IaGaERwybpDrFaAZZoY= + dependencies: + minimist "~0.0.1" + wordwrap "~0.0.2" + +os-homedir@^1.0.0, os-homedir@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/os-homedir/-/os-homedir-1.0.2.tgz" + integrity sha1-/7xJiDNuDoM94MFox+8VISGqf7M= + +os-locale@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-3.1.0.tgz" + integrity sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q== + dependencies: + execa "^1.0.0" + lcid "^2.0.0" + mem "^4.0.0" + +os-tmpdir@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz" + integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= + +own-or-env@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/own-or-env/-/own-or-env-1.0.1.tgz" + integrity sha512-y8qULRbRAlL6x2+M0vIe7jJbJx/kmUTzYonRAa2ayesR2qWLswninkVyeJe4x3IEXhdgoNodzjQRKAoEs6Fmrw== + dependencies: + own-or "^1.0.0" + +own-or@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/own-or/-/own-or-1.0.0.tgz" + integrity sha1-Tod/vtqaLsgAD7wLyuOWRe6L+Nw= + +p-defer@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/p-defer/-/p-defer-1.0.0.tgz" + integrity sha1-n26xgvbJqozXQwBKfU+WsZaw+ww= + +p-finally@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz" + integrity sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4= + +p-is-promise@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/p-is-promise/-/p-is-promise-2.1.0.tgz" + integrity sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg== + +p-limit@^2.0.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.2.0.tgz" + integrity sha512-pZbTJpoUsCzV48Mc9Nh51VbwO0X9cuPFE8gYwx9BTCt9SF8/b7Zljd2fVgOxhIF/HDTKgpVzs+GPhyKfjLLFRQ== + dependencies: + p-try "^2.0.0" + +p-locate@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-3.0.0.tgz" + integrity sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ== + dependencies: + p-limit "^2.0.0" + +p-try@^2.0.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.2.0.tgz" + integrity sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ== + +package-hash@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/package-hash/-/package-hash-3.0.0.tgz" + integrity sha512-lOtmukMDVvtkL84rJHI7dpTYq+0rli8N2wlnqUcBuDWCfVhRUfOmnR9SsoHFMLpACvEV60dX7rd0rFaYDZI+FA== + dependencies: + graceful-fs "^4.1.15" + hasha "^3.0.0" + lodash.flattendeep "^4.4.0" + release-zalgo "^1.0.0" + +parse-json@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-4.0.0.tgz" + integrity sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA= + dependencies: + error-ex "^1.3.1" + json-parse-better-errors "^1.0.1" + +path-exists@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz" + integrity sha1-zg6+ql94yxiSXqfYENe1mwEP1RU= + +path-is-absolute@^1.0.0, path-is-absolute@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz" + integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= + +path-key@^2.0.0, path-key@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz" + integrity sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A= + +path-parse@^1.0.6: + version "1.0.6" + resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.6.tgz" + integrity sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw== + +path-type@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/path-type/-/path-type-3.0.0.tgz" + integrity sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg== + dependencies: + pify "^3.0.0" + +performance-now@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz" + integrity sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns= + +picomatch@^2.0.4: + version "2.0.7" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.0.7.tgz" + integrity sha512-oLHIdio3tZ0qH76NybpeneBhYVj0QFTfXEFTc/B3zKQspYfYYkWYgFsmzo+4kvId/bQRcNkVeguI3y+CD22BtA== + +pify@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/pify/-/pify-3.0.0.tgz" + integrity sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY= + +pify@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/pify/-/pify-4.0.1.tgz" + integrity sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g== + +pirates@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/pirates/-/pirates-3.0.2.tgz" + integrity sha512-c5CgUJq6H2k6MJz72Ak1F5sN9n9wlSlJyEnwvpm9/y3WB4E3pHBDT2c6PEiS1vyJvq2bUxUAIu0EGf8Cx4Ic7Q== + dependencies: + node-modules-regexp "^1.0.0" + +pkg-dir@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-3.0.0.tgz" + integrity sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw== + dependencies: + find-up "^3.0.0" + +private@^0.1.8: + version "0.1.8" + resolved "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz" + integrity sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg== + +process-nextick-args@~2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz" + integrity sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag== + +prop-types@^15.6.2: + version "15.7.2" + resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.7.2.tgz" + integrity sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ== + dependencies: + loose-envify "^1.4.0" + object-assign "^4.1.1" + react-is "^16.8.1" + +pseudomap@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz" + integrity sha1-8FKijacOYYkX7wqKw0wa5aaChrM= + +psl@^1.1.24: + version "1.2.0" + resolved "https://registry.yarnpkg.com/psl/-/psl-1.2.0.tgz" + integrity sha512-GEn74ZffufCmkDDLNcl3uuyF/aSD6exEyh1v/ZSdAomB82t6G9hzJVRx0jBmLDW+VfZqks3aScmMw9DszwUalA== + +pump@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/pump/-/pump-3.0.0.tgz" + integrity sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww== + dependencies: + end-of-stream "^1.1.0" + once "^1.3.1" + +punycode@^1.3.2, punycode@^1.4.1: + version "1.4.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz" + integrity sha1-wNWmOycYgArY4esPpSachN1BhF4= + +punycode@^2.0.0, punycode@^2.1.0: + version "2.1.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz" + integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== + +qs@~6.5.2: + version "6.5.2" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz" + integrity sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA== + +react-is@^16.8.1: + version "16.8.6" + resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.8.6.tgz" + integrity sha512-aUk3bHfZ2bRSVFFbbeVS4i+lNPZr3/WM5jT2J5omUVV1zzcs1nAaf3l51ctA5FFvCRbhrH0bdAsRRQddFJZPtA== + +react-reconciler@^0.20.0: + version "0.20.4" + resolved "https://registry.yarnpkg.com/react-reconciler/-/react-reconciler-0.20.4.tgz" + integrity sha512-kxERc4H32zV2lXMg/iMiwQHOtyqf15qojvkcZ5Ja2CPkjVohHw9k70pdDBwrnQhLVetUJBSYyqU3yqrlVTOajA== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + prop-types "^15.6.2" + scheduler "^0.13.6" + +react@^16.8.6: + version "16.8.6" + resolved "https://registry.yarnpkg.com/react/-/react-16.8.6.tgz" + integrity sha512-pC0uMkhLaHm11ZSJULfOBqV4tIZkx87ZLvbbQYunNixAAvjnC+snJCg0XQXn9VIsttVsbZP/H/ewzgsd5fxKXw== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + prop-types "^15.6.2" + scheduler "^0.13.6" + +react@^16.9.0: + version "16.12.0" + resolved "https://registry.yarnpkg.com/react/-/react-16.12.0.tgz" + integrity sha512-fglqy3k5E+81pA8s+7K0/T3DBCF0ZDOher1elBFzF7O6arXJgzyu/FW+COxFvAWXJoJN9KIZbT2LXlukwphYTA== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + prop-types "^15.6.2" + +read-pkg-up@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-4.0.0.tgz" + integrity sha512-6etQSH7nJGsK0RbG/2TeDzZFa8shjQ1um+SwQQ5cwKy0dhSXdOncEhb1CPpvQG4h7FyOV6EB6YlV0yJvZQNAkA== + dependencies: + find-up "^3.0.0" + read-pkg "^3.0.0" + +read-pkg@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-3.0.0.tgz" + integrity sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k= + dependencies: + load-json-file "^4.0.0" + normalize-package-data "^2.3.2" + path-type "^3.0.0" + +readable-stream@^2.1.5: + version "2.3.6" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz" + integrity sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw== + dependencies: + core-util-is "~1.0.0" + inherits "~2.0.3" + isarray "~1.0.0" + process-nextick-args "~2.0.0" + safe-buffer "~5.1.1" + string_decoder "~1.1.1" + util-deprecate "~1.0.1" + +readdirp@~3.2.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.2.0.tgz" + integrity sha512-crk4Qu3pmXwgxdSgGhgA/eXiJAPQiX4GMOZZMXnqKxHX7TaoL+3gQVo/WeuAiogr07DpnfjIMpXXa+PAIvwPGQ== + dependencies: + picomatch "^2.0.4" + +redeyed@~2.1.0: + version "2.1.1" + resolved "https://registry.yarnpkg.com/redeyed/-/redeyed-2.1.1.tgz" + integrity sha1-iYS1gV2ZyyIEacme7v/jiRPmzAs= + dependencies: + esprima "~4.0.0" + +regenerator-runtime@^0.11.0: + version "0.11.1" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz" + integrity sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg== + +regenerator-runtime@^0.13.2: + version "0.13.2" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.2.tgz" + integrity sha512-S/TQAZJO+D3m9xeN1WTI8dLKBBiRgXBlTJvbWjCThHWZj9EvHK70Ff50/tYj2J/fvBY6JtFVwRuazHN2E7M9BA== + +release-zalgo@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/release-zalgo/-/release-zalgo-1.0.0.tgz" + integrity sha1-CXALflB0Mpc5Mw5TXFqQ+2eFFzA= + dependencies: + es6-error "^4.0.1" + +repeating@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/repeating/-/repeating-2.0.1.tgz" + integrity sha1-UhTFOpJtNVJwdSf7q0FdvAjQbdo= + dependencies: + is-finite "^1.0.0" + +request@^2.86.0: + version "2.88.0" + resolved "https://registry.yarnpkg.com/request/-/request-2.88.0.tgz" + integrity sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg== + dependencies: + aws-sign2 "~0.7.0" + aws4 "^1.8.0" + caseless "~0.12.0" + combined-stream "~1.0.6" + extend "~3.0.2" + forever-agent "~0.6.1" + form-data "~2.3.2" + har-validator "~5.1.0" + http-signature "~1.2.0" + is-typedarray "~1.0.0" + isstream "~0.1.2" + json-stringify-safe "~5.0.1" + mime-types "~2.1.19" + oauth-sign "~0.9.0" + performance-now "^2.1.0" + qs "~6.5.2" + safe-buffer "^5.1.2" + tough-cookie "~2.4.3" + tunnel-agent "^0.6.0" + uuid "^3.3.2" + +require-directory@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz" + integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= + +require-main-filename@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-2.0.0.tgz" + integrity sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg== + +resolve-from@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-3.0.0.tgz" + integrity sha1-six699nWiBvItuZTM17rywoYh0g= + +resolve-from@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz" + integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== + +resolve@^1.10.0: + version "1.11.1" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.11.1.tgz" + integrity sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw== + dependencies: + path-parse "^1.0.6" + +restore-cursor@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz" + integrity sha1-n37ih/gv0ybU/RYpI9YhKe7g368= + dependencies: + onetime "^2.0.0" + signal-exit "^3.0.2" + +rimraf@^2.6.2, rimraf@^2.6.3: + version "2.6.3" + resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz" + integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA== + dependencies: + glob "^7.1.3" + +rimraf@^2.7.1: + version "2.7.1" + resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.7.1.tgz" + integrity sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w== + dependencies: + glob "^7.1.3" + +safe-buffer@^5.0.1, safe-buffer@^5.1.2: + version "5.2.0" + resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.0.tgz" + integrity sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg== + +safe-buffer@~5.1.0, safe-buffer@~5.1.1: + version "5.1.2" + resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz" + integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== + +safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: + version "2.1.2" + resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz" + integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== + +scheduler@^0.13.2, scheduler@^0.13.6: + version "0.13.6" + resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.13.6.tgz" + integrity sha512-IWnObHt413ucAYKsD9J1QShUKkbKLQQHdxRyw73sw4FN26iWr3DY/H34xGPe4nmL1DwXyWmSWmMrA9TfQbE/XQ== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + +semver@^5.5.0, semver@^5.6.0, "semver@2 || 3 || 4 || 5": + version "5.7.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.0.tgz" + integrity sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA== + +semver@^6.0.0: + version "6.2.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.2.0.tgz" + integrity sha512-jdFC1VdUGT/2Scgbimf7FSx9iJLXoqfglSF+gJeuNWVpiE37OIbc1jywR/GJyFdz3mnkz2/id0L0J/cr0izR5A== + +set-blocking@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz" + integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc= + +shebang-command@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz" + integrity sha1-RKrGW2lbAzmJaMOfNj/uXer98eo= + dependencies: + shebang-regex "^1.0.0" + +shebang-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz" + integrity sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM= + +signal-exit@^3.0.0, signal-exit@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz" + integrity sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0= + +slash@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/slash/-/slash-1.0.0.tgz" + integrity sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU= + +slice-ansi@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-1.0.0.tgz" + integrity sha512-POqxBK6Lb3q6s047D/XsDVNPnF9Dl8JSaqe9h9lURl0OdNqy/ujDrOiIHtsqXMGbWWTIomRzAMaTyawAU//Reg== + dependencies: + is-fullwidth-code-point "^2.0.0" + +source-map-support@^0.4.15: + version "0.4.18" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.4.18.tgz" + integrity sha512-try0/JqxPLF9nOjvSta7tVondkP5dwgyLDjVoyMDlmjugT2lRZ1OfsrYTkCd2hkDnJTKRbO/Rl3orm8vlsUzbA== + dependencies: + source-map "^0.5.6" + +source-map-support@^0.5.11, source-map-support@^0.5.6: + version "0.5.12" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.12.tgz" + integrity sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + +source-map-support@^0.5.16: + version "0.5.16" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.16.tgz" + integrity sha512-efyLRJDr68D9hBBNIPWFjhpFzURh+KJykQwvMyW5UiZzYwoF6l4YMMDIJJEyFWxWCqfyxLzz6tSfUFR+kXXsVQ== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + +source-map@^0.5.0, source-map@^0.5.6, source-map@^0.5.7: + version "0.5.7" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz" + integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= + +source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz" + integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== + +spawn-wrap@^1.4.2: + version "1.4.2" + resolved "https://registry.yarnpkg.com/spawn-wrap/-/spawn-wrap-1.4.2.tgz" + integrity sha512-vMwR3OmmDhnxCVxM8M+xO/FtIp6Ju/mNaDfCMMW7FDcLRTPFWUswec4LXJHTJE2hwTI9O0YBfygu4DalFl7Ylg== + dependencies: + foreground-child "^1.5.6" + mkdirp "^0.5.0" + os-homedir "^1.0.1" + rimraf "^2.6.2" + signal-exit "^3.0.2" + which "^1.3.0" + +spdx-correct@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.0.tgz" + integrity sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q== + dependencies: + spdx-expression-parse "^3.0.0" + spdx-license-ids "^3.0.0" + +spdx-exceptions@^2.1.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz" + integrity sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA== + +spdx-expression-parse@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz" + integrity sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg== + dependencies: + spdx-exceptions "^2.1.0" + spdx-license-ids "^3.0.0" + +spdx-license-ids@^3.0.0: + version "3.0.4" + resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.4.tgz" + integrity sha512-7j8LYJLeY/Yb6ACbQ7F76qy5jHkp0U6jgBfJsk97bwWlVUnUWsAgpyaCvo17h0/RQGnQ036tVDomiwoI4pDkQA== + +sprintf-js@~1.0.2: + version "1.0.3" + resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz" + integrity sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw= + +sshpk@^1.7.0: + version "1.16.1" + resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.16.1.tgz" + integrity sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg== + dependencies: + asn1 "~0.2.3" + assert-plus "^1.0.0" + bcrypt-pbkdf "^1.0.0" + dashdash "^1.12.0" + ecc-jsbn "~0.1.1" + getpass "^0.1.1" + jsbn "~0.1.0" + safer-buffer "^2.0.2" + tweetnacl "~0.14.0" + +stack-utils@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/stack-utils/-/stack-utils-1.0.2.tgz" + integrity sha512-MTX+MeG5U994cazkjd/9KNAapsHnibjMLnfXodlkXw76JEea0UiNzrqidzo1emMwk7w5Qhc9jd4Bn9TBb1MFwA== + +string_decoder@~1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz" + integrity sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg== + dependencies: + safe-buffer "~5.1.0" + +string-length@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/string-length/-/string-length-2.0.0.tgz" + integrity sha1-1A27aGo6zpYMHP/KVivyxF+DY+0= + dependencies: + astral-regex "^1.0.0" + strip-ansi "^4.0.0" + +string-width@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz" + integrity sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M= + dependencies: + code-point-at "^1.0.0" + is-fullwidth-code-point "^1.0.0" + strip-ansi "^3.0.0" + +string-width@^2.0.0, string-width@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz" + integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== + dependencies: + is-fullwidth-code-point "^2.0.0" + strip-ansi "^4.0.0" + +string-width@^3.0.0, string-width@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-3.1.0.tgz" + integrity sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w== + dependencies: + emoji-regex "^7.0.1" + is-fullwidth-code-point "^2.0.0" + strip-ansi "^5.1.0" + +strip-ansi@^3.0.0, strip-ansi@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz" + integrity sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8= + dependencies: + ansi-regex "^2.0.0" + +strip-ansi@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-4.0.0.tgz" + integrity sha1-qEeQIusaw2iocTibY1JixQXuNo8= + dependencies: + ansi-regex "^3.0.0" + +strip-ansi@^5.0.0, strip-ansi@^5.1.0, strip-ansi@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-5.2.0.tgz" + integrity sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA== + dependencies: + ansi-regex "^4.1.0" + +strip-bom@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-3.0.0.tgz" + integrity sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM= + +strip-eof@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/strip-eof/-/strip-eof-1.0.0.tgz" + integrity sha1-u0P/VZim6wXYm1n80SnJgzE2Br8= + +supports-color@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz" + integrity sha1-U10EXOa2Nj+kARcIRimZXp3zJMc= + +supports-color@^5.3.0: + version "5.5.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz" + integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== + dependencies: + has-flag "^3.0.0" + +supports-color@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-6.1.0.tgz" + integrity sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ== + dependencies: + has-flag "^3.0.0" + +tap-mocha-reporter@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/tap-mocha-reporter/-/tap-mocha-reporter-5.0.0.tgz" + integrity sha512-8HlAtdmYGlDZuW83QbF/dc46L7cN+AGhLZcanX3I9ILvxUAl+G2/mtucNPSXecTlG/4iP1hv6oMo0tMhkn3Tsw== + dependencies: + color-support "^1.1.0" + debug "^2.1.3" + diff "^1.3.2" + escape-string-regexp "^1.0.3" + glob "^7.0.5" + tap-parser "^10.0.0" + tap-yaml "^1.0.0" + unicode-length "^1.0.0" optionalDependencies: - "readable-stream" "^2.1.5" + readable-stream "^2.1.5" -"tap-parser@^10.0.0", "tap-parser@^10.0.1": - "integrity" "sha512-qdT15H0DoJIi7zOqVXDn9X0gSM68JjNy1w3VemwTJlDnETjbi6SutnqmBfjDJAwkFS79NJ97gZKqie00ZCGmzg==" - "resolved" "https://registry.yarnpkg.com/tap-parser/-/tap-parser-10.0.1.tgz" - "version" "10.0.1" +tap-parser@^10.0.0, tap-parser@^10.0.1: + version "10.0.1" + resolved "https://registry.yarnpkg.com/tap-parser/-/tap-parser-10.0.1.tgz" + integrity sha512-qdT15H0DoJIi7zOqVXDn9X0gSM68JjNy1w3VemwTJlDnETjbi6SutnqmBfjDJAwkFS79NJ97gZKqie00ZCGmzg== dependencies: - "events-to-array" "^1.0.1" - "minipass" "^3.0.0" - "tap-yaml" "^1.0.0" + events-to-array "^1.0.1" + minipass "^3.0.0" + tap-yaml "^1.0.0" -"tap-yaml@^1.0.0": - "integrity" "sha512-Rxbx4EnrWkYk0/ztcm5u3/VznbyFJpyXO12dDBHKWiDVxy7O2Qw6MRrwO5H6Ww0U5YhRY/4C/VzWmFPhBQc4qQ==" - "resolved" "https://registry.yarnpkg.com/tap-yaml/-/tap-yaml-1.0.0.tgz" - "version" "1.0.0" +tap-yaml@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/tap-yaml/-/tap-yaml-1.0.0.tgz" + integrity sha512-Rxbx4EnrWkYk0/ztcm5u3/VznbyFJpyXO12dDBHKWiDVxy7O2Qw6MRrwO5H6Ww0U5YhRY/4C/VzWmFPhBQc4qQ== dependencies: - "yaml" "^1.5.0" + yaml "^1.5.0" -"tcompare@^2.3.0": - "integrity" "sha512-fAfA73uFtFGybWGt4+IYT6UPLYVZQ4NfsP+IXEZGY0vh8e2IF7LVKafcQNMRBLqP0wzEA65LM9Tqj+FSmO8GLw==" - "resolved" "https://registry.yarnpkg.com/tcompare/-/tcompare-2.3.0.tgz" - "version" "2.3.0" +tcompare@^2.3.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/tcompare/-/tcompare-2.3.0.tgz" + integrity sha512-fAfA73uFtFGybWGt4+IYT6UPLYVZQ4NfsP+IXEZGY0vh8e2IF7LVKafcQNMRBLqP0wzEA65LM9Tqj+FSmO8GLw== -"test-exclude@^5.2.3": - "integrity" "sha512-M+oxtseCFO3EDtAaGH7iiej3CBkzXqFMbzqYAACdzKui4eZA+pq3tZEwChvOdNfa7xxy8BfbmgJSIr43cC/+2g==" - "resolved" "https://registry.yarnpkg.com/test-exclude/-/test-exclude-5.2.3.tgz" - "version" "5.2.3" +test-exclude@^5.2.3: + version "5.2.3" + resolved "https://registry.yarnpkg.com/test-exclude/-/test-exclude-5.2.3.tgz" + integrity sha512-M+oxtseCFO3EDtAaGH7iiej3CBkzXqFMbzqYAACdzKui4eZA+pq3tZEwChvOdNfa7xxy8BfbmgJSIr43cC/+2g== dependencies: - "glob" "^7.1.3" - "minimatch" "^3.0.4" - "read-pkg-up" "^4.0.0" - "require-main-filename" "^2.0.0" + glob "^7.1.3" + minimatch "^3.0.4" + read-pkg-up "^4.0.0" + require-main-filename "^2.0.0" -"to-fast-properties@^1.0.3": - "integrity" "sha1-uDVx+k2MJbguIxsG46MFXeTKGkc=" - "resolved" "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-1.0.3.tgz" - "version" "1.0.3" +to-fast-properties@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-1.0.3.tgz" + integrity sha1-uDVx+k2MJbguIxsG46MFXeTKGkc= -"to-fast-properties@^2.0.0": - "integrity" "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=" - "resolved" "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz" - "version" "2.0.0" +to-fast-properties@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz" + integrity sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4= -"to-regex-range@^5.0.1": - "integrity" "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==" - "resolved" "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz" - "version" "5.0.1" +to-regex-range@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz" + integrity sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ== dependencies: - "is-number" "^7.0.0" + is-number "^7.0.0" -"tough-cookie@~2.4.3": - "integrity" "sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ==" - "resolved" "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.4.3.tgz" - "version" "2.4.3" +tough-cookie@~2.4.3: + version "2.4.3" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.4.3.tgz" + integrity sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ== dependencies: - "psl" "^1.1.24" - "punycode" "^1.4.1" + psl "^1.1.24" + punycode "^1.4.1" -"treport@^0.4.2": - "integrity" "sha512-Po8pQ/rmu4lVNmZWBgqyiHoIWXFeWaMA3H/WoCKw+DiS0xFn43UYRH6hYnjmrWCp0rkLItELQP/maO9uHDe/7A==" - "resolved" "https://registry.yarnpkg.com/treport/-/treport-0.4.2.tgz" - "version" "0.4.2" +treport@^0.4.2: + version "0.4.2" + resolved "https://registry.yarnpkg.com/treport/-/treport-0.4.2.tgz" + integrity sha512-Po8pQ/rmu4lVNmZWBgqyiHoIWXFeWaMA3H/WoCKw+DiS0xFn43UYRH6hYnjmrWCp0rkLItELQP/maO9uHDe/7A== dependencies: - "cardinal" "^2.1.1" - "chalk" "^2.4.2" - "import-jsx" "^2.0.0" - "ink" "^2.1.1" - "ms" "^2.1.1" - "react" "^16.8.6" - "string-length" "^2.0.0" - "tap-parser" "^10.0.1" - "unicode-length" "^2.0.1" + cardinal "^2.1.1" + chalk "^2.4.2" + import-jsx "^2.0.0" + ink "^2.1.1" + ms "^2.1.1" + react "^16.8.6" + string-length "^2.0.0" + tap-parser "^10.0.1" + unicode-length "^2.0.1" -"trim-right@^1.0.1": - "integrity" "sha1-yy4SAwZ+DI3h9hQJS5/kVwTqYAM=" - "resolved" "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz" - "version" "1.0.1" +trim-right@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz" + integrity sha1-yy4SAwZ+DI3h9hQJS5/kVwTqYAM= -"trivial-deferred@^1.0.1": - "integrity" "sha1-N21NKdlR1jaKb3oK6FwvTV4GWPM=" - "resolved" "https://registry.yarnpkg.com/trivial-deferred/-/trivial-deferred-1.0.1.tgz" - "version" "1.0.1" +trivial-deferred@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/trivial-deferred/-/trivial-deferred-1.0.1.tgz" + integrity sha1-N21NKdlR1jaKb3oK6FwvTV4GWPM= -"ts-node@^8.3.0": - "integrity" "sha512-dyNS/RqyVTDcmNM4NIBAeDMpsAdaQ+ojdf0GOLqE6nwJOgzEkdRNzJywhDfwnuvB10oa6NLVG1rUJQCpRN7qoQ==" - "resolved" "https://registry.yarnpkg.com/ts-node/-/ts-node-8.3.0.tgz" - "version" "8.3.0" +ts-node@^8.3.0: + version "8.3.0" + resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-8.3.0.tgz" + integrity sha512-dyNS/RqyVTDcmNM4NIBAeDMpsAdaQ+ojdf0GOLqE6nwJOgzEkdRNzJywhDfwnuvB10oa6NLVG1rUJQCpRN7qoQ== dependencies: - "arg" "^4.1.0" - "diff" "^4.0.1" - "make-error" "^1.1.1" - "source-map-support" "^0.5.6" - "yn" "^3.0.0" + arg "^4.1.0" + diff "^4.0.1" + make-error "^1.1.1" + source-map-support "^0.5.6" + yn "^3.0.0" -"tunnel-agent@^0.6.0": - "integrity" "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=" - "resolved" "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz" - "version" "0.6.0" +tunnel-agent@^0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz" + integrity sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0= dependencies: - "safe-buffer" "^5.0.1" + safe-buffer "^5.0.1" -"tweetnacl@^0.14.3", "tweetnacl@~0.14.0": - "integrity" "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=" - "resolved" "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz" - "version" "0.14.5" +tweetnacl@^0.14.3, tweetnacl@~0.14.0: + version "0.14.5" + resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz" + integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q= -"typedarray-to-buffer@^3.1.5": - "integrity" "sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==" - "resolved" "https://registry.yarnpkg.com/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz" - "version" "3.1.5" +typedarray-to-buffer@^3.1.5: + version "3.1.5" + resolved "https://registry.yarnpkg.com/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz" + integrity sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q== dependencies: - "is-typedarray" "^1.0.0" + is-typedarray "^1.0.0" -"typescript@^3.6.3": - "integrity" "sha512-ml7V7JfiN2Xwvcer+XAf2csGO1bPBdRbFCkYBczNZggrBZ9c7G3riSUeJmqEU5uOtXNPMhE3n+R4FA/3YOAWOQ==" - "resolved" "https://registry.yarnpkg.com/typescript/-/typescript-3.7.2.tgz" - "version" "3.7.2" +typescript@^3.6.3: + version "3.7.2" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.7.2.tgz" + integrity sha512-ml7V7JfiN2Xwvcer+XAf2csGO1bPBdRbFCkYBczNZggrBZ9c7G3riSUeJmqEU5uOtXNPMhE3n+R4FA/3YOAWOQ== -"uglify-js@^3.1.4": - "integrity" "sha512-W+jrUHJr3DXKhrsS7NUVxn3zqMOFn0hL/Ei6v0anCIMoKC93TjcflTagwIHLW7SfMFfiQuktQyFVCFHGUE0+yg==" - "resolved" "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.6.0.tgz" - "version" "3.6.0" +uglify-js@^3.1.4: + version "3.6.0" + resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.6.0.tgz" + integrity sha512-W+jrUHJr3DXKhrsS7NUVxn3zqMOFn0hL/Ei6v0anCIMoKC93TjcflTagwIHLW7SfMFfiQuktQyFVCFHGUE0+yg== dependencies: - "commander" "~2.20.0" - "source-map" "~0.6.1" + commander "~2.20.0" + source-map "~0.6.1" -"unicode-length@^1.0.0": - "integrity" "sha1-Wtp6f+1RhBpBijKM8UlHisg1irs=" - "resolved" "https://registry.yarnpkg.com/unicode-length/-/unicode-length-1.0.3.tgz" - "version" "1.0.3" +unicode-length@^1.0.0: + version "1.0.3" + resolved "https://registry.yarnpkg.com/unicode-length/-/unicode-length-1.0.3.tgz" + integrity sha1-Wtp6f+1RhBpBijKM8UlHisg1irs= dependencies: - "punycode" "^1.3.2" - "strip-ansi" "^3.0.1" + punycode "^1.3.2" + strip-ansi "^3.0.1" -"unicode-length@^2.0.1": - "integrity" "sha512-Ph/j1VbS3/r77nhoY2WU0GWGjVYOHL3xpKp0y/Eq2e5r0mT/6b649vm7KFO6RdAdrZkYLdxphYVgvODxPB+Ebg==" - "resolved" "https://registry.yarnpkg.com/unicode-length/-/unicode-length-2.0.2.tgz" - "version" "2.0.2" +unicode-length@^2.0.1: + version "2.0.2" + resolved "https://registry.yarnpkg.com/unicode-length/-/unicode-length-2.0.2.tgz" + integrity sha512-Ph/j1VbS3/r77nhoY2WU0GWGjVYOHL3xpKp0y/Eq2e5r0mT/6b649vm7KFO6RdAdrZkYLdxphYVgvODxPB+Ebg== dependencies: - "punycode" "^2.0.0" - "strip-ansi" "^3.0.1" + punycode "^2.0.0" + strip-ansi "^3.0.1" -"uri-js@^4.2.2": - "integrity" "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==" - "resolved" "https://registry.yarnpkg.com/uri-js/-/uri-js-4.2.2.tgz" - "version" "4.2.2" +uri-js@^4.2.2: + version "4.2.2" + resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.2.2.tgz" + integrity sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ== dependencies: - "punycode" "^2.1.0" + punycode "^2.1.0" -"util-deprecate@~1.0.1": - "integrity" "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" - "resolved" "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz" - "version" "1.0.2" +util-deprecate@~1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz" + integrity sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8= -"uuid@^3.3.2": - "integrity" "sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA==" - "resolved" "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz" - "version" "3.3.2" +uuid@^3.3.2: + version "3.3.2" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz" + integrity sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA== -"validate-npm-package-license@^3.0.1": - "integrity" "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==" - "resolved" "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz" - "version" "3.0.4" +validate-npm-package-license@^3.0.1: + version "3.0.4" + resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz" + integrity sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew== dependencies: - "spdx-correct" "^3.0.0" - "spdx-expression-parse" "^3.0.0" + spdx-correct "^3.0.0" + spdx-expression-parse "^3.0.0" -"verror@1.10.0": - "integrity" "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=" - "resolved" "https://registry.yarnpkg.com/verror/-/verror-1.10.0.tgz" - "version" "1.10.0" +verror@1.10.0: + version "1.10.0" + resolved "https://registry.yarnpkg.com/verror/-/verror-1.10.0.tgz" + integrity sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA= dependencies: - "assert-plus" "^1.0.0" - "core-util-is" "1.0.2" - "extsprintf" "^1.2.0" + assert-plus "^1.0.0" + core-util-is "1.0.2" + extsprintf "^1.2.0" -"vlq@^0.2.1": - "integrity" "sha512-DRibZL6DsNhIgYQ+wNdWDL2SL3bKPlVrRiBqV5yuMm++op8W4kGFtaQfCs4KEJn0wBZcHVHJ3eoywX8983k1ow==" - "resolved" "https://registry.yarnpkg.com/vlq/-/vlq-0.2.3.tgz" - "version" "0.2.3" +vlq@^0.2.1: + version "0.2.3" + resolved "https://registry.yarnpkg.com/vlq/-/vlq-0.2.3.tgz" + integrity sha512-DRibZL6DsNhIgYQ+wNdWDL2SL3bKPlVrRiBqV5yuMm++op8W4kGFtaQfCs4KEJn0wBZcHVHJ3eoywX8983k1ow== -"which-module@^2.0.0": - "integrity" "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=" - "resolved" "https://registry.yarnpkg.com/which-module/-/which-module-2.0.0.tgz" - "version" "2.0.0" +which-module@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/which-module/-/which-module-2.0.0.tgz" + integrity sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho= -"which@^1.2.9", "which@^1.3.0": - "integrity" "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==" - "resolved" "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz" - "version" "1.3.1" +which@^1.2.9, which@^1.3.0: + version "1.3.1" + resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz" + integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== dependencies: - "isexe" "^2.0.0" + isexe "^2.0.0" -"which@^2.0.1": - "integrity" "sha512-N7GBZOTswtB9lkQBZA4+zAXrjEIWAUOB93AvzUiudRzRxhUdLURQ7D/gAIMY1gatT/LTbmbcv8SiYazy3eYB7w==" - "resolved" "https://registry.yarnpkg.com/which/-/which-2.0.1.tgz" - "version" "2.0.1" +which@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/which/-/which-2.0.1.tgz" + integrity sha512-N7GBZOTswtB9lkQBZA4+zAXrjEIWAUOB93AvzUiudRzRxhUdLURQ7D/gAIMY1gatT/LTbmbcv8SiYazy3eYB7w== dependencies: - "isexe" "^2.0.0" + isexe "^2.0.0" -"widest-line@^2.0.0": - "integrity" "sha512-Ba5m9/Fa4Xt9eb2ELXt77JxVDV8w7qQrH0zS/TWSJdLyAwQjWoOzpzj5lwVftDz6n/EOu3tNACS84v509qwnJA==" - "resolved" "https://registry.yarnpkg.com/widest-line/-/widest-line-2.0.1.tgz" - "version" "2.0.1" +widest-line@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/widest-line/-/widest-line-2.0.1.tgz" + integrity sha512-Ba5m9/Fa4Xt9eb2ELXt77JxVDV8w7qQrH0zS/TWSJdLyAwQjWoOzpzj5lwVftDz6n/EOu3tNACS84v509qwnJA== dependencies: - "string-width" "^2.1.1" + string-width "^2.1.1" -"wordwrap@~0.0.2": - "integrity" "sha1-o9XabNXAvAAI03I0u68b7WMFkQc=" - "resolved" "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz" - "version" "0.0.3" +wordwrap@~0.0.2: + version "0.0.3" + resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz" + integrity sha1-o9XabNXAvAAI03I0u68b7WMFkQc= -"wrap-ansi@^2.0.0": - "integrity" "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=" - "resolved" "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz" - "version" "2.1.0" +wrap-ansi@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz" + integrity sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU= dependencies: - "string-width" "^1.0.1" - "strip-ansi" "^3.0.1" + string-width "^1.0.1" + strip-ansi "^3.0.1" -"wrap-ansi@^5.0.0", "wrap-ansi@^5.1.0": - "integrity" "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==" - "resolved" "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-5.1.0.tgz" - "version" "5.1.0" +wrap-ansi@^5.0.0, wrap-ansi@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-5.1.0.tgz" + integrity sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q== dependencies: - "ansi-styles" "^3.2.0" - "string-width" "^3.0.0" - "strip-ansi" "^5.0.0" + ansi-styles "^3.2.0" + string-width "^3.0.0" + strip-ansi "^5.0.0" -"wrappy@1": - "integrity" "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" - "resolved" "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz" - "version" "1.0.2" +wrappy@1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz" + integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= -"write-file-atomic@^2.4.2": - "integrity" "sha512-GaETH5wwsX+GcnzhPgKcKjJ6M2Cq3/iZp1WyY/X1CSqrW+jVNM9Y7D8EC2sM4ZG/V8wZlSniJnCKWPmBYAucRQ==" - "resolved" "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-2.4.3.tgz" - "version" "2.4.3" +write-file-atomic@^2.4.2: + version "2.4.3" + resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-2.4.3.tgz" + integrity sha512-GaETH5wwsX+GcnzhPgKcKjJ6M2Cq3/iZp1WyY/X1CSqrW+jVNM9Y7D8EC2sM4ZG/V8wZlSniJnCKWPmBYAucRQ== dependencies: - "graceful-fs" "^4.1.11" - "imurmurhash" "^0.1.4" - "signal-exit" "^3.0.2" + graceful-fs "^4.1.11" + imurmurhash "^0.1.4" + signal-exit "^3.0.2" -"write-file-atomic@^3.0.0": - "integrity" "sha512-EIgkf60l2oWsffja2Sf2AL384dx328c0B+cIYPTQq5q2rOYuDV00/iPFBOUiDKKwKMOhkymH8AidPaRvzfxY+Q==" - "resolved" "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-3.0.0.tgz" - "version" "3.0.0" +write-file-atomic@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-3.0.0.tgz" + integrity sha512-EIgkf60l2oWsffja2Sf2AL384dx328c0B+cIYPTQq5q2rOYuDV00/iPFBOUiDKKwKMOhkymH8AidPaRvzfxY+Q== dependencies: - "imurmurhash" "^0.1.4" - "is-typedarray" "^1.0.0" - "signal-exit" "^3.0.2" - "typedarray-to-buffer" "^3.1.5" + imurmurhash "^0.1.4" + is-typedarray "^1.0.0" + signal-exit "^3.0.2" + typedarray-to-buffer "^3.1.5" -"y18n@^4.0.0": - "integrity" "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==" - "resolved" "https://registry.yarnpkg.com/y18n/-/y18n-4.0.0.tgz" - "version" "4.0.0" +y18n@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/y18n/-/y18n-4.0.0.tgz" + integrity sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w== -"yallist@^2.1.2": - "integrity" "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=" - "resolved" "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz" - "version" "2.1.2" +yallist@^2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz" + integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI= -"yallist@^4.0.0": - "integrity" "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" - "resolved" "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz" - "version" "4.0.0" +yallist@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz" + integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== -"yaml@^1.5.0", "yaml@^1.6.0": - "integrity" "sha512-iZfse3lwrJRoSlfs/9KQ9iIXxs9++RvBFVzAqbbBiFT+giYtyanevreF9r61ZTbGMgWQBxAua3FzJiniiJXWWw==" - "resolved" "https://registry.yarnpkg.com/yaml/-/yaml-1.6.0.tgz" - "version" "1.6.0" +yaml@^1.5.0, yaml@^1.6.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/yaml/-/yaml-1.6.0.tgz" + integrity sha512-iZfse3lwrJRoSlfs/9KQ9iIXxs9++RvBFVzAqbbBiFT+giYtyanevreF9r61ZTbGMgWQBxAua3FzJiniiJXWWw== dependencies: "@babel/runtime" "^7.4.5" -"yapool@^1.0.0": - "integrity" "sha1-9pPymjFbUNmp2iZGp6ZkXJaYW2o=" - "resolved" "https://registry.yarnpkg.com/yapool/-/yapool-1.0.0.tgz" - "version" "1.0.0" +yapool@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/yapool/-/yapool-1.0.0.tgz" + integrity sha1-9pPymjFbUNmp2iZGp6ZkXJaYW2o= -"yargs-parser@^13.0.0", "yargs-parser@^13.1.0": - "integrity" "sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ==" - "resolved" "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-13.1.1.tgz" - "version" "13.1.1" +yargs-parser@^13.0.0, yargs-parser@^13.1.0: + version "13.1.1" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-13.1.1.tgz" + integrity sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ== dependencies: - "camelcase" "^5.0.0" - "decamelize" "^1.2.0" + camelcase "^5.0.0" + decamelize "^1.2.0" -"yargs@^13.2.2": - "integrity" "sha512-HG/DWAJa1PAnHT9JAhNa8AbAv3FPaiLzioSjCcmuXXhP8MlpHO5vwls4g4j6n30Z74GVQj8Xa62dWVx1QCGklg==" - "resolved" "https://registry.yarnpkg.com/yargs/-/yargs-13.2.4.tgz" - "version" "13.2.4" +yargs@^13.2.2: + version "13.2.4" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-13.2.4.tgz" + integrity sha512-HG/DWAJa1PAnHT9JAhNa8AbAv3FPaiLzioSjCcmuXXhP8MlpHO5vwls4g4j6n30Z74GVQj8Xa62dWVx1QCGklg== dependencies: - "cliui" "^5.0.0" - "find-up" "^3.0.0" - "get-caller-file" "^2.0.1" - "os-locale" "^3.1.0" - "require-directory" "^2.1.1" - "require-main-filename" "^2.0.0" - "set-blocking" "^2.0.0" - "string-width" "^3.0.0" - "which-module" "^2.0.0" - "y18n" "^4.0.0" - "yargs-parser" "^13.1.0" + cliui "^5.0.0" + find-up "^3.0.0" + get-caller-file "^2.0.1" + os-locale "^3.1.0" + require-directory "^2.1.1" + require-main-filename "^2.0.0" + set-blocking "^2.0.0" + string-width "^3.0.0" + which-module "^2.0.0" + y18n "^4.0.0" + yargs-parser "^13.1.0" -"yn@^3.0.0": - "integrity" "sha512-kKfnnYkbTfrAdd0xICNFw7Atm8nKpLcLv9AZGEt+kczL/WQVai4e2V6ZN8U/O+iI6WrNuJjNNOyu4zfhl9D3Hg==" - "resolved" "https://registry.yarnpkg.com/yn/-/yn-3.1.0.tgz" - "version" "3.1.0" +yn@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/yn/-/yn-3.1.0.tgz" + integrity sha512-kKfnnYkbTfrAdd0xICNFw7Atm8nKpLcLv9AZGEt+kczL/WQVai4e2V6ZN8U/O+iI6WrNuJjNNOyu4zfhl9D3Hg== -"yoga-layout-prebuilt@^1.9.3": - "integrity" "sha512-9SNQpwuEh2NucU83i2KMZnONVudZ86YNcFk9tq74YaqrQfgJWO3yB9uzH1tAg8iqh5c9F5j0wuyJ2z72wcum2w==" - "resolved" "https://registry.yarnpkg.com/yoga-layout-prebuilt/-/yoga-layout-prebuilt-1.9.3.tgz" - "version" "1.9.3" +yoga-layout-prebuilt@^1.9.3: + version "1.9.3" + resolved "https://registry.yarnpkg.com/yoga-layout-prebuilt/-/yoga-layout-prebuilt-1.9.3.tgz" + integrity sha512-9SNQpwuEh2NucU83i2KMZnONVudZ86YNcFk9tq74YaqrQfgJWO3yB9uzH1tAg8iqh5c9F5j0wuyJ2z72wcum2w== ` @@ -2995,25 +2995,25 @@ exports[`test/yarn-lock.js TAP yarn lock with dedupes yarn wouldnt do > yarn.loc # yarn lockfile v1 -"x@1.1": - "version" "1.1.0" +x@1.1: + version "1.1.0" -"x@1.x": - "version" "1.2.0" +x@1.x: + version "1.2.0" -"y@1.x": - "version" "1.0.0" +y@1.x: + version "1.0.0" dependencies: - "x" "1.1" - "z" "2.x" + x "1.1" + z "2.x" -"z@1.x": - "version" "1.0.0" +z@1.x: + version "1.0.0" -"z@2.x": - "version" "2.0.0" +z@2.x: + version "2.0.0" dependencies: - "x" "1.x" + x "1.x" ` @@ -3022,33 +3022,36 @@ exports[`test/yarn-lock.js TAP yarn-stuff > generated output from input 1`] = ` # yarn lockfile v1 -"abbrev@^1.1.1", "pinned@npm:abbrev@1.1.1", "reg@npm:abbrev@^1.1.1": - "integrity" "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" - "resolved" "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz" - "version" "1.1.1" +abbrev@^1.1.1, "pinned@npm:abbrev@1.1.1", "reg@npm:abbrev@^1.1.1": + version "1.1.1" + resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz" + integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== + alpha: "thisisnotapriorityentryeither" + beta: "thisisnotapriorityentryeither2" + meta: "thisisnotapriorityentry" "full-git-url@git+https://github.com/isaacs/abbrev-js.git": - "resolved" "git+https://github.com/isaacs/abbrev-js.git" - "version" "1.1.1" + version "1.1.1" + resolved "git+https://github.com/isaacs/abbrev-js.git" "ghshort@github:isaacs/abbrev-js": - "resolved" "https://codeload.github.com/isaacs/abbrev-js/tar.gz/b8f3a2fc0c3bb8ffd8b0d0072cc6b5a3667e963c" - "version" "1.1.1" + version "1.1.1" + resolved "https://codeload.github.com/isaacs/abbrev-js/tar.gz/b8f3a2fc0c3bb8ffd8b0d0072cc6b5a3667e963c" "old@npm:abbrev@1.0.x": - "integrity" "sha1-kbR5JYinc4wl813W9jdSovh3YTU=" - "resolved" "https://registry.yarnpkg.com/abbrev/-/abbrev-1.0.9.tgz" - "version" "1.0.9" + version "1.0.9" + resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.0.9.tgz" + integrity sha1-kbR5JYinc4wl813W9jdSovh3YTU= "remote@https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz": - "resolved" "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" - "version" "1.1.1" + version "1.1.1" + resolved "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz" "symlink@file:./abbrev-link-target": - "version" "1.1.1" + version "1.1.1" "tarball@file:abbrev-1.1.1.tgz": - "resolved" "file:abbrev-1.1.1.tgz" - "version" "1.1.1" + version "1.1.1" + resolved "file:abbrev-1.1.1.tgz" ` diff --git a/workspaces/arborist/test/add-rm-pkg-deps.js b/workspaces/arborist/test/add-rm-pkg-deps.js index 54485f7..b15b9f9 100644 --- a/workspaces/arborist/test/add-rm-pkg-deps.js +++ b/workspaces/arborist/test/add-rm-pkg-deps.js @@ -10,13 +10,30 @@ t.test('add', t => { const file = npa('file@file:/some/path/foo.tgz', '/') const logs = [] - const log = { - warn: function (...args) { + const log = (l, ...args) => { + if (l === 'warn') { logs.push(args) - }, + } } + process.on('log', log) + t.teardown(() => process.off('log', log)) + t.strictSame(add({ + pkg: { + dependencies: { bar: '1' }, + devDependencies: { foo: '2' }, + }, + add: [ + foo1, + bar, + ], + path: '/', + }), { + dependencies: { bar: '1' }, + devDependencies: { foo: '1' }, + }, 'inferred save types stay the same for each dependency') + + t.strictSame(logs, []) t.strictSame(add({ - log, pkg: { dependencies: { bar: '1' }, devDependencies: { foo: '2' }, diff --git a/workspaces/arborist/test/arborist/build-ideal-tree.js b/workspaces/arborist/test/arborist/build-ideal-tree.js index e718b0b..10a2910 100644 --- a/workspaces/arborist/test/arborist/build-ideal-tree.js +++ b/workspaces/arborist/test/arborist/build-ideal-tree.js @@ -364,7 +364,7 @@ t.test('dedupe example - deduped because preferDedupe=true', t => { t.test('dedupe example - nested because legacyBundling=true', t => { const path = resolve(fixtures, 'dedupe-tests') return t.resolveMatchSnapshot(printIdeal(path, { - legacyBundling: true, + installStrategy: 'nested', preferDedupe: true, })) }) @@ -607,7 +607,7 @@ t.test('link dep within node_modules and outside root', t => { }) t.test('global style', t => t.resolveMatchSnapshot(printIdeal(t.testdir(), { - globalStyle: true, + installStrategy: 'shallow', add: ['rimraf'], }))) @@ -673,7 +673,7 @@ t.test('empty update should not trigger old lockfile', async t => { 'package-lock.json': JSON.stringify({ name: 'empty-update', version: '1.0.0', - lockfileVersion: 2, + lockfileVersion: 3, requires: true, packages: { '': { @@ -1080,7 +1080,7 @@ t.test('pathologically nested dependency cycle', async t => { resolve(fixtures, 'pathological-dep-nesting-cycle'))) }) -t.test('resolve file deps from cwd', t => { +t.test('resolve file deps from cwd', async t => { const cwd = process.cwd() t.teardown(() => process.chdir(cwd)) const path = t.testdir({ @@ -1094,17 +1094,16 @@ t.test('resolve file deps from cwd', t => { path: resolve(path, 'global'), ...OPT, }) - return arb.buildIdealTree({ + const tree = await arb.buildIdealTree({ path: `${path}/local`, add: ['child-1.2.3.tgz'], global: true, - }).then(tree => { - const resolved = `file:${resolve(fixturedir, 'child-1.2.3.tgz')}` - t.equal(normalizePath(tree.children.get('child').resolved), normalizePath(resolved)) }) + const resolved = `file:${resolve(fixturedir, 'child-1.2.3.tgz')}` + t.equal(normalizePath(tree.children.get('child').resolved), normalizePath(resolved)) }) -t.test('resolve links in global mode', t => { +t.test('resolve links in global mode', async t => { const cwd = process.cwd() t.teardown(() => process.chdir(cwd)) const path = t.testdir({ @@ -1127,18 +1126,17 @@ t.test('resolve links in global mode', t => { global: true, path: resolve(path, 'global'), }) - return arb.buildIdealTree({ + const tree = await arb.buildIdealTree({ add: ['file:../../linked-dep'], global: true, - }).then(tree => { - const resolved = 'file:../../linked-dep' - t.equal(tree.children.get('linked-dep').resolved, resolved) }) + const resolved = 'file:../../linked-dep' + t.equal(tree.children.get('linked-dep').resolved, resolved) }) t.test('dont get confused if root matches duped metadep', async t => { const path = resolve(fixtures, 'test-root-matches-metadep') - const arb = new Arborist({ path, ...OPT }) + const arb = new Arborist({ path, installStrategy: 'hoisted', ...OPT }) const tree = await arb.buildIdealTree() t.matchSnapshot(printTree(tree)) }) @@ -1163,6 +1161,26 @@ This is a one-time fix-up, please be patient... ]) }) +t.test('inflating a link node in an old lockfile skips registry', async t => { + const checkLogs = warningTracker() + const path = resolve(fixtures, 'old-lock-with-link') + const arb = new Arborist({ path, ...OPT, registry: 'http://invalid.host' }) + const tree = await arb.buildIdealTree() + t.matchSnapshot(printTree(tree)) + t.strictSame(checkLogs(), [ + [ + 'warn', + 'old lockfile', + ` +The package-lock.json file was created with an old version of npm, +so supplemental metadata must be fetched from the registry. + +This is a one-time fix-up, please be patient... +`, + ], + ]) +}) + t.test('warn for ancient lockfile, even if we use v1', async t => { const checkLogs = warningTracker() const path = resolve(fixtures, 'sax') @@ -2193,10 +2211,10 @@ t.test('update global', async t => { }) t.matchSnapshot(await printIdeal(path, { global: true, update: ['abbrev'] }), - 'updating missing dep should have no effect') + 'updating missing dep should have no effect, but fix the invalid node') t.matchSnapshot(await printIdeal(path, { global: true, update: ['wrappy'] }), - 'updating sub-dep has no effect') + 'updating sub-dep has no effect, but fixes the invalid node') const invalidArgs = [ 'once@1.4.0', @@ -2214,7 +2232,7 @@ t.test('update global', async t => { } t.matchSnapshot(await printIdeal(path, { global: true, update: ['once'] }), - 'update a single dep') + 'update a single dep, also fixes the invalid node') t.matchSnapshot(await printIdeal(path, { global: true, update: true }), 'update all the deps') }) @@ -2656,6 +2674,19 @@ t.test('add packages to workspaces, not root', async t => { t.matchSnapshot(printTree(rmTree), 'tree with abbrev removed from a and b') }) +t.test('add one workspace to another', async t => { + const path = resolve(__dirname, '../fixtures/workspaces-not-root') + const packageA = resolve(path, 'packages/a') + + const addTree = await buildIdeal(path, { + add: [packageA], + workspaces: ['c'], + }) + const c = addTree.children.get('c').target + t.match(c.edgesOut.get('a'), { spec: 'file:../a' }) + t.matchSnapshot(printTree(addTree), 'tree with workspace a added to workspace c') +}) + t.test('workspace error handling', async t => { const path = t.testdir({ 'package.json': JSON.stringify({ diff --git a/workspaces/arborist/test/arborist/index.js b/workspaces/arborist/test/arborist/index.js index 3469c5c..88da04b 100644 --- a/workspaces/arborist/test/arborist/index.js +++ b/workspaces/arborist/test/arborist/index.js @@ -213,7 +213,7 @@ t.test('excludeSet includes nonworkspace metadeps', async t => { spec: 'file:pkgs/b', }) - const arb = new Arborist() + const arb = new Arborist({}) const filter = arb.excludeWorkspacesDependencySet(tree) t.equal(filter.size, 3) @@ -236,3 +236,20 @@ t.test('lockfileVersion config validation', async t => { message: 'Invalid lockfileVersion config: banana', }) }) + +t.test('valid replaceRegistryHost values', t => { + t.equal(new Arborist({ replaceRegistryHost: 'registry.garbage.com' }).options.replaceRegistryHost, 'registry.garbage.com') + t.equal(new Arborist({ replaceRegistryHost: 'npmjs' }).options.replaceRegistryHost, 'registry.npmjs.org') + t.equal(new Arborist({ replaceRegistryHost: undefined }).options.replaceRegistryHost, 'registry.npmjs.org') + t.equal(new Arborist({ replaceRegistryHost: 'always' }).options.replaceRegistryHost, 'always') + t.equal(new Arborist({ replaceRegistryHost: 'never' }).options.replaceRegistryHost, 'never') + t.end() +}) + +t.test('valid global/installStrategy values', t => { + t.equal(new Arborist({ global: true }).options.installStrategy, 'shallow') + t.equal(new Arborist({ global: false }).options.installStrategy, 'hoisted') + t.equal(new Arborist({}).options.installStrategy, 'hoisted') + t.equal(new Arborist({ installStrategy: 'hoisted' }).options.installStrategy, 'hoisted') + t.end() +}) diff --git a/workspaces/arborist/test/arborist/load-actual.js b/workspaces/arborist/test/arborist/load-actual.js index 464bdc7..9c2c8bf 100644 --- a/workspaces/arborist/test/arborist/load-actual.js +++ b/workspaces/arborist/test/arborist/load-actual.js @@ -14,7 +14,7 @@ const { // strip the fixtures path off of the trees in snapshots const pp = path => path && - normalizePath(path).substr(normalizePath(fixtures).length + 1) + normalizePath(path).slice(normalizePath(fixtures).length + 1) const defixture = obj => { if (obj instanceof Set) { return new Set([...obj].map(defixture)) @@ -170,37 +170,46 @@ t.test('shake out Link target timing issue', t => { t.matchSnapshot(tree, 'loaded tree')) }) -t.test('broken json', t => - loadActual(resolve(fixtures, 'bad')).then(d => { - t.ok(d.errors.length, 'Got an error object') - t.equal(d.errors[0] && d.errors[0].code, 'EJSONPARSE') - t.ok(d, 'Got a tree') - })) +t.test('broken json', async t => { + const d = await loadActual(resolve(fixtures, 'bad')) + t.ok(d.errors.length, 'Got an error object') + t.equal(d.errors[0] && d.errors[0].code, 'EJSONPARSE') + t.ok(d, 'Got a tree') +}) -t.test('missing json does not obscure deeper errors', t => - loadActual(resolve(fixtures, 'empty')).then(d => { - t.match(d, { errors: [{ code: 'ENOENT' }] }, - 'Error reading json of top level') - t.match(d.children.get('foo'), { errors: [{ code: 'EJSONPARSE' }] }, - 'Error parsing JSON of child node') - })) +t.test('missing json does not obscure deeper errors', async t => { + const d = await loadActual(resolve(fixtures, 'empty')) + t.match(d, { errors: [{ code: 'ENOENT' }] }, + 'Error reading json of top level') + t.match(d.children.get('foo'), { errors: [{ code: 'EJSONPARSE' }] }, + 'Error parsing JSON of child node') +}) t.test('missing folder', t => t.rejects(loadActual(resolve(fixtures, 'does-not-exist')), { code: 'ENOENT', })) -t.test('missing symlinks', t => - loadActual(resolve(fixtures, 'badlink')).then(d => { - t.equal(d.children.size, 2, 'both broken children are included') - t.match(d.children.get('foo'), { errors: [{ code: 'ELOOP' }] }, - 'foo has error') - t.match(d.children.get('bar'), { errors: [{ code: 'ENOENT' }] }, - 'bar has error') - })) +t.test('missing symlinks', async t => { + const d = await loadActual(resolve(fixtures, 'badlink')) + t.equal(d.children.size, 2, 'both broken children are included') + t.match(d.children.get('foo'), { errors: [{ code: 'ELOOP' }] }, + 'foo has error') + t.match(d.children.get('bar'), { errors: [{ code: 'ENOENT' }] }, + 'bar has error') +}) -t.test('load from a hidden lockfile', t => - t.resolveMatchSnapshot(loadActual(resolve(fixtures, 'hidden-lockfile')))) +t.test('load from a hidden lockfile', async (t) => { + const tree = await loadActual(resolve(fixtures, 'hidden-lockfile')) + t.ok(tree.meta.loadedFromDisk, 'meta was loaded from disk') + t.matchSnapshot(tree) +}) + +t.test('do not load from a hidden lockfile when forceActual is set', async (t) => { + const tree = await loadActual(resolve(fixtures, 'hidden-lockfile'), { forceActual: true }) + t.not(tree.meta.loadedFromDisk, 'meta was NOT loaded from disk') + t.matchSnapshot(tree) +}) t.test('load a global space', t => t.resolveMatchSnapshot(loadActual(resolve(fixtures, 'global-style/lib'), { @@ -423,6 +432,51 @@ t.test('load global space with link deps', async t => { }) }) +t.test('no edge errors for nested deps', async t => { + const path = t.testdir({ + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + dependencies: { + b: '1.0.0', + }, + }), + node_modules: { + b: { + 'package.json': JSON.stringify({ + name: 'b', + version: '1.0.0', + dependencies: { + c: '1.0.0', + }, + }), + }, + c: { + 'package.json': JSON.stringify({ + name: 'c', + version: '1.0.0', + }), + }, + }, + }) + + // disable treeCheck since it prevents the original issue from occuring + const ArboristNoTreeCheck = t.mock('../../lib/arborist', { + '../../lib/tree-check.js': tree => tree, + }) + const loadActualNoTreeCheck = (path, opts) => + new ArboristNoTreeCheck({ path, ...opts }).loadActual(opts) + + const tree = await loadActualNoTreeCheck(path) + + // assert that no outgoing edges have errors + for (const node of tree.inventory.values()) { + for (const [name, edge] of node.edgesOut.entries()) { + t.equal(edge.error, null, `node ${node.name} has outgoing edge to ${name} with error ${edge.error}`) + } + } +}) + t.test('loading a workspace maintains overrides', async t => { const path = t.testdir({ 'package.json': JSON.stringify({ diff --git a/workspaces/arborist/test/arborist/rebuild.js b/workspaces/arborist/test/arborist/rebuild.js index 4f7a09c..df383c6 100644 --- a/workspaces/arborist/test/arborist/rebuild.js +++ b/workspaces/arborist/test/arborist/rebuild.js @@ -2,9 +2,11 @@ const t = require('tap') const _trashList = Symbol.for('trashList') const Arborist = require('../../lib/arborist/index.js') const { resolve, dirname } = require('path') +const os = require('os') const fs = require('fs') const fixtures = resolve(__dirname, '../fixtures') const relpath = require('../../lib/relpath.js') +const localeCompare = require('@isaacs/string-locale-compare')('en') const fixture = (t, p) => require(`${fixtures}/reify-cases/${p}`)(t) @@ -181,9 +183,14 @@ t.test('verify dep flags in script environments', async t => { // don't include path or env, because that's going to be platform-specific const saved = [...arb.scriptsRun] .sort(({ path: patha, event: eventa }, { path: pathb, event: eventb }) => - patha.localeCompare(pathb, 'en') || eventa.localeCompare(eventb, 'en')) + localeCompare(patha, pathb) || localeCompare(eventa, eventb)) .map(({ pkg, event, cmd, code, signal, stdout, stderr }) => ({ pkg, event, cmd, code, signal, stdout, stderr })) + t.cleanSnapshot = (input) => { + return input.replace(new RegExp(os.tmpdir().replace(/\\/g, '\\\\\\\\'), 'g'), '{TMP}') + .replace(/\\\\/g, '/') + .replace(/-(.+)\.(?:sh|cmd)/g, '{HASH}') + } t.matchSnapshot(saved, 'saved script results') for (const [pkg, flags] of Object.entries(expect)) { @@ -191,7 +198,7 @@ t.test('verify dep flags in script environments', async t => { t.strictSame(flags, fs.readFileSync(file, 'utf8').split('\n'), pkg) } t.strictSame(checkLogs().sort((a, b) => - a[2].localeCompare(b[2], 'en') || (typeof a[4] === 'string' ? -1 : 1)), [ + localeCompare(a[2], b[2]) || (typeof a[4] === 'string' ? -1 : 1)), [ ['info', 'run', 'devdep@1.0.0', 'postinstall', 'node_modules/devdep', 'node ../../env.js'], ['info', 'run', 'devdep@1.0.0', 'postinstall', { code: 0, signal: null }], ['info', 'run', 'devopt@1.0.0', 'postinstall', 'node_modules/devopt', 'node ../../env.js'], @@ -414,7 +421,6 @@ t.test('rebuild node-gyp dependencies lacking both preinstall and install script event: 'install', path: resolve(path, 'node_modules/dep'), pkg: { scripts: { install: 'node-gyp rebuild' } }, - stdioString: true, env: { npm_package_resolved: null, npm_package_integrity: null, @@ -458,6 +464,51 @@ t.test('do not rebuild node-gyp dependencies with gypfile:false', async t => { await arb.rebuild() }) +// ref: https://github.com/npm/cli/issues/2905 +t.test('do not run lifecycle scripts of linked deps twice', async t => { + const testdir = t.testdir({ + project: { + 'package.json': JSON.stringify({ + name: 'my-project', + version: '1.0.0', + dependencies: { + foo: 'file:../foo', + }, + }), + node_modules: { + foo: t.fixture('symlink', '../../foo'), + }, + }, + foo: { + 'package.json': JSON.stringify({ + name: 'foo', + version: '1.0.0', + scripts: { + postinstall: 'echo "ok"', + }, + }), + }, + }) + + const path = resolve(testdir, 'project') + const RUNS = [] + const Arborist = t.mock('../../lib/arborist/index.js', { + '@npmcli/run-script': opts => { + RUNS.push(opts) + return require('@npmcli/run-script')(opts) + }, + }) + const arb = new Arborist({ path, registry }) + await arb.rebuild() + t.equal(RUNS.length, 1, 'should run postinstall script only once') + t.match(RUNS, [ + { + event: 'postinstall', + pkg: { name: 'foo' }, + }, + ]) +}) + t.test('workspaces', async t => { const path = t.testdir({ 'package.json': JSON.stringify({ diff --git a/workspaces/arborist/test/arborist/reify.js b/workspaces/arborist/test/arborist/reify.js index 7fb1f1f..7c250a3 100644 --- a/workspaces/arborist/test/arborist/reify.js +++ b/workspaces/arborist/test/arborist/reify.js @@ -1,37 +1,26 @@ -const { resolve, basename } = require('path') +const { join, resolve, basename } = require('path') const t = require('tap') const runScript = require('@npmcli/run-script') - -// mock rimraf so we can make it fail in rollback tests -const realRimraf = require('rimraf') -let failRimraf = false -const rimrafMock = (...args) => { - if (!failRimraf) { - return realRimraf(...args) - } else { - return args.pop()(new Error('rimraf fail')) - } -} -rimrafMock.sync = (...args) => { - if (!failRimraf) { - return realRimraf.sync(...args) - } else { - throw new Error('rimraf fail') - } -} +const localeCompare = require('@isaacs/string-locale-compare')('en') +const tnock = require('../fixtures/tnock') const fs = require('fs') +const fsp = require('fs/promises') +const npmFs = require('@npmcli/fs') + +let failRm = false let failRename = null let failRenameOnce = null let failMkdir = null -const { rename: realRename, mkdir: realMkdir } = fs +const { rename: realRename, rm: realRm, mkdir: realMkdir } = fs const fsMock = { ...fs, mkdir (...args) { if (failMkdir) { process.nextTick(() => args.pop()(failMkdir)) + return } - realMkdir(...args) + return realMkdir(...args) }, rename (...args) { if (failRename) { @@ -41,13 +30,52 @@ const fsMock = { failRenameOnce = null process.nextTick(() => args.pop()(er)) } else { - realRename(...args) + return realRename(...args) } }, + rm (...args) { + if (failRm) { + process.nextTick(() => args.pop()(new Error('rm fail'))) + return + } + + realRm(...args) + }, } +const fspMock = { + ...fsp, + mkdir: async (...args) => { + if (failMkdir) { + throw failMkdir + } + + return fsp.mkdir(...args) + }, + rename: async (...args) => { + if (failRename) { + throw failRename + } else if (failRenameOnce) { + const er = failRenameOnce + failRenameOnce = null + throw er + } else { + return fsp.rename(...args) + } + }, + rm: async (...args) => { + if (failRm) { + throw new Error('rm fail') + } + + return fsp.rm(...args) + }, +} +// need this to be injected so that it doesn't pull from main cache +const { moveFile } = t.mock('@npmcli/fs', { 'fs/promises': fspMock }) const mocks = { fs: fsMock, - rimraf: rimrafMock, + 'fs/promises': fspMock, + '@npmcli/fs': { ...npmFs, moveFile }, } const oldLockfileWarning = [ @@ -61,14 +89,6 @@ This is a one-time fix-up, please be patient... `, ] -// need this to be injected so that it doesn't pull from main cache -const moveFile = t.mock('@npmcli/move-file', { fs: fsMock }) -mocks['@npmcli/move-file'] = moveFile -const mkdirp = t.mock('mkdirp', mocks) -mocks.mkdirp = mkdirp -const mkdirpInferOwner = t.mock('mkdirp-infer-owner', mocks) -mocks['mkdirp-infer-owner'] = mkdirpInferOwner - // track the warnings that are emitted. returns a function that removes // the listener and provides the list of what it saw. const warningTracker = () => { @@ -230,6 +250,7 @@ t.test('omit peer deps', t => { } const lock = require(tree.path + '/package-lock.json') + // eslint-disable-next-line promise/always-return for (const [loc, meta] of Object.entries(lock.packages)) { if (meta.peer) { t.throws(() => fs.statSync(resolve(path, loc)), 'peer not reified') @@ -238,10 +259,11 @@ t.test('omit peer deps', t => { } } }) + // eslint-disable-next-line promise/always-return .then(() => { process.removeListener('time', onTime) process.removeListener('timeEnd', onTimeEnd) - finishedTimers.sort((a, b) => a.localeCompare(b, 'en')) + finishedTimers.sort(localeCompare) t.matchSnapshot(finishedTimers, 'finished timers') t.strictSame(timers, {}, 'should have no timers in progress now') }) @@ -269,7 +291,11 @@ t.test('update a bundling node without updating all of its deps', t => { : () => t.ok(fs.lstatSync(bin).isSymbolicLink(), 'created symlink') const checkPackageLock = () => { - t.matchSnapshot(require(path + '/package-lock.json').dependencies.fsevents, + t.match(require(path + '/package-lock.json').packages['node_modules/fsevents'], + { + dev: true, + optional: true, + }, 'contains fsevents in lockfile') } @@ -333,15 +359,15 @@ t.test('omit optional dep', t => { const ignoreScripts = true const arb = newArb({ path, ignoreScripts }) - return arb.reify({ omit: ['optional'] }) - .then(tree => { - t.equal(tree.children.get('fsevents'), undefined, 'no fsevents in tree') - t.throws(() => fs.statSync(path + '/node_modules/fsevents'), 'no fsevents unpacked') - t.match(require(path + '/package-lock.json').dependencies.fsevents, { - dev: true, - optional: true, - }, 'fsevents present in lockfile') - }) + // eslint-disable-next-line promise/always-return + return arb.reify({ omit: ['optional'] }).then(tree => { + t.equal(tree.children.get('fsevents'), undefined, 'no fsevents in tree') + t.throws(() => fs.statSync(path + '/node_modules/fsevents'), 'no fsevents unpacked') + t.match(require(path + '/package-lock.json').packages['node_modules/fsevents'], { + dev: true, + optional: true, + }, 'fsevents present in lockfile') + }) .then(() => t.ok(arb.diff, 'has a diff tree')) }) @@ -422,7 +448,7 @@ t.test('tracks changes of shrinkwrapped dep correctly', async t => { t.match(install2, update2, 'update maintains the same correct tree') // delete a dependency that was installed as part of the shrinkwrap - realRimraf.sync(resolve(path, 'node_modules/@nlf/shrinkwrapped-dep-updates-a/node_modules/@nlf/shrinkwrapped-dep-updates-b')) + fs.rmSync(resolve(path, 'node_modules/@nlf/shrinkwrapped-dep-updates-a/node_modules/@nlf/shrinkwrapped-dep-updates-b'), { recursive: true, force: true }) const repair = await printReified(path) t.match(repair, install2, 'tree got repaired') }) @@ -501,7 +527,7 @@ t.test('update a child of a node with bundled deps', t => { const path = fixture(t, 'testing-bundledeps-legacy-bundling') return t.resolveMatchSnapshot(printReified(path, { update: ['@isaacs/testing-bundledeps-c'], - legacyBundling: true, + installStrategy: 'nested', })) }) @@ -590,7 +616,7 @@ t.test('warn on reifying deprecated dependency', t => { t.test('rollbacks', { buffered: false }, t => { t.test('fail retiring shallow nodes', t => { const path = fixture(t, 'testing-bundledeps-3') - const a = newArb({ path, legacyBundling: true }) + const a = newArb({ path, installStrategy: 'nested' }) const expect = new Error('rename fail') const kRenamePath = Symbol.for('renamePath') const renamePath = a[kRenamePath] @@ -615,9 +641,9 @@ t.test('rollbacks', { buffered: false }, t => { }), expect).then(() => t.equal(rolledBack, true, 'rolled back')) }) - t.test('fail retiring nodes because rimraf fails after eexist', t => { + t.test('fail retiring nodes because rm fails after eexist', t => { const path = fixture(t, 'testing-bundledeps-3') - const a = newArb({ path, legacyBundling: true }) + const a = newArb({ path, installStrategy: 'nested' }) const eexist = new Error('rename fail') eexist.code = 'EEXIST' const kRenamePath = Symbol.for('renamePath') @@ -625,7 +651,7 @@ t.test('rollbacks', { buffered: false }, t => { a[kRenamePath] = (from, to) => { a[kRenamePath] = renamePath failRename = eexist - failRimraf = true + failRm = true return a[kRenamePath](from, to) } const kRollback = Symbol.for('rollbackRetireShallowNodes') @@ -634,8 +660,8 @@ t.test('rollbacks', { buffered: false }, t => { a[kRollback] = er => { rolledBack = true failRename = new Error('some other error') - failRimraf = false - t.match(er, new Error('rimraf fail')) + failRm = false + t.match(er, new Error('rm fail')) a[kRollback] = rollbackRetireShallowNodes return a[kRollback](er).then(er => { failRename = null @@ -648,13 +674,13 @@ t.test('rollbacks', { buffered: false }, t => { return t.rejects(a.reify({ update: ['@isaacs/testing-bundledeps-parent'], - }), new Error('rimraf fail')) + }), new Error('rm fail')) .then(() => t.equal(rolledBack, true, 'rolled back')) }) - t.test('fail retiring node, but then rimraf fixes it', t => { + t.test('fail retiring node, but then rm fixes it', async t => { const path = fixture(t, 'testing-bundledeps-3') - const a = newArb({ path, legacyBundling: true }) + const a = newArb({ path, installStrategy: 'nested' }) const eexist = new Error('rename fail') eexist.code = 'EEXIST' const kRenamePath = Symbol.for('renamePath') @@ -672,16 +698,17 @@ t.test('rollbacks', { buffered: false }, t => { return a[kRollback](er) } - return t.resolveMatchSnapshot(a.reify({ + const tree = await a.reify({ update: ['@isaacs/testing-bundledeps-parent'], save: false, - }).then(printTree)) + }) + return printTree(tree) }) t.test('fail creating sparse tree', t => { t.teardown(() => failMkdir = null) const path = fixture(t, 'testing-bundledeps-3') - const a = newArb({ path, legacyBundling: true }) + const a = newArb({ path, installStrategy: 'nested' }) const kCreateST = Symbol.for('createSparseTree') const createSparseTree = a[kCreateST] a[kCreateST] = () => { @@ -704,9 +731,9 @@ t.test('rollbacks', { buffered: false }, t => { t.test('fail rolling back from creating sparse tree', t => { failMkdir = null - failRimraf = null + failRm = null const path = fixture(t, 'testing-bundledeps-3') - const a = newArb({ path, legacyBundling: true }) + const a = newArb({ path, installStrategy: 'nested' }) const kCreateST = Symbol.for('createSparseTree') const kRetireShallowNodes = Symbol.for('retireShallowNodes') @@ -714,7 +741,7 @@ t.test('rollbacks', { buffered: false }, t => { a[kRetireShallowNodes] = async () => { a[kRetireShallowNodes] = retireShallowNodes await a[kRetireShallowNodes]() - failRimraf = true + failRm = true } const createSparseTree = a[kCreateST] t.teardown(() => failMkdir = null) @@ -735,6 +762,7 @@ t.test('rollbacks', { buffered: false }, t => { return t.rejects(a.reify({ update: ['@isaacs/testing-bundledeps-parent'], }).then(tree => 'it worked'), new Error('poop')) + // eslint-disable-next-line promise/always-return .then(() => { const warnings = check() t.equal(warnings.length, 2) @@ -744,16 +772,16 @@ t.test('rollbacks', { buffered: false }, t => { 'warn', 'cleanup', 'Failed to remove some directories', - [[String, new Error('rimraf fail')]], + [[String, new Error('rm fail')]], ], ]) }) - .then(() => failRimraf = false) + .then(() => failRm = false) }) t.test('fail loading shrinkwraps and updating trees', t => { const path = fixture(t, 'shrinkwrapped-dep-no-lock-empty') - const a = newArb({ path, legacyBundling: true }) + const a = newArb({ path, installStrategy: 'nested' }) const kLoadSW = Symbol.for('loadShrinkwrapsAndUpdateTrees') const loadShrinkwrapsAndUpdateTrees = a[kLoadSW] a[kLoadSW] = seen => { @@ -779,7 +807,7 @@ t.test('rollbacks', { buffered: false }, t => { t.test('fail loading bundles and updating trees', t => { const path = fixture(t, 'two-bundled-deps') - const a = newArb({ path, legacyBundling: true }) + const a = newArb({ path, installStrategy: 'nested' }) const kLoadBundles = Symbol.for('loadBundlesAndUpdateTrees') const loadBundlesAndUpdateTrees = a[kLoadBundles] a[kLoadBundles] = (depth, bundlesByDepth) => { @@ -797,7 +825,7 @@ t.test('rollbacks', { buffered: false }, t => { t.test('fail unpacking new modules', t => { const path = fixture(t, 'two-bundled-deps') - const a = newArb({ path, legacyBundling: true }) + const a = newArb({ path, installStrategy: 'nested' }) const kUnpack = Symbol.for('unpackNewModules') const unpackNewModules = a[kUnpack] a[kUnpack] = () => { @@ -815,7 +843,7 @@ t.test('rollbacks', { buffered: false }, t => { t.test('fail moving back retired unchanged', t => { const path = fixture(t, 'testing-bundledeps-3') - const a = newArb({ path, legacyBundling: true }) + const a = newArb({ path, installStrategy: 'nested' }) const kMoveback = Symbol.for('moveBackRetiredUnchanged') const moveBackRetiredUnchanged = a[kMoveback] @@ -843,11 +871,11 @@ t.test('rollbacks', { buffered: false }, t => { t.test('fail removing retired and deleted nodes', t => { const path = fixture(t, 'testing-bundledeps-3') - const a = newArb({ path, legacyBundling: true }) + const a = newArb({ path, installStrategy: 'nested' }) const kRemove = Symbol.for('removeTrash') const removeRetiredAndDeletedNodes = a[kRemove] a[kRemove] = () => { - failRimraf = true + failRm = true a[kRemove] = removeRetiredAndDeletedNodes return a[kRemove]() } @@ -856,6 +884,7 @@ t.test('rollbacks', { buffered: false }, t => { return t.resolveMatchSnapshot(a.reify({ update: ['@isaacs/testing-bundledeps-parent'], save: false, + // eslint-disable-next-line promise/always-return }).then(tree => printTree(tree))).then(() => { const warnings = check() t.equal(warnings.length, 2) @@ -865,11 +894,11 @@ t.test('rollbacks', { buffered: false }, t => { 'warn', 'cleanup', 'Failed to remove some directories', - [[String, new Error('rimraf fail')]], + [[String, new Error('rm fail')]], ], ]) }) - .then(() => failRimraf = false) + .then(() => failRm = false) }) t.end() @@ -893,8 +922,7 @@ t.test('saving the ideal tree', t => { a: 'git+ssh://git@github.com:foo/bar#baz', b: '', d: 'npm:c@1.x <1.9.9', - // XXX: should we remove dependencies that are also workspaces? - e: 'file:e', + e: '*', f: 'git+https://user:pass@github.com/baz/quux#asdf', g: '', h: '~1.2.3', @@ -1018,6 +1046,7 @@ t.test('saving the ideal tree', t => { // NB: these are all going to be marked as extraneous, because we're // skipping the actual buildIdealTree step that flags them properly return a[kSaveIdealTree]({}) + // eslint-disable-next-line promise/always-return }).then(saved => { t.ok(saved, 'true, because it was saved') t.matchSnapshot(require(path + '/package-lock.json'), 'lock after save') @@ -1027,7 +1056,7 @@ t.test('saving the ideal tree', t => { a: 'github:foo/bar#baz', b: '^1.2.3', d: 'npm:c@1.x <1.9.9', - e: 'file:e', + e: '*', f: 'git+https://user:pass@github.com/baz/quux.git#asdf', g: '*', h: '~1.2.3', @@ -1075,6 +1104,7 @@ t.test('scoped registries', async t => { registry, }) const kReify = Symbol.for('reifyNode') + a.addTracker('reify') a.idealTree = new Node({ path }) const node = new Node({ @@ -1105,7 +1135,7 @@ t.test('global style', t => { const rbinPart = '.bin/rimraf' + (process.platform === 'win32' ? '.cmd' : '') const rbin = resolve(nm, rbinPart) - return reify(path, { add: ['rimraf@2'], globalStyle: true }) + return reify(path, { add: ['rimraf@2'], installStrategy: 'shallow' }) .then(() => fs.statSync(rbin)) .then(() => t.strictSame(fs.readdirSync(nm).sort(), ['.bin', '.package-lock.json', 'rimraf'])) }) @@ -1157,12 +1187,10 @@ t.test('workspaces', t => { t.test('reify simple-workspaces', t => t.resolveMatchSnapshot(printReified(fixture(t, 'workspaces-simple')), 'should reify simple workspaces')) - t.test('reify workspaces lockfile', t => { + t.test('reify workspaces lockfile', async t => { const path = fixture(t, 'workspaces-simple') - reify(path).then(() => { - t.matchSnapshot(require(path + '/package-lock.json'), 'should lock workspaces config') - t.end() - }) + await reify(path) + t.matchSnapshot(require(path + '/package-lock.json'), 'should lock workspaces config') }) t.test('reify workspaces bin files', t => { @@ -1193,20 +1221,16 @@ t.test('workspaces', t => { 'should not clean up entire nm folder for no reason' )) - t.test('add new workspaces dep', t => { + t.test('add new workspaces dep', async t => { const path = fixture(t, 'workspaces-add-new-dep') - reify(path).then(() => { - t.matchSnapshot(require(path + '/package-lock.json'), 'should update package-lock with new added dep') - t.end() - }) + await reify(path) + t.matchSnapshot(require(path + '/package-lock.json'), 'should update package-lock with new added dep') }) - t.test('root as-a-workspace', t => { + t.test('root as-a-workspace', async t => { const path = fixture(t, 'workspaces-root-linked') - reify(path).then(() => { - t.matchSnapshot(require(path + '/package-lock.json'), 'should produce expected package-lock file') - t.end() - }) + await reify(path) + t.matchSnapshot(require(path + '/package-lock.json'), 'should produce expected package-lock file') }) t.end() @@ -1472,7 +1496,7 @@ t.test('rollback if process is terminated during reify process', async t => { // ensure that we end up with the same thing we started with, // if it was something other than we're installing const a = resolve(path, 'node_modules/abbrev') - mkdirp.sync(a) + fs.mkdirSync(a, { recursive: true }) const pj = resolve(a, 'package.json') fs.writeFileSync(pj, JSON.stringify({ name: 'abbrev', @@ -1758,7 +1782,6 @@ console.log('ok 1 - this is fine') event: 'test', path, pkg, - stdioString: true, stdio: 'pipe', }), 'test result') }) @@ -1769,6 +1792,8 @@ t.test('running lifecycle scripts of unchanged link nodes on reify', async t => t.ok(fs.lstatSync(resolve(path, 'a/a-prepare')).isFile(), 'should run prepare lifecycle scripts for links directly linked to the tree') + t.ok(fs.lstatSync(resolve(path, 'a/a-post-install')).isFile(), + 'should run postinstall lifecycle scripts for links directly linked to the tree') }) t.test('save-prod, with optional', async t => { @@ -2043,6 +2068,15 @@ t.test('add deps to workspaces', async t => { t.matchSnapshot(require(path + '/packages/a/package.json'), 'package.json a') t.matchSnapshot(require(path + '/package-lock.json'), 'lockfile') }) + + t.test('add a to root', async t => { + const path = t.testdir(fixture) + await reify(path) + const tree = await reify(path, { add: ['a'], lockfileVersion: 3 }) + t.matchSnapshot(printTree(tree), 'returned tree') + t.matchSnapshot(require(path + '/package.json'), 'package.json added workspace as dep') + t.matchSnapshot(require(path + '/package-lock.json'), 'lockfile added workspace as dep') + }) }) t.test('reify audit only workspace deps when reifying workspace', async t => { @@ -2321,7 +2355,7 @@ t.test('never unpack into anything other than a real directory', async t => { const wrappy = resolve(path, 'node_modules/once/node_modules/wrappy') arb[kUnpack] = () => { // will have already created it - realRimraf.sync(wrappy) + fs.rmSync(wrappy, { recursive: true, force: true }) const target = resolve(path, 'target') fs.symlinkSync(target, wrappy, 'junction') arb[kUnpack] = unpackNewModules @@ -2455,6 +2489,62 @@ t.test('add local dep with existing dev + peer/optional', async t => { t.equal(tree.children.size, 1, 'children') }) +t.test('runs dependencies script if tree changes', async (t) => { + const path = t.testdir({ + 'package.json': JSON.stringify({ + name: 'root', + version: '1.0.0', + dependencies: { + abbrev: '^1.1.1', + }, + scripts: { + predependencies: `node -e "require('fs').writeFileSync('ran-predependencies', '')"`, + dependencies: `node -e "require('fs').writeFileSync('ran-dependencies', '')"`, + postdependencies: `node -e "require('fs').writeFileSync('ran-postdependencies', '')"`, + }, + }), + }) + + await reify(path) + + for (const script of ['predependencies', 'dependencies', 'postdependencies']) { + const expectedPath = join(path, `ran-${script}`) + t.ok(fs.existsSync(expectedPath), `ran ${script}`) + // delete the files after we assert they exist + fs.unlinkSync(expectedPath) + } + + // reify again without changing dependencies + await reify(path) + + for (const script of ['predependencies', 'dependencies', 'postdependencies']) { + const expectedPath = join(path, `ran-${script}`) + // and this time we assert that they do _not_ exist + t.not(fs.existsSync(expectedPath), `did not run ${script}`) + } + + // take over console.log as run-script is going to print a banner for these because + // they're running in the foreground + const _log = console.log + t.teardown(() => { + console.log = _log + }) + const logs = [] + console.log = (msg) => logs.push(msg) + // reify again, this time adding a new dependency + await reify(path, { foregroundScripts: true, add: ['once@^1.4.0'] }) + console.log = _log + + t.match(logs, [/predependencies/, /dependencies/, /postdependencies/], 'logged banners') + + // files should exist again + for (const script of ['predependencies', 'dependencies', 'postdependencies']) { + const expectedPath = join(path, `ran-${script}`) + t.ok(fs.existsSync(expectedPath), `ran ${script}`) + fs.unlinkSync(expectedPath) + } +}) + t.test('save package.json on update', t => { t.test('should save many deps in multiple package.json when using save=true', async t => { const path = fixture(t, 'workspaces-need-update') @@ -2612,5 +2702,452 @@ t.test('save package.json on update', t => { 'should save no top level dep update to root package.json' ) }) + + t.test('should not throw when trying to update a link dep', async t => { + const path = t.testdir({ + one: { + 'package.json': JSON.stringify({ + name: 'one', + version: '1.0.0', + dependencies: { + two: 'file:../two', + }, + }), + }, + two: { + 'package.json': JSON.stringify({ + name: 'two', + version: '1.0.0', + }), + }, + }) + + await t.resolves(reify(resolve(path, 'one'), { update: true, save: true, workspaces: [] })) + + t.equal( + require(resolve(path, 'one', 'package.json')).dependencies.two, + 'file:../two', + 'should have made no changes' + ) + }) t.end() }) + +t.test('installLinks', (t) => { + t.test('when true, packs and extracts instead of symlinks', async (t) => { + const path = t.testdir({ + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + main: 'index.js', + dependencies: { + b: 'file:../b', + }, + }), + 'index.js': '', + }, + b: { + 'package.json': JSON.stringify({ + name: 'b', + version: '1.0.0', + main: 'index.js', + }), + 'index.js': '', + }, + }) + + await reify(resolve(path, 'a'), { installLinks: true }) + + const installedB = fs.lstatSync(resolve(path, 'a/node_modules/b')) + t.ok(installedB.isDirectory(), 'a/node_modules/b is a directory') + }) + + t.test('when false, symlinks', async (t) => { + const path = t.testdir({ + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + main: 'index.js', + dependencies: { + b: 'file:../b', + }, + }), + 'index.js': '', + }, + b: { + 'package.json': JSON.stringify({ + name: 'b', + version: '1.0.0', + main: 'index.js', + }), + 'index.js': '', + }, + }) + + await reify(resolve(path, 'a'), { installLinks: false }) + + const installedB = fs.lstatSync(resolve(path, 'a/node_modules/b')) + t.ok(installedB.isSymbolicLink(), 'a/node_modules/b is a symlink') + }) + + t.test('when symlinks exist, installLinks set to true replaces them with dirs', async (t) => { + const path = t.testdir({ + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + main: 'index.js', + dependencies: { + b: 'file:../b', + }, + }), + 'index.js': '', + }, + b: { + 'package.json': JSON.stringify({ + name: 'b', + version: '1.0.0', + main: 'index.js', + }), + 'index.js': '', + }, + }) + + await reify(resolve(path, 'a'), { installLinks: false, save: true }) + + const firstB = fs.lstatSync(resolve(path, 'a/node_modules/b')) + t.ok(firstB.isSymbolicLink(), 'a/node_modules/b is a symlink') + + await reify(resolve(path, 'a'), { installLinks: true, save: true }) + + const secondB = fs.lstatSync(resolve(path, 'a/node_modules/b')) + t.ok(secondB.isDirectory(), 'a/node_modules/b is now a directory') + }) + + t.test('when directories exist, installLinks set to false replaces them with symlinks', async (t) => { + const path = t.testdir({ + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + main: 'index.js', + dependencies: { + b: 'file:../b', + }, + }), + 'index.js': '', + }, + b: { + 'package.json': JSON.stringify({ + name: 'b', + version: '1.0.0', + main: 'index.js', + }), + 'index.js': '', + }, + }) + + await reify(resolve(path, 'a'), { installLinks: true }) + + const firstB = fs.lstatSync(resolve(path, 'a/node_modules/b')) + t.ok(firstB.isDirectory(), 'a/node_modules/b is a directory') + + await reify(resolve(path, 'a'), { installLinks: false }) + + const secondB = fs.lstatSync(resolve(path, 'a/node_modules/b')) + t.ok(secondB.isSymbolicLink(), 'a/node_modules/b is now a symlink') + }) + + t.test('when installLinks is true, dependencies of links are installed', async (t) => { + const path = t.testdir({ + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + main: 'index.js', + dependencies: { + b: 'file:../b', + }, + }), + 'index.js': '', + }, + b: { + 'package.json': JSON.stringify({ + name: 'b', + version: '1.0.0', + main: 'index.js', + dependencies: { + abbrev: '^1.0.0', + }, + }), + 'index.js': '', + }, + }) + + await reify(resolve(path, 'a'), { installLinks: true }) + + const installedB = fs.lstatSync(resolve(path, 'a/node_modules/b')) + t.ok(installedB.isDirectory(), 'a/node_modules/b is a directory') + + const abbrev = fs.lstatSync(resolve(path, 'a/node_modules/abbrev')) + t.ok(abbrev.isDirectory(), 'abbrev got installed') + }) + + t.test('workspaces are always symlinks, even with installLinks set to true', async (t) => { + const path = t.testdir({ + a: { + 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + main: 'index.js', + dependencies: { + b: 'file:../b', + c: '^1.0.0', + }, + workspaces: ['./c'], + }), + 'index.js': '', + c: { + 'package.json': JSON.stringify({ + name: 'c', + version: '1.0.0', + main: 'index.js', + }), + 'index.js': '', + }, + }, + b: { + 'package.json': JSON.stringify({ + name: 'b', + version: '1.0.0', + main: 'index.js', + dependencies: { + abbrev: '^1.0.0', + }, + }), + 'index.js': '', + }, + }) + + await reify(resolve(path, 'a'), { installLinks: true }) + + const installedB = fs.lstatSync(resolve(path, 'a/node_modules/b')) + t.ok(installedB.isDirectory(), 'a/node_modules/b is a directory') + + const installedC = fs.lstatSync(resolve(path, 'a/node_modules/c')) + t.ok(installedC.isSymbolicLink(), 'a/node_modules/c is a symlink') + + const abbrev = fs.lstatSync(resolve(path, 'a/node_modules/abbrev')) + t.ok(abbrev.isDirectory(), 'abbrev got installed') + }) + + t.end() +}) + +t.only('should preserve exact ranges, missing actual tree', async (t) => { + const Pacote = require('pacote') + const Arborist = t.mock('../../lib/arborist', { + pacote: { + ...Pacote, + extract: async (...args) => { + if (args[0].startsWith('gitssh')) { + // we just want to test that this url is handled properly + // but its not a real git url we can clone so return early + return true + } + return Pacote.extract(...args) + }, + }, + }) + const abbrev = resolve(__dirname, + '../fixtures/registry-mocks/content/abbrev/-/abbrev-1.1.1.tgz') + const abbrevTGZ = fs.readFileSync(abbrev) + + const abbrevPackument = JSON.stringify({ + _id: 'abbrev', + _rev: 'lkjadflkjasdf', + name: 'abbrev', + 'dist-tags': { latest: '1.1.1' }, + versions: { + '1.1.1': { + name: 'abbrev', + version: '1.1.1', + dist: { + tarball: 'https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz', + }, + }, + }, + }) + + const abbrevPackument2 = JSON.stringify({ + _id: 'abbrev', + _rev: 'lkjadflkjasdf', + name: 'abbrev', + 'dist-tags': { latest: '1.1.1' }, + versions: { + '1.1.1': { + name: 'abbrev', + version: '1.1.1', + dist: { + tarball: 'https://registry.garbage.org/abbrev/-/abbrev-1.1.1.tgz', + }, + }, + }, + }) + + const gitSshPackument = JSON.stringify({ + _id: 'gitssh', + _rev: 'lkjadflkjasdf', + name: 'gitssh', + 'dist-tags': { latest: '1.1.1' }, + versions: { + '1.1.1': { + name: 'gitssh', + version: '1.1.1', + dist: { + // this is a url that `new URL()` cant parse + // https://github.com/npm/cli/issues/5278 + tarball: 'git+ssh://git@github.com:a/b/c.git#lkjadflkjasdf', + }, + }, + }, + }) + + const notAUrlPackument = JSON.stringify({ + _id: 'notaurl', + _rev: 'lkjadflkjasdf', + name: 'notaurl', + 'dist-tags': { latest: '1.1.1' }, + versions: { + '1.1.1': { + name: 'notaurl', + version: '1.1.1', + dist: { + tarball: 'hey been trying to break this test', + }, + }, + }, + }) + + t.only('host should not be replaced replaceRegistryHost=never', async (t) => { + const testdir = t.testdir({ + project: { + 'package.json': JSON.stringify({ + name: 'myproject', + version: '1.0.0', + dependencies: { + abbrev: '1.1.1', + gitssh: '1.1.1', + notaurl: '1.1.1', + }, + }), + }, + }) + + tnock(t, 'https://registry.github.com') + .get('/abbrev') + .reply(200, abbrevPackument) + + tnock(t, 'https://registry.npmjs.org') + .get('/abbrev/-/abbrev-1.1.1.tgz') + .reply(200, abbrevTGZ) + + tnock(t, 'https://registry.github.com') + .get('/gitssh') + .reply(200, gitSshPackument) + + tnock(t, 'https://registry.github.com') + .get('/notaurl') + .reply(200, notAUrlPackument) + + const arb = new Arborist({ + path: resolve(testdir, 'project'), + registry: 'https://registry.github.com', + cache: resolve(testdir, 'cache'), + replaceRegistryHost: 'never', + }) + await arb.reify() + }) + + t.only('host should be replaced replaceRegistryHost=npmjs', async (t) => { + const testdir = t.testdir({ + project: { + 'package.json': JSON.stringify({ + name: 'myproject', + version: '1.0.0', + dependencies: { + abbrev: '1.1.1', + gitssh: '1.1.1', + notaurl: '1.1.1', + }, + }), + }, + }) + + tnock(t, 'https://registry.github.com') + .get('/abbrev') + .reply(200, abbrevPackument) + + tnock(t, 'https://registry.github.com') + .get('/gitssh') + .reply(200, gitSshPackument) + + tnock(t, 'https://registry.github.com') + .get('/abbrev/-/abbrev-1.1.1.tgz') + .reply(200, abbrevTGZ) + + tnock(t, 'https://registry.github.com') + .get('/notaurl') + .reply(200, notAUrlPackument) + + const arb = new Arborist({ + path: resolve(testdir, 'project'), + registry: 'https://registry.github.com', + cache: resolve(testdir, 'cache'), + replaceRegistryHost: 'npmjs', + }) + await arb.reify() + }) + + t.only('host should be always replaceRegistryHost=always', async (t) => { + const testdir = t.testdir({ + project: { + 'package.json': JSON.stringify({ + name: 'myproject', + version: '1.0.0', + dependencies: { + abbrev: '1.1.1', + gitssh: '1.1.1', + notaurl: '1.1.1', + }, + }), + }, + }) + + tnock(t, 'https://registry.github.com') + .get('/abbrev') + .reply(200, abbrevPackument2) + + tnock(t, 'https://registry.github.com') + .get('/gitssh') + .reply(200, gitSshPackument) + + tnock(t, 'https://registry.github.com') + .get('/abbrev/-/abbrev-1.1.1.tgz') + .reply(200, abbrevTGZ) + + tnock(t, 'https://registry.github.com') + .get('/notaurl') + .reply(200, notAUrlPackument) + + const arb = new Arborist({ + path: resolve(testdir, 'project'), + registry: 'https://registry.github.com', + cache: resolve(testdir, 'cache'), + replaceRegistryHost: 'always', + }) + await arb.reify() + }) +}) diff --git a/workspaces/arborist/test/arborist/validate-path.js b/workspaces/arborist/test/arborist/validate-path.js index 503e3c0..e5155d2 100644 --- a/workspaces/arborist/test/arborist/validate-path.js +++ b/workspaces/arborist/test/arborist/validate-path.js @@ -1,4 +1,4 @@ -// Arborist should be mkdirping the path, but not +// Arborist should be mkdir-ing the path, but not // changing its ownership in that case. // https://github.com/npm/arborist/issues/252 // This test has to club a lot of stuff, and provides no coverage, diff --git a/workspaces/arborist/test/audit-report.js b/workspaces/arborist/test/audit-report.js index 16ea7e1..13e2e4d 100644 --- a/workspaces/arborist/test/audit-report.js +++ b/workspaces/arborist/test/audit-report.js @@ -1,4 +1,5 @@ const t = require('tap') +const localeCompare = require('@isaacs/string-locale-compare')('en') const AuditReport = require('../lib/audit-report.js') const { auditToBulk } = AuditReport const Node = require('../lib/node.js') @@ -24,14 +25,14 @@ const newArb = (path, opts = {}) => const sortReport = report => { const entries = Object.entries(report.vulnerabilities) - const vulns = entries.sort(([a], [b]) => a.localeCompare(b, 'en')) + const vulns = entries.sort(([a], [b]) => localeCompare(a, b)) .map(([name, vuln]) => [ name, { ...vuln, via: (vuln.via || []).sort((a, b) => - String(a.source || a).localeCompare(String(b.source || b, 'en'))), - effects: (vuln.effects || []).sort((a, b) => a.localeCompare(b, 'en')), + localeCompare(String(a.source || a), String(b.source || b))), + effects: (vuln.effects || []).sort(localeCompare), }, ]) report.vulnerabilities = vulns.reduce((set, [k, v]) => { diff --git a/workspaces/arborist/test/consistent-resolve.js b/workspaces/arborist/test/consistent-resolve.js index 6145758..3792e88 100644 --- a/workspaces/arborist/test/consistent-resolve.js +++ b/workspaces/arborist/test/consistent-resolve.js @@ -101,12 +101,6 @@ t.test('remotes returned as-is', t => { t.end() }) -t.test('just a tag name interpreted as a tag name, not a name@', t => { - t.equal(cr('foo'), 'foo') - t.equal(cr('foo@'), '') - t.end() -}) - t.test('falsey resolved returns null', t => { t.equal(cr(null), null) t.equal(cr(0), null) @@ -115,6 +109,16 @@ t.test('falsey resolved returns null', t => { t.end() }) +t.test('tag returns tag', t => { + t.equal(cr('foo@latest'), 'latest') + t.end() +}) + +t.test('package name returns package name', t => { + t.equal(cr('foo'), 'foo') + t.end() +}) + t.test('invalid resolved returns as-is', t => { t.equal(cr('not ! a : v@lid t*A*g'), 'not ! a : v@lid t*A*g') t.end() diff --git a/workspaces/arborist/test/dep-valid.js b/workspaces/arborist/test/dep-valid.js index 3294ea4..aaf7da0 100644 --- a/workspaces/arborist/test/dep-valid.js +++ b/workspaces/arborist/test/dep-valid.js @@ -4,7 +4,12 @@ const npa = require('npm-package-arg') const { normalizePaths } = require('./fixtures/utils.js') const { resolve } = require('path') -t.ok(depValid({}, '', null, {}), '* is always ok') +// dep-valid reads from requestor.edgesOut so we use this instead of {} in these tests +const emptyRequestor = { + edgesOut: new Map(), +} + +t.ok(depValid({}, '', null, emptyRequestor), '* is always ok') t.ok(depValid({ package: { @@ -13,7 +18,7 @@ t.ok(depValid({ get version () { return this.package.version }, -}, '1.x', null, {}), 'range that is satisfied') +}, '1.x', null, emptyRequestor), 'range that is satisfied') t.ok(depValid({ package: { @@ -22,21 +27,21 @@ t.ok(depValid({ get version () { return this.package.version }, -}, '1.x', '2.x', {}), 'range that is acceptable') +}, '1.x', '2.x', emptyRequestor), 'range that is acceptable') t.ok(depValid({ isLink: true, realpath: '/some/path', -}, normalizePaths(npa('file:/some/path')), null, {}), 'links must point at intended target') +}, normalizePaths(npa('file:/some/path')), null, emptyRequestor), 'links must point at intended target') t.notOk(depValid({ isLink: true, realpath: '/some/other/path', -}, 'file:/some/path', null, {}), 'links must point at intended target') +}, 'file:/some/path', null, emptyRequestor), 'links must point at intended target') t.notOk(depValid({ realpath: '/some/path', -}, 'file:/some/path', null, {}), 'file:// must be a link') +}, 'file:/some/path', null, emptyRequestor), 'file:// must be a link') t.ok(depValid({ name: 'foo', @@ -47,7 +52,7 @@ t.ok(depValid({ get version () { return this.package.version }, -}, 'git://host/repo#semver:1.x', null, {}), 'git url with semver range') +}, 'git://host/repo#semver:1.x', null, emptyRequestor), 'git url with semver range') t.ok(depValid({ name: 'foo', @@ -58,7 +63,7 @@ t.ok(depValid({ get version () { return this.package.version }, -}, 'npm:bar@1.2.3', null, {}), 'alias is ok') +}, 'npm:bar@1.2.3', null, emptyRequestor), 'alias is ok') t.ok(depValid({ resolved: 'https://registry/abbrev-1.1.1.tgz', @@ -66,7 +71,7 @@ t.ok(depValid({ get version () { return this.package.version }, -}, 'https://registry/abbrev-1.1.1.tgz', null, {}), 'remote url match') +}, 'https://registry/abbrev-1.1.1.tgz', null, emptyRequestor), 'remote url match') t.ok(depValid({ resolved: 'git+ssh://git@github.com/foo/bar', @@ -74,7 +79,7 @@ t.ok(depValid({ get version () { return this.package.version }, -}, 'git+ssh://git@github.com/foo/bar.git', null, {}), 'matching _from saveSpec') +}, 'git+ssh://git@github.com/foo/bar.git', null, emptyRequestor), 'matching _from saveSpec') t.notOk(depValid({ resolved: 'git+ssh://git@github.com/foo/bar', @@ -82,26 +87,26 @@ t.notOk(depValid({ get version () { return this.package.version }, -}, 'git+ssh://git@github.com/bar/foo.git', null, {}), 'different repo') +}, 'git+ssh://git@github.com/bar/foo.git', null, emptyRequestor), 'different repo') t.notOk(depValid({ package: {}, get version () { return this.package.version }, -}, 'git+ssh://git@github.com/bar/foo.git', null, {}), 'missing repo') +}, 'git+ssh://git@github.com/bar/foo.git', null, emptyRequestor), 'missing repo') t.ok(depValid({ resolved: `file:${resolve('/path/to/tarball.tgz')}`, -}, resolve('/path/to/tarball.tgz'), null, {}), 'same tarball') +}, resolve('/path/to/tarball.tgz'), null, emptyRequestor), 'same tarball') t.notOk(depValid({ resolved: 'file:/path/to/other/tarball.tgz', -}, '/path/to/tarball.tgz', null, {}), 'different tarball') +}, '/path/to/tarball.tgz', null, emptyRequestor), 'different tarball') t.notOk(depValid({ isLink: true, -}, '/path/to/tarball.tgz', null, {}), 'links are not tarballs') +}, '/path/to/tarball.tgz', null, emptyRequestor), 'links are not tarballs') t.ok(depValid({ package: { @@ -112,28 +117,28 @@ t.ok(depValid({ get version () { return this.package.version }, -}, './tarball.tgz', null, {}), 'probably the same-ish, hopefully') +}, './tarball.tgz', null, emptyRequestor), 'probably the same-ish, hopefully') t.notOk(depValid({ package: {}, get version () { return this.package.version }, -}, './tarball.tgz', null, {}), 'too uncertain, nope') +}, './tarball.tgz', null, emptyRequestor), 'too uncertain, nope') t.ok(depValid({ resolved: 'https://registry.npmjs.org/foo/foo-1.2.3.tgz', -}, 'latest', null, {}), 'tagged registry version needs remote tarball') +}, 'latest', null, emptyRequestor), 'tagged registry version needs remote tarball') t.notOk(depValid({ resolved: 'git+https://registry.npmjs.org/foo/foo-1.2.3.git', -}, 'latest', null, {}), 'tagged registry version needs remote tarball, not git') +}, 'latest', null, emptyRequestor), 'tagged registry version needs remote tarball, not git') -t.notOk(depValid({}, 'latest', null, {}), +t.notOk(depValid({}, 'latest', null, emptyRequestor), 'tagged registry version needs remote tarball resolution') t.test('unsupported dependency type', t => { - const requestor = { errors: [] } + const requestor = { errors: [], edgesOut: new Map() } const child = { name: 'kid' } const request = { type: 'not a type' } t.notOk(depValid(child, request, null, requestor)) @@ -148,7 +153,7 @@ t.test('unsupported dependency type', t => { }) t.test('invalid tag name', t => { - const requestor = { errors: [] } + const requestor = { errors: [], edgesOut: new Map() } const child = { name: 'kid' } const request = '!!@#$%!#@$!' t.notOk(depValid(child, request, null, requestor)) @@ -163,7 +168,7 @@ t.test('invalid tag name', t => { }) t.test('invalid request all together', t => { - const requestor = { errors: [] } + const requestor = { errors: [], edgesOut: new Map() } const child = { name: 'kid' } const request = null t.notOk(depValid(child, request, null, requestor)) @@ -176,3 +181,24 @@ t.test('invalid request all together', t => { }, 'parent got an error for their invalid request') t.end() }) + +t.test('installLinks makes Link nodes invalid', t => { + const requestor = { errors: [], installLinks: true, edgesOut: new Map() } + const child = { isLink: true, isWorkspace: false, name: 'kid' } + const request = { type: 'directory' } + t.notOk(depValid(child, request, null, requestor)) + t.end() +}) + +t.test('installLinks does not make workspace nodes invalid', t => { + const requestor = { errors: [], installLinks: true, edgesOut: new Map() } + const child = { + isLink: true, + isWorkspace: true, + name: 'kid', + realpath: '/some/path', + } + const request = normalizePaths(npa('file:/some/path')) + t.ok(depValid(child, request, null, requestor)) + t.end() +}) diff --git a/workspaces/arborist/test/diff.js b/workspaces/arborist/test/diff.js index 0e943d5..219a0bb 100644 --- a/workspaces/arborist/test/diff.js +++ b/workspaces/arborist/test/diff.js @@ -1,3 +1,4 @@ +const localeCompare = require('@isaacs/string-locale-compare')('en') const Diff = require('../lib/diff.js') const t = require('tap') const Node = require('../lib/node.js') @@ -31,7 +32,7 @@ const formatDiff = obj => removed: obj.removed.map(d => normalizePath(d.path).split(normalizedCWD).join('{CWD}')), children: [...obj.children] .map(formatDiff) - .sort((a, b) => path(a).localeCompare(path(b, 'en'))), + .sort((a, b) => localeCompare(path(a), path(b))), }) t.formatSnapshot = obj => format(formatDiff(obj), { sort: false }) diff --git a/workspaces/arborist/test/edge.js b/workspaces/arborist/test/edge.js index c90b202..f45cb87 100644 --- a/workspaces/arborist/test/edge.js +++ b/workspaces/arborist/test/edge.js @@ -71,6 +71,7 @@ const a = { }, isTop: false, parent: top, + root: top, resolve (n) { return n === 'aa' ? aa : this.parent.resolve(n) }, @@ -244,16 +245,19 @@ t.not(new Edge({ }).satisfiedBy(b), 'b does not satisfy edge for c') reset(a) +const overrideSet = new OverrideSet({ + overrides: { + c: '2.x', + }, +}) + +a.overrides = overrideSet t.matchSnapshot(new Edge({ from: a, type: 'prod', name: 'c', spec: '1.x', - overrides: new OverrideSet({ - overrides: { - c: '2.x', - }, - }).getEdgeRule({ name: 'c', spec: '1.x' }), + overrides: overrideSet.getEdgeRule({ name: 'c', spec: '1.x' }), }).toJSON(), 'printableEdge shows overrides') reset(a) @@ -262,11 +266,7 @@ const overriddenExplanation = new Edge({ type: 'prod', name: 'c', spec: '1.x', - overrides: new OverrideSet({ - overrides: { - c: '2.x', - }, - }).getEdgeRule({ name: 'c', spec: '1.x' }), + overrides: overrideSet.getEdgeRule({ name: 'c', spec: '1.x' }), }).explain() t.equal(overriddenExplanation.rawSpec, '1.x', 'rawSpec has original spec') t.equal(overriddenExplanation.spec, '2.x', 'spec has override spec') @@ -278,24 +278,22 @@ t.ok(new Edge({ type: 'prod', name: 'c', spec: '1.x', - overrides: new OverrideSet({ - overrides: { - c: '2.x', - }, - }).getEdgeRule({ name: 'c', spec: '1.x' }), + overrides: overrideSet.getEdgeRule({ name: 'c', spec: '1.x' }), }).satisfiedBy(c), 'c@2 satisfies spec:1.x, override:2.x') reset(a) +const overrideSetB = new OverrideSet({ + overrides: { + b: '1.x', + }, +}) +a.overrides = overrideSetB t.matchSnapshot(new Edge({ from: a, type: 'prod', name: 'c', spec: '2.x', - overrides: new OverrideSet({ - overrides: { - b: '1.x', - }, - }).getEdgeRule({ name: 'c', spec: '2.x' }), + overrides: overrideSetB.getEdgeRule({ name: 'c', spec: '2.x' }), }).toJSON(), 'printableEdge does not show non-applicable override') t.ok(new Edge({ @@ -303,13 +301,26 @@ t.ok(new Edge({ type: 'prod', name: 'c', spec: '2.x', - overrides: new OverrideSet({ - overrides: { - b: '1.x', - }, - }).getEdgeRule({ name: 'c', spec: '2.x' }), + overrides: overrideSetB.getEdgeRule({ name: 'c', spec: '2.x' }), }).satisfiedBy(c), 'c@2 satisfies spec:1.x, no matching override') reset(a) +delete a.overrides + +const overrideEdge = new Edge({ + from: a, + type: 'prod', + name: 'c', + spec: '2.x', +}) +t.notOk(overrideEdge.overrides, 'edge has no overrides') +a.overrides = new OverrideSet({ overrides: { b: '1.x' } }) +t.notOk(overrideEdge.overrides, 'edge has no overrides') +overrideEdge.reload() +t.ok(overrideEdge.overrides, 'edge has overrides after reload') +delete a.overrides +overrideEdge.reload() +t.notOk(overrideEdge.overrides, 'edge has no overrides after reload') +reset(a) const referenceTop = { name: 'referenceTop', @@ -494,6 +505,7 @@ const overrides = new OverrideSet({ c: '1.x', }, }) +a.overrides = overrides const overriddenEdge = new Edge({ from: a, type: 'prod', @@ -504,6 +516,7 @@ const overriddenEdge = new Edge({ t.equal(overriddenEdge.spec, '1.x', 'override spec takes priority') t.equal(overriddenEdge.rawSpec, '2.x', 'rawSpec holds original spec') reset(a) +delete a.overrides const old = new Edge({ from: a, @@ -796,3 +809,256 @@ t.same(bundledEdge.explain(), { bundled: true, from: bundleParent.explain(), }, 'bundled edge.explain as expected') + +t.test('override references find the correct root', (t) => { + const overrides = new OverrideSet({ + overrides: { + foo: '$foo', + }, + }) + + const root = { + name: 'root', + packageName: 'root', + edgesOut: new Map(), + edgesIn: new Set(), + explain: () => 'root node explanation', + package: { + name: 'root', + version: '1.2.3', + dependencies: { + foo: '^1.0.0', + }, + overrides: { + foo: '$foo', + }, + }, + get version () { + return this.package.version + }, + isTop: true, + parent: null, + overrides, + resolve (n) { + return n === 'foo' ? foo : null + }, + addEdgeOut (edge) { + this.edgesOut.set(edge.name, edge) + }, + addEdgeIn (edge) { + this.edgesIn.add(edge) + }, + } + + const foo = { + name: 'foo', + packageName: 'foo', + edgesOut: new Map(), + edgesIn: new Set(), + explain: () => 'foo node explanation', + package: { + name: 'foo', + version: '1.2.3', + dependencies: {}, + }, + get version () { + return this.package.version + }, + parent: root, + root: root, + resolve (n) { + return n === 'bar' ? bar : this.parent.resolve(n) + }, + addEdgeOut (edge) { + this.edgesOut.set(edge.name, edge) + }, + addEdgeIn (edge) { + this.edgesIn.add(edge) + }, + } + foo.overrides = overrides.getNodeRule(foo) + + const bar = { + name: 'bar', + packageName: 'bar', + edgesOut: new Map(), + edgesIn: new Set(), + explain: () => 'bar node explanation', + package: { + name: 'bar', + version: '1.2.3', + dependencies: { + foo: '^2.0.0', + }, + }, + get version () { + return this.package.version + }, + parent: foo, + root: root, + resolve (n) { + return this.parent.resolve(n) + }, + addEdgeOut (edge) { + this.edgesOut.set(edge.name, edge) + }, + addEdgeIn (edge) { + this.edgesIn.add(edge) + }, + } + bar.overrides = foo.overrides.getNodeRule(bar) + + const virtualBar = { + name: 'bar', + packageName: 'bar', + edgesOut: new Map(), + edgesIn: new Set(), + explain: () => 'bar node explanation', + package: { + name: 'bar', + version: '1.2.3', + dependencies: { + foo: '^2.0.0', + }, + }, + parent: null, + root: null, + sourceReference: bar, + get version () { + return this.package.version + }, + resolve (n) { + return bar.resolve(n) + }, + addEdgeOut (edge) { + this.edgesOut.set(edge.name, edge) + }, + addEdgeIn (edge) { + this.edgesIn.add(edge) + }, + } + virtualBar.overrides = overrides + + const edge = new Edge({ + from: virtualBar, + type: 'prod', + spec: '^2.0.0', + name: 'foo', + overrides: overrides.getEdgeRule({ name: 'foo', spec: '^2.0.0' }), + }) + + t.ok(edge.valid, 'edge is valid') + t.end() +}) + +t.test('shrinkwrapped and bundled deps are not overridden and remain valid', (t) => { + const overrides = new OverrideSet({ + overrides: { + bar: '^2.0.0', + }, + }) + + const root = { + name: 'root', + packageName: 'root', + edgesOut: new Map(), + edgesIn: new Set(), + explain: () => 'root node explanation', + package: { + name: 'root', + version: '1.2.3', + dependencies: { + foo: '^1.0.0', + }, + overrides: { + bar: '^2.0.0', + }, + }, + get version () { + return this.package.version + }, + isTop: true, + parent: null, + overrides, + resolve (n) { + return n === 'foo' ? foo : null + }, + addEdgeOut (edge) { + this.edgesOut.set(edge.name, edge) + }, + addEdgeIn (edge) { + this.edgesIn.add(edge) + }, + } + + const foo = { + name: 'foo', + packageName: 'foo', + edgesOut: new Map(), + edgesIn: new Set(), + explain: () => 'foo node explanation', + hasShrinkwrap: true, + package: { + name: 'foo', + version: '1.2.3', + dependencies: { + bar: '^1.0.0', + }, + }, + get version () { + return this.package.version + }, + parent: root, + root, + resolve (n) { + return n === 'bar' ? bar : this.parent.resolve(n) + }, + addEdgeOut (edge) { + this.edgesOut.set(edge.name, edge) + }, + addEdgeIn (edge) { + this.edgesIn.add(edge) + }, + } + foo.overrides = overrides.getNodeRule(foo) + + const bar = { + name: 'bar', + packageName: 'bar', + edgesOut: new Map(), + edgesIn: new Set(), + explain: () => 'bar node explanation', + inShrinkwrap: true, + package: { + name: 'bar', + version: '1.2.3', + dependencies: {}, + }, + get version () { + return this.package.version + }, + parent: foo, + root, + resolve (n) { + return this.parent.resolve(n) + }, + addEdgeOut (edge) { + this.edgesOut.set(edge.name, edge) + }, + addEdgeIn (edge) { + this.edgesIn.add(edge) + }, + } + bar.overrides = foo.overrides.getNodeRule(bar) + + const edge = new Edge({ + from: foo, + type: 'prod', + spec: '^1.0.0', + name: 'bar', + overrides: overrides.getEdgeRule({ name: 'bar', spec: '^1.0.0' }), + }) + + t.ok(edge.valid, 'edge is valid') + t.end() +}) diff --git a/workspaces/arborist/test/fixtures/index.js b/workspaces/arborist/test/fixtures/index.js index f034807..31b6b0a 100644 --- a/workspaces/arborist/test/fixtures/index.js +++ b/workspaces/arborist/test/fixtures/index.js @@ -1,4 +1,5 @@ const mkdirp = require('mkdirp').sync +const localeCompare = require('@isaacs/string-locale-compare')('en') const { unlinkSync, symlinkSync, readFileSync, writeFileSync } = require('fs') const { relative, resolve, dirname } = require('path') @@ -167,7 +168,7 @@ const setup = () => { `### BEGIN IGNORED SYMLINKS ### ### this list is generated automatically, do not edit directly ### update it by running \`node test/fixtures/index.js\` -${links.sort((a,b) => a.localeCompare(b, 'en')).join('\n')} +${links.sort(localeCompare).join('\n')} ### END IGNORED SYMLINKS ###`) writeFileSync(gifile, gitignore) } diff --git a/workspaces/arborist/test/fixtures/link-dep-lifecycle-scripts/a/package.json b/workspaces/arborist/test/fixtures/link-dep-lifecycle-scripts/a/package.json index e545ad6..f239bf3 100644 --- a/workspaces/arborist/test/fixtures/link-dep-lifecycle-scripts/a/package.json +++ b/workspaces/arborist/test/fixtures/link-dep-lifecycle-scripts/a/package.json @@ -2,6 +2,7 @@ "name": "a", "version": "1.0.0", "scripts": { - "prepare": "node -e \"require('fs').writeFileSync(require('path').resolve('a-prepare'), '')\"" + "prepare": "node -e \"require('fs').writeFileSync('a-prepare', '')\"", + "postinstall": "node -e \"require('fs').writeFileSync('a-post-install', '')\"" } } diff --git a/workspaces/arborist/test/fixtures/old-lock-with-link/link-dep/package.json b/workspaces/arborist/test/fixtures/old-lock-with-link/link-dep/package.json new file mode 100644 index 0000000..0bb2ef1 --- /dev/null +++ b/workspaces/arborist/test/fixtures/old-lock-with-link/link-dep/package.json @@ -0,0 +1,4 @@ +{ + "name": "link-dep", + "version": "1.0.0" +} diff --git a/workspaces/arborist/test/fixtures/old-lock-with-link/package-lock.json b/workspaces/arborist/test/fixtures/old-lock-with-link/package-lock.json new file mode 100644 index 0000000..f004bc6 --- /dev/null +++ b/workspaces/arborist/test/fixtures/old-lock-with-link/package-lock.json @@ -0,0 +1,11 @@ +{ + "name": "old-lock-with-link", + "version": "1.0.0", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "link-dep": { + "version": "file:link-dep" + } + } +} diff --git a/workspaces/arborist/test/fixtures/old-lock-with-link/package.json b/workspaces/arborist/test/fixtures/old-lock-with-link/package.json new file mode 100644 index 0000000..85c2424 --- /dev/null +++ b/workspaces/arborist/test/fixtures/old-lock-with-link/package.json @@ -0,0 +1,7 @@ +{ + "name": "old-lock-with-link", + "version": "1.0.0", + "dependencies": { + "link-dep": "file:./link-dep" + } +} diff --git a/workspaces/arborist/test/fixtures/registry-mocks/fetch-lock-contents.js b/workspaces/arborist/test/fixtures/registry-mocks/fetch-lock-contents.js index 0f756f0..5fb010c 100644 --- a/workspaces/arborist/test/fixtures/registry-mocks/fetch-lock-contents.js +++ b/workspaces/arborist/test/fixtures/registry-mocks/fetch-lock-contents.js @@ -1,5 +1,6 @@ // fetch all the deps and tarballs in a v2 lockfile const pacote = require('pacote') +const Arborist = require('../../index.js') const url = require('url') const mkdirp = require('mkdirp') const {dirname, resolve} = require('path') @@ -29,7 +30,7 @@ const main = async lock => { continue const path = url.parse(meta.resolved).pathname.replace(/^\/@?/, '') const tgzFile = resolve(dir, path) - await pacote.tarball.file(meta.resolved, tgzFile) + await pacote.tarball.file(meta.resolved, tgzFile, { Arborist }) } console.log('OK!') } diff --git a/workspaces/arborist/test/fixtures/reify-cases/link-dep-lifecycle-scripts.js b/workspaces/arborist/test/fixtures/reify-cases/link-dep-lifecycle-scripts.js index 651761d..5f75cf3 100644 --- a/workspaces/arborist/test/fixtures/reify-cases/link-dep-lifecycle-scripts.js +++ b/workspaces/arborist/test/fixtures/reify-cases/link-dep-lifecycle-scripts.js @@ -6,7 +6,8 @@ module.exports = t => { "name": "a", "version": "1.0.0", "scripts": { - "prepare": "node -e \"require('fs').writeFileSync(require('path').resolve('a-prepare'), '')\"" + "prepare": "node -e \"require('fs').writeFileSync('a-prepare', '')\"", + "postinstall": "node -e \"require('fs').writeFileSync('a-post-install', '')\"" } }) }, diff --git a/workspaces/arborist/test/fixtures/reify-cases/workspaces-link-bin.js b/workspaces/arborist/test/fixtures/reify-cases/workspaces-link-bin.js index ceca15e..59120e2 100644 --- a/workspaces/arborist/test/fixtures/reify-cases/workspaces-link-bin.js +++ b/workspaces/arborist/test/fixtures/reify-cases/workspaces-link-bin.js @@ -25,13 +25,16 @@ module.exports = t => { }) }, "b": { - "file.js": "", + "create-file.js": "require('fs').writeFileSync('file.js', '')\n", "package.json": JSON.stringify({ "name": "b", "version": "1.0.0", "files": [ "file.js" ], + "scripts": { + "preinstall": "node create-file.js" + }, "bin": "file.js" }) } diff --git a/workspaces/libnpmaccess/test/fixtures/tnock.js b/workspaces/arborist/test/fixtures/tnock.js similarity index 77% rename from workspaces/libnpmaccess/test/fixtures/tnock.js rename to workspaces/arborist/test/fixtures/tnock.js index 048639a..2e07f73 100644 --- a/workspaces/libnpmaccess/test/fixtures/tnock.js +++ b/workspaces/arborist/test/fixtures/tnock.js @@ -5,7 +5,9 @@ const nock = require('nock') module.exports = tnock function tnock (t, host) { const server = nock(host) + nock.disableNetConnect() t.teardown(function () { + nock.enableNetConnect() server.done() }) return server diff --git a/workspaces/arborist/test/fixtures/workspaces-link-bin/packages/b/create-file.js b/workspaces/arborist/test/fixtures/workspaces-link-bin/packages/b/create-file.js new file mode 100644 index 0000000..937f47d --- /dev/null +++ b/workspaces/arborist/test/fixtures/workspaces-link-bin/packages/b/create-file.js @@ -0,0 +1 @@ +require('fs').writeFileSync('file.js', '') diff --git a/workspaces/arborist/test/fixtures/workspaces-link-bin/packages/b/file.js b/workspaces/arborist/test/fixtures/workspaces-link-bin/packages/b/file.js deleted file mode 100644 index e69de29..0000000 diff --git a/workspaces/arborist/test/fixtures/workspaces-link-bin/packages/b/package.json b/workspaces/arborist/test/fixtures/workspaces-link-bin/packages/b/package.json index 52a65b6..3d0b8d0 100644 --- a/workspaces/arborist/test/fixtures/workspaces-link-bin/packages/b/package.json +++ b/workspaces/arborist/test/fixtures/workspaces-link-bin/packages/b/package.json @@ -2,5 +2,8 @@ "name": "b", "version": "1.0.0", "files": ["file.js"], + "scripts": { + "preinstall": "node create-file.js" + }, "bin": "file.js" } diff --git a/workspaces/arborist/test/fixtures/yarn-stuff/yarn.lock b/workspaces/arborist/test/fixtures/yarn-stuff/yarn.lock index c465c12..a562873 100644 --- a/workspaces/arborist/test/fixtures/yarn-stuff/yarn.lock +++ b/workspaces/arborist/test/fixtures/yarn-stuff/yarn.lock @@ -3,6 +3,9 @@ abbrev@^1.1.1, "pinned@npm:abbrev@1.1.1", "reg@npm:abbrev@^1.1.1": + meta: "this is not a priority entry" + alpha: "this is not a priority entry either" + beta: "this is not a priority entry either 2" version "1.1.1" resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8" integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== diff --git a/workspaces/arborist/test/from-path.js b/workspaces/arborist/test/from-path.js index 5b5ea20..3bfd0b6 100644 --- a/workspaces/arborist/test/from-path.js +++ b/workspaces/arborist/test/from-path.js @@ -1,7 +1,7 @@ const t = require('tap') const { normalizePath } = require('./fixtures/utils.js') const fp = require('../lib/from-path.js') -const fromPath = obj => normalizePath(fp(obj)) +const fromPath = (node, edge) => normalizePath(fp(node, edge)) t.equal(fromPath({ realpath: '/some/path', @@ -21,3 +21,30 @@ t.equal(fromPath({ realpath: '/some/path/to/install/target', resolved: 'https://registry.com/package.tgz', }), '/some/path/to/install/target', 'use dirname if not dir or file type') + +t.equal(fromPath({ + root: { + realpath: '/some/root', + }, +}, { + name: 'foo', + overrides: { + name: 'foo', + value: 'foo@2', + }, +}), '/some/root', 'uses root realpath for overridden edges') + +t.equal(fromPath({ + sourceReference: { + root: { + realpath: '/some/root', + }, + }, + realpath: '/some/red/herring', +}, { + name: 'foo', + overrides: { + name: 'foo', + value: 'foo@2', + }, +}), '/some/root', 'uses sourceReferences root realpath for overridden edges') diff --git a/workspaces/arborist/test/gather-dep-set.js b/workspaces/arborist/test/gather-dep-set.js index 877e419..9fdb876 100644 --- a/workspaces/arborist/test/gather-dep-set.js +++ b/workspaces/arborist/test/gather-dep-set.js @@ -1,4 +1,5 @@ const t = require('tap') +const localeCompare = require('@isaacs/string-locale-compare')('en') const gatherDepSet = require('../lib/gather-dep-set.js') const Node = require('../lib/node.js') @@ -81,7 +82,7 @@ const tree = new Node({ const normalizePath = path => path.replace(/[A-Z]:/, '').replace(/\\/g, '/') const printSet = set => [...set] - .sort((a, b) => a.name.localeCompare(b.name, 'en')) + .sort((a, b) => localeCompare(a.name, b.name)) .map(n => n.location) const cwd = normalizePath(process.cwd()) diff --git a/workspaces/arborist/test/get-workspace-nodes.js b/workspaces/arborist/test/get-workspace-nodes.js index fa259a8..3de4d73 100644 --- a/workspaces/arborist/test/get-workspace-nodes.js +++ b/workspaces/arborist/test/get-workspace-nodes.js @@ -4,8 +4,6 @@ const Arborist = require('../lib/arborist/index.js') const { resolve } = require('path') const path = resolve(__dirname, './fixtures/workspaces-shared-deps-virtual') -const log = require('proc-log') - const warningTracker = () => { const list = [] const onlog = (...msg) => msg[0] === 'warn' && list.push(msg) @@ -23,7 +21,7 @@ t.before(async () => { t.test('basic behavior', t => { const getLogs = warningTracker() - const wsNodes = getWorkspaceNodes(tree, ['a'], log) + const wsNodes = getWorkspaceNodes(tree, ['a']) t.equal(wsNodes.length, 1) t.equal(wsNodes[0], tree.children.get('a').target) t.same(getLogs(), []) @@ -32,7 +30,7 @@ t.test('basic behavior', t => { t.test('filter set, but no workspaces present', t => { const getLogs = warningTracker() - const wsNodes = getWorkspaceNodes(tree.children.get('b').target, ['xyz'], log) + const wsNodes = getWorkspaceNodes(tree.children.get('b').target, ['xyz']) t.same(wsNodes, []) t.same(getLogs(), [ ['warn', 'workspaces', 'filter set, but no workspaces present'], @@ -42,7 +40,7 @@ t.test('filter set, but no workspaces present', t => { t.test('name in filter set, but not in workspaces', t => { const getLogs = warningTracker() - const wsNodes = getWorkspaceNodes(tree, ['xyz'], log) + const wsNodes = getWorkspaceNodes(tree, ['xyz']) t.same(wsNodes, []) t.same(getLogs(), [ ['warn', 'workspaces', 'xyz in filter set, but not in workspaces'], @@ -57,7 +55,7 @@ t.test('name in filter set, but no workspace folder present', t => { // but if we start moving things around and make a mistake, it's // possible to get there. tree.children.get('c').target.root = null - const wsNodes = getWorkspaceNodes(tree, ['c'], log) + const wsNodes = getWorkspaceNodes(tree, ['c']) t.same(wsNodes, []) t.same(getLogs(), [ ['warn', 'workspaces', 'c in filter set, but no workspace folder present'], diff --git a/workspaces/arborist/test/inventory.js b/workspaces/arborist/test/inventory.js index cb0a286..1b087fe 100644 --- a/workspaces/arborist/test/inventory.js +++ b/workspaces/arborist/test/inventory.js @@ -2,6 +2,8 @@ // does not enable it. process.env.ARBORIST_DEBUG = '1' const Inventory = require('../lib/inventory.js') +const localeCompare = require('@isaacs/string-locale-compare')('en') + const t = require('tap') t.test('basic operations', t => { @@ -21,7 +23,7 @@ t.test('basic operations', t => { i.get('y'), ], 'filter returns an iterable of all matching nodes') - t.same([...i.query('license')].sort((a, b) => String(a).localeCompare(String(b, 'en'))), + t.same([...i.query('license')].sort((a, b) => localeCompare(String(a), String(b))), ['ISC', 'MIT', undefined]) t.same([...i.query('license', 'MIT')], [ { location: 'x', name: 'x', package: { licence: 'MIT', funding: 'foo' } }, @@ -33,7 +35,7 @@ t.test('basic operations', t => { { location: 'x', name: 'x', package: { licence: 'MIT', funding: 'foo' } }, { location: 'y', name: 'x', package: { licenses: [{ type: 'ISC' }], funding: { url: 'foo' } } }, ], 'can query by name') - t.same([...i.query('funding')].sort((a, b) => String(a).localeCompare(String(b, 'en'))), + t.same([...i.query('funding')].sort((a, b) => localeCompare(String(a), String(b))), ['bar', 'foo', undefined]) t.same([...i.query('funding', 'foo')], [ { location: 'x', name: 'x', package: { licence: 'MIT', funding: 'foo' } }, diff --git a/workspaces/arborist/test/link.js b/workspaces/arborist/test/link.js index b9b9f23..ec648ed 100644 --- a/workspaces/arborist/test/link.js +++ b/workspaces/arborist/test/link.js @@ -94,23 +94,6 @@ t.test('link.target setter', async t => { t.equal(oldTarget.linksIn.size, 0, 'old target still has no links') t.equal(newTarget.linksIn.size, 0, 'new target has no links in now') - const laterTarget = new Promise((res) => - setTimeout(() => res(new Node({ - path: '/node-later', - realpath: '/node-later', - pkg: { name: 'node-later', version: '1.2.3' }, - })))) - link.target = laterTarget - t.equal(link.target, laterTarget, 'waiting for a new target to resolve') - t.throws(() => link.target = oldTarget, { - message: 'cannot set target while awaiting', - path: link.path, - realpath: link.realpath, - }) - const node = await laterTarget - t.equal(link.target, node, 'target resolved and assigned') - t.equal(link.package, node.package, 'took on new targets package') - t.equal(node.linksIn.has(link), true, 'link in node.linksIn') link.target = null t.equal(link.target, null, 'target is now null') t.strictSame(link.package, {}, 'removed target, package is now empty') diff --git a/workspaces/arborist/test/node.js b/workspaces/arborist/test/node.js index ecdf72c..d89bf80 100644 --- a/workspaces/arborist/test/node.js +++ b/workspaces/arborist/test/node.js @@ -62,8 +62,8 @@ t.test('basic instantiation', t => { t.end() }) -t.test('testing with dep tree', t => { - const runTest = rootMetadata => t => { +t.test('testing with dep tree', async t => { + const runTest = rootMetadata => async t => { const root = new Node({ pkg: { name: 'root', @@ -115,6 +115,10 @@ t.test('testing with dep tree', t => { t.equal(meta.isDescendantOf(root), true, 'meta descends from root') t.equal(meta.root, root, 'meta rooted in same tree via parent') + // retrieve a node using querySelectorAll + const queryResult = await root.querySelectorAll('* #meta') + t.same(queryResult, [meta], 'should retrieve node using querySelectorAll') + const bundled = new Node({ pkg: { name: 'bundled', @@ -328,20 +332,30 @@ t.test('testing with dep tree', t => { t.equal(prodLink.children.size, 0, 'links do not have child nodes') t.equal(prodLink.target.children.size, kidCount, 'link target has children') + t.equal(newProd.canReplace(prodLink), true, 'node can replace link') + const { target } = prodLink + newProd.replace(prodLink) + t.equal(prodLink.parent, null, 'prodLink removed from tree') + t.equal(prodLink.target, null, 'prodLink lost its target') + t.equal(prodLink.root, prodLink, 'prodLink removed from tree') + t.equal(target.root, target, 'prodLinks old target removed from tree') + t.equal(normalizePath(newProd.path), normalizePath(prodLink.path), 'replaced node') + t.equal(prodLink.children.size, 0, 'prodLink has no child nodes') + t.end() }) t.end() } - t.test('without meta', runTest()) + t.test('without meta', await runTest()) const meta = new Shrinkwrap({ path: '/home/user/projects/root' }) meta.data = { lockfileVersion: 2, packages: {}, dependencies: {}, } - t.test('with meta', runTest(meta)) + t.test('with meta', await runTest(meta)) t.end() }) @@ -2714,6 +2728,52 @@ t.test('overrides', (t) => { t.end() }) + t.test('node.overridden is true when an override applies to a specific node', async (t) => { + const tree = new Node({ + loadOverrides: true, + path: '/some/path', + pkg: { + name: 'foo', + dependencies: { + bar: '^1', + }, + overrides: { + baz: '1.0.0', + }, + }, + children: [{ + name: 'bar', + version: '1.0.0', + pkg: { + dependencies: { + baz: '2.0.0', + }, + }, + children: [{ + name: 'baz', + version: '1.0.0', + pkg: { + dependencies: { + buzz: '1.0.0', + }, + }, + children: [{ + name: 'buzz', + version: '1.0.0', + pkg: {}, + }], + }], + }], + }) + + const bar = tree.edgesOut.get('bar').to + t.not(bar.overridden, 'bar was not overridden') + const baz = bar.edgesOut.get('baz').to + t.ok(baz.overridden, 'baz was overridden') + const buzz = baz.edgesOut.get('buzz').to + t.not(buzz.overridden, 'buzz was not overridden') + }) + t.test('assertRootOverrides throws when a dependency and override conflict', async (t) => { const conflictingTree = new Node({ loadOverrides: true, @@ -2781,6 +2841,62 @@ t.test('overrides', (t) => { t.end() }) + t.test('setting root replaces overrides', async (t) => { + const root = new Node({ + path: '/some/path', + loadOverrides: true, + pkg: { + name: 'root', + version: '1.0.0', + dependencies: { + foo: '^1.0.0', + }, + overrides: { + bar: '^2.0.0', + }, + }, + }) + + const foo = new Node({ + path: '/some/path/node_modules/foo', + pkg: { + name: 'foo', + version: '1.0.0', + dependencies: { + bar: '^1.0.0', + }, + }, + }) + + const bar = new Node({ + path: '/some/path/node_modules/bar', + pkg: { + name: 'bar', + version: '2.0.0', + }, + }) + + t.ok(root.overrides, 'root has overrides') + t.notOk(foo.overrides, 'foo does not have overrides') + t.notOk(bar.overrides, 'bar does not have overrides') + t.notOk(root.edgesOut.get('foo').valid, 'foo edge is not valid') + t.notOk(foo.edgesOut.get('bar').valid, 'bar edge is not valid') + + // we add bar to the root first, this is deliberate so that we don't have a simple + // linear inheritance. we'll add foo later and make sure that both edges and nodes + // become valid after that + + bar.root = root + t.ok(bar.overrides, 'bar now has overrides') + t.notOk(foo.edgesOut.get('bar').valid, 'bar edge is not valid yet') + + foo.root = root + t.ok(foo.overrides, 'foo now has overrides') + t.ok(root.edgesOut.get('foo').valid, 'foo edge is now valid') + t.ok(bar.overrides, 'bar still has overrides') + t.ok(foo.edgesOut.get('bar').valid, 'bar edge is now valid') + }) + t.test('canReplaceWith requires the same overrides', async (t) => { const original = new Node({ loadOverrides: true, @@ -2842,3 +2958,26 @@ t.test('overrides', (t) => { t.end() }) + +t.test('node with no edges in is not a registry dep', async t => { + const node = new Node({ path: '/foo' }) + t.equal(node.isRegistryDependency, false) +}) + +t.test('node with non registry edge in is not a registry dep', async t => { + const root = new Node({ path: '/some/path', pkg: { dependencies: { registry: '', tar: '' } } }) + const node = new Node({ pkg: { name: 'node', version: '1.0.0' }, parent: root }) + + new Node({ pkg: { name: 'registry', dependencies: { node: '^1.0.0' } }, parent: root }) + new Node({ pkg: { name: 'tar', dependencies: { node: 'file:node' } }, parent: root }) + + t.equal(node.isRegistryDependency, false) +}) + +t.test('node with only registry edges in a registry dep', async t => { + const root = new Node({ path: '/some/path', pkg: { dependencies: { registry: '', tar: '' } } }) + const node = new Node({ pkg: { name: 'node', version: '1.0.0' }, parent: root }) + new Node({ pkg: { name: 'registry', dependencies: { node: '^1.0.0' } }, parent: root }) + + t.equal(node.isRegistryDependency, true) +}) diff --git a/workspaces/arborist/test/override-set.js b/workspaces/arborist/test/override-set.js index d46e212..b5695d3 100644 --- a/workspaces/arborist/test/override-set.js +++ b/workspaces/arborist/test/override-set.js @@ -124,26 +124,26 @@ t.test('constructor', async (t) => { const fooRule = ruleset.get('foo') // these are both empty because the foo rule does not actually override // anything directly, it only carries child rules through - t.equal(fooRule.keySpec, '', 'keySpec is empty') - t.equal(fooRule.value, '', 'value is empty') + t.equal(fooRule.keySpec, '*', 'keySpec is *') + t.equal(fooRule.value, '*', 'value is *') const barRule = ruleset.get('bar') - t.equal(barRule.keySpec, '', 'keySpec is empty') + t.equal(barRule.keySpec, '*', 'keySpec is *') t.equal(barRule.value, '2.0.0', 'got the correct override for bar') const bazRule = ruleset.get('baz') - t.equal(bazRule.keySpec, '', 'keySpec is empty') + t.equal(bazRule.keySpec, '*', 'keySpec is *') t.equal(bazRule.value, '2.0.0', 'got the correct override for baz') const childRule = edgeRule.getEdgeRule({ name: 'bar', spec: '^1.0.0' }) const childRuleSet = childRule.ruleset const childBazRule = childRuleSet.get('baz') - t.equal(childBazRule.keySpec, '', 'keySpec is empty') + t.equal(childBazRule.keySpec, '*', 'keySpec is *') t.equal(childBazRule.value, '3.0.0', 'got the correct override for nested baz') const childBarRule = childRuleSet.get('bar') - t.equal(childBarRule.keySpec, '', 'keySpec is empty') + t.equal(childBarRule.keySpec, '*', 'keySpec is *') t.equal(childBarRule.value, '2.0.0', 'got the correct override for nested bar') const childFooRule = childRuleSet.get('foo') - t.equal(childFooRule.keySpec, '', 'keySpec is empty') - t.equal(childFooRule.value, '', 'value is empty') + t.equal(childFooRule.keySpec, '*', 'keySpec is *') + t.equal(childFooRule.value, '*', 'value is *') }) t.test('coerces empty string to *', async (t) => { @@ -161,6 +161,6 @@ t.test('constructor', async (t) => { t.equal(edgeRule.value, '*', 'empty string was replaced with *') const barEdgeRule = overrides.getEdgeRule({ name: 'bar', spec: '^1' }) - t.equal(barEdgeRule.value, '', 'when rule is omitted entirely value is an empty string') + t.equal(barEdgeRule.value, '*', 'when rule is omitted entirely value is *') }) }) diff --git a/workspaces/arborist/test/place-dep.js b/workspaces/arborist/test/place-dep.js index 418d228..292a2c8 100644 --- a/workspaces/arborist/test/place-dep.js +++ b/workspaces/arborist/test/place-dep.js @@ -39,14 +39,12 @@ t.test('placement tests', t => { updateNames = [], // an audit report, telling us which nodes are vulnerable auditReport = null, - // --legacy-bundling set? - legacyBundling = false, // --strict-peer-deps set? strictPeerDeps = false, // --legacy-peer-deps set? legacyPeerDeps = false, // installing with --global or --global-style? - globalStyle = false, + installStrategy = 'hoisted', } = options const node = tree.inventory.get(nodeLoc) @@ -80,10 +78,9 @@ t.test('placement tests', t => { explicitRequest, updateNames, auditReport, - legacyBundling, strictPeerDeps, legacyPeerDeps, - globalStyle, + installStrategy, }) } @@ -271,7 +268,7 @@ t.test('placement tests', t => { }), dep: new Node({ pkg: { name: 'bar', version: '1.0.0' } }), nodeLoc: 'node_modules/foo', - legacyBundling: true, + installStrategy: 'nested', test: (t, tree) => { const foobar = tree.children.get('foo').resolve('bar') t.equal(foobar.location, 'node_modules/foo/node_modules/bar') @@ -291,7 +288,7 @@ t.test('placement tests', t => { }), dep: new Node({ pkg: { name: 'bar', version: '1.0.0' } }), nodeLoc: 'node_modules/foo', - globalStyle: true, + installStrategy: 'shallow', test: (t, tree) => { const foobar = tree.children.get('foo').resolve('bar') t.equal(foobar.location, 'node_modules/foo/node_modules/bar') @@ -323,7 +320,7 @@ t.test('placement tests', t => { }), dep: new Node({ pkg: { name: 'baz', version: '1.0.0' } }), nodeLoc: 'node_modules/foo/node_modules/bar', - globalStyle: true, + installStrategy: 'shallow', test: (t, tree) => { const foobar = tree.children.get('foo').resolve('bar') const foobarbaz = foobar.resolve('baz') diff --git a/workspaces/arborist/test/printable.js b/workspaces/arborist/test/printable.js index be2a604..8d06059 100644 --- a/workspaces/arborist/test/printable.js +++ b/workspaces/arborist/test/printable.js @@ -421,15 +421,13 @@ t.test('show overrides', (t) => { version: '1.0.0', dependencies: { foo: '^1.0.0', - bar: '^1.0.0', }, overrides: { - 'foo@1': '2.0.0', bar: '2.0.0', }, }, children: [ - { pkg: { name: 'foo', version: '2.0.0' }, ...flags }, + { pkg: { name: 'foo', version: '1.0.0', dependencies: { bar: '^1.0.0' } }, ...flags }, { pkg: { name: 'bar', version: '2.0.0' }, ...flags }, ], ...flags, diff --git a/workspaces/arborist/test/query-selector-all.js b/workspaces/arborist/test/query-selector-all.js new file mode 100644 index 0000000..e206e0b --- /dev/null +++ b/workspaces/arborist/test/query-selector-all.js @@ -0,0 +1,964 @@ +'use strict' + +const nock = require('nock') +const t = require('tap') +const Arborist = require('..') + +const q = require('../lib/query-selector-all.js') + +// test helper that spits out pkgid for readability +// and deduplicates link/target from results +const querySelectorAll = async (tree, query, options) => { + const res = await q(tree, query, options) + return [...new Set(res.map(i => i.pkgid))] +} + +t.test('query-selector-all', async t => { + /* + fixture tree: + + query-selector-all-tests@1.0.0 + ├── @npmcli/abbrev@2.0.0 (extraneous) + ├─┬ a@1.0.0 -> ./a (production dep of query-selector-all-tests, workspace) + │ └─┬ baz@1.0.0 (optional dep of a) + │ └── lorem@1.0.0 (production dep of baz) + ├── abbrev@1.1.1 (production dep of query-selector-all-tests) + ├─┬ b@1.0.0 -> ./b (workspace) + │ └── bar@2.0.0 (production dep of b, deduped) + ├─┬ bar@2.0.0 (production dep of query-selector-all-tests) + │ └── moo@3.0.0 (production dep of bar) + ├─┬ foo@2.2.2 (dev dep of query-selector-all-tests) + │ ├─┬ bar@1.4.0 (production dep of foo, deduped) + │ │ └── dasher@2.0.0 (overridden peer dep of bar) + │ └── dash-separated-pkg@1.0.0 (production dep of foo) + ├── moo@3.0.0 (dev dep of query-selector-all-tests) + └─┬ recur@1.0.0 (dev dep of query-selector-all-tests) + └─┬ sive@1.0.0 (production dep of recur) + └── recur@1.0.0 (recursive production dep of recur, deduped) + + */ + + const now = Date.now() + const today = new Date(now) + const yesterday = new Date(now - (1000 * 60 * 60 * 24)) + const dayBeforeYesterday = new Date(now - (1000 * 60 * 60 * 24 * 2)) + // @npmcli/abbrev is deliberately left out of this list to cover the case when + // fetching a packument fails + const packumentStubs = { + a: { + '1.0.0': today, + }, + abbrev: { + '1.1.1': dayBeforeYesterday, + '1.2.0': yesterday, + }, + b: { + '1.0.0': today, + }, + bar: { + '1.4.0': dayBeforeYesterday, + '2.0.0': today, + }, + baz: { + // undefined for coverage in --before mode + '1.0.0': undefined, + '1.0.1': yesterday, + }, + 'dash-separated-pkg': { + '1.0.0': dayBeforeYesterday, + '2.0.0': yesterday, + }, + dasher: { + '2.0.0': today, + }, + foo: { + '2.2.2': today, + }, + lorem: { + '1.0.0': today, + }, + moo: { + '3.0.0': today, + }, + recur: { + '1.0.0': today, + }, + sive: { + '1.0.0': today, + }, + } + + nock.disableNetConnect() + t.teardown(() => { + nock.enableNetConnect() + }) + + for (const [pkg, versions] of Object.entries(packumentStubs)) { + nock('https://registry.npmjs.org') + .persist() + .get(`/${pkg}`) + .reply(200, { + time: Object.entries(versions).reduce((final, [version, time]) => { + return { ...final, [version]: time } + }, {}), + versions: Object.keys(versions).reduce((final, next) => { + return { ...final, [next]: {} } + }, {}), + }) + } + + const path = t.testdir({ + node_modules: { + '@npmcli': { + abbrev: { + 'package.json': JSON.stringify({ + name: '@npmcli/abbrev', + version: '2.0.0-beta.45', + }), + }, + }, + a: t.fixture('symlink', '../a'), + abbrev: { + 'package.json': JSON.stringify({ + name: 'abbrev', + version: '1.1.1', + license: 'ISC', + engines: { + node: '^16.0.0', + }, + }), + }, + b: t.fixture('symlink', '../b'), + bar: { + 'package.json': JSON.stringify({ + name: 'bar', + version: '2.0.0', + dependencies: { + moo: '3.0.0', + }, + engines: { + node: '>= 14.0.0', + }, + arbitrary: { + foo: [ + false, + 'foo', + 'bar', + { funding: { type: 'GH' } }, + { funding: { type: 'MS' } }, + 10000, + 13000, + 15000, + ], + bar: 'bar', + baz: ['a', 'b', 'c'], + }, + }), + }, + baz: { + 'package.json': JSON.stringify({ + name: 'baz', + version: '1.0.0', + license: ['ISC', 'Something'], + dependencies: { + lorem: 'latest', + }, + scripts: { + test: 'tap', + }, + engines: { + // intentionally invalid range + node: 'nope', + }, + }), + }, + foo: { + node_modules: { + bar: { + 'package.json': JSON.stringify({ + name: 'bar', + version: '1.4.0', + peerDependencies: { + dasher: '2.1.0', + }, + }), + }, + }, + 'package.json': JSON.stringify({ + name: 'foo', + version: '2.2.2', + arbitrary: 'foo key', + dependencies: { + bar: '^1.0.0', + 'dash-separated-pkg': '^1.0.0', + }, + }), + }, + 'dash-separated-pkg': { + 'package.json': JSON.stringify({ + name: 'dash-separated-pkg', + version: '1.0.0', + description: 'One of the best libraries every dev should know about.', + }), + }, + dasher: { + 'package.json': JSON.stringify({ + name: 'dasher', + version: '2.0.0', + description: 'The best library ever.', + }), + }, + ipsum: { + 'package.json': JSON.stringify({ + name: 'sit', + version: '1.0.0', + keywords: ['lorem', 'ipsum', 'dolor'], + dependencies: { + 'missing-dep': '^1.0.0', + }, + }), + }, + lorem: { + 'package.json': JSON.stringify({ + name: 'lorem', + version: '1.0.0', + keywords: ['lorem', 'ipsum', 'sit', 'amet'], + devDependencies: { + moo: '^3.0.0', + }, + funding: [ + { type: 'GitHub', url: 'https://github.com/sponsors' }, + ], + }), + }, + moo: { + 'package.json': JSON.stringify({ + name: 'moo', + version: '3.0.0', + }), + }, + recur: { + 'package.json': JSON.stringify({ + name: 'recur', + version: '1.0.0', + dependencies: { + sive: '1.0.0', + }, + }), + }, + sive: { + 'package.json': JSON.stringify({ + name: 'sive', + version: '1.0.0', + dependencies: { + recur: '1.0.0', + }, + }), + }, + }, + a: { 'package.json': JSON.stringify({ + name: 'a', + version: '1.0.0', + optionalDependencies: { + baz: '^1.0.0', + }, + }) }, + b: { 'package.json': JSON.stringify({ + name: 'b', + version: '1.0.0', + private: true, + devDependencies: { + a: '^1.0.0', + }, + dependencies: { + bar: '^2.0.0', + }, + }) }, + 'package.json': JSON.stringify({ + name: 'query-selector-all-tests', + version: '1.0.0', + workspaces: ['a', 'b'], + dependencies: { + a: '^1.0.0', + abbrev: '^1.1.1', + bar: '^2.0.0', + ipsum: 'npm:sit@1.0.0', + }, + overrides: { + dasher: '2.0.0', + }, + devDependencies: { + foo: '^2.0.0', + moo: '^3.0.0', + recur: '1.0.0', + }, + bundleDependencies: ['abbrev'], + }), + }) + + const opts = { + path, + fullMetadata: true, + } + const arb = new Arborist(opts) + const tree = await arb.loadActual(opts) + + // empty query? + const emptyRes = await q(tree, '') + t.same(emptyRes, [], 'empty query') + + // missing pseudo selector + t.rejects( + q(tree, ':foo'), + { code: 'EQUERYNOPSEUDO' }, + 'should throw on missing pseudo selector' + ) + + // missing depType + t.rejects( + q(tree, '.foo'), + { code: 'EQUERYNODEPTYPE' }, + 'should throw on missing dep type' + ) + + // missing attribute matcher on :attr + t.rejects( + q(tree, ':attr(foo, bar)'), + { code: 'EQUERYATTR' }, + 'should throw on missing attribute matcher on :attr pseudo' + ) + + // no type or tag selectors, as documented + t.rejects( + q(tree, 'node'), + { code: 'EQUERYNOSELECTOR' }, + 'should throw in invalid selector' + ) + + t.rejects( + q(tree, ':semver(1.0.0, [version], eqqq)'), + { code: 'EQUERYINVALIDOPERATOR' }, + 'should throw on invalid semver operator' + ) + + t.rejects( + q(tree, ':semver(nope)'), + { code: 'EQUERYINVALIDSEMVER' }, + 'should throw on invalid semver value' + ) + + // :scope pseudo + const [nodeFoo] = await q(tree, '#foo') + const scopeRes = await querySelectorAll(nodeFoo, ':scope') + t.same(scopeRes, ['foo@2.2.2'], ':scope') + + const scopeChildren = await querySelectorAll(nodeFoo, ':scope > *') + t.same(scopeChildren, [ + 'dash-separated-pkg@1.0.0', + 'bar@1.4.0', + ], ':scope > *') + + const runSpecParsing = async testCase => { + for (const [selector, expected, options = {}] of testCase) { + let title = selector + if (options.before) { + const friendlyTime = options.before === today + ? 'today' + : options.before === yesterday + ? 'yesterday' + : options.before + title += ` before ${friendlyTime}` + } + t.test(title, async t => { + const res = await querySelectorAll(tree, selector, options) + t.same( + res, + expected, + title + ) + }) + } + } + + await runSpecParsing([ + // universal selector + ['*', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + '@npmcli/abbrev@2.0.0-beta.45', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'bar@1.4.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + ['* > *', [ + 'a@1.0.0', + 'b@1.0.0', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'bar@1.4.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + ['> #a', ['a@1.0.0']], + + // pseudo :root + [':root', ['query-selector-all-tests@1.0.0']], + [':scope', ['query-selector-all-tests@1.0.0']], // same as root in this context + [':root > *', [ + 'a@1.0.0', + 'b@1.0.0', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'foo@2.2.2', + 'ipsum@npm:sit@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + ]], + [':root > .workspace', ['a@1.0.0', 'b@1.0.0']], + [':root > *.workspace', ['a@1.0.0', 'b@1.0.0']], + [':root > .workspace[name=a]', ['a@1.0.0']], + [':root > [name=bar]', ['bar@2.0.0']], + [':root > .workspace[version=1.0.0]', ['a@1.0.0', 'b@1.0.0']], + [':root > .workspace[name=a][version=1.0.0]', ['a@1.0.0']], + [':root > :root', []], + ['* > :root', []], + ['* :root', []], + [':root, :root', ['query-selector-all-tests@1.0.0']], + ['#a *:root', []], + ['#a > :root', []], + ['#a ~ :root', []], + + // pseudo miscelaneous + [':empty', [ + '@npmcli/abbrev@2.0.0-beta.45', + 'a@1.0.0', + 'abbrev@1.1.1', + 'b@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'lorem@1.0.0', + 'moo@3.0.0', + ]], + [':root > :empty', [ + 'a@1.0.0', + 'abbrev@1.1.1', + 'b@1.0.0', + 'moo@3.0.0', + ]], + [':extraneous', ['@npmcli/abbrev@2.0.0-beta.45']], + [':invalid', ['lorem@1.0.0']], + [':link', ['a@1.0.0', 'b@1.0.0']], + [':link', ['a@1.0.0', 'b@1.0.0']], + [':deduped', [ + 'bar@2.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + ]], + [':missing', ['missing-dep@^1.0.0']], + [':private', ['b@1.0.0']], + [':overridden', ['dasher@2.0.0']], + + // :not pseudo + [':not(#foo)', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + '@npmcli/abbrev@2.0.0-beta.45', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'bar@1.4.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + [':root > .workspace:not(#b)', ['a@1.0.0']], + [':root > .workspace > *:not(#bar)', ['a@1.0.0', 'baz@1.0.0']], + ['.bundled ~ :not(.workspace)', [ + 'bar@2.0.0', + 'foo@2.2.2', + 'ipsum@npm:sit@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + ]], + ['*:root > *:empty:not(*[name^=a], #b)', ['moo@3.0.0']], + [':not(:not(:link))', [ + 'a@1.0.0', + 'b@1.0.0', + ]], + + // has pseudo + [':root > *:has(* > #bar:semver(1.4.0))', ['foo@2.2.2']], + ['*:has(* > #bar:semver(1.4.0))', ['foo@2.2.2']], + ['*:has(> #bar:semver(1.4.0))', ['foo@2.2.2']], + ['.workspace:has(> * > #lorem)', ['a@1.0.0']], + ['.workspace:has(* #lorem, ~ #b)', ['a@1.0.0']], + + // is pseudo + [':is(#a, #b) > *', ['a@1.0.0', 'bar@2.0.0', 'baz@1.0.0']], + // TODO: ipsum is not empty but its child is missing so it doesn't return a + // result here + [':root > *:is(.prod:not(:empty), .dev > [name=bar]) > *', [ + 'a@1.0.0', + 'bar@2.0.0', + 'baz@1.0.0', + 'dasher@2.0.0', + 'moo@3.0.0', + ]], + [':is(*:semver(2.0.0), :semver(=2.0.0-beta.45))', [ + '@npmcli/abbrev@2.0.0-beta.45', + 'bar@2.0.0', + 'dasher@2.0.0', + ]], + + // type pseudo + [':type()', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + '@npmcli/abbrev@2.0.0-beta.45', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'bar@1.4.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + [':type(tag)', ['lorem@1.0.0']], + [':type(alias)', ['ipsum@npm:sit@1.0.0']], + [':type(range)', [ + 'a@1.0.0', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'foo@2.2.2', + 'bar@1.4.0', + 'moo@3.0.0', + ]], + [':type(git)', []], + + // path pseudo + [':path(node_modules/*)', [ + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + [':path(node_modules/bar)', ['bar@2.0.0']], + [':path(./node_modules/bar)', ['bar@2.0.0']], + [':path(node_modules/foo/node_modules/bar)', ['bar@1.4.0']], + [':path(**/bar)', ['bar@2.0.0', 'bar@1.4.0']], + [':path(*)', ['a@1.0.0', 'b@1.0.0']], + [':path()', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + '@npmcli/abbrev@2.0.0-beta.45', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'bar@1.4.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + + // semver pseudo + [':semver()', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + '@npmcli/abbrev@2.0.0-beta.45', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'bar@1.4.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + [':semver(*)', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'bar@1.4.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + [':semver(2.0.0)', [ + 'bar@2.0.0', + 'dasher@2.0.0', + ]], + [':semver(>=2)', [ + 'bar@2.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'moo@3.0.0', + ]], + [':semver(~2.0.x)', [ + 'bar@2.0.0', + 'dasher@2.0.0', + ]], + [':semver(2 - 3)', [ + 'bar@2.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'moo@3.0.0', + ]], + [':semver(=1.4.0)', ['bar@1.4.0']], + [':semver(1.4.0 || 2.2.2)', ['foo@2.2.2', 'bar@1.4.0']], + [':semver(^16.0.0, :attr(engines, [node]))', ['abbrev@1.1.1', 'bar@2.0.0']], + [':semver(18.0.0, :attr(engines, [node]))', ['bar@2.0.0']], + [':semver(^16.0.0, :attr(engines, [node^=">="]))', ['bar@2.0.0']], + [':semver(3.0.0, [version], eq)', ['moo@3.0.0']], + [':semver(^3.0.0, [version], eq)', []], + [':semver(1.0.0, [version], neq)', [ + '@npmcli/abbrev@2.0.0-beta.45', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'bar@1.4.0', + 'moo@3.0.0', + ]], + [':semver(^1.0.0, [version], neq)', []], + [':semver(2.0.0, [version], gt)', ['foo@2.2.2', 'moo@3.0.0']], + [':semver(^2.0.0, [version], gt)', []], + [':semver(2.0.0, [version], gte)', [ + 'bar@2.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'moo@3.0.0', + ]], + [':semver(^2.0.0, [version], gte)', []], + [':semver(1.1.1, [version], lt)', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + [':semver(^1.1.1, [version], lt)', []], + [':semver(1.1.1, [version], lte)', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + 'abbrev@1.1.1', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + [':semver(^1.1.1, [version], lte)', []], + [':semver(^14.0.0, :attr(engines, [node]), intersects)', ['bar@2.0.0']], + [':semver(>=14, :attr(engines, [node]), subset)', ['abbrev@1.1.1', 'bar@2.0.0']], + [':semver(^2.0.0, [version], gtr)', ['moo@3.0.0']], + [':semver(^2.0.0, :attr(engines, [node]), gtr)', []], + [':semver(20.0.0, :attr(engines, [node]), gtr)', ['abbrev@1.1.1']], + [':semver(1.0.1, [version], gtr)', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + [':semver(^1.1.1, [version], ltr)', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + [':semver(^1.1.1, :attr(engines, [node]), ltr)', []], + [':semver(0.0.1, :attr(engines, [node]), ltr)', ['abbrev@1.1.1', 'bar@2.0.0']], + [':semver(1.1.1, [version], ltr)', [ + '@npmcli/abbrev@2.0.0-beta.45', + 'bar@2.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'bar@1.4.0', + 'moo@3.0.0', + ]], + + // outdated pseudo + [':outdated', [ + 'abbrev@1.1.1', // 1.2.0 is available + 'baz@1.0.0', // 1.0.1 is available + 'dash-separated-pkg@1.0.0', // 2.0.0 is available + 'bar@1.4.0', // 2.0.0 is available + ]], + [':outdated(any)', [ + 'abbrev@1.1.1', // 1.2.0 is available + 'baz@1.0.0', // 1.0.1 is available + 'dash-separated-pkg@1.0.0', // 2.0.0 is available + 'bar@1.4.0', // 2.0.0 is available + ]], + [':outdated(major)', [ + 'dash-separated-pkg@1.0.0', // 2.0.0 is available + 'bar@1.4.0', // 2.0.0 is available + ]], + [':outdated(minor)', [ + 'abbrev@1.1.1', // 1.2.0 is available + ]], + [':outdated(patch)', [ + 'baz@1.0.0', // 1.0.1 is available + ]], + [':outdated(in-range)', [ + 'abbrev@1.1.1', // 1.2.0 is available and in-range + 'baz@1.0.0', // 1.0.1 is available and in-range + ]], + [':outdated(out-of-range)', [ + 'dash-separated-pkg@1.0.0', // 2.0.0 is available + 'bar@1.4.0', // 2.0.0 is available and out-of-range + ]], + [':outdated(nonsense)', []], // invalid, no results ever + + // :outdated combined with --before + [':outdated', [ + 'abbrev@1.1.1', // 1.2.0 is available and published yesterday + 'baz@1.0.0', // 1.0.1 is available and published yesterday + 'dash-separated-pkg@1.0.0', // 2.0.0 is available and published yesterday + ], { before: yesterday }], + [':outdated(any)', [ + 'abbrev@1.1.1', // 1.2.0 is available and published yesterday + 'baz@1.0.0', // 1.0.1 is available and published yesterday + 'dash-separated-pkg@1.0.0', // 2.0.0 is available and published yesterday + ], { before: yesterday }], + [':outdated(major)', [ + 'dash-separated-pkg@1.0.0', // 2.0.0 is available and published yesterday + ], { before: yesterday }], + [':outdated(minor)', [ + 'abbrev@1.1.1', // 1.2.0 is available and published yesterday + ], { before: yesterday }], + [':outdated(patch)', [ + 'baz@1.0.0', // 1.0.1 is available and published yesterday + ], { before: yesterday }], + [':outdated(in-range)', [ + 'abbrev@1.1.1', // 1.2.0 is available, in-range and published yesterday + 'baz@1.0.0', // 1.0.1 is available, in-range and published yesterday + ], { before: yesterday }], + [':outdated(out-of-range)', [ + 'dash-separated-pkg@1.0.0', // 2.0.0 is available, out-of-range and published yesterday + ], { before: yesterday }], + [':outdated(nonsense)', [], { before: yesterday }], // again, no results here ever + + // attr pseudo + [':attr([name=dasher])', ['dasher@2.0.0']], + [':attr(dependencies, [bar="^1.0.0"])', ['foo@2.2.2']], + [':attr(dependencies, :attr([bar="^1.0.0"]))', ['foo@2.2.2']], + [':attr([keywords=lorem])', ['ipsum@npm:sit@1.0.0', 'lorem@1.0.0']], + [':attr(arbitrary, [foo$=oo])', ['bar@2.0.0']], + [':attr(arbitrary, [foo*=oo])', ['bar@2.0.0']], + [':attr(arbitrary, [foo|=oo])', []], + [':attr(funding, :attr([type=GitHub]))', ['lorem@1.0.0']], + [':attr(arbitrary, foo, :attr(funding, [type=GH]))', ['bar@2.0.0']], + [':attr(arbitrary, foo, :attr(funding, [type=gh i]))', ['bar@2.0.0']], + [':attr(arbitrary, :attr([foo=10000]))', ['bar@2.0.0']], + + // attribute matchers + ['[scripts]', [ + 'baz@1.0.0', + ]], + ['[name]', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + '@npmcli/abbrev@2.0.0-beta.45', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'bar@1.4.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + ['[name=a]', ['a@1.0.0']], + ['[name=@npmcli/abbrev]', ['@npmcli/abbrev@2.0.0-beta.45']], + ['[name=a], [name=b]', ['a@1.0.0', 'b@1.0.0']], + ['[name=a], *[name=b]', ['a@1.0.0', 'b@1.0.0']], + ['[name^=a]', ['a@1.0.0', 'abbrev@1.1.1']], + ['[name|=dash]', ['dash-separated-pkg@1.0.0']], + ['[name$=oo]', ['foo@2.2.2', 'moo@3.0.0']], + ['[description]', [ + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + ]], + ['[description~=ever]', ['dasher@2.0.0']], + ['[description~=best]', [ + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + ]], + ['[name*=a]', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + '@npmcli/abbrev@2.0.0-beta.45', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'bar@1.4.0', + ]], + ['[arbitrary^=foo]', ['foo@2.2.2']], + ['[license=ISC]', ['abbrev@1.1.1', 'baz@1.0.0']], + ['[license=isc i]', ['abbrev@1.1.1', 'baz@1.0.0']], + + // types + ['.prod', [ + 'query-selector-all-tests@1.0.0', + 'a@1.0.0', + 'b@1.0.0', + 'abbrev@1.1.1', + 'bar@2.0.0', + 'baz@1.0.0', + 'ipsum@npm:sit@1.0.0', + 'lorem@1.0.0', + 'moo@3.0.0', + ]], + ['.workspace', ['a@1.0.0', 'b@1.0.0']], + ['.workspace > *', ['a@1.0.0', 'bar@2.0.0', 'baz@1.0.0']], + ['.workspace ~ *', [ + 'abbrev@1.1.1', + 'bar@2.0.0', + 'foo@2.2.2', + 'ipsum@npm:sit@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + ]], + ['.dev', [ + '@npmcli/abbrev@2.0.0-beta.45', + 'a@1.0.0', + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'foo@2.2.2', + 'bar@1.4.0', + 'moo@3.0.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + ['.dev *', [ + 'dash-separated-pkg@1.0.0', + 'dasher@2.0.0', + 'bar@1.4.0', + 'recur@1.0.0', + 'sive@1.0.0', + ]], + ['.peer', ['@npmcli/abbrev@2.0.0-beta.45', 'dasher@2.0.0']], + ['.optional', ['@npmcli/abbrev@2.0.0-beta.45', 'baz@1.0.0', 'lorem@1.0.0']], + ['.bundled', ['abbrev@1.1.1']], + ['.bundled ~ *', [ + 'a@1.0.0', + 'b@1.0.0', + 'bar@2.0.0', + 'foo@2.2.2', + 'ipsum@npm:sit@1.0.0', + 'moo@3.0.0', + 'recur@1.0.0', + ]], + + // id selector + ['#bar', ['bar@2.0.0', 'bar@1.4.0']], + ['#bar:semver(2.0.0)', ['bar@2.0.0']], + ['#@npmcli/abbrev:semver(2.0.0-beta.45)', ['@npmcli/abbrev@2.0.0-beta.45']], + ['#bar:semver(2.0)', ['bar@2.0.0']], + ['#bar:semver(2)', ['bar@2.0.0']], + ['#bar:semver(^2.0.0)', ['bar@2.0.0']], + ['#bar:semver(~2.0.0)', ['bar@2.0.0']], + ['#bar:semver(=2.0.0)', ['bar@2.0.0']], + ['#bar:semver(>=2.0.0)', ['bar@2.0.0']], + ['#bar:semver(<3.0.0)', ['bar@2.0.0', 'bar@1.4.0']], + ['#bar:semver(2 - 3)', ['bar@2.0.0']], + ['#bar:semver(2.0.0 - 3.0.0)', ['bar@2.0.0']], + ['#bar:semver(*)', ['bar@2.0.0', 'bar@1.4.0']], + ['#bar:semver(^2.0.0-beta.0)', ['bar@2.0.0']], + ['#bar:semver(>1.5.0 <3.0.0)', ['bar@2.0.0']], + ['#bar:semver(2.x)', ['bar@2.0.0']], + ['#bar:semver(2.x.x)', ['bar@2.0.0']], + ['#bar:semver(1||2)', ['bar@2.0.0', 'bar@1.4.0']], + ['#bar:semver(1 || 2)', ['bar@2.0.0', 'bar@1.4.0']], + ['#bar:semver(1 || 2.0.0)', ['bar@2.0.0', 'bar@1.4.0']], + ['#bar:semver(1.4.0 || 2)', ['bar@2.0.0', 'bar@1.4.0']], + ['#ipsum', ['ipsum@npm:sit@1.0.0']], + ['#bar > *', ['dasher@2.0.0', 'moo@3.0.0']], + [':root > #bar', ['bar@2.0.0']], + [':root > #bar > *', ['moo@3.0.0']], + [':root #bar > *', ['dasher@2.0.0', 'moo@3.0.0']], + [':root #bar:semver(1) > *', ['dasher@2.0.0']], + [':root #bar:semver(1) ~ *', ['dash-separated-pkg@1.0.0']], + ['#bar:semver(2), #foo', ['bar@2.0.0', 'foo@2.2.2']], + ['#a, #bar:semver(2), #foo:semver(2.2.2)', ['a@1.0.0', 'bar@2.0.0', 'foo@2.2.2']], + ]) +}) diff --git a/workspaces/arborist/test/shrinkwrap.js b/workspaces/arborist/test/shrinkwrap.js index d47266d..b5303f9 100644 --- a/workspaces/arborist/test/shrinkwrap.js +++ b/workspaces/arborist/test/shrinkwrap.js @@ -4,7 +4,6 @@ const Link = require('../lib/link.js') const calcDepFlags = require('../lib/calc-dep-flags.js') const fs = require('fs') const Arborist = require('../lib/arborist/index.js') -const rimraf = require('rimraf') const t = require('tap') @@ -44,7 +43,7 @@ t.test('load and change lockfileVersion', async t => { const v2 = await Shrinkwrap.load({ path: fixture, lockfileVersion: 2 }) const v3 = await Shrinkwrap.load({ path: fixture, lockfileVersion: 3 }) - t.strictSame(vDefault, v2, 'default is same as version 2') + t.strictSame(vDefault, v3, 'default is same as version 3') const v1Data = await v1.commit() const v2Data = await v2.commit() const v3Data = await v3.commit() @@ -54,31 +53,31 @@ t.test('load and change lockfileVersion', async t => { t.equal(v3Data.dependencies, undefined, 'v3 data does not have dependencies') }) -t.test('load and then reset gets empty lockfile', t => - Shrinkwrap.load({ path: fixture }).then(sw => { - sw.reset() - t.strictSame(sw.data, { - lockfileVersion: 2, - requires: true, - dependencies: {}, - packages: {}, - }) - t.equal(sw.loadedFromDisk, true) - t.equal(sw.filename, resolve(fixture, 'package-lock.json')) - })) +t.test('load and then reset gets empty lockfile', async t => { + const sw = await Shrinkwrap.load({ path: fixture }) + sw.reset() + t.strictSame(sw.data, { + lockfileVersion: 3, + requires: true, + dependencies: {}, + packages: {}, + }) + t.equal(sw.loadedFromDisk, true) + t.equal(sw.filename, resolve(fixture, 'package-lock.json')) +}) -t.test('starting out with a reset lockfile is an empty lockfile', t => - Shrinkwrap.reset({ path: fixture }).then(sw => { - t.strictSame(sw.data, { - lockfileVersion: 2, - requires: true, - dependencies: {}, - packages: {}, - }) - t.equal(sw.originalLockfileVersion, 2) - t.equal(sw.loadedFromDisk, true) - t.equal(sw.filename, resolve(fixture, 'package-lock.json')) - })) +t.test('starting out with a reset lockfile is an empty lockfile', async t => { + const sw = await Shrinkwrap.reset({ path: fixture }) + t.strictSame(sw.data, { + lockfileVersion: 3, + requires: true, + dependencies: {}, + packages: {}, + }) + t.equal(sw.originalLockfileVersion, 3) + t.equal(sw.loadedFromDisk, true) + t.equal(sw.filename, resolve(fixture, 'package-lock.json')) +}) t.test('reset in a bad dir gets an empty lockfile with no lockfile version', async t => { const nullLockDir = t.testdir({ @@ -91,7 +90,7 @@ t.test('reset in a bad dir gets an empty lockfile with no lockfile version', asy ]) t.strictSame(swMissingLock.data, { - lockfileVersion: 2, + lockfileVersion: 3, requires: true, dependencies: {}, packages: {}, @@ -100,7 +99,7 @@ t.test('reset in a bad dir gets an empty lockfile with no lockfile version', asy t.equal(swMissingLock.loadedFromDisk, false) t.strictSame(swNullLock.data, { - lockfileVersion: 2, + lockfileVersion: 3, requires: true, dependencies: {}, packages: {}, @@ -109,103 +108,103 @@ t.test('reset in a bad dir gets an empty lockfile with no lockfile version', asy t.equal(swNullLock.loadedFromDisk, true) }) -t.test('loading in bad dir gets empty lockfile', t => - Shrinkwrap.load({ path: 'path/which/does/not/exist' }).then(sw => { - t.strictSame(sw.data, { - lockfileVersion: 2, - requires: true, - dependencies: {}, - packages: {}, - }) - t.equal(sw.loadedFromDisk, false) - })) +t.test('loading in bad dir gets empty lockfile', async t => { + const sw = await Shrinkwrap.load({ path: 'path/which/does/not/exist' }) + t.strictSame(sw.data, { + lockfileVersion: 3, + requires: true, + dependencies: {}, + packages: {}, + }) + t.equal(sw.loadedFromDisk, false) +}) -t.test('failure to parse json gets empty lockfile', t => - Shrinkwrap.load({ path: badJsonFixture }).then(sw => { - t.strictSame(sw.data, { - lockfileVersion: 2, - requires: true, - dependencies: {}, - packages: {}, - }) - t.equal(sw.loadedFromDisk, false) - })) +t.test('failure to parse json gets empty lockfile', async t => { + const sw = await Shrinkwrap.load({ path: badJsonFixture }) + t.strictSame(sw.data, { + lockfileVersion: 3, + requires: true, + dependencies: {}, + packages: {}, + }) + t.equal(sw.loadedFromDisk, false) +}) -t.test('loading in empty dir gets empty lockfile', t => - Shrinkwrap.load({ path: emptyFixture }).then(sw => { - t.strictSame(sw.data, { - lockfileVersion: 2, - requires: true, - dependencies: {}, - packages: {}, - }) - t.equal(sw.loadedFromDisk, false) - // update with an empty node, set name to node name, not package name - const root = new Node({ - path: emptyFixture, - realpath: emptyFixture, - }) - root.peer = false - root.dev = false - root.devOptional = false - root.optional = false - root.extraneous = false - sw.add(root) - t.strictSame(sw.commit(), { - name: 'empty', - lockfileVersion: 2, - requires: true, - packages: {}, - }) - })) +t.test('loading in empty dir gets empty lockfile', async t => { + const sw = await Shrinkwrap.load({ path: emptyFixture }) + t.strictSame(sw.data, { + lockfileVersion: 3, + requires: true, + dependencies: {}, + packages: {}, + }) + t.equal(sw.loadedFromDisk, false) + // update with an empty node, set name to node name, not package name + const root = new Node({ + path: emptyFixture, + realpath: emptyFixture, + }) + root.peer = false + root.dev = false + root.devOptional = false + root.optional = false + root.extraneous = false + sw.add(root) + t.strictSame(sw.commit(), { + name: 'empty', + lockfileVersion: 3, + requires: true, + packages: {}, + }) +}) -t.test('look up from locks and such', t => - new Shrinkwrap({ path: fixture }).load().then(m => { - t.strictSame(m.get(''), { - name: 'a', - version: '1.2.3', - dependencies: { - abbrev: '^1.1.1', - 'full-git-url': 'git+https://github.com/isaacs/abbrev-js.git', - ghshort: 'github:isaacs/abbrev-js', - old: 'npm:abbrev@^1.0.3', - pinned: 'npm:abbrev@^1.1.1', - reg: 'npm:abbrev@^1.1.1', - remote: 'https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz', - symlink: 'file:./abbrev-link-target', - tarball: 'file:abbrev-1.1.1.tgz', - bundler: '1.2.3', - }, - }, 'root metadata') - t.match(m.data, { - lockfileVersion: 2, - requires: true, - dependencies: Object, - packages: Object, - }) - t.equal(m.loadedFromDisk, true) - t.matchSnapshot(m.get('node_modules/abbrev'), 'basic package') +t.test('look up from locks and such', async t => { + const m = await new Shrinkwrap({ path: fixture }).load() + t.strictSame(m.get(''), { + name: 'a', + version: '1.2.3', + dependencies: { + abbrev: '^1.1.1', + 'full-git-url': 'git+https://github.com/isaacs/abbrev-js.git', + ghshort: 'github:isaacs/abbrev-js', + old: 'npm:abbrev@^1.0.3', + pinned: 'npm:abbrev@^1.1.1', + reg: 'npm:abbrev@^1.1.1', + remote: 'https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz', + symlink: 'file:./abbrev-link-target', + tarball: 'file:abbrev-1.1.1.tgz', + bundler: '1.2.3', + }, + }, 'root metadata') + t.match(m.data, { + lockfileVersion: 3, + requires: true, + dependencies: Object, + packages: Object, + }) + t.equal(m.loadedFromDisk, true) + t.matchSnapshot(m.get('node_modules/abbrev'), 'basic package') + t.matchSnapshot(m.get( + 'node_modules/abbrev/node_modules/@scope/name/node_modules/@otherscope/othername', 'scoped package')) + t.matchSnapshot(m.get('package/not/found'), 'not found') + + t.matchSnapshot(m.get('node_modules/old/node_modules/notfound'), 'fall off the dep tree') + + t.test('lockfile', t => { + const p = m.data.packages + m.data.packages = {} + t.matchSnapshot(m.get('node_modules/abbrev'), 'basic pkg, from lock') + t.matchSnapshot(m.data.packages, 'saved fetched metadata back to packages section') t.matchSnapshot(m.get( 'node_modules/abbrev/node_modules/@scope/name/node_modules/@otherscope/othername', 'scoped package')) t.matchSnapshot(m.get('package/not/found'), 'not found') - - t.matchSnapshot(m.get('node_modules/old/node_modules/notfound'), 'fall off the dep tree') - - t.test('lockfile', t => { - const p = m.data.packages - m.data.packages = {} - t.matchSnapshot(m.get('node_modules/abbrev'), 'basic pkg, from lock') - t.matchSnapshot(m.data.packages, 'saved fetched metadata back to packages section') - t.matchSnapshot(m.get( - 'node_modules/abbrev/node_modules/@scope/name/node_modules/@otherscope/othername', 'scoped package')) - t.matchSnapshot(m.get('package/not/found'), 'not found') - t.matchSnapshot(m.get('node_modules/full-git-url'), 'full git') - t.matchSnapshot(m.get('node_modules/symlink'), 'symlink') - t.matchSnapshot(m.get('node_modules/unhosted-git'), 'unhosted git') - m.data.packages = p - t.end() - }) - })) + t.matchSnapshot(m.get('node_modules/full-git-url'), 'full git') + t.matchSnapshot(m.get('node_modules/symlink'), 'symlink') + t.matchSnapshot(m.get('node_modules/unhosted-git'), 'unhosted git') + m.data.packages = p + t.end() + }) +}) t.test('load a shrinkwrap with some dev and optional flags', t => Shrinkwrap.load({ path: depTypesFixture }).then(m => @@ -231,6 +230,94 @@ t.test('throws when attempting to access data before loading', t => { t.end() }) +t.test('resolveOptions', async t => { + const url = 'https://private.registry.org/deadbeef/registry/-/registry-1.2.3.tgz' + const someOtherRegistry = 'https://someother.registry.org/registry/-/registry-1.2.3.tgz' + const getData = async (resolveOptions) => { + const dir = t.testdir() + const meta = await Shrinkwrap.load({ + path: dir, + resolveOptions, + lockfileVersion: 2, + }) + + const root = new Node({ + pkg: { + name: 'root', + dependencies: { + registry: '^1.0.0', + 'some-other-registry': '^1.0.0', + '@scoped/some-other-registry': '^1.0.0', + tar: url, + }, + }, + path: dir, + realpath: dir, + meta, + }) + + const registry = new Node({ + pkg: { name: 'registry', version: '1.2.3' }, + resolved: url, + integrity: 'sha512-registry', + parent: root, + }) + + const otherRegistry = new Node({ + pkg: { name: 'some-other-registry', version: '1.2.3' }, + resolved: someOtherRegistry, + integrity: 'sha512-registry', + parent: root, + }) + + const scopedOtherRegistry = new Node({ + pkg: { name: '@scope/some-other-registry', version: '1.2.3' }, + resolved: someOtherRegistry, + integrity: 'sha512-registry', + parent: root, + }) + + const tar = new Node({ + pkg: { name: 'tar', version: '1.2.3' }, + resolved: url, + integrity: 'sha512-registry', + parent: root, + }) + + calcDepFlags(root) + meta.add(root) + return { data: meta.commit(), registry, tar, root, otherRegistry, scopedOtherRegistry } + } + + await t.test('omitLockfileRegistryResolved', async t => { + const { data } = await getData({ omitLockfileRegistryResolved: true }) + // registry dependencies in v2 packages and v1 dependencies should + // have resolved stripped. + t.strictSame(data.packages['node_modules/registry'].resolved, undefined) + + // tar should have resolved because it is not a registry dep. + t.strictSame(data.packages['node_modules/tar'].resolved, url) + // v1 url dependencies never have resolved. + t.strictSame(data.dependencies.tar.resolved, undefined) + }) + + await t.test('omitLockfileRegistryResolved: false', async t => { + const { data } = await getData({ omitLockfileRegistryResolved: false }) + t.strictSame(data.packages['node_modules/registry'].resolved, url) + t.strictSame(data.dependencies.registry.resolved, url) + + t.strictSame(data.packages['node_modules/tar'].resolved, url) + // v1 url dependencies never have resolved. + t.strictSame(data.dependencies.tar.resolved, undefined) + }) + + t.test('metaFromNode default', async t => { + // test to cover options default. + const { registry } = await getData(undefined) + t.strictSame(Shrinkwrap.metaFromNode(registry, '').resolved, url) + }) +}) + t.test('construct metadata from node and package data', t => { const meta = new Shrinkwrap({ path: '/home/user/projects/root' }) // fake load @@ -528,39 +615,39 @@ t.test('saving dependency-free shrinkwrap object', t => { t.test('write the shrinkwrap back to disk', t => { const dir = t.testdir({}) - t.test('just read and write back', t => - Shrinkwrap.load({ path: fixture }).then(s => { - s.filename = dir + '/test-shrinkwrap.json' - return s.save().then(() => - t.strictSame(require(s.filename), s.data, 'saved json matches data')) - })) - t.test('write back with pending changes', t => - Shrinkwrap.load({ path: fixture }).then(s => { - const dir = t.testdir({}) - s.filename = dir + '/test-shrinkwrap-with-changes.json' - const node = new Node({ - path: fixture + '/node_modules/newthing', - pkg: { - name: 'newthing', - version: '1.2.3', - }, - }) - s.add(node) - const preCommit = JSON.parse(JSON.stringify(s.data)) - const postCommit = s.commit() - t.notSame(postCommit, preCommit, 'committing changes the data') - // delete and re-add to put us back in the pre-commit state - s.delete(node.location) - s.add(node) - return s.save().then(() => { - t.strictSame(s.data, postCommit, 'committed changes to data') - t.strictSame(require(s.filename), s.data, 'saved json matches data') - }) - })) + t.test('just read and write back', async t => { + const s = await Shrinkwrap.load({ path: fixture, lockfileVersion: 1 }) + const fileData = require(s.filename) + s.filename = dir + '/test-shrinkwrap.json' + const shrinkwrapData = await s.commit() + t.strictSame(shrinkwrapData, fileData, 'saved json matches data') + }) + t.test('write back with pending changes', async t => { + const s = await Shrinkwrap.load({ path: fixture, lockfileVersion: 2 }) + const dir = t.testdir({}) + s.filename = dir + '/test-shrinkwrap-with-changes.json' + const node = new Node({ + path: fixture + '/node_modules/newthing', + pkg: { + name: 'newthing', + version: '1.2.3', + }, + }) + s.add(node) + const preCommit = JSON.parse(JSON.stringify(s.data)) + const postCommit = s.commit() + t.notSame(postCommit, preCommit, 'committing changes the data') + // delete and re-add to put us back in the pre-commit state + s.delete(node.location) + s.add(node) + await s.save() + t.strictSame(s.data, postCommit, 'committed changes to data') + t.strictSame(require(s.filename), s.data, 'saved json matches data') + }) t.end() }) -t.test('load shrinkwrap if no package-lock.json present', t => { +t.test('load shrinkwrap if no package-lock.json present', async t => { const dir = t.testdir({ 'npm-shrinkwrap.json': JSON.stringify({ lockfileVersion: 1, @@ -568,41 +655,39 @@ t.test('load shrinkwrap if no package-lock.json present', t => { version: '1.2.3', }), }) - return Promise.all([ - Shrinkwrap.load({ path: dir, shrinkwrapOnly: true }).then(s => - t.equal(s.type, 'npm-shrinkwrap.json', 'loaded with swonly')), - Shrinkwrap.reset({ path: dir, shrinkwrapOnly: true }).then(s => - t.equal(s.type, 'npm-shrinkwrap.json', 'loaded fresh')), - Shrinkwrap.load({ path: dir }).then(s => - t.equal(s.type, 'npm-shrinkwrap.json', 'loaded without swonly')), - Shrinkwrap.reset({ path: dir }).then(s => - t.equal(s.type, 'npm-shrinkwrap.json', 'loaded fresh without swonly')), - ]) + let s + s = await Shrinkwrap.load({ path: dir, shrinkwrapOnly: true }) + t.equal(s.type, 'npm-shrinkwrap.json', 'loaded with swonly') + s = await Shrinkwrap.reset({ path: dir, shrinkwrapOnly: true }) + t.equal(s.type, 'npm-shrinkwrap.json', 'loaded fresh') + s = await Shrinkwrap.load({ path: dir }) + t.equal(s.type, 'npm-shrinkwrap.json', 'loaded without swonly') + s = await Shrinkwrap.reset({ path: dir }) + t.equal(s.type, 'npm-shrinkwrap.json', 'loaded fresh without swonly') }) -t.test('load yarn.lock file if present', t => - Shrinkwrap.load({ path: yarnFixture }).then(s => { - t.type(s.yarnLock, YarnLock, 'loaded a yarn lock file') - t.not(s.yarnLock.entries.size, 0, 'got some entries') - })) +t.test('load yarn.lock file if present', async t => { + const s = await Shrinkwrap.load({ path: yarnFixture }) + t.type(s.yarnLock, YarnLock, 'loaded a yarn lock file') + t.not(s.yarnLock.entries.size, 0, 'got some entries') +}) -t.test('save yarn lock if loaded', t => - Shrinkwrap.load({ path: yarnFixture }).then(s => { - s.path = t.testdir() - s.filename = s.path + '/package-lock.json' - return s.save() - .then(() => Shrinkwrap.load({ path: s.path })) - .then(ss => t.strictSame(s.yarnLock, ss.yarnLock)) - })) +t.test('save yarn lock if loaded', async t => { + const s = await Shrinkwrap.load({ path: yarnFixture }) + s.path = t.testdir() + s.filename = s.path + '/package-lock.json' + await s.save() + const ss = await Shrinkwrap.load({ path: s.path }) + t.strictSame(s.yarnLock, ss.yarnLock) +}) -t.test('ignore yarn lock file parse errors', t => { +t.test('ignore yarn lock file parse errors', async t => { const dir = t.testdir({ 'yarn.lock': 'this is not a yarn lock file!', }) - return Shrinkwrap.load({ path: dir }).then(s => { - t.type(s.yarnLock, YarnLock, 'got a yarn lock object because a yarn lock exists') - t.equal(s.yarnLock.entries.size, 0, 'did not get any entries out of it') - }) + const s = await Shrinkwrap.load({ path: dir }) + t.type(s.yarnLock, YarnLock, 'got a yarn lock object because a yarn lock exists') + t.equal(s.yarnLock.entries.size, 0, 'did not get any entries out of it') }) t.test('load a resolution from yarn.lock if we dont have our own', async t => { @@ -723,38 +808,38 @@ t.test('handle missing dependencies object without borking', t => { t.end() }) -t.test('load a hidden lockfile', t => { +t.test('load a hidden lockfile', async t => { // ensure the hidden lockfile is newer than the contents // otherwise this can fail on a fresh checkout. fs.utimesSync(resolve(hiddenLockfileFixture, hidden), new Date(), new Date()) - return Shrinkwrap.load({ + const s = await Shrinkwrap.load({ path: hiddenLockfileFixture, hiddenLockfile: true, - }).then(s => { - t.matchSnapshot(s.data) - // make sure it does not add to the dependencies block when a new - // node is added. - s.data.dependencies = {} - s.add(new Node({ - path: hiddenLockfileFixture + '/node_modules/foo', - pkg: { - name: 'foo', - version: '1.2.3', - _integrity: 'sha512-deadbeef', - _resolved: 'https://registry.npmjs.org/foo/-/foo-1.2.3.tgz', - }, - })) - t.strictSame(s.data.dependencies, {}, 'did not add to legacy data') - const data = s.commit() - t.equal(data.packages[''], undefined, 'no root entry') - t.equal(data.dependencies, undefined, 'deleted legacy metadata') }) + t.matchSnapshot(s.data) + // make sure it does not add to the dependencies block when a new + // node is added. + s.data.dependencies = {} + s.add(new Node({ + path: hiddenLockfileFixture + '/node_modules/foo', + pkg: { + name: 'foo', + version: '1.2.3', + _integrity: 'sha512-deadbeef', + _resolved: 'https://registry.npmjs.org/foo/-/foo-1.2.3.tgz', + }, + })) + t.strictSame(s.data.dependencies, {}, 'did not add to legacy data') + const data = s.commit() + t.equal(data.packages[''], undefined, 'no root entry') + t.equal(data.dependencies, undefined, 'deleted legacy metadata') }) -t.test('load a fresh hidden lockfile', t => Shrinkwrap.reset({ - path: hiddenLockfileFixture, - hiddenLockfile: true, -}).then(sw => { +t.test('load a fresh hidden lockfile', async t => { + const sw = await Shrinkwrap.reset({ + path: hiddenLockfileFixture, + hiddenLockfile: true, + }) t.strictSame(sw.data, { lockfileVersion: 3, requires: true, @@ -763,7 +848,7 @@ t.test('load a fresh hidden lockfile', t => Shrinkwrap.reset({ }) t.equal(sw.loadedFromDisk, true) t.equal(sw.filename, resolve(hiddenLockfileFixture, hidden)) -})) +}) t.test('hidden lockfile only used if up to date', async t => { const lockdata = require(resolve(hiddenLockfileFixture, hidden)) @@ -807,8 +892,8 @@ t.test('hidden lockfile only used if up to date', async t => { // make the lockfile newer, but missing a folder from node_modules { - rimraf.sync(resolve(path, 'node_modules/abbrev')) - rimraf.sync(resolve(path, 'node_modules/xyz')) + fs.rmSync(resolve(path, 'node_modules/abbrev'), { recursive: true, force: true }) + fs.rmSync(resolve(path, 'node_modules/xyz'), { recursive: true, force: true }) const later = Date.now() + 10000 fs.utimesSync(resolve(path, hidden), new Date(later), new Date(later)) const s = await Shrinkwrap.load({ path, hiddenLockfile: true }) @@ -1100,18 +1185,19 @@ t.test('loadActual tests', t => { roots.push('tap-with-yarn-lock') - t.plan(roots.length) - roots.forEach(root => { + for (const root of roots) { const path = resolve(fixtures, root) - t.test(root, t => new Arborist({ path }).loadActual().then(tree => { + t.test(root, async t => { + const tree = await new Arborist({ path }).loadActual() const shrinkwrap = tree.meta.commit() t.matchSnapshot(shrinkwrap, 'shrinkwrap data') if (tree.meta.yarnLock) { const yarnLock = tree.meta.yarnLock.toString() t.matchSnapshot(yarnLock, 'yarn.lock data') } - })) - }) + }) + } + t.end() }) t.test('set integrity because location and resolved match', async t => { @@ -1463,7 +1549,7 @@ t.test('shrinkwrap where root is a link node', async t => { }) t.strictSame(root.meta.commit(), { - lockfileVersion: 2, + lockfileVersion: 3, requires: true, packages: { '': { @@ -1478,12 +1564,6 @@ t.test('shrinkwrap where root is a link node', async t => { extraneous: true, }, }, - dependencies: { - kid: { - version: '1.2.3', - extraneous: true, - }, - }, name: 'path', version: '1.2.3', extraneous: true, @@ -1565,11 +1645,11 @@ t.test('setting lockfileVersion from the file contents', async t => { t.test('default setting', async t => { const s1 = await loadAndReset({ path: `${path}/v1` }) - t.strictSame(s1, [2, null], 'will upgrade old lockfile') + t.strictSame(s1, [3, null], 'will upgrade old lockfile') const s2 = await loadAndReset({ path: `${path}/v2` }) t.strictSame(s2, [2, null], 'will keep v2 as v2') const s3 = await loadAndReset({ path: `${path}/v3` }) - t.strictSame(s3, [3, 3], 'load will keep v3 as v3') + t.strictSame(s3, [3, null], 'load will keep v3 as v3') }) t.test('v1', async t => { const s1 = await loadAndReset({ path: `${path}/v1`, lockfileVersion: 1 }) @@ -1596,7 +1676,7 @@ t.test('setting lockfileVersion from the file contents', async t => { t.strictSame(s3, [3, 3], 'keep v3 setting') }) - t.equal(Shrinkwrap.defaultLockfileVersion, 2, 'default is 2') + t.equal(Shrinkwrap.defaultLockfileVersion, 3, 'default is 3') t.test('load should return error correctly when it cant access folder', { skip: process.platform === 'win32' ? 'skip chmod in windows' : false }, diff --git a/workspaces/arborist/test/tracker.js b/workspaces/arborist/test/tracker.js index 03ece91..2296639 100644 --- a/workspaces/arborist/test/tracker.js +++ b/workspaces/arborist/test/tracker.js @@ -1,17 +1,8 @@ const Tracker = require('../lib/tracker.js')(class {}) const t = require('tap') -const npmlog = { - newGroup: () => ({ - newGroup: () => ({ finish: () => {} }), - finish: () => {}, - }), - enableProgress: () => {}, - disableProgress: () => {}, -} - -t.test('no npmlog', t => { - const tr = new Tracker() +t.test('with progress', t => { + const tr = new Tracker({ progress: true }) t.doesNotThrow(() => { tr.addTracker('testTracker') }) @@ -19,32 +10,36 @@ t.test('no npmlog', t => { tr.finishTracker('testTracker') }) + t.throws(() => { + tr.addTracker() + }, Error, `Tracker can't be null or undefined`) + t.end() }) t.test('adds tracker', t => { t.doesNotThrow(() => { - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() tr.addTracker('testTracker') }) t.doesNotThrow(() => { - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() tr.addTracker('testTracker') tr.addTracker('testTracker', 'subTracker') }) t.doesNotThrow(() => { - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() tr.addTracker('testTracker') tr.addTracker('testTracker', 'subTracker') tr.addTracker('testTracker', 'subTracker') }) t.doesNotThrow(() => { - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() tr.addTracker('testTracker') tr.addTracker('testTracker', 'subTracker.name', 'subTracker.key') }) - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() t.throws(() => { tr.addTracker() }, Error, `Tracker can't be null or undefined`) @@ -70,19 +65,19 @@ t.test('adds tracker', t => { t.test('finishes tracker', t => { t.doesNotThrow(() => { - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() tr.addTracker('testTracker') tr.finishTracker('testTracker') }) t.doesNotThrow(() => { - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() tr.addTracker('testTracker') tr.addTracker('testTracker', 'subTracker') tr.finishTracker('testTracker', 'subTracker') tr.finishTracker('testTracker') }) t.doesNotThrow(() => { - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() tr.addTracker('testTracker') tr.addTracker('testTracker', 'subTracker.name', 'subTracker.key') tr.finishTracker('testTracker', 'subTracker.name', 'subTracker.key') @@ -90,14 +85,14 @@ t.test('finishes tracker', t => { }) t.doesNotThrow(() => { - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() tr.addTracker('firstTracker') tr.addTracker('secondTracker') tr.finishTracker('firstTracker') tr.finishTracker('secondTracker') }) - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() t.throws(() => { tr.finishTracker() }, Error, `Tracker can't be null or undefined`) @@ -109,19 +104,19 @@ t.test('finishes tracker', t => { }, Error, `Tracker can't be null or undefined`) t.doesNotThrow(() => { - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() tr.addTracker('testTracker') tr.addTracker('testTracker', 'testChild') tr.finishTracker('testTracker') }) t.throws(() => { - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() tr.finishTracker('testTracker') }, Error, 'Tracker "testTracker" does not exist') t.doesNotThrow(() => { - const tr = new Tracker({ log: npmlog }) + const tr = new Tracker() tr.addTracker('testTracker') tr.finishTracker('testTracker', 'nonExistentSubTracker') }) diff --git a/workspaces/arborist/test/yarn-lock.js b/workspaces/arborist/test/yarn-lock.js index 06c1655..1227237 100644 --- a/workspaces/arborist/test/yarn-lock.js +++ b/workspaces/arborist/test/yarn-lock.js @@ -64,12 +64,12 @@ bar@foo: # yarn lockfile v1 -"bar@foo": - "version" "1.2.3" +bar@foo: + version "1.2.3" -"foo@bar": - "resolved" "https://registry.local/foo/-/foo-1.2.3.tgz" - "version" "1.2.3" +foo@bar: + version "1.2.3" + resolved "https://registry.local/foo/-/foo-1.2.3.tgz" `) t.end() }) @@ -86,11 +86,13 @@ t.test('load a yarn lock from an actual tree', t => { resolve(__dirname, 'fixtures/install-types'), resolve(__dirname, 'fixtures/links-all-over'), ] - fixtures.forEach(fixture => t.test(basename(fixture), t => - new Arborist({ path: fixture }).loadActual().then(tree => { + for (const fixture of fixtures) { + t.test(basename(fixture), async t => { + const tree = await new Arborist({ path: fixture }).loadActual() const y = YarnLock.fromTree(tree) t.matchSnapshot(y.toString(), 'yarn.lock from a package tree') - }))) + }) + } t.end() }) diff --git a/workspaces/config/.eslintrc.js b/workspaces/config/.eslintrc.js new file mode 100644 index 0000000..5db9f81 --- /dev/null +++ b/workspaces/config/.eslintrc.js @@ -0,0 +1,17 @@ +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' + +const { readdirSync: readdir } = require('fs') + +const localConfigs = readdir(__dirname) + .filter((file) => file.startsWith('.eslintrc.local.')) + .map((file) => `./${file}`) + +module.exports = { + root: true, + extends: [ + '@npmcli', + ...localConfigs, + ], +} diff --git a/workspaces/config/.gitignore b/workspaces/config/.gitignore new file mode 100644 index 0000000..79af2bf --- /dev/null +++ b/workspaces/config/.gitignore @@ -0,0 +1,21 @@ +# This file is automatically added by @npmcli/template-oss. Do not edit. + +# ignore everything in the root +/* + +# keep these +!**/.gitignore +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ +!/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/config/CHANGELOG.md b/workspaces/config/CHANGELOG.md new file mode 100644 index 0000000..9584f80 --- /dev/null +++ b/workspaces/config/CHANGELOG.md @@ -0,0 +1,145 @@ +# Changelog + +## [6.1.0](https://github.com/npm/cli/compare/config-v6.0.1...config-v6.1.0) (2022-11-02) + +### Features + +* [`706b3d3`](https://github.com/npm/cli/commit/706b3d3f227de43a095263926d2eef2b4e4cf2a9) [#5779](https://github.com/npm/cli/pull/5779) set --no-audit when installing outside of a project (like --global) (@fritzy) +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +### Dependencies + +* [`b89c19e`](https://github.com/npm/cli/commit/b89c19e9a7674b0bd9d336c14dee1bf381843648) [#5795](https://github.com/npm/cli/pull/5795) `cli-table3@0.6.3` +* [`66f9bcd`](https://github.com/npm/cli/commit/66f9bcd10b8d8cb635593c526727056581c7955d) `nopt@7.0.0` + +## [6.0.1](https://github.com/npm/config/compare/v6.0.0...v6.0.1) (2022-10-17) + +### Dependencies + +* [`dca20cc`](https://github.com/npm/config/commit/dca20cc00c0cbebd9d1a1cf1962e32e99057ea8e) [#99](https://github.com/npm/config/pull/99) bump @npmcli/map-workspaces from 2.0.4 to 3.0.0 +* [`fc42456`](https://github.com/npm/config/commit/fc424565014cc155e902940221b6283cbb40faf4) [#100](https://github.com/npm/config/pull/100) bump proc-log from 2.0.1 to 3.0.0 + +## [6.0.0](https://github.com/npm/config/compare/v5.0.0...v6.0.0) (2022-10-13) + +### ⚠️ BREAKING CHANGES + +* this module no longer attempts to change file ownership automatically + +### Features + +* [`805535f`](https://github.com/npm/config/commit/805535ff6b7255a3a2fb5e7da392f53b1c2f3c04) [#96](https://github.com/npm/config/pull/96) do not alter file ownership (#96) (@nlf) + +### Dependencies + +* [`c62c19c`](https://github.com/npm/config/commit/c62c19cffc65a8b6e89cbd071bd7578f246312a9) [#95](https://github.com/npm/config/pull/95) bump read-package-json-fast from 2.0.3 to 3.0.0 + +## [5.0.0](https://github.com/npm/config/compare/v4.2.2...v5.0.0) (2022-10-06) + +### ⚠️ BREAKING CHANGES + +* unscoped auth configuration is no longer automatically scoped to a registry. the `validate` method is no longer called automatically. the `_auth` configuration key is no longer split into `username` and `_password`. errors will be thrown by `validate()` if problems are found. +* `@npmcli/config` is now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + +* [`344ccd3`](https://github.com/npm/config/commit/344ccd3d07979d0cb36dad8a7fe2e9cbbdbdbc9e) [#92](https://github.com/npm/config/pull/92) throw errors for invalid auth configuration (#92) (@nlf) +* [`aa25682`](https://github.com/npm/config/commit/aa256827d76ec9b1aea06eb3ebdd033067a5e604) [#87](https://github.com/npm/config/pull/87) postinstall for dependabot template-oss PR (@lukekarrys) + +## [4.2.2](https://github.com/npm/config/compare/v4.2.1...v4.2.2) (2022-08-25) + + +### Bug Fixes + +* warn on bare auth related configs ([#78](https://github.com/npm/config/issues/78)) ([d4e582a](https://github.com/npm/config/commit/d4e582ab7d8d9f4a8615619bb7d3263df5de66e6)) + +## [4.2.1](https://github.com/npm/config/compare/v4.2.0...v4.2.1) (2022-08-09) + + +### Bug Fixes + +* correctly handle nerf-darted env vars ([#74](https://github.com/npm/config/issues/74)) ([71f559b](https://github.com/npm/config/commit/71f559b08e01616b53f61e1cf385fc44162e2d66)) +* linting ([#75](https://github.com/npm/config/issues/75)) ([deb1001](https://github.com/npm/config/commit/deb10011d1b5e3df84b7d13284ea55b07dd62b63)) + + +### Dependencies + +* bump nopt from 5.0.0 to 6.0.0 ([#72](https://github.com/npm/config/issues/72)) ([d825726](https://github.com/npm/config/commit/d825726049644f5bbe0edf27b5600cc60ae14ee5)) + +## [4.2.0](https://github.com/npm/config/compare/v4.1.0...v4.2.0) (2022-07-18) + + +### Features + +* detect registry-scoped certfile and keyfile options ([#69](https://github.com/npm/config/issues/69)) ([e58a4f1](https://github.com/npm/config/commit/e58a4f18f0ec0820fe57ccaff34c4135ece12558)) + +## [4.1.0](https://github.com/npm/config/compare/v4.0.2...v4.1.0) (2022-04-13) + + +### Features + +* warn on deprecated config ([#62](https://github.com/npm/config/issues/62)) ([190065e](https://github.com/npm/config/commit/190065ef53d39a1e09486639c710dabdd73d8a7c)) + +### [4.0.2](https://github.com/npm/config/compare/v4.0.1...v4.0.2) (2022-04-05) + + +### Bug Fixes + +* replace deprecated String.prototype.substr() ([#59](https://github.com/npm/config/issues/59)) ([43893b6](https://github.com/npm/config/commit/43893b638f82ade945cba27fe9e483b32eea99ae)) + + +### Dependencies + +* bump ini from 2.0.0 to 3.0.0 ([#60](https://github.com/npm/config/issues/60)) ([965e2a4](https://github.com/npm/config/commit/965e2a40c7649ffd6e84fb83823a2b751bcda294)) +* update @npmcli/map-workspaces requirement from ^2.0.1 to ^2.0.2 ([#49](https://github.com/npm/config/issues/49)) ([9a0f182](https://github.com/npm/config/commit/9a0f182c4fa46dadccc631a244678a3c469ad63a)) + +### [4.0.1](https://www.github.com/npm/config/compare/v4.0.0...v4.0.1) (2022-03-02) + + +### Bug Fixes + +* skip workspace detection when in global mode ([#47](https://www.github.com/npm/config/issues/47)) ([bedff61](https://www.github.com/npm/config/commit/bedff61c6f074f21c1586afe391dc2cb6e821619)) + + +### Dependencies + +* update @npmcli/map-workspaces requirement from ^2.0.0 to ^2.0.1 ([#43](https://www.github.com/npm/config/issues/43)) ([c397ab8](https://www.github.com/npm/config/commit/c397ab88c459fc477ae9094ec0ee0b571e6bb8ed)) + +## [4.0.0](https://www.github.com/npm/config/compare/v3.0.1...v4.0.0) (2022-02-14) + + +### ⚠ BREAKING CHANGES + +* drop support for the `log` option + +### Features + +* remove `log` option ([#40](https://www.github.com/npm/config/issues/40)) ([bbf5128](https://www.github.com/npm/config/commit/bbf512818f30d0764e3951449c8f07856d70991e)) + + +### Bug Fixes + +* correct a polynomial regex ([#39](https://www.github.com/npm/config/issues/39)) ([9af098f](https://www.github.com/npm/config/commit/9af098fb874c1a8122ab7a5e009235a1f7df72f5)) + +### [3.0.1](https://www.github.com/npm/config/compare/v3.0.0...v3.0.1) (2022-02-10) + + +### Dependencies + +* update semver requirement from ^7.3.4 to ^7.3.5 ([2cb225a](https://www.github.com/npm/config/commit/2cb225a907180a3b569c8c9baf23da1a989a2f1f)) +* use proc-log instead of process.emit ([fd4cd42](https://www.github.com/npm/config/commit/fd4cd429ef875ce68aa0be9bba329cae4e7adfe3)) + +## [3.0.0](https://www.github.com/npm/config/compare/v2.4.0...v3.0.0) (2022-02-01) + + +### ⚠ BREAKING CHANGES + +* this drops support for node10 and non-LTS versions of node12 and node14 + +### Features + +* automatically detect workspace roots ([#28](https://www.github.com/npm/config/issues/28)) ([a3dc623](https://www.github.com/npm/config/commit/a3dc6234d57c7c80c66a8c33e17cf1d97f86f8d9)) + + +### Bug Fixes + +* template-oss ([#29](https://www.github.com/npm/config/issues/29)) ([6440fba](https://www.github.com/npm/config/commit/6440fba6e04b1f87e57b4c2ccc5ea84d8a69b823)) diff --git a/node_modules/@npmcli/ci-detect/LICENSE b/workspaces/config/LICENSE similarity index 100% rename from node_modules/@npmcli/ci-detect/LICENSE rename to workspaces/config/LICENSE diff --git a/workspaces/config/README.md b/workspaces/config/README.md new file mode 100644 index 0000000..3241838 --- /dev/null +++ b/workspaces/config/README.md @@ -0,0 +1,260 @@ +# `@npmcli/config` + +Configuration management for the npm cli. + +This module is the spiritual descendant of +[`npmconf`](http://npm.im/npmconf), and the code that once lived in npm's +`lib/config/` folder. + +It does the management of configuration files that npm uses, but +importantly, does _not_ define all the configuration defaults or types, as +those parts make more sense to live within the npm CLI itself. + +The only exceptions: + +- The `prefix` config value has some special semantics, setting the local + prefix if specified on the CLI options and not in global mode, or the + global prefix otherwise. +- The `project` config file is loaded based on the local prefix (which can + only be set by the CLI config options, and otherwise defaults to a walk + up the folder tree to the first parent containing a `node_modules` + folder, `package.json` file, or `package-lock.json` file.) +- The `userconfig` value, as set by the environment and CLI (defaulting to + `~/.npmrc`, is used to load user configs. +- The `globalconfig` value, as set by the environment, CLI, and + `userconfig` file (defaulting to `$PREFIX/etc/npmrc`) is used to load + global configs. +- A `builtin` config, read from a `npmrc` file in the root of the npm + project itself, overrides all defaults. + +The resulting hierarchy of configs: + +- CLI switches. eg `--some-key=some-value` on the command line. These are + parsed by [`nopt`](http://npm.im/nopt), which is not a great choice, but + it's the one that npm has used forever, and changing it will be + difficult. +- Environment variables. eg `npm_config_some_key=some_value` in the + environment. There is no way at this time to modify this prefix. +- INI-formatted project configs. eg `some-key = some-value` in the + `localPrefix` folder (ie, the `cwd`, or its nearest parent that contains + either a `node_modules` folder or `package.json` file.) +- INI-formatted userconfig file. eg `some-key = some-value` in `~/.npmrc`. + The `userconfig` config value can be overridden by the `cli`, `env`, or + `project` configs to change this value. +- INI-formatted globalconfig file. eg `some-key = some-value` in + the `globalPrefix` folder, which is inferred by looking at the location + of the node executable, or the `prefix` setting in the `cli`, `env`, + `project`, or `userconfig`. The `globalconfig` value at any of those + levels can override this. +- INI-formatted builtin config file. eg `some-key = some-value` in + `/usr/local/lib/node_modules/npm/npmrc`. This is not configurable, and + is determined by looking in the `npmPath` folder. +- Default values (passed in by npm when it loads this module). + +## USAGE + +```js +const Config = require('@npmcli/config') +// the types of all the configs we know about +const types = require('./config/types.js') +// default values for all the configs we know about +const defaults = require('./config/defaults.js') +// if you want -c to be short for --call and so on, define it here +const shorthands = require('./config/shorthands.js') + +const conf = new Config({ + // path to the npm module being run + npmPath: resolve(__dirname, '..'), + types, + shorthands, + defaults, + // optional, defaults to process.argv + argv: process.argv, + // optional, defaults to process.env + env: process.env, + // optional, defaults to process.execPath + execPath: process.execPath, + // optional, defaults to process.platform + platform: process.platform, + // optional, defaults to process.cwd() + cwd: process.cwd(), +}) + +// emits log events on the process object +// see `proc-log` for more info +process.on('log', (level, ...args) => { + console.log(level, ...args) +}) + +// returns a promise that fails if config loading fails, and +// resolves when the config object is ready for action +conf.load().then(() => { + conf.validate() + console.log('loaded ok! some-key = ' + conf.get('some-key')) +}).catch(er => { + console.error('error loading configs!', er) +}) +``` + +## API + +The `Config` class is the sole export. + +```js +const Config = require('@npmcli/config') +``` + +### static `Config.typeDefs` + +The type definitions passed to `nopt` for CLI option parsing and known +configuration validation. + +### constructor `new Config(options)` + +Options: + +- `types` Types of all known config values. Note that some are effectively + given semantic value in the config loading process itself. +- `shorthands` An object mapping a shorthand value to an array of CLI + arguments that replace it. +- `defaults` Default values for each of the known configuration keys. + These should be defined for all configs given a type, and must be valid. +- `npmPath` The path to the `npm` module, for loading the `builtin` config + file. +- `cwd` Optional, defaults to `process.cwd()`, used for inferring the + `localPrefix` and loading the `project` config. +- `platform` Optional, defaults to `process.platform`. Used when inferring + the `globalPrefix` from the `execPath`, since this is done diferently on + Windows. +- `execPath` Optional, defaults to `process.execPath`. Used to infer the + `globalPrefix`. +- `env` Optional, defaults to `process.env`. Source of the environment + variables for configuration. +- `argv` Optional, defaults to `process.argv`. Source of the CLI options + used for configuration. + +Returns a `config` object, which is not yet loaded. + +Fields: + +- `config.globalPrefix` The prefix for `global` operations. Set by the + `prefix` config value, or defaults based on the location of the + `execPath` option. +- `config.localPrefix` The prefix for `local` operations. Set by the + `prefix` config value on the CLI only, or defaults to either the `cwd` or + its nearest ancestor containing a `node_modules` folder or `package.json` + file. +- `config.sources` A read-only `Map` of the file (or a comment, if no file + found, or relevant) to the config level loaded from that source. +- `config.data` A `Map` of config level to `ConfigData` objects. These + objects should not be modified directly under any circumstances. + - `source` The source where this data was loaded from. + - `raw` The raw data used to generate this config data, as it was parsed + initially from the environment, config file, or CLI options. + - `data` The data object reflecting the inheritance of configs up to this + point in the chain. + - `loadError` Any errors encountered that prevented the loading of this + config data. +- `config.list` A list sorted in priority of all the config data objects in + the prototype chain. `config.list[0]` is the `cli` level, + `config.list[1]` is the `env` level, and so on. +- `cwd` The `cwd` param +- `env` The `env` param +- `argv` The `argv` param +- `execPath` The `execPath` param +- `platform` The `platform` param +- `defaults` The `defaults` param +- `shorthands` The `shorthands` param +- `types` The `types` param +- `npmPath` The `npmPath` param +- `globalPrefix` The effective `globalPrefix` +- `localPrefix` The effective `localPrefix` +- `prefix` If `config.get('global')` is true, then `globalPrefix`, + otherwise `localPrefix` +- `home` The user's home directory, found by looking at `env.HOME` or + calling `os.homedir()`. +- `loaded` A boolean indicating whether or not configs are loaded +- `valid` A getter that returns `true` if all the config objects are valid. + Any data objects that have been modified with `config.set(...)` will be + re-evaluated when `config.valid` is read. + +### `config.load()` + +Load configuration from the various sources of information. + +Returns a `Promise` that resolves when configuration is loaded, and fails +if a fatal error is encountered. + +### `config.find(key)` + +Find the effective place in the configuration levels a given key is set. +Returns one of: `cli`, `env`, `project`, `user`, `global`, `builtin`, or +`default`. + +Returns `null` if the key is not set. + +### `config.get(key, where = 'cli')` + +Load the given key from the config stack. + +### `config.set(key, value, where = 'cli')` + +Set the key to the specified value, at the specified level in the config +stack. + +### `config.delete(key, where = 'cli')` + +Delete the configuration key from the specified level in the config stack. + +### `config.validate(where)` + +Verify that all known configuration options are set to valid values, and +log a warning if they are invalid. + +Invalid auth options will cause this method to throw an error with a `code` +property of `ERR_INVALID_AUTH`, and a `problems` property listing the specific +concerns with the current configuration. + +If `where` is not set, then all config objects are validated. + +Returns `true` if all configs are valid. + +Note that it's usually enough (and more efficient) to just check +`config.valid`, since each data object is marked for re-evaluation on every +`config.set()` operation. + +### `config.repair(problems)` + +Accept an optional array of problems (as thrown by `config.validate()`) and +perform the necessary steps to resolve them. If no problems are provided, +this method will call `config.validate()` internally to retrieve them. + +Note that you must `await config.save('user')` in order to persist the changes. + +### `config.isDefault(key)` + +Returns `true` if the value is coming directly from the +default definitions, if the current value for the key config is +coming from any other source, returns `false`. + +This method can be used for avoiding or tweaking default values, e.g: + +> Given a global default definition of foo='foo' it's possible to read that +> value such as: +> +> ```js +> const save = config.get('foo') +> ``` +> +> Now in a different place of your app it's possible to avoid using the `foo` +> default value, by checking to see if the current config value is currently +> one that was defined by the default definitions: +> +> ```js +> const save = config.isDefault('foo') ? 'bar' : config.get('foo') +> ``` + +### `config.save(where)` + +Save the config file specified by the `where` param. Must be one of +`project`, `user`, `global`, `builtin`. diff --git a/node_modules/@npmcli/config/lib/env-replace.js b/workspaces/config/lib/env-replace.js similarity index 67% rename from node_modules/@npmcli/config/lib/env-replace.js rename to workspaces/config/lib/env-replace.js index a6e4b29..c851f6e 100644 --- a/node_modules/@npmcli/config/lib/env-replace.js +++ b/workspaces/config/lib/env-replace.js @@ -1,14 +1,14 @@ // replace any ${ENV} values with the appropriate environ. -const envExpr = /(\\*)\$\{([^}]+)\}/g +const envExpr = /(?<!\\)(\\*)\$\{([^${}]+)\}/g module.exports = (f, env) => f.replace(envExpr, (orig, esc, name) => { const val = env[name] !== undefined ? env[name] : `$\{${name}}` // consume the escape chars that are relevant. if (esc.length % 2) { - return orig.substr((esc.length + 1) / 2) + return orig.slice((esc.length + 1) / 2) } - return (esc.substr(esc.length / 2)) + val + return (esc.slice(esc.length / 2)) + val }) diff --git a/workspaces/config/lib/errors.js b/workspaces/config/lib/errors.js new file mode 100644 index 0000000..fa3e207 --- /dev/null +++ b/workspaces/config/lib/errors.js @@ -0,0 +1,22 @@ +'use strict' + +class ErrInvalidAuth extends Error { + constructor (problems) { + let message = 'Invalid auth configuration found: ' + message += problems.map((problem) => { + if (problem.action === 'delete') { + return `\`${problem.key}\` is not allowed in ${problem.where} config` + } else if (problem.action === 'rename') { + return `\`${problem.from}\` must be renamed to \`${problem.to}\` in ${problem.where} config` + } + }).join(', ') + message += '\nPlease run `npm config fix` to repair your configuration.`' + super(message) + this.code = 'ERR_INVALID_AUTH' + this.problems = problems + } +} + +module.exports = { + ErrInvalidAuth, +} diff --git a/node_modules/@npmcli/config/lib/index.js b/workspaces/config/lib/index.js similarity index 79% rename from node_modules/@npmcli/config/lib/index.js rename to workspaces/config/lib/index.js index dc839a5..e1d47ff 100644 --- a/node_modules/@npmcli/config/lib/index.js +++ b/workspaces/config/lib/index.js @@ -2,25 +2,20 @@ const walkUp = require('walk-up-path') const ini = require('ini') const nopt = require('nopt') -const mkdirp = require('mkdirp-infer-owner') const mapWorkspaces = require('@npmcli/map-workspaces') const rpj = require('read-package-json-fast') - -/* istanbul ignore next */ -const myUid = process.getuid && process.getuid() -/* istanbul ignore next */ -const myGid = process.getgid && process.getgid() +const log = require('proc-log') const { resolve, dirname, join } = require('path') const { homedir } = require('os') -const { promisify } = require('util') -const fs = require('fs') -const readFile = promisify(fs.readFile) -const writeFile = promisify(fs.writeFile) -const chmod = promisify(fs.chmod) -const chown = promisify(fs.chown) -const unlink = promisify(fs.unlink) -const stat = promisify(fs.stat) +const { + readFile, + writeFile, + chmod, + unlink, + stat, + mkdir, +} = require('fs/promises') const hasOwnProperty = (obj, key) => Object.prototype.hasOwnProperty.call(obj, key) @@ -50,6 +45,10 @@ const parseField = require('./parse-field.js') const typeDescription = require('./type-description.js') const setEnvs = require('./set-envs.js') +const { + ErrInvalidAuth, +} = require('./errors.js') + // types that can be saved back to const confFileTypes = new Set([ 'global', @@ -88,7 +87,6 @@ class Config { // options just to override in tests, mostly env = process.env, argv = process.argv, - log = require('./proc-log.js'), platform = process.platform, execPath = process.execPath, cwd = process.cwd(), @@ -114,7 +112,6 @@ class Config { this.defaults = defaults this.npmPath = npmPath - this.log = log this.argv = argv this.env = env this.execPath = execPath @@ -281,25 +278,10 @@ class Config { await this.loadGlobalConfig() process.emit('timeEnd', 'config:load:global') - // warn if anything is not valid - process.emit('time', 'config:load:validate') - this.validate() - process.emit('timeEnd', 'config:load:validate') - // set this before calling setEnvs, so that we don't have to share // symbols, as that module also does a bunch of get operations this[_loaded] = true - process.emit('time', 'config:load:credentials') - const reg = this.get('registry') - const creds = this.getCredentialsByURI(reg) - // ignore this error because a failed set will strip out anything that - // might be a security hazard, which was the intention. - try { - this.setCredentialsByURI(reg, creds) - } catch (_) {} - process.emit('timeEnd', 'config:load:credentials') - // set proper globalPrefix now that everything is loaded this.globalPrefix = this.get('prefix') @@ -367,9 +349,11 @@ class Config { if (!/^npm_config_/i.test(envKey) || envVal === '') { continue } - const key = envKey.substr('npm_config_'.length) - .replace(/(?!^)_/g, '-') // don't replace _ at the start of the key - .toLowerCase() + let key = envKey.slice('npm_config_'.length) + if (!key.startsWith('//')) { // don't normalize nerf-darted keys + key = key.replace(/(?!^)_/g, '-') // don't replace _ at the start of the key + .toLowerCase() + } conf[key] = envVal } this[_loadObject](conf, 'env', 'environment') @@ -397,15 +381,58 @@ class Config { validate (where) { if (!where) { let valid = true - for (const [where] of this.data.entries()) { + const authProblems = [] + + for (const entryWhere of this.data.keys()) { // no need to validate our defaults, we know they're fine // cli was already validated when parsed the first time - if (where === 'default' || where === 'builtin' || where === 'cli') { + if (entryWhere === 'default' || entryWhere === 'builtin' || entryWhere === 'cli') { continue } - const ret = this.validate(where) + const ret = this.validate(entryWhere) valid = valid && ret + + if (['global', 'user', 'project'].includes(entryWhere)) { + // after validating everything else, we look for old auth configs we no longer support + // if these keys are found, we build up a list of them and the appropriate action and + // attach it as context on the thrown error + + // first, keys that should be removed + for (const key of ['_authtoken', '-authtoken']) { + if (this.get(key, entryWhere)) { + authProblems.push({ action: 'delete', key, where: entryWhere }) + } + } + + // NOTE we pull registry without restricting to the current 'where' because we want to + // suggest scoping things to the registry they would be applied to, which is the default + // regardless of where it was defined + const nerfedReg = nerfDart(this.get('registry')) + // keys that should be nerfed but currently are not + for (const key of ['_auth', '_authToken', 'username', '_password']) { + if (this.get(key, entryWhere)) { + // username and _password must both exist in the same file to be recognized correctly + if (key === 'username' && !this.get('_password', entryWhere)) { + authProblems.push({ action: 'delete', key, where: entryWhere }) + } else if (key === '_password' && !this.get('username', entryWhere)) { + authProblems.push({ action: 'delete', key, where: entryWhere }) + } else { + authProblems.push({ + action: 'rename', + from: key, + to: `${nerfedReg}:${key}`, + where: entryWhere, + }) + } + } + } + } } + + if (authProblems.length) { + throw new ErrInvalidAuth(authProblems) + } + return valid } else { const obj = this.data.get(where) @@ -421,6 +448,40 @@ class Config { } } + // fixes problems identified by validate(), accepts the 'problems' property from a thrown + // ErrInvalidAuth to avoid having to check everything again + repair (problems) { + if (!problems) { + try { + this.validate() + } catch (err) { + // coverage skipped here because we don't need to test re-throwing an error + // istanbul ignore next + if (err.code !== 'ERR_INVALID_AUTH') { + throw err + } + + problems = err.problems + } finally { + if (!problems) { + problems = [] + } + } + } + + for (const problem of problems) { + // coverage disabled for else branch because it doesn't do anything and shouldn't + // istanbul ignore else + if (problem.action === 'delete') { + this.delete(problem.key, problem.where) + } else if (problem.action === 'rename') { + const old = this.get(problem.from, problem.where) + this.set(problem.to, old, problem.where) + this.delete(problem.from, problem.where) + } + } + } + // Returns true if the value is coming directly from the source defined // in default definitions, if the current value for the key config is // coming from any other different source, returns false @@ -436,7 +497,7 @@ class Config { } invalidHandler (k, val, type, source, where) { - this.log.warn( + log.warn( 'invalid config', k + '=' + JSON.stringify(val), `set in ${source}` @@ -469,7 +530,7 @@ class Config { : mustBe.filter(m => m !== Array) .map(n => typeof n === 'string' ? n : JSON.stringify(n)) .join(', ') - this.log.warn('invalid config', msg, desc) + log.warn('invalid config', msg, desc) } [_loadObject] (obj, where, source, er = null) { @@ -491,7 +552,7 @@ class Config { if (er) { conf.loadError = er if (er.code !== 'ENOENT') { - this.log.verbose('config', `error loading ${where} config`, er) + log.verbose('config', `error loading ${where} config`, er) } } else { conf.raw = obj @@ -507,10 +568,9 @@ class Config { } [_checkDeprecated] (key, where, obj, kv) { - // XXX a future npm version will make this a warning. - // An even more future npm version will make this an error. + // XXX(npm9+) make this throw an error if (this.deprecated[key]) { - this.log.verbose('config', key, this.deprecated[key]) + log.warn('config', key, this.deprecated[key]) } } @@ -567,6 +627,7 @@ class Config { } const cliWorkspaces = this[_get]('workspaces', 'cli') + const isGlobal = this[_get]('global') || this[_get]('location') === 'global' for (const p of walkUp(this.cwd)) { const hasNodeModules = await stat(resolve(p, 'node_modules')) @@ -580,8 +641,8 @@ class Config { if (!this.localPrefix && (hasNodeModules || hasPackageJson)) { this.localPrefix = p - // if workspaces are disabled, return now - if (cliWorkspaces === false) { + // if workspaces are disabled, or we're in global mode, return now + if (cliWorkspaces === false || isGlobal) { return } @@ -607,14 +668,14 @@ class Config { .catch(() => false) if (hasNpmrc) { - this.log.warn(`ignoring workspace config at ${this.localPrefix}/.npmrc`) + log.warn(`ignoring workspace config at ${this.localPrefix}/.npmrc`) } // set the workspace in the default layer, which allows it to be overridden easily const { data } = this.data.get('default') data.workspace = [this.localPrefix] this.localPrefix = p - this.log.info(`found workspace root at ${this.localPrefix}`) + log.info(`found workspace root at ${this.localPrefix}`) // we found a root, so we return now return } @@ -642,20 +703,19 @@ class Config { if (!confFileTypes.has(where)) { throw new Error('invalid config location param: ' + where) } + const conf = this.data.get(where) conf[_raw] = { ...conf.data } conf[_loadError] = null - // upgrade auth configs to more secure variants before saving if (where === 'user') { - const reg = this.get('registry') - const creds = this.getCredentialsByURI(reg) - // we ignore this error because the failed set already removed - // anything that might be a security hazard, and it won't be - // saved back to the .npmrc file, so we're good. - try { - this.setCredentialsByURI(reg, creds) - } catch (_) {} + // if email is nerfed, then we want to de-nerf it + const nerfed = nerfDart(this.get('registry')) + const email = this.get(`${nerfed}:email`, 'user') + if (email) { + this.delete(`${nerfed}:email`, 'user') + this.set('email', email, 'user') + } } const iniData = ini.stringify(conf.data).trim() + '\n' @@ -665,16 +725,8 @@ class Config { return } const dir = dirname(conf.source) - await mkdirp(dir) + await mkdir(dir, { recursive: true }) await writeFile(conf.source, iniData, 'utf8') - // don't leave a root-owned config file lying around - /* istanbul ignore if - this is best-effort and a pita to test */ - if (myUid === 0) { - const st = await stat(dir).catch(() => null) - if (st && (st.uid !== myUid || st.gid !== myGid)) { - await chown(conf.source, st.uid, st.gid).catch(() => {}) - } - } const mode = where === 'user' ? 0o600 : 0o666 await chmod(conf.source, mode) } @@ -683,57 +735,44 @@ class Config { const nerfed = nerfDart(uri) const def = nerfDart(this.get('registry')) if (def === nerfed) { - // do not delete email, that shouldn't be nerfed any more. - // just delete the nerfed copy, if one exists. this.delete(`-authtoken`, 'user') this.delete(`_authToken`, 'user') this.delete(`_authtoken`, 'user') this.delete(`_auth`, 'user') this.delete(`_password`, 'user') this.delete(`username`, 'user') + // de-nerf email if it's nerfed to the default registry + const email = this.get(`${nerfed}:email`, 'user') + if (email) { + this.set('email', email, 'user') + } } - this.delete(`${nerfed}:-authtoken`, 'user') - this.delete(`${nerfed}:_authtoken`, 'user') this.delete(`${nerfed}:_authToken`, 'user') this.delete(`${nerfed}:_auth`, 'user') this.delete(`${nerfed}:_password`, 'user') this.delete(`${nerfed}:username`, 'user') this.delete(`${nerfed}:email`, 'user') + this.delete(`${nerfed}:certfile`, 'user') + this.delete(`${nerfed}:keyfile`, 'user') } - setCredentialsByURI (uri, { token, username, password, email }) { + setCredentialsByURI (uri, { token, username, password, email, certfile, keyfile }) { const nerfed = nerfDart(uri) - const def = nerfDart(this.get('registry')) - if (def === nerfed) { - // remove old style auth info not limited to a single registry - this.delete('_password', 'user') - this.delete('username', 'user') - this.delete('_auth', 'user') - this.delete('_authtoken', 'user') - this.delete('-authtoken', 'user') - this.delete('_authToken', 'user') - } - - // email used to be nerfed always. if we're using the default - // registry, de-nerf it. - if (nerfed === def) { - email = email || - this.get('email', 'user') || - this.get(`${nerfed}:email`, 'user') - if (email) { - this.set('email', email, 'user') - } - } + // email is either provided, a top level key, or nothing + email = email || this.get('email', 'user') // field that hasn't been used as documented for a LONG time, // and as of npm 7.10.0, isn't used at all. We just always // send auth if we have it, only to the URIs under the nerf dart. this.delete(`${nerfed}:always-auth`, 'user') - this.delete(`${nerfed}:-authtoken`, 'user') - this.delete(`${nerfed}:_authtoken`, 'user') this.delete(`${nerfed}:email`, 'user') + if (certfile && keyfile) { + this.set(`${nerfed}:certfile`, certfile, 'user') + this.set(`${nerfed}:keyfile`, keyfile, 'user') + // cert/key may be used in conjunction with other credentials, thus no `else` + } if (token) { this.set(`${nerfed}:_authToken`, token, 'user') this.delete(`${nerfed}:_password`, 'user') @@ -751,7 +790,7 @@ class Config { // protects against shoulder-hacks if password is memorable, I guess? const encoded = Buffer.from(password, 'utf8').toString('base64') this.set(`${nerfed}:_password`, encoded, 'user') - } else { + } else if (!certfile || !keyfile) { throw new Error('No credentials to set.') } } @@ -759,18 +798,29 @@ class Config { // this has to be a bit more complicated to support legacy data of all forms getCredentialsByURI (uri) { const nerfed = nerfDart(uri) + const def = nerfDart(this.get('registry')) const creds = {} + // email is handled differently, it used to always be nerfed and now it never should be + // if it's set nerfed to the default registry, then we copy it to the unnerfed key + // TODO: evaluate removing 'email' from the credentials object returned here const email = this.get(`${nerfed}:email`) || this.get('email') if (email) { + if (nerfed === def) { + this.set('email', email, 'user') + } creds.email = email } - const tokenReg = this.get(`${nerfed}:_authToken`) || - this.get(`${nerfed}:_authtoken`) || - this.get(`${nerfed}:-authtoken`) || - nerfed === nerfDart(this.get('registry')) && this.get('_authToken') + const certfileReg = this.get(`${nerfed}:certfile`) + const keyfileReg = this.get(`${nerfed}:keyfile`) + if (certfileReg && keyfileReg) { + creds.certfile = certfileReg + creds.keyfile = keyfileReg + // cert/key may be used in conjunction with other credentials, thus no `return` + } + const tokenReg = this.get(`${nerfed}:_authToken`) if (tokenReg) { creds.token = tokenReg return creds @@ -796,35 +846,7 @@ class Config { return creds } - // at this point, we can only use the values if the URI is the - // default registry. - const defaultNerf = nerfDart(this.get('registry')) - if (nerfed !== defaultNerf) { - return creds - } - - const userDef = this.get('username') - const passDef = this.get('_password') - if (userDef && passDef) { - creds.username = userDef - creds.password = Buffer.from(passDef, 'base64').toString('utf8') - const auth = `${creds.username}:${creds.password}` - creds.auth = Buffer.from(auth, 'utf8').toString('base64') - return creds - } - - // Handle the old-style _auth=<base64> style for the default - // registry, if set. - const auth = this.get('_auth') - if (!auth) { - return creds - } - - const authDecode = Buffer.from(auth, 'base64').toString('utf8') - const authSplit = authDecode.split(':') - creds.username = authSplit.shift() - creds.password = authSplit.join(':') - creds.auth = auth + // at this point, nothing else is usable so just return what we do have return creds } diff --git a/node_modules/@npmcli/config/lib/nerf-dart.js b/workspaces/config/lib/nerf-dart.js similarity index 100% rename from node_modules/@npmcli/config/lib/nerf-dart.js rename to workspaces/config/lib/nerf-dart.js diff --git a/node_modules/@npmcli/config/lib/parse-field.js b/workspaces/config/lib/parse-field.js similarity index 98% rename from node_modules/@npmcli/config/lib/parse-field.js rename to workspaces/config/lib/parse-field.js index 9428996..0c905bf 100644 --- a/node_modules/@npmcli/config/lib/parse-field.js +++ b/workspaces/config/lib/parse-field.js @@ -56,7 +56,7 @@ const parseField = (f, key, opts, listElement = false) => { if (isPath) { const homePattern = platform === 'win32' ? /^~(\/|\\)/ : /^~\// if (homePattern.test(f) && home) { - f = resolve(home, f.substr(2)) + f = resolve(home, f.slice(2)) } else { f = resolve(f) } diff --git a/node_modules/@npmcli/config/lib/set-envs.js b/workspaces/config/lib/set-envs.js similarity index 100% rename from node_modules/@npmcli/config/lib/set-envs.js rename to workspaces/config/lib/set-envs.js diff --git a/node_modules/@npmcli/config/lib/type-defs.js b/workspaces/config/lib/type-defs.js similarity index 100% rename from node_modules/@npmcli/config/lib/type-defs.js rename to workspaces/config/lib/type-defs.js diff --git a/node_modules/@npmcli/config/lib/type-description.js b/workspaces/config/lib/type-description.js similarity index 100% rename from node_modules/@npmcli/config/lib/type-description.js rename to workspaces/config/lib/type-description.js diff --git a/node_modules/@npmcli/config/lib/umask.js b/workspaces/config/lib/umask.js similarity index 100% rename from node_modules/@npmcli/config/lib/umask.js rename to workspaces/config/lib/umask.js diff --git a/workspaces/config/map.js b/workspaces/config/map.js new file mode 100644 index 0000000..0b263fb --- /dev/null +++ b/workspaces/config/map.js @@ -0,0 +1 @@ +module.exports = t => t.replace(/^test/, 'lib') diff --git a/workspaces/config/package.json b/workspaces/config/package.json new file mode 100644 index 0000000..3d70a15 --- /dev/null +++ b/workspaces/config/package.json @@ -0,0 +1,55 @@ +{ + "name": "@npmcli/config", + "version": "6.1.0", + "files": [ + "bin/", + "lib/" + ], + "main": "lib/index.js", + "description": "Configuration management for the npm cli", + "repository": { + "type": "git", + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/config" + }, + "author": "GitHub Inc.", + "license": "ISC", + "scripts": { + "test": "tap", + "snap": "tap", + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "lintfix": "node ../.. run lint -- --fix", + "posttest": "node ../.. run lint", + "template-oss-apply": "template-oss-apply --force" + }, + "tap": { + "check-coverage": true, + "coverage-map": "map.js", + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] + }, + "devDependencies": { + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "tap": "^16.3.2" + }, + "dependencies": { + "@npmcli/map-workspaces": "^3.0.0", + "ini": "^3.0.0", + "nopt": "^7.0.0", + "proc-log": "^3.0.0", + "read-package-json-fast": "^3.0.0", + "semver": "^7.3.5", + "walk-up-path": "^1.0.0" + }, + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + }, + "templateOSS": { + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0" + } +} diff --git a/workspaces/config/scripts/example.js b/workspaces/config/scripts/example.js new file mode 100644 index 0000000..bbb2992 --- /dev/null +++ b/workspaces/config/scripts/example.js @@ -0,0 +1,43 @@ +const Config = require('../') + +const shorthands = require('../test/fixtures/shorthands.js') +const types = require('../test/fixtures/types.js') +const defaults = require('../test/fixtures/defaults.js') + +const npmPath = __dirname + +const timers = {} +process.on('time', k => { + if (timers[k]) { + throw new Error('duplicate timer: ' + k) + } + timers[k] = process.hrtime() +}) +process.on('timeEnd', k => { + if (!timers[k]) { + throw new Error('ending unstarted timer: ' + k) + } + const dur = process.hrtime(timers[k]) + delete timers[k] + console.error(`\x1B[2m${k}\x1B[22m`, Math.round(dur[0] * 1e6 + dur[1] / 1e3) / 1e3) + delete timers[k] +}) + +process.on('log', (level, ...message) => + console.log(`\x1B[31m${level}\x1B[39m`, ...message)) + +const priv = /(^|:)_([^=]+)=(.*)\n/g +const ini = require('ini') +const config = new Config({ shorthands, types, defaults, npmPath }) +config.load().then(async () => { + for (const [where, { data, source }] of config.data.entries()) { + console.log(`; ${where} from ${source}`) + if (where === 'default' && !config.get('long')) { + console.log('; not shown, run with -l to show all\n') + } else { + console.log(ini.stringify(data).replace(priv, '$1_$2=******\n')) + } + } + console.log('argv:', { raw: config.argv, parsed: config.parsedArgv }) + return undefined +}).catch(() => {}) diff --git a/workspaces/config/tap-snapshots/test/index.js.test.cjs b/workspaces/config/tap-snapshots/test/index.js.test.cjs new file mode 100644 index 0000000..6680fd2 --- /dev/null +++ b/workspaces/config/tap-snapshots/test/index.js.test.cjs @@ -0,0 +1,240 @@ +/* IMPORTANT + * This snapshot file is auto-generated, but designed for humans. + * It should be checked into source control and tracked carefully. + * Re-generate by setting TAP_SNAPSHOT=1 and running tests. + * Make sure to inspect the output below. Do not ignore changes! + */ +'use strict' +exports[`test/index.js TAP credentials management def_auth > default registry 1`] = ` +Object { + "auth": "aGVsbG86d29ybGQ=", + "password": "world", + "username": "hello", +} +` + +exports[`test/index.js TAP credentials management def_auth > default registry after set 1`] = ` +Object { + "auth": "aGVsbG86d29ybGQ=", + "password": "world", + "username": "hello", +} +` + +exports[`test/index.js TAP credentials management def_auth > other registry 1`] = ` +Object {} +` + +exports[`test/index.js TAP credentials management def_passNoUser > default registry 1`] = ` +Object { + "email": "i@izs.me", +} +` + +exports[`test/index.js TAP credentials management def_passNoUser > other registry 1`] = ` +Object { + "email": "i@izs.me", +} +` + +exports[`test/index.js TAP credentials management def_userNoPass > default registry 1`] = ` +Object { + "email": "i@izs.me", +} +` + +exports[`test/index.js TAP credentials management def_userNoPass > other registry 1`] = ` +Object { + "email": "i@izs.me", +} +` + +exports[`test/index.js TAP credentials management def_userpass > default registry 1`] = ` +Object { + "auth": "aGVsbG86d29ybGQ=", + "email": "i@izs.me", + "password": "world", + "username": "hello", +} +` + +exports[`test/index.js TAP credentials management def_userpass > default registry after set 1`] = ` +Object { + "auth": "aGVsbG86d29ybGQ=", + "email": "i@izs.me", + "password": "world", + "username": "hello", +} +` + +exports[`test/index.js TAP credentials management def_userpass > other registry 1`] = ` +Object { + "email": "i@izs.me", +} +` + +exports[`test/index.js TAP credentials management nerfed_auth > default registry 1`] = ` +Object { + "auth": "aGVsbG86d29ybGQ=", + "password": "world", + "username": "hello", +} +` + +exports[`test/index.js TAP credentials management nerfed_auth > default registry after set 1`] = ` +Object { + "auth": "aGVsbG86d29ybGQ=", + "password": "world", + "username": "hello", +} +` + +exports[`test/index.js TAP credentials management nerfed_auth > other registry 1`] = ` +Object {} +` + +exports[`test/index.js TAP credentials management nerfed_authToken > default registry 1`] = ` +Object { + "token": "0bad1de4", +} +` + +exports[`test/index.js TAP credentials management nerfed_authToken > default registry after set 1`] = ` +Object { + "token": "0bad1de4", +} +` + +exports[`test/index.js TAP credentials management nerfed_authToken > other registry 1`] = ` +Object {} +` + +exports[`test/index.js TAP credentials management nerfed_mtls > default registry 1`] = ` +Object { + "certfile": "/path/to/cert", + "keyfile": "/path/to/key", +} +` + +exports[`test/index.js TAP credentials management nerfed_mtls > default registry after set 1`] = ` +Object { + "certfile": "/path/to/cert", + "keyfile": "/path/to/key", +} +` + +exports[`test/index.js TAP credentials management nerfed_mtls > other registry 1`] = ` +Object {} +` + +exports[`test/index.js TAP credentials management nerfed_mtlsAuthToken > default registry 1`] = ` +Object { + "certfile": "/path/to/cert", + "keyfile": "/path/to/key", + "token": "0bad1de4", +} +` + +exports[`test/index.js TAP credentials management nerfed_mtlsAuthToken > default registry after set 1`] = ` +Object { + "certfile": "/path/to/cert", + "keyfile": "/path/to/key", + "token": "0bad1de4", +} +` + +exports[`test/index.js TAP credentials management nerfed_mtlsAuthToken > other registry 1`] = ` +Object {} +` + +exports[`test/index.js TAP credentials management nerfed_mtlsUserPass > default registry 1`] = ` +Object { + "auth": "aGVsbG86d29ybGQ=", + "certfile": "/path/to/cert", + "email": "i@izs.me", + "keyfile": "/path/to/key", + "password": "world", + "username": "hello", +} +` + +exports[`test/index.js TAP credentials management nerfed_mtlsUserPass > default registry after set 1`] = ` +Object { + "auth": "aGVsbG86d29ybGQ=", + "certfile": "/path/to/cert", + "email": "i@izs.me", + "keyfile": "/path/to/key", + "password": "world", + "username": "hello", +} +` + +exports[`test/index.js TAP credentials management nerfed_mtlsUserPass > other registry 1`] = ` +Object { + "email": "i@izs.me", +} +` + +exports[`test/index.js TAP credentials management nerfed_userpass > default registry 1`] = ` +Object { + "auth": "aGVsbG86d29ybGQ=", + "email": "i@izs.me", + "password": "world", + "username": "hello", +} +` + +exports[`test/index.js TAP credentials management nerfed_userpass > default registry after set 1`] = ` +Object { + "auth": "aGVsbG86d29ybGQ=", + "email": "i@izs.me", + "password": "world", + "username": "hello", +} +` + +exports[`test/index.js TAP credentials management nerfed_userpass > other registry 1`] = ` +Object { + "email": "i@izs.me", +} +` + +exports[`test/index.js TAP credentials management none_authToken > default registry 1`] = ` +Object { + "token": "0bad1de4", +} +` + +exports[`test/index.js TAP credentials management none_authToken > default registry after set 1`] = ` +Object { + "token": "0bad1de4", +} +` + +exports[`test/index.js TAP credentials management none_authToken > other registry 1`] = ` +Object {} +` + +exports[`test/index.js TAP credentials management none_emptyConfig > default registry 1`] = ` +Object {} +` + +exports[`test/index.js TAP credentials management none_emptyConfig > other registry 1`] = ` +Object {} +` + +exports[`test/index.js TAP credentials management none_lcAuthToken > default registry 1`] = ` +Object {} +` + +exports[`test/index.js TAP credentials management none_lcAuthToken > other registry 1`] = ` +Object {} +` + +exports[`test/index.js TAP credentials management none_noConfig > default registry 1`] = ` +Object {} +` + +exports[`test/index.js TAP credentials management none_noConfig > other registry 1`] = ` +Object {} +` diff --git a/workspaces/config/tap-snapshots/test/type-description.js.test.cjs b/workspaces/config/tap-snapshots/test/type-description.js.test.cjs new file mode 100644 index 0000000..9d80f7e --- /dev/null +++ b/workspaces/config/tap-snapshots/test/type-description.js.test.cjs @@ -0,0 +1,449 @@ +/* IMPORTANT + * This snapshot file is auto-generated, but designed for humans. + * It should be checked into source control and tracked carefully. + * Re-generate by setting TAP_SNAPSHOT=1 and running tests. + * Make sure to inspect the output below. Do not ignore changes! + */ +'use strict' +exports[`test/type-description.js TAP > must match snapshot 1`] = ` +Object { + "_exit": Array [ + "boolean value (true or false)", + ], + "access": Array [ + null, + "restricted", + "public", + ], + "all": Array [ + "boolean value (true or false)", + ], + "allow-same-version": Array [ + "boolean value (true or false)", + ], + "also": Array [ + null, + "dev", + "development", + ], + "always-auth": Array [ + "boolean value (true or false)", + ], + "audit": Array [ + "boolean value (true or false)", + ], + "audit-level": Array [ + "low", + "moderate", + "high", + "critical", + "none", + null, + ], + "auth-type": Array [ + "legacy", + "sso", + "saml", + "oauth", + ], + "before": Array [ + null, + "valid Date string", + ], + "bin-links": Array [ + "boolean value (true or false)", + ], + "browser": Array [ + null, + "boolean value (true or false)", + Function String(), + ], + "ca": Array [ + null, + Function String(), + Function Array(), + ], + "cache": Array [ + "valid filesystem path", + ], + "cache-lock-retries": Array [ + "numeric value", + ], + "cache-lock-stale": Array [ + "numeric value", + ], + "cache-lock-wait": Array [ + "numeric value", + ], + "cache-max": Array [ + "numeric value", + ], + "cache-min": Array [ + "numeric value", + ], + "cafile": Array [ + "valid filesystem path", + ], + "call": Array [ + Function String(), + ], + "cert": Array [ + null, + Function String(), + ], + "cidr": Array [ + null, + Function String(), + Function Array(), + ], + "color": Array [ + "always", + "boolean value (true or false)", + ], + "commit-hooks": Array [ + "boolean value (true or false)", + ], + "depth": Array [ + "numeric value", + ], + "description": Array [ + "boolean value (true or false)", + ], + "dev": Array [ + "boolean value (true or false)", + ], + "dry-run": Array [ + "boolean value (true or false)", + ], + "editor": Array [ + Function String(), + ], + "engine-strict": Array [ + "boolean value (true or false)", + ], + "fetch-retries": Array [ + "numeric value", + ], + "fetch-retry-factor": Array [ + "numeric value", + ], + "fetch-retry-maxtimeout": Array [ + "numeric value", + ], + "fetch-retry-mintimeout": Array [ + "numeric value", + ], + "force": Array [ + "boolean value (true or false)", + ], + "format-package-lock": Array [ + "boolean value (true or false)", + ], + "fund": Array [ + "boolean value (true or false)", + ], + "git": Array [ + Function String(), + ], + "git-tag-version": Array [ + "boolean value (true or false)", + ], + "global": Array [ + "boolean value (true or false)", + ], + "global-style": Array [ + "boolean value (true or false)", + ], + "globalconfig": Array [ + "valid filesystem path", + ], + "heading": Array [ + Function String(), + ], + "https-proxy": Array [ + null, + "full url with \\"http://\\"", + ], + "if-present": Array [ + "boolean value (true or false)", + ], + "ignore-prepublish": Array [ + "boolean value (true or false)", + ], + "ignore-scripts": Array [ + "boolean value (true or false)", + ], + "include": Array [ + Function Array(), + "prod", + "dev", + "optional", + "peer", + ], + "include-staged": Array [ + "boolean value (true or false)", + ], + "init-author-email": Array [ + Function String(), + ], + "init-author-name": Array [ + Function String(), + ], + "init-author-url": Array [ + "", + "full url with \\"http://\\"", + ], + "init-license": Array [ + Function String(), + ], + "init-module": Array [ + "valid filesystem path", + ], + "init-version": Array [ + "full valid SemVer string", + ], + "json": Array [ + "boolean value (true or false)", + ], + "key": Array [ + null, + Function String(), + ], + "legacy-bundling": Array [ + "boolean value (true or false)", + ], + "legacy-peer-deps": Array [ + "boolean value (true or false)", + ], + "link": Array [ + "boolean value (true or false)", + ], + "loglevel": Array [ + "silent", + "error", + "warn", + "notice", + "http", + "timing", + "info", + "verbose", + "silly", + ], + "logs-max": Array [ + "numeric value", + ], + "long": Array [ + "boolean value (true or false)", + ], + "maxsockets": Array [ + "numeric value", + ], + "message": Array [ + Function String(), + ], + "metrics-registry": Array [ + null, + Function String(), + ], + "multiple-numbers": Array [ + Function Array(), + "numeric value", + ], + "node-options": Array [ + null, + Function String(), + ], + "node-version": Array [ + null, + "full valid SemVer string", + ], + "noproxy": Array [ + null, + Function String(), + Function Array(), + ], + "offline": Array [ + "boolean value (true or false)", + ], + "omit": Array [ + Function Array(), + "dev", + "optional", + "peer", + ], + "only": Array [ + null, + "dev", + "development", + "prod", + "production", + ], + "optional": Array [ + "boolean value (true or false)", + ], + "otp": Array [ + null, + Function String(), + ], + "package": Array [ + Function String(), + Function Array(), + ], + "package-lock": Array [ + "boolean value (true or false)", + ], + "package-lock-only": Array [ + "boolean value (true or false)", + ], + "parseable": Array [ + "boolean value (true or false)", + ], + "prefer-offline": Array [ + "boolean value (true or false)", + ], + "prefer-online": Array [ + "boolean value (true or false)", + ], + "prefix": Array [ + "valid filesystem path", + ], + "preid": Array [ + Function String(), + ], + "production": Array [ + "boolean value (true or false)", + ], + "progress": Array [ + "boolean value (true or false)", + ], + "proxy": Array [ + null, + false, + "full url with \\"http://\\"", + ], + "read-only": Array [ + "boolean value (true or false)", + ], + "rebuild-bundle": Array [ + "boolean value (true or false)", + ], + "registry": Array [ + null, + "full url with \\"http://\\"", + ], + "rollback": Array [ + "boolean value (true or false)", + ], + "save": Array [ + "boolean value (true or false)", + ], + "save-bundle": Array [ + "boolean value (true or false)", + ], + "save-dev": Array [ + "boolean value (true or false)", + ], + "save-exact": Array [ + "boolean value (true or false)", + ], + "save-optional": Array [ + "boolean value (true or false)", + ], + "save-prefix": Array [ + Function String(), + ], + "save-prod": Array [ + "boolean value (true or false)", + ], + "scope": Array [ + Function String(), + ], + "script-shell": Array [ + null, + Function String(), + ], + "scripts-prepend-node-path": Array [ + "boolean value (true or false)", + "auto", + "warn-only", + ], + "searchexclude": Array [ + null, + Function String(), + ], + "searchlimit": Array [ + "numeric value", + ], + "searchopts": Array [ + Function String(), + ], + "searchstaleness": Array [ + "numeric value", + ], + "send-metrics": Array [ + "boolean value (true or false)", + ], + "shell": Array [ + Function String(), + ], + "shrinkwrap": Array [ + "boolean value (true or false)", + ], + "sign-git-commit": Array [ + "boolean value (true or false)", + ], + "sign-git-tag": Array [ + "boolean value (true or false)", + ], + "sso-poll-frequency": Array [ + "numeric value", + ], + "sso-type": Array [ + null, + "oauth", + "saml", + ], + "strict-ssl": Array [ + "boolean value (true or false)", + ], + "tag": Array [ + Function String(), + ], + "tag-version-prefix": Array [ + Function String(), + ], + "timing": Array [ + "boolean value (true or false)", + ], + "tmp": Array [ + "valid filesystem path", + ], + "umask": Array [ + "octal number in range 0o000..0o777 (0..511)", + ], + "unicode": Array [ + "boolean value (true or false)", + ], + "update-notifier": Array [ + "boolean value (true or false)", + ], + "usage": Array [ + "boolean value (true or false)", + ], + "user-agent": Array [ + Function String(), + ], + "userconfig": Array [ + "valid filesystem path", + ], + "version": Array [ + "boolean value (true or false)", + ], + "versions": Array [ + "boolean value (true or false)", + ], + "viewer": Array [ + Function String(), + ], +} +` diff --git a/workspaces/config/test/env-replace.js b/workspaces/config/test/env-replace.js new file mode 100644 index 0000000..c2b5703 --- /dev/null +++ b/workspaces/config/test/env-replace.js @@ -0,0 +1,13 @@ +const envReplace = require('../lib/env-replace.js') +const t = require('tap') + +const env = { + foo: 'bar', + bar: 'baz', +} + +t.equal(envReplace('\\${foo}', env), '${foo}') +t.equal(envReplace('\\\\${foo}', env), '\\bar') +t.equal(envReplace('${baz}', env), '${baz}') +t.equal(envReplace('\\${baz}', env), '${baz}') +t.equal(envReplace('\\\\${baz}', env), '\\${baz}') diff --git a/workspaces/config/test/fixtures/cafile b/workspaces/config/test/fixtures/cafile new file mode 100644 index 0000000..0bc922b --- /dev/null +++ b/workspaces/config/test/fixtures/cafile @@ -0,0 +1,32 @@ +-----BEGIN CERTIFICATE----- +MIICjTCCAfigAwIBAgIEMaYgRzALBgkqhkiG9w0BAQQwRTELMAkGA1UEBhMCVVMx +NjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFuZCBTcGFjZSBBZG1pbmlz +dHJhdGlvbjAmFxE5NjA1MjgxMzQ5MDUrMDgwMBcROTgwNTI4MTM0OTA1KzA4MDAw +ZzELMAkGA1UEBhMCVVMxNjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFu +ZCBTcGFjZSBBZG1pbmlzdHJhdGlvbjEgMAkGA1UEBRMCMTYwEwYDVQQDEwxTdGV2 +ZSBTY2hvY2gwWDALBgkqhkiG9w0BAQEDSQAwRgJBALrAwyYdgxmzNP/ts0Uyf6Bp +miJYktU/w4NG67ULaN4B5CnEz7k57s9o3YY3LecETgQ5iQHmkwlYDTL2fTgVfw0C +AQOjgaswgagwZAYDVR0ZAQH/BFowWDBWMFQxCzAJBgNVBAYTAlVTMTYwNAYDVQQK +Ey1OYXRpAAAAACBBZXJvbmF1dGljcyBhbmQgU3BhY2UgQWRtaW5pc3RyYXRpb24x +DTALBgNVBAMTBENSTDEwFwYDVR0BAQH/BA0wC4AJODMyOTcwODEwMBgGA1UdAgQR +MA8ECTgzMjk3MDgyM4ACBSAwDQYDVR0KBAYwBAMCBkAwCwYJKoZIhvcNAQEEA4GB +AH2y1VCEw/A4zaXzSYZJTTUi3uawbbFiS2yxHvgf28+8Js0OHXk1H1w2d6qOHH21 +X82tZXd/0JtG0g1T9usFFBDvYK8O0ebgz/P5ELJnBL2+atObEuJy1ZZ0pBDWINR3 +WkDNLCGiTkCKp0F5EWIrVDwh54NNevkCQRZita+z4IBO +-----END CERTIFICATE----- +-----BEGIN CERTIFICATE----- +AAAAAACCAfigAwIBAgIEMaYgRzALBgkqhkiG9w0BAQQwRTELMAkGA1UEBhMCVVMx +NjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFuZCBTcGFjZSBBZG1pbmlz +dHJhdGlvbjAmFxE5NjA1MjgxMzQ5MDUrMDgwMBcROTgwNTI4MTM0OTA1KzA4MDAw +ZzELMAkGA1UEBhMCVVMxNjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFu +ZCBTcGFjZSBBZG1pbmlzdHJhdGlvbjEgMAkGA1UEBRMCMTYwEwYDVQQDEwxTdGV2 +ZSBTY2hvY2gwWDALBgkqhkiG9w0BAQEDSQAwRgJBALrAwyYdgxmzNP/ts0Uyf6Bp +miJYktU/w4NG67ULaN4B5CnEz7k57s9o3YY3LecETgQ5iQHmkwlYDTL2fTgVfw0C +AQOjgaswgagwZAYDVR0ZAQH/BFowWDBWMFQxCzAJBgNVBAYTAlVTMTYwNAYDVQQK +Ey1OYXRpb25hbCBBZXJvbmF1dGljcyBhbmQgU3BhY2UgQWRtaW5pc3RyYXRpb24x +DTALBgNVBAMTBENSTDEwFwYDVR0BAQH/BA0wC4AJODMyOTcwODEwMBgGA1UdAgQR +MA8ECTgzMjk3MDgyM4ACBSAwDQYDVR0KBAYwBAMCBkAwCwYJKoZIhvcNAQEEA4GB +AH2y1VCEw/A4zaXzSYZJTTUi3uawbbFiS2yxHvgf28+8Js0OHXk1H1w2d6qOHH21 +X82tZXd/0JtG0g1T9usFFBDvYK8O0ebgz/P5ELJnBL2+atObEuJy1ZZ0pBDWINR3 +WkDNLCGiTkCKp0F5EWIrVDwh54NNevkCQRZita+z4IBO +-----END CERTIFICATE----- diff --git a/workspaces/config/test/fixtures/defaults.js b/workspaces/config/test/fixtures/defaults.js new file mode 100644 index 0000000..322ceb0 --- /dev/null +++ b/workspaces/config/test/fixtures/defaults.js @@ -0,0 +1,143 @@ +module.exports = { + methane: 'CH4', + access: null, + all: false, + 'allow-same-version': false, + 'always-auth': false, + also: null, + audit: true, + 'audit-level': null, + 'auth-type': 'legacy', + + before: null, + 'bin-links': true, + browser: null, + + ca: null, + cafile: null, + + cache: '~/.npm', + + 'cache-lock-stale': 60000, + 'cache-lock-retries': 10, + 'cache-lock-wait': 10000, + + 'cache-max': Infinity, + 'cache-min': 10, + + cert: null, + + cidr: null, + + color: true, + call: '', + depth: 0, + description: true, + dev: false, + 'dry-run': false, + editor: 'vim', + 'engine-strict': false, + force: false, + 'format-package-lock': true, + + fund: true, + + 'fetch-retries': 2, + 'fetch-retry-factor': 10, + 'fetch-retry-mintimeout': 10000, + 'fetch-retry-maxtimeout': 60000, + + git: 'git', + 'git-tag-version': true, + 'commit-hooks': true, + + global: false, + 'global-style': false, + heading: 'npm', + 'if-present': false, + include: [], + 'include-staged': false, + 'ignore-prepublish': false, + 'ignore-scripts': false, + 'init-module': '~/.npm-init.js', + 'init-author-name': '', + 'init-author-email': '', + 'init-author-url': '', + 'init-version': '1.0.0', + 'init-license': 'ISC', + json: false, + key: null, + 'legacy-bundling': false, + 'legacy-peer-deps': false, + link: false, + 'local-address': undefined, + loglevel: 'notice', + 'logs-max': 10, + long: false, + maxsockets: 50, + message: '%s', + 'metrics-registry': null, + 'node-options': null, + 'node-version': process.version, + offline: false, + omit: [], + only: null, + optional: true, + otp: null, + package: [], + 'package-lock': true, + 'package-lock-only': false, + parseable: false, + 'prefer-offline': false, + 'prefer-online': false, + preid: '', + production: true, + progress: true, + proxy: null, + 'https-proxy': null, + noproxy: null, + 'user-agent': 'npm/{npm-version} ' + + 'node/{node-version} ' + + '{platform} ' + + '{arch} ' + + '{ci}', + 'read-only': false, + 'rebuild-bundle': true, + registry: 'https://registry.npmjs.org/', + rollback: true, + save: true, + 'save-bundle': false, + 'save-dev': false, + 'save-exact': false, + 'save-optional': false, + 'save-prefix': '^', + 'save-prod': false, + scope: '', + 'script-shell': null, + 'scripts-prepend-node-path': 'warn-only', + searchopts: '', + searchexclude: null, + searchlimit: 20, + searchstaleness: 15 * 60, + 'send-metrics': false, + shell: '/bin/sh', + shrinkwrap: true, + 'sign-git-commit': false, + 'sign-git-tag': false, + 'sso-poll-frequency': 500, + 'sso-type': 'oauth', + 'strict-ssl': true, + tag: 'latest', + 'tag-version-prefix': 'v', + timing: false, + unicode: /UTF-?8$/i.test( + process.env.LC_ALL || process.env.LC_CTYPE || process.env.LANG + ), + 'update-notifier': true, + usage: false, + userconfig: '~/.npmrc', + umask: 0o22, + version: false, + versions: false, + viewer: 'man', +} diff --git a/workspaces/config/test/fixtures/definitions.js b/workspaces/config/test/fixtures/definitions.js new file mode 100644 index 0000000..ce0aff6 --- /dev/null +++ b/workspaces/config/test/fixtures/definitions.js @@ -0,0 +1,2609 @@ +const url = require('url') +const path = require('path') +const { join } = path +const querystring = require('querystring') +const semver = require('semver') +const Umask = require('../../lib/type-defs.js').Umask.type + +// dumped out of npm/cli/lib/utils/config/definitions.js + +// used by cafile flattening to flatOptions.ca +const fs = require('fs') +const maybeReadFile = file => { + if (file.includes('WEIRD-ERROR')) { + throw Object.assign(new Error('weird error'), { code: 'EWEIRD' }) + } + + try { + return fs.readFileSync(file, 'utf8') + } catch (er) { + if (er.code !== 'ENOENT') { + throw er + } + return null + } +} + +const definitions = module.exports = { + methane: { + envExport: false, + type: String, + typeDescription: 'Greenhouse Gas', + default: 'CH4', + description: ` + This is bad for the environment, for our children, do not put it there. + `, + }, + 'multiple-numbers': { + key: 'multiple-numbers', + default: [], + type: [ + Array, + Number, + ], + descriptions: 'one or more numbers', + }, + _auth: { + key: '_auth', + default: null, + type: [ + null, + String, + ], + description: ` + A basic-auth string to use when authenticating against the npm registry. + + Warning: This should generally not be set via a command-line option. It + is safer to use a registry-provided authentication bearer token stored in + the ~/.npmrc file by running \`npm login\`. + `, + defaultDescription: 'null', + typeDescription: 'null or String', + }, + access: { + key: 'access', + default: null, + defaultDescription: ` + 'restricted' for scoped packages, 'public' for unscoped packages + `, + type: [ + null, + 'restricted', + 'public', + ], + description: ` + When publishing scoped packages, the access level defaults to + \`restricted\`. If you want your scoped package to be publicly viewable + (and installable) set \`--access=public\`. The only valid values for + \`access\` are \`public\` and \`restricted\`. Unscoped packages _always_ + have an access level of \`public\`. + + Note: Using the \`--access\` flag on the \`npm publish\` command will only + set the package access level on the initial publish of the package. Any + subsequent \`npm publish\` commands using the \`--access\` flag will not + have an effect to the access level. To make changes to the access level + after the initial publish use \`npm access\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + typeDescription: 'null, "restricted", or "public"', + }, + all: { + key: 'all', + default: false, + type: Boolean, + short: 'a', + description: ` + When running \`npm outdated\` and \`npm ls\`, setting \`--all\` will show + all outdated or installed packages, rather than only those directly + depended upon by the current project. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'allow-same-version': { + key: 'allow-same-version', + default: false, + type: Boolean, + description: ` + Prevents throwing an error when \`npm version\` is used to set the new + version to the same value as the current version. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + also: { + key: 'also', + default: null, + type: [ + null, + 'dev', + 'development', + ], + description: ` + When set to \`dev\` or \`development\`, this is an alias for + \`--include=dev\`. + `, + deprecated: 'Please use --include=dev instead.', + flatten (key, obj, flatOptions) { + if (!/^dev(elopment)?$/.test(obj.also)) { + return + } + + // add to include, and call the omit flattener + obj.include = obj.include || [] + obj.include.push('dev') + definitions.omit.flatten('omit', obj, flatOptions) + }, + defaultDescription: 'null', + typeDescription: 'null, "dev", or "development"', + }, + audit: { + key: 'audit', + default: true, + type: Boolean, + description: ` + When "true" submit audit reports alongside the current npm command to the + default registry and all registries configured for scopes. See the + documentation for [\`npm audit\`](/commands/npm-audit) for details on what + is submitted. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + 'audit-level': { + key: 'audit-level', + default: null, + type: [ + 'low', + 'moderate', + 'high', + 'critical', + 'none', + null, + ], + description: ` + The minimum level of vulnerability for \`npm audit\` to exit with + a non-zero exit code. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'null', + typeDescription: '"low", "moderate", "high", "critical", "none", or null', + }, + 'auth-type': { + key: 'auth-type', + default: 'legacy', + type: [ + 'legacy', + 'sso', + 'saml', + 'oauth', + ], + deprecated: ` + This method of SSO/SAML/OAuth is deprecated and will be removed in + a future version of npm in favor of web-based login. + `, + description: ` + What authentication strategy to use with \`adduser\`/\`login\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '"legacy"', + typeDescription: '"legacy", "sso", "saml", or "oauth"', + }, + before: { + key: 'before', + default: null, + type: [ + null, + Date, + ], + description: ` + If passed to \`npm install\`, will rebuild the npm tree such that only + versions that were available **on or before** the \`--before\` time get + installed. If there's no versions available for the current set of + direct dependencies, the command will error. + + If the requested version is a \`dist-tag\` and the given tag does not + pass the \`--before\` filter, the most recent version less than or equal + to that tag will be used. For example, \`foo@latest\` might install + \`foo@1.2\` even though \`latest\` is \`2.0\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'null', + typeDescription: 'null or Date', + }, + 'bin-links': { + key: 'bin-links', + default: true, + type: Boolean, + description: ` + Tells npm to create symlinks (or \`.cmd\` shims on Windows) for package + executables. + + Set to false to have it not do this. This can be used to work around the + fact that some file systems don't support symlinks, even on ostensibly + Unix systems. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + browser: { + key: 'browser', + default: null, + defaultDescription: ` + OS X: \`"open"\`, Windows: \`"start"\`, Others: \`"xdg-open"\` + `, + type: [ + null, + Boolean, + String, + ], + description: ` + The browser that is called by npm commands to open websites. + + Set to \`false\` to suppress browser behavior and instead print urls to + terminal. + + Set to \`true\` to use default system URL opener. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + typeDescription: 'null, Boolean, or String', + }, + ca: { + key: 'ca', + default: null, + type: [ + null, + String, + Array, + ], + description: ` + The Certificate Authority signing certificate that is trusted for SSL + connections to the registry. Values should be in PEM format (Windows + calls it "Base-64 encoded X.509 (.CER)") with newlines replaced by the + string "\\n". For example: + + \`\`\`ini + ca="-----BEGIN CERTIFICATE-----\\nXXXX\\nXXXX\\n-----END CERTIFICATE-----" + \`\`\` + + Set to \`null\` to only allow "known" registrars, or to a specific CA + cert to trust only that specific signing authority. + + Multiple CAs can be trusted by specifying an array of certificates: + + \`\`\`ini + ca[]="..." + ca[]="..." + \`\`\` + + See also the \`strict-ssl\` config. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'null', + typeDescription: 'null or String (can be set multiple times)', + }, + cache: { + key: 'cache', + default: '~/.npm', + defaultDescription: ` + Windows: \`%LocalAppData%\\npm-cache\`, Posix: \`~/.npm\` + `, + type: path, + description: ` + The location of npm's cache directory. See [\`npm + cache\`](/commands/npm-cache) + `, + flatten (key, obj, flatOptions) { + flatOptions.cache = join(obj.cache, '_cacache') + }, + typeDescription: 'Path', + }, + 'cache-max': { + key: 'cache-max', + default: null, + type: Number, + description: ` + \`--cache-max=0\` is an alias for \`--prefer-online\` + `, + deprecated: ` + This option has been deprecated in favor of \`--prefer-online\` + `, + flatten (key, obj, flatOptions) { + if (obj[key] <= 0) { + flatOptions.preferOnline = true + } + }, + defaultDescription: 'Infinity', + typeDescription: 'Number', + }, + 'cache-min': { + key: 'cache-min', + default: 0, + type: Number, + description: ` + \`--cache-min=9999 (or bigger)\` is an alias for \`--prefer-offline\`. + `, + deprecated: ` + This option has been deprecated in favor of \`--prefer-offline\`. + `, + flatten (key, obj, flatOptions) { + if (obj[key] >= 9999) { + flatOptions.preferOffline = true + } + }, + defaultDescription: '0', + typeDescription: 'Number', + }, + cafile: { + key: 'cafile', + default: null, + type: path, + description: ` + A path to a file containing one or multiple Certificate Authority signing + certificates. Similar to the \`ca\` setting, but allows for multiple + CA's, as well as for the CA information to be stored in a file on disk. + `, + flatten (key, obj, flatOptions) { + // always set to null in defaults + if (!obj.cafile) { + return + } + + const raw = maybeReadFile(obj.cafile) + if (!raw) { + return + } + + const delim = '-----END CERTIFICATE-----' + flatOptions.ca = raw.replace(/\r\n/g, '\n').split(delim) + .filter(section => section.trim()) + .map(section => section.trimLeft() + delim) + }, + defaultDescription: 'null', + typeDescription: 'Path', + }, + call: { + key: 'call', + default: '', + type: String, + short: 'c', + description: ` + Optional companion option for \`npm exec\`, \`npx\` that allows for + specifying a custom command to be run along with the installed packages. + + \`\`\`bash + npm exec --package yo --package generator-node --call "yo node" + \`\`\` + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '""', + typeDescription: 'String', + }, + cert: { + key: 'cert', + default: null, + type: [ + null, + String, + ], + description: ` + A client certificate to pass when accessing the registry. Values should + be in PEM format (Windows calls it "Base-64 encoded X.509 (.CER)") with + newlines replaced by the string "\\n". For example: + + \`\`\`ini + cert="-----BEGIN CERTIFICATE-----\\nXXXX\\nXXXX\\n-----END CERTIFICATE-----" + \`\`\` + + It is _not_ the path to a certificate file (and there is no "certfile" + option). + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'null', + typeDescription: 'null or String', + }, + 'ci-name': { + key: 'ci-name', + default: null, + defaultDescription: ` + The name of the current CI system, or \`null\` when not on a known CI + platform. + `, + type: [ + null, + String, + ], + description: ` + The name of a continuous integration system. If not set explicitly, npm + will detect the current CI environment using the + [\`@npmcli/ci-detect\`](http://npm.im/@npmcli/ci-detect) module. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + typeDescription: 'null or String', + }, + cidr: { + key: 'cidr', + default: null, + type: [ + null, + String, + Array, + ], + description: ` + This is a list of CIDR address to be used when configuring limited access + tokens with the \`npm token create\` command. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'null', + typeDescription: 'null or String (can be set multiple times)', + }, + color: { + key: 'color', + default: true, + defaultDescription: ` + true unless the NO_COLOR environ is set to something other than '0' + `, + type: [ + 'always', + Boolean, + ], + description: ` + If false, never shows colors. If \`"always"\` then always shows colors. + If true, then only prints color codes for tty file descriptors. + `, + flatten (key, obj, flatOptions) { + flatOptions.color = !obj.color ? false + : obj.color === 'always' ? true + : process.stdout.isTTY + }, + typeDescription: '"always" or Boolean', + }, + 'commit-hooks': { + key: 'commit-hooks', + default: true, + type: Boolean, + description: ` + Run git commit hooks when using the \`npm version\` command. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + depth: { + key: 'depth', + default: null, + defaultDescription: '\n `Infinity` if `--all` is set, otherwise `1`\n ', + type: [ + null, + Number, + ], + description: ` + The depth to go when recursing packages for \`npm ls\`. + + If not set, \`npm ls\` will show only the immediate dependencies of the + root project. If \`--all\` is set, then npm will show all dependencies + by default. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + typeDescription: 'null or Number', + }, + description: { + key: 'description', + default: true, + type: Boolean, + description: ` + Show the description in \`npm search\` + `, + flatten (key, obj, flatOptions) { + flatOptions.search = flatOptions.search || { limit: 20 } + flatOptions.search[key] = obj[key] + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + diff: { + key: 'diff', + default: [], + type: [ + String, + Array, + ], + description: ` + Define arguments to compare in \`npm diff\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '', + typeDescription: 'String (can be set multiple times)', + }, + 'diff-ignore-all-space': { + key: 'diff-ignore-all-space', + default: false, + type: Boolean, + description: ` + Ignore whitespace when comparing lines in \`npm diff\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'diff-name-only': { + key: 'diff-name-only', + default: false, + type: Boolean, + description: ` + Prints only filenames when using \`npm diff\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'diff-no-prefix': { + key: 'diff-no-prefix', + default: false, + type: Boolean, + description: ` + Do not show any source or destination prefix in \`npm diff\` output. + + Note: this causes \`npm diff\` to ignore the \`--diff-src-prefix\` and + \`--diff-dst-prefix\` configs. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'diff-dst-prefix': { + key: 'diff-dst-prefix', + default: 'b/', + type: String, + description: ` + Destination prefix to be used in \`npm diff\` output. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '"b/"', + typeDescription: 'String', + }, + 'diff-src-prefix': { + key: 'diff-src-prefix', + default: 'a/', + type: String, + description: ` + Source prefix to be used in \`npm diff\` output. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '"a/"', + typeDescription: 'String', + }, + 'diff-text': { + key: 'diff-text', + default: false, + type: Boolean, + description: ` + Treat all files as text in \`npm diff\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'diff-unified': { + key: 'diff-unified', + default: 3, + type: Number, + description: ` + The number of lines of context to print in \`npm diff\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '3', + typeDescription: 'Number', + }, + 'dry-run': { + key: 'dry-run', + default: false, + type: Boolean, + description: ` + Indicates that you don't want npm to make any changes and that it should + only report what it would have done. This can be passed into any of the + commands that modify your local installation, eg, \`install\`, + \`update\`, \`dedupe\`, \`uninstall\`, as well as \`pack\` and + \`publish\`. + + Note: This is NOT honored by other network related commands, eg + \`dist-tags\`, \`owner\`, etc. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + editor: { + key: 'editor', + default: 'vim', + defaultDescription: ` + The EDITOR or VISUAL environment variables, or 'notepad.exe' on Windows, + or 'vim' on Unix systems + `, + type: String, + description: ` + The command to run for \`npm edit\` and \`npm config edit\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + typeDescription: 'String', + }, + 'engine-strict': { + key: 'engine-strict', + default: false, + type: Boolean, + description: ` + If set to true, then npm will stubbornly refuse to install (or even + consider installing) any package that claims to not be compatible with + the current Node.js version. + + This can be overridden by setting the \`--force\` flag. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'fetch-retries': { + key: 'fetch-retries', + default: 2, + type: Number, + description: ` + The "retries" config for the \`retry\` module to use when fetching + packages from the registry. + + npm will retry idempotent read requests to the registry in the case + of network failures or 5xx HTTP errors. + `, + flatten (key, obj, flatOptions) { + flatOptions.retry = flatOptions.retry || {} + flatOptions.retry.retries = obj[key] + }, + defaultDescription: '2', + typeDescription: 'Number', + }, + 'fetch-retry-factor': { + key: 'fetch-retry-factor', + default: 10, + type: Number, + description: ` + The "factor" config for the \`retry\` module to use when fetching + packages. + `, + flatten (key, obj, flatOptions) { + flatOptions.retry = flatOptions.retry || {} + flatOptions.retry.factor = obj[key] + }, + defaultDescription: '10', + typeDescription: 'Number', + }, + 'fetch-retry-maxtimeout': { + key: 'fetch-retry-maxtimeout', + default: 60000, + defaultDescription: '60000 (1 minute)', + type: Number, + description: ` + The "maxTimeout" config for the \`retry\` module to use when fetching + packages. + `, + flatten (key, obj, flatOptions) { + flatOptions.retry = flatOptions.retry || {} + flatOptions.retry.maxTimeout = obj[key] + }, + typeDescription: 'Number', + }, + 'fetch-retry-mintimeout': { + key: 'fetch-retry-mintimeout', + default: 10000, + defaultDescription: '10000 (10 seconds)', + type: Number, + description: ` + The "minTimeout" config for the \`retry\` module to use when fetching + packages. + `, + flatten (key, obj, flatOptions) { + flatOptions.retry = flatOptions.retry || {} + flatOptions.retry.minTimeout = obj[key] + }, + typeDescription: 'Number', + }, + 'fetch-timeout': { + key: 'fetch-timeout', + default: 300000, + defaultDescription: '300000 (5 minutes)', + type: Number, + description: ` + The maximum amount of time to wait for HTTP requests to complete. + `, + flatten (key, obj, flatOptions) { + flatOptions.timeout = obj[key] + }, + typeDescription: 'Number', + }, + force: { + key: 'force', + default: false, + type: Boolean, + short: 'f', + description: ` + Removes various protections against unfortunate side effects, common + mistakes, unnecessary performance degradation, and malicious input. + + * Allow clobbering non-npm files in global installs. + * Allow the \`npm version\` command to work on an unclean git repository. + * Allow deleting the cache folder with \`npm cache clean\`. + * Allow installing packages that have an \`engines\` declaration + requiring a different version of npm. + * Allow installing packages that have an \`engines\` declaration + requiring a different version of \`node\`, even if \`--engine-strict\` + is enabled. + * Allow \`npm audit fix\` to install modules outside your stated + dependency range (including SemVer-major changes). + * Allow unpublishing all versions of a published package. + * Allow conflicting peerDependencies to be installed in the root project. + * Implicitly set \`--yes\` during \`npm init\`. + * Allow clobbering existing values in \`npm pkg\` + + If you don't have a clear idea of what you want to do, it is strongly + recommended that you do not use this option! + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'foreground-scripts': { + key: 'foreground-scripts', + default: false, + type: Boolean, + description: ` + Run all build scripts (ie, \`preinstall\`, \`install\`, and + \`postinstall\`) scripts for installed packages in the foreground + process, sharing standard input, output, and error with the main npm + process. + + Note that this will generally make installs run slower, and be much + noisier, but can be useful for debugging. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'format-package-lock': { + key: 'format-package-lock', + default: true, + type: Boolean, + description: ` + Format \`package-lock.json\` or \`npm-shrinkwrap.json\` as a human + readable file. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + fund: { + key: 'fund', + default: true, + type: Boolean, + description: ` + When "true" displays the message at the end of each \`npm install\` + acknowledging the number of dependencies looking for funding. + See [\`npm fund\`](/commands/npm-fund) for details. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + git: { + key: 'git', + default: 'git', + type: String, + description: ` + The command to use for git commands. If git is installed on the + computer, but is not in the \`PATH\`, then set this to the full path to + the git binary. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '"git"', + typeDescription: 'String', + }, + 'git-tag-version': { + key: 'git-tag-version', + default: true, + type: Boolean, + description: ` + Tag the commit when using the \`npm version\` command. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + global: { + key: 'global', + default: false, + type: Boolean, + short: 'g', + description: ` + Operates in "global" mode, so that packages are installed into the + \`prefix\` folder instead of the current working directory. See + [folders](/configuring-npm/folders) for more on the differences in + behavior. + + * packages are installed into the \`{prefix}/lib/node_modules\` folder, + instead of the current working directory. + * bin files are linked to \`{prefix}/bin\` + * man pages are linked to \`{prefix}/share/man\` + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'global-style': { + key: 'global-style', + default: false, + type: Boolean, + description: ` + Causes npm to install the package into your local \`node_modules\` folder + with the same layout it uses with the global \`node_modules\` folder. + Only your direct dependencies will show in \`node_modules\` and + everything they depend on will be flattened in their \`node_modules\` + folders. This obviously will eliminate some deduping. If used with + \`legacy-bundling\`, \`legacy-bundling\` will be preferred. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + globalconfig: { + key: 'globalconfig', + type: path, + default: '', + defaultDescription: ` + The global --prefix setting plus 'etc/npmrc'. For example, + '/usr/local/etc/npmrc' + `, + description: ` + The config file to read for global config options. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + typeDescription: 'Path', + }, + heading: { + key: 'heading', + default: 'npm', + type: String, + description: ` + The string that starts all the debugging log output. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '"npm"', + typeDescription: 'String', + }, + 'https-proxy': { + key: 'https-proxy', + default: null, + type: [ + null, + url, + ], + description: ` + A proxy to use for outgoing https requests. If the \`HTTPS_PROXY\` or + \`https_proxy\` or \`HTTP_PROXY\` or \`http_proxy\` environment variables + are set, proxy settings will be honored by the underlying + \`make-fetch-happen\` library. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'null', + typeDescription: 'null or URL', + }, + 'if-present': { + key: 'if-present', + default: false, + type: Boolean, + description: ` + 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 running scripts that may only apply for + some builds in an otherwise generic CI setup. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'ignore-scripts': { + key: 'ignore-scripts', + default: false, + type: Boolean, + description: ` + 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. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + include: { + key: 'include', + default: [], + type: [ + Array, + 'prod', + 'dev', + 'optional', + 'peer', + ], + description: ` + Option that allows for defining which types of dependencies to install. + + This is the inverse of \`--omit=<type>\`. + + Dependency types specified in \`--include\` will not be omitted, + regardless of the order in which omit/include are specified on the + command-line. + `, + flatten (key, obj, flatOptions) { + // just call the omit flattener, it reads from obj.include + definitions.omit.flatten('omit', obj, flatOptions) + }, + defaultDescription: '', + typeDescription: '"prod", "dev", "optional", or "peer" (can be set multiple times)', + }, + 'include-staged': { + key: 'include-staged', + default: false, + type: Boolean, + description: ` + Allow installing "staged" published packages, as defined by [npm RFC PR + #92](https://github.com/npm/rfcs/pull/92). + + This is experimental, and not implemented by the npm public registry. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'init-author-email': { + key: 'init-author-email', + default: '', + type: String, + description: ` + The value \`npm init\` should use by default for the package author's + email. + `, + defaultDescription: '""', + typeDescription: 'String', + }, + 'init-author-name': { + key: 'init-author-name', + default: '', + type: String, + description: ` + The value \`npm init\` should use by default for the package author's name. + `, + defaultDescription: '""', + typeDescription: 'String', + }, + 'init-author-url': { + key: 'init-author-url', + default: '', + type: [ + '', + url, + ], + description: ` + The value \`npm init\` should use by default for the package author's homepage. + `, + defaultDescription: '""', + typeDescription: '"" or URL', + }, + 'init-license': { + key: 'init-license', + default: 'ISC', + type: String, + description: ` + The value \`npm init\` should use by default for the package license. + `, + defaultDescription: '"ISC"', + typeDescription: 'String', + }, + 'init-module': { + key: 'init-module', + default: '~/.npm-init.js', + type: path, + description: ` + A module that will be loaded by the \`npm init\` command. See the + documentation for the + [init-package-json](https://github.com/npm/init-package-json) module for + more information, or [npm init](/commands/npm-init). + `, + defaultDescription: '"~/.npm-init.js"', + typeDescription: 'Path', + }, + 'init-version': { + key: 'init-version', + default: '1.0.0', + type: semver, + description: ` + The value that \`npm init\` should use by default for the package + version number, if not already set in package.json. + `, + defaultDescription: '"1.0.0"', + typeDescription: 'SemVer string', + }, + 'init.author.email': { + key: 'init.author.email', + default: '', + type: String, + deprecated: ` + Use \`--init-author-email\` instead.`, + description: ` + Alias for \`--init-author-email\` + `, + defaultDescription: '""', + typeDescription: 'String', + }, + 'init.author.name': { + key: 'init.author.name', + default: '', + type: String, + deprecated: ` + Use \`--init-author-name\` instead. + `, + description: ` + Alias for \`--init-author-name\` + `, + defaultDescription: '""', + typeDescription: 'String', + }, + 'init.author.url': { + key: 'init.author.url', + default: '', + type: [ + '', + url, + ], + deprecated: ` + Use \`--init-author-url\` instead. + `, + description: ` + Alias for \`--init-author-url\` + `, + defaultDescription: '""', + typeDescription: '"" or URL', + }, + 'init.license': { + key: 'init.license', + default: 'ISC', + type: String, + deprecated: ` + Use \`--init-license\` instead. + `, + description: ` + Alias for \`--init-license\` + `, + defaultDescription: '"ISC"', + typeDescription: 'String', + }, + 'init.module': { + key: 'init.module', + default: '~/.npm-init.js', + type: path, + deprecated: ` + Use \`--init-module\` instead. + `, + description: ` + Alias for \`--init-module\` + `, + defaultDescription: '"~/.npm-init.js"', + typeDescription: 'Path', + }, + 'init.version': { + key: 'init.version', + default: '1.0.0', + type: semver, + deprecated: ` + Use \`--init-version\` instead. + `, + description: ` + Alias for \`--init-version\` + `, + defaultDescription: '"1.0.0"', + typeDescription: 'SemVer string', + }, + json: { + key: 'json', + default: false, + type: Boolean, + description: ` + Whether or not to output JSON data, rather than the normal output. + + * In \`npm pkg set\` it enables parsing set values with JSON.parse() + before saving them to your \`package.json\`. + + Not supported by all npm commands. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + key: { + key: 'key', + default: null, + type: [ + null, + String, + ], + description: ` + A client key to pass when accessing the registry. Values should be in + PEM format with newlines replaced by the string "\\n". For example: + + \`\`\`ini + key="-----BEGIN PRIVATE KEY-----\\nXXXX\\nXXXX\\n-----END PRIVATE KEY-----" + \`\`\` + + It is _not_ the path to a key file (and there is no "keyfile" option). + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'null', + typeDescription: 'null or String', + }, + 'legacy-bundling': { + key: 'legacy-bundling', + default: false, + type: Boolean, + description: ` + Causes npm to install the package such that versions of npm prior to 1.4, + such as the one included with node 0.8, can install the package. This + eliminates all automatic deduping. If used with \`global-style\` this + option will be preferred. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'legacy-peer-deps': { + key: 'legacy-peer-deps', + default: false, + type: Boolean, + description: ` + Causes npm to completely ignore \`peerDependencies\` when building a + package tree, as in npm versions 3 through 6. + + If a package cannot be installed because of overly strict + \`peerDependencies\` that collide, it provides a way to move forward + resolving the situation. + + This differs from \`--omit=peer\`, in that \`--omit=peer\` will avoid + unpacking \`peerDependencies\` on disk, but will still design a tree such + that \`peerDependencies\` _could_ be unpacked in a correct place. + + Use of \`legacy-peer-deps\` is not recommended, as it will not enforce + the \`peerDependencies\` contract that meta-dependencies may rely on. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + link: { + key: 'link', + default: false, + type: Boolean, + description: ` + Used with \`npm ls\`, limiting output to only those packages that are + linked. + `, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'local-address': { + key: 'local-address', + default: null, + type: [ + null, + '127.0.0.1', + '::1', + 'fe80::1', + 'fe80::aede:48ff:fe00:1122', + 'fe80::18fe:6168:6908:4239', + '2600:1700:87d0:b28f:481:1fd0:2067:5a90', + '2600:1700:87d0:b28f:11be:d3f3:278c:ade9', + 'fd2e:635c:9594:10:109e:699c:6fdc:41b9', + 'fd2e:635c:9594:10:69ce:d360:4ab9:1632', + '192.168.103.122', + 'fe80::715:4a5e:3af5:99e5', + 'fe80::d32a:27b1:2ac:1155', + 'fe80::bbb2:6e76:3877:9f2f', + 'fe80::8e1f:15b0:b70:2d70', + ], + typeDescription: 'IP Address', + description: ` + The IP address of the local interface to use when making connections to + the npm registry. Must be IPv4 in versions of Node prior to 0.12. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'null', + }, + location: { + key: 'location', + default: 'user', + type: ['global', 'user', 'project'], + description: ` + When passed to \`npm config\` this refers to which config file to use. + `, + defaultDescription: ` + "user" unless \`--global\` is passed, which will also set this value to "global" + `, + typeDescription: '"global", "user", or "project"', + }, + loglevel: { + key: 'loglevel', + default: 'notice', + type: [ + 'silent', + 'error', + 'warn', + 'notice', + 'http', + 'timing', + 'info', + 'verbose', + 'silly', + ], + description: ` + What level of logs to report. All logs are written to a debug log, + with the path to that file printed if the execution of a command fails. + + Any logs of a higher level than the setting are shown. The default is + "notice". + + See also the \`foreground-scripts\` config. + `, + defaultDescription: '"notice"', + typeDescription: '"silent", "error", "warn", "notice", "http", "timing", "info", "verbose",' + + ' or "silly"', + }, + 'logs-max': { + key: 'logs-max', + default: 10, + type: Number, + description: ` + The maximum number of log files to store. + `, + defaultDescription: '10', + typeDescription: 'Number', + }, + long: { + key: 'long', + default: false, + type: Boolean, + short: 'l', + description: ` + Show extended information in \`ls\`, \`search\`, and \`help-search\`. + `, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + maxsockets: { + key: 'maxsockets', + default: null, + type: Number, + description: ` + The maximum number of connections to use per origin (protocol/host/port + combination). + `, + flatten (key, obj, flatOptions) { + flatOptions.maxSockets = obj[key] + }, + defaultDescription: 'Infinity', + typeDescription: 'Number', + }, + message: { + key: 'message', + default: '%s', + type: String, + short: 'm', + description: ` + Commit message which is used by \`npm version\` when creating version commit. + + Any "%s" in the message will be replaced with the version number. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '"%s"', + typeDescription: 'String', + }, + 'node-options': { + key: 'node-options', + default: null, + type: [ + null, + String, + ], + description: ` + Options to pass through to Node.js via the \`NODE_OPTIONS\` environment + variable. This does not impact how npm itself is executed but it does + impact how lifecycle scripts are called. + `, + defaultDescription: 'null', + typeDescription: 'null or String', + }, + 'node-version': { + key: 'node-version', + default: 'v15.3.0', + defaultDescription: 'Node.js `process.version` value', + type: semver, + description: ` + The node version to use when checking a package's \`engines\` setting. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + typeDescription: 'SemVer string', + }, + noproxy: { + key: 'noproxy', + default: '', + defaultDescription: ` + The value of the NO_PROXY environment variable + `, + type: [ + String, + Array, + ], + description: ` + Domain extensions that should bypass any proxies. + + Also accepts a comma-delimited string. + `, + flatten (key, obj, flatOptions) { + flatOptions.noProxy = obj[key].join(',') + }, + typeDescription: 'String (can be set multiple times)', + }, + 'npm-version': { + key: 'npm-version', + default: '7.6.3', + defaultDescription: 'Output of `npm --version`', + type: semver, + description: ` + The npm version to use when checking a package's \`engines\` setting. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + typeDescription: 'SemVer string', + }, + offline: { + key: 'offline', + default: false, + type: Boolean, + description: ` + Force offline mode: no network requests will be done during install. To allow + the CLI to fill in missing cache data, see \`--prefer-offline\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + omit: { + key: 'omit', + default: [], + defaultDescription: ` + 'dev' if the \`NODE_ENV\` environment variable is set to 'production', + otherwise empty. + `, + type: [ + Array, + 'dev', + 'optional', + 'peer', + ], + description: ` + Dependency types to omit from the installation tree on disk. + + Note that these dependencies _are_ still resolved and added to the + \`package-lock.json\` or \`npm-shrinkwrap.json\` file. They are just + not physically installed on disk. + + If a package type appears in both the \`--include\` and \`--omit\` + lists, then it will be included. + + If the resulting omit list includes \`'dev'\`, then the \`NODE_ENV\` + environment variable will be set to \`'production'\` for all lifecycle + scripts. + `, + flatten (key, obj, flatOptions) { + const include = obj.include || [] + const omit = flatOptions.omit || [] + flatOptions.omit = omit.concat(obj[key]) + .filter(type => type && !include.includes(type)) + }, + typeDescription: '"dev", "optional", or "peer" (can be set multiple times)', + }, + only: { + key: 'only', + default: null, + type: [ + null, + 'prod', + 'production', + ], + deprecated: ` + Use \`--omit=dev\` to omit dev dependencies from the install. + `, + description: ` + When set to \`prod\` or \`production\`, this is an alias for + \`--omit=dev\`. + `, + flatten (key, obj, flatOptions) { + const value = obj[key] + if (!/^prod(uction)?$/.test(value)) { + return + } + + obj.omit = obj.omit || [] + obj.omit.push('dev') + definitions.omit.flatten('omit', obj, flatOptions) + }, + defaultDescription: 'null', + typeDescription: 'null, "prod", or "production"', + }, + optional: { + key: 'optional', + default: null, + type: [ + null, + Boolean, + ], + deprecated: ` + Use \`--omit=optional\` to exclude optional dependencies, or + \`--include=optional\` to include them. + + Default value does install optional deps unless otherwise omitted. + `, + description: ` + Alias for --include=optional or --omit=optional + `, + flatten (key, obj, flatOptions) { + const value = obj[key] + if (value === null) { + return + } else if (value === true) { + obj.include = obj.include || [] + obj.include.push('optional') + } else { + obj.omit = obj.omit || [] + obj.omit.push('optional') + } + definitions.omit.flatten('omit', obj, flatOptions) + }, + defaultDescription: 'null', + typeDescription: 'null or Boolean', + }, + otp: { + key: 'otp', + default: null, + type: [ + null, + String, + ], + description: ` + This is a one-time password from a two-factor authenticator. It's needed + when publishing or changing package permissions with \`npm access\`. + + If not set, and a registry response fails with a challenge for a one-time + password, npm will prompt on the command line for one. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'null', + typeDescription: 'null or String', + }, + package: { + key: 'package', + default: [], + type: [ + String, + Array, + ], + description: ` + The package to install for [\`npm exec\`](/commands/npm-exec) + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '', + typeDescription: 'String (can be set multiple times)', + }, + 'package-lock': { + key: 'package-lock', + default: true, + type: Boolean, + description: ` + If set to false, then ignore \`package-lock.json\` files when installing. + This will also prevent _writing_ \`package-lock.json\` if \`save\` is + true. + + When package package-locks are disabled, automatic pruning of extraneous + modules will also be disabled. To remove extraneous modules with + package-locks disabled use \`npm prune\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + 'package-lock-only': { + key: 'package-lock-only', + default: false, + type: Boolean, + description: ` + If set to true, the current operation will only use the \`package-lock.json\`, + ignoring \`node_modules\`. + + For \`update\` this means only the \`package-lock.json\` will be updated, + instead of checking \`node_modules\` and downloading dependencies. + + For \`list\` this means the output will be based on the tree described by the + \`package-lock.json\`, rather than the contents of \`node_modules\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + parseable: { + key: 'parseable', + default: false, + type: Boolean, + short: 'p', + description: ` + Output parseable results from commands that write to standard output. For + \`npm search\`, this will be tab-separated table format. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'prefer-offline': { + key: 'prefer-offline', + default: false, + type: Boolean, + description: ` + If true, staleness checks for cached data will be bypassed, but missing + data will be requested from the server. To force full offline mode, use + \`--offline\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'prefer-online': { + key: 'prefer-online', + default: false, + type: Boolean, + description: ` + If true, staleness checks for cached data will be forced, making the CLI + look for updates immediately even for fresh package data. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + prefix: { + key: 'prefix', + type: path, + short: 'C', + default: '', + defaultDescription: ` + In global mode, the folder where the node executable is installed. In + local mode, the nearest parent folder containing either a package.json + file or a node_modules folder. + `, + description: ` + The location to install global items. If set on the command line, then + it forces non-global commands to run in the specified folder. + `, + typeDescription: 'Path', + }, + preid: { + key: 'preid', + default: '', + type: String, + description: ` + The "prerelease identifier" to use as a prefix for the "prerelease" part + of a semver. Like the \`rc\` in \`1.2.0-rc.8\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '""', + typeDescription: 'String', + }, + production: { + key: 'production', + default: false, + type: Boolean, + deprecated: 'Use `--omit=dev` instead.', + description: 'Alias for `--omit=dev`', + flatten (key, obj, flatOptions) { + const value = obj[key] + if (!value) { + return + } + + obj.omit = obj.omit || [] + obj.omit.push('dev') + definitions.omit.flatten('omit', obj, flatOptions) + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + progress: { + key: 'progress', + default: true, + defaultDescription: '\n `true` unless running in a known CI system\n ', + type: Boolean, + description: ` + When set to \`true\`, npm will display a progress bar during time + intensive operations, if \`process.stderr\` is a TTY. + + Set to \`false\` to suppress the progress bar. + `, + typeDescription: 'Boolean', + }, + proxy: { + key: 'proxy', + default: null, + type: [ + null, + false, + url, + ], + description: ` + A proxy to use for outgoing http requests. If the \`HTTP_PROXY\` or + \`http_proxy\` environment variables are set, proxy settings will be + honored by the underlying \`request\` library. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'null', + typeDescription: 'null, false, or URL', + }, + 'read-only': { + key: 'read-only', + default: false, + type: Boolean, + description: ` + This is used to mark a token as unable to publish when configuring + limited access tokens with the \`npm token create\` command. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'rebuild-bundle': { + key: 'rebuild-bundle', + default: true, + type: Boolean, + description: ` + Rebuild bundled dependencies after installation. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + registry: { + key: 'registry', + default: 'https://registry.npmjs.org/', + type: [null, url], + description: ` + The base URL of the npm registry. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '"https://registry.npmjs.org/"', + typeDescription: 'URL', + }, + save: { + key: 'save', + default: true, + type: Boolean, + short: 'S', + description: ` + Save installed packages to a \`package.json\` file as dependencies. + + When used with the \`npm rm\` command, removes the dependency from + \`package.json\`. + + Will also prevent writing to \`package-lock.json\` if set to \`false\`. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + 'save-bundle': { + key: 'save-bundle', + default: false, + type: Boolean, + short: 'B', + description: ` + If a package would be saved at install time by the use of \`--save\`, + \`--save-dev\`, or \`--save-optional\`, then also put it in the + \`bundleDependencies\` list. + + Ignore if \`--save-peer\` is set, since peerDependencies cannot be bundled. + `, + flatten (key, obj, flatOptions) { + // XXX update arborist to just ignore it if resulting saveType is peer + // otherwise this won't have the expected effect: + // + // npm config set save-peer true + // npm i foo --save-bundle --save-prod <-- should bundle + flatOptions.saveBundle = obj['save-bundle'] && !obj['save-peer'] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'save-dev': { + key: 'save-dev', + default: false, + type: Boolean, + short: 'D', + description: ` + Save installed packages to a package.json file as \`devDependencies\`. + `, + flatten (key, obj, flatOptions) { + if (!obj[key]) { + if (flatOptions.saveType === 'dev') { + delete flatOptions.saveType + } + return + } + + flatOptions.saveType = 'dev' + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'save-exact': { + key: 'save-exact', + default: false, + type: Boolean, + short: 'E', + description: ` + Dependencies saved to package.json will be configured with an exact + version rather than using npm's default semver range operator. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'save-optional': { + key: 'save-optional', + default: false, + type: Boolean, + short: 'O', + description: ` + Save installed packages to a package.json file as + \`optionalDependencies\`. + `, + flatten (key, obj, flatOptions) { + if (!obj[key]) { + if (flatOptions.saveType === 'optional') { + delete flatOptions.saveType + } else if (flatOptions.saveType === 'peerOptional') { + flatOptions.saveType = 'peer' + } + return + } + + if (flatOptions.saveType === 'peerOptional') { + return + } + + if (flatOptions.saveType === 'peer') { + flatOptions.saveType = 'peerOptional' + } else { + flatOptions.saveType = 'optional' + } + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'save-peer': { + key: 'save-peer', + default: false, + type: Boolean, + description: ` + Save installed packages to a package.json file as \`peerDependencies\` + `, + flatten (key, obj, flatOptions) { + if (!obj[key]) { + if (flatOptions.saveType === 'peer') { + delete flatOptions.saveType + } else if (flatOptions.saveType === 'peerOptional') { + flatOptions.saveType = 'optional' + } + return + } + + if (flatOptions.saveType === 'peerOptional') { + return + } + + if (flatOptions.saveType === 'optional') { + flatOptions.saveType = 'peerOptional' + } else { + flatOptions.saveType = 'peer' + } + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'save-prefix': { + key: 'save-prefix', + default: '^', + type: String, + description: ` + Configure how versions of packages installed to a package.json file via + \`--save\` or \`--save-dev\` get prefixed. + + For example if a package has version \`1.2.3\`, by default its version is + set to \`^1.2.3\` which allows minor upgrades for that package, but after + \`npm config set save-prefix='~'\` it would be set to \`~1.2.3\` which + only allows patch upgrades. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '"^"', + typeDescription: 'String', + }, + 'save-prod': { + key: 'save-prod', + default: false, + type: Boolean, + short: 'P', + description: ` + Save installed packages into \`dependencies\` specifically. This is + useful if a package already exists in \`devDependencies\` or + \`optionalDependencies\`, but 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. + `, + flatten (key, obj, flatOptions) { + if (!obj[key]) { + if (flatOptions.saveType === 'prod') { + delete flatOptions.saveType + } + return + } + + flatOptions.saveType = 'prod' + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + scope: { + key: 'scope', + default: '', + defaultDescription: ` + the scope of the current project, if any, or "" + `, + type: String, + description: ` + Associate an operation with a scope for a scoped registry. + + Useful when logging in to or out of a private registry: + + \`\`\` + # log in, linking the scope to the custom registry + npm login --scope=@mycorp --registry=https://registry.mycorp.com + + # log out, removing the link and the auth token + npm logout --scope=@mycorp + \`\`\` + + This will cause \`@mycorp\` to be mapped to the registry for future + installation of packages specified according to the pattern + \`@mycorp/package\`. + + This will also cause \`npm init\` to create a scoped package. + + \`\`\` + # accept all defaults, and create a package named "@foo/whatever", + # instead of just named "whatever" + npm init --scope=@foo --yes + \`\`\` + `, + flatten (key, obj, flatOptions) { + const value = obj[key] + flatOptions.projectScope = value && !/^@/.test(value) ? `@${value}` : value + }, + typeDescription: 'String', + }, + 'script-shell': { + key: 'script-shell', + default: null, + defaultDescription: ` + '/bin/sh' on POSIX systems, 'cmd.exe' on Windows + `, + type: [ + null, + String, + ], + description: ` + The shell to use for scripts run with the \`npm exec\`, + \`npm run\` and \`npm init <pkg>\` commands. + `, + flatten (key, obj, flatOptions) { + flatOptions.scriptShell = obj[key] || undefined + }, + typeDescription: 'null or String', + }, + searchexclude: { + key: 'searchexclude', + default: '', + type: String, + description: ` + Space-separated options that limit the results from search. + `, + flatten (key, obj, flatOptions) { + flatOptions.search = flatOptions.search || { limit: 20 } + flatOptions.search.exclude = obj[key] + }, + defaultDescription: '""', + typeDescription: 'String', + }, + searchlimit: { + key: 'searchlimit', + default: 20, + type: Number, + description: ` + Number of items to limit search results to. Will not apply at all to + legacy searches. + `, + flatten (key, obj, flatOptions) { + flatOptions.search = flatOptions.search || {} + flatOptions.search.limit = obj[key] + }, + defaultDescription: '20', + typeDescription: 'Number', + }, + searchopts: { + key: 'searchopts', + default: '', + type: String, + description: ` + Space-separated options that are always passed to search. + `, + flatten (key, obj, flatOptions) { + flatOptions.search = flatOptions.search || { limit: 20 } + flatOptions.search.opts = querystring.parse(obj[key]) + }, + defaultDescription: '""', + typeDescription: 'String', + }, + searchstaleness: { + key: 'searchstaleness', + default: 900, + type: Number, + description: ` + The age of the cache, in seconds, before another registry request is made + if using legacy search endpoint. + `, + flatten (key, obj, flatOptions) { + flatOptions.search = flatOptions.search || { limit: 20 } + flatOptions.search.staleness = obj[key] + }, + defaultDescription: '900', + typeDescription: 'Number', + }, + shell: { + key: 'shell', + default: '/usr/local/bin/bash', + defaultDescription: ` + SHELL environment variable, or "bash" on Posix, or "cmd.exe" on Windows + `, + type: String, + description: ` + The shell to run for the \`npm explore\` command. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + typeDescription: 'String', + }, + shrinkwrap: { + key: 'shrinkwrap', + default: true, + type: Boolean, + deprecated: ` + Use the --package-lock setting instead. + `, + description: ` + Alias for --package-lock + `, + flatten (key, obj, flatOptions) { + obj['package-lock'] = obj.shrinkwrap + definitions['package-lock'].flatten('package-lock', obj, flatOptions) + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + 'sign-git-commit': { + key: 'sign-git-commit', + default: false, + type: Boolean, + description: ` + If set to true, then the \`npm version\` command will commit the new + package version using \`-S\` to add a signature. + + Note that git requires you to have set up GPG keys in your git configs + for this to work properly. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'sign-git-tag': { + key: 'sign-git-tag', + default: false, + type: Boolean, + description: ` + If set to true, then the \`npm version\` command will tag the version + using \`-s\` to add a signature. + + Note that git requires you to have set up GPG keys in your git configs + for this to work properly. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'sso-poll-frequency': { + key: 'sso-poll-frequency', + default: 500, + type: Number, + deprecated: ` + The --auth-type method of SSO/SAML/OAuth will be removed in a future + version of npm in favor of web-based login. + `, + description: ` + When used with SSO-enabled \`auth-type\`s, configures how regularly the + registry should be polled while the user is completing authentication. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '500', + typeDescription: 'Number', + }, + 'sso-type': { + key: 'sso-type', + default: 'oauth', + type: [ + null, + 'oauth', + 'saml', + ], + deprecated: ` + The --auth-type method of SSO/SAML/OAuth will be removed in a future + version of npm in favor of web-based login. + `, + description: ` + If \`--auth-type=sso\`, the type of SSO type to use. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '"oauth"', + typeDescription: 'null, "oauth", or "saml"', + }, + 'strict-peer-deps': { + key: 'strict-peer-deps', + default: false, + type: Boolean, + description: ` + If set to \`true\`, and \`--legacy-peer-deps\` is not set, then _any_ + conflicting \`peerDependencies\` will be treated as an install failure, + even if npm could reasonably guess the appropriate resolution based on + non-peer dependency relationships. + + By default, conflicting \`peerDependencies\` deep in the dependency graph + will be resolved using the nearest non-peer dependency specification, + even if doing so will result in some packages receiving a peer dependency + outside the range set in their package's \`peerDependencies\` object. + + When such and override is performed, a warning is printed, explaining the + conflict and the packages involved. If \`--strict-peer-deps\` is set, + then this warning is treated as a failure. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'strict-ssl': { + key: 'strict-ssl', + default: true, + type: Boolean, + description: ` + Whether or not to do SSL key validation when making requests to the + registry via https. + + See also the \`ca\` config. + `, + flatten (key, obj, flatOptions) { + flatOptions.strictSSL = obj[key] + }, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + tag: { + key: 'tag', + default: 'latest', + type: String, + description: ` + If you ask npm to install a package and don't tell it a specific version, + then it will install the specified tag. + + Also the tag that is added to the package@version specified by the \`npm + tag\` command, if no explicit tag is given. + + When used by the \`npm diff\` command, this is the tag used to fetch the + tarball that will be compared with the local files by default. + `, + flatten (key, obj, flatOptions) { + flatOptions.defaultTag = obj[key] + }, + defaultDescription: '"latest"', + typeDescription: 'String', + }, + 'tag-version-prefix': { + key: 'tag-version-prefix', + default: 'v', + type: String, + description: ` + If set, alters the prefix used when tagging a new version when performing + a version increment using \`npm-version\`. To remove the prefix + altogether, set it to the empty string: \`""\`. + + Because other tools may rely on the convention that npm version tags look + like \`v1.0.0\`, _only use this property if it is absolutely necessary_. + In particular, use care when overriding this setting for public packages. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '"v"', + typeDescription: 'String', + }, + timing: { + key: 'timing', + default: false, + type: Boolean, + description: ` + If true, writes an \`npm-debug\` log to \`_logs\` and timing information + to \`_timing.json\`, both in your cache, even if the command completes + successfully. \`_timing.json\` is a newline delimited list of JSON + objects. + + You can quickly view it with this [json](https://npm.im/json) command + line: \`npm exec -- json -g < ~/.npm/_timing.json\`. + `, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + tmp: { + key: 'tmp', + default: '/var/folders/zc/5n20yjzn7mn7cz_qckj3b3440000gn/T', + defaultDescription: ` + The value returned by the Node.js \`os.tmpdir()\` method + <https://nodejs.org/api/os.html#os_os_tmpdir> + `, + type: path, + deprecated: ` + This setting is no longer used. npm stores temporary files in a special + location in the cache, and they are managed by + [\`cacache\`](http://npm.im/cacache). + `, + description: ` + Historically, the location where temporary files were stored. No longer + relevant. + `, + typeDescription: 'Path', + }, + umask: { + key: 'umask', + default: 0, + type: Umask, + description: ` + The "umask" value to use when setting the file creation mode on files and + folders. + + Folders and executables are given a mode which is \`0o777\` masked + against this value. Other files are given a mode which is \`0o666\` + masked against this value. + + Note that the underlying system will _also_ apply its own umask value to + files and folders that are created, and npm does not circumvent this, but + rather adds the \`--umask\` config to it. + + Thus, the effective default umask value on most POSIX systems is 0o22, + meaning that folders and executables are created with a mode of 0o755 and + other files are created with a mode of 0o644. + `, + flatten: (key, obj, flatOptions) => { + const camel = key.replace(/-([a-z])/g, (_0, _1) => _1.toUpperCase()) + flatOptions[camel] = obj[key] + }, + defaultDescription: '0', + typeDescription: 'Octal numeric string in range 0000..0777 (0..511)', + }, + unicode: { + key: 'unicode', + default: true, + defaultDescription: ` + false on windows, true on mac/unix systems with a unicode locale, as + defined by the \`LC_ALL\`, \`LC_CTYPE\`, or \`LANG\` environment variables. + `, + type: Boolean, + description: ` + When set to true, npm uses unicode characters in the tree output. When + false, it uses ascii characters instead of unicode glyphs. + `, + typeDescription: 'Boolean', + }, + 'update-notifier': { + key: 'update-notifier', + default: true, + type: Boolean, + description: ` + Set to false to suppress the update notification when using an older + version of npm than the latest. + `, + defaultDescription: 'true', + typeDescription: 'Boolean', + }, + usage: { + key: 'usage', + default: false, + type: Boolean, + short: [ + '?', + 'H', + 'h', + ], + description: ` + Show short usage output about the command specified. + `, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + 'user-agent': { + key: 'user-agent', + default: 'npm/{npm-version} node/{node-version} {platform} {arch} {ci}', + type: String, + description: ` + Sets the User-Agent request header. The following fields are replaced + with their actual counterparts: + + * \`{npm-version}\` - The npm version in use + * \`{node-version}\` - The Node.js version in use + * \`{platform}\` - The value of \`process.platform\` + * \`{arch}\` - The value of \`process.arch\` + * \`{workspaces}\` - Set to \`true\` if the \`workspaces\` or \`workspace\` + options are set. + * \`{ci}\` - The value of the \`ci-name\` config, if set, prefixed with + \`ci/\`, or an empty string if \`ci-name\` is empty. + `, + flatten (key, obj, flatOptions) { + const value = obj[key] + const ciName = obj['ci-name'] + flatOptions.userAgent = + value.replace(/\{node-version\}/gi, obj['node-version']) + .replace(/\{npm-version\}/gi, obj['npm-version']) + .replace(/\{platform\}/gi, process.platform) + .replace(/\{arch\}/gi, process.arch) + .replace(/\{ci\}/gi, ciName ? `ci/${ciName}` : '') + .trim() + }, + defaultDescription: '"npm/{npm-version} node/{node-version} {platform} {arch} {ci}"', + typeDescription: 'String', + }, + userconfig: { + key: 'userconfig', + default: '~/.npmrc', + type: path, + description: ` + The location of user-level configuration settings. + + This may be overridden by the \`npm_config_userconfig\` environment + variable or the \`--userconfig\` command line option, but may _not_ + be overridden by settings in the \`globalconfig\` file. + `, + defaultDescription: '"~/.npmrc"', + typeDescription: 'Path', + }, + version: { + key: 'version', + default: false, + type: Boolean, + short: 'v', + description: ` + If true, output the npm version and exit successfully. + + Only relevant when specified explicitly on the command line. + `, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + versions: { + key: 'versions', + default: false, + type: Boolean, + description: ` + If true, output the npm version as well as node's \`process.versions\` + map and the version in the current working directory's \`package.json\` + file if one exists, and exit successfully. + + Only relevant when specified explicitly on the command line. + `, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, + viewer: { + key: 'viewer', + default: 'man', + defaultDescription: '\n "man" on Posix, "browser" on Windows\n ', + type: String, + description: ` + The program to use to view help content. + + Set to \`"browser"\` to view html help content in the default web browser. + `, + typeDescription: 'String', + }, + workspace: { + key: 'workspace', + default: [], + type: [String, Array], + short: 'w', + envExport: false, + description: ` + Enable running a command in the context of the configured workspaces of the + current project while filtering by running only the workspaces defined by + this configuration option. + + Valid values for the \`workspace\` config are either: + + * Workspace names + * Path to a workspace directory + * Path to a parent workspace directory (will result in selecting all + workspaces within that folder) + + When set for the \`npm init\` command, this may be set to the folder of + a workspace which does not yet exist, to create the folder and set it + up as a brand new workspace within the project. + `, + defaultDescription: '', + typeDescription: 'String (can be set multiple times)', + flatten: (key, obj, flatOptions) => { + definitions['user-agent'].flatten('user-agent', obj, flatOptions) + }, + }, + yes: { + key: 'yes', + default: false, + type: Boolean, + short: 'y', + description: ` + Automatically answer "yes" to any prompts that npm might print on + the command line. + `, + defaultDescription: 'false', + typeDescription: 'Boolean', + }, +} diff --git a/lib/utils/config/flatten.js b/workspaces/config/test/fixtures/flatten.js similarity index 100% rename from lib/utils/config/flatten.js rename to workspaces/config/test/fixtures/flatten.js diff --git a/workspaces/config/test/fixtures/shorthands.js b/workspaces/config/test/fixtures/shorthands.js new file mode 100644 index 0000000..5c460c6 --- /dev/null +++ b/workspaces/config/test/fixtures/shorthands.js @@ -0,0 +1,41 @@ +module.exports = { + 'enjoy-by': ['--before'], + a: ['--all'], + c: ['--call'], + s: ['--loglevel', 'silent'], + d: ['--loglevel', 'info'], + dd: ['--loglevel', 'verbose'], + ddd: ['--loglevel', 'silly'], + noreg: ['--no-registry'], + N: ['--no-registry'], + reg: ['--registry'], + 'no-reg': ['--no-registry'], + silent: ['--loglevel', 'silent'], + verbose: ['--loglevel', 'verbose'], + quiet: ['--loglevel', 'warn'], + q: ['--loglevel', 'warn'], + h: ['--usage'], + H: ['--usage'], + '?': ['--usage'], + help: ['--usage'], + v: ['--version'], + f: ['--force'], + desc: ['--description'], + 'no-desc': ['--no-description'], + local: ['--no-global'], + l: ['--long'], + m: ['--message'], + p: ['--parseable'], + porcelain: ['--parseable'], + readonly: ['--read-only'], + g: ['--global'], + S: ['--save'], + D: ['--save-dev'], + E: ['--save-exact'], + O: ['--save-optional'], + P: ['--save-prod'], + y: ['--yes'], + n: ['--no-yes'], + B: ['--save-bundle'], + C: ['--prefix'], +} diff --git a/workspaces/config/test/fixtures/types.js b/workspaces/config/test/fixtures/types.js new file mode 100644 index 0000000..0f8cedf --- /dev/null +++ b/workspaces/config/test/fixtures/types.js @@ -0,0 +1,151 @@ +const { + String: { type: String }, + Boolean: { type: Boolean }, + url: { type: url }, + Number: { type: Number }, + path: { type: path }, + Date: { type: Date }, + semver: { type: semver }, + Umask: { type: Umask }, +} = require('../../lib/type-defs.js') + +const { networkInterfaces } = require('os') +const getLocalAddresses = () => { + try { + return Object.values(networkInterfaces()).map( + int => int.map(({ address }) => address) + ).reduce((set, addrs) => set.concat(addrs), [undefined]) + } catch (e) { + return [undefined] + } +} + +module.exports = { + access: [null, 'restricted', 'public'], + all: Boolean, + 'allow-same-version': Boolean, + 'always-auth': Boolean, + also: [null, 'dev', 'development'], + audit: Boolean, + 'audit-level': ['low', 'moderate', 'high', 'critical', 'none', null], + 'auth-type': ['legacy', 'sso', 'saml', 'oauth'], + before: [null, Date], + 'bin-links': Boolean, + browser: [null, Boolean, String], + ca: [null, String, Array], + cafile: path, + cache: path, + 'cache-lock-stale': Number, + 'cache-lock-retries': Number, + 'cache-lock-wait': Number, + 'cache-max': Number, + 'cache-min': Number, + cert: [null, String], + cidr: [null, String, Array], + color: ['always', Boolean], + call: String, + depth: Number, + description: Boolean, + dev: Boolean, + 'dry-run': Boolean, + editor: String, + 'engine-strict': Boolean, + force: Boolean, + fund: Boolean, + 'format-package-lock': Boolean, + 'fetch-retries': Number, + 'fetch-retry-factor': Number, + 'fetch-retry-mintimeout': Number, + 'fetch-retry-maxtimeout': Number, + git: String, + 'git-tag-version': Boolean, + 'commit-hooks': Boolean, + global: Boolean, + globalconfig: path, + 'global-style': Boolean, + 'https-proxy': [null, url], + 'user-agent': String, + heading: String, + 'if-present': Boolean, + include: [Array, 'prod', 'dev', 'optional', 'peer'], + 'include-staged': Boolean, + 'ignore-prepublish': Boolean, + 'ignore-scripts': Boolean, + 'init-module': path, + 'init-author-name': String, + 'init-author-email': String, + 'init-author-url': ['', url], + 'init-license': String, + 'init-version': semver, + json: Boolean, + key: [null, String], + 'legacy-bundling': Boolean, + 'legacy-peer-deps': Boolean, + link: Boolean, + 'local-address': getLocalAddresses(), + loglevel: ['silent', 'error', 'warn', 'notice', 'http', 'timing', 'info', 'verbose', 'silly'], + 'logs-max': Number, + long: Boolean, + 'multiple-numbers': [Array, Number], + maxsockets: Number, + message: String, + 'metrics-registry': [null, String], + 'node-options': [null, String], + 'node-version': [null, semver], + noproxy: [null, String, Array], + offline: Boolean, + omit: [Array, 'dev', 'optional', 'peer'], + only: [null, 'dev', 'development', 'prod', 'production'], + optional: Boolean, + otp: [null, String], + package: [String, Array], + 'package-lock': Boolean, + 'package-lock-only': Boolean, + parseable: Boolean, + 'prefer-offline': Boolean, + 'prefer-online': Boolean, + prefix: path, + preid: String, + production: Boolean, + progress: Boolean, + proxy: [null, false, url], // allow proxy to be disabled explicitly + 'read-only': Boolean, + 'rebuild-bundle': Boolean, + registry: [null, url], + rollback: Boolean, + save: Boolean, + 'save-bundle': Boolean, + 'save-dev': Boolean, + 'save-exact': Boolean, + 'save-optional': Boolean, + 'save-prefix': String, + 'save-prod': Boolean, + scope: String, + 'script-shell': [null, String], + 'scripts-prepend-node-path': [Boolean, 'auto', 'warn-only'], + searchopts: String, + searchexclude: [null, String], + searchlimit: Number, + searchstaleness: Number, + 'send-metrics': Boolean, + shell: String, + shrinkwrap: Boolean, + 'sign-git-commit': Boolean, + 'sign-git-tag': Boolean, + 'sso-poll-frequency': Number, + 'sso-type': [null, 'oauth', 'saml'], + 'strict-ssl': Boolean, + tag: String, + timing: Boolean, + tmp: path, + unicode: Boolean, + 'update-notifier': Boolean, + usage: Boolean, + userconfig: path, + umask: Umask, + version: Boolean, + 'tag-version-prefix': String, + versions: Boolean, + viewer: String, + _exit: Boolean, +} diff --git a/workspaces/config/test/index.js b/workspaces/config/test/index.js new file mode 100644 index 0000000..8dbee05 --- /dev/null +++ b/workspaces/config/test/index.js @@ -0,0 +1,1295 @@ +const t = require('tap') + +const fs = require('fs') +const { readFileSync } = fs + +// when running with `npm test` it adds environment variables that +// mess with the things we expect here, so delete all of those. +Object.keys(process.env) + .filter(k => /^npm_/.test(k)) + .forEach(k => delete process.env[k]) +delete process.env.PREFIX +delete process.env.DESTDIR + +const definitions = require('./fixtures/definitions.js') +const shorthands = require('./fixtures/shorthands.js') +const flatten = require('./fixtures/flatten.js') +const typeDefs = require('../lib/type-defs.js') + +const { resolve, join, dirname } = require('path') + +const Config = t.mock('../', { + 'fs/promises': { + ...fs.promises, + readFile: async (path, ...args) => { + if (path.includes('WEIRD-ERROR')) { + throw Object.assign(new Error('weird error'), { code: 'EWEIRD' }) + } + + return fs.promises.readFile(path, ...args) + }, + }, +}) + +// because we used t.mock above, the require cache gets blown and we lose our direct equality +// on the typeDefs. to get around that, we require an un-mocked Config and assert against that +const RealConfig = require('../') +t.equal(typeDefs, RealConfig.typeDefs, 'exposes type definitions') + +t.test('construct with no settings, get default values for stuff', t => { + const npmPath = t.testdir() + const c = new Config({ + definitions: {}, + npmPath, + }) + + t.test('default some values from process object', t => { + const { env, execPath, platform } = process + const cwd = process.cwd() + t.equal(c.env, env, 'env') + t.equal(c.execPath, execPath, 'execPath') + t.equal(c.cwd, cwd, 'cwd') + t.equal(c.platform, platform, 'platform') + t.end() + }) + + t.test('not loaded yet', t => { + t.equal(c.loaded, false, 'not loaded yet') + t.throws(() => c.get('foo'), { + message: 'call config.load() before reading values', + }) + t.throws(() => c.find('foo'), { + message: 'call config.load() before reading values', + }) + t.throws(() => c.set('foo', 'bar'), { + message: 'call config.load() before setting values', + }) + t.throws(() => c.delete('foo'), { + message: 'call config.load() before deleting values', + }) + t.rejects(() => c.save('user'), { + message: 'call config.load() before saving', + }) + t.throws(() => c.data.set('user', {}), { + message: 'cannot change internal config data structure', + }) + t.throws(() => c.data.delete('user'), { + message: 'cannot change internal config data structure', + }) + t.end() + }) + + t.test('data structure all wired up properly', t => { + // verify that the proto objects are all wired up properly + c.list.forEach((data, i) => { + t.equal(Object.getPrototypeOf(data), c.list[i + 1] || null) + }) + t.equal(c.data.get('default').data, c.list[c.list.length - 1]) + t.equal(c.data.get('cli').data, c.list[0]) + t.end() + }) + + t.end() +}) + +t.test('load from files and environment variables', t => { + // need to get the dir because we reference it in the contents + const path = t.testdir() + t.testdir({ + npm: { + npmrc: ` +builtin-config = true +foo = from-builtin +userconfig = ${path}/user/.npmrc-from-builtin +`, + }, + global: { + etc: { + npmrc: ` +global-config = true +foo = from-global +userconfig = ${path}/should-not-load-this-file +`, + }, + }, + user: { + '.npmrc': ` +default-user-config-in-home = true +foo = from-default-userconfig +prefix = ${path}/global +`, + '.npmrc-from-builtin': ` +user-config-from-builtin = true +foo = from-custom-userconfig +globalconfig = ${path}/global/etc/npmrc +`, + }, + project: { + node_modules: {}, + '.npmrc': ` +project-config = true +foo = from-project-config +loglevel = yolo +`, + }, + 'project-no-config': { + 'package.json': '{"name":"@scope/project"}', + }, + }) + + const logs = [] + const logHandler = (...args) => logs.push(args) + process.on('log', logHandler) + t.teardown(() => process.off('log', logHandler)) + + const argv = [ + process.execPath, + __filename, + '-v', + '--no-audit', + 'config', + 'get', + 'foo', + '--also=dev', + '--registry=hello', + '--omit=cucumber', + '--access=blueberry', + '--multiple-numbers=what kind of fruit is not a number', + '--multiple-numbers=a baNaNa!!', + '-C', + ] + + t.test('dont let userconfig be the same as builtin config', async t => { + const config = new Config({ + npmPath: `${path}/npm`, + env: {}, + argv: [process.execPath, __filename, '--userconfig', `${path}/npm/npmrc`], + cwd: `${path}/project`, + shorthands, + definitions, + }) + await t.rejects(() => config.load(), { + message: `double-loading config "${resolve(path, 'npm/npmrc')}" as "user",` + + ' previously loaded as "builtin"', + }) + }) + + t.test('dont load project config if global is true', async t => { + const config = new Config({ + npmPath: `${path}/npm`, + env: {}, + argv: [process.execPath, __filename, '--global'], + cwd: `${path}/project`, + shorthands, + definitions, + }) + + await config.load() + const source = config.data.get('project').source + t.equal(source, '(global mode enabled, ignored)', 'data has placeholder') + t.equal(config.sources.get(source), 'project', 'sources has project') + }) + + t.test('dont load project config if location is global', async t => { + const config = new Config({ + npmPath: `${path}/npm`, + env: {}, + argv: [process.execPath, __filename, '--location', 'global'], + cwd: `${path}/project`, + shorthands, + definitions, + }) + + await config.load() + const source = config.data.get('project').source + t.equal(source, '(global mode enabled, ignored)', 'data has placeholder') + t.equal(config.sources.get(source), 'project', 'sources has project') + t.ok(config.localPrefix, 'localPrefix is set') + }) + + t.test('verbose log if config file read is weird error', async t => { + const config = new Config({ + npmPath: path, + env: {}, + argv: [process.execPath, + __filename, + '--userconfig', + `${path}/WEIRD-ERROR`, + '--no-workspaces'], + cwd: path, + shorthands, + definitions, + }) + logs.length = 0 + await config.load() + t.match(logs, [['verbose', 'config', 'error loading user config', { + message: 'weird error', + }]]) + logs.length = 0 + }) + + t.test('load configs from all files, cli, and env', async t => { + const env = { + npm_config_foo: 'from-env', + npm_config_global: '', + npm_config_prefix: '/something', + } + const config = new Config({ + npmPath: `${path}/npm`, + env, + argv, + cwd: `${path}/project`, + + shorthands, + definitions, + }) + + t.equal(config.globalPrefix, null, 'globalPrefix missing before load') + + await config.load() + + t.equal(config.globalPrefix, resolve('/something'), 'env-defined prefix should be loaded') + + t.equal(config.get('global', 'env'), undefined, 'empty env is missing') + t.equal(config.get('global'), false, 'empty env is missing') + + config.set('asdf', 'quux', 'global') + await config.save('global') + const gres = readFileSync(`${path}/global/etc/npmrc`, 'utf8') + t.match(gres, 'asdf=quux') + + const cliData = config.data.get('cli') + t.throws(() => cliData.loadError = true, { + message: 'cannot set ConfigData loadError after load', + }) + t.throws(() => cliData.source = 'foo', { + message: 'cannot set ConfigData source more than once', + }) + t.throws(() => cliData.raw = 1234, { + message: 'cannot set ConfigData raw after load', + }) + + config.argv = [] + + t.throws(() => config.loadCLI(), { + message: 'double-loading "cli" configs from command line options, previously loaded from' + + ' command line options', + }) + t.rejects(() => config.loadUserConfig(), { + message: `double-loading "user" configs from ${resolve(path, 'should-not-load-this-file')}` + + `, previously loaded from ${resolve(path, 'user/.npmrc-from-builtin')}`, + }) + + t.equal(config.loaded, true, 'config is loaded') + + await t.rejects(() => config.load(), { + message: 'attempting to load npm config multiple times', + }) + t.equal(config.find('no config value here'), null) + + t.equal(config.prefix, config.localPrefix, 'prefix is local prefix when not global') + config.set('global', true) + t.equal(config.prefix, config.globalPrefix, 'prefix is global prefix when global') + config.set('global', false) + t.equal(config.find('global'), 'cli') + config.delete('global') + t.equal(config.find('global'), 'default') + + t.throws(() => config.get('foo', 'barbaz'), { + message: 'invalid config location param: barbaz', + }) + t.throws(() => config.set('foo', 1234, 'barbaz'), { + message: 'invalid config location param: barbaz', + }) + t.throws(() => config.delete('foo', 'barbaz'), { + message: 'invalid config location param: barbaz', + }) + + t.match(config.sources, new Map([ + ['default values', 'default'], + [resolve(path, 'npm/npmrc'), 'builtin'], + ['command line options', 'cli'], + ['environment', 'env'], + [resolve(path, 'project/.npmrc'), 'project'], + [resolve(path, 'user/.npmrc-from-builtin'), 'user'], + [resolve(path, 'global/etc/npmrc'), 'global'], + ])) + + t.strictSame({ + version: config.get('version'), + audit: config.get('audit'), + 'project-config': config.get('project-config'), + foo: config.get('foo'), + 'user-config-from-builtin': config.get('user-config-from-builtin'), + 'global-config': config.get('global-config'), + 'builtin-config': config.get('builtin-config'), + all: config.get('all'), + }, { + version: true, + audit: false, + 'project-config': true, + foo: 'from-env', + 'user-config-from-builtin': true, + 'global-config': true, + 'builtin-config': true, + all: config.get('all'), + }) + + t.match(env, { + npm_config_user_config_from_builtin: 'true', + npm_config_audit: '', + npm_config_version: 'true', + npm_config_foo: 'from-env', + npm_config_builtin_config: 'true', + }, 'set env values') + + // warn logs are emitted as a side effect of validate + config.validate() + t.strictSame(logs, [ + ['warn', 'invalid config', 'registry="hello"', 'set in command line options'], + ['warn', 'invalid config', 'Must be', 'full url with "http://"'], + ['warn', 'invalid config', 'omit="cucumber"', 'set in command line options'], + ['warn', 'invalid config', 'Must be one or more of:', 'dev, optional, peer'], + ['warn', 'invalid config', 'access="blueberry"', 'set in command line options'], + ['warn', 'invalid config', 'Must be one of:', 'null, restricted, public'], + ['warn', 'invalid config', 'multiple-numbers="what kind of fruit is not a number"', + 'set in command line options'], + ['warn', 'invalid config', 'Must be one or more', 'numeric value'], + ['warn', 'invalid config', 'multiple-numbers="a baNaNa!!"', 'set in command line options'], + ['warn', 'invalid config', 'Must be one or more', 'numeric value'], + ['warn', 'invalid config', 'prefix=true', 'set in command line options'], + ['warn', 'invalid config', 'Must be', 'valid filesystem path'], + ['warn', 'config', 'also', 'Please use --include=dev instead.'], + ['warn', 'invalid config', 'loglevel="yolo"', + `set in ${resolve(path, 'project/.npmrc')}`], + ['warn', 'invalid config', 'Must be one of:', + ['silent', 'error', 'warn', 'notice', 'http', 'timing', 'info', + 'verbose', 'silly'].join(', '), + ], + ]) + t.equal(config.valid, false) + logs.length = 0 + + // set a new value that defaults to cli source + config.set('cli-config', 1) + + t.ok(config.isDefault('methane'), + 'should return true if value is retrieved from default definitions') + t.notOk(config.isDefault('cli-config'), + 'should return false for a cli-defined value') + t.notOk(config.isDefault('foo'), + 'should return false for a env-defined value') + t.notOk(config.isDefault('project-config'), + 'should return false for a project-defined value') + t.notOk(config.isDefault('default-user-config-in-home'), + 'should return false for a user-defined value') + t.notOk(config.isDefault('global-config'), + 'should return false for a global-defined value') + t.notOk(config.isDefault('builtin-config'), + 'should return false for a builtin-defined value') + + // make sure isDefault still works as intended after + // setting and deleting values in differente sources + config.set('methane', 'H2O', 'cli') + t.notOk(config.isDefault('methane'), + 'should no longer return true now that a cli value was defined') + config.delete('methane', 'cli') + t.ok(config.isDefault('methane'), + 'should return true once again now that values is retrieved from defaults') + }) + + t.test('normalize config env keys', async t => { + const env = { + npm_config_bAr: 'bAr env', + NPM_CONFIG_FOO: 'FOO env', + 'npm_config_//reg.example/UP_CASE/:username': 'ME', + 'npm_config_//reg.example/UP_CASE/:_password': 'Shhhh!', + 'NPM_CONFIG_//reg.example/UP_CASE/:_authToken': 'sEcReT', + } + const config = new Config({ + npmPath: `${path}/npm`, + env, + argv, + cwd: `${path}/project`, + + shorthands, + definitions, + }) + + await config.load() + + t.strictSame({ + bar: config.get('bar'), + foo: config.get('foo'), + '//reg.example/UP_CASE/:username': config.get('//reg.example/UP_CASE/:username'), + '//reg.example/UP_CASE/:_password': config.get('//reg.example/UP_CASE/:_password'), + '//reg.example/UP_CASE/:_authToken': config.get('//reg.example/UP_CASE/:_authToken'), + }, { + bar: 'bAr env', + foo: 'FOO env', + '//reg.example/UP_CASE/:username': 'ME', + '//reg.example/UP_CASE/:_password': 'Shhhh!', + '//reg.example/UP_CASE/:_authToken': 'sEcReT', + }) + }) + + t.test('do not double-load project/user config', async t => { + const env = { + npm_config_foo: 'from-env', + npm_config_globalconfig: '/this/path/does/not/exist', + } + + const config = new Config({ + npmPath: `${path}/npm`, + env, + argv: [process.execPath, __filename, '--userconfig', `${path}/project/.npmrc`], + cwd: `${path}/project`, + + shorthands, + definitions, + }) + await config.load() + + config.argv = [] + t.equal(config.loaded, true, 'config is loaded') + + t.match(config.data.get('global').loadError, { code: 'ENOENT' }) + t.strictSame(config.data.get('env').raw, Object.assign(Object.create(null), { + foo: 'from-env', + globalconfig: '/this/path/does/not/exist', + })) + + t.match(config.sources, new Map([ + ['default values', 'default'], + [resolve(path, 'npm/npmrc'), 'builtin'], + ['command line options', 'cli'], + ['environment', 'env'], + ['(same as "user" config, ignored)', 'project'], + [resolve(path, 'project/.npmrc'), 'user'], + ])) + + t.rejects(() => config.save('yolo'), { + message: 'invalid config location param: yolo', + }) + config.validate() + t.equal(config.valid, false, 'config should not be valid') + logs.length = 0 + }) + + t.test('load configs from files, cli, and env, no builtin or project', async t => { + const env = { + npm_config_foo: 'from-env', + HOME: `${path}/user`, + } + + const config = new Config({ + // no builtin + npmPath: path, + env, + argv, + cwd: `${path}/project-no-config`, + + // should prepend DESTDIR to /global + DESTDIR: path, + PREFIX: '/global', + platform: 'posix', + + shorthands, + definitions, + }) + await config.load() + + t.match(config.sources, new Map([ + ['default values', 'default'], + ['command line options', 'cli'], + ['environment', 'env'], + [resolve(path, 'user/.npmrc'), 'user'], + [resolve(path, 'global/etc/npmrc'), 'global'], + ])) + // no builtin or project config + t.equal(config.sources.get(resolve(path, 'npm/npmrc')), undefined) + t.equal(config.sources.get(resolve(path, 'project/.npmrc')), undefined) + + t.strictSame({ + version: config.get('version'), + audit: config.get('audit'), + 'project-config': config.get('project-config'), + foo: config.get('foo'), + 'user-config-from-builtin': config.get('user-config-from-builtin'), + 'default-user-config-in-home': config.get('default-user-config-in-home'), + 'global-config': config.get('global-config'), + 'builtin-config': config.get('builtin-config'), + all: config.get('all'), + }, { + version: true, + audit: false, + 'project-config': undefined, + foo: 'from-env', + 'user-config-from-builtin': undefined, + 'default-user-config-in-home': true, + 'global-config': true, + 'builtin-config': undefined, + all: config.get('all'), + }) + + t.strictSame(logs, [ + ['warn', 'invalid config', 'registry="hello"', 'set in command line options'], + ['warn', 'invalid config', 'Must be', 'full url with "http://"'], + ['warn', 'invalid config', 'omit="cucumber"', 'set in command line options'], + ['warn', 'invalid config', 'Must be one or more of:', 'dev, optional, peer'], + ['warn', 'invalid config', 'access="blueberry"', 'set in command line options'], + ['warn', 'invalid config', 'Must be one of:', 'null, restricted, public'], + ['warn', 'invalid config', 'multiple-numbers="what kind of fruit is not a number"', + 'set in command line options'], + ['warn', 'invalid config', 'Must be one or more', 'numeric value'], + ['warn', 'invalid config', 'multiple-numbers="a baNaNa!!"', 'set in command line options'], + ['warn', 'invalid config', 'Must be one or more', 'numeric value'], + ['warn', 'invalid config', 'prefix=true', 'set in command line options'], + ['warn', 'invalid config', 'Must be', 'valid filesystem path'], + ['warn', 'config', 'also', 'Please use --include=dev instead.'], + ]) + }) + + t.end() +}) + +t.test('cafile loads as ca (and some saving tests)', async t => { + const cafile = resolve(__dirname, 'fixtures', 'cafile') + const dir = t.testdir({ + '.npmrc': `cafile = ${cafile} +//registry.npmjs.org/:_authToken = deadbeefcafebadfoobarbaz42069 +`, + }) + const expect = `cafile=${cafile} +//registry.npmjs.org/:_authToken=deadbeefcafebadfoobarbaz42069 +` + + const config = new Config({ + shorthands, + definitions, + npmPath: __dirname, + env: { HOME: dir, PREFIX: dir }, + flatten, + }) + await config.load() + t.equal(config.get('ca'), null, 'does not overwrite config.get') + const { flat } = config + t.equal(config.flat, flat, 'getter returns same value again') + const ca = flat.ca + t.equal(ca.join('\n').replace(/\r\n/g, '\n').trim(), readFileSync(cafile, 'utf8') + .replace(/\r\n/g, '\n').trim()) + await config.save('user') + const res = readFileSync(`${dir}/.npmrc`, 'utf8').replace(/\r\n/g, '\n') + t.equal(res, expect, 'did not write back ca, only cafile') + // while we're here, test that saving an empty config file deletes it + config.delete('cafile', 'user') + config.clearCredentialsByURI(config.get('registry')) + await config.save('user') + t.throws(() => readFileSync(`${dir}/.npmrc`, 'utf8'), { code: 'ENOENT' }) + // do it again to verify we ignore the unlink error + await config.save('user') + t.throws(() => readFileSync(`${dir}/.npmrc`, 'utf8'), { code: 'ENOENT' }) + t.equal(config.valid, true) +}) + +t.test('cafile ignored if ca set', async t => { + const cafile = resolve(__dirname, 'fixtures', 'cafile') + const dir = t.testdir({ + '.npmrc': `cafile = ${cafile}`, + }) + const ca = ` +-----BEGIN CERTIFICATE----- +fakey mc fakerson +-----END CERTIFICATE----- +` + const config = new Config({ + shorthands, + definitions, + npmPath: __dirname, + env: { + HOME: dir, + npm_config_ca: ca, + }, + }) + await config.load() + t.strictSame(config.get('ca'), [ca.trim()]) + await config.save('user') + const res = readFileSync(`${dir}/.npmrc`, 'utf8') + t.equal(res.trim(), `cafile=${cafile}`) +}) + +t.test('ignore cafile if it does not load', async t => { + const cafile = resolve(__dirname, 'fixtures', 'cafile-does-not-exist') + const dir = t.testdir({ + '.npmrc': `cafile = ${cafile}`, + }) + const config = new Config({ + shorthands, + definitions, + npmPath: __dirname, + env: { HOME: dir }, + }) + await config.load() + t.equal(config.get('ca'), null) + await config.save('user') + const res = readFileSync(`${dir}/.npmrc`, 'utf8') + t.equal(res.trim(), `cafile=${cafile}`) +}) + +t.test('raise error if reading ca file error other than ENOENT', async t => { + const cafile = resolve(__dirname, 'fixtures', 'WEIRD-ERROR') + const dir = t.testdir({ + '.npmrc': `cafile = ${cafile}`, + }) + const config = new Config({ + shorthands, + definitions, + npmPath: __dirname, + env: { HOME: dir }, + flatten, + }) + await config.load() + t.throws(() => config.flat.ca, { code: 'EWEIRD' }) +}) + +t.test('credentials management', async t => { + const fixtures = { + nerfed_authToken: { '.npmrc': '//registry.example/:_authToken = 0bad1de4' }, + nerfed_userpass: { + '.npmrc': `//registry.example/:username = hello +//registry.example/:_password = ${Buffer.from('world').toString('base64')} +//registry.example/:email = i@izs.me +//registry.example/:always-auth = "false"`, + }, + nerfed_auth: { // note: does not load, because we don't do _auth per reg + '.npmrc': `//registry.example/:_auth = ${Buffer.from('hello:world').toString('base64')}`, + }, + nerfed_mtls: { '.npmrc': `//registry.example/:certfile = /path/to/cert +//registry.example/:keyfile = /path/to/key`, + }, + nerfed_mtlsAuthToken: { '.npmrc': `//registry.example/:_authToken = 0bad1de4 +//registry.example/:certfile = /path/to/cert +//registry.example/:keyfile = /path/to/key`, + }, + nerfed_mtlsUserPass: { '.npmrc': `//registry.example/:username = hello +//registry.example/:_password = ${Buffer.from('world').toString('base64')} +//registry.example/:email = i@izs.me +//registry.example/:always-auth = "false" +//registry.example/:certfile = /path/to/cert +//registry.example/:keyfile = /path/to/key`, + }, + def_userpass: { + '.npmrc': `username = hello +_password = ${Buffer.from('world').toString('base64')} +email = i@izs.me +//registry.example/:always-auth = true +`, + }, + def_userNoPass: { + '.npmrc': `username = hello +email = i@izs.me +//registry.example/:always-auth = true +`, + }, + def_passNoUser: { + '.npmrc': `_password = ${Buffer.from('world').toString('base64')} +email = i@izs.me +//registry.example/:always-auth = true +`, + }, + def_auth: { + '.npmrc': `_auth = ${Buffer.from('hello:world').toString('base64')} +always-auth = true`, + }, + none_authToken: { '.npmrc': '_authToken = 0bad1de4' }, + none_lcAuthToken: { '.npmrc': '_authtoken = 0bad1de4' }, + none_emptyConfig: { '.npmrc': '' }, + none_noConfig: {}, + } + const path = t.testdir(fixtures) + + const defReg = 'https://registry.example/' + const otherReg = 'https://other.registry/' + for (const testCase of Object.keys(fixtures)) { + t.test(testCase, async t => { + const c = new Config({ + npmPath: path, + shorthands, + definitions, + env: { HOME: resolve(path, testCase) }, + argv: ['node', 'file', '--registry', defReg], + }) + await c.load() + + // only have to do this the first time, it's redundant otherwise + if (testCase === 'none_noConfig') { + t.throws(() => c.setCredentialsByURI('http://x.com', { + username: 'foo', + email: 'bar@baz.com', + }), { message: 'must include password' }) + t.throws(() => c.setCredentialsByURI('http://x.com', { + password: 'foo', + email: 'bar@baz.com', + }), { message: 'must include username' }) + c.setCredentialsByURI('http://x.com', { + username: 'foo', + password: 'bar', + email: 'asdf@quux.com', + }) + } + + // the def_ and none_ prefixed cases have unscoped auth values and should throw + if (testCase.startsWith('def_') || + testCase === 'none_authToken' || + testCase === 'none_lcAuthToken') { + try { + c.validate() + // validate should throw, fail the test here if it doesn't + t.fail('validate should have thrown') + } catch (err) { + if (err.code !== 'ERR_INVALID_AUTH') { + throw err + } + + // we got our expected invalid auth error, so now repair it + c.repair(err.problems) + t.ok(c.valid, 'config is valid') + } + } else { + // validate won't throw for these ones, so let's prove it and repair are no-ops + c.validate() + c.repair() + } + + const d = c.getCredentialsByURI(defReg) + const o = c.getCredentialsByURI(otherReg) + + t.matchSnapshot(d, 'default registry') + t.matchSnapshot(o, 'other registry') + + c.clearCredentialsByURI(defReg) + const defAfterDelete = c.getCredentialsByURI(defReg) + { + const expectKeys = [] + if (defAfterDelete.email) { + expectKeys.push('email') + } + t.strictSame(Object.keys(defAfterDelete), expectKeys) + } + + c.clearCredentialsByURI(otherReg) + const otherAfterDelete = c.getCredentialsByURI(otherReg) + { + const expectKeys = [] + if (otherAfterDelete.email) { + expectKeys.push('email') + } + t.strictSame(Object.keys(otherAfterDelete), expectKeys) + } + + // need both or none of user/pass + if (!d.token && (!d.username || !d.password) && (!d.certfile || !d.keyfile)) { + t.throws(() => c.setCredentialsByURI(defReg, d)) + } else { + c.setCredentialsByURI(defReg, d) + t.matchSnapshot(c.getCredentialsByURI(defReg), 'default registry after set') + } + + if (!o.token && (!o.username || !o.password) && (!o.certfile || !o.keyfile)) { + t.throws(() => c.setCredentialsByURI(otherReg, o), {}, { otherReg, o }) + } else { + c.setCredentialsByURI(otherReg, o) + t.matchSnapshot(c.getCredentialsByURI(otherReg), 'other registry after set') + } + }) + } + t.end() +}) + +t.test('finding the global prefix', t => { + const npmPath = __dirname + t.test('load from PREFIX env', t => { + const c = new Config({ + env: { + PREFIX: '/prefix/env', + }, + shorthands, + definitions, + npmPath, + }) + c.loadGlobalPrefix() + t.throws(() => c.loadGlobalPrefix(), { + message: 'cannot load default global prefix more than once', + }) + t.equal(c.globalPrefix, '/prefix/env') + t.end() + }) + t.test('load from execPath, win32', t => { + const c = new Config({ + platform: 'win32', + execPath: '/path/to/nodejs/node.exe', + shorthands, + definitions, + npmPath, + }) + c.loadGlobalPrefix() + t.equal(c.globalPrefix, dirname('/path/to/nodejs/node.exe')) + t.end() + }) + t.test('load from execPath, posix', t => { + const c = new Config({ + platform: 'posix', + execPath: '/path/to/nodejs/bin/node', + shorthands, + definitions, + npmPath, + }) + c.loadGlobalPrefix() + t.equal(c.globalPrefix, dirname(dirname('/path/to/nodejs/bin/node'))) + t.end() + }) + t.test('load from execPath with destdir, posix', t => { + const c = new Config({ + platform: 'posix', + execPath: '/path/to/nodejs/bin/node', + env: { DESTDIR: '/some/dest/dir' }, + shorthands, + definitions, + npmPath, + }) + c.loadGlobalPrefix() + t.equal(c.globalPrefix, join('/some/dest/dir', dirname(dirname('/path/to/nodejs/bin/node')))) + t.end() + }) + t.end() +}) + +t.test('finding the local prefix', t => { + const path = t.testdir({ + hasNM: { + node_modules: {}, + x: { y: { z: {} } }, + }, + hasPJ: { + 'package.json': '{}', + x: { y: { z: {} } }, + }, + }) + t.test('explicit cli prefix', async t => { + const c = new Config({ + argv: [process.execPath, __filename, '-C', path], + shorthands, + definitions, + npmPath: path, + }) + await c.load() + t.equal(c.localPrefix, resolve(path)) + }) + t.test('has node_modules', async t => { + const c = new Config({ + cwd: `${path}/hasNM/x/y/z`, + shorthands, + definitions, + npmPath: path, + }) + await c.load() + t.equal(c.localPrefix, resolve(path, 'hasNM')) + }) + t.test('has package.json', async t => { + const c = new Config({ + cwd: `${path}/hasPJ/x/y/z`, + shorthands, + definitions, + npmPath: path, + }) + await c.load() + t.equal(c.localPrefix, resolve(path, 'hasPJ')) + }) + t.test('nada, just use cwd', async t => { + const c = new Config({ + cwd: '/this/path/does/not/exist/x/y/z', + shorthands, + definitions, + npmPath: path, + }) + await c.load() + t.equal(c.localPrefix, '/this/path/does/not/exist/x/y/z') + }) + t.end() +}) + +t.test('setting basic auth creds and email', async t => { + const registry = 'https://registry.npmjs.org/' + const path = t.testdir() + const _auth = Buffer.from('admin:admin').toString('base64') + const opts = { + shorthands: {}, + argv: ['node', __filename, `--userconfig=${path}/.npmrc`], + definitions: { + registry: { default: registry }, + }, + npmPath: process.cwd(), + } + const c = new Config(opts) + await c.load() + c.set('email', 'name@example.com', 'user') + t.equal(c.get('email', 'user'), 'name@example.com', 'email was set') + await c.save('user') + t.equal(c.get('email', 'user'), 'name@example.com', 'email still top level') + t.strictSame(c.getCredentialsByURI(registry), { email: 'name@example.com' }) + const d = new Config(opts) + await d.load() + t.strictSame(d.getCredentialsByURI(registry), { email: 'name@example.com' }) + d.set('_auth', _auth, 'user') + t.equal(d.get('_auth', 'user'), _auth, '_auth was set') + d.repair() + await d.save('user') + const e = new Config(opts) + await e.load() + t.equal(e.get('_auth', 'user'), undefined, 'un-nerfed _auth deleted') + t.strictSame(e.getCredentialsByURI(registry), { + email: 'name@example.com', + username: 'admin', + password: 'admin', + auth: _auth, + }, 'credentials saved and nerfed') +}) + +t.test('setting username/password/email individually', async t => { + const registry = 'https://registry.npmjs.org/' + const path = t.testdir() + const opts = { + shorthands: {}, + argv: ['node', __filename, `--userconfig=${path}/.npmrc`], + definitions: { + registry: { default: registry }, + }, + npmPath: process.cwd(), + } + const c = new Config(opts) + await c.load() + c.set('email', 'name@example.com', 'user') + t.equal(c.get('email'), 'name@example.com') + c.set('username', 'admin', 'user') + t.equal(c.get('username'), 'admin') + c.set('_password', Buffer.from('admin').toString('base64'), 'user') + t.equal(c.get('_password'), Buffer.from('admin').toString('base64')) + t.equal(c.get('_auth'), undefined) + c.repair() + await c.save('user') + + const d = new Config(opts) + await d.load() + t.equal(d.get('email'), 'name@example.com') + t.equal(d.get('username'), undefined) + t.equal(d.get('_password'), undefined) + t.equal(d.get('_auth'), undefined) + t.strictSame(d.getCredentialsByURI(registry), { + email: 'name@example.com', + username: 'admin', + password: 'admin', + auth: Buffer.from('admin:admin').toString('base64'), + }) +}) + +t.test('nerfdart auths set at the top level into the registry', async t => { + const registry = 'https://registry.npmjs.org/' + const _auth = Buffer.from('admin:admin').toString('base64') + const username = 'admin' + const _password = Buffer.from('admin').toString('base64') + const email = 'i@izs.me' + const _authToken = 'deadbeefblahblah' + + // name: [ini, expect, wontThrow] + const cases = { + '_auth only, no email': [`_auth=${_auth}`, { + '//registry.npmjs.org/:_auth': _auth, + }], + '_auth with email': [`_auth=${_auth}\nemail=${email}`, { + '//registry.npmjs.org/:_auth': _auth, + email, + }], + '_authToken alone': [`_authToken=${_authToken}`, { + '//registry.npmjs.org/:_authToken': _authToken, + }], + '_authToken and email': [`_authToken=${_authToken}\nemail=${email}`, { + '//registry.npmjs.org/:_authToken': _authToken, + email, + }], + 'username and _password': [`username=${username}\n_password=${_password}`, { + '//registry.npmjs.org/:username': username, + '//registry.npmjs.org/:_password': _password, + }], + 'username, password, email': [`username=${username}\n_password=${_password}\nemail=${email}`, { + '//registry.npmjs.org/:username': username, + '//registry.npmjs.org/:_password': _password, + email, + }], + // handled invalid/legacy cases + 'username, no _password': [`username=${username}`, {}], + '_password, no username': [`_password=${_password}`, {}], + '_authtoken instead of _authToken': [`_authtoken=${_authToken}`, {}], + '-authtoken instead of _authToken': [`-authtoken=${_authToken}`, {}], + // de-nerfdart the email, if present in that way + 'nerf-darted email': [`//registry.npmjs.org/:email=${email}`, { + email, + }, true], + } + + const logs = [] + const logHandler = (...args) => logs.push(args) + process.on('log', logHandler) + t.teardown(() => { + process.removeListener('log', logHandler) + }) + const cwd = process.cwd() + for (const [name, [ini, expect, wontThrow]] of Object.entries(cases)) { + t.test(name, async t => { + t.teardown(() => { + process.chdir(cwd) + logs.length = 0 + }) + const path = t.testdir({ + '.npmrc': ini, + 'package.json': JSON.stringify({}), + }) + process.chdir(path) + const argv = [ + 'node', + __filename, + `--prefix=${path}`, + `--userconfig=${path}/.npmrc`, + `--globalconfig=${path}/etc/npmrc`, + ] + const opts = { + shorthands: {}, + argv, + env: {}, + definitions: { + registry: { default: registry }, + }, + npmPath: process.cwd(), + } + + const c = new Config(opts) + await c.load() + + if (!wontThrow) { + t.throws(() => c.validate(), { code: 'ERR_INVALID_AUTH' }) + } + + // now we go ahead and do the repair, and save + c.repair() + await c.save('user') + t.same(c.list[3], expect) + }) + } +}) + +t.test('workspaces', async (t) => { + const path = resolve(t.testdir({ + 'package.json': JSON.stringify({ + name: 'root', + version: '1.0.0', + workspaces: ['./workspaces/*'], + }), + workspaces: { + one: { + 'package.json': JSON.stringify({ + name: 'one', + version: '1.0.0', + }), + }, + two: { + 'package.json': JSON.stringify({ + name: 'two', + version: '1.0.0', + }), + }, + three: { + 'package.json': JSON.stringify({ + name: 'three', + version: '1.0.0', + }), + '.npmrc': 'package-lock=false', + }, + }, + })) + + const logs = [] + const logHandler = (...args) => logs.push(args) + process.on('log', logHandler) + t.teardown(() => process.off('log', logHandler)) + t.afterEach(() => logs.length = 0) + + t.test('finds own parent', async (t) => { + const cwd = process.cwd() + t.teardown(() => process.chdir(cwd)) + process.chdir(`${path}/workspaces/one`) + + const config = new Config({ + npmPath: cwd, + env: {}, + argv: [process.execPath, __filename], + cwd: `${path}/workspaces/one`, + shorthands, + definitions, + }) + + await config.load() + t.equal(config.localPrefix, path, 'localPrefix is the root') + t.same(config.get('workspace'), [join(path, 'workspaces', 'one')], 'set the workspace') + t.equal(logs.length, 1, 'got one log message') + t.match(logs[0], ['info', /^found workspace root at/], 'logged info about workspace root') + }) + + t.test('finds other workspace parent', async (t) => { + const cwd = process.cwd() + t.teardown(() => process.chdir(cwd)) + process.chdir(`${path}/workspaces/one`) + + const config = new Config({ + npmPath: process.cwd(), + env: {}, + argv: [process.execPath, __filename, '--workspace', '../two'], + cwd: `${path}/workspaces/one`, + shorthands, + definitions, + }) + + await config.load() + t.equal(config.localPrefix, path, 'localPrefix is the root') + t.same(config.get('workspace'), ['../two'], 'kept the specified workspace') + t.equal(logs.length, 1, 'got one log message') + t.match(logs[0], ['info', /^found workspace root at/], 'logged info about workspace root') + }) + + t.test('warns when workspace has .npmrc', async (t) => { + const cwd = process.cwd() + t.teardown(() => process.chdir(cwd)) + process.chdir(`${path}/workspaces/three`) + + const config = new Config({ + npmPath: process.cwd(), + env: {}, + argv: [process.execPath, __filename], + cwd: `${path}/workspaces/three`, + shorthands, + definitions, + }) + + await config.load() + t.equal(config.localPrefix, path, 'localPrefix is the root') + t.same(config.get('workspace'), [join(path, 'workspaces', 'three')], 'kept the workspace') + t.equal(logs.length, 2, 'got two log messages') + t.match(logs[0], ['warn', /^ignoring workspace config/], 'warned about ignored config') + t.match(logs[1], ['info', /^found workspace root at/], 'logged info about workspace root') + }) + + t.test('prefix skips auto detect', async (t) => { + const cwd = process.cwd() + t.teardown(() => process.chdir(cwd)) + process.chdir(`${path}/workspaces/one`) + + const config = new Config({ + npmPath: process.cwd(), + env: {}, + argv: [process.execPath, __filename, '--prefix', './'], + cwd: `${path}/workspaces/one`, + shorthands, + definitions, + }) + + await config.load() + t.equal(config.localPrefix, join(path, 'workspaces', 'one'), 'localPrefix is the root') + t.same(config.get('workspace'), [], 'did not set workspace') + t.equal(logs.length, 0, 'got no log messages') + }) + + t.test('no-workspaces skips auto detect', async (t) => { + const cwd = process.cwd() + t.teardown(() => process.chdir(cwd)) + process.chdir(`${path}/workspaces/one`) + + const config = new Config({ + npmPath: process.cwd(), + env: {}, + argv: [process.execPath, __filename, '--no-workspaces'], + cwd: `${path}/workspaces/one`, + shorthands, + definitions, + }) + + await config.load() + t.equal(config.localPrefix, join(path, 'workspaces', 'one'), 'localPrefix is the root') + t.same(config.get('workspace'), [], 'did not set workspace') + t.equal(logs.length, 0, 'got no log messages') + }) + + t.test('global skips auto detect', async (t) => { + const cwd = process.cwd() + t.teardown(() => process.chdir(cwd)) + process.chdir(`${path}/workspaces/one`) + + const config = new Config({ + npmPath: process.cwd(), + env: {}, + argv: [process.execPath, __filename, '--global'], + cwd: `${path}/workspaces/one`, + shorthands, + definitions, + }) + + await config.load() + t.equal(config.localPrefix, join(path, 'workspaces', 'one'), 'localPrefix is the root') + t.same(config.get('workspace'), [], 'did not set workspace') + t.equal(logs.length, 0, 'got no log messages') + }) + + t.test('location=global skips auto detect', async (t) => { + const cwd = process.cwd() + t.teardown(() => process.chdir(cwd)) + process.chdir(`${path}/workspaces/one`) + + const config = new Config({ + npmPath: process.cwd(), + env: {}, + argv: [process.execPath, __filename, '--location=global'], + cwd: `${path}/workspaces/one`, + shorthands, + definitions, + }) + + await config.load() + t.equal(config.localPrefix, join(path, 'workspaces', 'one'), 'localPrefix is the root') + t.same(config.get('workspace'), [], 'did not set workspace') + t.equal(logs.length, 0, 'got no log messages') + }) + + t.test('does not error for invalid package.json', async (t) => { + const invalidPkg = join(path, 'workspaces', 'package.json') + const cwd = process.cwd() + t.teardown(() => { + fs.unlinkSync(invalidPkg) + process.chdir(cwd) + }) + process.chdir(`${path}/workspaces/one`) + + // write some garbage to the file so read-package-json-fast will throw + fs.writeFileSync(invalidPkg, 'not-json') + const config = new Config({ + npmPath: cwd, + env: {}, + argv: [process.execPath, __filename], + cwd: `${path}/workspaces/one`, + shorthands, + definitions, + }) + + await config.load() + t.equal(config.localPrefix, path, 'localPrefix is the root') + t.same(config.get('workspace'), [join(path, 'workspaces', 'one')], 'set the workspace') + t.equal(logs.length, 1, 'got one log message') + t.match(logs[0], ['info', /^found workspace root at/], 'logged info about workspace root') + }) +}) diff --git a/workspaces/config/test/nerf-dart.js b/workspaces/config/test/nerf-dart.js new file mode 100644 index 0000000..8c175a5 --- /dev/null +++ b/workspaces/config/test/nerf-dart.js @@ -0,0 +1,44 @@ +const t = require('tap') +const nerfDart = require('../lib/nerf-dart.js') + +const cases = [ + ['//registry.npmjs.org/', [ + 'https://registry.npmjs.org', + 'https://registry.npmjs.org/package-name', + 'https://registry.npmjs.org/package-name?write=true', + 'https://registry.npmjs.org/@scope%2fpackage-name', + 'https://registry.npmjs.org/@scope%2fpackage-name?write=true', + 'https://username:password@registry.npmjs.org/package-name?write=true', + 'https://registry.npmjs.org/#hash', + 'https://registry.npmjs.org/?write=true#hash', + 'https://registry.npmjs.org/package-name?write=true#hash', + 'https://registry.npmjs.org/package-name#hash', + 'https://registry.npmjs.org/@scope%2fpackage-name?write=true#hash', + 'https://registry.npmjs.org/@scope%2fpackage-name#hash', + ]], + ['//my-couch:5984/registry/_design/app/rewrite/', [ + 'https://my-couch:5984/registry/_design/app/rewrite/', + 'https://my-couch:5984/registry/_design/app/rewrite/package-name', + 'https://my-couch:5984/registry/_design/app/rewrite/package-name?write=true', + 'https://my-couch:5984/registry/_design/app/rewrite/@scope%2fpackage-name', + 'https://my-couch:5984/registry/_design/app/rewrite/@scope%2fpackage-name?write=true', + 'https://username:password@my-couch:5984/registry/_design/app/rewrite/package-name?write=true', + 'https://my-couch:5984/registry/_design/app/rewrite/#hash', + 'https://my-couch:5984/registry/_design/app/rewrite/?write=true#hash', + 'https://my-couch:5984/registry/_design/app/rewrite/package-name?write=true#hash', + 'https://my-couch:5984/registry/_design/app/rewrite/package-name#hash', + 'https://my-couch:5984/registry/_design/app/rewrite/@scope%2fpackage-name?write=true#hash', + 'https://my-couch:5984/registry/_design/app/rewrite/@scope%2fpackage-name#hash', + ]], +] + +for (const [dart, tests] of cases) { + t.test(dart, t => { + t.plan(tests.length) + for (const url of tests) { + t.equal(nerfDart(url), dart, url) + } + }) +} + +t.throws(() => nerfDart('not a valid url')) diff --git a/workspaces/config/test/parse-field.js b/workspaces/config/test/parse-field.js new file mode 100644 index 0000000..1c4193b --- /dev/null +++ b/workspaces/config/test/parse-field.js @@ -0,0 +1,36 @@ +const parseField = require('../lib/parse-field.js') +const t = require('tap') +const { resolve } = require('path') + +t.strictSame(parseField({ a: 1 }, 'a'), { a: 1 }) + +const opts = { + platform: 'posix', + types: require('./fixtures/types.js'), + home: '/home/user', + env: { foo: 'bar' }, +} + +t.equal(parseField('', 'global', opts), true, 'boolean flag') +t.equal(parseField('true', 'global', opts), true, 'boolean flag "true"') +t.equal(parseField('false', 'global', opts), false, 'boolean flag "false"') +t.equal(parseField('null', 'access', opts), null, '"null" is null') +t.equal(parseField('undefined', 'access', opts), undefined, '"undefined" is undefined') +t.equal(parseField('blerg', 'access', opts), 'blerg', '"blerg" just is a string') +t.equal(parseField('blerg', 'message', opts), 'blerg', '"blerg" just is a string') +t.strictSame(parseField([], 'global', opts), [], 'array passed to non-list type') +t.strictSame(parseField([' dev '], 'omit', opts), ['dev'], 'array to list type') +t.strictSame(parseField('dev\n\noptional', 'omit', opts), ['dev', 'optional'], + 'double-LF delimited list, like we support in env vals') +t.equal(parseField('~/foo', 'userconfig', opts), resolve('/home/user/foo'), + 'path supports ~/') +t.equal(parseField('~\\foo', 'userconfig', { ...opts, platform: 'win32' }), + resolve('/home/user/foo'), 'path supports ~\\ on windows') +t.equal(parseField('foo', 'userconfig', opts), resolve('foo'), + 'path gets resolved') + +t.equal(parseField('1234', 'maxsockets', opts), 1234, 'number is parsed') + +t.equal(parseField('0888', 'umask', opts), '0888', + 'invalid umask is not parsed (will warn later)') +t.equal(parseField('0777', 'umask', opts), 0o777, 'valid umask is parsed') diff --git a/workspaces/config/test/set-envs.js b/workspaces/config/test/set-envs.js new file mode 100644 index 0000000..c663c22 --- /dev/null +++ b/workspaces/config/test/set-envs.js @@ -0,0 +1,212 @@ +const setEnvs = require('../lib/set-envs.js') + +const { join } = require('path') +const t = require('tap') +const defaults = require('./fixtures/defaults.js') +const definitions = require('./fixtures/definitions.js') +const { execPath } = process +const cwd = process.cwd() +const globalPrefix = join(cwd, 'global') +const localPrefix = join(cwd, 'local') +const NODE = execPath + +t.test('set envs that are not defaults and not already in env', t => { + const envConf = Object.create(defaults) + const cliConf = Object.create(envConf) + const extras = { + NODE, + INIT_CWD: cwd, + EDITOR: 'vim', + HOME: undefined, + npm_execpath: require.main.filename, + npm_node_execpath: execPath, + npm_config_global_prefix: globalPrefix, + npm_config_local_prefix: localPrefix, + } + + const env = {} + const config = { + list: [cliConf, envConf], + env, + defaults, + definitions, + execPath, + globalPrefix, + localPrefix, + } + + setEnvs(config) + t.strictSame(env, { ...extras }, 'no new environment vars to create') + envConf.call = 'me, maybe' + setEnvs(config) + t.strictSame(env, { ...extras }, 'no new environment vars to create, already in env') + delete envConf.call + cliConf.call = 'me, maybe' + setEnvs(config) + t.strictSame(env, { + ...extras, + npm_config_call: 'me, maybe', + }, 'set in env, because changed from default in cli') + envConf.call = 'me, maybe' + cliConf.call = '' + cliConf['node-options'] = 'some options for node' + setEnvs(config) + t.strictSame(env, { + ...extras, + npm_config_call: '', + npm_config_node_options: 'some options for node', + NODE_OPTIONS: 'some options for node', + }, 'set in env, because changed from default in env, back to default in cli') + t.end() +}) + +t.test('set envs that are not defaults and not already in env, array style', t => { + const envConf = Object.create(defaults) + const cliConf = Object.create(envConf) + const extras = { + NODE, + INIT_CWD: cwd, + EDITOR: 'vim', + HOME: undefined, + npm_execpath: require.main.filename, + npm_node_execpath: execPath, + npm_config_global_prefix: globalPrefix, + npm_config_local_prefix: localPrefix, + } + // make sure it's not sticky + const env = { INIT_CWD: '/some/other/path' } + const config = { + list: [cliConf, envConf], + env, + defaults, + definitions, + execPath, + globalPrefix, + localPrefix, + } + setEnvs(config) + t.strictSame(env, { ...extras }, 'no new environment vars to create') + + envConf.omit = ['dev'] + setEnvs(config) + t.strictSame(env, { ...extras }, 'no new environment vars to create, already in env') + delete envConf.omit + cliConf.omit = ['dev', 'optional'] + setEnvs(config) + t.strictSame(env, { + ...extras, + npm_config_omit: 'dev\n\noptional', + }, 'set in env, because changed from default in cli') + envConf.omit = ['optional', 'peer'] + cliConf.omit = [] + setEnvs(config) + t.strictSame(env, { + ...extras, + npm_config_omit: '', + }, 'set in env, because changed from default in env, back to default in cli') + t.end() +}) + +t.test('set envs that are not defaults and not already in env, boolean edition', t => { + const envConf = Object.create(defaults) + const cliConf = Object.create(envConf) + const extras = { + NODE, + INIT_CWD: cwd, + EDITOR: 'vim', + HOME: undefined, + npm_execpath: require.main.filename, + npm_node_execpath: execPath, + npm_config_global_prefix: globalPrefix, + npm_config_local_prefix: localPrefix, + } + + const env = {} + const config = { + list: [cliConf, envConf], + env, + defaults, + definitions, + execPath, + globalPrefix, + localPrefix, + } + setEnvs(config) + t.strictSame(env, { ...extras }, 'no new environment vars to create') + envConf.audit = false + setEnvs(config) + t.strictSame(env, { ...extras }, 'no new environment vars to create, already in env') + delete envConf.audit + cliConf.audit = false + cliConf.ignoreObjects = { + some: { object: 12345 }, + } + setEnvs(config) + t.strictSame(env, { + ...extras, + npm_config_audit: '', + }, 'set in env, because changed from default in cli') + envConf.audit = false + cliConf.audit = true + setEnvs(config) + t.strictSame(env, { + ...extras, + npm_config_audit: 'true', + }, 'set in env, because changed from default in env, back to default in cli') + t.end() +}) + +t.test('dont set npm_execpath if require.main.filename is not set', t => { + const { filename } = require.main + t.teardown(() => require.main.filename = filename) + require.main.filename = null + // also, don't set editor + const d = { ...defaults, editor: null } + const envConf = Object.create(d) + const cliConf = Object.create(envConf) + const env = { DESTDIR: '/some/dest' } + const config = { + list: [cliConf, envConf], + env, + defaults: d, + definitions, + execPath, + globalPrefix, + localPrefix, + } + setEnvs(config) + t.equal(env.npm_execpath, undefined, 'did not set npm_execpath') + t.end() +}) + +t.test('dont set configs marked as envExport:false', t => { + const envConf = Object.create(defaults) + const cliConf = Object.create(envConf) + const extras = { + NODE, + INIT_CWD: cwd, + EDITOR: 'vim', + HOME: undefined, + npm_execpath: require.main.filename, + npm_node_execpath: execPath, + npm_config_global_prefix: globalPrefix, + npm_config_local_prefix: localPrefix, + } + + const env = {} + const config = { + list: [cliConf, envConf], + env, + defaults, + definitions, + execPath, + globalPrefix, + localPrefix, + } + setEnvs(config) + t.strictSame(env, { ...extras }, 'no new environment vars to create') + cliConf.methane = 'CO2' + setEnvs(config) + t.strictSame(env, { ...extras }, 'not exported, because envExport=false') + t.end() +}) diff --git a/workspaces/config/test/type-defs.js b/workspaces/config/test/type-defs.js new file mode 100644 index 0000000..2ce0ac9 --- /dev/null +++ b/workspaces/config/test/type-defs.js @@ -0,0 +1,22 @@ +const typeDefs = require('../lib/type-defs.js') +const t = require('tap') +const { + semver: { + validate: validateSemver, + }, + path: { + validate: validatePath, + }, +} = typeDefs +const { resolve } = require('path') + +const d = { semver: 'foobar', somePath: true } +t.equal(validateSemver(d, 'semver', 'foobar'), false) +t.equal(validateSemver(d, 'semver', 'v1.2.3'), undefined) +t.equal(d.semver, '1.2.3') +t.equal(validatePath(d, 'somePath', true), false) +t.equal(validatePath(d, 'somePath', false), false) +t.equal(validatePath(d, 'somePath', null), false) +t.equal(validatePath(d, 'somePath', 1234), false) +t.equal(validatePath(d, 'somePath', 'false'), true) +t.equal(d.somePath, resolve('false')) diff --git a/workspaces/config/test/type-description.js b/workspaces/config/test/type-description.js new file mode 100644 index 0000000..d487c11 --- /dev/null +++ b/workspaces/config/test/type-description.js @@ -0,0 +1,14 @@ +const t = require('tap') +const typeDescription = require('../lib/type-description.js') +const types = require('./fixtures/types.js') +const descriptions = {} +for (const [name, type] of Object.entries(types)) { + const desc = typeDescription(type) + if (name === 'local-address') { + t.strictSame(desc.sort(), type.filter(t => t !== undefined).sort()) + } else { + descriptions[name] = desc + } +} + +t.matchSnapshot(descriptions) diff --git a/workspaces/libnpmaccess/.eslintrc.js b/workspaces/libnpmaccess/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/libnpmaccess/.eslintrc.js +++ b/workspaces/libnpmaccess/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/libnpmaccess/.gitignore b/workspaces/libnpmaccess/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/libnpmaccess/.gitignore +++ b/workspaces/libnpmaccess/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/libnpmaccess/.npmrc b/workspaces/libnpmaccess/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/libnpmaccess/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/libnpmaccess/CHANGELOG.md b/workspaces/libnpmaccess/CHANGELOG.md index 6d8036a..4a4da5a 100644 --- a/workspaces/libnpmaccess/CHANGELOG.md +++ b/workspaces/libnpmaccess/CHANGELOG.md @@ -1,6 +1,84 @@ -# Change Log +# Changelog + +## [7.0.1](https://github.com/npm/cli/compare/libnpmaccess-v7.0.0...libnpmaccess-v7.0.1) (2022-12-07) + +### Dependencies + +* [`0a3fe00`](https://github.com/npm/cli/commit/0a3fe000e2723ae6fdb8b1d3154fd3835057c992) [#5933](https://github.com/npm/cli/pull/5933) `minipass@4.0.0` +* [`fee9b66`](https://github.com/npm/cli/commit/fee9b6686892a1c7f976c36ddd5d89b70c416817) `npm-registry-fetch@14.0.3` +* [`875bd56`](https://github.com/npm/cli/commit/875bd56c33ca5eef80c2a50a11808445f2a39a2a) `npm-package-arg@10.1.0` + +## [7.0.0](https://github.com/npm/cli/compare/libnpmaccess-v7.0.0-pre.2...libnpmaccess-v7.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +## [7.0.0-pre.2](https://github.com/npm/cli/compare/libnpmaccess-v7.0.0-pre.1...libnpmaccess-v7.0.0-pre.2) (2022-10-19) + +### Dependencies + +* [`2008ea6`](https://github.com/npm/cli/commit/2008ea6a807acbd97912799adfe97f276202cea6) `npm-package-arg@10.0.0`, `pacote@15.0.2` +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies + +## [7.0.0-pre.1](https://github.com/npm/cli/compare/libnpmaccess-v7.0.0-pre.0...libnpmaccess-v7.0.0-pre.1) (2022-09-14) + +### ⚠️ BREAKING CHANGES + +* the api for libnpmaccess is different now + +### Features + +* [`854521b`](https://github.com/npm/cli/commit/854521baa49ef88ff9586ec2cc5f1fbaee7fa364) rewrite: Rewrite libnpmaccess (@wraithgar) + +## [7.0.0-pre.0](https://github.com/npm/cli/compare/libnpmaccess-v6.0.4...libnpmaccess-v7.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + +## [6.0.4](https://github.com/npm/cli/compare/libnpmaccess-v6.0.3...libnpmaccess-v6.0.4) (2022-08-31) + +### Dependencies + + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` + +### [6.0.3](https://github.com/npm/cli/compare/libnpmaccess-v6.0.2...libnpmaccess-v6.0.3) (2022-04-06) + + +### Bug Fixes + +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/template-oss@3.2.1 ([aac01b8](https://github.com/npm/cli/commit/aac01b89caf6336a2eb34d696296303cdadd5c08)) +* @npmcli/template-oss@3.2.2 ([#4639](https://github.com/npm/cli/issues/4639)) ([a59fd2c](https://github.com/npm/cli/commit/a59fd2cb863245fce56f96c90ac854e62c5c4d6f)) + +### [6.0.2](https://www.github.com/npm/cli/compare/libnpmaccess-v6.0.1...libnpmaccess-v6.0.2) (2022-03-15) + + +### Documentation + +* standardize changelog heading ([#4510](https://www.github.com/npm/cli/issues/4510)) ([91f03ee](https://www.github.com/npm/cli/commit/91f03ee618bc635f9cfbded735fe98bbfa9d643f)) + + +### Dependencies + +* npm-package-arg@9.0.1 ([9555a5f](https://www.github.com/npm/cli/commit/9555a5f1d135aa1b8f7374273403efe41e99ee26)) + +### [6.0.1](https://www.github.com/npm/cli/compare/libnpmaccess-vlibnpmaccess@6.0.0...libnpmaccess-v6.0.1) (2022-03-03) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) -<a name="4.0.0"></a> ## [4.0.0](https://github.com/npm/libnpmaccess/compare/v3.0.2...v4.0.0) (2020-03-02) ### BREAKING CHANGES diff --git a/workspaces/libnpmaccess/README.md b/workspaces/libnpmaccess/README.md index c079344..060016b 100644 --- a/workspaces/libnpmaccess/README.md +++ b/workspaces/libnpmaccess/README.md @@ -2,246 +2,92 @@ [![npm version](https://img.shields.io/npm/v/libnpmaccess.svg)](https://npm.im/libnpmaccess) [![license](https://img.shields.io/npm/l/libnpmaccess.svg)](https://npm.im/libnpmaccess) -[![GitHub Actions](https://github.com/npm/libnpmaccess/workflows/Node%20CI/badge.svg)](https://github.com/npm/libnpmaccess/actions?query=workflow%3A%22Node+CI%22) -[![Coverage Status](https://coveralls.io/repos/github/npm/libnpmaccess/badge.svg?branch=latest)](https://coveralls.io/github/npm/libnpmaccess?branch=latest) +[![CI - libnpmaccess](https://github.com/npm/cli/actions/workflows/ci-libnpmaccess.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-libnpmaccess.yml) [`libnpmaccess`](https://github.com/npm/libnpmaccess) is a Node.js library that provides programmatic access to the guts of the npm CLI's `npm -access` command and its various subcommands. This includes managing account 2FA, -listing packages and permissions, looking at package collaborators, and defining +access` command. This includes managing account mfa settings, listing +packages and permissions, looking at package collaborators, and defining package permissions for users, orgs, and teams. ## Example ```javascript const access = require('libnpmaccess') +const opts = { '//registry.npmjs.org/:_authToken: 'npm_token } // List all packages @zkat has access to on the npm registry. -console.log(Object.keys(await access.lsPackages('zkat'))) +console.log(Object.keys(await access.getPackages('zkat', opts))) ``` -## Table of Contents - -* [Installing](#install) -* [Example](#example) -* [Contributing](#contributing) -* [API](#api) - * [access opts](#opts) - * [`public()`](#public) - * [`restricted()`](#restricted) - * [`grant()`](#grant) - * [`revoke()`](#revoke) - * [`tfaRequired()`](#tfa-required) - * [`tfaNotRequired()`](#tfa-not-required) - * [`lsPackages()`](#ls-packages) - * [`lsPackages.stream()`](#ls-packages-stream) - * [`lsCollaborators()`](#ls-collaborators) - * [`lsCollaborators.stream()`](#ls-collaborators-stream) - -### Install - -`$ npm install libnpmaccess` - ### API -#### <a name="opts"></a> `opts` for `libnpmaccess` commands +#### `opts` for all `libnpmaccess` commands `libnpmaccess` uses [`npm-registry-fetch`](https://npm.im/npm-registry-fetch). -All options are passed through directly to that library, so please refer to [its -own `opts` + +All options are passed through directly to that library, so please refer +to [its own `opts` documentation](https://www.npmjs.com/package/npm-registry-fetch#fetch-options) for options that can be passed in. -A couple of options of note for those in a hurry: - -* `opts.token` - can be passed in and will be used as the authentication token for the registry. For other ways to pass in auth details, see the n-r-f docs. -* `opts.otp` - certain operations will require an OTP token to be passed in. If a `libnpmaccess` command fails with `err.code === EOTP`, please retry the request with `{otp: <2fa token>}` - -#### <a name="public"></a> `> access.public(spec, [opts]) -> Promise<Boolean>` +#### `spec` parameter for all `libnpmaccess` commands `spec` must be an [`npm-package-arg`](https://npm.im/npm-package-arg)-compatible registry spec. -Makes package described by `spec` public. +#### `access.getCollaborators(spec, opts) -> Promise<Object>` -##### Example +Gets collaborators for a given package -```javascript -await access.public('@foo/bar', {token: 'myregistrytoken'}) -// `@foo/bar` is now public -``` +#### `access.getPackages(user|scope|team, opts) -> Promise<Object>` -#### <a name="restricted"></a> `> access.restricted(spec, [opts]) -> Promise<Boolean>` +Gets all packages for a given user, scope, or team. -`spec` must be an [`npm-package-arg`](https://npm.im/npm-package-arg)-compatible -registry spec. +Teams should be in the format `scope:team` or `@scope:team` -Makes package described by `spec` private/restricted. +Users and scopes can be in the format `@scope` or `scope` -##### Example +#### `access.getVisibility(spec, opts) -> Promise<Object>` -```javascript -await access.restricted('@foo/bar', {token: 'myregistrytoken'}) -// `@foo/bar` is now private -``` +Gets the visibility of a given package -#### <a name="grant"></a> `> access.grant(spec, team, permissions, [opts]) -> Promise<Boolean>` +#### `access.removePermissions(team, spec, opts) -> Promise<Boolean>` -`spec` must be an [`npm-package-arg`](https://npm.im/npm-package-arg)-compatible -registry spec. `team` must be a fully-qualified team name, in the `scope:team` -format, with or without the `@` prefix, and the team must be a valid team within -that scope. `permissions` must be one of `'read-only'` or `'read-write'`. +Removes the access for a given team to a package. -Grants `read-only` or `read-write` permissions for a certain package to a team. +Teams should be in the format `scope:team` or `@scope:team` -##### Example +#### `access.setAccess(package, access, opts) -> Promise<Boolean>` -```javascript -await access.grant('@foo/bar', '@foo:myteam', 'read-write', { - token: 'myregistrytoken' -}) -// `@foo/bar` is now read/write enabled for the @foo:myteam team. -``` +Sets access level for package described by `spec`. -#### <a name="revoke"></a> `> access.revoke(spec, team, [opts]) -> Promise<Boolean>` +The npm registry accepts the following `access` levels: -`spec` must be an [`npm-package-arg`](https://npm.im/npm-package-arg)-compatible -registry spec. `team` must be a fully-qualified team name, in the `scope:team` -format, with or without the `@` prefix, and the team must be a valid team within -that scope. `permissions` must be one of `'read-only'` or `'read-write'`. +`public`: package is public +`private`: package is private -Removes access to a package from a certain team. +The npm registry also only allows scoped packages to have their access +level set. -##### Example +#### access.setMfa(spec, level, opts) -> Promise<Boolean>` -```javascript -await access.revoke('@foo/bar', '@foo:myteam', { - token: 'myregistrytoken' -}) -// @foo:myteam can no longer access `@foo/bar` -``` +Sets the publishing mfa requirements for a given package. Level must be one of the +following -#### <a name="tfa-required"></a> `> access.tfaRequired(spec, [opts]) -> Promise<Boolean>` +`none`: mfa is not required to publish this package. +`publish`: mfa is required to publish this package, automation tokens +cannot be used to publish. +`automation`: mfa is required to publish this package, automation tokens +may also be used for publishing from continuous integration workflows. -`spec` must be an [`npm-package-arg`](https://npm.im/npm-package-arg)-compatible -registry spec. +#### access.setPermissions(team, spec, permssions, opts) -> Promise<Boolean>` -Makes it so publishing or managing a package requires using 2FA tokens to -complete operations. +Sets permissions levels for a given team to a package. -##### Example +Teams should be in the format `scope:team` or `@scope:team` -```javascript -await access.tfaRequires('lodash', {token: 'myregistrytoken'}) -// Publishing or changing dist-tags on `lodash` now require OTP to be enabled. -``` +The npm registry accepts the following `permissions`: -#### <a name="tfa-not-required"></a> `> access.tfaNotRequired(spec, [opts]) -> Promise<Boolean>` - -`spec` must be an [`npm-package-arg`](https://npm.im/npm-package-arg)-compatible -registry spec. - -Disabled the package-level 2FA requirement for `spec`. Note that you will need -to pass in an `otp` token in `opts` in order to complete this operation. - -##### Example - -```javascript -await access.tfaNotRequired('lodash', {otp: '123654', token: 'myregistrytoken'}) -// Publishing or editing dist-tags on `lodash` no longer requires OTP to be -// enabled. -``` - -#### <a name="ls-packages"></a> `> access.lsPackages(entity, [opts]) -> Promise<Object | null>` - -`entity` must be either a valid org or user name, or a fully-qualified team name -in the `scope:team` format, with or without the `@` prefix. - -Lists out packages a user, org, or team has access to, with corresponding -permissions. Packages that the access token does not have access to won't be -listed. - -In order to disambiguate between users and orgs, two requests may end up being -made when listing orgs or users. - -For a streamed version of these results, see -[`access.lsPackages.stream()`](#ls-package-stream). - -##### Example - -```javascript -await access.lsPackages('zkat', { - token: 'myregistrytoken' -}) -// Lists all packages `@zkat` has access to on the registry, and the -// corresponding permissions. -``` - -#### <a name="ls-packages-stream"></a> `> access.lsPackages.stream(scope, [team], [opts]) -> Stream` - -`entity` must be either a valid org or user name, or a fully-qualified team name -in the `scope:team` format, with or without the `@` prefix. - -Streams out packages a user, org, or team has access to, with corresponding -permissions, with each stream entry being formatted like `[packageName, -permissions]`. Packages that the access token does not have access to won't be -listed. - -In order to disambiguate between users and orgs, two requests may end up being -made when listing orgs or users. - -The returned stream is a valid `asyncIterator`. - -##### Example - -```javascript -for await (let [pkg, perm] of access.lsPackages.stream('zkat')) { - console.log('zkat has', perm, 'access to', pkg) -} -// zkat has read-write access to eggplant -// zkat has read-only access to @npmcorp/secret -``` - -#### <a name="ls-collaborators"></a> `> access.lsCollaborators(spec, [user], [opts]) -> Promise<Object | null>` - -`spec` must be an [`npm-package-arg`](https://npm.im/npm-package-arg)-compatible -registry spec. `user` must be a valid user name, with or without the `@` -prefix. - -Lists out access privileges for a certain package. Will only show permissions -for packages to which you have at least read access. If `user` is passed in, the -list is filtered only to teams _that_ user happens to belong to. - -For a streamed version of these results, see [`access.lsCollaborators.stream()`](#ls-collaborators-stream). - -##### Example - -```javascript -await access.lsCollaborators('@npm/foo', 'zkat', { - token: 'myregistrytoken' -}) -// Lists all teams with access to @npm/foo that @zkat belongs to. -``` - -#### <a name="ls-collaborators-stream"></a> `> access.lsCollaborators.stream(spec, [user], [opts]) -> Stream` - -`spec` must be an [`npm-package-arg`](https://npm.im/npm-package-arg)-compatible -registry spec. `user` must be a valid user name, with or without the `@` -prefix. - -Stream out access privileges for a certain package, with each entry in `[user, -permissions]` format. Will only show permissions for packages to which you have -at least read access. If `user` is passed in, the list is filtered only to teams -_that_ user happens to belong to. - -The returned stream is a valid `asyncIterator`. - -##### Example - -```javascript -for await (let [usr, perm] of access.lsCollaborators.stream('npm')) { - console.log(usr, 'has', perm, 'access to npm') -} -// zkat has read-write access to npm -// iarna has read-write access to npm -``` +`read-only`: Read only permissions +`read-write`: Read and write (aka publish) permissions diff --git a/workspaces/libnpmaccess/SECURITY.md b/workspaces/libnpmaccess/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/libnpmaccess/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/libnpmaccess/lib/index.js b/workspaces/libnpmaccess/lib/index.js index 925f742..fca0e47 100644 --- a/workspaces/libnpmaccess/lib/index.js +++ b/workspaces/libnpmaccess/lib/index.js @@ -1,186 +1,140 @@ 'use strict' -const Minipass = require('minipass') const npa = require('npm-package-arg') const npmFetch = require('npm-registry-fetch') -const validate = require('aproba') -const eu = encodeURIComponent -const npar = spec => { +const npar = (spec) => { spec = npa(spec) if (!spec.registry) { - throw new Error('`spec` must be a registry spec') + throw new Error('must use package name only') } return spec } -const mapJSON = (value, [key]) => { - if (value === 'read') { - return [key, 'read-only'] - } else if (value === 'write') { - return [key, 'read-write'] - } else { - return [key, value] + +const parseTeam = (scopeTeam) => { + let slice = 0 + if (scopeTeam.startsWith('@')) { + slice = 1 } -} - -const cmd = module.exports = {} - -cmd.public = (spec, opts) => setAccess(spec, 'public', opts) -cmd.restricted = (spec, opts) => setAccess(spec, 'restricted', opts) -function setAccess (spec, access, opts = {}) { - return Promise.resolve().then(() => { - spec = npar(spec) - validate('OSO', [spec, access, opts]) - const uri = `/-/package/${eu(spec.name)}/access` - return npmFetch(uri, { - ...opts, - method: 'POST', - body: { access }, - spec, - }).then(() => true) - }) -} - -cmd.grant = (spec, entity, permissions, opts = {}) => { - return Promise.resolve().then(() => { - spec = npar(spec) - const { scope, team } = splitEntity(entity) - validate('OSSSO', [spec, scope, team, permissions, opts]) - if (permissions !== 'read-write' && permissions !== 'read-only') { - throw new Error( - '`permissions` must be `read-write` or `read-only`. Got `' - + permissions + '` instead') - } - const uri = `/-/team/${eu(scope)}/${eu(team)}/package` - return npmFetch(uri, { - ...opts, - method: 'PUT', - body: { package: spec.name, permissions }, - scope, - spec, - ignoreBody: true, - }) - .then(() => true) - }) -} - -cmd.revoke = (spec, entity, opts = {}) => { - return Promise.resolve().then(() => { - spec = npar(spec) - const { scope, team } = splitEntity(entity) - validate('OSSO', [spec, scope, team, opts]) - const uri = `/-/team/${eu(scope)}/${eu(team)}/package` - return npmFetch(uri, { - ...opts, - method: 'DELETE', - body: { package: spec.name }, - scope, - spec, - ignoreBody: true, - }) - .then(() => true) - }) -} - -cmd.lsPackages = (entity, opts) => { - return cmd.lsPackages.stream(entity, opts) - .collect() - .then(data => { - return data.reduce((acc, [key, val]) => { - if (!acc) { - acc = {} - } - acc[key] = val - return acc - }, null) - }) -} - -cmd.lsPackages.stream = (entity, opts = {}) => { - validate('SO|SZ', [entity, opts]) - const { scope, team } = splitEntity(entity) - let uri - if (team) { - uri = `/-/team/${eu(scope)}/${eu(team)}/package` - } else { - uri = `/-/org/${eu(scope)}/package` - } - const nextOpts = { - ...opts, - query: { format: 'cli' }, - mapJSON, - } - const ret = new Minipass({ objectMode: true }) - npmFetch.json.stream(uri, '*', nextOpts) - .on('error', err => { - if (err.code === 'E404' && !team) { - uri = `/-/user/${eu(scope)}/package` - npmFetch.json.stream(uri, '*', nextOpts) - .on('error', err => ret.emit('error', err)) - .pipe(ret) - } else { - ret.emit('error', err) - } - }) - .pipe(ret) - return ret -} - -cmd.lsCollaborators = (spec, user, opts) => { - return Promise.resolve().then(() => { - return cmd.lsCollaborators.stream(spec, user, opts) - .collect() - .then(data => { - return data.reduce((acc, [key, val]) => { - if (!acc) { - acc = {} - } - acc[key] = val - return acc - }, null) - }) - }) -} - -cmd.lsCollaborators.stream = (spec, user, opts) => { - if (typeof user === 'object' && !opts) { - opts = user - user = undefined - } else if (!opts) { - opts = {} - } - spec = npar(spec) - validate('OSO|OZO', [spec, user, opts]) - const uri = `/-/package/${eu(spec.name)}/collaborators` - return npmFetch.json.stream(uri, '*', { - ...opts, - query: { format: 'cli', user: user || undefined }, - mapJSON, - }) -} - -cmd.tfaRequired = (spec, opts) => setRequires2fa(spec, true, opts) -cmd.tfaNotRequired = (spec, opts) => setRequires2fa(spec, false, opts) -function setRequires2fa (spec, required, opts = {}) { - return Promise.resolve().then(() => { - spec = npar(spec) - validate('OBO', [spec, required, opts]) - const uri = `/-/package/${eu(spec.name)}/access` - return npmFetch(uri, { - ...opts, - method: 'POST', - body: { publish_requires_tfa: required }, - spec, - ignoreBody: true, - }).then(() => true) - }) -} - -cmd.edit = () => { - throw new Error('Not implemented yet') -} - -function splitEntity (entity = '') { - const [, scope, team] = entity.match(/^@?([^:]+)(?::(.*))?$/) || [] + const [scope, team] = scopeTeam.slice(slice).split(':').map(encodeURIComponent) return { scope, team } } + +const getPackages = async (scopeTeam, opts) => { + const { scope, team } = parseTeam(scopeTeam) + + let uri + if (team) { + uri = `/-/team/${scope}/${team}/package` + } else { + uri = `/-/org/${scope}/package` + } + try { + return await npmFetch.json(uri, opts) + } catch (err) { + if (err.code === 'E404') { + uri = `/-/user/${scope}/package` + return npmFetch.json(uri, opts) + } + throw err + } +} + +const getCollaborators = async (pkg, opts) => { + const spec = npar(pkg) + const uri = `/-/package/${spec.escapedName}/collaborators` + return npmFetch.json(uri, opts) +} + +const getVisibility = async (pkg, opts) => { + const spec = npar(pkg) + const uri = `/-/package/${spec.escapedName}/visibility` + return npmFetch.json(uri, opts) +} + +const setAccess = async (pkg, access, opts) => { + const spec = npar(pkg) + const uri = `/-/package/${spec.escapedName}/access` + await npmFetch(uri, { + ...opts, + method: 'POST', + body: { access }, + spec, + ignoreBody: true, + }) + return true +} + +const setMfa = async (pkg, level, opts) => { + const spec = npar(pkg) + const body = {} + switch (level) { + case 'none': + body.publish_requires_tfa = false + break + case 'publish': + // tfa is required, automation tokens can not override tfa + body.publish_requires_tfa = true + body.automation_token_overrides_tfa = false + break + case 'automation': + // tfa is required, automation tokens can override tfa + body.publish_requires_tfa = true + body.automation_token_overrides_tfa = true + break + default: + throw new Error(`Invalid mfa setting ${level}`) + } + const uri = `/-/package/${spec.escapedName}/access` + await npmFetch(uri, { + ...opts, + method: 'POST', + body, + spec, + ignoreBody: true, + }) + return true +} + +const setPermissions = async (scopeTeam, pkg, permissions, opts) => { + const spec = npar(pkg) + const { scope, team } = parseTeam(scopeTeam) + if (!scope || !team) { + throw new Error('team must be in format `scope:team`') + } + const uri = `/-/team/${scope}/${team}/package` + await npmFetch(uri, { + ...opts, + method: 'PUT', + body: { package: spec.name, permissions }, + scope, + spec, + ignoreBody: true, + }) + return true +} + +const removePermissions = async (scopeTeam, pkg, opts) => { + const spec = npar(pkg) + const { scope, team } = parseTeam(scopeTeam) + const uri = `/-/team/${scope}/${team}/package` + await npmFetch(uri, { + ...opts, + method: 'DELETE', + body: { package: spec.name }, + scope, + spec, + ignoreBody: true, + }) + return true +} + +module.exports = { + getCollaborators, + getPackages, + getVisibility, + removePermissions, + setAccess, + setMfa, + setPermissions, +} diff --git a/workspaces/libnpmaccess/package.json b/workspaces/libnpmaccess/package.json index 760da6c..1e27f79 100644 --- a/workspaces/libnpmaccess/package.json +++ b/workspaces/libnpmaccess/package.json @@ -1,50 +1,53 @@ { "name": "libnpmaccess", - "version": "5.0.1", + "version": "7.0.1", "description": "programmatic library for `npm access` commands", "author": "GitHub Inc.", "license": "ISC", "main": "lib/index.js", "scripts": { - "preversion": "npm test", - "postversion": "npm publish", - "postpublish": "git push origin --follow-tags", - "lint": "eslint '**/*.js'", + "lint": "eslint \"**/*.js\"", "test": "tap", - "postlint": "npm-template-check", - "lintfix": "npm run lint -- --fix", - "prepublishOnly": "git push origin --follow-tags", + "postlint": "template-oss-check", + "lintfix": "node ../.. run lint -- --fix", "snap": "tap", - "posttest": "npm run lint" + "posttest": "node ../.. run lint", + "template-oss-apply": "template-oss-apply --force" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "nock": "^12.0.1", - "tap": "^15.1.0" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/mock-registry": "^1.0.0", + "@npmcli/template-oss": "4.11.0", + "nock": "^13.2.4", + "tap": "^16.3.2" }, "repository": { "type": "git", - "url": "https://github.com/npm/libnpmaccess.git" + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/libnpmaccess" }, "bugs": "https://github.com/npm/libnpmaccess/issues", "homepage": "https://npmjs.com/package/libnpmaccess", "dependencies": { - "aproba": "^2.0.0", - "minipass": "^3.1.1", - "npm-package-arg": "^8.1.2", - "npm-registry-fetch": "^12.0.1" + "npm-package-arg": "^10.1.0", + "npm-registry-fetch": "^14.0.3" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - }, - "tap": { - "check-coverage": true + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/workspaces/libnpmaccess/test/index.js b/workspaces/libnpmaccess/test/index.js index 7417ab5..48049e7 100644 --- a/workspaces/libnpmaccess/test/index.js +++ b/workspaces/libnpmaccess/test/index.js @@ -1,423 +1,167 @@ 'use strict' const t = require('tap') -const tnock = require('./fixtures/tnock.js') +const MockRegistry = require('@npmcli/mock-registry') const access = require('../lib/index.js') -const REG = 'http://localhost:1337' -const OPTS = { - registry: REG, +const opts = { + registry: 'http://localhost:1337', } -t.test('access public', t => { - tnock(t, REG).post( - '/-/package/%40foo%2Fbar/access', { access: 'public' } - ).reply(200) - return access.public('@foo/bar', OPTS).then(ret => { - t.same(ret, true, 'request succeeded') +const pkg = '@npmcli/libnpmaccess-test' +const team = 'npm:test-team' +const orgUser = 'test-user' +const mockRegistry = (t) => { + return new MockRegistry({ + tap: t, + strict: true, + registry: 'http://localhost:1337', }) -}) +} -t.test('access public - failure', t => { - tnock(t, REG).post( - '/-/package/%40foo%2Fbar/access', { access: 'public' } - ).reply(418) - return access.public('@foo/bar', OPTS) - .catch(err => { - t.equal(err.statusCode, 418, 'fails with code from registry') - }) -}) - -t.test('access restricted', t => { - tnock(t, REG).post( - '/-/package/%40foo%2Fbar/access', { access: 'restricted' } - ).reply(200) - return access.restricted('@foo/bar', OPTS).then(ret => { - t.same(ret, true, 'request succeeded') - }) -}) - -t.test('access restricted - failure', t => { - tnock(t, REG).post( - '/-/package/%40foo%2Fbar/access', { access: 'restricted' } - ).reply(418) - return access.restricted('@foo/bar', OPTS) - .catch(err => { - t.equal(err.statusCode, 418, 'fails with code from registry') - }) -}) - -t.test('access 2fa-required', t => { - tnock(t, REG).post('/-/package/%40foo%2Fbar/access', { - publish_requires_tfa: true, - }).reply(200, { ok: true }) - return access.tfaRequired('@foo/bar', OPTS).then(ret => { - t.same(ret, true, 'request succeeded') - }) -}) - -t.test('access 2fa-not-required', t => { - tnock(t, REG).post('/-/package/%40foo%2Fbar/access', { - publish_requires_tfa: false, - }).reply(200, { ok: true }) - return access.tfaNotRequired('@foo/bar', OPTS).then(ret => { - t.same(ret, true, 'request succeeded') - }) -}) - -t.test('access grant basic read-write', t => { - tnock(t, REG).put('/-/team/myorg/myteam/package', { - package: '@foo/bar', - permissions: 'read-write', - }).reply(201) - return access.grant( - '@foo/bar', 'myorg:myteam', 'read-write', OPTS - ).then(ret => { - t.same(ret, true, 'request succeeded') - }) -}) - -t.test('access grant basic read-only', t => { - tnock(t, REG).put('/-/team/myorg/myteam/package', { - package: '@foo/bar', - permissions: 'read-only', - }).reply(201) - return access.grant( - '@foo/bar', 'myorg:myteam', 'read-only', OPTS - ).then(ret => { - t.same(ret, true, 'request succeeded') - }) -}) - -t.test('access grant bad perm', t => { - return access.grant( - '@foo/bar', 'myorg:myteam', 'unknown', OPTS - ).then(ret => { - throw new Error('should not have succeeded') - }, err => { - t.match( - err.message, - /must be.*read-write.*read-only/, - 'only read-write and read-only are accepted' +t.test('getCollaborators', t => { + t.test('success', async t => { + const registry = mockRegistry(t) + const collaborators = { + 'npm:myteam': 'write', + 'npm:anotherteam': 'read', + 'npm:thirdteam': 'special-case', + } + registry.getCollaborators({ spec: pkg, collaborators }) + await t.resolves( + access.getCollaborators(pkg, opts), + collaborators ) }) -}) -t.test('access grant no entity', t => { - return access.grant( - '@foo/bar', undefined, 'read-write', OPTS - ).then(ret => { - throw new Error('should not have succeeded') - }, err => { - t.match( - err.message, - /Expected string/, - 'passing undefined entity gives useful error' - ) + t.test('non registry package', async t => { + await t.rejects(access.getCollaborators('./local', opts), /package name only/) }) -}) - -t.test('access grant basic unscoped', t => { - tnock(t, REG).put('/-/team/myorg/myteam/package', { - package: 'bar', - permissions: 'read-write', - }).reply(201) - return access.grant( - 'bar', 'myorg:myteam', 'read-write', OPTS - ).then(ret => { - t.same(ret, true, 'request succeeded') - }) -}) - -t.test('access grant no opts passed', t => { - // NOTE: mocking real url, because no opts variable means `registry` value - // will be defauled to real registry url - tnock(t, 'https://registry.npmjs.org') - .put('/-/team/myorg/myteam/package', { - package: 'bar', - permissions: 'read-write', - }) - .reply(201) - return access.grant('bar', 'myorg:myteam', 'read-write') - .then(ret => { - t.equal(ret, true, 'request succeeded') - }) -}) - -t.test('access revoke basic', t => { - tnock(t, REG).delete('/-/team/myorg/myteam/package', { - package: '@foo/bar', - }).reply(200) - return access.revoke('@foo/bar', 'myorg:myteam', OPTS).then(ret => { - t.same(ret, true, 'request succeeded') - }) -}) - -t.test('access revoke basic unscoped', t => { - tnock(t, REG).delete('/-/team/myorg/myteam/package', { - package: 'bar', - }).reply(200, { accessChanged: true }) - return access.revoke('bar', 'myorg:myteam', OPTS).then(ret => { - t.same(ret, true, 'request succeeded') - }) -}) - -t.test('access revoke no opts passed', t => { - // NOTE: mocking real url, because no opts variable means `registry` value - // will be defauled to real registry url - tnock(t, 'https://registry.npmjs.org') - .delete('/-/team/myorg/myteam/package', { - package: 'bar', - }) - .reply(201) - return access.revoke('bar', 'myorg:myteam') - .then(ret => { - t.equal(ret, true, 'request succeeded') - }) -}) - -t.test('ls-packages on team', t => { - const serverPackages = { - '@foo/bar': 'write', - '@foo/util': 'read', - '@foo/other': 'shrödinger', - } - const clientPackages = { - '@foo/bar': 'read-write', - '@foo/util': 'read-only', - '@foo/other': 'shrödinger', - } - tnock(t, REG).get( - '/-/team/myorg/myteam/package?format=cli' - ).reply(200, serverPackages) - return access.lsPackages('myorg:myteam', OPTS).then(data => { - t.same(data, clientPackages, 'got client package info') - }) -}) - -t.test('ls-packages on org', t => { - const serverPackages = { - '@foo/bar': 'write', - '@foo/util': 'read', - '@foo/other': 'shrödinger', - } - const clientPackages = { - '@foo/bar': 'read-write', - '@foo/util': 'read-only', - '@foo/other': 'shrödinger', - } - tnock(t, REG).get( - '/-/org/myorg/package?format=cli' - ).reply(200, serverPackages) - return access.lsPackages('myorg', OPTS).then(data => { - t.same(data, clientPackages, 'got client package info') - }) -}) - -t.test('ls-packages on user', t => { - const serverPackages = { - '@foo/bar': 'write', - '@foo/util': 'read', - '@foo/other': 'shrödinger', - } - const clientPackages = { - '@foo/bar': 'read-write', - '@foo/util': 'read-only', - '@foo/other': 'shrödinger', - } - const srv = tnock(t, REG) - srv.get('/-/org/myuser/package?format=cli').reply(404, { error: 'not found' }) - srv.get('/-/user/myuser/package?format=cli').reply(200, serverPackages) - return access.lsPackages('myuser', OPTS).then(data => { - t.same(data, clientPackages, 'got client package info') - }) -}) - -t.test('ls-packages error on team', t => { - tnock(t, REG).get('/-/team/myorg/myteam/package?format=cli').reply(404) - return access.lsPackages('myorg:myteam', OPTS).then( - () => { - throw new Error('should not have succeeded') - }, - err => t.equal(err.code, 'E404', 'spit out 404 directly if team provided') - ) -}) - -t.test('ls-packages error on user', t => { - const srv = tnock(t, REG) - srv.get('/-/org/myuser/package?format=cli').reply(404, { error: 'not found' }) - srv.get('/-/user/myuser/package?format=cli').reply(404, { error: 'not found' }) - return access.lsPackages('myuser', OPTS).then( - () => { - throw new Error('should not have succeeded') - }, - err => t.equal(err.code, 'E404', 'spit out 404 if both reqs fail') - ) -}) - -t.test('ls-packages bad response', t => { - tnock(t, REG).get( - '/-/team/myorg/myteam/package?format=cli' - ).reply(200, JSON.stringify(null)) - return access.lsPackages('myorg:myteam', OPTS).then(data => { - t.same(data, null, 'succeeds with null') - }) -}) - -t.test('ls-packages stream', t => { - const serverPackages = { - '@foo/bar': 'write', - '@foo/util': 'read', - '@foo/other': 'shrödinger', - } - const clientPackages = [ - ['@foo/bar', 'read-write'], - ['@foo/util', 'read-only'], - ['@foo/other', 'shrödinger'], - ] - tnock(t, REG).get( - '/-/team/myorg/myteam/package?format=cli' - ).reply(200, serverPackages) - return access.lsPackages.stream('myorg:myteam', OPTS) - .collect() - .then(data => { - t.same(data, clientPackages, 'got streamed client package info') - }) -}) - -t.test('ls-packages stream no opts', t => { - const serverPackages = { - '@foo/bar': 'write', - '@foo/util': 'read', - '@foo/other': 'shrödinger', - } - const clientPackages = [ - ['@foo/bar', 'read-write'], - ['@foo/util', 'read-only'], - ['@foo/other', 'shrödinger'], - ] - // NOTE: mocking real url, because no opts variable means `registry` value - // will be defauled to real registry url - tnock(t, 'https://registry.npmjs.org') - .get('/-/team/myorg/myteam/package?format=cli') - .reply(200, serverPackages) - return access.lsPackages.stream('myorg:myteam') - .collect() - .then(data => { - t.same(data, clientPackages, 'got streamed client package info') - }) -}) - -t.test('ls-collaborators', t => { - const serverCollaborators = { - 'myorg:myteam': 'write', - 'myorg:anotherteam': 'read', - 'myorg:thirdteam': 'special-case', - } - const clientCollaborators = { - 'myorg:myteam': 'read-write', - 'myorg:anotherteam': 'read-only', - 'myorg:thirdteam': 'special-case', - } - tnock(t, REG).get( - '/-/package/%40foo%2Fbar/collaborators?format=cli' - ).reply(200, serverCollaborators) - return access.lsCollaborators('@foo/bar', OPTS).then(data => { - t.same(data, clientCollaborators, 'got collaborators') - }) -}) - -t.test('ls-collaborators stream', t => { - const serverCollaborators = { - 'myorg:myteam': 'write', - 'myorg:anotherteam': 'read', - 'myorg:thirdteam': 'special-case', - } - const clientCollaborators = [ - ['myorg:myteam', 'read-write'], - ['myorg:anotherteam', 'read-only'], - ['myorg:thirdteam', 'special-case'], - ] - tnock(t, REG).get( - '/-/package/%40foo%2Fbar/collaborators?format=cli' - ).reply(200, serverCollaborators) - return access.lsCollaborators.stream('@foo/bar', OPTS) - .collect() - .then(data => { - t.same(data, clientCollaborators, 'got collaborators') - }) -}) - -t.test('ls-collaborators w/scope', t => { - const serverCollaborators = { - 'myorg:myteam': 'write', - 'myorg:anotherteam': 'read', - 'myorg:thirdteam': 'special-case', - } - const clientCollaborators = { - 'myorg:myteam': 'read-write', - 'myorg:anotherteam': 'read-only', - 'myorg:thirdteam': 'special-case', - } - tnock(t, REG).get( - '/-/package/%40foo%2Fbar/collaborators?format=cli&user=zkat' - ).reply(200, serverCollaborators) - return access.lsCollaborators('@foo/bar', 'zkat', OPTS).then(data => { - t.same(data, clientCollaborators, 'got collaborators') - }) -}) - -t.test('ls-collaborators w/o scope', t => { - const serverCollaborators = { - 'myorg:myteam': 'write', - 'myorg:anotherteam': 'read', - 'myorg:thirdteam': 'special-case', - } - const clientCollaborators = { - 'myorg:myteam': 'read-write', - 'myorg:anotherteam': 'read-only', - 'myorg:thirdteam': 'special-case', - } - tnock(t, REG).get( - '/-/package/bar/collaborators?format=cli&user=zkat' - ).reply(200, serverCollaborators) - return access.lsCollaborators('bar', 'zkat', OPTS).then(data => { - t.same(data, clientCollaborators, 'got collaborators') - }) -}) - -t.test('ls-collaborators bad response', t => { - tnock(t, REG).get( - '/-/package/%40foo%2Fbar/collaborators?format=cli' - ).reply(200, JSON.stringify(null)) - return access.lsCollaborators('@foo/bar', null, OPTS).then(data => { - t.same(data, null, 'succeeds with null') - }) -}) - -t.test('error on non-registry specs', t => { - const resolve = () => { - throw new Error('should not succeed') - } - const reject = err => t.match( - err.message, /spec.*must be a registry spec/, 'registry spec required' - ) - return Promise.all([ - access.public('githubusername/reponame').then(resolve, reject), - access.restricted('foo/bar').then(resolve, reject), - access.grant('foo/bar', 'myorg', 'myteam', 'read-only').then(resolve, reject), - access.revoke('foo/bar', 'myorg', 'myteam').then(resolve, reject), - access.lsCollaborators('foo/bar').then(resolve, reject), - access.tfaRequired('foo/bar').then(resolve, reject), - access.tfaNotRequired('foo/bar').then(resolve, reject), - ]) -}) - -t.test('edit', t => { - t.equal(typeof access.edit, 'function', 'access.edit exists') - t.throws(() => { - access.edit() - }, /Not implemented/, 'directly throws NIY message') + t.end() +}) + +t.test('getPackages', t => { + const packages = { + '@npmcli/test-package': 'write', + '@npmcli/util': 'read', + '@npmcli/other': 'shrödinger', + } + t.test('team', async t => { + const registry = mockRegistry(t) + registry.getPackages({ team, packages }) + await t.resolves(access.getPackages(team, opts), packages) + }) + t.test('org', async t => { + const registry = mockRegistry(t) + registry.getPackages({ team: 'npm', packages }) + await t.resolves(access.getPackages('npm', opts), packages) + }) + t.test('user', async t => { + const registry = mockRegistry(t) + registry.getPackages({ team: orgUser, responseCode: 404 }) + registry.getPackages({ user: orgUser, packages }) + await t.resolves(access.getPackages(orgUser, opts), packages) + }) + t.test('registry error', async t => { + const registry = mockRegistry(t) + registry.getPackages({ team: orgUser, responseCode: 500 }) + await t.rejects(access.getPackages(orgUser, opts), { code: 'E500' }) + }) + t.end() +}) + +t.test('getVisibility', t => { + t.test('success', async t => { + const registry = mockRegistry(t) + const visibility = { public: true } + registry.getVisibility({ spec: pkg, visibility }) + await t.resolves(access.getVisibility(pkg, opts), visibility) + }) + t.test('non registry package', async t => { + await t.rejects(access.getVisibility('./local', opts), /package name only/) + }) + t.end() +}) + +t.test('removePermissions', t => { + t.test('success', async t => { + const registry = mockRegistry(t) + registry.removePermissions({ spec: pkg, team }) + await t.resolves(access.removePermissions(team, pkg, opts)) + }) + t.test('non registry spec', async t => { + await t.rejects(access.removePermissions(team, './local', opts), /package name only/) + }) + t.end() +}) + +t.test('setAccess', t => { + t.test('public', async t => { + const body = { access: 'public' } + const registry = mockRegistry(t) + registry.setAccess({ spec: pkg, body }) + await t.resolves(access.setAccess(pkg, 'public', opts)) + }) + t.test('restricted', async t => { + const body = { access: 'restricted' } + const registry = mockRegistry(t) + registry.setAccess({ spec: pkg, body }) + await t.resolves(access.setAccess(pkg, 'restricted', opts)) + }) + t.test('non registry package', async t => { + await t.rejects(access.setAccess('./local', 'public', opts), /package name only/) + }) + t.end() +}) + +t.test('setMfa', t => { + t.test('none', async t => { + const registry = mockRegistry(t) + const body = { publish_requires_tfa: false } + registry.setAccess({ spec: pkg, body }) + await t.resolves(access.setMfa(pkg, 'none', opts)) + }) + t.test('publish', async t => { + const registry = mockRegistry(t) + const body = { + publish_requires_tfa: true, + automation_token_overrides_tfa: false, + } + registry.setAccess({ spec: pkg, body }) + await t.resolves(access.setMfa(pkg, 'publish', opts)) + }) + t.test('automation', async t => { + const registry = mockRegistry(t) + const body = { + publish_requires_tfa: true, + automation_token_overrides_tfa: true, + } + registry.setAccess({ spec: pkg, body }) + await t.resolves(access.setMfa(pkg, 'automation', opts)) + }) + t.test('invalid', async t => { + await t.rejects(access.setMfa(pkg, 'invalid', opts), /Invalid mfa setting/) + }) + t.test('non registry spec', async t => { + await t.rejects(access.setMfa('./local', 'none', opts, /package name only/)) + }) + t.end() +}) + +t.test('setPermissions', t => { + t.test('scope:team read-only', async t => { + const registry = mockRegistry(t) + registry.setPermissions({ spec: pkg, team, permissions: 'read-only' }) + await t.resolves(access.setPermissions(team, pkg, 'read-only', opts)) + }) + t.test('scope only', async t => { + await t.rejects(access.setPermissions('npmcli', pkg, 'read-only', opts), /scope:team/) + }) + + t.test('no scope or team', async t => { + await t.rejects(access.setPermissions('@:myteam', pkg, 'read-only', opts), /scope:team/) + }) + t.end() }) diff --git a/workspaces/libnpmdiff/.eslintrc.js b/workspaces/libnpmdiff/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/libnpmdiff/.eslintrc.js +++ b/workspaces/libnpmdiff/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/libnpmdiff/.gitignore b/workspaces/libnpmdiff/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/libnpmdiff/.gitignore +++ b/workspaces/libnpmdiff/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/libnpmdiff/.npmrc b/workspaces/libnpmdiff/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/libnpmdiff/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/libnpmdiff/CHANGELOG.md b/workspaces/libnpmdiff/CHANGELOG.md index b93b15b..e99b3f9 100644 --- a/workspaces/libnpmdiff/CHANGELOG.md +++ b/workspaces/libnpmdiff/CHANGELOG.md @@ -1,5 +1,142 @@ # Changelog +## [5.0.6](https://github.com/npm/cli/compare/libnpmdiff-v5.0.5...libnpmdiff-v5.0.6) (2022-12-07) + +### Dependencies + +* [`372d158`](https://github.com/npm/cli/commit/372d158d2637120600a95abee64355ed1cb6f990) [#5935](https://github.com/npm/cli/pull/5935) `minimatch@5.1.1` (#5935) +* [`0a3fe00`](https://github.com/npm/cli/commit/0a3fe000e2723ae6fdb8b1d3154fd3835057c992) [#5933](https://github.com/npm/cli/pull/5933) `minipass@4.0.0` +* [`6b77340`](https://github.com/npm/cli/commit/6b7734009ecd939fbb3d382cb92eb0cdbec7dcd3) `tar@6.1.13` +* [`3da9a1a`](https://github.com/npm/cli/commit/3da9a1a4ebcf1779035b5f9ae985c087f617efe3) `pacote@15.0.7` +* [`875bd56`](https://github.com/npm/cli/commit/875bd56c33ca5eef80c2a50a11808445f2a39a2a) `npm-package-arg@10.1.0` +* [Workspace](https://github.com/npm/cli/releases/tag/arborist-v6.1.5): `@npmcli/arborist@6.1.5` + +## [5.0.5](https://github.com/npm/cli/compare/libnpmdiff-v5.0.4...libnpmdiff-v5.0.5) (2022-11-30) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.3...arborist-v6.1.4): `@npmcli/arborist@6.1.4` + +## [5.0.4](https://github.com/npm/cli/compare/libnpmdiff-v5.0.3...libnpmdiff-v5.0.4) (2022-11-16) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.2...arborist-v6.1.3): `@npmcli/arborist@6.1.3` + +## [5.0.3](https://github.com/npm/cli/compare/libnpmdiff-v5.0.2...libnpmdiff-v5.0.3) (2022-11-09) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.1...arborist-v6.1.2): `@npmcli/arborist@6.1.2` + +## [5.0.2](https://github.com/npm/cli/compare/libnpmdiff-v5.0.1...libnpmdiff-v5.0.2) (2022-11-02) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.0...arborist-v6.1.1): `@npmcli/arborist@6.1.1` + +## [5.0.1](https://github.com/npm/cli/compare/libnpmdiff-v5.0.0...libnpmdiff-v5.0.1) (2022-10-26) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0...arborist-v6.1.0): `@npmcli/arborist@6.1.0` + +## [5.0.0](https://github.com/npm/cli/compare/libnpmdiff-v5.0.0-pre.3...libnpmdiff-v5.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.5...arborist-v6.0.0): `@npmcli/arborist@6.0.0` + +## [5.0.0-pre.3](https://github.com/npm/cli/compare/libnpmdiff-v5.0.0-pre.2...libnpmdiff-v5.0.0-pre.3) (2022-10-19) + +### Dependencies + +* [`2008ea6`](https://github.com/npm/cli/commit/2008ea6a807acbd97912799adfe97f276202cea6) `npm-package-arg@10.0.0`, `pacote@15.0.2` +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.4...arborist-v6.0.0-pre.5): `@npmcli/arborist@6.0.0-pre.5` + +## [5.0.0-pre.2](https://github.com/npm/cli/compare/libnpmdiff-v5.0.0-pre.1...libnpmdiff-v5.0.0-pre.2) (2022-10-05) + +### Dependencies + +* [`5344d2c`](https://github.com/npm/cli/commit/5344d2ca9ffd1f6db473fd58b46b50179f899ff5) [#5644](https://github.com/npm/cli/pull/5644) `pacote@14.0.0` +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.3...arborist-v6.0.0-pre.4): `@npmcli/arborist@6.0.0-pre.4` + +## [5.0.0-pre.1](https://github.com/npm/cli/compare/libnpmdiff-v5.0.0-pre.0...libnpmdiff-v5.0.0-pre.1) (2022-09-30) + +### ⚠️ BREAKING CHANGES + +* `npm pack` now follows a strict order of operations when applying ignore rules. If a files array is present in the package.json, then rules in .gitignore and .npmignore files from the root will be ignored. + +### Features + +* [`3ae796d`](https://github.com/npm/cli/commit/3ae796d937bd36a5b1b9fd6e9e8473b4f2ddc32d) implement new `npm-packlist` behavior (@lukekarrys) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.2...arborist-v6.0.0-pre.3): `@npmcli/arborist@6.0.0-pre.3` + +## [5.0.0-pre.0](https://github.com/npm/cli/compare/libnpmdiff-v4.0.5...libnpmdiff-v5.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + +## [4.0.5](https://github.com/npm/cli/compare/libnpmdiff-v4.0.4...libnpmdiff-v4.0.5) (2022-08-31) + +### Dependencies + + * [`1286f03`](https://github.com/npm/cli/commit/1286f03fe73dee9a447b13b662f0c5622ab6ec9e) [#5381](https://github.com/npm/cli/pull/5381) deps: `unique-filename@2.0.1` + * [`f4205e5`](https://github.com/npm/cli/commit/f4205e57d6c4ee5f2ff7d21ffc116ffc420d191e) [#5381](https://github.com/npm/cli/pull/5381) deps: `diff@5.1.0` + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` + +## [4.0.4](https://github.com/npm/cli/compare/libnpmdiff-v4.0.3...libnpmdiff-v4.0.4) (2022-06-22) + + +### Dependencies + +* pacote@13.6.1 ([2e50cb8](https://github.com/npm/cli/commit/2e50cb83e84cf25fee93ba0ca5a0343fbdb33c41)) + +### [4.0.3](https://github.com/npm/cli/compare/libnpmdiff-v4.0.2...libnpmdiff-v4.0.3) (2022-04-06) + + +### Bug Fixes + +* replace deprecated String.prototype.substr() ([#4667](https://github.com/npm/cli/issues/4667)) ([e3da5df](https://github.com/npm/cli/commit/e3da5df4152fbe547f7871547165328e1bf06262)) +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/disparity-colors@2.0.0 ([f86f1af](https://github.com/npm/cli/commit/f86f1af636f39d7d30a97873bbb6652416f68013)) +* @npmcli/template-oss@3.2.1 ([aac01b8](https://github.com/npm/cli/commit/aac01b89caf6336a2eb34d696296303cdadd5c08)) +* @npmcli/template-oss@3.2.2 ([#4639](https://github.com/npm/cli/issues/4639)) ([a59fd2c](https://github.com/npm/cli/commit/a59fd2cb863245fce56f96c90ac854e62c5c4d6f)) +* minimatch@5.0.1 ([1b30c72](https://github.com/npm/cli/commit/1b30c725ecd0f03f55e3c0576962972748eec238)) + +### [4.0.2](https://www.github.com/npm/cli/compare/libnpmdiff-v4.0.1...libnpmdiff-v4.0.2) (2022-03-15) + + +### Dependencies + +* npm-package-arg@9.0.1 ([9555a5f](https://www.github.com/npm/cli/commit/9555a5f1d135aa1b8f7374273403efe41e99ee26)) +* pacote@13.0.4 ([6d31450](https://www.github.com/npm/cli/commit/6d3145014861b4198c16d7772d809fd037ece289)) +* pacote@13.0.5 ([340fa51](https://www.github.com/npm/cli/commit/340fa51f423a518a96c8015a67d8f6144a2e8051)) + +### [4.0.1](https://www.github.com/npm/cli/compare/libnpmdiff-vlibnpmdiff@4.0.0...libnpmdiff-v4.0.1) (2022-03-03) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) + ## 2.0.3 - fix name of options sent by the npm cli @@ -27,4 +164,3 @@ ## 1.0.0 - Initial release - diff --git a/workspaces/libnpmdiff/README.md b/workspaces/libnpmdiff/README.md index 6c60f71..b8eb083 100644 --- a/workspaces/libnpmdiff/README.md +++ b/workspaces/libnpmdiff/README.md @@ -2,9 +2,7 @@ [![npm version](https://img.shields.io/npm/v/libnpmdiff.svg)](https://npm.im/libnpmdiff) [![license](https://img.shields.io/npm/l/libnpmdiff.svg)](https://npm.im/libnpmdiff) -[![GitHub Actions](https://github.com/npm/libnpmdiff/workflows/node-ci/badge.svg)](https://github.com/npm/libnpmdiff/actions?query=workflow%3Anode-ci) -[![Coverage Status](https://coveralls.io/repos/github/npm/libnpmdiff/badge.svg?branch=main)](https://coveralls.io/github/npm/libnpmdiff?branch=main) - +[![CI - libnpmdiff](https://github.com/npm/cli/actions/workflows/ci-libnpmdiff.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-libnpmdiff.yml) The registry diff lib. ## Table of Contents diff --git a/workspaces/libnpmdiff/SECURITY.md b/workspaces/libnpmdiff/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/libnpmdiff/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/libnpmdiff/lib/should-print-patch.js b/workspaces/libnpmdiff/lib/should-print-patch.js index a954811..f8277a8 100644 --- a/workspaces/libnpmdiff/lib/should-print-patch.js +++ b/workspaces/libnpmdiff/lib/should-print-patch.js @@ -14,7 +14,7 @@ const shouldPrintPatch = (path, opts = {}) => { filename.startsWith('.') ? filename : extname(filename) - ).substr(1) + ).slice(1) return !binaryExtensions.includes(extension) } diff --git a/workspaces/libnpmdiff/lib/tarball.js b/workspaces/libnpmdiff/lib/tarball.js index 4d01d69..930d624 100644 --- a/workspaces/libnpmdiff/lib/tarball.js +++ b/workspaces/libnpmdiff/lib/tarball.js @@ -1,5 +1,6 @@ const { relative } = require('path') +const Arborist = require('@npmcli/arborist') const npa = require('npm-package-arg') const pkgContents = require('@npmcli/installed-package-contents') const pacote = require('pacote') @@ -28,7 +29,10 @@ const tarball = (manifest, opts) => { return nodeModulesTarball(manifest, opts) } - return pacote.tarball(manifest._resolved, opts) + return pacote.tarball(manifest._resolved, { + ...opts, + Arborist, + }) } module.exports = tarball diff --git a/workspaces/libnpmdiff/package.json b/workspaces/libnpmdiff/package.json index 24846f3..d761b0c 100644 --- a/workspaces/libnpmdiff/package.json +++ b/workspaces/libnpmdiff/package.json @@ -1,15 +1,19 @@ { "name": "libnpmdiff", - "version": "3.0.0", + "version": "5.0.6", "description": "The registry diff", - "repository": "https://github.com/npm/libnpmdiff", + "repository": { + "type": "git", + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/libnpmdiff" + }, "main": "lib/index.js", "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "keywords": [ "npm", @@ -29,35 +33,39 @@ "license": "ISC", "scripts": { "eslint": "eslint", - "lint": "eslint '**/*.js'", - "lintfix": "npm run lint -- --fix", + "lint": "eslint \"**/*.js\"", + "lintfix": "node ../.. run lint -- --fix", "test": "tap", - "posttest": "npm run lint", + "posttest": "node ../.. run lint", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "postlint": "npm-template-check" - }, - "tap": { - "check-coverage": true + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "eslint": "^8.1.0", - "tap": "^15.0.9" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "tap": "^16.3.2" }, "dependencies": { - "@npmcli/disparity-colors": "^1.0.1", - "@npmcli/installed-package-contents": "^1.0.7", + "@npmcli/arborist": "^6.1.5", + "@npmcli/disparity-colors": "^3.0.0", + "@npmcli/installed-package-contents": "^2.0.0", "binary-extensions": "^2.2.0", - "diff": "^5.0.0", - "minimatch": "^3.0.4", - "npm-package-arg": "^8.1.4", - "pacote": "^12.0.0", - "tar": "^6.1.0" + "diff": "^5.1.0", + "minimatch": "^5.1.1", + "npm-package-arg": "^10.1.0", + "pacote": "^15.0.7", + "tar": "^6.1.13" }, "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/workspaces/libnpmdiff/test/index.js b/workspaces/libnpmdiff/test/index.js index 6f6e481..cccde42 100644 --- a/workspaces/libnpmdiff/test/index.js +++ b/workspaces/libnpmdiff/test/index.js @@ -5,11 +5,12 @@ const t = require('tap') const diff = require('../lib/index.js') const normalizePath = p => p - .replace(/\\+/g, '/') + .replace(/\\+(?!")/g, '/') .replace(/\r\n/g, '\n') t.cleanSnapshot = (str) => normalizePath(str) .replace(normalizePath(process.execPath), 'node') + .replace(/\\"node\\"/g, 'node') const json = (obj) => `${JSON.stringify(obj, null, 2)}\n` @@ -62,7 +63,7 @@ t.test('folder in node_modules', async t => { name: 'a', version: '1.0.0', scripts: { - prepare: `${process.execPath} prepare.js`, + prepare: `"${process.execPath}" prepare.js`, }, }), 'prepare.js': 'throw new Error("ERR")', @@ -72,7 +73,7 @@ t.test('folder in node_modules', async t => { name: 'b', version: '2.0.0', scripts: { - prepare: `${process.execPath} prepare.js`, + prepare: `"${process.execPath}" prepare.js`, }, }), 'prepare.js': 'throw new Error("ERR")', @@ -86,7 +87,7 @@ t.test('folder in node_modules', async t => { name: 'a', version: '1.0.1', scripts: { - prepare: `${process.execPath} prepare.js`, + prepare: `"${process.execPath}" prepare.js`, }, }), 'prepare.js': '', @@ -96,7 +97,7 @@ t.test('folder in node_modules', async t => { name: 'b', version: '2.0.1', scripts: { - prepare: `${process.execPath} prepare.js`, + prepare: `"${process.execPath}" prepare.js`, }, }), 'prepare.js': '', diff --git a/workspaces/libnpmdiff/test/tarball.js b/workspaces/libnpmdiff/test/tarball.js index 3a959be..cb61556 100644 --- a/workspaces/libnpmdiff/test/tarball.js +++ b/workspaces/libnpmdiff/test/tarball.js @@ -11,7 +11,7 @@ const tarball = require('../lib/tarball.js') const json = (obj) => `${JSON.stringify(obj, null, 2)}\n` -t.test('returns a tarball from node_modules', t => { +t.test('returns a tarball from node_modules', async t => { t.plan(2) const path = t.testdir({ @@ -33,22 +33,21 @@ t.test('returns a tarball from node_modules', t => { process.chdir(_cwd) }) - tarball({ bin: { a: 'index.js' }, _resolved: resolve(path, 'node_modules/a') }, { where: path }) - .then(res => { - tar.list({ - filter: path => { - t.match( - path, - /package.json|index.js/, - 'should return tarball with expected files' - ) - }, - }) - .on('error', e => { - throw e - }) - .end(res) - }) + const res = await tarball( + { bin: { a: 'index.js' }, _resolved: resolve(path, 'node_modules/a') }, + { where: path } + ) + tar.list({ + filter: p => { + t.match( + p, + /package.json|index.js/, + 'should return tarball with expected files' + ) + }, + }).on('error', e => { + throw e + }).end(res) }) t.test('node_modules folder within a linked dir', async t => { diff --git a/workspaces/libnpmexec/.editorconfig b/workspaces/libnpmexec/.editorconfig deleted file mode 100644 index 0f3bb61..0000000 --- a/workspaces/libnpmexec/.editorconfig +++ /dev/null @@ -1,3 +0,0 @@ -[*.js] -indent_style = space -indent_size = 2 diff --git a/workspaces/libnpmexec/.eslintrc.js b/workspaces/libnpmexec/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/libnpmexec/.eslintrc.js +++ b/workspaces/libnpmexec/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/libnpmexec/.gitignore b/workspaces/libnpmexec/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/libnpmexec/.gitignore +++ b/workspaces/libnpmexec/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/libnpmexec/.npmrc b/workspaces/libnpmexec/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/libnpmexec/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/libnpmexec/CHANGELOG.md b/workspaces/libnpmexec/CHANGELOG.md index 698d1a4..c0721ca 100644 --- a/workspaces/libnpmexec/CHANGELOG.md +++ b/workspaces/libnpmexec/CHANGELOG.md @@ -1,5 +1,254 @@ # Changelog +## [5.0.6](https://github.com/npm/cli/compare/libnpmexec-v5.0.5...libnpmexec-v5.0.6) (2022-12-07) + +### Dependencies + +* [`0e6c28b`](https://github.com/npm/cli/commit/0e6c28ba093f8c5d35df98afca28e842b247004b) [#5934](https://github.com/npm/cli/pull/5934) `ci-info@3.7.0` (#5934) +* [`0a3fe00`](https://github.com/npm/cli/commit/0a3fe000e2723ae6fdb8b1d3154fd3835057c992) [#5933](https://github.com/npm/cli/pull/5933) `minipass@4.0.0` +* [`3da9a1a`](https://github.com/npm/cli/commit/3da9a1a4ebcf1779035b5f9ae985c087f617efe3) `pacote@15.0.7` +* [`875bd56`](https://github.com/npm/cli/commit/875bd56c33ca5eef80c2a50a11808445f2a39a2a) `npm-package-arg@10.1.0` +* [Workspace](https://github.com/npm/cli/releases/tag/arborist-v6.1.5): `@npmcli/arborist@6.1.5` + +## [5.0.5](https://github.com/npm/cli/compare/libnpmexec-v5.0.4...libnpmexec-v5.0.5) (2022-11-30) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.3...arborist-v6.1.4): `@npmcli/arborist@6.1.4` + +## [5.0.4](https://github.com/npm/cli/compare/libnpmexec-v5.0.3...libnpmexec-v5.0.4) (2022-11-16) + +### Bug Fixes + +* [`cc0ad27`](https://github.com/npm/cli/commit/cc0ad2798a3e9d2a25e9b3ac947c0324fa8b40c1) [#5842](https://github.com/npm/cli/pull/5842) npx: properly look for local bins when there are more than one (#5842) (@wraithgar) + +### Dependencies + +* [`a351685`](https://github.com/npm/cli/commit/a351685c4951b1d9e2ba86bc99e3706688813438) [#5858](https://github.com/npm/cli/pull/5858) move from @npmcli/ci-detect to ci-info (#5858) +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.2...arborist-v6.1.3): `@npmcli/arborist@6.1.3` + +## [5.0.3](https://github.com/npm/cli/compare/libnpmexec-v5.0.2...libnpmexec-v5.0.3) (2022-11-09) + +### Bug Fixes + +* [`a767aae`](https://github.com/npm/cli/commit/a767aae7148dbbc943095ba994bbfab58bf2a8be) npx: look for bins in local package.json (@wraithgar) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.1...arborist-v6.1.2): `@npmcli/arborist@6.1.2` + +## [5.0.2](https://github.com/npm/cli/compare/libnpmexec-v5.0.1...libnpmexec-v5.0.2) (2022-11-02) + +### Bug Fixes + +* [`1f5382d`](https://github.com/npm/cli/commit/1f5382dada181cda41f1504974de1e69a6c1ad7f) [#5789](https://github.com/npm/cli/pull/5789) don't set `stdioString` for any spawn/run-script calls (@lukekarrys) + +### Dependencies + +* [`b89c19e`](https://github.com/npm/cli/commit/b89c19e9a7674b0bd9d336c14dee1bf381843648) [#5795](https://github.com/npm/cli/pull/5795) `cli-table3@0.6.3` +* [`9972ed1`](https://github.com/npm/cli/commit/9972ed1423d7a4f7ca03a34f5aa69321b81850fd) `@npmcli/ci-detect@3.0.1` +* [`abfb28b`](https://github.com/npm/cli/commit/abfb28b249183b8c033f8e7acc1546150cdac137) `@npmcli/run-script@6.0.0` +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.0...arborist-v6.1.1): `@npmcli/arborist@6.1.1` + +## [5.0.1](https://github.com/npm/cli/compare/libnpmexec-v5.0.0...libnpmexec-v5.0.1) (2022-10-26) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0...arborist-v6.1.0): `@npmcli/arborist@6.1.0` + +## [5.0.0](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.5...libnpmexec-v5.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.5...arborist-v6.0.0): `@npmcli/arborist@6.0.0` + +## [5.0.0-pre.5](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.4...libnpmexec-v5.0.0-pre.5) (2022-10-19) + +### ⚠️ BREAKING CHANGES + +* this package no longer attempts to change file ownership automatically + +### Features + +* [`58065bc`](https://github.com/npm/cli/commit/58065bc679e6968742b5b15fa2fb82dd9e8ae988) [#5704](https://github.com/npm/cli/pull/5704) do not alter file ownership (@nlf) + +### Bug Fixes + +* [`1afe5ba`](https://github.com/npm/cli/commit/1afe5ba9647d1f0f55bf0a4bace543965d05daed) account for new npm-package-arg behavior (@wraithgar) + +### Dependencies + +* [`88137a3`](https://github.com/npm/cli/commit/88137a329c8ad418db265dd465768a7cf5ebccb1) `npmlog@7.0.1` +* [`2008ea6`](https://github.com/npm/cli/commit/2008ea6a807acbd97912799adfe97f276202cea6) `npm-package-arg@10.0.0`, `pacote@15.0.2` +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.4...arborist-v6.0.0-pre.5): `@npmcli/arborist@6.0.0-pre.5` + +## [5.0.0-pre.4](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.3...libnpmexec-v5.0.0-pre.4) (2022-10-05) + +### Dependencies + +* [`5344d2c`](https://github.com/npm/cli/commit/5344d2ca9ffd1f6db473fd58b46b50179f899ff5) [#5644](https://github.com/npm/cli/pull/5644) `pacote@14.0.0` +* [`8b072dc`](https://github.com/npm/cli/commit/8b072dc113190ed49b296a5f02650b7d8cbf384a) [#5639](https://github.com/npm/cli/pull/5639) `@npmcli/ci-detect@3.0.0` (#5639) +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.3...arborist-v6.0.0-pre.4): `@npmcli/arborist@6.0.0-pre.4` + +## [5.0.0-pre.3](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.2...libnpmexec-v5.0.0-pre.3) (2022-09-30) + +### ⚠️ BREAKING CHANGES + +* `npm pack` now follows a strict order of operations when applying ignore rules. If a files array is present in the package.json, then rules in .gitignore and .npmignore files from the root will be ignored. + +### Features + +* [`3ae796d`](https://github.com/npm/cli/commit/3ae796d937bd36a5b1b9fd6e9e8473b4f2ddc32d) implement new `npm-packlist` behavior (@lukekarrys) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.2...arborist-v6.0.0-pre.3): `@npmcli/arborist@6.0.0-pre.3` + +## [5.0.0-pre.2](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.1...libnpmexec-v5.0.0-pre.2) (2022-09-23) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.1...arborist-v6.0.0-pre.2): `@npmcli/arborist@6.0.0-pre.2` + +## [5.0.0-pre.1](https://github.com/npm/cli/compare/libnpmexec-v5.0.0-pre.0...libnpmexec-v5.0.0-pre.1) (2022-09-14) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.0...arborist-v6.0.0-pre.1): `@npmcli/arborist@6.0.0-pre.1` + +## [5.0.0-pre.0](https://github.com/npm/cli/compare/libnpmexec-v4.0.12...libnpmexec-v5.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @npmcli/arborist bumped from ^5.6.1 to ^6.0.0-pre.0 + +## [4.0.12](https://github.com/npm/cli/compare/libnpmexec-v4.0.11...libnpmexec-v4.0.12) (2022-08-31) + +### Dependencies + + * [`1286f03`](https://github.com/npm/cli/commit/1286f03fe73dee9a447b13b662f0c5622ab6ec9e) [#5381](https://github.com/npm/cli/pull/5381) deps: `unique-filename@2.0.1` + * [`7fbf6f7`](https://github.com/npm/cli/commit/7fbf6f7825f76906ecdec79ab15595f9e2f7b784) [#5381](https://github.com/npm/cli/pull/5381) deps: `bin-links@3.0.3` + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` +* The following workspace dependencies were updated + * dependencies + * @npmcli/arborist bumped from ^5.0.0 to ^5.6.1 + +## [4.0.11](https://github.com/npm/cli/compare/libnpmexec-v4.0.10...libnpmexec-v4.0.11) (2022-08-17) + + +### Bug Fixes + +* don't prompt on `npm exec [directory]` ([#5298](https://github.com/npm/cli/issues/5298)) ([6eba131](https://github.com/npm/cli/commit/6eba13164d84efb34554c7dddeb2dbfed063ac0a)) +* npm exec does not use script-shell option to run commands ([#5297](https://github.com/npm/cli/issues/5297)) ([e5a9162](https://github.com/npm/cli/commit/e5a9162a9dae9471e1ea77ad38baa02bb8d9852e)) + +## [4.0.10](https://github.com/npm/cli/compare/libnpmexec-v4.0.9...libnpmexec-v4.0.10) (2022-08-10) + + +### Bug Fixes + +* ignore global prefix if --prefix is used ([#5291](https://github.com/npm/cli/issues/5291)) ([daaf461](https://github.com/npm/cli/commit/daaf4619c85ecf62346770735cfa8e2ddecbef8b)) +* look up local command bins from local tree ([#5273](https://github.com/npm/cli/issues/5273)) ([c992fd6](https://github.com/npm/cli/commit/c992fd6757505974dc8e92a9e2886d2233e098eb)) +* only try to run global bin if the bin name exists ([#5253](https://github.com/npm/cli/issues/5253)) ([95ae9f2](https://github.com/npm/cli/commit/95ae9f2e2555ef592777399bf8fee5206d77f41d)) + +## [4.0.9](https://github.com/npm/cli/compare/libnpmexec-v4.0.8...libnpmexec-v4.0.9) (2022-08-03) + + +### Bug Fixes + +* fix exec tests and clean up workspace-location-msg ([3b30af2](https://github.com/npm/cli/commit/3b30af25e93665f5aa21897910a65d7f26bbd066)) +* properly find and run global scoped packages ([#5250](https://github.com/npm/cli/issues/5250)) ([19a8346](https://github.com/npm/cli/commit/19a834610d154f36748536b27aed13bfdb5ee748)) +* properly find locally/globally/npxCache packages ([ea44995](https://github.com/npm/cli/commit/ea449954844f21abbf984e09e421f0e03485a535)) +* use binPaths ([19f1497](https://github.com/npm/cli/commit/19f1497322411f1566885bd53e63dc39f0df27ea)) + + +### Dependencies + +* @npmcli/run-script@4.2.0 ([d0be9a2](https://github.com/npm/cli/commit/d0be9a2bb53e74b30e13751afd1f6924990c8422)) +* add @npmcli/fs@2.1.1 ([c18dbc4](https://github.com/npm/cli/commit/c18dbc4393491e02532d698351747307848d2e20)) +* add semver@7.3.7 ([cd6bafd](https://github.com/npm/cli/commit/cd6bafdfbbd7a054709c11850b58f7dbc26eb8da)) + +## [4.0.8](https://github.com/npm/cli/compare/libnpmexec-v4.0.7...libnpmexec-v4.0.8) (2022-06-23) + + +### Dependencies + +* @npmcli/run-script@4.1.3 ([#5064](https://github.com/npm/cli/issues/5064)) ([f59a114](https://github.com/npm/cli/commit/f59a114ffe3d1f86ccb2e52a4432292ab76852cc)) + +## [4.0.7](https://github.com/npm/cli/compare/libnpmexec-v4.0.6...libnpmexec-v4.0.7) (2022-06-22) + + +### Dependencies + +* @npmcli/run-script@4.1.0 ([2c06cee](https://github.com/npm/cli/commit/2c06ceee82dd813c0ae84cc0b09e6941cfc5533e)) +* pacote@13.6.1 ([2e50cb8](https://github.com/npm/cli/commit/2e50cb83e84cf25fee93ba0ca5a0343fbdb33c41)) + +### [4.0.6](https://github.com/npm/cli/compare/libnpmexec-v4.0.5...libnpmexec-v4.0.6) (2022-06-01) + + +### Bug Fixes + +* **libnpmexec:** fix bug not install latest pkg ([#4929](https://github.com/npm/cli/issues/4929)) ([fcc72dd](https://github.com/npm/cli/commit/fcc72dd8791187f4b3d8705fb23c2744c83ef943)) + +### [4.0.5](https://github.com/npm/cli/compare/libnpmexec-v4.0.4...libnpmexec-v4.0.5) (2022-04-26) + + +### Dependencies + +* npmlog@6.0.2 ([5e31322](https://github.com/npm/cli/commit/5e313223100db1207818d756b081eaba3468b273)) + +### [4.0.4](https://github.com/npm/cli/compare/libnpmexec-v4.0.3...libnpmexec-v4.0.4) (2022-04-19) + + +### Bug Fixes + +* **exec:** workspaces support ([6253d19](https://github.com/npm/cli/commit/6253d1968d8390ea6b16604ff3abb5e6509349c9)) +* **libnpmexec:** fix read mixed local/registry pkg ([4a46a27](https://github.com/npm/cli/commit/4a46a27f2b968e2f8c1f4821508f93013738c482)) + +### [4.0.3](https://github.com/npm/cli/compare/libnpmexec-v4.0.2...libnpmexec-v4.0.3) (2022-04-06) + + +### Bug Fixes + +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/template-oss@3.2.1 ([aac01b8](https://github.com/npm/cli/commit/aac01b89caf6336a2eb34d696296303cdadd5c08)) +* @npmcli/template-oss@3.2.2 ([#4639](https://github.com/npm/cli/issues/4639)) ([a59fd2c](https://github.com/npm/cli/commit/a59fd2cb863245fce56f96c90ac854e62c5c4d6f)) + +### [4.0.2](https://www.github.com/npm/cli/compare/libnpmexec-v4.0.1...libnpmexec-v4.0.2) (2022-03-15) + + +### Dependencies + +* npm-package-arg@9.0.1 ([9555a5f](https://www.github.com/npm/cli/commit/9555a5f1d135aa1b8f7374273403efe41e99ee26)) +* pacote@13.0.4 ([6d31450](https://www.github.com/npm/cli/commit/6d3145014861b4198c16d7772d809fd037ece289)) +* pacote@13.0.5 ([340fa51](https://www.github.com/npm/cli/commit/340fa51f423a518a96c8015a67d8f6144a2e8051)) + +### [4.0.1](https://www.github.com/npm/cli/compare/libnpmexec-vlibnpmexec@4.0.0...libnpmexec-v4.0.1) (2022-03-03) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) + ## v2.0.0 - Added a new required `npxCache` option @@ -22,4 +271,3 @@ similar to `@npmcli/run-script` - Initial implementation, moves the code that used to live in the **npm cli**, ref: https://github.com/npm/cli/blob/release/v7.10.0/lib/exec.js into this separate module, providing a programmatic API to the **npm exec** functionality. - diff --git a/workspaces/libnpmexec/CONTRIBUTING.md b/workspaces/libnpmexec/CONTRIBUTING.md deleted file mode 100644 index 045ba4b..0000000 --- a/workspaces/libnpmexec/CONTRIBUTING.md +++ /dev/null @@ -1,68 +0,0 @@ -# Contributing -## Table of Contents - -* [Introduction](#introduction) -* [Running Tests](#running-tests) -* [Coverage](#coverage) -* [Types of Contributions](#types-of-contributions) - * [Contributing an Issue?](#contributing-an-issue) - * [Contributing a Question?](#contributing-a-question) - * [Contributing a Bug Fix?](#contributing-a-bug-fix) - * [Contributing a Feature?](#contributing-a-feature) -* [Development Dependencies](#development-dependencies) -* [Dependencies](#dependencies) - -## Introduction - -Welcome to the **libnpmexec** Contributor Guide! This document outlines the libnpmexec's process for community interaction and contribution. This includes the issue tracker, pull requests, wiki pages, and, to a certain extent, outside communication in the context of the libnpmexec. This is an entry point for anyone wishing to contribute their time and effort to making libnpmexec a better tool for the JavaScript community! - -All interactions in the **libnpmexec** repository are covered by the [npm Code of Conduct](https://www.npmjs.com/policies/conduct) - - -## Running Tests - -``` -# Make sure you install the dependencies first before running tests. -$ npm install - -# Run tests for the CLI (it could take awhile). -$ npm run test -``` - -## Coverage - -We try and make sure that each new feature or bug fix has tests to go along with them in order to keep code coverages consistent and increasing. We are actively striving for 100% code coverage! - -## Types of Contributions - -> Before contributing something, double check the issue you're creating doesn't already exist in the repository but doing a quick search. Search of the [current issues](https://github.com/npm/libnpmexec/issues). - -### Contributing a Question? - -Huh? 🤔 Got a situation you're not sure about?! Perfect! - -You can create a new question [here](https://github.com/npm/libnpmexec/issues/new?template=question.md&title=%5BQUESTION%5D+%3Ctitle%3E)! - -### Contributing a Bug Fix? - -We'd be happy to triage and help! Head over to the issues and [create a new one](https://github.com/npm/libnpmexec/issues/new?template=bug.md&title=%5BBUG%5D+%3Ctitle%3E)! - - -### Contributing a Feature? - -Snazzy, we're always up for fancy new things! If the feature is fairly minor [create a new one](https://github.com/npm/libnpmexec/issues/new?template=feature.md&title=%5BFEATURE%5D+%3Ctitle%3E), and the team can triage it and prioritize it into our backlog. However, if the feature is a little more complex, then it's best to create an [RFC](https://en.wikipedia.org/wiki/Request_for_Comments) in our [RFC repository](https://github.com/npm/rfcs). Exactly how to do that is outlined in that repository. If you're not sure _exactly_ how to implement your idea, or don't want to make a document about your idea, then please create an issue on that repository. We consider these RRFC's, or a "Requesting Request For Comment". - -## Development Dependencies - -You'll need a few things installed in order to update and test **libnpmexec** during development: - - -* [node](https://nodejs.org/) v10 or greater - -> We recommend that you have a [node version manager](https://github.com/nvm-sh/nvm) installed if you plan on fixing bugs that might be present in a specific version of node. With a version manager you can easily switch versions of node and test if your changes to the CLI project are working. - -* [git](https://git-scm.com/) v2.11+ - - -## Dependencies -<!-- Optional Section --> diff --git a/workspaces/libnpmexec/README.md b/workspaces/libnpmexec/README.md index a485527..dc79d12 100644 --- a/workspaces/libnpmexec/README.md +++ b/workspaces/libnpmexec/README.md @@ -2,8 +2,7 @@ [![npm version](https://img.shields.io/npm/v/libnpmexec.svg)](https://npm.im/libnpmexec) [![license](https://img.shields.io/npm/l/libnpmexec.svg)](https://npm.im/libnpmexec) -[![GitHub Actions](https://github.com/npm/libnpmexec/workflows/node-ci/badge.svg)](https://github.com/npm/libnpmexec/actions?query=workflow%3Anode-ci) -[![Coverage Status](https://coveralls.io/repos/github/npm/libnpmexec/badge.svg?branch=main)](https://coveralls.io/github/npm/libnpmexec?branch=main) +[![CI - libnpmexec](https://github.com/npm/cli/actions/workflows/ci-libnpmexec.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-libnpmexec.yml) The `npm exec` (`npx`) Programmatic API @@ -35,7 +34,6 @@ await libexec({ - `color`: Output should use color? **Boolean**, defaults to `false` - `localBin`: Location to the `node_modules/.bin` folder of the local project to start scanning for bin files **String**, defaults to `./node_modules/.bin`. **libexec** will walk up the directory structure looking for `node_modules/.bin` folders in parent folders that might satisfy the current `arg` and will use that bin if found. - `locationMsg`: Overrides "at location" message when entering interactive mode **String** - - `log`: Sets an optional logger **Object**, defaults to `proc-log` module usage. - `globalBin`: Location to the global space bin folder, same as: `$(npm bin -g)` **String**, defaults to empty string. - `output`: A function to print output to **Function** - `packages`: A list of packages to be used (possibly fetch from the registry) **Array<String>**, defaults to `[]` diff --git a/workspaces/libnpmexec/SECURITY.md b/workspaces/libnpmexec/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/libnpmexec/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/libnpmexec/lib/cache-install-dir.js b/workspaces/libnpmexec/lib/cache-install-dir.js deleted file mode 100644 index 7746693..0000000 --- a/workspaces/libnpmexec/lib/cache-install-dir.js +++ /dev/null @@ -1,20 +0,0 @@ -const crypto = require('crypto') - -const { resolve } = require('path') - -const cacheInstallDir = ({ npxCache, packages }) => { - if (!npxCache) { - throw new Error('Must provide a valid npxCache path') - } - - // only packages not found in ${prefix}/node_modules - return resolve(npxCache, getHash(packages)) -} - -const getHash = (packages) => - crypto.createHash('sha512') - .update(packages.sort((a, b) => a.localeCompare(b, 'en')).join('\n')) - .digest('hex') - .slice(0, 16) - -module.exports = cacheInstallDir diff --git a/workspaces/libnpmexec/lib/file-exists.js b/workspaces/libnpmexec/lib/file-exists.js index 05dddc8..0a8d79e 100644 --- a/workspaces/libnpmexec/lib/file-exists.js +++ b/workspaces/libnpmexec/lib/file-exists.js @@ -1,23 +1,25 @@ const { resolve } = require('path') -const { promisify } = require('util') -const stat = promisify(require('fs').stat) +const { stat } = require('fs/promises') const walkUp = require('walk-up-path') -const fileExists = (file) => stat(file) - .then((stat) => stat.isFile()) - .catch(() => false) +const fileExists = async (file) => { + try { + const res = await stat(file) + return res.isFile() + } catch { + return false + } +} -const localFileExists = async (dir, binName, root = '/') => { - root = resolve(root).toLowerCase() - - for (const path of walkUp(resolve(dir))) { +const localFileExists = async (dir, binName, root) => { + for (const path of walkUp(dir)) { const binDir = resolve(path, 'node_modules', '.bin') if (await fileExists(resolve(binDir, binName))) { return binDir } - if (path.toLowerCase() === root) { + if (path.toLowerCase() === resolve(root).toLowerCase()) { return false } } diff --git a/workspaces/libnpmexec/lib/index.js b/workspaces/libnpmexec/lib/index.js index facafb0..ea4ff5d 100644 --- a/workspaces/libnpmexec/lib/index.js +++ b/workspaces/libnpmexec/lib/index.js @@ -1,155 +1,242 @@ -const { delimiter, dirname, resolve } = require('path') +'use strict' + +const { mkdir } = require('fs/promises') const { promisify } = require('util') -const read = promisify(require('read')) const Arborist = require('@npmcli/arborist') -const ciDetect = require('@npmcli/ci-detect') -const logger = require('proc-log') -const mkdirp = require('mkdirp-infer-owner') +const ciInfo = require('ci-info') +const crypto = require('crypto') +const log = require('proc-log') const npa = require('npm-package-arg') +const npmlog = require('npmlog') const pacote = require('pacote') -const readPackageJson = require('read-package-json-fast') +const read = promisify(require('read')) +const semver = require('semver') -const cacheInstallDir = require('./cache-install-dir.js') const { fileExists, localFileExists } = require('./file-exists.js') const getBinFromManifest = require('./get-bin-from-manifest.js') -const manifestMissing = require('./manifest-missing.js') const noTTY = require('./no-tty.js') const runScript = require('./run-script.js') const isWindows = require('./is-windows.js') -/* istanbul ignore next */ -const PATH = ( - process.env.PATH || process.env.Path || process.env.path -).split(delimiter) +const { dirname, resolve } = require('path') + +const binPaths = [] + +// when checking the local tree we look up manifests, cache those results by +// spec.raw so we don't have to fetch again when we check npxCache +const manifests = new Map() + +const getManifest = async (spec, flatOptions) => { + if (!manifests.has(spec.raw)) { + const manifest = await pacote.manifest(spec, { ...flatOptions, preferOnline: true }) + manifests.set(spec.raw, manifest) + } + return manifests.get(spec.raw) +} + +// Returns the required manifest if the spec is missing from the tree +// Returns the found node if it is in the tree +const missingFromTree = async ({ spec, tree, flatOptions }) => { + if (spec.registry && spec.type !== 'tag') { + // registry spec that is not a specific tag. + const nodesBySpec = tree.inventory.query('packageName', spec.name) + for (const node of nodesBySpec) { + // package requested by name only (or name@*) + if (spec.rawSpec === '*') { + return { node } + } + // package requested by specific version + if (spec.type === 'version' && (node.pkgid === spec.raw)) { + return { node } + } + // package requested by version range, only remaining registry type + if (semver.satisfies(node.package.version, spec.rawSpec)) { + return { node } + } + } + const manifest = await getManifest(spec, flatOptions) + return { manifest } + } else { + // non-registry spec, or a specific tag. Look up manifest and check + // resolved to see if it's in the tree. + const manifest = await getManifest(spec, flatOptions) + if (spec.type === 'directory') { + return { manifest } + } + const nodesByManifest = tree.inventory.query('packageName', manifest.name) + for (const node of nodesByManifest) { + if (node.package.resolved === manifest._resolved) { + // we have a package by the same name and the same resolved destination, nothing to add. + return { node } + } + } + return { manifest } + } +} const exec = async (opts) => { const { args = [], call = '', - color = false, localBin = resolve('./node_modules/.bin'), locationMsg = undefined, globalBin = '', + globalPath, output, - packages: _packages = [], + // dereference values because we manipulate it later + packages: [...packages] = [], path = '.', runPath = '.', scriptShell = isWindows ? process.env.ComSpec || 'cmd' : 'sh', - yes = undefined, ...flatOptions } = opts - const log = flatOptions.log || logger - // dereferences values because we manipulate it later - const packages = [..._packages] - const pathArr = [...PATH] - const _run = () => runScript({ + let yes = opts.yes + const run = () => runScript({ args, call, - color, flatOptions, locationMsg, - log, output, path, - pathArr, + binPaths, runPath, scriptShell, }) - // nothing to maybe install, skip the arborist dance + // interactive mode if (!call && !args.length && !packages.length) { - return await _run() + return run() } - const needPackageCommandSwap = args.length && !packages.length - // if there's an argument and no package has been explicitly asked for - // check the local and global bin paths for a binary named the same as - // the argument and run it if it exists, otherwise fall through to - // the behavior of treating the single argument as a package name + let needPackageCommandSwap = (args.length > 0) && (packages.length === 0) + // If they asked for a command w/o specifying a package, see if there is a + // bin that directly matches that name: + // - in the local package itself + // - in the local tree + // - globally if (needPackageCommandSwap) { - let binExists = false - const dir = dirname(dirname(localBin)) - const localBinPath = await localFileExists(dir, args[0]) - if (localBinPath) { - pathArr.unshift(localBinPath) - binExists = true - } else if (await fileExists(`${globalBin}/${args[0]}`)) { - pathArr.unshift(globalBin) - binExists = true + let localManifest + try { + localManifest = await pacote.manifest(path, flatOptions) + } catch { + // no local package.json? no problem, move one. } - - if (binExists) { - return await _run() + if (localManifest?.bin?.[args[0]]) { + // we have to install the local package into the npx cache so that its + // bin links get set up + flatOptions.installLinks = false + // args[0] will exist when the package is installed + packages.push(path) + yes = true + needPackageCommandSwap = false + } else { + const dir = dirname(dirname(localBin)) + const localBinPath = await localFileExists(dir, args[0], '/') + if (localBinPath) { + binPaths.push(localBinPath) + return await run() + } else if (globalPath && await fileExists(`${globalBin}/${args[0]}`)) { + binPaths.push(globalBin) + return await run() + } + // We swap out args[0] with the bin from the manifest later + packages.push(args[0]) } - - packages.push(args[0]) } - // If we do `npm exec foo`, and have a `foo` locally, then we'll - // always use that, so we don't really need to fetch the manifest. - // So: run npa on each packages entry, and if it is a name with a - // rawSpec==='', then try to readPackageJson at - // node_modules/${name}/package.json, and only pacote fetch if - // that fails. - const manis = await Promise.all(packages.map(async p => { - const spec = npa(p, path) - if (spec.type === 'tag' && spec.rawSpec === '') { - // fall through to the pacote.manifest() approach - try { - const pj = resolve(path, 'node_modules', spec.name, 'package.json') - return await readPackageJson(pj) - } catch (er) {} + // Resolve any directory specs so that the npx directory is unique to the + // resolved directory, not the potentially relative one (i.e. "npx .") + for (const i in packages) { + const pkg = packages[i] + const spec = npa(pkg) + if (spec.type === 'directory') { + packages[i] = spec.fetchSpec + } + } + + const localArb = new Arborist({ ...flatOptions, path }) + const localTree = await localArb.loadActual() + + // Find anything that isn't installed locally + const needInstall = [] + let commandManifest + await Promise.all(packages.map(async (pkg, i) => { + const spec = npa(pkg, path) + const { manifest, node } = await missingFromTree({ spec, tree: localTree, flatOptions }) + if (manifest) { + // Package does not exist in the local tree + needInstall.push({ spec, manifest }) + if (i === 0) { + commandManifest = manifest + } + } else if (i === 0) { + // The node.package has enough to look up the bin + commandManifest = node.package } - // Force preferOnline to true so we are making sure to pull in the latest - // This is especially useful if the user didn't give us a version, and - // they expect to be running @latest - return await pacote.manifest(p, { - ...flatOptions, - preferOnline: true, - }) })) if (needPackageCommandSwap) { - args[0] = getBinFromManifest(manis[0]) + const spec = npa(args[0]) + + if (spec.type === 'directory') { + yes = true + } + + args[0] = getBinFromManifest(commandManifest) + + if (needInstall.length > 0 && globalPath) { + // See if the package is installed globally, and run the translated bin + const globalArb = new Arborist({ ...flatOptions, path: globalPath, global: true }) + const globalTree = await globalArb.loadActual() + const { manifest: globalManifest } = + await missingFromTree({ spec, tree: globalTree, flatOptions }) + if (!globalManifest && await fileExists(`${globalBin}/${args[0]}`)) { + binPaths.push(globalBin) + return await run() + } + } } - // figure out whether we need to install stuff, or if local is fine - const localArb = new Arborist({ - ...flatOptions, - path, - }) - const tree = await localArb.loadActual() - - // do we have all the packages in manifest list? - const needInstall = - manis.some(manifest => manifestMissing({ tree, manifest })) - - if (needInstall) { + const add = [] + if (needInstall.length > 0) { + // Install things to the npx cache, if needed const { npxCache } = flatOptions - const installDir = cacheInstallDir({ npxCache, packages }) - await mkdirp(installDir) - const arb = new Arborist({ + if (!npxCache) { + throw new Error('Must provide a valid npxCache path') + } + const hash = crypto.createHash('sha512') + .update(packages.map(p => { + // Keeps the npx directory unique to the resolved directory, not the + // potentially relative one (i.e. "npx .") + const spec = npa(p) + if (spec.type === 'directory') { + return spec.fetchSpec + } + return p + }).sort((a, b) => a.localeCompare(b, 'en')).join('\n')) + .digest('hex') + .slice(0, 16) + const installDir = resolve(npxCache, hash) + await mkdir(installDir, { recursive: true }) + const npxArb = new Arborist({ ...flatOptions, path: installDir, }) - const tree = await arb.loadActual() - - // at this point, we have to ensure that we get the exact same - // version, because it's something that has only ever been installed - // by npm exec in the cache install directory - const add = manis.filter(mani => manifestMissing({ - tree, - manifest: { - ...mani, - _from: `${mani.name}@${mani.version}`, - }, + const npxTree = await npxArb.loadActual() + await Promise.all(needInstall.map(async ({ spec }) => { + const { manifest } = await missingFromTree({ spec, tree: npxTree, flatOptions }) + if (manifest) { + // Manifest is not in npxCache, we need to install it there + if (!spec.registry) { + add.push(manifest._from) + } else { + add.push(manifest._id) + } + } })) - .map(mani => mani._from) - .sort((a, b) => a.localeCompare(b, 'en')) - // no need to install if already present if (add.length) { if (!yes) { // set -n to always say no @@ -157,7 +244,7 @@ const exec = async (opts) => { throw new Error('canceled') } - if (noTTY() || ciDetect()) { + if (noTTY() || ciInfo.isCI) { log.warn('exec', `The following package${ add.length === 1 ? ' was' : 's were' } not found and will be installed: ${ @@ -169,24 +256,22 @@ const exec = async (opts) => { const prompt = `Need to install the following packages:\n${ addList }Ok to proceed? ` - if (typeof log.clearProgress === 'function') { - log.clearProgress() - } + npmlog.clearProgress() const confirm = await read({ prompt, default: 'y' }) if (confirm.trim().toLowerCase().charAt(0) !== 'y') { throw new Error('canceled') } } } - await arb.reify({ + await npxArb.reify({ ...flatOptions, add, }) } - pathArr.unshift(resolve(installDir, 'node_modules/.bin')) + binPaths.push(resolve(installDir, 'node_modules/.bin')) } - return await _run() + return await run() } module.exports = exec diff --git a/workspaces/libnpmexec/lib/manifest-missing.js b/workspaces/libnpmexec/lib/manifest-missing.js deleted file mode 100644 index aec1281..0000000 --- a/workspaces/libnpmexec/lib/manifest-missing.js +++ /dev/null @@ -1,19 +0,0 @@ -const manifestMissing = ({ tree, manifest }) => { - // if the tree doesn't have a child by that name/version, return true - // true means we need to install it - const child = tree.children.get(manifest.name) - // if no child, we have to load it - if (!child) { - return true - } - - // if no version/tag specified, allow whatever's there - if (manifest._from === `${manifest.name}@`) { - return false - } - - // otherwise the version has to match what we WOULD get - return child.version !== manifest.version -} - -module.exports = manifestMissing diff --git a/workspaces/libnpmexec/lib/run-script.js b/workspaces/libnpmexec/lib/run-script.js index 851f5c6..ba60395 100644 --- a/workspaces/libnpmexec/lib/run-script.js +++ b/workspaces/libnpmexec/lib/run-script.js @@ -1,9 +1,9 @@ -const { delimiter } = require('path') - const chalk = require('chalk') -const ciDetect = require('@npmcli/ci-detect') +const ciInfo = require('ci-info') const runScript = require('@npmcli/run-script') const readPackageJson = require('read-package-json-fast') +const npmlog = require('npmlog') +const log = require('proc-log') const noTTY = require('./no-tty.js') const nocolor = { @@ -15,18 +15,17 @@ const nocolor = { const run = async ({ args, call, - color, flatOptions, locationMsg, - log, output = () => {}, path, - pathArr, + binPaths, runPath, scriptShell, }) => { // turn list of args into command string const script = call || args.shift() || scriptShell + const color = !!flatOptions.color const colorize = color ? chalk : nocolor // do the fakey runScript dance @@ -41,16 +40,12 @@ const run = async ({ }, } - if (log && log.disableProgress) { - log.disableProgress() - } + npmlog.disableProgress() try { if (script === scriptShell) { - const isTTY = !noTTY() - - if (isTTY) { - if (ciDetect()) { + if (!noTTY()) { + if (ciInfo.isCI) { return log.warn('exec', 'Interactive mode disabled in CI environment') } @@ -71,18 +66,14 @@ const run = async ({ banner: false, // we always run in cwd, not --prefix path: runPath, - stdioString: true, + binPaths, event: 'npx', args, - env: { - PATH: pathArr.join(delimiter), - }, stdio: 'inherit', + scriptShell, }) } finally { - if (log && log.enableProgress) { - log.enableProgress() - } + npmlog.enableProgress() } } diff --git a/workspaces/libnpmexec/package.json b/workspaces/libnpmexec/package.json index 4410f18..f1cefd2 100644 --- a/workspaces/libnpmexec/package.json +++ b/workspaces/libnpmexec/package.json @@ -1,16 +1,20 @@ { "name": "libnpmexec", - "version": "3.0.3", + "version": "5.0.6", "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "main": "lib/index.js", "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "description": "npm exec (npx) programmatic API", - "repository": "https://github.com/npm/libnpmexec", + "repository": { + "type": "git", + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/libnpmexec" + }, "keywords": [ "npm", "npmcli", @@ -29,40 +33,50 @@ ], "license": "ISC", "scripts": { - "lint": "eslint '**/*.js'", - "posttest": "npm run lint", + "lint": "eslint \"**/*.js\"", + "posttest": "node ../.. run lint", "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "postlint": "npm-template-check", - "lintfix": "npm run lint -- --fix" + "postlint": "template-oss-check", + "lintfix": "node ../.. run lint -- --fix", + "template-oss-apply": "template-oss-apply --force" }, "tap": { "color": true, - "check-coverage": true, - "files": "test/*.js" + "files": "test/*.js", + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "bin-links": "^3.0.0", - "tap": "^15.0.6" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/mock-registry": "^1.0.0", + "@npmcli/template-oss": "4.11.0", + "bin-links": "^4.0.1", + "just-extend": "^6.1.1", + "just-safe-set": "^4.1.1", + "minify-registry-metadata": "^3.0.0", + "mkdirp": "^1.0.4", + "tap": "^16.3.2" }, "dependencies": { - "@npmcli/arborist": "^4.0.0", - "@npmcli/ci-detect": "^2.0.0", - "@npmcli/run-script": "^2.0.0", + "@npmcli/arborist": "^6.1.5", + "@npmcli/run-script": "^6.0.0", "chalk": "^4.1.0", - "mkdirp-infer-owner": "^2.0.0", - "npm-package-arg": "^8.1.2", - "pacote": "^12.0.0", - "proc-log": "^1.0.0", + "ci-info": "^3.7.0", + "npm-package-arg": "^10.1.0", + "npmlog": "^7.0.1", + "pacote": "^15.0.7", + "proc-log": "^3.0.0", "read": "^1.0.7", - "read-package-json-fast": "^2.0.2", + "read-package-json-fast": "^3.0.1", + "semver": "^7.3.7", "walk-up-path": "^1.0.0" }, "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" } } diff --git a/workspaces/libnpmexec/test/cache-install-dir.js b/workspaces/libnpmexec/test/cache-install-dir.js deleted file mode 100644 index 9a7aee6..0000000 --- a/workspaces/libnpmexec/test/cache-install-dir.js +++ /dev/null @@ -1,12 +0,0 @@ -const t = require('tap') - -const cacheInstallDir = require('../lib/cache-install-dir.js') - -t.test('invalid npxCache path', t => { - t.throws( - () => cacheInstallDir({}), - /Must provide a valid npxCache path/, - 'should throw invalid path error' - ) - t.end() -}) diff --git a/workspaces/libnpmexec/test/fixtures/setup.js b/workspaces/libnpmexec/test/fixtures/setup.js new file mode 100644 index 0000000..84c404c --- /dev/null +++ b/workspaces/libnpmexec/test/fixtures/setup.js @@ -0,0 +1,256 @@ + +const fs = require('fs/promises') +const { existsSync } = require('fs') +const { resolve, extname, join } = require('path') +const binLinks = require('bin-links') +const MockRegistry = require('@npmcli/mock-registry') +const justExtend = require('just-extend') +const set = require('just-safe-set') + +const merge = (...args) => justExtend(true, ...args) + +const DEFAULT_BIN_FILE = 'bin-file.js' + +const createPkg = ({ + name = '@npmcli/create-index', + bin, + files, + versions = [], + version, + localVersion, +}) => { + if (localVersion && !versions.includes(localVersion)) { + versions = [...versions, localVersion] + } + if (version && !versions.includes(version)) { + versions = [...versions, version] + } + + const defaultBinName = name.includes('/') ? name.split('/')[1] : name + + if (!bin) { + bin = { + [defaultBinName]: `./${DEFAULT_BIN_FILE}`, + } + } + + const pkgsArr = versions.map((v) => ({ + name, + version: v, + bin, + })) + + const pkgs = {} + const tarballs = {} + const fixtures = {} + + for (const pkg of pkgsArr) { + pkgs[pkg.version] = pkg + } + + if (localVersion) { + set(fixtures, ['node_modules', ...name.split('/')], { + 'package.json': pkgs[localVersion], + ...files || { + [DEFAULT_BIN_FILE]: { key: name, value: `local-${localVersion}` }, + }, + }) + fixtures['package.json'] = { + name: 'pkg', + version: '9.9.9', + dependencies: { + [name]: `^${localVersion}`, + }, + } + } + + for (const pkg of pkgsArr) { + const fixturePath = `${pkg.name}-${pkg.version}`.replace('/', '-') + set(fixtures, ['packages', fixturePath], { + 'package.json': pkg, + ...files || { + [DEFAULT_BIN_FILE]: { key: pkg.name, value: `packages-${pkg.version}` }, + }, + }) + tarballs[pkg.version] = join('packages', fixturePath) + } + + return { + pkg: pkgsArr[0], + pkgs, + fixtures, + package: ({ registry, path, tarballs: tgz = versions, ...opts }) => registry.package({ + times: 2, + manifest: registry.manifest({ name: pkgsArr[0].name, packuments: pkgsArr }), + tarballs: tgz.reduce((acc, v) => { + acc[v] = resolve(path, tarballs[v]) + return acc + }, {}), + ...opts, + }), + } +} + +const createTestdir = (...objs) => { + const testdirHelper = (obj, ancestors = []) => { + for (const [key, value] of Object.entries(obj)) { + if (extname(key) === '.json') { + obj[key] = JSON.stringify(value, null, 2) + } else if (extname(key) === '.js' || ancestors.slice(-2).join('/') === 'node_modules/.bin') { + // a js or bin file is converted to a bin script that writes a file + obj[key] = `#!/usr/bin/env node\nrequire('fs').writeFileSync( + 'output-${value.key.replace('/', '-')}', + JSON.stringify({ + value: '${value.value}', + args: process.argv.slice(2), + created: '${[...ancestors, key].join('/')}', + }) + )` + } else if (value && typeof value === 'object') { + obj[key] = testdirHelper(value, [...ancestors, key]) + } else { + obj[key] = value + } + } + return obj + } + + return testdirHelper(merge(...objs)) +} + +const setup = (t, { + pkg, + testdir: _testdir = {}, + mocks, + global, + debug, + execPath, + defaults = true, +} = {}) => { + const registry = new MockRegistry({ + tap: t, + registry: 'http://smoke-test-registry.club/', + strict: true, + debug, + }) + + if (debug) { + process.on('log', console.error) + t.teardown(() => process.off('log', console.error)) + } + + const { node_modules: testdirNm, ...testdir } = _testdir + const fullTestdir = createTestdir({ + cache: {}, + npxCache: {}, + ...testdirNm ? + global ? { + global: { + node_modules: { + '.bin': {}, + ...testdirNm, + }, + }, + } : { + node_modules: { + '.bin': {}, + ...testdirNm, + }, + } + : {}, + }, testdir) + + // quick way to remove undefined and null values that we merged + // in to not write certain directories + const path = t.testdir(JSON.parse(JSON.stringify(fullTestdir, (_, v) => { + if (v === null) { + return + } + if (typeof v === 'string') { + return v.replace(/\{REGISTRY\}/g, registry.origin) + } + return v + })) + ) + + const cache = resolve(path, 'cache') + const npxCache = resolve(path, 'npxCache') + const nodeModules = resolve(path, global ? 'global/node_modules' : 'node_modules') + + const defaultOpts = { + call: '', + color: false, + localBin: '', + globalBin: '', + packages: [], + scriptShell: undefined, + yes: true, + path, + runPath: path, + } + + const baseOpts = { + audit: false, + registry: registry.origin + '/', + ...existsSync(cache) ? { cache } : {}, + ...existsSync(npxCache) ? { npxCache } : {}, + ...global ? { + globalBin: resolve(path, nodeModules, '.bin'), + globalPath: resolve(path, 'global'), + } : {}, + } + + return { + path, + registry, + chmod: async (chmodPath) => { + if (!chmodPath) { + for (const p of [].concat(pkg)) { + await fs.chmod(resolve(path, nodeModules, p.name, DEFAULT_BIN_FILE), 0o775) + } + return + } + return fs.chmod(resolve(path, chmodPath), 0o775) + }, + binLinks: async (binPkg) => { + if (!binPkg) { + for (const p of [].concat(pkg)) { + await binLinks({ + pkg: p, + path: resolve(path, nodeModules, p.name), + }) + } + return + } + await binLinks({ + pkg: binPkg, + path: resolve(path, nodeModules, binPkg.name), + }) + }, + readOutput: async (outputPath, { root = path } = {}) => { + if (!outputPath) { + outputPath = pkg.name.replace('/', '-') + } + return fs.readFile(resolve(root, `output-${outputPath}`), 'utf-8').then(r => JSON.parse(r)) + }, + rmOutput: (outputPath, { root = path } = {}) => { + if (!outputPath) { + outputPath = pkg.name.replace('/', '-') + } + return fs.rm(resolve(root, `output-${outputPath}`)) + }, + exec: (opts) => t.mock(execPath || '../../lib/index.js', mocks)({ + ...defaults ? { + ...defaultOpts, + path, + runPath: path, + } : {}, + ...baseOpts, + ...opts, + }), + } +} + +module.exports.setup = setup +module.exports.createPkg = createPkg +module.exports.merge = merge diff --git a/workspaces/libnpmexec/test/index.js b/workspaces/libnpmexec/test/index.js index cbd3eda..008560e 100644 --- a/workspaces/libnpmexec/test/index.js +++ b/workspaces/libnpmexec/test/index.js @@ -1,747 +1,16 @@ -const fs = require('fs') -const { resolve } = require('path') const t = require('tap') -const binLinks = require('bin-links') - -const libexec = require('../lib/index.js') - -// setup server -const registryServer = require('./registry/server.js') -const { registry } = registryServer -t.test('setup server', { bail: true, buffered: false }, registryServer) - -const baseOpts = { - audit: false, - call: '', - color: false, - localBin: '', - globalBin: '', - packages: [], - path: '', - registry, - runPath: '', - scriptShell: undefined, - yes: true, -} - -t.test('local pkg', async t => { - const pkg = { - name: 'pkg', - bin: { - a: 'index.js', - }, - } - const path = t.testdir({ - cache: {}, - npxCache: {}, - node_modules: { - '.bin': {}, - a: { - 'index.js': `#!/usr/bin/env node -require('fs').writeFileSync(process.argv.slice(2)[0], 'LOCAL PKG')`, - }, - }, - 'package.json': JSON.stringify(pkg), - }) - const localBin = resolve(path, 'node_modules/.bin') - const runPath = path - - const executable = resolve(path, 'node_modules/a') - fs.chmodSync(executable, 0o775) - - await binLinks({ - path: resolve(path, 'node_modules/a'), - pkg, - }) - - await libexec({ - ...baseOpts, - args: ['a', 'resfile'], - localBin, - path, - runPath, - }) - - const res = fs.readFileSync(resolve(path, 'resfile')).toString() - t.equal(res, 'LOCAL PKG', 'should run local pkg bin script') -}) - -t.test('local pkg, must not fetch manifest for avail pkg', async t => { - const pkg = { - name: '@ruyadorno/create-index', - version: '2.0.0', - bin: { - 'create-index': './index.js', - }, - } - const path = t.testdir({ - cache: {}, - npxCache: {}, - node_modules: { - '.bin': {}, - '@ruyadorno': { - 'create-index': { - 'package.json': JSON.stringify(pkg), - 'index.js': `#!/usr/bin/env node - require('fs').writeFileSync(process.argv.slice(2)[0], 'LOCAL PKG')`, - }, - }, - }, - 'package.json': JSON.stringify({ - name: 'pkg', - dependencies: { - '@ruyadorno/create-index': '^2.0.0', - }, - }), - }) - const runPath = path - const cache = resolve(path, 'cache') - const npxCache = resolve(path, 'npxCache') - - const executable = - resolve(path, 'node_modules/@ruyadorno/create-index/index.js') - fs.chmodSync(executable, 0o775) - - await binLinks({ - path: resolve(path, 'node_modules/@ruyadorno/create-index'), - pkg, - }) - - await libexec({ - ...baseOpts, - cache, - npxCache, - packages: ['@ruyadorno/create-index'], - call: 'create-index resfile', - path, - runPath, - }) - - const res = fs.readFileSync(resolve(path, 'resfile')).toString() - t.equal(res, 'LOCAL PKG', 'should run local pkg bin script') -}) - -t.test('local file system path', async t => { - const path = t.testdir({ - cache: {}, - npxCache: {}, - a: { - 'package.json': JSON.stringify({ - name: 'a', - bin: { - a: './index.js', - }, - }), - 'index.js': `#!/usr/bin/env node -require('fs').writeFileSync(process.argv.slice(2)[0], 'LOCAL PKG')`, - }, - }) - const runPath = path - const cache = resolve(path, 'cache') - const npxCache = resolve(path, 'npxCache') - - const executable = resolve(path, 'a/index.js') - fs.chmodSync(executable, 0o775) - - await libexec({ - ...baseOpts, - args: [`file:${resolve(path, 'a')}`, 'resfile'], - cache, - npxCache, - path, - runPath, - }) - - const res = fs.readFileSync(resolve(path, 'resfile')).toString() - t.equal(res, 'LOCAL PKG', 'should run local pkg bin script') -}) - -t.test('global space pkg', async t => { - const pkg = { - name: 'a', - bin: { - a: 'index.js', - }, - } - const path = t.testdir({ - cache: {}, - npxCache: {}, - global: { - node_modules: { - '.bin': {}, - a: { - 'index.js': `#!/usr/bin/env node - require('fs').writeFileSync(process.argv.slice(2)[0], 'GLOBAL PKG')`, - 'package.json': JSON.stringify(pkg), - }, - }, - }, - }) - const globalBin = resolve(path, 'global/node_modules/.bin') - const runPath = path - - const executable = resolve(path, 'global/node_modules/a') - fs.chmodSync(executable, 0o775) - - await binLinks({ - path: resolve(path, 'global/node_modules/a'), - pkg, - }) - - await libexec({ - ...baseOpts, - args: ['a', 'resfile'], - globalBin, - path, - runPath, - }) - - const res = fs.readFileSync(resolve(path, 'resfile')).toString() - t.equal(res, 'GLOBAL PKG', 'should run local pkg bin script') -}) - -t.test('run from registry', async t => { - const testdir = t.testdir({ - cache: {}, - npxCache: {}, - work: {}, - }) - const path = resolve(testdir, 'work') - const runPath = path - const cache = resolve(testdir, 'cache') - const npxCache = resolve(testdir, 'npxCache') - - t.throws( - () => fs.statSync(resolve(path, 'index.js')), - { code: 'ENOENT' }, - 'should not have template file' - ) - - await libexec({ - ...baseOpts, - args: ['@ruyadorno/create-index'], - cache, - npxCache, - path, - runPath, - }) - - t.ok(fs.statSync(resolve(path, 'index.js')).isFile(), 'ran create pkg') -}) - -t.test('avoid install when exec from registry an available pkg', async t => { - const testdir = t.testdir({ - cache: {}, - npxCache: {}, - work: {}, - }) - const path = resolve(testdir, 'work') - const runPath = path - const cache = resolve(testdir, 'cache') - const npxCache = resolve(testdir, 'npxCache') - - t.throws( - () => fs.statSync(resolve(path, 'index.js')), - { code: 'ENOENT' }, - 'should not have template file' - ) - - await libexec({ - ...baseOpts, - args: ['@ruyadorno/create-index'], - cache, - npxCache, - path, - runPath, - }) - - t.ok(fs.statSync(resolve(path, 'index.js')).isFile(), 'ran create pkg') - fs.unlinkSync(resolve(path, 'index.js')) - - await libexec({ - ...baseOpts, - args: ['@ruyadorno/create-index'], - cache, - npxCache, - path, - runPath, - }) - - t.ok(fs.statSync(resolve(path, 'index.js')).isFile(), 'ran create pkg again') -}) - -t.test('run multiple from registry', async t => { - const testdir = t.testdir({ - cache: {}, - npxCache: {}, - work: {}, - }) - const path = resolve(testdir, 'work') - const runPath = path - const cache = resolve(testdir, 'cache') - const npxCache = resolve(testdir, 'npxCache') - - t.throws( - () => fs.statSync(resolve(path, 'index.js')), - { code: 'ENOENT' }, - 'should not have index template file' - ) - - t.throws( - () => fs.statSync(resolve(path, 'test.js')), - { code: 'ENOENT' }, - 'should not have test template file' - ) - - await libexec({ - ...baseOpts, - packages: ['@ruyadorno/create-test', '@ruyadorno/create-index'], - call: ['create-test && create-index'], - cache, - npxCache, - path, - runPath, - }) - - t.ok(fs.statSync(resolve(path, 'index.js')).isFile(), 'ran index pkg') - t.ok(fs.statSync(resolve(path, 'test.js')).isFile(), 'ran test pkg') -}) +const { setup } = require('./fixtures/setup.js') t.test('no args', async t => { - const path = t.testdir({}) - const runPath = path - const libexec = t.mock('../lib/index.js', { - '../lib/run-script': ({ args }) => { - t.ok(args.length === 0, 'should call run-script with no args') - }, - }) + t.plan(1) - await libexec({ - ...baseOpts, - path, - runPath, - }) -}) - -t.test('prompt, accepts', async t => { - const testdir = t.testdir({ - cache: {}, - npxCache: {}, - work: {}, - }) - const path = resolve(testdir, 'work') - const runPath = path - const cache = resolve(testdir, 'cache') - const npxCache = resolve(testdir, 'npxCache') - t.test('with clearProgress function', async t => { - const libexec = t.mock('../lib/index.js', { - '@npmcli/ci-detect': () => false, - 'proc-log': { - clearProgress () { - t.ok(true, 'should call clearProgress function') - }, - }, - read (opts, cb) { - cb(null, 'y') - }, - '../lib/no-tty.js': () => false, - }) - - await libexec({ - ...baseOpts, - args: ['@ruyadorno/create-index'], - cache, - npxCache, - path, - runPath, - yes: undefined, - }) - - const installedDir = resolve(npxCache, - '0e8e15840a234288/node_modules/@ruyadorno/create-index/package.json') - t.ok(fs.statSync(installedDir).isFile(), 'installed required packages') - }) - - t.test('without clearProgress function', async t => { - const libexec = t.mock('../lib/index.js', { - '@npmcli/ci-detect': () => false, - 'proc-log': {}, - read (opts, cb) { - cb(null, 'y') - }, - '../lib/no-tty.js': () => false, - }) - - await libexec({ - ...baseOpts, - args: ['@ruyadorno/create-index'], - cache, - npxCache, - path, - runPath, - yes: undefined, - }) - - const installedDir = resolve(npxCache, - '0e8e15840a234288/node_modules/@ruyadorno/create-index/package.json') - t.ok(fs.statSync(installedDir).isFile(), 'installed required packages') - }) -}) - -t.test('prompt, refuses', async t => { - const testdir = t.testdir({ - cache: {}, - npxCache: {}, - work: {}, - }) - const path = resolve(testdir, 'work') - const runPath = path - const cache = resolve(testdir, 'cache') - const npxCache = resolve(testdir, 'npxCache') - t.test('with clearProgress function', async t => { - const libexec = t.mock('../lib/index.js', { - '@npmcli/ci-detect': () => false, - 'proc-log': { - clearProgress () { - t.ok(true, 'should call clearProgress function') - }, - }, - read (opts, cb) { - cb(null, 'n') - }, - '../lib/no-tty.js': () => false, - }) - - await t.rejects( - libexec({ - ...baseOpts, - args: ['@ruyadorno/create-index'], - cache, - npxCache, - path, - runPath, - yes: undefined, - }), - /canceled/, - 'should throw with canceled error' - ) - - const installedDir = resolve(npxCache, - '0e8e15840a234288/node_modules/@ruyadorno/create-index/package.json') - - t.throws( - () => fs.statSync(installedDir), - { code: 'ENOENT' }, - 'should not have installed required packages' - ) - }) - - t.test('without clearProgress function', async t => { - const libexec = t.mock('../lib/index.js', { - '@npmcli/ci-detect': () => false, - 'proc-log': {}, - read (opts, cb) { - cb(null, 'n') - }, - '../lib/no-tty.js': () => false, - }) - - await t.rejects( - libexec({ - ...baseOpts, - args: ['@ruyadorno/create-index'], - cache, - npxCache, - path, - runPath, - yes: undefined, - }), - /canceled/, - 'should throw with canceled error' - ) - - const installedDir = resolve(npxCache, - '0e8e15840a234288/node_modules/@ruyadorno/create-index/package.json') - - t.throws( - () => fs.statSync(installedDir), - { code: 'ENOENT' }, - 'should not have installed required packages' - ) - }) -}) - -t.test('prompt, -n', async t => { - const testdir = t.testdir({ - cache: {}, - npxCache: {}, - work: {}, - }) - const path = resolve(testdir, 'work') - const runPath = path - const cache = resolve(testdir, 'cache') - const npxCache = resolve(testdir, 'npxCache') - - await t.rejects( - libexec({ - ...baseOpts, - args: ['@ruyadorno/create-index'], - cache, - npxCache, - path, - runPath, - yes: false, - }), - /canceled/, - 'should throw with canceled error' - ) - - const installedDir = resolve(npxCache, - '0e8e15840a234288/node_modules/@ruyadorno/create-index/package.json') - - t.throws( - () => fs.statSync(installedDir), - { code: 'ENOENT' }, - 'should not have installed required packages' - ) -}) - -t.test('no prompt if no tty', async t => { - const testdir = t.testdir({ - cache: {}, - npxCache: {}, - work: {}, - }) - const path = resolve(testdir, 'work') - const runPath = path - const cache = resolve(testdir, 'cache') - const npxCache = resolve(testdir, 'npxCache') - const libexec = t.mock('../lib/index.js', { - '../lib/no-tty.js': () => true, - }) - - await libexec({ - ...baseOpts, - args: ['@ruyadorno/create-index'], - cache, - npxCache, - path, - runPath, - yes: undefined, - }) - - const installedDir = resolve(npxCache, - '0e8e15840a234288/node_modules/@ruyadorno/create-index/package.json') - t.ok(fs.statSync(installedDir).isFile(), 'installed required packages') -}) - -t.test('no prompt if CI', async t => { - const testdir = t.testdir({ - cache: {}, - npxCache: {}, - work: {}, - }) - const path = resolve(testdir, 'work') - const runPath = path - const cache = resolve(testdir, 'cache') - const npxCache = resolve(testdir, 'npxCache') - const libexec = t.mock('../lib/index.js', { - '@npmcli/ci-detect': () => true, - }) - - await libexec({ - ...baseOpts, - args: ['@ruyadorno/create-index'], - cache, - npxCache, - path, - runPath, - yes: undefined, - }) - - const installedDir = resolve(npxCache, - '0e8e15840a234288/node_modules/@ruyadorno/create-index/package.json') - t.ok(fs.statSync(installedDir).isFile(), 'installed required packages') -}) - -t.test('no prompt if CI, multiple packages', async t => { - const testdir = t.testdir({ - cache: {}, - npxCache: {}, - work: {}, - }) - const path = resolve(testdir, 'work') - const runPath = path - const cache = resolve(testdir, 'cache') - const npxCache = resolve(testdir, 'npxCache') - const libexec = t.mock('../lib/index.js', { - '@npmcli/ci-detect': () => true, - 'proc-log': { - warn (title, msg) { - t.equal(title, 'exec', 'should warn exec title') - const expected = 'The following packages were not found and will be ' + - 'installed: @ruyadorno/create-index, @ruyadorno/create-test' - t.equal(msg, expected, 'should warn installing pkg') + const { exec } = setup(t, { + mocks: { + '../../lib/run-script': ({ args }) => { + t.ok(args.length === 0, 'should call run-script with no args') }, }, }) - await libexec({ - ...baseOpts, - call: 'create-index', - packages: ['@ruyadorno/create-index', '@ruyadorno/create-test'], - cache, - npxCache, - path, - runPath, - yes: undefined, - }) -}) - -t.test('sane defaults', async t => { - const testdir = t.testdir({ - cache: {}, - npxCache: {}, - work: {}, - }) - const cache = resolve(testdir, 'cache') - const npxCache = resolve(testdir, 'npxCache') - const workdir = resolve(testdir, 'work') - - const cwd = process.cwd() - process.chdir(workdir) - t.teardown(() => { - process.chdir(cwd) - }) - - await libexec({ - args: ['@ruyadorno/create-index'], - cache, - npxCache, - yes: true, - }) - - t.ok(fs.statSync(resolve(workdir, 'index.js')).isFile(), - 'ran create-index pkg') -}) - -t.test('scriptShell default value', t => { - t.test('/bin/sh platforms', t => { - t.plan(1) - const libexec = t.mock('../lib/index.js', { - '../lib/is-windows.js': false, - '../lib/run-script.js': (opt) => { - t.equal(opt.scriptShell, 'sh', 'should use expected shell value') - }, - }) - libexec({ args: [], runPath: t.testDirName }) - }) - - t.test('win32 defined ComSpec env var', t => { - t.plan(1) - const comspec = process.env.ComSpec - process.env.ComSpec = 'CMD' - const libexec = t.mock('../lib/index.js', { - '../lib/is-windows.js': true, - '../lib/run-script.js': ({ scriptShell }) => { - t.equal(scriptShell, 'CMD', 'should use expected ComSpec value') - process.env.ComSpec = comspec - }, - }) - libexec({ args: [], runPath: t.testDirName }) - }) - - t.test('win32 cmd', t => { - t.plan(1) - const comspec = process.env.ComSpec - process.env.ComSpec = '' - const libexec = t.mock('../lib/index.js', { - '../lib/is-windows.js': true, - '../lib/run-script.js': ({ scriptShell }) => { - t.equal(scriptShell, 'cmd', 'should use expected cmd default value') - process.env.ComSpec = comspec - }, - }) - libexec({ args: [], runPath: t.testDirName }) - }) - - t.end() -}) - -t.test('workspaces', async t => { - const pkg = { - name: '@ruyadorno/create-index', - version: '2.0.0', - bin: { - 'create-index': './index.js', - }, - } - const path = t.testdir({ - cache: {}, - npxCache: {}, - node_modules: { - '.bin': {}, - '@ruyadorno': { - 'create-index': { - 'package.json': JSON.stringify(pkg), - 'index.js': `#!/usr/bin/env node - require('fs').writeFileSync('resfile', 'LOCAL PKG')`, - }, - }, - a: t.fixture('symlink', '../a'), - }, - 'package.json': JSON.stringify({ - name: 'project', - workspaces: ['a'], - }), - a: { - 'package.json': JSON.stringify({ - name: 'a', - version: '1.0.0', - dependencies: { - '@ruyadorno/create-index': '^2.0.0', - }, - }), - }, - }) - const runPath = path - const cache = resolve(path, 'cache') - const npxCache = resolve(path, 'npxCache') - - const executable = - resolve(path, 'node_modules/@ruyadorno/create-index/index.js') - fs.chmodSync(executable, 0o775) - - await binLinks({ - path: resolve(path, 'node_modules/@ruyadorno/create-index'), - pkg, - }) - - // runs at the project level - await libexec({ - ...baseOpts, - args: ['create-index'], - localBin: resolve(path, 'node_modules/.bin'), - cache, - npxCache, - path, - runPath, - }) - - const res = fs.readFileSync(resolve(path, 'resfile')).toString() - t.equal(res, 'LOCAL PKG', 'should run existing bin from project level') - - // runs at the child workspace level - await libexec({ - ...baseOpts, - args: ['create-index'], - cache, - npxCache, - localBin: resolve(path, 'a/node_modules/.bin'), - path: resolve(path, 'a'), - runPath: resolve(path, 'a'), - }) - - const wRes = fs.readFileSync(resolve(path, 'a/resfile')).toString() - t.equal(wRes, 'LOCAL PKG', 'should run existing bin from workspace level') + await exec() }) diff --git a/workspaces/libnpmexec/test/local.js b/workspaces/libnpmexec/test/local.js new file mode 100644 index 0000000..1959518 --- /dev/null +++ b/workspaces/libnpmexec/test/local.js @@ -0,0 +1,370 @@ +const log = require('proc-log') +const { resolve } = require('path') +const t = require('tap') +const fs = require('fs/promises') +const { resetSeen: resetSeenLinks } = require('bin-links') +const { setup, createPkg, merge } = require('./fixtures/setup.js') + +t.test('bin in local pkg', async t => { + const { pkg, fixtures } = createPkg({ + version: '1.0.0', + name: '@npmcli/local-pkg-bin-test', + bin: { + b: 'does-not-exist.js', + a: 'local-bin-test.js', + 'a-nested': 'bin-dir/nested-bin-test.js', + 'conflicting-bin': 'conflicting-bin-test.js', + }, + files: { + 'local-bin-test.js': { key: 'local-bin', value: 'LOCAL PKG' }, + 'conflicting-bin-test.js': { key: 'conflicting-bin', value: 'LOCAL PKG' }, + 'bin-dir': { + 'nested-bin-test.js': { key: 'nested-bin', value: 'LOCAL PKG' }, + }, + }, + }) + + const existingPkg = createPkg({ + name: 'pkg-with-conflicting-bin', + localVersion: '1.0.0', + bin: { + 'conflicting-bin': 'index.js', + }, + files: { + 'index.js': { key: 'existing-bin', value: 'NODE_MODULES PKG' }, + }, + }) + + const { exec: _exec, chmod, readOutput, binLinks, path } = setup(t, { + pkg, + testdir: merge( + existingPkg.fixtures, + fixtures.packages[`@npmcli-local-pkg-bin-test-1.0.0`], + { + node_modules: { + '@npmcli': { + 'some-other-pkg-with-same-scope': {}, + }, + }, + } + ), + }) + + const localBin = resolve(path, 'node_modules', '.bin') + + await chmod('local-bin-test.js') + await chmod('conflicting-bin-test.js') + await chmod('bin-dir/nested-bin-test.js') + await chmod('node_modules/pkg-with-conflicting-bin/index.js') + + // Note that we have to resetSeenLinks after each exec since otherwise + // our non-existent file will fail when it gets attempted to get chmod'ed + // in a real world situation these would happen during different + // processes where these is no shared cache + const exec = async (...args) => { + await _exec(...args) + resetSeenLinks() + } + + await exec({ localBin, args: ['a', 'argument-a'] }) + t.match(await readOutput('local-bin'), { + value: 'LOCAL PKG', + args: ['argument-a'], + }) + t.strictSame(await fs.readdir(resolve(path, 'node_modules', '.bin')), []) + + await exec({ localBin, args: ['a-nested', 'argument-a-nested'] }) + t.strictSame(await fs.readdir(resolve(path, 'node_modules', '.bin')), []) + t.match(await readOutput('nested-bin'), { + value: 'LOCAL PKG', + args: ['argument-a-nested'], + }) + + // now link a bin which will conflict with the one we try to run next + await binLinks(existingPkg.pkg) + + t.match(await fs.readdir(resolve(path, 'node_modules', '.bin')), ['conflicting-bin']) + await exec({ localBin, args: ['conflicting-bin'] }) + // local bin was called for conflicting-bin + t.match(await readOutput('conflicting-bin'), { + value: 'LOCAL PKG', + }) + + await t.rejects(() => exec({ localBin, args: ['b'] }), /command failed/) +}) + +t.test('locally available pkg - by scoped name only', async t => { + const { pkg, fixtures } = createPkg({ + name: '@npmcli/npx-local-test', + localVersion: '2.0.0', + }) + + const { exec, chmod, binLinks, readOutput } = setup(t, { + pkg, + testdir: fixtures, + }) + + await chmod() + await binLinks() + await exec({ args: ['@npmcli/npx-local-test', 'arg'] }) + + t.match(await readOutput(), { + value: 'local-2.0.0', + args: ['arg'], + }) +}) + +t.test('locally available pkg - by name', async t => { + const { pkg, fixtures } = createPkg({ + name: '@npmcli/create-index', + localVersion: '2.0.0', + }) + + const { chmod, binLinks, exec, readOutput } = setup(t, { + pkg, + testdir: fixtures, + }) + + await chmod() + await binLinks() + await exec({ + packages: ['@npmcli/create-index'], + call: 'create-index arg', + }) + + t.match(await readOutput(), { + value: 'local-2.0.0', + args: ['arg'], + }) +}) + +t.test('locally available pkg - by version', async t => { + const { pkg, fixtures } = createPkg({ + name: '@npmcli/create-index', + localVersion: '1.0.0', + }) + const { chmod, binLinks, exec, readOutput } = setup(t, { + pkg, + testdir: fixtures, + }) + + await chmod() + await binLinks() + await exec({ args: ['@npmcli/create-index@1.0.0'] }) + + t.match(await readOutput(), { + value: 'local-1.0.0', + args: [], + }) +}) + +t.test('locally available pkg - by range', async t => { + const { pkg, fixtures } = createPkg({ + name: '@npmcli/create-index', + localVersion: '2.0.0', + }) + const { chmod, binLinks, exec, readOutput } = setup(t, { + pkg, + testdir: fixtures, + }) + + await chmod() + await binLinks() + await exec({ + packages: ['@npmcli/create-index@^2.0.0'], + call: 'create-index resfile', + }) + + t.match(await readOutput(), { + value: 'local-2.0.0', + args: ['resfile'], + }) +}) + +t.test('locally available pkg - by latest tag', async t => { + const { pkg, fixtures, package } = createPkg({ + name: '@npmcli/create-index', + localVersion: '1.0.0', + }) + const { chmod, binLinks, exec, readOutput, registry, path } = setup(t, { + pkg, + testdir: merge(fixtures, { + node_modules: { + '.package-lock.json': { + name: 'lock', + lockfileVersion: 3, + requires: true, + packages: { + [`node_modules/${pkg.name}`]: { + ...pkg, + resolved: `{REGISTRY}/${pkg.name}/-/create-index-${pkg.version}.tgz`, + }, + }, + }, + }, + }), + }) + + // latest forces the manifest to be fetched + await package({ registry, path, times: 1, tarballs: [] }) + + await chmod() + await binLinks() + await exec({ + packages: ['@npmcli/create-index@latest'], + call: 'create-index resfile', + }) + + t.match(await readOutput(), { + value: 'local-1.0.0', + args: ['resfile'], + }) +}) + +t.test('multiple local pkgs', async t => { + const pkgFoo = createPkg({ + name: '@npmcli/create-foo', + localVersion: '2.0.0', + }) + + const pkgBar = createPkg({ + name: '@npmcli/create-bar', + localVersion: '1.0.0', + }) + + const { readOutput, chmod, exec, binLinks } = setup(t, { + pkg: [pkgFoo.pkg, pkgBar.pkg], + testdir: merge(pkgFoo.fixtures, pkgBar.fixtures), + }) + + await chmod() + await binLinks() + + await exec({ + packages: ['@npmcli/create-foo', '@npmcli/create-bar'], + call: 'create-foo resfile && create-bar bar', + }) + + t.match(await readOutput('@npmcli-create-foo'), { + value: 'local-2.0.0', + args: ['resfile'], + }) + t.match(await readOutput('@npmcli-create-bar'), { + value: 'local-1.0.0', + args: ['bar'], + }) +}) + +t.test('no npxCache', async t => { + const { chmod, exec, path } = setup(t, { + testdir: { + npxCache: null, + a: { + 'package.json': { + name: 'a', + bin: { + a: './index.js', + }, + }, + 'index.js': { key: 'a', value: 'LOCAL PKG' }, + }, + }, + }) + + await chmod('a/index.js') + + await t.rejects(() => exec({ + args: [`file:${resolve(path, 'a')}`, 'resfile'], + }), /Must provide a valid npxCache path/) +}) + +t.test('local file system path', async t => { + const { exec, chmod, readOutput, path } = setup(t, { + mocks: { + 'ci-info': { isCI: true }, + 'proc-log': { + ...log, + warn () { + t.fail('should not warn about local file package install') + }, + }, + }, + testdir: { + a: { + 'package.json': { + name: 'a', + bin: { + a: './index.js', + }, + }, + 'index.js': { key: 'a', value: 'LOCAL PKG' }, + }, + }, + }) + + await chmod('a/index.js') + + await exec({ + args: [`file:${resolve(path, 'a')}`, 'resfile'], + + }) + + t.match(await readOutput('a'), { + value: 'LOCAL PKG', + args: ['resfile'], + }) +}) + +t.test('global space pkg', async t => { + const { pkg, fixtures } = createPkg({ + name: 'a', + localVersion: '1.0.0', + }) + + const { exec, chmod, readOutput, binLinks } = setup(t, { + pkg, + global: true, + testdir: fixtures, + }) + + await chmod() + await binLinks() + + await exec({ + args: ['a', 'resfile'], + }) + + t.match(await readOutput(), { + value: 'local-1.0.0', + args: [], + created: 'global/node_modules/a/bin-file.js', + }) +}) + +t.test('global scoped pkg', async t => { + const { pkg, fixtures, package } = createPkg({ + localVersion: '1.0.0', + name: '@npmcli/create-test', + }) + + const { chmod, exec, readOutput, binLinks, registry, path } = setup(t, { + pkg, + global: true, + testdir: fixtures, + }) + + await chmod() + await binLinks() + + await package({ registry, path, times: 1, tarballs: [] }) + + await exec({ + args: ['@npmcli/create-test', 'resfile'], + }) + + t.match(await readOutput(), { + value: 'local-1.0.0', + args: ['resfile'], + created: 'global/node_modules/@npmcli/create-test/bin-file.js', + }) +}) diff --git a/workspaces/libnpmexec/test/manifest-missing.js b/workspaces/libnpmexec/test/manifest-missing.js deleted file mode 100644 index e7ce1c8..0000000 --- a/workspaces/libnpmexec/test/manifest-missing.js +++ /dev/null @@ -1,32 +0,0 @@ -const t = require('tap') -const Arborist = require('@npmcli/arborist') - -const manifestMissing = require('../lib/manifest-missing.js') - -t.test('missing version', async t => { - const path = t.testdir({ - node_modules: { - a: { - 'package.json': JSON.stringify({ - name: 'a', - version: '1.0.0', - }), - }, - }, - 'package.json': JSON.stringify({ - name: 'root', - dependencies: { - a: '^1.0.0', - }, - }), - }) - const arb = new Arborist({ - path, - }) - const tree = await arb.loadActual() - const manifest = { - name: 'a', - _from: 'a@', - } - t.notOk(manifestMissing({ tree, manifest }), 'manifest not missing') -}) diff --git a/workspaces/libnpmexec/test/prompt.js b/workspaces/libnpmexec/test/prompt.js new file mode 100644 index 0000000..ff93d8f --- /dev/null +++ b/workspaces/libnpmexec/test/prompt.js @@ -0,0 +1,384 @@ +const log = require('proc-log') +const { resolve } = require('path') +const t = require('tap') +const fs = require('fs/promises') +const { setup, createPkg, merge } = require('./fixtures/setup.js') + +t.test('prompt, accepts', async t => { + t.test('with clearProgress function', async t => { + const { pkg, package, fixtures } = createPkg({ + name: '@npmcli/create-index', + version: '1.0.0', + }) + const { exec, path, registry } = setup(t, { + testdir: fixtures, + mocks: { + 'ci-info': { isCI: false }, + '../../lib/no-tty.js': () => false, + npmlog: { + clearProgress () { + t.ok(true, 'should call clearProgress function') + }, + disableProgress () {}, + enableProgress () {}, + }, + read (_, cb) { + cb(null, 'y') + }, + }, + }) + + await package({ registry, path }) + + await exec({ + args: ['@npmcli/create-index'], + yes: undefined, + }) + + const installedDir = `npxCache/e7ce50d8d2d8ec11/node_modules/${pkg.name}/package.json` + t.ok(await fs.stat(resolve(path, installedDir)).then(f => f.isFile())) + }) + + t.test('without clearProgress function', async t => { + const { pkg, package, fixtures } = createPkg({ + name: '@npmcli/create-index', + version: '1.0.0', + }) + const { exec, path, registry } = setup(t, { + testdir: fixtures, + mocks: { + 'ci-info': { isCI: false }, + '../../lib/no-tty.js': () => false, + read (_, cb) { + cb(null, 'y') + }, + }, + }) + + await package({ registry, path }) + + await exec({ + args: ['@npmcli/create-index'], + yes: undefined, + }) + + const installedDir = `npxCache/e7ce50d8d2d8ec11/node_modules/${pkg.name}/package.json` + t.ok(await fs.stat(resolve(path, installedDir)).then(f => f.isFile())) + }) +}) + +t.test('prompt, refuses', async t => { + t.test('with clearProgress function', async t => { + t.plan(3) + + const { pkg, package, fixtures } = createPkg({ + name: '@npmcli/create-index', + version: '1.0.0', + }) + const { exec, path, registry } = setup(t, { + testdir: fixtures, + mocks: { + 'ci-info': { isCI: false }, + npmlog: { + clearProgress () { + t.ok(true, 'should call clearProgress function') + }, + disableProgess () {}, + }, + read (_, cb) { + cb(null, 'n') + }, + '../../lib/no-tty.js': () => false, + }, + }) + + await package({ registry, path, times: 1, tarballs: [] }) + + await t.rejects( + exec({ + args: ['@npmcli/create-index'], + yes: undefined, + }), + /canceled/, + 'should throw with canceled error' + ) + + const installedDir = `npxCache/e7ce50d8d2d8ec11/node_modules/${pkg.name}/package.json` + t.rejects( + () => fs.stat(resolve(path, installedDir)), + { code: 'ENOENT' } + ) + }) + + t.test('without clearProgress function', async t => { + const { pkg, package, fixtures } = createPkg({ + name: '@npmcli/create-index', + version: '1.0.0', + }) + const { exec, path, registry } = setup(t, { + testdir: fixtures, + mocks: { + 'ci-info': { isCI: false }, + read (_, cb) { + cb(null, 'n') + }, + '../../lib/no-tty.js': () => false, + }, + }) + + await package({ registry, path, times: 1, tarballs: [] }) + + await t.rejects( + exec({ + args: ['@npmcli/create-index'], + yes: undefined, + }), + /canceled/, + 'should throw with canceled error' + ) + + const installedDir = `npxCache/e7ce50d8d2d8ec11/node_modules/${pkg.name}/package.json` + t.rejects( + () => fs.stat(resolve(path, installedDir)), + { code: 'ENOENT' } + ) + }) +}) + +t.test('prompt, -n', async t => { + const { pkg, package, fixtures } = createPkg({ + name: '@npmcli/create-index', + version: '1.0.0', + }) + const { exec, path, registry } = setup(t, { + testdir: fixtures, + }) + + await package({ registry, path, times: 1, tarballs: [] }) + + await t.rejects( + exec({ + args: ['@npmcli/create-index'], + yes: false, + }), + /canceled/, + 'should throw with canceled error' + ) + + const installedDir = `npxCache/e7ce50d8d2d8ec11/node_modules/${pkg.name}/package.json` + t.rejects( + () => fs.stat(resolve(path, installedDir)), + { code: 'ENOENT' } + ) +}) + +t.test('no prompt if no tty', async t => { + const { pkg, package, fixtures } = createPkg({ + name: '@npmcli/create-index', + version: '1.0.0', + }) + const { exec, path, registry } = setup(t, { + testdir: fixtures, + mocks: { '../../lib/no-tty.js': () => true }, + }) + + await package({ registry, path }) + + await exec({ + args: ['@npmcli/create-index'], + yes: undefined, + }) + + const installedDir = `npxCache/e7ce50d8d2d8ec11/node_modules/${pkg.name}/package.json` + t.ok(await fs.stat(resolve(path, installedDir)).then(f => f.isFile())) +}) + +t.test('no prompt if CI', async t => { + const { pkg, package, fixtures } = createPkg({ + name: '@npmcli/create-index', + version: '1.0.0', + }) + const { exec, path, registry } = setup(t, { + testdir: fixtures, + mocks: { 'ci-info': { isCI: true } }, + }) + + await package({ registry, path }) + + await exec({ + args: ['@npmcli/create-index'], + yes: undefined, + }) + + const installedDir = `npxCache/e7ce50d8d2d8ec11/node_modules/${pkg.name}/package.json` + t.ok(await fs.stat(resolve(path, installedDir)).then(f => f.isFile())) +}) + +t.test('no prompt if CI, multiple packages', async t => { + t.plan(4) + + const pkgIndex = createPkg({ + name: '@npmcli/create-index', + version: '1.0.0', + }) + const pkgTest = createPkg({ + name: '@npmcli/create-test', + version: '1.0.0', + }) + const { exec, path, registry } = setup(t, { + testdir: merge(pkgIndex.fixtures, pkgTest.fixtures), + mocks: { + 'ci-info': { isCI: true }, + 'proc-log': { + ...log, + warn (title, msg) { + t.equal(title, 'exec', 'should warn exec title') + // this message is nondeterministic as it queries manifests so we just + // test the constituent parts + t.match( + msg, + 'The following packages were not found and will be installed:', + 'should warn installing packages' + ) + t.match(msg, '@npmcli/create-index@1.0.0', 'includes package being installed') + t.match(msg, '@npmcli/create-test@1.0.0', 'includes package being installed') + }, + }, + }, + }) + + await pkgIndex.package({ path, registry }) + await pkgTest.package({ path, registry }) + + await exec({ + call: 'create-index', + packages: ['@npmcli/create-index', '@npmcli/create-test'], + yes: undefined, + }) +}) + +t.test('defaults', async t => { + const { pkg, fixtures, package } = createPkg({ + name: '@npmcli/create-index', + version: '1.0.0', + }) + const { exec, path, registry, readOutput } = setup(t, { + pkg, + defaults: false, + execPath: '../../../lib/index.js', + testdir: { + ...fixtures, + work: {}, + }, + }) + + const workDir = resolve(path, 'work') + const cwd = process.cwd() + process.chdir(workDir) + t.teardown(() => process.chdir(cwd)) + + await package({ registry, path }) + + await exec({ + args: ['@npmcli/create-index'], + yes: true, + }) + + t.match(await readOutput('', { root: workDir }), { + value: 'packages-1.0.0', + args: [], + }) +}) + +t.test('scriptShell default value', async t => { + await t.test('/bin/sh platforms', async t => { + t.plan(1) + const mockexec = t.mock('../lib/index.js', { + '../lib/is-windows.js': false, + '../lib/run-script.js': (opt) => { + t.equal(opt.scriptShell, 'sh', 'should use expected shell value') + }, + }) + await mockexec({ args: [], runPath: t.testDirName }) + }) + + await t.test('win32 defined ComSpec env var', async t => { + t.plan(1) + const comspec = process.env.ComSpec + process.env.ComSpec = 'CMD' + const mockexec = t.mock('../lib/index.js', { + '../lib/is-windows.js': true, + '../lib/run-script.js': ({ scriptShell }) => { + t.equal(scriptShell, 'CMD', 'should use expected ComSpec value') + process.env.ComSpec = comspec + }, + }) + await mockexec({ args: [], runPath: t.testDirName }) + }) + + await t.test('win32 cmd', async t => { + t.plan(1) + const comspec = process.env.ComSpec + process.env.ComSpec = '' + const mockexec = t.mock('../lib/index.js', { + '../lib/is-windows.js': true, + '../lib/run-script.js': ({ scriptShell }) => { + t.equal(scriptShell, 'cmd', 'should use expected cmd default value') + process.env.ComSpec = comspec + }, + }) + await mockexec({ args: [], runPath: t.testDirName }) + }) +}) + +t.test('workspaces', async t => { + const { pkg, fixtures } = createPkg({ + name: '@npmcli/create-index', + localVersion: '2.0.0', + }) + + const { path, exec, chmod, binLinks, readOutput } = setup(t, { + pkg, + testdir: merge(fixtures, { + 'package.json': { + workspaces: ['a'], + dependencies: null, + }, + a: { + 'package.json': { + name: 'a', + version: '1.0.0', + dependencies: fixtures['package.json'].dependencies, + }, + }, + node_modules: { + a: t.fixture('symlink', '../a'), + }, + }), + }) + + await chmod() + await binLinks() + + // runs at the project level + await exec({ + args: ['create-index'], + localBin: resolve(path, 'node_modules/.bin'), + }) + + t.match(await readOutput(), { + value: 'local-2.0.0', + }) + + // runs at the child workspace level + await exec({ + args: ['create-index'], + localBin: resolve(path, 'a/node_modules/.bin'), + path: resolve(path, 'a'), + runPath: resolve(path, 'a'), + }) + + t.match(await readOutput('', { root: resolve(path, 'a') }), { + value: 'local-2.0.0', + }) +}) diff --git a/workspaces/libnpmexec/test/registry.js b/workspaces/libnpmexec/test/registry.js new file mode 100644 index 0000000..45d7cf4 --- /dev/null +++ b/workspaces/libnpmexec/test/registry.js @@ -0,0 +1,166 @@ +const { resolve } = require('path') +const t = require('tap') +const { setup, createPkg, merge } = require('./fixtures/setup.js') + +t.test('run from registry - no local packages', async t => { + const { fixtures, package } = createPkg({ versions: ['2.0.0'] }) + + const { exec, path, registry, readOutput } = setup(t, { + testdir: merge(fixtures, { + global: {}, + }), + }) + + await package({ registry, path }) + + await exec({ + args: ['@npmcli/create-index'], + globalPath: resolve(path, 'global'), + }) + + t.match(await readOutput('@npmcli-create-index'), { + value: 'packages-2.0.0', + }) +}) + +t.test('run from registry - local version mismatch', async t => { + const { fixtures, package } = createPkg({ + localVersion: '2.0.0', + versions: ['2.0.0', '1.0.0'], + }) + + const { exec, path, registry, readOutput } = setup(t, { + testdir: { + ...fixtures, + }, + }) + + await package({ registry, path, tarballs: ['1.0.0'] }) + + await exec({ args: ['@npmcli/create-index@1.0.0'] }) + + t.match(await readOutput('@npmcli-create-index'), { + value: 'packages-1.0.0', + }) +}) + +t.test('run from registry - local range mismatch', async t => { + const { fixtures, package } = createPkg({ + localVersion: '2.0.0', + versions: ['2.0.0', '1.0.0'], + }) + + const { exec, path, registry, readOutput } = setup(t, { + testdir: { + ...fixtures, + }, + }) + + await package({ registry, path, tarballs: ['1.0.0'] }) + + await exec({ + args: ['@npmcli/create-index@^1.0.0'], + }) + + t.match(await readOutput('@npmcli-create-index'), { + value: 'packages-1.0.0', + }) +}) + +t.test('run from registry - local tag mismatch', async t => { + const { fixtures, package } = createPkg({ + localVersion: '2.0.0', + versions: ['2.0.0'], + }) + + const { exec, path, registry, readOutput } = setup(t, { + testdir: { + ...fixtures, + }, + }) + + await package({ registry, path }) + + await exec({ + args: ['@npmcli/create-index@latest'], + }) + + t.match(await readOutput('@npmcli-create-index'), { + value: 'packages-2.0.0', + }) +}) + +t.test('avoid install when exec from registry an available pkg', async t => { + const { fixtures, package } = createPkg({ + versions: ['2.0.0'], + }) + + const { exec, path, registry, readOutput, rmOutput } = setup(t, { + testdir: { + ...fixtures, + }, + }) + + await package({ registry, path }) + + // no file + t.rejects(() => readOutput('@npmcli-create-index'), { code: 'ENOENT' }) + + // file is created + await exec({ args: ['@npmcli/create-index'] }) + t.match(await readOutput('@npmcli-create-index'), { + value: 'packages-2.0.0', + }) + + // remove file + await rmOutput('@npmcli-create-index') + t.rejects(() => readOutput('@npmcli-create-index'), { code: 'ENOENT' }) + + // create file again but mock manifest only once + await package({ registry, path, tarballs: [], times: 1 }) + await exec({ args: ['@npmcli/create-index'] }) + t.match(await readOutput('@npmcli-create-index'), { + value: 'packages-2.0.0', + }) +}) + +t.test('run multiple from registry', async t => { + const indexPkg = createPkg({ + versions: ['2.0.0'], + name: '@npmcli/create-index', + }) + const testPkg = createPkg({ + versions: ['2.0.0'], + name: '@npmcli/create-test', + }) + + const { exec, path, registry, readOutput } = setup(t, { + testdir: { + ...merge(indexPkg.fixtures, testPkg.fixtures), + }, + }) + + await indexPkg.package({ registry, path }) + await testPkg.package({ registry, path }) + + t.rejects( + () => readOutput(resolve('@npmcli-create-index')), + { code: 'ENOENT' } + ) + t.rejects( + () => readOutput(resolve('@npmcli-create-test')), + { code: 'ENOENT' } + ) + + await exec({ + packages: ['@npmcli/create-test', '@npmcli/create-index'], + call: 'create-test && create-index', + }) + + t.match(await readOutput('@npmcli-create-index'), { + value: 'packages-2.0.0', + }) + t.match(await readOutput('@npmcli-create-test'), { + value: 'packages-2.0.0', + }) +}) diff --git a/workspaces/libnpmexec/test/registry/content/ruyadorno/create-index.json b/workspaces/libnpmexec/test/registry/content/ruyadorno/create-index.json deleted file mode 100644 index 1e85cbb..0000000 --- a/workspaces/libnpmexec/test/registry/content/ruyadorno/create-index.json +++ /dev/null @@ -1,81 +0,0 @@ -{ - "_id": "@ruyadorno/create-index", - "name": "@ruyadorno/create-index", - "dist-tags": { - "latest": "1.0.0" - }, - "versions": { - "1.0.0": { - "name": "@ruyadorno/create-index", - "version": "1.0.0", - "description": "Create an empty index.js file", - "bin": { - "create-index": "create-index.js" - }, - "keywords": [ - "init", - "create", - "index" - ], - "author": { - "name": "Ruy Adorno", - "url": "https://ruyadorno.com" - }, - "license": "MIT", - "gitHead": "0c1b6a4c503d8565439b2b194b4691824a1bc902", - "_id": "@ruyadorno/create-index@1.0.0", - "_nodeVersion": "15.13.0", - "_npmVersion": "7.9.0", - "dist": { - "integrity": "sha512-2T2JRYWtB9/wN8Vr/SRDcjIbKD5IjR5joO8iCCCYjXfDRZ2lYBSnZQ2kGp34F+T8OEavzJfj9sxNt9Y7QT7Oaw==", - "shasum": "a7d15d2ca78c496685b7b2bc24599d4e0983783c", - "tarball": "https://registry.npmjs.org/@ruyadorno/create-index/-/create-index-1.0.0.tgz", - "fileCount": 3, - "unpackedSize": 565, - "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgd0fRCRA9TVsSAnZWagAA9ysP/i22HySX0+RYcHUldWcv\neDgd24/wQqNEsQiTrGpIRSSorqbrC5+xoZfFzbvbUA24JaFChgQE1rRtYDab\ntjo5asfUqCspru1X05D3T3lmy3NyBCShqzwsZo88stj8L1w8DcnmU83als4h\n6DqxmwQbPMn+hd5gKtr6ZsUwHZRc/9dXWjn6GI3ztAla73RKXQ4D9Gs/ULyo\nNwS6a/CqThqu4atlA6ZGXum72XsFYSRB712N3Q1l0+8T9L3lAWuitGx/K8L/\n95gxU0e6ME+Wiin62SxH6QYWuVIKD04UNkz14dzfI2RIjT2NDbX6l308uSza\nbWz6aro4w9kUJviDX/hk/o469d+EQ87L+vpFrLDbSfZg8RtvSptHCDdM6mNw\n05xNFji33ujMX54HyGxplioAgnE5X2ZTQuBymsiINHq5gxCn8MSaUxiX45yB\n7Bhf1rWbp5KgiUa0kGXV4eoAutP6HWs1avzkHi9q2xS61wMBdPPHX5GsTTqe\nI+4mdgpNOdQLQjLyCp+ydvSqTHtVHkHDrBJzgkOjDWC7YzDcbzFQt6Fn6uc/\nA4kTlU1yTD2lPz9ICNI6BwqM7aOa9qCVkBL7vWaUUpxblRpzfbKmCtEi704h\nIJ6YZ3z6xwTl59aMXiInOLFsb7upEwtTXTAWqDlsJmTYS7hsVi3gY7wqYp1p\nMwwm\r\n=rrJ8\r\n-----END PGP SIGNATURE-----\r\n" - }, - "_npmUser": { - "name": "ruyadorno", - "email": "ruyadorno@hotmail.com" - }, - "directories": {}, - "maintainers": [ - { - "name": "ruyadorno", - "email": "ruyadorno@hotmail.com" - } - ], - "_npmOperationalInternal": { - "host": "s3://npm-registry-packages", - "tmp": "tmp/create-index_1.0.0_1618429905498_0.11104270815832784" - }, - "_hasShrinkwrap": false - } - }, - "time": { - "created": "2021-04-14T19:51:45.442Z", - "1.0.0": "2021-04-14T19:51:45.650Z", - "modified": "2021-04-14T19:51:47.833Z" - }, - "maintainers": [ - { - "name": "ruyadorno", - "email": "ruyadorno@hotmail.com" - } - ], - "description": "Create an empty index.js file", - "keywords": [ - "init", - "create", - "index" - ], - "author": { - "name": "Ruy Adorno", - "url": "https://ruyadorno.com" - }, - "license": "MIT", - "readme": "# create-index\n\nPuts an empty `index.js` into current working dir. Meant for testing only.\n\n## Usage\n\n`npm exec @ruyadorno/create-index`\n\n", - "readmeFilename": "README.md", - "_cached": false, - "_contentLength": 0 -} \ No newline at end of file diff --git a/workspaces/libnpmexec/test/registry/content/ruyadorno/create-index.min.json b/workspaces/libnpmexec/test/registry/content/ruyadorno/create-index.min.json deleted file mode 100644 index e4e9983..0000000 --- a/workspaces/libnpmexec/test/registry/content/ruyadorno/create-index.min.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - "name": "@ruyadorno/create-index", - "dist-tags": { - "latest": "1.0.0" - }, - "versions": { - "1.0.0": { - "name": "@ruyadorno/create-index", - "version": "1.0.0", - "bin": { - "create-index": "create-index.js" - }, - "dist": { - "integrity": "sha512-2T2JRYWtB9/wN8Vr/SRDcjIbKD5IjR5joO8iCCCYjXfDRZ2lYBSnZQ2kGp34F+T8OEavzJfj9sxNt9Y7QT7Oaw==", - "shasum": "a7d15d2ca78c496685b7b2bc24599d4e0983783c", - "tarball": "https://registry.npmjs.org/@ruyadorno/create-index/-/create-index-1.0.0.tgz", - "fileCount": 3, - "unpackedSize": 565, - "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgd0fRCRA9TVsSAnZWagAA9ysP/i22HySX0+RYcHUldWcv\neDgd24/wQqNEsQiTrGpIRSSorqbrC5+xoZfFzbvbUA24JaFChgQE1rRtYDab\ntjo5asfUqCspru1X05D3T3lmy3NyBCShqzwsZo88stj8L1w8DcnmU83als4h\n6DqxmwQbPMn+hd5gKtr6ZsUwHZRc/9dXWjn6GI3ztAla73RKXQ4D9Gs/ULyo\nNwS6a/CqThqu4atlA6ZGXum72XsFYSRB712N3Q1l0+8T9L3lAWuitGx/K8L/\n95gxU0e6ME+Wiin62SxH6QYWuVIKD04UNkz14dzfI2RIjT2NDbX6l308uSza\nbWz6aro4w9kUJviDX/hk/o469d+EQ87L+vpFrLDbSfZg8RtvSptHCDdM6mNw\n05xNFji33ujMX54HyGxplioAgnE5X2ZTQuBymsiINHq5gxCn8MSaUxiX45yB\n7Bhf1rWbp5KgiUa0kGXV4eoAutP6HWs1avzkHi9q2xS61wMBdPPHX5GsTTqe\nI+4mdgpNOdQLQjLyCp+ydvSqTHtVHkHDrBJzgkOjDWC7YzDcbzFQt6Fn6uc/\nA4kTlU1yTD2lPz9ICNI6BwqM7aOa9qCVkBL7vWaUUpxblRpzfbKmCtEi704h\nIJ6YZ3z6xwTl59aMXiInOLFsb7upEwtTXTAWqDlsJmTYS7hsVi3gY7wqYp1p\nMwwm\r\n=rrJ8\r\n-----END PGP SIGNATURE-----\r\n" - } - } - }, - "modified": "2021-04-14T19:51:47.833Z", - "_cached": false, - "_contentLength": 1423 -} \ No newline at end of file diff --git a/workspaces/libnpmexec/test/registry/content/ruyadorno/create-index/-/create-index-1.0.0.tgz b/workspaces/libnpmexec/test/registry/content/ruyadorno/create-index/-/create-index-1.0.0.tgz deleted file mode 100644 index d6ddf7570e3fc8e7ddb812ed95ae376cb2fcb62f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 490 zcmV<G0TuoqiwFP!00002|Ls=6j?*v@&Dmcuq=#&!k~rNaNIkKFMdDBiEpS3eHOX{q zn%Kd1+KtfuJ9gT%6j*WTR;rYDaXj<J<5B#^u2{BW_ZVdgnZcJ_<oFPN*WM{XDSeeB z@GrYVd_4y5I!S39rzxF)N8@pvT0Zs8fLa@->{d=tqy_B93&G$;RBIJ|<03+_1|f4K zMB$H`E4&I8Iv9o<#SOmW1%7NqcD46a%q*=}p_awk&by-%3`Y<IL*n(g08~5u??(Io zq&RgBtA}(lc~bw$IQ~=rapL&B{+}N|34kwHiT)J)*Q#z<E|ri+_kllhq%|tdrEt7B zq#@l}bJUsQmDzdTv|+#mU|E?4x~2dN+dsAuw$)gs%WEe`X{N_>8|GWqV;i-?W+PRu zE$NHT1vmbvW4o{I0$*DytIblXLyoSxySjm!wz_sB)>Es(IhMv$dKyLh>cdQy9mj0A zG3b`__x{7S3Z9|R?eeqtpM3I2E>!<_w>NKRw_%w-LyrIGe;ogH|I@_133~mX;r@r; zB}d4I+USFP=baGeR>?*}Rx5?VfR*Bki+jkq3SoxKnif)lL2aB_ilPY#84TdFwug(5 gxu{CO2h8A!7BeUPd!a{<9zD*AUyU5II{**>055{~Gynhq diff --git a/workspaces/libnpmexec/test/registry/content/ruyadorno/create-test.json b/workspaces/libnpmexec/test/registry/content/ruyadorno/create-test.json deleted file mode 100644 index d193b83..0000000 --- a/workspaces/libnpmexec/test/registry/content/ruyadorno/create-test.json +++ /dev/null @@ -1,81 +0,0 @@ -{ - "_id": "@ruyadorno/create-test", - "name": "@ruyadorno/create-test", - "dist-tags": { - "latest": "1.0.0" - }, - "versions": { - "1.0.0": { - "name": "@ruyadorno/create-test", - "version": "1.0.0", - "description": "Creates an empty test.js file", - "bin": { - "create-test": "create-test.js" - }, - "keywords": [ - "init", - "create", - "test" - ], - "author": { - "name": "Ruy Adorno", - "url": "https://ruyadorno.com" - }, - "license": "MIT", - "gitHead": "707aa293e34f48dcf9cb6b4b452cb1fc8e484c8b", - "_id": "@ruyadorno/create-test@1.0.0", - "_nodeVersion": "15.13.0", - "_npmVersion": "7.9.0", - "dist": { - "integrity": "sha512-WOifELHCU8nmg0yHsPbSETPaNO1orDPhTSflJsomqGFNwVS44qvkWwMPbDE3L2aAglXLf5AxUznyFkxsXgDF2w==", - "shasum": "f0f393449fe5205c54a4ca2181d8355d2372da93", - "tarball": "https://registry.npmjs.org/@ruyadorno/create-test/-/create-test-1.0.0.tgz", - "fileCount": 3, - "unpackedSize": 557, - "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgd1SICRA9TVsSAnZWagAAOa4P/jknjgmFaBWz6PCng8qV\nsdfa23GbE4MdmvpB72v6DvNjGQ+51Vgd7PBAJRo+d3LmQ0c2DE/e6PZEgam/\nOtuVbgimxPy85V1MTA66bgML4nFtEOKS/R/Z5s7wMMCrhYqKdMp6ELMUEO07\n7cDIzAmc7WeSLyzhTBC661T0nKPPAf2nKKYXLI+6RisQoXnEgZmgNyNlIt6D\nNDNTRZjaR6s1QvHgWN9h/hLAgKvgaAnSy+JOzcB+SGaClLow3svbvW+klQpA\n8afOTLV4D/pgPDGXvvwDDInH6yccYSOSNiAZgd45hsmo82xIR3n+Cod2qk9Y\njCye36nXzdQTz9A7a3SgH++DV7fA5n87GoahkpGEnKu8gjgMuE6ncDEypbTi\nM4R8JikZrScR2wWXtO+jK4f/5XHVh19ZpqdOrlxzXutkUy0/bMoHFNxcGrXB\n5D1Qk/lOpNO4rd0NoURk6OkpueHOlBHlBNxqrEsltzY2IWs+JICcFaz385H0\nKYyNQrmltEqWVgW+LeFvm3B1sLL5wySqplX/396lC6kCHZyofeeqZFcC1G+m\ntkp0iho63tlm6WjIzw6ddHWu8olNohCk4xFpvNkkZ0u9GR4BaDBRXS60AcoD\nNIYwMuUlqmXAc7ey+xNZCqXokgbtjD7aI2uIDLNUMHELxrRzBccHe76sIQit\nBeBy\r\n=u7P4\r\n-----END PGP SIGNATURE-----\r\n" - }, - "_npmUser": { - "name": "ruyadorno", - "email": "ruyadorno@hotmail.com" - }, - "directories": {}, - "maintainers": [ - { - "name": "ruyadorno", - "email": "ruyadorno@hotmail.com" - } - ], - "_npmOperationalInternal": { - "host": "s3://npm-registry-packages", - "tmp": "tmp/create-test_1.0.0_1618433159830_0.5969279363908722" - }, - "_hasShrinkwrap": false - } - }, - "time": { - "created": "2021-04-14T20:45:59.789Z", - "1.0.0": "2021-04-14T20:45:59.974Z", - "modified": "2021-04-14T20:46:02.139Z" - }, - "maintainers": [ - { - "name": "ruyadorno", - "email": "ruyadorno@hotmail.com" - } - ], - "description": "Creates an empty test.js file", - "keywords": [ - "init", - "create", - "test" - ], - "author": { - "name": "Ruy Adorno", - "url": "https://ruyadorno.com" - }, - "license": "MIT", - "readme": "# create-test\n\nPuts an empty `test.js` into current working dir. Meant for testing only.\n\n## Usage\n\n`npm exec @ruyadorno/create-test`\n\n", - "readmeFilename": "README.md", - "_cached": false, - "_contentLength": 0 -} \ No newline at end of file diff --git a/workspaces/libnpmexec/test/registry/content/ruyadorno/create-test.min.json b/workspaces/libnpmexec/test/registry/content/ruyadorno/create-test.min.json deleted file mode 100644 index cc15084..0000000 --- a/workspaces/libnpmexec/test/registry/content/ruyadorno/create-test.min.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - "name": "@ruyadorno/create-test", - "dist-tags": { - "latest": "1.0.0" - }, - "versions": { - "1.0.0": { - "name": "@ruyadorno/create-test", - "version": "1.0.0", - "bin": { - "create-test": "create-test.js" - }, - "dist": { - "integrity": "sha512-WOifELHCU8nmg0yHsPbSETPaNO1orDPhTSflJsomqGFNwVS44qvkWwMPbDE3L2aAglXLf5AxUznyFkxsXgDF2w==", - "shasum": "f0f393449fe5205c54a4ca2181d8355d2372da93", - "tarball": "https://registry.npmjs.org/@ruyadorno/create-test/-/create-test-1.0.0.tgz", - "fileCount": 3, - "unpackedSize": 557, - "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgd1SICRA9TVsSAnZWagAAOa4P/jknjgmFaBWz6PCng8qV\nsdfa23GbE4MdmvpB72v6DvNjGQ+51Vgd7PBAJRo+d3LmQ0c2DE/e6PZEgam/\nOtuVbgimxPy85V1MTA66bgML4nFtEOKS/R/Z5s7wMMCrhYqKdMp6ELMUEO07\n7cDIzAmc7WeSLyzhTBC661T0nKPPAf2nKKYXLI+6RisQoXnEgZmgNyNlIt6D\nNDNTRZjaR6s1QvHgWN9h/hLAgKvgaAnSy+JOzcB+SGaClLow3svbvW+klQpA\n8afOTLV4D/pgPDGXvvwDDInH6yccYSOSNiAZgd45hsmo82xIR3n+Cod2qk9Y\njCye36nXzdQTz9A7a3SgH++DV7fA5n87GoahkpGEnKu8gjgMuE6ncDEypbTi\nM4R8JikZrScR2wWXtO+jK4f/5XHVh19ZpqdOrlxzXutkUy0/bMoHFNxcGrXB\n5D1Qk/lOpNO4rd0NoURk6OkpueHOlBHlBNxqrEsltzY2IWs+JICcFaz385H0\nKYyNQrmltEqWVgW+LeFvm3B1sLL5wySqplX/396lC6kCHZyofeeqZFcC1G+m\ntkp0iho63tlm6WjIzw6ddHWu8olNohCk4xFpvNkkZ0u9GR4BaDBRXS60AcoD\nNIYwMuUlqmXAc7ey+xNZCqXokgbtjD7aI2uIDLNUMHELxrRzBccHe76sIQit\nBeBy\r\n=u7P4\r\n-----END PGP SIGNATURE-----\r\n" - } - } - }, - "modified": "2021-04-14T20:46:02.139Z", - "_cached": false, - "_contentLength": 1417 -} \ No newline at end of file diff --git a/workspaces/libnpmexec/test/registry/content/ruyadorno/create-test/-/create-test-1.0.0.tgz b/workspaces/libnpmexec/test/registry/content/ruyadorno/create-test/-/create-test-1.0.0.tgz deleted file mode 100644 index 34a85702055f3aa6c1235537795d48bf0195ab9c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 487 zcmV<D0T})tiwFP!00002|Ls;$Yuhjo_OpJ)&3SMGoh>)919@8MI@m*CblcMyM71xC z8e8%tIhiT_?~`07%}U2!(m=r9i>$lvba&X_$ra01><*($Av5^ipf=&X_6`b4=_E<u zHM>JRioqKtDUIVarDO1Dd_hNU^^SmA8>Vb22WZj)cI$~?@Gh#gif*}xP^>}790^hQ ztL6&Nf`tx-;YM+TpLl^^8<Cyud=)cG>s6>_v9|l}(+P&>5ClWw^*9Aoo&LMkzCbAs zox|!O9gqL1|0GUc>OW4#lV1PFzyksB1uM~?g8xC)4a=nxa{oT?&mCutN^>b3Ee>f& zpR76RO!3Neo~t%W0~3H{Wg6&)0xazKc#5!-#xh-6yV=h&{cCH3e9L)kV^-K~q{_AB z{P4NpwxliDJ+<LKTPCZ`QmW?!+s<z41}@vq+A6H4R)upcjj8lBigulcnJl*)v*E^| zJI>$vpQ|c(hC;W;&pv<i$s;*o{oh<)ew<y0W&Q>^{-gg3I(eyonvBw3|3|t1VNY~~ ze5uWzdgq-I=fH)Lkkv||FkrQ~;^Gc+u0oh0v!;bqt=64cilPY#84TdNwx1Rub5WIm dzcGW?2h5!Ge+xZ&^yqPH`~gbZ5>NmT0040h_GSP8 diff --git a/workspaces/libnpmexec/test/registry/server.js b/workspaces/libnpmexec/test/registry/server.js deleted file mode 100644 index 1db583a..0000000 --- a/workspaces/libnpmexec/test/registry/server.js +++ /dev/null @@ -1,280 +0,0 @@ -const { join, dirname } = require('path') -const { existsSync, readFileSync, writeFileSync } = require('fs') -const PORT = 12345 + (+process.env.TAP_CHILD_ID || 0) -const http = require('http') -const https = require('https') - -const mkdirp = require('mkdirp') -const doProxy = process.env.ARBORIST_TEST_PROXY -const missing = /\/@isaacs(\/|%2[fF])(this-does-not-exist-at-all|testing-missing-tgz\/-\/)/ -const corgiDoc = 'application/vnd.npm.install-v1+json; q=1.0, application/json; q=0.8, */*' -const { gzipSync, unzipSync } = require('zlib') - -let advisoryBulkResponse = null -let failAdvisoryBulk = false -let auditResponse = null -let failAudit = false -const startServer = cb => { - const server = module.exports.server = http.createServer((req, res) => { - res.setHeader('connection', 'close') - - if (req.url === '/-/npm/v1/security/advisories/bulk') { - const body = [] - req.on('data', c => body.push(c)) - req.on('end', () => { - res.setHeader('connection', 'close') - if (failAdvisoryBulk) { - res.statusCode = 503 - return res.end('no advisory bulk for you') - } - if (!advisoryBulkResponse) { - if (auditResponse && !failAudit) { - // simulate what the registry does when quick audits are allowed, - // but advisory bulk requests are not - res.statusCode = 405 - return res.end(JSON.stringify({ - code: 'MethodNotAllowedError', - message: 'POST is not allowed', - })) - } else { - res.statusCode = 404 - return res.end('not found') - } - } - if (doProxy && !existsSync(advisoryBulkResponse)) { - // hit the main registry, then fall back to staging for now - // XXX: remove this when bulk advisory endpoint pushed to production! - const opts = { - host: 'registry.npmjs.org', - method: req.method, - path: req.url, - headers: { - ...req.headers, - accept: '*', - host: 'registry.npmjs.org', - connection: 'close', - 'if-none-match': '', - }, - } - const handleUpstream = upstream => { - res.statusCode = upstream.statusCode - if (upstream.statusCode >= 300 || upstream.statusCode < 200) { - console.error('UPSTREAM ERROR', upstream.statusCode) - return upstream.pipe(res) - } - res.setHeader('content-encoding', upstream.headers['content-encoding']) - const file = advisoryBulkResponse - console.error('PROXY', `${req.url} -> ${file} ${upstream.statusCode}`) - mkdirp.sync(dirname(file)) - const data = [] - upstream.on('end', () => { - const out = Buffer.concat(data) - const obj = JSON.parse(unzipSync(out).toString()) - writeFileSync(file, JSON.stringify(obj, 0, 2) + '\n') - res.end(out) - }) - upstream.on('data', c => data.push(c)) - } - return https.request(opts).on('response', upstream => { - if (upstream.statusCode !== 200) { - console.error('ATTEMPTING TO PROXY FROM STAGING') - console.error('NOTE: THIS WILL FAIL WHEN NOT ON VPN!') - opts.host = 'security-microservice-3-west.npm.red' - opts.headers.host = opts.host - opts.path = '/v1/advisories/bulk' - https.request(opts) - .on('response', upstream => handleUpstream(upstream)) - .end(Buffer.concat(body)) - } else { - handleUpstream(upstream) - } - }).end(Buffer.concat(body)) - } else { - res.setHeader('content-encoding', 'gzip') - res.end(gzipSync(readFileSync(advisoryBulkResponse))) - } - }) - return - } else if (req.url === '/-/npm/v1/security/audits/quick') { - const body = [] - req.on('data', c => body.push(c)) - req.on('end', () => { - res.setHeader('connection', 'close') - if (failAudit) { - res.statusCode = 503 - return res.end('no audit for you') - } - if (!auditResponse) { - res.statusCode = 404 - return res.end('not found') - } - if (doProxy && !existsSync(auditResponse)) { - return https.request({ - host: 'registry.npmjs.org', - method: req.method, - path: req.url, - headers: { - ...req.headers, - accept: '*', - host: 'registry.npmjs.org', - connection: 'close', - 'if-none-match': '', - }, - }).on('response', upstream => { - res.statusCode = upstream.statusCode - if (upstream.statusCode >= 300 || upstream.statusCode < 200) { - console.error('UPSTREAM ERROR', upstream.statusCode) - // don't save if it's not a valid response - return upstream.pipe(res) - } - res.setHeader('content-encoding', upstream.headers['content-encoding']) - const file = auditResponse - console.error('PROXY', `${req.url} -> ${file} ${upstream.statusCode}`) - mkdirp.sync(dirname(file)) - const data = [] - upstream.on('end', () => { - const out = Buffer.concat(data) - // make it a bit prettier to read later - const obj = JSON.parse(unzipSync(out).toString()) - writeFileSync(file, JSON.stringify(obj, 0, 2) + '\n') - res.end(out) - }) - upstream.on('data', c => data.push(c)) - }).end(Buffer.concat(body)) - } else { - res.setHeader('content-encoding', 'gzip') - res.end(gzipSync(readFileSync(auditResponse))) - } - }) - return - } - - const f = join(__dirname, 'content', join('/', req.url.replace(/@/, '').replace(/%2f/i, '/'))) - const isCorgi = req.headers.accept.includes('application/vnd.npm.install-v1+json') - const file = f + ( - isCorgi && existsSync(`${f}.min.json`) ? '.min.json' - : existsSync(`${f}.json`) ? '.json' - : existsSync(`${f}/index.json`) ? 'index.json' - : '' - ) - - try { - const body = readFileSync(file) - res.setHeader('content-length', body.length) - res.setHeader('content-type', /\.min\.json$/.test(file) ? corgiDoc - : /\.json$/.test(file) ? 'application/json' - : 'application/octet-stream') - res.end(body) - } catch (er) { - // testing things going missing from the registry somehow - if (missing.test(req.url)) { - res.statusCode = 404 - res.end('{"error": "not found"}') - return - } - - if (doProxy) { - return https.get({ - host: 'registry.npmjs.org', - path: req.url, - headers: { - ...req.headers, - accept: '*', - 'accept-encoding': 'identity', - host: 'registry.npmjs.org', - connection: 'close', - 'if-none-match': '', - }, - }).on('response', upstream => { - const errorStatus = - upstream.statusCode >= 300 || upstream.statusCode < 200 - - if (errorStatus) { - console.error('UPSTREAM ERROR', upstream.statusCode) - } - - const ct = upstream.headers['content-type'] - const isJson = ct.includes('application/json') - const file = isJson ? f + '.json' : f - console.error('PROXY', `${req.url} -> ${file} ${ct}`) - mkdirp.sync(dirname(file)) - const data = [] - res.statusCode = upstream.statusCode - res.setHeader('content-type', ct) - upstream.on('end', () => { - console.error('ENDING', req.url) - const out = Buffer.concat(data) - if (!errorStatus) { - if (isJson) { - const obj = JSON.parse(out.toString()) - writeFileSync(file, JSON.stringify(obj, 0, 2) + '\n') - const mrm = require('minify-registry-metadata') - const minFile = file.replace(/\.json$/, '.min.json') - writeFileSync(minFile, JSON.stringify(mrm(obj), 0, 2) + '\n') - console.error('WROTE JSONS', [file, minFile]) - } else { - writeFileSync(file, out) - } - } - res.end(out) - }) - upstream.on('data', c => data.push(c)) - }).end() - } - - res.statusCode = er.code === 'ENOENT' ? 404 : 500 - if (res.method === 'GET') { - console.error(er) - } - res.setHeader('content-type', 'text/plain') - res.end(er.stack) - } - }) - server.listen(PORT, cb) -} - -module.exports = t => startServer(() => { - t.parent.teardown(() => module.exports.server.close()) - t.end() -}) - -module.exports.auditResponse = value => { - if (auditResponse && auditResponse !== value) { - throw new Error('setting audit response, but already set\n' + - '(did you forget to call the returned function on teardown?)') - } - auditResponse = value - return () => auditResponse = null -} -module.exports.failAudit = () => { - failAudit = true - return () => failAudit = false -} - -module.exports.advisoryBulkResponse = value => { - if (advisoryBulkResponse && advisoryBulkResponse !== value) { - throw new Error('setting advisory bulk response, but already set\n' + - '(did you forget to call the returned function on teardown?)') - } - advisoryBulkResponse = value - return () => advisoryBulkResponse = null -} -module.exports.failAdvisoryBulk = () => { - failAdvisoryBulk = true - return () => failAdvisoryBulk = false -} - -module.exports.registry = `http://localhost:${PORT}/` - -module.exports.start = startServer -module.exports.stop = () => module.exports.server.close() - -if (require.main === module) { - startServer(() => { - console.log(`Mock registry live at: - ${module.exports.registry} -Press ^D to close gracefully.`) - }) - process.openStdin() - process.stdin.on('end', () => module.exports.server.close()) -} diff --git a/workspaces/libnpmexec/test/run-script.js b/workspaces/libnpmexec/test/run-script.js index c86e8e1..d360fc1 100644 --- a/workspaces/libnpmexec/test/run-script.js +++ b/workspaces/libnpmexec/test/run-script.js @@ -4,11 +4,8 @@ const baseOpts = { args: [], call: '', color: false, - log: { - warn () {}, - }, + flatOptions: {}, path: '', - pathArr: [''], runPath: '', shell: process.platform === 'win32' ? process.env.ComSpec || 'cmd' @@ -24,25 +21,23 @@ t.test('disable, enable log progress', t => { }), }) const runScript = t.mock('../lib/run-script.js', { - '@npmcli/ci-detect': () => false, + 'ci-info': { isCI: false }, '@npmcli/run-script': async () => { t.ok('should call run-script') }, '../lib/no-tty.js': () => false, + npmlog: { + disableProgress () { + t.ok('should disable progress') + }, + enableProgress () { + t.ok('should enable progress') + }, + }, }) - const log = { - ...baseOpts.log, - disableProgress () { - t.ok('should disable progress') - }, - enableProgress () { - t.ok('should enable progress') - }, - } runScript({ ...baseOpts, - log, path, }) }) @@ -51,7 +46,7 @@ t.test('no package.json', t => { t.plan(1) const runScript = t.mock('../lib/run-script.js', { - '@npmcli/ci-detect': () => false, + 'ci-info': { isCI: false }, '@npmcli/run-script': async () => { t.ok('should call run-script') }, @@ -61,11 +56,11 @@ t.test('no package.json', t => { runScript(baseOpts) }) -t.test('colorized interactive mode msg', t => { +t.test('colorized interactive mode msg', async t => { t.plan(2) const runScript = t.mock('../lib/run-script.js', { - '@npmcli/ci-detect': () => false, + 'ci-info': { isCI: false }, '@npmcli/run-script': async () => { t.ok('should call run-script') }, @@ -73,27 +68,22 @@ t.test('colorized interactive mode msg', t => { }) const OUTPUT = [] - runScript({ + await runScript({ ...baseOpts, output: msg => { OUTPUT.push(msg) }, runPath: '/foo/', - color: true, + flatOptions: { color: true }, }) - .then(() => { - t.matchSnapshot(OUTPUT.join('\n'), 'should print colorized output') - }) - .catch(err => { - throw err - }) + t.matchSnapshot(OUTPUT.join('\n'), 'should print colorized output') }) -t.test('no color interactive mode msg', t => { +t.test('no color interactive mode msg', async t => { t.plan(2) const runScript = t.mock('../lib/run-script.js', { - '@npmcli/ci-detect': () => false, + 'ci-info': { isCI: false }, '@npmcli/run-script': async () => { t.ok('should call run-script') }, @@ -101,26 +91,21 @@ t.test('no color interactive mode msg', t => { }) const OUTPUT = [] - runScript({ + await runScript({ ...baseOpts, output: msg => { OUTPUT.push(msg) }, runPath: '/foo/', }) - .then(() => { - t.matchSnapshot(OUTPUT.join('\n'), 'should print non-colorized output') - }) - .catch(err => { - throw err - }) + t.matchSnapshot(OUTPUT.join('\n'), 'should print non-colorized output') }) t.test('no tty', t => { t.plan(1) const runScript = t.mock('../lib/run-script.js', { - '@npmcli/ci-detect': () => false, + 'ci-info': { isCI: false }, '@npmcli/run-script': async () => { t.ok('should call run-script') }, @@ -134,23 +119,22 @@ t.test('ci env', t => { t.plan(2) const runScript = t.mock('../lib/run-script.js', { - '@npmcli/ci-detect': () => true, + 'ci-info': { isCI: true }, '@npmcli/run-script': async () => { throw new Error('should not call run-script') }, '../lib/no-tty.js': () => false, - }) - const log = { - ...baseOpts.log, - warn (title, msg) { - t.equal(title, 'exec', 'should have expected title') - t.equal( - msg, - 'Interactive mode disabled in CI environment', - 'should have expected ci environment message' - ) + 'proc-log': { + warn (title, msg) { + t.equal(title, 'exec', 'should have expected title') + t.equal( + msg, + 'Interactive mode disabled in CI environment', + 'should have expected ci environment message' + ) + }, }, - } + }) - runScript({ ...baseOpts, log }) + runScript({ ...baseOpts }) }) diff --git a/workspaces/libnpmfund/.editorconfig b/workspaces/libnpmfund/.editorconfig deleted file mode 100644 index 0f3bb61..0000000 --- a/workspaces/libnpmfund/.editorconfig +++ /dev/null @@ -1,3 +0,0 @@ -[*.js] -indent_style = space -indent_size = 2 diff --git a/workspaces/libnpmfund/.eslintrc.js b/workspaces/libnpmfund/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/libnpmfund/.eslintrc.js +++ b/workspaces/libnpmfund/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/libnpmfund/.gitignore b/workspaces/libnpmfund/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/libnpmfund/.gitignore +++ b/workspaces/libnpmfund/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/libnpmfund/.npmrc b/workspaces/libnpmfund/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/libnpmfund/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/libnpmfund/CHANGELOG.md b/workspaces/libnpmfund/CHANGELOG.md index 9b76209..4581968 100644 --- a/workspaces/libnpmfund/CHANGELOG.md +++ b/workspaces/libnpmfund/CHANGELOG.md @@ -1,5 +1,127 @@ # Changelog +## [4.0.6](https://github.com/npm/cli/compare/libnpmfund-v4.0.5...libnpmfund-v4.0.6) (2022-12-07) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/releases/tag/arborist-v6.1.5): `@npmcli/arborist@6.1.5` + +## [4.0.5](https://github.com/npm/cli/compare/libnpmfund-v4.0.4...libnpmfund-v4.0.5) (2022-11-30) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.3...arborist-v6.1.4): `@npmcli/arborist@6.1.4` + +## [4.0.4](https://github.com/npm/cli/compare/libnpmfund-v4.0.3...libnpmfund-v4.0.4) (2022-11-16) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.2...arborist-v6.1.3): `@npmcli/arborist@6.1.3` + +## [4.0.3](https://github.com/npm/cli/compare/libnpmfund-v4.0.2...libnpmfund-v4.0.3) (2022-11-09) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.1...arborist-v6.1.2): `@npmcli/arborist@6.1.2` + +## [4.0.2](https://github.com/npm/cli/compare/libnpmfund-v4.0.1...libnpmfund-v4.0.2) (2022-11-02) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.0...arborist-v6.1.1): `@npmcli/arborist@6.1.1` + +## [4.0.1](https://github.com/npm/cli/compare/libnpmfund-v4.0.0...libnpmfund-v4.0.1) (2022-10-26) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0...arborist-v6.1.0): `@npmcli/arborist@6.1.0` + +## [4.0.0](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.5...libnpmfund-v4.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.5...arborist-v6.0.0): `@npmcli/arborist@6.0.0` + +## [4.0.0-pre.5](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.4...libnpmfund-v4.0.0-pre.5) (2022-10-19) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.4...arborist-v6.0.0-pre.5): `@npmcli/arborist@6.0.0-pre.5` + +## [4.0.0-pre.4](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.3...libnpmfund-v4.0.0-pre.4) (2022-10-05) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.3...arborist-v6.0.0-pre.4): `@npmcli/arborist@6.0.0-pre.4` + +## [4.0.0-pre.3](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.2...libnpmfund-v4.0.0-pre.3) (2022-09-30) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.2...arborist-v6.0.0-pre.3): `@npmcli/arborist@6.0.0-pre.3` + +## [4.0.0-pre.2](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.1...libnpmfund-v4.0.0-pre.2) (2022-09-23) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.1...arborist-v6.0.0-pre.2): `@npmcli/arborist@6.0.0-pre.2` + +## [4.0.0-pre.1](https://github.com/npm/cli/compare/libnpmfund-v4.0.0-pre.0...libnpmfund-v4.0.0-pre.1) (2022-09-14) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.0...arborist-v6.0.0-pre.1): `@npmcli/arborist@6.0.0-pre.1` + +## [4.0.0-pre.0](https://github.com/npm/cli/compare/libnpmfund-v3.0.3...libnpmfund-v4.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + + +### Dependencies + +* The following workspace dependencies were updated + * dependencies + * @npmcli/arborist bumped from ^5.6.1 to ^6.0.0-pre.0 + +## [3.0.3](https://github.com/npm/cli/compare/libnpmfund-v3.0.2...libnpmfund-v3.0.3) (2022-08-31) + +### Dependencies + + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` +* The following workspace dependencies were updated + * dependencies + * @npmcli/arborist bumped from ^5.0.0 to ^5.6.1 + +### [3.0.2](https://github.com/npm/cli/compare/libnpmfund-v3.0.1...libnpmfund-v3.0.2) (2022-04-06) + + +### Bug Fixes + +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/template-oss@3.2.1 ([aac01b8](https://github.com/npm/cli/commit/aac01b89caf6336a2eb34d696296303cdadd5c08)) +* @npmcli/template-oss@3.2.2 ([#4639](https://github.com/npm/cli/issues/4639)) ([a59fd2c](https://github.com/npm/cli/commit/a59fd2cb863245fce56f96c90ac854e62c5c4d6f)) + +### [3.0.1](https://www.github.com/npm/cli/compare/libnpmfund-vlibnpmfund@3.0.0...libnpmfund-v3.0.1) (2022-03-03) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) + ## 1.0.2 - Bumped @npmcli/arborist dependency version @@ -7,4 +129,3 @@ ## 1.0.0 - Initial release - diff --git a/workspaces/libnpmfund/README.md b/workspaces/libnpmfund/README.md index 8ab663f..6072b11 100644 --- a/workspaces/libnpmfund/README.md +++ b/workspaces/libnpmfund/README.md @@ -2,8 +2,7 @@ [![npm version](https://img.shields.io/npm/v/libnpmfund.svg)](https://npm.im/libnpmfund) [![license](https://img.shields.io/npm/l/libnpmfund.svg)](https://npm.im/libnpmfund) -[![GitHub Actions](https://github.com/npm/libnpmfund/workflows/node-ci/badge.svg)](https://github.com/npm/libnpmfund/actions?query=workflow%3Anode-ci) -[![Coverage Status](https://coveralls.io/repos/github/npm/libnpmfund/badge.svg?branch=master)](https://coveralls.io/github/npm/libnpmfund?branch=master) +[![CI - libnpmfund](https://github.com/npm/cli/actions/workflows/ci-libnpmfund.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-libnpmfund.yml) [`libnpmfund`](https://github.com/npm/libnpmfund) is a Node.js library for retrieving **funding** information for packages installed using diff --git a/workspaces/libnpmfund/SECURITY.md b/workspaces/libnpmfund/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/libnpmfund/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/libnpmfund/lib/index.js b/workspaces/libnpmfund/lib/index.js index a3d2d82..a53893d 100644 --- a/workspaces/libnpmfund/lib/index.js +++ b/workspaces/libnpmfund/lib/index.js @@ -91,8 +91,8 @@ function readTree (tree, opts) { } } - function getFundingDependencies (tree) { - const edges = tree && tree.edgesOut && tree.edgesOut.values() + function getFundingDependencies (t) { + const edges = t && t.edgesOut && t.edgesOut.values() if (!edges) { return empty() } diff --git a/workspaces/libnpmfund/package.json b/workspaces/libnpmfund/package.json index 4b7ffc8..b92af92 100644 --- a/workspaces/libnpmfund/package.json +++ b/workspaces/libnpmfund/package.json @@ -1,13 +1,17 @@ { "name": "libnpmfund", - "version": "2.0.2", + "version": "4.0.6", "main": "lib/index.js", "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "description": "Programmatic API for npm fund", - "repository": "https://github.com/npm/libnpmfund", + "repository": { + "type": "git", + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/libnpmfund" + }, "keywords": [ "npm", "npmcli", @@ -28,30 +32,34 @@ "license": "ISC", "scripts": { "eslint": "eslint", - "lint": "eslint '**/*.js'", - "lintfix": "npm run lint -- --fix", - "posttest": "npm run lint", + "lint": "eslint \"**/*.js\"", + "lintfix": "node ../.. run lint -- --fix", + "posttest": "node ../.. run lint", "test": "tap", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "postlint": "npm-template-check" - }, - "tap": { - "check-coverage": true + "postlint": "template-oss-check", + "template-oss-apply": "template-oss-apply --force" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "tap": "^15.0.9" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "tap": "^16.3.2" }, "dependencies": { - "@npmcli/arborist": "^4.0.0" + "@npmcli/arborist": "^6.1.5" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/workspaces/libnpmfund/test.js b/workspaces/libnpmfund/test/index.js similarity index 99% rename from workspaces/libnpmfund/test.js rename to workspaces/libnpmfund/test/index.js index f862f46..0a84e62 100644 --- a/workspaces/libnpmfund/test.js +++ b/workspaces/libnpmfund/test/index.js @@ -6,7 +6,7 @@ const { readTree, normalizeFunding, isValidFunding, -} = require('./lib/index.js') +} = require('../lib/index.js') const { join } = require('path') t.test('symlink tree', async (t) => { @@ -171,7 +171,7 @@ t.test('loading tree from path', async (t) => { t.test('no args', async (t) => { // will parse data from libnpmfund itself which has *many* fund-listed deps const res = await read({ - path: join(__dirname, '..', '..'), + path: join(__dirname, '..', '..', '..'), }) t.ok( res.length > 0, // thus length should always be greater than 0 diff --git a/workspaces/libnpmhook/.eslintrc.js b/workspaces/libnpmhook/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/libnpmhook/.eslintrc.js +++ b/workspaces/libnpmhook/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/libnpmhook/.gitignore b/workspaces/libnpmhook/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/libnpmhook/.gitignore +++ b/workspaces/libnpmhook/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/libnpmhook/.npmrc b/workspaces/libnpmhook/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/libnpmhook/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/libnpmhook/CHANGELOG.md b/workspaces/libnpmhook/CHANGELOG.md index 0557274..580f1f6 100644 --- a/workspaces/libnpmhook/CHANGELOG.md +++ b/workspaces/libnpmhook/CHANGELOG.md @@ -1,7 +1,62 @@ -# Change Log +# Changelog -<a name="6.0.0"></a> -# [6.0.0](https://github.com/npm/libnpmhook/compare/v5.0.2...v6.0.0) (2020-02-26) +## [9.0.1](https://github.com/npm/cli/compare/libnpmhook-v9.0.0...libnpmhook-v9.0.1) (2022-12-07) + +### Dependencies + +* [`0a3fe00`](https://github.com/npm/cli/commit/0a3fe000e2723ae6fdb8b1d3154fd3835057c992) [#5933](https://github.com/npm/cli/pull/5933) `minipass@4.0.0` +* [`fee9b66`](https://github.com/npm/cli/commit/fee9b6686892a1c7f976c36ddd5d89b70c416817) `npm-registry-fetch@14.0.3` + +## [9.0.0](https://github.com/npm/cli/compare/libnpmhook-v9.0.0-pre.1...libnpmhook-v9.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +## [9.0.0-pre.1](https://github.com/npm/cli/compare/libnpmhook-v9.0.0-pre.0...libnpmhook-v9.0.0-pre.1) (2022-10-19) + +### Dependencies + +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies + +## [9.0.0-pre.0](https://github.com/npm/cli/compare/libnpmhook-v8.0.4...libnpmhook-v9.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + +## [8.0.4](https://github.com/npm/cli/compare/libnpmhook-v8.0.3...libnpmhook-v8.0.4) (2022-08-31) + +### Dependencies + + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` + +### [8.0.3](https://github.com/npm/cli/compare/libnpmhook-v8.0.2...libnpmhook-v8.0.3) (2022-04-06) + + +### Bug Fixes + +* replace deprecated String.prototype.substr() ([#4667](https://github.com/npm/cli/issues/4667)) ([e3da5df](https://github.com/npm/cli/commit/e3da5df4152fbe547f7871547165328e1bf06262)) +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/template-oss@3.2.1 ([aac01b8](https://github.com/npm/cli/commit/aac01b89caf6336a2eb34d696296303cdadd5c08)) +* @npmcli/template-oss@3.2.2 ([#4639](https://github.com/npm/cli/issues/4639)) ([a59fd2c](https://github.com/npm/cli/commit/a59fd2cb863245fce56f96c90ac854e62c5c4d6f)) + +### [8.0.2](https://www.github.com/npm/cli/compare/libnpmhook-v8.0.1...libnpmhook-v8.0.2) (2022-03-10) + + +### Documentation + +* standardize changelog heading ([#4510](https://www.github.com/npm/cli/issues/4510)) ([91f03ee](https://www.github.com/npm/cli/commit/91f03ee618bc635f9cfbded735fe98bbfa9d643f)) + +## [6.0.0](https://github.com/npm/libnpmhook/compare/v5.0.2...v6.0.0) (2020-02-26) ### Breaking Changes @@ -17,6 +72,13 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. <a name="5.0.2"></a> +### [8.0.1](https://www.github.com/npm/cli/compare/libnpmhook-vlibnpmhook@8.0.0...libnpmhook-v8.0.1) (2022-03-03) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) + ## [5.0.2](https://github.com/npm/libnpmhook/compare/v5.0.1...v5.0.2) (2018-08-24) diff --git a/workspaces/libnpmhook/README.md b/workspaces/libnpmhook/README.md index ce6e8c1..309f804 100644 --- a/workspaces/libnpmhook/README.md +++ b/workspaces/libnpmhook/README.md @@ -2,7 +2,7 @@ [![npm version](https://img.shields.io/npm/v/libnpmhook.svg)](https://npm.im/libnpmhook) [![license](https://img.shields.io/npm/l/libnpmhook.svg)](https://npm.im/libnpmhook) -[![Coverage Status](https://coveralls.io/repos/github/npm/libnpmhook/badge.svg?branch=latest)](https://coveralls.io/github/npm/libnpmhook?branch=latest) +[![CI - libnpmhook](https://github.com/npm/cli/actions/workflows/ci-libnpmhook.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-libnpmhook.yml) [`libnpmhook`](https://github.com/npm/libnpmhook) is a Node.js library for programmatically managing the npm registry's server-side hooks. diff --git a/workspaces/libnpmhook/SECURITY.md b/workspaces/libnpmhook/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/libnpmhook/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/libnpmhook/lib/index.js b/workspaces/libnpmhook/lib/index.js index 7cd1826..091cdc4 100644 --- a/workspaces/libnpmhook/lib/index.js +++ b/workspaces/libnpmhook/lib/index.js @@ -13,7 +13,7 @@ cmd.add = (name, endpoint, secret, opts = {}) => { } if (name[0] === '~') { type = 'owner' - name = name.substr(1) + name = name.slice(1) } return fetch.json('/-/npm/v1/hooks/hook', { ...opts, diff --git a/workspaces/libnpmhook/package.json b/workspaces/libnpmhook/package.json index 4f30555..b157f97 100644 --- a/workspaces/libnpmhook/package.json +++ b/workspaces/libnpmhook/package.json @@ -1,29 +1,28 @@ { "name": "libnpmhook", - "version": "7.0.1", + "version": "9.0.1", "description": "programmatic API for managing npm registry hooks", "main": "lib/index.js", "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "scripts": { "prerelease": "npm t", "postrelease": "npm publish && git push --follow-tags", "test": "tap", - "lint": "eslint '**/*.js'", - "postlint": "npm-template-check", - "lintfix": "npm run lint -- --fix", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "lintfix": "node ../.. run lint -- --fix", "snap": "tap", - "posttest": "npm run lint" + "posttest": "node ../.. run lint", + "template-oss-apply": "template-oss-apply --force" }, - "tap": { - "check-coverage": true + "repository": { + "type": "git", + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/libnpmhook" }, - "repository": "https://github.com/npm/libnpmhook", "keywords": [ "npm", "hooks", @@ -34,17 +33,26 @@ "license": "ISC", "dependencies": { "aproba": "^2.0.0", - "npm-registry-fetch": "^12.0.1" + "npm-registry-fetch": "^14.0.3" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "nock": "^9.6.1", - "tap": "^15.1.0" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "nock": "^13.2.4", + "tap": "^16.3.2" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/workspaces/libnpmorg/.eslintrc.js b/workspaces/libnpmorg/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/libnpmorg/.eslintrc.js +++ b/workspaces/libnpmorg/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/libnpmorg/.gitignore b/workspaces/libnpmorg/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/libnpmorg/.gitignore +++ b/workspaces/libnpmorg/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/libnpmorg/.npmrc b/workspaces/libnpmorg/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/libnpmorg/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/libnpmorg/CHANGELOG.md b/workspaces/libnpmorg/CHANGELOG.md index 4cd5cd1..3994677 100644 --- a/workspaces/libnpmorg/CHANGELOG.md +++ b/workspaces/libnpmorg/CHANGELOG.md @@ -1,4 +1,66 @@ -# Change Log +# Changelog + +## [5.0.1](https://github.com/npm/cli/compare/libnpmorg-v5.0.0...libnpmorg-v5.0.1) (2022-12-07) + +### Dependencies + +* [`0a3fe00`](https://github.com/npm/cli/commit/0a3fe000e2723ae6fdb8b1d3154fd3835057c992) [#5933](https://github.com/npm/cli/pull/5933) `minipass@4.0.0` +* [`fee9b66`](https://github.com/npm/cli/commit/fee9b6686892a1c7f976c36ddd5d89b70c416817) `npm-registry-fetch@14.0.3` + +## [5.0.0](https://github.com/npm/cli/compare/libnpmorg-v5.0.0-pre.1...libnpmorg-v5.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +## [5.0.0-pre.1](https://github.com/npm/cli/compare/libnpmorg-v5.0.0-pre.0...libnpmorg-v5.0.0-pre.1) (2022-10-19) + +### Dependencies + +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies + +## [5.0.0-pre.0](https://github.com/npm/cli/compare/libnpmorg-v4.0.4...libnpmorg-v5.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + +## [4.0.4](https://github.com/npm/cli/compare/libnpmorg-v4.0.3...libnpmorg-v4.0.4) (2022-08-31) + +### Dependencies + + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` + +### [4.0.3](https://github.com/npm/cli/compare/libnpmorg-v4.0.2...libnpmorg-v4.0.3) (2022-04-06) + + +### Bug Fixes + +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/template-oss@3.2.1 ([aac01b8](https://github.com/npm/cli/commit/aac01b89caf6336a2eb34d696296303cdadd5c08)) +* @npmcli/template-oss@3.2.2 ([#4639](https://github.com/npm/cli/issues/4639)) ([a59fd2c](https://github.com/npm/cli/commit/a59fd2cb863245fce56f96c90ac854e62c5c4d6f)) + +### [4.0.2](https://www.github.com/npm/cli/compare/libnpmorg-v4.0.1...libnpmorg-v4.0.2) (2022-03-10) + + +### Documentation + +* standardize changelog heading ([#4510](https://www.github.com/npm/cli/issues/4510)) ([91f03ee](https://www.github.com/npm/cli/commit/91f03ee618bc635f9cfbded735fe98bbfa9d643f)) + +### [4.0.1](https://www.github.com/npm/cli/compare/libnpmorg-vlibnpmorg@4.0.0...libnpmorg-v4.0.1) (2022-03-03) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) ## 2.0.0 (2020-03-02) diff --git a/workspaces/libnpmorg/README.md b/workspaces/libnpmorg/README.md index b2e1ed5..d516552 100644 --- a/workspaces/libnpmorg/README.md +++ b/workspaces/libnpmorg/README.md @@ -2,8 +2,7 @@ [![npm version](https://img.shields.io/npm/v/libnpmorg.svg)](https://npm.im/libnpmorg) [![license](https://img.shields.io/npm/l/libnpmorg.svg)](https://npm.im/libnpmorg) -[![GitHub Actions](https://github.com/npm/libnpmorg/workflows/Node%20CI/badge.svg)](https://github.com/npm/libnpmorg/workflows/Node%20CI/badge.svg) -[![Coverage Status](https://coveralls.io/repos/github/npm/libnpmorg/badge.svg?branch=latest)](https://coveralls.io/github/npm/libnpmorg?branch=latest) +[![CI - libnpmorg](https://github.com/npm/cli/actions/workflows/ci-libnpmorg.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-libnpmorg.yml) [`libnpmorg`](https://github.com/npm/libnpmorg) is a Node.js library for programmatically accessing the [npm Org membership diff --git a/workspaces/libnpmorg/SECURITY.md b/workspaces/libnpmorg/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/libnpmorg/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/libnpmorg/package.json b/workspaces/libnpmorg/package.json index 5c4909b..529a7ff 100644 --- a/workspaces/libnpmorg/package.json +++ b/workspaces/libnpmorg/package.json @@ -1,6 +1,6 @@ { "name": "libnpmorg", - "version": "3.0.1", + "version": "5.0.1", "description": "Programmatic api for `npm org` commands", "author": "GitHub Inc.", "main": "lib/index.js", @@ -14,43 +14,48 @@ ], "license": "ISC", "scripts": { - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "lint": "eslint '**/*.js'", + "lint": "eslint \"**/*.js\"", "test": "tap", - "posttest": "npm run lint", - "postlint": "npm-template-check", - "lintfix": "npm run lint -- --fix", - "snap": "tap" + "posttest": "node ../.. run lint", + "postlint": "template-oss-check", + "lintfix": "node ../.. run lint -- --fix", + "snap": "tap", + "template-oss-apply": "template-oss-apply --force" }, "files": [ - "bin", - "lib" + "bin/", + "lib/" ], - "tap": { - "check-coverage": true - }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "minipass": "^3.1.1", - "nock": "^12.0.1", - "tap": "^15.0.0" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "minipass": "^4.0.0", + "nock": "^13.2.4", + "tap": "^16.3.2" }, "repository": { "type": "git", - "url": "https://github.com/npm/libnpmorg.git" + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/libnpmorg" }, "bugs": "https://github.com/npm/libnpmorg/issues", "homepage": "https://npmjs.com/package/libnpmorg", "dependencies": { "aproba": "^2.0.0", - "npm-registry-fetch": "^12.0.1" + "npm-registry-fetch": "^14.0.3" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/workspaces/libnpmorg/test/index.js b/workspaces/libnpmorg/test/index.js index ecdda07..bbe4ff4 100644 --- a/workspaces/libnpmorg/test/index.js +++ b/workspaces/libnpmorg/test/index.js @@ -11,7 +11,7 @@ const OPTS = { } const REG = 'https://registry.npmjs.org/' -test('set', t => { +test('set', async t => { const memDeets = { org: { name: 'myorg', @@ -27,13 +27,11 @@ test('set', t => { }) .reply(201, memDeets) - return org.set('myorg', 'myuser', 'admin', OPTS) - .then(res => { - t.same(res, memDeets, 'got a membership details object back') - }) + const res = await org.set('myorg', 'myuser', 'admin', OPTS) + t.same(res, memDeets, 'got a membership details object back') }) -test('optional role for set', t => { +test('optional role for set', async t => { const memDeets = { org: { name: 'myorg', @@ -45,57 +43,48 @@ test('optional role for set', t => { tnock(t, OPTS.registry).put('/-/org/myorg/user', { user: 'myuser', }).reply(201, memDeets) - return org.set('myorg', 'myuser', OPTS).then(res => { - t.same(res, memDeets, 'got a membership details object back') - }) + const res = await org.set('myorg', 'myuser', OPTS) + t.same(res, memDeets, 'got a membership details object back') }) -test('rm with no options', t => { +test('rm with no options', async t => { tnock(t, REG).delete('/-/org/myorg/user', { user: 'myuser', }).reply(204) - return org.rm('myorg', 'myuser').then(() => { - t.ok(true, 'request succeeded') - }) + await t.resolves(org.rm('myorg', 'myuser')) }) -test('rm', t => { +test('rm', async t => { tnock(t, OPTS.registry).delete('/-/org/myorg/user', { user: 'myuser', }).reply(204) - return org.rm('myorg', 'myuser', OPTS) - .then(ret => { - t.equal(ret, null, 'null return value') - t.ok(true, 'request succeeded') - }) + const ret = await org.rm('myorg', 'myuser', OPTS) + t.equal(ret, null, 'null return value') }) -test('ls with no options', t => { +test('ls with no options', async t => { const roster = { zkat: 'developer', iarna: 'admin', isaacs: 'owner', } tnock(t, REG).get('/-/org/myorg/user').reply(200, roster) - return org.ls('myorg').then(res => { - t.same(res, roster, 'got back a roster') - }) + const res = await org.ls('myorg') + t.same(res, roster, 'got back a roster') }) -test('ls', t => { +test('ls', async t => { const roster = { zkat: 'developer', iarna: 'admin', isaacs: 'owner', } tnock(t, OPTS.registry).get('/-/org/myorg/user').reply(200, roster) - return org.ls('myorg', OPTS).then(res => { - t.same(res, roster, 'got back a roster') - }) + const res = await org.ls('myorg', OPTS) + t.same(res, roster, 'got back a roster') }) -test('ls stream with no options', t => { - t.plan(2) +test('ls stream with no options', async t => { const roster = { zkat: 'developer', iarna: 'admin', @@ -105,14 +94,11 @@ test('ls stream with no options', t => { tnock(t, REG).get('/-/org/myorg/user').reply(200, roster) const result = org.ls.stream('myorg') t.ok(Minipass.isStream(result), 'returns a stream') - return result.collect() - .then(res => { - t.same(res, rosterArr, 'got back a roster, in entries format') - }) + const res = await result.collect() + t.same(res, rosterArr, 'got back a roster, in entries format') }) -test('ls stream', t => { - t.plan(2) +test('ls stream', async t => { const roster = { zkat: 'developer', iarna: 'admin', @@ -122,8 +108,6 @@ test('ls stream', t => { tnock(t, OPTS.registry).get('/-/org/myorg/user').reply(200, roster) const result = org.ls.stream('myorg', OPTS) t.ok(Minipass.isStream(result), 'returns a stream') - return result.collect() - .then(res => { - t.same(res, rosterArr, 'got back a roster, in entries format') - }) + const res = await result.collect() + t.same(res, rosterArr, 'got back a roster, in entries format') }) diff --git a/workspaces/libnpmpack/.eslintrc.js b/workspaces/libnpmpack/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/libnpmpack/.eslintrc.js +++ b/workspaces/libnpmpack/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/libnpmpack/.gitignore b/workspaces/libnpmpack/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/libnpmpack/.gitignore +++ b/workspaces/libnpmpack/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/libnpmpack/.npmrc b/workspaces/libnpmpack/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/libnpmpack/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/libnpmpack/CHANGELOG.md b/workspaces/libnpmpack/CHANGELOG.md index 2310ac7..79baeaa 100644 --- a/workspaces/libnpmpack/CHANGELOG.md +++ b/workspaces/libnpmpack/CHANGELOG.md @@ -1,17 +1,187 @@ -# Change Log +# Changelog -<a name="2.0.0"></a> -# [2.0.0](https://github.com/npm/libnpmpack/compare/v1.0.0...v2.0.0) (2020-03-27) +## [5.0.6](https://github.com/npm/cli/compare/libnpmpack-v5.0.5...libnpmpack-v5.0.6) (2022-12-07) + +### Dependencies + +* [`0a3fe00`](https://github.com/npm/cli/commit/0a3fe000e2723ae6fdb8b1d3154fd3835057c992) [#5933](https://github.com/npm/cli/pull/5933) `minipass@4.0.0` +* [`3da9a1a`](https://github.com/npm/cli/commit/3da9a1a4ebcf1779035b5f9ae985c087f617efe3) `pacote@15.0.7` +* [`875bd56`](https://github.com/npm/cli/commit/875bd56c33ca5eef80c2a50a11808445f2a39a2a) `npm-package-arg@10.1.0` +* [Workspace](https://github.com/npm/cli/releases/tag/arborist-v6.1.5): `@npmcli/arborist@6.1.5` + +## [5.0.5](https://github.com/npm/cli/compare/libnpmpack-v5.0.4...libnpmpack-v5.0.5) (2022-11-30) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.3...arborist-v6.1.4): `@npmcli/arborist@6.1.4` + +## [5.0.4](https://github.com/npm/cli/compare/libnpmpack-v5.0.3...libnpmpack-v5.0.4) (2022-11-16) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.2...arborist-v6.1.3): `@npmcli/arborist@6.1.3` + +## [5.0.3](https://github.com/npm/cli/compare/libnpmpack-v5.0.2...libnpmpack-v5.0.3) (2022-11-09) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.1...arborist-v6.1.2): `@npmcli/arborist@6.1.2` + +## [5.0.2](https://github.com/npm/cli/compare/libnpmpack-v5.0.1...libnpmpack-v5.0.2) (2022-11-02) + +### Bug Fixes + +* [`1f5382d`](https://github.com/npm/cli/commit/1f5382dada181cda41f1504974de1e69a6c1ad7f) [#5789](https://github.com/npm/cli/pull/5789) don't set `stdioString` for any spawn/run-script calls (@lukekarrys) + +### Dependencies + +* [`abfb28b`](https://github.com/npm/cli/commit/abfb28b249183b8c033f8e7acc1546150cdac137) `@npmcli/run-script@6.0.0` +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.1.0...arborist-v6.1.1): `@npmcli/arborist@6.1.1` + +## [5.0.1](https://github.com/npm/cli/compare/libnpmpack-v5.0.0...libnpmpack-v5.0.1) (2022-10-26) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0...arborist-v6.1.0): `@npmcli/arborist@6.1.0` + +## [5.0.0](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.4...libnpmpack-v5.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.5...arborist-v6.0.0): `@npmcli/arborist@6.0.0` + +## [5.0.0-pre.4](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.3...libnpmpack-v5.0.0-pre.4) (2022-10-19) + +### Dependencies + +* [`2008ea6`](https://github.com/npm/cli/commit/2008ea6a807acbd97912799adfe97f276202cea6) `npm-package-arg@10.0.0`, `pacote@15.0.2` +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.4...arborist-v6.0.0-pre.5): `@npmcli/arborist@6.0.0-pre.5` + +## [5.0.0-pre.3](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.2...libnpmpack-v5.0.0-pre.3) (2022-10-13) + +### Bug Fixes + +* [`a990c3c`](https://github.com/npm/cli/commit/a990c3c9a0e67f0a8b6454213675e159fe49432d) [#5651](https://github.com/npm/cli/pull/5651) libnpmpack: obey ignoreScripts (@winterqt) + +## [5.0.0-pre.2](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.1...libnpmpack-v5.0.0-pre.2) (2022-10-05) + +### Bug Fixes + +* [`e4e8ae2`](https://github.com/npm/cli/commit/e4e8ae20aef9e27e57282e87e8757d5b364abb39) libnpmpack: obey foregroundScripts (@winterqt) + +### Dependencies + +* [`5344d2c`](https://github.com/npm/cli/commit/5344d2ca9ffd1f6db473fd58b46b50179f899ff5) [#5644](https://github.com/npm/cli/pull/5644) `pacote@14.0.0` +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.3...arborist-v6.0.0-pre.4): `@npmcli/arborist@6.0.0-pre.4` + +## [5.0.0-pre.1](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.0...libnpmpack-v5.0.0-pre.1) (2022-09-30) + +### ⚠️ BREAKING CHANGES + +* `npm pack` now follows a strict order of operations when applying ignore rules. If a files array is present in the package.json, then rules in .gitignore and .npmignore files from the root will be ignored. + +### Features + +* [`3ae796d`](https://github.com/npm/cli/commit/3ae796d937bd36a5b1b9fd6e9e8473b4f2ddc32d) implement new `npm-packlist` behavior (@lukekarrys) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/arborist-v6.0.0-pre.2...arborist-v6.0.0-pre.3): `@npmcli/arborist@6.0.0-pre.3` + +## [5.0.0-pre.0](https://github.com/npm/cli/compare/libnpmpack-v4.1.3...libnpmpack-v5.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + +## [4.1.3](https://github.com/npm/cli/compare/libnpmpack-v4.1.2...libnpmpack-v4.1.3) (2022-08-31) + +### Dependencies + + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` + +## [4.1.2](https://github.com/npm/cli/compare/libnpmpack-v4.1.1...libnpmpack-v4.1.2) (2022-06-23) + + +### Dependencies + +* @npmcli/run-script@4.1.3 ([#5064](https://github.com/npm/cli/issues/5064)) ([f59a114](https://github.com/npm/cli/commit/f59a114ffe3d1f86ccb2e52a4432292ab76852cc)) + +## [4.1.1](https://github.com/npm/cli/compare/libnpmpack-v4.1.0...libnpmpack-v4.1.1) (2022-06-22) + + +### Dependencies + +* @npmcli/run-script@4.1.0 ([2c06cee](https://github.com/npm/cli/commit/2c06ceee82dd813c0ae84cc0b09e6941cfc5533e)) +* pacote@13.6.1 ([2e50cb8](https://github.com/npm/cli/commit/2e50cb83e84cf25fee93ba0ca5a0343fbdb33c41)) + +## [4.1.0](https://github.com/npm/cli/compare/libnpmpack-v4.0.3...libnpmpack-v4.1.0) (2022-05-25) + + +### Features + +* **libnpmpack:** bump pacote for better workspace awareness ([7307c8d](https://github.com/npm/cli/commit/7307c8de388cd14c96c42d70b7e567ec343ad084)) + + +### Dependencies + +* pacote@13.5.0 npm-packlist@5.1.0 ([353e2f9](https://github.com/npm/cli/commit/353e2f9dc60a5d319d4105822a9e0b2ddbf82bc0)) + +### [4.0.3](https://github.com/npm/cli/compare/libnpmpack-v4.0.2...libnpmpack-v4.0.3) (2022-04-06) + + +### Bug Fixes + +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/template-oss@3.2.1 ([aac01b8](https://github.com/npm/cli/commit/aac01b89caf6336a2eb34d696296303cdadd5c08)) +* @npmcli/template-oss@3.2.2 ([#4639](https://github.com/npm/cli/issues/4639)) ([a59fd2c](https://github.com/npm/cli/commit/a59fd2cb863245fce56f96c90ac854e62c5c4d6f)) + +### [4.0.2](https://www.github.com/npm/cli/compare/libnpmpack-v4.0.1...libnpmpack-v4.0.2) (2022-03-15) + + +### Documentation + +* standardize changelog heading ([#4510](https://www.github.com/npm/cli/issues/4510)) ([91f03ee](https://www.github.com/npm/cli/commit/91f03ee618bc635f9cfbded735fe98bbfa9d643f)) + + +### Dependencies + +* npm-package-arg@9.0.1 ([9555a5f](https://www.github.com/npm/cli/commit/9555a5f1d135aa1b8f7374273403efe41e99ee26)) +* pacote@13.0.4 ([6d31450](https://www.github.com/npm/cli/commit/6d3145014861b4198c16d7772d809fd037ece289)) +* pacote@13.0.5 ([340fa51](https://www.github.com/npm/cli/commit/340fa51f423a518a96c8015a67d8f6144a2e8051)) + +### [4.0.1](https://www.github.com/npm/cli/compare/libnpmpack-vlibnpmpack@4.0.0...libnpmpack-v4.0.1) (2022-03-03) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) + + +## [2.0.0](https://github.com/npm/libnpmpack/compare/v1.0.0...v2.0.0) (2020-03-27) ### Breaking Changes * [`cb2ecf2`](https://github.com/npm/libnpmpack/commit/cb2ecf2) feat: resolve to tarball data Buffer ([@claudiahdz](https://github.com/claudiahdz)) -<a name="1.0.0"></a> -# 1.0.0 (2020-03-26) + +### 1.0.0 (2020-03-26) + ### Features * [`a35c590`](https://github.com/npm/libnpmpack/commit/a35c590) feat: pack tarballs from local dir or registry spec ([@claudiahdz](https://github.com/claudiahdz)) - * [`6d72149`](https://github.com/npm/libnpmpack/commit/6d72149) feat: sorted tarball contents ([@eridal](https://github.com/eridal)) diff --git a/workspaces/libnpmpack/README.md b/workspaces/libnpmpack/README.md index 74b4934..e3ed416 100644 --- a/workspaces/libnpmpack/README.md +++ b/workspaces/libnpmpack/README.md @@ -2,8 +2,7 @@ [![npm version](https://img.shields.io/npm/v/libnpmpack.svg)](https://npm.im/libnpmpack) [![license](https://img.shields.io/npm/l/libnpmpack.svg)](https://npm.im/libnpmpack) -[![GitHub Actions](https://github.com/npm/libnpmpack/workflows/Node%20CI/badge.svg)](https://github.com/npm/libnpmpack/actions?query=workflow%3A%22Node+CI%22) -[![Coverage Status](https://coveralls.io/repos/github/npm/libnpmpack/badge.svg?branch=latest)](https://coveralls.io/github/npm/libnpmpack?branch=latest) +[![CI - libnpmpack](https://github.com/npm/cli/actions/workflows/ci-libnpmpack.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-libnpmpack.yml) [`libnpmpack`](https://github.com/npm/libnpmpack) is a Node.js library for programmatically packing tarballs from a local directory or from a registry or github spec. If packing from a local source, `libnpmpack` will also run the `prepack` and `postpack` lifecycles. diff --git a/workspaces/libnpmpack/SECURITY.md b/workspaces/libnpmpack/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/libnpmpack/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/libnpmpack/lib/index.js b/workspaces/libnpmpack/lib/index.js index a2c95cf..70d67d3 100644 --- a/workspaces/libnpmpack/lib/index.js +++ b/workspaces/libnpmpack/lib/index.js @@ -5,6 +5,7 @@ const npa = require('npm-package-arg') const runScript = require('@npmcli/run-script') const path = require('path') const util = require('util') +const Arborist = require('@npmcli/arborist') const writeFile = util.promisify(require('fs').writeFile) module.exports = pack @@ -16,15 +17,17 @@ async function pack (spec = 'file:.', opts = {}) { // Default to true if no log options passed, set to false if we're in silent // mode - const banner = !opts.log || (opts.log.level !== 'silent') + const banner = !opts.silent - if (spec.type === 'directory') { + const stdio = opts.foregroundScripts ? 'inherit' : 'pipe' + + if (spec.type === 'directory' && !opts.ignoreScripts) { // prepack await runScript({ ...opts, event: 'prepack', path: spec.fetchSpec, - stdio: 'inherit', + stdio, pkg: manifest, banner, }) @@ -33,6 +36,7 @@ async function pack (spec = 'file:.', opts = {}) { // packs tarball const tarball = await pacote.tarball(manifest._resolved, { ...opts, + Arborist, integrity: manifest._integrity, }) @@ -44,13 +48,13 @@ async function pack (spec = 'file:.', opts = {}) { await writeFile(destination, tarball) } - if (spec.type === 'directory') { + if (spec.type === 'directory' && !opts.ignoreScripts) { // postpack await runScript({ ...opts, event: 'postpack', path: spec.fetchSpec, - stdio: 'inherit', + stdio, pkg: manifest, banner, env: { diff --git a/workspaces/libnpmpack/package.json b/workspaces/libnpmpack/package.json index 7317c27..3fd1f38 100644 --- a/workspaces/libnpmpack/package.json +++ b/workspaces/libnpmpack/package.json @@ -1,6 +1,6 @@ { "name": "libnpmpack", - "version": "3.1.0", + "version": "5.0.6", "description": "Programmatic API for the bits behind npm pack", "author": "GitHub Inc.", "main": "lib/index.js", @@ -8,44 +8,51 @@ "Claudia Hernández <claudia@npmjs.com>" ], "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "license": "ISC", "scripts": { - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "lint": "eslint '**/*.js'", + "lint": "eslint \"**/*.js\"", "test": "tap", - "posttest": "npm run lint", - "postlint": "npm-template-check", - "lintfix": "npm run lint -- --fix", - "snap": "tap" - }, - "tap": { - "check-coverage": true + "posttest": "node ../.. run lint", + "postlint": "template-oss-check", + "lintfix": "node ../.. run lint -- --fix", + "snap": "tap", + "template-oss-apply": "template-oss-apply --force" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", "nock": "^13.0.7", - "tap": "^15.0.0" + "spawk": "^1.7.1", + "tap": "^16.3.2" }, "repository": { "type": "git", - "url": "https://github.com/npm/libnpmpack.git" + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/libnpmpack" }, "bugs": "https://github.com/npm/libnpmpack/issues", "homepage": "https://npmjs.com/package/libnpmpack", "dependencies": { - "@npmcli/run-script": "^2.0.0", - "npm-package-arg": "^8.1.0", - "pacote": "^12.0.0" + "@npmcli/arborist": "^6.1.5", + "@npmcli/run-script": "^6.0.0", + "npm-package-arg": "^10.1.0", + "pacote": "^15.0.7" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/workspaces/libnpmpack/test/fixtures/tspawk.js b/workspaces/libnpmpack/test/fixtures/tspawk.js new file mode 100644 index 0000000..b2559fc --- /dev/null +++ b/workspaces/libnpmpack/test/fixtures/tspawk.js @@ -0,0 +1,13 @@ +'use strict' + +const spawk = require('spawk') + +module.exports = tspawk + +function tspawk (t) { + t.teardown(function () { + spawk.done() + spawk.unload() + }) + return spawk +} diff --git a/workspaces/libnpmpack/test/index.js b/workspaces/libnpmpack/test/index.js index 5f25f41..ee34cd2 100644 --- a/workspaces/libnpmpack/test/index.js +++ b/workspaces/libnpmpack/test/index.js @@ -1,6 +1,10 @@ 'use strict' const t = require('tap') + +const tspawk = require('./fixtures/tspawk.js') +const spawk = tspawk(t) + const fs = require('fs') const path = require('path') const pack = require('../lib/index.js') @@ -37,8 +41,8 @@ t.test('writes tarball to file when dryRun === false', async t => { name: 'my-cool-pkg', version: '1.0.0', scripts: { - prepack: 'touch prepack', - postpack: 'touch postpack', + prepack: 'touch prepack && sleep 1', + postpack: 'sleep 1 && touch postpack', }, }, null, 2), }) @@ -49,7 +53,7 @@ t.test('writes tarball to file when dryRun === false', async t => { const tarball = await pack('file:.', { dryRun: false, packDestination: testDir, - log: { level: 'silent' }, // so the test doesn't try to log + silent: true, }) t.ok(tarball) const expectedTarball = path.join(testDir, 'my-cool-pkg-1.0.0.tgz') @@ -68,7 +72,7 @@ t.test('writes tarball to file when dryRun === false', async t => { }) }) -t.test('packs from local directory with silent loglevel', async t => { +t.test('packs from local directory with silent', async t => { const testDir = t.testdir({ 'package.json': JSON.stringify({ name: 'my-cool-pkg', @@ -79,7 +83,7 @@ t.test('packs from local directory with silent loglevel', async t => { const cwd = process.cwd() process.chdir(testDir) - const tarball = await pack('file:', { log: { level: 'silent' } }) + const tarball = await pack('file:', { silent: true }) t.ok(tarball) t.teardown(async () => { @@ -128,3 +132,69 @@ t.test('packs from registry spec', async t => { const tarball = await pack(spec, { ...OPTS }) t.ok(tarball) }) + +t.test('runs scripts in foreground when foregroundScripts === true', async t => { + const testDir = t.testdir({ + 'package.json': JSON.stringify({ + name: 'my-cool-pkg', + version: '1.0.0', + scripts: { + prepack: 'touch prepack', + }, + }, null, 2), + }) + + const cwd = process.cwd() + process.chdir(testDir) + + const shell = process.platform === 'win32' + ? process.env.COMSPEC + : 'sh' + + const args = process.platform === 'win32' + ? ['/d', '/s', '/c', 'touch prepack'] + : ['-c', 'touch prepack'] + + const prepack = spawk.spawn(shell, args) + + await pack('file:.', { + packDestination: testDir, + foregroundScripts: true, + }) + + t.ok(prepack.called) + + t.teardown(async () => { + process.chdir(cwd) + }) +}) + +t.test('doesn\'t run scripts when ignoreScripts === true', async t => { + const testDir = t.testdir({ + 'package.json': JSON.stringify({ + name: 'my-cool-pkg', + version: '1.0.0', + scripts: { + prepack: 'touch prepack', + }, + }, null, 2), + }) + + const cwd = process.cwd() + process.chdir(testDir) + + const prepack = spawk.spawn('sh', ['-c', 'touch prepack']) + + await pack('file:.', { + packDestination: testDir, + foregroundScripts: true, + ignoreScripts: true, + }) + + t.ok(!prepack.called) + + t.teardown(async () => { + process.chdir(cwd) + spawk.clean() + }) +}) diff --git a/workspaces/libnpmpublish/.eslintrc.js b/workspaces/libnpmpublish/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/libnpmpublish/.eslintrc.js +++ b/workspaces/libnpmpublish/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/libnpmpublish/.gitignore b/workspaces/libnpmpublish/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/libnpmpublish/.gitignore +++ b/workspaces/libnpmpublish/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/libnpmpublish/.npmrc b/workspaces/libnpmpublish/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/libnpmpublish/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/libnpmpublish/CHANGELOG.md b/workspaces/libnpmpublish/CHANGELOG.md index 57d21f8..4d0b639 100644 --- a/workspaces/libnpmpublish/CHANGELOG.md +++ b/workspaces/libnpmpublish/CHANGELOG.md @@ -1,7 +1,156 @@ -# Change Log +# Changelog -<a name="3.0.1"></a> -# [3.0.1](https://github.com/npm/libnpmpublish/compare/v3.0.0...v3.0.1) (2020-03-27) +## [7.0.6](https://github.com/npm/cli/compare/libnpmpublish-v7.0.5...libnpmpublish-v7.0.6) (2022-12-07) + +### Dependencies + +* [`0a3fe00`](https://github.com/npm/cli/commit/0a3fe000e2723ae6fdb8b1d3154fd3835057c992) [#5933](https://github.com/npm/cli/pull/5933) `minipass@4.0.0` +* [`cf0a174`](https://github.com/npm/cli/commit/cf0a17407abc577c27420a1c8a4a0c08c7cefce9) `ssri@10.0.1` +* [`fee9b66`](https://github.com/npm/cli/commit/fee9b6686892a1c7f976c36ddd5d89b70c416817) `npm-registry-fetch@14.0.3` +* [`875bd56`](https://github.com/npm/cli/commit/875bd56c33ca5eef80c2a50a11808445f2a39a2a) `npm-package-arg@10.1.0` +* [Workspace](https://github.com/npm/cli/releases/tag/libnpmpack-v5.0.6): `libnpmpack@5.0.6` + +## [7.0.5](https://github.com/npm/cli/compare/libnpmpublish-v7.0.4...libnpmpublish-v7.0.5) (2022-11-30) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.4...libnpmpack-v5.0.5): `libnpmpack@5.0.5` + +## [7.0.4](https://github.com/npm/cli/compare/libnpmpublish-v7.0.3...libnpmpublish-v7.0.4) (2022-11-16) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.3...libnpmpack-v5.0.4): `libnpmpack@5.0.4` + +## [7.0.3](https://github.com/npm/cli/compare/libnpmpublish-v7.0.2...libnpmpublish-v7.0.3) (2022-11-09) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.2...libnpmpack-v5.0.3): `libnpmpack@5.0.3` + +## [7.0.2](https://github.com/npm/cli/compare/libnpmpublish-v7.0.1...libnpmpublish-v7.0.2) (2022-11-02) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.1...libnpmpack-v5.0.2): `libnpmpack@5.0.2` + +## [7.0.1](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0...libnpmpublish-v7.0.1) (2022-10-26) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.0...libnpmpack-v5.0.1): `libnpmpack@5.0.1` + +## [7.0.0](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0-pre.4...libnpmpublish-v7.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.4...libnpmpack-v5.0.0): `libnpmpack@5.0.0` + +## [7.0.0-pre.4](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0-pre.3...libnpmpublish-v7.0.0-pre.4) (2022-10-19) + +### Dependencies + +* [`2008ea6`](https://github.com/npm/cli/commit/2008ea6a807acbd97912799adfe97f276202cea6) `npm-package-arg@10.0.0`, `pacote@15.0.2` +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.3...libnpmpack-v5.0.0-pre.4): `libnpmpack@5.0.0-pre.4` + +## [7.0.0-pre.3](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0-pre.2...libnpmpublish-v7.0.0-pre.3) (2022-10-13) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.2...libnpmpack-v5.0.0-pre.3): `libnpmpack@5.0.0-pre.3` + +## [7.0.0-pre.2](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0-pre.1...libnpmpublish-v7.0.0-pre.2) (2022-10-05) + +### Dependencies + +* [Workspace](https://github.com/npm/cli/compare/libnpmpack-v5.0.0-pre.1...libnpmpack-v5.0.0-pre.2): `libnpmpack@5.0.0-pre.2` + +## [7.0.0-pre.1](https://github.com/npm/cli/compare/libnpmpublish-v7.0.0-pre.0...libnpmpublish-v7.0.0-pre.1) (2022-09-30) + +### ⚠️ BREAKING CHANGES + +* The default value of `access` is now `public` + +### Features + +* [`525654e`](https://github.com/npm/cli/commit/525654e957a80c7f47472e18240e3c8d94e0568f) default access to `public` (@wraithgar) + +### Documentation + +* [`f0e7584`](https://github.com/npm/cli/commit/f0e758494698d9dd8a58d07bf71c87608c36869e) [#5601](https://github.com/npm/cli/pull/5601) update docs/logging for new --access default (@wraithgar) + +## [7.0.0-pre.0](https://github.com/npm/cli/compare/libnpmpublish-v6.0.5...libnpmpublish-v7.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + + +### Dependencies + +* The following workspace dependencies were updated + * devDependencies + * libnpmpack bumped from ^4.1.3 to ^5.0.0-pre.0 + +## [6.0.5](https://github.com/npm/cli/compare/libnpmpublish-v6.0.4...libnpmpublish-v6.0.5) (2022-08-31) + +### Dependencies + + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` +* The following workspace dependencies were updated + * devDependencies + * libnpmpack bumped from ^4.0.0 to ^4.1.3 + +### [6.0.4](https://github.com/npm/cli/compare/libnpmpublish-v6.0.3...libnpmpublish-v6.0.4) (2022-04-26) + + +### Bug Fixes + +* **libnpmpublish:** unpublish from custom reg ([#4657](https://github.com/npm/cli/issues/4657)) ([e9163b4](https://github.com/npm/cli/commit/e9163b48d8e46a80d2a4cc98c492b94dfa152cb8)) + + +### Dependencies + +* semver@7.3.7 ([c51e553](https://github.com/npm/cli/commit/c51e553a32315e4f1b703ca9030eb7ade91d1a85)) + +### [6.0.3](https://github.com/npm/cli/compare/libnpmpublish-v6.0.2...libnpmpublish-v6.0.3) (2022-04-06) + + +### Bug Fixes + +* replace deprecated String.prototype.substr() ([#4667](https://github.com/npm/cli/issues/4667)) ([e3da5df](https://github.com/npm/cli/commit/e3da5df4152fbe547f7871547165328e1bf06262)) +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/template-oss@3.2.1 ([aac01b8](https://github.com/npm/cli/commit/aac01b89caf6336a2eb34d696296303cdadd5c08)) +* @npmcli/template-oss@3.2.2 ([#4639](https://github.com/npm/cli/issues/4639)) ([a59fd2c](https://github.com/npm/cli/commit/a59fd2cb863245fce56f96c90ac854e62c5c4d6f)) +* ssri@9.0.0 ([a2781a3](https://github.com/npm/cli/commit/a2781a367d62328d7f870de878f1b63d66593f4f)) + +### [6.0.2](https://www.github.com/npm/cli/compare/libnpmpublish-v6.0.1...libnpmpublish-v6.0.2) (2022-03-15) + + +### Documentation + +* standardize changelog heading ([#4510](https://www.github.com/npm/cli/issues/4510)) ([91f03ee](https://www.github.com/npm/cli/commit/91f03ee618bc635f9cfbded735fe98bbfa9d643f)) + + +### Dependencies + +* normalize-package-data@4.0.0 ([b2a4942](https://www.github.com/npm/cli/commit/b2a494283f45a25d1b87bc40bf2d68812871e89c)) +* npm-package-arg@9.0.1 ([9555a5f](https://www.github.com/npm/cli/commit/9555a5f1d135aa1b8f7374273403efe41e99ee26)) + +## [3.0.1](https://github.com/npm/libnpmpublish/compare/v3.0.0...v3.0.1) (2020-03-27) ### Features @@ -25,6 +174,13 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +### [6.0.1](https://www.github.com/npm/cli/compare/libnpmpublish-vlibnpmpublish@6.0.0...libnpmpublish-v6.0.1) (2022-03-03) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) + ## [2.0.0](https://github.com/npm/libnpmpublish/compare/v1.1.3...v2.0.0) (2019-09-18) diff --git a/workspaces/libnpmpublish/README.md b/workspaces/libnpmpublish/README.md index 0da46e8..9c9c61d 100644 --- a/workspaces/libnpmpublish/README.md +++ b/workspaces/libnpmpublish/README.md @@ -1,5 +1,9 @@ # libnpmpublish +[![npm version](https://img.shields.io/npm/v/libnpmpublish.svg)](https://npm.im/libnpmpublish) +[![license](https://img.shields.io/npm/l/libnpmpublish.svg)](https://npm.im/libnpmpublish) +[![CI - libnpmpublish](https://github.com/npm/cli/actions/workflows/ci-libnpmpublish.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-libnpmpublish.yml) + [`libnpmpublish`](https://github.com/npm/libnpmpublish) is a Node.js library for programmatically publishing and unpublishing npm packages. Give it a manifest as an object and a tarball as a Buffer, and it'll put them on @@ -40,8 +44,8 @@ A couple of options of note: defaults to `latest`. * `opts.access` - tells the registry whether this package should be - published as public or restricted. Only applies to scoped packages, which - default to restricted. + published as `public` or `restricted`. Only applies to scoped + packages. Defaults to `public`. * `opts.token` - can be passed in and will be used as the authentication token for the registry. For other ways to pass in auth details, see the diff --git a/workspaces/libnpmpublish/SECURITY.md b/workspaces/libnpmpublish/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/libnpmpublish/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/libnpmpublish/lib/publish.js b/workspaces/libnpmpublish/lib/publish.js index f6d88f7..7d01fab 100644 --- a/workspaces/libnpmpublish/lib/publish.js +++ b/workspaces/libnpmpublish/lib/publish.js @@ -17,10 +17,9 @@ Remove the 'private' field from the package.json to publish it.`), // spec is used to pick the appropriate registry/auth combo const spec = npa.resolve(manifest.name, manifest.version) opts = { - defaultTag: 'latest', - // if scoped, restricted by default - access: spec.scope ? 'restricted' : 'public', + access: 'public', algorithms: ['sha512'], + defaultTag: 'latest', ...opts, spec, } @@ -58,7 +57,7 @@ Remove the 'private' field from the package.json to publish it.`), ...opts, query: { write: true }, }) - const newMetadata = patchMetadata(current, metadata, opts) + const newMetadata = patchMetadata(current, metadata) return npmFetch(spec.escapedName, { ...opts, method: 'PUT', diff --git a/workspaces/libnpmpublish/lib/unpublish.js b/workspaces/libnpmpublish/lib/unpublish.js index 7fbeea5..9b124c1 100644 --- a/workspaces/libnpmpublish/lib/unpublish.js +++ b/workspaces/libnpmpublish/lib/unpublish.js @@ -1,9 +1,26 @@ 'use strict' +const { URL } = require('url') const npa = require('npm-package-arg') const npmFetch = require('npm-registry-fetch') const semver = require('semver') -const { URL } = require('url') + +// given a tarball url and a registry url, returns just the +// relevant pathname portion of it, so that it can be handled +// elegantly by npm-registry-fetch which only expects pathnames +// and handles the registry hostname via opts +const getPathname = (tarball, registry) => { + const registryUrl = new URL(registry).pathname.slice(1) + let tarballUrl = new URL(tarball).pathname.slice(1) + + // test the tarball url to see if it starts with a possible + // pathname from the registry url, in that case strips that portion + // of it so that we only return the post-registry-url pathname + if (registryUrl) { + tarballUrl = tarballUrl.slice(registryUrl.length) + } + return tarballUrl +} const unpublish = async (spec, opts) => { spec = npa(spec) @@ -82,7 +99,7 @@ const unpublish = async (spec, opts) => { ...opts, query: { write: true }, }) - const tarballUrl = new URL(dist.tarball).pathname.substr(1) + const tarballUrl = getPathname(dist.tarball, opts.registry) await npmFetch(`${tarballUrl}/-rev/${_rev}`, { ...opts, method: 'DELETE', diff --git a/workspaces/libnpmpublish/package.json b/workspaces/libnpmpublish/package.json index 3fd2d6d..6e53723 100644 --- a/workspaces/libnpmpublish/package.json +++ b/workspaces/libnpmpublish/package.json @@ -1,6 +1,6 @@ { "name": "libnpmpublish", - "version": "5.0.1", + "version": "7.0.6", "description": "Programmatic API for the bits behind npm publish and unpublish", "author": "GitHub Inc.", "main": "lib/index.js", @@ -9,49 +9,54 @@ "Claudia Hernández <claudia@npmjs.com>" ], "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "license": "ISC", "scripts": { "eslint": "eslint", - "lint": "eslint '**/*.js'", - "lintfix": "npm run lint -- --fix", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", + "lint": "eslint \"**/*.js\"", + "lintfix": "node ../.. run lint -- --fix", "test": "tap", - "posttest": "npm run lint", - "postlint": "npm-template-check", - "snap": "tap" - }, - "tap": { - "check-coverage": true + "posttest": "node ../.. run lint", + "postlint": "template-oss-check", + "snap": "tap", + "template-oss-apply": "template-oss-apply --force" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "libnpmpack": "^3.0.0", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "libnpmpack": "^5.0.6", "lodash.clonedeep": "^4.5.0", - "nock": "^12.0.2", - "tap": "^15" + "nock": "^13.2.4", + "tap": "^16.3.2" }, "repository": { "type": "git", - "url": "https://github.com/npm/cli.git" + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/libnpmpublish" }, "bugs": "https://github.com/npm/cli/issues", "homepage": "https://npmjs.com/package/libnpmpublish", "dependencies": { - "normalize-package-data": "^3.0.2", - "npm-package-arg": "^8.1.2", - "npm-registry-fetch": "^12.0.1", - "semver": "^7.1.3", - "ssri": "^8.0.1" + "normalize-package-data": "^5.0.0", + "npm-package-arg": "^10.1.0", + "npm-registry-fetch": "^14.0.3", + "semver": "^7.3.7", + "ssri": "^10.0.1" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/workspaces/libnpmpublish/test/publish.js b/workspaces/libnpmpublish/test/publish.js index fdd20f8..c696e82 100644 --- a/workspaces/libnpmpublish/test/publish.js +++ b/workspaces/libnpmpublish/test/publish.js @@ -79,7 +79,66 @@ t.test('basic publish', async t => { t.ok(ret, 'publish succeeded') }) -t.test('scoped publish', async t => { +t.test('scoped publish - default access', async t => { + const manifest = { + name: '@claudiahdz/libnpmpublish', + version: '1.0.0', + description: 'some stuff', + } + + const tarData = await pack(`file:${testDir}`, { ...OPTS }) + const shasum = crypto.createHash('sha1').update(tarData).digest('hex') + const integrity = ssri.fromData(tarData, { algorithms: ['sha512'] }) + const packument = { + _id: '@claudiahdz/libnpmpublish', + name: '@claudiahdz/libnpmpublish', + description: 'some stuff', + 'dist-tags': { + latest: '1.0.0', + }, + versions: { + '1.0.0': { + _id: '@claudiahdz/libnpmpublish@1.0.0', + _nodeVersion: process.versions.node, + _npmVersion: '6.13.7', + name: '@claudiahdz/libnpmpublish', + version: '1.0.0', + description: 'some stuff', + dist: { + shasum, + integrity: integrity.toString(), + tarball: 'http://mock.reg/@claudiahdz/libnpmpublish/' + + '-/@claudiahdz/libnpmpublish-1.0.0.tgz', + }, + }, + }, + access: 'public', + _attachments: { + '@claudiahdz/libnpmpublish-1.0.0.tgz': { + content_type: 'application/octet-stream', + data: tarData.toString('base64'), + length: tarData.length, + }, + }, + } + + const srv = tnock(t, REG) + srv.put('/@claudiahdz%2flibnpmpublish', body => { + t.same(body, packument, 'posted packument matches expectations') + return true + }, { + authorization: 'Bearer deadbeef', + }).reply(201, {}) + + const ret = await publish(manifest, tarData, { + ...OPTS, + npmVersion: '6.13.7', + token: 'deadbeef', + }) + t.ok(ret, 'publish succeeded') +}) + +t.test('scoped publish - restricted access', async t => { const manifest = { name: '@claudiahdz/libnpmpublish', version: '1.0.0', @@ -132,6 +191,7 @@ t.test('scoped publish', async t => { const ret = await publish(manifest, tarData, { ...OPTS, + access: 'restricted', npmVersion: '6.13.7', token: 'deadbeef', }) diff --git a/workspaces/libnpmpublish/test/unpublish.js b/workspaces/libnpmpublish/test/unpublish.js index 6fbe802..b59dad6 100644 --- a/workspaces/libnpmpublish/test/unpublish.js +++ b/workspaces/libnpmpublish/test/unpublish.js @@ -134,6 +134,61 @@ t.test('unpublish specific version', async t => { t.ok(ret, 'foo was unpublished') }) +t.test('unpublishing from a custom registry', async t => { + const opt = { + registry: 'https://artifactory.example.com/api/npm/npm-snapshots/', + } + const reg = opt.registry + const doc = { + _id: 'foo', + _rev: REV, + _revisions: [1, 2, 3], + _attachments: [1, 2, 3], + name: 'foo', + 'dist-tags': { + latest: '1.0.1', + }, + versions: { + '1.0.0': { + name: 'foo', + dist: { + tarball: `${reg}/foo/-/foo-1.0.0.tgz`, + }, + }, + '1.0.1': { + name: 'foo', + dist: { + tarball: `${reg}/foo/-/foo-1.0.1.tgz`, + }, + }, + }, + } + const postEdit = { + _id: 'foo', + _rev: REV, + name: 'foo', + 'dist-tags': { + latest: '1.0.0', + }, + versions: { + '1.0.0': { + name: 'foo', + dist: { + tarball: `${reg}/foo/-/foo-1.0.0.tgz`, + }, + }, + }, + } + + const srv = tnock(t, reg) + srv.get('/foo?write=true').reply(200, doc) + srv.put(`/foo/-rev/${REV}`, postEdit).reply(200) + srv.get('/foo?write=true').reply(200, postEdit) + srv.delete(`/foo/-/foo-1.0.1.tgz/-rev/${REV}`).reply(200) + const ret = await unpub('foo@1.0.1', opt) + t.ok(ret, 'foo was unpublished') +}) + t.test('404 considered a success', async t => { const srv = tnock(t, REG) srv.get('/foo?write=true').reply(404) diff --git a/workspaces/libnpmsearch/.eslintrc.js b/workspaces/libnpmsearch/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/libnpmsearch/.eslintrc.js +++ b/workspaces/libnpmsearch/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/libnpmsearch/.gitignore b/workspaces/libnpmsearch/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/libnpmsearch/.gitignore +++ b/workspaces/libnpmsearch/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/libnpmsearch/.npmrc b/workspaces/libnpmsearch/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/libnpmsearch/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/libnpmsearch/CHANGELOG.md b/workspaces/libnpmsearch/CHANGELOG.md index 03b7fed..3bcc493 100644 --- a/workspaces/libnpmsearch/CHANGELOG.md +++ b/workspaces/libnpmsearch/CHANGELOG.md @@ -1,7 +1,61 @@ -# Change Log +# Changelog -<a name="3.0.0"></a> -# [3.0.0](https://github.com/npm/libnpmhook/compare/v2.0.2...v3.0.0) (2020-02-26) +## [6.0.1](https://github.com/npm/cli/compare/libnpmsearch-v6.0.0...libnpmsearch-v6.0.1) (2022-12-07) + +### Dependencies + +* [`0a3fe00`](https://github.com/npm/cli/commit/0a3fe000e2723ae6fdb8b1d3154fd3835057c992) [#5933](https://github.com/npm/cli/pull/5933) `minipass@4.0.0` +* [`fee9b66`](https://github.com/npm/cli/commit/fee9b6686892a1c7f976c36ddd5d89b70c416817) `npm-registry-fetch@14.0.3` + +## [6.0.0](https://github.com/npm/cli/compare/libnpmsearch-v6.0.0-pre.1...libnpmsearch-v6.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +## [6.0.0-pre.1](https://github.com/npm/cli/compare/libnpmsearch-v6.0.0-pre.0...libnpmsearch-v6.0.0-pre.1) (2022-10-19) + +### Dependencies + +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies + +## [6.0.0-pre.0](https://github.com/npm/cli/compare/libnpmsearch-v5.0.4...libnpmsearch-v6.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + +## [5.0.4](https://github.com/npm/cli/compare/libnpmsearch-v5.0.3...libnpmsearch-v5.0.4) (2022-08-31) + +### Dependencies + + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` + +### [5.0.3](https://github.com/npm/cli/compare/libnpmsearch-v5.0.2...libnpmsearch-v5.0.3) (2022-04-06) + + +### Bug Fixes + +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/template-oss@3.2.1 ([aac01b8](https://github.com/npm/cli/commit/aac01b89caf6336a2eb34d696296303cdadd5c08)) +* @npmcli/template-oss@3.2.2 ([#4639](https://github.com/npm/cli/issues/4639)) ([a59fd2c](https://github.com/npm/cli/commit/a59fd2cb863245fce56f96c90ac854e62c5c4d6f)) + +### [5.0.2](https://www.github.com/npm/cli/compare/libnpmsearch-v5.0.1...libnpmsearch-v5.0.2) (2022-03-10) + + +### Documentation + +* standardize changelog heading ([#4510](https://www.github.com/npm/cli/issues/4510)) ([91f03ee](https://www.github.com/npm/cli/commit/91f03ee618bc635f9cfbded735fe98bbfa9d643f)) + +## [3.0.0](https://github.com/npm/libnpmhook/compare/v2.0.2...v3.0.0) (2020-02-26) ### Breaking Changes @@ -18,6 +72,13 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. <a name="2.0.2"></a> +### [5.0.1](https://www.github.com/npm/cli/compare/libnpmsearch-vlibnpmsearch@5.0.0...libnpmsearch-v5.0.1) (2022-03-03) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) + ## [2.0.2](https://github.com/npm/libnpmsearch/compare/v2.0.1...v2.0.2) (2019-07-16) diff --git a/workspaces/libnpmsearch/README.md b/workspaces/libnpmsearch/README.md index 31f44fe..86d75b1 100644 --- a/workspaces/libnpmsearch/README.md +++ b/workspaces/libnpmsearch/README.md @@ -2,7 +2,7 @@ [![npm version](https://img.shields.io/npm/v/libnpmsearch.svg)](https://npm.im/libnpmsearch) [![license](https://img.shields.io/npm/l/libnpmsearch.svg)](https://npm.im/libnpmsearch) -[![Coverage Status](https://coveralls.io/repos/github/npm/libnpmsearch/badge.svg?branch=latest)](https://coveralls.io/github/npm/libnpmsearch?branch=latest) +[![CI - libnpmsearch](https://github.com/npm/cli/actions/workflows/ci-libnpmsearch.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-libnpmsearch.yml) [`libnpmsearch`](https://github.com/npm/libnpmsearch) is a Node.js library for programmatically accessing the npm search endpoint. It does **not** support diff --git a/workspaces/libnpmsearch/SECURITY.md b/workspaces/libnpmsearch/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/libnpmsearch/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/libnpmsearch/package.json b/workspaces/libnpmsearch/package.json index f524426..e0d67af 100644 --- a/workspaces/libnpmsearch/package.json +++ b/workspaces/libnpmsearch/package.json @@ -1,12 +1,12 @@ { "name": "libnpmsearch", - "version": "4.0.1", + "version": "6.0.1", "description": "Programmatic API for searching in npm and compatible registries.", "author": "GitHub Inc.", "main": "lib/index.js", "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "keywords": [ "npm", @@ -16,37 +16,42 @@ ], "license": "ISC", "scripts": { - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "posttest": "npm run lint", + "posttest": "node ../.. run lint", "test": "tap", - "lint": "eslint '**/*.js'", - "postlint": "npm-template-check", - "lintfix": "npm run lint -- --fix", - "snap": "tap" - }, - "tap": { - "check-coverage": true + "lint": "eslint \"**/*.js\"", + "postlint": "template-oss-check", + "lintfix": "node ../.. run lint -- --fix", + "snap": "tap", + "template-oss-apply": "template-oss-apply --force" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "nock": "^9.6.1", - "tap": "^15" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "nock": "^13.2.4", + "tap": "^16.3.2" }, "repository": { "type": "git", - "url": "https://github.com/npm/libnpmsearch.git" + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/libnpmsearch" }, "bugs": "https://github.com/npm/libnpmsearch/issues", "homepage": "https://npmjs.com/package/libnpmsearch", "dependencies": { - "npm-registry-fetch": "^12.0.1" + "npm-registry-fetch": "^14.0.3" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/workspaces/libnpmsearch/test/index.js b/workspaces/libnpmsearch/test/index.js index 8512ecb..dd54949 100644 --- a/workspaces/libnpmsearch/test/index.js +++ b/workspaces/libnpmsearch/test/index.js @@ -12,7 +12,7 @@ const REG = OPTS.registry const NPM_REG = 'https://registry.npmjs.org/' const search = require('../lib/index.js') -test('basic test no options', t => { +test('basic test no options', async t => { const query = qs.stringify({ text: 'oo', size: 20, @@ -27,18 +27,17 @@ test('basic test no options', t => { { package: { name: 'foo', version: '2.0.0' } }, ], }) - return search('oo').then(results => { - t.match(results, [{ - name: 'cool', - version: '1.0.0', - }, { - name: 'foo', - version: '2.0.0', - }], 'got back an array of search results') - }) + const results = await search('oo') + t.match(results, [{ + name: 'cool', + version: '1.0.0', + }, { + name: 'foo', + version: '2.0.0', + }], 'got back an array of search results') }) -test('basic test', t => { +test('basic test', async t => { const query = qs.stringify({ text: 'oo', size: 20, @@ -53,18 +52,17 @@ test('basic test', t => { { package: { name: 'foo', version: '2.0.0' } }, ], }) - return search('oo', OPTS).then(results => { - t.match(results, [{ - name: 'cool', - version: '1.0.0', - }, { - name: 'foo', - version: '2.0.0', - }], 'got back an array of search results') - }) + const results = await search('oo', OPTS) + t.match(results, [{ + name: 'cool', + version: '1.0.0', + }, { + name: 'foo', + version: '2.0.0', + }], 'got back an array of search results') }) -test('basic test supports nested options', t => { +test('basic test supports nested options', async t => { const query = qs.stringify({ text: 'oo', size: 20, @@ -82,18 +80,17 @@ test('basic test supports nested options', t => { // this test is to ensure we don't break the nested opts parameter // that the cli supplies when a user passes --searchopts= - return search('oo', { ...OPTS, opts: { from: 1 } }).then(results => { - t.match(results, [{ - name: 'cool', - version: '1.0.0', - }, { - name: 'foo', - version: '2.0.0', - }], 'got back an array of search results') - }) + const results = await search('oo', { ...OPTS, opts: { from: 1 } }) + t.match(results, [{ + name: 'cool', + version: '1.0.0', + }, { + name: 'foo', + version: '2.0.0', + }], 'got back an array of search results') }) -test('search.stream', t => { +test('search.stream', async t => { const query = qs.stringify({ text: 'oo', size: 20, @@ -108,18 +105,17 @@ test('search.stream', t => { { package: { name: 'foo', version: '2.0.0' } }, ], }) - return search.stream('oo', OPTS).collect().then(results => { - t.match(results, [{ - name: 'cool', - version: '1.0.0', - }, { - name: 'foo', - version: '2.0.0', - }], 'has a stream-based API function with identical results') - }) + const results = await search.stream('oo', OPTS).collect() + t.match(results, [{ + name: 'cool', + version: '1.0.0', + }, { + name: 'foo', + version: '2.0.0', + }], 'has a stream-based API function with identical results') }) -test('accepts a limit option', t => { +test('accepts a limit option', async t => { const query = qs.stringify({ text: 'oo', size: 3, @@ -136,12 +132,11 @@ test('accepts a limit option', t => { { package: { name: 'cool', version: '1.0.0' } }, ], }) - return search('oo', { ...OPTS, limit: 3 }).then(results => { - t.equal(results.length, 4, 'returns more results if endpoint does so') - }) + const results = await search('oo', { ...OPTS, limit: 3 }) + t.equal(results.length, 4, 'returns more results if endpoint does so') }) -test('accepts a from option', t => { +test('accepts a from option', async t => { const query = qs.stringify({ text: 'oo', size: 20, @@ -158,12 +153,11 @@ test('accepts a from option', t => { { package: { name: 'cool', version: '1.0.0' } }, ], }) - return search('oo', { ...OPTS, from: 1 }).then(results => { - t.equal(results.length, 4, 'returns more results if endpoint does so') - }) + const results = await search('oo', { ...OPTS, from: 1 }) + t.equal(results.length, 4, 'returns more results if endpoint does so') }) -test('accepts quality/mainenance/popularity options', t => { +test('accepts quality/mainenance/popularity options', async t => { const query = qs.stringify({ text: 'oo', size: 20, @@ -180,17 +174,16 @@ test('accepts quality/mainenance/popularity options', t => { { package: { name: 'cool', version: '1.0.0' } }, ], }) - return search('oo', { + const results = await search('oo', { ...OPTS, quality: 1, popularity: 2, maintenance: 3, - }).then(results => { - t.equal(results.length, 4, 'returns more results if endpoint does so') }) + t.equal(results.length, 4, 'returns more results if endpoint does so') }) -test('sortBy: quality', t => { +test('sortBy: quality', async t => { const query = qs.stringify({ text: 'oo', size: 20, @@ -207,15 +200,14 @@ test('sortBy: quality', t => { { package: { name: 'cool', version: '1.0.0' } }, ], }) - return search('oo', { + const results = await search('oo', { ...OPTS, sortBy: 'quality', - }).then(results => { - t.equal(results.length, 4, 'returns more results if endpoint does so') }) + t.equal(results.length, 4, 'returns more results if endpoint does so') }) -test('sortBy: popularity', t => { +test('sortBy: popularity', async t => { const query = qs.stringify({ text: 'oo', size: 20, @@ -232,15 +224,14 @@ test('sortBy: popularity', t => { { package: { name: 'cool', version: '1.0.0' } }, ], }) - return search('oo', { + const results = await search('oo', { ...OPTS, sortBy: 'popularity', - }).then(results => { - t.equal(results.length, 4, 'returns more results if endpoint does so') }) + t.equal(results.length, 4, 'returns more results if endpoint does so') }) -test('sortBy: maintenance', t => { +test('sortBy: maintenance', async t => { const query = qs.stringify({ text: 'oo', size: 20, @@ -257,15 +248,14 @@ test('sortBy: maintenance', t => { { package: { name: 'cool', version: '1.0.0' } }, ], }) - return search('oo', { + const results = await search('oo', { ...OPTS, sortBy: 'maintenance', - }).then(results => { - t.equal(results.length, 4, 'returns more results if endpoint does so') }) + t.equal(results.length, 4, 'returns more results if endpoint does so') }) -test('sortBy: optimal', t => { +test('sortBy: optimal', async t => { const query = qs.stringify({ text: 'oo', size: 20, @@ -282,15 +272,14 @@ test('sortBy: optimal', t => { { package: { name: 'cool', version: '1.0.0' } }, ], }) - return search('oo', { + const results = await search('oo', { ...OPTS, sortBy: 'optimal', - }).then(results => { - t.equal(results.length, 4, 'returns more results if endpoint does so') }) + t.equal(results.length, 4, 'returns more results if endpoint does so') }) -test('detailed format', t => { +test('detailed format', async t => { const query = qs.stringify({ text: 'oo', size: 20, @@ -328,16 +317,15 @@ test('detailed format', t => { tnock(t, REG).get(`/-/v1/search?${query}`).once().reply(200, { objects: results, }) - return search('oo', { + const res = await search('oo', { ...OPTS, sortBy: 'maintenance', detailed: true, - }).then(res => { - t.same(res, results, 'return full-format results with opts.detailed') }) + t.same(res, results, 'return full-format results with opts.detailed') }) -test('space-separates and URI-encodes multiple search params', t => { +test('space-separates and URI-encodes multiple search params', async t => { const query = qs.stringify({ text: 'foo bar:baz quux?=', size: 1, @@ -348,13 +336,11 @@ test('space-separates and URI-encodes multiple search params', t => { }).replace(/%20/g, '+') tnock(t, REG).get(`/-/v1/search?${query}`).reply(200, { objects: [] }) - return search(['foo', 'bar:baz', 'quux?='], { + await t.resolves(search(['foo', 'bar:baz', 'quux?='], { ...OPTS, limit: 1, quality: 1, popularity: 2, maintenance: 3, - }).then( - () => t.ok(true, 'sent parameters correctly urlencoded') - ) + })) }) diff --git a/workspaces/libnpmteam/.eslintrc.js b/workspaces/libnpmteam/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/libnpmteam/.eslintrc.js +++ b/workspaces/libnpmteam/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/libnpmteam/.github/settings.yml b/workspaces/libnpmteam/.github/settings.yml deleted file mode 100644 index 1019e26..0000000 --- a/workspaces/libnpmteam/.github/settings.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -_extends: '.github:npm-cli/settings.yml' diff --git a/workspaces/libnpmteam/.github/workflows/ci.yml b/workspaces/libnpmteam/.github/workflows/ci.yml deleted file mode 100644 index c20a298..0000000 --- a/workspaces/libnpmteam/.github/workflows/ci.yml +++ /dev/null @@ -1,97 +0,0 @@ ---- -################################################################################ -# Template - Node CI -# -# Location: .github/workflows/{filename}.yml -# -# Description: -# This contains the basic information to: install dependencies, run tests, -# get coverage, and run linting on a nodejs project. This template will run -# over the MxN matrix of all operating systems, and all current LTS versions -# of NodeJS. -# -# Dependencies: -# This template assumes that your project is using the `tap` module for -# testing. If you're not using this module, then the step that runs your -# coverage will need to be adjusted. -# -################################################################################ -name: node-ci - -on: [push, pull_request] - -jobs: - build: - strategy: - fail-fast: false - matrix: - node-version: [10.x, 12.x, 13.x] - os: [ubuntu-latest, windows-latest, macOS-latest] - - runs-on: ${{ matrix.os }} - - steps: - # Checkout the repository - - uses: actions/checkout@v2 - # Installs the specific version of Node.js - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v1 - with: - node-version: ${{ matrix.node-version }} - - ################################################################################ - # Install Dependencies - # - # ASSUMPTIONS: - # - The project has a package-lock.json file - # - # Simply run the tests for the project. - ################################################################################ - - name: Install dependencies - run: npm ci - - ################################################################################ - # Run Testing - # - # ASSUMPTIONS: - # - The project has `tap` as a devDependency - # - There is a script called "test" in the package.json - # - # Simply run the tests for the project. - ################################################################################ - - name: Run tests - if: github.event_name != 'push' || matrix.node-version != '12.x' || matrix.os != 'ubuntu-latest' - run: npm test -- --no-coverage - - ################################################################################ - # Run coverage check - # - # ASSUMPTIONS: - # - The project has `tap` as a devDependency - # - There is a script called "coverage" in the package.json - # - # Coverage should only be posted once, we are choosing the latest LTS of - # node, and ubuntu as the matrix point to post coverage from. We limit - # to the 'push' event so that coverage ins't posted twice from the - # pull-request event, and push event (line 3). - ################################################################################ - - name: Run coverage report - if: github.event_name == 'push' && matrix.node-version == '12.x' && matrix.os == 'ubuntu-latest' - run: npm test - env: - # The environment variable name is leveraged by `tap` - COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} - - ################################################################################ - # Run linting - # - # ASSUMPTIONS: - # - There is a script called "lint" in the package.json - # - # We run linting AFTER we run testing and coverage checks, because if a step - # fails in an GitHub Action, all other steps are not run. We don't want to - # fail to run tests or coverage because of linting. It should be the lowest - # priority of all the steps. - ################################################################################ - - name: Run linter - run: npm run lint diff --git a/workspaces/libnpmteam/.gitignore b/workspaces/libnpmteam/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/libnpmteam/.gitignore +++ b/workspaces/libnpmteam/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/libnpmteam/.npmrc b/workspaces/libnpmteam/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/libnpmteam/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/libnpmteam/CHANGELOG.md b/workspaces/libnpmteam/CHANGELOG.md index ba472cf..9e7b92b 100644 --- a/workspaces/libnpmteam/CHANGELOG.md +++ b/workspaces/libnpmteam/CHANGELOG.md @@ -1,4 +1,66 @@ -# Change Log +# Changelog + +## [5.0.1](https://github.com/npm/cli/compare/libnpmteam-v5.0.0...libnpmteam-v5.0.1) (2022-12-07) + +### Dependencies + +* [`0a3fe00`](https://github.com/npm/cli/commit/0a3fe000e2723ae6fdb8b1d3154fd3835057c992) [#5933](https://github.com/npm/cli/pull/5933) `minipass@4.0.0` +* [`fee9b66`](https://github.com/npm/cli/commit/fee9b6686892a1c7f976c36ddd5d89b70c416817) `npm-registry-fetch@14.0.3` + +## [5.0.0](https://github.com/npm/cli/compare/libnpmteam-v5.0.0-pre.1...libnpmteam-v5.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +## [5.0.0-pre.1](https://github.com/npm/cli/compare/libnpmteam-v5.0.0-pre.0...libnpmteam-v5.0.0-pre.1) (2022-10-19) + +### Dependencies + +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies + +## [5.0.0-pre.0](https://github.com/npm/cli/compare/libnpmteam-v4.0.4...libnpmteam-v5.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + +## [4.0.4](https://github.com/npm/cli/compare/libnpmteam-v4.0.3...libnpmteam-v4.0.4) (2022-08-31) + +### Dependencies + + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` + +### [4.0.3](https://github.com/npm/cli/compare/libnpmteam-v4.0.2...libnpmteam-v4.0.3) (2022-04-06) + + +### Bug Fixes + +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/template-oss@3.2.1 ([aac01b8](https://github.com/npm/cli/commit/aac01b89caf6336a2eb34d696296303cdadd5c08)) +* @npmcli/template-oss@3.2.2 ([#4639](https://github.com/npm/cli/issues/4639)) ([a59fd2c](https://github.com/npm/cli/commit/a59fd2cb863245fce56f96c90ac854e62c5c4d6f)) + +### [4.0.2](https://www.github.com/npm/cli/compare/libnpmteam-v4.0.1...libnpmteam-v4.0.2) (2022-03-10) + + +### Documentation + +* standardize changelog heading ([#4510](https://www.github.com/npm/cli/issues/4510)) ([91f03ee](https://www.github.com/npm/cli/commit/91f03ee618bc635f9cfbded735fe98bbfa9d643f)) + +### [4.0.1](https://www.github.com/npm/cli/compare/libnpmteam-vlibnpmteam@4.0.0...libnpmteam-v4.0.1) (2022-03-03) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) ## [2.0.0](https://github.com/npm/libnpmteam/compare/v1.0.2...v2.0.0) (2020-03-02) diff --git a/workspaces/libnpmteam/README.md b/workspaces/libnpmteam/README.md index 603cf66..97323f8 100644 --- a/workspaces/libnpmteam/README.md +++ b/workspaces/libnpmteam/README.md @@ -2,8 +2,7 @@ [![npm version](https://img.shields.io/npm/v/libnpmteam.svg)](https://npm.im/libnpmteam) [![license](https://img.shields.io/npm/l/libnpmteam.svg)](https://npm.im/libnpmteam) -[![GitHub Actions](https://github.com/npm/libnpmteam/workflows/Node%20CI/badge.svg)](https://github.com/npm/libnpmteam/workflows/Node%20CI/badge.svg) -[![Coverage Status](https://coveralls.io/repos/github/npm/libnpmteam/badge.svg?branch=latest)](https://coveralls.io/github/npm/libnpmteam?branch=latest) +[![CI - libnpmteam](https://github.com/npm/cli/actions/workflows/ci-libnpmteam.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-libnpmteam.yml) [`libnpmteam`](https://github.com/npm/libnpmteam) is a Node.js library that provides programmatic access to the guts of the npm CLI's `npm diff --git a/workspaces/libnpmteam/SECURITY.md b/workspaces/libnpmteam/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/libnpmteam/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/libnpmteam/package.json b/workspaces/libnpmteam/package.json index 2390355..b3444c7 100644 --- a/workspaces/libnpmteam/package.json +++ b/workspaces/libnpmteam/package.json @@ -1,46 +1,51 @@ { "name": "libnpmteam", "description": "npm Team management APIs", - "version": "3.0.1", + "version": "5.0.1", "author": "GitHub Inc.", "license": "ISC", "main": "lib/index.js", "scripts": { - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "lint": "eslint '**/*.js'", + "lint": "eslint \"**/*.js\"", "test": "tap", - "posttest": "npm run lint", - "postlint": "npm-template-check", - "lintfix": "npm run lint -- --fix", - "snap": "tap" + "posttest": "node ../.. run lint", + "postlint": "template-oss-check", + "lintfix": "node ../.. run lint -- --fix", + "snap": "tap", + "template-oss-apply": "template-oss-apply --force" }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", - "nock": "^12.0.1", - "tap": "^15" + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", + "nock": "^13.2.4", + "tap": "^16.3.2" }, "repository": { "type": "git", - "url": "https://github.com/npm/libnpmteam.git" + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/libnpmteam" }, "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "homepage": "https://npmjs.com/package/libnpmteam", "dependencies": { "aproba": "^2.0.0", - "npm-registry-fetch": "^12.0.1" + "npm-registry-fetch": "^14.0.3" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" - }, - "tap": { - "check-coverage": true + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" + }, + "tap": { + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] } } diff --git a/workspaces/libnpmteam/test/index.js b/workspaces/libnpmteam/test/index.js index 6e0b929..fd02666 100644 --- a/workspaces/libnpmteam/test/index.js +++ b/workspaces/libnpmteam/test/index.js @@ -10,249 +10,198 @@ const OPTS = { registry: REG, } -test('create', t => { +test('create', async t => { tnock(t, REG).put( '/-/org/foo/team', { name: 'cli' } ).reply(201, { name: 'cli' }) - return team.create('@foo:cli', OPTS).then(ret => { - t.same(ret, { name: 'cli' }, 'request succeeded') - }) + const ret = await team.create('@foo:cli', OPTS) + t.same(ret, { name: 'cli' }, 'request succeeded') }) -test('create - no options', t => { +test('create - no options', async t => { // NOTE: mocking real url, because no opts variable means `registry` value // will be defauled to real registry url in `npm-registry-fetch` tnock(t, 'https://registry.npmjs.org') .put('/-/org/foo/team', { name: 'cli' }) .reply(201, { name: 'cli' }) - return team.create('@foo:cli') - .then(ret => { - t.same(ret, { name: 'cli' }) - }) + const ret = await team.create('@foo:cli') + t.same(ret, { name: 'cli' }) }) -test('create bad entity name', t => { - return team.create('go away', OPTS).then( - () => { - throw new Error('should not succeed') - }, - err => { - t.ok(err, 'error on bad entity name') - } - ) +test('create bad entity name', async t => { + await t.rejects(team.create('go away', OPTS)) }) -test('create empty entity', t => { - return team.create(undefined, OPTS).then( - () => { - throw new Error('should not succeed') - }, - err => { - t.ok(err, 'error on bad entity name') - } - ) +test('create empty entity', async t => { + await t.rejects(team.create(undefined, OPTS)) }) -test('create w/ description', t => { +test('create w/ description', async t => { tnock(t, REG).put('/-/org/foo/team', { name: 'cli', description: 'just some cool folx', }).reply(201, { name: 'cli' }) - return team.create('@foo:cli', { + const ret = await team.create('@foo:cli', { ...OPTS, description: 'just some cool folx', - }).then(ret => { - t.same(ret, { name: 'cli' }, 'no desc in return') }) + t.same(ret, { name: 'cli' }, 'no desc in return') }) -test('destroy', t => { +test('destroy', async t => { tnock(t, REG).delete( '/-/team/foo/cli' ).reply(204, {}) - return team.destroy('@foo:cli', OPTS).then(ret => { - t.same(ret, {}, 'request succeeded') - }) + const ret = await team.destroy('@foo:cli', OPTS) + t.same(ret, {}, 'request succeeded') }) -test('destroy - no options', t => { +test('destroy - no options', async t => { // NOTE: mocking real url, because no opts variable means `registry` value // will be defauled to real registry url in `npm-registry-fetch` tnock(t, 'https://registry.npmjs.org') .delete('/-/team/foo/cli') .reply(204, {}) - return team.destroy('@foo:cli').then(ret => { - t.same(ret, {}, 'request succeeded') - }) + const ret = await team.destroy('@foo:cli') + t.same(ret, {}, 'request succeeded') }) -test('add', t => { +test('add', async t => { tnock(t, REG).put( '/-/team/foo/cli/user', { user: 'zkat' } ).reply(201, {}) - return team.add('zkat', '@foo:cli', OPTS).then(ret => { - t.same(ret, {}, 'request succeeded') - }) + const ret = await team.add('zkat', '@foo:cli', OPTS) + t.same(ret, {}, 'request succeeded') }) -test('add - no options', t => { +test('add - no options', async t => { // NOTE: mocking real url, because no opts variable means `registry` value // will be defauled to real registry url in `npm-registry-fetch` tnock(t, 'https://registry.npmjs.org') .put('/-/team/foo/cli/user', { user: 'zkat' }) .reply(201, {}) - return team.add('zkat', '@foo:cli').then(ret => { - t.same(ret, {}, 'request succeeded') - }) + const ret = await team.add('zkat', '@foo:cli') + t.same(ret, {}, 'request succeeded') }) -test('rm', t => { +test('rm', async t => { tnock(t, REG).delete( '/-/team/foo/cli/user', { user: 'zkat' } ).reply(204, {}) - return team.rm('zkat', '@foo:cli', OPTS).then(ret => { - t.same(ret, {}, 'request succeeded') - }) + const ret = await team.rm('zkat', '@foo:cli', OPTS) + t.same(ret, {}, 'request succeeded') }) -test('rm - no options', t => { +test('rm - no options', async t => { // NOTE: mocking real url, because no opts variable means `registry` value // will be defauled to real registry url in `npm-registry-fetch` tnock(t, 'https://registry.npmjs.org') .delete('/-/team/foo/cli/user', { user: 'zkat' }) .reply(204, {}) - return team.rm('zkat', '@foo:cli').then(ret => { - t.same(ret, {}, 'request succeeded') - }) + const ret = await team.rm('zkat', '@foo:cli') + t.same(ret, {}, 'request succeeded') }) -test('lsTeams', t => { +test('lsTeams', async t => { tnock(t, REG).get( '/-/org/foo/team?format=cli' ).reply(200, ['foo:bar', 'foo:cli']) - return team.lsTeams('foo', OPTS).then(ret => { - t.same(ret, ['foo:bar', 'foo:cli'], 'got teams') - }) + const ret = await team.lsTeams('foo', OPTS) + t.same(ret, ['foo:bar', 'foo:cli'], 'got teams') }) -test('lsTeams - no options', t => { +test('lsTeams - no options', async t => { // NOTE: mocking real url, because no opts variable means `registry` value // will be defauled to real registry url in `npm-registry-fetch` tnock(t, 'https://registry.npmjs.org') .get('/-/org/foo/team?format=cli') .reply(200, ['foo:bar', 'foo:cli']) - return team.lsTeams('foo').then(ret => { - t.same(ret, ['foo:bar', 'foo:cli'], 'got teams') - }) + const ret = await team.lsTeams('foo') + t.same(ret, ['foo:bar', 'foo:cli'], 'got teams') }) -test('lsTeams error', t => { +test('lsTeams error', async t => { tnock(t, REG).get( '/-/org/foo/team?format=cli' ).reply(500) - return team.lsTeams('foo', OPTS).then( - () => { - throw new Error('should not succeed') - }, - err => { - t.equal(err.code, 'E500', 'got error code') - } + await t.rejects( + team.lsTeams('foo', OPTS), + { code: 'E500' } ) }) -test('lsTeams.stream', t => { +test('lsTeams.stream', async t => { tnock(t, REG).get( '/-/org/foo/team?format=cli' ).reply(200, ['foo:bar', 'foo:cli']) - return team.lsTeams.stream('foo', OPTS) - .collect() - .then(ret => { - t.same(ret, ['foo:bar', 'foo:cli'], 'got teams') - }) + const ret = await team.lsTeams.stream('foo', OPTS).collect() + t.same(ret, ['foo:bar', 'foo:cli'], 'got teams') }) -test('lsTeams.stream - no options', t => { +test('lsTeams.stream - no options', async t => { // NOTE: mocking real url, because no opts variable means `registry` value // will be defauled to real registry url in `npm-registry-fetch` tnock(t, 'https://registry.npmjs.org') .get('/-/org/foo/team?format=cli') .reply(200, ['foo:bar', 'foo:cli']) - return team.lsTeams.stream('foo') - .collect() - .then(ret => { - t.same(ret, ['foo:bar', 'foo:cli'], 'got teams') - }) + const ret = await team.lsTeams.stream('foo').collect() + t.same(ret, ['foo:bar', 'foo:cli'], 'got teams') }) -test('lsUsers', t => { +test('lsUsers', async t => { tnock(t, REG).get( '/-/team/foo/cli/user?format=cli' ).reply(500) - return team.lsUsers('@foo:cli', OPTS).then( - () => { - throw new Error('should not succeed') - }, - err => { - t.equal(err.code, 'E500', 'got error code') - } + await t.rejects( + team.lsUsers('@foo:cli', OPTS), + { code: 'E500' } ) }) -test('lsUsers - no options', t => { +test('lsUsers - no options', async t => { // NOTE: mocking real url, because no opts variable means `registry` value // will be defauled to real registry url in `npm-registry-fetch` tnock(t, 'https://registry.npmjs.org') .get('/-/team/foo/cli/user?format=cli') .reply(500) - return team.lsUsers('@foo:cli').then( - () => { - throw new Error('should not succeed') - }, - err => { - t.equal(err.code, 'E500', 'got error code') - } + await t.rejects( + team.lsUsers('@foo:cli'), + { code: 'E500' } ) }) -test('lsUsers error', t => { +test('lsUsers error', async t => { tnock(t, REG).get( '/-/team/foo/cli/user?format=cli' ).reply(200, ['iarna', 'zkat']) - return team.lsUsers('@foo:cli', OPTS).then(ret => { - t.same(ret, ['iarna', 'zkat'], 'got team members') - }) + const ret = await team.lsUsers('@foo:cli', OPTS) + t.same(ret, ['iarna', 'zkat'], 'got team members') }) -test('lsUsers.stream', t => { +test('lsUsers.stream', async t => { tnock(t, REG).get( '/-/team/foo/cli/user?format=cli' ).reply(200, ['iarna', 'zkat']) - return team.lsUsers.stream('@foo:cli', OPTS) - .collect() - .then(ret => { - t.same(ret, ['iarna', 'zkat'], 'got team members') - }) + const ret = await team.lsUsers.stream('@foo:cli', OPTS).collect() + t.same(ret, ['iarna', 'zkat'], 'got team members') }) -test('lsUsers.stream - no options', t => { +test('lsUsers.stream - no options', async t => { // NOTE: mocking real url, because no opts variable means `registry` value // will be defauled to real registry url in `npm-registry-fetch` tnock(t, 'https://registry.npmjs.org') .get('/-/team/foo/cli/user?format=cli') .reply(200, ['iarna', 'zkat']) - return team.lsUsers.stream('@foo:cli') - .collect() - .then(ret => { - t.same(ret, ['iarna', 'zkat'], 'got team members') - }) + const ret = await team.lsUsers.stream('@foo:cli').collect() + t.same(ret, ['iarna', 'zkat'], 'got team members') }) test('edit', t => { diff --git a/workspaces/libnpmversion/.eslintrc.js b/workspaces/libnpmversion/.eslintrc.js index 022767b..5db9f81 100644 --- a/workspaces/libnpmversion/.eslintrc.js +++ b/workspaces/libnpmversion/.eslintrc.js @@ -1,4 +1,6 @@ -// This file is automatically added by @npmcli/template-oss. Do not edit. +/* This file is automatically added by @npmcli/template-oss. Do not edit. */ + +'use strict' const { readdirSync: readdir } = require('fs') @@ -7,6 +9,7 @@ const localConfigs = readdir(__dirname) .map((file) => `./${file}`) module.exports = { + root: true, extends: [ '@npmcli', ...localConfigs, diff --git a/workspaces/libnpmversion/.gitignore b/workspaces/libnpmversion/.gitignore index 6ed44c7..79af2bf 100644 --- a/workspaces/libnpmversion/.gitignore +++ b/workspaces/libnpmversion/.gitignore @@ -4,20 +4,18 @@ /* # keep these -!/.commitlintrc.js -!/.npmrc -!/.eslintrc* -!/.github !**/.gitignore -!/package.json -!/docs -!/bin -!/lib -!/map.js -!/tap-snapshots -!/test -!/scripts -!/README* -!/LICENSE* -!/SECURITY* +!/.eslintrc.js +!/.eslintrc.local.* +!/.gitignore +!/bin/ !/CHANGELOG* +!/docs/ +!/lib/ +!/LICENSE* +!/map.js +!/package.json +!/README* +!/scripts/ +!/tap-snapshots/ +!/test/ diff --git a/workspaces/libnpmversion/.npmrc b/workspaces/libnpmversion/.npmrc deleted file mode 100644 index 878b7dd..0000000 --- a/workspaces/libnpmversion/.npmrc +++ /dev/null @@ -1,3 +0,0 @@ -;This file is automatically added by @npmcli/template-oss. Do not edit. - -package-lock=false diff --git a/workspaces/libnpmversion/CHANGELOG.md b/workspaces/libnpmversion/CHANGELOG.md new file mode 100644 index 0000000..2c13959 --- /dev/null +++ b/workspaces/libnpmversion/CHANGELOG.md @@ -0,0 +1,91 @@ +# Changelog + +## [4.0.1](https://github.com/npm/cli/compare/libnpmversion-v4.0.0...libnpmversion-v4.0.1) (2022-11-02) + +### Bug Fixes + +* [`1f5382d`](https://github.com/npm/cli/commit/1f5382dada181cda41f1504974de1e69a6c1ad7f) [#5789](https://github.com/npm/cli/pull/5789) don't set `stdioString` for any spawn/run-script calls (@lukekarrys) + +### Dependencies + +* [`abfb28b`](https://github.com/npm/cli/commit/abfb28b249183b8c033f8e7acc1546150cdac137) `@npmcli/run-script@6.0.0` + +## [4.0.0](https://github.com/npm/cli/compare/libnpmversion-v4.0.0-pre.1...libnpmversion-v4.0.0) (2022-10-19) + +### Features + +* [`586e78d`](https://github.com/npm/cli/commit/586e78d59c3dad29e8e886a4764d2eb8021d11d1) empty commit to trigger all workspace releases (@lukekarrys) + +## [4.0.0-pre.1](https://github.com/npm/cli/compare/libnpmversion-v4.0.0-pre.0...libnpmversion-v4.0.0-pre.1) (2022-10-19) + +### Dependencies + +* [`aa01072`](https://github.com/npm/cli/commit/aa010722996ef6de46e1bb937c6f8a94dc2844fa) [#5707](https://github.com/npm/cli/pull/5707) update the following dependencies + +## [4.0.0-pre.0](https://github.com/npm/cli/compare/libnpmversion-v3.0.7...libnpmversion-v4.0.0-pre.0) (2022-09-08) + +### ⚠ BREAKING CHANGES + +* **workspaces:** all workspace packages are now compatible with the following semver range for node: `^14.17.0 || ^16.13.0 || >=18.0.0` + +### Features + + * [`e95017a`](https://github.com/npm/cli/commit/e95017a07b041cbb3293e659dad853f76462c108) [#5485](https://github.com/npm/cli/pull/5485) feat(workspaces): update supported node engines in package.json (@lukekarrys) + +## [3.0.7](https://github.com/npm/cli/compare/libnpmversion-v3.0.6...libnpmversion-v3.0.7) (2022-08-31) + +### Bug Fixes + + * [`bd2ae5d`](https://github.com/npm/cli/commit/bd2ae5d79eb8807bfca6075e98432c545a9ededa) [#5323](https://github.com/npm/cli/pull/5323) fix: linting (@wraithgar) + +### Dependencies + + * [`8ab12dc`](https://github.com/npm/cli/commit/8ab12dc32b26db770b868cf694cedab38f4e7460) [#5323](https://github.com/npm/cli/pull/5323) deps: `@npmcli/eslint-config@3.1.0` + +## [3.0.6](https://github.com/npm/cli/compare/libnpmversion-v3.0.5...libnpmversion-v3.0.6) (2022-06-23) + + +### Dependencies + +* @npmcli/run-script@4.1.3 ([#5064](https://github.com/npm/cli/issues/5064)) ([f59a114](https://github.com/npm/cli/commit/f59a114ffe3d1f86ccb2e52a4432292ab76852cc)) + +## [3.0.5](https://github.com/npm/cli/compare/libnpmversion-v3.0.4...libnpmversion-v3.0.5) (2022-06-22) + + +### Dependencies + +* @npmcli/run-script@4.1.0 ([2c06cee](https://github.com/npm/cli/commit/2c06ceee82dd813c0ae84cc0b09e6941cfc5533e)) + +### [3.0.4](https://github.com/npm/cli/compare/libnpmversion-v3.0.3...libnpmversion-v3.0.4) (2022-04-26) + + +### Dependencies + +* semver@7.3.7 ([c51e553](https://github.com/npm/cli/commit/c51e553a32315e4f1b703ca9030eb7ade91d1a85)) + +### [3.0.3](https://github.com/npm/cli/compare/libnpmversion-v3.0.2...libnpmversion-v3.0.3) (2022-04-12) + + +### Dependencies + +* remove stringify-package ([#4714](https://github.com/npm/cli/issues/4714)) ([e33aa0f](https://github.com/npm/cli/commit/e33aa0f94f87ae4f9d2a73781e84832ef61d1855)) + +### [3.0.2](https://github.com/npm/cli/compare/libnpmversion-v3.0.1...libnpmversion-v3.0.2) (2022-04-06) + + +### Bug Fixes + +* update readme badges ([#4658](https://github.com/npm/cli/issues/4658)) ([2829cb2](https://github.com/npm/cli/commit/2829cb28a432b5ff7beeeb3bf3e7e2e174c1121d)) + + +### Dependencies + +* @npmcli/template-oss@3.2.1 ([aac01b8](https://github.com/npm/cli/commit/aac01b89caf6336a2eb34d696296303cdadd5c08)) +* @npmcli/template-oss@3.2.2 ([#4639](https://github.com/npm/cli/issues/4639)) ([a59fd2c](https://github.com/npm/cli/commit/a59fd2cb863245fce56f96c90ac854e62c5c4d6f)) + +### [3.0.1](https://www.github.com/npm/cli/compare/libnpmversion-vlibnpmversion@3.0.0...libnpmversion-v3.0.1) (2022-03-03) + + +### Bug Fixes + +* set proper workspace repo urls in package.json ([#4476](https://www.github.com/npm/cli/issues/4476)) ([0cfc155](https://www.github.com/npm/cli/commit/0cfc155db5f11ce23419e440111d99a63bf39754)) diff --git a/workspaces/libnpmversion/README.md b/workspaces/libnpmversion/README.md index e82e7cd..ac9ee50 100644 --- a/workspaces/libnpmversion/README.md +++ b/workspaces/libnpmversion/README.md @@ -1,5 +1,9 @@ # libnpmversion +[![npm version](https://img.shields.io/npm/v/libnpmversion.svg)](https://npm.im/libnpmversion) +[![license](https://img.shields.io/npm/l/libnpmversion.svg)](https://npm.im/libnpmversion) +[![CI - libnpmversion](https://github.com/npm/cli/actions/workflows/ci-libnpmversion.yml/badge.svg)](https://github.com/npm/cli/actions/workflows/ci-libnpmversion.yml) + Library to do the things that 'npm version' does. ## USAGE @@ -27,6 +31,7 @@ npmVersion(arg, { ignoreScripts: false, // do not run pre/post/version lifecycle scripts scriptShell: '/bin/bash', // shell to run lifecycle scripts in message: 'v%s', // message for tag and commit, replace %s with the version + silent: false, // passed to @npmcli/run-script to control whether it logs }).then(newVersion => { console.error('version updated!', newVersion) }) diff --git a/workspaces/libnpmversion/SECURITY.md b/workspaces/libnpmversion/SECURITY.md deleted file mode 100644 index a93106d..0000000 --- a/workspaces/libnpmversion/SECURITY.md +++ /dev/null @@ -1,3 +0,0 @@ -<!-- This file is automatically added by @npmcli/template-oss. Do not edit. --> - -Please send vulnerability reports through [hackerone](https://hackerone.com/github). diff --git a/workspaces/libnpmversion/lib/enforce-clean.js b/workspaces/libnpmversion/lib/enforce-clean.js index 6103da9..721f146 100644 --- a/workspaces/libnpmversion/lib/enforce-clean.js +++ b/workspaces/libnpmversion/lib/enforce-clean.js @@ -1,9 +1,10 @@ const git = require('@npmcli/git') +const log = require('proc-log') // returns true if it's cool to do git stuff // throws if it's unclean, and not forced. module.exports = async opts => { - const { force, log } = opts + const { force } = opts let hadError = false const clean = await git.isClean(opts).catch(er => { if (er.code === 'ENOGIT') { diff --git a/workspaces/libnpmversion/lib/index.js b/workspaces/libnpmversion/lib/index.js index 683941c..95acd11 100644 --- a/workspaces/libnpmversion/lib/index.js +++ b/workspaces/libnpmversion/lib/index.js @@ -1,6 +1,5 @@ const readJson = require('./read-json.js') const version = require('./version.js') -const proclog = require('./proc-log.js') module.exports = async (newversion, opts = {}) => { const { @@ -15,8 +14,8 @@ module.exports = async (newversion, opts = {}) => { ignoreScripts = false, scriptShell = undefined, preid = null, - log = proclog, message = 'v%s', + silent, } = opts const pkg = opts.pkg || await readJson(path + '/package.json') @@ -35,7 +34,7 @@ module.exports = async (newversion, opts = {}) => { scriptShell, preid, pkg, - log, message, + silent, }) } diff --git a/workspaces/libnpmversion/lib/proc-log.js b/workspaces/libnpmversion/lib/proc-log.js deleted file mode 100644 index a7c683b..0000000 --- a/workspaces/libnpmversion/lib/proc-log.js +++ /dev/null @@ -1,21 +0,0 @@ -// default logger. -// emits 'log' events on the process -const LEVELS = [ - 'notice', - 'error', - 'warn', - 'info', - 'verbose', - 'http', - 'silly', - 'pause', - 'resume', -] - -const log = level => (...args) => process.emit('log', level, ...args) - -const logger = {} -for (const level of LEVELS) { - logger[level] = log(level) -} -module.exports = logger diff --git a/workspaces/libnpmversion/lib/version.js b/workspaces/libnpmversion/lib/version.js index 116a375..f14b95e 100644 --- a/workspaces/libnpmversion/lib/version.js +++ b/workspaces/libnpmversion/lib/version.js @@ -8,6 +8,7 @@ const readJson = require('./read-json.js') const git = require('@npmcli/git') const commit = require('./commit.js') const tag = require('./tag.js') +const log = require('proc-log') const runScript = require('@npmcli/run-script') @@ -19,7 +20,7 @@ module.exports = async (newversion, opts) => { ignoreScripts, preid, pkg, - log, + silent, } = opts const { valid, clean, inc } = semver @@ -64,7 +65,7 @@ module.exports = async (newversion, opts) => { pkg, stdio: 'inherit', event: 'preversion', - banner: log.level !== 'silent', + banner: !silent, env: { npm_old_version: current, npm_new_version: newV, @@ -89,7 +90,9 @@ module.exports = async (newversion, opts) => { } await writeJson(lock, sw) haveLocks.push(lock) - } catch (er) {} + } catch { + // ignore errors + } } if (!ignoreScripts) { @@ -98,7 +101,7 @@ module.exports = async (newversion, opts) => { pkg, stdio: 'inherit', event: 'version', - banner: log.level !== 'silent', + banner: !silent, env: { npm_old_version: current, npm_new_version: newV, @@ -125,7 +128,7 @@ module.exports = async (newversion, opts) => { pkg, stdio: 'inherit', event: 'postversion', - banner: log.level !== 'silent', + banner: !silent, env: { npm_old_version: current, npm_new_version: newV, diff --git a/workspaces/libnpmversion/package.json b/workspaces/libnpmversion/package.json index 6d7823f..ff3855a 100644 --- a/workspaces/libnpmversion/package.json +++ b/workspaces/libnpmversion/package.json @@ -1,49 +1,54 @@ { "name": "libnpmversion", - "version": "2.0.2", + "version": "4.0.1", "main": "lib/index.js", "files": [ - "bin", - "lib" + "bin/", + "lib/" ], "description": "library to do the things that 'npm version' does", "repository": { "type": "git", - "url": "git+https://github.com/npm/libnpmversion" + "url": "https://github.com/npm/cli.git", + "directory": "workspaces/libnpmversion" }, "author": "GitHub Inc.", "license": "ISC", "scripts": { - "lint": "eslint '**/*.js'", + "lint": "eslint \"**/*.js\"", "test": "tap", - "posttest": "npm run lint", + "posttest": "node ../.. run lint", "snap": "tap", - "preversion": "npm test", - "postversion": "npm publish", - "prepublishOnly": "git push origin --follow-tags", - "postlint": "npm-template-check", - "lintfix": "npm run lint -- --fix" + "postlint": "template-oss-check", + "lintfix": "node ../.. run lint -- --fix", + "template-oss-apply": "template-oss-apply --force" }, "tap": { "coverage-map": "map.js", - "check-coverage": true + "nyc-arg": [ + "--exclude", + "tap-snapshots/**" + ] }, "devDependencies": { - "@npmcli/template-oss": "^2.4.2", + "@npmcli/eslint-config": "^4.0.0", + "@npmcli/template-oss": "4.11.0", "require-inject": "^1.4.4", - "tap": "^15" + "tap": "^16.3.2" }, "dependencies": { - "@npmcli/git": "^2.0.7", - "@npmcli/run-script": "^2.0.0", - "json-parse-even-better-errors": "^2.3.1", - "semver": "^7.3.5", - "stringify-package": "^1.0.1" + "@npmcli/git": "^4.0.1", + "@npmcli/run-script": "^6.0.0", + "json-parse-even-better-errors": "^3.0.0", + "proc-log": "^3.0.0", + "semver": "^7.3.7" }, "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16" + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" }, "templateOSS": { - "version": "2.4.3" + "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", + "version": "4.11.0", + "content": "../../scripts/template-oss/index.js" } } diff --git a/workspaces/libnpmversion/tap-snapshots/test/index.js.test.cjs b/workspaces/libnpmversion/tap-snapshots/test/index.js.test.cjs index 6b79d41..59224e1 100644 --- a/workspaces/libnpmversion/tap-snapshots/test/index.js.test.cjs +++ b/workspaces/libnpmversion/tap-snapshots/test/index.js.test.cjs @@ -15,17 +15,6 @@ Array [ "force": false, "gitTagVersion": true, "ignoreScripts": false, - "log": Object { - "error": Function (...args), - "http": Function (...args), - "info": Function (...args), - "notice": Function (...args), - "pause": Function (...args), - "resume": Function (...args), - "silly": Function (...args), - "verbose": Function (...args), - "warn": Function (...args), - }, "message": "v%s", "path": "{CWD}", "pkg": Object { @@ -35,6 +24,7 @@ Array [ "scriptShell": undefined, "signGitCommit": false, "signGitTag": false, + "silent": undefined, "tagVersionPrefix": "v", }, ] @@ -50,7 +40,6 @@ Array [ "force": true, "gitTagVersion": false, "ignoreScripts": true, - "log": Object {}, "message": "hello, i have a message for you", "path": "/some/path", "pkg": Object { @@ -60,6 +49,7 @@ Array [ "scriptShell": "/bin/bash", "signGitCommit": true, "signGitTag": true, + "silent": undefined, "tagVersionPrefix": "=", }, ] diff --git a/workspaces/libnpmversion/test/enforce-clean.js b/workspaces/libnpmversion/test/enforce-clean.js index 9a489d6..3badf47 100644 --- a/workspaces/libnpmversion/test/enforce-clean.js +++ b/workspaces/libnpmversion/test/enforce-clean.js @@ -16,53 +16,47 @@ const enforceClean = requireInject('../lib/enforce-clean.js', { } }, }, + 'proc-log': { warn: (...msg) => warnings.push(msg) }, }) const warnings = [] -const log = { warn: (...msg) => warnings.push(msg) } -t.test('clean, ok', t => - t.resolveMatch(enforceClean({ log, cwd: 'clean' }), true) - .then(() => t.strictSame(warnings, [])) - .then(() => { - warnings.length = 0 - })) +t.afterEach(() => { + warnings.length = 0 +}) -t.test('unclean, no force, throws', t => - t.rejects(enforceClean({ log, cwd: 'unclean' })) - .then(() => t.strictSame(warnings, [])) - .then(() => { - warnings.length = 0 - })) +t.test('clean, ok', async t => { + await t.resolveMatch(enforceClean({ cwd: 'clean' }), true) + t.strictSame(warnings, []) +}) -t.test('unclean, forced, no throw', t => - t.resolveMatch(enforceClean({ log, cwd: 'unclean', force: true }), true) - .then(() => t.strictSame(warnings, [ - [ - 'version', - 'Git working directory not clean, proceeding forcefully.', - ], - ])) - .then(() => { - warnings.length = 0 - })) +t.test('unclean, no force, throws', async t => { + await t.rejects(enforceClean({ cwd: 'unclean' })) + t.strictSame(warnings, []) +}) -t.test('nogit, return false, no throw', t => - t.resolveMatch(enforceClean({ log, cwd: 'nogit' }), false) - .then(() => t.strictSame(warnings, [ - [ - 'version', - 'This is a Git checkout, but the git command was not found.', - 'npm could not create a Git tag for this release!', - ], - ])) - .then(() => { - warnings.length = 0 - })) +t.test('unclean, forced, no throw', async t => { + await t.resolveMatch(enforceClean({ cwd: 'unclean', force: true }), true) + t.strictSame(warnings, [ + [ + 'version', + 'Git working directory not clean, proceeding forcefully.', + ], + ]) +}) -t.test('other error, throw it', t => - t.rejects(enforceClean({ log, cwd: 'error' }), new Error('poop')) - .then(() => t.strictSame(warnings, [])) - .then(() => { - warnings.length = 0 - })) +t.test('nogit, return false, no throw', async t => { + await t.resolveMatch(enforceClean({ cwd: 'nogit' }), false) + t.strictSame(warnings, [ + [ + 'version', + 'This is a Git checkout, but the git command was not found.', + 'npm could not create a Git tag for this release!', + ], + ]) +}) + +t.test('other error, throw it', async t => { + await t.rejects(enforceClean({ cwd: 'error' }), new Error('poop')) + t.strictSame(warnings, []) +}) diff --git a/workspaces/libnpmversion/test/index.js b/workspaces/libnpmversion/test/index.js index 8c853c6..9dcef7b 100644 --- a/workspaces/libnpmversion/test/index.js +++ b/workspaces/libnpmversion/test/index.js @@ -33,7 +33,6 @@ t.test('set the package ahead of time', async t => ignoreScripts: true, scriptShell: '/bin/bash', preid: 'rc', - log: {}, message: 'hello, i have a message for you', someOtherRandomField: 'this should not show up', }))) diff --git a/workspaces/libnpmversion/test/proc-log.js b/workspaces/libnpmversion/test/proc-log.js deleted file mode 100644 index 54f7d0b..0000000 --- a/workspaces/libnpmversion/test/proc-log.js +++ /dev/null @@ -1,11 +0,0 @@ -const procLog = require('../lib/proc-log.js') -const t = require('tap') -process.once('log', (...args) => t.same(args, ['warn', 1, 2, 3])) -procLog.warn(1, 2, 3) -t.same(Object.keys(procLog), [ - 'notice', 'error', - 'warn', 'info', - 'verbose', 'http', - 'silly', 'pause', - 'resume', -]) diff --git a/workspaces/libnpmversion/test/version.js b/workspaces/libnpmversion/test/version.js index dfaa95d..2cbd615 100644 --- a/workspaces/libnpmversion/test/version.js +++ b/workspaces/libnpmversion/test/version.js @@ -3,10 +3,6 @@ const requireInject = require('require-inject') const actionLog = [] -const log = { - verbose: (...msg) => actionLog.push(['verbose', ...msg]), -} - const gitMock = { is: async opts => !/\bnot-git$/.test(opts.path), spawn: async (args, opts) => actionLog.push(['spawn', args, opts]), @@ -15,8 +11,8 @@ const gitMock = { const version = requireInject('../lib/version.js', { '../lib/enforce-clean.js': async () => true, '../lib/write-json.js': async (file, data) => actionLog.push(['write-json', file, data]), - '../lib/commit.js': async (version, opts) => actionLog.push(['commit', version, opts]), - '../lib/tag.js': async (version, opts) => actionLog.push(['tag', version, opts]), + '../lib/commit.js': async (v, opts) => actionLog.push(['commit', v, opts]), + '../lib/tag.js': async (v, opts) => actionLog.push(['tag', v, opts]), '../lib/retrieve-tag.js': async (opts) => { if (/\bnot-git$/.test(opts.path)) { throw new Error('not a git dir') @@ -26,6 +22,9 @@ const version = requireInject('../lib/version.js', { }, '@npmcli/git': gitMock, '@npmcli/run-script': async opt => actionLog.push(['run-script', opt.event, opt.env, opt]), + 'proc-log': { + verbose: (...msg) => actionLog.push(['verbose', ...msg]), + }, }) t.test('test out bumping the version in all the ways', async t => { @@ -70,7 +69,7 @@ t.test('test out bumping the version in all the ways', async t => { } throw new Error('no addy the locky fiel please & thanky i ignoring it') } - t.equal(await version('major', { path, log, pkg, gitTagVersion: true }), '2.0.0') + t.equal(await version('major', { path, pkg, gitTagVersion: true }), '2.0.0') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '1.2.0', npm_new_version: '2.0.0' }], ['write-json', path + '/package.json', pkg], @@ -85,7 +84,7 @@ t.test('test out bumping the version in all the ways', async t => { }) await t.test('minor (ignore scripts)', async t => { t.equal(await version('minor', - { path, log, pkg, ignoreScripts: true, gitTagVersion: true }), '2.1.0') + { path, pkg, ignoreScripts: true, gitTagVersion: true }), '2.1.0') t.match(actionLog, [ ['write-json', path + '/package.json', pkg], ['write-json', path + '/package-lock.json', pkg], @@ -97,7 +96,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '2.1.0') }) await t.test('patch', async t => { - t.equal(await version('patch', { path, log, pkg, gitTagVersion: true }), '2.1.1') + t.equal(await version('patch', { path, pkg, gitTagVersion: true }), '2.1.1') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '2.1.0', npm_new_version: '2.1.1' }], ['write-json', path + '/package.json', pkg], @@ -112,7 +111,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '2.1.1') }) await t.test('pre', async t => { - t.equal(await version('pre', { path, log, pkg, gitTagVersion: true }), '2.1.1-0') + t.equal(await version('pre', { path, pkg, gitTagVersion: true }), '2.1.1-0') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '2.1.1', npm_new_version: '2.1.1-0' }], ['write-json', path + '/package.json', pkg], @@ -127,7 +126,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '2.1.1-0') }) await t.test('pre with preid', async t => { - t.equal(await version('pre', { path, log, preid: 'alpha', pkg, gitTagVersion: true }), + t.equal(await version('pre', { path, preid: 'alpha', pkg, gitTagVersion: true }), '2.1.1-alpha.0') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '2.1.1-0', @@ -145,7 +144,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '2.1.1-alpha.0') }) await t.test('skips git tag when gitTagVersion is false', async t => { - t.equal(await version('minor', { path, log, pkg, ignoreScripts: true, gitTagVersion: false }), + t.equal(await version('minor', { path, pkg, ignoreScripts: true, gitTagVersion: false }), '2.2.0') t.match(actionLog, [ ['write-json', path + '/package.json', pkg], @@ -155,7 +154,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '2.2.0') }) await t.test('explicit version', async t => { - t.equal(await version('=v3.2.1', { path, log, pkg, gitTagVersion: true }), '3.2.1') + t.equal(await version('=v3.2.1', { path, pkg, gitTagVersion: true }), '3.2.1') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '2.2.0', npm_new_version: '3.2.1' }], ['write-json', path + '/package.json', pkg], @@ -170,14 +169,14 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '3.2.1') }) await t.test('invalid version', async t => { - await t.rejects(version('invalid version', { path, log, pkg }), { + await t.rejects(version('invalid version', { path, pkg }), { message: 'Invalid version: invalid version', current: '3.2.1', requested: 'invalid version', }) }) await t.test('same version, not allowed', async t => { - await t.rejects(version('=v3.2.1', { path, log, pkg }), { + await t.rejects(version('=v3.2.1', { path, pkg }), { message: 'Version not changed', current: '3.2.1', requested: '=v3.2.1', @@ -186,7 +185,7 @@ t.test('test out bumping the version in all the ways', async t => { }) await t.test('same version, is allowed', async t => { t.equal(await version('=v3.2.1', - { path, log, pkg, allowSameVersion: true, gitTagVersion: true }), '3.2.1') + { path, pkg, allowSameVersion: true, gitTagVersion: true }), '3.2.1') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '3.2.1', npm_new_version: '3.2.1' }], ['write-json', path + '/package.json', pkg], @@ -201,7 +200,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '3.2.1') }) await t.test('from git', async t => { - t.equal(await version('from-git', { path, log, pkg, gitTagVersion: true }), '1.2.3') + t.equal(await version('from-git', { path, pkg, gitTagVersion: true }), '1.2.3') t.match(actionLog, [ ['retrieve-tag', { path, pkg }], ['run-script', 'preversion', { npm_old_version: '3.2.1', npm_new_version: '1.2.3' }], @@ -218,7 +217,7 @@ t.test('test out bumping the version in all the ways', async t => { }) await t.test('no current version', async t => { delete pkg.version - t.equal(await version('2.3.4', { path, log, pkg, gitTagVersion: true }), '2.3.4') + t.equal(await version('2.3.4', { path, pkg, gitTagVersion: true }), '2.3.4') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '0.0.0', npm_new_version: '2.3.4' }], ['write-json', path + '/package.json', pkg], @@ -241,7 +240,7 @@ t.test('test out bumping the version in all the ways', async t => { }) const path = `${dir}/not-git` await t.test('major', async t => { - t.equal(await version('major', { path, log, pkg }), '2.0.0') + t.equal(await version('major', { path, pkg }), '2.0.0') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '1.2.0', npm_new_version: '2.0.0' }], ['write-json', path + '/package.json', pkg], @@ -253,7 +252,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '2.0.0') }) await t.test('minor (ignore scripts)', async t => { - t.equal(await version('minor', { path, log, pkg, ignoreScripts: true }), '2.1.0') + t.equal(await version('minor', { path, pkg, ignoreScripts: true }), '2.1.0') t.match(actionLog, [ ['write-json', path + '/package.json', pkg], ['write-json', path + '/npm-shrinkwrap.json', pkg], @@ -262,7 +261,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '2.1.0') }) await t.test('patch', async t => { - t.equal(await version('patch', { path, log, pkg }), '2.1.1') + t.equal(await version('patch', { path, pkg }), '2.1.1') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '2.1.0', npm_new_version: '2.1.1' }], ['write-json', path + '/package.json', pkg], @@ -274,7 +273,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '2.1.1') }) await t.test('pre', async t => { - t.equal(await version('pre', { path, log, pkg }), '2.1.1-0') + t.equal(await version('pre', { path, pkg }), '2.1.1-0') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '2.1.1', npm_new_version: '2.1.1-0' }], ['write-json', path + '/package.json', pkg], @@ -286,7 +285,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '2.1.1-0') }) await t.test('pre with preid', async t => { - t.equal(await version('pre', { path, log, preid: 'alpha', pkg }), '2.1.1-alpha.0') + t.equal(await version('pre', { path, preid: 'alpha', pkg }), '2.1.1-alpha.0') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '2.1.1-0', npm_new_version: '2.1.1-alpha.0' }], @@ -300,7 +299,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '2.1.1-alpha.0') }) await t.test('explicit version', async t => { - t.equal(await version('=v3.2.1', { path, log, pkg }), '3.2.1') + t.equal(await version('=v3.2.1', { path, pkg }), '3.2.1') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '2.1.1-alpha.0', npm_new_version: '3.2.1' }], @@ -314,14 +313,14 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '3.2.1') }) await t.test('invalid version', async t => { - await t.rejects(version('invalid version', { path, log, pkg }), { + await t.rejects(version('invalid version', { path, pkg }), { message: 'Invalid version: invalid version', current: '3.2.1', requested: 'invalid version', }) }) await t.test('same version, not allowed', async t => { - await t.rejects(version('=v3.2.1', { path, log, pkg }), { + await t.rejects(version('=v3.2.1', { path, pkg }), { message: 'Version not changed', current: '3.2.1', requested: '=v3.2.1', @@ -329,7 +328,7 @@ t.test('test out bumping the version in all the ways', async t => { }) }) await t.test('same version, is allowed', async t => { - t.equal(await version('=v3.2.1', { path, log, pkg, allowSameVersion: true }), '3.2.1') + t.equal(await version('=v3.2.1', { path, pkg, allowSameVersion: true }), '3.2.1') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '3.2.1', npm_new_version: '3.2.1' }, { banner: true }], @@ -345,7 +344,7 @@ t.test('test out bumping the version in all the ways', async t => { }) await t.test('same version, is allowed (silent mode)', async t => { t.equal(await version('=v3.2.1', - { path, log: { ...log, level: 'silent' }, pkg, allowSameVersion: true }), '3.2.1') + { path, silent: true, pkg, allowSameVersion: true }), '3.2.1') t.match(actionLog, [ ['run-script', 'preversion', { npm_old_version: '3.2.1', npm_new_version: '3.2.1' }, { banner: false }], @@ -360,7 +359,7 @@ t.test('test out bumping the version in all the ways', async t => { t.equal(pkg.version, '3.2.1') }) await t.test('from git', async t => { - await t.rejects(version('from-git', { path, log, pkg }), { + await t.rejects(version('from-git', { path, pkg }), { message: 'not a git dir', }) })