mirror of
https://github.com/NotAShelf/neovim-flake.git
synced 2024-12-27 02:49:47 +01:00
47 lines
993 B
Nix
47 lines
993 B
Nix
|
{
|
||
|
pkgs,
|
||
|
lib,
|
||
|
config,
|
||
|
...
|
||
|
}:
|
||
|
with lib;
|
||
|
with builtins; let
|
||
|
cfg = config.vim.autopairs;
|
||
|
in {
|
||
|
options.vim = {
|
||
|
autopairs = {
|
||
|
enable = mkOption {
|
||
|
type = types.bool;
|
||
|
default = false;
|
||
|
description = "enable autopairs";
|
||
|
};
|
||
|
|
||
|
type = mkOption {
|
||
|
type = types.enum ["nvim-autopairs"];
|
||
|
default = "nvim-autopairs";
|
||
|
description = "Set the autopairs type. Options: nvim-autopairs [nvim-autopairs]";
|
||
|
};
|
||
|
|
||
|
nvim-compe = {
|
||
|
map_cr = mkOption {
|
||
|
type = types.bool;
|
||
|
default = true;
|
||
|
description = "map <CR> on insert mode";
|
||
|
};
|
||
|
|
||
|
map_complete = mkOption {
|
||
|
type = types.bool;
|
||
|
default = true;
|
||
|
description = "auto insert `(` after select function or method item";
|
||
|
};
|
||
|
|
||
|
auto_select = mkOption {
|
||
|
type = types.bool;
|
||
|
default = false;
|
||
|
description = "auto select first item";
|
||
|
};
|
||
|
};
|
||
|
};
|
||
|
};
|
||
|
}
|