From 6fc35de5e88bb4035fa2a2be28b09d01fc8ebd53 Mon Sep 17 00:00:00 2001 From: Michal 'vorner' Vaner Date: Sun, 27 Aug 2017 19:20:03 +0200 Subject: [PATCH] Fail ./x.py on invalid command Make the ./x.py script fail when run with an invalid command, like: ./x.py nonsense This helps in case of chaining multiple runs, eg.: ./x.py biuld && ./x.py test --- src/bootstrap/flags.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bootstrap/flags.rs b/src/bootstrap/flags.rs index a84d43d3deede..7546d7fd4f07a 100644 --- a/src/bootstrap/flags.rs +++ b/src/bootstrap/flags.rs @@ -136,7 +136,7 @@ To learn more about a subcommand, run `./x.py -h`"); None => { // No subcommand -- show the general usage and subcommand help println!("{}\n", subcommand_help); - process::exit(0); + process::exit(1); } };