如何在Linux下使用clearcase命令行将子分支合并到主分支? [英] How merge sub branch to main branch using clearcase command line under linux?
问题描述
我想将子分支 AAA
中所有标有 XXX
的文件合并到主分支。
I want to merge all the files labelled with XXX
in sub branch AAA
to main branch.
主分支不会更新,因为 AAA
分支出来了,所以合并任务只是将所有更改的文件替换为子分支文件。
The main branch do not update since AAA
branched out, so the merge task is just replace all changed files with sub branch files.
如何在Linux下使用ClearCase命令行( cleartool
)做到这一点?
How can I do this using ClearCase command line (cleartool
) under Linux?
推荐答案
为此,您可以使用命令 cleartool findmerge
。
You can use the command cleartool findmerge
for that.
关键是使用一个视图来选择那些文件:
The key is to use a view which select those files:
element * MYLABEL
element * /main/LATEST
并使用 -ftag yourLabelView
您也可以直接使用 -fver YourLabel
(意味着,不需要特殊的专用视图)
You can also directly use -fver YourLabel
(meaning, no need to have a special dedicated view)
转到设置在 / main
上的动态视图,然后执行以下操作:
Go to a dynamic view set on /main
, and do a:
cd /view/MyView/vobs/MyVob
cleartool findmerge . -fver MyLabel -whynot -print
-为什么和
-print
允许您预览要合并的内容,并查看是否符合您的期望。
The -whynot
and -print
allow you to preview what would be merge and see if that fits what you expect.
预览看起来不错:
cleartool findmerge . -c "Merge MyLabel on main" –fver MyLabel –merge
这篇关于如何在Linux下使用clearcase命令行将子分支合并到主分支?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!