Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Add Code Action for adding a module to your project's cabal file #4617

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

Merged
fendor merged 1 commit into haskell:master from VeryMilkyJoe:feature/cabal-add-module
Aug 7, 2025

Conversation

Copy link
Collaborator

@VeryMilkyJoe VeryMilkyJoe commented Jun 7, 2025
edited
Loading

For diagnostics complaining about the current haskell module being unknown, we now offer all possible code actions to add the module to a field in the responsible cabal file.

Additionally, this PR refactors the cabal-plugin into smaller modules and also refactors the add-package feature to have some shared functions to be used for both add-package and add-module.

Thank you to @Bodigrim for the changes in cabal-add that made it possible to implement this feature without a huge amount of pain!

Screencast.From.2025年06月07日.17-49-54.mp4

VeryMilkyJoe, jian-lin, fendor, dschrempf, davidgarland, fishtreesugar, and Bodigrim reacted with hooray emoji
Copy link
Contributor

@VeryMilkyJoe please upgrade to the latest commit of cabal-add, Bodigrim/cabal-add@d831980. Once you confirm that it works well, I'll make a release.

@VeryMilkyJoe VeryMilkyJoe force-pushed the feature/cabal-add-module branch 2 times, most recently from c40661e to 56144e4 Compare June 16, 2025 09:44
Copy link
Collaborator Author

@VeryMilkyJoe please upgrade to the latest commit of cabal-add, Bodigrim/cabal-add@d831980. Once you confirm that it works well, I'll make a release.

Done and all tests that matter are green :)

Copy link
Contributor

VeryMilkyJoe reacted with hooray emoji

Copy link
Collaborator Author

In my opinion, this is in a merge ready state, unless anyone wants to look over it again 🙃 @fendor?

@VeryMilkyJoe VeryMilkyJoe force-pushed the feature/cabal-add-module branch 4 times, most recently from c508085 to ec0b496 Compare August 7, 2025 09:37
Copy link
Collaborator

@fendor fendor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, final cleanup round

VeryMilkyJoe reacted with thumbs up emoji
For diagnostics complaining about the current module being unknown,
we now offer code actions to add the module to any possible field in
the responsible cabal file.
Additionally, refactor the cabal-plugin into smaller modules and
refactor the add-package feature to have some shared functions to be
used for both add-package and add-module.
@fendor fendor merged commit 4d309d5 into haskell:master Aug 7, 2025
36 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@fendor fendor fendor approved these changes

@michaelpj michaelpj Awaiting requested review from michaelpj michaelpj is a code owner

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /