hi! quick question, is there a way to make go-to-definition
work in emacs for clojure specs?
I have it working for defns and defs but canβt handle specs
[I use spacemacs] it used to work for me with cider-find-keyword
for things like ::specs/non-empty-string
but it doesn't work anymore.
I can still do press g d
(go-to-definition) and get a quick list of occurences of given symbol and usually quickly identity the place where it's defined
@andrzej.fricze using fully qualified spec names, e.g. :practicalli.banking/account-id
rather than ::account-id and with the REPL running, then cider-browse-spec
works well as well as the clj-find-var
function in Spacemacs Clojure layer (a wrapper function around cider-find-var). With the cursor on an auto-qualified spec form, ::account-id
these functions do not seem to work. If the repl is not running, the clj-find-var
function used dump-jump-go which doesn't seem to work for specs
https://github.com/syl20bnr/spacemacs/blob/develop/layers/%2Blang/clojure/funcs.el#L187-L195
thanks for help guys! π
Take a look at clojure-lsp
with lsp-mode
for Emacs, more info on #lsp
Is there something obvious I'm missing why this isn't properly setting the keybinding:
(define-key inf-clojure-mode-map (kbd "C-c C-r") #'inf-clojure-restart)
Ah, think I figured it out. I was doing
(require 'clj-refactor)
later in the .el file which I think was overriding the keybinding