summaryrefslogtreecommitdiff
path: root/user-profiles/tmux/default.nix
blob: 11c537889e84ab53a40155f368cb2f4999a64259 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
{ userName, pkgs, lib, ... }:
{
  home-manager.users.${userName} = {
    programs.tmux = {
      enable = true;
      clock24 = true;
      historyLimit = 50000;
      extraConfig = lib.readFile (pkgs.stdenv.mkDerivation {
        name = "tmux.conf";
        src = ./tmux.conf;

        buildInputs = with pkgs; [ makeWrapper ];

        phases = [ "installPhase" ];

        inherit (pkgs) zsh;
        mandb = pkgs.man-db;
        
        installPhase = ''
          substituteAll $src $out
        '';
      });
    };

    home.packages = [
      pkgs.tmuxp
    ];
  };
}