mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-01-22 05:44:25 +01:00
Simplify wrapper imports
This commit is contained in:
parent
43c8adddb6
commit
42ebeaf86e
19 changed files with 298 additions and 248 deletions
|
|
@ -1,47 +1,56 @@
|
|||
{ assembleWrapper, moduleArgs, ... }:
|
||||
let
|
||||
inherit (moduleArgs) pkgs lib;
|
||||
in
|
||||
{
|
||||
inputs,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
theme ? "dark",
|
||||
}:
|
||||
assembleWrapper {
|
||||
basePackage = pkgs.rofi-wayland;
|
||||
flags =
|
||||
let
|
||||
theming =
|
||||
{
|
||||
dark = ''
|
||||
* {
|
||||
background: #1E2127FF;
|
||||
background-alt: #282B31FF;
|
||||
foreground: #FFFFFFFF;
|
||||
selected: #61AFEFFF;
|
||||
active: #98C379FF;
|
||||
urgent: #E06C75FF;
|
||||
}
|
||||
'';
|
||||
light = ''
|
||||
* {
|
||||
background: #F1F1F1FF;
|
||||
background-alt: #E0E0E0FF;
|
||||
foreground: #252525FF;
|
||||
selected: #008EC4FF;
|
||||
active: #10A778FF;
|
||||
urgent: #C30771FF;
|
||||
}
|
||||
'';
|
||||
}
|
||||
.${theme};
|
||||
rofi-config = pkgs.writeText "rofi-config" (
|
||||
lib.concatLines [
|
||||
theming
|
||||
(builtins.readFile ./config.rasi)
|
||||
]
|
||||
);
|
||||
in
|
||||
[
|
||||
"-config"
|
||||
rofi-config
|
||||
];
|
||||
}
|
||||
(inputs.wrapper-manager.lib {
|
||||
inherit pkgs;
|
||||
modules = [
|
||||
{
|
||||
wrappers.rofi = {
|
||||
basePackage = pkgs.rofi-wayland;
|
||||
flags =
|
||||
let
|
||||
theming =
|
||||
{
|
||||
dark = ''
|
||||
* {
|
||||
background: #1E2127FF;
|
||||
background-alt: #282B31FF;
|
||||
foreground: #FFFFFFFF;
|
||||
selected: #61AFEFFF;
|
||||
active: #98C379FF;
|
||||
urgent: #E06C75FF;
|
||||
}
|
||||
'';
|
||||
light = ''
|
||||
* {
|
||||
background: #F1F1F1FF;
|
||||
background-alt: #E0E0E0FF;
|
||||
foreground: #252525FF;
|
||||
selected: #008EC4FF;
|
||||
active: #10A778FF;
|
||||
urgent: #C30771FF;
|
||||
}
|
||||
'';
|
||||
}
|
||||
.${theme};
|
||||
rofi-config = pkgs.writeText "rofi-config" (
|
||||
lib.concatLines [
|
||||
theming
|
||||
(builtins.readFile ./config.rasi)
|
||||
]
|
||||
);
|
||||
in
|
||||
[
|
||||
"-config"
|
||||
rofi-config
|
||||
];
|
||||
};
|
||||
}
|
||||
];
|
||||
}).config.wrappers.rofi.wrapped
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue