From 16434de5f61453f8a6690ec3c07033631ac912fe Mon Sep 17 00:00:00 2001 From: Peter Esselius Date: Sun, 14 Jul 2024 23:07:50 +0200 Subject: [PATCH] cache-nix-action --- .github/workflows/ci.yaml | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index cb98abd..4c811f2 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -10,6 +10,15 @@ jobs: steps: - uses: actions/checkout@v4 - uses: DeterminateSystems/nix-installer-action@main - - uses: DeterminateSystems/magic-nix-cache-action@main - - run: nix --extra-experimental-features 'flakes nix-command' path-info --derivation .#nixosConfigurations.adama.config.system.build.toplevel + - uses: nix-community/cache-nix-action@v5 + with: + primary-key: nix-${{ runner.os }}-${{ hashFiles('**/*.nix') }} + restore-prefixes-first-match: nix-${{ runner.os }}- + nix: true + paths: | + /nix/store + ~/.cache/nix + ~root/.cache/nix + + - run: nix --accept-flake-config --extra-experimental-features 'flakes nix-command' path-info --derivation .#nixosConfigurations.adama.config.system.build.toplevel