]> Git — Sourcephile - julm/julm-nix.git/blob - home-manager/profiles/essential.nix
aubergine: wireshark: enable
[julm/julm-nix.git] / home-manager / profiles / essential.nix
1 { pkgs, lib, config, nixosConfig, ... }:
2 {
3 imports = [
4 ./bash.nix
5 ./htop.nix
6 ./ssh.nix
7 ./tmux.nix
8 ];
9 programs.bat.enable = lib.mkDefault true;
10 home.packages = [
11 nixosConfig.boot.kernelPackages.cpupower
12 pkgs.acpi
13 pkgs.audit
14 pkgs.binutils
15 pkgs.cryptsetup
16 pkgs.dislocker
17 pkgs.dmidecode
18 pkgs.dstat
19 pkgs.dust
20 pkgs.e2fsprogs
21 pkgs.file
22 pkgs.fio
23 pkgs.gptfdisk
24 pkgs.hdparm
25 pkgs.hwinfo
26 pkgs.i2c-tools # for decode-dimms
27 pkgs.iotop
28 pkgs.iperf
29 pkgs.kernel-hardening-checker
30 pkgs.ldns
31 pkgs.lm_sensors
32 pkgs.lshw
33 pkgs.lsof
34 pkgs.lsscsi
35 pkgs.mkpasswd
36 pkgs.mmc-utils
37 #pkgs.moreutils
38 pkgs.multitail
39 pkgs.nload
40 pkgs.parted
41 pkgs.pciutils
42 #pkgs.powertop
43 pkgs.procps
44 pkgs.pstree
45 pkgs.pv
46 pkgs.s-tui
47 pkgs.smartmontools
48 pkgs.smem
49 pkgs.spectre-meltdown-checker
50 pkgs.strace
51 pkgs.stress-ng
52 pkgs.testdisk
53 pkgs.tree
54 pkgs.usbutils
55 pkgs.util-linux
56 pkgs.which
57 ] ++ lib.optionals nixosConfig.services.xserver.enable [
58 pkgs.gparted
59 pkgs.xdg-utils
60 ] ++ pkgs.lib.optionals pkgs.stdenv.hostPlatform.isx86_64 [
61 pkgs.ncdu
62 ];
63 home.sessionPath = [ "${config.home.homeDirectory}/bin" ];
64 home.sessionVariables = {
65 EDITOR = "vim";
66 LANG = "fr_FR.UTF-8";
67 LESS = "-FRSX";
68 # NixOS generates a customized pkgs.glibcLocales in config.i18n.glibcLocales
69 #LOCALE_ARCHIVE = "${pkgs.glibcLocalesUtf8}/lib/locale/locale-archive";
70 MANPAGER = "less";
71 };
72 # Keep only the last generation of the home-manager profile
73 home.activation.delete-generations = lib.hm.dag.entryAfter [ "writeBoundary" ] ''
74 if [ "$(${pkgs.coreutils}/bin/id -u)" = 0 ]
75 then profile="''${NIX_STATE_DIR:-/nix/var/nix}/profiles/per-user/$USER"
76 else profile="''${XDG_STATE_HOME:-$HOME/.local/state}"/nix/profiles
77 fi
78 ${nixosConfig.nix.package}/bin/nix-env --delete-generations +1 --profile "$profile"/home-manager
79 '';
80 }