[JIRA] (JENKINS-59863) currentBuild.changeSets always null

4 views
Skip to first unread message

omar.malik02@gmail.com (JIRA)

unread,
Oct 21, 2019, 1:40:02 AM10/21/19
to jenkinsc...@googlegroups.com
Omar Malik created an issue
 
Jenkins / Bug JENKINS-59863
currentBuild.changeSets always null
Issue Type: Bug Bug
Assignee: Alex Earl
Components: email-ext-plugin
Created: 2019-10-21 05:39
Environment: Jenkins ver 2.140
Priority: Blocker Blocker
Reporter: Omar Malik

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.

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo

slide.o.mix@gmail.com (JIRA)

unread,
Oct 21, 2019, 10:01:02 AM10/21/19
to jenkinsc...@googlegroups.com
Alex Earl closed an issue as Not A Defect
 

There is no currentBuild in the context of an email-ext template. You can use build.currentChangesets

Change By: Alex Earl
Status: Open Closed
Resolution: Not A Defect
Reply all
Reply to author
Forward
0 new messages