This week's book giveaway is in the OCAJP 8 forum.
We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line!
See this thread for details.
The moose likes Ant, Maven and Other Build Tools and the fly likes Maven Ant xml task not working Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "Maven Ant xml task not working" Watch "Maven Ant xml task not working" New topic
Author

Maven Ant xml task not working

Anu Devarla
Greenhorn

Joined: May 10, 2007
Posts: 2
Hi I am using maevn ant xml task for manipulating xml i.e replacing the attribute value. following is the pom.xml entries, not able to copy the file to destination folder and manipulate it .But build is successful

My xml entires are :
<deployment>
<sources>
<repository url="http://mvnrepo.9090/nexus/content/repositories/releases">

pom.xml : I downloaded xmltask.jar and added to my local m2 repository.

<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<dependencies>
<dependency>
<groupId>com.oopsconsultancy</groupId>
<artifactId>xmltask</artifactId>
<version>1.14</version>
<classifier>local</classifier>
</dependency>
</dependencies>
<executions>
<execution>
<phase>prepare-package</phase>
<configuration>
<tasks>
<echo message="Using testing configuration" />
<taskdef name="xmltask"
classname="com.oopsconsultancy.xmltask.ant.XmlTask"
classpath="xmltask-1.14-local.jar"/>
<target name="default">
<xmltask
source="C:\Maven\artifact_config.xml"
dest="C:\Maven]\artifact_config_new.xml"
preserveType="true">
<replace path="/deployment/sources/@url" withText="http;//suguna.com" />
</xmltask>
</target>
</tasks>
</configuration>
</execution>
</executions>
</plugin>


Let me now wts wrong. Any help is appreciated.
Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 32636
    
216

Are you saying there are no errors or warnings; it just doesn't copy?


[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Maven Ant xml task not working
 
jQuery in Action, 3rd edition