mirror of
https://gitee.com/dcren/initializr.git
synced 2026-09-20 06:47:41 +08:00
Fix version -> repo mapping in install.sh
This commit is contained in:
+10
-3
@@ -3,7 +3,7 @@
|
|||||||
set -e
|
set -e
|
||||||
# set -x
|
# set -x
|
||||||
|
|
||||||
VERSION="1.0.1.RELEASE"
|
VERSION="1.0.2.RELEASE"
|
||||||
if [ -z "${PREFIX}" ]; then
|
if [ -z "${PREFIX}" ]; then
|
||||||
PREFIX="/usr/local/bin"
|
PREFIX="/usr/local/bin"
|
||||||
fi
|
fi
|
||||||
@@ -11,10 +11,17 @@ if [ -z "${JAR_FILE}" ]; then
|
|||||||
JAR_FILE="/tmp/spring.zip"
|
JAR_FILE="/tmp/spring.zip"
|
||||||
if [ -z "${JAR_URL}" ]; then
|
if [ -z "${JAR_URL}" ]; then
|
||||||
|
|
||||||
echo "Downloading spring ${VERSION} distribution"
|
case "${VERSION}" in
|
||||||
|
*SNAPSHOT) REPO=snapshot ;;
|
||||||
|
*.M*) REPO=milestone ;;
|
||||||
|
*.RC*) REPO=milestone ;;
|
||||||
|
*) REPO=release ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
echo "Downloading spring ${VERSION} distribution from repo.spring.io/${REPO}"
|
||||||
echo
|
echo
|
||||||
|
|
||||||
JAR_URL="https://repo.spring.io/milestone/org/springframework/boot/spring-boot-cli/${VERSION}/spring-boot-cli-${VERSION}-bin.zip"
|
JAR_URL="https://repo.spring.io/${REPO}/org/springframework/boot/spring-boot-cli/${VERSION}/spring-boot-cli-${VERSION}-bin.zip"
|
||||||
curl --progress-bar --fail "$JAR_URL" -o "$JAR_FILE"
|
curl --progress-bar --fail "$JAR_URL" -o "$JAR_FILE"
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user