You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Pritesh saharey <pr...@sqatester.com> on 2004/08/11 08:35:21 UTC

Checking for avaliablity of file

Hi All,
I want to check for a file whether it exsist or not in a particular path how can it be checked, suppose there is a file at
/home/pritu/verify/gu_hrd.distrib and in my build.xml file there is target <target name="move-along"> which is dependent on the avaliability
of this gu_hrd.distrib file, so i wanted to check that untill and unless this file exsist at its particular location target move-along should 
not get executed and build should stop with message that "gu_hrd.distrib file does not exsist at /home/pritu/verify"
can anyone help me out?

pritu




_____________________________________________________________
Join SQAtester.com Community  ---> http://www.sqatester.com/testersarea/joinus.htm

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Re: Checking for avaliablity of file

Posted by Angeshwar Deepak <an...@yahoo.com>.
Hi,

I am not sure myself, but what I would do is assign a
property name to the file and check in the <target....
if the property has been assigned a value. 

<property name="project.status"     
location="${project.home}/gu_hrd.distrib" />

if assigned it proceeds else direst it to the next
required target.

bye,
with regards,
Deepak.

--- Pritesh saharey <pr...@sqatester.com> wrote:

> Hi All,
> I want to check for a file whether it exsist or not
> in a particular path how can it be checked, suppose
> there is a file at
> /home/pritu/verify/gu_hrd.distrib and in my
> build.xml file there is target <target
> name="move-along"> which is dependent on the
> avaliability
> of this gu_hrd.distrib file, so i wanted to check
> that untill and unless this file exsist at its
> particular location target move-along should 
> not get executed and build should stop with message
> that "gu_hrd.distrib file does not exsist at
> /home/pritu/verify"
> can anyone help me out?
> 
> pritu
> 
> 
> 
> 
>
_____________________________________________________________
> Join SQAtester.com Community  --->
> http://www.sqatester.com/testersarea/joinus.htm
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> user-unsubscribe@ant.apache.org
> For additional commands, e-mail:
> user-help@ant.apache.org
> 
> 



		
__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - Send 10MB messages!
http://promotions.yahoo.com/new_mail 

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org