Qwen-Image-Layered-MRP-MLX/.github/workflows/release.yml
2025-06-14 11:18:27 +02:00

43 lines
1.1 KiB
YAML

name: Create Release and Publish to PyPI
on:
workflow_dispatch:
inputs:
confirm:
description: 'Type "publish" to confirm release'
required: true
type: string
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Validate confirmation
run: |
if [ "${{ github.event.inputs.confirm }}" != "publish" ]; then
echo "❌ Must type 'publish' to confirm release"
exit 1
fi
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install requests build twine toml
- name: Run release script
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}
PYPI_API_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
run: |
python scripts/release.py