I have an automation rule that triggers when a comment is added to an issue. The new comment is searched using a regex, looking for something like "[tw] 5m" at the beginning of a line. So far so good:
I then want to do something in a rule action with the "5m" captured in my regex. Within the regex, I would simply use "\1" to refer to the contents of the capture group, but I have no idea if I can recall the contents of the capture group in a subsequent action, and, if I can, how I would recall the contents so that I can use them. It seems like some smart value or other is what I need, but I can't find any smart values that reference the results of a regex match.
Or should I forget about capturing in the conditional step, and instead use something like `{{comment.body.match("^\[tw\]\s*(\d+[wdhm])")}}` for setting the value of a field in an action step? Also, when using the .match method, where do the regex options (e.g. "gim" in the screenshot regex above) go?
Thank you.
Hi @[deleted]
Have you tried creating a variable?
Ravi
Being relatively new to Jira -- but coming from an engineering and development background -- a variable sounds like exactly what I need, but I don't know where to begin with creating one. Can you please refer me to relevant documentation?
Thank you,
-Brian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.