rebuild_dependencies

This commit is contained in:
2024-07-18 22:06:35 +03:00
parent b7109ef9fa
commit de9a63f84b
6 changed files with 37 additions and 4 deletions

View File

@@ -95,6 +95,7 @@ function call_task {
local current_config_path="$1"
local default_config_path="$2"
local task="$3"
TASK_ARGS="$4"
print_header "${CYAN}" "─" "$PROJECT/$task"
load_config "$current_config_path" "$default_config_path" "$task" true
@@ -117,8 +118,16 @@ function call_tasks {
local tasks="$@"
load_config "$current_config_path" "$default_config_path" "" false
print_header "${WHITE}" "═" "$PROJECT"
for task in $tasks ; do
call_task "$current_config_path" "$default_config_path" "$task"
project_dir="$(pwd)"
for task_str in $tasks ; do
task=$(safeprint "$task_str" | sed 's/=.*//g')
local args_str=$(safeprint "$task_str" | grep -oP '(?<=\=).*' || echo "")
IFS_backup="$IFS"
IFS=',;'
args_array=($args_str)
IFS="$IFS_backup"
call_task "$current_config_path" "$default_config_path" "$task" "${args_array[@]}"
cd "$project_dir"
done
}