Skip to content

Use GitHub's native badges for Actions #6

Use GitHub's native badges for Actions

Use GitHub's native badges for Actions #6

Workflow file for this run

name: Publish Python package
on:
push:
tags:
- '*'
env:
PIP_DISABLE_PIP_VERSION_CHECK: '1'
PY_COLORS: '1'
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install prerequisites
run: python -m pip install tox wheel
- name: Verify package version is same as Git tag
env:
GIT_TAG: ${{ github.ref_name }}
run: tox run -qe ensure_version_matches -- $GIT_TAG
- name: Build package and upload to PyPI
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: tox run -e package -- upload