SERVER-102786 make clang-tidy run on generated sources (#34025)
GitOrigin-RevId: 313b8e4100897ac2c3cdbc98a2e9886ba37b43d4
This commit is contained in:
parent
1ae76cf2bf
commit
2f6a068c2b
2
.bazelrc
2
.bazelrc
@ -335,8 +335,10 @@ common --remote_upload_local_results=False
|
||||
common:clang-tidy --config=dbg
|
||||
common:clang-tidy --build_tag_filters=-third_party,-mongo-tidy-tests
|
||||
common:clang-tidy --//bazel/config:compiler_type=clang
|
||||
common:clang-tidy --keep_going
|
||||
common:clang-tidy --aspects @bazel_clang_tidy//clang_tidy:clang_tidy.bzl%clang_tidy_aspect
|
||||
common:clang-tidy --output_groups=report
|
||||
common:clang-tidy --@bazel_clang_tidy//:clang_tidy_excludes=".pb.cc,icu_init.cpp"
|
||||
common:clang-tidy --@bazel_clang_tidy//:clang_tidy_config=//:clang_tidy_config_strict
|
||||
common:clang-tidy --@bazel_clang_tidy//:clang_tidy_executable=//:clang_tidy
|
||||
common:clang-tidy --@bazel_clang_tidy//:clang_tidy_additional_deps=//:toolchain_files
|
||||
|
||||
12
MODULE.bazel
12
MODULE.bazel
@ -13,17 +13,13 @@ http_archive = use_repo_rule("@bazel_tools//tools/build_defs/repo:http.bzl", "ht
|
||||
|
||||
http_archive(
|
||||
name = "bazel_clang_tidy",
|
||||
integrity = "sha256-nar8iWq+4goJBEfmQZPWGsRlHdt+paVu5LY1WQ/BCZA=",
|
||||
strip_prefix = "bazel_clang_tidy-a46e57159bfe2d5d41135cec61f1c9cd514c1964",
|
||||
integrity = "sha256-A+TGGfuHdS7vWT20eyAEiA3u4YXFtuzsJDcpTEmDMS0=",
|
||||
strip_prefix = "bazel_clang_tidy-10c4bf70a8946789e3932f30e29dfba2dfb78e67",
|
||||
urls = [
|
||||
# Implements retry by relisting each url multiple times to be used as a failover.
|
||||
# TODO(SERVER-86719): Re-implement http_archive to allow sleeping between retries
|
||||
"https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz",
|
||||
"https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz",
|
||||
"https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz",
|
||||
"https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz",
|
||||
"https://github.com/mongodb-forks/bazel_clang_tidy/archive/a46e57159bfe2d5d41135cec61f1c9cd514c1964.tar.gz",
|
||||
],
|
||||
"https://github.com/mongodb-forks/bazel_clang_tidy/archive/10c4bf70a8946789e3932f30e29dfba2dfb78e67.tar.gz",
|
||||
] * 5,
|
||||
)
|
||||
|
||||
bazel_dep(name = "platforms", version = "0.0.9")
|
||||
|
||||
@ -3503,7 +3503,9 @@ class _CppSourceFileWriter(_CppFileWriterBase):
|
||||
self.write_empty_line()
|
||||
|
||||
def _gen_config_options_register(self, root_opts, sections, returns_status):
|
||||
self._writer.write_line("namespace moe = ::mongo::optionenvironment;")
|
||||
self._writer.write_line(
|
||||
"namespace moe = ::mongo::optionenvironment; // NOLINT(misc-unused-alias-decls)"
|
||||
)
|
||||
self.write_empty_line()
|
||||
|
||||
for opt in root_opts:
|
||||
@ -3531,7 +3533,9 @@ class _CppSourceFileWriter(_CppFileWriterBase):
|
||||
|
||||
def _gen_config_options_store(self, configs, return_status):
|
||||
# Setup initializer for storing configured options in their variables.
|
||||
self._writer.write_line("namespace moe = ::mongo::optionenvironment;")
|
||||
self._writer.write_line(
|
||||
"namespace moe = ::mongo::optionenvironment; // NOLINT(misc-unused-alias-decls)"
|
||||
)
|
||||
self.write_empty_line()
|
||||
|
||||
for opt in configs:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user