mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-20 16:15:43 +02:00
plugins/yaml-schema-detect: init
This commit is contained in:
parent
8b3a69cfea
commit
3e5fc2f93d
2 changed files with 37 additions and 0 deletions
29
plugins/by-name/yaml-schema-detect/default.nix
Normal file
29
plugins/by-name/yaml-schema-detect/default.nix
Normal file
|
@ -0,0 +1,29 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
options,
|
||||
...
|
||||
}:
|
||||
lib.nixvim.plugins.mkNeovimPlugin {
|
||||
name = "yaml-schema-detect";
|
||||
packPathName = "yaml-schema-detect.nvim";
|
||||
package = "yaml-schema-detect-nvim";
|
||||
|
||||
description = ''
|
||||
A Neovim plugin that automatically detects and applies YAML schemas for your YAML files using yaml-language-server (yamlls)
|
||||
'';
|
||||
|
||||
extraConfig = cfg: {
|
||||
warnings = lib.nixvim.mkWarnings "plugins.yaml-schema-detect" [
|
||||
{
|
||||
when = !config.plugins.which-key.enable;
|
||||
message = ''
|
||||
This plugin requires `plugins.which-key` to be enabled
|
||||
${options.plugins.which-key.enable} = true;
|
||||
'';
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
maintainers = [ lib.maintainers.FKouhai ];
|
||||
}
|
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
# empty test case is not needed since having it would make the warning throw an error
|
||||
# this plugin requires which-key
|
||||
combine-plugins = {
|
||||
plugins.which-key.enable = true;
|
||||
plugins.yaml-schema-detect.enable = true;
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue