From 4ba0321c19704c0b4218b9d5de4acd9f75b5cdeb Mon Sep 17 00:00:00 2001 From: Koen Vervloesem Date: Sat, 23 Dec 2023 20:26:58 +0100 Subject: [PATCH] [CI] Test build of Python package on all Python versions for every PR --- .github/workflows/check.yml | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 0737c920..8b652c5f 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -1,13 +1,10 @@ -name: check +name: Test build on: - push: - branches: - - development pull_request: jobs: - pre-commit: + test: strategy: fail-fast: false matrix: @@ -21,9 +18,22 @@ jobs: steps: - name: Checkout repository uses: actions/checkout@v3 + with: {fetch-depth: 0} # deep clone for setuptools-scm - name: Set up Python uses: actions/setup-python@v4 with: python-version: ${{ matrix.python }} - name: Run pre-commit uses: pre-commit/action@v3.0.0 + - name: Install requirements + run: | + pip3 install --upgrade pip + pip3 install setuptools setuptools_scm cmake wheel scikit-build ninja + - name: Build package + run: | + python3 setup.py sdist + - uses: actions/upload-artifact@v4 + if: ${{ matrix.python == "3.12" }} + with: + name: python-package + path: dist/