File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -11,7 +11,15 @@ if [ $# -gt 1 ]; then echo -e "ERROR: One argument maximum.\n$USAGE" >&2; exit 1
11
11
12
12
TICKET_ID=${1:? " TICKET_ID Parameter is missing!" }
13
13
14
- OLD_VERSION_TMP=$( mvn org.apache.maven.plugins:maven-help-plugin:2.1.1:evaluate -Dexpression=project.version | grep -Ev ' ^\[.*' )
14
+ # Warmup the maven plugins before actually using them (avoids "Downloading" messages getting in variables)
15
+ echo " Warming up the Maven plugins..."
16
+ mvn -q org.apache.maven.plugins:maven-help-plugin:2.1.1:evaluate -Dexpression=project.version
17
+ mvn -q versions:help
18
+
19
+ # Now use the plugins to roll the version
20
+
21
+ echo " Looking up the current version..."
22
+ OLD_VERSION_TMP=$( mvn -o org.apache.maven.plugins:maven-help-plugin:2.1.1:evaluate -Dexpression=project.version | grep -Ev ' ^\[.*' )
15
23
16
24
OLD_POM_VERSION=${OLD_VERSION_TMP:? " Could not extract current project version from pom.xml" }
17
25
@@ -23,7 +31,7 @@ echo "Creating feature branch $TICKET_ID: $OLD_POM_VERSION -> $NEW_POM_VERSION"
23
31
24
32
echo " Stashing potential intermediate changes..." && git stash\
25
33
&& git checkout -b $ISSUE_BRANCH \
26
- && $( mvn $MAVEN_FLAGS -q versions:set -DgenerateBackupPoms=false -DnewVersion=$NEW_POM_VERSION ) \
34
+ && $( mvn -o $MAVEN_FLAGS -q versions:set -DgenerateBackupPoms=false -DnewVersion=$NEW_POM_VERSION ) \
27
35
&& ( \
28
36
(\
29
37
git commit -am " $TICKET_ID - Prepare branch" \
You can’t perform that action at this time.
0 commit comments