Set the next fix version

Use case

Change the fix version of the current issue for the following one by increasing it in one unit.


⚒️ Configuration

Add the Update or copy field values post function to the transition of your choice.

Target issue*

Choose Current issue

Field*

Choose Fix Version/s

Value

In the popup, select the value Set field value manually (parser expression)

Expression*

Set the expression editor to Advanced text and use the following expression

floor(toNumber(%{issue.fixVersions})) + "." + (toNumber(substring(%{issue.fixVersions}, length(toString(floor(toNumber(%{issue.fixVersions}))))+1, length(%{issue.fixVersions}))) + 1) 

This expression will update the version 1.0 to the version 1.1, the version 1.1 to the version 1.2 and so forth indefinitely.

Variant

Bash
(floor(toNumber(%{issue.fixVersions})) + 1) + ".0"

This expression will update the version 1.0 to the version 2.0, the version 1.2 to the version 2.0, the version 2.0 to the version 3.0 and so forth indefinitely.


📚 Related use cases