Skip to content

Instantly share code, notes, and snippets.

@fedir
Created February 1, 2012 09:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fedir/1716150 to your computer and use it in GitHub Desktop.
Save fedir/1716150 to your computer and use it in GitHub Desktop.
Finding all files with non-ascii characters in names and replacing it by underscores
find . | perl -ane '{ if(m/[[:^ascii:]]/) { print } }' | rename -n 's/[^[:ascii:]]/_/g'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment