Calculate the Percent Complete of Linked Issues in JIRA

by Byron Barker on December 30, 2020

A client recently asked us to automate the calculation of the the percent complete for linked issues in Jira.

To accomplish this you will need to use the Power Scripts for Jira plugin and add this as a SIL script Post function, listener etc.


number linkedIssuesCount = size(linkedIssues(key)); // number of linked issues
string [] allLinks = linkedIssues(key); // string with keys of linked issues
number doneCount = 0;
for (string eachTask in allLinks){

if (%eachTask%.status == “Closed”){
doneCount = doneCount + 1;
number prctDone = ((doneCount / linkedIssuesCount) * 100);

#{Percent Complete} = “Percent complete: ” + prctDone;