How can I open a file and search for a word inside it using Ruby?
Try gem 'search_in_file', it helps you to search word of phrase in specified file or in many files by path