mirror of
https://github.com/NotAShelf/nvf.git
synced 2025-09-06 18:31:35 +00:00
Merge remote-tracking branch 'origin/markdown_fix'
This commit is contained in:
commit
79f3dc2c02
7 changed files with 65 additions and 2 deletions
|
@ -9,7 +9,7 @@
|
|||
inherit (lib.modules) mkIf mkMerge;
|
||||
inherit (lib.options) mkEnableOption mkOption;
|
||||
inherit (lib.lists) isList;
|
||||
inherit (lib.types) bool enum either package listOf str;
|
||||
inherit (lib.types) bool enum either package listOf str nullOr;
|
||||
inherit (lib.nvim.lua) expToLua toLuaObject;
|
||||
inherit (lib.nvim.types) diagnostics mkGrammarOption mkPluginSetupOption;
|
||||
inherit (lib.nvim.dag) entryAnywhere;
|
||||
|
@ -117,7 +117,18 @@ in {
|
|||
'';
|
||||
};
|
||||
|
||||
setupOpts = mkPluginSetupOption "render-markdown" {};
|
||||
setupOpts = mkPluginSetupOption "render-markdown" {
|
||||
file_types = lib.mkOption {
|
||||
type = nullOr (listOf str);
|
||||
default = null;
|
||||
description = ''
|
||||
List of buffer filetypes to enable this plugin in.
|
||||
|
||||
This will cause the plugin to attach to new buffers who
|
||||
have any of these filetypes.
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
|
19
modules/plugins/mini/cursorword/config.nix
Normal file
19
modules/plugins/mini/cursorword/config.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
inherit (lib.modules) mkIf;
|
||||
inherit (lib.nvim.dag) entryAnywhere;
|
||||
inherit (lib.nvim.lua) toLuaObject;
|
||||
|
||||
cfg = config.vim.mini.cursorword;
|
||||
in {
|
||||
vim = mkIf cfg.enable {
|
||||
startPlugins = ["mini-cursorword"];
|
||||
|
||||
pluginRC.mini-ai = entryAnywhere ''
|
||||
require("mini.cursorword").setup(${toLuaObject cfg.setupOpts})
|
||||
'';
|
||||
};
|
||||
}
|
9
modules/plugins/mini/cursorword/cursorword.nix
Normal file
9
modules/plugins/mini/cursorword/cursorword.nix
Normal file
|
@ -0,0 +1,9 @@
|
|||
{lib, ...}: let
|
||||
inherit (lib.options) mkEnableOption;
|
||||
inherit (lib.nvim.types) mkPluginSetupOption;
|
||||
in {
|
||||
options.vim.mini.cursorword = {
|
||||
enable = mkEnableOption "mini.cursorword";
|
||||
setupOpts = mkPluginSetupOption "mini.cursorword" {};
|
||||
};
|
||||
}
|
6
modules/plugins/mini/cursorword/default.nix
Normal file
6
modules/plugins/mini/cursorword/default.nix
Normal file
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
imports = [
|
||||
./cursorword.nix
|
||||
./config.nix
|
||||
];
|
||||
}
|
|
@ -11,6 +11,7 @@
|
|||
./colors
|
||||
./comment
|
||||
./completion
|
||||
./cursorword
|
||||
./diff
|
||||
./doc
|
||||
./extra
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue