-
Notifications
You must be signed in to change notification settings - Fork 189
45 lines (37 loc) · 941 Bytes
/
wheels.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
name: "Build Wheels"
on:
workflow_dispatch:
push:
release:
types:
- published
jobs:
buildpackage:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install wheel and SDist requirements
run: python -m pip install "setuptools>=42.0" wheel twine
- name: Build SDist
run: python setup.py sdist bdist_wheel
- uses: actions/upload-artifact@v2
with:
path: |
dist/*.tar.gz
dist/*.whl
publish:
needs: [buildpackage]
runs-on: ubuntu-latest
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
steps:
- uses: actions/download-artifact@v2
with:
name: artifact
path: dist
- uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
password: ${{ secrets.pypi_password }}