clojure-vim / acid.nvim

Asynchronous Clojure Interactive Development
161 stars 12 forks source link

Feature request: an option to disable "go to definition" #53

Closed daveyarwood closed 5 years ago

daveyarwood commented 5 years ago

I've grown quite used to using ctags to manage "go to definition," to the extent that I prefer it over nREPL-based "go to definition," even if nREPL-based "go to definition" is more precise. The key thing is that I often edit Clojure code without being connected to a REPL, and I need "go to definition" to work in those moments. ctags allow me to do that in a "good enough" sort of way.

Would it be feasible to add something like a g:acid_disable_go_to_definition, which makes acid not remap <C-]>?

I see that there is a g:acid_no_default_keymappings, but that's not ideal because I would then need to maintain my own set of acid keybindings (for everything else acid provides) identical to the defaults, and keep up with any changes, etc. instead of the plugin ensuring that the keybindings stay up to date with the implementations.

hkupty commented 5 years ago

I believe I'd better remap to gd or cgd than <C-]>. Wdyt?

On Mon, 1 Apr 2019, 22:15 Dave Yarwood, notifications@github.com wrote:

I've grown quite used to using ctags to manage "jump to definition," to the extent that I prefer it over nREPL-based "jump to definition," even if nREPL-based "jump to definition is more precise. The key thing is that I often edit Clojure code without being connected to a REPL, and I need "jump to definition" to work in those moments. ctags allow me to do that in a "good enough" sort of way.

Would it be feasible to add something like a g:acid_disable_jump_to_definition, which makes acid not remap <C-]>?

I see that there is a g:acid_no_default_keymappings https://github.com/clojure-vim/acid.nvim/blob/e8fec9276f2ff69e3ea10533065e7ff947563495/doc/acid.txt#L105, but that's not ideal because I would then need to maintain my own set of acid keybindings (for everything else acid provides) identical to the defaults, and keep up with any changes, etc. instead of the plugin ensuring that the keybindings stay up to date with the implementations.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/clojure-vim/acid.nvim/issues/53, or mute the thread https://github.com/notifications/unsubscribe-auth/ACkii-BeaAbxgxOPAq8bZqjvFSbzYZjoks5vcmjlgaJpZM4cWjWh .

daveyarwood commented 5 years ago

I'm not familiar with gd, but based on this, it looks like it might be the better choice, since it looks like <C-]> might be specifically for tags.

hkupty commented 5 years ago

Nice.

Care to open a pr for that? Otherwise I will do that tomorrow morning.

Cheers, Henry John Kupty

On Mon, 1 Apr 2019, 23:04 Dave Yarwood, notifications@github.com wrote:

I'm not familiar with gd, but based on this https://vim.fandom.com/wiki/Go_to_definition_using_g, it looks like it might be the better choice, since it looks like <C-]> might be specifically for tags.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/clojure-vim/acid.nvim/issues/53#issuecomment-478747515, or mute the thread https://github.com/notifications/unsubscribe-auth/ACkii2v7G4FSfSjbCNWSX-oPHSEHUb5Fks5vcnR5gaJpZM4cWjWh .

daveyarwood commented 5 years ago

Sure, I'm happy to take a stab at it tonight!