在grep命令

使用或我尝试下面的命令在grep命令" title="grep命令">grep命令

cat filename.txt | grep "<Line: (429|6854)>" 

cat filename.txt | grep "<Line: \(429\|6854\)>"

显示含有<线线:429 >或<线:6854 >,但我没有得到任何输出。

回答:

你必须使用grep -Eegrep

grep -E '<Line: (429|6854)>' filename.text 

以上是 在grep命令 的全部内容, 来源链接: utcz.com/qa/262261.html

回到顶部