mirror of
https://github.com/pnpm/pnpm.git
synced 2026-04-04 15:24:02 -04:00
6
.changeset/wild-suns-beg.md
Normal file
6
.changeset/wild-suns-beg.md
Normal file
@@ -0,0 +1,6 @@
|
||||
---
|
||||
"@pnpm/modules-cleaner": patch
|
||||
"pnpm": patch
|
||||
---
|
||||
|
||||
Installation should not fail if an empty `node_modules` directory cannot be removed [#7405](https://github.com/pnpm/pnpm/issues/7405).
|
||||
@@ -114,7 +114,12 @@ export async function prune (
|
||||
})
|
||||
}))
|
||||
await Promise.all(Array.from(removedFromScopes).map((scope) => removeIfEmpty(path.join(modulesDir, scope))))
|
||||
await removeIfEmpty(modulesDir)
|
||||
try {
|
||||
await removeIfEmpty(modulesDir)
|
||||
} catch {
|
||||
// On some server setups we might not have permission to remove the node_modules directory.
|
||||
// That's fine, just proceed.
|
||||
}
|
||||
}))
|
||||
|
||||
const selectedImporterIds = importers.map((importer) => importer.id).sort()
|
||||
|
||||
Reference in New Issue
Block a user