This question pertains to the usage and inner workings of grep. If I issue grep 'needle' *, grep will search for needle within all text files of the current directory (e.g., http://www.linfo.org/grep.html). But what constitutes these so-called "text files", and how does grep identify these files?
For example, ASCII, UTF-8, UTF-16, could all be considered to be text files, but grep does not search UTF-16 by default.
As for identification, does grep use solely the file signature at the beginning of the file?