Submodules for vim plugins
This commit is contained in:
parent
88c3671e74
commit
d68e711e5a
30
.gitmodules
vendored
Normal file
30
.gitmodules
vendored
Normal file
|
@ -0,0 +1,30 @@
|
|||
[submodule "home/.vim/bundle/Vundle.vim"]
|
||||
path = home/.vim/bundle/Vundle.vim
|
||||
url = https://github.com/gmarik/Vundle.vim
|
||||
[submodule "home/.vim/bundle/nerdtree"]
|
||||
path = home/.vim/bundle/nerdtree
|
||||
url = https://github.com/scrooloose/nerdtree
|
||||
[submodule "home/.vim/bundle/vim-nerdtree-tabs"]
|
||||
path = home/.vim/bundle/vim-nerdtree-tabs
|
||||
url = https://github.com/jistr/vim-nerdtree-tabs
|
||||
[submodule "home/.vim/bundle/vim-airline"]
|
||||
path = home/.vim/bundle/vim-airline
|
||||
url = https://github.com/bling/vim-airline
|
||||
[submodule "home/.vim/bundle/tagbar"]
|
||||
path = home/.vim/bundle/tagbar
|
||||
url = https://github.com/majutsushi/tagbar
|
||||
[submodule "home/.vim/bundle/molokai"]
|
||||
path = home/.vim/bundle/molokai
|
||||
url = https://github.com/tomasr/molokai
|
||||
[submodule "home/.vim/bundle/ctrlp.vim"]
|
||||
path = home/.vim/bundle/ctrlp.vim
|
||||
url = https://github.com/kien/ctrlp.vim
|
||||
[submodule "home/.vim/bundle/vim-coffee-script"]
|
||||
path = home/.vim/bundle/vim-coffee-script
|
||||
url = https://github.com/kchmck/vim-coffee-script
|
||||
[submodule "home/.vim/bundle/vim-markdown"]
|
||||
path = home/.vim/bundle/vim-markdown
|
||||
url = https://github.com/tpope/vim-markdown
|
||||
[submodule "home/.vim/bundle/editorconfig-vim"]
|
||||
path = home/.vim/bundle/editorconfig-vim
|
||||
url = https://github.com/editorconfig/editorconfig-vim
|
27
make-submodules.py
Normal file
27
make-submodules.py
Normal file
|
@ -0,0 +1,27 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
"""Script to generate the .gitmodules file for the vim plugins."""
|
||||
|
||||
import re
|
||||
|
||||
# Open the files
|
||||
vimrc = open("home/.vimrc", "r")
|
||||
outfh = open(".gitmodules", "w")
|
||||
|
||||
for line in vimrc.readlines():
|
||||
line = line.strip()
|
||||
match = re.search(r"Plugin '(\w+?)/([A-Za-z0-9.-]+?)'", line)
|
||||
if match:
|
||||
username = match.group(1)
|
||||
repo = match.group(2)
|
||||
path = "home/.vim/bundle/{}".format(repo)
|
||||
url = "https://github.com/{}/{}".format(username, repo)
|
||||
print "Submodule:", url
|
||||
|
||||
outfh.write("[submodule \"{}\"]\n".format(path))
|
||||
outfh.write("\tpath = {}\n".format(path))
|
||||
outfh.write("\turl = {}\n".format(url))
|
||||
|
||||
# Clean up.
|
||||
vimrc.close()
|
||||
outfh.close()
|
Loading…
Reference in New Issue
Block a user