Skip to content
This repository has been archived by the owner on Nov 22, 2024. It is now read-only.

Commit

Permalink
install plugins dependencies in parallel
Browse files Browse the repository at this point in the history
Reviewed By: LukeDefeo

Differential Revision: D60448300

fbshipit-source-id: de74665981cafaa40d8531857ee67adee41d3a84
  • Loading branch information
antonk52 authored and facebook-github-bot committed Jul 30, 2024
1 parent b9b25e2 commit 1a59aca
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions desktop/plugins/postinstall.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -93,16 +93,19 @@ async function postinstall(): Promise<number> {
}
return 1;
}
console.log("* Installing public plugins' dependencies...");
await exec('yarn install --mutex network:30330', {
cwd: publicPluginsDir,
});
if (await fs.pathExists(fbPluginsDir)) {
console.log("* Installing internal plugins' dependencies...");
await exec('yarn install --mutex network:30330', {
cwd: fbPluginsDir,
});
}
console.log("* Installing plugins' dependencies...");
await Promise.all([
exec('yarn install --mutex network:30330', {
cwd: publicPluginsDir,
}),
fs.pathExists(fbPluginsDir).then((exists) => {
if (exists) {
return exec('yarn install --mutex network:30330', {
cwd: fbPluginsDir,
});
}
}),
]);
const peerDependenciesArray = Object.keys(peerDependencies);
console.log('* Removing peer dependencies from node_modules...');
await Promise.all([
Expand Down

0 comments on commit 1a59aca

Please sign in to comment.