maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sizu <scott...@gmail.com>
Subject Re: Is there any maven plugin to add dependency to existing pom.xml ?
Date Fri, 11 Oct 2013 18:45:48 GMT
Example using sed:

sed
's/<dependencies>/<dependencies>\r\n\r\n<dependency>\r\n<groupId>org.ghost4j<\/groupId>\r\n<artifactId>ghost4j<\/artifactId>\r\n<version>0.5.0<\/version>\r\n<\/dependency>\r\n/g'
pom.xml > pom2.xml

Replaces the dependencies tag with the dependencies tag followed by the new
dependency (inserts the new dependency first in the list.

Creates a new file pom2.xml with the new dependency (this can be changed to
overwrite the original file using: pom.xml > pom.xml



--
View this message in context: http://maven.40175.n5.nabble.com/Is-there-any-maven-plugin-to-add-dependency-to-existing-pom-xml-tp2839092p5772863.html
Sent from the Maven - Users mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Mime
View raw message