You can do it faster if you do
Quote:
find /mnt/us/documents -type d -mindepth 2 | grep -v "\.sdr$" | grep -v "^$" | grep -v "/mnt/us/documents/Gallery" | sed "s/^\/mnt\/us\/documents\///g" | sed "s/\//-/g" | while read dir; do
|
A bit fewer "greps". You'll have to check for yourself, though, I just wrote that code without checking it on the device.