-
-
Notifications
You must be signed in to change notification settings - Fork 15.3k
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
haskell-modules: add callCabal2nixWithOptions. #44424
Conversation
Looks related to #42658 (I’m not in the position to judge whether it’s better or worse than that). |
Bumping for review, please. |
@peti @ryantm @roberth like @cocreature mentions this is indeed an alternative to #42658. Advantages of #42658 compared to this PR:
Disadvantages #42658 compared to this PR:
I would go for #42658 if it introduces some documentation. What do you think? |
It's fine with me, as long as one of them gets merged soon :) |
I have no preference. |
I prefer this one, becuase it seems the least path of resistance to actually get moving with this, and this has already sat for quite a while. 😃 |
@dhess @basvandijk I think we should bite the bullet on this, but also rewrite the function to take an argset instead of multiple arguments, such that next time, we can hide the addition of some field from the user without introducing |
@srhb I agree we should bite the bullet and I also think we should backport this to With regards to your point about the argset argument, do you mean something like:
|
@basvandijk I was actually considering
This way it becomes a uniform invocation no matter what we add in the future. But if it's too radical a change, I don't feel strongly about it. I just thought it could help future-proof a bit. |
@srhb I think all |
Fixes #44377.
Motivation for this change
haskellSrc2nix
supports callingcabal2nix
with extra options, but there is no way to do this viacallCabal2nix
. This adds a new function,callCabal2nixWithOptions
, which supports those extra options.Things done
sandbox
innix.conf
on non-NixOS)nix-shell -p nox --run "nox-review wip"
./result/bin/
)nix path-info -S
before and after)