Files
wehub-resource-sync 542cfa195c
CI / Frontend build (push) Failing after 9m6s
CI / Plugin validate (push) Failing after 9m27s
CI / Python lint (push) Failing after 16m1s
CI / Tests (push) Successful in 18m0s
Deploy / deploy (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 12:33:27 +08:00

46 lines
1.2 KiB
YAML

name: Release to PyPI
# Publishes the `pixelrag` package to PyPI. Auth is an account-scoped API token stored as
# the `PYPI_API_TOKEN` repo secret (see RELEASING.md). Triggered by publishing a GitHub
# Release (tag like `v0.2.0`), or run manually:
# - dry_run = true → build only (no upload)
# - dry_run = false → build + publish
# `--check-url` makes publishing idempotent: files already on PyPI are skipped.
on:
release:
types: [published]
workflow_dispatch:
inputs:
dry_run:
description: "Build only, do not publish"
type: boolean
default: true
concurrency:
group: release-${{ github.ref }}
cancel-in-progress: false
jobs:
release:
name: pixelrag
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v6
with:
version: "latest"
- name: Build
run: uv build --out-dir dist
- name: List artifacts
run: ls -l dist
- name: Publish to PyPI
if: ${{ github.event_name == 'release' || !inputs.dry_run }}
env:
UV_PUBLISH_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
run: uv publish --check-url https://pypi.org/simple/