0
votes

I imported several git repos to Azure Devops. They were previously hosted on Azure Server 2019 (On premise version of Azure Devops):

git remote add origin [email protected]:v3/MyOrg/MyProj
git push -u origin --all

I noticed the commit history showing work items from an entirely different project than the one I imported to.

So I deleted the repos. I had used azure devops migrations tools to import the Iterations, Areas, and Work Items for this project from on-prem, so I thought it was an issue with this tool. But, I re-pushed the repo to azure devops, and the unrelated work items were once again updated with links to git commits, some of them entirely different.

Is this a bug with Azure DevOps?

Can I clean up the links without impacting the work item?

1
The commit messages likely contain references to work item IDs in the format #1234. You'd need to figure out what the remapped work item IDs are and rewrite the commit messages with the correct ID, or simply rewrite the commit messages to not contain an ID at all.Daniel Mann
Awesome thank you!! I will look into this solution.user210757
The thing is, the work items are showing that I updated them, at both import timesuser210757

1 Answers

0
votes

It seems like you should explore the "Import a repository" option.

enter image description here

The import feature disables automated linking for work items mentioned in a commit comment since the work item IDs in the destination project might not be the same as ones in the source project. Automatic linking for work items mentioned in a commit can be re-enabled by navigating to Settings, Version Control, selecting your repository, and choosing Options. For more information on linking commits with work items, see How do I associate my commits with work items?