[BUG] ripgrep follows gitignore, it should not

Status Open
Reported on v2.1.285
Maintainer reply None cached
Activity 0 comments · opened Sep 30, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

In Claude Code, ripgrep is used for file indexing, but it follows .gitigore by default unless it is passed with the flag "--no-ignore" or at least "no-ignore-vcs".

What Should Happen?

My argument is that Claude Code file indexing should not depend on gitignore.

My current workaround is to have a separate rgignore to include all files "!*" so that Claude code file indexing works.

Error Messages/Logs

Steps to Reproduce

Have a gitignore file containing "*" to exclude everything in the current working directory, and then use Claude Code's file picker (@) to search for files.

Claude Model

_No response_

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.285

Platform

Anthropic API

Operating System

Other Linux

Terminal/Shell

VS Code integrated terminal

Additional Information

_No response_

View original on GitHub ↗