Skip to content

Instantly share code, notes, and snippets.

@gerjantd
Last active August 29, 2015 13:56
Show Gist options
  • Save gerjantd/9158091 to your computer and use it in GitHub Desktop.
Save gerjantd/9158091 to your computer and use it in GitHub Desktop.
Bash/Perl script to replace spaces in file names
# http://stackoverflow.com/questions/2709458/bash-script-to-replace-spaces-in-file-names
find ./tmp/ -depth -name "* *" -execdir rename 's/ /_/g' "{}" \;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment