-
Bug
-
Resolution: Not A Defect
-
Blocker
-
None
-
Jenkins ver 2.140
I was wondering if someone can help me.
I am using the extended-email plugin together with jelly.
When running the plugin (linked to a jelly script) .
<!-- CHANGE SET -->
<j:set var="changeSets" value="${scurrentBuild.changeSets}" />
<j:if test="${changeSets!=null}">
<j:set var="hadChanges" value="false" />
<TABLE width="100%">
<TR>
<TD class="bg1" colspan="2"><B>CHANGES</B></TD>
</TR>
<j:forEach var="cs" items="${changeSets}" varStatus="loop">
<j:set var="hadChanges" value="true" />
<j:set var="aUser" value="${cs.hudsonUser}"/>
<TR>
<TD colspan="2" class="bg2"> Revision <B>${cs.commitId?:cs.revision?:cs.changeNumber}</B> by
<B>${aUser!=null?aUser.displayName:cs.author.displayName}: </B>
<B>(${cs.msgAnnotated})</B>
</TD>
</TR>
<j:forEach var="p" items="${cs.affectedFiles}">
<TR>
<TD width="10%"> ${p.editType.name}</TD>
<TD>${p.path}</TD>
</TR>
</j:forEach>
</j:forEach>
<j:if test="${!hadChanges}">
<TR><TD colspan="2">No Changes</TD></TR>
</j:if>
</TABLE>
<BR/>
</j:if>
The currentBuild.changeSets is always null. I am wondering why this is null. I do the checkout before hand and I see my commits on the jenkins homepage.
Any help would be great.
There is no currentBuild in the context of an email-ext template. You can use build.currentChangesets