fix some caching

This commit is contained in:
Peter Buchegger 2023-02-19 12:59:32 +01:00
parent eab5f3c2e6
commit c4a6700ab6

View file

@ -15,19 +15,23 @@ jobs:
name: Compile Firmware name: Compile Firmware
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout code
uses: actions/checkout@v3
- uses: actions/cache@v3 - uses: actions/cache@v3
with: with:
path: | path: |
~/.cache/pip ~/.cache/pip
~/.platformio/.cache ~/.platformio/.cache
key: ${{ runner.os }}-pio key: compile-cache
- uses: actions/setup-python@v4 - uses: actions/setup-python@v4
with: with:
python-version: '3.9' python-version: '3.10'
- name: Install PlatformIO Core - name: Install PlatformIO
run: pip install --upgrade platformio shell: bash
run: |
python -m pip install --upgrade pip
pip install --upgrade platformio
- name: Checkout code
uses: actions/checkout@v3
- name: Build PlatformIO Project - name: Build PlatformIO Project
run: pio run run: pio run
- name: Upload artifacts - name: Upload artifacts
@ -84,16 +88,13 @@ jobs:
env: env:
PLATFORMIO_AUTH_TOKEN: ${{ secrets.PLATFORMIO_AUTH_TOKEN }} PLATFORMIO_AUTH_TOKEN: ${{ secrets.PLATFORMIO_AUTH_TOKEN }}
steps: steps:
- name: Cache pip - name: Setup Cache
uses: actions/cache@v3 uses: actions/cache@v3
with: with:
path: ~/.cache/pip path: |
key: pip-cache ~/.cache/pip
- name: Cache PlatformIO ~/.platformio
uses: actions/cache@v3 key: remote-cache
with:
path: ~/.platformio
key: pio-cache
- name: Setup Python - name: Setup Python
uses: actions/setup-python@v4 uses: actions/setup-python@v4
with: with: