【发布时间】:2015-06-10 14:04:53
【问题描述】:
我正在尝试在当前文件夹中包含的所有文件中递归搜索字符串,我正在执行 grep。但似乎这台主机上的grep 太旧了。以下是它的一些用法。
>> grep -r "some string here" *.*
grep: illegal option -- r
usage: grep [-E|-F] [-c|-l|-q] [-bhinsvwx] -e pattern_list...
[-f pattern_file...] [file...]
usage: grep [-E|-F] [-c|-l|-q] [-bhinsvwx] [-e pattern_list...]
-f pattern_file... [file...]
usage: grep [-E|-F] [-c|-l|-q] [-bhinsvwx] pattern [file...]
那我该怎么做?
【问题讨论】:
标签: shell text command-line grep