Clearcase: list all changed files between 2 baselines

南笙酒味 提交于 2019-12-22 11:26:33

问题


I want to know all files that changed between 2 baselines. I need to have a list in text. Through the interface I need to enter in each activity of baseline. In this dialog, I list the files, but can't copy the names to a text editor.


回答1:


The normal command is:

cleartool diffbl -ver baseline1@\apvob baseline2@\apvob

But be aware it will list all the versions changed between the two baselines, not just the elements (files or directory).
That means a file could be listed multiple times, because multiple versions of said files have changed between the two baselines.

That old thread mentions a potential solution (not tested) in order to list the elements (files or directories) only once.

my %elem = map {
  tr|\\|/|; # Convert slashes to unix style.
  s|^<< M:/^/+/^/+/||; # Drop view tag and vob tag.
  s|\@\@.*||; # Drop branch and version id.
  $_ => 1; # Pick up the path.
} qx(cleartool diffbl -version -first $laterbl $olderbl);
print sort keys %elem;

The OP neves confirms that this idea works, with:

cleartool diffbl -ver baseline_abc.123@\\MYVOB baseline_abc.358@\\MYVOB | \
  awk -F '\\' '{print $8}' |grep @@|sort| uniq|sed 's/@@//' 


来源:https://stackoverflow.com/questions/17558999/clearcase-list-all-changed-files-between-2-baselines

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