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

fix is_juliaup_installed for invalid path #880

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions src/bin/juliainstaller.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,10 @@ fn is_juliaup_installed() -> bool {
.stdin(Stdio::null())
.status();

exit_status.is_ok()
match exit_status {
Ok(status) => status.success(),
Err(_) => false, // failed to execute `juliaup` command
}
}

#[derive(Parser)]
Expand Down Expand Up @@ -286,7 +289,8 @@ pub fn main() -> Result<()> {

if paths.juliaupconfig.exists() {
println!("While Juliaup does not seem to be installed on this system, there is a");
println!("Juliaup configuration file present from a previous installation.");
println!("Juliaup configuration file present from a previous installation:");
println!("{}", paths.juliaupconfig.display());

if args.disable_confirmation_prompt {
println!();
Expand Down