At 15:15 +0000 12/22/05, James Harvard wrote:
I'm trying to detect a file's line endings (\r\n for DOS, \r for Mac and \n for Unix as I'm sure y'all know).

<ftp://ftp.macnauchtan.com/Software/LineEnds/FixEndsFolder.sit>  52 kB
<ftp://ftp.macnauchtan.com/Software/LineEnds/ReadMe_fixends.txt>  4 kB

I have trouble with files that contain multiple types of line ends. The result was these drag and drop AppleScripts that might help. They do look at the whole file but the underlying code (included) is in C and pretty fast and not memory intensive. You can change or just test for line endings but they don't (yet) handle the two newer 16 bit unicode line ends.

--

Applescript syntax is like English spelling:
Roughly, but not thoroughly, thought through.

Reply via email to