How to select a date from an issue description (generated from an email)?

Matt Miller February 5, 2025

This can be via regex or otherwise. We're trying to autopopulate the due date field on Jira issues that are generated from inbound email. I attempted to do this through automation by creating a rule that updates the issue field with the value of 

{{issue.description.match("(?<=Due Date: )\\d{2}/\\d{2}/\\d{4}")}}

 

I'm not sure if this is the correct syntax for Jira or not, but my attempt was to have it search the issue description and match the regex for "Due Date: mm/dd/yyyy". Thus far it hasn't worked. Has anyone done this and have a working solution?

1 answer

0 votes
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 5, 2025

Hi @Matt Miller 

Short answer: I recommend not trying any complicated regular expressions with automation rules as there is no documentation on what is (or is not) actually supported.  Perhaps try the simplest thing that could possibly work, adding edge cases only when needed, and testing fully.

For example you could try either text functions, chained matches, or a mix:

{{issue.description.substringAfter("Due Date: ").left(10).toDate("MM/dd/yyyy")}}

{{issue.description.match("(Due Date: \\d{2}/\\d{2}/\\d{4})").substringAfter("Due Date: ").toDate("MM/dd/yyyy")}}

...

 

Kind regards,
Bill

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events