bidict/.github/workflows/release-to-test-pypi.yml

36 lines
1.1 KiB
YAML
Raw Normal View History

name: Release to Test PyPI
on:
push:
tags:
# To publish a test release to test.pypi.org,
# create and push a tag as follows:
2021-09-05 15:25:22 +00:00
# git tag -a 0.21.3.rc1 -m "Tag 0.21.3.rc1 for release to test.pypi.org"
# git push --tags
# Go to https://github.com/jab/bidict/actions?query=workflow%3A%22Release+to+Test+PyPI%22
# and watch for a new run of this workflow to publish to test.pypi.org.
# IMPORTANT: Run the following to clean up after:
2021-09-05 15:25:22 +00:00
# git tag -d 0.21.3.rc1
# git push origin :0.21.3.rc1
- "[0-9]+.[0-9]+.[0-9]+.rc[0-9]+"
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: "3.10"
- name: Prepare Env
run: |
python -m pip install --upgrade pip
pip install setuptools build
- name: Build
run: python -m build
- name: Publish
2021-11-04 21:38:41 +00:00
uses: pypa/gh-action-pypi-publish@v1.4.2
with:
user: __token__
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
repository_url: https://test.pypi.org/legacy/
verbose: true