Why do I get these .vimrc errors in Ubuntu 14 after upgrade from Ubuntu 13?

Michael Durrant

I get errors for all these commands when I try to use vim (though vim then works):

autocmd BufWritePre *.rb :%s/\s\+$//e
set filetype off
filetype plugin on
filetype indent on
syntax on " Turn on syntax highlighting
match ExtraWhitespace /\s\+$/
autocmd BufWinEnter * match ExtraWhitespace /\s\+$/
autocmd InsertEnter * match ExtraWhitespace /\s\+\%#\@<!$/
autocmd InsertLeave * match ExtraWhitespace /\s\+$/
autocmd BufWinLeave * call clearmatches()
let mapleader = ","
set foldmethod=indent   "fold based on indent
set foldnestmax=10      "deepest fold is 10 levels
set nofoldenable        "dont fold by default
set foldlevel=1         "what I use
let loaded_matchparen = 1 " MDD Turn off matching bracket " Ubuntu14 filetype plugin indent on    " required

If I comment these lines out in my .vimrc I don't get any errors.

But I suspect I may have now 'lost' those settings.

Is there a different form for them or something in vim in Ubuntu 13?

Errors:

Three categories:

  • Sorry, the command is not available in this version
  • Option not supported
  • Unknown option

Details:

$ vi .vimrc
Error detected while processing /home/durrantm/.vimrc:
line   20:
E319: Sorry, the command is not available in this version: autocmd BufWritePre *.rb :%s/\s\+$//e
line   24:
E519: Option not supported: filetype 
line   25:
E319: Sorry, the command is not available in this version: filetype plugin on
line   26:
E319: Sorry, the command is not available in this version: filetype indent on
line   27:
E319: Sorry, the command is not available in this version: syntax on " Turn on syntax highlighting
line   37:
E319: Sorry, the command is not available in this version: match ExtraWhitespace /\s\+$/
line   38:
E319: Sorry, the command is not available in this version: autocmd BufWinEnter * match ExtraWhitespace /\s\+$/
line   39:
E319: Sorry, the command is not available in this version: autocmd InsertEnter * match ExtraWhitespace /\s\+\%#\@
<!$/
line   40:
E319: Sorry, the command is not available in this version: autocmd InsertLeave * match ExtraWhitespace /\s\+$/
line   41:
E319: Sorry, the command is not available in this version: autocmd BufWinLeave * call clearmatches()
line   48:
E319: Sorry, the command is not available in this version: let mapleader = ","
line   52:
E518: Unknown option: foldmethod=indent
line   53:
E518: Unknown option: foldnestmax=10
line   54:
E518: Unknown option: nofoldenable
line   55:
E518: Unknown option: foldlevel=1
line   57:
E319: Sorry, the command is not available in this version: let loaded_matchparen = 1 " MDD Turn off matching brac
ket highlighting.
line   58:
E319: Sorry, the command is not available in this version: filetype plugin indent on
Michael Durrant

Turns out I didn't have vim, just had vi, due to dependency issues after the upgrade.

tl;dr; - needed older versions of dependencies. Fixed with:

$ sudo apt-get remove vim-common 
$ sudo apt-get remove vim-runtime
$ sudo apt-get update && sudo apt-get install vim  
Change .vimrc setting "set filetype off" => "filetype off"

Full Version...

Fix was:

Attempted to do:

apt-get install vim

But got message

...
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 vim : Depends: vim-common (= 2:7.4.052-1ubuntu3) but 2:7.4.335-1~ppa1~s is to be installed
       Depends: vim-runtime (= 2:7.4.052-1ubuntu3) but 2:7.4.335-1~ppa1~s is to be installed
E: Unable to correct problems, you have held broken packages.
$

So then I tried:

$ sudo apt-get install vim-common

Reading package lists... Done
Building dependency tree       
Reading state information... Done
vim-common is already the newest version.

Finally, realizing that the messages say the dependency is 2:7.4.052 but I have 2:7.4.335 for vim-common and vim-runtime, in other words I had more recent versions. Realizing this the final fix was:

$ sudo apt-get remove vim-common 
...
$ sudo apt-get remove vim-runtime

Then I was able to do;

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

This fixed all the issues except for one line

set filetype off

which I changed to

filetype off

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

Why do PPAs get errors after an upgrade?

From Dev

Why do PPAs get errors after an upgrade?

From Dev

Unable to do su or sudo after upgrade from 13 to 14

From Dev

Why do I have two bluetooth icons after the Ubuntu 14.04 upgrade?

From Dev

Why there are 2 versions of Linux after I upgrade the Ubuntu?

From Dev

How do I restore pip after upgrade from ver 9 to ver 18 on Ubuntu 18.04 Desktop Vm?

From Dev

Why does Akonadi not start after upgrade from Ubuntu 19.04 to 19.10?

From Dev

Why does Ubuntu 17.10 not look like it after upgrade from 16.04

From Dev

Upgrade from Ubuntu 16.04 to 18.04.1: why do I need to wait several days?

From Dev

Do i need to reinstall ubuntu after GPU/CPU upgrade

From Dev

Why do I get unmet dependencies errors when installing Nvidia 418 drivers on Ubuntu 18.04?

From Dev

No video after "apt-get upgrade" from Ubuntu 16.04.1 and 16.04.2?

From Dev

Ubuntu Server: how do I upgrade from 16.04 to 17.04 to get better hardware support?

From Dev

Ubuntu 14 upgrade problem , because i installed ROS in Ubuntu

From Dev

Why I can not scroll by my thinkpad usb keyboard's trackpoint after I upgrade Ubuntu from 15.04 to 15.10

From Dev

Stuck at fsck "/dev/sda1: clean xxx/xxx files [...] " after upgrade to Ubuntu 16 from 14

From Dev

Stuck at fsck "/dev/sda1: clean xxx/xxx files [...] " after upgrade to Ubuntu 16 from 14

From Dev

How do I upgrade Ubuntu OS from 32 to 64 bit?

From Dev

How do I install qps from repositories on ubuntu 13?

From Dev

How do I install qps from repositories on ubuntu 13?

From Dev

How to do a Vagrant upgrade from Ubuntu 12 to 14 (precise64 to trusty64)

From Dev

rEFind doal boot option disappeared after ubuntu 14 to 16 upgrade

From Dev

Ubuntu "Could not get screen information" after upgrade

From Dev

Should I upgrade to "Ubuntu 14.04 'Trusty Tahr'" from "Ubuntu 12.04 LTS" and what care do I need to take if I upgrade?

From Dev

Can I repair Ubuntu after an interrupted upgrade?

From Dev

Ubuntu 20.04 with root on ZFS errors after 'apt dist-upgrade'

From Dev

ubuntu 12.10 not working after Upgrade from 12.04

From Dev

Why am I not getting the Ubuntu 18.04 upgrade?

From Dev

How to upgrade alsamixer in ubuntu 13

Related Related

  1. 1

    Why do PPAs get errors after an upgrade?

  2. 2

    Why do PPAs get errors after an upgrade?

  3. 3

    Unable to do su or sudo after upgrade from 13 to 14

  4. 4

    Why do I have two bluetooth icons after the Ubuntu 14.04 upgrade?

  5. 5

    Why there are 2 versions of Linux after I upgrade the Ubuntu?

  6. 6

    How do I restore pip after upgrade from ver 9 to ver 18 on Ubuntu 18.04 Desktop Vm?

  7. 7

    Why does Akonadi not start after upgrade from Ubuntu 19.04 to 19.10?

  8. 8

    Why does Ubuntu 17.10 not look like it after upgrade from 16.04

  9. 9

    Upgrade from Ubuntu 16.04 to 18.04.1: why do I need to wait several days?

  10. 10

    Do i need to reinstall ubuntu after GPU/CPU upgrade

  11. 11

    Why do I get unmet dependencies errors when installing Nvidia 418 drivers on Ubuntu 18.04?

  12. 12

    No video after "apt-get upgrade" from Ubuntu 16.04.1 and 16.04.2?

  13. 13

    Ubuntu Server: how do I upgrade from 16.04 to 17.04 to get better hardware support?

  14. 14

    Ubuntu 14 upgrade problem , because i installed ROS in Ubuntu

  15. 15

    Why I can not scroll by my thinkpad usb keyboard's trackpoint after I upgrade Ubuntu from 15.04 to 15.10

  16. 16

    Stuck at fsck "/dev/sda1: clean xxx/xxx files [...] " after upgrade to Ubuntu 16 from 14

  17. 17

    Stuck at fsck "/dev/sda1: clean xxx/xxx files [...] " after upgrade to Ubuntu 16 from 14

  18. 18

    How do I upgrade Ubuntu OS from 32 to 64 bit?

  19. 19

    How do I install qps from repositories on ubuntu 13?

  20. 20

    How do I install qps from repositories on ubuntu 13?

  21. 21

    How to do a Vagrant upgrade from Ubuntu 12 to 14 (precise64 to trusty64)

  22. 22

    rEFind doal boot option disappeared after ubuntu 14 to 16 upgrade

  23. 23

    Ubuntu "Could not get screen information" after upgrade

  24. 24

    Should I upgrade to "Ubuntu 14.04 'Trusty Tahr'" from "Ubuntu 12.04 LTS" and what care do I need to take if I upgrade?

  25. 25

    Can I repair Ubuntu after an interrupted upgrade?

  26. 26

    Ubuntu 20.04 with root on ZFS errors after 'apt dist-upgrade'

  27. 27

    ubuntu 12.10 not working after Upgrade from 12.04

  28. 28

    Why am I not getting the Ubuntu 18.04 upgrade?

  29. 29

    How to upgrade alsamixer in ubuntu 13

HotTag

Archive