sh 将CRLF行结尾转换为LF。

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了sh 将CRLF行结尾转换为LF。相关的知识,希望对你有一定的参考价值。

# Convert a file

## Usage
dos2unix < inputfile > outputfile

## Example
dos2unix \
  < app/controllers/application_controller.rb \
  > app/controllers/application_controller.rb


# Convert a whole folder

## Usage
find {folder} -type f -exec dos2unix {} \;

## Example
find ./app -type f -exec dos2unix {} \;

以上是关于sh 将CRLF行结尾转换为LF。的主要内容,如果未能解决你的问题,请参考以下文章