提交 63b40fb2 编写于 作者: T tangfangzhi

enh: backup source code if case fails

上级 c7fb7f30
......@@ -41,5 +41,16 @@ fi
cat ../script/jenkins/basic.txt |grep -v "^#"|grep -v "^$"|sed "s/^/,,script,/" >>$case_file
grep "^python" ../system-test/fulltest.sh |sed "s/^/,,system-test,/" >>$case_file
# tar source code for run.sh to use
if [ $ent -eq 0 ]; then
cd ../../../
rm -rf TDengine.tar.gz
tar czf TDengine.tar.gz TDengine taos-connector-python --exclude=TDengine/debug
else
cd ../../../../
rm -rf TDinternal.tar.gz
tar czf TDinternal.tar.gz TDinternal taos-connector-python --exclude=TDinternal/debug --exclude=TDinternal/community/debug
fi
exit 0
......@@ -291,6 +291,19 @@ function run_thread() {
fi
cmd="$scpcmd:${remote_sim_tar} $log_dir/${case_file}.sim.tar.gz"
$cmd
# backup source code
source_tar_dir=$log_dir/TDengine_${hosts[index]}
source_tar_file=TDengine.tar.gz
if [ $ent -ne 0 ]; then
source_tar_dir=$log_dir/TDinternal_${hosts[index]}
source_tar_file=TDinternal.tar.gz
fi
mkdir $source_tar_dir 2>/dev/null
if [ $? -eq 0 ]; then
cmd="$scpcmd:${workdirs[index]}/$source_tar_file $source_tar_dir"
echo "$cmd"
$cmd
fi
fi
done
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册