Repository navigation
Give matches after -, ., /, \ and any whitespace the separator bonus [minor] - #108
Merged
Merged
Conversation
…[minor] Only '_' and a space counted as separators, so a match that starts a path segment, a kebab-case word or a dotted name scored like one buried mid-word: "domain.cs" outranked "src/main.cs" for "main". Treat whitespace plus the common identifier and path separators as word boundaries. Fixes #92 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JGKBe8wvU3P6jYj9MkNC69
|
This was referenced Oct 6, 2026
This was referenced Oct 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Fixes #92
What changed
CalculateScoreCoredecided separators inline withstrChar is '_' or ' '. It now calls a newFuzzy.IsSeparator(char), which returns true for any whitespace and for_,-,.,/and\.matchAfterSeparatorBonus. As a resultdomain.csoutrankedsrc/main.csformain, andgetlistoutrankedget-listforlist.matchAfterSeparatorBonusXML doc, the README scoring table andCLAUDE.mdto list the new separator set.Tests
Score("src/main.cs","main") > Score("domain.cs","main")Score("get-list","list") > Score("getlist","list")src-main.cs,src.main.cs,src/main.cs,src\main.cs,src<TAB>main.csandsrc main.cseach score the same assrc_main.cs, which also covers the tab criterionIsSeparatorcases for separator and non-separator charactersIsSeparatorreverted to'_' or ' ', the new tests fail. With the change in place, all 94 tests pass. No existing test needed to change.dotnet build -c Releasesucceeds with no warnings.🤖 Generated with Claude Code
https://claude.ai/code/session_01JGKBe8wvU3P6jYj9MkNC69
Generated by Claude Code