Skip to content

v3.0.1 🌈

v3.0.1 🌈 #2

Workflow file for this run

---
name: Release
on:
release:
types:
- published
env:
DEFAULT_PYTHON: "3.11"
jobs:
release:
name: Releasing to PyPi
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/pypaperless
permissions:
contents: write
id-token: write # important for trusted publishing (pypi)
outputs:
version: ${{ steps.vars.outputs.tag }}
steps:
- name: ‡️ Checkout code
uses: actions/[email protected]
- name: 🚧 Setup Poetry
run: pip install poetry
- name: 🐍 Setup Python ${{ env.DEFAULT_PYTHON }}
uses: actions/[email protected]
with:
python-version: ${{ env.DEFAULT_PYTHON }}
cache: poetry
- name: 🚧 Install dependencies
run: poetry install --no-interaction
- name: 🏷 Get repository tag
id: vars
run: echo "tag=${GITHUB_REF#refs/*/}" >> $GITHUB_OUTPUT
- name: 🚧 Set project version from tag
run: poetry version --no-interaction "${{ steps.vars.outputs.tag }}"
- name: πŸš€ Build package
run: poetry build --no-interaction
- name: ⬆️ Publish to PyPi
uses: pypa/[email protected]
with:
print-hash: true
- name: πŸ” Sign published artifacts
uses: sigstore/[email protected]
with:
inputs: ./dist/*.tar.gz ./dist/*.whl
release-signing-artifacts: true