sb2nov / mac-setup

Installing Development environment on macOS
https://sourabhbajaj.com/mac-setup/
Other
7.18k stars 1.02k forks source link

Use yarn over npm for speed #209

Closed simeg closed 6 years ago

hugovk commented 6 years ago

Is it worth it on Travis CI too?

It takes ~35s to npm install.

https://travis-ci.org/sb2nov/mac-setup/builds/381817378#L448

simeg commented 6 years ago

Good idea, added it!

EDIT: Using yarn over npm on travis saved us ~0.5s (on a cold run). Not sure how travis deals with caching.

sb2nov commented 6 years ago

Thanks.

hugovk commented 6 years ago

See https://blog.travis-ci.com/2016-11-21-travis-ci-now-supports-yarn for caching.

Kyslik commented 6 years ago

@simeg isn't it slower because of security audit?

simeg commented 6 years ago

@Kyslik Do you mean that npm is slower because of security audit? You mean npm audit? Not sure if that's being run during the CI process.

I enabled caching, it should speed the build time up. It now takes 8 seconds to install dependencies on Travis! 🎉

Kyslik commented 6 years ago

@simeg yea, for example https://travis-ci.org/sb2nov/mac-setup/builds/381817378#L458, but now its irrelevant since we are on yarn.

simeg commented 6 years ago

@Kyslik Ah, didn't know npm install automatically did an audit every time it installed.