문제

I am using the following plugin to simplify tagging URLs in Markdown: tpope/vim-surround

This works:

nmap <leader>l <Plug>Ysurroundiw]%a(<C-R>*)<Esc>

This doesn't (notice the capital 'S'):

vmap <leader>l <Plug>YSurround]%a(<C-R>*)<Esc>

Any idea why?

도움이 되었습니까?

해결책

Try using VSurround instead of YSurround since you're using a vmap.

다른 팁

Surround is awesome but what about a more portable, plugin-agnostic, solution?

xnoremap <leader>l <Esc>`>a](<C-r>*)<C-o>`<[<Esc>
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top