How can I get the latest released or earliest unreleased version?

Jonas July 12, 2021

I'm trying to make an automation that compares a version on an issue (or more precisely, from the latest comment on an issue) with my released versions, and if the version is the latest released version, I want to perform an action.

In JQL there's the function to get latestReleasedVersion() or earliestUnreleasedVersion(), but I can't get that to work in automation because it's not a smart value ( i.e. {{latestReleasedVersion}}  doesn't return anything).

Getting a list of all versions (or released / unreleased versions) might also work if they're sorted so that I can get the appropriate one from that list, but again I can't find a way to get that info.

I can't search and compare my issue with JQL either (I think) because I can't search for only the latest comments on every issue, and the version that I'm looking for isn't in a field on that issue.

1 answer

1 accepted

0 votes
Answer accepted
Jonas July 12, 2021

Oh ok. After randomly trying a few things, I found how to get the list of versions:


... and then I can get the first/last/whicheverIWant.

Well, not quite whichever, optimally I'd now be able to filter those issues to only contain `released` versions, which I'm not sure how to do. (Any pointers?)
And to make this even more complex, I'd actually need to check whether the version matches a given regex and only consider those... 

(--> /

Suggest an answer

Log in or Sign up to answer
AUG Leaders

Atlassian Community Events