Stuart McCulloch | bdea0e4 | 2009-02-16 15:28:03 +0000 | [diff] [blame] | 1 | #!/bin/sh |
| 2 | |
| 3 | VERSION=$1 |
| 4 | |
| 5 | if [ "$VERSION" = "" ] |
| 6 | then |
| 7 | |
| 8 | echo "Usage: $0 <new-bundleplugin-version>" |
| 9 | exit |
| 10 | |
| 11 | fi |
| 12 | |
| 13 | cd ../pom |
| 14 | |
| 15 | for POM in `find .. -name .svn -prune -o -name pom.xml -print` |
| 16 | do |
| 17 | |
| 18 | mvn "-DprojectFile=$POM" \ |
| 19 | "-Dxpath=/project/build/plugins/plugin[artifactId[.='maven-bundle-plugin']]/version" \ |
| 20 | "-DnewValue=$VERSION" \ |
| 21 | org.apache.maven.plugins:maven-pom-plugin:1.0-SNAPSHOT:alter-by-xpath |
| 22 | |
| 23 | mvn "-DprojectFile=$POM" \ |
| 24 | "-DskipXPath=/project/build/plugins/plugin[artifactId[.='maven-bundle-plugin']]/version" \ |
| 25 | "-Dxpath=/project/build/plugins/plugin[artifactId[.='maven-bundle-plugin']]" \ |
| 26 | "-DnewElement=version" "-DnewValue=$VERSION" \ |
| 27 | org.apache.maven.plugins:maven-pom-plugin:1.0-SNAPSHOT:add-by-xpath |
| 28 | |
| 29 | done |
| 30 | |