update ci to download artefact #5
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: PyPi Release | |
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- "main" | |
jobs: | |
build-package: | |
name: Build our package. | |
runs-on: ubuntu-latest | |
environment: | |
name: release | |
url: https://pypi.org/p/pywiegandpi | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: hynek/build-and-inspect-python-package@v2 | |
pypi-publish: | |
name: Upload release to PyPI | |
runs-on: ubuntu-latest | |
environment: | |
name: release | |
url: https://pypi.org/p/pywiegandpi | |
needs: build-package | |
permissions: | |
id-token: write | |
steps: | |
- name: Download packages built by previous step | |
uses: actions/download-artifact@v4 | |
with: | |
name: Packages | |
path: dist | |
- name: Publish package distributions to PyPI | |
uses: pypa/gh-action-pypi-publish@release/v1 |