home: switch to tmux

This commit is contained in:
Guanran Wang 2024-07-03 21:01:39 +08:00
parent b325e7c3a8
commit 39598c2e1a
Signed by: nyancat
GPG key ID: 91F97D9ED12639CF
3 changed files with 23 additions and 37 deletions

View file

@ -0,0 +1,21 @@
{
programs.tmux = {
enable = true;
# value from tmux-sensible, but got overridden by HM (?)
aggressiveResize = true;
escapeTime = 0;
historyLimit = 50000;
baseIndex = 1;
customPaneNavigationAndResize = true;
keyMode = "vi";
mouse = true;
newSession = true;
terminal = "tmux-256color";
extraConfig = ''
set -g set-clipboard on
set -g renumber-windows on
'';
};
}

View file

@ -1,35 +0,0 @@
{lib, ...}: {
programs.zellij = {
enable = true;
enableFishIntegration = true;
};
# Unsure about the syntax for defining keybindings in Nix (refer to line 16)
xdg.configFile."zellij/config.kdl".text = lib.mkForce ''
simplified_ui true
pane_frames false
default_layout "compact"
on_force_close "quit"
mirror_session false
// WORKAROUND: This feature slows down startup speed, and I don't need it anyway.
// See: https://github.com/zellij-org/zellij/issues/1757#issuecomment-1962981641
session_serialization false
keybinds {
normal {
bind "Alt 1" { GoToTab 1; }
bind "Alt 2" { GoToTab 2; }
bind "Alt 3" { GoToTab 3; }
bind "Alt 4" { GoToTab 4; }
bind "Alt 5" { GoToTab 5; }
bind "Alt 6" { GoToTab 6; }
bind "Alt 7" { GoToTab 7; }
bind "Alt 8" { GoToTab 8; }
bind "Alt 9" { GoToTab 9; }
bind "Alt 0" { GoToTab 10; }
}
}
'';
}

View file

@ -38,14 +38,14 @@
./applications/bash
./applications/bat
./applications/eza
./applications/neovim
./applications/fish
./applications/git
./applications/gpg
./applications/neovim
./applications/skim
./applications/starship
./applications/tealdeer
./applications/zellij
./applications/tmux
];
programs.jq.enable = true;