在/etc/vim/vimrc添加如下: set encoding=gb2312set fileencodings=gb2312set termencoding=gb2312 转载于:https://www.cnblogs.com/php5/archive/2011/02/15/1955456.html