nix-community.nixvim/plugins/by-name/cmp-tabby/default.nix

51 lines
1 KiB
Nix
Raw Normal View History

2024-12-18 18:42:03 +01:00
{ lib, ... }:
let
inherit (lib) types;
inherit (lib.nixvim) defaultNullOpts;
in
2024-12-22 09:58:27 +00:00
lib.nixvim.plugins.mkNeovimPlugin {
2024-12-18 18:42:03 +01:00
name = "cmp-tabby";
maintainers = [ lib.maintainers.GaetanLepage ];
imports = [
{ cmpSourcePlugins.cmp_tabby = "cmp-tabby"; }
];
deprecateExtraOptions = true;
optionsRenamedToSettings = [
"host"
"maxLines"
"runOnEveryKeyStroke"
"stop"
];
moduleName = "cmp_tabby.config";
setup = ":setup";
settingsOptions = {
host = defaultNullOpts.mkStr "http://localhost:5000" ''
The address of the tabby host server.
'';
max_lines = defaultNullOpts.mkUnsignedInt 100 ''
The max number of lines to complete.
'';
run_on_every_keystroke = defaultNullOpts.mkBool true ''
Whether to run the completion on every keystroke.
'';
stop = defaultNullOpts.mkListOf types.str [ "\n" ] ''
Stop character.
'';
};
settingsExample = {
host = "http://localhost:5000";
max_lines = 100;
run_on_every_keystroke = true;
stop = [ "\n" ];
};
}