clearcase findmerge supress new element/directory

跟風遠走 提交于 2019-12-06 12:34:04

问题


I have two views say A and B,

c:\a_view
A - View
-------Folder_1-->test.bat
-------Folder_2
-------Folder_3

d:\b_view
B - View
-------Folder_1
-------Folder_2

When I do findmerge (with merge option):

c:\>cleartool findmerge "d:\b_view" -ftag a_view -type d -merge

I am getting output as:

d:\b_view
B - View
-------Folder_1-->test.bat(Merged file)
-------Folder_2
-------Folder_3 (Merged directory)

which is ok as per findmerge behavious,

But I want to merge only existing folder, i.e Folder_1 should be only merged and new elements Folder_3 should be suppressed (should not be merged)

How can we do this?


cd D:\bView\Folder1
cleartool findmerge . -ftag a_view -type d -merge

This is fine, but suppose I have "n" number of folders I have to execute this command "N" times, it would take lot of time,

My requirement is only run on parent folder.

i.e
c:\>cleartool findmerge "d:\b_view" -ftag a_view -type d -merge

and it should exclude the new elements/folders

Do we have any parameter or some regular expression or some thing, which would exclude the new elements ?


回答1:


cd D:\bView\Folder1 cleartool findmerge . -ftag a_view -type d -merge

This is fine, but suppose I have "n" number of folders I have to execute this command "N" times, it would take lot of time,

My requirement is only run on parent folder.

i.e c:>cleartool findmerge "d:\b_view" -ftag a_view -type d -merge and it should exclude the new elements/folders

Do we have any parameter or some regular expression or some thing, which would exclude the new elements ?




回答2:


You could simply go to Folder1 (in the destination view, that is the view where the merge takes place), and run the findmerge from there.

cd D:\bView\Folder1
cleartool findmerge . -ftag a_view -type d -merge

That would limit the merge to that specific folder (you find similar example in the cleartool findmerge man page, since you can merge directory versions).

Do we have any parameter or some regular expression or some thing, which would exclude the new elements ?

The only thing you have would be the NEVER_MERGE type presented in this IBM article:

But that is not practical to apply on all the folder (and their content).

You can also try a merge -ndata on the elements you don't want to merge (by making ClearCase think they are already merged).
Again, not practical.

It is best to list the high-level folders you want to merge and merge them individually.



来源:https://stackoverflow.com/questions/20948535/clearcase-findmerge-supress-new-element-directory

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!