tpope / vim-fireplace

fireplace.vim: Clojure REPL support
https://www.vim.org/scripts/script.php?script_id=4978
1.75k stars 139 forks source link

Provide tag stack support with CTRL-] / CTRL-T maps #304

Closed low-on-mana closed 4 years ago

low-on-mana commented 6 years ago

[\<C-D> jumps to the definition of a symbol (even if it's inside a jar file).

How to override above with <ctrl-]>

Personally, I think <ctrl-]> should be default goto definition key, as the tag file generation is not required anymore with vim-fireplace.

This behavior is practiced by fatih/vim-go as well.

low-on-mana commented 6 years ago

nnoremap <C-]> :execute 'Djump' expand('<cword>') <CR>

Found an ugly way to do it.

tpope commented 6 years ago

I think providing <C-]> would be cool but only if we also support its companion <C-T>, i.e. implement a tag stack.

Slightly cleaner override in the meantime:

autocmd FileType clojure nmap <buffer> <C-]> ]<C-D>
jrdoane commented 4 years ago

I know that this was suggested a while ago, but this still would be a huge benefit.