mirror of
https://github.com/nix-community/nixvim.git
synced 2025-07-02 21:34:33 +02:00
plugins/cmp-tabnine: move to by-name
This commit is contained in:
parent
79a637d196
commit
7aed1c4b57
4 changed files with 116 additions and 22 deletions
49
tests/test-sources/plugins/by-name/cmp-tabnine/default.nix
Normal file
49
tests/test-sources/plugins/by-name/cmp-tabnine/default.nix
Normal file
|
@ -0,0 +1,49 @@
|
|||
{ lib, pkgs, ... }:
|
||||
let
|
||||
platform = pkgs.stdenv.hostPlatform;
|
||||
|
||||
# tabnine is not available on aarch64-linux.
|
||||
doRun = !(platform.isLinux && platform.isAarch64);
|
||||
in
|
||||
lib.optionalAttrs doRun {
|
||||
empty = {
|
||||
plugins = {
|
||||
cmp.enable = true;
|
||||
cmp-tabnine.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
defaults = {
|
||||
plugins = {
|
||||
cmp.enable = true;
|
||||
cmp-tabnine = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
max_lines = 1000;
|
||||
max_num_results = 20;
|
||||
sort = true;
|
||||
run_on_every_keystroke = true;
|
||||
snippet_placeholder = "..";
|
||||
ignored_file_types = { };
|
||||
min_percent = 0;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
example = {
|
||||
plugins = {
|
||||
cmp.enable = true;
|
||||
cmp-tabnine = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
max_lines = 600;
|
||||
max_num_results = 10;
|
||||
sort = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue