类似于
sed -i 's/n/en/g' text.txt
sed默认是包含n的行就行
我们可以写成
sed -i 's/\<n\>/en/g' text.txt
实现精准匹配,匹配单个字母 n
类似于
sed -i 's/n/en/g' text.txt
sed默认是包含n的行就行
我们可以写成
sed -i 's/\<n\>/en/g' text.txt
实现精准匹配,匹配单个字母 n
本文标题:Linux----sed方法实现精准匹配
本文链接:https://www.haomeiwen.com/subject/vddzxqtx.html
网友评论