Microsoft Developer Network > 포럼 홈 > MSBuild > Exec task and "error :" in output
질문하기질문하기
 

답변됨Exec task and "error :" in output

  • 2008년 6월 18일 수요일 오후 2:03Ant1 사용자 메달사용자 메달사용자 메달사용자 메달사용자 메달
     
    Hi,

    I just discovered a strange behavior of the exec task :

    <Exec Command="echo error : "/>

    will fail with code -1

    and

    <Exec Command="echo warning : " />

    will print a warning.


    Is it possible to disable this command output parsing ? I currently use ContinueOnError="True" but that modify my build logs.


    Regards,
    Ant1

답변

  • 2008년 6월 23일 월요일 오전 9:25Rong-Chun ZhangMSFT, 중재자사용자 메달사용자 메달사용자 메달사용자 메달사용자 메달
     답변됨
     

    Hi Ant1,

    By default, MsBuild will format the warnings and errors which Visual Studio can then display. We can ignore this beahvior in 3.5 by setting the IgnoreStandardErrorWarningFormat parameter to True. Please try something like the following:

    <Exec Command="echo error:" IgnoreStandardErrorWarningFormat="true"/>

    Hope this helps.
    Best regards.
    Rong-Chun Zhang

    Windows Forms General FAQs
    Windows Forms Data Controls and Databinding FAQs


    Please mark the replies as answers if they help and unmark if they don't.
    • 답변으로 제안됨Feng Chen중재자2008년 6월 23일 월요일 오전 9:29
    • 답변으로 표시됨Ant1 2008년 6월 23일 월요일 오후 12:11
    • 답변으로 표시됨Ant1 2008년 6월 23일 월요일 오후 12:11
    •  

모든 응답

  • 2008년 6월 23일 월요일 오전 9:25Rong-Chun ZhangMSFT, 중재자사용자 메달사용자 메달사용자 메달사용자 메달사용자 메달
     답변됨
     

    Hi Ant1,

    By default, MsBuild will format the warnings and errors which Visual Studio can then display. We can ignore this beahvior in 3.5 by setting the IgnoreStandardErrorWarningFormat parameter to True. Please try something like the following:

    <Exec Command="echo error:" IgnoreStandardErrorWarningFormat="true"/>

    Hope this helps.
    Best regards.
    Rong-Chun Zhang

    Windows Forms General FAQs
    Windows Forms Data Controls and Databinding FAQs


    Please mark the replies as answers if they help and unmark if they don't.
    • 답변으로 제안됨Feng Chen중재자2008년 6월 23일 월요일 오전 9:29
    • 답변으로 표시됨Ant1 2008년 6월 23일 월요일 오후 12:11
    • 답변으로 표시됨Ant1 2008년 6월 23일 월요일 오후 12:11
    •  
  • 2008년 6월 23일 월요일 오전 11:55Ant1 사용자 메달사용자 메달사용자 메달사용자 메달사용자 메달
     
    Oh, thanks a lot !

    I am missing something in the msdn ? I don't see anything about it here : http://msdn.microsoft.com/en-us/library/x8zx72cd.aspx


    Thanks again,

    Ant1