claude-code - 💡(How to fix) Fix Case-insensitive file mention matching with @ [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#46137Fetched 2026-04-11 06:28:06
View on GitHub
Comments
1
Participants
2
Timeline
3
Reactions
0
Timeline (top)
labeled ×2commented ×1
RAW_BUFFERClick to expand / collapse

Feature Request

When typing @ to mention a file in the Claude Code terminal, suggestions are currently case-sensitive. This means users must type the exact casing (e.g. ItemListView) to get the correct file suggestion.

Expected Behavior

File suggestions should match case-insensitively, so typing itemlistview or itemlistView would still surface ItemListView.swift.

Why

In Swift/iOS projects, files are typically named in PascalCase (e.g. FAProductSelectionDelegate.swift, ItemListViewModel.swift). Requiring exact casing slows down the workflow when mentioning files in prompts.

Suggested Solution

Add a setting (e.g. fileSearch.caseSensitive: false) to allow users to opt into case-insensitive @ file mention matching.

extent analysis

TL;DR

Implementing a case-insensitive file suggestion matching feature by adding a setting to opt into this behavior is likely the most straightforward fix.

Guidance

  • Review the current implementation of the file suggestion algorithm to understand how case sensitivity is currently enforced.
  • Consider adding a configuration option, such as fileSearch.caseSensitive, to allow users to toggle between case-sensitive and case-insensitive matching.
  • When implementing case-insensitive matching, ensure that the comparison is done in a way that is consistent with the user's expectations, such as using a case-folded comparison.
  • Test the new feature with various file names and casing scenarios to ensure it works as expected.

Example

// Example of case-insensitive string comparison in Swift
let fileName = "ItemListView.swift"
let userInput = "itemlistview"

if fileName.caseInsensitiveCompare(userInput) == .orderedSame {
    // Match found
}

Notes

The implementation details may vary depending on the programming language and framework used in the Claude Code terminal. This guidance assumes a Swift-based implementation.

Recommendation

Apply workaround by implementing the suggested fileSearch.caseSensitive setting, allowing users to opt into case-insensitive matching, as this provides the most flexibility and control over the feature's behavior.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING