Posted by speckx 3 days ago
unbind C-b
set-option -g prefix C-Space
bind-key C-Space send-prefixVery handy when you make a typo far into a long password and can't keep track of whether you've mashed backspace enough.
edit: oh, and I think Ctrl-space is the keystroke to get a nul character, and vi uses that character to insert the last entered piece of text in insert mode. It looks like Ctrl-@ does the same things, but tmux might not be able to tell the difference either.
Because the author suggested swapping caps lock and control key, I also recommend mapping escape key at the control key and change the behavior based on whether another key is pressed. For example, if you press control + a, it sends c-a, but if you only press control key and then release, it sends escape. It makes your vim life (and in general) a lot easier. You don’t have to compete the most variable real estate on the keyboard, right next to the A key.
For most bindings like moving, resizing, and splitting,I emulate vim bindings.
Also, -r flag for bind-key command is impotent, because it enables to repeat commands like changing the pane size or move focus. You don’t have to press prefix key each time.
If you want to get fancy look with minimal setting, use plugins like nord tmux theme.
For the vim/nvim fans out there, I try my best to add "vim-style" key bindings for navigating between panes, so that e.g. ctrl-h, ctrl-j, ctrl-k, and ctrl-l can be used to move around qukcly. My dotfiles are here:
Disconnecting a session's lifetime from the connection's lifetime hardly need such lengthy tutorial.
And displaying and arranging multiple virtual terminals was supposed to be the job of the terminal emulator and the windowing system.
only now we are seeing gui terminals to integrate such features: wezterm, ghostty, ttypoon, ... so we are discussing tmux because it took more than 40 years for those features to make it to the gui layer.
My hotkey is the backtick, `, rather than a chord.
The one thing I still struggle with - because it happens rarely - is easily copying the contents, full or partial, of a particular pane.
Interesting...I kinda thought that was 90% of the use case for using tmux.
It uses libghostty to restore scrollback history and terminal state.
https://sw.kovidgoyal.net/kitty/sessions/#more-complex-sessi...