Questions tagged [tmux]

tmux is terminal multiplexer software, allowing users to work with terminals using multiple windows and panes, which can be created, removed, attached, and reattached as needed.

From the tmux website:

tmux is a terminal multiplexer: it enables a number of terminals (or windows), each running a separate program, to be created, accessed, and controlled from a single screen. tmux may be detached from a screen and continue running in the background, then later reattached.

tmux is largely designed to be a differently designed and BSD-licensed alternative to GNU screen. IRC support can be found in #tmux on the freenode network.

Features:

  • Runs on OpenBSD, FreeBSD, NetBSD, Linux and OS X
  • Panes - similar to the ones found in Vim
  • Client-Server model, allowing windows to be moved across sessions and allowing multiple clients to share the same session
  • 256-color support
  • UTF-8 support

Website:

Screenshot:

tmux session

1106 questions
1973
votes
15 answers

How do I scroll in tmux?

How do I scroll with either the keyboard or mouse? The tmux man page indicates one must enter copy-mode to scroll. Is there a way to quickly scroll without manually entering copy-mode?
chadoh
  • 19,899
638
votes
24 answers

How do I reorder tmux windows?

In screen, I can just type C-a :number 0 to move a window to the top of the window list and push all the other windows down one. What's the equivalent command sequence for tmux? I looked at the man page, but I'm finding it confusing on this point.
dan
  • 7,397
411
votes
6 answers

Restore tmux session after reboot

Is there any way to save a tmux session? In other words, if I reboot the computer, will I always lose the sessions?
KendallB
  • 4,221
328
votes
4 answers

How to convert 2 horizontal panes to vertical panes in tmux?

After doing join-pane on 2 windows, you have 2 horizontal panes. How do I rearrange the panes to be vertical panes instead?
krishonadish
  • 3,391
309
votes
12 answers

"Maximizing" a pane in tmux

Sometimes it would be very useful to maximize a pane in tmux and then restore it to it's previous size. I've been reading the manual and I can't find a way. What I've come up with is that I could bind a key to resize the pane to "max" width, and…
Ivan
  • 4,509
224
votes
4 answers

Move pane to a new window in tmux

I know that it's possible in tmux to join a window as a pane, but is it possible to move a pane to it's own window (tab)? I tried searching it up the man page but couldn't find it. I guess it is possible doing it through a shell script, but is there…
Mikey S.
  • 2,579
213
votes
7 answers

How to detach a tmux session that itself already in a tmux?

I've opened a tmux session on my local machine, and ssh'd into the remote machine. After this, I typed tmux attach on the remote machine, then I got a remote tmux session on my local tmux session. Now I want to detach from the remote tmux session,…
superadmin
  • 2,243
185
votes
7 answers

How does the tmux color palette work?

I'm trying to set something to gray, but can't figure out how. The only bit of info in the man page about colors I can find is: message-bg colour Set status line message background colour, where colour is one of: black, red, green, yellow, blue,…
Lawrence
  • 1,997
  • 3
  • 12
  • 10
177
votes
2 answers

Uppercase "M" at the right of window name in tmux

For some reason, occasionally, an uppercase M appears at the right side of the window name, so the window name looks like this: 1:bash*M I'm pretty sure is because I'm pressing some combination that causes this. What is it and what does it means?
André Wagner
  • 1,903
  • 2
  • 11
  • 6
95
votes
1 answer

On tmux, what is the difference between "bind" and "bind-key"?

On .tmux.conf, what is the difference between "bind" and "bind-key"?
fkreusch
  • 1,053
80
votes
1 answer

Disable the status bar in tmux?

I want to disable the default status bar on tmux. I prefer to treat screen/tmux as persistant session managers, and deprecate the menu/window stuff in favor of my system window manager. I suspect Tmux could be better for this role than screen. And…
clord
  • 903
73
votes
4 answers

Move a tmux pane to another session

Short of doing this, is it possible to move a running command in a pane to another tmux session?
HEGX64
  • 834
60
votes
6 answers

How do I know current tmux session name, by running tmux command

I'm writing a script. I really want to know this. I hope tmux executable can tell me this. I find tmux rename can rename current session. But I can't find a command to fetch its own name.
Jimm Chen
  • 5,904
56
votes
3 answers

Detach the *other* tmux client(s)

I use tmux when working on my desktop, and then if I want to work outside on my laptop I ssh over to the desktop and attach to the same session. Then when I close my laptop and go back inside, the session visible on my desktop is shrunken to show…
51
votes
3 answers

tmux configuration conditional to OS

There's some lines of my tmux.conf which I'd like executed only if my OS is Mac. However, I'd like to use my tmux.conf on multiple different operating systems. How can I make a command conditional to the OS on which tmux is currently running?
muckabout
  • 611
1
2 3
17 18