From d006fe91902a0a26e894f9d4ce1353a02a3bbc08 Mon Sep 17 00:00:00 2001 From: naskya Date: Fri, 5 Jan 2024 10:37:21 +0900 Subject: [PATCH] dev (minor): don't take "yes" as a negative response --- update.sh | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/update.sh b/update.sh index f6bbfca8..285bcd44 100755 --- a/update.sh +++ b/update.sh @@ -75,16 +75,20 @@ for message in neko/messages/*; do done say 'Do you use Docker or Podman?' -printf '(d: Docker, p: Podman, n: No) [d/p/N] > ' -read -r yn +printf 'd: Docker, p: Podman, n: No [d/p/N] > ' +read -r resp -case "${yn}" in +case "${resp}" in [Dd]) ./neko/update/docker.sh 'docker' "$@" ;; [Pp]) ./neko/update/docker.sh 'podman' "$@" ;; + [Yy]|[Yy][Ee][Ss]) + printf "Watch out! ${resp} is not a valid answer.\n" >&2 + exit 1 + ;; *) ./neko/update/native.sh "$@" ;;