@@ 7,14 7,12 @@ mod options;
mod revlogs;
fn main() {
- match options::Rug::from_args() {
- options::Rug::Log {} => match commands::hg_log() {
- Ok(_) => {}
- Err(e) => println!("{}", e),
- },
- options::Rug::Status {} => match commands::hg_status() {
- Ok(_) => {}
- Err(e) => println!("{}", e),
- },
+ let res = match options::Rug::from_args() {
+ options::Rug::Log {} => commands::hg_log(),
+ options::Rug::Status {} => commands::hg_status(),
+ };
+ match res {
+ Ok(_) => {}
+ Err(e) => println!("{}", e),
}
}