Add haskell language support to pre-commit.#2932
Merged
asottile merged 1 commit intopre-commit:mainfrom Jul 22, 2023
Merged
Conversation
9a0d441 to
dd611ea
Compare
asottile
reviewed
Jul 19, 2023
tests/languages/haskell_test.py
Outdated
|
|
||
|
|
||
| class TestRunLanguage: | ||
| def test_run_example_executable(self, example: pathlib.Path) -> None: |
Member
There was a problem hiding this comment.
don't bother with typing in tests -- if the test were going to fail it's already going to fail
371941c to
924c0f0
Compare
Contributor
Author
|
@asottile, thanks for the pointers. Let me know if you have any other stylistic or architectural guidance. This is now passing, and I am confident I do what I need to start playing with other repositories to add hooks for this language. |
924c0f0 to
60273ca
Compare
Member
|
I reworked it a little bit, picked a smaller test dependency, and updated it to match the structure of the rest of the languages and language tests |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

I'm attempting to follow the other languages and documentation in CONTRIBUTING (which seems outdated) to add Haskell support to pre-commit so I can add hooks for several useful Haskell tools.
I'm running into issues when trying to run tests of my new language, and I'm trying to figure out where I'm going wrong. Can someone provide guidance?
I'm assuming the system has Haskell installed already, the same as Python and attempting to follow the documented interface in CONTRIBUTING as well as I can without adding too many things for a first pass. I'm hitting strange errors where my mock project can be listed, but it seems to be something other than the CWD for the installation (no project file found to do the install of '.').
Please let me know if there is more up-to-date documentation or something I should try. Once I pass the tests, I'll be ready for deeper integration with some tools to see how things go.