From 90dd57f75dc762e369e447fdec264c7c0b17bb6f Mon Sep 17 00:00:00 2001 From: Ophestra Umiker Date: Wed, 18 Dec 2024 23:20:25 +0900 Subject: [PATCH] workflows: cache nix store Signed-off-by: Ophestra Umiker --- .gitea/workflows/nix.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.gitea/workflows/nix.yml b/.gitea/workflows/nix.yml index 3193db4..36651a5 100644 --- a/.gitea/workflows/nix.yml +++ b/.gitea/workflows/nix.yml @@ -22,6 +22,17 @@ jobs: system-features = nixos-test benchmark big-parallel kvm enable_kvm: true + - name: Ensure environment + run: >- + apt-get update && apt-get install -y sqlite3 + if: ${{ runner.os == 'Linux' }} + + - name: Restore Nix store + uses: nix-community/cache-nix-action@v5 + with: + primary-key: nix-${{ runner.os }}-${{ hashFiles('**/*.nix') }} + restore-prefixes-first-match: nix-${{ runner.os }}- + - name: Run tests run: | nix --print-build-logs --experimental-features 'nix-command flakes' flake check --all-systems