zcat filename | grep pattern
Find and replace string using VI editor
ARUN Posted in LINUX COMMANDS, SEARCH COMMANDS,
17
April
2010
Open file in VI
vi filename
esc
:%s/old string/new String/
Search a pattern inside all files in current
ARUN Posted in LINUX COMMANDS, SEARCH COMMANDS,
17
January
2010
grep -rl pattern .
For example :
To search for each line under the current directory for the word “Hacked”
grep -rl Hacked .