使往vim里粘贴东西时不要自动每行加tab

~/.vim/vimrc(当前用户)或者/etc/vim/vimrc里设置。(Debian/Ubuntu可以直接在vimrc.local里设置,vimrc有对此文件的引用。

set noautoindent
set smartindent
set nocindent

附我的vimrc.local

set tabstop=4                                                                           
set shiftwidth=4
set noexpandtab
set cursorline
set encoding=utf-8
set number
set showmode
set noautoindent
set smartindent
set nocindent
syntax on

## USING VUNDLE TO HANDLE ALL PLUGINS
set nocompatible
filetype off
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
Plugin 'VundleVim/Vundle.vim'

##...OTHER PLUGINS

call vundle#end()
filetype plugin indent on

此处评论已关闭