MCPcopy Create free account
hub / github.com/FastLED/FastLED / _run_compile_cmd

Function _run_compile_cmd

tests/measure_esp32s3_opt_ins.py:226–242  ·  view source on GitHub ↗

Pick the right compile entry point per platform. On Linux/macOS: `bash compile esp32s3 --examples --platformio`. On Windows: ` /compile.bat esp32s3 --examples --platformio` (absolute path — Windows subprocess.run does not auto-resolve `.bat` files fr

(example: str)

Source from the content-addressed store, hash-verified

224
225
226def _run_compile_cmd(example: str) -> list[str]:
227 """Pick the right compile entry point per platform.
228
229 On Linux/macOS: `bash compile esp32s3 --examples <example> --platformio`.
230 On Windows: `<PROJECT_ROOT>/compile.bat esp32s3 --examples <example>
231 --platformio` (absolute path — Windows subprocess.run does not
232 auto-resolve `.bat` files from the cwd argument). `bash` is not on
233 PATH in a non-WSL Windows Python launched by `uv run`, and there is
234 no `bash.exe` in the project; the project ships `compile.bat` for
235 this case. See #2935.
236 """
237 import os
238
239 args = ["esp32s3", "--examples", example, "--platformio"]
240 if os.name == "nt":
241 return [str(PROJECT_ROOT / "compile.bat"), *args]
242 return ["bash", "compile", *args]
243
244
245def _run_bloat_cmd() -> list[str]:

Callers 1

run_compileFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected