flocon/modules/programs/fastfetch.nix
Anthony Rodriguez fc876b2ea5
treewide: update options API
The options API has been updated, in order for a more flexible setup
with `local.modules.desktop.enable` being replaced with an enum of
desktops at `local.systemVars.desktop`, which allows for switching
desktop environments by changing a single option. This is so that we can
switch to cosmic and only enable the programs we need (i.e. disable
greetd because we use cosmic-greeter and enable terminals since that is
desktop related). This is simpler than having a different module per
desktop.
2025-02-06 18:47:01 +01:00

123 lines
3 KiB
Nix

{
lib,
pkgs,
config,
...
}: let
inherit (config.local.systemVars) username;
logo = builtins.fetchurl {
url = "https://raw.githubusercontent.com/gytis-ivaskevicius/high-quality-nix-content/refs/heads/master/emoji/nix-owo-transparent.png";
sha256 = "137k3i7z4va68v4rvrazy26szc7p2w59h7bc2h8japzjyj6xjs71";
};
in {
config = lib.mkIf (config.local.systemVars.desktop != "none") {
hjem.users.${username} = {
packages = [pkgs.fastfetch];
files = {
".config/fastfetch/config.jsonc".text = builtins.toJSON {
logo = {
source = logo;
type = "kitty";
width = 33;
};
modules = [
{
type = "title";
color = {
user = "35";
host = "36";
};
}
{
type = "separator";
string = "";
}
{
type = "os";
key = " ";
format = "{3} ({12})";
keyColor = "32";
}
{
type = "host";
key = "󰟀 ";
keyColor = "32";
}
{
type = "kernel";
key = "󰒔 ";
format = "{1} {2}";
keyColor = "32";
}
{
type = "shell";
key = "$ ";
format = "{1} {4}";
keyColor = "32";
}
{
type = "packages";
key = " ";
keyColor = "32";
}
{
type = "uptime";
key = "󰔚 ";
keyColor = "32";
}
"break"
{
type = "display";
key = "󰹑 ";
keyColor = "33";
compactType = "original";
}
{
type = "de";
key = "󰧨 ";
keyColor = "33";
}
{
type = "wm";
key = " ";
keyColor = "33";
}
{
type = "theme";
key = "󰉼 ";
keyColor = "33";
}
{
type = "icons";
key = " ";
keyColor = "33";
}
{
type = "cursor";
key = "󰳽 ";
keyColor = "33";
}
{
type = "font";
key = " ";
format = "{2}";
keyColor = "33";
}
{
type = "terminal";
key = " ";
format = "{3}";
keyColor = "33";
}
"break"
{
type = "colors";
symbol = "block";
}
];
};
};
};
};
}