如何在元素(不是版本)级别向VOB中的每个文件添加属性 [英] How to add attribute to every file in VOB at element (not version) level
问题描述
我正在尝试为给定VOB中的每个文件向元素添加属性,并且我找不到避免避免将属性添加到版本而不是元素的语法.
I'm trying to add an attribute to the element for every file in a given VOB, and I can't find the syntax to avoid having the attribute added to the version instead of the element.
这就是我要尝试的:
cleartool find . -exec "cleartool mkattr Exception \\\"NEW_VAL\\\" \"%CLEARCASE_PN%\""
我总是得到
Created attribute "Exception" on ".\bigrdj6000\bigrdj6000.fmb@@\main\4".
我已经在find命令中尝试了-nxn,-all和-element的许多组合,但是我似乎无法摆脱@@ \ main \ 4
I've tried lots of combinations of -nxn, -all and -element on the find command, but I just can't seem to get rid of the @@\main\4
有人可以让我摆脱痛苦吗?
Can somebody please put me out of my misery?
推荐答案
尝试:
cleartool find . -exec "cleartool mkattr Exception \\\"NEW_VAL\\\" \"%CLEARCASE_PN%@@\""
^^
|
(final '@@' to reference an element)
问题是 \%CLEARCASE_PN%\"
表示视图中的文件,这意味着该视图的配置规范所选择的文件的 version
The problem is that \"%CLEARCASE_PN%\"
represents a file within a view, meaning the version of that file as selected by the config spec of that view.
但是, \%CLEARCASE_PN%@@ \"
应该代表该文件的 .
However, \"%CLEARCASE_PN%@@\"
should represent the element of that file.
This is compliant with the mkattr
man page:
cmd-context mkattr RESPONSIBLE \"Anne\" hello.c@@
Created attribute "RESPONSIBLE" on "hello.c@@".
这篇关于如何在元素(不是版本)级别向VOB中的每个文件添加属性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!