parameterized job which is used to run automatic tests using Postman. So when the build is completed an email is triggered with the build attachment logs. We are using Newman in Jenkins which returns a table with the results.
So i would like to include that table into my email body when the Jenkins completes the build. I am attaching the sample table here. Kindly help me in this please also let me know if you need any additional info.
You can generate an HTML file and then set that as the body of the email (make sure to set the content type to HTML as well). The ${FILE} macro would probably be the most useful in this case.
@slide_o_mix Thank you so much for the suggestions. Could you please provide us a reference how can we write a file for text table in Jenkins and then use the same File macro in email body ? As i am not very much good in scripting so asking this question please pardon me.
You can find information on writeFile in the Jenkins docs. All of the content tokens (and their documentation) for email-ext can be seen in the pipeline step generator on your Jenkins instance.