Recently I wrote a small script for someone who wanted a count of lines in two directories on two different machines then consolidated into one report.
Simple script, pulled back the information, consolidated it perfectly (even if I do say so myself), the one file was in csv format and as a little bonus I put the information into a spreadsheet for them using Python.
The first thing I got back from the person who requested it is can I remove the spaces after the comma as they don't like the look of them, they want it all together.
User requests sometime you have to love them, luckily its a simple fix, I know there are many ways to overcome this, but for me I used this simple perl one liner, this will remove all spaces from the file.
perl -pi -e 's/ +//g' ${LOGDIR}/count.txt
Please feel free to comment and add your suggestions on the best way to do this
I am always interested in feedback so please feel free to add any comments, or you can mail me here. If you would like to submit a quick tip with full credit and links back to your site then also feel free to contact me.
