nix-community.nixvim/plugins/snippets/friendly-snippets.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

33 lines
611 B
Nix
Raw Normal View History

2024-01-22 11:25:52 +01:00
{
lib,
helpers,
config,
pkgs,
...
}:
with lib;
let
cfg = config.plugins.friendly-snippets;
in
{
meta.maintainers = [ maintainers.GaetanLepage ];
options.plugins.friendly-snippets = {
enable = mkEnableOption "friendly-snippets";
package = lib.mkPackageOption pkgs "friendly-snippets" {
default = [
"vimPlugins"
"friendly-snippets"
];
};
2024-01-22 11:25:52 +01:00
};
config = mkIf cfg.enable {
extraPlugins = [ cfg.package ];
# Simply add an element to the `fromVscode` list to trigger the import of friendly-snippets
plugins.luasnip.fromVscode = [ { } ];
};
}