注解
tmuxp is usable but still needs your help reporting errors, bugs and usability feedback. If you encounter an error, please post on the Issue tracker.
The Tao of tmux¶
tmux is geared for developers and admins who interact regularly with CLI (text-only interfaces)
In the world of computers, there are 2 realms:
- The text realm
- The graphical realm
Tmux resides in the text realm. This is about fixed-width fonts and that old fashioned black terminal.
tmux is to the console what a desktop is to gui apps. It’s a world inside the text dimension. Inside tmux you can:
- multitask inside the terminal, run multiple applications.
- have multiple command lines (pane) in the same window
- have multiple windows (window) in the workspace (session)
- switch between multiple workspaces, like virtual desktops
Overview¶
For Terminals only.¶
No graphics.
Uses:
- window-manager for text-based applications
- keep applications in a background process
Text-based window manager¶
tmux | “Desktop”-Speak | Plain English |
Multiplexer | Multitasking | Do more than one thing at once |
Session | Desktop | Where stuff gets done |
Window | Virtual Desktop or screen | Has windows inside |
Pane | Application | Performs operations |
Multiple terminals in one screen¶
It allows multiple applications or terminals to run at once.
Being able to run 2 or more terminals on one screen is convenient. This way one screen can be used to edit a file, and another may be used to $ tail -F a logfile.
tmux supports as manys terminals as you want.
It allows multiple layouts to view the apps¶
Different applications are viewable better in different layouts.
It allows switching between layouts such as...
Organize apps based on your needs¶
You can categorize and keep many terminals / applications separated into multiple windows.
In addition to being able to split the terminal into multiple panes, you can create new windows as much as you want.
You can switch between the windows you create.
Resume everything later¶
You can leave tmux and all applications running (detach), log out, make a sandwich, and re-(attach), all applications are still running!
Core Concepts¶
Your workflow¶
You can keep tmux on a server with your latest work, come back and resume your “train of thought” and work.
Multitasking. More important than any technical jargon - it’s preserving the thinking you have, whether you were in the midst of a one-off task, or a common task.
If you do a task commonly, it may help to use an application which manages tmux workspaces.
Server¶
A server contains Session‘s.
tmux starts the server automatically if it’s not running.
In advanced cases, multiple can be run by specifying [-L socket-name] and [-S socket-path].
Session¶
Inside a tmux Server.
The session has 1 or more Window. The bottom bar in tmux show a list of windows. Normally they can be navigated with Ctrl-a [0-9], Ctrl-a n and Ctrl-a p.
Sessions can have a session_name.
Uniquely identified by session_id.
Window¶
Entity of a Session.
Can have 1 or more Pane.
panes can be organized with a layouts.
windows can have names.
Target¶
A target, cited in the manual as [-t target] can be a session, window or pane.
License¶
This page is licensed Creative Commons BY-NC-ND 3.0 US.