plymouth: remove blackBackground option (#294)

This commit is contained in:
Daniel Thwaites 2024-03-18 15:11:06 +00:00 committed by GitHub
parent daddbb141b
commit 2221c7d61b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -26,19 +26,9 @@ let
else "cp ${./theme_still.script} $themeDir/stylix.script" else "cp ${./theme_still.script} $themeDir/stylix.script"
} }
${ substituteInPlace $themeDir/stylix.script \
if cfg.blackBackground --replace-fail "%BASE00%" "${base00-dec-r}, ${base00-dec-g}, ${base00-dec-b}" \
then '' --replace-fail "%BASE05%" "${base05-dec-r}, ${base05-dec-g}, ${base05-dec-b}"
substituteInPlace $themeDir/stylix.script \
--replace-fail "%BASE00%" "0, 0, 0" \
--replace-fail "%BASE05%" "1, 1, 1"
''
else ''
substituteInPlace $themeDir/stylix.script \
--replace-fail "%BASE00%" "${base00-dec-r}, ${base00-dec-g}, ${base00-dec-b}" \
--replace-fail "%BASE05%" "${base05-dec-r}, ${base05-dec-g}, ${base05-dec-b}"
''
}
echo " echo "
[Plymouth Theme] [Plymouth Theme]
@ -85,20 +75,16 @@ in {
type = types.bool; type = types.bool;
default = true; default = true;
}; };
blackBackground = mkOption {
description = mdDoc ''
Whether to use a black background rather than a theme colour.
This looks good in combination with systemd-boot, as it means that the
background colour doesn't change throughout the boot process.
'';
type = types.bool;
defaultText = literalMD "`true` if systemd-boot is enabled";
default = config.boot.loader.systemd-boot.enable;
};
}; };
imports = [
(
lib.mkRemovedOptionModule
[ "stylix" "targets" "plymouth" "blackBackground" ]
"This was removed since it goes against the chosen color scheme. If you want this, consider disabling the target and configuring Plymouth by hand."
)
];
config.boot.plymouth = mkIf cfg.enable { config.boot.plymouth = mkIf cfg.enable {
theme = "stylix"; theme = "stylix";
themePackages = [ theme ]; themePackages = [ theme ];