Add todo #222
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: CI | |
on: | |
- push | |
- workflow_dispatch | |
permissions: | |
contents: write | |
jobs: | |
prettier: | |
name: Prettier check | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: pnpm/action-setup@v2 | |
with: | |
version: latest | |
- name: Install node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '20.10.0' | |
cache: 'pnpm' | |
- name: Install frontend dependencies, check Prettier formatting | |
run: | | |
pnpm i | |
pnpm lint:prettier | |
cpp_format: | |
name: C++ Formatting Check | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Run clang-format style check for C/C++/Protobuf programs. | |
uses: jidicula/[email protected] | |
with: | |
clang-format-version: '17' | |
frontend_eslint: | |
name: ESLint Frontend | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: pnpm/action-setup@v2 | |
with: | |
version: latest | |
- name: Install node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '20.10.0' | |
cache: 'pnpm' | |
- name: Install frontend dependencies, run ESLint | |
run: | | |
pnpm i | |
pnpm lint:frontend:eslint | |
frontend_typescript: | |
name: Typescript Frontend | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: pnpm/action-setup@v2 | |
with: | |
version: latest | |
- name: Install node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '20.10.0' | |
cache: 'pnpm' | |
- name: Install frontend dependencies, check typing | |
run: | | |
pnpm i | |
pnpm lint:frontend:ts | |
actionlint: | |
name: Actionlint | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: actionlint | |
uses: raven-actions/actionlint@v1 | |
build_esp: | |
name: Build and archive ESP firmware | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build ESP binaries | |
uses: ./.github/actions/build-esp | |
- name: Archive build output artifacts | |
uses: actions/upload-artifact@v4 | |
with: | |
name: merged_firmware | |
path: build/merged_firmware.bin | |
compression-level: 0 | |
build_simulator: | |
name: Build simulator binary | |
timeout-minutes: 10 | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/cache@v3 | |
with: | |
path: | | |
~/.cache/pip | |
~/.platformio/.cache | |
key: ${{ runner.os }}-pio | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
- name: Install SDL2 | |
run: | | |
sudo add-apt-repository -y "deb http://archive.ubuntu.com/ubuntu $(lsb_release -sc) main universe restricted multiverse" | |
sudo apt-get update -y -qq | |
sudo apt-get install libsdl2-dev | |
- name: Install PlatformIO Core | |
run: pip install --upgrade platformio | |
- name: Build PlatformIO Project | |
run: | | |
cd simulator | |
pio run --verbose --environment emulator |