claude - windows | linux 国内镜像安装
文章目录安装claudewindows1.首先安装node, 进入这个网址https://nodejs.org/en/download/2.安装github windows桌面版3.下载claude4.设置settings.json文件linux1.首先安装node, 进入这个网址https://nodejs.org/en/download/2.下载git3.安装claude:4.设置settings.json文件安装claude安装顺序 nvm|node - git - claude - settings.json基础设置windows1.首先安装node, 进入这个网址https://nodejs.org/en/download/下载windows Installer.msi文件进行安装2.安装github windows桌面版https://desktop.github.com/download/进入该网址下载windows 64bit安装3.下载claude打开windows powershell,使用国内镜像安装npm i -g anthropic-ai/claude-code --registryhttps://registry.npmmirror.com3.1设置运行路径在上图中可以看到 C:\Users\Administrator. local\bin 不在PATH中因此将 C:\Users\Administrator. local\bin 设置到系统路径里面。windows键 - 系统变量 - 编辑系统变量 - 将C:\Users\Administrator. local\bin复制到 PATH3.2 另外打开一个powershell:运行claude查看是否已经正常安装claude --version4.设置settings.json文件打开windows上的对应的user/.claude比如我的在“C:\Users\caisn\.claude”配置基础信息{ env: { ANTHROPIC_AUTH_TOKEN: 换成自己的, ANTHROPIC_BASE_URL: 换成自己的, API_TIMEOUT_MS: 3000000, CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC: 1 }, model: deepseek-v4-pro, enabledPlugins: { document-skillsanthropic-agent-skills: true, example-skillsanthropic-agent-skills: true, superpowersclaude-plugins-official: false, claude-scientific-writerclaude-scientific-writer: true }, extraKnownMarketplaces: { anthropic-agent-skills: { source: { source: github, repo: anthropics/skills } }, claude-scientific-writer: { source: { source: git, url: https://github.com/K-Dense-AI/claude-scientific-writer.git } } }, autoUpdatesChannel: latest, ENABLE_TOOL_SEARCH: true }安装完毕可以正常使用啦linux1.首先安装node, 进入这个网址https://nodejs.org/en/download/按照注意将上面的下载指令设置成自己需要的环境比如设置成linux、使用ubuntu v24.18.0 LTS环境进行下载的话使用nvm进行下载并同时下载npm那么得到了下面的指令# Download and install nvm: curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.5/install.sh | bash # in lieu of restarting the shell \. $HOME/.nvm/nvm.sh # Download and install Node.js: nvm install 24 # Verify the Node.js version: node -v # Should print v24.18.0. # Verify npm version: npm -v # Should print 11.16.0.将这些命令复制到linux上运行等待安装完毕。2.下载gitsudo apt update sudo apt upgrade sudo apt install git3.安装claude:# 使用国内镜像安装 REGISTRYhttps://registry.npmmirror.com npm i -g anthropic-ai/claude-code --registry$REGISTRY查看是否安装完成. ~/.bashrc claude --version4.设置settings.json文件vim ~/.claude/settings.json配置基础信息{ env: { ANTHROPIC_AUTH_TOKEN: 换成自己的, ANTHROPIC_BASE_URL: 换成自己的, API_TIMEOUT_MS: 3000000, CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC: 1 }, model: deepseek-v4-pro, enabledPlugins: { document-skillsanthropic-agent-skills: true, example-skillsanthropic-agent-skills: true, superpowersclaude-plugins-official: false, claude-scientific-writerclaude-scientific-writer: true }, extraKnownMarketplaces: { anthropic-agent-skills: { source: { source: github, repo: anthropics/skills } }, claude-scientific-writer: { source: { source: git, url: https://github.com/K-Dense-AI/claude-scientific-writer.git } } }, autoUpdatesChannel: latest, ENABLE_TOOL_SEARCH: true }好啦可以开始使用啦