Merge pull request #1984 from hctym1995/v1.x

Add a color-terminal type
This commit is contained in:
Gabi Melman 2021-06-28 15:10:01 +03:00 committed by GitHub
commit 082d6fbea9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -415,8 +415,8 @@ SPDLOG_INLINE bool is_color_terminal() SPDLOG_NOEXCEPT
return true; return true;
} }
static constexpr std::array<const char *, 15> terms = {{"ansi", "color", "console", "cygwin", "gnome", "konsole", "kterm", "linux", static constexpr std::array<const char *, 16> terms = {{"ansi", "color", "console", "cygwin", "gnome", "konsole", "kterm", "linux",
"msys", "putty", "rxvt", "screen", "vt100", "xterm", "alacritty"}}; "msys", "putty", "rxvt", "screen", "vt100", "xterm", "alacritty", "vt102"}};
const char *env_term_p = std::getenv("TERM"); const char *env_term_p = std::getenv("TERM");
if (env_term_p == nullptr) if (env_term_p == nullptr)