
Ask HN: Which is better tmux or screen? - archmonk
Before you go on pointing me to archives or asking me to google understand that I have done that. 
The reason for asking is all the comparisons are by now old. I ask now because both might have progressed a long way. 
I personally use tmux but am not a pro user. I want to know if there is something that tmux has that screen doesn&#x27;t have or vice versa.
I would also like to know which is more light weight, more configurable.<p>Also I would really like to know the scenario of how you use either.<p>Thanks,<p>AM
======
dllthomas
I use screen, but there's no real reason for it but inertia. I don't know of
anything it does better than tmux (except, perhaps, being available more
places).

I use it, plus some scripts, to keep my work separated into various contexts.
See [https://github.com/dlthomas/config-
files/blob/master/bin/ses...](https://github.com/dlthomas/config-
files/blob/master/bin/session) and [https://github.com/dlthomas/config-
files/blob/master/.bash.d...](https://github.com/dlthomas/config-
files/blob/master/.bash.d/session.bashrc)

The single biggest win is keeping a separate bash history per context. But
it's also very handy to define context specific functions and aliases, cd at
start to a relevant directory, etc.

Putting it all inside screen means that I can trivially start a new shell in
the same context and gives a nice grouping.

~~~
archmonk
Interesting I didn't know that in screen you could isolate bash history per
context.

~~~
dllthomas
It's not screen doing the work.

Screen is just a process that spawns other processes, and like always those
inherit environment variables. The script I have that starts screen defines a
variable called "SESSION" beforehand, and that's used in my bashrc to set
HISTFILE (and other things). Screen is just how I organize it.

------
sigjuice
I don't think tmux can talk to serial ports. I am primarily a tmux user, but
use screen if I need a serial console. e.g.

    
    
       screen /dev/ttyUSB0 115200

------
mod
I've never used screen, but I love tmux.

I particularly love tmuxinator and using it to set up complex environments,
like sourcing a virtualenv in python on all my windows/panes.

I use tmux for my main development environment, which usually has:

Window 1 (2 panes): vim and tests Window 2: bash console, used for git or one-
off tasks Window 3: console (python/ruby REPL, usually) Window 4: localhost
server (running whatever webapp I'm working on)

------
caspervonb
Use screen mostly, reason is simple, its the one i started using first and
it's installed by default on most servers.

Objectively, I really don't know.

~~~
__DarkBlue
Same here. I use screen mostly because it's generally available, whereas tmux
usually has to be installed.

------
jtchang
I've used both. I kinda like how tmux has a bottom bar by default. Both are
super stable and I haven't had either crash on me ever.

Configuring both are kinda of a pain. I can never seem to get scroll to work
properly in mac os x. I don't think I ever tried in screen. tmux is shorter
character wise :)

