33 lines
893 B
Nix
33 lines
893 B
Nix
{
|
|
fetchFromGitHub
|
|
, stdenv, formats
|
|
, config ? {}
|
|
}:
|
|
|
|
# This package works a bit differently as the config needs to be inside the package.
|
|
# Override with config set to the settings you want. See
|
|
# https://github.com/MarianArlt/sddm-sugar-dark/blob/master/theme.conf
|
|
let
|
|
iniFmt = formats.ini {};
|
|
configFile = iniFmt.generate "theme.conf" config;
|
|
in stdenv.mkDerivation rec {
|
|
pname = "sddm-sugar-dark";
|
|
version = "1.2";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "MarianArlt";
|
|
repo = "sddm-sugar-dark";
|
|
rev = "v${version}";
|
|
sha256 = "0gx0am7vq1ywaw2rm1p015x90b75ccqxnb1sz3wy8yjl27v82yhb";
|
|
};
|
|
|
|
dontBuild = true;
|
|
|
|
installPhase = ''
|
|
mkdir -p $out/usr/share/sddm/themes/sugar-dark
|
|
|
|
cp -r metadata.desktop Main.qml Background.jpg Components Assets $out/usr/share/sddm/themes/sugar-dark
|
|
ln -s ${configFile} $out/usr/share/sddm/themes/sugar-dark/theme.conf
|
|
'';
|
|
}
|