Skip to content

Commit d3f1cde

Browse files
committed
deps: upgrade npm to 7.0.8
PR-URL: #35953 Reviewed-By: Ruy Adorno <[email protected]> Reviewed-By: Jiawen Geng <[email protected]> Reviewed-By: Joyee Cheung <[email protected]>
1 parent fd027cd commit d3f1cde

File tree

147 files changed

+5653
-7124
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

147 files changed

+5653
-7124
lines changed

deps/npm/AUTHORS

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -727,3 +727,6 @@ Jake Champion <[email protected]>
727727
728728
729729
Michele Azzolari <[email protected]>
730+
731+
732+
Jan Tojnar <[email protected]>

deps/npm/CHANGELOG.md

Lines changed: 67 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,59 @@
1+
## 7.0.8 (2020-11-03)
2+
3+
### DOCUMENTATION
4+
5+
* [`052e977b9`](https://github.com/npm/cli/commit/052e977b9d071e1b3654976881d10cd3ddcba788)
6+
[#1822](https://github.com/npm/cli/issues/1822)
7+
[#1247](https://github.com/npm/cli/issues/1247)
8+
add section on peerDependenciesMeta field in package.json
9+
([@foxxyz](https://github.com/foxxyz))
10+
* [`52d32d175`](https://github.com/npm/cli/commit/52d32d1758c5ebc58944a1e8d98d57e30048e527)
11+
[#1970](https://github.com/npm/cli/issues/1970)
12+
match npm-exec.md -p usage with lib/exec.js
13+
([@dr-js](https://github.com/dr-js))
14+
* [`48ee8d01e`](https://github.com/npm/cli/commit/48ee8d01edd11ed6186c483e1169ff4d2070b963)
15+
[#2096](https://github.com/npm/cli/issues/2096)
16+
Fix RFC links in changelog
17+
([@jtojnar](https://github.com/jtojnar))
18+
19+
20+
### BUG FIXES
21+
22+
* [`6cd3cd08a`](https://github.com/npm/cli/commit/6cd3cd08af56445e13757cac3af87f3e7d54ed27)
23+
Support *all* conf keys in publishConfig
24+
* [`a1f9be8a7`](https://github.com/npm/cli/commit/a1f9be8a7f9b7a3a813fc3e5e705bc982470b0e2)
25+
[#2074](https://github.com/npm/cli/issues/2074)
26+
Support publishing any kind of spec, not just directories
27+
28+
### DEPENDENCIES
29+
30+
* [`545382df6`](https://github.com/npm/cli/commit/545382df62e3014f3e51d7034e52498fb2b01a37)
31+
32+
* Support publishing things other than folders
33+
* [`7d88f1719`](https://github.com/npm/cli/commit/7d88f17197e3c8cca9b277378d6f9b054b1b7886)
34+
35+
* [`823b40a4e`](https://github.com/npm/cli/commit/823b40a4e9c6ef76388af6fe01a3624f6f7675be)
36+
37+
* [`90bf57826`](https://github.com/npm/cli/commit/90bf57826edf2f78ddf8deb0793115ead8a8b556)
38+
39+
* [`e5a413577`](https://github.com/npm/cli/commit/e5a4135770d13cf114fac439167637181f87d824)
40+
41+
* [`fc5aa7b4a`](https://github.com/npm/cli/commit/fc5aa7b4ad45cb65893f734e1229a6720f7966e5)
42+
43+
* [`9fc1dee13`](https://github.com/npm/cli/commit/9fc1dee138ca33ecdbd57e63142b27c60cf88f9b)
44+
45+
* [`0ea870ec5`](https://github.com/npm/cli/commit/0ea870ec5d2be1d44f050ad8bc24ed936cc45fde)
46+
47+
* [`32fd744ea`](https://github.com/npm/cli/commit/32fd744ea745f297f0be79a80955f077a57c4ac7)
48+
49+
* [`fc76f3d9f`](https://github.com/npm/cli/commit/fc76f3d9fcf19e65a9373ab3d9068c4326d2f782)
50+
51+
* Fix `cannot read property 'description' of undefined` in `npm ls`
52+
when `package-lock.json` is corrupted
53+
* Do not allow peerDependencies to be nested under dependents in any
54+
circumstances
55+
* Always resolve peerDependencies in `--prefer-dedupe` mode
56+
157
## 7.0.7 (2020-10-30)
258

359
### BUG FIXES
@@ -602,7 +658,7 @@
602658
sources ([@ruyadorno](https://github.com/ruyadorno))
603659
* [`3a63ecb6f`](https://github.com/npm/cli/commit/3a63ecb6f6a0b235660f73a3ffa329b1f131b0c3)
604660
[#1718](https://github.com/npm/cli/pull/1718)
605-
[RFC-0029](https://github.com/npm/rfcs/blob/latest/accepted/0029-add-ability-to-skip-hooks.md)
661+
[RFC-0029](https://github.com/npm/rfcs/blob/latest/implemented/0029-add-ability-to-skip-hooks.md)
606662
add ability to skip pre/post hooks to `npm run-script` by using
607663
`--ignore-scripts` ([@ruyadorno](https://github.com/ruyadorno))
608664

@@ -829,7 +885,7 @@ Now on to the list of **BREAKING CHANGES**!
829885
### Programmatic Usage
830886

831887
- [RFC
832-
20](https://github.com/npm/rfcs/blob/latest/accepted/0020-npm-option-handling.md)
888+
20](https://github.com/npm/rfcs/blob/latest/implemented/0020-npm-option-handling.md)
833889
The CLI and its dependencies no longer use the `figgy-pudding` library
834890
for configs. Configuration is done using a flat plain old JavaScript
835891
object.
@@ -859,7 +915,7 @@ The environment for lifecycle scripts (eg, build scripts, `npm test`, etc.)
859915
has changed.
860916

861917
- [RFC
862-
21](https://github.com/npm/rfcs/blob/latest/accepted/0021-reduce-lifecycle-script-environment.md)
918+
21](https://github.com/npm/rfcs/blob/latest/implemented/0021-reduce-lifecycle-script-environment.md)
863919
Environment no longer includes `npm_package_*` fields, or `npm_config_*`
864920
fields for default configs. `npm_package_json`, `npm_package_integrity`,
865921
`npm_package_resolved`, and `npm_command` environment variables added.
@@ -868,13 +924,13 @@ has changed.
868924
release](https://github.com/npm/rfcs/pull/183))
869925

870926
- [RFC
871-
22](https://github.com/npm/rfcs/blob/latest/accepted/0022-quieter-install-scripts.md)
927+
22](https://github.com/npm/rfcs/blob/latest/implemented/0022-quieter-install-scripts.md)
872928
Scripts run during the normal course of installation are silenced unless
873929
they exit in error (ie, with a signal or non-zero exit status code), and
874930
are for a non-optional dependency.
875931

876932
- [RFC
877-
24](https://github.com/npm/rfcs/blob/latest/accepted/0024-npm-run-traverse-directory-tree.md)
933+
24](https://github.com/npm/rfcs/blob/latest/implemented/0024-npm-run-traverse-directory-tree.md)
878934
`PATH` environment variable includes all `node_modules/.bin` folders,
879935
even if found outside of an existing `node_modules` folder hierarchy.
880936

@@ -924,7 +980,7 @@ We do intend to continue supporting the `npx` that npm ships; just not the
924980
### Files On Disk
925981

926982
- [RFC
927-
13](https://github.com/npm/rfcs/blob/latest/accepted/0013-no-package-json-_fields.md)
983+
13](https://github.com/npm/rfcs/blob/latest/implemented/0013-no-package-json-_fields.md)
928984
Installed `package.json` files no longer are mutated to include extra
929985
metadata. (This extra metadata is stored in the lockfile.)
930986
- `package-lock.json` is updated to a newer format, using
@@ -940,7 +996,7 @@ These changes affect `install`, `ci`, `install-test`, `install-ci-test`,
940996
`update`, `prune`, `dedupe`, `uninstall`, `link`, and `audit fix`.
941997

942998
- [RFC
943-
25](https://github.com/npm/rfcs/blob/latest/accepted/0025-install-peer-deps.md)
999+
25](https://github.com/npm/rfcs/blob/latest/implemented/0025-install-peer-deps.md)
9441000
`peerDependencies` are installed by default. This behavior can be
9451001
disabled by setting the `legacy-peer-deps` configuration flag.
9461002

@@ -951,7 +1007,7 @@ These changes affect `install`, `ci`, `install-test`, `install-ci-test`,
9511007
of correctness. Use the `--legacy-peer-deps` config flag if impacted.
9521008

9531009
- [RFC
954-
23](https://github.com/npm/rfcs/blob/latest/accepted/0023-acceptDependencies.md)
1010+
23](https://github.com/npm/rfcs/blob/latest/implemented/0023-acceptDependencies.md)
9551011
Support for `acceptDependencies` is added. This can result in dependency
9561012
resolutions that previous versions of npm will incorrectly flag as invalid.
9571013

@@ -973,23 +1029,23 @@ These changes affect `install`, `ci`, `install-test`, `install-ci-test`,
9731029
### Workspaces
9741030

9751031
- [RFC
976-
26](https://github.com/npm/rfcs/blob/latest/accepted/0026-workspaces.md)
1032+
26](https://github.com/npm/rfcs/blob/latest/implemented/0026-workspaces.md)
9771033
First phase of `workspaces` support is added. This changes npm's
9781034
behavior when a root project's `package.json` file contains a
9791035
`workspaces` field.
9801036

9811037
### `npm update`
9821038

9831039
- [RFC
984-
19](https://github.com/npm/rfcs/blob/latest/accepted/0019-remove-update-depth-option.md)
1040+
19](https://github.com/npm/rfcs/blob/latest/implemented/0019-remove-update-depth-option.md)
9851041
Update all dependencies when `npm update` is run without any arguments.
9861042
As it is no longer relevant, `--depth` config flag removed from `npm
9871043
update`.
9881044

9891045
### `npm outdated`
9901046

9911047
- [RFC
992-
27](https://github.com/npm/rfcs/blob/latest/accepted/0027-remove-depth-outdated.md)
1048+
27](https://github.com/npm/rfcs/blob/latest/implemented/0027-remove-depth-outdated.md)
9931049
Remove `--depth` config from `npm outdated`. Only top-level dependencies
9941050
are shown, unless `--all` config option is set.
9951051

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
if not defined npm_config_node_gyp (
2-
node "%~dp0\..\..\node_modules\node-gyp\bin\node-gyp.js" %*
3-
) else (
1+
if not defined npm_config_node_gyp (
2+
node "%~dp0\..\..\node_modules\node-gyp\bin\node-gyp.js" %*
3+
) else (
44
node "%npm_config_node_gyp%" %*
5-
)
5+
)

deps/npm/bin/npm.cmd

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
1-
:: Created by npm, please don't edit manually.
2-
@ECHO OFF
3-
4-
SETLOCAL
5-
6-
SET "NODE_EXE=%~dp0\node.exe"
7-
IF NOT EXIST "%NODE_EXE%" (
8-
SET "NODE_EXE=node"
9-
)
10-
11-
SET "NPM_CLI_JS=%~dp0\node_modules\npm\bin\npm-cli.js"
12-
FOR /F "delims=" %%F IN ('CALL "%NODE_EXE%" "%NPM_CLI_JS%" prefix -g') DO (
13-
SET "NPM_PREFIX_NPM_CLI_JS=%%F\node_modules\npm\bin\npm-cli.js"
14-
)
15-
IF EXIST "%NPM_PREFIX_NPM_CLI_JS%" (
16-
SET "NPM_CLI_JS=%NPM_PREFIX_NPM_CLI_JS%"
17-
)
18-
19-
"%NODE_EXE%" "%NPM_CLI_JS%" %*
1+
:: Created by npm, please don't edit manually.
2+
@ECHO OFF
3+
4+
SETLOCAL
5+
6+
SET "NODE_EXE=%~dp0\node.exe"
7+
IF NOT EXIST "%NODE_EXE%" (
8+
SET "NODE_EXE=node"
9+
)
10+
11+
SET "NPM_CLI_JS=%~dp0\node_modules\npm\bin\npm-cli.js"
12+
FOR /F "delims=" %%F IN ('CALL "%NODE_EXE%" "%NPM_CLI_JS%" prefix -g') DO (
13+
SET "NPM_PREFIX_NPM_CLI_JS=%%F\node_modules\npm\bin\npm-cli.js"
14+
)
15+
IF EXIST "%NPM_PREFIX_NPM_CLI_JS%" (
16+
SET "NPM_CLI_JS=%NPM_PREFIX_NPM_CLI_JS%"
17+
)
18+
19+
"%NODE_EXE%" "%NPM_CLI_JS%" %*

deps/npm/bin/npx.cmd

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
1-
:: Created by npm, please don't edit manually.
2-
@ECHO OFF
3-
4-
SETLOCAL
5-
6-
SET "NODE_EXE=%~dp0\node.exe"
7-
IF NOT EXIST "%NODE_EXE%" (
8-
SET "NODE_EXE=node"
9-
)
10-
11-
SET "NPM_CLI_JS=%~dp0\node_modules\npm\bin\npm-cli.js"
12-
SET "NPX_CLI_JS=%~dp0\node_modules\npm\bin\npx-cli.js"
13-
FOR /F "delims=" %%F IN ('CALL "%NODE_EXE%" "%NPM_CLI_JS%" prefix -g') DO (
14-
SET "NPM_PREFIX_NPX_CLI_JS=%%F\node_modules\npm\bin\npx-cli.js"
15-
)
16-
IF EXIST "%NPM_PREFIX_NPX_CLI_JS%" (
17-
SET "NPX_CLI_JS=%NPM_PREFIX_NPX_CLI_JS%"
18-
)
19-
20-
"%NODE_EXE%" "%NPX_CLI_JS%" %*
1+
:: Created by npm, please don't edit manually.
2+
@ECHO OFF
3+
4+
SETLOCAL
5+
6+
SET "NODE_EXE=%~dp0\node.exe"
7+
IF NOT EXIST "%NODE_EXE%" (
8+
SET "NODE_EXE=node"
9+
)
10+
11+
SET "NPM_CLI_JS=%~dp0\node_modules\npm\bin\npm-cli.js"
12+
SET "NPX_CLI_JS=%~dp0\node_modules\npm\bin\npx-cli.js"
13+
FOR /F "delims=" %%F IN ('CALL "%NODE_EXE%" "%NPM_CLI_JS%" prefix -g') DO (
14+
SET "NPM_PREFIX_NPX_CLI_JS=%%F\node_modules\npm\bin\npx-cli.js"
15+
)
16+
IF EXIST "%NPM_PREFIX_NPX_CLI_JS%" (
17+
SET "NPX_CLI_JS=%NPM_PREFIX_NPX_CLI_JS%"
18+
)
19+
20+
"%NODE_EXE%" "%NPX_CLI_JS%" %*

deps/npm/changelogs/CHANGELOG-5.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1935,7 +1935,7 @@ helpful when community members go over our code and help clean it up, too!
19351935
* [`9e5b76140`](https://github.com/npm/npm/commit/9e5b76140ffdb7dcd12aa402793644213fb8c5d7)
19361936
[#17411](https://github.com/npm/npm/pull/17411)
19371937
Convert all callback-style `move` usage to use Promises.
1938-
([@vramana](https://github.com/vramana))
1938+
([@vramana](https://github.com/vramana))
19391939
* [`0711c08f7`](https://github.com/npm/npm/commit/0711c08f779ac641ec42ecc96f604c8861008b28)
19401940
[#17394](https://github.com/npm/npm/pull/17394)
19411941
Remove unused argument in `deepSortObject`.

deps/npm/docs/content/commands/npm-completion.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ npm completion >> ~/.zshrc
2525
```
2626

2727
You may of course also pipe the output of `npm completion` to a file
28-
such as `/usr/local/etc/bash_completion.d/npm` or
29-
`/etc/bash_completion.d/npm` if you have a system that will read
28+
such as `/usr/local/etc/bash_completion.d/npm` or
29+
`/etc/bash_completion.d/npm` if you have a system that will read
3030
that file for you.
3131

3232
When `COMP_CWORD`, `COMP_LINE`, and `COMP_POINT` are defined in the

deps/npm/docs/content/commands/npm-deprecate.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ npm deprecate my-thing@"< 0.2.3" "critical bug fixed in v0.2.3"
2525
Note that you must be the package owner to deprecate something. See the
2626
`owner` and `adduser` help topics.
2727

28-
To un-deprecate a package, specify an empty string (`""`) for the `message`
29-
argument. Note that you must use double quotes with no space between them to
28+
To un-deprecate a package, specify an empty string (`""`) for the `message`
29+
argument. Note that you must use double quotes with no space between them to
3030
format an empty string.
3131

3232
### See Also

deps/npm/docs/content/commands/npm-exec.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@ This command allows you to run an arbitrary command from an npm package
3030
(either one installed locally, or fetched remotely), in a similar context
3131
as running it via `npm run`.
3232

33-
Whatever packages are specified by the `--package` or `-p` option will be
33+
Whatever packages are specified by the `--package` option will be
3434
provided in the `PATH` of the executed command, along with any locally
35-
installed package executables. The `--package` or `-p` option may be
35+
installed package executables. The `--package` option may be
3636
specified multiple times, to execute the supplied command in an environment
3737
where all specified packages are available.
3838

@@ -48,7 +48,7 @@ only be considered a match if they have the exact same name and version as
4848
the local dependency.
4949

5050
If no `-c` or `--call` option is provided, then the positional arguments
51-
are used to generate the command string. If no `-p` or `--package` options
51+
are used to generate the command string. If no `--package` options
5252
are provided, then npm will attempt to determine the executable name from
5353
the package specifier provided as the first positional argument according
5454
to the following heuristic:

deps/npm/docs/content/commands/npm-profile.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ you're using a non-npmjs registry.
4646
| updated | 2017-10-02T21:29:45.922Z |
4747
+-----------------+---------------------------+
4848
```
49-
49+
5050
* `npm profile set <property> <value>`:
5151
Set the value of a profile property. You can set the following properties this way:
5252
email, fullname, homepage, freenode, twitter, github

deps/npm/docs/content/commands/npm-token.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,5 +60,5 @@ This lets you list, create and revoke authentication tokens.
6060
* `npm token revoke <token|id>`:
6161
This removes an authentication token, making it immediately unusable. This can accept
6262
both complete tokens (as you get back from `npm token create` and will
63-
find in your `.npmrc`) and ids as seen in the `npm token list` output.
63+
find in your `.npmrc`) and ids as seen in the `npm token list` output.
6464
This will NOT accept the truncated token found in `npm token list` output.

deps/npm/docs/content/commands/npm-unpublish.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ Even if a package version is unpublished, that specific name and
3434
version combination can never be reused. In order to publish the
3535
package again, a new version number must be used. If you unpublish the entire package, you may not publish any new versions of that package until 24 hours have passed.
3636

37-
To learn more about how unpublish is treated on the npm registry, see our <a href="https://www.npmjs.com/policies/unpublish" target="_blank" rel="noopener noreferrer"> unpublish policies</a>.
37+
To learn more about how unpublish is treated on the npm registry, see our <a href="https://www.npmjs.com/policies/unpublish" target="_blank" rel="noopener noreferrer"> unpublish policies</a>.
3838

3939

4040
### See Also

deps/npm/docs/content/commands/npm-update.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@ As of `[email protected]`, the `npm update` will only inspect top-level packages.
3131
Prior versions of `npm` would also recursively inspect all dependencies.
3232
To get the old behavior, use `npm --depth 9999 update`.
3333

34-
As of `[email protected]`, the `npm update` will change `package.json` to save the
35-
new version as the minimum required dependency. To get the old behavior,
34+
As of `[email protected]`, the `npm update` will change `package.json` to save the
35+
new version as the minimum required dependency. To get the old behavior,
3636
use `npm update --no-save`.
3737

3838
### Example

deps/npm/docs/content/commands/npm-version.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ and tag up to the server, and deletes the `build/temp` directory.
9494
* Default: false
9595
* Type: Boolean
9696
97-
Prevents throwing an error when `npm version` is used to set the new version
97+
Prevents throwing an error when `npm version` is used to set the new version
9898
to the same value as the current version.
9999
100100
#### git-tag-version

deps/npm/docs/content/commands/npm-view.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ was required by each matching version of yui3:
8888

8989
```bash
9090
npm view yui3@'>0.5.4' dependencies.jsdom
91-
```
91+
```
9292

9393
To show the `connect` package version history, you can do
9494
this:

deps/npm/docs/content/configuring-npm/package-json.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -716,6 +716,30 @@ the host package's major version will break your plugin. Thus, if you've worked
716716
with every 1.x version of the host package, use `"^1.0"` or `"1.x"` to express
717717
this. If you depend on features introduced in 1.5.2, use `">= 1.5.2 < 2"`.
718718

719+
### peerDependenciesMeta
720+
721+
When a user installs your package, npm will emit warnings if packages specified in `peerDependencies` are not already installed. The `peerDependenciesMeta` field serves to provide npm more information on how your peer dependencies are to be used. Specifically, it allows peer dependencies to be marked as optional.
722+
723+
For example:
724+
725+
```json
726+
{
727+
"name": "tea-latte",
728+
"version": "1.3.5",
729+
"peerDependencies": {
730+
"tea": "2.x",
731+
"soy-milk": "1.2"
732+
},
733+
"peerDependenciesMeta": {
734+
"soy-milk": {
735+
"optional": true
736+
}
737+
}
738+
}
739+
```
740+
741+
Marking a peer dependency as optional ensures npm will not emit a warning 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.
742+
719743
### bundledDependencies
720744

721745
This defines an array of package names that will be bundled when publishing

0 commit comments

Comments
 (0)