https://github.blog/2016-02-01-working-with-submodules/
进入当前工作目录下的子目录 cd subDir git submodule add subRepository-url newDirhttps://help.github.com/en/github/using-git/splitting-a-subfolder-out-into-a-new-repository
拆分工作目录 git clone repository-url cd repository-dir git filter-branch --prune-empty --subdirectory-filter FOLDER-NAME BRANCH-NAME (master or gh-pages) 在github上创建repository,并拷贝repository-url连接本地子目录和新的repository git remote -v git remote set-url origin new-repository-url (更新子目录关联的repository) git remote -v git push -u origin BRANCH-NAMEhttps://www.git-tower.com/learn/git/ebook/en/command-line/advanced-topics/submodules
