I am trying to get ANT-Buildscript to count the lines stored in ANT -property. From the examples I got a way to count the lines in a file, for example:
<resourcecount count="0" when="eq">
<tokens>
<concat>
<filterchain>
<tokenfilter>
<linetokenizer/>
</tokenfilter>
</filterchain>
<fileset file="${file}" />
</concat>
</tokens>
</resourcecount>
Now I want to reference ANT -property instead of a file. Is there any way to do this? I know about the decision to write the contents of a property to a file using <echo file="${temp.file}">${the.property.with.many.lines}</echo>and using the code above. But I am wondering if there is a solution that works without a temporary file.
source
share