Ubuntu – Cannot install vim

installationvim

I am running Ubuntu 11.10, as Xubuntu, in an AMD 64 pc, configured as dual boot with Windows 7.

I tried installing vim with this:

sudo apt-get install vim

I got this error message:

The following packages have unmet dependencies:
 vim : Depends: vim-common (= 2:7.3.154+hg~74503f6ee649-2ubuntu2) but 2:7.3.154+hg~74503f6ee649-2ubuntu3 is to be installed
E: Unable to correct problems, you have held broken packages.

I only have a very faint idea of what the problem is, and none whatsoever on how to correct this. Hope you guys can help.

Best Answer

You have an outdated package list.

Run this command:

sudo apt-get update && sudo apt-get install vim

What that will do is update your package list, and then try to install vim.

Related Question