diff options
author | Peter Collingbourne <peter@pcc.me.uk> | 2011-10-03 03:02:11 (GMT) |
---|---|---|
committer | Peter Collingbourne <peter@pcc.me.uk> | 2011-11-04 19:10:31 (GMT) |
commit | 4836a864667df3a8c1dd90bb9db7571c6a91e4dc (patch) | |
tree | e31a16b42f2607395c429b5e35f9d3fed243412a /doc | |
parent | 801377e0651d35a8f006ea3722a44f52cfe787bf (diff) | |
download | Ninja-4836a864667df3a8c1dd90bb9db7571c6a91e4dc.zip Ninja-4836a864667df3a8c1dd90bb9db7571c6a91e4dc.tar.gz Ninja-4836a864667df3a8c1dd90bb9db7571c6a91e4dc.tar.bz2 |
Add a "commands" tool
This tool performs a post-order traversal of the build graph, starting
from a list of targets specified on the command line, and for each
build statement encountered, prints the evaluated command line.
Use cases include:
- Generating input for a tool which needs to know the full command line
for every command invoked during a build. Many static analysis
and indexing tools require this information.
- Generating a build script which does not depend on Ninja.
For example, such a script could be used by Ninja to bootstrap
itself.
Diffstat (limited to 'doc')
-rw-r--r-- | doc/manual.asciidoc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/doc/manual.asciidoc b/doc/manual.asciidoc index d59f471..bc15a1f 100644 --- a/doc/manual.asciidoc +++ b/doc/manual.asciidoc @@ -382,6 +382,10 @@ than the _depth_ mode. It returns non-zero if an error occurs. one. It can be used to know which rule name to pass to +ninja -t targets rule _name_+. +`commands`:: given a list of targets, print a list of commands which, if +executed in order, may be used to rebuild those targets, assuming that all +output files are out of date. + `clean`:: remove built files. If used like this +ninja -t clean+ it removes all the built files, except for those created by the generator. If used like this +ninja -t clean -g+ it also removes built files created by the |