mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-21 08:35:43 +02:00
plugins/{telescope,bufferline}: make use of helpers.extraOptionsOptions (#212)
This commit is contained in:
parent
73bdf8a96f
commit
e439cb79df
2 changed files with 255 additions and 262 deletions
|
@ -35,7 +35,9 @@ in {
|
|||
];
|
||||
|
||||
options = {
|
||||
plugins.bufferline = {
|
||||
plugins.bufferline =
|
||||
helpers.extraOptionsOptions
|
||||
// {
|
||||
enable = mkEnableOption "bufferline";
|
||||
package = helpers.mkPackageOption "bufferline" pkgs.vimPlugins.bufferline-nvim;
|
||||
numbers = mkOption {
|
||||
|
@ -64,7 +66,8 @@ in {
|
|||
default = null;
|
||||
};
|
||||
# is deprecated, but might still work
|
||||
indicatorIcon = mkOption {
|
||||
indicatorIcon =
|
||||
mkOption {
|
||||
type = types.nullOr types.str;
|
||||
description = "The Icon shown as a indicator for buffer. Changing it is NOT recommended,
|
||||
this is intended to be an escape hatch for people who cannot bear it for whatever reason.";
|
||||
|
@ -246,12 +249,6 @@ in {
|
|||
};
|
||||
}));
|
||||
};
|
||||
|
||||
extraOptions = mkOption {
|
||||
type = types.attrs;
|
||||
default = {};
|
||||
description = "Extra options, will override others if defined";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -18,7 +18,9 @@ in {
|
|||
|
||||
# TODO:add support for aditional filetypes. This requires autocommands!
|
||||
|
||||
options.plugins.telescope = {
|
||||
options.plugins.telescope =
|
||||
helpers.extraOptionsOptions
|
||||
// {
|
||||
enable = mkEnableOption "telescope.nvim";
|
||||
|
||||
package = helpers.mkPackageOption "telescope.nvim" pkgs.vimPlugins.telescope-nvim;
|
||||
|
@ -62,12 +64,6 @@ in {
|
|||
default = null;
|
||||
description = "Telescope default configuration";
|
||||
};
|
||||
|
||||
extraOptions = mkOption {
|
||||
type = types.attrs;
|
||||
default = {};
|
||||
description = "An attribute set, that lets you set extra options or override options set by nixvim";
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue