Currently Being ModeratedDec 4, 2011 6:38 PM (in response to Kiraku)
tr -d "\r\n" to
tr -d "\n"
, but try both
for f in ~/Desktop/*
new="$(printf %s "$f" | tr -d "\n")"
if [ "$f" != "$new" ]; then
mv "$f" "$new"
doneMacBook Air, MacBook, Mac mini, Mac OS X (10.7.2)
Currently Being ModeratedMar 8, 2013 7:43 PM (in response to pjdube)
Good for you! So long as the thread remains 'unsolved' I see no reason not to offer answers. I for one have found this discussion useful. I wasn't aware of the 'tr' command until reading this thread, and found out some useful tricks you can do with it from exploring the tr man page.
If you hadn't brought this thread back to life, I'd have missed out on that, so here's a 'thanks' from me, too!