mirror of
https://github.com/tomasriveral/nixos.git
synced 2026-08-12 10:30:44 +02:00
finished fastfetch module
This commit is contained in:
@@ -111,10 +111,6 @@
|
|||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
neovim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
|
neovim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
|
||||||
wget
|
wget
|
||||||
warpinator # used to send files via Lan between Linux systems
|
|
||||||
#zoxide # better cd moved into home-manager
|
|
||||||
fastfetch
|
|
||||||
#git #enabled in home-manager
|
|
||||||
tree # shows dir in tree
|
tree # shows dir in tree
|
||||||
zsh # better bash
|
zsh # better bash
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ imports = [
|
|||||||
../../modules/home-manager/zsh.nix # better bash
|
../../modules/home-manager/zsh.nix # better bash
|
||||||
../../modules/home-manager/git.nix
|
../../modules/home-manager/git.nix
|
||||||
../../modules/home-manager/ssh.nix
|
../../modules/home-manager/ssh.nix
|
||||||
|
../../modules/home-manager/fastfetch.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+152
-105
@@ -1,130 +1,177 @@
|
|||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
# Adapted from https://github.com/dacrab/fastfetch-config/blob/main/config.jsonc
|
|
||||||
{
|
{
|
||||||
|
# Adapted from https://github.com/dacrab/fastfetch-config/blob/main/config.jsonc
|
||||||
programs.fastfetch = {
|
programs.fastfetch = {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings = {"logo": {"type":"nixos_small"},
|
|
||||||
"modules": [
|
settings = {
|
||||||
|
logo = {
|
||||||
|
type = "none";
|
||||||
|
#source = "nixos";
|
||||||
|
};
|
||||||
|
|
||||||
|
modules = [
|
||||||
|
|
||||||
|
# ───────────── Hardware ─────────────
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "custom",
|
type = "custom";
|
||||||
"format": "╭───────────────────────── Hardware ──────────────────────────╮",
|
format = "╭───────────────────────── Hardware ──────────────────────────╮";
|
||||||
"outputColor": "blue"
|
outputColor = "blue";
|
||||||
},
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "title",
|
type = "title";
|
||||||
"key": " PC",
|
key = " PC";
|
||||||
"keyColor": "green"
|
keyColor = "green";
|
||||||
},
|
}
|
||||||
{
|
|
||||||
"key": "│ ├ Laptop",
|
|
||||||
"keyColor": "green",
|
|
||||||
"type": "host"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"key": "│ ├ Display",
|
|
||||||
"keyColor": "green",
|
|
||||||
"type": "display"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "cpu",
|
type = "host";
|
||||||
"key": "│ ├ CPU",
|
key = "│ ├ Laptop";
|
||||||
"showPeCoreCount": true,
|
keyColor = "green";
|
||||||
"format": "{1}",
|
}
|
||||||
"keyColor": "green"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "gpu",
|
type = "display";
|
||||||
"key": "│ ├ GPU",
|
key = "│ ├ Display";
|
||||||
"keyColor": "green"
|
keyColor = "green";
|
||||||
},
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "memory",
|
type = "cpu";
|
||||||
"key": "└ └ Memory",
|
key = "│ ├ CPU";
|
||||||
"keyColor": "green"
|
showPeCoreCount = true;
|
||||||
},
|
format = "{1}";
|
||||||
|
keyColor = "green";
|
||||||
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "custom",
|
type = "gpu";
|
||||||
"format": "╰─────────────────────────────────────────────────────────────╯",
|
key = "│ ├ GPU";
|
||||||
"outputColor": "blue"
|
keyColor = "green";
|
||||||
},
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "custom",
|
type = "memory";
|
||||||
"format": "╭───────────────────────── Software ──────────────────────────╮",
|
key = "└ └ Memory";
|
||||||
"outputColor": "blue"
|
keyColor = "green";
|
||||||
},
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "os",
|
type = "custom";
|
||||||
"key": " OS ",
|
format = "╰─────────────────────────────────────────────────────────────╯";
|
||||||
"keyColor": "cyan"
|
outputColor = "blue";
|
||||||
},
|
}
|
||||||
|
|
||||||
|
# ───────────── Software ─────────────
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "kernel",
|
type = "custom";
|
||||||
"key": "│ ├ Kernel",
|
format = "╭───────────────────────── Software ──────────────────────────╮";
|
||||||
"keyColor": "cyan"
|
outputColor = "blue";
|
||||||
},
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "packages",
|
type = "os";
|
||||||
"key": "│ ├ Packages",
|
key = " OS";
|
||||||
"keyColor": "cyan"
|
keyColor = "cyan";
|
||||||
},
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "shell",
|
type = "kernel";
|
||||||
"key": "│ ├ Shell",
|
key = "│ ├ Kernel";
|
||||||
"keyColor": "cyan"
|
keyColor = "cyan";
|
||||||
},
|
}
|
||||||
{
|
|
||||||
"key": "│ ├ Terminal",
|
|
||||||
"keyColor": "cyan",
|
|
||||||
"type": "terminal"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "command",
|
type = "packages";
|
||||||
"key": "│ ├ OS Age",
|
key = "│ ├ Packages";
|
||||||
"keyColor": "cyan",
|
keyColor = "cyan";
|
||||||
"text": "birth_install=$(stat -c %W /); current=$(date +%s); time_progression=$((current - birth_install)); days_difference=$((time_progression / 86400)); echo $days_difference days"
|
}
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "uptime",
|
type = "shell";
|
||||||
"key": "└ └ Uptime",
|
key = "│ ├ Shell";
|
||||||
"keyColor": "cyan"
|
keyColor = "cyan";
|
||||||
},
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "de",
|
type = "terminal";
|
||||||
"key": " DE",
|
key = "│ ├ Terminal";
|
||||||
"keyColor": "blue"
|
keyColor = "cyan";
|
||||||
},
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "wm",
|
type = "command";
|
||||||
"key": " WM",
|
key = "│ ├ OS Age";
|
||||||
"keyColor": "magenta"
|
keyColor = "cyan";
|
||||||
},
|
text = ''
|
||||||
|
birth_install=$(stat -c %W /)
|
||||||
|
current=$(date +%s)
|
||||||
|
time_progression=$((current - birth_install))
|
||||||
|
days_difference=$((time_progression / 86400))
|
||||||
|
echo $days_difference days
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "gpu",
|
type = "uptime";
|
||||||
"key": "│ ├ GPU Driver",
|
key = "└ └ Uptime";
|
||||||
"format": "{3}",
|
keyColor = "cyan";
|
||||||
"keyColor": "magenta"
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"key": "│ ├ Brightness ",
|
|
||||||
"keyColor": "magenta",
|
|
||||||
"type": "brightness"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "version",
|
type = "de";
|
||||||
"key": "└ └ FastFetch",
|
key = " DE";
|
||||||
"keyColor": "magenta"
|
keyColor = "blue";
|
||||||
},
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "custom",
|
type = "wm";
|
||||||
"format": "╰────────────────────────────────────────────────────────────╯",
|
key = " WM";
|
||||||
"outputColor": "blue"
|
keyColor = "magenta";
|
||||||
},
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
"type": "custom",
|
type = "gpu";
|
||||||
"format": " \u001b[90m \u001b[31m \u001b[32m \u001b[33m \u001b[34m \u001b[35m \u001b[36m \u001b[37m "
|
key = "│ ├ GPU Driver";
|
||||||
},
|
format = "{3}";
|
||||||
|
keyColor = "magenta";
|
||||||
|
}
|
||||||
|
|
||||||
|
{
|
||||||
|
type = "brightness";
|
||||||
|
key = "│ ├ Brightness";
|
||||||
|
keyColor = "magenta";
|
||||||
|
}
|
||||||
|
|
||||||
|
{
|
||||||
|
type = "version";
|
||||||
|
key = "└ └ FastFetch";
|
||||||
|
keyColor = "magenta";
|
||||||
|
}
|
||||||
|
|
||||||
|
{
|
||||||
|
type = "custom";
|
||||||
|
format = "╰────────────────────────────────────────────────────────────╯";
|
||||||
|
outputColor = "blue";
|
||||||
|
}
|
||||||
|
|
||||||
|
#{
|
||||||
|
# type = "custom";
|
||||||
|
# format = ''
|
||||||
|
# {#0} {#1} {#2} {#3} {#4} {#5} {#6} {#7}
|
||||||
|
# '';
|
||||||
|
#} #for some reason dont work
|
||||||
|
{
|
||||||
|
type = "colors";
|
||||||
|
symbol = "diamond";
|
||||||
|
}
|
||||||
|
|
||||||
"break"
|
"break"
|
||||||
]
|
];
|
||||||
}
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user