When even i try to copy paste this text in vim it put half of it in the command line and half in text editor main window
This is the text
sub(/;;/," ",$0)
How can i copy paste that
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
When you paste in console Vim (not GVIM), Vim cannot detect whether what you’ve pasted is typed by you or an actual paste. Therefore, any (insert mode) mappings will apply. You probably have a mapping (maybe
;;?) that leaves insert mode, and that is triggered during the paste, wreaking havoc.There are two ways to prevent that:
Either paste in normal mode via
"*p(active selection) or"+p(system clipboard), provided that Vim is able to interact with them.Or, set the
'pastetoggle'option, e.g.and then press F2 (in insert mode) before pasting (note how the mode changes to
-- INSERT (paste) --, and again after it. This way, you explicitly tell Vim “the next characters aren’t typed by me, treat them literally”.If this manual management is too much of a hassle for you, you can alternatively use graphical GVIM.