Skip to content

Commit

Permalink
Rollup merge of #100020 - CallumIO:issue-99648, r=jyn514
Browse files Browse the repository at this point in the history
better error when python is not found in x - issue #99648

`x` now shows an appropriate error message and exits, when a version of `python` is not found on the users `PATH`.

Resolves #99648
  • Loading branch information
matthiaskrgr committed Aug 1, 2022
2 parents 4606830 + fcf1f95 commit 058ea7a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/tools/x/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@ fn python() -> &'static str {
} else if python2 {
PYTHON2
} else {
// We would have returned early if we found that python is installed ...
// maybe this should panic with an error instead?
PYTHON
// Python was not found on path, so exit
eprintln!("Unable to find python in your PATH. Please check it is installed.");
process::exit(1);
}
}

Expand Down

0 comments on commit 058ea7a

Please sign in to comment.