Skip to content

Commit d524568

Browse files
committed
Allow uploading Github Actions -> PyPI
1 parent 772e3b3 commit d524568

File tree

2 files changed

+27
-2
lines changed

2 files changed

+27
-2
lines changed

.github/workflows/pypi_upload.yaml

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: PYPI Upload
2+
3+
on:
4+
- workflow_dispatch
5+
6+
jobs:
7+
pypi_upload:
8+
name: pypi-upload
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Checkout
12+
uses: actions/checkout@v2
13+
- name: Setup Python
14+
uses: actions/setup-python@v1
15+
with:
16+
python-version: 3.9
17+
- name: Build Package
18+
run: |
19+
pip install wheel
20+
python setup.py sdist bdist_wheel
21+
- name: Publish to PyPI
22+
uses: pypa/gh-action-pypi-publish@master
23+
with:
24+
user: __token__
25+
password: ${{ secrets.PYPI_API_TOKEN }}

.github/workflows/build.yaml renamed to .github/workflows/tests.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
name: build
1+
name: tests
22

33
on:
44
- push
55
- pull_request
66

77
jobs:
88
test:
9-
name: build
9+
name: tests
1010
runs-on: ubuntu-latest
1111
strategy:
1212
matrix:

0 commit comments

Comments
 (0)