more env variable checks for vte.

This commit is contained in:
Christopher Jeffrey 2015-01-31 22:22:15 -08:00
parent 32a783b282
commit 9589eb81d6
1 changed files with 9 additions and 2 deletions

View File

@ -68,9 +68,16 @@ function Program(options) {
|| process.env.TERM
|| (process.platform === 'win32' ? 'windows-ansi' : 'xterm');
// NOTE: lxterminal does not provide an env variable to check for.
// NOTE: gnome-terminal and sakura use a later version of VTE
// which provides VTE_VERSION as well as supports SGR events.
this.isXFCE = /xfce/i.test(process.env.COLORTERM);
this.isTerminator = process.env.TERMINATOR_UUID;
this.isVTE = !!(process.env.VTE_VERSION || this.isXFCE || this.isTerminator);
this.isTerminator = !!process.env.TERMINATOR_UUID;
this.isLXDE = false;
this.isVTE = !!process.env.VTE_VERSION
|| this.isXFCE
|| this.isTerminator
|| this.isLXDE;
this._buf = '';
this._flush = this.flush.bind(this);