Skip to content

Set ghcOptions on all local pacakges #1282

Closed
@kirelagin

Description

@kirelagin

I think, it is pretty normal to use haskell.nix on the CI, and also it is a good idea to have -Werror on the CI, but only for local (project) packages. Stack supports this by allowing one to set options on a fake package called $local, but, arguably, stack.yaml is not the right place to have this, since during development you don’t actually want to have -Werror.

In haskell.nix it feels like some combination of modules on e.g. stackProject and haskellLib.selectProjectPackages could do the trick, but this is, obviously, a very bad idea and won’t work because of recursion. The problem is that we need to have the result of stackProject to get at list of local packages, but then what we want to craft based on this output is actually one of the inputs of the function.

Prior art:

Metadata

Metadata

Assignees

Labels

preservedKeep stale bot away

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions