From 01a308331230833c2aca9e7e67892364b9e6a958 Mon Sep 17 00:00:00 2001 From: 233boy Date: Sun, 6 May 2018 00:10:49 +0800 Subject: [PATCH] bug fix --- install.sh | 2 +- v2ray.sh | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/install.sh b/install.sh index 85b3a80..2130c52 100644 --- a/install.sh +++ b/install.sh @@ -1281,7 +1281,7 @@ config() { backup_config() { sed -i "18s/=1/=$v2ray_transport_opt/; 21s/=2333/=$v2ray_port/; 24s/=$old_id/=$uuid/" $backup - if [ $v2ray_transport_opt -ge 9 && $v2ray_transport_opt -le 15 ]; then + if [[ $v2ray_transport_opt -ge 9 && $v2ray_transport_opt -le 15 ]]; then sed -i "30s/=10000/=$v2ray_dynamic_port_start_input/; 33s/=20000/=$v2ray_dynamic_port_end_input/" $backup fi if [ $shadowsocks ]; then diff --git a/v2ray.sh b/v2ray.sh index 69e823b..1efc308 100644 --- a/v2ray.sh +++ b/v2ray.sh @@ -10,7 +10,7 @@ none='\e[0m' # Root [[ $(id -u) != 0 ]] && echo -e " 哎呀……请使用 ${red}root ${none}用户运行 ${yellow}~(^_^) ${none}" && exit 1 -_version="v2.19" +_version="v2.20" cmd="apt-get" @@ -3608,7 +3608,10 @@ un | uninstall) ;; reinstall) uninstall_v2ray - [[ $is_uninstall_v2ray ]] && bash <(curl -s -L https://233blog.com/v2ray.sh) + if [[ $is_uninstall_v2ray ]]; then + cd; cd - >/dev/null 2>&1 + bash <(curl -s -L https://233blog.com/v2ray.sh) + fi ;; 233 | 2333 | 233boy | 233blog | 233blog.com) _boom_