From 0688d4f318d3094c20a8c2916595a26ff93ec5b0 Mon Sep 17 00:00:00 2001 From: whyour Date: Tue, 9 Nov 2021 23:23:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Drepo=E6=96=87=E4=BB=B6?= =?UTF-8?q?=E6=AF=94=E5=AF=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- shell/task.sh | 6 ------ shell/update.sh | 2 +- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/shell/task.sh b/shell/task.sh index f09da655..178006a0 100755 --- a/shell/task.sh +++ b/shell/task.sh @@ -78,8 +78,6 @@ run_nohup() { run_normal() { local first_param=$1 cd $dir_scripts - local relative_path="${first_param%/*}" - [[ ! -z ${relative_path} ]] && cd ${relative_path} define_program "$first_param" if [[ $first_param == *.js ]]; then if [[ $# -eq 1 ]]; then @@ -139,8 +137,6 @@ run_concurrent() { local cookieStr=$(echo ${array_run[*]} | sed 's/\ /\&/g') cd $dir_scripts - local relative_path="${first_param%/*}" - [[ ! -z ${relative_path} ]] && cd ${relative_path} define_program "$first_param" log_time=$(date "+%Y-%m-%d-%H-%M-%S") log_dir_tmp="${first_param##*/}" @@ -196,8 +192,6 @@ run_designated() { fi cd $dir_scripts - local relative_path="${first_param%/*}" - [[ ! -z ${relative_path} ]] && cd ${relative_path} define_program "$file_param" log_time=$(date "+%Y-%m-%d-%H-%M-%S") log_dir_tmp="${file_param##*/}" diff --git a/shell/update.sh b/shell/update.sh index 9016d9be..eeeec8a4 100755 --- a/shell/update.sh +++ b/shell/update.sh @@ -407,7 +407,7 @@ gen_list_repo() { result=$(update_cron_command_api "$cmd_task ${uniq_path}/${filename}:$cron_id") fi done - grep -E "$cmd_task $uniq_path" $list_crontab_user | perl -pe "s|.*ID=(.*) $cmd_task ($uniq_path.*)\.*|\2|" | awk -F " " '{print $1}' | sort -u >"$dir_list_tmp/${repo}_user.list" + grep -E "$cmd_task $uniq_path" $list_crontab_user | perl -pe "s|.*ID=(.*) $cmd_task ($uniq_path.*)\.*|\2|" | awk -F " " '{print $1}' | sort -u >"$dir_list_tmp/${uniq_path}_user.list" cd $dir_current }