如何在Git中管理依赖于另一个项目的项目? [英] How to manage a project dependent on another project in Git?

查看:338
本文介绍了如何在Git中管理依赖于另一个项目的项目?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对这个令人困惑的问题表示歉意,我不知道如何解释它。让我也道歉,我对Git相当陌生,所以我可能会错过一个明显的解决方案(因此为什么我问)。

所以基本上,我有三个在这里,我试图轻松保持最新的一步项目:


  1. 我在CakePHP中开发,更新。

  2. 使用CakePHP,我正在开发一个我称之为Mobile Fort的系统
    ,它基本上是一个完全开发的用户管理系统与
    几个其他功能。

  3. 使用Mobile Fort,我正在开发几个不同的单独
    网站。

    >

    问题是,我如何(如果可能)使用Git让我的CakePHP安装保持最新(CakePHP在Git中开发)到Mobile Fort,并保持我的Mobile Fort安装最新跨越各个项目?



    非常感谢!

    解决方案

    我认为你需要的是 git submodules
    基本上它允许你在回购中有一个subrepo,同时保持它们彼此不同。阅读文档以了解更多信息。


    I apologize for the somewhat confusing question, I'm not sure how to explain it in short. Let me also apologize that I'm fairly new to Git and so I may be missing an obvious solution (thus why I ask).

    So essentially, I have a three step project here that I'm trying to easily keep up to date:

    1. I'm developing in CakePHP, which is regularly updated.

    2. Using CakePHP, I am developing a system I've called "Mobile Fort," which is basically a fully developed user management system with a few other features.

    3. Using Mobile Fort, I'm developing several different individual websites.

    The question is, how do I (if possible) use Git to keep my CakePHP install up to date (CakePHP is developed in Git) to Mobile Fort, and keep my Mobile Fort install up to date across the various individual projects?

    Thank you so much!

    解决方案

    I think what you need is git submodules. Basically it allows you to have a subrepo within a repo, while keeping them distinct from each other. Read the doc to learn more.

    这篇关于如何在Git中管理依赖于另一个项目的项目?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆