diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2021-09-14 14:57:58 +0200 |
---|---|---|
committer | Eelco Dolstra <edolstra@gmail.com> | 2021-09-14 14:57:58 +0200 |
commit | 75837bb5953653a184eda92ef9727c96f41a4512 (patch) | |
tree | b23121a93be9ffa0f371c6fe2c895e54932931ea /src/libcmd | |
parent | 7e4dd0e2799d6ae072d9b9a7f1e21acf858dfbb3 (diff) |
Respect NO_COLOR in Markdown output
Diffstat (limited to 'src/libcmd')
-rw-r--r-- | src/libcmd/markdown.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libcmd/markdown.cc b/src/libcmd/markdown.cc index 8a2f155d6..737356284 100644 --- a/src/libcmd/markdown.cc +++ b/src/libcmd/markdown.cc @@ -44,7 +44,7 @@ std::string renderMarkdownToTerminal(std::string_view markdown) if (!rndr_res) throw Error("allocation error while rendering Markdown"); - return std::string(buf->data, buf->size); + return filterANSIEscapes(std::string(buf->data, buf->size), !shouldANSI()); } } |