Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/xsl/xslUpVersion.sh')
-rwxr-xr-xscripts/xsl/xslUpVersion.sh26
1 files changed, 26 insertions, 0 deletions
diff --git a/scripts/xsl/xslUpVersion.sh b/scripts/xsl/xslUpVersion.sh
new file mode 100755
index 00000000..38dee904
--- /dev/null
+++ b/scripts/xsl/xslUpVersion.sh
@@ -0,0 +1,26 @@
+#!/bin/bash
+#
+
+DIR=$( dirname $0 )
+NEW_VER=4.4.0-SNAPSHOT
+if [ $# -eq 1 ]; then
+ NEW_VER="$1"
+fi
+
+find * -name pom.xml -print0 >/tmp/files.txt
+
+cat /tmp/files.txt | xargs -0 grep packaging.pom..packaging | cut -f1 -d: | sort -u >/tmp/t1_$$.txt
+cat /tmp/files.txt | xargs -0 grep packaging.eclipse-repository..packaging | cut -f1 -d: | sort -u >>/tmp/t1_$$.txt
+
+for POM in $( cat /tmp/t1_$$.txt ); do
+xsltproc --stringparam new-version "$NEW_VER" -o "${POM}.out" $DIR/fix-pom-version.xsl "${POM}"
+mv "${POM}.out" "${POM}"
+done
+
+find * -name pom.xml | sort -u >/tmp/t1_$$.txt
+
+for POM in $( cat /tmp/t1_$$.txt ); do
+xsltproc --stringparam new-version "$NEW_VER" -o "${POM}.out" $DIR/fix-pom-parent-version.xsl "${POM}"
+mv "${POM}.out" "${POM}"
+done
+

Back to the top