1. 程式人生 > >DOS/Windows 文本格式與 Unix 文本各式轉換

DOS/Windows 文本格式與 Unix 文本各式轉換

-s 轉換 pos post tro style ons blog 語法

命令簡介:

dos2unix是將Windows格式文件轉換為Unix、Linux格式的實用命令。Windows格式文件的換行符為\r\n ,而Unix&Linux文件的換行符為\n. dos2unix命令其實就是將文件中的\r\n 轉換為\n。

而unix2dos則是和dos2unix互為孿生的一個命令,它是將Linux&Unix格式文件轉換為Windows格式文件的命令。

命令語法

dos2unix [options] [-c convmode] [-o file ...] [-n infile outfile ...]

unix2dos [options] [-c convmode] [-o file ...] [-n infile outfile ...]

DOS/Windows 文本格式與 Unix 文本各式轉換