EN
Linux grep command problem - how to solve Binary file my_file.txt matches?
1
answers
6
points
My problem:
grep -irn "My message" my_file.txt
Binary file my_file.txt matches
This txt file contains some binary parts, but mostly it is text file.
How to make grep to work on partially binary file and ignore binary parts and search over text?
1 answer
2
points
Solution:
grep -irn --text "My message" my_file.txt
From man grep:
grep --help
-a, --text equivalent to --binary-files=text
0 comments
Add comment