diff --git a/plugins/colorschemes/gruvbox-material.nix b/plugins/colorschemes/gruvbox-material.nix index b304c36c..847c69f6 100644 --- a/plugins/colorschemes/gruvbox-material.nix +++ b/plugins/colorschemes/gruvbox-material.nix @@ -1,4 +1,4 @@ -{ lib, ... }: +{ lib, config, ... }: lib.nixvim.plugins.mkVimPlugin { name = "gruvbox-material"; isColorscheme = true; @@ -19,4 +19,15 @@ lib.nixvim.plugins.mkVimPlugin { }; show_eob = 0; }; + + extraConfig = cfg: { + warnings = lib.nixvim.mkWarnings "colorschemes.gruvbox-material" { + when = (cfg.settings.better_performance or 0 == 1) && !config.impureRtp; + message = '' + You have enabled 'better_performance', but the top-level option 'impureRtp' is false. + The performance option generates syntax files at runtime that cannot be accessed with impureRtp disabled. + This breaks the plugin. Either disable 'better_performance' or enable 'impureRtp'. + ''; + }; + }; }