diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index f9375476f5..b9f1b35e6a 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -39,6 +39,8 @@ jobs: with: cache-targets: true # cache build artifacts cache-bin: true # cache the ~/.cargo/bin directory + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - name: Generate code coverage (including doc tests) run: | cargo llvm-cov --all-features --workspace --no-report nextest diff --git a/.github/workflows/fuzz.yml b/.github/workflows/fuzz.yml index a44010700f..40c323f6c4 100644 --- a/.github/workflows/fuzz.yml +++ b/.github/workflows/fuzz.yml @@ -26,6 +26,8 @@ jobs: with: cache-targets: true # cache build artifacts cache-bin: true # cache the ~/.cargo/bin directory + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - run: | set -e # cargo bolero list outputs {"package":"package-name","test":"test-name"} diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index a74cdabfff..4a47db8a2d 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -33,6 +33,8 @@ jobs: with: cache-targets: true # cache build artifacts cache-bin: true # cache the ~/.cargo/bin directory + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - run: cargo fmt --all -- --check clippy: name: "clippy #${{ matrix.platform }} ${{ matrix.rust_version }}" @@ -54,6 +56,8 @@ jobs: with: cache-targets: true # cache build artifacts cache-bin: true # cache the ~/.cargo/bin directory + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - name: Run clippy on ${{ matrix.platform }} ${{ matrix.rust_version }} shell: bash run: | diff --git a/.github/workflows/miri.yml b/.github/workflows/miri.yml index 51860ea42e..c88de7d9b9 100644 --- a/.github/workflows/miri.yml +++ b/.github/workflows/miri.yml @@ -30,6 +30,8 @@ jobs: with: cache-targets: true # cache build artifacts cache-bin: true # cache the ~/.cargo/bin directory + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - run: MIRIFLAGS="-Zmiri-disable-isolation" cargo miri nextest run --partition count:${{ matrix.partition }}/5 # We need to disable isolation because # "unsupported operation: `clock_gettime` with `REALTIME` clocks not available when isolation is enabled" diff --git a/.github/workflows/pr-metadata-docs-and-deps.yml b/.github/workflows/pr-metadata-docs-and-deps.yml index 0406c8658c..5b9ec53a65 100644 --- a/.github/workflows/pr-metadata-docs-and-deps.yml +++ b/.github/workflows/pr-metadata-docs-and-deps.yml @@ -103,6 +103,8 @@ jobs: - uses: Swatinem/rust-cache@f13886b937689c021905a6b90929199931d60db1 # v2.8.1 with: cache-targets: true + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - uses: dtolnay/rust-toolchain@stable - name: Check missing docs id: missing-docs @@ -274,6 +276,8 @@ jobs: - uses: Swatinem/rust-cache@f13886b937689c021905a6b90929199931d60db1 # v2.8.1 with: cache-targets: true + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - uses: dtolnay/rust-toolchain@stable - uses: taiki-e/cache-cargo-install-action@7447f04c51f2ba27ca35e7f1e28fab848c5b3ba7 # 2.3.1 with: diff --git a/.github/workflows/pr-title-semver-check.yml b/.github/workflows/pr-title-semver-check.yml index 288f9dbfd7..a510027de4 100644 --- a/.github/workflows/pr-title-semver-check.yml +++ b/.github/workflows/pr-title-semver-check.yml @@ -99,6 +99,8 @@ jobs: uses: Swatinem/rust-cache@f13886b937689c021905a6b90929199931d60db1 # 2.8.1 with: cache-targets: true + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - name: Install dependencies run: | diff --git a/.github/workflows/release-proposal-dispatch.yml b/.github/workflows/release-proposal-dispatch.yml index f69e238aa8..8488b50b19 100644 --- a/.github/workflows/release-proposal-dispatch.yml +++ b/.github/workflows/release-proposal-dispatch.yml @@ -142,6 +142,8 @@ jobs: - uses: Swatinem/rust-cache@f13886b937689c021905a6b90929199931d60db1 # v2.8.1 with: cache-targets: true + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - uses: dtolnay/rust-toolchain@nightly with: toolchain: nightly-2026-02-08 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 964fcbae36..262c9bdd1e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -53,6 +53,8 @@ jobs: with: cache-targets: true # cache build artifacts cache-bin: true # cache the ~/.cargo/bin directory + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - name: "Remove nextest CI report" shell: bash run: rm -rf target/nextest/ci/junit.xml @@ -193,6 +195,8 @@ jobs: with: cache-targets: true # cache build artifacts cache-bin: true # cache the ~/.cargo/bin directory + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - name: "Generate profiling FFI" shell: bash env: @@ -308,6 +312,8 @@ jobs: with: cache-targets: true # cache build artifacts cache-bin: true # cache the ~/.cargo/bin directory + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - run: cargo install cross || true - run: cross build --workspace --target x86_64-unknown-linux-gnu --exclude builder - run: cross test --workspace --features libdd-crashtracker/generate-unit-test-files --target x86_64-unknown-linux-gnu --exclude builder -- --skip "::single_threaded_tests::" --skip "tracing_integration_tests::" diff --git a/.github/workflows/verify-proto-files.yml b/.github/workflows/verify-proto-files.yml index 6a9a00b525..9d878711e0 100644 --- a/.github/workflows/verify-proto-files.yml +++ b/.github/workflows/verify-proto-files.yml @@ -52,6 +52,8 @@ jobs: with: cache-targets: true # cache build artifacts cache-bin: true # cache the ~/.cargo/bin directory + shared-key: shared-${{ runner.os }} + save-if: ${{ github.ref == 'refs/heads/main' }} - name: diff pb.rs working-directory: libdd-trace-protobuf run: |