21 lines
710 B
Bash
Executable File
21 lines
710 B
Bash
Executable File
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
|
|
STATUS_FILE="${1:?phase status file required}"
|
|
CONTENT="$(cat "$STATUS_FILE")"
|
|
|
|
if [[ "$CONTENT" == *'importer_smoke_gate_result=PASS'* && "$CONTENT" == *'ROOT_CAUSE class='* && "$CONTENT" != *'ROOT_CAUSE class=none'* ]]; then
|
|
if [[ "$CONTENT" != *'BLOCKER_SWITCH class=global-blocker-shift'* ]]; then
|
|
echo "missing global blocker switch hint" >&2
|
|
exit 1
|
|
fi
|
|
fi
|
|
|
|
if [[ "$CONTENT" == *'importer_smoke_gate_result=FAIL'* && "$CONTENT" == *'live_run_result=SKIPPED'* ]]; then
|
|
if [[ "$CONTENT" != *'BLOCKER_SWITCH class=global-blocker-shift'* ]]; then
|
|
echo "missing global blocker switch hint" >&2
|
|
exit 1
|
|
fi
|
|
fi
|
|
echo "GLOBAL_BLOCKER_SWITCH_GUARD: PASS"
|