
10 Nov
2011
10 Nov
'11
2:13 a.m.
On Thu, Nov 10, 2011 at 12:43 PM, David Zuccaro < david.zuccaro@optusnet.com.au> wrote:
Anyone like to critique this script for grammatical efficiency and correctness? In particular the line indicated. I'm guessing I can do command substitution better than this.
title="test" ls -1 *.mp3 > mp3.txt while read filename do
Relying on ls in bash scripts is bad, from memory. It could be aliased to "ls -laF --color" for instance, breaking your script. Far better to just use: for filename in *.mp3 do cheers, / Brett