Refactor fastfetch images and terminal output
Some checks are pending
Build NixOS ISOs (x86 only) / build-iso (x86, desktop) (push) Waiting to run
Build NixOS ISOs (x86 only) / build-iso (x86, server) (push) Waiting to run
Build NixOS ISOs (x86 only) / create-release (push) Blocked by required conditions

- Update logo paths and fallback from text to PNG images
- Adjust logo settings for kitty display (dimensions, padding)
- Modify shell command in gen.fish to use an alternative runner
- Wrap fastfetch call in a fish_greeting function for terminal detection
- Revise host configuration for updated system specs
This commit is contained in:
Chris Toph 2025-06-20 17:41:33 -04:00
parent 894cc4444c
commit 10bad206e5
6 changed files with 27 additions and 17 deletions

View file

@ -6,15 +6,14 @@
...
}:
{
#TODO: Scripts might need a rework
programs.fastfetch =
let
hostname = hostSpec.hostName;
logoFile =
let
hostLogoPath = ./. + "/host/${hostname}.txt";
hostLogoPath = ./. + "/host/images/${hostname}.png";
in
if builtins.pathExists hostLogoPath then hostLogoPath else ./host/nix.txt;
if builtins.pathExists hostLogoPath then hostLogoPath else ./host/images/nix.png;
weather = import ./scripts/weather.nix { inherit pkgs; };
title = import ./scripts/title.nix { inherit pkgs; };
in
@ -22,12 +21,14 @@
enable = true;
settings = {
logo = {
source = builtins.readFile logoFile;
type = "data";
position = "left";
type = "kitty";
source = logoFile;
width = 21; # columns
height = 12; # rows
padding = {
top = 0;
right = 0;
top = 1;
right = 2;
left = 2;
};
};
display = {
@ -72,7 +73,11 @@
type = "wm";
}
{
text = "printf '%s%s' (string upper (string sub -l 1 $SHELL)) (string lower (string sub -s 2 $SHELL))";
text =
let
name = lib.getName pkgs.fish;
in
"printf '%s%s' (string upper (string sub -l 1 ${name})) (string lower (string sub -s 2 ${name}))";
key = "shell » {#keys}";
keyColor = "1;33";
type = "command";

Binary file not shown.

After

Width:  |  Height:  |  Size: 56 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 123 KiB

View file

@ -21,7 +21,10 @@ for i in (seq 1 $num)
set type2 $types[$j]
set combination "$type1+$type2"
echo "Creating with type $combination"
nix run nixpkgs#chafa -- -s 24x11 -w 9 --symbols $combination --view-size 24x11 $input_png
# chafa -s 23x12 -w 9 --stretch --symbols $combination --view-size 23x12 $input_png
yay try chafa -- chafa -s 24x11 -w 9 --symbols $combination --view-size 24x11 $input_png
# yay try chafa -- chafa -s 23x12 -w 9 --stretch --symbols $combination --view-size 23x12 $input_png
end
end
# yay try chafa -- chafa -s 23x12 -w 9 --symbols half --view-size 23x12 ./1989.png
# fastfetch --logo-height 12 --logo-width 21 --logo-type kitty --logo-position left --logo-preserve-aspect-ratio --logo ./haze.png --logo-padding 2 --logo-padding-top 1

View file

@ -1,4 +1,10 @@
set fish_greeting # Disable greeting
function fish_greeting
if test "$SIXEL" = true; or string match -q xterm-256color "$TERM"
fastfetch --logo-type sixel
else
fastfetch
end
end
## Aliases and Overrides ##
@ -108,7 +114,3 @@ function unzipz
return 1
end
end
## Fish Prompt ##
fastfetch

View file

@ -1,7 +1,7 @@
###############################################################
#
# Haze - Cesar's Desktop
# NixOS running on Ryzen 7 ___ , Radeon RX 6950 XT, 32GB RAM
# NixOS running on Ryzen 5 7600x, Radeon RX 7600, 32GB RAM
#
###############################################################