Ray Booysen
Ray Booysen

Reputation: 30021

Teamcity - Monitoring a specific folder as a VCS trigger

We are moving to a monolithic repository for a project which means that when a commit occurs, on team city we need to determine which build to kick off.

Consider the following repo:

/
  a/
  b/

We currently have builds per sub-project that need to trigger when commits

In VCS triggers, we can create a VCS trigger rule, which "seems" to work however I have the following questions:

  1. if I commit a change to folder b, through a trigger rule I can make only the builds for b kick off. However, the builds for a show pending changes that are unrelated.
  2. Is this approach sensible long term? Are there any unintended gotchas that occur?

Upvotes: 0

Views: 2715

Answers (2)

Pavel Sher
Pavel Sher

Reputation: 2211

If you don't want to see unrelated pending changes, consider using checkout rules. If you set checkout rules to +:a TeamCity will show changes under "a" directory only. But be aware that with such checkout rules only directory "a" will appear in agent checkout directory.

Upvotes: 4

Vampire
Vampire

Reputation: 38639

I don't think so. If you use trigger rules in the VCS trigger, this just means whether a build is kicked off automatically if there is anything checked in. So yes, the pending changes will of course be shown and if you have a dependency from one build configuration to another, a new build will be triggered even if there are only "unrelated" changes. But I don't think you will have any drawbacks.

Upvotes: 2

Related Questions