Performance issues
Closed this issue · 6 comments
simonwep commented
It takes a really long time to upgrade each package in particular. It would be a lot faster if you use the npm-api to fetch the versions, replace these in the package.json
and run yarn
after it.
vesper8 commented
agree with the above.. currently it takes forever, I just ran it on one of my projects and it took over an hour!
elderapo commented
I don't think it's necessary to remove packages before updating them. yarn add pkg-1 pkg-2 pkg-3 ...
should be enough.
const packageJson = require("./package.json");
const { execSync } = require("child_process");
const allDeps = {
...packageJson.devDependencies,
...packageJson.dependencies
};
const allDepsNames = Object.keys(allDeps);
execSync(`yarn add ${allDepsNames.join(" ")}`);
lropero commented
If you want same results but fast, try upgradeps which does parallel version querying for all packages before updating.
Disclaimer: I've built it.
lropero commented
..happens :)
tylerlong commented
The issue has been discussed here: #2 (comment)