{ pkgs, lib, config, ... }: { programs.bash = { enable = lib.mkDefault true; shellAliases = { cl = "clear"; eic = "edit-in-commit"; eigg = "edit-in-git-grep"; emacs = "emacsclient --create-frame"; g = "git"; grep = "grep --color"; j="sudo journalctl -u"; jb="sudo journalctl -b"; l = "ls -alh"; ll = "ls -al"; ls = "ls --color=tty"; md-toc = "grep '^#\\+' --color"; mem = "ps -e -orss=,user=,args= | sort -b -k1,1n"; mem-top = "smem --sort rss --autosize"; mpl = "mplayer"; nixos-clean="sudo nix-collect-garbage -d"; nixos-history="sudo nix-env --list-generations --profile /nix/var/nix/profiles/system"; nixos-rollback="sudo nixos-rebuild switch --rollback"; pass-gen = "tr -d -C A-Za-z0-9_- /dev/null | while IFS=: read -r file x size x do pid=''${file#/proc/} pid=''${pid%/smaps} size=''${size% kB} size=''${size##* } if test "$pid" = "$lastpid" then swap=$(( swap + size )) else if test "$swap" -gt 0 then printf "%u pid=%u cmd=%s\n" "$swap" "$lastpid" "$(tr '\000' ' '