Split in folders

This commit is contained in:
Georgi Gardev
2024-03-04 23:56:20 +02:00
parent 8d30d8f42c
commit 57d074b3a2
9 changed files with 15 additions and 8 deletions
+154
View File
@@ -0,0 +1,154 @@
# ------------------
# General Settings
# ------------------
# See: https://github.com/gpakosz/.tmux/blob/master/.tmux.conf
# Set Custom Prefix
set -g prefix C-a
unbind C-b
# Start in newer bash
set-option -g default-command "/usr/local/bin/bash --login"
# Disable delay
set -sg escape-time 1
set -g base-index 1 # start windows numbering at 1
setw -g pane-base-index 1 # make pane numbering consistent with windows
set -q -g status-utf8 on # expect UTF-8 (tmux < 2.2)
setw -q -g utf8 on
# -------------------
# Visual Settings
# -------------------
set -g default-terminal "screen-256color"
source-file ~/.tmux/themes/tomorrow-night.tmux
# Theme Variables
TMUX_ACTIVE_COLOR="#373b41"
TMUX_STATUS_TEXT_COLOR="#c5c8c6"
TMUX_STATUS_BG="#26292c"
TMUX_NAMESPACE_FG="#000000"
TMUX_STATUS_RED="#cc6666"
TMUX_USERNAME_FG="#000000"
TMUX_STATUS_AQUA="#8abeb7"
# Styles
STYLE_DEFAULT="fg=white,bg=$TMUX_STATUS_BG"
STYLE_ACTIVE_ITEM="#[fg=$TMUX_STATUS_TEXT_COLOR,bg=$TMUX_ACTIVE_COLOR,noreverse,bold]"
STYLE_RED="#[fg=$TMUX_NAMESPACE_FG,bg=$TMUX_STATUS_RED,bold]"
STYLE_AQUA="#[fg=$TMUX_USERNAME_FG,bg=$TMUX_STATUS_AQUA,bold]"
# Status bar
set-option -g status-position bottom
# Status mid style
set -g status-style $STYLE_DEFAULT
set -g status-left "#{prefix_highlight}$STYLE_RED #S #[fg=$TMUX_STATUS_RED,bg=$TMUX_STATUS_AQUA,bold]$STYLE_AQUA #(whoami) #[fg=$TMUX_STATUS_AQUA,bg=$TMUX_STATUS_BG,bold] "
set -g status-left-length 30
PC_STATS="$STYLE_ACTIVE_ITEM cpu #{cpu_icon} #{cpu_percentage} #[$STYLE_DEFAULT] $STYLE_ACTIVE_ITEM mem #{ram_icon} #{ram_percentage} #[$STYLE_DEFAULT]"
set -g status-right "$PC_STATS #[fg=$TMUX_STATUS_AQUA,bg=$TMUX_STATUS_BG,bold]$STYLE_AQUA #h #[fg=$TMUX_STATUS_RED,bg=$TMUX_STATUS_AQUA,bold]$STYLE_RED %a, %h %d %H:%M "
set -g status-right-length 90
# window name options
# set -g window-status-format "#[$STATUS_DEFAILT] #I #W "
# set -g window-status-current-format "$TYLE_ACTIVE_ITEM] #I #W "
# Prefix style
# https://github.com/tmux-plugins/tmux-prefix-highlight
set -g @prefix_highlight_fg $TMUX_STATUS_TEXT_COLOR
set -g @prefix_highlight_bg $TMUX_ACTIVE_COLOR
# --------------------
# Custom keybindings
# --------------------
set -g mouse on
bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'copy-mode -e'"
setw -g mode-keys vi
bind C-a send-prefix
# Unbind unused defaults
unbind %
unbind [
unbind p
unbind Up
unbind Down
unbind Left
unbind Right
unbind M-Up
unbind M-Down
unbind M-Left
unbind M-Right
unbind C-Up
unbind C-Down
unbind C-Left
unbind C-Right
# Source this file
bind r source-file ~/.tmux.conf \; display "Config file reloaded!"
# split current window horizontally
bind v split-window -h
bind | split-window -h
# split current window vertically
bind s split-window -v
bind - split-window -v
# Swap panes
bind-key -r "<" swap-window -d -t -1
bind-key -r ">" swap-window -d -t +1
bind-key -r n swap-pane -U
# Move between panes
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# Move between windows
bind -r C-h select-window -t :-
bind -r C-l select-window -t :+
# Resize panes
bind -r H resize-pane -L 5
bind -r J resize-pane -D 5
bind -r K resize-pane -U 5
bind -r L resize-pane -R 5
# Copy & Paste
bind Escape copy-mode
bind b list-buffers # list paste buffers
bind p paste-buffer # paste last buffer
bind P choose-buffer # see all buffers
bind C-c run-shell "bash -c 'tmux show-buffer | pbcopy'" \; display 'Copied to clipboard'
# Tmux Plugin manager
# https://github.com/tmux-plugins/tpm
# Enabled plugins
# install prefix I
# update prefix u
# uninstall all prefix alt u
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-cpu'
set -g @plugin 'tmux-plugins/tmux-prefix-highlight'
run -b '~/.tmux/plugins/tpm/tpm'
+72
View File
@@ -0,0 +1,72 @@
# https://github.com/edouard-lopez/tmux-tomorrow/
# Color key:
# #1d1f21 Background
# #282a2e Current Line
# #373b41 Selection
# #c5c8c6 Foreground
# #969896 Comment
# #cc6666 Red
# #de935f Orange
# #f0c674 Yellow
# #b5bd68 Green
# #8abeb7 Aqua
# #81a2be Blue
# #b294bb Purple
## set status bar
set -g status-style bg=default
setw -g window-status-current-style bg="#282a2e"
setw -g window-status-current-style fg="#81a2be"
## highlight active window
setw -g window-style 'bg=#282a2e'
setw -g window-active-style 'bg=#1d1f21'
setw -g pane-active-border-style ''
## highlight activity in status bar
setw -g window-status-activity-style fg="#8abeb7"
setw -g window-status-activity-style bg="#1d1f21"
## pane border and colors
set -g pane-active-border-style bg=default
set -g pane-active-border-style fg="#373b41"
set -g pane-border-style bg=default
set -g pane-border-style fg="#373b41"
set -g clock-mode-colour "#81a2be"
set -g clock-mode-style 24
set -g message-style bg="#8abeb7"
set -g message-style fg="#000000"
set -g message-command-style bg="#8abeb7"
set -g message-command-style fg="#000000"
# message bar or "prompt"
set -g message-style bg="#2d2d2d"
set -g message-style fg="#cc99cc"
set -g mode-style bg="#1d1f21"
set -g mode-style fg="#de935f"
# right side of status bar holds "[host name] (date time)"
set -g status-right-length 100
set -g status-right-style fg=black
set -g status-right-style bold
set -g status-right '#[fg=#f99157,bg=#2d2d2d] %H:%M |#[fg=#6699cc] %y.%m.%d '
# make background window look like white tab
set-window-option -g window-status-style bg=default
set-window-option -g window-status-style fg=white
set-window-option -g window-status-style none
set-window-option -g window-status-format '#[fg=#6699cc,bg=colour235] #I #[fg=#999999,bg=#2d2d2d] #W #[default]'
# make foreground window look like bold yellow foreground tab
set-window-option -g window-status-current-style none
set-window-option -g window-status-current-format '#[fg=#f99157,bg=#2d2d2d] #I #[fg=#cccccc,bg=#393939] #W #[default]'
# active terminal yellow border, non-active white
set -g pane-border-style bg=default
set -g pane-border-style fg="#999999"
set -g pane-active-border-style fg="#f99157"