diff options
3 files changed, 23 insertions, 12 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/query2/CommonQueryOptions.java b/src/main/java/com/google/devtools/build/lib/query2/CommonQueryOptions.java index 027f8e4eb6..a87719f4d2 100644 --- a/src/main/java/com/google/devtools/build/lib/query2/CommonQueryOptions.java +++ b/src/main/java/com/google/devtools/build/lib/query2/CommonQueryOptions.java @@ -32,18 +32,6 @@ import java.util.Set; public class CommonQueryOptions extends OptionsBase { @Option( - name = "output", - defaultValue = "label", - documentationCategory = OptionDocumentationCategory.QUERY, - effectTags = {OptionEffectTag.TERMINAL_OUTPUT}, - help = - "The format in which the query results should be printed. Allowed values for query are: " - + "build, graph, label, label_kind, locations, maxrank, minrank, package, proto, xml." - + "Currently you should never explicitly set this flag for cquery." - ) - public String outputFormat; - - @Option( name = "universe_scope", defaultValue = "", documentationCategory = OptionDocumentationCategory.QUERY, diff --git a/src/main/java/com/google/devtools/build/lib/query2/output/CqueryOptions.java b/src/main/java/com/google/devtools/build/lib/query2/output/CqueryOptions.java index 860e3ca9ae..c12005101a 100644 --- a/src/main/java/com/google/devtools/build/lib/query2/output/CqueryOptions.java +++ b/src/main/java/com/google/devtools/build/lib/query2/output/CqueryOptions.java @@ -37,6 +37,18 @@ public class CqueryOptions extends CommonQueryOptions { } @Option( + name = "output", + defaultValue = "label", + documentationCategory = OptionDocumentationCategory.QUERY, + effectTags = {OptionEffectTag.TERMINAL_OUTPUT}, + help = + "The format in which the cquery results should be printed. Allowed values for cquery " + + "are: label, transitions, proto. If you select 'transitions', you also have to " + + "specify the --transitions=(lite|full) option." + ) + public String outputFormat; + + @Option( name = "transitions", converter = TransitionsConverter.class, defaultValue = "none", diff --git a/src/main/java/com/google/devtools/build/lib/query2/output/QueryOptions.java b/src/main/java/com/google/devtools/build/lib/query2/output/QueryOptions.java index fbd2644d51..862dde3001 100644 --- a/src/main/java/com/google/devtools/build/lib/query2/output/QueryOptions.java +++ b/src/main/java/com/google/devtools/build/lib/query2/output/QueryOptions.java @@ -32,6 +32,17 @@ public class QueryOptions extends CommonQueryOptions { } @Option( + name = "output", + defaultValue = "label", + documentationCategory = OptionDocumentationCategory.QUERY, + effectTags = {OptionEffectTag.TERMINAL_OUTPUT}, + help = + "The format in which the query results should be printed. Allowed values for query are: " + + "build, graph, label, label_kind, locations, maxrank, minrank, package, proto, xml." + ) + public String outputFormat; + + @Option( name = "null", defaultValue = "null", expansion = {"--line_terminator_null=true"}, |