Permalink
Browse files

Check presence of $ITERM_SESSION_ID for iTerm support

Checking for the existance of the $ITERM_SESSION_ID env variable is also
an acceptable way of determining if you are using iTerm or not.
  • Loading branch information...
1 parent 6882fbb commit a9a5d762cf90647e35c9045a6e9d568e6d54c8e7 @fabiomcosta fabiomcosta committed with May 22, 2013
Showing with 2 additions and 1 deletion.
  1. +2 −1 plugin/togglecursor.vim
@@ -36,7 +36,8 @@ let s:supported_terminal = ''
" Check for supported terminals.
if !has("gui_running")
- if $TERM_PROGRAM == "iTerm.app" || $KONSOLE_DBUS_SESSION != ""
+ if $TERM_PROGRAM == "iTerm.app" || exists("$ITERM_SESSION_ID")
+ \ || $KONSOLE_DBUS_SESSION != ""
" Konsole and iTerm support using CursorShape.
let s:supported_terminal = 'cursorshape'
elseif $XTERM_VERSION != ''

0 comments on commit a9a5d76

Please sign in to comment.