Goal
Make fbuild drop-in usable in consumer CI pipelines with a single step:
```yaml
- uses: FastLED/fbuild/.github/actions/setup@v1
with:
cache-key-extra: ${{ hashFiles('platformio.ini') }}
- run: fbuild build examples/Blink -e esp32dev
```
Today, consumers must read docs/CI_CACHING.md and hand-wire `actions/cache@v4` + install + env vars. That's error-prone (especially the exclude-daemon-dir pitfall).
What the action does
- Install fbuild from PyPI at the requested version (default: latest)
- Set `FBUILD_CACHE_DIR` to a stable CI-predictable path (so no $HOME dependence)
- Wire `actions/cache@v4` to save/restore that dir across runs using the cache-key strategy documented in `CI_CACHING.md`
- Exclude `~/.fbuild/*/daemon/` automatically (the gotcha)
- Output: `cache-hit` (bool) so consumers can assert warm-builds in a smoke step
Scope
- Composite action at `.github/actions/setup/action.yml`
- README in the action dir with usage + inputs reference
- Update `docs/CI_CACHING.md` TL;DR to recommend the action (keep the raw-YAML snippet for consumers who don't want the action dependency)
Out of scope
- A JavaScript action (composite is sufficient, no build-tooling overhead)
- Windows-specific quirks beyond what `actions/cache@v4` already handles
- Matrix sharding with persistent volumes (one-shot runners only)
Follow-up
- After this action lands, switch FastLED repo workflows to use it. That's a separate PR in the FastLED repo.
Acceptance
Goal
Make fbuild drop-in usable in consumer CI pipelines with a single step:
```yaml
with:
cache-key-extra: ${{ hashFiles('platformio.ini') }}
```
Today, consumers must read docs/CI_CACHING.md and hand-wire `actions/cache@v4` + install + env vars. That's error-prone (especially the exclude-daemon-dir pitfall).
What the action does
Scope
Out of scope
Follow-up
Acceptance