Keep Your Work Running
A mobile connection can disappear when you change networks, lock the screen, or put the app in the background. Mightty supports two complementary tools for making that less disruptive.
Know what each tool keeps alive
- Mosh makes the connection more tolerant of changing networks and temporary loss of connectivity. It does not keep a remote process alive after the session itself ends.
- tmux runs on the host and keeps the shell, commands, and agents alive even when your device disconnects.
Use Auto transport for a convenient Mosh-to-SSH connection choice, and use a tmux destination for work that needs to survive a disconnect.
Choose where to start
After selecting a host, Mightty can show several destinations:
- Start Shell opens a regular shell. Use it for a quick check or a short command.
- New tmux session starts durable work on the host.
- An existing tmux session returns to work that is already running.
- Recent reopens a recently used project directory when one is available.
If you expect a build, agent, server, or long command to keep running, start it inside tmux rather than a regular shell.
Install tmux when it is missing
On macOS:
brew install tmux
On Debian or Ubuntu:
sudo apt update
sudo apt install tmux
Return to the host in Mightty after installation. You can also enable tmux by default in Settings → Terminal → Behavior & Sessions.
Leave and return
You do not need to stop the remote command before leaving Mightty. When you return, select the same host and choose the existing tmux session. The terminal reconnects to the process on the host rather than starting over.
For earlier output, first scroll normally in the terminal. Inside tmux, press Ctrl-b, then [, to enter copy mode; press / to search and q to leave copy mode.
If an existing session is missing or Mosh repeatedly falls back to SSH, see Fix Connection Problems.