标签:sed
sed 要定位,用 ADDRESS 行号 (也可是范围 “起始位置, 终止位置‘),或者 /PATTERN/ 匹配,而后是编辑命令 a(append), i(insert), s(replace)
sed ‘/export PATH=/ a\abc‘ .bashrc (add whole Line)
sed ‘s/export PATH=/export PATH=abc:/‘ .bashrc insert something after pattern
标签:sed
原文地址:http://qihua.blog.51cto.com/6365095/1585246