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

Add .toml file extension restriction for -Zconfig-include #12298

Merged
merged 3 commits into from
Jun 21, 2023

Conversation

weihanglo
Copy link
Member

What does this PR try to resolve?

During yesterday's Cargo meeting, we decide to have a restriction to .toml extensions on the file name for -Zconfig-include. Thus it will be less likely to collide with what the user specified in .cargo/ directory.

This also included a unstable doc update and a tests to verify what has been written in the doc.

How should we test and review this PR?

By commit. Most tests are touched because they need to comply with the .toml restriction.

Additional information

Part of #7723

This is to avoid possible name collisions. For example, a user
creates a file called `.cargo/cache`, and then in the future
cargo wants to create a directory called `.cargo/cache/`, that
would collide with what the user specified. Restricting to `.toml`
extensions would avoid that since we won’t make a directory named
with a `.toml` extension.
@rustbot
Copy link
Collaborator

rustbot commented Jun 21, 2023

r? @epage

(rustbot has picked a reviewer for you, use r? to override)

@rustbot rustbot added A-configuration Area: cargo config files and env vars A-documenting-cargo-itself Area: Cargo's documentation S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 21, 2023
@epage
Copy link
Contributor

epage commented Jun 21, 2023

@bors r+

@bors
Copy link
Collaborator

bors commented Jun 21, 2023

📌 Commit 26b7725 has been approved by epage

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 21, 2023
@bors
Copy link
Collaborator

bors commented Jun 21, 2023

⌛ Testing commit 26b7725 with merge 465a9ff...

bors added a commit that referenced this pull request Jun 21, 2023
Add `.toml` file extension restriction for `-Zconfig-include`
@bors
Copy link
Collaborator

bors commented Jun 21, 2023

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Jun 21, 2023
@weihanglo
Copy link
Member Author

weihanglo commented Jun 21, 2023

#11334 (comment) (due to coarse mtime on macOS)?

@bors retry

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 21, 2023
@bors
Copy link
Collaborator

bors commented Jun 21, 2023

⌛ Testing commit 26b7725 with merge 05cd14e...

@bors
Copy link
Collaborator

bors commented Jun 21, 2023

☀️ Test successful - checks-actions
Approved by: epage
Pushing 05cd14e to master...

@bors bors merged commit 05cd14e into rust-lang:master Jun 21, 2023
18 checks passed
@weihanglo weihanglo deleted the config-include-toml branch June 21, 2023 22:45
compiler-errors added a commit to compiler-errors/rust that referenced this pull request Jun 24, 2023
Update cargo

8 commits in 4cebd130ebca3bc219180a54f3e26cc1b14a91de..03bc66b55c290324bd46eb22e369c8fae1908f91
2023-06-21 18:59:29 +0000 to 2023-06-23 23:27:46 +0000
- fix(script): Be quiet on programmatic output (rust-lang/cargo#12305)
- docs(unstable): Update script documentation (rust-lang/cargo#12308)
- cargo script example needs nightly -Zscript feature (rust-lang/cargo#12287)
- fix(script): Process config relative to script, not CWD (rust-lang/cargo#12303)
- -Znext-lockfile-bump: Don't suggest using -Z on stable (rust-lang/cargo#12302)
- build(deps): bump openssl from 0.10.54 to 0.10.55 (rust-lang/cargo#12300)
- Add `.toml` file extension restriction for `-Zconfig-include` (rust-lang/cargo#12298)
- docs(unstable): Point stable-unstable docs to nightly docs (rust-lang/cargo#12299)

r? `@ghost`
@ehuss ehuss added this to the 1.72.0 milestone Jul 2, 2023
@weihanglo weihanglo added the Z-config-include Nightly: `include` config key label Dec 13, 2023
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-documenting-cargo-itself Area: Cargo's documentation S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. Z-config-include Nightly: `include` config key
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants