# ========================================== # Claude Code Rust 环境变量配置示例 # ========================================== # 复制此文件为 .env 并填入你的实际值 # ========================================== # API 配置 - 方式1:Anthropic (推荐) # ========================================== ANTHROPIC_API_KEY=sk-ant-your-api-key-here API_BASE_URL=https://api.anthropic.com # ========================================== # API 配置 - 方式2:阿里云 DashScope # ========================================== # DASHSCOPE_API_KEY=sk-your-dashscope-key-here # API_BASE_URL=https://coding.dashscope.aliyuncs.com/v1 # ========================================== # 模型配置 # ========================================== # 可用模型: claude-opus, claude-sonnet, claude-haiku CLAUDE_MODEL=claude-3-5-sonnet-20241022 # ========================================== # 日志配置 # ========================================== # 日志级别: debug, info, warn, error RUST_LOG=claude_code=info # ========================================== # 代理配置(可选) # ========================================== # HTTP_PROXY=http://proxy.example.com:8080 # HTTPS_PROXY=https://proxy.example.com:8080 # ========================================== # 配置目录(可选) # ========================================== # XDG_CONFIG_HOME=~/.config # ========================================== # Docker 使用时的环境变量示例 # ========================================== # docker run --env-file .env -it claude-code-rust repl