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

Unified Diff: tools/gn/command_help.cc

Issue 1015063003: tools/gn: add "gn help grammar" with formal grammar (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 months 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/parser.h » ('j') | tools/gn/parser.cc » ('J')
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 0f8c34790a7d593dff32f67014c13b532fbdc3a9..8c070c9c0bde012e97be364751c44bdfd6ece9bf 100644
--- a/tools/gn/command_help.cc
+++ b/tools/gn/command_help.cc
@@ -12,6 +12,7 @@
#include "tools/gn/functions.h"
#include "tools/gn/input_conversion.h"
#include "tools/gn/label_pattern.h"
+#include "tools/gn/parser.h"
#include "tools/gn/setup.h"
#include "tools/gn/standard_out.h"
#include "tools/gn/substitution_writer.h"
@@ -62,6 +63,7 @@ void PrintToplevelHelp() {
PrintShortHelp(
"input_conversion: Processing input from exec_script and read_file.");
PrintShortHelp("source_expansion: Map sources to outputs for scripts.");
+ PrintShortHelp("syntax: Formal syntax for GN build files.");
PrintShortHelp("switches: Show available command-line switches.");
}
@@ -181,6 +183,10 @@ int RunHelp(const std::vector<std::string>& args) {
PrintLongHelp(kSourceExpansion_Help);
return 0;
}
+ if (what == "syntax") {
+ PrintLongHelp(kSyntax_Help);
+ return 0;
+ }
if (what == "switches") {
PrintSwitchHelp();
return 0;
« no previous file with comments | « no previous file | tools/gn/parser.h » ('j') | tools/gn/parser.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698