Personal tmux configuration with plugin management via tpm and an auto-attach shell function.
- tpm — plugin manager
- tmux-resurrect — persist and restore sessions across restarts
- tmux-cpu — CPU/RAM stats in the status bar
git clone https://github.com/zarei-dev/tmux-config.git ~/dotfiles
cd ~/dotfiles
chmod +x setup.sh
./setup.sh
source ~/.bashrcsetup.sh will:
- Install tmux (apt) if missing
- Symlink
.tmux.confto~/.tmux.conf(existing file backed up) - Clone tpm and install all plugins
- Add an auto-attach
tmux()function to~/.bashrc
After setup, typing tmux with no arguments will reattach to the last session or create a new one. Pass arguments normally (e.g. tmux ls) and they work as expected.
| Keys | Action |
|---|---|
prefix + r |
Reload config |
prefix + | |
Split vertical (current path) |
prefix + - |
Split horizontal (current path) |
prefix + c |
New window (current path) |
Alt + Arrow |
Navigate panes (no prefix) |
Shift + Arrow |
Switch windows (no prefix) |
prefix + Ctrl + Arrow |
Resize pane |
Default prefix is Ctrl + b.