diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a4be1837d..b31688505 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -123,10 +123,23 @@ jobs: - uses: ./.github/actions/setup-rust with: go: 'true' + go-cache: 'false' + - uses: actions/cache/restore@0057852bfaa89a56745cba8c7296529d2fc39830 # ratchet:actions/cache@v4 + id: go-build-cache + with: + path: ~/.cache/go-build + key: go-build-e2e-smoke-${{ runner.os }}-${{ hashFiles('go-version', 'Cargo.lock', 'crates/**', 'tests/**', 'prelude/**') }} + restore-keys: | + go-build-e2e-smoke-${{ runner.os }}- - run: cargo build -p lisette --locked - run: cargo test -p tests --test e2e_smoke --locked -- --format terse - run: cargo test -p tests --test e2e_learn --locked -- --format terse - run: cargo test -p tests --test e2e_run --locked -- --format terse + - if: github.ref == 'refs/heads/main' && steps.go-build-cache.outputs.cache-hit != 'true' + uses: actions/cache/save@0057852bfaa89a56745cba8c7296529d2fc39830 # ratchet:actions/cache@v4 + with: + path: ~/.cache/go-build + key: ${{ steps.go-build-cache.outputs.cache-primary-key }} stdlib-check: name: Stdlib check