문제

In MsBuild, is it possible to create an MSBuild condition (or another situation) that will evaluate whether a Property is 'defined' (presuming that this is previous to assigning the property a value somewhere)?

The following seems a little too clumsy to be reliable:

<PropertyGroup Label="Undefined State">
     <Defined></Defined>
</PropertyGroup>

<Choose>
   <When Condition="('$(Defined)' == '' OR '$(Defined)' != '')">
        <Message Text="Defined is probably/likely/assuredly defined"/>
    </When>
    <Otherwise>
       <Message Text="Defined is reportedly/maybe/possibly not defined"/>
    </Otherwise>
<Choose>

올바른 솔루션이 없습니다

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top