#!/bin/bash # recurcively apply mp3gain # run as 'find -type d -exec /home/ak/docs/scripts/mp3rg "{}" \;' cd "$*" && \ if [ "`find -maxdepth 1 -type f -name \*.mp3`" ]; then mp3gain -a -k -t -p *.mp3 fi