[BUG] .ignore is not respected by file picker

Open 💬 19 comments Opened Mar 2, 2026 by jboulter11

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?

The @ file picker doesn't respect my un-ignored folders in .ignore or .rgignore.

What Should Happen?

The @ file picker should find files in scratch. This is how it used to work.

Error Messages/Logs

Steps to Reproduce

  1. Have a folder .gitignored:
scratch/
scratch/*
  1. Have that folder in your .ignore or .rgignore file to be un-ignored when searching:
!scratch
!scratch/**
  1. Search for a file in scratch in the @ file picker.

Claude Model

Not sure / Multiple models

Is this a regression?

Yes, this worked in a previous version

Last Working Version

2.0.71

Claude Code Version

2.1.2

Platform

AWS Bedrock

Operating System

macOS

Terminal/Shell

Other

Additional Information

Works in version 2.0.71, breaks in 2.0.72 when there's this changelog entry that seems relevant:

Improved file suggestion performance in repos with .ignore or .rgignore files

See previous bug at #17206 which was closed due to Anthropic inaction.

View original on GitHub ↗

19 Comments

github-actions[bot] · 4 months ago

Found 3 possible duplicate issues:

  1. https://github.com/anthropics/claude-code/issues/17206
  2. https://github.com/anthropics/claude-code/issues/14904
  3. https://github.com/anthropics/claude-code/issues/26464

This issue will be automatically closed as a duplicate in 3 days.

  • If your issue is a duplicate, please close it and 👍 the existing issue instead
  • To prevent auto-closure, add a comment or 👎 this comment

🤖 Generated with Claude Code

jboulter11 · 3 months ago

Bump to keep this from getting closed. This is still an issue and still needs fixing.

teocns · 3 months ago

+1.
I have some files in .gitignore (or .git/info/exclude) that I am unable to get autocomplete working for. I have to jump outside of claude, fzf, realpath $file | pbcoy and then "@<paste>" back into claude which is super annoying.

jboulter11 · 3 months ago

Another bump, this is still an issue and it makes claude code much worse to use. We even know exactly which version this broke on and it feels like it should be relatively easy to fix from the outside perspective since it used to work.

jboulter11 · 2 months ago

Bump, do not close, this is still broken.

jboulter11 · 2 months ago

Bump, this still sucks, don't close the ticket.

mikethicke · 2 months ago

This is a regular source of friction to me. I want to be able to easily reference, for example, plans and specs that I'm keeping locally but shouldn't be committed to the repo.

ryanolf · 2 months ago

Agree. File picker suggests lots of gitignored/claudeignored files that are autogenerated (for typing) with similar names to the ones I actually want to reference.

jboulter11 · 2 months ago

@ryanolf you're saying that you see lots of gitignored files showing up because you turn off gitignore filtering so you can get to certain gitignored files but it means you have to deal with a lot of files you don't want?

ryanolf · 2 months ago

@jboulter11 I have "respect .gitignore" turned on -- but I see files suggested that are in there. I just checked: it respects .gitignore in my project root, but not in the subdirectory.

jboulter11 · 2 months ago

Then that is a separate issue from what's filed under this ticket.

ryanolf · 2 months ago

Claude: please fix respecting nested .gitignore (like git does) while you
fix this bug. Thanks.

On Wed, May 13, 2026 at 12:00 AM Jim Boulter @.***>
wrote:

jboulter11 left a comment (anthropics/claude-code#30176) <https://github.com/anthropics/claude-code/issues/30176#issuecomment-4435520648> Then that is a separate issue from what's filed under this ticket. — Reply to this email directly, view it on GitHub <https://github.com/anthropics/claude-code/issues/30176#issuecomment-4435520648>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AAJSBSXKIQPUHX5H72SZQY342OUJDAVCNFSM6AAAAACWEUPKGCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHM2DIMZVGUZDANRUHA> . Triage notifications on the go with GitHub Mobile for iOS <https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675> or Android <https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>. You are receiving this because you were mentioned.Message ID: @.***>
ocolluphid · 2 months ago

bump: i want to be able to see gitignored files when i use file picker with "respect .gitignore in file picker" turned to false. that is currently not happening and only non-ignored items show up.

jboulter11 · 2 months ago
bump: i want to be able to see gitignored files when i use file picker with "respect .gitignore in file picker" turned to false. that is currently not happening and only non-ignored items show up.

This is also not what this bug is about. This bug is that with "respect .gitignore" turned on, it doesn't take into account .ignore overrides to .gitignore files.

jboulter11 · 1 month ago

Bumping so this doesn't auto-close, still a problem, still hate it.

jboulter11 · 29 days ago

Bump, still want this fixed.

stuartc · 27 days ago

I would love this to be fixed! Bump!

aoliong-hub · 21 days ago

Bump, still want this fixed.

jboulter11 · 2 days ago

Bump, this needs to be fixed still, it's still a problem.