From a5b09240360c48bc06ac03367ad9ef50ca8c2019 Mon Sep 17 00:00:00 2001 From: hanhh <18330117883@163.com> Date: Mon, 7 Jun 2021 22:31:03 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=AF=E6=8C=81=E6=9F=90=E4=B8=AAck=E4=B8=B4?= =?UTF-8?q?=E6=97=B6=E5=B1=8F=E8=94=BD=E6=9F=90=E4=B8=AA=E8=84=9A=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sample/config.sample.sh | 7 +++++++ shell/task.sh | 3 +++ 2 files changed, 10 insertions(+) diff --git a/sample/config.sample.sh b/sample/config.sample.sh index 5217cb62..0517ec21 100644 --- a/sample/config.sample.sh +++ b/sample/config.sample.sh @@ -114,6 +114,13 @@ export GOBOT_URL = "" export GOBOT_TOKEN = "" export GOBOT_QQ = "" +## 如果只是想要屏蔽某个ck不执行某个脚本,可以参考下面 case 这个命令的例子来控制,脚本名称包含后缀 +## case $1 in +## test.js) +## TempBlockCookie="5" +## ;; +## esac + ## 需组合的环境变量列表,env_name需要和var_name一一对应,如何有新活动按照格式添加(不懂勿动) env_name=( JD_COOKIE diff --git a/shell/task.sh b/shell/task.sh index 11b7a05a..708d1d99 100755 --- a/shell/task.sh +++ b/shell/task.sh @@ -10,6 +10,9 @@ combine_sub() { local combined_all="" local tmp1 tmp2 for ((i = 1; i <= $user_sum; i++)); do + for num in $TempBlockCookie; do + [[ $i -eq $num ]] && continue 2 + done local tmp1=$what_combine$i local tmp2=${!tmp1} combined_all="$combined_all&$tmp2"