Converting End of Line markers

トップ ページ
添付ファイル:
Eメールのメッセージ
+ (text/plain)
このメッセージを削除
このメッセージに返信
著者: David A. Sinck
日付:  
題目: Converting End of Line markers

\_ SMTP quoth Simper, Brian D on 3/5/2003 10:31 as having spake thusly:
\_
\_
\_ A co-worker sent a set of development files to me containing source code
\_ and scripts. Unfortunately, he routed it through his Windows desktop and
\_ all of the text files have the standard Dos end-of-line markers. Bash
\_ won't interpret them correctly. Is there a simple way to convert between
\_ Dos EOL and UNIX/Linux EOL?

perl -i.bak -e 's/\r\n$/\n/' file

if I remember the stanza right. :-)

David