diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index 85acafdaecca..a62817b6be29 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -18,9 +18,10 @@ jobs: - name: Install Dependencies run: sudo make install-deps - name: Setup sccache - uses: hanabi1224/sccache-action@9a6eaffba482beb3b919ce68d12f2559b4db12b3 + uses: hanabi1224/sccache-action@6e1e19ee4f8c1a2efec1f23a41dd2f9b75c7ee84 with: cache-key: ${{ runner.os }}-sccache-codecov-${{ hashFiles('rust-toolchain.toml') }} + # cache-save: ${{ github.event_name != 'pull_request' }} - name: Run cargo-llvm-cov uses: taiki-e/install-action@cargo-llvm-cov - name: Generate code coverage diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index e69aecdcb4ed..aa3a74d53078 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -28,7 +28,7 @@ jobs: # Fail action on broken links fail: true - name: Setup sccache - uses: hanabi1224/sccache-action@9a6eaffba482beb3b919ce68d12f2559b4db12b3 + uses: hanabi1224/sccache-action@6e1e19ee4f8c1a2efec1f23a41dd2f9b75c7ee84 with: cache-key: ${{ runner.os }}-sccache-${{ hashFiles('rust-toolchain.toml') }} cache-save: false diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 06e90ec8dd7e..21b5faf0fe39 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -14,7 +14,7 @@ jobs: include: - os: ubuntu-latest file: forest-${{ github.ref_name }}-linux-amd64.zip - - os: macos-latest + - os: macos-12 file: forest-${{ github.ref_name }}-macos-amd64.zip steps: - name: Checkout Sources diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index ca3e81f67fc3..317b783142ad 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -26,7 +26,7 @@ jobs: - name: Checkout Sources uses: actions/checkout@v3 - name: Setup sccache - uses: hanabi1224/sccache-action@9a6eaffba482beb3b919ce68d12f2559b4db12b3 + uses: hanabi1224/sccache-action@6e1e19ee4f8c1a2efec1f23a41dd2f9b75c7ee84 with: # reuse build cache from calibnet sync check which is built with release profile cache-key: ${{ runner.os }}-sccache-test-${{ hashFiles('rust-toolchain.toml') }} @@ -49,7 +49,7 @@ jobs: - name: Apt Dependencies run: sudo make install-deps - name: Setup sccache - uses: hanabi1224/sccache-action@9a6eaffba482beb3b919ce68d12f2559b4db12b3 + uses: hanabi1224/sccache-action@6e1e19ee4f8c1a2efec1f23a41dd2f9b75c7ee84 with: cache-key: ${{ runner.os }}-sccache-${{ hashFiles('rust-toolchain.toml') }} cache-save: false @@ -70,12 +70,14 @@ jobs: steps: - name: Checkout Sources uses: actions/checkout@v3 - - name: Rust Cache - uses: Swatinem/rust-cache@v2 - timeout-minutes: ${{ fromJSON(env.CACHE_TIMEOUT_MINUTES) }} - continue-on-error: true + - uses: actions/cache@v3 + with: + path: | + ~/.cargo/bin/ + key: ${{ runner.os }}-audit-cargo-bin-${{ hashFiles('rust-toolchain.toml') }} - name: Install Audit run: cargo install cargo-audit + continue-on-error: true - name: Run Audit run: make audit @@ -86,7 +88,7 @@ jobs: - name: Checkout Sources uses: actions/checkout@v3 - name: Setup sccache - uses: hanabi1224/sccache-action@9a6eaffba482beb3b919ce68d12f2559b4db12b3 + uses: hanabi1224/sccache-action@6e1e19ee4f8c1a2efec1f23a41dd2f9b75c7ee84 with: cache-key: ${{ runner.os }}-sccache-${{ hashFiles('rust-toolchain.toml') }} cache-save: false @@ -110,12 +112,14 @@ jobs: steps: - name: Checkout Sources uses: actions/checkout@v3 - - name: Rust Cache - uses: Swatinem/rust-cache@v2 - timeout-minutes: ${{ fromJSON(env.CACHE_TIMEOUT_MINUTES) }} - continue-on-error: true + - uses: actions/cache@v3 + with: + path: | + ~/.cargo/bin/ + key: ${{ runner.os }}-spellcheck-cargo-bin-${{ hashFiles('rust-toolchain.toml') }} - name: Install spellcheck run: cargo install cargo-spellcheck + continue-on-error: true - name: Run Spellcheck run: make spellcheck @@ -124,22 +128,15 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-latest, macos-latest] + os: [ubuntu-latest, macos-12] steps: - name: Checkout Sources uses: actions/checkout@v3 - - name: Setup sccache Linux - uses: hanabi1224/sccache-action@9a6eaffba482beb3b919ce68d12f2559b4db12b3 - if: startsWith(matrix.os, 'Ubuntu') - with: - arch: x86_64-unknown-linux-musl - cache-key: ${{ runner.os }}-sccache-${{ hashFiles('rust-toolchain.toml') }} - - name: Setup sccache MACOS - uses: hanabi1224/sccache-action@9a6eaffba482beb3b919ce68d12f2559b4db12b3 - if: startsWith(matrix.os, 'macOS') + - name: Setup sccache + uses: hanabi1224/sccache-action@6e1e19ee4f8c1a2efec1f23a41dd2f9b75c7ee84 with: - arch: x86_64-apple-darwin cache-key: ${{ runner.os }}-sccache-${{ hashFiles('rust-toolchain.toml') }} + # cache-save: ${{ github.event_name != 'pull_request' }} - name: Install Linux Dependencies if: startsWith(matrix.os, 'Ubuntu') run: | @@ -169,9 +166,10 @@ jobs: - name: Install Dependencies run: sudo make install-deps - name: Setup sccache - uses: hanabi1224/sccache-action@9a6eaffba482beb3b919ce68d12f2559b4db12b3 + uses: hanabi1224/sccache-action@6e1e19ee4f8c1a2efec1f23a41dd2f9b75c7ee84 with: cache-key: ${{ runner.os }}-sccache-test-${{ hashFiles('rust-toolchain.toml') }} + # cache-save: ${{ github.event_name != 'pull_request' }} - name: build and install binaries run: make install env: