-
Notifications
You must be signed in to change notification settings - Fork 760
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
Expose toolchain-preference
as a CLI and configuration file option
#4424
Conversation
6036aa0
to
1efd162
Compare
b7a0df4
to
6bb5c44
Compare
bd14d24
to
c64a2c8
Compare
Should we bikeshed the name? Should it just be |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
As for the name... Is this something that you think will be commonly used on the CLI? If so, I think I'd favor a shorter name. Otherwise, I like the descriptiveness of --toolchain-preference
.
One other possible downside is redundancy here. Namely, --toolchain-preference prefer-system
has "prefer" twice in it, but arguably is just as clear if "prefer" only appeared once. Not quite sure what the right answer is there.
1efd162
to
caf31b0
Compare
c64a2c8
to
7963af4
Compare
Agree, this is a source of discomfort for me but idk it's also very clear. I don't expect this to be used much from the CLI — mostly as a persistent configuration option. |
I'm fine adjusting this later if we need to since it's in preview. |
7963af4
to
a2e6b9c
Compare
I guess another option is I drop the
which is pretty reasonable too? |
I think that's probably okay. I thought of that too, but wondered whether it might leave folks wondering the difference between |
I think `--toolchain-preference system` is sufficiently clear and `--toolchain-preference prefer-system` is excessively verbose. This was discussed in the original pull request at #4424 but because we had a case for preferring "installed managed" toolchains I was hesitant to change it. Now that I've dropped that in #4601, I think we can drop the prefix.
Exposes the option added in #4416. Adds
--toolchain-preference
andtool.uv.toolchain-preference
to configure if system or managed toolchains are preferred. Users can opt-out of managed toolchains or system toolchains entirely as well.