colorscheme update + some tmux updates
This commit is contained in:
parent
59daa951f9
commit
3db255cc32
12 changed files with 153 additions and 432 deletions
|
@ -1,22 +1,29 @@
|
|||
# Change prefix key to C-a, found in in GNU Screen
|
||||
unbind-key C-b
|
||||
|
||||
set-option -g prefix C-a
|
||||
bind-key C-a send-prefix
|
||||
|
||||
# Sane splits
|
||||
# moving
|
||||
bind u previous-window
|
||||
bind i next-window
|
||||
|
||||
bind n new-window -c "#{pane_current_path}"
|
||||
bind n "new-window -c '#{pane_current_path}'"
|
||||
|
||||
bind k split-window -v -c "#{pane_current_path}"
|
||||
bind l split-window -h -c "#{pane_current_path}"
|
||||
# splits
|
||||
bind h "split-window -hb -c '#{pane_current_path}'"
|
||||
bind j "split-window -v -c '#{pane_current_path}'"
|
||||
bind k "split-window -v -b -c '#{pane_current_path}'"
|
||||
bind l "split-window -h -c '#{pane_current_path}'"
|
||||
|
||||
# Rebind command key to ;
|
||||
bind \; command-prompt
|
||||
bind ';' "command-prompt"
|
||||
|
||||
# Reload config on C-r
|
||||
bind C-r source-file ~/.config/tmux/tmux.conf
|
||||
bind C-r "source-file ~/.config/tmux/tmux.conf"
|
||||
|
||||
# session binds
|
||||
bind C-n "new-session -c '#{pane_current_path}' -s '#{b:pane_current_path}'"
|
||||
bind C-x "set-option -g detach-on-destroy on; kill-session"
|
||||
bind X "set-option -g detach-on-destroy off; kill-session; set-option -g detach-on-destroy on"
|
||||
|
||||
# vim: ft=tmux
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
set -g @plugin 'odedlaz/tmux-onedark-theme'
|
||||
set -g @plugin 'tmux-plugins/tpm'
|
||||
set -g @plugin 'tmux-plugins/tmux-battery'
|
||||
|
||||
|
@ -12,11 +11,6 @@ set -g @batt_icon_charge_tier3 ' '
|
|||
set -g @batt_icon_charge_tier2 ' '
|
||||
set -g @batt_icon_charge_tier1 '! !'
|
||||
|
||||
# Change date and time format
|
||||
set -g @onedark_time_format "%I:%M %p"
|
||||
set -g @onedark_date_format "%D"
|
||||
set -g @onedark_widgets "#{battery_icon_charge} #{battery_percentage}"
|
||||
|
||||
set-environment -g TMUX_PLUGIN_MANAGER_PATH '~/.local/share/tmux-plugins'
|
||||
|
||||
# Run tmux-plugin-manager
|
||||
|
|
42
.config/tmux/theme.conf
Normal file
42
.config/tmux/theme.conf
Normal file
|
@ -0,0 +1,42 @@
|
|||
set -g @theme-bg "color0"
|
||||
set -g @theme-fg "color15"
|
||||
set -g @theme-active-bg "color8"
|
||||
set -g @theme-active-fg "color15"
|
||||
set -g @theme-urgent "red"
|
||||
|
||||
# theme
|
||||
set -g status-position "bottom"
|
||||
set -g status-style "bg=#{@theme-bg},fg=#{@theme-fg}"
|
||||
set -g message-style "bg=#{@theme-bg},fg=#{@theme-fg}"
|
||||
set -g status-justify "left"
|
||||
|
||||
# status
|
||||
set -g status-left-length 0
|
||||
set -g status-left "#[bg=#{@theme-active-bg},fg=#{@theme-active-fg}]#{?client_prefix,[#{session_name}],#[bg=#{@theme-bg},fg=#{@theme-fg}][#{session_name}]}#[bg=#{@theme-bg},fg=#{@theme-fg}] "
|
||||
set -g status-right "#{battery_icon_charge} #{battery_percentage} | %a %m/%d %I:%M %P"
|
||||
set -g window-status-format " #I:#W "
|
||||
set -g window-status-current-format "#[bg=#{@theme-active-bg},fg=#{@theme-active-fg}, bold]#{?window_zoomed_flag, #I:#W , #I:#W }"
|
||||
set -g window-status-style "bg=#{@theme-bg},fg=#{@theme-fg}"
|
||||
|
||||
# pane styles
|
||||
set -g pane-border-style "fg=#{@theme-active-bg}"
|
||||
set -g pane-active-border-style "fg=#{@theme-active-fg}"
|
||||
|
||||
# copy mode
|
||||
set -g copy-mode-match-style bg=color227,fg=black
|
||||
set -g copy-mode-current-match-style bg=color229,fg=black
|
||||
set -g mode-style bg=color8,fg=black
|
||||
set -g copy-mode-mark-style default
|
||||
|
||||
# other styles
|
||||
set -g cursor-style block
|
||||
set -g clock-mode-style 12
|
||||
set -g popup-style default
|
||||
set -g popup-border-style default
|
||||
|
||||
set -g window-active-style default
|
||||
set -g window-style default
|
||||
set -g window-status-activity-style reverse
|
||||
set -g window-status-bell-style "bg=#{@theme-urgent}"
|
||||
|
||||
# vim: ft=tmux
|
|
@ -32,14 +32,10 @@ set -g monitor-activity off
|
|||
setw -g aggressive-resize on
|
||||
|
||||
# Change history limit
|
||||
set -g history-limit 4096
|
||||
|
||||
# Default status bar config (doesn't change the behavior of custom status bars)
|
||||
set -g status-justify left
|
||||
set -g status-bg green
|
||||
set -g status-interval 2
|
||||
set -g history-limit 131072
|
||||
|
||||
# Source extra configs
|
||||
source-file ~/.config/tmux/theme.conf
|
||||
source-file ~/.config/tmux/keybinds.conf
|
||||
source-file ~/.config/tmux/plugins.conf
|
||||
source-file ~/.config/tmux/vim.conf
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
is_vim="ps -o state= -o comm= -t '#{pane_tty}'| grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?(view|n?vim?x?)(diff)?$'"
|
||||
TMUX_IS_VIM="ps -o state= -o comm= -t '#{pane_tty}'| grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?(view|n?vim?x?)(diff)?$'"
|
||||
|
||||
bind-key -n M-h if-shell "$is_vim" "send-keys M-h" "select-pane -L"
|
||||
bind-key -n M-j if-shell "$is_vim" "send-keys M-j" "select-pane -D"
|
||||
bind-key -n M-k if-shell "$is_vim" "send-keys M-k" "select-pane -U"
|
||||
bind-key -n M-l if-shell "$is_vim" "send-keys M-l" "select-pane -R"
|
||||
bind-key -n M-h if-shell "$TMUX_IS_VIM" "send-keys M-h" "select-pane -L"
|
||||
bind-key -n M-j if-shell "$TMUX_IS_VIM" "send-keys M-j" "select-pane -D"
|
||||
bind-key -n M-k if-shell "$TMUX_IS_VIM" "send-keys M-k" "select-pane -U"
|
||||
bind-key -n M-l if-shell "$TMUX_IS_VIM" "send-keys M-l" "select-pane -R"
|
||||
|
||||
bind-key -T copy-mode-vi M-h select-pane -L
|
||||
bind-key -T copy-mode-vi M-j select-pane -D
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue