ant-user mailing list archives

Why not
<taskdef file=""/> ???
or with Ant 1.6 and namespaces
<project xmlns:my="antlib:com.mycompany.tools.ant">
<my:custom1/>
So you haven´t to worry about to ensure that a modified Ant version is on
the machine.
I personally would reject modifying a tools only for lazyness :-)
But if you want that, then:
- extract the default.properties from the ant.jar (<unjar>)
- add your lines to that (<concat>, <echo append>)
- update the jar (<jar><zipfileset prefix>)
Maybe you will have problems with updating the jar using Ant because
Ant uses that jar for itself :-)
Jan
> -----Original Message-----
> From: Sreejith.M.Janardhanan [mailto:mjsreejith@vanenburg.com]
> Sent: Wednesday, December 17, 2003 8:13 AM
> To: user@ant.apache.org
> Subject: Updating default.properties in ant.jar for taskdefs
>
>
> Hi,
>
> I want to append the following lines to end of file
> "defaults.properties" located in package
> "org/apache/tools/ant/taskdefs"
> in "ant.jar" for avoiding writing taskdefs in all build files.
>
> # my custom tasks
> contentexport=com.mycompany.tools.ant.CustomTask1
> contentimport=com.mycompany.tools.ant.CustomTask2
>
> I don't want to build the ant project with new "default.properties". I
> am having ant.jar ready and just have to update
> default.properties in it
> using a ant build file (probably from another properties file). Can
> anyone tell me how I can achieve this?
>
> Thanks in advance,
>
> Regards,
> ____________________________
> Sreejith M Janardhanan
>
>
>
>
> **********************************************************************
> The information in this message is confidential and may be legally
> privileged. It is intended solely for the addressee. Access
> to this message
> by anyone else is unauthorized. If you are not the intended
> recipient, any
> disclosure, copying, or distribution of the message, or any action or
> omission taken by you in reliance on it, is prohibited and
> may be unlawful.
> Please immediately contact the sender if you have received
> this message in
> error.
>
> **********************************************************************
>
>