I am fairly familiar with Linux, I’ve been using different distros for some years now and have done some config editing here and there. I am also a web developer and use the terminal quite a lot and so I always stumble on people’s recommendation to use tmux and how good it is, but I never really understood what it does and, in layman’s terms, how can it be useful and for what use cases.
Can you guys please enlight me a bit on this?
Thank you.
Edit: if my phrasing is a bit awkward or confusing I apologize since I am not an English native speaker. (Maybe that’s why I never fully grasped what tmux is from other explanations xD)
To understand why you might want to use tmux try the following:
You will have lost your progress, next we can repeat but this time using tmux so you don’t lose your session:
tmux
tmux a
to re-attach to the existing sessionNote that this time none of your progress is lost.
Aside from enabling you to have a persistent session, tmux also allows you to have multiple terminal panes open so you can do more than one thing at a time in the window, to see what I mean try this:
tmux
top
to begin listing processesctrl b
then%
to make a new split panels
or other terminal commandsYou will see that you can use more than one panel to do things. This can be useful for example if you want to watch run tests and also run other commands.
All of this is way more useful when all you have to work with is a tty or an ssh session. No X? No problem.