Using configuration parameters in branch triggers
Hi!
We have a VCS trigger with the following branch filters:
+:%version%
+:Release_%version%
+:feature/%version%/*
+:bugfix/%version%/*
version is configuration parametr = %system.teamcity.projectName%
%system.teamcity.projectName% is version number, for example - 2.0.4
VCS settings:
Default branch: refs/heads/%version%
Branch specification:
+:refs/heads/(%version%)
+:refs/heads/(feature/%version%/*)
+:refs/heads/(bugfix/%version%/*)
+:refs/tags/(Release_%version%)
We have a problem with Git branches with name like version, this trigger doesn't work.
And build cinfiguration is in pending state.
But another triggers like +:feature/%version%/* works good.
But if thre is only one branch filter (+:%version%) in VCS trigger then build is triggered and everything is OK.
Is it known problem or we create incorrect branch filters?
| system.teamcity.version | 2017.1.3 (build 46961) |
Thx,
Aleksey
Please sign in to leave a comment.
Hi Aleksey,
I'm going to try to dig deeper into the issue, but a question first. If I'm not mistaken, you are using on the VCS Trigger the exact same branches you use in the VCS Root. If so, you don't need to specify them on the Trigger as well.
Also, do you have any checkout rules?
Hi Denis,
There are no any checkout rules.
Thanks for advise, I'll remove the branches from the trigger.
What's the format on versions? Always something like "Major.Minor.Bugfix"? I'm trying to replicate the issue. Could you also confirm whether removing the trigger filter works for the "version" branch?
Format is %d.%d.%d. For example, 2.0.5
Yes, of course, I'll notify you when I remove the trigger filters and check it.
Denis,
I've cleared the branch filters in VCS Trigger. I can confirm that thу issue is gone.