Strip backend-version noise from a single define; None to drop entirely.
(define: str)
| 158 | |
| 159 | |
| 160 | def _normalize_define(define: str) -> str | None: |
| 161 | """Strip backend-version noise from a single define; None to drop entirely.""" |
| 162 | # PIO emits "PLATFORMIO=60119"; fbuild emits "PLATFORMIO". Normalize both |
| 163 | # to just the bare name so we don't false-positive on the version stamp. |
| 164 | if _PIO_VERSION_DEFINE_RE.match(define): |
| 165 | return "PLATFORMIO" |
| 166 | return define |
| 167 | |
| 168 | |
| 169 | def _normalize_include(path: str) -> str: |
no outgoing calls
no test coverage detected