Skip to content

Commit

Permalink
fix: fix yarn_install yarn cache mutex bug
Browse files Browse the repository at this point in the history
  • Loading branch information
gregmagolan committed Aug 6, 2019
1 parent 1f902bf commit 31aa1a6
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions internal/npm_install/pre_process_package_json.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,11 @@ function clearYarnFilePathCaches(pkg) {

if (clearPackages.length) {
if (DEBUG) console.error(`Cleaning packages from yarn cache: ${clearPackages.join(' ')}`);

child_process.execFileSync(
'yarn', ['cache', 'clean'].concat(clearPackages),
{stdio: [process.stdin, process.stdout, process.stderr]});
for (const c of clearPackages) {
child_process.execFileSync(
'yarn', ['--mutex', 'network', 'cache', 'clean', c],
{stdio: [process.stdin, process.stdout, process.stderr]});
}
}
}

Expand Down

0 comments on commit 31aa1a6

Please sign in to comment.