Add CI for ayab-esp32 #4
Workflow file for this run
This file contains 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: Hardware Design | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- ayab-esp32/** | |
pull_request: | |
branches: | |
- main | |
paths: | |
- ayab-esp32/** | |
env: | |
workflow_project_dir: ayab-esp32 | |
kicad_project_name: ayab-esp32 | |
jobs: | |
buildfiles: | |
name: Design check & documentation build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Create output directory | |
run: mkdir -p ${workflow_project_dir}/outputs/gerbers | |
- name: Install KiCad | |
run: sudo bash ./scripts/dependencies.sh | |
- name: Verify clean design files | |
run: | | |
kicad-cli sch erc -o ${workflow_project_dir}/outputs/erc_errors.json --format json --severity-error --exit-code-violations ${workflow_project_dir}/${kicad_project_name}.kicad_sch | |
kicad-cli pcb drc -o ${workflow_project_dir}/outputs/drc_errors.json --format json --severity-error --exit-code-violations ${workflow_project_dir}/${kicad_project_name}.kicad_pcb | |
- name: Export design file PDFs | |
run: | | |
kicad-cli sch export pdf -o ${workflow_project_dir}/outputs/${kicad_project_name}-sch.pdf ${workflow_project_dir}/${kicad_project_name}.kicad_sch | |
kicad-cli pcb export pdf -o ${workflow_project_dir}/outputs/${kicad_project_name}-pcb-front.pdf -l "F.Cu,F.Mask,F.Silkscreen" ${workflow_project_dir}/${kicad_project_name}.kicad_pcb | |
kicad-cli pcb export pdf -o ${workflow_project_dir}/outputs/${kicad_project_name}-pcb-back.pdf --erd --ev --mirror -l "B.Cu,B.Mask,B.Silkscreen" ${workflow_project_dir}/${kicad_project_name}.kicad_pcb | |
- name: Archive artifacts | |
uses: actions/upload-artifact@v4 | |
if: always() | |
with: | |
name: design-artifacts | |
path: ayab-esp32/outputs |