|
1 | 1 | const linkBins = require('./link-bins.js') |
2 | | -const linkMans = require('./link-mans.js') |
3 | 2 |
|
4 | 3 | const binLinks = opts => { |
5 | 4 | const { path, pkg, force, global, top } = opts |
6 | | - // global top pkgs on windows get bins installed in {prefix}, and no mans |
| 5 | + // global top pkgs on windows get bins installed in {prefix}. |
7 | 6 | // |
8 | | - // unix global top pkgs get their bins installed in {prefix}/bin, |
9 | | - // and mans in {prefix}/share/man |
| 7 | + // unix global top pkgs get their bins installed in {prefix}/bin. |
10 | 8 | // |
11 | | - // non-top pkgs get their bins installed in {prefix}/node_modules/.bin, |
12 | | - // and do not install mans |
| 9 | + // non-top pkgs get their bins installed in {prefix}/node_modules/.bin. |
13 | 10 | // |
14 | | - // non-global top pkgs don't have any bins or mans linked. From here on |
15 | | - // out, if it's top, we know that it's global, so no need to pass that |
16 | | - // option further down the stack. |
| 11 | + // non-global top pkgs don't have any bins linked. From here on out, if it's top, we know that it's global, so no need to pass that option further down the stack. |
| 12 | + // |
| 13 | + // As of v7, bin-links no longer installs man pages into the system man path for any package. `getPaths` still returns legacy man paths so pre-existing installs can be cleaned up on uninstall. |
17 | 14 | if (top && !global) { |
18 | 15 | return Promise.resolve() |
19 | 16 | } |
20 | 17 |
|
21 | | - return Promise.all([ |
22 | | - // allow clobbering within the local node_modules/.bin folder. |
23 | | - // only global bins are protected in this way, or else it is |
24 | | - // yet another vector for excessive dependency conflicts. |
25 | | - linkBins({ path, pkg, top, force: force || !top }), |
26 | | - linkMans({ path, pkg, top, force }), |
27 | | - ]) |
| 18 | + // allow clobbering within the local node_modules/.bin folder. only global bins are protected in this way, or else it is yet another vector for excessive dependency conflicts. |
| 19 | + return linkBins({ path, pkg, top, force: force || !top }) |
28 | 20 | } |
29 | 21 |
|
30 | 22 | const shimBin = require('./shim-bin.js') |
|
0 commit comments