Get per-sketch cache directory next to the .ino file: /.build/wasm/.
(example_name: str)
| 54 | |
| 55 | |
| 56 | def get_sketch_cache_dir(example_name: str) -> Path: |
| 57 | """Get per-sketch cache directory next to the .ino file: <sketch_dir>/.build/wasm/.""" |
| 58 | ino_file = PROJECT_ROOT / "examples" / example_name / f"{example_name}.ino" |
| 59 | if not ino_file.exists(): |
| 60 | raise FileNotFoundError(f"Sketch not found: {ino_file}") |
| 61 | d = ino_file.parent / ".build" / "wasm" |
| 62 | d.mkdir(parents=True, exist_ok=True) |
| 63 | return d |
| 64 | |
| 65 | |
| 66 | def get_meson_executable() -> str: |