Files
haskell.nix/test/stack-local-resolver/default.nix
T
Hamish Mackenzie 9e6820cc71 Add haskell-nix.project (and project') (#703)
Generalized version of the `cabalProject` and `stackProject`
functions.

Automatically selects the correct project type based on the
`projectFileName` argument if provided or what files exist in
the `src` directory if no `projectFileName` was specified.

If it cannot be determined which it should use the following
error message is given:

```
error: haskell-nix.project : both `stack.yaml` and `cabal.project` files exist set `projectFileName = "stack.yaml;"` or `projectFileName = "cabal.project";`
```
2020-06-19 20:07:19 +12:00

15 lines
286 B
Nix

{ project', recurseIntoAttrs, testSrc }:
let
project = project' {
src = testSrc "stack-local-resolver";
};
packages = project.hsPkgs;
in recurseIntoAttrs {
ifdInputs = {
inherit (project) stack-nix;
};
inherit (packages.stack-local-resolver.components) library;
}