Sorting by random in bash and mocp random updated

Post by Nico Brailovsky @ 2010-09-09 | Permalink | Leave a comment

Random is nice. And now you can sort by random your output using sort -R. Why would this be useful? Well, I updated my mocp random script with a oneliner:

mocp -c && find -type d | sort -R | head -n1 | awk '{print """$0"""}'; | xargs mocp -a