如果我有两个开发流(称为Stream1,Stream2),并且我想将这两个流合并为一个流。
目前,这是我的操作方式:
这是合并2个或更多流的最佳实践,还是有更优雅的方法?
最佳答案
创建一个新的流???没必要。
打开 repo 工作区时,将有一个名为“流目标”的部分,该部分包含在您的流中(特征为“默认”)。
向其中添加流源(要合并的流),将其设置为“当前”,然后在“待更改” View 中会看到“传入”部分,其中包含所有更改集或基准源流。
这个想法是让您接受这些更改集,将它们加载到本地工作区中并对其进行测试(编译和测试),然后将其传递回您的默认流。
“接受”阶段是合并发生的地方(自动或发生冲突时手动进行)。
如this thread中所述:
The merge algorithm in RTC is logically the same as is found in ClearCase, i.e., given a configuration (stream, workspace) that selects a different version of a given file, find the common ancestor of the two versions, and then do a 3-way merge.
Changing the "flow target" of a workspace is just RTC's way of letting you specify what branch (stream) you want to merge into your workspace (cleartool findmerge
gives you the same flexibility).
Note that ClearCase and RTC use a different common ancestor algorithm.
最后一步假设您返回“流目标”部分,并将默认流设置为“当前”。
我更喜欢此工作流程:
在这里,Brent将把目标流设置为当前流,以便传递合并结果。这是一个替代的工作流程,也在How to keep your streams flowing smoothly in Rational Team Concert 3.0.1中进行了描述。
关于rtc - 如何合并两个或多个流,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13647021/