Why does vi behave differently in Ubuntu than in CentOS?

In ubuntu, the default vim install comes from the package vim-tiny, which isn't the whole thing.

You probably want to:

apt-get install vim

or

apt-get install vim-full

Some of your other problems sound like issues with the backspace key and other things. Once you get the full version of vim, try adding these to your .vimrc:

set nocompatible

set t_kb=^H
fixdel

(IMPORTANT NOTE: that ^H is a literal ctrl-H character, which you'll get by doing Ctrl-V Ctrl-H in insert mode)


The previously offered answers did not work for me.

I tend to prefer leaving OS installations as stock as possible and keeping config files as simple as possible. In order to fix these three issues in Ubuntu 12.04, I did the following:

In "~/.vimrc", insert the lines -
set nocp
set bs=2

Tags:

Vim

Ubuntu

Centos