Files
mathias2784 5e76bf8a37
Tests / test_and_lint (push) Successful in 7s
Publish workflow (#4)
Reviewed-on: #4
Co-authored-by: Mathias Scheider <mathias2784@web.de>
2026-10-01 19:57:59 +00:00

37 lines
1.0 KiB
YAML

name: Publish Package to Gitea
on:
push:
tags:
- "v*" # This triggers the workflow when you push a tag like v1.0.0
jobs:
publish:
runs-on: ubuntu-latest # Or your specific runner label
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.x"
- name: Install build dependencies
run: |
python -m pip install --upgrade pip
pip install build twine
- name: Build package
run: python -m build
- name: Publish to Gitea PyPI
env:
# These secrets must match the names you created in Gitea
TWINE_USERNAME: ${{ secrets.TWINE_USERNAME }}
TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }}
# REPLACE THIS URL with your actual Gitea PyPI endpoint
TWINE_REPOSITORY_URL: "https://gitea.schneiderserver.site/api/packages/mathias2784/pypi"
run: |
twine upload --repository-url $TWINE_REPOSITORY_URL dist/*