开发者

Can sed be made recursive in for windows?

I'm using sed for windo开发者_运维问答ws to do search and replace on some javascript files, and I was wondering if using some other utility I could make it work recursively.


yes you can, either use a for loop coupled with dir /s, or you can use find for windows. eg

find c:\path -iname "*.txt" -exec sed "s/old/new/g" "{}" ;
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜