grep -r "texthere" .
The first parameter represents the regular expression to search for, while the second one represents the directory that should be searched.
(第一个参数表示要搜索的正则表达式,而第二个参数表示应搜索的目录。)
In this case, .
(在这种情况下, .
)
means the current directory. (表示当前目录。)
Note: This works for GNU grep, and on some platforms like Solaris you must specifically use GNU grep as opposed to legacy implementation.
(注意:这适用于GNU grep,在某些平台(如Solaris)上,必须专门使用GNU grep而不是传统实现。)
For Solaris this is the ggrep
command. (对于Solaris,这是ggrep
命令。)
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…