add pre-commit, run pre-commit before build #64
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Arduino Library CI | ||
| on: [pull_request, push, repository_dispatch] | ||
| jobs: | ||
| pre-commit: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - name: Run pre-commit | ||
| uses: pre-commit/[email protected] | ||
| - uses: actions/checkout@v4 | ||
| with: | ||
| repository: adafruit/ci-arduino | ||
| path: ci | ||
| - name: pre-install | ||
| run: bash ci/actions_install.sh | ||
| - name: clang | ||
| run: python3 ci/run-clang-format.py -e "ci/*" -e "bin/*" -r . | ||
| - name: doxygen | ||
| env: | ||
| GH_REPO_TOKEN: ${{ secrets.GH_REPO_TOKEN }} | ||
| PRETTYNAME : "Adafruit Arcada Library" | ||
| run: bash ci/doxy_gen_and_deploy.sh | ||
| build: | ||
| runs-on: ubuntu-latest | ||
| need: pre-commit | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - uses: actions/checkout@v4 | ||
| with: | ||
| repository: adafruit/ci-arduino | ||
| path: ci | ||
| - name: pre-install | ||
| run: bash ci/actions_install.sh | ||
| - name: test platforms | ||
| run: python3 ci/build_platform.py "pycamera_s3" | ||
| - name: list | ||
| run: | | ||
| ls | ||
| ls examples/*/build/ | ||
| - name: Upload build artifacts | ||
| uses: actions/upload-artifact@v4 | ||
| with: | ||
| name: example_uf2s | ||
| path: | | ||
| examples/*/build/*/*.uf2 | ||