Skip to content

Merge pull request #26 from KiraPC/update-deps #14

Merge pull request #26 from KiraPC/update-deps

Merge pull request #26 from KiraPC/update-deps #14

Workflow file for this run

name: Publish Release
on:
push:
tags:
- '*'
jobs:
pypi-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Get Tag Version
id: vars
run: echo "tag=${GITHUB_REF#refs/*/}" >> "$GITHUB_OUTPUT"
- name: Set version in pyproject.toml
env:
RELEASE_VERSION: ${{ steps.vars.outputs.tag }}
run: sed -i "s/^version = .*/version = \"$RELEASE_VERSION\"/" pyproject.toml
- name: Build distribution package
run: |
pip install build
python -m build
- name: Publish package
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_API_TOKEN }}