Skip to content
This repository has been archived by the owner on May 10, 2024. It is now read-only.

Commit

Permalink
Updating update-version script to update feature.xml.template file
Browse files Browse the repository at this point in the history
Add settings.xml parameter to update-version.sh to use maven repo credentials

(cherry picked from commit 1fd2258)
(cherry picked from commit 2cf8a26)
  • Loading branch information
asequeira committed May 20, 2015
1 parent a9f1e82 commit 56cc7ea
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions update-version.sh
@@ -1,14 +1,15 @@
#!/bin/sh
if [ -z $4 ]; then
echo "Usage: \033[1mupdate-version.sh\033[0m MAVEN_VERSION_FROM MAVEN_VERSION_TO OSGI_VERSION_FROM OSGI_VERSION_TO";
if [ -z $5 ]; then
echo "Usage: \033[1mupdate-version.sh\033[0m MAVEN_VERSION_FROM MAVEN_VERSION_TO OSGI_VERSION_FROM OSGI_VERSION_TO MAVEN_SETTINGS";
exit 1
fi
echo update-version "$1 $2 $3 $4"
mvn versions:set versions:commit -DnewVersion="$2"
echo update-version "$1 $2 $3 $4 $5"
mvn --settings $5 versions:set versions:commit -DnewVersion="$2"
sed -e "s/mule-transport-amqp-$1.jar/mule-transport-amqp-$2.jar/g" -i '' amqp-eclipse-plugin/org.mule.tooling.ui.contribution.amqp/build.properties
sed -e "s/mule-transport-amqp-$1.zip/mule-transport-amqp-$2.zip/g" -i '' amqp-eclipse-plugin/org.mule.tooling.ui.contribution.amqp/build.properties
find . -name MANIFEST.MF -exec sed -e "s/Bundle-Version:.*/Bundle-Version: $4/g" -i '' {} \;
find . -name feature.xml -exec sed -e "s/version=.*$3/version=\"$4/g" -i '' {} \;
sed -e "s/contributionJar=\"mule-transport-amqp-$1.jar\"/contributionJar=\"mule-transport-amqp-$2.jar\"/g" -i '' amqp-eclipse-plugin/org.mule.tooling.ui.contribution.amqp/plugin.xml
sed -e "s/contributionLibs=\"mule-transport-amqp-$1.zip\"/contributionJar=\"mule-transport-amqp-$2.zip\"/g" -i '' amqp-eclipse-plugin/org.mule.tooling.ui.contribution.amqp/plugin.xml
sed -e "s/version=.*$1/version=\"$2/g" -i '' amqp-eclipse-plugin/org.mule.tooling.ui.contribution.amqp/plugin.xml
sed -e "s/contributionLibs=\"mule-transport-amqp-$1.zip\"/contributionLibs=\"mule-transport-amqp-$2.zip\"/g" -i '' amqp-eclipse-plugin/org.mule.tooling.ui.contribution.amqp/plugin.xml
sed -e "s/version=\"*$1\"/version=\"$2\"/g" -i '' amqp-eclipse-plugin/org.mule.tooling.ui.contribution.amqp/plugin.xml
sed -e "s/version=\"$3\"/version=\"$4\"/g" -i '' amqp-eclipse-plugin/org.mule.tooling.amqp/feature.xml.template

0 comments on commit 56cc7ea

Please sign in to comment.