开发者

Copy with sed 's//'

I have a file with various 'return BBQ;' statements. I'd l开发者_开发问答ike to change them all to 'exit(BBQ);\nreturn BBQ;' (with BBQ being an arbitrary value). Is this possible?


Backreferences.

s/return \(BBQ\);/exit(\1);\nreturn \1;/
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜