TeamCity says to use “Build Parameters” instead of “/property:” in an MSBuild step. What does that mean?

前端 未结 2 1561
礼貌的吻别
礼貌的吻别 2020-12-07 14:13

I have a TeamCity server setup to do my CI builds. I\'m building and testing a C# solution and running some custom MSBuild tasks. One of these tasks is printing a warning in

2条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-07 14:50

    It all happens behind the scenes! You just have to follow the right conventions. In your MSBuild script, you use the regular variable notation

    $(DbPath)
    

    And in TeamCity, you define a system or env variable

    system.DbPath
    

    TeamCity will automagically send all of its system/env variables to your MSBuild task, removing the 'system' or 'env' part. And you don't have to write /property:DbPath=system.DbPath in your TeamCity task.

提交回复
热议问题