我以为我知道这一点(或者至少如何在谷歌上搜索它)!
但是在文本文件中搜索模式时,我无法弄清楚如何使用 grep 匹配双引号。我试图用反斜杠转义双引号符号,但它似乎不起作用。
>cat trial.txt "Bill" is here and "Ben" is there > grep -iE "and \"ben\" is" trial.txt Unmatched ".
我如何让这个工作?
regex grep double-quotes
double-quotes ×1
grep ×1
regex ×1