I have two TFS branches that do not have a direct parent/child relationship in TFS. In a certain revision, 94 in my example, several items were deleted. I have been tasked with applying those deletes to the main branch. I’d like to do so through a baseless merge. I tried the following command to do so:
tf merge /baseless /recursive /version:94 .\programs\program1 ..\Release\programs\program1
Most of the items in the tree were marked as “merge”, and some were marked as “merge edit”. However, none of the items were deleted at the destination. On a whim i tried to merge over a single delete like so:
tf merge /baseless /recursive /version:94 .\programs\program1\source1.cs ..\Release\programs\program1\source1.cs
I got the following error message:
The item [TFS_PATH] does not exist at the specified version.
How do I do this? Is there a way to avoid making all those deletes myself?
I experimented a bit and here is my version of the above. seems to work for me:
to make it even more useful, one can parametrize the changeset number and branch paths to allow for more convenient processing.
for example, to process all deletes in a given branch run this from the source location: