home *** CD-ROM | disk | FTP | other *** search
- #!/usr/bin/perl
-
- while (<>) {
- if (/^\n$/) {
- &flush if $line;
- print "\n";
- } elsif (/^>/) {
- print;
- } else {
- $line .= $_;
- }
- }
- &flush if $line;
- exit 0;
-
-
- sub flush {
- $_ = $line;
- $line = '';
- s/^\s+//;
- s/\s+$//;
- s/\s+/ /g;
- s/(\w)- /$1/g; # unhyphenate
- write;
- }
-
- format STDOUT =
- ^<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< ~~
- $_
- .
-