> src = [ ./subproject-A/schema.sql ./subproject-A/lib ]; Each of the files you mentioned here will be stored in a separate store path. You could write a simple function that takes a list of derivations and copies the contents of those derivations in a new output.
On Thu, Feb 16, 2017 at 1:14 PM, Thomas Hunger <tehun...@gmail.com> wrote: > Hi, > > I am consistently struggling with the following in nix: I have a > repository and I want to specify derivations for some local sub-projects. > The obvious solution is > > src = ./subproject-A; > > But that pulls in everything in that directory, including build artifacts, > or random intermediate data files. > > Another solution is > > src = sourceFilesBySuffices ./subproject-A [".cabal" ".hs"]; > > Which works reasonably well but introduces this weird dance where I suffix > files so they can be matched by sourceFilesBySuffices. Mostly I want to do > this: > > src = [ ./subproject-A/schema.sql ./subproject-A/lib ]; > > Or even get all the files checked into git: > > src = gitFiles ./subproject-A; # does not work > > I was wondering whether any of you have this issue, and if you do: how do > you solve it? > > ~ > > (see also https://github.com/NixOS/nix/issues/885) > > _______________________________________________ > nix-dev mailing list > nix-dev@lists.science.uu.nl > http://lists.science.uu.nl/mailman/listinfo/nix-dev > >
_______________________________________________ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev