Skip to content

Commit

Permalink
GitHub Actions: update deprecated images
Browse files Browse the repository at this point in the history
  • Loading branch information
Anexen committed Oct 28, 2024
1 parent 4d3871e commit 0ebd536
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 14 deletions.
31 changes: 17 additions & 14 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,13 @@ on:

env:
MATURIN_VERSION: 1.7.4
RUNNER_IMAGE_LINUX: ubuntu-latest
RUNNER_IMAGE_MACOS: macos-latest
RUNNER_IMAGE_WINDOWS: windows-latest

jobs:
test:
runs-on: ubuntu-22.04
runs-on: ${{ env.RUNNER_IMAGE_LINUX }}
steps:
- uses: actions/checkout@v4
- uses: actions-rust-lang/setup-rust-toolchain@v1
Expand All @@ -37,11 +40,11 @@ jobs:
matrix:
python: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12', '3.13']
platform:
- os: ubuntu-22.04
- os: macos-12
- os: macos-12
- os: ${{ env.RUNNER_IMAGE_LINUX }}
- os: ${{ env.RUNNER_IMAGE_MACOS }}
- os: ${{ env.RUNNER_IMAGE_MACOS }}
arch: aarch64
- os: windows-2022
- os: ${{ env.RUNNER_IMAGE_WINDOWS }}
runs-on: ${{ matrix.platform.os }}
steps:
- uses: actions/checkout@v4
Expand All @@ -50,33 +53,33 @@ jobs:
python-version: ${{ matrix.python }}
# allow-prereleases: ${{ matrix.python == "3.13" }}
- name: Build Wheels - Linux
if: matrix.platform.os == 'ubuntu-22.04'
if: matrix.platform.os == '${{ env.RUNNER_IMAGE_LINUX }}'
uses: PyO3/maturin-action@v1
with:
maturin-version: ${{ env.MATURIN_VERSION }}
manylinux: auto
args: -i python${{ matrix.python }} --release --strip --sdist

- name: Check that the source distribution installed correctly
if: matrix.platform.os == 'ubuntu-22.04'
if: matrix.platform.os == '${{ env.RUNNER_IMAGE_LINUX }}'
run: pip install target/wheels/pyxirr-*.tar.gz

- name: Build Wheels - MacOS [aarch64]
if: ${{ matrix.platform.os == 'macos-12' && matrix.platform.arch == 'aarch64' }}
if: ${{ matrix.platform.os == '${{ env.RUNNER_IMAGE_MACOS }}' && matrix.platform.arch == 'aarch64' }}
uses: PyO3/maturin-action@v1
with:
maturin-version: ${{ env.MATURIN_VERSION }}
args: -i python --release --target aarch64-apple-darwin --strip

- name: Build Wheels - MacOS [x86_64]
if: ${{ matrix.platform.os == 'macos-12' && matrix.platform.arch != 'aarch64' }}
if: ${{ matrix.platform.os == '${{ env.RUNNER_IMAGE_MACOS }}' && matrix.platform.arch != 'aarch64' }}
uses: PyO3/maturin-action@v1
with:
maturin-version: ${{ env.MATURIN_VERSION }}
args: -i python --release --target universal2-apple-darwin --strip

- name: Build Wheels - Windows
if: matrix.platform.os == 'windows-2022'
if: matrix.platform.os == '${{ env.RUNNER_IMAGE_WINDOWS }}'
uses: PyO3/maturin-action@v1
with:
maturin-version: ${{ env.MATURIN_VERSION }}
Expand All @@ -96,7 +99,7 @@ jobs:
matrix:
python: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12', '3.13']
target: [aarch64, armv7, s390x, ppc64le, ppc64]
runs-on: ubuntu-22.04
runs-on: ${{ env.RUNNER_IMAGE_LINUX }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
Expand Down Expand Up @@ -126,7 +129,7 @@ jobs:
emscripten: 3.1.46 # pyodide 0.25.*
- python: '3.11'
emscripten: 3.1.45 # pyodide 0.24.*
runs-on: ubuntu-22.04
runs-on: ${{ env.RUNNER_IMAGE_LINUX }}
steps:
- uses: actions/checkout@v4
- uses: mymindstorm/setup-emsdk@v14
Expand Down Expand Up @@ -154,7 +157,7 @@ jobs:
- i686-unknown-linux-musl
- aarch64-unknown-linux-musl
- armv7-unknown-linux-musleabihf
runs-on: ubuntu-22.04
runs-on: ${{ env.RUNNER_IMAGE_LINUX }}
steps:
- uses: actions/checkout@v4
- name: Build Wheels - musl
Expand All @@ -177,7 +180,7 @@ jobs:
- linux-cross
- linux-musl
- wasm-emscripten
runs-on: ubuntu-22.04
runs-on: ${{ env.RUNNER_IMAGE_LINUX }}
steps:
- uses: actions/download-artifact@v4
with:
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,5 @@ __pycache__
*.so
.gdb_history
.pyodide-xbuildenv
.venv
.devbox

0 comments on commit 0ebd536

Please sign in to comment.