1. Vim 各个版本的区别:
查看version,vi <任意文件>,:version,得到如下信息:
:version VIM - Vi IMproved 7.0 (2006 May 7, compiled Jul 10 2012 08:48:32) Included patches: 1, 3-4, 7-9, 11, 13-17, 19-26, 29-31, 34-44, 47, 50-56, 58-64, 66-73, 75, 77-92, 94-107, 109, 202, 234-237 Compiled by <bugzilla@redhat.com> Tiny version without GUI. Features included (+) or not (-): -arabic -autocmd -balloon_eval -browse +builtin_terms -byte_offset -cindent -clientserver -clipboard -cmdline_compl -cmdline_hist -cmdline_info -comments -cryptv -cscope -cursorshape -dialog -diff -digraphs -dnd -ebcdic -emacs_tags -eval -ex_extra -extra_search -farsi -file_in_path -find_in_path -folding -footer +fork() -gettext -hangul_input +iconv -insert_expand -jumplist -keymap -langmap -libcall -linebreak -lispindent -listcmds -localmap -menu -mksession -modify_fname -mouse -mouse_dec -mouse_gpm -mouse_jsbterm -mouse_netterm -mouse_xterm +multi_byte -multi_lang -mzscheme -netbeans_intg -osfiletype -path_extra -perl -printer -profile -python -quickfix -reltime -rightleft -ruby -scrollbind -signs -smartindent -sniff -statusline -sun_workshop -syntax -tag_binary -tag_old_static -tag_any_white -tcl +terminfo -termresponse -textobjects -title -toolbar -user_commands -vertsplit -virtualedit -visual -viminfo -vreplace +wildignore -wildmenu -windows +writebackup -X11 -xfontset -xim -xsmp -xterm_clipboard -xterm_save system vimrc file: "/etc/virc" user vimrc file: "$HOME/.vimrc" user exrc file: "$HOME/.exrc" fall-back for $VIM: "/usr/share/vim" Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector - -param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2 Linking: gcc -L/usr/local/lib -o vim -lselinux -ltermcap -lacl
ubuntu下预装的版本是vim.tiny,这个更靠近纯vi了,不能使用小键盘和方向键,在编辑模式下,移动光标会变成A B C D等字符并换行。
解决方法两个;
1.vim缺省是vi兼容模式,设置成不兼容模式就好了:
:set nocp
2.安装完整VIM
VIM其他版本:vim-gnome安装的vim依赖于gnome的某些东西的。vim-gtk 依赖于gtk的某些东西。vim-nox这个不知道,ubuntu官网也没说明。还有一个vim-athena,据说是界面很华丽,没用过不评论。具体看http://packages.ubuntu.com/oneiric/vim
2. Vi
3. vim
百度百科中的vim命令简单介绍: