Migrated from import based to config based
This commit is contained in:
24
modules/system/desktop-environments/cosmic.nix
Normal file
24
modules/system/desktop-environments/cosmic.nix
Normal file
@@ -0,0 +1,24 @@
|
||||
{ lib, config, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.settings.desktop-environments.cosmic;
|
||||
in {
|
||||
options = {
|
||||
settings.desktop-environments.cosmic.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
description = ''
|
||||
Enable cosmic desktop environment
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
services.desktopManager.cosmic.enable = true;
|
||||
|
||||
environment.sessionVariables = {
|
||||
COSMIC_DISABLE_DIRECT_SCANOUT = "true";
|
||||
};
|
||||
};
|
||||
}
|
44
modules/system/desktop-environments/hyprland.nix
Normal file
44
modules/system/desktop-environments/hyprland.nix
Normal file
@@ -0,0 +1,44 @@
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.settings.desktop-environments.hyprland;
|
||||
in {
|
||||
options = {
|
||||
settings.desktop-environments.hyprland.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
description = ''
|
||||
Enable hyprland window manager
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
programs.hyprland = {
|
||||
enable = true;
|
||||
package = pkgs.unstable.hyprland;
|
||||
xwayland.enable = true;
|
||||
};
|
||||
|
||||
# Sound configuration
|
||||
hardware.pulseaudio.enable = false;
|
||||
security.rtkit.enable = true;
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
};
|
||||
|
||||
# Keyring configuration
|
||||
security.polkit.enable = true;
|
||||
services.gnome.gnome-keyring.enable = true;
|
||||
security.pam.services.greetd.enableGnomeKeyring = true;
|
||||
programs.ssh.startAgent = true;
|
||||
|
||||
# Configure networking
|
||||
networking.networkmanager.enable = true;
|
||||
networking.wireless.iwd.enable = true;
|
||||
};
|
||||
}
|
Reference in New Issue
Block a user