4
votes

This describes a scenario that I find myself in now and then when I realize I should have worked in a development branch in TFS. Then I would like to shelve my changes and unshelv into a dev branch, alternatively create a branch from "Main" with saved, uncommitted changes. What is described on this linked page and many other pages is possible with earlier versions of VS and TFS using the TF power tools command utility: http://geekswithblogs.net/TarunArora/archive/2011/06/06/unshelve-shelveset-created-from-one-branch-to-another.aspx

Now those features are no longer available, because "most of the previous Power Tools have been integrated into TFS 2017" (according to https://docs.microsoft.com/en-us/visualstudio/releasenotes/tfs2017-relnotes ). But there is no command line utility AFAIK available to enable such operations. How can I achieve unshelving to another branch with Visual Studio 2017 and TFS 2017? Alternatively, how can I create a branch from "Main" with saved, uncommitted changes?

1

1 Answers

0
votes

With older versions of Visual Studio (2015 and older), the Power Tools extension (https://marketplace.visualstudio.com/items?itemName=TFSPowerToolsTeam.MicrosoftVisualStudioTeamFoundationServer2015Power) used to unshelve to a different branch. But unfortunately this tool does not exist for VS2017.

I have tried another extension MutliMerge - https://marketplace.visualstudio.com/items?itemName=Jesusfan.MultiMerge2017&ssr=false#overview

I was able to unshelve from a branch to a different branch. I have ensured that there were no pending changes and both branches were up to date.

Note: the tool did not automatically show me the target branch but I was able to edit it and get to work.