Compare commits

..

6 commits

Author SHA1 Message Date
Noire
3c4e0aa8d9
Merge 18e27eb0bb into 8ff50562d7 2024-11-07 05:47:49 +00:00
Nowaaru
18e27eb0bb
utility/precognition: format 2024-11-06 22:47:44 -07:00
Nowaaru
80ca761639
utility/precognition: fix configuration.nix entry
oops lol
2024-11-06 22:46:54 -07:00
Nowaaru
f013656dab
utility/precognition: remove periods at the end of descriptions 2024-11-06 22:45:02 -07:00
Nowaaru
c20bfdd6dc
utility/precognition: manual format 2024-11-06 22:44:37 -07:00
Nowaaru
3c1f89984c
utility/precognition: add description to disabled_fts
oops
2024-11-06 16:32:40 -07:00
3 changed files with 13 additions and 34 deletions

View file

@ -165,29 +165,7 @@ isMaximal: {
motion = { motion = {
hop.enable = true; hop.enable = true;
leap.enable = true; leap.enable = true;
precognition.enable = isMaximal;
precognition = {
enable = true;
setupOpts = {
startVisible = true;
showBlankVirtLine = true;
# highlightColor - automatically set by theme
disabled_fts = ["startify" "alpha" "dashboard"];
gutterHints = {
gg = {
text = "gg";
prio = 2;
};
};
hints = {
Caret = {
text = "^";
prio = 10;
};
};
};
};
}; };
images = { images = {

View file

@ -10,9 +10,7 @@ in {
config = config =
mkIf cfg.enable mkIf cfg.enable
{ {
vim.startPlugins = [ vim.startPlugins = ["precognition-nvim"];
"precognition-nvim"
];
vim.luaConfigRC.precognition = lib.nvim.dag.entryAnywhere '' vim.luaConfigRC.precognition = lib.nvim.dag.entryAnywhere ''
require('precognition').setup(${lib.nvim.lua.toLuaObject cfg.setupOpts}) require('precognition').setup(${lib.nvim.lua.toLuaObject cfg.setupOpts})

View file

@ -11,11 +11,11 @@
options = { options = {
text = mkOption { text = mkOption {
type = str; type = str;
description = "The easier-to-read depiction of the motion."; description = "The easier-to-read depiction of the motion";
}; };
prio = mkOption { prio = mkOption {
type = int; type = int;
description = "The priority of the hint."; description = "The priority of the hint";
example = 10; example = 10;
default = 1; default = 1;
}; };
@ -29,13 +29,13 @@ in {
setupOpts = mkPluginSetupOption "precognition.nvim" { setupOpts = mkPluginSetupOption "precognition.nvim" {
startVisible = mkOption { startVisible = mkOption {
type = bool; type = bool;
description = "Whether to start 'precognition' automatically."; description = "Whether to start 'precognition' automatically";
default = true; default = true;
}; };
showBlankVirtLine = mkOption { showBlankVirtLine = mkOption {
type = bool; type = bool;
description = "Whether to show a blank virtual line when no movements are shown."; description = "Whether to show a blank virtual line when no movements are shown";
default = true; default = true;
}; };
@ -48,17 +48,20 @@ in {
{ foreground = "#0000FF"; background = "#000000"; }; { foreground = "#0000FF"; background = "#000000"; };
''; '';
description = '' description = ''
The highlight for the virtual text. The highlight for the virtual text
''; '';
}; };
hints = mkHintType "What motions display and at what priority."; hints = mkHintType "What motions display and at what priority";
gutterHints = gutterHints = mkHintType ''
mkHintType "What motions display and at what priority. Only appears in gutters."; What motions display and at what priority. Only appears in gutters
'';
disabled_fts = mkOption { disabled_fts = mkOption {
type = listOf str; type = listOf str;
description = "Filetypes that automatically disable 'precognition'";
default = ["startify"]; default = ["startify"];
example = literalExpression ''["startify"]''; example = literalExpression ''["startify"]'';
}; };