Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Look at using aliases instead of toolchains #4

Open
keith opened this issue Jan 18, 2022 · 1 comment
Open

Look at using aliases instead of toolchains #4

keith opened this issue Jan 18, 2022 · 1 comment

Comments

@keith
Copy link
Owner

keith commented Jan 18, 2022

The only reason this repo uses toolchains is to avoid downloading multiple versions of buildifier that you'll never use on your platform. It looks like if you use some indirection with a bazel alias in a select() you can avoid this as well. bazelbuild/bazel@903c272

If someone can confirm this is intentional behavior I can switch to this method instead to remove a lot of boilerplate.

@alexeagle
Copy link

My understanding is that select() in an unconfigured build (e.g. bazel query) will follow all the branches, downloading too much.

But in a configured build like bazel cquery or bazel build you only follow the matching branch, so it's as minimal as using toolchains.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants