Merge remote-tracking branch 'upstream/dev' into integration

This commit is contained in:
J. Nick Koston
2026-04-15 19:46:17 -10:00
7 changed files with 31 additions and 18 deletions
+6 -1
View File
@@ -180,7 +180,12 @@ def build_all_include(header_files: list[str] | None = None) -> None:
if line and line.replace(os.path.sep, "/") not in exclude
]
headers = [f'#include "{h}"' for h in header_files]
from esphome.writer import ENTITY_TYPES_H_TARGET
# X-macro files are included multiple times with different macro definitions
# and must not be included bare in the all-include header
exclude = {ENTITY_TYPES_H_TARGET}
headers = [f'#include "{h}"' for h in header_files if h not in exclude]
headers.sort()
headers.append("")
content = "\n".join(headers)