cmap <f28> <nop>
cmap <f29> <nop>
+ "https://coderwall.com/p/if9mda/automatically-set-paste-mode-in-vim-when-pasting-in-insert-mode
+ function! WrapForTmux(s)
+ if !exists('$TMUX')
+ return a:s
+ endif
+
+ let tmux_start = "\<Esc>Ptmux;"
+ let tmux_end = "\<Esc>\\"
+
+ return tmux_start . substitute(a:s, "\<Esc>", "\<Esc>\<Esc>", 'g') . tmux_end
+ endfunction
+
" https://vim.fandom.com/wiki/Change_cursor_shape_in_different_modes
- let &t_EI.="\e[2 q" "EI = NORMAL mode (ELSE)
- let &t_SI.="\e[6 q" "SI = INSERT mode
- let &t_SR.="\e[4 q" "SR = REPLACE mode
+ let &t_EI.=WrapForTmux("\e[2 q") "EI = NORMAL mode (ELSE)
+ let &t_SI.=WrapForTmux("\e[6 q") "SI = INSERT mode
+ let &t_SR.=WrapForTmux("\e[4 q") "SR = REPLACE mode
"Cursor settings:
" 1 -> blinking block