Skip to content

Publish

Publish #15

Workflow file for this run

name: Publish
on:
workflow_run:
workflows:
- GitHub Release
types:
- completed
branches:
- main
concurrency:
group: publish-${{ github.event.workflow_run.head_sha }}
cancel-in-progress: true
jobs:
publish:
name: Publish to PyPI
if: github.event.workflow_run.conclusion == 'success'
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
environment:
name: pypi
url: https://pypi.org/project/django-returns/
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.workflow_run.head_sha }}
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Install uv
uses: astral-sh/setup-uv@v4
- name: Build sdist and wheel
run: uv build
- name: Publish
uses: pypa/gh-action-pypi-publish@release/v1
with:
skip-existing: true