From f3fbeea5a173902ca7455c6c94a9e677591b0410 Mon Sep 17 00:00:00 2001 From: Gar Date: Tue, 8 Feb 2022 11:22:29 -0800 Subject: [PATCH] docs: add --save-bundle to --save usage output --- docs/content/using-npm/config.md | 2 +- lib/utils/config/definitions.js | 4 ++-- tap-snapshots/test/lib/load-all-commands.js.test.cjs | 12 ++++++------ .../test/lib/utils/config/definitions.js.test.cjs | 2 +- .../test/lib/utils/config/describe-all.js.test.cjs | 2 +- tap-snapshots/test/lib/utils/npm-usage.js.test.cjs | 12 ++++++------ 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/docs/content/using-npm/config.md b/docs/content/using-npm/config.md index 0af538fed52bc..9fbb614564df8 100644 --- a/docs/content/using-npm/config.md +++ b/docs/content/using-npm/config.md @@ -1351,7 +1351,7 @@ If a package would be saved at install time by the use of `--save`, `--save-dev`, or `--save-optional`, then also put it in the `bundleDependencies` list. -Ignore if `--save-peer` is set, since peerDependencies cannot be bundled. +Ignored if `--save-peer` is set, since peerDependencies cannot be bundled. diff --git a/lib/utils/config/definitions.js b/lib/utils/config/definitions.js index 79222881c9734..93092685ff173 100644 --- a/lib/utils/config/definitions.js +++ b/lib/utils/config/definitions.js @@ -1587,7 +1587,7 @@ define('save', { default: true, defaultDescription: `\`true\` unless when using \`npm update\` or \`npm dedupe\` where it defaults to \`false\``, - usage: '-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer', + usage: '-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle', type: Boolean, short: 'S', description: ` @@ -1610,7 +1610,7 @@ define('save-bundle', { \`--save-dev\`, or \`--save-optional\`, then also put it in the \`bundleDependencies\` list. - Ignore if \`--save-peer\` is set, since peerDependencies cannot be bundled. + Ignored if \`--save-peer\` is set, since peerDependencies cannot be bundled. `, flatten (key, obj, flatOptions) { // XXX update arborist to just ignore it if resulting saveType is peer 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 e7142c2492322..c9da1e23671ea 100644 --- a/tap-snapshots/test/lib/load-all-commands.js.test.cjs +++ b/tap-snapshots/test/lib/load-all-commands.js.test.cjs @@ -170,7 +170,7 @@ npm dedupe Options: [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [--omit [--omit ...]] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] @@ -447,7 +447,7 @@ npm install npm install / Options: -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] [--omit [--omit ...]] [--ignore-scripts] @@ -494,7 +494,7 @@ npm install-test npm install-test / Options: -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] [--omit [--omit ...]] [--ignore-scripts] @@ -517,7 +517,7 @@ npm link (in package dir) npm link [<@scope>/][@] Options: -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] [--omit [--omit ...]] [--ignore-scripts] @@ -1013,7 +1013,7 @@ Usage: npm uninstall [<@scope>/]... Options: -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [-w|--workspace [-w|--workspace ...]] [-ws|--workspaces] [--include-workspace-root] @@ -1063,7 +1063,7 @@ npm update [...] Options: [-g|--global] [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] -[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] +[-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [--omit [--omit ...]] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] 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 ab706be89b835..d75d32d9b74ea 100644 --- a/tap-snapshots/test/lib/utils/config/definitions.js.test.cjs +++ b/tap-snapshots/test/lib/utils/config/definitions.js.test.cjs @@ -1430,7 +1430,7 @@ If a package would be saved at install time by the use of \`--save\`, \`--save-dev\`, or \`--save-optional\`, then also put it in the \`bundleDependencies\` list. -Ignore if \`--save-peer\` is set, since peerDependencies cannot be bundled. +Ignored if \`--save-peer\` is set, since peerDependencies cannot be bundled. ` exports[`test/lib/utils/config/definitions.js TAP > config description for save-dev 1`] = ` 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 58958ebdab954..27b8278fd388e 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 @@ -1225,7 +1225,7 @@ If a package would be saved at install time by the use of \`--save\`, \`--save-dev\`, or \`--save-optional\`, then also put it in the \`bundleDependencies\` list. -Ignore if \`--save-peer\` is set, since peerDependencies cannot be bundled. +Ignored if \`--save-peer\` is set, since peerDependencies cannot be bundled. diff --git a/tap-snapshots/test/lib/utils/npm-usage.js.test.cjs b/tap-snapshots/test/lib/utils/npm-usage.js.test.cjs index ab8f1cf3b4e87..f91f2b11d3533 100644 --- a/tap-snapshots/test/lib/utils/npm-usage.js.test.cjs +++ b/tap-snapshots/test/lib/utils/npm-usage.js.test.cjs @@ -311,7 +311,7 @@ All commands: Options: [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] + [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [--omit [--omit ...]] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]] @@ -556,7 +556,7 @@ All commands: npm install / Options: - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] + [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] [--omit [--omit ...]] [--ignore-scripts] @@ -599,7 +599,7 @@ All commands: npm install-test / Options: - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] + [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] [--omit [--omit ...]] [--ignore-scripts] @@ -620,7 +620,7 @@ All commands: npm link [<@scope>/][@] Options: - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] + [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [-E|--save-exact] [-g|--global] [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] [--omit [--omit ...]] [--ignore-scripts] @@ -1054,7 +1054,7 @@ All commands: npm uninstall [<@scope>/]... Options: - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] + [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [-w|--workspace [-w|--workspace ...]] [-ws|--workspaces] [--include-workspace-root] @@ -1098,7 +1098,7 @@ All commands: Options: [-g|--global] [--global-style] [--legacy-bundling] [--strict-peer-deps] [--no-package-lock] - [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer] + [-S|--save|--no-save|--save-prod|--save-dev|--save-optional|--save-peer|--save-bundle] [--omit [--omit ...]] [--ignore-scripts] [--no-audit] [--no-bin-links] [--no-fund] [--dry-run] [-w|--workspace [-w|--workspace ...]]