mirror of
https://github.com/nix-community/nixvim.git
synced 2026-09-24 15:30:15 -05:00
plantuml: init syntax plugin (#104)
This commit is contained in:
@@ -23,6 +23,7 @@
|
||||
|
||||
./languages/ledger.nix
|
||||
./languages/nix.nix
|
||||
./languages/plantuml-syntax.nix
|
||||
./languages/treesitter.nix
|
||||
./languages/treesitter-context.nix
|
||||
./languages/treesitter-refactor.nix
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
with lib; {
|
||||
options.plugins.plantuml-syntax = {
|
||||
enable = mkEnableOption "Enable plantuml syntax support";
|
||||
setMakeprg = mkOption {
|
||||
type = types.bool;
|
||||
default = true;
|
||||
description = "Set the makeprg to 'plantuml'";
|
||||
};
|
||||
executableScript = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
description = "Set the script to be called with makeprg, default to 'plantuml' in PATH";
|
||||
};
|
||||
};
|
||||
|
||||
config = let
|
||||
cfg = config.plugins.plantuml-syntax;
|
||||
in
|
||||
mkIf cfg.enable {
|
||||
extraPlugins = with pkgs.vimPlugins; [plantuml-syntax];
|
||||
|
||||
globals = {
|
||||
plantuml_set_makeprg = cfg.setMakeprg;
|
||||
plantuml_executable_script = cfg.executableScript;
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user