Skip to content

fix: trigger version 0.2.2 #38

fix: trigger version 0.2.2

fix: trigger version 0.2.2 #38

name: Release (release → PyPI)
on:
push:
branches:
- release
permissions:
contents: write
id-token: write
pull-requests: write
jobs:
release:
runs-on: ubuntu-latest
environment:
name: pypi-universalpython
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install build twine python-semantic-release
pip install -r utils/requirements.txt
- name: Create stable release
id: release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
set +e
semantic-release version --commit --tag --push --verbose
EXIT_CODE=$?
set -e
echo "exit_code=$EXIT_CODE" >> $GITHUB_OUTPUT
- name: Build package
run: bash utils/build_package.sh
# - name: Publish to TestPyPI
# uses: pypa/gh-action-pypi-publish@release/v1
# with:
# repository-url: https://test.pypi.org/legacy/
# packages-dir: dist/
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
packages-dir: dist/