diff options
author | KWSys Robot <kwrobot@kitware.com> | 2015-10-16 13:04:33 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2015-10-19 13:16:26 (GMT) |
commit | 9c6a7203fb0c6034771011a8ac58ae447726b919 (patch) | |
tree | 4eb9004abceef2f537a99cae3ae4001b6655c06f | |
parent | 13c22d280e3b4d4f73e607617d18a3d55b509099 (diff) | |
download | CMake-9c6a7203fb0c6034771011a8ac58ae447726b919.zip CMake-9c6a7203fb0c6034771011a8ac58ae447726b919.tar.gz CMake-9c6a7203fb0c6034771011a8ac58ae447726b919.tar.bz2 |
KWSys 2015-10-16 (a7e5360f)
Extract upstream KWSys using the following shell commands.
$ git archive --prefix=upstream-kwsys/ a7e5360f | tar x
$ git shortlog --no-merges --abbrev=8 --format='%h %s' ed82989c..a7e5360f
Jan Niklas Hasse (1):
a7e5360f Terminal: Force color output when CLICOLOR_FORCE is set != 0
-rw-r--r-- | Terminal.c | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -184,14 +184,25 @@ static const char* kwsysTerminalVT100Names[] = static int kwsysTerminalStreamIsVT100(FILE* stream, int default_vt100, int default_tty) { + /* Force color according to http://bixense.com/clicolors/ convention. */ + { + const char* clicolor_force = getenv("CLICOLOR_FORCE"); + if (clicolor_force && *clicolor_force && strcmp(clicolor_force, "0") != 0) + { + return 1; + } + } + /* If running inside emacs the terminal is not VT100. Some emacs seem to claim the TERM is xterm even though they do not support VT100 escapes. */ + { const char* emacs = getenv("EMACS"); if(emacs && *emacs == 't') { return 0; } + } /* Check for a valid terminal. */ if(!default_vt100) |