Merge pull request #4 from fred13kim/main #34
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: Build fw | |
on: [pull_request, push, workflow_dispatch] | |
jobs: | |
pre_job: | |
runs-on: ubuntu-latest | |
outputs: | |
should_skip: ${{ steps.skip_check.outputs.should_skip }} | |
steps: | |
- id: skip_check | |
uses: fkirc/[email protected] | |
build: | |
needs: pre_job | |
if: ${{ needs.pre_job.outputs.should_skip != 'true' }} | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- name: Set up Python | |
run: | | |
sudo apt-get update -yqq | |
sudo apt-get install python3 python3-pip python3-venv -yqq | |
- name: Get x86 libraries | |
run: sudo apt-get install gcc-multilib -yqq | |
- name: Install PlatformIO | |
run: sudo pip install --upgrade platformio | |
- name: Install scons | |
run: pip install scons | |
- name: Build CAN network | |
run: scons dbc | |
- name: Build firmware | |
run: scons fw | |
- name: Upload CAN network | |
uses: actions/upload-artifact@v3 | |
with: | |
name: can-dbc | |
path: build/can/eol_can.dbc | |
- name: Upload OpenCAN Codegen Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: opencan-codegen-files | |
path: build/fw/opencan_generated/* | |
- name: Upload firmware binaries | |
uses: actions/upload-artifact@v3 | |
with: | |
name: fw-bin | |
path: build/fw/*/firmware.bin |