From a21131c1c44d7819418d5000cbb573472c3de904 Mon Sep 17 00:00:00 2001 From: TheHedgeify Date: Thu, 28 Nov 2024 16:39:42 +0100 Subject: [PATCH] tag release --- .github/workflows/tag_release.yml | 40 +++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 .github/workflows/tag_release.yml diff --git a/.github/workflows/tag_release.yml b/.github/workflows/tag_release.yml new file mode 100644 index 0000000..b25cfad --- /dev/null +++ b/.github/workflows/tag_release.yml @@ -0,0 +1,40 @@ +name: tag-release + +on: + push: + # Pattern matched against refs/tags + tags: + - 'v*' # This includes only tags starting with v + +jobs: + build-source: + runs-on: ubuntu-latest + permissions: + contents: write + id-token: write + # Dedicated environments with protections for publishing are strongly recommended. + environment: + name: release + # OPTIONAL: uncomment and update to include your PyPI project URL in the deployment status: + # url: https://pypi.org/p/YOURPROJECT + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 + with: + python-version: "3.10" + cache: "pip" + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install build + - name: Build source Python package + run: python -m build -s -o dist . + - name: Publish release distributions to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + - name: Release + uses: softprops/action-gh-release@v2 + with: + files: | + ./dist/** + +