Ended up adding an exclusion to .clj-kondo/config.edn
for now.
$ clj-kondo --lint project.clj
zsh: segmentation fault (core dumped) clj-kondo --lint project.clj
Where should I start debugging?@ackerleytng are you using the static Linux binary by any chance?
I was! I switched to the regular one and it worked.
1FYI, the static one is meant for OSes like alpine which uses musl. On others is a better idea to use the dynamic one. Static binaries have unforeseen issues unfortunately 😕
@ezmiller77 Unresolved var is usually because some other namespace you are using defines vars using some unknown macro
You can exclude that namespace using :unresolved-var {:exclude [the.ns]}}
GH actions by default failed if exit code is not zero. You can wrap call to clj-kondo in a script which will catch exit code, analyze it and transform it to zero in case there's only warnings.
echo '(def x (def x 1))' | clj-kondo --lint - || if [[ $? = 2 ]]; then exit 0; else exit $?; fi
this snippet pipes output of clj-kondo to simple if/else expression which is transforming exit code 2 (more than one warning found but no errors) to exit 0 indicating that this should be OK result in the scope of GH actions.I was! I switched to the regular one and it worked.
1