TFS注释/非项目摘要报告 [英] TFS annotate/blame summary report for a project

查看:81
本文介绍了TFS注释/非项目摘要报告的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Team Foundation Server中,我知道您可以使用 Annotate 功能来查看谁最后一次编辑了特定文件中的每一行(相当于CVS中的"Blame").我想做的类似于在项目中的每个文件上运行Annotate,并获得所有已在项目中编辑过文件的开发人员的摘要报告,以及他们当前在其中拥有"了多少行代码项目.

In Team Foundation Server, I know that you can use the Annotate feature to see who last edited each line in a particular file (equivalent to "Blame" in CVS). What I'd like to do is akin to running Annotate on every file in a project, and get a summary report of all the developers who have edited a file in the project, and how many lines of code they currently "own" in that project.

除了系统地运行每个文件的注释外,我看不到实现此目的的方法.有什么想法可以使这个过程更快吗?

Aside from systematically running Annotate of each file, I can't see a way to do this. Any ideas that would make this process faster?

PS-我这样做是为了查看在一个特定的(相当大的)项目中仍然有多少顾问的代码,而不是密切关注我的开发人员,以防万一您担心我的动力:)

PS - I'm doing to this to see how much of a consultant's code still remains in a particular (rather large) project, not to keep tabs on my developers, in case you're worried about my motivation :)

推荐答案

在TFS中的文件目录中递归使用"tf.exe历史记录"命令很容易.这将告诉您谁更改了哪些文件.

It's easy enough to use the "tf.exe history" command recursively across a directory of files in TFS. This will tell you who changed what files.

但是,您所追求的只是这一点而已-您想知道任何文件的最新版本是否都有特定用户编写的行.

However what you're after is a little bit more than this - you want to know if the latest versions of any files have lines written by a particular user.

Team Foundation Power Tools附带了一个命令行版本的注释,称为"tfpt.exe注释".它具有一个/noprompt选项,将输出定向到控制台,但仅输出更改集ID,而不输出用户名.

The Team Foundation Power Tools ship with a command-line version of annotate called "tfpt.exe annotate". This has a /noprompt option to direct the output to the console, but it only outputs the changeset id - not the user name.

您还可以使用TFS VersionControl对象模型编写完全满足您需要的工具.

You could also use the TFS VersionControl object model to write a tool that does exactly what you need.

这篇关于TFS注释/非项目摘要报告的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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