开发者

how to find a file in clearcase

I am using clearcase on linux. I opened a file and this file inclueds an another file, but I try to search where is the included file, I checked some folder(not all the folder, because I contains so many subfolders), can not find it. Is there any 开发者_Go百科method to find a file based on the file name in clearcase? can anyone help me on this?


The inclusion mechanism isn't tied to ClearCase, meaning:
if there is an inclusion path (like "include path/afile), that file should be in "apath", relative to your file. if this is "include afile", it should be in the same directory than your current file.

But if it isn't, that means it has been deleted (i.e. it was present in a former version of the parent directory, but the current version of said directory has dereferenced that file).
That would be a good explanation why you don't seem able to find it.

In that case, you need cleartool find, used with the option nvisible:

–nvi/sible

Includes only those elements, along with their branches and versions, that are not visible (do not have a standard path name) in the view.

(non standard path means "extended pathname", able to reference a file in a previous version of a directory)

The option -all might help also, in order to look in all the vob (in case of that file being moved, then deleted!).

-all

With pname arguments, modifies the meaning of each argument to specify its entire VOB, not just a single file or directory.
Without any pname arguments, specifies the VOB containing the current working directory.

Note: When you use find –all only one instance of an element is reported, even if one or more VOB hard links point to the element. Either the element name or one of the VOB hard links is displayed.

See this SO answer for additional find examples.


Have a look at the cleartool find command. It's quite similar to the linux find command. Been a while since I last did CC... However, this is is how you can locate a file using Linux find

find . -type f -name lostheader.h -print

See e.g. here for an introduction to cleartool find

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜