Fork me on GitHub
#clj-kondo
<
2020-09-08
>
borkdude20:09:43

I'm currently (re)searching a solution to the following: Clj-kondo will support :config-paths in the next release which is a list of directories with additional config. This opens up the possibility of a tool that scans your classpath for library specific clj-kondo configs, spits them out to directories in .clj-kondo, so clj-kondo can pick up on those. What should be the directory structure in which libs bundle their clj-kondo config? E.g. a library repo could have:

resources/clj-kondo-config/rum/rum/config.edn
resources/clj-kondo-config/rum/rum/hooks/*.clj
and a tool would scan the classpath, detect all the clj-kondo/*/* directories, spit them out to:
$project/.clj-kondo/configs/rum/rum/config.edn
$project/.clj-kondo/configs/rum/rum/hooks/*.clj
and clj-kondo will implicitly add configs/*/* to the :config-paths. If anyone sees a problem with this or has other ideas, I'd like to hear them. This is for #992.

borkdude20:09:19

(this tool can then become part of your normal dependencies, much like a lein plugin, or deps.edn alias tool)