release.yml
1 # SPDX-FileCopyrightText: 2021 Jeff Epler 2 # 3 # SPDX-License-Identifier: MIT 4 5 name: Release chap 6 7 on: 8 release: 9 types: [published] 10 11 jobs: 12 release: 13 14 runs-on: ubuntu-22.04 15 steps: 16 - name: Dump GitHub context 17 env: 18 GITHUB_CONTEXT: ${{ toJson(github) }} 19 run: echo "$GITHUB_CONTEXT" 20 21 - uses: actions/checkout@v4 22 23 - name: Set up Python 24 uses: actions/setup-python@v5 25 with: 26 python-version: 3.11 27 28 - name: Install deps 29 run: | 30 python -mpip install wheel 31 python -mpip install -r requirements-dev.txt 32 33 - name: Build release 34 run: python -mbuild 35 36 - name: Upload release 37 run: twine upload -u "$TWINE_USERNAME" -p "$TWINE_PASSWORD" dist/* 38 env: 39 TWINE_USERNAME: __token__ 40 TWINE_PASSWORD: ${{ secrets.pypi_token }}