-
Notifications
You must be signed in to change notification settings - Fork 62
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 non-standard cabal.project file locations to cabal cradles #357
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems nice!
projectLocationOrDefault :: CradleProjectConfig -> [FilePath] | ||
projectLocationOrDefault = \case | ||
NoExplicitConfig -> ["cabal.project", "cabal.project.local"] | ||
(ExplicitConfig prjFile) -> [prjFile, prjFile <.> "local"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should the explicit config include the .local file? Or will cabal pick it up automatically if it has the main project file?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is used for cabal cradle dependencies, e.g. telling HLS that the cradle needs to be reloaded if either of the two changes. IIRC, that behaviour is in line with cabal.
However, the name is misleading.
@fendor what's the status on this PR? Do you think you can spare some time to solve the conflicts / rebase it? |
@Kleidukos Sure, do you have a use-case for this feature? |
@fendor I personally don't, but a post on the Discourse could certainly gauge the interest for this feature :) |
023067d
to
1f8d512
Compare
Add parser tests for cabal.project files Add bios tests for cabal.project files
1f8d512
to
91c7348
Compare
Add parser tests for non-standard
cabal.project
file locationsAdd bios tests for projects with non-standard
cabal.project
file locationsFollows the same structure as
stackYaml
feature for stack cradles.Fixes #263