1
0
Fork 0
mirror of https://github.com/nix-community/nixvim.git synced 2025-11-08 19:46:06 +01:00

plugins/alpha: remove old deprecation warning

This commit is contained in:
Gaetan Lepage 2025-10-24 14:53:59 +02:00 committed by Gaétan Lepage
parent 3896bc0e32
commit edfb052c7e

View file

@ -1,7 +1,6 @@
{
lib,
config,
options,
pkgs,
...
}:
@ -62,13 +61,6 @@ in
];
};
# TODO: deprecated 2024-08-29 remove after 24.11
iconsEnabled = mkOption {
type = types.bool;
description = "Toggle icon support. Installs nvim-web-devicons.";
visible = false;
};
theme = mkOption {
type = with types; nullOr (maybeRaw str);
apply = v: if lib.isString v then lib.nixvim.mkRaw "require'alpha.themes.${v}'.config" else v;
@ -147,37 +139,8 @@ in
let
layoutDefined = cfg.layout != [ ];
themeDefined = cfg.theme != null;
opt = options.plugins.alpha;
in
lib.mkIf cfg.enable {
# TODO: added 2024-09-20 remove after 24.11
warnings = lib.nixvim.mkWarnings "plugins.alpha" {
when = opt.iconsEnabled.isDefined;
message = ''
The option definition `plugins.alpha.iconsEnabled' in ${lib.showFiles opt.iconsEnabled.files} has been deprecated; please remove it.
'';
};
plugins.web-devicons =
lib.mkIf
(
opt.iconsEnabled.isDefined
&& cfg.iconsEnabled
&& !(
(
config.plugins.mini.enable
&& config.plugins.mini.modules ? icons
&& config.plugins.mini.mockDevIcons
)
|| (config.plugins.mini-icons.enable && config.plugins.mini-icons.mockDevIcons)
)
)
{
enable = lib.mkOverride 1490 true;
};
extraPlugins = [ cfg.package ];
assertions = lib.nixvim.mkAssertions "plugins.alpha" [