Vim variants other than vim-tiny source /etc/vim/vimrc instead of /etc/vim/vimrc.tiny when invoked as vi (ie, Arrow keys not broken when running vi)
Bug #70569 reported by
Constantine Evans
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
vim (Ubuntu) |
Triaged
|
Low
|
Unassigned |
Bug Description
When invoked as vi, vim.tiny sources /etc/vim/
However, when another variant of vim, such as vim-full or vim-gnome is installed, the vi command sources /etc/vim/vimrc, which among other things sets nocompatible, so, for example, arrow keys work in insert mode. This is not the intended behaviour.
Changed in vim: | |
importance: | Undecided → Low |
To post a comment you must log in.
While arrow-key support doesn't bother me particularly, I'd agree that invoking "vi" should bring up a traditional (compatible) vi. However, this should probably be discussed on the ubuntu- devel-discuss list, for the correct solution if not for the desired result.
vim.tiny does what it does only because it has been specifically patched by Debian to look for /etc/vim/vimrc.tiny when and only when it has been invoked as vi. None of the other compiled variants of vim (nor, of course, upstream) have such conditional rc-checking behavior. And I'm not sure that they should: that seems like the wrong way to go.
Instead, what should possibly happen is that the "vi" alternative should be linked directly to vim.tiny by default, instead of vim. That way, installing and update- alternativing a different vim variant would leave vi still invoking a compatible session.