User-scoped PIO packages dir; works on Windows / Linux / macOS.
()
| 83 | |
| 84 | |
| 85 | def pio_packages_dir() -> Path: |
| 86 | """User-scoped PIO packages dir; works on Windows / Linux / macOS.""" |
| 87 | home = Path.home() |
| 88 | candidate = home / ".platformio" / "packages" |
| 89 | if candidate.is_dir(): |
| 90 | return candidate |
| 91 | raise SystemExit( |
| 92 | f"PlatformIO packages dir not found at {candidate}. " |
| 93 | "Run a PIO build first (`bash compile <board> --examples Blink`)." |
| 94 | ) |
| 95 | |
| 96 | |
| 97 | def resolve_nm(board: str) -> Path: |