mirror of
https://github.com/nix-community/nixvim.git
synced 2025-07-09 08:44:32 +02:00
Some checks are pending
Publish every Git push to main to FlakeHub / flakehub-publish (push) Waiting to run
Publish every git push to Flakestry / publish-flake (push) Waiting to run
Documentation / Version info (push) Waiting to run
Documentation / Build (push) Blocked by required conditions
Documentation / Combine builds (push) Blocked by required conditions
Documentation / Deploy (push) Blocked by required conditions
Add support for [telescope-zf-native.nvim](https://github.com/natecraddock/telescope-zf-native.nvim), providing native telescope bindings to zf for sorting results .
72 lines
1.9 KiB
Nix
72 lines
1.9 KiB
Nix
{ lib, ... }:
|
|
let
|
|
inherit (lib.nixvim) defaultNullOpts;
|
|
mkExtension = import ./_mk-extension.nix;
|
|
in
|
|
mkExtension {
|
|
name = "zf-native";
|
|
extensionName = "zf-native";
|
|
package = "telescope-zf-native-nvim";
|
|
|
|
settingsOptions = {
|
|
file = {
|
|
enable = defaultNullOpts.mkBool true ''
|
|
Override default telescope file sorter.
|
|
'';
|
|
highlight_results = defaultNullOpts.mkBool true ''
|
|
Highlight matching text in results.
|
|
'';
|
|
match_filename = defaultNullOpts.mkBool true ''
|
|
Enable zf filename match priority.
|
|
'';
|
|
initial_sort = defaultNullOpts.mkBool null ''
|
|
Optional function to define a sort order when the query is empty.
|
|
'';
|
|
smart_case = defaultNullOpts.mkBool true ''
|
|
Set to false to enable case sensitive matching.
|
|
'';
|
|
};
|
|
|
|
generic = {
|
|
enable = defaultNullOpts.mkBool true ''
|
|
Override default telescope generic item sorter.
|
|
'';
|
|
highlight_results = defaultNullOpts.mkBool true ''
|
|
Highlight matching text in results.
|
|
'';
|
|
match_filename = defaultNullOpts.mkBool false ''
|
|
Disable zf filename match priority.
|
|
'';
|
|
initial_sort = defaultNullOpts.mkBool null ''
|
|
Optional function to define a sort order when the query is empty.
|
|
'';
|
|
smart_case = defaultNullOpts.mkBool true ''
|
|
Set to false to enable case sensitive matching.
|
|
'';
|
|
};
|
|
};
|
|
|
|
settingsExample = {
|
|
file = {
|
|
enable = true;
|
|
highlight_results = true;
|
|
match_filename = true;
|
|
initial_sort = null;
|
|
smart_case = true;
|
|
};
|
|
generic = {
|
|
enable = true;
|
|
highlight_results = true;
|
|
match_filename = false;
|
|
initial_sort = null;
|
|
smart_case = true;
|
|
};
|
|
};
|
|
|
|
dependencies = [ "zf" ];
|
|
|
|
extraConfig = cfg: {
|
|
# zf-native shared binaries
|
|
performance.combinePlugins.pathsToLink = [ "/lib" ];
|
|
};
|
|
}
|