Bulk Rename – Replace Space with Underscore
August 26th, 2009
A small script to perform bulk renaming of files, replacing spaces with underscores and exotic letters with sanitized versions.
Save this link as /usr/bin/s2u.
#!/bin/sh ls -1 | while read -r FILE; do mv -v "$FILE" `echo $FILE | tr ' áéíóöïúü' '_aeiooouu'`; done