How do I do a recursive grep?
To do a recursive grep, you need the help of some other utilities. Probably included in the same package that has grep will be find, a program that can recursively traverse directories and invoke programs on the files it finds. To do a recursive grep with find, invoke “M-x grep” and run the following command: find . -name pattern -exec grep -n string NUL {} ; (Note that find is not the same program as the find that comes with Windows, rather a port of the GNU Findutils component). The pattern argument determines which files are matched (e.g., “*.c” for all .c files). The string argument specifies the string that you are searching for. And the NUL argument is a standard way to ensure that grep reports filenames in the matches (grep reports filenames when it is invoked on more than one file, and the NUL device is simply another file that will never contain matches; on Unix, you would use /dev/null). If you also have the xargs program, than you can make the recursive grep more efficient.