diff --git a/assets/logo2.png b/assets/logo2.png new file mode 100644 index 0000000..beeac55 Binary files /dev/null and b/assets/logo2.png differ diff --git a/modules/programs/default.nix b/modules/programs/default.nix index f46243c..f454717 100644 --- a/modules/programs/default.nix +++ b/modules/programs/default.nix @@ -7,6 +7,7 @@ ./coding.nix ./containers.nix ./drives.nix + ./fastfetch.nix ./fish.nix ./flatpak.nix ./gaming.nix diff --git a/modules/programs/fastfetch.nix b/modules/programs/fastfetch.nix new file mode 100644 index 0000000..60e51cd --- /dev/null +++ b/modules/programs/fastfetch.nix @@ -0,0 +1,67 @@ +{ + pkgs, + lib, + options, + config, + ... +}: { + options.mods = { + dashfetch = lib.mkOption { + default = true; + example = false; + type = lib.types.bool; + description = "A custom configuration for fastfetch"; + }; + }; + + config = lib.optionalAttrs (options ? home.packages) { + xdg.configFile."fastfetch/config.jsonc" = lib.mkIf (config.mods.dashfetch) { + source = (pkgs.formats.json {}).generate "config.jsonc" { + "$schema" = "https://github.com/fastfetch-cli/fastfetch/raw/dev/doc/json_schema.json"; + logo = { + type = "kitty"; + source = ../../assets/logo2.png; + width = 35; + padding = { + top = 2; + }; + }; + modules = [ + "title" + "separator" + { + type = "os"; + key = "OS"; + format = "DashNix ({name} {version})"; + } + "host" + "kernel" + "uptime" + "packages" + "shell" + "display" + "de" + "wm" + "wmtheme" + "theme" + "icons" + "font" + "cursor" + "terminal" + "terminalfont" + "cpu" + "gpu" + "memory" + "swap" + "disk" + "localip" + "battery" + "poweradapter" + "locale" + "break" + "colors" + ]; + }; + }; + }; +}