fix: 修正灵眸模式下 API Key 警告误报
ANTHROPIC_AUTH_TOKEN 不为空时不再显示警告 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -734,7 +734,9 @@ Write-Host ""
|
|||||||
Write-Host " 4) 在 Claude Code (WSL2) 中使用:" -ForegroundColor White
|
Write-Host " 4) 在 Claude Code (WSL2) 中使用:" -ForegroundColor White
|
||||||
Write-Host " claude-wsl → claude → /mcp" -ForegroundColor DarkGray
|
Write-Host " claude-wsl → claude → /mcp" -ForegroundColor DarkGray
|
||||||
Write-Host ""
|
Write-Host ""
|
||||||
if (-not $ANTHROPIC_API_KEY) {
|
if (-not $ANTHROPIC_API_KEY -and -not $ANTHROPIC_AUTH_TOKEN) {
|
||||||
Write-Warn " ⚠ 未设置 ANTHROPIC_API_KEY,请编辑 .env 后重新运行"
|
Write-Warn " ⚠ 未设置 API Key,请编辑 .env 后重新运行"
|
||||||
|
Write-Warn " 灵眸用户:填写 ANTHROPIC_AUTH_TOKEN=sk-xxx"
|
||||||
|
Write-Warn " 官方用户:填写 ANTHROPIC_API_KEY=sk-xxx"
|
||||||
}
|
}
|
||||||
Write-Host "╚══════════════════════════════════════════════════════════════╝" -ForegroundColor Green
|
Write-Host "╚══════════════════════════════════════════════════════════════╝" -ForegroundColor Green
|
||||||
|
|||||||
Reference in New Issue
Block a user