mirror of
https://github.com/NotAShelf/neovim-flake.git
synced 2024-11-08 10:15:59 +01:00
utility/precognition: no more rec
This commit is contained in:
parent
0b647a209d
commit
39e27e17a2
1 changed files with 23 additions and 27 deletions
|
@ -1,8 +1,28 @@
|
||||||
{lib, ...}: let
|
{lib, ...}: let
|
||||||
inherit (lib.options) mkEnableOption mkOption literalExpression;
|
inherit (lib.options) mkEnableOption mkOption literalExpression;
|
||||||
inherit (lib.types) attrsOf listOf str bool int submodule;
|
inherit (lib.types) attrsOf listOf str bool int submodule;
|
||||||
|
|
||||||
|
mkHintType = description:
|
||||||
|
mkOption {
|
||||||
|
inherit description;
|
||||||
|
default = {};
|
||||||
|
type = attrsOf (submodule {
|
||||||
|
options = {
|
||||||
|
text = mkOption {
|
||||||
|
type = str;
|
||||||
|
description = "The easier-to-read depiction of the motion.";
|
||||||
|
};
|
||||||
|
prio = mkOption {
|
||||||
|
type = int;
|
||||||
|
description = "The priority of the hint.";
|
||||||
|
example = 10;
|
||||||
|
default = 1;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
});
|
||||||
|
};
|
||||||
in {
|
in {
|
||||||
options.vim.utility.motion.precognition = rec {
|
options.vim.utility.motion.precognition = {
|
||||||
enable = mkEnableOption "precognition.nvim plugin";
|
enable = mkEnableOption "precognition.nvim plugin";
|
||||||
|
|
||||||
startVisible = mkOption {
|
startVisible = mkOption {
|
||||||
|
@ -31,34 +51,10 @@ in {
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
hints = mkOption {
|
hints = mkHintType "What motions display and at what priority.";
|
||||||
default = {};
|
|
||||||
description = ''
|
|
||||||
What motions display and at what priority.";
|
|
||||||
'';
|
|
||||||
type = attrsOf (submodule {
|
|
||||||
options = {
|
|
||||||
text = mkOption {
|
|
||||||
type = str;
|
|
||||||
description = "The easier-to-read depiction of the motion.";
|
|
||||||
};
|
|
||||||
prio = mkOption {
|
|
||||||
type = int;
|
|
||||||
description = "The priority of the hint.";
|
|
||||||
example = 10;
|
|
||||||
default = 1;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
});
|
|
||||||
};
|
|
||||||
|
|
||||||
gutterHints =
|
gutterHints =
|
||||||
hints
|
mkHintType "What motions display and at what priority. Only appears in gutters.";
|
||||||
// {
|
|
||||||
description = ''
|
|
||||||
What motions display and at what priority. Only appears in gutters.
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
disabled_fts = mkOption {
|
disabled_fts = mkOption {
|
||||||
type = listOf str;
|
type = listOf str;
|
||||||
|
|
Loading…
Reference in a new issue