Fork me on GitHub

one step closer to windows support command prompt:

echo (inc) | .\clj-kondo.exe --lint -
:1:1: error: clojure.core/inc is called with 0 args but expects 1
linting took 16ms, errors: 1, warnings: 0
echo '(inc)' | .\clj-kondo.exe --lint -
:1:1: error: clojure.core/inc is called with 0 args but expects 1
linting took 31ms, errors: 1, warnings: 0


@borkdude it appears the following is sufficient for getting IncludeResources to work on windows:

call %GRAALVM_HOME%\bin\native-image.cmd ^
  -jar target/clj-kondo-%CLJ_KONDO_VERSION%-standalone.jar ^
  "-H:Name=clj-kondo" ^
  -H:+ReportExceptionStackTraces ^
  "-J-Dclojure.spec.skip-macros=true" ^
  "" ^
  "-H:IncludeResources=clj_kondo/impl/cache/built_in/.{0,}" ^
  "-H:ReflectionConfigurationFiles=reflection.json" ^
  --initialize-at-build-time  ^
  "-H:Log=registerResource:" ^
  --verbose ^
  --no-fallback ^


From what I'm seeing on CI, this looks pretty good


I'm happy to have confirmation from @filipematossilva that the .exe works under Windows now!

Filipe Silva13:11:45

if you add it to the release assets for releases, the npm package will just pick it up

Filipe Silva13:11:13

btw I haven't been updating the npm package on each of clj-kondo's release... I wanted to automate that, but haven't


no worries, I guess people will start asking if they really need it faster than you are doing it


@marc-omorain maybe there are some Windows users in CircleCI that want to give the clj-kondo.exe a test? Maybe some Calva users, @pez?

Filipe Silva14:11:47

I should make a github action to do that, check the release version of another repo and run a script with the new version


so the npm package is looking for a windows exe and if it's not there it falls back to the jar?

Filipe Silva14:11:03

for npm distributions the 18mb single file might be a problem

Filipe Silva14:11:40

it makes it more likely that the retrieval from the registry will not succeed

Filipe Silva14:11:15

on some CI envs we see that happening with yarn and large packages


I see two potential problems with this script: the entry for windows is not there and the binary is named clj-kondo.exe on Windows (not just clj-kondo)


for now let's just leave it like this


I'll provide the binary via scoop, and when it gives no further problems, we can migrate it to npm

Filipe Silva14:11:27

but yes, there's no url entry for the windows one there

Marc O'Morain14:11:59

We don’t have any Windows developers afaik


@borkdude, just ask for testers in #calva-dev . My experience is that I succeed in recruiting one or two. 😃


I or someone else should really make a flow diagram of how text -> code -> analysis -> linting works in clj-kondo. If someone really really feels like this, please yell. Probably is a good tool to use because it's free and thus friendly for OSS.


have interest in participating, but am in the camp of "needing lots of practice drawing". not sure if i can be much help here.