-
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 config-cli #7722
Comments
A use case for this: docs.rs wants to pass |
Is it not possible to specify registry sources via this? I wanted to migrate from using > cargo -Zunstable-options '--config=source.bs58_cli_0_1_0_anyhow.registry="http://127.0.0.1:8080/ifps/QmP6KmpjQrYpYyeXGqAvmrw45dPoKvmKeTqTanmSqJGJKz"' '--config=source.bs58_cli_0_1_0_bs58.registry="http://127.0.0.1:8080/ifps/Qmb2PJ9vMALRFmQjLDQbcNHYUvcFc96XzKMwAhBMEECxzb"' '--config=source.bs58_cli_0_1_0_paw.registry="http://127.0.0.1:8080/ifps/QmNkJbrmpjJErbX9fTpSSQYb7Ky1Qnpg47QptfMcVQUwBx"' '--config=source.bs58_cli_0_1_0_structopt.registry="http://127.0.0.1:8080/ifps/Qmbh5sZbKezvYq2ESVhbnymqs7VKMTaz7yXUaoMi9tBjJp"' update --manifest-path /tmp/ipfs-registry.bs58-cli-0.1.0.yIgXKp/bs58-cli-0.1.0/Cargo.toml
error: failed to parse manifest at `/tmp/ipfs-registry.bs58-cli-0.1.0.yIgXKp/bs58-cli-0.1.0/Cargo.toml`
Caused by:
no index found for registry: `bs58_cli_0_1_0_anyhow` |
🤦 ignore that, I was using the wrong config key. |
Curious if there's any updated status on this? It would be really great to get stabilized! |
There's no update. There's still an unresolved issue noted above that needs someone to work on it. |
I'll add what I think is a pretty compelling use-case for this: passing For the unresolved issue, some guidance on exactly what you're imagining would be helpful @ehuss. Specifically, why do you think that restriction is necessary in the first place? Alternatively, could we just parse into a |
The restriction is to just constrain the format so that it has a straightforward syntax. That way, someone wouldn't be able to pass in comments or |
👍 |
This addresses the remaining unresolved issue for `config-cli` (rust-lang#7722).
Check --config for dotted keys only This addresses the remaining unresolved issue for `config-cli` (#7722).
Now that #10176 has been merged, I think the unchecked box can be ticked! |
What are the plans for stabilising those features? My use case is using vendored dependencies on CI (while using "live" dependencies locally). Configuring this through an extra argument to cargo commands with This becomes even more powerful, when I realised |
@ehuss Gentle nudge on this. |
Ah, sorry for the confusion. I was expecting you or someone to post a stabilization PR. Perhaps you were expecting an FCP first. I'll go ahead and kick that off. @rfcbot fcp merge @rust-lang/cargo This is a proposal to stabilize the I'll also propose that this also include the ability to pass @jonhoo or whoever wants to stabilize this, the general steps for stabilizing something is outlined in https://doc.crates.io/contrib/process/unstable.html#stabilization. To support |
Team member @ehuss has proposed to merge this. The next step is review by the rest of the tagged team members: Concerns:
Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up! See this document for info about what commands tagged team members can give me. |
The final comment period, with a disposition to merge, as per the review above, is now complete. As the automated representative of the governance process, I would like to thank the author for their work and everyone else who contributed. This will be merged soon. |
@ehuss Do you want me to send a stabilization PR for this? |
Yes, please! |
Vroom vroom: #10755 |
Stabilize config-cli This stabilizes the `--config` CLI argument as per [this FCP](#7722 (comment)). It also makes the adjustment [suggested by `@ehuss](https://github.com/rust-lang/cargo/issues/7722#issuecomment-1098612205)` to allow stabilizing `--config path` without _also_ stabilizing [`config-include`](https://doc.rust-lang.org/cargo/reference/unstable.html#config-include). I took a guess that this would land in 1.63 and put that in the tombstone entry in the unstable docs, but let me know if that's likely to be wrong. Closes #7722. Also, I think this should probably be tagged `relnotes`.
As per the concern `restricted-values` in rust-lang#7722 (comment).
As per the concern `restricted-values` in rust-lang#7722 (comment).
Implementation: #7649
Original proposal: #6699
Documentation: https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#config-cli
Summary
Adds
--config
CLI option to pass config options to any command.Unresolved issues
KEY=VALUE
. Will need updates to the toml crate to make that possible. DONE: Check --config for dotted keys only #10176--config PATH
work has a shorthand for `--config 'include="path"' DONE: Support--config path_to_config.toml
cli syntax. #7901The text was updated successfully, but these errors were encountered: