Skip to content

Semantic Release

Semantic Release #6

Workflow file for this run

name: Semantic Release
on:
workflow_run:
workflows: ["CI"]
branches: [main]
types:
- completed
jobs:
release:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
concurrency: release
environment: release
permissions:
id-token: write
contents: write
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Setup | Force release branch to be at workflow sha
run: |
git reset --hard ${{ github.sha }}
- name: Python Semantic Release
id: release
uses: python-semantic-release/python-semantic-release@v10.5.2
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
- name: Publish to PyPI
if: steps.release.outputs.released == 'true'
uses: pypa/gh-action-pypi-publish@release/v1