mirror of
https://github.com/Noratrieb/cargo-minimize.git
synced 2026-01-14 16:35:01 +01:00
python in bash in rust
This commit is contained in:
parent
ff26987129
commit
f84cfd935b
2 changed files with 94 additions and 17 deletions
|
|
@ -6,10 +6,11 @@ use std::sync::{
|
|||
Arc,
|
||||
};
|
||||
|
||||
use anyhow::Result;
|
||||
use cargo_minimize::{Cargo, Parser};
|
||||
use tracing::{error, Level};
|
||||
|
||||
fn main() {
|
||||
fn main() -> Result<()> {
|
||||
let Cargo::Minimize(options) = Cargo::parse();
|
||||
|
||||
cargo_minimize::init_recommended_tracing_subscriber(Level::INFO);
|
||||
|
|
@ -34,8 +35,5 @@ fn main() {
|
|||
error!("Failed to install CTRL-C handler: {err}");
|
||||
}
|
||||
|
||||
if let Err(err) = cargo_minimize::minimize(options, cancel2) {
|
||||
error!("An error occured:\n{err}");
|
||||
std::process::exit(1);
|
||||
}
|
||||
cargo_minimize::minimize(options, cancel2)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue