提交 228be72a 编写于 作者: haoranc's avatar haoranc

modify release.sh about beta version name

上级 20c6dd70
...@@ -69,7 +69,7 @@ rm -rf ./TDengine-alert ...@@ -69,7 +69,7 @@ rm -rf ./TDengine-alert
pkg_name=TDengine-alert-${version}-${osType^}-${archMap[${cpuType}]} pkg_name=TDengine-alert-${version}-${osType^}-${archMap[${cpuType}]}
if [ "$verType" == "beta" ]; then if [ "$verType" == "beta" ]; then
pkg_name=${pkg_name}-${verType} pkg_name=TDengine-alert-${version}-${verType}-${osType^}-${archMap[${cpuType}]}
elif [ "$verType" == "stable" ]; then elif [ "$verType" == "stable" ]; then
pkg_name=${pkg_name} pkg_name=${pkg_name}
else else
......
...@@ -16,7 +16,7 @@ cpuType="" ...@@ -16,7 +16,7 @@ cpuType=""
version="" version=""
passWord="" passWord=""
pkgFile="" pkgFile=""
verType="" verType="stable"
while getopts "hc:n:p:f:V:" arg while getopts "hc:n:p:f:V:" arg
do do
......
...@@ -47,24 +47,28 @@ mkdir -p ${install_dir}/init.d && cp ${init_file_tarbitrator_rpm} ${install_dir} ...@@ -47,24 +47,28 @@ mkdir -p ${install_dir}/init.d && cp ${init_file_tarbitrator_rpm} ${install_dir}
cd ${release_dir} cd ${release_dir}
if [ "$verMode" == "cluster" ]; then # install_dir has been distinguishes cluster from edege, so comments this code
pkg_name=${install_dir}-${osType}-${cpuType} pkg_name=${install_dir}-${osType}-${cpuType}
elif [ "$verMode" == "edge" ]; then
pkg_name=${install_dir}-${osType}-${cpuType} # if [ "$verMode" == "cluster" ]; then
else # pkg_name=${install_dir}-${osType}-${cpuType}
echo "unknow verMode, nor cluster or edge" # elif [ "$verMode" == "edge" ]; then
exit 1 # pkg_name=${install_dir}-${osType}-${cpuType}
fi # else
# echo "unknow verMode, nor cluster or edge"
# exit 1
# fi
if [ "$verType" == "beta" ]; then if [ "$verType" == "beta" ]; then
pkg_name=${pkg_name}-${verType} pkg_name=${install_dir}-${verType}-${osType}-${cpuType}
elif [ "$verType" == "stable" ]; then elif [ "$verType" == "stable" ]; then
pkg_name=${pkg_name} pkg_name=${pkg_name}
else else
echo "unknow verType, nor stabel or beta" echo "unknow verType, nor stabel or beta"
exit 1 exit 1
fi fi
tar -zcv -f "$(basename ${pkg_name}).tar.gz" $(basename ${install_dir}) --remove-files || : tar -zcv -f "$(basename ${pkg_name}).tar.gz" $(basename ${install_dir}) --remove-files || :
exitcode=$? exitcode=$?
if [ "$exitcode" != "0" ]; then if [ "$exitcode" != "0" ]; then
......
...@@ -170,12 +170,24 @@ fi ...@@ -170,12 +170,24 @@ fi
cd ${release_dir} cd ${release_dir}
if [ "$verMode" == "cluster" ]; then # install_dir has been distinguishes cluster from edege, so comments this code
pkg_name=${install_dir}-${osType}-${cpuType} pkg_name=${install_dir}-${osType}-${cpuType}
elif [ "$verMode" == "edge" ]; then
pkg_name=${install_dir}-${osType}-${cpuType} # if [ "$verMode" == "cluster" ]; then
# pkg_name=${install_dir}-${osType}-${cpuType}
# elif [ "$verMode" == "edge" ]; then
# pkg_name=${install_dir}-${osType}-${cpuType}
# else
# echo "unknow verMode, nor cluster or edge"
# exit 1
# fi
if [ "$verType" == "beta" ]; then
pkg_name=${install_dir}-${verType}-${osType}-${cpuType}
elif [ "$verType" == "stable" ]; then
pkg_name=${pkg_name}
else else
echo "unknow verMode, nor cluster or edge" echo "unknow verType, nor stabel or beta"
exit 1 exit 1
fi fi
...@@ -183,15 +195,6 @@ if [ "$pagMode" == "lite" ]; then ...@@ -183,15 +195,6 @@ if [ "$pagMode" == "lite" ]; then
pkg_name=${pkg_name}-Lite pkg_name=${pkg_name}-Lite
fi fi
if [ "$verType" == "beta" ]; then
pkg_name=${pkg_name}-${verType}
elif [ "$verType" == "stable" ]; then
pkg_name=${pkg_name}
else
echo "unknow verType, nor stable or beta"
exit 1
fi
if [ "$osType" != "Darwin" ]; then if [ "$osType" != "Darwin" ]; then
tar -zcv -f "$(basename ${pkg_name}).tar.gz" $(basename ${install_dir}) --remove-files || : tar -zcv -f "$(basename ${pkg_name}).tar.gz" $(basename ${install_dir}) --remove-files || :
else else
......
...@@ -203,21 +203,20 @@ fi ...@@ -203,21 +203,20 @@ fi
cd ${release_dir} cd ${release_dir}
if [ "$verMode" == "cluster" ]; then # install_dir has been distinguishes cluster from edege, so comments this code
pkg_name=${install_dir}-${osType}-${cpuType} pkg_name=${install_dir}-${osType}-${cpuType}
elif [ "$verMode" == "edge" ]; then
pkg_name=${install_dir}-${osType}-${cpuType} # if [ "$verMode" == "cluster" ]; then
else # pkg_name=${install_dir}-${osType}-${cpuType}
echo "unknow verMode, nor cluster or edge" # elif [ "$verMode" == "edge" ]; then
exit 1 # pkg_name=${install_dir}-${osType}-${cpuType}
fi # else
# echo "unknow verMode, nor cluster or edge"
if [ "$pagMode" == "lite" ]; then # exit 1
pkg_name=${pkg_name}-Lite # fi
fi
if [ "$verType" == "beta" ]; then if [ "$verType" == "beta" ]; then
pkg_name=${pkg_name}-${verType} pkg_name=${install_dir}-${verType}-${osType}-${cpuType}
elif [ "$verType" == "stable" ]; then elif [ "$verType" == "stable" ]; then
pkg_name=${pkg_name} pkg_name=${pkg_name}
else else
...@@ -225,6 +224,10 @@ else ...@@ -225,6 +224,10 @@ else
exit 1 exit 1
fi fi
if [ "$pagMode" == "lite" ]; then
pkg_name=${pkg_name}-Lite
fi
tar -zcv -f "$(basename ${pkg_name}).tar.gz" $(basename ${install_dir}) --remove-files || : tar -zcv -f "$(basename ${pkg_name}).tar.gz" $(basename ${install_dir}) --remove-files || :
exitcode=$? exitcode=$?
if [ "$exitcode" != "0" ]; then if [ "$exitcode" != "0" ]; then
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册