Bzr:从现有的独立存储库创建共享存储库 [英] Bzr: Create a shared repository from an existing stand-alone repository

查看:46
本文介绍了Bzr:从现有的独立存储库创建共享存储库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在过去的几个月里,我一直在使用 Bzr 对我的项目进行版本控制.我是唯一的开发人员,目前我只有一个本地项目目录中的所有内容,我提交并同步到 DriveHQ.

I have been using Bzr for version control of my project over the last few months. I am the sole developer, and currently I just have everything in a single local project directory, to which I commit and which I sync to DriveHQ.

我现在想到了一些可能会打破这条主线的大规模实验,所以我一直在研究分支和共享存储库的概念.所以我的问题基本上是:我应该如何从这个已经受版本控制的基础上创建一个新的共享存储库?

I now have some large-scale experiments in mind which would likely break this main line, so I've been looking into the concepts of branches and shared repositories. So my question is, basically: how should I go about creating a new, shared repository from this already-version-controlled base?

我熟悉主干、分支和标签的SVN项目结构,打算采用这种结构.我的计划是继续做一个新的 init-repo,并将我的所有代码(加上 .bzr)复制到主干文件夹中.这样可以吗?或者有什么方法可以将我已有的内容转换为共享存储库?

I am familiar with the SVN project structure of trunk, branches and tags, and I'm going to adopt this structure. My plan is to just go ahead and do a fresh init-repo, and copy all my code (plus .bzr) over into the trunk folder. So is this OK? Or is there some way to convert what I have already into a shared repository?

非常感谢您的帮助.

克里斯托弗

推荐答案

好的,所以你有一些 work 目录,你的独立分支所在的目录.您想在新的共享存储库中创建 trunk 和功能分支.

OK, so you have some work directory where your standalone branch is. You want to create trunk and feature branches in new shared repo.

首先你需要自己创建一个共享仓库:

At first you need to create a shared repository itself:

bzr init-repo /path/to/repo

现在你可以把你的代码放到repo/trunk.您可以使用pushbranch 或者您可以复制work 并使用reconfigure.

Now you can put your code to repo/trunk. You can use push, branch or you can copy work and use reconfigure.

  1. cd 工作;bzr push/path/to/repo/trunk
  2. cd path/to/repo;bzr 分支/path/to/work trunk
  3. 或者复制/移动work/path/to/repo/trunk然后cd/path/to/repo/trunk;bzr 重新配置 --use-shared

在所有情况下,您将拥有分支 trunk 作为旧 work 的副本,并且此 trunk 将使用共享存储库来保存修订.

In all cases you'll have branch trunk as a copy of your old work, and this trunk will use shared repository to save the revisions.

您还可以查看 bzr-colo 插件.

You can also look at bzr-colo plugin.

这篇关于Bzr:从现有的独立存储库创建共享存储库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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