Skip to content

sasoe-git/tmux-custom

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

Tmux Configuration

Tmux configuration, that supercharges your tmux and builds cozy and cool terminal environment. This repository is custom version from samoshkin/tmux-config, thanks to him (https://github.com/samoshkin/tmux-config)

intro

Features

  • "C-a" prefix instead of "C-b" (screen like)
  • support for nested tmux sessions
  • scroll and copy mode improvements
  • supercharged status line
  • renew tmux and shell environment (SSH_AUTH_SOCK, DISPLAY, SSH_TTY) when reattaching back to old session
  • prompt to rename window right after it's created
  • newly created windows and panes retain current working directory
  • monitor windows for activity/silence
  • highlight focused pane
  • merge current session with existing one (move all windows)
  • configurable visual theme/colors, with some elements borrowed from Powerline
  • integration with 3rd party plugins: tmux-sidebar, tmux-copycat, tmux-open, tmux-plugin-sysstat

Status line widgets:

  • CPU, memory usage, system load average metrics
  • username and hostname, current date time
  • visual indicator when you press prefix
  • visual indicator when you're in Copy mode
  • visual indicator when pane is zoomed
  • online/offline visual indicator
  • toggle visibility of status line

Installation

Prerequisites:

  • tmux >= "v2.4"
  • OSX, Linux (tested on Ubuntu 14 and CentOS7), FreeBSD (tested on 11.1)

To install tmux-config:

$ git clone https://github.com/sasoe-git/tmux-custom.git
$ ./tmux-config/install.sh

install.sh script does following:

  • copies files to ~/.tmux directory
  • symlink tmux config file at ~/.tmux.conf, existing ~/.tmux.conf will be backed up
  • Tmux Plugin Manager will be installed at default location ~/.tmux/plugins/tpm, unless already presemt
  • required tmux plugins will be installed

Finally, you can start new tmux session:

$ tmux new

Key bindings

tmux key Description iTerm2 key
C-a Default prefix, used instead of "C-b". Same prefix is used in screen program, and it's easy to type. The only drawback of "C-a" is that underlying shell does not receive the keystroke to move to the beginning of the line. -
<prefix> C-e Open ~/.tmux.conf file in your $EDITOR -
<prefix> C-r Reload tmux configuration from ~/.tmux.conf file -
<prefix> r Rename current window -
<prefix> R Rename current session -
<prefix> _ Split new pane horizontally ⌘⇧D
<prefix> | Split new pane vertically ⌘D
<prefix> < Select next pane ⌘[
<prefix> > Select previous pane ⌘]
<prefix> ← Select pane on the left ⌘⌥←
<prefix> → Select pane on the right ⌘⌥→
<prefix> ↑ Select pane on the top ⌘⌥↑
<prefix> ↓ Select pane on the bottom ⌘⌥↓
<prefix> C-← Resize pane to the left ^⌘←
<prefix> C-→ Resize pane to the right ^⌘→
<prefix> C-↑ Resize pane to the top ^⌘↑
<prefix> C-↓ Resize pane to the bottom ^⌘↓
<prefix> > Move to next window ⌘⇧]
<prefix> < Move to previous window ⌘⇧[
<prefix> Tab Switch to most recently used window ^Tab
<prefix> L Link window from another session by entering target session and window reference -
<prefix> \ Swap panes back and forth with 1st pane. When in main-horizontal or main-vertical layout, the main panel is always at index 1. This keybinding let you swap secondary pane with main one, and do the opposite. ⌘\
<prefix> C-o Swap current active pane with next one -
<prefix> + Toggle zoom for current pane ⌘⇧Enter
<prefix> x Kill current pane ⌘W
<prefix> X Kill current window ⌘⌥W
<prefix> C-x Kill other windows but current one (with confirmation) -
<prefix> Q Kill current session (with confirmation) -
<prefix> C-u Merge current session with another. Essentially, this moves all windows from current session to another one -
<prefix> d Detach from session -
<prefix> D Detach other clients except current one from session -
<prefix> C-s Toggle status bar visibility -
<prefix> m Monitor current window for activity -
<prefix> M Monitor current window for silence by entering silence period -
<prefix> F12 Switch off all key binding and prefix hanling in current window. See "Nested sessions" paragraph for more info -

About

customized tmux configuration

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages