mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 22:59:15 +00:00
35 lines
812 B
Nix
35 lines
812 B
Nix
# This module integrates tmux with fish
|
|
{
|
|
pkgs,
|
|
lib,
|
|
config,
|
|
...
|
|
}: {
|
|
assertions = [
|
|
{
|
|
assertion = config.programs.fish.enable;
|
|
message = "Should have fish enabled";
|
|
}
|
|
{
|
|
assertion = config.programs.tmux.enable;
|
|
message = "Should have tmux enabled";
|
|
}
|
|
];
|
|
|
|
home.sessionVariables = lib.mapAttrs (_: path: config.home.homeDirectory + "/${path}") {
|
|
REPO_PATH = "r";
|
|
PLAYGROUND_PATH = "pg";
|
|
WORKTREE_PATH = "wt";
|
|
};
|
|
|
|
programs.direnv.config.whitelist.prefix = [(config.home.sessionVariables.REPO_PATH + "/leana8959")];
|
|
programs.tmux.extraConfig = lib.mkBefore ''
|
|
# sessionizer binds
|
|
bind -n C-f run-shell "tmux new-window tmux-sessionizer"
|
|
bind s run-shell "tmux-last"
|
|
'';
|
|
|
|
home.packages = with pkgs; [
|
|
tmux-sessionizer
|
|
];
|
|
}
|