Skip to content

Commit

Permalink
Merge branch 'main' of github.com:DonIsaac/oxbuild into don/feat/mani…
Browse files Browse the repository at this point in the history
…fest
  • Loading branch information
DonIsaac committed Oct 8, 2024
2 parents 9cf4853 + c874cca commit 3a19eca
Showing 1 changed file with 8 additions and 10 deletions.
18 changes: 8 additions & 10 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ mod reporter;
mod walk;
mod workspace;

use std::{thread, time::Instant};
use std::{process::ExitCode, thread, time::Instant};

extern crate pretty_env_logger;
#[macro_use]
Expand All @@ -20,7 +20,7 @@ use crate::{
};

#[allow(clippy::print_stdout)]
fn main() -> Result<()> {
fn main() -> Result<ExitCode> {
pretty_env_logger::init();
let cli_args = CliOptions::new(cli())?;
let opts = OxbuildOptions::new(cli_args)?;
Expand Down Expand Up @@ -49,14 +49,12 @@ fn main() -> Result<()> {
"Finished in {:2}ms with {num_errors} errors and {num_warnings} warnings using {num_threads} threads.",
duration.as_millis()
);
} else {
println!(
"Finished in {:2}ms using {num_threads} threads.",
duration.as_millis()
);
}
println!(
"Finished in {:2}ms using {num_threads} threads.",
duration.as_millis()
);

if did_fail {
std::process::exit(1);
}
Ok(())
Ok(ExitCode::from(u8::from(did_fail)))
}

0 comments on commit 3a19eca

Please sign in to comment.