hey there, i installed clj-kondo on a shared ubuntu server i don’t have sudo access to. the install seemed fine with using the —dir command but when i try to run it i get this error: clj-kondo: error while loading shared libraries: cannot make segment writable for relocation: Permission denied
@tech Maybe you could download the bash script and debug it: https://github.com/borkdude/clj-kondo/blob/master/script/install-clj-kondo
All the installer does is basically download the zip file, extract it and put the binary on your path
the install script worked ok... i was running just clj-kondo -h
when i got the error
oh, that's weird. I'm not sure what's going on there
must be some directory it wants... not sure either. i can keep poking around at it
@tech after some googling I found this: https://linux-tips.com/t/cannot-make-segment-writable-for-relocation-error/481
oh interesting, doubt i will be able to run that since i don’t have sudo on this shared machine
Maybe you can run clj-kondo via docker or via the JVM version
might be able to install a local JVM too with jenv
Is there a way after writing hooks for a library to expose them to other kondo users who use macros the from my library?
@ben.sless Yes. This is a new feature that's been implemented since the previous release: https://github.com/borkdude/clj-kondo/blob/master/doc/config.md#exporting-and-importing-configuration
Excellent, thanks 🙏
I'm trying to add the fulcro config. I followed the instructions at https://github.com/clj-kondo/config, but there is no .clj-kondo/configs/
folder present after the clojure -A:clj-kondo/config --lib fulcro
command appears to complete successfully.
@randumbo Did you have a .clj-kondo
directory prior to that?
Yes, I did.
OK, I see there's a bug in there. Let me fix it
Fixed.
Thanks very much. Folder is there now.
I still see warnings show up in places like defmutation
, where it shows error| unresolved symbol action
and other similar warnings. My understanding was that adding the fulcro configs should eliminate some or all of those warnings.
Ah. Currently the fulcro support is a bit sparse. It only contains:
{:lint-as {com.fulcrologic.fulcro.components/defsc clojure.core/defn}}
But the config lib is open for contributions so if more people find out the right config, everyone will profit.
I'm not using fulcro myself at the moment, so I have no idea how the API works
Got it. Appreciate the help. I think I saw a few mentions in the Fulcro docs about setting this sort of thing up in Cursive. I'll see if I can copy it over.
People could also contribute the config to fulcro itself. It can then be imported from the classpath: https://github.com/borkdude/clj-kondo/blob/master/doc/config.md#exporting-and-importing-configuration
Is there a good way to configure as->
to not trigger an error? I’ve tried {:lint-as {clojure.core/as-> clojure.core/->}}
but it still flags the first are to as->
as an unresolved symbol.
@jkrasnay as->
should be fully supported. can you please post a repro of the your problem as a standalone example?
Also please specify which version of clj-kondo you are using
Oh, I had the args to as->
reversed 😊 .
clj-kondo, just doin’ its job!