feat(rofi): Catppuccin -> Rose Pine

This commit is contained in:
punkfairie 2024-10-20 12:19:42 -07:00
parent dc1c94c811
commit e1d74c0117
Signed by: punkfairie
GPG key ID: 01823C057725C266
2 changed files with 21 additions and 14 deletions

View file

@ -268,13 +268,13 @@
"type": "Git",
"repository": {
"type": "GitHub",
"owner": "catppuccin",
"owner": "rose-pine",
"repo": "rofi"
},
"branch": "main",
"revision": "b636a00fd40a7899a8206195464ae8b7f0450a6d",
"url": "https://github.com/catppuccin/rofi/archive/b636a00fd40a7899a8206195464ae8b7f0450a6d.tar.gz",
"hash": "1a1sr451nsfii70j2f5qf8wq4jns0d4477a2kzh3993xdnx1j3yc"
"revision": "414bb2538713a874dbb357f19212c96a011e1ac8",
"url": "https://github.com/rose-pine/rofi/archive/414bb2538713a874dbb357f19212c96a011e1ac8.tar.gz",
"hash": "19kif3nh0lr934blam971fm55pr1pdbn9b3lnrpc0yq2vpgf8x9y"
},
"rose-pine-dunst": {
"type": "Git",

View file

@ -1,18 +1,25 @@
{ config, lib, ... }:
let
inherit (config.catppuccin) sources;
cfg = config.programs.rofi.catppuccin;
enable = cfg.enable && config.programs.rofi.enable;
in
{
options.programs.rofi.catppuccin = lib.ctp.mkCatppuccinOpt { name = "rofi"; };
config,
lib,
...
}: let
inherit (config.rose-pine) sources;
cfg = config.programs.rofi.rose-pine;
enable = cfg.enable && config.programs.rofi.enable;
themeName =
if (cfg.flavor == "main")
then "rose-pine"
else "rose-pine-${cfg.flavor}";
in {
options.programs.rofi.rose-pine = lib.rp.mkRosePineOpt {name = "rofi";};
config.programs.rofi = lib.mkIf enable {
theme = {
"@theme" = builtins.path {
name = "catppuccin-${cfg.flavor}.rasi";
path = "${sources.rofi}/basic/.local/share/rofi/themes/catppuccin-${cfg.flavor}.rasi";
name = "${themeName}.rasi";
path = "${sources.rofi}/${themeName}.rasi";
};
};
};