- If you have any variable group defined and used in source build make sure to crate the variable groups with same name in the target team project.
- If any task groups are used export and import them to the new team project. There may be extensions that you may want to install for the target team project if it is a different Azure DevOps organization.
With above prerequisites fulfilled, you can use export in builds tab to export a definition as a json file.
- Agent pool – you have to select the relevant pools.
- Fix source location and authorize to get source code.
- Fix any service connections used in tasks.
The request specifies project ID <target project guid> but the supplied pipeline specifies project ID <source project guid>.
To fix this open the exported json file in a notepad and search for source project guid and replace it with target project guid. you do nt have to fix any other part of this file such as URLs referring the source team project and Azure DevOps organization.