Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
提前为这个问题的看似琐碎道歉。如此看来。字符匹配除行尾字符以外的任何字符,为什么运行grep .* foo.bar 会返回文件中的每一行?我会假设它只应该在到达行尾之前返回第一行,不匹配它并且conks out。
grep 将每一行分别与给定的正则表达式匹配