Part of the Beginner's Guide series:
- Git Command Guide
- Coding Python in Linux Server
- Create A Site by Hugo
- Using tmux to manage your terminalThis post!
- Tensorboard Cheet Sheet (SummaryWriter)
- Debugging Python with pdb
- Customize your PyTorch Dataset
- Cheetsheet for Python os module
The main purpose for me to use tmux is to keep my program running even if I close the terminal.
Basic Usage
Command | Description |
---|---|
tmux |
Start a new session |
tmux new -s <session-name> |
Start a new session with name |
tmux ls |
List all sessions |
tmux kill-session -t <session-name> |
Kill a session |
tmux attach -t <session-name> |
Attach to a session |
tmux detach |
Detach from a session |
Other Commands
Command | Description |
---|---|
tmux rename-session -t <old-name> <new-name> |
Rename a session |
tmux switch -t <session-name> |
Switch to a session |
tmux a |
Attach to the last session |
tmux list-keys |
List all key bindings |
tmux list-commands |
List all commands and their arguments |
tmux info |
Show information about the current session |
Installation
On Ubuntu, you can install tmux using the following command:
bash1sudo apt install tmux