How to: Merge Files and Folders
Team Foundation version control provides merging functionality through Source Control Explorer, or from the command line using the Merge Command. For more information, see Understanding Merging. The following procedure demonstrates merging with Source Control Explorer.
To perform these procedures, you must have the Read permission for the item in the source tree and Check out permission for the item in the target tree set to Allow. If the item in the target tree is being renamed, you must have the Check out permission for both the source tree and the target tree set to Allow. If a lock is involved, you must have the Lock permission set to Allow. For more information, see Team Foundation Server Permissions.
To merge files and folders
In Source Control Explorer, right-click the team project, folder, or file version that you wish to merge with another team project, folder, or file version, and click Merge.
In the Source Control Merge Wizard, in the Source branch box, either type the name of the team project source branch, or click Browse to locate it.
In the Target branch drop-down list, select the desired target team project branch to which you want to merge the source branch.
Select the type of changes you want to merge into the target branch by choosing either the All changes up to a specific version or Selected changesets option, and click Next.
If you chose All changes up to a specific version, in the Select the versions of the source items page, select the version of the items that you want to use.
If you chose Selected changesets,on the Select changesets to merge into the target branch page, select the changeset that you want to merge.
If possible, click All changes up to a specific version, as doing so will reduce the likelihood of conflicts in future merge invocations.
Click Next, and then, on the Perform the merge operation page, click Finish.
Should merge conflicts arise, you must resolve them. For more information, see How to: Resolve Conflicts Between Two Files.