diff options
author | Vincent Ambo <mail@tazj.in> | 2023-07-13T21·12+0300 |
---|---|---|
committer | tazjin <tazjin@tvl.su> | 2023-08-08T20·11+0000 |
commit | fcda0682357f1ec531c494dac5aa49ba8ae8851a (patch) | |
tree | a196355edfcd975bdd42eaf7ab25bfa3e110abd5 /users | |
parent | 33fa42a1a33dd0e5cae2573f764f26a73b6ad72e (diff) |
feat(nix/sparseTree): add optional `name` argument r/6472
This allows pinning the name of the sparse tree derivation, which stops the continous rebuilding of tvix-store-proto dependents. I've opted to let the function take an attribute set instead and refactored the call sites appropriately. Change-Id: I3e57785094b1adbfffa24caf9f1c3384844fa200 Reviewed-on: https://cl.tvl.fyi/c/depot/+/8965 Reviewed-by: grfn <grfn@gws.fyi> Tested-by: BuildkiteCI Reviewed-by: sterni <sternenseemann@systemli.org>
Diffstat (limited to 'users')
-rw-r--r-- | users/grfn/xanthous/server/default.nix | 11 | ||||
-rw-r--r-- | users/tazjin/tgsa/default.nix | 13 |
2 files changed, 15 insertions, 9 deletions
diff --git a/users/grfn/xanthous/server/default.nix b/users/grfn/xanthous/server/default.nix index fbb5ccd26920..572230a56c5e 100644 --- a/users/grfn/xanthous/server/default.nix +++ b/users/grfn/xanthous/server/default.nix @@ -10,10 +10,13 @@ depot.third_party.naersk.buildPackage { # Workaround for a potential Nix bug related to restricted eval. # See https://github.com/nix-community/naersk/issues/169 - root = depot.nix.sparseTree ./. [ - ./Cargo.toml - ./Cargo.lock - ]; + root = depot.nix.sparseTree { + root = ./.; + paths = [ + ./Cargo.toml + ./Cargo.lock + ]; + }; passthru = { docker = import ./docker.nix args; diff --git a/users/tazjin/tgsa/default.nix b/users/tazjin/tgsa/default.nix index e413c99116fb..063781047a74 100644 --- a/users/tazjin/tgsa/default.nix +++ b/users/tazjin/tgsa/default.nix @@ -1,11 +1,14 @@ { depot, pkgs, ... }: depot.third_party.naersk.buildPackage { - src = depot.nix.sparseTree ./. [ - ./Cargo.lock - ./Cargo.toml - ./src - ]; + src = depot.nix.sparseTree { + root = ./.; + paths = [ + ./Cargo.lock + ./Cargo.toml + ./src + ]; + }; buildInputs = with pkgs; [ pkg-config |