19 ms·
Just trying to understand... so we would have ~5 (going by my original example figure) Bazel builds and then use "imports of published things" to have projects
by Quekid5 7y ago
Just trying to understand... so we would have ~5 (going by my original example figure) Bazel builds and then use "imports of published things" to have projects that depend on each other work?
- lhorie 7y agoYou would have 5 workspaces. How they work together is sort of up to you. If you use `local_repository`, then you can link whatever's checked out from version control together. This can be dangerous since there's nothing that enforces what version of what works with what, but it's helpful for example, if you want to beta test a new version of a ruleset in a workspace that consumes it. If you want to be strict about publishing artifacts and versioning, then `http_archive` is the way to go. You can choose your publishing schedule and other workspaces can independently manage which versions of the published artifacts they want to use. `git_repository` is a middle ground if you don't want the hassle of publishing versioned artifacts, since it lets each workspace reference specific commit SHAs for the things they import.
- Quekid5 7y agoThanks. Things may have changed since the last time I investigated Bazel -- I'll read up on this stuff. I'm actually currently leaning towards something like Nix or Guix just because it really encompasses everything...
- lalaithion 7y agoNix is good for inter-package dependencies, while Bazel is good for internal dependencies. You could use Bazel to build your packages for Nix, and import your other projects into your BUILD files with https://github.com/tweag/rules_nixpkgs https://github.com/tweag/rules_nixpkgs.