首页 > Linux操作系统 > Linux操作系统 > 批量删除文件中的^M
删除lunix下文件中的^M。
#for f in `ls -1`
>do
>mv $f $f\.tmp
>sed 's/^M//' $f\.tmp >$f
>rm -f $f\.tmp
>done
其中^M为ctrl+v,ctrl+m
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/241379/viewspace-693649/,如需转载,请注明出处,否则将追究法律责任。