Make set-version update versions correctly

This commit is contained in:
Paul Campbell 2018-10-07 18:13:09 +01:00
parent c43212f234
commit 85332abf47
2 changed files with 9 additions and 9 deletions

View file

@ -49,7 +49,7 @@ The simplest way to use the ruleset is with the maven-tile:
<extensions>true</extensions>
<configuration>
<tiles>
<tile>net.kemitix.checkstyle:tile:RELEASE</tile>
<tile>net.kemitix.checkstyle:tile:DEV-SNAPSHOT</tile>
</tiles>
</configuration>
</plugin>

View file

@ -1,15 +1,15 @@
#!/usr/bin/env bash
if test $# != 2
if test $# != 1
then
echo "current and next version missing"
echo "Next version missing"
exit
fi
CURRENT=$1
NEXT=$2
NEXT=$1
echo Updating version from $CURRENT to $NEXT
mvn versions:set -DnewVersion=$NEXT
perl -p -i -e "s,$CURRENT</,$NEXT</," builder/pom.xml builder/src/main/resources/README-template.md ruleset/pom.xml tile/pom.xml tile/tile.xml
echo "Updating version to $NEXT..."
mvn versions:set -DnewVersion=$NEXT -DgenerateBackupPoms=false -DprocessAllModules
echo "Updating README template..."
perl -p -i -e "s,DEV-SNAPSHOT</,$NEXT</," builder/src/main/resources/README-template.md
echo "Done."