From 475f337b5f33cf77b01b3a5723906002c3d23be9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9o=20Gaspard?= Date: Wed, 17 Feb 2016 03:06:01 +0100 Subject: [PATCH] Support newer tmux versions First, it should not break anything: according to tmux's ChangeLog, then tmux support for bracketed-paste mode dates back to 1.7. Then, on my (tmux 2.1) system, WrapForTmux actually makes the char codes be ignored, and a tmux error file is written. I couldn't find a trace in tmux's ChangeLog as to when this occured, and so went with switching on the major tmux version. --- plugin/bracketed-paste.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugin/bracketed-paste.vim b/plugin/bracketed-paste.vim index 196ec9b..9606004 100644 --- a/plugin/bracketed-paste.vim +++ b/plugin/bracketed-paste.vim @@ -14,7 +14,7 @@ if !exists("g:bracketed_paste_tmux_wrap") endif function! WrapForTmux(s) - if !g:bracketed_paste_tmux_wrap || !exists('$TMUX') + if !g:bracketed_paste_tmux_wrap || !exists('$TMUX') || system('tmux -V')[5] >= '2' return a:s endif