Skip to content

Commit

Permalink
feat(nixos): add support for plymouth
Browse files Browse the repository at this point in the history
  • Loading branch information
Weathercold committed May 10, 2024
1 parent eaa6e28 commit 8a54bbb
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 1 deletion.
22 changes: 22 additions & 0 deletions modules/nixos/plymouth.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{ config
, pkgs
, lib
, ...
}:
let
inherit (lib) ctp mkIf;
cfg = config.boot.plymouth.catppuccin;
enable = cfg.enable && config.boot.plymouth.enable;
in
{
options.boot.plymouth.catppuccin = ctp.mkCatppuccinOpt "plymouth";

config.boot.plymouth = mkIf enable {
theme = "catppuccin-${cfg.flavour}";
themePackages = with pkgs; [
(catppuccin-plymouth.override {
variant = cfg.flavour;
})
];
};
}
5 changes: 4 additions & 1 deletion test.nix
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,10 @@ testers.runNixOSTest {
common
];

boot.loader.grub = enable;
boot = {
loader.grub = enable;
plymouth = enable;
};

console = enable;

Expand Down

0 comments on commit 8a54bbb

Please sign in to comment.