TeamCity Add-in 2024.1 Help

Personal Build, Remote Run, Pre-tested Commit

When working with a centralized version control system, where feature branches are not a part of the workflow, you normally have two options:

  • Build the solution and run tests locally before you commit your changes to the main branch. This way you can make sure that you will not introduce any problems to the repository, but you might spend significant time waiting until the build and tests are over.

  • Commit your untested changes to the main branch of your repository and then run build and tests on your build server. This way you can continue working after the commit, but at the risk of breaking the repository.

With TeamCity Add-in, you have a third option - you can quickly create a personal build, which will only be visible to you and include your selected non-committed changes.

Then you can initiate a remote run on the TeamCity server - TeamCity Add-in will take a snapshot of the selected changes, send them to your TeamCity server and start your personal build and tests. Note that by doing this, you do not commit anything to your VCS, and you can continue working while your changes are built and tested remotely.

You can use the pre-tested commit option to automatically commit your changes only if your personal build succeeds.

Run a personal build on your TeamCity server

  1. Choose ReSharper | TeamCity | Remote Run (Local Changes) in the main menu.

  2. In the Local Changes window, choose the changes that you want to include in the remote build. If you do not see some of your changes, click Re-collect Local Changes ThemedIcon.Refresh.Screen.(Gray).png on the toolbar

  3. Click Configure Personal Build ThemedIcon.RemoteRun.Screen.(Gray).png on the toolbar. This will open the Personal Build dialog.

    TeamCity Add-in: personal build details
  4. The dialog will display the build configurations whose sources were modified in the Visual Studio on your machine, as well as their snapshot-dependent build configurations. They are listed if the VCS settings of the TeamCity Add-in and the VCS root on the TeamCity server are the same, and the checkout paths are configured properly. Select the configurations that you want to run with your changes.

  5. Optionally, you can customize each build configuration. To do so, right-click the desired configuration and choose Customize build or click the corresponding button ThemedIcon.CustomizeBuildSet.Screen.(Gray).png on the toolbar.

  6. If your project's VCS is TFS or Perforce, you can configure additional VCS-specific settings on the corresponding tab.

  7. Type a comment for your changes or select one of the previous comments from the Recent comments list.

  8. If you want to automatically commit selected changes on a successful build, select Pre-tested Commit and then choose the condition of a successful build in the Commit if selector.

    Note that TeamCity Add-in will commit the selected changes as they are at the moment of starting the personal build. Therefore, you can go on working on your project and be sure that untested changes will not be committed.

  9. Click Run to start your personal build with specified parameters.

You can monitor execution of your personal builds in two ways:

  • On the web interface of your TeamCity server, your personal builds are designated with the corresponding icons. For example, in the illustration below, the failed build is a personal one.

    Personal build in TeamCity web UI
  • Select ReSharper | TeamCity | My Changes in the main menu and check states of your changes:

    TeamCity Add-in: My Changes window

    Similarly to the TeamCity web UI, changes corresponding to personal builds are designated with special icons. If necessary, you can click Hide non-personal ThemedIcon.FilterShowPersonalOnly.Screen.(Gray).png on the toolbar, so that only changes corresponding to personal builds are displayed in the list.

    You can see a brief summary of each remote run underneath the corresponding change set, and click it to see more details. Information in this view is provided by your TeamCity server.

    If necessary, you can view any of the changesets or build details in the web UI of your TeamCity server. To do so, select the desired item and click Open in Web ThemedIcon.OpenInBrowser.Screen.(Gray).png on the toolbar.

    For more information, refer to Analyzing Server Changesets, Builds, and Tests.

Last modified: 09 April 2024