diff options
author | Nico Weber <thakis@chromium.org> | 2012-01-19 00:09:16 (GMT) |
---|---|---|
committer | Nico Weber <thakis@chromium.org> | 2012-01-19 00:09:16 (GMT) |
commit | a2c4b6780dcf105821e4f2ec1f0b591adbeb6dca (patch) | |
tree | a62348131d053354b7d8d5fb1c3ca5b3d5527d67 /src/util.h | |
parent | 63013b3bd5ca79d454a95a6f985d98f16f21da1c (diff) | |
download | Ninja-a2c4b6780dcf105821e4f2ec1f0b591adbeb6dca.zip Ninja-a2c4b6780dcf105821e4f2ec1f0b591adbeb6dca.tar.gz Ninja-a2c4b6780dcf105821e4f2ec1f0b591adbeb6dca.tar.bz2 |
Strip ansi escape sequences from subcommand output when not writing to a smart terminal.
Diffstat (limited to 'src/util.h')
-rw-r--r-- | src/util.h | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -65,6 +65,9 @@ const char* SpellcheckStringV(const string& text, const vector<const char*>& wor /// Like SpellcheckStringV, but takes a NULL-terminated list. const char* SpellcheckString(const string& text, ...); +/// Removes all Ansi escape codes (http://www.termsys.demon.co.uk/vtansi.htm). +string StripAnsiEscapeCodes(const string& in); + #ifdef _WIN32 #define snprintf _snprintf #define fileno _fileno |