Skip to content
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

Show "Add dependency" Code Action only if there is no package.yaml file #4400

Open
fendor opened this issue Sep 12, 2024 · 0 comments
Open
Labels
component: hls-cabal-plugin Issues related to the hls-cabal-plugin Hackathon This issue is suitable for hackathon sessions type: bug Something isn't right: doesn't work as intended, documentation is missing/outdated, etc..

Comments

@fendor
Copy link
Collaborator

fendor commented Sep 12, 2024

If the project is a stack project, there might be a package.yaml file. Adding a dependency to the generated .cabal file is a bad idea, as it will lead to annoying behaviour: Stack will no longer re-generate the .cabal file, so changes to package.yaml are not propagated to the .cabal file any more.

solution:

When looking for the .cabal file in the filesystem, check there is no package.yaml file next to it.

@fendor fendor added type: bug Something isn't right: doesn't work as intended, documentation is missing/outdated, etc.. status: needs triage component: hls-cabal-plugin Issues related to the hls-cabal-plugin and removed status: needs triage labels Sep 12, 2024
@fendor fendor added the Hackathon This issue is suitable for hackathon sessions label Oct 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: hls-cabal-plugin Issues related to the hls-cabal-plugin Hackathon This issue is suitable for hackathon sessions type: bug Something isn't right: doesn't work as intended, documentation is missing/outdated, etc..
Projects
None yet
Development

No branches or pull requests

1 participant