Skip to content

Commit

Permalink
use a Python script more cross-platform
Browse files Browse the repository at this point in the history
  • Loading branch information
alexlancaster committed Nov 13, 2024
1 parent ff2486d commit 6084a3a
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions .github/workflows/build_wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -183,11 +183,21 @@ jobs:
uses: docker/setup-qemu-action@v3
with:
platforms: all
- name: Remove cffconvert from build-system requires in pyproject.toml
- name: Install toml and remove cffconvert from pyproject.toml
run: |
sed -i '/^\[build-system\]/,/^\[/ {
/"cffconvert\( @[^"]*\)\?"/d
}' pyproject.toml
python -m pip install toml
python -c "
import toml
with open('pyproject.toml', 'r') as f:
config = toml.load(f)
if 'build-system' in config and 'requires' in config['build-system']:
config['build-system']['requires'] = [
dep for dep in config['build-system']['requires'] if 'cffconvert' not in dep.lower()
]
with open('pyproject.toml', 'w') as f:
toml.dump(config, f)
"
cat pyproject.toml
- name: Build and test wheels
uses: pypa/cibuildwheel@v2.21.3
env:
Expand Down

0 comments on commit 6084a3a

Please sign in to comment.