mirror of
https://github.com/nix-community/nixvim.git
synced 2025-07-13 10:44:34 +02:00
38 lines
910 B
Nix
38 lines
910 B
Nix
|
{
|
||
|
config,
|
||
|
lib,
|
||
|
pkgs,
|
||
|
...
|
||
|
}:
|
||
|
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||
|
name = "telekasten";
|
||
|
originalName = "telekasten.nvim";
|
||
|
package = "telekasten-nvim";
|
||
|
|
||
|
maintainers = [ lib.maintainers.onemoresuza ];
|
||
|
|
||
|
settingsExample = {
|
||
|
home.__raw = ''vim.fn.expand("~/zettelkasten")'';
|
||
|
};
|
||
|
|
||
|
# TODO: Remove once nixpkgs #349346 lands, since it will have plenary-nvim as
|
||
|
# a dependency.
|
||
|
extraOptions = {
|
||
|
plenaryPackage = lib.mkPackageOption pkgs.vimPlugins "plenary-nvim" { nullable = true; };
|
||
|
};
|
||
|
|
||
|
# TODO: Remove once nixpkgs #349346 lands, since it will have telescope-nvim
|
||
|
# as a dependency.
|
||
|
extraConfig = cfg: {
|
||
|
assertions = [
|
||
|
{
|
||
|
assertion = config.plugins.telescope.enable;
|
||
|
message = ''
|
||
|
Nixvim (plugins.telekasten): The plugin needs telescope to function as intended.
|
||
|
'';
|
||
|
}
|
||
|
];
|
||
|
extraPlugins = [ cfg.plenaryPackage ];
|
||
|
};
|
||
|
}
|