我想要将私人的vim配置文件和插件备份到github上,但是有些插件是通过vundle安装的,目录带有.git仓库。
出现的情况:当我在.vim目录下
git init
git add .
git commit -m ""
git push
这时候push到github仓库里面的一些子模块只有目录名没有文件.
谷歌:需要将带有.git仓库的插件作为子模块添加到.vim文件夹下作为submodule,
但是git官网submodule的教程没有说怎么将本地git仓库添加到另一个git仓库作为submodule。
问题:我该怎么完整的把整个.vim文件夹备份到github,备份.vimrc文件的话一些插件还是要通过vundle去插件官网下载,有些插件好像是服务器在国外原因下载好慢,例如YouComPleteMe.
为情所困2017-05-02 09:53:06
Git backup should not include Vundle backups in the first place. If you really want to copy to another place where the network is inconvenient, you can write a script to package the corresponding files.
For example, under Windows, I have a script win_init.cmd:
If you execute it directly, Vundle and other warehouses will be automatically downloaded. Check whether .vimrc
和detorte
配色方案拷贝到Windows下的相应目录。然后检查curl
, ag
, ctags
, gtags
and other necessary tools are installed. If not, download them to the corresponding directory.
win_init.cmd portable
, it will package all local Vim-related files, copy them to other machines and decompress them, and also include various plug-ins installed under Vundle.