From cc44ce01d3e0f2e82d4352c5e2159451a89016d4 Mon Sep 17 00:00:00 2001 From: Binh Duc Tran Date: Sun, 24 Mar 2024 17:31:57 +0700 Subject: [PATCH] ci(cache): enhance restore-keys --- .github/workflows/ci.yml | 4 ++++ .github/workflows/gh-page.yml | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bc15fd7..f38efc5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -38,6 +38,8 @@ jobs: ~/.cargo/git/db/ target/ key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.lock') }} + restore-keys: | + ${{ runner.os }}-cargo - name: Cache perseus builds uses: actions/cache@v4 @@ -45,6 +47,8 @@ jobs: path: | dist/ key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.lock') }}-${{ hashFiles('src/**/*', 'static/**/*') }} + restore-keys: | + ${{ runner.os }}-cargo - name: Set up Bun uses: oven-sh/setup-bun@v1 diff --git a/.github/workflows/gh-page.yml b/.github/workflows/gh-page.yml index 49bb297..feb466f 100644 --- a/.github/workflows/gh-page.yml +++ b/.github/workflows/gh-page.yml @@ -50,6 +50,8 @@ jobs: ~/.cargo/git/db/ target/ key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.lock') }} + restore-keys: | + ${{ runner.os }}-cargo - name: Cache perseus builds uses: actions/cache@v4 @@ -57,6 +59,8 @@ jobs: path: | dist/ key: ${{ runner.os }}-cargo-build-${{ hashFiles('Cargo.lock') }}-${{ hashFiles('src/**/*', 'static/**/*') }} + restore-keys: | + ${{ runner.os }}-cargo-build - name: Set up Bun uses: oven-sh/setup-bun@v1