summaryrefslogtreecommitdiffstats
path: root/roles/common/files/tmux.conf
blob: ee0fa523b5e7a78bc549cda09cb4c1f8e43a4422 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
# reload changes in tmux, handy
bind r source-file ~/.tmux.conf \; display "Reloaded!"

# changing the status line colour
# set-option -g status-style bg=blue

# Moveing between windows.
# Provided you've mapped your `CAPS LOCK` key to the `CTRL` key,
# you can now move between panes without moving your hands off the home row.
# bind -r C-k select-window -t :-
# bind -r C-l select-window -t :+

# Set the base index for windows to 1 instead of 0.
set -g base-index 1
# make pane numbering consistent with windows
setw -g pane-base-index 1

# Mouse support - set to on if you want to use the mouse.
# set -g mouse on

# Set the default terminal mode to 256color mode.
set -g default-terminal "screen-256color"

# center align the window list
set -g status-justify centre

# Update history size.
set -sgw history-limit 102400

# Defines the string that'd be used for the parent terminal.
set -sgw set-titles-string "tmux(p:#P w:#I) s:#S - p:#W (#T)"

# Renumber windows when a window is closed
set-option -g renumber-windows on

# Highlighting Current Window Using Specified Colour
set-window-option -g window-status-current-bg red

# Use tmux windows like tabs
#bind -n C-left swap-window -t -1
#bind -n C-right swap-window -t +1

# Copy mode comme dans emacs
setw -g mode-keys emacs

# add uptime in status right
set -g status-right-length 60
#set -g status-right '#[fg=red,bg=default]epoch: #(uptime | cut -d " " -f 4,5,6,7) #[fg=blue]|| %Y-%m-%d %H:%M %a '
set -g status-right '#[fg=red,bg=default]epoch: #(uptime -s) #[fg=blue]|| %Y-%m-%d %H:%M %a '

# recording  program output to a log
bind P pipe-pane -o "cat >> ~/logs/#W-$(date +%Y%m%d-%H%M%S).log.bin" \; display "Toggled logging"

# Design part