I'm using Visual Studio 2015 and have deleted a branch from our TFS source control. Looking at other guides there's mention of being able to recover the branch by opening Source Control Explorer, right-click and select 'Undelete' or 'Rollback'. These options are not available
I have not got this branch mapped on any workspace. Clicking on 'Undo Pending Changes…' brings up a message saying there are no pending changes. How can I restore a branch on TFS? Is there a way I can enable Undelete or Rollback?
Best Answer
First, please make sure you or your teammates haven't destroyed this branch (After doing this, there is no way to recover it in TFS server).
If you delete this branch in Visual Studio,
If you delete this branch from your dev machine outside of Visual Studio,
Please check the solution from MSDN link Delete or restore files and folders
Morever, you can also try to use the undelete command restores items that were previously deleted. For Example:
Update:
Note: To be able to undelete a branch you must first map the parent folder/branch to your workspace. Now, the undelete option will be enable.