Remove a line from a csv file bash, sed, bash

Posted by S1syphus on Stack Overflow See other posts from Stack Overflow or by S1syphus
Published on 2010-04-15T14:25:06Z Indexed on 2010/04/15 14:33 UTC
Read the original article Hit count: 727

Filed under:
|
|

I'm looking for a way to remove lines within multiple csv files, in bash using sed, awk or anything appropriate where the file ends in 0.

So there are multiple csv files, their format is:

EXAMPLEfoo,60,6
EXAMPLEbar,30,10
EXAMPLElong,60,0
EXAMPLEcon,120,6
EXAMPLEdev,60,0
EXAMPLErandom,30,6

So the file will be amended to:

EXAMPLEfoo,60,6
EXAMPLEbar,30,10
EXAMPLEcon,120,6
EXAMPLErandom,30,6

A problem which I can see arising is distinguishing between double digits that end in zero and 0 itself.

So any ideas?

© Stack Overflow or respective owner

Related posts about sed

Related posts about bash