README.md: Add 'Garbled output' to 'Troubleshooting' (#1937)
As per #234, #403, #1572, #1823 and #1897, this commit clarifies that
`bat` cannot properly handle escape sequences.
Signed-off-by: Isabella Basso <isabbasso@riseup.net>
commit59d4cfb75c1a17a26b2b38956ee08d8c53f04e04
authorIsabella Basso <isabellabdoamaral@usp.br>
dateFri 19 Nov 2021, 03:09 (5 years ago)
parent194e7bb
README.md+7
@@ -674,6 +674,13 @@ bat() {
674674
675675## Troubleshooting
676676
677+### Garbled output
678+
679+If an input file contains color codes or other ANSI escape sequences, `bat` will have problems
680+performing syntax highlighting and text wrapping, and thus the output can become garbled.
681+When displaying such files it is recommended to disable both syntax highlighting and wrapping by
682+passing the `--color=never --wrap=never` options to `bat`.
683+
677684### Terminals & colors
678685
679686`bat` handles terminals *with* and *without* truecolor support. However, the colors in most syntax