38 lines
970 B
YAML
38 lines
970 B
YAML
name: Build Package
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
on:
|
|
workflow_call:
|
|
inputs:
|
|
python-version:
|
|
required: false
|
|
type: string
|
|
default: "3.10"
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: 📥 Checkout the repository
|
|
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
|
|
|
- name: 🐍 Install uv and set Python version ${{ inputs.python-version }}
|
|
uses: astral-sh/setup-uv@681c641aba71e4a1c380be3ab5e12ad51f415867 # v7.1.6
|
|
with:
|
|
python-version: ${{ inputs.python-version }}
|
|
activate-environment: true
|
|
|
|
- name: 🏗️ Build source and wheel distributions
|
|
run: |
|
|
uv pip install -r pyproject.toml --group build
|
|
uv build
|
|
uv run twine check --strict dist/*
|
|
|
|
- name: 📤 Upload distribution artifacts
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: dist
|
|
path: dist/
|