amaan can't into kernel

do 400 pushups per cache miss idiot
This commit is contained in:
atagen 2026-04-27 16:09:39 +10:00
parent 848ed62c5d
commit 4921973b9a
34 changed files with 3240 additions and 605 deletions

View file

@ -3,24 +3,13 @@
lib,
getPkgs,
config,
mkWrappers,
...
}:
let
pal = config.rice.palette.hex;
ui = config.rice.roles pal;
wrap =
name: pkg: args:
pkgs.symlinkJoin {
inherit name;
paths = [ pkg ];
nativeBuildInputs = [ pkgs.makeWrapper ];
postBuild = "wrapProgram $out/bin/${name} ${args}";
};
wrapXdg =
name: pkg: configDir:
wrap name pkg ''--set XDG_CONFIG_HOME "${configDir}"'';
inherit (mkWrappers pkgs) wrap wrapXdg;
lazygitConfig = pkgs.writeText "lazygit-config.yml" ''
gui:
@ -68,55 +57,12 @@ let
theme "nix-rice"
'';
btopConfig = pkgs.writeText "btop.conf" ''
color_theme = "nix-rice"
'';
btopThemeDir = pkgs.runCommand "btop-themes" { } ''
mkdir -p $out
cp ${pkgs.writeText "nix-rice.theme" ''
theme[main_bg]="${ui.bg}"
theme[main_fg]="${ui.fg}"
theme[title]="${ui.fg}"
theme[hi_fg]="${ui.accent}"
theme[selected_bg]="${ui.surface}"
theme[selected_fg]="${ui.fg}"
theme[inactive_fg]="${ui.muted}"
theme[graph_text]="${ui.fg}"
theme[meter_bg]="${ui.overlay}"
theme[proc_misc]="${ui.primary}"
theme[cpu_box]="${ui.primary}"
theme[mem_box]="${ui.accent}"
theme[net_box]="${pal.normal.green}"
theme[proc_box]="${pal.normal.magenta}"
theme[div_line]="${ui.overlay}"
theme[temp_start]="${pal.normal.green}"
theme[temp_mid]="${ui.highlight}"
theme[temp_end]="${ui.error}"
theme[cpu_start]="${ui.primary}"
theme[cpu_mid]="${ui.accent}"
theme[cpu_end]="${ui.highlight}"
theme[free_start]="${pal.normal.green}"
theme[free_mid]="${ui.accent}"
theme[free_end]="${ui.primary}"
theme[cached_start]="${ui.primary}"
theme[cached_mid]="${ui.accent}"
theme[cached_end]="${pal.normal.green}"
theme[available_start]="${pal.normal.green}"
theme[available_mid]="${ui.accent}"
theme[available_end]="${ui.highlight}"
theme[used_start]="${ui.highlight}"
theme[used_mid]="${ui.error}"
theme[used_end]="${pal.bright.red}"
theme[download_start]="${pal.normal.green}"
theme[download_mid]="${ui.accent}"
theme[download_end]="${ui.primary}"
theme[upload_start]="${ui.highlight}"
theme[upload_mid]="${pal.bright.red}"
theme[upload_end]="${ui.error}"
theme[process_start]="${ui.primary}"
theme[process_mid]="${ui.accent}"
theme[process_end]="${pal.normal.green}"
''} $out/nix-rice.theme
btopConfigDir = pkgs.runCommand "btop-xdg" { } ''
mkdir -p $out/btop
cp ${pkgs.writeText "btop.conf" ''
color_theme = "TTY"
update_ms = 100
''} $out/btop/btop.conf
'';
in
{
@ -124,16 +70,26 @@ in
inherit (pkgs)
curl
eza
git
gitMinimal
ripgrep
fd
ouch
btop
bat
;
lazygit = wrap "lazygit" pkgs.lazygit ''--add-flags "--use-config-file=${lazygitConfig}"'';
zellij = wrap "zellij" pkgs.zellij ''--add-flags "--config-dir ${zellijConfig}"'';
# btop = wrap "btop" pkgs.btop ''--add-flags "--config ${btopConfig} --themes-dir ${btopThemeDir}"'';
lazygit = wrap {
name = "lazygit";
pkg = pkgs.lazygit;
args = [ "--use-config-file=${lazygitConfig}" ];
};
zellij = wrap {
name = "zellij";
pkg = pkgs.zellij;
args = [ "--config-dir ${zellijConfig}" ];
envs = {
SHELL = "${config.users.defaultUserShell}/bin/nu";
};
};
btop = wrapXdg "btop" pkgs.btop btopConfigDir;
};
environment.variables.BAT_THEME = "ansi";