Your Vundle configuration looks incorrect. You should call vundle#begin()
at the start, before the Bundle
commands. And you should call vundle#end()
at the end of that section, before you re-enable filetype detection and plug-ins.
(The vundle#rc()
function is an old way to initialize Vundle, it's deprecated now in favor of vundle#begin()
.)
See the Vundle Getting Started page for more details.
You probably also need to have syntax enable
somewhere in your vimrc (not sure if it's there, only not showing in your small snippet.)
You should also use the canonical and more modern 'VundleVim/Vundle.vim'
location for Vundle itself. (You might need to reinstall it into that location, see the first steps in the Getting Started guide for instructions on that.)
I also switched the plug-in declarations to use the more modern Plugin
instead of the older Bundle
. (Vundle went through a few iterations of renaming things...)
Putting it all together:
set nocompatible
filetype off
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
Plugin 'VundleVim/Vundle.vim'
Plugin 'dag/vim-fish'
call vundle#end()
filetype plugin indent on " required
syntax enable
highlight LineNr ctermfg=grey
Hopefully straightening up your Vundle setup will get your fish syntax highlighting working as expected.
Personally, I'd actually recommend that you consider migrating from Vundle to vim-plug, which is a much more modern take on a plug-in manager that is still similar to Vundle (such that users of Vundle will see a familiar environment in vim-plug.) You could say vim-plug is in a way a successor to Vundle in that sense.
You can simply install vim-plug with a simple shell command:
$ curl -fLo ~/.vim/autoload/plug.vim --create-dirs \
https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
After installing it, update your vimrc to the following configuration:
call plug#begin()
Plug 'dag/vim-fish'
call plug#end()
filetype plugin indent on " optional!
syntax enable
highlight LineNr ctermfg=grey
That's all! No messing with rtp
or having to set filetype off
and back on
in the right order and locations...
Once you start Vim with this configuration, simply run :PlugInstall
to have your plug-ins installed by vim-plug. (Similar to how you would have used :VundleInstall
or :PluginInstall
on Vundle.)
See vim-plug's documentation for more. In particular, you might want to take a look at this section on migrating from other plug-in managers, Vundle in particular.