From ff9f9cefd3fec75b6c67fd792dc31fc27ece4d2b Mon Sep 17 00:00:00 2001 From: Ibraheem Tuffaha Date: Fri, 25 Aug 2023 15:07:39 +0300 Subject: [PATCH] Add GitHub action that releases to PyPI on `Create Release` --- .github/workflows/release.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..a3f28da --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,19 @@ +name: Release Package to PyPI.org + +on: + release: + types: [published] + +jobs: + build-and-publish: + name: Build and Publish Package to PyPI.org + runs-on: ubuntu-latest + permissions: + id-token: write + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + with: + python-version: 3.9 + - run: python -m pip install build twine && python -m build + - uses: pypa/gh-action-pypi-publish@release/v1