Thursday, March 30, 2017

Re: show reference about word under cursor under scope of all project files

I've been mapping "gb" to use vim-ack for this:

nnoremap gb :Ack -w <cword><CR>

To do without ack, you could probably use this instead:

nnoremap gb :grep -rw <cword> .<CR>



On Mar 30, 2017 8:19 AM, "YZ Xie" <xiedeacc@gmail.com> wrote:
Hi,is there a method show all references about the word under current cursor in a new window?
or a plugin more easy to use than cscope and support golang

I know four way,
1. [I, 
2. grep then :cope
3.just cscope
4.# or *

but it seems method one just work in the same file, not project.
method two works well, but too slow
method three works well, but only suppor c and c++, suport golang?
method four, jesus, cursor will move.

is there a method show all references about the word under current cursor in a new window?
or a plugin more easy to use than cscope and support golang

Regards

Xie




--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment