-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
628b53d
commit 0012857
Showing
1 changed file
with
48 additions
and
18 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 |
---|---|---|
|
@@ -13,39 +13,69 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: 3.9 | ||
- name: Test fizzbuzzo3 | ||
run: cargo test --package fizzbuzzo3 | ||
|
||
|
||
wheels: | ||
name: Build wheels on ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
# macos-13 is an intel runner, macos-14 is apple silicon | ||
os: [ubuntu-latest, windows-latest, macos-13, macos-14] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- name: Build wheels | ||
uses: pypa/[email protected] | ||
env: | ||
CIBW_CONFIG_SETTINGS: "--build-option=--py-limited-api=cp38" | ||
# with: | ||
# package-dir: . | ||
# output-dir: wheelhouse | ||
# config-file: "{package}/pyproject.toml" | ||
- uses: actions/upload-artifact@v4 | ||
with: | ||
name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }} | ||
path: ./wheelhouse/*.whl | ||
|
||
sdist: | ||
name: Make SDist | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- name: Build SDist | ||
run: pipx run build --sdist | ||
- uses: actions/upload-artifact@v4 | ||
with: | ||
name: cibw-sdist | ||
path: dist/*.tar.gz | ||
|
||
publish: | ||
environment: ADO-Packages | ||
needs: [python-checks, rust-checks] | ||
needs: [python-checks, rust-checks, wheels, sdist] | ||
runs-on: ubuntu-latest | ||
container: quay.io/pypa/manylinux2014_x86_64 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Setup Rust | ||
uses: actions-rs/toolchain@v1 | ||
- uses: actions/download-artifact@v4 | ||
with: | ||
profile: minimal | ||
toolchain: stable | ||
- name: Build cp38-abi3 sdist | ||
run: python3.8 -m build --config-setting=--build-option=--py-limited-api=cp38 | ||
- name: Auditwheel | ||
run: | | ||
for whl in dist/*linux*.whl; do | ||
auditwheel repair "$whl" | ||
done \ | ||
&& rm -f dist/*linux*.whl \ | ||
&& mv wheelhouse/* dist | ||
pattern: cibw-* | ||
path: dist | ||
merge-multiple: true | ||
- name: Install ADO tooling | ||
run: python3.12 -m pip install keyring artifacts-keyring | ||
run: python -m pip install keyring artifacts-keyring | ||
- name: Upload to ADO | ||
env: | ||
TWINE_REPOSITORY_URL: https://pkgs.dev.azure.com/MusicalNinjas/FizzBuzz/_packaging/FizzBuzz/pypi/upload/ | ||
TWINE_USERNAME: FizzBuzz | ||
TWINE_PASSWORD: ${{ secrets.ADO_TOKEN }} | ||
run: python3.12 -m twine upload --non-interactive dist/* | ||
run: twine upload --non-interactive dist/* |