当前位置: 首页 > 工具软件 > dos2unix > 使用案例 >

dos2unix整个目录

景永春
2023-12-01

因为经常在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

 

 类似资料: