10

I want to keep my Vim plugins up-to-date with git by using github repos as submodules with the help of pathogen. Everything is well except pathogen itself.

For example, I have a repository in ~/.vim, at pathogen's repo has autoload directory in its root: <pathogen repo>/autoload.

Is it possible to make a git submodule so that pathogen's autoload goes into ~/.vim?

~/.vim/autoload/pathogen.vim

2 Answers 2

21

Clone the submodule into a subdirectory and symlink it's contents.

For pathogen, I also explicitly blacklisted itself (in the bundle directory) to prevent it from self-sourcing.

Sign up to request clarification or add additional context in comments.

2 Comments

This is what I ended up doing, except pathogen is outside bundle directory. This doesn't work on Windows (which I don't use, anyway), so I was waiting for a somewhat portable answer to appear.
I believe you can create a symbolic link in Windows: howtogeek.com/howto/windows-vista/…
10

You can't have a submodule at the root of your repository because both .git folder would conflicts.

You must create your submodule in a subfolder.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.