From d543f0121b4e22b145d2d66a7bed8618b88fc8fb Mon Sep 17 00:00:00 2001 From: Michael Terry Date: Mon, 22 Jul 2024 15:13:16 -0400 Subject: [PATCH] Add pypi action to automate releases When a new GitHub release is created, this bundles us up and pushes to PyPI. --- .github/workflows/pypi.yaml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 .github/workflows/pypi.yaml diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml new file mode 100644 index 00000000..3b2055df --- /dev/null +++ b/.github/workflows/pypi.yaml @@ -0,0 +1,26 @@ +name: PyPI + +on: + release: + types: [created] + +jobs: + publish: + runs-on: ubuntu-latest + + permissions: + id-token: write # this permission is required for PyPI "trusted publishing" + + steps: + - uses: actions/checkout@v4 + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install build + + - name: Build + run: python -m build + + - name: Publish + uses: pypa/gh-action-pypi-publish@release/v1