Change cursor to I-bar in insert mode even when in Tmux

pull/2/head
Bo Jeanes 2012-08-16 15:49:11 -05:00 committed by Bodaniel Jeanes
parent a9bb324650
commit d62f1d3346
2 changed files with 11 additions and 2 deletions

View File

@ -138,7 +138,13 @@ syntax on
" May only work in iTerm2 and may have other bad effects,
" but this shows a block in normal mode, and vertical bar
" in insert mode.
if exists('$TMUX')
" https://github.com/sjl/vitality.vim/issues/8#issuecomment-7664649
let &t_SI = "\<Esc>[3 q"
let &t_EI = "\<Esc>[0 q"
else
let &t_SI = "\<Esc>]50;CursorShape=1\x7"
let &t_EI = "\<Esc>]50;CursorShape=0\x7"
endif
runtime macros/matchit.vim

View File

@ -89,3 +89,6 @@ bind z last-window \; swap-pane -s tmux-zoom.0 \; kill-window -t tmux-zoom
set-option -g status-right-length 1000
set-option -g status-left-length 60
# https://github.com/sjl/vitality.vim/issues/8#issuecomment-7664649
set-option -g terminal-overrides '*88col*:colors=88,*256col*:colors=256,xterm*:XT:Ms=\E]52;%p1%s;%p2%s\007:Cc=\E]12;%p1%s\007:Cr=\E]112\007:Cs=\E]50;CursorShape=%?%p1%{3}%<%t%{0}%e%p1%{2}%-%;%d\007'