summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEvan Martin <martine@danga.com>2011-02-05 19:38:36 (GMT)
committerEvan Martin <martine@danga.com>2011-02-05 19:38:36 (GMT)
commit4caf59af8d2b927922c796ac6222b0dbd8bbf182 (patch)
tree8c7f3b5fcd1e7c9d0883c837c57a3fa050b91a01
parente5cf693cdc320576a226e689f0d42350ebde0faf (diff)
downloadNinja-4caf59af8d2b927922c796ac6222b0dbd8bbf182.zip
Ninja-4caf59af8d2b927922c796ac6222b0dbd8bbf182.tar.gz
Ninja-4caf59af8d2b927922c796ac6222b0dbd8bbf182.tar.bz2
use -f for input file, matching make
-rw-r--r--misc/long-slow-build.ninja2
-rw-r--r--src/ninja.cc6
2 files changed, 4 insertions, 4 deletions
diff --git a/misc/long-slow-build.ninja b/misc/long-slow-build.ninja
index 113f1e1..46af6ba 100644
--- a/misc/long-slow-build.ninja
+++ b/misc/long-slow-build.ninja
@@ -1,5 +1,5 @@
# An input file for running a "slow" build.
-# Use like: ninja -i misc/long-slow-build.ninja all
+# Use like: ninja -f misc/long-slow-build.ninja all
rule sleep
command = sleep 1
diff --git a/src/ninja.cc b/src/ninja.cc
index 0547013..39cbfed 100644
--- a/src/ninja.cc
+++ b/src/ninja.cc
@@ -32,7 +32,7 @@ void usage(const BuildConfig& config) {
"usage: ninja [options] target\n"
"\n"
"options:\n"
-" -i FILE specify input build file [default=build.ninja]\n"
+" -f FILE specify input build file [default=build.ninja]\n"
" -j N run N jobs in parallel [default=%d]\n"
" -n dry run (don't run commands but pretend they succeeded)\n"
" -v show all command lines\n"
@@ -144,9 +144,9 @@ int main(int argc, char** argv) {
config.parallelism = GuessParallelism();
int opt;
- while ((opt = getopt_long(argc, argv, "hi:j:nt:v", options, NULL)) != -1) {
+ while ((opt = getopt_long(argc, argv, "f:hj:nt:v", options, NULL)) != -1) {
switch (opt) {
- case 'i':
+ case 'f':
input_file = optarg;
break;
case 'j':