!814 修复升级问题

Merge pull request !814 from 邓旭玥/efix_0315
This commit is contained in:
opengauss-bot
2021-03-15 20:28:02 +08:00
committed by Gitee

View File

@ -295,15 +295,9 @@ function install_gaussdb()
####################################################################### #######################################################################
function copy_files_list() function copy_files_list()
{ {
for element in $(ls $1) for file in $(echo $1)
do do
dir_or_file=$1"/"$element tar -cpf - $file | ( cd $2; tar -xpf - )
if [ -d "$dir_or_file" ]
then
copy_files_list $dir_or_file $2
else
tar -cpf - $file | ( cd $2; tar -xpf - )
fi
done done
} }
@ -313,10 +307,7 @@ function copy_files_list()
function target_file_copy() function target_file_copy()
{ {
cd ${BUILD_DIR} cd ${BUILD_DIR}
for file in $(echo $1) copy_files_list "$1" $2
do
copy_files_list $file $2
done
cp ${SCRIPT_DIR}/version.cfg ${BUILD_DIR}/temp cp ${SCRIPT_DIR}/version.cfg ${BUILD_DIR}/temp
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
@ -356,10 +347,7 @@ function target_file_copy()
function target_file_copy_for_non_server() function target_file_copy_for_non_server()
{ {
cd ${BUILD_DIR} cd ${BUILD_DIR}
for file in $(echo $1) copy_files_list "$1" $2
do
copy_files_list $file $2
done
} }
####################################################################### #######################################################################