Test: Cover contract runner consent

This commit is contained in:
Gabriel Brown
2026-08-26 22:22:57 -04:00
parent d8144a66c1
commit 6d71a77798
2 changed files with 92 additions and 14 deletions
+1 -1
View File
@@ -57,7 +57,7 @@ header(){ printf '\n%s%s%s\n' "${MAGENTA}${BOLD}" "$*" "$RESET"; }
# Ask a yes/no question. Returns 0 for yes, 1 for no. Default = no.
confirm() {
local prompt="$1" reply
printf '%s?%s %s %s[y/N]%s ' "${CYAN}${BOLD}" "$RESET" "$prompt" "$BOLD" "$RESET"
printf '%s?%s %s %s[y/N]%s ' "${CYAN}${BOLD}" "$RESET" "$prompt" "$BOLD" "$RESET" >&2
read -r reply || true
[[ "$reply" =~ ^[Yy]([Ee][Ss])?$ ]]
}