Skip to content

Commit b712e6f

Browse files
committed
.github/workflows/dist.yml: Upload various artifacts
1 parent 107a6a1 commit b712e6f

File tree

1 file changed

+27
-12
lines changed

1 file changed

+27
-12
lines changed

.github/workflows/dist.yml

Lines changed: 27 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,8 @@ concurrency:
1313
jobs:
1414

1515
sdists_for_pypi:
16-
name: Build sdist (and upload to PyPI on release tags)
16+
name: Build sdist
1717
runs-on: ubuntu-latest
18-
env:
19-
CAN_DEPLOY: ${{ secrets.SAGEMATH_PYPI_API_TOKEN != '' }}
2018
steps:
2119
- uses: actions/checkout@v4
2220
- uses: actions/setup-python@v4
@@ -28,13 +26,6 @@ jobs:
2826
with:
2927
path: "dist/*.tar.gz"
3028
name: dist
31-
- uses: pypa/gh-action-pypi-publish@release/v1
32-
with:
33-
user: __token__
34-
password: ${{ secrets.SAGEMATH_PYPI_API_TOKEN }}
35-
skip_existing: true
36-
verbose: true
37-
if: env.CAN_DEPLOY == 'true' && github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
3829

3930
build_wheels:
4031
name: Build wheels on ${{ matrix.os }}, arch ${{ matrix.arch }}
@@ -144,6 +135,12 @@ jobs:
144135
"${{ steps.python.outputs.python-path }}" -m pipx run cibuildwheel==2.21.3 unpacked/$pkg*
145136
done
146137
138+
- uses: actions/upload-artifact@v4
139+
if: always()
140+
with:
141+
name: ${{ matrix.os }}-${{ matrix.build }}-${{ matrix.arch }}-wheels
142+
path: ./wheelhouse/*.whl
143+
147144
build_wheels_windows:
148145
name: Build wheels on ${{ matrix.os }} using ${{ matrix.env }}
149146
runs-on: ${{ matrix.os }}
@@ -341,10 +338,28 @@ jobs:
341338
name: ${{ matrix.os }}-${{ matrix.arch }}-wheels
342339
path: ./wheelhouse/*.whl
343340

341+
- uses: actions/upload-artifact@v4
342+
if: always()
343+
with:
344+
name: unpacked-${{ matrix.os }}
345+
path: ./unpacked
346+
347+
- uses: actions/upload-artifact@v4
348+
if: always()
349+
with:
350+
name: sage-local-${{ matrix.os }}
351+
path: ./sage-local
352+
353+
- uses: actions/upload-artifact@v4
354+
if: always()
355+
with:
356+
name: logs-${{ matrix.os }}
357+
path: ./logs
358+
344359
pypi-publish:
345360
# https://github.com/pypa/gh-action-pypi-publish
346-
name: Upload wheels to PyPI
347-
needs: build_wheels
361+
name: Upload to PyPI
362+
needs: [build_wheels, build_wheels_windows]
348363
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
349364
runs-on: ubuntu-latest
350365
env:

0 commit comments

Comments
 (0)