Tfs VSTS团队构建邮件通知应包括“AssociateTechRangeSets”

Tfs VSTS团队构建邮件通知应包括“AssociateTechRangeSets”,tfs,tfsbuild,Tfs,Tfsbuild,团队建设大师 我正在查找构建邮件通知中包含的关联变更集列表 比如说,默认情况下,我们会收到这样的生成通知 Team Project: Content Server Build Number: MerchantPortal_1.0.0707.69 Build Agent: \Content Server\MerchantPortalBuildBox Build Definition: \Content Server\MerchantPortal QA Build started

团队建设大师

我正在查找构建邮件通知中包含的关联变更集列表

比如说,默认情况下,我们会收到这样的生成通知

Team Project:   Content Server
Build Number:   MerchantPortal_1.0.0707.69
Build Agent:    \Content Server\MerchantPortalBuildBox
Build Definition:   \Content Server\MerchantPortal QA
Build started by:   ENETDOM\jrichter
Build Start Time:   7/7/2009 8:25:30 AM
Build Finish Time:  7/7/2009 8:30:49 AM

Notes: 
- All dates and times are shown in GMT -05:00:00 Central Daylight Time
- You are receiving this notification because of a subscription created by ENETDOM\enbuild
Provided by Microsoft Visual Studio® Team System 2008
我真正想要的是一封包含更改的电子邮件。因此,用户不必单击URL来检索更改列表。 所以我希望邮件看起来像这样:

Team Project:   Content Server
Build Number:   MerchantPortal_1.0.0707.69
Build Agent:    \Content Server\MerchantPortalBuildBox
Build Definition:   \Content Server\MerchantPortal QA
Build started by:   ENETDOM\enbuild
Build Start Time:   7/7/2009 8:25:30 AM
Build Finish Time:  7/7/2009 8:30:49 AM


**Associated changesets:
482 DOMAIN\johny    Not needed...
486 DOMAIN\adam A final synchronization with SourceSafe files after the 15 december release.
487 DOMAIN\bob  Corrected the naught millenium bug....
488 DOMAIN\sarah    Reverted back to csproj file with SC changes....
Associated  work items:**
....


Notes: 
- All dates and times are shown in GMT -05:00:00 Central Daylight Time
- You are receiving this notification because of a subscription created by ENETDOM\enbuild
Provided by Microsoft Visual Studio® Team System 2008

据我所知,没有任何配置选项允许这样做

如果您可以访问服务器,我认为有一种方法可以编写自定义代码,将其挂接到服务器上的事件系统中,您可以构建自己的电子邮件格式。但我认为这将是一项艰巨的工作


我同意,无法自定义电子邮件内容令人沮丧。

您可以使用以下代码获取相关的更改集:

TeamFoundationServer tfs = TeamFoundationServerFactory.GetServer(TeamFoundationServerUrl);
IBuildServer buildServer = (IBuildServer)tfs.GetService(typeof(IBuildServer));
IBuildDetail build = buildServer.GetAllBuildDetails(new Uri(BuildUri));

List<IChangesetSummary> assocChangesets = InformationNodeConverters.GetAssociatedChangesets(build);
您可以使用web服务侦听构建并从eventXml读取构建URI