From e4eb30df53e3382a19edb56a80f14d8bc31a9e8e Mon Sep 17 00:00:00 2001 From: mack-a <57424792+mack-a@users.noreply.github.com> Date: Mon, 6 Sep 2021 11:53:02 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E8=84=9A=E6=9C=AC):=20=E7=A7=BB=E9=99=A4s?= =?UTF-8?q?table=E3=80=81=E4=BF=AE=E6=94=B9=E6=97=B6=E9=97=B4=E8=AE=A1?= =?UTF-8?q?=E7=AE=97=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 5 ----- install.sh | 18 ++++++++++-------- 2 files changed, 10 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index 6292396..319426a 100644 --- a/README.md +++ b/README.md @@ -129,11 +129,6 @@ wget -P /root -N --no-check-certificate "https://raw.githubusercontent.com/mack-a/v2ray-agent/master/install.sh" && chmod 700 /root/install.sh && /root/install.sh ``` -- Stable-v2.4.16【无gRPC】 -``` -wget -P /root -N --no-check-certificate "https://raw.githubusercontent.com/mack-a/v2ray-agent/stable_v2.4.16/install.sh" && chmod 700 /root/install.sh && /root/install.sh -``` - # 示例图 diff --git a/install.sh b/install.sh index 770e86f..9e69661 100644 --- a/install.sh +++ b/install.sh @@ -1005,9 +1005,10 @@ renewalTLS() { modifyTime=$(date +%s -d "${modifyTime}") currentTime=$(date +%s) - stampDiff=$(("${currentTime}" - "${modifyTime}")) - days=$(("${stampDiff}" / 86400)) - remainingDays=$((90 - "${days}")) + ((stampDiff=currentTime - modifyTime)) + ((days=stampDiff / 86400)) + ((remainingDays=90 - days)) + tlsStatus=${remainingDays} if [[ ${remainingDays} -le 0 ]]; then tlsStatus="已过期" @@ -1041,9 +1042,10 @@ checkTLStatus() { modifyTime=$(date +%s -d "${modifyTime}") currentTime=$(date +%s) - stampDiff=$(("${currentTime}" - "${modifyTime}")) - days=$(("${stampDiff}" / 86400)) - remainingDays=$((90 - "${days}")) + ((stampDiff=currentTime - modifyTime)) + ((days=stampDiff / 86400)) + ((remainingDays=90 - days)) + tlsStatus=${remainingDays} if [[ ${remainingDays} -le 0 ]]; then tlsStatus="已过期" @@ -4099,7 +4101,7 @@ subscribe() { showAccounts >/dev/null mv /etc/v2ray-agent/subscribe_tmp/* /etc/v2ray-agent/subscribe/ - if [[ -n $(ls /etc/v2ray-agent/subscribe) ]]; then + if [[ -n $(ls /etc/v2ray-agent/subscribe/) ]]; then find /etc/v2ray-agent/subscribe | while read -r email; do email=$(echo "${email}" | awk -F "[s][u][b][s][c][r][i][b][e][/]" '{print $2}') local base64Result @@ -4123,7 +4125,7 @@ menu() { cd "$HOME" || exit echoContent red "\n==============================================================" echoContent green "作者:mack-a" - echoContent green "当前版本:v2.5.30" + echoContent green "当前版本:v2.5.31" echoContent green "Github:https://github.com/mack-a/v2ray-agent" echoContent green "描述:八合一共存脚本\c" showInstallStatus