diff options
Diffstat (limited to 'tvix/build/protos/default.nix')
-rw-r--r-- | tvix/build/protos/default.nix | 21 |
1 files changed, 8 insertions, 13 deletions
diff --git a/tvix/build/protos/default.nix b/tvix/build/protos/default.nix index 790655ac7522..287b513136c9 100644 --- a/tvix/build/protos/default.nix +++ b/tvix/build/protos/default.nix @@ -1,17 +1,12 @@ -{ depot, pkgs, ... }: +{ depot, pkgs, lib, ... }: let - protos = depot.nix.sparseTree { - name = "build-protos"; - root = depot.path.origSrc; - paths = [ - # We need to include castore.proto (only), as it's referred. - ../../castore/protos/castore.proto - ./build.proto - ./rpc_build.proto - ../../../buf.yaml - ../../../buf.gen.yaml - ]; - }; + protos = lib.sourceByRegex depot.path.origSrc [ + "buf.yaml" + "buf.gen.yaml" + # We need to include castore.proto (only), as it's referred. + "^tvix(/castore(/protos(/castore\.proto)?)?)?$" + "^tvix(/build(/protos(/.*\.proto)?)?)?$" + ]; in depot.nix.readTree.drvTargets { inherit protos; |