From 5a9b85dc8ad6c47d46376efdeffd1e9f48a497ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miguel=20=C3=81ngel=20Gonz=C3=A1lez=20Santamarta?= Date: Thu, 24 Oct 2024 22:39:19 +0200 Subject: [PATCH] github actions --- .github/workflows/ci.yml | 42 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 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..e79eb8a --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,42 @@ +name: Python CI with Docker and Formatting Check + +on: [push, pull_request] + +jobs: + python_formatter: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Black Formatter + uses: lgeiger/black-action@master + with: + args: ". --check --diff" + + cpp_formatter: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Clang Formatter + uses: jidicula/clang-format-action@v4.13.0 + with: + clang-format-version: "13" + check-path: "." + fallback-style: "Mozilla" + + build: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + + - name: Build Docker + uses: docker/build-push-action@v6 + with: + push: false