62 lines
1.6 KiB
Nix
62 lines
1.6 KiB
Nix
{
|
|
lib,
|
|
pkgs,
|
|
...
|
|
}: let
|
|
sddm-sugar-candy = pkgs.stdenv.mkDerivation {
|
|
pname = "sddm-sugar-candy";
|
|
version = "master";
|
|
src = pkgs.fetchgit {
|
|
url = "https://framagit.org/MarianArlt/sddm-sugar-candy.git";
|
|
hash = "sha256-XggFVsEXLYklrfy1ElkIp9fkTw4wvXbyVkaVCZq4ZLU=";
|
|
};
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
mkdir -p $out/share/sddm/themes/sugar-candy
|
|
cp -r /build/sddm-sugar-candy/* $out/share/sddm/themes/sugar-candy
|
|
|
|
runHook postInstall
|
|
'';
|
|
};
|
|
|
|
/*
|
|
Adds a theme.conf.user file to the current sddm theme's folder,
|
|
allowing you to change it's configuration without needing to
|
|
repackage it
|
|
*/
|
|
customcfg = pkgs.stdenv.mkDerivation {
|
|
name = "sddm-theme-customizer";
|
|
dontUnpack = true;
|
|
installPhase = let
|
|
config = lib.generators.toINI {} {
|
|
# Add the custom config here
|
|
General = {
|
|
background = "${pkgs.kdePackages.breeze}/share/wallpapers/Next/contents/images_dark/5120x2880.png";
|
|
};
|
|
};
|
|
in ''
|
|
runHook preInstall
|
|
|
|
mkdir -p $out/share/sddm/themes/breeze/
|
|
echo "${config}" >> $out/share/sddm/themes/breeze/theme.conf.user
|
|
|
|
runHook postInstall
|
|
'';
|
|
};
|
|
in {
|
|
# Enable SDDM.
|
|
services.displayManager.sddm = {
|
|
enable = true;
|
|
wayland.enable = true;
|
|
# theme = "sugar-candy";
|
|
settings = {
|
|
General = {Numlock = "off";};
|
|
Theme = {CursorTheme = "Breeze_Light";};
|
|
};
|
|
};
|
|
|
|
# Sugar candy doesn't seem to work on qt6 :(
|
|
# environment.systemPackages = [sddm-sugar-candy customcfg];
|
|
environment.systemPackages = [customcfg];
|
|
}
|