7
7
- develop
8
8
- main
9
9
tags :
10
- - *
10
+ - " * "
11
11
12
12
13
13
jobs :
@@ -133,7 +133,8 @@ jobs:
133
133
env :
134
134
PYTHON_ISAL_LINK_DYNAMIC : True
135
135
136
- buildwheels :
136
+ deploy :
137
+ # if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
137
138
runs-on : ${{ matrix.os }}
138
139
needs : [lint, docs, test-static, test-dynamic, twine_check]
139
140
# if: startsWith(github.ref, 'refs/tags')
@@ -158,11 +159,22 @@ jobs:
158
159
CIBW_SKIP : " *-win32 *-manylinux_i686" # Skip 32 bit.
159
160
CIBW_MANYLINUX_X86_64_IMAGE : " manylinux2014"
160
161
# Below command fails when data is not correctly statically linked
162
+ # Full tests not needed: these are done prior to building.
161
163
CIBW_TEST_COMMAND : " python -c 'from isal import isal_zlib, igzip; isal_zlib.adler32(b\" bla\" )'"
162
164
- name : Build sdist
163
165
if : " runner.os == 'Linux'"
164
166
run : python setup.py sdist
165
- - uses : actions/upload-artifact@v2
167
+ - name : Publish package to TestPyPI
168
+ uses : pypa/gh-action-pypi-publish@master
169
+ # Alpha, Beta and dev releases contain a - in the tag.
170
+ if : contains(github.ref, '-') && startsWith(github.ref, 'refs/tags')
166
171
with :
167
- name : ${{matrix.os}}_wheels
168
- path : dist/
172
+ user : __token__
173
+ password : ${{ secrets.TEST_PYPI_API_TOKEN }}
174
+ repository_url : https://test.pypi.org/legacy/
175
+ - name : Publish package to PyPI
176
+ uses : pypa/gh-action-pypi-publish@master
177
+ if : !contains(github.ref, '-') && startsWith(github.ref, 'refs/tags')
178
+ with :
179
+ user : __token__
180
+ password : ${{ secrets.PYPI_API_TOKEN }}
0 commit comments