Choose an appropriate python version for x.py at runtime#80585
Closed
jyn514 wants to merge 1 commit intorust-lang:masterfrom
Closed
Choose an appropriate python version for x.py at runtime#80585jyn514 wants to merge 1 commit intorust-lang:masterfrom
jyn514 wants to merge 1 commit intorust-lang:masterfrom
Conversation
8e77d03 to
b60bf06
Compare
Member
Author
|
I found that this breaks on CentOS because it doesn't have |
- Default to python3 -> python -> python2 - Start as shell script and re-execute the program with the right python interpreter
b60bf06 to
47980db
Compare
Member
Author
|
This breaks in Powershell (probably cmd.exe too, but I don't know how to install that on linux): |
Member
Author
|
It looks like servo handles this by having a separate |
Member
|
Are you sure this isn't missing a shebang for shell of some sort? Running |
Member
Author
|
@nagisa most shells will execute files as scripts if they don't have a shebang, what shell are you using? That said, if this doesn't work even on linux, it's probably not worth pursuing. |
Member
|
I use |
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Jan 15, 2021
…ulacrum Choose the version of python at runtime (portable version) r? `@Mark-Simulacrum` Fixed version of rust-lang#80585. The goal is to avoid giving 'error: python3 required' when downloading LLVM from CI and instead default to python3 where possible. This has some minor overhead when you have `python` as python2, but almost nothing compared to actually running the build.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Or, how I learned to stop worrying and love the shell.
x.pyas a shell script and re-execute the program with the right python interpreterCloses #71818.
r? @Mark-Simulacrum