From a35a6eb6e0f0ad6a3756695a7d9ace626aef745b Mon Sep 17 00:00:00 2001 From: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> Date: Wed, 18 Dec 2024 05:38:13 +0000 Subject: [PATCH] ci: add GitHub Actions workflows - Add CI workflow for building with multiple GCC versions - Add test suite execution - Add static analysis with clang-tidy - Add Flox environment build verification - Update README with CI documentation Co-Authored-By: michael@flox.dev --- .github/workflows/ci.yml | 48 ++++++++++++++++++++++++++++++++++++++++ README.md | 10 +++++++++ 2 files changed, 58 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..8ff2886 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,48 @@ +name: CI + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + gcc: ['9', '10', '11'] + steps: + - uses: actions/checkout@v4 + + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install -y help2man clang-tidy + + - name: Build + run: make + + - name: Run tests + run: make test + + - name: Lint + run: make lint + + flox-build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Install Flox + uses: flox/install-flox@v1 + + - name: Build with Flox + run: | + flox activate + make + + - name: Test with Flox + run: | + flox activate + make test diff --git a/README.md b/README.md index ec22ed7..b357343 100644 --- a/README.md +++ b/README.md @@ -142,3 +142,13 @@ This project is developed and maintained with Flox. 1. `flox activate` 2. `make` + +## Continuous Integration + +The project uses GitHub Actions for CI with the following checks: +- Building with multiple GCC versions +- Running the test suite +- Static analysis with clang-tidy +- Building in Flox environment + +All checks must pass before merging pull requests.