We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
buck query
1 parent 38d8a8f commit c40ee9eCopy full SHA for c40ee9e
source/buck/builder.ml
@@ -85,7 +85,13 @@ let query_buck_for_changed_targets ~targets { BuckOptions.raw; mode; isolation_p
85
match source_paths with
86
| [] -> Lwt.return "{}"
87
| source_paths ->
88
- let target_string = List.map targets ~f:Target.show |> String.concat ~sep:" " in
+ let target_string =
89
+ (* Targets need to be quoted since `buck query` can fail with syntax errors if target
90
+ name contains special characters like `=`. *)
91
+ let quote_string value = Format.sprintf "\"%s\"" value in
92
+ let quote_target target = Target.show target |> quote_string in
93
+ List.map targets ~f:quote_target |> String.concat ~sep:" "
94
+ in
95
List.concat
96
[
97
["--json"];
0 commit comments