Bzr:从现有的独立存储库创建共享存储库

编程入门 行业动态 更新时间:2024-10-21 13:32:08
本文介绍了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.您可以使用push、branch 或者您可以复制work 并使用reconfigure.

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

  • cd 工作;bzr push/path/to/repo/trunk
  • cd path/to/repo;bzr 分支/path/to/work trunk
  • 或者复制/移动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:从现有的独立存储库创建共享存储库

    本文发布于:2023-11-28 16:34:20,感谢您对本站的认可!
    本文链接:https://www.elefans.com/category/jswz/34/1643151.html
    版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
    本文标签:独立   Bzr

    发布评论

    评论列表 (有 0 条评论)
    草根站长

    >www.elefans.com

    编程频道|电子爱好者 - 技术资讯及电子产品介绍!