Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Unified Diff: tools/gn/command_help.cc

Issue 2504133003: Add more gn documentation (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tools/gn/docs/language.md » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/command_help.cc
diff --git a/tools/gn/command_help.cc b/tools/gn/command_help.cc
index b8e17e0b169aa79e58e4eb97d0870763ee6f4ab4..045034473e0bf7b59b848f300248f31e83576d75 100644
--- a/tools/gn/command_help.cc
+++ b/tools/gn/command_help.cc
@@ -11,7 +11,9 @@
#include "tools/gn/err.h"
#include "tools/gn/functions.h"
#include "tools/gn/input_conversion.h"
+#include "tools/gn/label.h"
#include "tools/gn/label_pattern.h"
+#include "tools/gn/ninja_build_writer.h"
#include "tools/gn/parser.h"
#include "tools/gn/runtime_deps.h"
#include "tools/gn/setup.h"
@@ -19,6 +21,7 @@
#include "tools/gn/string_utils.h"
#include "tools/gn/substitution_writer.h"
#include "tools/gn/switches.h"
+#include "tools/gn/target.h"
#include "tools/gn/variables.h"
namespace commands {
@@ -62,10 +65,13 @@ void PrintToplevelHelp() {
PrintShortHelp("all: Print all the help at once");
PrintShortHelp("buildargs: How build arguments work.");
PrintShortHelp("dotfile: Info about the toplevel .gn file.");
+ PrintShortHelp("execution: Build graph and execution overview.");
PrintShortHelp("grammar: Language and grammar for GN build files.");
PrintShortHelp(
"input_conversion: Processing input from exec_script and read_file.");
PrintShortHelp("label_pattern: Matching more than one label.");
+ PrintShortHelp("labels: About labels.");
+ PrintShortHelp("ninja_rules: How Ninja build rules and named.");
PrintShortHelp("nogncheck: Annotating includes for checking.");
PrintShortHelp("runtime_deps: How runtime dependency computation works.");
PrintShortHelp("source_expansion: Map sources to outputs for scripts.");
@@ -124,9 +130,12 @@ void PrintAllHelp() {
PrintLongHelp(kBuildArgs_Help);
PrintLongHelp(kDotfile_Help);
+ PrintLongHelp(kExecution_Help);
PrintLongHelp(kGrammar_Help);
PrintLongHelp(kInputConversion_Help);
PrintLongHelp(kLabelPattern_Help);
+ PrintLongHelp(kLabels_Help);
+ PrintLongHelp(kNinjaRules_Help);
PrintLongHelp(kNoGnCheck_Help);
PrintLongHelp(kRuntimeDeps_Help);
PrintLongHelp(kSourceExpansion_Help);
@@ -240,6 +249,7 @@ int RunHelp(const std::vector<std::string>& args) {
// Random other topics.
std::map<std::string, void(*)()> random_topics;
random_topics["all"] = PrintAllHelp;
+ random_topics["execution"] = []() { PrintLongHelp(kExecution_Help); };
random_topics["buildargs"] = []() { PrintLongHelp(kBuildArgs_Help); };
random_topics["dotfile"] = []() { PrintLongHelp(kDotfile_Help); };
random_topics["grammar"] = []() { PrintLongHelp(kGrammar_Help); };
@@ -247,6 +257,8 @@ int RunHelp(const std::vector<std::string>& args) {
PrintLongHelp(kInputConversion_Help);
};
random_topics["label_pattern"] = []() { PrintLongHelp(kLabelPattern_Help); };
+ random_topics["labels"] = []() { PrintLongHelp(kLabels_Help); };
+ random_topics["ninja_rules"] = []() { PrintLongHelp(kNinjaRules_Help); };
random_topics["nogncheck"] = []() { PrintLongHelp(kNoGnCheck_Help); };
random_topics["runtime_deps"] = []() { PrintLongHelp(kRuntimeDeps_Help); };
random_topics["source_expansion"] = []() {
« no previous file with comments | « no previous file | tools/gn/docs/language.md » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698