太初行更新脚本修改

main
grimm 2024-07-25 16:08:54 +08:00
parent 2fb38c03e2
commit 154acbf987
1 changed files with 3 additions and 4 deletions

View File

@ -128,20 +128,19 @@ game_send_package() {
if is_valid_ip "$channel"; then if is_valid_ip "$channel"; then
unzip_package $channel $package $source_tar $destination_dir unzip_package $channel $package $source_tar $destination_dir
case $input in case $reboot in
[yY][eE][sS]|[yY]) [yY][eE][sS]|[yY])
restart_server "coreRestart" "$channel" restart_server "coreRestart" "$channel"
;; ;;
*) *)
echo "over..." echo "over..."
exit 0
;; ;;
esac esac
else else
for ip in $(awk '{print $2}' "txt/$channel.txt") for ip in $(awk '{print $2}' "txt/$channel.txt")
do do
unzip_package $ip $package $source_tar $destination_dir unzip_package $ip $package $source_tar $destination_dir
case $input in case $reboot in
[yY][eE][sS]|[yY]) [yY][eE][sS]|[yY])
restart_server "super" "$ip" restart_server "super" "$ip"
;; ;;
@ -237,7 +236,7 @@ game_code_official(){
read -rp "请输入包名(不需要带文件后缀):" package read -rp "请输入包名(不需要带文件后缀):" package
show_file script/txt show_file script/txt
read -rp "请输入ip地址或文件名称(不需要带文件后缀): " channel read -rp "请输入ip地址或文件名称(不需要带文件后缀): " channel
read -rp "是否需要重启(Y/N)" reboot read -rp "是否需要重启(Y/N):" reboot
echo -e "开始发送 包名:$package, 渠道:$channel" echo -e "开始发送 包名:$package, 渠道:$channel"
game_send_package "$channel" "$package" "$reboot" game_send_package "$channel" "$package" "$reboot"
} }