-
Notifications
You must be signed in to change notification settings - Fork 701
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
new-{build,repl}
incorrectly looks at any directory that exists for dependencies
#4797
Comments
@TomMD does your |
@hvr There is no I've patched the example to be a bit more in-your-face with the issue but at a new repo location. Observe:
So we should build
|
Well, that's the problem then :-) Explanation: if there is no
which is combined with the one from your
which explains what you're seeing. What's not properly documented is when these defaults are relevant: these defaults only matter when you don't have any |
I'd argue this is a mis-feature which should be removed. It is bound to cause lots of confusion and I don't know of anyone using new-build in a manner that implicitly includes the immediate subdirectories. An unhappy alternative is to add an additional feature of either:
|
@TomMD I symphatise with your complaint, as I've been confused myself when I started using early The original rationale for doing it this way (iirc -- I could be wrong; it was @dcoutts who invented the
tbh, I think that one's really unhappy, as it'd be imho rather non-obvious/too magically. I'd rather sympathise with having |
|
As demonstrated by @aisamanra's minimum example.
If you have a cabal project with the
cabal.project.local
of:And there exists a spurious
./foo
copy of the package in addition to thedeps/foo
then new-build will try to use the top level directory instead of (in addition to? unsure) the pointed-to directory nested indeps
.The text was updated successfully, but these errors were encountered: