# TMUX A series of useful commands for navigating and managing Tmux ## Session Management (Terminal Commands) * tmux new -s = starts a new named session; * ctrl + b d = detaches from the current session (leaves it running in the background); * tmux a = reattaches to the last active session; * tmux a -t = reattaches to a specific named session; * tmux ls = lists all active tmux sessions. ## Window Management (Full Screens) * ctrl + b c = opens a new window (terminal); * ctrl + b p = goes to the previous window; * ctrl + b n = goes to the next window; * ctrl + b 1..9 = switches to the specified window number; * ctrl + b , = renames the current window. ## Pane Management (Split Screens) * ctrl + b % = splits the window vertically (side-by-side pane); * ctrl + b " = splits the window horizontally (pane below); * ctrl + b arrow keys = moves between panes on the same split screen; * ctrl + b z = toggles zoom for the current pane (fullscreen on/off); * ctrl + b x = closes the current pane (asks for confirmation). ## Advanced Utilities & Copy Mode * ctrl + b : = opens the tmux command prompt (e.g., type "set -g mouse on" to enable mouse support); * ctrl + b [ = enters "Copy Mode" to scroll through the terminal history. ### How to use Copy Mode: 1. Enter the mode by pressing 'ctrl + b' followed by '[' (a line counter will appear in the top-right corner). 2. Move through the text using the following keys: - Arrow Keys (Up/Down) = scroll line by line; - PageUp / PageDown = scroll page by page; - g (pressed twice) = jump to the very beginning of the history; - G (Shift + g) = jump to the very end (most recent output). 3. Press 'q' (quit) to exit Copy Mode and return to the normal terminal prompt.