sed 对一堆文件指定行后增加内容

sed -i '/\/opt\/php\/bin\/php/ r /tmp/check.file'  /root/*.sh

 

sed 替换\t等特殊字符,试了很多博客的方法,最后还是通过16进制修改了。

sed -i 's/\x09/\x01/g' ./*

 

posted @ 2021-11-05 10:32  腐汝  阅读(46)  评论(0编辑  收藏  举报