Getting more idomatic nix modules setup... will tackle users dir later
This commit is contained in:
parent
6316fffeb1
commit
913cff0ffa
41 changed files with 675 additions and 498 deletions
32
modules/de/cosmic.nix
Normal file
32
modules/de/cosmic.nix
Normal file
|
@ -0,0 +1,32 @@
|
|||
{
|
||||
cosmic,
|
||||
config,
|
||||
lib,
|
||||
settings,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
let
|
||||
name = "de_cosmic";
|
||||
cfg = config.mods.${name};
|
||||
in
|
||||
{
|
||||
|
||||
options = {
|
||||
mods.${name} = {
|
||||
enable = mkEnableOption (lib.mdDoc "Enable COSMIC desktop environment");
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
# Use cosmic binary cache
|
||||
nix.settings = {
|
||||
substituters = [ "https://cosmic.cachix.org/" ];
|
||||
trusted-public-keys = [ "cosmic.cachix.org-1:Dya9IyXD4xdBehWjrkPv6rtxpmMdRel02smYzA85dPE=" ];
|
||||
};
|
||||
|
||||
# Enable cosmic
|
||||
services.desktopManager.cosmic.enable = true;
|
||||
services.displayManager.cosmic-greeter.enable = true;
|
||||
};
|
||||
}
|
37
modules/de/gnome_wayland.nix
Normal file
37
modules/de/gnome_wayland.nix
Normal file
|
@ -0,0 +1,37 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
let
|
||||
name = "de_gnome_wayland";
|
||||
cfg = config.mods.${name};
|
||||
in
|
||||
{
|
||||
options = {
|
||||
mods.${name} = {
|
||||
enable = mkEnableOption (lib.mdDoc "Enable GNOME with wayland desktop environment");
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
services.xserver = {
|
||||
enable = true;
|
||||
displayManager.gdm = {
|
||||
enable = true;
|
||||
autoSuspend = false;
|
||||
wayland = true;
|
||||
};
|
||||
desktopManager.gnome.enable = true;
|
||||
};
|
||||
services.gnome.core-utilities.enable = false;
|
||||
environment.systemPackages = with pkgs; [
|
||||
gnome.dconf-editor
|
||||
# wayland clipboard in terminal
|
||||
wl-clipboard
|
||||
];
|
||||
environment.sessionVariables.NIXOS_OZONE_WL = "1";
|
||||
};
|
||||
}
|
35
modules/de/gnome_xorg.nix
Normal file
35
modules/de/gnome_xorg.nix
Normal file
|
@ -0,0 +1,35 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
let
|
||||
name = "de_gnome_xorg";
|
||||
cfg = config.mods.${name};
|
||||
in
|
||||
{
|
||||
options = {
|
||||
mods.${name} = {
|
||||
enable = mkEnableOption "Enable GNOME with wayland desktop environment";
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
services.xserver = {
|
||||
enable = true;
|
||||
displayManager.gdm = {
|
||||
enable = true;
|
||||
autoSuspend = false;
|
||||
wayland = false;
|
||||
};
|
||||
desktopManager.gnome.enable = true;
|
||||
};
|
||||
services.gnome.core-utilities.enable = false;
|
||||
environment.systemPackages = with pkgs; [
|
||||
gnome.dconf-editor
|
||||
xclip
|
||||
];
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue