
You are here: HardwareHacks 2000 > Software > LineConv
LineConvTranslate UNIX/LF to MS-DOS/CRLF and vice-versaIf you program on a Windows box you'll probably find these tools useful. LineConv is comprised of two tools. unix2dos converts UNIX-like LF line endings to DOS-like CRLF line endings. The result is that you'll be able to access the files from more ordinary text editors like Notepad without having to resort to more power-hungry editors like Visual Studio. dos2unix does the inverse. Both were inspired by their respective Python equivalents. The tools are written using the .NET Framework 2.0. Vista has this preinstalled. If you're on an earlier operating system and don't already have it installed, you can grab the installer from the Microsoft Download Center. SyntaxTo convert an LF text file to CRLF: unix2dos [filename] Both tools will automatically overwrite the input file with the corresponding line ending format. Download Links
Future ReleasesI'm thinking of implementing a recursive feature in future releases, so that one can change the line endings of all applicable files in a single directory or entire directory tree. Last updated 12/13/2007 15:17:41 |