Using Version Control – Part 3

In this post I will go deeper with the version control stuff and the new improvements in TFS 2012,  one of the most improvements in TFS 202 version control is Managing Pending Changes, Most changes that you make to your files are queued as pending changes. As you work, you can organize, manage, and get details about what you’ve changed.

 , Solution Explorer is probably the hub of the development work you do.

Solution Explorer with Test and Class projects
When you open and modify a file from Solution Explorer, the file is automatically checked out for you. Icons appear to indicate which files you have not changed TFSC Checked-In Status Icon, those you have checked out TFSC Checked-Out Status Icon, and those you have added to the solution TFSC Pending Addition Status Icon.If you’re using Visual Studio Premium or Visual Studio Ultimate, you can use the My Work page in Team Explorer to manage your work. In Team Explorer, choose Home icon Home, and then choose My Work.
To Do List on My Work Page in Team Navigator
You can use My Work to:

  • Track your work against tasks
  • Suspend and later resume your work (including file changes, associated tasks, and Visual Studio state such as window positions and breakpoints)
  • Request a code review

You can use the Pending Changes page in Team Explorer to manage your work. In Team Explorer, choose Home icon Home, and then choose Pending Changes. The Pending Changes page is also displayed whenever you begin the check-in process.

Checking in the pending changes

Almost every change that you make to the files on your dev machine is stored in your workspace as a pending change until you check it in.

If you are working in a local workspace, Visual Studio can detect changes that you make outside the system. If you edit a file outside Visual Studio (for example, in Notepad) the change automatically appears in your Included Changes.

If you add or remove a file outside Visual Studio, for example, in Windows Explorer (File Explorer in Windows 8), the Detected changes link appears in the Excluded Changes section. Choose this link if you want to include these changes. The Promote Candidate Changes dialog box appears. You can open the shortcut menu of added items and choose Browse in Windows Explorer to display them or Delete from disk to delete them.

Sometimes you need to remind yourself about what you’ve changed in a file.
To see what you changed from Pending Changes
  • On the Pending Changes page, open the shortcut menu for the item and choose:
    • Compare with Workspace Version to see what you’ve changed to the version in your workspace
    • Compare with Latest Version to see how your changes compare to the latest version of the file in your team’s codebase
To undo a few of your pending changes
  1. In Solution Explorer, the Pending Changes Window, or Source Control Explorer, select one or more items, open their shortcut menu and choose Undo or Undo Pending Changes.
  2. In the Undo Pending Changes dialog box, make sure the changes you want to undo are selected, and then choose Undo Changes.

To undo all your pending changes

  • On the Pending Changes page, choose the Actions link, and then choose Undo All.

I wish this post makes value for you and your teams 🙂


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s