FIX:修复Gemini_base_url 不能自定义

This commit is contained in:
jayNuc
2025-10-15 10:20:00 +08:00
parent e5443d1776
commit 1474e6c64b

6
.claude/scripts/gemini-wrapper Normal file → Executable file
View File

@@ -52,6 +52,12 @@ GREEN='\033[0;32m'
YELLOW='\033[1;33m'
NC='\033[0m' # No Color
# Respect custom Gemini base URL
if [[ -n "$GOOGLE_GEMINI_BASE_URL" ]]; then
echo -e "${GREEN}🌐 Using custom Gemini base URL: $GOOGLE_GEMINI_BASE_URL${NC}" >&2
export GOOGLE_GEMINI_BASE_URL
fi
# Function to count tokens (approximate: chars/4) - optimized version
count_tokens() {
local total_chars=0