diff options
author | isaacs <i@izs.me> | 2020-09-08 00:38:12 +0300 |
---|---|---|
committer | isaacs <i@izs.me> | 2020-09-08 19:52:39 +0300 |
commit | 5e49bdaa34e29dbd25c687f8e6881747a86b7435 (patch) | |
tree | 78eef0d61e34b49387369f3a41d4aeca1ccb7e2f /tap-snapshots | |
parent | 7418970f03229dd2bce7973b99b981779aee6916 (diff) |
Add 'npm explain' command
Pass a specifier or folder path, and it'll explain what that dependency
is doing there.
PR-URL: https://github.com/npm/cli/pull/1776
Credit: @isaacs
Close: #1776
Reviewed-by: @ruyadorno
Diffstat (limited to 'tap-snapshots')
-rw-r--r-- | tap-snapshots/test-lib-utils-cmd-list.js-TAP.test.js | 3 | ||||
-rw-r--r-- | tap-snapshots/test-lib-utils-explain-eresolve.js-TAP.test.js | 4 |
2 files changed, 5 insertions, 2 deletions
diff --git a/tap-snapshots/test-lib-utils-cmd-list.js-TAP.test.js b/tap-snapshots/test-lib-utils-cmd-list.js-TAP.test.js index 1b0118d26..c77da6b18 100644 --- a/tap-snapshots/test-lib-utils-cmd-list.js-TAP.test.js +++ b/tap-snapshots/test-lib-utils-cmd-list.js-TAP.test.js @@ -100,6 +100,7 @@ Object { "urn": "run-script", "v": "view", "verison": "version", + "why": "explain", "x": "exec", }, "cmdList": Array [ @@ -164,6 +165,7 @@ Object { "completion", "doctor", "exec", + "explain", ], "plumbing": Array [ "birthday", @@ -190,6 +192,7 @@ Object { "unstar": "star", "up": "update", "v": "view", + "why": "explain", "x": "exec", }, } diff --git a/tap-snapshots/test-lib-utils-explain-eresolve.js-TAP.test.js b/tap-snapshots/test-lib-utils-explain-eresolve.js-TAP.test.js index 9baadbe6e..716d82ced 100644 --- a/tap-snapshots/test-lib-utils-explain-eresolve.js-TAP.test.js +++ b/tap-snapshots/test-lib-utils-explain-eresolve.js-TAP.test.js @@ -170,7 +170,7 @@ Found: [1mreact[22m@[1m16.13.1[22m[2m[22m [35mpeer[39m [1mreact[22m@"[1m^16.4.2[22m" from [1mgatsby[22m@[1m2.24.53[22m[2m[22m [2mnode_modules/gatsby[22m [1mgatsby[22m@"" from the root project - 26 more (react-dom, @reach/router, gatsby-cli, ...) + 26 more (react-dom, @reach/router, gatsby-cli, gatsby-link, ...) Could not add conflicting dependency: [1mreact[22m@[1m16.8.1[22m[2m[22m [2mnode_modules/react[22m @@ -734,7 +734,7 @@ Found: [1mreact[22m@[1m16.13.1[22m[2m[22m [35mpeer[39m [1mreact[22m@"[1m^16.4.2[22m" from [1mgatsby[22m@[1m2.24.53[22m[2m[22m [2mnode_modules/gatsby[22m [1mgatsby[22m@"" from the root project - 26 more (react-dom, @reach/router, gatsby-cli, ...) + 26 more (react-dom, @reach/router, gatsby-cli, gatsby-link, ...) Could not add conflicting dependency: [1mreact[22m@[1m16.8.1[22m[2m[22m [2mnode_modules/react[22m |