rice/programs/foot.nix

50 lines
1.5 KiB
Nix
Raw Normal View History

2022-12-02 13:58:25 +00:00
{lib, ...}: {
home-manager.users.buffet = {
programs.foot = {
enable = true;
server.enable = true;
2022-12-20 13:40:52 +00:00
settings = let
2022-12-02 13:58:25 +00:00
theme = import ../theme.nix;
2022-12-20 13:40:52 +00:00
dehash = lib.attrsets.mapAttrs (_: lib.strings.removePrefix "#");
2022-12-02 13:58:25 +00:00
normal = dehash theme.normal;
bright = dehash theme.bright;
in {
main = {
font = "${theme.font.family}:size=${toString (theme.font.size - 2)}";
2022-12-20 13:40:52 +00:00
font-italic = "${theme.font.family}:size=${toString (theme.font.size - 2)}";
font-bold-italic = "${theme.font.family}:style=Bold:size=${toString (theme.font.size - 2)}";
2022-12-02 13:58:25 +00:00
pad = "${toString theme.font.size}x${toString theme.font.size}";
};
url = {
launch = ''firefox ''${url}'';
};
colors = {
foreground = lib.strings.removePrefix "#" theme.primary.foreground;
background = lib.strings.removePrefix "#" theme.primary.background;
regular0 = normal.black;
regular1 = normal.red;
regular2 = normal.green;
regular3 = normal.yellow;
regular4 = normal.blue;
regular5 = normal.magenta;
regular6 = normal.cyan;
regular7 = normal.white;
bright0 = bright.black;
bright1 = bright.red;
bright2 = bright.green;
bright3 = bright.yellow;
bright4 = bright.blue;
bright5 = bright.magenta;
bright6 = bright.cyan;
bright7 = bright.white;
};
};
};
};
}