60 lines
1001 B
Markdown
60 lines
1001 B
Markdown
|
---
|
|||
|
title: "TMUX Cheat Sheet"
|
|||
|
date: 2022-04-08T13:20:00+02:00
|
|||
|
draft: false
|
|||
|
type: "post"
|
|||
|
---
|
|||
|
|
|||
|
Default prefix “key” is `Ctrl + b`.
|
|||
|
|
|||
|
Sessions
|
|||
|
--------
|
|||
|
|
|||
|
Creating a new named session:
|
|||
|
|
|||
|
tmux new-session -s <name>
|
|||
|
|
|||
|
|
|||
|
Listing all sessions:
|
|||
|
|
|||
|
tmux list-session
|
|||
|
|
|||
|
|
|||
|
Attach to a running session:
|
|||
|
|
|||
|
tmux attach -t <name>
|
|||
|
|
|||
|
|
|||
|
To detach from a session, press: `<Prefix> + d`
|
|||
|
|
|||
|
Renaming a session:
|
|||
|
|
|||
|
tmux rename-session -t <old-name> <new-name>
|
|||
|
|
|||
|
|
|||
|
Kill a session:
|
|||
|
|
|||
|
tmux kill-session -t <name>
|
|||
|
|
|||
|
|
|||
|
Windows
|
|||
|
-------
|
|||
|
|
|||
|
To create a new window, within a session press: `<Prefix> + c`.
|
|||
|
|
|||
|
To list all windows, press: `<Prefix> + w`. The list also allows us to select a window using `UP, DOWN` and `ENTER`.
|
|||
|
|
|||
|
To rename a window, press: `<Prefix> + ,`.
|
|||
|
|
|||
|
To terminate a window, press: `<Prefix> + &`.
|
|||
|
|
|||
|
Copy-Mode
|
|||
|
---------
|
|||
|
|
|||
|
To enter copy mode, press: `<Prefix> + [`.
|
|||
|
|
|||
|
Begin selection with: `<Prefix> + Space`.
|
|||
|
|
|||
|
Hit `ENTER` to copy the selected text to tmux’s clipboard.
|
|||
|
|
|||
|
Paste with `<Prefix> + ]`.
|