Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Pathogen does not load plugins

Tags:

vim

vim-plugin

Pathogen does not work for me. I am following Adam Lowe's hints posted here (and few more) without any success...

My vimrc:

filetype off call pathogen#runtime_append_all_bundles()  filetype plugin indent on set nocompatible syntax on set tabstop=2 set smarttab set shiftwidth=2 set autoindent set expandtab set number colorscheme darkblue 

Contents of .vim - ls .vim/*:

.vim/autoload: pathogen.vim  .vim/bundle: nerdcommenter/  vim-haml/   vim-surround/ vim-endwise/    vim-rails/  vim-vividchalk/ 

All plugins in bundle were installed by cloning them from GitHub into bundle directory.

I have tried with pathogen 1.1 and 1.2 and even the latest from GitHub without any result. Vividchalk, Vim-rails and nerdcommenter are not working. I have very little experience with other plugs so I am not sure about them, but I suppose they are not working too.

I am using ArchLinux, vim 7.2.385-1 (not the latest because the latest requires me to install ruby1.9, but it is still 7.2). It has been installed via pacman - ArchLinux package manager. No vim plugins were installed the other way than using pathogen (I have even reinstalled vim package with cleaning /usr/share/vim).

What am I doing wrong?

EDIT:

  • /etc/vimrc http://hpaste.org/fastcgi/hpaste.fcgi/view?id=29685#a29685
  • /usr/share/vim/vimfiles/archlinux.vim http://hpaste.org/fastcgi/hpaste.fcgi/view?id=29686#a29686
like image 419
skalee Avatar asked Aug 01 '10 19:08

skalee


2 Answers

This seems to be common problem caused by the "system" vimrc in some distributions setting filetype on before you set up pathogen. So turning it off and back on again forces plugins to load correctly:

 call pathogen#runtime_append_all_bundles()  filetype off  syntax on  filetype plugin indent on 

More info here.

like image 186
Dave Ray Avatar answered Oct 08 '22 12:10

Dave Ray


I was having a similar problem. Pathogen was loading some of my plugins while not all of them. After some fiddling and wondering I discovered (I don't know if it's mentioned in the documentation) that in each bundle/'plugin_name' folder, there should be another folder called plugin that contains the *.vim file.

Then, when vim starts will look, not in bundle, but in those folders within bundle that contain a folder called plugin... and will create other folders (in each plugin folder).

So, if the plugin is just a .vim file make a folder for it...

instead of:

~/.vim/bundle/vimexplorer/vimExplorer.vim 

you need:

~/.vim/bundle/vimexplorer/plugin/vimExplorer.vim 

And everything works like a charm.

like image 32
fioghual Avatar answered Oct 08 '22 14:10

fioghual