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

feat(cli): Support cargo Cargo.toml #12281

Merged
merged 2 commits into from
Jun 21, 2023
Merged

feat(cli): Support cargo Cargo.toml #12281

merged 2 commits into from
Jun 21, 2023

Conversation

epage
Copy link
Contributor

@epage epage commented Jun 17, 2023

What does this PR try to resolve?

This is making the assumption that we want full unity between places accepting both single-file packages and Cargo.toml for #12207. This has not been brought up before in any of the discussions (Internals, eRFC), so I can understand if there are concerns about this and we decide to hold off.

We might want to resolve symlinks before this so people can have a prettier name for these.

How should we test and review this PR?

The test for this was added in a commit before the actual change, letting people see how the behavior changed.

This wasn't in the original Pre-RFC but in terms of consistently
accepting manifests everything, I think this makes sense.
@rustbot
Copy link
Collaborator

rustbot commented Jun 17, 2023

r? @ehuss

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

@rustbot rustbot added A-cli Area: Command-line interface, option parsing, etc. A-documenting-cargo-itself Area: Cargo's documentation Command-run S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 17, 2023
@epage epage force-pushed the toml branch 4 times, most recently from f11ebdd to 7f2eca4 Compare June 19, 2023 15:47
Copy link
Member

@weihanglo weihanglo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like pretty similar to #12289 but for cargo <script.rs>. I don't have a strong opinion against the feature itself, but I am more curious about how we teach this (and #12289 as well)?

Apart from that, I can merge it as is.

Copy link
Member

@weihanglo weihanglo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's leave teaching discussion then.

I love the consistency between this and #12289. Merge and move on.

Edited: Just want to note that this cargo Cargo.toml can be seen as a shorthand of cargo run --manifest-path Cargo.toml.

@weihanglo
Copy link
Member

@bors r+

@bors
Copy link
Collaborator

bors commented Jun 21, 2023

📌 Commit 7f2eca4 has been approved by weihanglo

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 7f2eca4 with merge 3de1cc4...

@bors
Copy link
Collaborator

bors commented Jun 21, 2023

☀️ Test successful - checks-actions
Approved by: weihanglo
Pushing 3de1cc4 to master...

@bors bors merged commit 3de1cc4 into rust-lang:master Jun 21, 2023
@epage epage deleted the toml branch June 21, 2023 19:38
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Jun 22, 2023
Update cargo

2 commits in dead4b8740c4b6a8ed5211e37c99cf81d01c3b1c..4cebd130ebca3bc219180a54f3e26cc1b14a91de
2023-06-20 20:07:17 +0000 to 2023-06-21 18:59:29 +0000
- fix: Allow embedded manifests in all commands (rust-lang/cargo#12289)
- feat(cli): Support `cargo Cargo.toml` (rust-lang/cargo#12281)

r? `@ghost`
@ehuss ehuss added this to the 1.72.0 milestone Jun 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-cli Area: Command-line interface, option parsing, etc. A-documenting-cargo-itself Area: Cargo's documentation Command-run S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants