diff options
Diffstat (limited to 'doc/doc-docbook/Tidytxt')
-rwxr-xr-x | doc/doc-docbook/Tidytxt | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/doc/doc-docbook/Tidytxt b/doc/doc-docbook/Tidytxt new file mode 100755 index 000000000..02bf9dbd4 --- /dev/null +++ b/doc/doc-docbook/Tidytxt @@ -0,0 +1,21 @@ +#! /usr/bin/perl + +# $Cambridge: exim/doc/doc-docbook/Tidytxt,v 1.1 2005/06/16 10:32:31 ph10 Exp $ + +# Script to tidy up the output of w3m when it makes a text file. We convert +# sequences of blank lines into a single blank line. + +$blanks = 0; +while (<>) + { + if (/^\s*$/) + { + $blanks++; + next; + } + print "\n" if $blanks > 0; + $blanks = 0; + print; + } + +# End |