Skip to content

Commit d5a971d

Browse files
author
Matthias Koeppe
committed
.github/workflows/dist.yml: Upload platform-independent wheels to PyPI
1 parent e6fe93c commit d5a971d

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

.github/workflows/dist.yml

+30
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,36 @@ jobs:
103103
verbose: true
104104
if: env.CAN_DEPLOY == 'true'
105105

106+
noarch_wheels_for_pypi:
107+
108+
runs-on: ubuntu-latest
109+
env:
110+
CAN_DEPLOY: ${{ secrets.SAGEMATH_PYPI_API_TOKEN != '' }}
111+
steps:
112+
- uses: actions/checkout@v4
113+
- name: Install bootstrap prerequisites
114+
run: |
115+
sudo DEBIAN_FRONTEND=noninteractive apt-get update
116+
sudo DEBIAN_FRONTEND=noninteractive apt-get install $(build/bin/sage-get-system-packages debian _bootstrap)
117+
- name: make pypi-noarch-wheels
118+
run: |
119+
./bootstrap
120+
./configure
121+
make pypi-noarch-wheels V=0
122+
(mkdir dist && mv upstream/sage*-none-any.whl dist/)
123+
ls -l dist
124+
- uses: actions/upload-artifact@v3
125+
with:
126+
path: "dist/*.whl"
127+
name: dist
128+
- uses: pypa/gh-action-pypi-publish@release/v1
129+
with:
130+
user: __token__
131+
password: ${{ secrets.SAGEMATH_PYPI_API_TOKEN }}
132+
skip-existing: true
133+
verbose: true
134+
if: env.CAN_DEPLOY == 'true'
135+
106136
build_wheels:
107137
name: Build wheels on ${{ matrix.os }}, arch ${{ matrix.arch }}
108138
runs-on: ${{ matrix.os }}

0 commit comments

Comments
 (0)