未验证 提交 f0292723 编写于 作者: L Linhe Huo 提交者: GitHub

[TD-13531]<fix>: fix rm error: refusing to remove '.' (#10312)

上级 a597c2bf
...@@ -567,7 +567,7 @@ function install_data() { ...@@ -567,7 +567,7 @@ function install_data() {
} }
function install_connector() { function install_connector() {
${csudo}cp -rf ${script_dir}/connector/ ${install_main_dir}/ [ -d "${script_dir}/connector/" ] && ${csudo}cp -rf ${script_dir}/connector/ ${install_main_dir}/
} }
function install_examples() { function install_examples() {
...@@ -885,7 +885,7 @@ function update_TDengine() { ...@@ -885,7 +885,7 @@ function update_TDengine() {
echo -e "\033[44;32;1m${productName} client is updated successfully!${NC}" echo -e "\033[44;32;1m${productName} client is updated successfully!${NC}"
fi fi
rm -rf $(tar -tf ${tarName}) rm -rf $(tar -tf ${tarName} |grep -v "^\./$")
} }
function install_TDengine() { function install_TDengine() {
...@@ -982,7 +982,7 @@ function install_TDengine() { ...@@ -982,7 +982,7 @@ function install_TDengine() {
fi fi
touch ~/.${historyFile} touch ~/.${historyFile}
rm -rf $(tar -tf ${tarName}) rm -rf $(tar -tf ${tarName} |grep -v "^\./$")
} }
## ==============================Main program starts from here============================ ## ==============================Main program starts from here============================
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册