summaryrefslogtreecommitdiff
path: root/lua
diff options
context:
space:
mode:
Diffstat (limited to 'lua')
-rw-r--r--lua/telescope/sorters.lua13
1 files changed, 13 insertions, 0 deletions
diff --git a/lua/telescope/sorters.lua b/lua/telescope/sorters.lua
index 7a15325..1ac410f 100644
--- a/lua/telescope/sorters.lua
+++ b/lua/telescope/sorters.lua
@@ -407,6 +407,19 @@ sorters.get_fzy_sorter = function(opts)
}
end
+sorters.highlighter_only = function(opts)
+ opts = opts or {}
+ local fzy = opts.fzy_mod or require('telescope.algos.fzy')
+
+ return Sorter:new {
+ scoring_function = function() return 0 end,
+
+ highlighter = function(_, prompt, display)
+ return fzy.positions(prompt, display)
+ end,
+ }
+end
+
-- Bad & Dumb Sorter
sorters.get_levenshtein_sorter = function()
return Sorter:new {