mirror of
https://github.com/pnpm/pnpm.git
synced 2026-04-10 18:18:56 -04:00
fix(cli): allow --cache-dir and --save-prefix
This commit is contained in:
5
.changeset/giant-yaks-hear.md
Normal file
5
.changeset/giant-yaks-hear.md
Normal file
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"@pnpm/plugin-commands-installation": patch
|
||||
---
|
||||
|
||||
Add `--save-prefix` and `--cache-dir` to the list of allowed CLI options.
|
||||
@@ -9,6 +9,7 @@ import installDeps from './installDeps'
|
||||
|
||||
export function rcOptionsTypes () {
|
||||
return pick([
|
||||
'cache-dir',
|
||||
'child-concurrency',
|
||||
'engine-strict',
|
||||
'fetch-retries',
|
||||
@@ -47,6 +48,7 @@ export function rcOptionsTypes () {
|
||||
'save-exact',
|
||||
'save-optional',
|
||||
'save-peer',
|
||||
'save-prefix',
|
||||
'save-prod',
|
||||
'save-workspace-protocol',
|
||||
'shamefully-flatten',
|
||||
|
||||
@@ -10,6 +10,7 @@ import installDeps from './installDeps'
|
||||
|
||||
export function rcOptionsTypes () {
|
||||
return pick([
|
||||
'cache-dir',
|
||||
'child-concurrency',
|
||||
'dev',
|
||||
'engine-strict',
|
||||
|
||||
@@ -47,6 +47,7 @@ export function cliOptionsTypes () {
|
||||
'save-dev',
|
||||
'save-exact',
|
||||
'save-optional',
|
||||
'save-prefix',
|
||||
'unsafe-perm',
|
||||
], allTypes)
|
||||
}
|
||||
|
||||
@@ -46,6 +46,7 @@ class RemoveMissingDepsError extends PnpmError {
|
||||
|
||||
export function rcOptionsTypes () {
|
||||
return pick([
|
||||
'cache-dir',
|
||||
'global-dir',
|
||||
'global-pnpmfile',
|
||||
'global',
|
||||
|
||||
@@ -19,6 +19,7 @@ import getUpdateChoices from './getUpdateChoices'
|
||||
|
||||
export function rcOptionsTypes () {
|
||||
return pick([
|
||||
'cache-dir',
|
||||
'depth',
|
||||
'dev',
|
||||
'engine-strict',
|
||||
@@ -53,6 +54,7 @@ export function rcOptionsTypes () {
|
||||
'reporter',
|
||||
'save',
|
||||
'save-exact',
|
||||
'save-prefix',
|
||||
'save-workspace-protocol',
|
||||
'shamefully-flatten',
|
||||
'shamefully-hoist',
|
||||
@@ -272,4 +274,4 @@ function makeIncludeDependenciesFromCLI (opts: {
|
||||
devDependencies: opts.dev === true || (opts.production !== true && opts.optional !== true),
|
||||
optionalDependencies: opts.optional === true || (opts.production !== true && opts.dev !== true),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user