Skip to content

infra: add CI test for MinGW #97

infra: add CI test for MinGW

infra: add CI test for MinGW #97

Workflow file for this run

name: Python CI
on:
push:
branches: [ master ]
pull_request_target:
branches: [ master ]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"]
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
- name: Set up uv
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
- name: Install dependencies
run: |
uv sync --locked --dev
- name: Configure Git user/email
run: |
git config --global user.email user@example.com
git config --global user.name "Example User"
- name: Run test suite
run: |
uv run pip install .
uv run pytest -v --cov=PyGitUp
shell: bash
- name: Verify dist package format
run: |
uv build
uv tool run twine check dist/*
if: matrix.os != 'windows-latest'
- name: Upload coverage result
if: github.repository_owner == 'msiemens'
env:
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
run: |
uv run coveralls
mingw:
name: MinGW (MSYS2)
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Set up MSYS2 (MinGW64)
uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: true
install: >-
mingw-w64-x86_64-python
mingw-w64-x86_64-python-pip
git
- name: Install dependencies
shell: msys2 {0}
run: |
python -m pip install -U pip
pip install -e .
pip install pytest pytest-cov
git config --global user.email user@example.com
git config --global user.name "Example User"
- name: Run test suite
shell: msys2 {0}
run: |
pytest -v