From 3dae8b3b297828a58f493c9f8180ffdddaa86711 Mon Sep 17 00:00:00 2001 From: Correl Roush Date: Sun, 20 Oct 2024 23:51:25 -0400 Subject: [PATCH] Add publishing github workflow --- .github/workflows/publish.yml | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 .github/workflows/publish.yml diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000..95e782f --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,32 @@ +name: Publish +on: + push: + tags: + - '*' +jobs: + publish: + runs-on: ubuntu-latest + environment: + name: pypi + url: https://pypi.org/project/tornado-openapi3/ + permissions: + id-token: write + steps: + - uses: actions/checkout@v4 + - name: Install Python + uses: actions/setup-python@v5 + with: + python-version: '3.13' + - name: Install Poetry + run: | + curl -sSL https://install.python-poetry.org | python - -y + - name: Update PATH + run: echo "$HOME/.local/bin" >> $GITHUB_PATH + - name: Update Poetry configuration + run: poetry config virtualenvs.create false + - name: Install dependencies + run: poetry install --sync --no-interaction + - name: Build package + run: poetry build + - name: Publish to PyPI + uses: pypa/gh-action-pypi-publish@release/v1