--- "Frank W. Zammetti" <[EMAIL PROTECTED]> wrote:
[SNIP]
> So, is there a way to get this task...
> 
> <propertyfile file="build.properties">
>   <entry key="build_number" default="0" type="int"
> operation="+" value="1"
> pattern="0000" />
> </propertyfile>
> 
> To NOT wipe out my comments?  Thanks again, I'm
> learning alot :)

According to its doc, this task makes no effort to
preserve comments.  If you are familiar with the
javadoc on the Properties class it doesn't take much
of a leap to conclude that these are the facilities
being used "under the hood", as it were.  So the
propertyfile task will inherit the limitations of the
Properties class.  You could implement this yourself
in Ant... I would think you might find yourself using
ant-contrib's math task as well as one of the several
text replacement approaches available in Ant (my
favorite is filterchains).  Or you could always
implement in Java or a compatible scripting language.

-Matt

> 
> -- 
> Frank W. Zammetti
> Founder and Chief Software Architect
> Omnytex Technologies
> http://www.omnytex.com
> 
> On Mon, February 28, 2005 1:07 pm, Matt Benson said:
> >
> > --- "Frank W. Zammetti" <[EMAIL PROTECTED]>
> wrote:
> >> Is it possible, and if so how, to do
> conditionals?
> >> I'd like to have a way
> >> basically on each task to say "if property
> A=value1,
> >> then run this task,
> >> otherwise don't".  I'm looking through the manual
> >> now but haven't come
> >> across what seems to fit the bill.
> >
> > As others have suggested, you can use
> ant-contrib's if
> > task.  However, the "Ant way" to do this is
> described
> > in the manual:
> > http://ant.apache.org/manual/using.html#buildfile
> >
> > HTH,
> > Matt
> >
> > __________________________________________________
> > Do You Yahoo!?
> > Tired of spam?  Yahoo! Mail has the best spam
> protection around
> > http://mail.yahoo.com
> >
> >
>
---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> > For additional commands, e-mail:
> [EMAIL PROTECTED]
> >
> >
> 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
> 
> 


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to