From 2a8c2fcd124ce7d4b23a6c26552d097c6501ac74 Mon Sep 17 00:00:00 2001 From: Gar Date: Thu, 8 Sep 2022 09:51:08 -0700 Subject: [PATCH] feat: default `install-links` to true (#5458) BREAKING CHANGE: this changes the default value of `install-links` to true Closes https://github.com/npm/statusboard/issues/510 --- docs/content/commands/npm-audit.md | 2 +- docs/content/commands/npm-ci.md | 2 +- docs/content/commands/npm-dedupe.md | 2 +- docs/content/commands/npm-find-dupes.md | 2 +- docs/content/commands/npm-install-ci-test.md | 2 +- docs/content/commands/npm-install-test.md | 2 +- docs/content/commands/npm-install.md | 2 +- docs/content/commands/npm-link.md | 2 +- docs/content/commands/npm-ls.md | 2 +- docs/content/commands/npm-prune.md | 2 +- docs/content/commands/npm-rebuild.md | 2 +- docs/content/commands/npm-uninstall.md | 2 +- docs/content/commands/npm-update.md | 2 +- docs/content/using-npm/config.md | 2 +- lib/utils/config/definitions.js | 2 +- .../tap-snapshots/test/index.js.test.cjs | 2 +- .../test/lib/commands/config.js.test.cjs | 4 +-- .../test/lib/load-all-commands.js.test.cjs | 28 +++++++++---------- tap-snapshots/test/lib/npm.js.test.cjs | 28 +++++++++---------- .../lib/utils/config/definitions.js.test.cjs | 2 +- .../lib/utils/config/describe-all.js.test.cjs | 2 +- 21 files changed, 48 insertions(+), 48 deletions(-) diff --git a/docs/content/commands/npm-audit.md b/docs/content/commands/npm-audit.md index 48e0a3161e8f2..6a5c3e6be676e 100644 --- a/docs/content/commands/npm-audit.md +++ b/docs/content/commands/npm-audit.md @@ -453,7 +453,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-ci.md b/docs/content/commands/npm-ci.md index 3ecd7c6efb095..af6fc7fcc94e8 100644 --- a/docs/content/commands/npm-ci.md +++ b/docs/content/commands/npm-ci.md @@ -361,7 +361,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-dedupe.md b/docs/content/commands/npm-dedupe.md index 570e018342f27..da9f406d57024 100644 --- a/docs/content/commands/npm-dedupe.md +++ b/docs/content/commands/npm-dedupe.md @@ -308,7 +308,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-find-dupes.md b/docs/content/commands/npm-find-dupes.md index 4da6c296c6bf6..590c7e2cbd438 100644 --- a/docs/content/commands/npm-find-dupes.md +++ b/docs/content/commands/npm-find-dupes.md @@ -232,7 +232,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-install-ci-test.md b/docs/content/commands/npm-install-ci-test.md index b886f8ab9599a..784efdcf46e95 100644 --- a/docs/content/commands/npm-install-ci-test.md +++ b/docs/content/commands/npm-install-ci-test.md @@ -307,7 +307,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-install-test.md b/docs/content/commands/npm-install-test.md index d27686e731ce1..ec69e081f9dee 100644 --- a/docs/content/commands/npm-install-test.md +++ b/docs/content/commands/npm-install-test.md @@ -308,7 +308,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-install.md b/docs/content/commands/npm-install.md index d6ae4324ecefc..0cf2eea83edb9 100644 --- a/docs/content/commands/npm-install.md +++ b/docs/content/commands/npm-install.md @@ -698,7 +698,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-link.md b/docs/content/commands/npm-link.md index 8c1b422493bd5..fd6eb69e9b03c 100644 --- a/docs/content/commands/npm-link.md +++ b/docs/content/commands/npm-link.md @@ -384,7 +384,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-ls.md b/docs/content/commands/npm-ls.md index a7936fafc72a2..bb7fd5cc06f79 100644 --- a/docs/content/commands/npm-ls.md +++ b/docs/content/commands/npm-ls.md @@ -287,7 +287,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-prune.md b/docs/content/commands/npm-prune.md index 28f02f6add190..064b0e07e4e7a 100644 --- a/docs/content/commands/npm-prune.md +++ b/docs/content/commands/npm-prune.md @@ -193,7 +193,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-rebuild.md b/docs/content/commands/npm-rebuild.md index 6a396421213d3..89fbd763555a0 100644 --- a/docs/content/commands/npm-rebuild.md +++ b/docs/content/commands/npm-rebuild.md @@ -163,7 +163,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-uninstall.md b/docs/content/commands/npm-uninstall.md index e39c7e328b20a..bea7112ae5719 100644 --- a/docs/content/commands/npm-uninstall.md +++ b/docs/content/commands/npm-uninstall.md @@ -147,7 +147,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/commands/npm-update.md b/docs/content/commands/npm-update.md index 421d04ca3dc58..cd77b7baddf19 100644 --- a/docs/content/commands/npm-update.md +++ b/docs/content/commands/npm-update.md @@ -435,7 +435,7 @@ This value is not exported to the environment for child processes. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/docs/content/using-npm/config.md b/docs/content/using-npm/config.md index cd13237f34dd3..e6a7231861ba0 100644 --- a/docs/content/using-npm/config.md +++ b/docs/content/using-npm/config.md @@ -910,7 +910,7 @@ number, if not already set in package.json. #### `install-links` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root diff --git a/lib/utils/config/definitions.js b/lib/utils/config/definitions.js index a132c8456b0fa..a76484b5228f5 100644 --- a/lib/utils/config/definitions.js +++ b/lib/utils/config/definitions.js @@ -1083,7 +1083,7 @@ define('init.version', { }) define('install-links', { - default: false, + default: true, type: Boolean, description: ` When set file: protocol dependencies that exist outside of the project root diff --git a/smoke-tests/tap-snapshots/test/index.js.test.cjs b/smoke-tests/tap-snapshots/test/index.js.test.cjs index 6b0b7b3940605..f7e49ed91e1d2 100644 --- a/smoke-tests/tap-snapshots/test/index.js.test.cjs +++ b/smoke-tests/tap-snapshots/test/index.js.test.cjs @@ -61,7 +61,7 @@ npm ERR! [--omit [--omit ...]] 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 [-w|--workspace ...]] -npm ERR! [-ws|--workspaces] [--include-workspace-root] [--install-links] +npm ERR! [-ws|--workspaces] [--include-workspace-root] [--no-install-links] npm ERR! npm ERR! aliases: clean-install, ic, install-clean, isntall-clean npm ERR! diff --git a/tap-snapshots/test/lib/commands/config.js.test.cjs b/tap-snapshots/test/lib/commands/config.js.test.cjs index 5c3f86415dfff..6ed14ae5b2546 100644 --- a/tap-snapshots/test/lib/commands/config.js.test.cjs +++ b/tap-snapshots/test/lib/commands/config.js.test.cjs @@ -81,7 +81,7 @@ 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": false, + "install-links": true, "key": null, "legacy-bundling": false, "legacy-peer-deps": false, @@ -237,7 +237,7 @@ init.author.url = "" init.license = "ISC" init.module = "{HOME}/.npm-init.js" init.version = "1.0.0" -install-links = false +install-links = true json = false key = null legacy-bundling = false diff --git a/tap-snapshots/test/lib/load-all-commands.js.test.cjs b/tap-snapshots/test/lib/load-all-commands.js.test.cjs index 6ea63931ce874..ad7acd359b984 100644 --- a/tap-snapshots/test/lib/load-all-commands.js.test.cjs +++ b/tap-snapshots/test/lib/load-all-commands.js.test.cjs @@ -52,7 +52,7 @@ Options: [--omit [--omit ...]] [--foreground-scripts] [--ignore-scripts] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] Run "npm help audit" for more info ` @@ -110,7 +110,7 @@ Options: [--strict-peer-deps] [--no-package-lock] [--foreground-scripts] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] aliases: clean-install, ic, install-clean, isntall-clean @@ -156,7 +156,7 @@ Options: [--omit [--omit ...]] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: ddp @@ -305,7 +305,7 @@ Options: [--omit [--omit ...]] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] Run "npm help find-dupes" for more info ` @@ -404,7 +404,7 @@ Options: [--strict-peer-deps] [--no-package-lock] [--foreground-scripts] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] aliases: add, i, in, ins, inst, insta, instal, isnt, isnta, isntal, isntall @@ -424,7 +424,7 @@ Options: [--strict-peer-deps] [--no-package-lock] [--foreground-scripts] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: cit @@ -444,7 +444,7 @@ Options: [--strict-peer-deps] [--no-package-lock] [--foreground-scripts] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: it @@ -464,7 +464,7 @@ Options: [--omit [--omit ...]] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: ln @@ -482,7 +482,7 @@ Options: [--omit [--omit ...]] [--link] [--package-lock-only] [--unicode] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: la @@ -527,7 +527,7 @@ Options: [--omit [--omit ...]] [--link] [--package-lock-only] [--unicode] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: list @@ -662,7 +662,7 @@ Options: [--omit [--omit ...]] [--dry-run] [--json] [--foreground-scripts] [--ignore-scripts] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] Run "npm help prune" for more info ` @@ -704,7 +704,7 @@ npm rebuild [] ...] Options: [-g|--global] [--no-bin-links] [--foreground-scripts] [--ignore-scripts] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: rb @@ -914,7 +914,7 @@ npm uninstall [<@scope>/]... Options: [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] aliases: unlink, remove, rm, r, un @@ -960,7 +960,7 @@ Options: [--strict-peer-deps] [--no-package-lock] [--foreground-scripts] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] -[-ws|--workspaces] [--include-workspace-root] [--install-links] +[-ws|--workspaces] [--include-workspace-root] [--no-install-links] aliases: up, upgrade, udpate diff --git a/tap-snapshots/test/lib/npm.js.test.cjs b/tap-snapshots/test/lib/npm.js.test.cjs index fcd167742b442..a728654a51d43 100644 --- a/tap-snapshots/test/lib/npm.js.test.cjs +++ b/tap-snapshots/test/lib/npm.js.test.cjs @@ -207,7 +207,7 @@ All commands: [--omit [--omit ...]] [--foreground-scripts] [--ignore-scripts] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] Run "npm help audit" for more info @@ -250,7 +250,7 @@ All commands: [--strict-peer-deps] [--no-package-lock] [--foreground-scripts] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] aliases: clean-install, ic, install-clean, isntall-clean @@ -290,7 +290,7 @@ All commands: [--omit [--omit ...]] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: ddp @@ -419,7 +419,7 @@ All commands: [--omit [--omit ...]] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] Run "npm help find-dupes" for more info @@ -494,7 +494,7 @@ All commands: [--strict-peer-deps] [--no-package-lock] [--foreground-scripts] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] aliases: add, i, in, ins, inst, insta, instal, isnt, isnta, isntal, isntall @@ -512,7 +512,7 @@ All commands: [--strict-peer-deps] [--no-package-lock] [--foreground-scripts] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: cit @@ -530,7 +530,7 @@ All commands: [--strict-peer-deps] [--no-package-lock] [--foreground-scripts] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: it @@ -548,7 +548,7 @@ All commands: [--omit [--omit ...]] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: ln @@ -564,7 +564,7 @@ All commands: [--omit [--omit ...]] [--link] [--package-lock-only] [--unicode] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: la @@ -603,7 +603,7 @@ All commands: [--omit [--omit ...]] [--link] [--package-lock-only] [--unicode] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: list @@ -720,7 +720,7 @@ All commands: [--omit [--omit ...]] [--dry-run] [--json] [--foreground-scripts] [--ignore-scripts] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] Run "npm help prune" for more info @@ -756,7 +756,7 @@ All commands: Options: [-g|--global] [--no-bin-links] [--foreground-scripts] [--ignore-scripts] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] alias: rb @@ -934,7 +934,7 @@ All commands: Options: [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] aliases: unlink, remove, rm, r, un @@ -974,7 +974,7 @@ All commands: [--strict-peer-deps] [--no-package-lock] [--foreground-scripts] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] - [-ws|--workspaces] [--include-workspace-root] [--install-links] + [-ws|--workspaces] [--include-workspace-root] [--no-install-links] aliases: up, upgrade, udpate diff --git a/tap-snapshots/test/lib/utils/config/definitions.js.test.cjs b/tap-snapshots/test/lib/utils/config/definitions.js.test.cjs index 024ad345a5d32..6eac545b2ce2d 100644 --- a/tap-snapshots/test/lib/utils/config/definitions.js.test.cjs +++ b/tap-snapshots/test/lib/utils/config/definitions.js.test.cjs @@ -983,7 +983,7 @@ Alias for \`--init-version\` exports[`test/lib/utils/config/definitions.js TAP > config description for install-links 1`] = ` #### \`install-links\` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root 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 index a03d22e5e6305..46910d1282e03 100644 --- a/tap-snapshots/test/lib/utils/config/describe-all.js.test.cjs +++ b/tap-snapshots/test/lib/utils/config/describe-all.js.test.cjs @@ -783,7 +783,7 @@ number, if not already set in package.json. #### \`install-links\` -* Default: false +* Default: true * Type: Boolean When set file: protocol dependencies that exist outside of the project root