TFS Build Summary Notification with Attachment Link - tfs

How i can add attachment link in TFS Build notification email? I have TFS 2017 on-premises installed. I have tried by making changes in xls file but it didnt worked. i will be grateful to you if anyone can help me with this.

You can find the email templates in %PROGRAMFILES%\Microsoft Team Foundation Server 2015\Application Tier\TFSJobAgent\Transforms and modify them the way you want. In this folder you'll find the build completion events xsl files.
The build events expose a Url property, which shows the hyperlink in the email.
Besides, you could also choose to use some 3rd-party extension to send E-mail Notification.
Send Email
Other Extension
Those tasks they send an email to the address(es) you defined in your pipeline. You can defined the contents of the message yourself.

Related

Change TFS email template

Can I change the email template used by this TFS 2017 feature?
There's a folder under the TFS installation that hosts the templates for the eventing services alerts. You need to modify the xsl file corresponding to your event (in this case WorkItemChangedEvent.xsl) to change the formatting.
You can find this templates under Drive:\%programfiles%\Microsoft Team Foundation Server 15.0\Application Tier\TFSJobAgent\Transforms\1033 and after you modify it, you need to restart the application pool or the website because the templates are cached when the site starts.
P.S. Be sure to backup the original template and the changed one, because in future service packs or hotfixes Microsoft can replace this template and you'll loose your changes.
More info you can find here.

TFS File Changed Notifications in future branches

We've got TFS email alerts set up when certain files are changed. In the future, many of these files will likely have "copies" via branching. Other than manually creating additional alerts each time a branch is created, can anyone offer some strategies for this scenario? Or simply strategies to make sure we're covered in case a branch is created and we forget to create these alerts.
Thanks for any help!
There is no out of box feature for this, you can submit a feature request on VSTS User Voice.
However, if the name of the files is unique,you can create an email alert just with "File Name = filename.extension" and "Folder Path Contains XXX". This will track the change for the file in the specified folders/branches.

Is there a way to inform users about a change in Stash repository?

I would like to know if it is possible to send an e-mail notification to certain users when there is a modification to a particular directory within a repository in Stash. I know it is possible to write a shell script within Jenkins project to do this and then inform through e-mail but I would like to know if there is a native option within Jenkins configuration to this action.
This is possible within BitBucket Server itself as of May 7, 2013:
Repository subscriptions
[...] At times, you may want to receive emails on specific types of messages you care most about including:
...
Commits – when a new commit is added or a comment is left
...
See also Manage Inbox and email notifications.
You can use Poll SCM under Build Triggers section.
Define a job that uses GIT plugin, specify a workspace and machine so it'll always be synced with the latest, and poll every 2 minutes. if there is a change in the repository the job will be triggered. Add a post build action to send emails using the built in email notification or using Email-ext plugin.
Don't forget to edit the SMTP information under Manage Jenkins->Configure.
You can check Here for more information about Jenkins Polling.

Change TFS Alert Email Subject Line

We are running TFS Visual Studio online. Is there a way to configure the email subject line of alert emails to be more user friendly/Readable
No. This is not something you can do with VSOnline. On premise TFS has some templates on the App Server(s) IIRC that you can edit.
I can't see the VSO team adding customisation, but you could always log something on UserVoice and see what happens.
You could consider using the Service Hooks to push notifications to another service that could then create the e-mails. I've not tried this so I don't know how scalable it will be.

Publishing MSTest results to team members

I am trying to publish MSTest results to the team. I'd like to send all the test results by email, or have a testresults.trx file attached, or something similar.
How can this be done in TFS 2010?
We are using trx2html tool to convert MSTest report files to readable form (html files). These html files are attached to email send by MSbuild script to all contacts specified in the mailing list.
In the TFS you have to update build template. Call trx2html tool using InvokeProcess activity after every MStest call and at the end pick all html files and send e-mail using Send email activity, but I don't think there is such activity. You have to implement it or send mail using some external tool/script.

Resources