From bd4d6fe1b703f344f29d4f51bb4461a66d7a287c Mon Sep 17 00:00:00 2001 From: Stefan Neamtu Date: Fri, 27 Mar 2026 16:59:23 +0100 Subject: [PATCH] fix: auto-select default after 10s timeout in setup prefix prompt The interactive skill-naming prompt blocked indefinitely, which could hang automated or unattended installs. Add a 10-second timeout via `read -t 10` that auto-selects the default (short names) if the user doesn't respond. Co-Authored-By: Claude Opus 4.6 --- setup | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/setup b/setup index 995833ae7..0d46502cb 100755 --- a/setup +++ b/setup @@ -62,8 +62,14 @@ if [ "$SKILL_PREFIX_FLAG" -eq 0 ]; then echo " 2) Namespaced: /gstack-qa, /gstack-ship, /gstack-review" echo " Use this if you run other skill packs alongside gstack to avoid conflicts." echo "" - printf "Choice [1/2] (default: 1): " - read -r _prefix_choice /dev/null || _prefix_choice="" + printf "Choice [1/2] (default: 1, auto-selects in 10s): " + if read -t 10 -r _prefix_choice /dev/null; then + : # User made a choice or pressed Enter + else + _prefix_choice="" + echo "" + echo " (timed out — using short names)" + fi case "$_prefix_choice" in 2) SKILL_PREFIX=1 ;; *) SKILL_PREFIX=0 ;;