From d1f707796f1f6eea5d4c6b227447067a54a33b05 Mon Sep 17 00:00:00 2001 From: bootloader Date: Fri, 10 Apr 2026 10:56:01 +0800 Subject: [PATCH] ci: add initial GitHub Actions workflow for dev/main --- .github/workflows/ci.yml | 46 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..52d97cf --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,46 @@ +name: CI + +on: + push: + branches: + - dev + - main + pull_request: + branches: + - dev + - main + workflow_dispatch: + +permissions: + contents: read + +jobs: + build: + name: Build (${{ matrix.os }}) + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest, windows-latest] + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Configure (Linux) + if: runner.os == 'Linux' + run: cmake -S . -B build -DCMAKE_BUILD_TYPE=Release + + - name: Build (Linux) + if: runner.os == 'Linux' + run: cmake --build build --config Release + + - name: Configure (Windows) + if: runner.os == 'Windows' + shell: pwsh + run: cmake -S . -B build -G "NMake Makefiles" -DCMAKE_BUILD_TYPE=Release + + - name: Build (Windows) + if: runner.os == 'Windows' + shell: pwsh + run: cmake --build build --config Release