Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Ignore all errors in vimrc at vim startup

I am trying to create an Ansible script to set up my mac. One role is to set up vim. A first clone my dot-files into a local folder and symlink them to ~/. In my vimrc I use vundle to install extension. So I try to start vim to install all extensions like this:

- name: vim | Install vundle plugins
  shell: vim  +PluginInstall +qall

But when I start this, I get the error:

E185: Cannot find color scheme 'molokai'

Is it possible to suppress this error messages for the first startup?

like image 892
Pascal Avatar asked Feb 09 '19 13:02

Pascal


1 Answers

You can silence the E185: Cannot find color scheme 'molokai' error in your .vimrc by setting silent! colorscheme molokai then install with i.e.: vim -E -s -u ~/.vimrc +PlugInstall +qall.

like image 98
masseyb Avatar answered Sep 20 '22 15:09

masseyb