Create

Sign in to ReadmeX

or

How we handle your data: Privacy Policy

ReadmeX

Your AI reading companion

What would you like to catch up on?

Pick a briefing, or ask your own question.

Your community and people briefings stay personal to you.

Story

Three Windows Pitfalls When Configuring MCP in Claude Code

AI summary

A Juejin author reproduced three MCP connection problems with Claude Code 2.1.318 on Windows 11 while testing the official @modelcontextprotocol/server-filesystem package. The workarounds are quoting “--” in Windows PowerShell 5.1, avoiding Git Bash path conversion of “cmd /c,” and placing a newer Node.js directory first in PATH for a specific MCP server. The author recommends running “claude mcp list” to compare the effective command with the entered command and check whether each service is connected.

In-depth insight

The report provides concrete troubleshooting steps for a common Claude Code setup problem, although the results come from one author’s Windows environment and PowerShell 7 was not tested.

网上的 Claude Code + MCP 教程很多,但我在 Windows 上照着做,好几次都卡在"命令明明一样,就是连不上",这是最让人绝望的,每个字母都认真核对后都还是不行。下面三个坑是我这两天在自己电脑上一个个复现出来的,每个都给出能直接用的解决办法。 先说结论:Windows PowerShell 像一坨屎

测试环境:Windows 11,Claude Code 2.1.318,Node.js 26 / 20.20.2,系统自带的 Windows PowerShell 5.1,Git Bash。测试用的 MCP 是官方的 @modelcontextprotocol/server-filesystem。

先说一个通用的排查办法:配完之后跑一下

claude mcp list

每个服务后面会显示 ✔ Connected 或 ✘ Failed to connect。重点看它显示的那条命令和你输入的是不是一样——下面第 2 个坑就是靠这个发现的。


坑 1:PowerShell 里 -- 被"吃掉",报 unknown option '-y'

教程里的标准写法:

#Claude Code#@modelcontextprotocol/server-filesystem#Node.js#Windows PowerShell 5.1#Git Bash

Original · 3 min readRead the original
Group chat

No comments yet. Start the conversation.