-
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
Tracking Issue for -Z configurable-env #9539
Comments
Is there a discussion about this occurring in some other other place? |
I don't think so. Feel free to discuss it here or on Zulip or internals. The boilerplate in the issue is just meant to keep the noise down so that people following the issue only get relevant updates, but I doubt there are too many people following here (esp since it was just opened). |
This is still not available by setting |
It will have a |
Sorry, I misunderstood how |
Does adding [unstable]
configurable-env = true to a |
Don't allow config env to modify vars set by cargo This changes how the `[env]` variables are applied. They will no longer replace any variables that are being set by cargo itself, whether or not the `force` flag is set. The `force` flag still determines whether existing variables from the environment can be overridden or not. Addresses unresolved issue in #9539
Any opinions on expanding an environment variable? For example: [env]
FOO = "$BAR/xyz"
PATH = "/opt/foobar/bin:$PATH" |
Another consideration here is whether it should be possible to set the environment variables differently during build and execution. For example, it seems reasonable to allow using a different |
This should presumably be closed since this feature was stabilized in Rust 1.56? I guess there was never an answer to the unresolved question around interaction with envvars that Cargo sets itself? |
I'd also like to propose another (minor?) missing part of the current design: the ability to unset an environment variable. The current design would only let you set a variables value to |
Yea, thanks for the ping. Going ahead and closing since this was stabilized in #9411. If you want to extend it to support unsetting, that is probably OK. I can imagine an |
Summary
Original issue: #4121
Implementation: #9175
Documentation: https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#configurable-env
The
-Z configurable-env
option enables reading the[env]
table from config which will set the specified environment variables.Unresolved issues
fill_env
like build-script env vars).About tracking issues
Tracking issues are used to record the overall progress of implementation.
They are also used as hubs connecting to other relevant issues, e.g., bugs or open design questions.
A tracking issue is however not meant for large scale discussion, questions, or bug reports about a feature.
Instead, open a dedicated issue for the specific matter and add the relevant feature gate label.
The text was updated successfully, but these errors were encountered: