How to create branch on TFS with attaching pending changes to new branch

branch, tfs, version-control, visual-studio

Solution

You can shelve your changes, then use the TFS Power Tools to unshelve them into a different branch.

This is a specific feature of the Power Tools (tfpt unshelve /migrate). It will rewrite server paths to migrate the changes into another branch. See this blog post for more info: http://geekswithblogs.net/TarunArora/archive/2011/06/06/unshelve-shelveset-created-from-one-branch-to-another.aspx

Problem

I was working on main branch and I have done a lot of changes to files. I did not check in those changes. How to create child branch from main, but all local pending changes which are attached to main branch, changes to be attached to newly created child branch. So basically: How to create child branch with attaching all pending changes of parent branch to child branch?

Original source