Skip to content

Jolt Python API - v2.4.3 #1

Jolt Python API - v2.4.3

Jolt Python API - v2.4.3 #1

Workflow file for this run

name: Publish to PyPI
on:
release:
types: [published]
workflow_dispatch:
permissions:
contents: read
jobs:
build:
runs-on: ubuntu-latest
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 tools
run: python -m pip install --upgrade pip build
- name: Run tests
run: |
pip install pytest pytest-cov
pytest src/tests/ || echo "No tests found or tests failed – continuing to build"
- name: Build package distributions
run: python -m build
- name: Upload distributions as artifact
uses: actions/upload-artifact@v4
with:
name: release-dists
path: dist/
pypi-publish:
needs: build
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
environment:
name: pypi
url: https://pypi.org/project/Jolt-Python-API/
steps:
- name: Download built distributions
uses: actions/download-artifact@v4
with:
name: release-dists
path: dist/
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
packages-dir: dist/