How do i find all files containing specific text ?

 

We propose here an easy and immediate method to search all the files containing our string.

 

# Output every line that contains SUBSTRING
clear; grep -rnw  "./"  -e "SUBSTRING"
# Number of files that contains SUBSTRING
clear; grep -rnw  "./"  -e "SUBSTRING" | wc -l

# List of files that contains SUBSTRING
clear; grep -Ril "SUBSTRING"   ./
# Number of accourences
clear; grep -Ril "SUBSTRING" ./ | wc -l

# List of every file:line that contains SUBSTRING
clear; grep -R  "SUBSTRING"   ./
sitemap_410_gone.html