How to detect any .NET 4.0 CLR on an agent in TeamCity 2017
In TW-44076 TeamCity was changed such that it reports the exact version of the .NET 4.x framework installed, rather than always reporting .NET 4.0 (since all the 4.x versions are in-place upgrades of 4.0). This is good and makes sense. However, it means we can't write agent requirements that allow for any .NET 4.x version to be installed, because really the only thing we care about is a 4.0 CLR. TW-46352 seems to suggest agent requirements can accept regular expressions but this doesn't seem to be the case.
How can I write an agent requirement on a build configuration that allows for any .NET 4.x version installed?
Please sign in to leave a comment.
Hi,
we actually set agent requirements as regular expressions, so they definitely should work. https://confluence.jetbrains.com/display/TCD18/Configuring+Agent+Requirements
Regular expressions have to be passed in the format defined by java, as explained in the link above.
To be clear, it seems that https://youtrack.jetbrains.com/issue/TW-46352 is suggesting that a parameter name can be specified via regular expression, which I cannot get to work.