ci: reuse more previous caches (Nix & Stack)
This commit is contained in:
committed by
Wolfgang Walther
parent
310d04065e
commit
a45058ba02
@@ -22,7 +22,9 @@ runs:
|
|||||||
with:
|
with:
|
||||||
key: cache-nix-${{ runner.os }}-id-${{ inputs.cache-id }}-${{ hashFiles('nix/**/*.nix', '.github/actions/setup-nix/*') }}
|
key: cache-nix-${{ runner.os }}-id-${{ inputs.cache-id }}-${{ hashFiles('nix/**/*.nix', '.github/actions/setup-nix/*') }}
|
||||||
restore-keys: |
|
restore-keys: |
|
||||||
cache-nix-${{ runner.os }}-common-
|
cache-nix-${{ runner.os }}-id-${{ inputs.cache-id }}-
|
||||||
|
cache-nix-${{ runner.os }}-id-common-
|
||||||
|
cache-nix-${{ runner.os }}-
|
||||||
- uses: cachix/cachix-action@v14
|
- uses: cachix/cachix-action@v14
|
||||||
with:
|
with:
|
||||||
name: postgrest
|
name: postgrest
|
||||||
|
|||||||
@@ -98,8 +98,6 @@ jobs:
|
|||||||
uses: ./.github/actions/setup-nix
|
uses: ./.github/actions/setup-nix
|
||||||
with:
|
with:
|
||||||
tools: tests withTools
|
tools: tests withTools
|
||||||
# It seems like they are installing the same set of derivations, so we can assign them the same cache id.
|
|
||||||
# This would decrease the amount of caches dowloaded on merge cache step and will prevent disk space issues.
|
|
||||||
cache-id: common
|
cache-id: common
|
||||||
|
|
||||||
- name: Run spec tests
|
- name: Run spec tests
|
||||||
@@ -202,6 +200,8 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: ${{ matrix.cache }}
|
path: ${{ matrix.cache }}
|
||||||
key: cache-stack-${{ runner.os }}-${{ hashFiles('stack.yaml.lock') }}
|
key: cache-stack-${{ runner.os }}-${{ hashFiles('stack.yaml.lock') }}
|
||||||
|
restore-keys: |
|
||||||
|
cache-stack-${{ runner.os }}-
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
if: ${{ matrix.deps }}
|
if: ${{ matrix.deps }}
|
||||||
run: ${{ matrix.deps }}
|
run: ${{ matrix.deps }}
|
||||||
|
|||||||
Reference in New Issue
Block a user