Skip to content

Commit 904bdba

Browse files
committed
set up release action
1 parent 8f16a3f commit 904bdba

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

.github/workflows/pypi.yml

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: pypi
2+
3+
on:
4+
push:
5+
tags: [v*]
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- uses: actions/checkout@v2
13+
- name: Set up Python
14+
uses: actions/setup-python@v2
15+
with:
16+
python-version: 3.8
17+
- name: Install dependencies
18+
run: |
19+
python -m pip install --upgrade pip
20+
pip install twine
21+
- name: Build sdist
22+
run: |
23+
python setup.py sdist
24+
- name: Publish to Pypi
25+
env:
26+
TWINE_REPOSITORY: pypi
27+
TWINE_NON_INTERACTIVE: true
28+
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
29+
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
30+
run: |
31+
twine upload dist/*

0 commit comments

Comments
 (0)