Add gitea workflow to run offline tests and publish package
Some checks failed
Run Unit Tests / publish (push) Failing after 1m15s
Some checks failed
Run Unit Tests / publish (push) Failing after 1m15s
This commit is contained in:
parent
2869b181c6
commit
37ee12a8e0
37
.gitea/workflows/test-and-publish.yml
Normal file
37
.gitea/workflows/test-and-publish.yml
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
name: Run Unit Tests
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
release:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
# test-package:
|
||||||
|
# strategy:
|
||||||
|
# matrix:
|
||||||
|
# python-version:
|
||||||
|
# - "3.11"
|
||||||
|
# - "3.12"
|
||||||
|
# - "3.13"
|
||||||
|
# runs-on: ubuntu-latest
|
||||||
|
# container: ghcr.io/astral-sh/uv:0.5-python${{ matrix.python-version }}-alpine
|
||||||
|
# steps:
|
||||||
|
# - uses: taiki-e/checkout-action@v1
|
||||||
|
# - name: Install the project
|
||||||
|
# run: uv sync --all-extras --dev
|
||||||
|
# - name: Run tests
|
||||||
|
# run: uv run pytest
|
||||||
|
|
||||||
|
publish:
|
||||||
|
if: startsWith(github.ref, 'refs/tags/v')
|
||||||
|
# needs: test-package
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container: ghcr.io/astral-sh/uv:0.5-python3.13-bookworm
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- name: Build package
|
||||||
|
run: uv build
|
||||||
|
- name: Publish to Gitea
|
||||||
|
run: uv publish
|
||||||
|
env:
|
||||||
|
UV_PUBLISH_URL: "${{ gitea.server_url }}/api/packages/${{ gitea.repository_owner }}/pypi"
|
||||||
|
UV_PUBLISH_USERNAME: "${{ secrets.PACKAGE_REPO_USERNAME }}"
|
||||||
|
UV_PUBLISH_PASSWORD: "${{ secrets.PACKAGE_REPO_PASSWORD }}"
|
Loading…
Reference in New Issue
Block a user