dotfiles/modules/greetd/default.nix

25 lines
470 B
Nix
Raw Normal View History

2024-07-18 04:08:27 +00:00
{config, lib, pkgs, ... }:
with lib;
let
cfg = config.modules.greetd;
in {
options.modules.greetd = {
enable = mkEnableOption "greetd";
command = mkOption {
type = types.str;
default = "";
description = "Command to run to show greeter.";
};
};
config = mkIf cfg.enable {
services.greetd = {
enable = true;
settings.default_session = {
command = cfg.command;
user = "greeter";
};
};
};
}