Monday, June 8, 2009

COLRM - Discovered a fun new tool!

It seems amazing to me that no matter how long I work in the world of Linux I am still to this day finding little tools to help my productivity. There are many different ways to remove certain columns of information from a text file but I just discovered colrm ( colrm first_col [second_col] ) which is a tool to do specifically that task. I am not sure how it does this behind the scenes so I am not sure how well it works if performance is critical but for a hackey little side thing it seems to do very well.

Here is an example where I removed columns 87 to the end and from column 1 to 69 leaving just column data from 70 to 86:

> cat ~/tmp/max_data.out colrm 87 colrm 1 69 > ~/tmp/max_data2.out

No comments:

Post a Comment