From: <[EMAIL PROTECTED]> > > This happens in the validate-war target for the j2ee plugin - it's just a > case of referencing it like you do below. > > Is there something that doesn't work when u do this?
I've figured out why this does't work for me. Right now the only way to get access to the classpath ref "maven.dependency.classpath" is by being a Maven plugin. So its not automatically available in a project's (mostly empty) build.xml file. The reason is that references don't currently get returned from inner Ant builds. The reason it works for plugins is due to the explicit call of the maven ProjectProperties Ant task. So to get access to the "maven.dependency.classpath" you can add this to your projects build.xml... <taskdef name="project-properties" classname="org.apache.maven.ProjectProperties"> <classpath> <pathelement location="${lib.repo}/commons-lang-0.1-dev.jar"/> <pathelement location="${lib.repo}/commons-util-1.0-rc2-dev.jar"/> <pathelement location="${lib.repo}/commons-beanutils-dev.jar"/> <pathelement location="${lib.repo}/commons-collections.jar"/> <pathelement location="${lib.repo}/commons-io.jar"/> <pathelement location="${lib.repo}/commons-logging-1.0.jar"/> <pathelement location="${lib.repo}/commons-xo-1.0-20020507.jar"/> <pathelement location="${lib.repo}/dom4j-1.3.jar"/> <pathelement location="${lib.repo}/maven.jar"/> </classpath> </taskdef> <project-properties projectDescriptor="project.xml"/> Then the classpath reference will be available. A better solution will probably be to patch Ant so that references can be exported someway from an inner Ant build (such as the ${maven.home}/plugins/core/build.xml) to an outer build, such as a projects build.xml. I wonder if there's a way we could patch the org.apache.maven.ProjectProperties to put the classpath reference somewhere that could then be referenced by a projects build.xml. Anyone got any bright ideas? James _________________________________________________________ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>