Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to bulk change just a part of the Fix version string?

Vigfus Andersson
Contributor
January 26, 2024

Hi,

My team is working in an organisation that have different web services per customer type (ie employers and employees). Previously we have been organized according to which customer type the team was developing services for which meant both teams could use the organization's standard 3 letter abbrevation for a service since we handled them in different projects. So we have been using the following setup for Fix version

[standard abbreviation] [major release].[minor release].[hotfix] => NYJ 2.3.0 is the third release of the 2nd major release for web service NYJ.

Now we have re-organized and my team will handle both customer types for NYJ (the web services are totally separate and have nothing in common except that they are part of the same (really long) process). 

Is there a way to bulk change the old fix version with a search and replace function similar to the one you have in Excel? Search for "NYJ" and replace that with "NYJ - A". That way I don't overwrite the suffix part, "2.3.0", in our old Fix versions and thus the old Fix version will be change into "NYJ - A 1.0.0", "NYJ - A 2.3.0" and so on since we don't write over the numbers. When we release our first piece of code for the other customer type we can start from scratch and it will be similar to "NYJ - B 1.0.0" (unless we import the old stories from the other project) and do a similar search and replace for those stories (if that is possible).

Best Regards,
Vigfus

1 answer

0 votes
Rudy Holtkamp
Community Champion
January 26, 2024

Hi @Vigfus Andersson ,

I think the best way to do this, is to write a script which makes use of:

Update version , see: https://docs.atlassian.com/software/jira/docs/api/REST/1000.824.0/#api/2/version-updateVersion 

With the Python lib, you can make use of 

# Get a full representation of a the specified project's versions
jira.get_project_versions(key, expand=None)

to get versions and see if they match the regex of your release and with

# Update an existing version
jira.update_version(version, name=None, description=None, is_archived=None, is_released=None, start_date=None, release_date=None)

 you can update it.

 

Good luck

Suggest an answer

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

Atlassian Community Events