Merge pull request #163 from kiryph/feature-repeat-late

Add repeat.vim support to surround with LaTeX environment 'ys<>l'
This commit is contained in:
Tim Pope 2015-03-15 13:32:12 -05:00
commit 772ab9587b

View File

@ -212,10 +212,11 @@ function! s:wrap(string,char,type,removed,special)
elseif newchar ==# 'l' || newchar == '\'
" LaTeX
let env = input('\begin{')
let env = '{' . env
let env .= s:closematch(env)
echo '\begin'.env
if env != ""
let s:input = env."\<CR>"
let env = '{' . env
let env .= s:closematch(env)
echo '\begin'.env
let before = '\begin'.env
let after = '\end'.matchstr(env,'[^}]*').'}'
endif