diff --git a/src/postinstall.js b/src/postinstall.js index bf2decb3..b3650b1a 100644 --- a/src/postinstall.js +++ b/src/postinstall.js @@ -38,7 +38,9 @@ async function warmNpmCache() { } try { - await shExec(`npm cache add ${toCache.join(' ')}`); + for await (const pkgWithVersion of toCache) { + await shExec(`npm cache add ${pkgWithVersion}`); + } console.log(' Done.'); } catch (err) { console.error(err);