如何为同一个项目维护单独的 svn 存储库? [英] How to maintain separate svn repositories for the same project?

查看:29
本文介绍了如何为同一个项目维护单独的 svn 存储库?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用一个大型(数千个源文件)公共项目,并在本地进行了少量修改和添加(十几个源文件).本地修改与大项目的其他用户无关.该项目使用 svn,我们自己的项目也是如此.我希望能够在更新时从项目中获取更新并合并我们的更改;我还希望我们的更改保持在源代码控制之下.

I'm using a large (thousands of source files) public project with minor (a dozen source files) local modifications and additions. The local modifications aren't relevant to other users of the big project. The project uses svn, as do we for our own projects. I want to be able to get the updates from the project when it is updated and incorporate our changes; I also want our changes kept under source control.

目前,我只是在需要时更新我们的大项目的工作副本,将我们的更改检出到不同的目录中,并将我们的更改复制到大项目中的相应目录中,并进行一些手动协调修改.这是可行的;它很少改变,没什么大不了的,这种方式有效.但如果我们这边或他们那边的事情变化得更频繁,那就不切实际了.有没有更好的办法?

At present, I'm simply svn updating our working copy of the big project when needed, checking out our changes into a different directory, and copying our changes into the corresponding directories in the big project, with some manual reconciliation of the modifications. It's workable; it's rarely changed, not a big deal, and this way works. But if things on our end or theirs were changing more frequently, it wouldn't be practical. Is there a better way?

推荐答案

您确实希望使用单个存储库,分支现有项目以创建您的版本,然后使用该分支.当主版本发生变化时,您可以将它们的更新合并到您的分支中(因为您只会获得自上次合并以来所做的更改,手动合并 2 棵树要容易得多)

You really want to use a single repository, branch the existing project to create your version, then use that branch. When the main version changes, you can just merge their updates into your branch (as you'll only get the changes made since last time you merged, its a lot easier that manually merging 2 trees)

如果你不能将你的项目添加到主仓库,并且必须维护你自己的项目,那么 svk 值得研究.

If you cannot add your project to the main repo, and have to maintain your own, then svk is something to look into.

这篇关于如何为同一个项目维护单独的 svn 存储库?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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