Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[nix-local-build] Allow specifying freeze file for other commands #3587

Open
acfoltzer opened this issue Jul 21, 2016 · 4 comments
Open

[nix-local-build] Allow specifying freeze file for other commands #3587

acfoltzer opened this issue Jul 21, 2016 · 4 comments

Comments

@acfoltzer
Copy link
Collaborator

Right now the constraints file generated by new-freeze is called cabal.project.freeze, and the D.C.ProjectConfig code looks for it by that name. This makes it difficult to support multiple compiler versions in a project, though. The current workaround is to have CI symlink to the appropriate freeze file based on an environment variable, but this is pretty clunky.

Would it be possible to add a --freeze-file=foo.freeze option to the relevant commands? Would it make more sense to generalize to --extra-config-file, since these the freeze file is just mappended to the other config files?

@gbaz
Copy link
Collaborator

gbaz commented Jul 21, 2016

We actually have an --extra-config-file type option added for the standard build setup already as per: #2820

The only question I have (haven't tested) is if this gets handled by the nix-local-build stuff or if it needs to be plugged in. I suspect the latter?

@dcoutts
Copy link
Contributor

dcoutts commented Jul 24, 2016

@acfoltzer I was thinking of making the includes into the main cabal.project fully explicit, which would 1. make it clearer what files are used and how they're combined, 2. make it possible to use more complex setups. In that case it's not needed to have a freeze-file option except for when generating one, to produce one with the non-default name.

@phadej
Copy link
Collaborator

phadej commented Jul 24, 2016

Includes could be optional via if impl(ghc == 7.10.*)? Is there a ticket for this? Would be cool!

I suspect that might depend on my/duncan's parsec stuff...

@hasufell
Copy link
Member

bump!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants