Fork me on GitHub
#calva
<
2024-08-01
>
Bailey Kocin15:08:49

When you right click on a function and try to click Go to Definition is it the clojure-lsp tool handling that request? I still have a problem where if I connect to a NREPL (my app runs in a docker container exposing a repl) , anytime I click Go to definition it prefixes the file path with app/src/mynamespace/myfile.clj when its just src/mynamespace/myfile.clj and it can never find and open it. This did not used to happen before but it started about a year ago at this point, it has not been that bothersome since I can search for the file and open it but its wearing me down now lol. Any thoughts on what could be going on here?

Bailey Kocin15:08:17

The app almost looks like a root directory on my system

Bailey Kocin15:08:42

My repl connect command looks like this (I started using a custom one a little bit ago, same problem)

clojure -Sdeps '{:deps {nrepl/nrepl {:mvn/version \"1.0.0\"}}}' -M:dev:test -m nrepl.cmdline --connect --host 127.0.0.1 --port 31401
The dev alias just has extra-paths and extra-deps The test alias has extra-paths and extra-deps then a test runner command

Bailey Kocin15:08:08

If I connect using deps.edn and a nrepl-port file it does the same thing

Bailey Kocin15:08:30

The only other relevant thing might be my maven is set to use a local file :mvn/local-repo "local-m2" in the clojure project workspace/root

pez15:08:34

There’s a setting which let’s you choose which definition provider to prioritize.

Bailey Kocin15:08:08

My hero! Thank you @U0ETXRFEW 😃

🙏 1
Bailey Kocin15:08:27

I actually did not know Calva had that option either!