{"repo":"sahilm/fuzzy","free":true,"listed":false,"github":"https://github.com/sahilm/fuzzy","clone":"git clone https://github.com/sahilm/fuzzy.git","description":"Go library that provides fuzzy string matching optimized for filenames and code symbols in the style of Sublime Text, VSCode, IntelliJ IDEA et al.","language":"Go","stars":1443,"topics":["fuzzy-search","golang","go","fuzzyfinder","fuzzy"],"license":"MIT","category":"dev-tools","readme_excerpt":"fuzzy Go library that provides fuzzy string matching optimized for filenames and code symbols in the style of Sublime Text, VSCode, IntelliJ IDEA et al. This library is external dependency-free. It only depends on the Go standard library. Features - Intuitive matching. Results are returned in descending order of match quality. Quality is determined by: - The first character in the pattern matches the first character in the match string. - The matched character is camel cased. - The matched character follows a separator such as an underscore character. - The matched character is adjacent to a previous match. - Speed. Matches are returned in milliseconds. It's perfect for interactive search boxes. - The positions of matches are returned. Allows you to highlight matching characters. - Unicode aware. Demo Here is a demo of matching various patterns against 16K files from the Unreal Engine 4 codebase. You can run the demo yourself like so: Usage The following example prints out matches with the matched chars in bold. If the data you want to match isn't a slice of strings, you can use FindFrom by implementing the provided Source interface. Here's an example: If your data is produced lazily, you can use FindFromIter to match against a Go iterator ( iter.Seq[string] ) instead of a Source . Results are sorted by match quality by default. Each function has a NoSort variant that skips sorting: FindNoSort , FindFromNoSort , and FindFromIterNoSort . Check out the godoc for detailed docume","default_branch":null,"files":null,"tree":[],"storefront":"/r/sahilm","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/sahilm/fuzzy/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}