From 9dc41f22c1b8878c9080c3f579d6c920f7b627d8 Mon Sep 17 00:00:00 2001 From: osbm Date: Fri, 24 Jan 2025 23:56:27 +0300 Subject: [PATCH] add new step to see cache availability --- .github/workflows/test-my-packages.yml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test-my-packages.yml b/.github/workflows/test-my-packages.yml index cf12967..087bf62 100644 --- a/.github/workflows/test-my-packages.yml +++ b/.github/workflows/test-my-packages.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-24.04 strategy: matrix: - nixpkgs: [nixos-unstable, nixpkgs-unstable, master] # TODO: add stable branch once they are available + nixpkgs-branch: [nixos-unstable, nixpkgs-unstable, master] # TODO: add stable branch once they are available # platform: [x86_64-linux, aarch64-linux] #TODO: add aarch64-linux myPackages: # TODO automate this list - python313Packages.runstats @@ -31,5 +31,11 @@ jobs: # extra_nix_config: | # # system = ${{ matrix.platform }} + # i want to create .drv file and check if they exist in the nixos.cache + # if they dont exist, i want to skip the build + + - name: Check if the dependencies are in the cache + run: nix path-info --closure-size --eval-store auto --store https://cache.nixos.org 'github:nixos/nixpkgs/${{ matrix.nixpkgs-branch }}${{ matrix.myPackages }}^*' + - name: Build my packages - run: nix build -L "github:nixos/nixpkgs/${{ matrix.nixpkgs }}#${{ matrix.myPackages }}" + run: nix build -L "github:nixos/nixpkgs/${{ matrix.nixpkgs-branch }}#${{ matrix.myPackages }}"