mirror of
https://github.com/pnpm/pnpm.git
synced 2026-04-10 18:18:56 -04:00
fix: keep the ignoredBuilds field when installing different pkg (#9242)
* fix: keep the `ignoredBuilds` field when installing different dependencies * fix: print warning about ignored builds --------- close #9240 Co-authored-by: Zoltan Kochan <z@kochan.io>
This commit is contained in:
6
.changeset/fruity-corners-dance.md
Normal file
6
.changeset/fruity-corners-dance.md
Normal file
@@ -0,0 +1,6 @@
|
||||
---
|
||||
"@pnpm/core": patch
|
||||
pnpm: patch
|
||||
---
|
||||
|
||||
When installing different dependency packages, should retain the `ignoredBuilds` field in the `.modules.yaml` file [#9240](https://github.com/pnpm/pnpm/issues/9240).
|
||||
@@ -10,6 +10,7 @@ import {
|
||||
WANTED_LOCKFILE,
|
||||
} from '@pnpm/constants'
|
||||
import {
|
||||
ignoredScriptsLogger,
|
||||
stageLogger,
|
||||
summaryLogger,
|
||||
} from '@pnpm/core-loggers'
|
||||
@@ -1224,6 +1225,10 @@ const _installInContext: InstallFunction = async (projects, ctx, opts) => {
|
||||
unsafePerm: opts.unsafePerm,
|
||||
userAgent: opts.userAgent,
|
||||
})).ignoredBuilds
|
||||
if (ignoredBuilds == null && ctx.modulesFile?.ignoredBuilds?.length) {
|
||||
ignoredBuilds = ctx.modulesFile.ignoredBuilds
|
||||
ignoredScriptsLogger.debug({ packageNames: ignoredBuilds })
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user