-
Notifications
You must be signed in to change notification settings - Fork 7
41 lines (32 loc) · 988 Bytes
/
publish-pypi.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
name: Publish to PyPI
on:
release:
types: [published]
jobs:
publish_pypi:
if: github.repository == 'GeoscienceAustralia/fc'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v1
with:
python-version: 3.8
- name: Install Twine
run: |
python -m pip install --upgrade twine
python -m pip freeze
- name: Install wheel dependencies
run: |
sudo apt-get install gfortran
python -m pip install auditwheel
- name: Build manylinux wheel
run: |
python setup.py sdist bdist_wheel
auditwheel repair dist/*linux_x86_64.whl --plat manylinux_2_27_x86_64 --wheel-dir dist/
rm dist/*linux_x86_64.whl
- name: Upload to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_TOKEN }}
skip_existing: true