Updated .tmux.conf
I'm not even sure what is different now, but the `.tmux.conf` in the repo was so old and the `diff` was extensive. All I know is that this is the current `.tmux.conf` I use everywhere now (circa 2/2024) I also updated the README and removed the `.gitignore`
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1 +0,0 @@
|
||||
tmux-menu.sh
|
||||
43
.tmux.conf
43
.tmux.conf
@@ -1,7 +1,3 @@
|
||||
# use UTF8
|
||||
set -g utf8
|
||||
set-window-option -g utf8 on
|
||||
|
||||
## make tmux display things in 256 colors
|
||||
set -g default-terminal "screen-256color"
|
||||
|
||||
@@ -58,30 +54,20 @@ bind L resize-pane -R 5
|
||||
## set some pretty colors
|
||||
## ----------------------
|
||||
## set pane colors - hilight the active pane
|
||||
set -g pane-border-bg colour0
|
||||
set -g pane-border-fg colour1
|
||||
set -g pane-active-border-bg colour8
|
||||
set -g pane-active-border-fg colour2
|
||||
set -g pane-border-style bg=colour0,fg=colour1
|
||||
set -g pane-active-border-style bg=colour8,fg=colour2
|
||||
|
||||
## colorize messages in the command line
|
||||
set-option -g message-bg colour0
|
||||
set-option -g message-fg colour9
|
||||
set-option -g message-style bg=colour0,fg=colour9
|
||||
|
||||
#set inactive/active window styles
|
||||
set -g window-style 'fg=colour247,bg=colour236'
|
||||
set -g window-active-style 'fg=colour250,bg=black'
|
||||
|
||||
# set the pane border colors
|
||||
#set -g pane-border-fg colour250
|
||||
#set -g pane-border-bg colour236
|
||||
#set -g pane-active-border-fg colour250
|
||||
#set -g pane-active-border-bg colour250
|
||||
set -g window-style fg=colour247,bg=colour236
|
||||
set -g window-active-style fg=colour250,bg=black
|
||||
|
||||
## ----------------------
|
||||
## Status Bar
|
||||
## -----------------------
|
||||
set-option -g status on # turn the status bar on
|
||||
set -g status-utf8 on # set utf-8 for the status bar
|
||||
set -g status-interval 5 # set update frequencey (default 15 seconds)
|
||||
set -g status-justify centre # center window list for clarity
|
||||
|
||||
@@ -90,23 +76,20 @@ setw -g monitor-activity on
|
||||
set -g visual-activity on
|
||||
|
||||
## set color for status bar
|
||||
set-option -g status-bg colour0
|
||||
set-option -g status-fg colour7
|
||||
set-option -g status-attr bright
|
||||
set-option -g status-style bg=colour0,fg=colour7,bright
|
||||
|
||||
## set window list colors
|
||||
set-window-option -g window-status-fg colour6
|
||||
set-window-option -g window-status-bg colour0
|
||||
set-window-option -g window-status-attr dim
|
||||
|
||||
set-window-option -g window-status-current-fg colour11
|
||||
set-window-option -g window-status-current-bg colour0
|
||||
set-window-option -g window-status-current-attr bright
|
||||
set-window-option -g window-status-style fg=colour8,bg=colour0,bright
|
||||
set-window-option -g window-status-current-style fg=colour35,bg=colour0,bright
|
||||
|
||||
## show host name and IP address on left side of status bar
|
||||
set -g status-left-length 70
|
||||
set -g status-left "#[fg=colour7]#h : #(ifconfig eth0 | grep 'inet ' | awk '{print $2}') "
|
||||
set -g status-left "#[fg=colour7]#h"
|
||||
|
||||
## show session name, window & pane number, date and time on right side of status bar
|
||||
set -g status-right-length 60
|
||||
set -g status-right "#[fg=colour7]#S w#I:p#P | %b %d | %H:%M"
|
||||
|
||||
# These make tmux transparent again
|
||||
set -g "window-style" "bg=default"
|
||||
set -g "window-active-style" "bg=default"
|
||||
|
||||
14
README.md
14
README.md
@@ -14,7 +14,7 @@ After I discovered tmux I searched for a way to manage multiple groups of tmux s
|
||||
|
||||
Not finding anything (or maybe just not looking well enough) I decided to write my own.
|
||||
|
||||
It ain't pretty, but I've been using for a couple of years now and it's become an integral part of my workflow.
|
||||
It's not pretty, but I've been using for a couple of years now and it's become an integral part of my workflow.
|
||||
|
||||
My setup works this way:
|
||||
|
||||
@@ -55,11 +55,14 @@ case $session in
|
||||
;;
|
||||
```
|
||||
|
||||
Calling the script with a pre-determined session name (ex: `./tmux-menu.sh web` or `./tmux-menu.sh database`) first checks to see if there is already a session group with that name. If not, it creates a new group with the commands you specify and names each connection in tmux.
|
||||
Calling the script with a pre-determined session name (ex: `./tmux-menu.sh web` or `./tmux-menu.sh database`) first
|
||||
checks to see if there is already a session group with that name. If not, it creates a new group with the commands you
|
||||
specify and names each connection in tmux.
|
||||
|
||||
If the session group *does* already exist, it simply switches you to that group.
|
||||
|
||||
If you alias `tmux-menu.sh` to something shorter (like `tm`), switching between active sessions is as easy as `Ctrl-A + d` (to detach) and `tm web` (to attach or create the web group).
|
||||
If you alias `tmux-menu.sh` to something shorter (like `tm`), switching between active sessions is as easy as `Ctrl-A +
|
||||
d` (to detach) and `tm web` (to attach or create the web group).
|
||||
|
||||
Killing session groups is as easy as `tmux-session kill -t web`.
|
||||
|
||||
@@ -67,6 +70,7 @@ Killing session groups is as easy as `tmux-session kill -t web`.
|
||||
|
||||
## Use
|
||||
|
||||
I've found that I use this script on different servers with different configurations. So I copy the `tmux-menu.template.sh` to `tmux-menu.sh` and then alias that to `tm`. My `.gitignore` prevents the customized `tmux-menu.sh` from being version controlled.
|
||||
I've found that I use this script on different servers with different configurations. So I copy the
|
||||
`tmux-menu.template.sh` to `$HOME/tmux-menu.sh` and then alias that to `tm`.
|
||||
|
||||
I also include my `/.tmux.conf` file with comments about what does what. If you choose to use it, make sure to copy it to your home directory.
|
||||
I also include my `.tmux.conf` file with comments about what does what. If you choose to use it, make sure to copy it to your home directory.
|
||||
|
||||
Reference in New Issue
Block a user