--- "Scot P. Floess" <[EMAIL PROTECTED]> wrote:
> I was wondering if anyone can please help me? I am
> having trouble
> converting a path to a property when a fileset's dir
> does not exist.
[SNIP]
You will have to check for the directory's existence
before adding the offending fileset to the path. I
assume your expectation of pathconvert results for a
fileset with no matching files (including when the
directory does not exist) is "".
Example:
<project default="foo">
<path id="base">
<fileset dir="a" />
<fileset dir="b" />
<fileset dir="c" />
</path>
<path id="p" refid="base" />
<target name="check">
<available file="z" type="dir" property="found" />
</target>
<target name="modify" if="found">
<path id="p">
<path refid="base" />
<fileset dir="z" />
</path>
</target>
<target name="foo" depends="check,modify">
<pathconvert property="result" refid="p"
pathsep="${line.separator}" />
<echo>$${result}=${result}</echo>
</target>
</project>
HTH,
Matt
__________________________________
Yahoo! Mail - PC Magazine Editors' Choice 2005
http://mail.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]