File tree Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -104,12 +104,8 @@ install_mvn() {
104104 # See simple version normalization: http://stackoverflow.com/questions/16989598/bash-comparing-version-numbers
105105 function version { echo " $@ " | awk -F. ' { printf("%03d%03d%03d\n", $1,$2,$3); }' ; }
106106
107- if [ $( version $MVND_DETECTED_VERSION ) -ne $( version $MVND_VERSION ) ]; then
108-
109- # if [ $(version $MVN_DETECTED_VERSION) -ne $(version $MVN_VERSION) ]; then
110- # echo "Mvnd $MVND_DETECTED_VERSION embedded maven version $MVN_DETECTED_VERSION is not equivalent to $MVN_VERSION required in pom."
111- # exit 1
112- # fi
107+ if [ $( version $MVND_DETECTED_VERSION ) -ne $( version $MVND_VERSION ) ]
108+ then
113109 local APACHE_MIRROR=${APACHE_MIRROR:- ' https://downloads.apache.org' }
114110 local OS_TYPE=$( get_os_type)
115111 local ARCH=$( get_os_arch)
@@ -120,6 +116,11 @@ install_mvn() {
120116 " maven-mvnd-${MVND_VERSION} -${OS_TYPE} -${ARCH} /bin/mvnd"
121117
122118 MVND_BIN=" ${_DIR} /maven-mvnd-${MVND_VERSION} -${OS_TYPE} -${ARCH} /bin/mvnd"
119+ else
120+ if [ $( version $MVN_DETECTED_VERSION ) -ne $( version $MVN_VERSION ) ]; then
121+ echo " Mvnd $MVND_DETECTED_VERSION embedded maven version $MVN_DETECTED_VERSION is not equivalent to $MVN_VERSION required in pom."
122+ exit 1
123+ fi
123124 fi
124125}
125126
You can’t perform that action at this time.
0 commit comments