aboutsummaryrefslogtreecommitdiff
path: root/.vim
diff options
context:
space:
mode:
authortdro <tdro@users.noreply.github.com>2021-07-28 23:45:59 -0400
committertdro <tdro@users.noreply.github.com>2021-07-28 23:45:59 -0400
commit9b9db1efa58f1ea0a2ad7e933c980e8c06f76b82 (patch)
tree0dc54a1410acfb37ac4eb6528f17458ab04e3ebb /.vim
parent3626813b149f1411b9fcd987896e54770c4c99cb (diff)
downloaddotfiles-9b9db1efa58f1ea0a2ad7e933c980e8c06f76b82.tar.gz
dotfiles-9b9db1efa58f1ea0a2ad7e933c980e8c06f76b82.tar.bz2
dotfiles-9b9db1efa58f1ea0a2ad7e933c980e8c06f76b82.zip
.vim/snippets/module: Use more refined snippet template
Diffstat (limited to '.vim')
-rw-r--r--.vim/snippets/module.nix23
1 files changed, 22 insertions, 1 deletions
diff --git a/.vim/snippets/module.nix b/.vim/snippets/module.nix
index 8debed4..1ad9d80 100644
--- a/.vim/snippets/module.nix
+++ b/.vim/snippets/module.nix
@@ -4,15 +4,36 @@ let
service = "";
cfg = config.services.${service};
+ settings = pkgs.formats.json { };
in {
options.services.${service} = {
+
enable = lib.mkOption {
type = lib.types.bool;
default = false;
};
+
+ user = lib.mkOption {
+ type = lib.types.str;
+ default = service;
+ };
+
+ group = lib.mkOption {
+ type = lib.types.str;
+ default = service;
+ };
+
+ settings = lib.mkOption {
+ type = settings.type;
+ default = { };
+ };
};
- config = lib.mkIf cfg.enable { };
+ config = lib.mkIf cfg.enable {
+
+ services.${service}.settings = { };
+
+ };
}