pom_xpath_inject (7) Linux Manual Page
pom_xpath_inject – inject XML code into POM file
Synopsis
%pom_xpath_inject XPath [XML-code] [POM-location]
Description
This macro patches specified POM file appending some code as childreen of all XML nodes described by the XPath expression.
XPath is an expression describing a set of XML nodes in the POM file to which child code is to be appended. It must be a properly formated XPath 1.0 expression, as described in m[blue]http://www.w3.org/TR/xpath/m[].
POM location can be either a full path to the POM file, or a path to the directory containing pom.xml. If POM location is not given then pom.xml from current working directory is used.
Examples
%pom_xpath_inject pom:project "<packaging>war</packaging>" – this call sets packaging of POM in current working directory to war.
Bugs
POM files use a specific namespace – m[blue]http://maven.apache.org/POM/4.0.0m[]. Currently this namespace needs to be explicitly specified in all XPath POM macros by prefixing all node names with pom:.
Author
Written by Mikolaj Izdebski.
Reporting Bugs
Bugs should be reported through Red Hat Bugzilla at m[blue]http://bugzilla.redhat.com/m[].
See Also
pom_add_dep(7), pom_add_parent(7), pom_add_plugin(7), pom_disable_module(7), pom_remove_dep(7), pom_remove_parent(7), pom_remove_plugin(7), pom_set_parent(7), pom_xpath_remove(7), pom_xpath_replace(7), pom_xpath_set(7).
