actually:
perl -i.bak -0777pe 's/\n\n/\n/g' inputtext
may be sightly better as no byte value matches octal 777, although that's rather nit picking and I'd have not noticed if I hadn't have needed to look up perlrun to find out what -0 (the digit 0 btw) actually does. ;)
In reply to Re^2: Removing double carriage return
by GrandFather
in thread Removing double carriage return
by dragooneye
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |