sudo apt-get install vim-gtk
sudo vim /etc/vim/vimrc
syntax on
set nu // 在左侧行号
set tabstop //tab 长度设置为 4
set nobackup //覆盖文件时不备份
set cursorline //突出显示当前行
set ruler //在右下角显示光标位置的状态行
set autoindent //自动缩进
http://jingyan.baidu.com/article/046a7b3efd165bf9c27fa915.html
:wq 保存文件并退出vi
Question? apt Could not open lock file
Ubuntu与Debian下apt-get软件安装与删除的相关命令
From Ubuntu使用教程:E: 无法获得锁 /var/lib/apt/lists/lock - open , I use sudo rm /var/lib/apt/lists/lock
then, try sudo apt-get install vim-gtk
, succeed. Otherways maybe also abailable, but I didn't try.