Skip to content

Claude Code与Open Code使用总结

About 584 wordsAbout 2 min

2026-02-04

一、Claude Code

1、安装方式有三种,一种是下载脚本执行,一种是homebrew, 一种是通过npm

Claude Code 下载安装教程(Mac 版),图文指南

如果地区不支持,挂梯子,并设置

HTTP_PROXY=http://127.0.0.1:7890 HTTPS_PROXY=http://127.0.0.1:7890 claude

7890是你的梯子的代理端口。

git config --global --get http.proxy
git config --global --get https.proxy

查看git的代理信息。

Claude Code Doc

快捷导航

免费白嫖 Claude Code,国内也能免费使用(保姆级教程)

DeepSeek 官网

DeepSeek Api文档

poe 连接claude code

Poe 官网

Poe Doc

使用Ctrl+Alt+S快捷键打开idea全局配置,在快捷键映射配置Settings -> keymap中,找到 Plug-ins -> Terminal -> Switch Focus To Editor,删除其快捷键绑定即可。

# Set these in your shell (e.g., ~/.bashrc, ~/.zshrc)
export POE_API_KEY="api key"
export ANTHROPIC_BASE_URL="https://api.poe.com"
export ANTHROPIC_AUTH_TOKEN="$POE_API_KEY"
export ANTHROPIC_API_KEY="" # Important: Must be explicitly empty

anyrouter url

二、Open Code

需要node v20+

Oh My Open Code 插件

通过4种方式安装opencode, 在命令行中使用npm安装:npm i -g opencode-ai,删除npm uninstall -g opencode-ai

需要安装这个插件,才能使用gemini

NoeFabris/opencode-antigravity-auth

然后让LLM帮我安装上面的插件:

Install the opencode-antigravity-auth plugin and add the Antigravity model definitions to ~/.config/opencode/opencode.json by following: https://raw.githubusercontent.com/NoeFabris/opencode-antigravity-auth/dev/README.md

安装之后,会在opencode.json里面的plugin里面添加一行"opencode-antigravity-auth@beta", 但是我后面注释掉了,不注释调启动不了opencode。

code-yeongyu/oh-my-opencode

npx oh-my-opencode install(我没有安装成功,找到安装使用LLM帮忙安装)

都选择no

npm install -g oh-my-opencode@latest

还是使用LLM帮忙安装

Install and configure oh-my-opencode by following the instructions here:
https://raw.githubusercontent.com/code-yeongyu/oh-my-opencode/refs/heads/master/docs/guide/installation.md
# 安装 Bun(若未安装)
curl -fsSL https://bun.sh/install | bash
# 安装 Oh My OpenCode(示例:启用 Claude 与 ChatGPT)
bunx oh-my-opencode install --no-tui --claude=no --chatgpt=no --gemini=no

问题:当opencode 添加插件之后,就打不开opencode了,例如:

{
  "plugin": ["oh-my-opencode@3.4.0"]
}

cursor集成opencode

打开命令模式快捷键: F1或者是Cmd + Shift + P, 搜索opencode in new tab

进入之后然后/init,会生成一个项目的agent价格文件,是md的文件

/themes 主题

/models 切换模型

/init 初始化生成agent文件

求求了,快滚去学习!!!

求求了求求了,快去学习吧!

【LeetCode】贪心算法
【LeetBook】数组和字符串

不知道方向的时候,可以多看看书,书会给你指明下一步该干什么,加油!