In order to make search and navigation more useful, I have edited my ~/.vim/after/ftplugin/clojure.clj to include the following:
"setlocal iskeyword-=.
"setlocal iskeyword-=/
This allows me to do things like quick-find (*/#) all variables belonging to a particular namespace in a document, or use w and b to navigate to a particular part of a namespace to edit it.
Unfortunately, this breaks vim-fireplace's "jump to definition" feature for any function that is referenced via its namespace. For example, (my-fun ...) will be found, but (my-ns/my-fun ...) will not, presumably because my redefinition of keyword now treats namespace and variable as two separate entities.
It would be nice for the jump-to-definition feature to be robust enough to cope with these sorts of modifications.
In order to make search and navigation more useful, I have edited my
~/.vim/after/ftplugin/clojure.clj
to include the following:This allows me to do things like quick-find (
*
/#
) all variables belonging to a particular namespace in a document, or usew
andb
to navigate to a particular part of a namespace to edit it.Unfortunately, this breaks vim-fireplace's "jump to definition" feature for any function that is referenced via its namespace. For example,
(my-fun ...)
will be found, but(my-ns/my-fun ...)
will not, presumably because my redefinition of keyword now treats namespace and variable as two separate entities.It would be nice for the jump-to-definition feature to be robust enough to cope with these sorts of modifications.