diff --git a/docs/content/using-npm/config.md b/docs/content/using-npm/config.md index 4dc2829825d60..df1d996110b31 100644 --- a/docs/content/using-npm/config.md +++ b/docs/content/using-npm/config.md @@ -68,6 +68,7 @@ The following shorthands are parsed on the command-line: * `--desc`: `--description` * `-f`: `--force` * `-g`: `--global` +* `--iwr`: `--include-workspace-root` * `-L`: `--location` * `-d`: `--loglevel info` * `-s`: `--loglevel silent` diff --git a/lib/utils/config/index.js b/lib/utils/config/index.js index d8706d50c612d..b0ad24d7ee12f 100644 --- a/lib/utils/config/index.js +++ b/lib/utils/config/index.js @@ -25,6 +25,7 @@ const shorthands = { porcelain: ['--parseable'], readonly: ['--read-only'], reg: ['--registry'], + iwr: ['--include-workspace-root'], } for (const [key, { short }] of Object.entries(definitions)) { diff --git a/tap-snapshots/test/lib/utils/config/index.js.test.cjs b/tap-snapshots/test/lib/utils/config/index.js.test.cjs index f1cba9264ee2f..78055d5bc720b 100644 --- a/tap-snapshots/test/lib/utils/config/index.js.test.cjs +++ b/tap-snapshots/test/lib/utils/config/index.js.test.cjs @@ -61,6 +61,9 @@ Object { "help": Array [ "--usage", ], + "iwr": Array [ + "--include-workspace-root", + ], "l": Array [ "--long", ],