-
Notifications
You must be signed in to change notification settings - Fork 237
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
Add support for cabal.project.local #632
Conversation
Running `cabal v2-configure` overwrites the `cabal.project.local` file so this change adds the contents onto the end of the `cabal.project` file before running `cabal v2-configure`. You can override this behavior passing `cabalProjectLocal = ""`
I have slightly mixed feelings about this. Conceptually it makes sense to me that haskell.nix should pick this up, since the guiding principle is to do whatever cabal does. But usually I have a As I write that, though, I guess this might be solved by using an appropriate source cleaner? I.e. if you use |
It bypasses the cleaner and goes straight to the file location. We could make it respect the filter in the cleaner, but then we would have to find a way to let it through Perhaps we could rename it |
haskell/cabal#6016 (comment) alleges that the old |
Hmm... IDK. local is local. I see that it would be useful for "local" development/nix build/nix shell, but maybe we don't want cleanGit in that instance anyway? |
The problem is that it ignores the current I think the main thing we have to decide is the default behaviour of Include
Excluded
|
This is a problem we have because we actually have the ability to share builds with CI. Looking at it again, I'm convinced by the benefits. IMO So 👍 to the functionality here. On an implementation point of view, it seems like the cabal config files get treated in two different ways:
Does |
Do not that we still want to have This usecase needs to mesh with this as well. |
Will still be used if it is in the .gitignore
I have updated this PR so both
|
Running `cabal v2-configure` overwrites the `cabal.project.local` file so this change adds the contents onto the end of the `cabal.project` file before running `cabal v2-configure`. You can override this behavior passing `cabalProjectLocal = ""` Treats cabal.project.feeze the same way as `cabal.project` and `cabal.project.local` in that it will still use it if it is filtered by cleanGit. This change also adds `cabalProjectFileName` arg so that we can override the default `cabal.project` name.
Running
cabal v2-configure
overwrites thecabal.project.local
fileso this change adds the contents onto the end of the
cabal.project
file before running
cabal v2-configure
.You can override this behavior passing
cabalProjectLocal = ""