Skip to content

Update ci.yml

Update ci.yml #58

Workflow file for this run

name: ci
on: [push, pull_request]
env:
SERVER_PATH: server/src/
WEB_PATH: web/
jobs:
Server-Compile:
runs-on: ubuntu-latest
strategy:
matrix:
fqbn:
- arduino:avr:uno
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Arduino CLI
uses: arduino/compile-sketches@v1
with:
fqbn: ${{ matrix.fqbn }}
libraries: |
- name: Ethernet
- name: SD
sketch-paths: |
- ${{ env.SERVER_PATH }}
Server-Format-Check:
needs: [Server-Compile]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: "3.x"
- name: Setup Clang Formatter
uses: actions/checkout@v4
with:
repository: adafruit/ci-arduino
path: ci
- name: Check correct code formatting with clang-format
run: python3 ci/run-clang-format.py -e "ci/*" -e "bin/*" --extensions "ino" -r ${{ env.SERVER_PATH }}
Web-Format-Check:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20.x
- name: Install dependecies
working-directory: ${{ env.WEB_PATH }}
run: npm ci
- name: Check format
working-directory: ${{ env.WEB_PATH }}
run: npm run check-format