I am running an Automated test suite on jenkins and I am able to get the status of the job using Email ext plugin. I want to include only some part of build log in email is there any way that I can do that using groovy syntax? Any help would be appreciated!
def notifyFailed() {
emailext (
subject: "FAILED : Job '${env.JOB_NAME} [${env.BUILD_NUMBER}]'",
body: '''<p><font size="8" color="red">Build Failure!</font></p>
<p>Check console output at "<a href='${BUILD_URL}consoleText'>${JOB_NAME} [${BUILD_NUMBER}]</a>"</p>
${BUILD_LOG_REGEX, regex="^.*?*****.*?$", linesBefore=0, linesAfter=999, maxMatches=10, showTruncatedLines=false,escapeHtml=false}''',