@@ -52,6 +52,12 @@ let
5252 set -s escape-time ${toString cfg.escapeTime}
5353 set -g history-limit ${toString cfg.historyLimit}
5454
55+ ${lib.optionalString (cfg.plugins != []) ''
56+ # Run plugins
57+ ${lib.concatMapStringsSep "\n" (x: "run-shell ${x.rtp}") cfg.plugins}
58+
59+ ''}
60+
5561 ${cfg.extraConfig}
5662 '';
5763
@@ -165,6 +171,13 @@ in {
165171 downside it doesn't survive user logout.
166172 '';
167173 };
174+
175+ plugins = mkOption {
176+ default = [];
177+ type = types.listOf types.package;
178+ description = "List of plugins to install.";
179+ example = lib.literalExpression "[ pkgs.tmuxPlugins.nord ]";
180+ };
168181 };
169182 };
170183
@@ -174,7 +187,7 @@ in {
174187 environment = {
175188 etc."tmux.conf".text = tmuxConf;
176189
177− systemPackages = [ pkgs.tmux ];
190+ systemPackages = [ pkgs.tmux ] ++ cfg.plugins;
178191
179192 variables = {
180193 TMUX_TMPDIR = lib.optional cfg.secureSocket ''''${XDG_RUNTIME_DIR:-"/run/user/$(id -u)"}'';