Paste toggle
Put the following in your vimrc (change <F2> to whatever key you want):
set pastetoggle=<F2>
To paste from another application:
- Start insert mode.
- Press F2 (toggles the 'paste' option on).
- Use your terminal to paste text from the clipboard.
- Press F2 (toggles the 'paste' option off).
Then the existing indentation of the pasted text will be retained.
相关热门文章
给主人留下些什么吧!~~
评论热议