<!-- BEG COMMENT ===========================
add this debug Ant target to your depends= to expose the properties in play
END COMMENT ======================= -->
<target name="display.properties.tgt" description="display project
properties.">
<echoproperties destfile="${ant.file}.runtime.properties"
failonerror="false" />
<echo message="----- ${project.name.text} ${project.version} -----"/>
<echo message="java.class.path = ${java.class.path}"/>
<echo message="java.home = ${java.home}"/>
<echo message="user.home = ${user.home}"/>
<echo message="ant.home = ${ant.home}"/>
<echo message="base.dir = ${basedir}"/>
</target>
-----Original Message-----
From: Niranjan Deshpande [mailto:[EMAIL PROTECTED]
Sent: Friday, June 06, 2008 5:54 AM
To: [EMAIL PROTECTED]; Maven Users List
Subject: need help in ant's javadoc task (from maven)
I am trying to generate a .properties file using javadocs in a java source
file, and i am using ant's <javadoc> task to do this.
but i am getting this error when i run the antrun plugin
generate.appcodes:
[javadoc] Generating Javadoc
[javadoc] Javadoc execution
[javadoc] javadoc: Cannot find doclet class
com.company.app.util.doclet.AppCodesDoclet
[javadoc] 1 error
Please help. Also can anyone tell me what the <path> and <pathelement> elements
are for? How are the paths relative to?
My ant build file is:
<project name="generate.appcodes" basedir=".." default="all">
<path id="tools.classpath">
<pathelement path="build/lib/tools.jar" />
<pathelement path="lib/xerces.jar" />
<pathelement path="WebContent/WEB-INF/lib/log4j-1.2.9.jar" /> </path>
<target name="all" depends="generate.appcodes"/>
<target name="generate.appcodes">
<delete file="src/main/resources/appcodes.properties" />
<javadoc sourcefiles="src/main/com/company/app/shared/security/AppCodes.java"
failonerror="yes">
<doclet name="com.company.app.util.doclet.AppCodesDoclet"
path="${tools.classpath}">
<param name="-outputfile" value="../src/main/resources/appcodes.properties"
/>
<param name="-sourcepath" value="src/main/resources" />
<param name="-command" value="properties" />
</doclet>
</javadoc>
<mkdir dir="target/WEB-INF/classes/resources" />
<copy file="src/main/resources/appcodes.properties"
todir="target/WEB-INF/classes/resources" />
</target>
</project>
--
Regards,
Niranjan Deshpande
"Shut yourself from the world and create the reality you want"
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]