Rename to lower case

To rename all jpg-files in a folder to its lower cased equivalent, you can run this little shell script: $> for i in folderpath/*.jpg; do mv -v $i `echo $i | tr ‘[:upper:]’ ‘[:lower:]’`; done The -v param of mv will only give you a list of renamed files.

Flatten directory structure

Recently I brought a mp3 player that wasn’t able to shuffle the track through all folders. That’s why I had to bring all tracks to the root directory of the player (flatten directory structure). I did it with the following command, that flattens the whole structure by searching all files in the structure and copying […]