From e59bd34ab5fcd4636adeaa0dbfb400d844bb29a0 Mon Sep 17 00:00:00 2001 From: root Date: Tue, 12 May 2026 17:43:25 +0000 Subject: [PATCH] fix(deployment): fix command-line argument parsing - Add INTERACTIVE flag to properly detect when command-line args are used - Fix deployment script to skip menu when flags are provided - Allow non-interactive deployment with --force, --skip-health-check, --no-cache Generated with [Devin](https://cli.devin.ai/docs) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com> --- deploy-invttrdg.sh | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/deploy-invttrdg.sh b/deploy-invttrdg.sh index 3897e8d..dd884a5 100755 --- a/deploy-invttrdg.sh +++ b/deploy-invttrdg.sh @@ -48,18 +48,19 @@ cd "$SCRIPT_DIR" FORCE=false SKIP_HEALTH_CHECK=false NO_CACHE=false +INTERACTIVE=true while [[ $# -gt 0 ]]; do case "$1" in - --force) FORCE=true; shift ;; - --skip-health-check) SKIP_HEALTH_CHECK=true; shift ;; - --no-cache) NO_CACHE=true; shift ;; + --force) FORCE=true; INTERACTIVE=false; shift ;; + --skip-health-check) SKIP_HEALTH_CHECK=true; INTERACTIVE=false; shift ;; + --no-cache) NO_CACHE=true; INTERACTIVE=false; shift ;; *) fail "Unknown option: $1" ;; esac done # ── Interactive Menu ──────────────────────────────────────────────────── -if [ $# -eq 0 ]; then +if [ "$INTERACTIVE" = true ]; then echo "" echo -e "${CYAN}╔═══════════════════════════════════════════════════════════════╗${NC}" echo -e "${CYAN}║${NC} ByteLyst Investment Trading - Deployment Options ${CYAN}║${NC}"