This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-11-21
Channels
- # aleph (2)
- # announcements (2)
- # babashka (10)
- # beginners (117)
- # calva (11)
- # cider (19)
- # clj-kondo (27)
- # cljs-dev (24)
- # cljsjs (1)
- # clojure (73)
- # clojure-europe (3)
- # clojure-italy (2)
- # clojure-nl (47)
- # clojure-spec (23)
- # clojure-uk (28)
- # clojurescript (71)
- # cursive (7)
- # data-science (17)
- # datascript (1)
- # datomic (7)
- # duct (23)
- # emacs (23)
- # fulcro (6)
- # graalvm (41)
- # jobs (2)
- # luminus (1)
- # malli (1)
- # off-topic (151)
- # pathom (1)
- # portkey (10)
- # re-frame (12)
- # reitit (17)
- # shadow-cljs (158)
- # spacemacs (14)
- # sql (8)
- # tools-deps (17)
- # xtdb (9)
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
powershell:
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" ^
"-J-Dclojure.compiler.direct-linking=true" ^
"-H:IncludeResources=clj_kondo/impl/cache/built_in/.{0,}" ^
"-H:ReflectionConfigurationFiles=reflection.json" ^
--initialize-at-build-time ^
"-H:Log=registerResource:" ^
--verbose ^
--no-fallback ^
"-J-Xmx3g"
Experimental new Windows build: https://ci.appveyor.com/api/buildjobs/oqwh72id7x3q8es2/artifacts/clj-kondo-2019.11.08-SNAPSHOT-windows-amd64.zip. Please give it a shot.
I'm happy to have confirmation from @filipematossilva that the .exe works under Windows now!
if you add it to the release assets for releases, the npm package will just pick it up
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?
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?
for npm distributions the 18mb single file might be a problem
it makes it more likely that the retrieval from the registry will not succeed
on some CI envs we see that happening with yarn and large packages
I see two potential problems with this script: https://github.com/filipesilva/clj-kondo/blob/e4e48a1f2f1ae01dbc2ea4d362b4f44da579f743/index.js#L22 the entry for windows is not there and the binary is named clj-kondo.exe on Windows (not just clj-kondo)
I'll provide the binary via scoop, and when it gives no further problems, we can migrate it to npm
https://github.com/filipesilva/clj-kondo/blob/master/bin/clj-kondo takes care of the exe bit
but yes, there's no url entry for the windows one there
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 http://draw.io is a good tool to use because it's free and thus friendly for OSS.