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

cargo script example needs nightly -Zscript feature #12287

Merged
merged 1 commit into from
Jun 23, 2023

Conversation

yerke
Copy link
Contributor

@yerke yerke commented Jun 18, 2023

What does this PR try to resolve?

Update cargo script example. Cargo script currently needs nightly -Zscript feature.
Without this change users will see:

error: running `./cargo_script.rs` requires `-Zscript`

cc #12207

How should we test and review this PR?

I don't think any additional tests are needed. All existing tests for cargo script already use -Zscript.

Additional information

Thanks for designing and implementing cargo script @epage!

@rustbot
Copy link
Collaborator

rustbot commented Jun 18, 2023

r? @epage

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

@rustbot rustbot added A-documenting-cargo-itself Area: Cargo's documentation S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 18, 2023
@weihanglo weihanglo added the Z-script Nightly: cargo script label Jun 19, 2023
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.

We have more discussions on Zulip for this topic. As epage said, shebang is platform dependent. I'll close this at this moment and let's discuss on Zulip. Thank you!

@weihanglo weihanglo closed this Jun 21, 2023
@epage
Copy link
Contributor

epage commented Jun 21, 2023

I was thinking the opposite. It sounds like -S is wider supported than I last looked and if someone is using an unstable feature within busybox, then they are likely the type of user who can find workarounds to their problems

@epage
Copy link
Contributor

epage commented Jun 21, 2023

(this is all within the scope of this being for unstable documentation, not production)

@weihanglo
Copy link
Member

Sounds fair. Let me reopen it.

@weihanglo weihanglo reopened this Jun 21, 2023
@yerke yerke force-pushed the yerke/fix-cargo-script-example branch from ad9ecea to 4fb22dd Compare June 22, 2023 22:15
@yerke
Copy link
Contributor Author

yerke commented Jun 22, 2023

Addressed the comment re -S. Ready for another review.

@epage
Copy link
Contributor

epage commented Jun 23, 2023

@bors r+

@bors
Copy link
Contributor

bors commented Jun 23, 2023

📌 Commit 4fb22dd 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 23, 2023
@bors
Copy link
Contributor

bors commented Jun 23, 2023

⌛ Testing commit 4fb22dd with merge ac78f60...

@bors
Copy link
Contributor

bors commented Jun 23, 2023

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

@bors bors merged commit ac78f60 into rust-lang:master Jun 23, 2023
@yerke yerke deleted the yerke/fix-cargo-script-example branch June 23, 2023 01:26
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
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 S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. Z-script Nightly: cargo script
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants