{ pkgs, lib, config, nixosConfig, ... }: { imports = [ ./bash.nix ./htop.nix ./ssh.nix ./tmux.nix ]; programs.bat.enable = lib.mkDefault true; home.packages = [ nixosConfig.boot.kernelPackages.cpupower pkgs.acpi pkgs.audit pkgs.binutils pkgs.cryptsetup pkgs.dmidecode pkgs.dstat pkgs.dust pkgs.e2fsprogs pkgs.file pkgs.fio pkgs.gptfdisk pkgs.hdparm pkgs.hwinfo pkgs.i2c-tools # for decode-dimms pkgs.iotop pkgs.iperf pkgs.kernel-hardening-checker pkgs.ldns pkgs.lm_sensors pkgs.lshw pkgs.lsof pkgs.lsscsi pkgs.mkpasswd pkgs.mmc-utils #pkgs.moreutils pkgs.multitail pkgs.nload pkgs.parted pkgs.pciutils #pkgs.powertop pkgs.procps pkgs.pstree pkgs.pv pkgs.s-tui pkgs.smartmontools pkgs.smem pkgs.spectre-meltdown-checker pkgs.strace pkgs.stress-ng pkgs.testdisk pkgs.tree pkgs.usbutils pkgs.util-linux pkgs.which ] ++ lib.optionals nixosConfig.services.xserver.enable [ pkgs.gparted pkgs.xdg-utils ] ++ pkgs.lib.optionals pkgs.stdenv.hostPlatform.isx86_64 [ pkgs.ncdu ]; home.sessionPath = [ "${config.home.homeDirectory}/bin" ]; home.sessionVariables = { EDITOR = "vim"; LANG = "fr_FR.UTF-8"; LESS = "-FRSX"; # NixOS generates a customized pkgs.glibcLocales in config.i18n.glibcLocales #LOCALE_ARCHIVE = "${pkgs.glibcLocalesUtf8}/lib/locale/locale-archive"; MANPAGER = "less"; }; # Keep only the last generation of the home-manager profile home.activation.delete-generations = lib.hm.dag.entryAfter [ "writeBoundary" ] '' if [ "$(${pkgs.coreutils}/bin/id -u)" = 0 ] then profile="''${NIX_STATE_DIR:-/nix/var/nix}/profiles/per-user/$USER" else profile="''${XDG_STATE_HOME:-$HOME/.local/state}"/nix/profiles fi ${nixosConfig.nix.package}/bin/nix-env --delete-generations +1 --profile "$profile"/home-manager ''; }