Single sprint Sync

Originally asked by Nicolò Spito on 28 November 2022 (original question)


Hi team!

We have 2 Jira Cloud instances.

We would like to test a sync by synchronizing only a Single Sprint of a board. (Not all Sprints of the Sprint Board).

Have you got any insight to perform this action?

Thanks!


Answer by Syed Majid Hassan on 29 November 2022

Hi Nicolo,

I have just tested this using the following code snippet on the Outgoing side:

def boardIds = ["7"] //Boards which sprints will get synced
if(entityType == "sprint" && boardIds.find{it == sprint.originBoardId}){
    if (sprint.name!="MP Sprint 2") return
    replica.name = sprint.name
    replica.goal = sprint.goal
    replica.state = sprint.state
    replica.startDate = sprint.startDate
    replica.endDate = sprint.endDate
    replica.originBoardId = sprint.originBoardId
}

The key is the if statement which would return unless the name matches a specific sprint that you want to sync.

Hopefully this gives you a path forward.

Thanks

Majid


Answer by Nicolò Spito on 30 November 2022

Thank you Syed! Super!

I’m going to test it!!! :smile:


This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.