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

Consider the interaction of the [env] table with Cargo's own environment #11589

Open
ehuss opened this issue Jan 17, 2023 · 0 comments
Open

Consider the interaction of the [env] table with Cargo's own environment #11589

ehuss opened this issue Jan 17, 2023 · 0 comments
Labels
A-configuration Area: cargo config files and env vars A-environment-variables Area: environment variables S-triage Status: This issue is waiting on initial triage.

Comments

@ehuss
Copy link
Contributor

ehuss commented Jan 17, 2023

Currently Cargo does not inspect the [env] config table for its own environment variables. This may have been an oversight and it is not clear exactly how to proceed from here. A few options:

  • Merge the [env] table into Cargo's environment snapshot, and make cargo honor most of the environment variables.
    • There are some environment variables with subtle complexities like CARGO_HOME and PATH.
  • Deny (or issue a warning) if you attempt to set one of Cargo's environment variables in the [env] table.
    • Unfortunately this will be challenging, and a breaking change. There are some users already setting environment variables that start with CARGO_ for their own purpose. Also, those environment variables will apply to recursive cargo invocations.

Related issues:

@ehuss ehuss added A-configuration Area: cargo config files and env vars A-environment-variables Area: environment variables labels Jan 17, 2023
@epage epage added the S-triage Status: This issue is waiting on initial triage. label Nov 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-configuration Area: cargo config files and env vars A-environment-variables Area: environment variables S-triage Status: This issue is waiting on initial triage.
Projects
None yet
Development

No branches or pull requests

2 participants