I want to find all filenames in a directory tree that contain extended ASCII characters (0x80-0xFF). I thought that I could do this like this:
find . -regex '.*[\x80-\xFF]+.*' but instead it matches everything. Alternatively I tried to look for files that contained any character not in a standard set of a-z, A-Z, 0-9, hyphen or period.
find . -regex '.*[^- a-zA-Z0-9]+.*' Obviously I'm misunderstanding a fundamental aspect here.
Examples of the files in my tree:
./file 1/file - 1 - A2.mkv ./file 1/file - 1 - A2.nfo ./tést/tést - 2 - 2.mkv ./français/français - 2 -3.mkv I'm using find (GNU findutils) 4.7.0, under Ubuntu 20.04.
françaisandtéstif you add.and/to the negated character class:'.*[^- a-zA-Z0-9./]+.*'(and you could remove the+).