Change surround mapping for creating markdown link

This commit is contained in:
Kenneth Benzie 2016-08-11 11:14:24 +01:00
parent 5299184d0b
commit 20e4ab57e5

View File

@ -9,10 +9,10 @@ setlocal textwidth=80
setlocal tabstop=4 shiftwidth=4 softtabstop=4
" Custom surround for markdown link syntax.
" "ys{motion}[" makes link out of "word" -> "[word]()"
autocmd FileType markdown let b:surround_91 = "[\r]()"
" "ys{motion}]" makes link out of "url" -> "[](url)"
autocmd FileType markdown let b:surround_93 = "[](\r)"
" "ys{motion}l" makes link out of "word" -> "[word]()"
autocmd FileType markdown let b:surround_{char2nr("l")} = "[\r]()"
" "ys{motion}L" makes link out of "url" -> "[](url)"
autocmd FileType markdown let b:surround_{char2nr("L")} = "[](\r)"
finish " Experiment functionality (disabled). {{{