Search text in files in linux

Use the following command to search any text in the files using the command line in linux.

grep -i -n -r 'pagination' /home/sheetal/xyz

Above command will search pagination text in all files in xyz directory and its subdirectory.





Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>

More information about formatting options