mirror of
https://github.com/pnpm/pnpm.git
synced 2026-01-08 15:08:27 -05:00
feat: print an info message about dependencies that were not built (#7854)
close #7815
This commit is contained in:
6
.changeset/brave-sheep-dress.md
Normal file
6
.changeset/brave-sheep-dress.md
Normal file
@@ -0,0 +1,6 @@
|
||||
---
|
||||
"@pnpm/build-modules": minor
|
||||
"pnpm": minor
|
||||
---
|
||||
|
||||
Print an info message about dependencies that were not built [#7815](https://github.com/pnpm/pnpm/issues/7815).
|
||||
@@ -56,7 +56,14 @@ export async function buildModules (
|
||||
warn,
|
||||
}
|
||||
const chunks = buildSequence(depGraph, rootDepPaths)
|
||||
const allowBuild = opts.allowBuild ?? (() => true)
|
||||
const ignoredPkgs = new Set<string>()
|
||||
const allowBuild = opts.allowBuild
|
||||
? (pkgName: string) => {
|
||||
if (opts.allowBuild!(pkgName)) return true
|
||||
ignoredPkgs.add(pkgName)
|
||||
return false
|
||||
}
|
||||
: () => true
|
||||
const groups = chunks.map((chunk) => {
|
||||
chunk = chunk.filter((depPath) => {
|
||||
const node = depGraph[depPath]
|
||||
@@ -76,6 +83,10 @@ export async function buildModules (
|
||||
)
|
||||
})
|
||||
await runGroups(opts.childConcurrency ?? 4, groups)
|
||||
logger.info({
|
||||
message: `The following dependencies have build scripts that were ignored: ${Array.from(ignoredPkgs).sort().join(', ')}`,
|
||||
prefix: opts.lockfileDir,
|
||||
})
|
||||
}
|
||||
|
||||
async function buildDependency (
|
||||
|
||||
Reference in New Issue
Block a user