Re: Patch to add the vimgrep command
- Dnia piątek, 19 listopada 2004 17:01, Bram Moolenaar napisał:
> > One organizational thing: wouldn't it be better to make it an optionThis is not small disadvantage.
> > to
> > :grep command and 'grepprg' option - "builtin" - like for 'term'
> > : option?
> When using ":grep" and setting 'grepprg' to something specific to use
> internal grepping, it's easier to type the command. But it will not be
> compatible with previous versions, since the Vim pattern works a bit
> different from the external grep program.
> When using ":vimgrep" it's easy to switch between external and internal
> grepping. The only disadvantage appears to be that the command is
> longer to type.
> It would also be possible to do both: Supply ":vimgrep" that always doesYes, this the best solution. Leave 'grepprg' default as is but
> it internally, and allow setting 'grepprg' to make ":grep" work
> internally. That at least makes ":grep" work for systems that don't
> have an external grep command. And scripts can use ":vimgrep", as it
> works the same way on all systems.
provide option to call grep internally.