I am trying to do a simple replace in an xml document where the root node
has a namespace. Here's my latest attempt:
<xmltask preservetype="true" report="true"
source="${DEPLOY_DIR}/installer/update.xml"
dest="${DEPLOY_DIR}/installer/update.xml">
<replace path="//*[local-name()='update']/exe/version/text()"
withXML="1.0.${build.number}"/>
</xmltask>
The XML document looks like:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<update xmlns="http://ns.riaspace.com/air/framework/update/description/1.1">
<exe>
<version>1.0.1</version>
</exe>
</update>
For the life of me I cannot get it to replace the <version> text with the
text I supply. I've tried all sorts of xPath, but it simply does not find
it. Now, if I remove the namespace and use this as the path:
/update/exe/version/text()
It works fine. Problem is the xml file needs to have the namespace. Any
ideas?
--Abram
------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires
February 28th, so secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsight-sfd2d
_______________________________________________
Xmltask-users mailing list
Xmltask-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/xmltask-users