Monday, December 3, 2012

List files contains 'WORD' word

In Linux, grep command can be used to find files that contain specific word.

Change directory first to location where files are located.
Use following command to get file list

grep -l WORD *.*

Above command will list all files that contains word "WORD".

To get word location in file remove -l flag.