We have a Team City Unit test build which we call using $(teamcity_dotnet_nunitlauncher) through different MSBuild scripts. The build has an environment variable set up. Is there a way we can override the variable through the scripts?
We have a Team City Unit test build which we call using $(teamcity_dotnet_nunitlauncher) through
Share
Environment variables are “published” as MSBuild properties, so for example:
…will give the value of that env var. You can override any property inside an MSBuild script…
…or pass it in on the command line to MSBuild…
These two ways to alter the “property” presented by an environment variable are not equal though, when passing a property via the command line, the value will not be overridden if it is declared in an MSBuild file.