On 12/07/06, Petar Tahchiev <[EMAIL PROTECTED]> wrote:
On 12/07/06, Rémon van Gijn <[EMAIL PROTECTED]> wrote: > > In ant you can use the "env" properties, in combination with the ant-contrib extension that would allow you to create if statements. > > Met vriendelijke groet, > Rémon van Gijn > > > > -----Original Message----- > From: Nagender Malik [mailto:[EMAIL PROTECTED] > Sent: woensdag 12 juli 2006 12:05 > To: Ant Group > Subject: how to conditionally execute a task > > Hi All, > > i want to execute a task conditionally based on operating system property. how can we do that. > > please suggest.... > > thanks, > Nagender Malik > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > I would suggest place your task in a target and then use the if attribute of the target element like this:<target name="blah" if="${Property}"> <your task/> </target> this will execute your task only if Property is set. Something more: To check for your system property has some specific value you can use condition and then based on this condition you can initialise Property. Hope this helps! -- Regards, Petar! Karlovo, Bulgaria.
Sorry for the late response... :-) -- Regards, Petar! Karlovo, Bulgaria. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
