Even if we are still in preview, Git support in TF Service already has some nice integration between git and all the rest of the world of TFS. As an example suppose you have a Work Item you are working to.

image

Figure 1: Simple Work Item in web interface

Now suppose you want to associate a local commit to this Work Item, all you need to do is inserting hashtag followed by the id of the Work Item in the comment of the commit, es #437. Since we are in the first preview of Git support actually there is no UI support, but using a simple comment is really quick and simple.

image

Figure 2: A commit that contains a reference to a Work Item

Now when you push changes to the TF Service, the commit will be associated to the corresponding Work Item, as you can see from Web Interface Code browser.

image

Figure 3: The Commits explorer window shows associated Work Item and all other details of the commit

As you can verify from Figure 3, you are able to visualize all the details of the commit with related Work Items included. You can click the link to the Work Item and you are bring to the Work Item editor where you can verify that the association is correctly done directly to the Work Item.

SNAGHTML19a523c

Figure 4: Commit is correctly associated with a Commit Link to the related Work Item

The association is not only in the commit explorer, but a real link is created between the Work Item artifact and the commit in code, as it happens in standard TFS VCS where the link points to a changesetid.

Gian Maria.

Tags: ,

4 Responses to “Associate Work Items to check-in in a TF Service Git enabled repository”

  1. Is there any way to change the state of the work item via the comment. For example, make the Product Backlog Item go from New to Done?

  2. In this first version still there is not the ability to move status of work item, you can actually achieve this with a little bit of API (you can find an hint on this post http://www.codewrecks.com/blog.....ment-tags/).

    You can expect that the level of integration between Git and TFS will improve over time, in the latest release the team added the support for building git source, and we can expect more news in the future.

    You can add this request to the appropriate user voice site if you like

    http://visualstudio.uservoice......ion-server

    Alk.

  3. Hello,

    Since a couple of days the work item / commit integration seems not to work anymore on my project.
    Is this a known / global issue or is this something that I should investigate on ?

    Simon

  4. I’m not aware of global issue regarding this, try to post on http://social.msdn.microsoft.c.....ce/threads and see if someone can tell you more about this particular issue you are experiencing. (maybe your account undergo some problem, the git support is still in the early phases).

    Gian Maria.