Allow TeamCity to stop an in-progress build if it detects a new commit


Hi there,

It's clear that there is no functionality that allows this, but I'd like to be able to stop a build from running if a new source control commit is detected.

For some background, our build server has an SVN trigger which detects new code commits. It then performs a .NET build and publish of the solution and then commits those updated DLLs to source control.

However, if, during that build I commit something else, the build will invariably fail because new changes have been made.

Ideally, I'd like the ability for the trigger to continue checking and stop the build if it's triggered. I would then wish to have the option of re-adding the build to the queue, thus updating the source, rebuilding/publishing and committing again.

Any guidance with this would be wonderful.

Many thanks, Dan

Comment actions Permalink

Hello Dan,

We have the related request in our tracker: Please describe your use case in comments and vote for the request.

Please take a look at Quiet Period setting in VCS trigger. The quiet period is a period between the last VCS change is detected and a build is added into the queue. Probably you can increase it to avoid broken builds.

Comment actions Permalink

Hi Alina,

Thanks for your reply. I've seen the quiet period feature but I definitely want it to build ASAP, but stop if a commit is detected during the current build which would otherwise trigger a build.

Thanks, Dan




Please sign in to leave a comment.