View Full Version : UNIX and DOS file formats?
What the differences in UNIX and DOS text files formats?
RocketJeff
11-2-02, 09:49 AM
In MS-DOS (and Windows), text file lines end with both a carrage-return and a new-line (<cr><nl>) characters.
In Unix, text files only have a new-line character at the end.
Thank you for answering.
Does it mean that 1-string text files in DOS and UNIX have just the same format?
RocketJeff
11-2-02, 10:16 AM
Originally posted by aza
Does it mean that 1-string text files in DOS and UNIX have just the same format?
Depends on how the file was created. Some editors/utilities automatically put the end-of-line character(s) on the last line of a file (even if it is only a single line).
In this case, the file size will differ by 1 byte at most.
vBulletin v3.6.0, Copyright ©2000-2010, Jelsoft Enterprises Ltd.