Explain the problem here ...
This is a great tool I can install most of the plugins faster and convenient way. However, it doesn't seem working or supporting to VIM install color schema.
To install onedark schema; I followed the following steps.
I add this description "Plug 'joshdick/onedark.vim', and source it then install it. I also add the colorshema name in .vimrc file. Once it's installed, I see that color schema is activated and seems working. Once I exit VIM, and open another file, I see that VIM can't find the color schema.
E185: Cannot find color scheme 'onedark'VIM - Vi IMproved 8.0 (2016 Sep 12, compiled Jun 06 2019 17:31:41)
Provide a minimal vimrc like the following:
call plug#begin('~/.vim/plugged')
Plug 'joshdick/onedark.vim'
call plug#end()
colorscheme onedark
If you have a vimrc like the following, then onedark should always load if the other Vim you opened uses the same vimrc.
Probably related: https://github.com/junegunn/vim-plug/wiki/faq#im-getting-cannot-find-color-scheme--does-vim-plug-support-color-schemes
Provide a minimal vimrc like the following:
call plug#begin('~/.vim/plugged') Plug 'joshdick/onedark.vim' call plug#end() colorscheme onedarkIf you have a vimrc like the following, then
onedarkshould always load if the other Vim you opened uses the same vimrc.
right, it needs to be loaded every time using the following command.
call plug#begin('~/.vim/plugged') Plug 'joshdick/onedark.vim' call plug#end() colorscheme onedark
On a fresh install in a docker container (Ubuntu 20.04), using
call plug#begin('~/.vim/plugged')
Plug 'joshdick/onedark.vim'
call plug#end()
colorscheme onedark
I still get the error:
E185: Cannot find color scheme 'onedark'
This is really annoying as it suddenly requires user input to type ENTER when using ansible.
silent! colorscheme onedark.
Thanks, yeah, that solved it.
However, it's still just supressing the error, not solving the issue. Or is this expected behavior?
Yes, it is expected on a fresh install. PlugInstall must run first before colorscheme onedark to avoid the error on a new machine.
Most helpful comment
silent! colorscheme onedark.