From f6c9d3beb2d11959d22b2555636aeb0c37e66aa1 Mon Sep 17 00:00:00 2001 From: Tim Pope Date: Sat, 10 Sep 2011 19:25:18 -0400 Subject: [PATCH] Warn about removed "s" mapping --- plugin/surround.vim | 29 ++++++++++------------------- 1 file changed, 10 insertions(+), 19 deletions(-) diff --git a/plugin/surround.vim b/plugin/surround.vim index 383e45e..a09df31 100644 --- a/plugin/surround.vim +++ b/plugin/surround.vim @@ -542,25 +542,16 @@ inoremap Isurround =insert() inoremap ISurround =insert(1) if !exists("g:surround_no_mappings") || ! g:surround_no_mappings - nmap ds Dsurround - nmap cs Csurround - nmap ys Ysurround - nmap yS YSurround - nmap yss Yssurround - nmap ySs YSsurround - nmap ySS YSsurround - if !hasmapto("VSurround","v") - if exists(":xmap") - xmap S VSurround - else - vmap S VSurround - endif - endif - if exists(":xmap") - xmap gS VgSurround - else - vmap gS VgSurround - endif + nmap ds Dsurround + nmap cs Csurround + nmap ys Ysurround + nmap yS YSurround + nmap yss Yssurround + nmap ySs YSsurround + nmap ySS YSsurround + xmap S VSurround + xmap gS VgSurround + xnoremap s :echoerr 'surround.vim: Visual mode s has been removed in favor of S' if !hasmapto("Isurround","i") && "" == mapcheck("","i") imap Isurround endif