Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Regular expressions (regex) for cloning part of description

Hi all


I'm trying to make a manual triggered automation, that when triggered evaluates the triggerissues description through a regular expression, and then copies it to a new issue(or a linked issue)

I'm however stuck at the regex part, and can't seem to make it work. I'm trying to log to audit log

The trigger issues description will always have a structure with a number of defined headlines eg. 

h2. Why - what is the potential business value hoped to achieve?
Lorem ipsum
h2. Assumptions / prerequisites
More lorem ipsum
h2. Breakdown
even more lorem ipsum
h2. Acceptance Criteria

# acceptance lorem ipsum 1
# acceptance lorem ipsum 2

So what I want is to get all sections headline and lorem ipsum text, except the breakdown section. And then add the rest of the sections to the linked issues description.

I've tried even very simple regex'es eg. just trying to find the "Why" in the first section and the rule succeeds but there's nothing in the log, so it's like I cant access the result/group and print/log it

This xyz: {{issue.description.match("Why").group(0).toString()}} :321 just succeeds and only logs xyz: :321

Any help or pointers would be greatly appreciated :)


0 answers

Suggest an answer

Log in or Sign up to answer
Community showcase
Asked in Jira Service Desk

Calling all Insight users, we need your help!

Hello Insight users,  As part of our (Mindville's) acquisition by Atlassian, our training team is looking to build some new Insight training materials. It would really helpful if you can ...

80 views 1 0
View question

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you