From 43d159c2ee8863f5a0a2087367a0f9ca9b4d407b Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Sun, 2 Apr 2023 20:15:24 +0300 Subject: [PATCH] dev: relocate nvim/nvim-flake assertion --- lib/assertions.nix | 6 ++++++ lib/module/default.nix | 9 --------- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/lib/assertions.nix b/lib/assertions.nix index 49ea8ac..66e0317 100644 --- a/lib/assertions.nix +++ b/lib/assertions.nix @@ -12,5 +12,11 @@ in { assertion = cfg.kommentary.enable; message = "Kommentary has been deprecated in favor"; } + mkIf + (config.programs.neovim-flake.enable) + { + assertion = !config.programs.neovim.enable; + message = "You cannot use neovim-flake together with vanilla neovim."; + } ]; } diff --git a/lib/module/default.nix b/lib/module/default.nix index ae97a26..7689aef 100644 --- a/lib/module/default.nix +++ b/lib/module/default.nix @@ -46,13 +46,4 @@ in { config = mkIf cfg.enable { home.packages = [set.neovim]; }; - - assertions = mkMerge [ - mkIf - (config.programs.neovim-flake.enable) - { - assertion = !config.programs.neovim.enable; - message = "You cannot use neovim-flake together with vanilla neovim."; - } - ]; }