diff options
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main.rs b/src/main.rs index 009fccf..e58188b 100644 --- a/src/main.rs +++ b/src/main.rs @@ -12,14 +12,14 @@ fn main() { let mut args = Args::from_env_and_args(); // If no makefile is specified, try some options. if args.makefile.is_empty() { - if metadata("./makefile").is_ok() { - args.makefile = vec!["./makefile".into()]; + args.makefile = vec![if metadata("./makefile").is_ok() { + "./makefile".into() } else if metadata("./Makefile").is_ok() { - args.makefile = vec!["./Makefile".into()]; + "./Makefile".into() } else { // TODO handle error gracefully panic!("no makefile found"); - } + }]; } // Read in the makefile(s) specified. // TODO dump command-line args into MAKEFLAGS |