Created
January 4, 2013 15:40
-
-
Save npero/4453544 to your computer and use it in GitHub Desktop.
Batch script to replace spaces by underscore in list of filenames (recursively).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| find . -name "*.doc" | while read file; do new_file=$(echo $file | sed s/\ /_/g); mv "$file" "$new_file"; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment