cruisecontrol.net - MSBuild find value in file -


So I run my work with ccnet and makes my work file what is the best way to read and recognize the file Is there any definite value from MSBield in it ??

This is dependent on your file.

Plain Text with Multiple Rows

If the file is like that:

  Building XXX ... build successful total time: 38 seconds buildfile : File  

You can use ReadLinesFromFile to read the file and CreateProperty to condition You can check the value with

& lt; Asset group & gt; & Lt; ValueToCheck & gt; Advanced SUCCESSFUL & lt; / ValueToCheck & gt; & Lt; / PropertyGroup & gt; & Lt; Target name = "check value" & gt; & Lt; ReadLinesFromFile file = "@ (MyTextFile)" & gt; & Lt; Output Task parameter = "Lines" item name = "value" /> & Lt; / ReadLinesFromFile & gt; & Lt; CreateProperty value = "true" condition = "'% (value.)' == '$ (ValueToCheck)' & gt; Output Task parameter =" value "property name =" human "/> & lt; / CreateProperty & gt; & gt; Target & gt;

XML file

If the file is in XML, you can XmlPeek (MSBuild 4) or XmlRead from.


Comments

Popular posts from this blog

windows - Heroku throws SQLITE3 Read only exception -

lex - Building a lexical Analyzer in Java -

python - rename keys in a dictionary -