From 5420ae8749d846d25365e81ee8fc47d7dcd144a8 Mon Sep 17 00:00:00 2001 From: Xee authors Date: Mon, 4 Dec 2023 12:38:48 -0800 Subject: [PATCH] Use `actions/setup-python@v4` with built-in caching. `actions/setup-python@v4` supports caching built-in: https://github.com/actions/setup-python#caching-packages-dependencies. Discovered when reviewing cache mechanisms for cl/587110684. PiperOrigin-RevId: 587808925 --- .github/workflows/ci-build.yml | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci-build.yml b/.github/workflows/ci-build.yml index 3b99dee..60b5d83 100644 --- a/.github/workflows/ci-build.yml +++ b/.github/workflows/ci-build.yml @@ -47,19 +47,10 @@ jobs: if: ${{github.ref != 'refs/head/main'}} - uses: actions/checkout@v2 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: ${{ matrix.python-version }} - - name: Get pip cache dir - id: pip-cache - run: | - python -m pip install --upgrade pip wheel - echo "::set-output name=dir::$(pip cache dir)" - - name: pip cache - uses: actions/cache@v2 - with: - path: ${{ steps.pip-cache.outputs.dir }} - key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }} + cache: 'pip' - name: Install Xee run: | pip install -e .[tests]