btop: move to modules/home, clean up
Signed-off-by: fau <fau@faukah.com> Change-Id: I6a6a696439b1369f17f636024507155d43005dec
This commit is contained in:
parent
c621860314
commit
967218a48e
3 changed files with 40 additions and 50 deletions
40
modules/home/programs/btop.hjem.nix
Normal file
40
modules/home/programs/btop.hjem.nix
Normal file
|
@ -0,0 +1,40 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
inherit (builtins) attrValues;
|
||||
inherit (lib.attrsets) mapAttrsToList;
|
||||
inherit (lib.strings) concatStringsSep;
|
||||
|
||||
btop-settings = {
|
||||
truecolor = "True";
|
||||
vim_keys = "True";
|
||||
rounded_corners = "True";
|
||||
update_ms = "100";
|
||||
graph_symbol = "braille";
|
||||
cpu_single_graph = "True";
|
||||
clock_format = "%X";
|
||||
use_fstab = "True";
|
||||
io_mode = "True";
|
||||
net_sync = "True";
|
||||
net_iface = "enp4s0";
|
||||
log_level = "ERROR";
|
||||
color_theme = "gruvbox_dark";
|
||||
};
|
||||
|
||||
btop-no-desktop-entry = pkgs.btop.overrideAttrs (prev: {
|
||||
postInstall = ''
|
||||
${prev.postInstall or ""}
|
||||
rm -rf $out/share/applications/*.desktop
|
||||
'';
|
||||
});
|
||||
|
||||
in
|
||||
{
|
||||
packages = attrValues { inherit btop-no-desktop-entry; };
|
||||
files.".config/btop/btop.conf".text =
|
||||
concatStringsSep "\n" <| mapAttrsToList (name: value: "${name} = ${toString value}") btop-settings;
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue