vim搜索插件-grep
2016年05月26日

常用命令

查找匹配功能

命令 作用
:Grep 按照指定的规则在指定的文件中查找
:Rgrep 同上,但是递归
:GrepBuffer 在所有已打开的缓冲区中查找
:Bgrep 同上
:GrepArgs 再vim的argument filenames (:args)中查找
:Fgrep 运行fgrep
:Rfgrep 运行递归 fgrep
:Egrep 运行egrep
:Regrep 运行递归 egrep
:Agrep 运行agrep
:Ragrep 运行agrep

:Grep [<grep_options>] [<search_pattern> [<file_name(s)>]]
:Rgrep [<grep_options>] [<search_pattern> [<file_name(s)>]]
:Fgrep [<grep_options>] [<search_pattern> [<file_name(s)>]]
:Rfgrep [<grep_options>] [<search_pattern> [<file_name(s)>]]
:Egrep [<grep_options>] [<search_pattern> [<file_name(s)>]]
:Regrep [<grep_options>] [<search_pattern> [<file_name(s)>]]
:Agrep [<grep_options>] [<search_pattern> [<file_name(s)>]]
:Ragrep [<grep_options>] [<search_pattern> [<file_name(s)>]]
:GrepBuffer [<grep_options>] [<search_pattern>]
:Bgrep [<grep_options>] [<search_pattern>]
:GrepArgs [<grep_options>] [<search_pattern>]