2 ms·
I'm not certain, just learning it. You might find this blog post that does a code review of ripgrep interesting, though. It's a deep dive into a serious-scale c
by iudqnolq 7y ago
I'm not certain, just learning it. You might find this blog post that does a code review of ripgrep interesting, though. It's a deep dive into a serious-scale cli tool.
https://web.archive.org/web/20190401042439/http://blog.mbrt.it/2016-12-01-ripgrep-code-review/ https://web.archive.org/web/20190401042439/http://blog.mbrt....
Here's what the main function looks like:
fn main() {
match Args::parse().and_then(run) {
Ok(count) if count == 0 => process::exit(1),
Ok(_) => process::exit(0),
Err(err) => {
eprintln!("{}", err);
process::exit(1);
}
}
}