Skip to content

Commit d582eed

Browse files
committed
Add publisher action
1 parent ecf187f commit d582eed

File tree

2 files changed

+33
-0
lines changed

2 files changed

+33
-0
lines changed
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: PyPI publisher
2+
3+
on:
4+
release:
5+
types: [created,prereleased]
6+
7+
jobs:
8+
deploy:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v1
12+
- name: Set up Python
13+
uses: actions/setup-python@v1
14+
with:
15+
python-version: '3.8.x'
16+
- name: Install dependencies
17+
run: |
18+
python -m pip install --upgrade pip
19+
pip install setuptools wheel twine
20+
- name: Build and publish
21+
env:
22+
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
23+
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
24+
run: |
25+
python setup.py sdist bdist_wheel
26+
twine upload --verbose dist/*
27+
# - name: Upload documentation
28+
# env:
29+
# BOT_TOKEN: ${{ secrets.BOT_TOKEN }}
30+
# run: |
31+
# pip install -e .
32+
# doc/build_doc.sh

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@ dist
33
env
44
__pycache__
55
.pytest_cache
6+
build

0 commit comments

Comments
 (0)