[ci] Add ESP32 Variants clang-tidy run (S3/P4/C6) (#16825)

This commit is contained in:
Jonathan Swoboda
2026-06-05 22:03:08 -04:00
committed by GitHub
parent 8aa4157574
commit 6996b7ed1c
13 changed files with 233 additions and 20 deletions
+6 -5
View File
@@ -99,11 +99,12 @@ def calculate_clang_tidy_hash(repo_root: Path | None = None) -> str:
platformio_content = read_file_bytes(platformio_path)
hasher.update(platformio_content)
# Hash sdkconfig.defaults file
sdkconfig_path = repo_root / "sdkconfig.defaults"
if sdkconfig_path.exists():
sdkconfig_content = read_file_bytes(sdkconfig_path)
hasher.update(sdkconfig_content)
# Hash sdkconfig.defaults and any per-target sdkconfig.defaults.<target>:
# the per-target files flip CONFIG flags that change which variant code
# paths clang-tidy sees. Include the filename so a rename is detected.
for sdkconfig_path in sorted(repo_root.glob("sdkconfig.defaults*")):
hasher.update(sdkconfig_path.name.encode())
hasher.update(read_file_bytes(sdkconfig_path))
# Hash esphome/idf_component.yml: its managed deps drive the ESP-IDF
# build's include set, which clang-tidy analyzes.