Sync work across epics and stories
Nothing exists in isolation in Jira. This is by design. Various teams use and rely on Jira to manage their work and automation is the perfect solution to avoid constant updates & repetitive work. You can sync across epics and stories, parents and sub-tasks or even across projects and products.
In this use case, we will focus on syncing the epic with its stories, ensuring they are always linked. More specifically whenever an Epic is marked as ‘done’ then move all its stories to ‘done’ also. This avoids stories hanging around with the wrong status.
The automation recipe
Step 1: Choose your trigger
Every rule starts with a trigger. In this case, we choose the ‘Issue transitioned’ trigger and specify the status as ‘done.’ This simply means that whenever an issue changes status to ‘done’, automation will be listening out for it.
Step 2: Add your condition
A condition refines the rule so it won’t act too broadly. We use the ‘Issue fields' condition here and, using the dropdown menu, clarify that the Issue type we are looking out for is the Epic.
Step 3: Add a Branch rule / related issues
This is where the real magic comes in. We can branch off from the main trunk of the rule and perform actions on related issues that we specify. For example we could work on the subtask of a parent or any linked issues. For this rule, we choose 'Stories (or other issues in Epic) from the dropdown menu.
Step 4: Add a condition
We add another clarifying condition here to rule out any stories that are already in ‘done’ status. We only want to act on issues in the wrong status. So we choose status does not equal ‘done’.
Step 5: Add an action
As ever, our rule finishes with an action. In this case, we choose the ‘Transition issue’ action. We could simply choose the ‘done’ status. However, we can go one better and say ‘copy from the trigger issue’. This means stories will always match the status of the Epic if they meet the conditions we set. They will always stay in sync.
Step 6: Test it!
You can play around with this rule in the Playground below or you can test it out in a sample project in your own instance.
Resources to help
How to test/debug your automation rule
One page with all helpful Jira automation resources
More about syncing work in Jira with automation
Visit our Jira automation YouTube channel
Other rules that you may find useful
When an issue is raised without an assignee, auto-assign to whoever created it
Daily Slack summary
Send a daily Slack message with a list of issues still open in the Sprint
Sum up story points
When a new sub-task is created, sum up its story points to the parent
Connect Jira & Bitbucket, GitHub or GitLab
When a PR is merged in Bitbucket/GitHub/GitLab, then transition the issue in Jira
Auto-close old support issues
If a customer has not responded to an issue in 5 days, close the issue and leave a comment