Quote:
Originally Posted by grumbles
I should add, since this was originally about stripping excess carriage returns, I have a couple of command line programs that take text file and unwraps them. The Gutenberg text files for instance, where each line is truncated at about eighty characters. It requires that each paragraph is separated by a blank line. The first program just unwraps from standard input to standard output. The second program does the same thing but wraps the text into a very simple xhtml file. Quotes, single and double, angle brackets and ampersands are converted to entities. I use this as the first stage when converting from text files.
These are very simple programs and are written in Pascal and are compiles with the Free Pascal Compiler. They run on any system that FPC is available for. I use them, and other utilities, on both Windows (XP, 7 and 8.1) as well as Linux.
If anyone is interested, I can post the source. I also have utilities to merge xhtml files or split them on headings.
|
Thanks. I'd certainly be interested in looking at your programs. I have Windows 10, though I don't suppose that makes much difference.