git submodule add 倉庫地址 路徑 #會在根目錄下會生成一個.gitmodules文件 cat .gitmodules #實例以下,能夠添加多個目錄 [submodule "vendor/TSEmojiView"] path = vendor/TSEmojiView url = https://github.com/jimneylee/TSEmojiView.git [submodule "vendor/JLNimbusTimeline"] path = vendor/JLNimbusTimeline url = https://github.com/jimneylee/JLNimbusTimeline.git #而後初始更新模塊的代碼 git submodule init git submodule update
刪除git
一、刪除「.gitmodules」文件中刪除相應配置信息github
二、清除緩存緩存
git rm –cached