Skip to content

Use pipx instead of manually calling setup.py #41

Use pipx instead of manually calling setup.py

Use pipx instead of manually calling setup.py #41

Workflow file for this run

name: Test Python
on:
push:
branches:
- main
jobs:
build_sdist:
if: ${{ !startsWith(github.event.head_commit.message, '[doc]') }}
name: Build source distribution
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.12'
- run: pipx run build --sdist
working-directory: python
- uses: actions/upload-artifact@v3
with:
name: undr-sdist
path: python/dist/*.tar.gz
import_library:
name: Import library on ${{ matrix.os }} with Python ${{ matrix.python }}
runs-on: ${{ matrix.os }}
needs: [build_sdist]
strategy:
matrix:
python: ["3.8", "3.9", "3.10", "3.11", "3.12"]
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- uses: actions/download-artifact@v3
with:
name: undr-sdist
path: dist
- run: python -m pip install dist/*.tar.gz
shell: bash
- run: python -c 'import undr'