Conversation

On OSX, find and rename all pdfs in the current directory to the file's md5sum(.pdf). Added bonus is that it deduplicates. find ./*.pdf -type f -exec bash -c 'echo "${1%.*}.${1##*.} --> $(md5 -q "$1").${1##*.}"; mv "${1%.*}.${1##*.}" "$(md5 -q "$1").${1##*.}"' bash {} \;
5
179
This Tweet was deleted by the Tweet author. Learn more