From 66947e7005d28eb26d6aa6bbf2e33a7a6921ff66 Mon Sep 17 00:00:00 2001 From: Dawen Ren Date: Mon, 2 Feb 2026 04:28:26 +0800 Subject: [PATCH] fix: update ralph_import.sh (#148) Fix ralph_import.sh CLI detection: - Replace npx @anthropic/claude-code check with CLAUDE_CODE_CMD variable - Quote CLAUDE_CODE_CMD to prevent shell expansion issues - Add jq dependency check with installation guidance --- ralph_import.sh | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/ralph_import.sh b/ralph_import.sh index eb98e64..13a2f4b 100755 --- a/ralph_import.sh +++ b/ralph_import.sh @@ -273,9 +273,13 @@ check_dependencies() { log "ERROR" "Ralph not installed. Run ./install.sh first" exit 1 fi - - if ! npx @anthropic/claude-code --version &> /dev/null 2>&1; then - log "WARN" "Claude Code CLI not found. It will be downloaded when first used." + + if ! command -v jq &> /dev/null; then + log "WARN" "jq not found. Install it (brew install jq | sudo apt-get install jq | choco install jq) for faster JSON parsing." + fi + + if ! command -v "$CLAUDE_CODE_CMD" &> /dev/null 2>&1; then + log "WARN" "Claude Code CLI ($CLAUDE_CODE_CMD) not found. It will be downloaded when first used." fi }