Fork me on GitHub
#emacs
<
2023-02-17
>
Zmicier Misiuk13:02:36

Hi there! Could you please recommend some tree explorer for emacs? Maybe there is some that can show clojure deps tree too 🙂

ericdallo13:02:53

treemacs? it has good support for LSP for some commands

ericdallo13:02:16

and the idea of showing clojure deps tree sounds pretty interesting, I may try to add that in lsp-treemacs in the future

😻 2
Zmicier Misiuk13:02:41

Thank you Eric! Just installed it. Looks very nice. I don't understand, how I live in emacs without it:)

ericdallo13:02:25

haha yea, one of the reasons I think today's framework are pretty nice like doom and spaceemacs, you find really useful stuff in there and can choose to enable or disable

John14:02:29

Hi. What should be handling jar:file:/home/....jar!/com.... ? It feels something is missing in my setup. I found no mentions in CIDER docs of some buddy package that does that handling. jarchive adds a handler to find-file only, but CIDER does browse-url so even with that I'm not sure how people have it working :thinking_face: Also the TRAMP-ish string would be jar:file:///home.. but CIDER yields jar:file:/path

👀 2
John15:02:07

Wonder if anything is different because of enrich-classpath

lispers-anonymous02:02:55

jarchive was written with eglot in mind, not cider. Can you write out the steps to reproduce this (perhaps with a minimal repository to clone) so I can see what is going on with cider and the jar url?

John20:02:24

So, I'm not sure there is or isn't a bug. Maybe Doom Emacs is just lacking. In any case

John20:02:40

it's a Doom Emacs setup (Clojure layer) with a simple new project with these requirements

:dependencies [[org.clojure/clojure "1.11.1"]
                 [com.slack.api/bolt "1.27.3"]
                 [com.slack.api/bolt-jetty "1.27.3"]]

John20:02:06

and what I expected was that enrich-classpath would lead to local documentation JAR's, which it does, albeit not unpacked

John20:02:29

I'm not using LSP because it's stack overflowing, so I'm on CIDER only

John20:02:31

and so what I expected was that CIDER would either have some companion code that deals with that so the docs land on eww or something, or maybe Doom should have jarchive in the Clojure layer and doesn't, but then the URL's don't match, as CIDER reports it in that style that doesn't quite fit

John20:02:44

so it's more that I don't know if it should even work 😛

John20:02:05

or that enrich-classpath extracted the javadocs 🤷

John20:02:46

ah I had missed the , not cider of your message I think, so, makes sense

lispers-anonymous15:03:50

Sorry for really slow response. I think in this case I might be able to have jarchive work the URL format cider uses, jar:file: . Currently jarchive is expecting jar:file:// Though I'm not sure what to do about cider using browse-url, I need to try it out

lispers-anonymous15:03:01

I'll see what I can do and report back here

John14:02:35

^ that is for the the *cider-doc* functionality on a Java package. C-c C-d C-d on Class/staticMethod yields com/...html as the javadoc target, but doing it on Class separated yields that jar:file path

borkdude15:02:06

When you change your .dir-locals.el how can you refresh it so cider-jack-in will pick up?

elken15:02:00

Re-run the major mode

dpsutton15:02:23

(hack-local-variables)

👆 4
👀 2
borkdude15:02:16

@U11BV7MTK that's not defined in my emacs

elken15:02:33

It's a function not a command

borkdude15:02:05

gotcha!

😁 2
dpsutton15:02:19

and before you jack in again and it takes forever, call c-h v [ret] <variable-name> and confirm its value is what you are hoping before. so you can save the “jack in, didn’t work…” cycle that takes a while

dakra15:02:53

If you have no unsaved changes you can also do M-x revert-buffer which is the same as simply closing the buffer and reopening it.

👍 2
borkdude15:02:29

Thanks, good suggestions

practicalli-johnny16:02:06

.dir-locals.el is only read when opening a buffer and won't be updated for any already opened buffers So the buffer that is current when running the command must be opened (reverted) after any change to .dir-locals.el Also use the universal argument before issuing the cider jack-in command to see the full details of the command to run in the mini buffer

borkdude16:02:51

yep, makes sense

hifumi12305:02:15

In my case, I simply revert buffer to refresh dir-local variables on opened files. On Mac OS this is pushing S-u

👍 2