boltpkg / bolt

⚡️ Super-powered JavaScript project management
MIT License
2.34k stars 84 forks source link

Install published packages instead of linking #305

Closed steve-taylor closed 2 years ago

steve-taylor commented 2 years ago
Title Description
Version 0.24.9
Type Feature request
node 14.17.5
Operating System macOS 11.4
Short Description Link to published packages to avoid rebuilding the entire monorepo in CI/CD
Detailed description Suppose I have a bolt monorepo with packages @acme/a, @acme/b, @acme/c and @acme/d. I make a change to only @acme/a and create a pull request. Although @acme/a depends on @acme/b, which depends on @acme/c, I want the CI pipeline to build only @acme/a and install @acme/b and @acme/c from the registry as they are already published. This isn't such a big deal for a monorepo with four packages, but I expect to have tens of packages, if not hundreds, with multiple pull requests per day, almost entirely single-package changes only. I haven't found a way to make bolt do this, so it seems this is a feature request.

NOTE: I'm not asking how I can detect which packages have changed. That's easily done. What I want to be able to do is to treat internal packages that are depended on, but not changed, as external packages, instalable from their npm registry so they don't need to be unnecessarily rebuilt.

steve-taylor commented 2 years ago

After rethinking this and understanding monorepos a bit better, I don't think this is a good idea.