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

The cargo reference should mention how to control number of jobs via env #5780

Closed
gnzlbg opened this issue Jul 24, 2018 · 3 comments · Fixed by #7650
Closed

The cargo reference should mention how to control number of jobs via env #5780

gnzlbg opened this issue Jul 24, 2018 · 3 comments · Fixed by #7650
Labels
A-documenting-cargo-itself Area: Cargo's documentation

Comments

@gnzlbg
Copy link
Contributor

gnzlbg commented Jul 24, 2018

The environment variables section of the cargo reference does not mention how to control the number of jobs for cargo via an environment variable. It should.

https://doc.rust-lang.org/cargo/reference/environment-variables.html

@alexcrichton alexcrichton added the A-documenting-cargo-itself Area: Cargo's documentation label Jul 24, 2018
@zachlute
Copy link
Contributor

zachlute commented Sep 8, 2018

There is a link at the bottom of the "Environment Variables Cargo reads" section that states:

Note that Cargo will also read environment variables for .cargo/config configuration values, as described in that documentation

The documentation at that link says:

Cargo can also be configured through environment variables in addition to the TOML syntax above. For each configuration key above of the form foo.bar the environment variable CARGO_FOO_BAR can also be used to define the value. For example the build.jobs key can also be defined by CARGO_BUILD_JOBS.

So I guess the question is, does it make sense to specifically call out things you'd commonly use as "Environment Variables Cargo reads" for more discoverability, or to remain consistent and have all of the config-override variables handled the same?

@gnzlbg
Copy link
Contributor Author

gnzlbg commented Sep 8, 2018

So I guess the question is, does it make sense to specifically call out things you'd commonly use as "Environment Variables Cargo reads" for more discoverability, or to remain consistent and have all of the config-override variables handled the same?

I often end up trying to find documentation in both of these places, and for me it would make sense if the list of environment variable was more "comprehensive" and cross-linked with the configuration keys.

I am not suggesting that these should be generated and kept in sync manually. But maybe it would be good to explore automatically generating a part of the environment variable list from the keys.

@zachlute
Copy link
Contributor

#5690 appears to be asking for essentially the same thing, FWIW. It's clear there could be some improvement in discoverability here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-documenting-cargo-itself Area: Cargo's documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants