SyntaxFix
Write A Post
Hire A Developer
Questions
The usual way to do this is with grep, which uses a regex pattern to match lines:
grep
grep 'pattern' file
Each line which matches the pattern will be output. If you want to search for fixed strings only, use grep -F 'pattern' file.
grep -F 'pattern' file