Skip to content

Commit

Permalink
remove --kill-who flags
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisho authored and Vicente-Cheng committed May 23, 2023
1 parent e78a8c5 commit 746783b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ if [ ${#unit_list[@]} -lt $max_concurrency ]; then
max_concurrency=${#unit_list[@]}
fi

printf '%s\0' "${unit_list[@]}" | xargs -0 -n1 -P "$max_concurrency" sh -c 'sudo systemctl stop --kill-who=all "$@" && echo "Finished $@"' _ | { grep -v '^Finished' || true; } | { grep -v 'xargs:' || true; } &
printf '%s\0' "${unit_list[@]}" | xargs -0 -n1 -P "$max_concurrency" sh -c 'sudo systemctl stop "$@" && echo "Finished $@"' _ | { grep -v '^Finished' || true; } | { grep -v 'xargs:' || true; } &
wait

echo "Finished stopping all units."
Expand Down

0 comments on commit 746783b

Please sign in to comment.