tmux: upated plugins & key bindings

This commit is contained in:
Fiscal Velvet Poet 2022-07-18 15:45:17 +10:00
parent 43c29f650d
commit 4745c4f5f7
Signed by: fiscalvelvetpoet
GPG key ID: D8EBFD58B023BD47

View file

@ -3,7 +3,9 @@
config, config,
pkgs, pkgs,
... ...
}: { }: let
cfg = config.programs.tmux;
in {
programs = { programs = {
tmux = { tmux = {
# Terminal multiplexer required by byobu # Terminal multiplexer required by byobu
@ -11,34 +13,31 @@
aggressiveResize = true; aggressiveResize = true;
clock24 = true; clock24 = true;
extraConfig = '' extraConfig = ''
#POWERLINE_COMMAND="/run/current-system/sw/bin/powerline" POWERLINE_COMMAND="/run/current-system/sw/bin/powerline"
#POWERLINE_CONFIG_COMMAND="/run/current-system/sw/bin/powerline-config" POWERLINE_CONFIG_COMMAND="/run/current-system/sw/bin/powerline-config"
#run-shell "/run/current-system/sw/bin/powerline-daemon -q" run-shell "/run/current-system/sw/bin/powerline-daemon -q"
#source /run/current-system/sw/share/tmux/powerline.conf source /run/current-system/sw/share/tmux/powerline.conf
# Plugins
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-continuum'
set -g @plugin 'dracula/tmux'
set -g @dracula-show-battery false
set -g @dracula-show-powerline true
set -g @dracula-refresh-rate 10
# Bind home and end keys: # Bind home and end keys:
bind-key -n Home send Escape "OH" bind-key -n Home send Escape "OH"
bind-key -n End send Escape "OF" bind-key -n End send Escape "OF"
# Run tmux plugins in NixOS
run-shell ${pkgs.tmuxPlugins.onedark-theme}/share/tmux-plugins/onedark-theme/tmux-onedark-theme.tmux
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-continuum'
''; '';
keyMode = "vi"; keyMode = "vi";
newSession = true; newSession = true;
shortcut = "a"; shortcut = "b";
terminal = "screen-256color"; terminal = "screen-256color";
}; };
}; };
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
powerline
tmuxPlugins.continuum tmuxPlugins.continuum
tmuxPlugins.dracula tmuxPlugins.onedark-theme
tmuxPlugins.resurrect tmuxPlugins.resurrect
tmuxPlugins.sensible tmuxPlugins.sensible
tmuxPlugins.tmux-fzf tmuxPlugins.tmux-fzf