dos2unix整個目錄


因為經常在windos平台和linux平台之間協同開發,所以不可避免的就碰到了CRLF的問題,dos2unix 和 unix2dos可以說是最常用的解決CRLF問題的工具了。
下面列出怎么對整個目錄中的問題做dos2unix操作
$ find . -type f -exec dos2unix {} \;


其中具體命令的解釋如下:

find .
= find files in the current directory

-type f
= of type f

-exec dos2unix {} \;
= and execute dos2unix on each file found


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM