Manual Release #15
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Manual Release | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| ref: | |
| description: "Branch or tag to publish" | |
| required: true | |
| default: main | |
| type: string | |
| permissions: | |
| contents: read | |
| jobs: | |
| pypi: | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: pypi | |
| url: https://pypi.org/p/neutral-llm-gateway | |
| permissions: | |
| # Trusted publishing (OIDC): no API token stored anywhere. | |
| id-token: write | |
| steps: | |
| - uses: actions/checkout@v5 | |
| with: | |
| ref: ${{ inputs.ref }} | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| - name: Build sdist and wheel | |
| run: uv build | |
| # Between the build and the upload is the last moment this can be | |
| # stopped: a published file is mirrored within minutes, and deleting the | |
| # release does not unpublish what was inside it. | |
| # Plain python3 on purpose: the audit is stdlib-only, and a guard that | |
| # depends on a resolver is a guard that can be skipped by a resolver. | |
| - name: Refuse to publish anything local | |
| run: python3 scripts/audit_dist.py | |
| - name: Publish to PyPI | |
| uses: pypa/gh-action-pypi-publish@release/v1 |