Skip to content

Commit

Permalink
rewrite deploy with macos
Browse files Browse the repository at this point in the history
  • Loading branch information
SunsetWolf committed Dec 19, 2024
1 parent 22ca863 commit 59d28b8
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -150,24 +150,20 @@ jobs:
print(f'Renamed: {whl_file} -> {new_whl_file}')
"
- name: Build 2
if: ${{ (matrix.buildplat[0] != 'macos-13' || matrix['python-version'] != '3.11') && (matrix.buildplat[0] != 'macos-13' || matrix['python-version'] != '3.12') }}
run: |
make build
- name: Rename 2
if: ${{ (matrix.buildplat[0] != 'macos-13' || matrix['python-version'] != '3.11') && (matrix.buildplat[0] != 'macos-13' || matrix['python-version'] != '3.12') }}
run: |
python -c "
from pathlib import Path
plat_info = '${{ matrix.buildplat[1] }}'.split('_', 1)[-1]
for whl_file in Path('./dist').glob('*.whl'):
if 'universal2' in whl_file.stem:
new_name = whl_file.name.replace('universal2', plat_info)
new_whl_file = whl_file.with_name(new_name)
whl_file.rename(new_whl_file)
print(f'Renamed: {whl_file} -> {new_whl_file}')
new_name = whl_file.name.replace('universal2', plat_info)
new_whl_file = whl_file.with_name(new_name)
whl_file.rename(new_whl_file)
print(f'Renamed: {whl_file} -> {new_whl_file}')
"
- name: Build 3
if: ${{ (matrix.buildplat[0] != 'macos-13' || matrix['python-version'] != '3.11') && (matrix.buildplat[0] != 'macos-13' || matrix['python-version'] != '3.12') }}
run: |
make build
- name: Build and publish
Expand Down

0 comments on commit 59d28b8

Please sign in to comment.