6

我正在尝试按照MqTutorialHGbook 第 13 章中的描述使用 MQ 设置我的工作流。我挣扎的部分是如何在版本下拥有多个补丁队列。

备择方案:

I. 为每个队列创建一个单独的存储库。为了便于管理,将 repos 标记为 .hgsub 文件中的 subrepos

问题:以下导致错误:路径包含非法组件

 .hg/patches-queue1 = .hg/patches-queue1

二、HGbook 第 13 章描述了您可以在子目录中添加补丁,例如

 qnew queue1/patch1.diff

问题:所有补丁仍在同一个队列中,必须按顺序应用

有没有另一种方法可以让我的所有补丁队列受到版本控制并推送?一个存储库中有多个 HG MQ 补丁队列?

4

1 回答 1

14

查看hg qqueue作为 mq 一部分的命令。它允许您以自动方式切换多个补丁队列:

hg qqueue [OPTION] [QUEUE]

manage multiple patch queues

    Supports switching between different patch queues, as well as creating new
    patch queues and deleting existing ones.

    Omitting a queue name or specifying -l/--list will show you the registered
    queues - by default the "normal" patches queue is registered. The
    currently active queue will be marked with "(active)".

    To create a new queue, use -c/--create. The queue is automatically made
    active, except in the case where there are applied patches from the
    currently active queue in the repository. Then the queue will only be
    created and switching will fail.

    To delete an existing queue, use --delete. You cannot delete the currently
    active queue.

    Returns 0 on success.

options:

 -l --list    list all available queues
 -c --create  create new queue
    --rename  rename active queue
    --delete  delete reference to queue
    --purge   delete queue, and remove patch dir

您不能将 .hg 中的内容作为外部(外部/父)存储库的子存储库,但应该可以为每个 qqueue 存储库提供不同的路径,并且可能使它们成为父存储库的所有子存储库本身在 .hg/patches 中。

于 2011-05-15T19:38:20.747 回答