#!/usr/bin/perl while (<>) { $last = $this; $this = $next; $next = $_; $lastblank = ($last =~ (/^\s*$/)); $thisblank = ($this =~ (/^\s*$/)); $nextblank = ($next =~ (/^\s*$/)); print $this unless (! $lastblank) && ($thisblank) && (! $nextblank); } print $next unless ($nextblank) && (! $thisblank);
In reply to Re: remove single blank lines?
by aloomens
in thread remove single blank lines?
by aloomens
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |