ClearCase动态视图中两个版本之间的差异 [英] Difference between two versions in ClearCase dynamic view

查看:77
本文介绍了ClearCase动态视图中两个版本之间的差异的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

说,我在ClearCase中有两种不同的动态视图。

Say , I've two different dynamic views in ClearCase.

我想知道是否有命令给出报告:

x添加了x行,y删除了两行,更改了z行

I would like to know if there is any command to give a report with:
"x lines added , y lines deleted , z lines changed" between two versions.

推荐答案

是的,您可以使用 diffstat 产生一个非常漂亮的视觉效果,添加了x行,删除了y行,更改了z行概述(1 )。

Yes, you can use diffstat to produce a very nice, visual "x lines added , y lines deleted , z lines changed" overview (1).

以下是比较diffstat的两个最新版本的输出示例:

Here is an example of the output from comparing the two latest versions of diffstat:

$ diff -u diffstat-1.53 diffstat-1.54 | diffstat
 CHANGES    |   12 +++++++++++-
 diffstat.1 |    4 ++--
 diffstat.c |   57 +++++++++++++++++++++++++++++++++++++++++++++++++++------
 3 files changed, 64 insertions(+), 9 deletions(-)

以您的情况运行

diff -u /view/VIEW1/SOMEVOB/some/dir_or_file /view/VIEW2/SOMEVOB/some/dir_or_file | diffstat






(1)
实际上是如果不分析各行的含义,则无法确定 z行已更改(而且计算机算法无法做到这一点)。例如。如果旧行是 int x; 而新行是 int y; 是a) x 更改为 y 或b)删除 x y 已添加?


(1) Actually "z lines changed" is impossible to determine without analysing the meaning of the lines (and a computer algorithm cannot do that). E.g. if the old line is int x; and the new line is int y;, is a) x changed to y or b) x removed and y added?

这篇关于ClearCase动态视图中两个版本之间的差异的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆