重写安装软件逻辑

This commit is contained in:
lsy 2024-09-23 15:02:29 +08:00
parent 192a8a145f
commit 3df59d74ae
2 changed files with 2 additions and 1 deletions

View File

@ -5,6 +5,7 @@ read -p "默认 /var/script" path
if [[ -z $path ]];then if [[ -z $path ]];then
path="/var/script" path="/var/script"
fi fi
echo "软件正在安装中"
mkdir -p "$path" mkdir -p "$path"
rm -rf "$path/linuxtoo" rm -rf "$path/linuxtoo"

View File

@ -47,7 +47,7 @@ done
read -p "请输入需要安装的软件序号,用 空格 隔开:" pick read -p "请输入需要安装的软件序号,用 空格 隔开:" pick
if [[ ! $pick =~ [1-"${#soft_dick[@]}"] ]];then if [[ ! $pick =~ [1-"${#soft_dick[@]}"\ ] ]];then
echo "输入错误" echo "输入错误"
exit exit
fi fi