folke / ultra-runner

🏃⛰ Ultra fast monorepo script runner and build tool
https://www.npmjs.com/package/ultra-runner
Apache License 2.0
1.2k stars 32 forks source link

Build cache: custom script name and args not taken into account #183

Open fellowseb opened 3 years ago

fellowseb commented 3 years ago

Hi,

First of all thanks for this great tool !

I have one issue though that I think could be really useful fixing : when launching a build with a different set of arguments or another custom build script then the cache system should get invalidated. RushJS for example lists the command line params as one of the four reasons to get a rebuild.

What do you think ?

sprockow commented 2 years ago

I ultimately had a lot of problems with RushJs and pnpm, but I really liked their caching logic. I'm dealing with some problems with Ultra right now where different types of build outputs are treated the same by the cache, which ultimately causes problems...

My only solution is to add rebuild right now to most of my commands, which would remove one of the biggest benefits of using a tool like ultra in the first place.

Alternatively, if this is more complicated than it seems on the surface, can we at least add support for naming our cache files manually? npx ultra -r -b devBuild --cache ultra.dev.cache.json