Home: Need a Custom or Prewritten Perl Program?: I need a program that...:
perl program to remove blank lines in a csv file



manoj1031
New User

Nov 16, 2011, 12:43 AM


Views: 8637
perl program to remove blank lines in a csv file

need a perl program to remove black lines from a csv file


FishMonger
Veteran / Moderator

Nov 16, 2011, 10:04 AM


Views: 8619
Re: [manoj1031] perl program to remove blank lines in a csv file

There are several ways to strip blank lines. Here's one.

Code
perl -ni.bak -e 'print unless /^\s*$/' file.csv