-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Build wheels in docker to fix 'cannot repair dist/vcztools-0.1.dev1+g…
…89924d7-cp311-cp311-linux_x86_64.whl to manylinux_2_5_x86_64 ABI because of the presence of too-recent versioned symbols. You'll need to compile the wheel on an older toolchain.'
- Loading branch information
1 parent
89924d7
commit 51b6b73
Showing
1 changed file
with
32 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
name: CD | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- main | ||
|
@@ -21,26 +22,29 @@ jobs: | |
python-version: '3.11' | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
python -m pip install build twine auditwheel validate-pyproject[all] | ||
- name: Check and install package | ||
python -m pip install --upgrade pip build validate-pyproject[all] | ||
python -m build --sdist | ||
- name: Upload sdist | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: sdist | ||
path: dist | ||
- name: Build wheels | ||
run: | | ||
validate-pyproject pyproject.toml | ||
python -m build | ||
python -m auditwheel repair dist/*.whl | ||
python -m twine check --strict dist/* | ||
python -m pip install dist/*.whl | ||
docker run --rm -v `pwd`:/project -w /project quay.io/pypa/manylinux2014_x86_64 bash .github/workflows/docker/buildwheel.sh | ||
- name: Check vcztools CLI | ||
run: | | ||
pip install vcztools --no-index --only-binary vcztools -f dist/wheelhouse | ||
vcztools --help | ||
# Make sure we don't have ``vcztools`` in the CWD | ||
cd tests | ||
python -m vcztools --help | ||
- name: Store the distribution packages | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: python-package-distributions | ||
path: dist/ | ||
name: linux-wheels | ||
path: dist/wheelhouse | ||
|
||
publish-to-pypi: | ||
if: github.repository_owner == 'sgkit-dev' && github.event_name == 'release' | ||
|
@@ -55,11 +59,14 @@ jobs: | |
id-token: write # IMPORTANT: mandatory for trusted publishing | ||
|
||
steps: | ||
- uses: actions/download-artifact@v4 | ||
with: | ||
name: python-package-distributions | ||
path: dist/ | ||
- uses: pypa/gh-action-pypi-publish@release/v1 | ||
- name: Download all | ||
uses: actions/[email protected] | ||
- name: Move to dist | ||
run: | | ||
mkdir dist | ||
cp */*.{whl,gz} dist/. | ||
ls dist | ||
- uses: pypa/gh-action-pypi-publish@release/v1 | ||
|
||
|
||
publish-to-testpypi: | ||
|
@@ -76,11 +83,14 @@ jobs: | |
id-token: write # IMPORTANT: mandatory for trusted publishing | ||
|
||
steps: | ||
- uses: actions/download-artifact@v4 | ||
with: | ||
name: python-package-distributions | ||
path: dist/ | ||
- uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
verbose: true | ||
repository-url: https://test.pypi.org/legacy/ | ||
- name: Download all | ||
uses: actions/[email protected] | ||
- name: Move to dist | ||
run: | | ||
mkdir dist | ||
cp */*.{whl,gz} dist/. | ||
ls dist | ||
- uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
verbose: true | ||
repository-url: https://test.pypi.org/legacy/ |