Skip to content

♻️ chore: update pyproject.toml dependencies. #20

♻️ chore: update pyproject.toml dependencies.

♻️ chore: update pyproject.toml dependencies. #20

name: Master Build
permissions:
contents: write
packages: write
issues: read
checks: write
pull-requests: write
on:
workflow_dispatch:
inputs:
branch:
description: 'Branch to release'
default: 'master'
push:
branches:
- master
jobs:
build:
name: test with ${{ matrix.py }} on linux
runs-on: ubuntu-24.04
strategy:
fail-fast: false
matrix:
py:
- "3.12"
- "3.11"
- "3.10"
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup python for test ${{ matrix.py }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.py }}
- name: Install tox and pex dependencies
run: |
python -m pip install --upgrade pip
python -m pip install pex tox tox-gh setuptools_scm
- name: Save package version for later
run: |
echo "local_version=$(python -m setuptools_scm)" >> $GITHUB_OUTPUT
id: versioncheck
- name: Build Software
run: |
tox
# Order is important we don't want to have the pex uploaded to pypi
- name: Store the distribution packages
uses: actions/upload-artifact@v4
with:
name: python-package-distributions-${{ matrix.py }}
path: dist/
- name: Build documentation
run: |
tox -e docs
- name: Build distributable packages
run: |
tox -e package
env:
PACKAGE_VERSION: ${{ steps.versioncheck.outputs.local_version }}
- name: Verify pex package is runnable
run: ./dist/seriesmgmt_${{ steps.versioncheck.outputs.local_version }}.pex
- name: Verify package is runnable
run: |
pip install -e .
python scripts/test.py -h
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
with:
publish_branch: gh-pages
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: .tox/docs/tmp/html/
force_orphan: true
if: matrix.py == '3.12'
publish-to-testpypi:
name: Publish Python 🐍 distribution 📦 to TestPyPI
needs:
- build
runs-on: ubuntu-24.04
environment:
name: testpypi
url: https://test.pypi.org/p/seriesManagementSystem
permissions:
id-token: write # IMPORTANT: mandatory for trusted publishing
steps:
- name: Download all the dists
uses: actions/download-artifact@v4
with:
pattern: python-package-distributions-3.12
path: dist/
merge-multiple: true
- name: Show downloaded packages
run: ls -R dist/
- name: Publish distribution 📦 to TestPyPI
uses: pypa/gh-action-pypi-publish@v1.10.3
with:
repository-url: https://test.pypi.org/legacy/
verbose: true
skip-existing: true