What is the purpose of a shelveset?

后端 未结 3 1480
天涯浪人
天涯浪人 2021-02-05 09:27

I\'ve been using TFS for a while now but as a lone developer I haven\'t really used its features to its full extent. I\'ve now been tasked with working with a couple of colleagu

3条回答
  •  悲哀的现实
    2021-02-05 09:34

    In my experience shelvesets are typically used for 3 purposes:

    1. Switching Tasks before I'm ready to Check-In
    2. Getting help from colleagues on code that isn't working
    3. Code Reviews

    When you create a shelveset you have a checkbox to choose whether you want to undo your pending changes at the same time or not.

    For #1, I would want to check the box to undo my changes, as the entire purpose of shelving is to get a clean local workspace to start on the new task.

    For #2, I would probably not undo my changes, as after the colleague has looked at my code and helped me I will want to continue working on those changes.

    For #3 this is only applicable if the code review workflow is pre-checkin, in that case you would typically undo your pending changes so you can start working on the next item while waiting for the review and not comingling the changes.

提交回复
热议问题