Skip to content

Conversation

@lread
Copy link
Contributor

@lread lread commented Nov 6, 2025

From linter perspective:

  • options are now optional
  • binding-name must be a symbol
  • first arg must be a vector
  • can't have more than 2 values in vector

My initial hook used throws, but I moved to reg-finding! for its better precision and therefore better error squiggles in the editor.

Adding tests for the hook helped me to verify correctness of hook.

Closes #155

Please answer the following questions and leave the below in as part of your PR.

From linter perspective:
- `options` are now optional
- `binding-name` must be a symbol
- first arg must be a vector

My initial hook used throws, but I moved to `reg-finding!` for its better
precision and therefore better error squiggles in the editor.

Adding tests for the hook helped me to verify correctness of hook.

Closes babashka#155
@lread
Copy link
Contributor Author

lread commented Nov 6, 2025

@borkdude lemme know what you think.

Wasn't entirely sure about how linter tests inits the clj-kondo .cache. Seems to work fine, but maybe there's a better or more proper way.

@lread
Copy link
Contributor Author

lread commented Nov 6, 2025

Oh, I should follow test naming as per style guide: https://guide.clojure.style/#test-naming, commit coming.

@borkdude borkdude merged commit 967a764 into babashka:master Nov 7, 2025
12 checks passed
@borkdude
Copy link
Contributor

borkdude commented Nov 7, 2025

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

with-temp-dir clj-kondo config raises an error when called without options

2 participants