Skip to content

Commit

Permalink
Add the "clang-tidy" and "clang_tidy" tags
Browse files Browse the repository at this point in the history
... as suggested by cjreynol@. This enables running
```
bazel build --build_tag_filters="-clang-tidy" "//..."
```
  • Loading branch information
Databean committed Feb 4, 2025
1 parent 7b631cf commit f697d8c
Show file tree
Hide file tree
Showing 26 changed files with 44 additions and 0 deletions.
2 changes: 2 additions & 0 deletions base/cvd/cuttlefish/common/libs/fs/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ cc_library(
clang_tidy_test(
name = "fs_clang_tidy",
srcs = [":fs"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_test(
Expand All @@ -52,4 +53,5 @@ cc_test(
clang_tidy_test(
name = "fs_test_clang_tidy",
srcs = [":fs_test"],
tags = ["clang_tidy", "clang-tidy"],
)
5 changes: 5 additions & 0 deletions base/cvd/cuttlefish/common/libs/utils/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ cc_library(
clang_tidy_test(
name = "result_clang_tidy",
srcs = [":result"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_library(
Expand All @@ -44,6 +45,7 @@ cc_library(
clang_tidy_test(
name = "result_matchers_clang_tidy",
srcs = [":result_matchers"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_library(
Expand Down Expand Up @@ -106,6 +108,7 @@ cc_library(
clang_tidy_test(
name = "utils_clang_tidy",
srcs = [":utils"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_test(
Expand All @@ -126,6 +129,7 @@ cc_test(
clang_tidy_test(
name = "result_test_clang_tidy",
srcs = [":result_test"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_test(
Expand Down Expand Up @@ -163,4 +167,5 @@ cc_test(
clang_tidy_test(
name = "utils_test_clang_tidy",
srcs = [":utils_test"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/commands/assemble_cvd/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,5 @@ cc_library(
clang_tidy_test(
name = "libassemble_cvd_clang_tidy",
srcs = [":libassemble_cvd"],
tags = ["clang_tidy", "clang-tidy"],
)
2 changes: 2 additions & 0 deletions base/cvd/cuttlefish/host/commands/cvd/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ cc_library(
clang_tidy_test(
name = "libcvd_clang_tidy",
srcs = [":libcvd"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_binary(
Expand All @@ -49,4 +50,5 @@ cc_binary(
clang_tidy_test(
name = "cvd_clang_tidy",
srcs = [":cvd"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/commands/cvd/acloud/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -50,4 +50,5 @@ cc_library(
clang_tidy_test(
name = "acloud_clang_tidy",
srcs = [":acloud"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/commands/cvd/cache/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,5 @@ cc_library(
clang_tidy_test(
name = "cache_clang_tidy",
srcs = [":cache"],
tags = ["clang_tidy", "clang-tidy"],
)
6 changes: 6 additions & 0 deletions base/cvd/cuttlefish/host/commands/cvd/cli/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ cc_library(
clang_tidy_test(
name = "command_request_clang_tidy",
srcs = [":command_request"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_library(
Expand All @@ -38,6 +39,7 @@ cc_library(
clang_tidy_test(
name = "frontline_parser_clang_tidy",
srcs = [":frontline_parser"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_library(
Expand All @@ -55,6 +57,7 @@ cc_library(
clang_tidy_test(
name = "interruptible_terminal_clang_tidy",
srcs = [":interruptible_terminal"],
tags = ["clang_tidy", "clang-tidy"],
)

# Commands that may invoke other commands
Expand Down Expand Up @@ -105,6 +108,7 @@ cc_library(
clang_tidy_test(
name = "nesting_commands_clang_tidy",
srcs = [":nesting_commands"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_library(
Expand All @@ -116,6 +120,7 @@ cc_library(
clang_tidy_test(
name = "types_clang_tidy",
srcs = [":types"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_library(
Expand All @@ -139,4 +144,5 @@ cc_library(
clang_tidy_test(
name = "utils_clang_tidy",
srcs = [":utils"],
tags = ["clang_tidy", "clang-tidy"],
)
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ cc_library(
clang_tidy_test(
name = "command_handler_clang_tidy",
srcs = [":command_handler"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_library(
Expand All @@ -52,6 +53,7 @@ cc_library(
clang_tidy_test(
name = "host_tool_target_clang_tidy",
srcs = [":host_tool_target"],
tags = ["clang_tidy", "clang-tidy"],
)

# Commands that don't execute other commands
Expand Down Expand Up @@ -149,5 +151,6 @@ cc_library(
clang_tidy_test(
name = "leaf_commands_clang_tidy",
srcs = [":leaf_commands"],
tags = ["clang_tidy", "clang-tidy"],
)

2 changes: 2 additions & 0 deletions base/cvd/cuttlefish/host/commands/cvd/cli/parser/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ cc_library(
clang_tidy_test(
name = "configs_common_clang_tidy",
srcs = [":configs_common"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_library(
Expand Down Expand Up @@ -76,4 +77,5 @@ cc_library(
clang_tidy_test(
name = "parser_clang_tidy",
srcs = [":parser"],
tags = ["clang_tidy", "clang-tidy"],
)
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ cc_library(
clang_tidy_test(
name = "parser_clang_tidy",
srcs = [":parser"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_library(
Expand All @@ -63,4 +64,5 @@ cc_library(
clang_tidy_test(
name = "selector_clang_tidy",
srcs = [":selector"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/commands/cvd/fetch/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,5 @@ cc_library(
clang_tidy_test(
name = "fetch_clang_tidy",
srcs = [":fetch"],
tags = ["clang_tidy", "clang-tidy"],
)
3 changes: 3 additions & 0 deletions base/cvd/cuttlefish/host/commands/cvd/instances/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ cc_library(
clang_tidy_test(
name = "instances_clang_tidy",
srcs = [":instances"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_library(
Expand All @@ -81,6 +82,7 @@ cc_library(
clang_tidy_test(
name = "instance_database_utils_clang_tidy",
srcs = [":instance_database_utils"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_library(
Expand All @@ -102,4 +104,5 @@ cc_library(
clang_tidy_test(
name = "reset_client_utils_clang_tidy",
srcs = [":reset_client_utils"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/commands/cvd/legacy/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,5 @@ cc_library(
clang_tidy_test(
name = "legacy_clang_tidy",
srcs = [":legacy"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/commands/cvd/metrics/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,5 @@ cc_library(
clang_tidy_test(
name = "metrics_clang_tidy",
srcs = [":metrics"],
tags = ["clang_tidy", "clang-tidy"],
)
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,5 @@ cc_test(
clang_tidy_test(
name = "fetch_clang_tidy",
srcs = [":fetch"],
tags = ["clang_tidy", "clang-tidy"],
)
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,5 @@ cc_test(
clang_tidy_test(
name = "parser_clang_tidy",
srcs = [":parser"],
tags = ["clang_tidy", "clang-tidy"],
)
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,5 @@ cc_test(
clang_tidy_test(
name = "selector_clang_tidy",
srcs = [":selector"],
tags = ["clang_tidy", "clang-tidy"],
)
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,5 @@ cc_test(
clang_tidy_test(
name = "server_clang_tidy",
srcs = [":server"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/commands/cvd/utils/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,5 @@ cc_library(
clang_tidy_test(
name = "utils_clang_tidy",
srcs = [":utils"],
tags = ["clang_tidy", "clang-tidy"],
)
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,5 @@ cc_binary(
clang_tidy_test(
name = "logcat_receiver_clang_tidy",
srcs = [":logcat_receiver"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/commands/metrics/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,5 @@ cc_library(
clang_tidy_test(
name = "libmetrics_clang_tidy",
srcs = [":libmetrics"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/libs/command_util/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,5 @@ cc_library(
clang_tidy_test(
name = "command_util_clang_tidy",
srcs = [":command_util"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/libs/config/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,5 @@ cc_library(
clang_tidy_test(
name = "config_clang_tidy",
srcs = [":config"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/libs/directories/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,5 @@ cc_library(
clang_tidy_test(
name = "directories_clang_tidy",
srcs = [":directories"],
tags = ["clang_tidy", "clang-tidy"],
)
1 change: 1 addition & 0 deletions base/cvd/cuttlefish/host/libs/image_aggregator/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,5 @@ cc_library(
clang_tidy_test(
name = "image_aggregator_clang_tidy",
srcs = [":image_aggregator"],
tags = ["clang_tidy", "clang-tidy"],
)
2 changes: 2 additions & 0 deletions base/cvd/cuttlefish/host/libs/web/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ cc_library(
clang_tidy_test(
name = "web_clang_tidy",
srcs = [":web"],
tags = ["clang_tidy", "clang-tidy"],
)

cc_test(
Expand Down Expand Up @@ -81,4 +82,5 @@ cc_test(
clang_tidy_test(
name = "web_test_clang_tidy",
srcs = [":web_test"],
tags = ["clang_tidy", "clang-tidy"],
)

0 comments on commit f697d8c

Please sign in to comment.