Skip to content
This repository has been archived by the owner on Jan 18, 2025. It is now read-only.

ci: configure semantic release in GitHub Action (#51) #1

ci: configure semantic release in GitHub Action (#51)

ci: configure semantic release in GitHub Action (#51) #1

name: sematic-release
on:
push:
branches:
- main
jobs:
release:
runs-on: ubuntu-latest
concurrency: release
permissions:
id-token: write
contents: write
steps:
- name: Checkout Repository
uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{ github.sha }}
- name: Setup | Force correct release branch on workflow sha
run: |
git checkout -B ${{ github.ref_name }} ${{ github.sha }}
- name: Update Semantic Version Release
id: release
uses: python-semantic-release/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
git_committer_name: 'github-actions'
git_committer_email: '[email protected]'
changelog: 'false'
- name: Upload to GitHub Release Assets
uses: python-semantic-release/[email protected]
if: steps.release.outputs.released == 'true'
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ steps.release.outputs.tag }}