Re:If you use GNU grep on text files, use the -a (--text) op...
by zajio1am on Tuesday April 21, 2020 @06:54PM
(#22940175)
This 'feature' is especially irritating when one uses grep on some text files with legacy (non UTF-8) encoding, but has locale with UTF-8 encoding. The grep decides that regular text file is binary just because there are byte sequences that are not valid UTF-8 sequences.
[ Parent
| on HN ]
Re:If you use GNU grep on text files, use the -a (--text) op...
by _ZeD_ on Wednesday April 22, 2020 @01:32AM
(#22942554)
How... How can grep possibly work on a strange non-utf8 encoding if you don't say to it?
Re:If you use GNU grep on text files, use the -a (--text) op...
by twic on Wednesday April 22, 2020 @03:19AM
(#22943053)
If you're grepping for ASCII strings, then the UTF-8 pattern will match the Latin-1 file.