You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
xplr/examples/run.rs

15 lines
344 B
Rust

fn main() {
let pwd = std::path::PathBuf::from("/");
match xplr::run(pwd, None, None) {
Ok(Some(out)) => print!("{}", out),
Ok(None) => {}
Err(err) => {
if !err.to_string().is_empty() {
eprintln!("error: {}", err);
};
std::process::exit(1);
}
}
}