cmd - Do "if" type statements exist when inside Property Groups in MSBuild? -


i have have 2 separate property groups 2 differences between them, set have 1 or other trigger depending on condition. here's have:

<!--came teambuild-->   <propertygroup condition=" '$(configuration)|$(platform)' != 'debug|anycpu' , '$(configuration)|$(platform)' != 'release|anycpu' , '$(buildinginsidevisualstudio)' != 'true' ">     <prebuildevent>     </prebuildevent>     <postbuildevent>       set mage="c:\program files (x86)\microsoft sdks\windows\v7.0a\bin\netfx 4.0 tools\mage.exe"       set appfile=$(targetdir)$(targetname).application       set manifest=$(targetpath).manifest       set cert=$(projectdir)$(targetname).pfx       set projectname=$(targetname)       set configuration=$(configurationname)       set targetdir=$(targetdir)       set teambuild=$true       powershell -file "$(projectdir)postbuild.ps1"     </postbuildevent>   </propertygroup>    <!--came publish command-->   <propertygroup condition=" '$(configuration)|$(platform)' != 'debug|anycpu' , '$(configuration)|$(platform)' != 'release|anycpu' , '$(buildinginsidevisualstudio)' == 'true' ">     <prebuildevent>     </prebuildevent>     <postbuildevent>       set mage="c:\program files (x86)\microsoft sdks\windows\v7.0a\bin\netfx 4.0 tools\mage.exe"       set appfile=$(targetdir)$(targetname).application       set manifest=$(targetpath).manifest       set cert=$(projectdir)$(targetname).pfx       set projectname=$(targetname)       set configuration=$(configurationname)       set targetdir=$(targetdir)       set teambuild=$false       powershell -file "$(projectdir)postbuild.ps1"     </postbuildevent>   </propertygroup> 

is there way set teambuild value based on $(buildinginsidevisualstudio) value inside post build event?

if ($(buildinginsidevisualstudio) == 'true') set teambuild = $true

or set teambuild = $$(buildinginsidevisualstudio) ?

you're using it: condition. have extract step create property used teambuild value. example:

<propertygroup condition='$(buildinginsidevisualstudio)' != 'true' ">   <teambuildvalue>false</teambuildvalue> </propertygroup>  <propertygroup condition='$(buildinginsidevisualstudio)' == 'true' ">   <teambuildvalue>true</teambuildvalue> </propertygroup>  <propertygroup>   <prebuildevent>   </prebuildevent>   <postbuildevent>     ...     set teambuild=$(teambuildvalue)     ...   </postbuildevent> </propertygroup> 

Comments

Popular posts from this blog

basic authentication with http post params android -

vb.net - Virtual Keyboard commands -

css - Firefox for ubuntu renders wrong colors -