adding gitea actions to publish
Some checks are pending
Build and Publish / Package Library (push) Blocked by required conditions

This commit is contained in:
Andy Pack 2024-07-28 14:22:04 +01:00
parent 0561b0036e
commit 7d23b01a5e
Signed by: sarsoo
GPG Key ID: A55BA3536A5E0ED7

40
.gitea/workflows/ci.yml Normal file
View File

@ -0,0 +1,40 @@
name: Build and Publish
on: [push, pull_request]
env:
python-version: '3.10'
poetry-version: 1.8.3
jobs:
publishLib:
runs-on: ubuntu-latest
name: Package Library
needs: [ build ] # for ignoring bad builds
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
steps:
- name: Checkout
uses: actions/checkout@v4
with:
github-server-url: https://gitea.sheep-ghoul.ts.net
- name: Install Python 3
uses: actions/setup-python@v4
with:
python-version: ${{ env.python-version }}
- name: Install Poetry # dependency management
uses: abatilo/actions-poetry@v2.1.6
with:
poetry-version: ${{ env.poetry-version }}
- name: Poetry Add Repo
run: poetry source add --priority=supplemental sargit https://git.sarsoo.xyz/api/packages/${{ secrets.PYPI_USERNAME }}/pypi
- name: Poetry Repo Creds
run: poetry config http-basic.sargit ${{ secrets.PYPI_USERNAME }} ${{ secrets.PYPI_KEY }}
- name: Poetry Build
run: poetry build
- name: Poetry Publish
run: poetry publish --repository sargit