terminal refactor, move packages to default, inline btop theme

This commit is contained in:
Sean Kovacs 2026-03-05 21:41:12 -05:00
commit 903cc34632
Signed by: sckova
GPG key ID: 00F325187C68651A
5 changed files with 119 additions and 124 deletions

View file

@ -4,107 +4,105 @@
...
}:
let
btop-colors = with config.scheme.withHashtag; ''
# Credit to https://github.com/catppuccin/btop
# Main background, empty for terminal default, need to be empty if you want transparent background
theme[main_bg]="${base00}"
# Main text color
theme[main_fg]="${base05}"
# Title color for boxes
theme[title]="${base05}"
# Highlight color for keyboard shortcuts
theme[hi_fg]="${base0D}"
# Background color of selected item in processes box
theme[selected_bg]="${base02}"
# Foreground color of selected item in processes box
theme[selected_fg]="${base0D}"
# Color of inactive/disabled text
theme[inactive_fg]="${base03}"
# Color of text appearing on top of graphs, i.e uptime and current network graph scaling
theme[graph_text]="${base06}"
# Background color of the percentage meters
theme[meter_bg]="${base02}"
# Misc colors for processes box including mini cpu graphs, details memory graph and details status text
theme[proc_misc]="${base06}"
# CPU, Memory, Network, Proc box outline colors
theme[cpu_box]="${base0E}" #Mauve
theme[mem_box]="${base0B}" #Green
theme[net_box]="${base12}" #Maroon
theme[proc_box]="${base0D}" #Blue
# Box divider line and small boxes line color
theme[div_line]="${base03}"
# Temperature graph color (Green -> Yellow -> Red)
theme[temp_start]="${base0B}"
theme[temp_mid]="${base0A}"
theme[temp_end]="${base08}"
# CPU graph colors (Teal -> Lavender)
theme[cpu_start]="${base0C}"
theme[cpu_mid]="${base16}"
theme[cpu_end]="${base07}"
# Mem/Disk free meter (Mauve -> Lavender -> Blue)
theme[free_start]="${base0E}"
theme[free_mid]="${base07}"
theme[free_end]="${base0D}"
# Mem/Disk cached meter (Sapphire -> Lavender)
theme[cached_start]="${base16}"
theme[cached_mid]="${base0D}"
theme[cached_end]="${base07}"
# Mem/Disk available meter (Peach -> Red)
theme[available_start]="${base09}"
theme[available_mid]="${base12}"
theme[available_end]="${base08}"
# Mem/Disk used meter (Green -> Sky)
theme[used_start]="${base0B}"
theme[used_mid]="${base0C}"
theme[used_end]="${base15}"
# Download graph colors (Peach -> Red)
theme[download_start]="${base09}"
theme[download_mid]="${base12}"
theme[download_end]="${base08}"
# Upload graph colors (Green -> Sky)
theme[upload_start]="${base0B}"
theme[upload_mid]="${base0C}"
theme[upload_end]="${base15}"
# Process box color gradient for threads, mem and cpu usage (Sapphire -> Mauve)
theme[process_start]="${base16}"
theme[process_mid]="${base07}"
theme[process_end]="${base0E}"
'';
btop-colors-file = pkgs.writeTextFile {
name = "btop-colors";
text = btop-colors;
text = with config.scheme.withHashtag; ''
# Credit to https://github.com/catppuccin/btop
# Main background, empty for terminal default, need to be empty if you want transparent background
theme[main_bg]="${base00}"
# Main text color
theme[main_fg]="${base05}"
# Title color for boxes
theme[title]="${base05}"
# Highlight color for keyboard shortcuts
theme[hi_fg]="${base0D}"
# Background color of selected item in processes box
theme[selected_bg]="${base02}"
# Foreground color of selected item in processes box
theme[selected_fg]="${base0D}"
# Color of inactive/disabled text
theme[inactive_fg]="${base03}"
# Color of text appearing on top of graphs, i.e uptime and current network graph scaling
theme[graph_text]="${base06}"
# Background color of the percentage meters
theme[meter_bg]="${base02}"
# Misc colors for processes box including mini cpu graphs, details memory graph and details status text
theme[proc_misc]="${base06}"
# CPU, Memory, Network, Proc box outline colors
theme[cpu_box]="${base0E}" #Mauve
theme[mem_box]="${base0B}" #Green
theme[net_box]="${base12}" #Maroon
theme[proc_box]="${base0D}" #Blue
# Box divider line and small boxes line color
theme[div_line]="${base03}"
# Temperature graph color (Green -> Yellow -> Red)
theme[temp_start]="${base0B}"
theme[temp_mid]="${base0A}"
theme[temp_end]="${base08}"
# CPU graph colors (Teal -> Lavender)
theme[cpu_start]="${base0C}"
theme[cpu_mid]="${base16}"
theme[cpu_end]="${base07}"
# Mem/Disk free meter (Mauve -> Lavender -> Blue)
theme[free_start]="${base0E}"
theme[free_mid]="${base07}"
theme[free_end]="${base0D}"
# Mem/Disk cached meter (Sapphire -> Lavender)
theme[cached_start]="${base16}"
theme[cached_mid]="${base0D}"
theme[cached_end]="${base07}"
# Mem/Disk available meter (Peach -> Red)
theme[available_start]="${base09}"
theme[available_mid]="${base12}"
theme[available_end]="${base08}"
# Mem/Disk used meter (Green -> Sky)
theme[used_start]="${base0B}"
theme[used_mid]="${base0C}"
theme[used_end]="${base15}"
# Download graph colors (Peach -> Red)
theme[download_start]="${base09}"
theme[download_mid]="${base12}"
theme[download_end]="${base08}"
# Upload graph colors (Green -> Sky)
theme[upload_start]="${base0B}"
theme[upload_mid]="${base0C}"
theme[upload_end]="${base15}"
# Process box color gradient for threads, mem and cpu usage (Sapphire -> Mauve)
theme[process_start]="${base16}"
theme[process_mid]="${base07}"
theme[process_end]="${base0E}"
'';
destination = "/nixos.theme";
};
mergedConfig = pkgs.runCommand "mergedConfig" { } ''
batConfigDir = pkgs.runCommand "mergedConfig" { } ''
mkdir -p $out/themes
cp -r ${btop-colors-file}/nixos.theme $out/themes/nixos.theme
'';
in
{
home.file.".config/btop" = {
source = mergedConfig;
source = batConfigDir;
recursive = true;
};
}

View file

@ -28,6 +28,9 @@
browsh
mosh
gh
kdePackages.qttools
eza
pigz
# development & tooling
jdk21_headless
@ -42,17 +45,37 @@
flaresolverr
nerd-fonts.fira-mono
ffmpeg-full
# formatters
kdePackages.qtdeclarative
prettier
prettierd
nixfmt
stylua
black
clang-tools
];
programs.git = {
enable = true;
settings = {
user = {
name = config.userOptions.name;
email = config.userOptions.email;
programs = {
git = {
enable = true;
settings = {
user = {
name = config.userOptions.name;
email = config.userOptions.email;
};
core.pager = "${pkgs.bat}/bin/bat";
commit.gpgsign = true;
};
core.pager = "${pkgs.bat}/bin/bat";
commit.gpgsign = true;
};
bat = {
enable = true;
config.style = "numbers,changes";
};
lazygit = {
enable = true;
enableFishIntegration = true;
};
lazysql.enable = true;
};
}

View file

@ -1,16 +1,9 @@
{
pkgs,
config,
lib,
...
}:
{
home.packages = with pkgs; [
kdePackages.qttools
eza
pigz
];
programs.fish = {
enable = true;
shellAliases = {

View file

@ -128,14 +128,5 @@ in
macos_titlebar_color = "system";
};
};
bat = {
enable = true;
# config.theme = "Catppuccin ${config.catppuccinUpper.flavor}";
};
lazygit = {
enable = true;
enableFishIntegration = true;
};
lazysql.enable = true;
};
}

View file

@ -7,16 +7,6 @@
{
home.sessionVariables.EDITOR = lib.mkForce "kitty nvim";
home.packages = with pkgs; [
kdePackages.qtdeclarative
prettier
prettierd
nixfmt
stylua
black
clang-tools
];
programs.nixvim = {
enable = true;
enablePrintInit = true;