diff --git a/hosts/configuration_desktop.nix b/hosts/configuration_desktop.nix index 1a103b1..d2e7d2d 100644 --- a/hosts/configuration_desktop.nix +++ b/hosts/configuration_desktop.nix @@ -101,6 +101,10 @@ age-plugin-yubikey pwgen cryptsetup + powerline + powerline-fonts + powerline-symbols + tree ]; }; diff --git a/hosts/configuration_server.nix b/hosts/configuration_server.nix index dcec78a..68186b7 100644 --- a/hosts/configuration_server.nix +++ b/hosts/configuration_server.nix @@ -88,6 +88,10 @@ agenix.packages.x86_64-linux.default ffmpeg smartmontools + powerline + powerline-fonts + powerline-symbols + tree ]; }; diff --git a/modules/shell/tmux.nix b/modules/shell/tmux.nix index 0339c70..c9bdad6 100644 --- a/modules/shell/tmux.nix +++ b/modules/shell/tmux.nix @@ -13,17 +13,26 @@ keyMode = "vi"; historyLimit = 10000; clock24 = true; - shortcut = "h"; + shortcut = "Space"; baseIndex = 1; - plugins = [ pkgs.tmuxPlugins.dracula ]; + plugins = with pkgs.tmuxPlugins; [ + yank + sidebar + { + plugin = dracula; + extraConfig = " + set -g @dracula-show-powerline true + set -g @dracula-plugins 'git cpu-usage ram-usage battery time' + set -g @dracula-border-contrast true + "; + } + ]; extraConfig = '' - set -g @dracula-plugins "cpu-usage ram-usage network-bandwidth time" set -g mouse on - #set -g @dracula-show-powerline true - + # More friendly split pane - bind-key s split-window -h - bind-key v split-window -v + bind-key s split-window -h -c "#{pane_current_path}" + bind-key v split-window -v -c "#{pane_current_path}" unbind '"' unbind '%' @@ -38,8 +47,9 @@ bind -r C-i select-window -t :+ # Vim style X clipboard integration↲ - bind-key -T copy-mode-vi 'v' send -X begin-selection - bind-key -T copy-mode-vi 'y' send-keys -X copy-pipe-and-cancel "xsel -i -p && xsel -o -p | xsel -i -b" + bind-key -T copy-mode-vi 'v' send-keys -X begin-selection + bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle + bind-key -T copy-mode-vi 'y' send-keys -X copy-selection-and-cancel bind-key P run "xsel -o | tmux load-buffer - ; tmux paste-buffer" # resize panes with vim movement keys @@ -51,6 +61,8 @@ # bindings for pane joining and breaking bind < split-window -h \; choose-window 'kill-pane ; join-pane -hs %%' bind > break-pane -d + + run-shell ${pkgs.tmuxPlugins.sidebar}/share/tmux-plugins/sidebar/sidebar.tmux ''; }; };