Update actions/setup-python action to v4.7.1 #71
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish | |
on: | |
push: | |
branches: | |
- main | |
tags: | |
- "[0-9]+.[0-9]+.*" | |
jobs: | |
pypi: | |
name: PyPI | |
environment: Release | |
if: github.ref_type == 'tag' | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out repository | |
uses: actions/checkout@v3.6.0 | |
- name: Set up Python 3.10 | |
uses: actions/setup-python@v4.7.1 | |
with: | |
python-version: "3.10" | |
cache: pip | |
cache-dependency-path: setup.py | |
- name: Install dependencies | |
run: python -m pip install -U pip build | |
- name: Simplify README.md for packaging | |
run: python .github/scripts/simplify-readme.py | |
- name: Build package | |
run: python -m build | |
- name: Publish package | |
uses: pypa/gh-action-pypi-publish@v1.8.10 | |
with: | |
password: ${{ secrets.PYPI_API_TOKEN }} | |
print_hash: true |