From be779437462e867a4d5d1594409fe829bf4173eb Mon Sep 17 00:00:00 2001 From: Joongi Kim Date: Thu, 4 Apr 2024 20:21:11 +0900 Subject: [PATCH] ci: Upgrade actions Note that actions/upload-artifact and actions/download-artifact v2 -> v4 upgrade involves a breaking change: https://github.com/actions/upload-artifact/blob/main/docs/MIGRATION.md --- .github/workflows/default.yml | 41 ++++++++++++++++++----------------- 1 file changed, 21 insertions(+), 20 deletions(-) diff --git a/.github/workflows/default.yml b/.github/workflows/default.yml index 826bbee..b343c2a 100644 --- a/.github/workflows/default.yml +++ b/.github/workflows/default.yml @@ -6,16 +6,16 @@ jobs: sdist: if: github.event_name == 'push' && contains(github.ref, 'refs/tags/') - runs-on: ubuntu-20.04 + runs-on: ubuntu-22.04 steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: lfs: true - name: Set up Python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: - python-version: '3.11' + python-version: '3.12' - name: Install dependencies run: | python -m pip install -U pip setuptools wheel @@ -24,9 +24,9 @@ jobs: python setup.py sdist ls -lh dist - name: Upload artifacts - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v4 with: - name: dist + name: dist-src path: dist @@ -37,8 +37,8 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-20.04] - pyver: [cp311-cp311] + os: [ubuntu-22.04] + pyver: [cp312-cp312] arch: [x86_64, aarch64] env: @@ -47,16 +47,16 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: lfs: true - name: Set up Python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: - python-version: '3.11' + python-version: '3.12' - name: Set up QEMU id: qemu - uses: docker/setup-qemu-action@v2 + uses: docker/setup-qemu-action@v3 - name: Show available platforms run: echo ${{ steps.qemu.outputs.platforms }} - name: Install dependencies @@ -89,9 +89,9 @@ jobs: dist/backend.ai_krunner_static_gnu-${PKGVER}-py3-none-${GLIBC_PTAG}.${MUSL_PTAG}.${MACOS_PTAG}.whl ls -lh dist - name: Upload artifacts - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v4 with: - name: dist + name: dist-${{ matrix.os }}-${{ matrix.pyver }}-${{ matrix.arch }} path: dist @@ -105,19 +105,20 @@ jobs: id-token: write runs-on: ubuntu-20.04 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v5 with: - python-version: "3.11" + python-version: "3.12" - name: Install dependencies run: | python -m pip install -U pip setuptools wheel - name: Download distributions - uses: actions/download-artifact@v2 + uses: actions/download-artifact@v4 with: - name: dist + pattern: dist-* + merge-multiple: true path: dist - name: >- Publish 🐍📦 to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 \ No newline at end of file + uses: pypa/gh-action-pypi-publish@release/v1