From f202b2e9972c26d6e63a225b43de1d7bb19988bb Mon Sep 17 00:00:00 2001 From: Paul Yang Date: Fri, 23 Feb 2024 12:55:26 -0800 Subject: [PATCH] Add workflow to publish a release. --- .github/workflows/cd-push-to-pypi.yaml | 28 ++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 .github/workflows/cd-push-to-pypi.yaml diff --git a/.github/workflows/cd-push-to-pypi.yaml b/.github/workflows/cd-push-to-pypi.yaml new file mode 100644 index 00000000..0eb9b1b1 --- /dev/null +++ b/.github/workflows/cd-push-to-pypi.yaml @@ -0,0 +1,28 @@ +name: Publish `dbt-semantic-interfaces` Release +on: + workflow_dispatch: + push: + tags: + - "*" + +env: + PYTHON_VERSION: "3.8" + +jobs: + pypi-publish: + runs-on: ubuntu-latest + environment: PYPI_PUBLISH + steps: + - name: Check-out the repo + uses: actions/checkout@v3 + + - name: Setup Python ${{ env.PYTHON_VERSION }} Environment + uses: ./.github/actions/setup-python-env + with: + python-version: "${{ env.PYTHON_VERSION }}" + + - name: Hatch Publish + run: hatch build && hatch publish + env: + HATCH_INDEX_USER: __token__ + HATCH_INDEX_AUTH: ${{ secrets.PYPI_API_TOKEN }}