1
0
mirror of https://github.com/esphome/esphome.git synced 2025-10-21 03:03:50 +01:00
This commit is contained in:
J. Nick Koston
2025-10-17 14:57:45 -10:00
parent e2101f5a20
commit b0ada914bc
2 changed files with 7 additions and 7 deletions

View File

@@ -65,13 +65,11 @@ def extract_from_compile_output(
total_ram = sum(int(match) for match in ram_matches)
total_flash = sum(int(match) for match in flash_matches)
# Extract build directory from ESPHome's delete messages
# Look for: INFO Deleting /path/to/build/.esphome/build/componenttest.../.pioenvs
# Extract build directory from ESPHome's explicit build path output
# Look for: INFO Compiling app... Build path: /path/to/build
build_dir = None
if match := re.search(
r"INFO Deleting (.+/\.esphome/build/componenttest[^/]+)/\.pioenvs", output_text
):
build_dir = match.group(1)
if match := re.search(r"Build path: (.+)", output_text):
build_dir = match.group(1).strip()
return total_ram, total_flash, build_dir