diff --git a/docs/content/commands/npm-bin.md b/docs/content/commands/npm-bin.md index b344ea2fc9415..94b72cfd5c81c 100644 --- a/docs/content/commands/npm-bin.md +++ b/docs/content/commands/npm-bin.md @@ -34,8 +34,6 @@ Print the folder where npm will install executables. * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/commands/npm-config.md b/docs/content/commands/npm-config.md index 809e42a1be1cd..28c6003571de5 100644 --- a/docs/content/commands/npm-config.md +++ b/docs/content/commands/npm-config.md @@ -124,8 +124,6 @@ Not supported by all npm commands. * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/commands/npm-diff.md b/docs/content/commands/npm-diff.md index 7183e4a2b752e..7dcc8af7c3b4c 100644 --- a/docs/content/commands/npm-diff.md +++ b/docs/content/commands/npm-diff.md @@ -248,8 +248,6 @@ Treat all files as text in `npm diff`. * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/commands/npm-install-test.md b/docs/content/commands/npm-install-test.md index 18e374869d5a6..3dd860ea5c6f6 100644 --- a/docs/content/commands/npm-install-test.md +++ b/docs/content/commands/npm-install-test.md @@ -70,8 +70,6 @@ rather than using npm's default semver range operator. * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/commands/npm-install.md b/docs/content/commands/npm-install.md index f99fcc0161dea..445772f0353a1 100644 --- a/docs/content/commands/npm-install.md +++ b/docs/content/commands/npm-install.md @@ -460,8 +460,6 @@ rather than using npm's default semver range operator. * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/commands/npm-link.md b/docs/content/commands/npm-link.md index 34c67aa3def81..975c807c38b34 100644 --- a/docs/content/commands/npm-link.md +++ b/docs/content/commands/npm-link.md @@ -153,8 +153,6 @@ rather than using npm's default semver range operator. * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/commands/npm-ls.md b/docs/content/commands/npm-ls.md index 5ad4593bfa2f6..ded8c0c0d26ef 100644 --- a/docs/content/commands/npm-ls.md +++ b/docs/content/commands/npm-ls.md @@ -137,8 +137,6 @@ Output parseable results from commands that write to standard output. For * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/commands/npm-outdated.md b/docs/content/commands/npm-outdated.md index 1bf2de039c315..6fa026550e747 100644 --- a/docs/content/commands/npm-outdated.md +++ b/docs/content/commands/npm-outdated.md @@ -150,8 +150,6 @@ Output parseable results from commands that write to standard output. For * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/commands/npm-prefix.md b/docs/content/commands/npm-prefix.md index 6f08e43fa8c0c..39328bcc88a14 100644 --- a/docs/content/commands/npm-prefix.md +++ b/docs/content/commands/npm-prefix.md @@ -51,8 +51,6 @@ npm prefix -g * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/commands/npm-rebuild.md b/docs/content/commands/npm-rebuild.md index fa5b0cfa97d7c..52c368c8c513b 100644 --- a/docs/content/commands/npm-rebuild.md +++ b/docs/content/commands/npm-rebuild.md @@ -42,8 +42,6 @@ will be rebuilt. * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/commands/npm-root.md b/docs/content/commands/npm-root.md index 80545235fc969..40b58e4b33d0b 100644 --- a/docs/content/commands/npm-root.md +++ b/docs/content/commands/npm-root.md @@ -41,8 +41,6 @@ echo "Global packages installed in: ${global_node_modules}" * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/commands/npm-update.md b/docs/content/commands/npm-update.md index 55aad182fcafe..421d04ca3dc58 100644 --- a/docs/content/commands/npm-update.md +++ b/docs/content/commands/npm-update.md @@ -188,8 +188,6 @@ Will also prevent writing to `package-lock.json` if set to `false`. * Default: false * Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. Operates in "global" mode, so that packages are installed into the `prefix` folder instead of the current working directory. See diff --git a/docs/content/using-npm/config.md b/docs/content/using-npm/config.md index 4e9e67d970ba2..6ef854eb6e0ff 100644 --- a/docs/content/using-npm/config.md +++ b/docs/content/using-npm/config.md @@ -687,6 +687,23 @@ 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` + + + + #### `global-style` * Default: false @@ -1935,25 +1952,6 @@ Alias for `--include=dev`. -#### `global` - -* Default: false -* Type: Boolean -* DEPRECATED: `--global`, `--local` are deprecated. Use `--location=global` - instead. - -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` - - - - #### `init.author.email` * Default: "" diff --git a/lib/utils/config/definitions.js b/lib/utils/config/definitions.js index 4032c552e24bb..4c77e375c5ccf 100644 --- a/lib/utils/config/definitions.js +++ b/lib/utils/config/definitions.js @@ -813,9 +813,6 @@ define('global', { default: false, type: Boolean, short: 'g', - deprecated: ` - \`--global\`, \`--local\` are deprecated. Use \`--location=global\` instead. - `, description: ` Operates in "global" mode, so that packages are installed into the \`prefix\` folder instead of the current working directory. See 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 d67f3e6fe0bd7..33d6e4fb7a00f 100644 --- a/tap-snapshots/test/lib/utils/config/definitions.js.test.cjs +++ b/tap-snapshots/test/lib/utils/config/definitions.js.test.cjs @@ -733,8 +733,6 @@ exports[`test/lib/utils/config/definitions.js TAP > config description for globa * Default: false * Type: Boolean -* DEPRECATED: \`--global\`, \`--local\` are deprecated. Use \`--location=global\` - instead. Operates in "global" mode, so that packages are installed into the \`prefix\` folder instead of the current working directory. See 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 853e758dcd600..77f2c876841ed 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 @@ -560,6 +560,23 @@ 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\` + + + + #### \`global-style\` * Default: false @@ -1808,25 +1825,6 @@ Alias for \`--include=dev\`. -#### \`global\` - -* Default: false -* Type: Boolean -* DEPRECATED: \`--global\`, \`--local\` are deprecated. Use \`--location=global\` - instead. - -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\` - - - - #### \`init.author.email\` * Default: ""