Fixes pre-commit failing on build step (#10785)
When rebuildig the image during commit, kill command failed to find the spinner job to kill (this is just preventive measure) and failed the rebuild step in pre-commit. This is now fixed.
This commit is contained in:
Родитель
f14f379716
Коммит
ef0d639b34
|
@ -509,7 +509,7 @@ function build_images::build_ci_image() {
|
|||
spinner::spin "${OUTPUT_LOG}" &
|
||||
SPIN_PID=$!
|
||||
# shellcheck disable=SC2064
|
||||
traps::add_trap "kill ${SPIN_PID}" INT TERM HUP EXIT
|
||||
traps::add_trap "kill ${SPIN_PID} || true" INT TERM HUP EXIT
|
||||
fi
|
||||
push_pull_remove_images::pull_ci_images_if_needed
|
||||
if [[ "${DOCKER_CACHE}" == "disabled" ]]; then
|
||||
|
@ -537,7 +537,7 @@ function build_images::build_ci_image() {
|
|||
spinner::spin "${OUTPUT_LOG}" &
|
||||
SPIN_PID=$!
|
||||
# shellcheck disable=SC2064
|
||||
traps::add_trap "kill ${SPIN_PID}" EXIT HUP INT TERM
|
||||
traps::add_trap "kill ${SPIN_PID} || true" EXIT HUP INT TERM
|
||||
fi
|
||||
if [[ -n ${DETECTED_TERMINAL=} ]]; then
|
||||
echo -n "
|
||||
|
|
|
@ -235,7 +235,7 @@ EOF
|
|||
}
|
||||
|
||||
function stop_output_heartbeat() {
|
||||
kill "${HEARTBEAT_PID}"
|
||||
kill "${HEARTBEAT_PID}" || true
|
||||
wait "${HEARTBEAT_PID}" || true 2> /dev/null
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче