vim编辑器实用设置
打开位于根目录下的etc文件夹,找到vim文件夹下的vimrc文件或者vim.rc,用编辑器打开,在结尾添加下面的指令:
有的使用树莓派系统的同学有可能不能复制中文。需要取消选中其中的注释
"代码补全"
62 set completeopt=preview,menu
63 "允许插件"
64 filetype plugin on
65 "共享剪切板"
66 set clipboard+=unnamed
67 "自动保存"
68 set autowrite
69 "打开状态标栏尺"
70 set ruler
71 "突出显示当前行"
72 set cursorline
73 "设置魔术"
74 set magic
75 "语法高亮"
76 set syntax=on
77 "在处理未保存或只读文件时弹出确认"
78 set confirm
79 "自动缩进"
80 set autoindent
80 set autoindent
81
82 set cindent
87 "不要用空格代替制表符"
88 set noexpandtab
89 "在行和段开始处用制表符"
90 set smarttab
91 "显示行号"
92 set number
93 "搜索忽略大小写"
94 set ignorecase
95 "搜索逐字符高亮"
96 set hlsearch
97
98 set incsearch
99 "编码设置"
100 set enc=utf-8
101
102 set fencs=utf-8,ucs-bom,shift-jis,gb18030,gbk,gb2312,cp936
103 "语言设置"
104 set langmenu=zh_CN.UTF-8
105
106 set helplang=cn
107 if filereadable("/etc/vim/vimrc.local")
108 source /etc/vim/vimrc.local
109 endif