t14_legacy_config/home/gui/default.nix
2022-11-29 22:17:46 -06:00

50 lines
895 B
Nix

{ config, pkgs, lib, ... } :
with lib;
let
cfg = config.local.gui;
in
{
options.local.gui = {
enable = mkEnableOption "GUI settings and programs";
desktop = mkEnableOption "i3 desktop envirorment";
};
imports = [
./autorandr.nix
./fonts.nix
./gtk.nix
./i3.nix
./polybar.nix
./startx.nix
];
config = mkIf cfg.enable {
local.gui = {
fonts.enable = mkDefault true;
gtk.enable = mkDefault true;
autorandr.enable = mkDefault cfg.desktop;
i3.enable = mkDefault cfg.desktop;
polybar.enable = mkDefault cfg.desktop;
startx.enable = mkDefault cfg.desktop;
};
services = mkIf cfg.desktop {
picom = {
enable = true;
};
dunst = {
enable = true;
};
betterlockscreen = {
enable = true;
};
};
xdg.mimeApps.enable = true;
};
}