refactor(treewide): enable modules based on host.type
This commit is contained in:
parent
779603c4cc
commit
25e02c034c
10 changed files with 39 additions and 67 deletions
|
|
@ -1,13 +1,5 @@
|
|||
{ lib, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./tuigreet
|
||||
];
|
||||
|
||||
options.systemModules.displayManager = {
|
||||
tuigreet = {
|
||||
enable = lib.mkEnableOption "Enable tuigreet display manager module";
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,15 +1,16 @@
|
|||
{ pkgs, lib, config, ... }:
|
||||
let
|
||||
inherit (lib) mkIf;
|
||||
tuigreet = "${pkgs.greetd.tuigreet}/bin/tuigreet";
|
||||
cfg = config.systemModules.displayManager.tuigreet;
|
||||
host = config.systemModules.host;
|
||||
in
|
||||
{
|
||||
config = lib.mkIf cfg.enable {
|
||||
config = mkIf (host.type != "phone") {
|
||||
services.greetd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
default_session = {
|
||||
command = "${tuigreet} --time --remember --cmd Hyprland";
|
||||
command = "${tuigreet} --time --remember --cmd Hyprland"; # TODO: dont hardcode this
|
||||
user = "greeter";
|
||||
};
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue