1

I am trying to make pathogen work but I am getting a no matches found error:

I followed the instructions here and getting the above error.

mkdir -p ~/.vim/autoload ~/.vim/bundle; \
curl -Sso ~/.vim/autoload/pathogen.vim \
    https://raw.github.com/tpope/vim-pathogen/master/autoload/pathogen.vim

and pathogen.vim is created in autoload folder and a bundle folder is created as well.

The error I am receiving is

~/.vim]$ source ~/.vimrc    
/Users/malugus/.vimrc:1: no matches found: pathogen#infect

I am on a mac 10.7.5 and I am using zsh shell. Vim version is 7.3

Other related posts seem to be getting a different error - no function found. I suspect autoload isn't doing what it is supposed to do.

Related SO posts that I tried with no avail:

Update: Also I put up my .vim files here - https://github.com/prolificcoder/vim. After installing the ruby doc plugin, I ran rake. Few files were created including ~/.vim/plugin/ruby-doc.vim. So I go back vim and open a rails file. When I press RR on a ruby method, I see the screen flicker but I see no browser being opened. The functionality of the plugin is to open the ruby doc in a browser window.

So thinking about this- the problem might be with my vim configuration but not related to pathogen.

Community
  • 1
  • 1
satyajit
  • 1,470
  • 3
  • 22
  • 43
  • 2
    Do include the full error message (it must have told you where the error happens). – ZyX Nov 27 '12 at 18:07
  • Yes, and when the error occurs. Are you on a UNIX-like OS? – romainl Nov 27 '12 at 18:18
  • Could you show us your `.vimrc` file? Just whatever Pathogen does. Thanks. – greduan Nov 27 '12 at 23:21
  • Did you edit your `.vimrc` file as the [documentation suggests](https://github.com/tpope/vim-pathogen#runtime-path-manipulation)? You need to add `call pathogen#infect()` in there somewhere. – Marius Nov 28 '12 at 00:39
  • What version of vim do you use? In vim7.3, calling unknown autoload function occur E117, and I can't see the message "no matches found" in pathoge.vim and source code of vim. Older version remains in your after directory? – mattn Nov 28 '12 at 02:57

1 Answers1

2

pathogent#infect is a wrong name: there is a t just before # which should not be there.

But I see your problem is different: ~/.vim]$ suggests that you are doing source ~/.vimrc while being in zsh. It is completely wrong, ~/.vimrc is a vim configuration file and you must do source ~/.vimrc in an existing vim session (in new vim session there is no need in doing so: vim sources file automatically). I still don’t get why you are having “no matches found error”, on my system zsh reports parse error near `\n' for line call pathogen#infect() which is what you are supposed to use.

ZyX
  • 52,536
  • 7
  • 114
  • 135
  • 1
    You are correct! When I did :source ~/.vimrc with in vim I got no errors. But I still can't figure out how to use plugins. See my update – satyajit Nov 28 '12 at 16:58
  • @satyajit You have to learn how to write descriptive issue reports. “I can’t use the plugin” is not descriptive at all. Normally it is “what have you tried - what is the result of your attempts - what did you expect as the result”. – ZyX Nov 28 '12 at 17:40
  • I felt that I already belabored and people miss the question in all the details. But I will expand – satyajit Nov 28 '12 at 18:05
  • @satyajit It does not look like a pathogen or ruby-doc issue. If plugin was not working `RR` would enter replace mode and replace character under cursor with `R`, it would not cause screen to flicker once. Check ruby-doc documentation for how it opens browser (especially related variables), it is likely that it either tries to use one that is not installed or it uses `xdg-open` and xdg-open itself does not support your browser. – ZyX Nov 28 '12 at 18:34
  • So I installed other plugins through pathogen and they are working. I just got confused with no matches found message in zsh. But now I know :) – satyajit Nov 28 '12 at 21:53