diff --git a/.github/workflows/apple.yml b/.github/workflows/apple.yml index afe7add3..f55dba44 100644 --- a/.github/workflows/apple.yml +++ b/.github/workflows/apple.yml @@ -14,18 +14,7 @@ jobs: runs-on: 'macos-13' steps: - uses: actions/checkout@v4 - - - name: Emit rustc version - run: | - rustc --version > .rustc-version - - - uses: actions/cache@v4 - with: - path: | - ~/.cargo/registry - ~/.cargo/git - target - key: ${{ runner.os }}-pythonbuild-${{ hashFiles('Cargo.lock', '.rustc-version') }} + - uses: Swatinem/rust-cache@v2 - name: Build run: | diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 622f49e8..f1a59da7 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -19,18 +19,7 @@ jobs: sudo apt install -y --no-install-recommends libssl-dev pkg-config - uses: actions/checkout@v4 - - - name: Emit rustc version - run: | - rustc --version > .rustc-version - - - uses: actions/cache@v4 - with: - path: | - ~/.cargo/registry - ~/.cargo/git - target - key: ${{ runner.os }}-pythonbuild-${{ hashFiles('Cargo.lock', '.rustc-version') }} + - uses: Swatinem/rust-cache@v2 - name: Build run: | diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index ef9e1f62..810409e4 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -14,18 +14,7 @@ jobs: runs-on: 'windows-2022' steps: - uses: actions/checkout@v4 - - - name: Emit rustc version - run: | - rustc --version > .rustc-version - - - uses: actions/cache@v4 - with: - path: | - C:/Rust/.cargo/registry - C:/Rust/.cargo/git - target - key: ${{ runner.os }}-pythonbuild-${{ hashFiles('Cargo.lock', '.rustc-version') }} + - uses: Swatinem/rust-cache@v2 - name: Build run: |