loading…
Search for a command to run...
loading…
Standalone MCP filesystem server fork with opt-in ignore-file filtering for listing, traversal, and search.
Standalone MCP filesystem server fork with opt-in ignore-file filtering for listing, traversal, and search.
@neonlightdev/mcp-server-filesystem-ignore is a standalone repository and npm package derived from the official Model Context Protocol filesystem server in modelcontextprotocol/servers.
This fork keeps the upstream filesystem server behavior by default, then adds opt-in ignore-file filtering for:
list_directorylist_directory_with_sizesdirectory_treesearch_filesThe goal is to make developer workspaces less noisy without changing tool contracts or silently introducing default exclusions.
.gitignore, .cursorignore, .mcpignore, .claudeignore, and custom user-defined files.src/filesystem0.6.3f4244583a6af9425633e433a3eec000d23f4e011See UPSTREAM.md for the recorded baseline and future sync workflow.
npm install -g @neonlightdev/mcp-server-filesystem-ignore
You can also run it without a global install:
npx -y @neonlightdev/mcp-server-filesystem-ignore /absolute/project/path
Run the server with one or more allowed directories:
npx -y @neonlightdev/mcp-server-filesystem-ignore /absolute/project/path
Use MCP roots as usual if your client supports them. Ignore support remains opt-in; if you do not pass ignore-related flags, listing, traversal, and search behave like the upstream filesystem server.
Use absolute paths in MCP client configs. Relative paths are a common source of startup failures in desktop clients.
Msty Studio's Toolbox JSON import expects the server object itself, not the outer mcpServers wrapper.
{
"command": "npx",
"args": [
"-y",
"@neonlightdev/mcp-server-filesystem-ignore",
"--respect-gitignore",
"--ignore-file",
".cursorignore",
"/ABSOLUTE/PROJECT/PATH"
]
}
Example with multiple ignore files:
{
"command": "npx",
"args": [
"-y",
"@neonlightdev/mcp-server-filesystem-ignore",
"--ignore-file",
".gitignore",
"--ignore-file",
".cursorignore",
"--ignore-file",
"/ABSOLUTE/PATH/TO/custom.ignore",
"/ABSOLUTE/PROJECT/PATH"
]
}
Note: MCP support is in Msty Studio. The older Msty App 1.x docs explicitly note that MCP support is not available there.
settings.jsonGemini CLI uses an mcpServers object in ~/.gemini/settings.json or .gemini/settings.json.
{
"mcpServers": {
"filesystem-ignore": {
"command": "npx",
"args": [
"-y",
"@neonlightdev/mcp-server-filesystem-ignore",
"--respect-gitignore",
"/ABSOLUTE/PROJECT/PATH"
],
"trust": true
}
}
}
Gemini CLI example with multiple ignore files:
{
"mcpServers": {
"filesystem-ignore": {
"command": "npx",
"args": [
"-y",
"@neonlightdev/mcp-server-filesystem-ignore",
"--ignore-file",
".gitignore",
"--ignore-file",
".cursorignore",
"--ignore-file",
".mcpignore",
"/ABSOLUTE/PROJECT/PATH"
],
"trust": true
}
}
}
mcpServersSeveral MCP hosts use the same mcpServers JSON shape. If your client expects a full config block, this is the safest starting point:
{
"mcpServers": {
"filesystem-ignore": {
"command": "npx",
"args": [
"-y",
"@neonlightdev/mcp-server-filesystem-ignore",
"--respect-gitignore",
"/ABSOLUTE/PROJECT/PATH"
]
}
}
}
Example with multiple ignore files:
{
"mcpServers": {
"filesystem-ignore": {
"command": "npx",
"args": [
"-y",
"@neonlightdev/mcp-server-filesystem-ignore",
"--ignore-file",
".gitignore",
"--ignore-file",
".cursorignore",
"--ignore-file",
"/ABSOLUTE/PATH/TO/custom.ignore",
"/ABSOLUTE/PROJECT/PATH"
]
}
}
}
If your client only asks for a server JSON payload rather than a full config file, copy just the inner object from the examples above.
--ignore-file <path-or-name>--respect-gitignore--Examples:
npx -y @neonlightdev/mcp-server-filesystem-ignore \
--ignore-file .gitignore \
/absolute/project/path
npx -y @neonlightdev/mcp-server-filesystem-ignore \
--ignore-file .gitignore \
--ignore-file .cursorignore \
/absolute/project/path
npx -y @neonlightdev/mcp-server-filesystem-ignore \
--ignore-file /absolute/path/to/custom.ignore \
/absolute/project/path
npx -y @neonlightdev/mcp-server-filesystem-ignore \
--respect-gitignore \
/absolute/project/path
--ignore-file Is Interpreted.gitignore, .cursorignore, .mcpignore, and .claudeignore are treated as discoverable ignore-file names./ or \\, are treated as explicit ignore files and resolved once at startup.excludePatterns for directory_tree and search_files remain hard exclusions and still apply after ignore-file matching.Ignore files use gitignore-style syntax through the ignore package, including:
node_modules/dist/**!dist/keep.txtHide common build and dependency directories from all supported browse/search operations:
npx -y @neonlightdev/mcp-server-filesystem-ignore \
--ignore-file .gitignore \
--ignore-file .cursorignore \
/absolute/project/path
Use a shared team-specific ignore file:
npx -y @neonlightdev/mcp-server-filesystem-ignore \
--ignore-file /absolute/team-configs/workspace.ignore \
/absolute/project/path
Pass a custom ignore file name that should be discovered throughout the workspace:
npx -y @neonlightdev/mcp-server-filesystem-ignore \
--ignore-file .mcpignore \
/absolute/project/path
.git/info/exclude and core.excludesFile are not read unless you pass those files explicitly.core.ignoreCase is not modeled.npm install
npm test
npm run build
package.json.@your-scope/mcp-server-filesystem-ignore.bin, repository, bugs, homepage, license, and files aligned with the final package identity.npm login.npm run build.npm pack --dry-run and confirm the tarball only contains dist plus the intended docs and license files.npm publish --access public.npm view @neonlightdev/mcp-server-filesystem-ignore version.Notes:
--access public unless your registry defaults already handle it.README.md.files field should stay intentionally small.This repo includes publish.yml for npm trusted publishing.
The workflow is currently pinned to actions/checkout@v6 and actions/setup-node@v6, which GitHub documents as Node 24-based releases. If you see a Node 20 deprecation warning again, it usually means an older workflow still references @v4 or @v5.
The workflow also upgrades npm explicitly before publish because npm trusted publishing requires a newer npm CLI than the GitHub runner image may provide by default.
Trusted Publisher section, choose GitHub Actions.publish.ymlnpm version patch
git push origin main --follow-tags
Or create the tag explicitly:
git tag v0.1.1
git push origin v0.1.1
The workflow will run npm ci, npm test, npm pack --dry-run, and then npm publish --access public.
Trusted publishing notes:
11.5.1 or later and Node 22.14.0 or higher.checkout and setup-node majors still run on Node 20 and trigger the deprecation warning.10.x, upgrade npm in the workflow before npm publish or trusted publishing may fail with a misleading registry error.This repo should be maintained with a replay-based subtree sync, not a literal git rebase onto the upstream monorepo.
git remote add upstream https://github.com/modelcontextprotocol/servers.git
git fetch upstream
git switch -c codex/upstream-sync-YYYYMMDD
src/filesystem against this repo root.Give the agent this workflow:
upstream/main.codex/upstream-sync-YYYYMMDD.src/filesystem with this repo root.npm run build and npm test.The agent should avoid destructive git commands and treat this repo as a subtree-derived fork, not as a full-history rebase target.
See CONTRIBUTING.md for development expectations and PR guidance.
Добавь это в claude_desktop_config.json и перезапусти Claude Desktop.
{
"mcpServers": {
"filesystem-ignore": {
"command": "npx",
"args": [
"-y",
"@neonlightdev/mcp-server-filesystem-ignore"
]
}
}
}