简体   繁体   中英

Can I have a cloned git repo inside my own repo?

Say I've got a project under git version control. Within that project, I have a folder called "third_party_tools." And within that folder, I've got a folder called "some_open_source_tool," which was cloned from github.

Will this cause problems? Can I check the tool into git for my project and retain the ability to pull from github if there are updates? Or is it not permitted to have one git repo inside another?

It is permitted to have one git repository inside another. If you want to check the tool into your outer project, I would recommend you look into submodules , which allow you to keep nested git projects in sync properly.

如果使用--recursive标志进行克隆,Nathan将获得所需的内容。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM