keymapping - Vim key mapping with symbols -


I define a key key map to insert the selected line inside an HTML p tag I'm trying to:

This is not work, I think that Vim is in a specific way by & lt; P & gt; is interpreting how can I solve it?

It seems that you are using VIM in "compatible mode" which is just disappointing Drafting people do "Nocompatible mode", your mapping works as expected, so you should make sure that nocompatible is set to (empty ~ / .imim Must be enough).

Anyway, your & lt; P & gt; s is not a problem, because it is inserted normally, this is your & lt; cr & gt; and your & lt; esc & gt; Creating a mistake: Since you are running VIM in "compatible mode", cpoptions in the option , which does not recognize Vime and lt; CR & gt; and friends as a special key.

Running the Vim in "nocompatible mode" is the best way to go the best , but you can also use the following notation if you really insist on being "compatible" :

  vnoremap & lt; leader & gt; BP C & lt; P & gt; ^ M & lt; / P & gt; ^] P   

where ^ M is passed to & lt; C-V & gt; & Lt; CR & gt; and ^] are inserted with & lt; C-V & gt; & Lt; Esc & gt; .

Comments

Popular posts from this blog

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

jasper reports - How to center align barcode using jasperreports and barcode4j -

c# - ASP.NET MVC - Attaching an entity of type 'MODELNAME' failed because another entity of the same type already has the same primary key value -