How do I rename all files and folders to lowercase
Submitted by Scott on Tue, 07/18/2017 - 11:43Navigate to the folder that you want to operate on. Then execute the following line.
find . -depth |while read LONG; do SHORT=$( basename "$LONG" | tr '[:upper:]' '[:lower:]' ); DIR=$( dirname "$LONG" ); if [ "${LONG}" != "${DIR}/${SHORT}" ]; then mv "${LONG}" "${DIR}/${SHORT}" ; fi; done