如何搜索包含字符串--->
?
$ cat arrow
--->
$ grep ---> *
-bash: *: ambiguous redirect
$ grep "--->" *
grep: unrecognized option '--->'
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help` for more information.
$ grep "\-\-\-\>" *
$
答案 0 :(得分:3)
使用grep - 表示选项结束
grep -- '--->' *