Skip to content

Commit

Permalink
Add workflow to publish releases to PyPI
Browse files Browse the repository at this point in the history
Signed-off-by: Xiaochao Dong (@damnever) <the.xcdong@gmail.com>
  • Loading branch information
damnever committed Dec 4, 2022
1 parent 281971a commit f171a1e
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Release
on:
push:
tags: [v**]
jobs:
release:
runs-on: ubuntu-latest
name: Build and Publish Python distributions to PyPI
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: 3.11
architecture: x64
- name: Install requirements
run: pip install build
- name: Build distributions
run: python -m build
- name: Publish distribution to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
verbose: true
print_hash: true
packages_dir: dist
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}

0 comments on commit f171a1e

Please sign in to comment.