-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vundle can manage Vundle, when it cloned as git submodule #185
Conversation
When vundle installed as git submodule, git create file '.git' instead of directory '.git'. And vundle cannot update by self :(
Hey @snufrick, |
Hey @snufrick, looks like this
isn't the case for me What i did:
Which shows that after adding Vundle as a submodule PS: sorry for late reply |
I'm having this same problem. The .git folder was created properly on the initial git add submodule but when I checked out the changes to my laptop and ran git submodule init && git submodule update it created the .git file instead of the .git directory and am getting the error when running :BundleInstall If it makes any difference my vim repo is a submodule of another git repo so vundle is the third tier down. |
This patch works for me using git 1.7.10.4. I hope this can be merged in. |
This patch didn't resolve the issue for me. Here is what the log states with or without the patch applied.
If it matters the contents of the file is just a path to the actual gitdir for the submodule in the parent git repository
|
My erikw@inglewood:~/.dotfiles/.vim/bundle/vundle [master]> cat .git
gitdir: ../../../.git/modules/.vim/bundle/vundle |
Were you running :BundleInstall or :BundleInstall! ? I'm curious why this resolved the issue for you but not for me? =[ |
Both |
Found this https://lkml.org/lkml/2011/12/2/316 .. this appears to be a change in the way git creates .git directories for submodules "When populating a new submodule directory with "git submodule init", Apparently the fix is to have code that parses the contents of the .git file in the event that it is not a git directory. I wish I knew vimscript so I could write a patch =/ |
I tried the patch again on a fresh system(VM) and it worked, I tried it again on the system I was having the problem with and it also worked. I must have forgotten to reload vim the first time I tried it. It doesn't appear to do anything with the .git directory either, just check for it so parsing shouldn't be required. I say commit this patch as well =] |
Vundle can manage Vundle, when it cloned as git submodule
Based on feedback i'm merging it in |
Vundle was throwing an error when updating Vundle.vim (itself). Vundle's github has [Issue #185](VundleVim/Vundle.vim#185), which addresses this issue, if Vundle is installed as a submodule.
When vundle installed as git submodule, git create file '.git' instead of
directory '.git' .
When I do :BundleInstall 'autoload/vundle/installer.vim' think there is no '.git' directory in my 'bundle/vundle'
and try to clone vundle repo. It cause 'directory exists error'
Now we check for '.git' file exists and we think if this file readable, this is git repo.