From f9b44dd9cbce4987db4df07f47d77bd41f5d1190 Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Mon, 27 Feb 2023 17:52:18 +0300 Subject: [PATCH] feat: apply new module format to comment.nvim --- modules/comments/comment-nvim/comment-nvim.nix | 14 ++++++++++++++ .../{comment-nvim.nix => comment-nvim/config.nix} | 4 ---- modules/comments/comment-nvim/default.nix | 6 ++++++ 3 files changed, 20 insertions(+), 4 deletions(-) create mode 100644 modules/comments/comment-nvim/comment-nvim.nix rename modules/comments/{comment-nvim.nix => comment-nvim/config.nix} (77%) create mode 100644 modules/comments/comment-nvim/default.nix diff --git a/modules/comments/comment-nvim/comment-nvim.nix b/modules/comments/comment-nvim/comment-nvim.nix new file mode 100644 index 0000000..b445d91 --- /dev/null +++ b/modules/comments/comment-nvim/comment-nvim.nix @@ -0,0 +1,14 @@ +{ + pkgs, + config, + lib, + ... +}: +with lib; +with builtins; let + cfg = config.vim.comments.comment-nvim; +in { + options.vim.comments.comment-nvim = { + enable = mkEnableOption "comment-nvim"; + }; +} diff --git a/modules/comments/comment-nvim.nix b/modules/comments/comment-nvim/config.nix similarity index 77% rename from modules/comments/comment-nvim.nix rename to modules/comments/comment-nvim/config.nix index 1139b3c..8b0dbd0 100644 --- a/modules/comments/comment-nvim.nix +++ b/modules/comments/comment-nvim/config.nix @@ -8,10 +8,6 @@ with lib; with builtins; let cfg = config.vim.comments.comment-nvim; in { - options.vim.comments.comment-nvim = { - enable = mkEnableOption "comment-nvim"; - }; - config = mkIf cfg.enable { vim.startPlugins = [ "comment-nvim" diff --git a/modules/comments/comment-nvim/default.nix b/modules/comments/comment-nvim/default.nix new file mode 100644 index 0000000..db4eb42 --- /dev/null +++ b/modules/comments/comment-nvim/default.nix @@ -0,0 +1,6 @@ +_: { + imports = [ + ./config.nix + ./comment-nvim.nix + ]; +}