-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Who is .cargo/config.toml meant for? #14565
Comments
Whether the file is checked in or not is project dependent. Manifests ( Potentially related to your specific idea, #7723 proposes ways to have additional config files. If we had glob support, then no change would be needed for a user one. I think @weihanglo previously had use cases for sometimes-there-sometimes-not config files and they might have other ideas in that direction. |
The idea sounds pretty much like a use case of optionality of the
Like epage has said, it's pretty project dependent. The doc of the config has mentioned this: "With this structure, you can specify configuration per-package, and even possibly check it into version control. You can also specify personal defaults with a configuration file in your home directory." I'd like to understand what you're looking for in the documentation. Could you provide some suggestions about how to make the doc clearer? |
https://doc.rust-lang.org/cargo/reference/overriding-dependencies.html#paths-overrides suggests that
cargo/config.toml
isn't expected to be included in version control (I mean, why would editing one verion-controlled file be better than editing another?), but I don't see anything like that actually specified on https://doc.rust-lang.org/cargo/reference/config.html.It was hoping to see something along the lines of "
.cargo/config.toml
is intended for local configuration and it's best if you can avoid adding one to version control" , or perhaps an additonal file for user-specific config, in the style of https://learn.microsoft.com/en-us/visualstudio/msbuild/customize-your-local-build?view=vs-2022#user-file, to use for settings that are specific to the user, their machine, or what they are tinkering with at the moment.If
.cargo/config.toml
is actually meant to be shared in version control, then I suppose this is a feature request to add a.cargo/config.local.toml
or.cargo/config.user.toml
to the hierarchy before each.cargo/config.toml
(except$CARGO_HOME/config.toml
, which is clearly supposed to be user-specific already).Otherwise, this is a docs bug.
The text was updated successfully, but these errors were encountered: