mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-23 01:08:43 +02:00
fix: add ripgrep for todo-comments functionality (#1020)
This commit is contained in:
parent
ffe8978028
commit
4448c4ce63
2 changed files with 16 additions and 0 deletions
|
@ -33,6 +33,13 @@ in {
|
|||
"todo-comments"
|
||||
pkgs.vimPlugins.todo-comments-nvim;
|
||||
|
||||
ripgrepPackage = mkOption {
|
||||
type = with types; nullOr package;
|
||||
default = pkgs.ripgrep;
|
||||
example = null;
|
||||
description = "Which package (if any) to be added for file search support in todo-comments.";
|
||||
};
|
||||
|
||||
signs = helpers.defaultNullOpts.mkBool true "Show icons in the signs column.";
|
||||
|
||||
signPriority = helpers.defaultNullOpts.mkInt 8 "Sign priority.";
|
||||
|
@ -264,6 +271,7 @@ in {
|
|||
in
|
||||
mkIf cfg.enable {
|
||||
extraPlugins = [cfg.package];
|
||||
extraPackages = optional (cfg.ripgrepPackage != null) cfg.ripgrepPackage;
|
||||
extraConfigLua = ''
|
||||
require("todo-comments").setup${helpers.toLuaObject setupOptions}
|
||||
'';
|
||||
|
|
|
@ -125,4 +125,12 @@
|
|||
};
|
||||
};
|
||||
};
|
||||
|
||||
withoutRipgrep = {
|
||||
plugins.todo-comments = {
|
||||
enable = true;
|
||||
|
||||
ripgrepPackage = null;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue