Skip to content

Commit b5dd092

Browse files
author
Hugo Osvaldo Barrera
committed
Add GitHub Action to publish releases
1 parent d854bd6 commit b5dd092

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

.github/workflows/publish.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Publish
2+
3+
on:
4+
push:
5+
tags:
6+
- 0.*
7+
8+
jobs:
9+
github-release:
10+
runs-on: ubuntu-18.04
11+
name: Publish GitHub Release
12+
steps:
13+
- uses: actions/checkout@master
14+
- uses: actions/setup-python@v1
15+
with:
16+
python-version: 3.7
17+
architecture: x64
18+
- run: pip install wheel
19+
- run: python setup.py sdist bdist_wheel
20+
- uses: softprops/action-gh-release@v1
21+
with:
22+
files: dist/*
23+
env:
24+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
25+
pypi:
26+
runs-on: ubuntu-18.04
27+
name: Publish package on PyPI
28+
steps:
29+
- uses: actions/checkout@master
30+
- uses: actions/setup-python@v1
31+
with:
32+
python-version: 3.7
33+
architecture: x64
34+
- run: pip install wheel
35+
- run: python setup.py sdist bdist_wheel
36+
- uses: pypa/gh-action-pypi-publish@master
37+
with:
38+
password: ${{ secrets.PYPI_TOKEN }}

0 commit comments

Comments
 (0)