26 lines
683 B
YAML

name: Build and Publish Package
on:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Build & Publish in container
uses: addnab/docker-run-action@v3
with:
image: python:3.12-slim
options: -v $WORKSPACE:/app -w /app
run: |
pip install build twine
python -m build
twine upload \
--repository-url https://git.gansejunge.com/api/packages/notifier/pypi \
-u ${{ secrets.PACKAGE_UPLOAD_USERNAME }} \
-p ${{ secrets.PACKAGE_UPLOAD_TOKEN }} \
dist/*