Skip to content

Commit

Permalink
use -f for input file, matching make
Browse files Browse the repository at this point in the history
  • Loading branch information
evmar committed Feb 5, 2011
1 parent e5cf693 commit 4caf59a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion misc/long-slow-build.ninja
Original file line number Diff line number Diff line change
@@ -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
Expand Down
6 changes: 3 additions & 3 deletions src/ninja.cc
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down Expand Up @@ -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':
Expand Down

0 comments on commit 4caf59a

Please sign in to comment.