Export (0) Print
Expand All

Check in Pending Changes (Team Explorer Everywhere)

Visual Studio 2010

After you have made changes to one or more source files and are ready to share those changes with your team, you check those changes into Team Foundation version control. When you check in, warnings appear if you have not satisfied the requirements of the check-in policies. You can provide check-in notes and associate work items with your check-in as part of the check-in process.

In this topic

Required Permissions

To perform these procedures, you must have the Check in permission set to Allow. For more information, see the following topic on the Microsoft Web site: Team Foundation Server Permissions.

To check in pending changes, you open the Pending Changes view or the Check In dialog box and use one of those interface elements to specify the files and folders that you want to check in. You can open the Check In dialog box from several locations.

To specify items to check in

  • In the Pending Changes view, select the check boxes that correspond to the items that you want to check in. For information about how to open the Pending Changes window, see View and Manage All Pending Changes in Your Workspace (Team Explorer Everywhere).

  • In Project Explorer or Package Explorer, right-click the item that you want to check in, point to Team, and click Check in Pending Changes.

    In the Check In dialog box, select the check boxes that correspond to the items that you want to check in.

  • In Source Control Explorer, right-click the folder or file that you want to check in, and click Check In Pending Changes. For more information, see Open Source Control Explorer.

    You can also highlight multiple items in the details pane, right-click any one of them, and then click Check in Pending Changes.

    In the Check In dialog box, select the check boxes that correspond to the items that you want to check in.

Next, you use either the Pending Changes view or the Check In dialog box to check in your changes. You use the channel buttons along the left of the window or dialog box to move between the channels that you use to provide information about the check-in.

To check in pending changes

  1. In the Source Files channel, clear the check boxes for any files or other items that you do not want to check in, and optionally type any applicable comments in the Comment box.

  2. (Optional) If you are checking in files or other items that are associated with a work item, click the Work Items channel, and select the check boxes for the work items with which the items are associated.

    For more information, see Associate Work Items with Changesets (Team Explorer Everywhere) and View Work Item Details from Pending Changes Window (Team Explorer Everywhere).

    Some organizations create check-in policies that require you to associate each check-in operation with at least one work item. If your organization has such a policy, you will be prompted if you have not selected the check box for a work item. For more information, see Associate Work Items with Changesets (Team Explorer Everywhere) and Setting and Enforcing Quality Gates (Team Explorer Everywhere).

  3. (Optional) Click the Check-in Notes channel, and add notes.

    Some organizations require that you provide notes from one or more roles. For example, your organization might require notes from a code reviewer, a security reviewer, and a performance reviewer. If your organization has such a policy, you will be prompted if you have not specified any required check-in notes. For more information, see Setting and Enforcing Quality Gates (Team Explorer Everywhere).

  4. (Optional) Click the Policy Warnings channel to ensure that your changes do not violate any check-in policies before you check them in.

    If you try to check in items that violate a policy, you will be notified, and the changes will not be checked in. If necessary, you can override check-in policies. For more information, see Override a Check-In Policy (Team Explorer Everywhere).

  5. Click Check In.

    One of the following results occurs:

    • If you have conflicts that you must resolve before you can check in, the Conflicts dialog box appears. For more information, see Resolve Conflicts between Two Files (Team Explorer Everywhere).

    • If the items are in a working folder that is protected by a gated check-in build, an additional message box appears with the following message:

      You need to build your changes for validation before they can be committed to the Team Foundation Server. Your changes have been shelved and will be built as follows: 
      Shelveset: ShelvesetName 
      Build definition: BuildDefinition
      

      If the build completes successfully, your changes are checked into version control. For information about how you can monitor the build results, see Using Build Explorer to View and Manage Queued, Ongoing, and Completed Builds. You can also reconcile your local workspace with the changes that are checked into version control. For more information, see Check In Pending Changes that Are Controlled by a Gated Check-in Build (Team Explorer Everywhere) and Reconcile Command.

      Caution noteCaution

      The build server merges the shelved changes with the most recent version of code from version control before queuing the gated check-in build. Therefore, the actual code that is committed by the gated check-in may differ from the code that is submitted as part of the shelveset.

    • If the items are in a working folder that is not protected by a gated check-in, the items are checked in.

When you check in from a command prompt, you can check in all files from the current folder. You can also specify a file or folder to check in. The checkin command does not display the pending changes for review before you check in. If you are unsure about which files are checked out, you should consider using tf status to verify the pending changes before you check in. For more information, see the following topic on the Microsoft Web site: Status Command (Team Foundation Version Control).

To check in pending changes from a command prompt

  1. Open a command prompt.

  2. Browse to the folder that contains the files that you want to check in.

  3. Perform one of the following tasks:

    • To check in all checked-out files in the current folder, type tf checkin –recursive., and then press ENTER.

    • To check in a specific file or folder, type tf checkin ItemSpec and press ENTER, where ItemSpec is the file or folder that you want to check in.

    • To specify a check-in comment, add -comment:CommentText to the command, where CommentText is the comment that you want to provide.

    • To resolve one or more work items with the check-in, add -resolve:WorkItemIds to the command, where WorkItemIds is a list of work item IDs, separated by commas.

    • To associate one or more work items with the check-in, add -associate:WorkItemIds to the command, where WorkItemIds is a list of work item IDs, separated by commas.

    • To associate check-in notes with your check-in, add -notes:”NoteType”=”NoteValue, where NoteType is the type of note and NoteValue is the text for the note. For example, you could specify -notes:”Code Reviewer”=”No code quality issues were identified.”.

    For more information about the tf checkin command, see the following topic on the Microsoft Web site: Checkin Command (Team Foundation Version Control)

Community Additions

ADD
Show:
© 2014 Microsoft