feat(tmux): nixify my tmux config
This commit is contained in:
@@ -28,6 +28,63 @@
|
||||
plugins.web-devicons.enable = true;
|
||||
};
|
||||
|
||||
# tmux config
|
||||
programs.tmux = {
|
||||
enable = true;
|
||||
# Basic options
|
||||
prefix = "C-a";
|
||||
keyMode = "vi";
|
||||
mouse = true;
|
||||
# Terminal settings
|
||||
terminal = "screen-256color";
|
||||
# Extra configuration
|
||||
extraConfig = ''
|
||||
# Status keys
|
||||
set -g status-keys vi
|
||||
# Status bar options
|
||||
set -g status-interval 1
|
||||
set -g status on
|
||||
set -g status-justify left
|
||||
# Clock mode
|
||||
setw -g clock-mode-colour cyan
|
||||
# Colors
|
||||
set -g status-bg black
|
||||
set -g status-fg white
|
||||
# Key bindings
|
||||
# Reload configuration
|
||||
bind r source-file ~/.config/tmux/tmux.conf
|
||||
# Panel split and selection
|
||||
unbind %
|
||||
unbind '"'
|
||||
bind v split-window -v
|
||||
bind c split-window -h
|
||||
bind i new-window
|
||||
bind b previous-window
|
||||
bind n next-window
|
||||
# Move around panes with hjkl
|
||||
bind h select-pane -L
|
||||
bind j select-pane -D
|
||||
bind k select-pane -U
|
||||
bind l select-pane -R
|
||||
# Resize panes
|
||||
bind H resize-pane -L 5
|
||||
bind J resize-pane -D 5
|
||||
bind K resize-pane -U 5
|
||||
bind L resize-pane -R 5
|
||||
# Kill commands
|
||||
bind q kill-window
|
||||
bind Q kill-session
|
||||
# Bars
|
||||
set -g status-left "#[fg=black,bg=blue,bold] #S#[fg=blue,bg=black,nobold,noitalics,nounderscore]"
|
||||
set -g status-left "#[fg=black,bg=blue,bold] #S #[fg=blue,bg=black,nobold,noitalics,nounderscore]"
|
||||
set -g status-right "#{prefix_highlight}#[fg=brightblack,bg=black,nobold,noitalics,nounderscore]#[fg=white,bg=brightblack] %Y-%m-%d #[fg=white,bg=brightblack,nobold,noitalics,nounderscore]#[fg=white,bg=brightblack] %H:%M #[fg=cyan,bg=brightblack,nobold,noitalics,nounderscore]#[fg=black,bg=cyan,bold] #H "
|
||||
# Windows
|
||||
set -g window-status-format "#[fg=black,bg=brightblack,nobold,noitalics,nounderscore] #[fg=white,bg=brightblack]#I #[fg=white,bg=brightblack,nobold,noitalics,nounderscore] #[fg=white,bg=brightblack]#W #F #[fg=brightblack,bg=black,nobold,noitalics,nounderscore]"
|
||||
set -g window-status-current-format "#[fg=black,bg=cyan,nobold,noitalics,nounderscore] #[fg=black,bg=cyan]#I #[fg=black,bg=cyan,nobold,noitalics,nounderscore] #[fg=black,bg=cyan]#W #F #[fg=cyan,bg=black,nobold,noitalics,nounderscore]"
|
||||
set -g window-status-separator ""
|
||||
'';
|
||||
};
|
||||
|
||||
# user packages
|
||||
home.packages = with pkgs; [
|
||||
discord
|
||||
|
||||
Reference in New Issue
Block a user