Find files with non-ascii characters in filename
Is there a way that I can have find
non-ascii character files? I could use a pipe of course and filter files with perl, but for efficiency I would like to set the whole thing to find
. I tried the following:
find . -type f -name '*[^[:ascii:]]*'
it doesn't work at all.
Edit
Now I am trying to use
find . -type f -regex '.*[^[:ascii:]].*'
It is emacs regexp and has a class [:ascii:]
. But the expression I'm trying to use doesn't work.
Edit 2 :
LC_COLLATE=C find . -type f -regex '.*[^!-~].*'
matches files with non-ascii characters (full voodoo ...). But it also matches files with a space in the name.
-1
source to share