Feature Request: restart/reload terminal #19926

Open
opened 2026-01-31 06:57:38 +00:00 by claunia · 0 comments
Owner

Originally created by @sparkchaser on GitHub (May 23, 2023).

It would be helpful if a terminal session could be re-started in situ after it closes.

Background:
I build firmware for embedded devices that I control via SSH. I set up a terminal profile that runs the command ssh.exe <IP> <args>, so now I can open a shell and connect to the device's console with just a keystroke. Everything works great, at least until I flash a new firmware image and the device reboots. The underlying ssh process terminates and I get the "process exited" message. That terminal tab is effectively dead and I have to open a new tab to reconnect. If I try to connect before the device is ready, the ssh command in the new tab will time out and I'll have another dead terminal window to close and re-open. Re-connecting to the device and cleaning up all the old terminal windows is a multi-step process, and I often have to do this every 10-15 minutes. It's even more annoying when using quake mode (which I am now addicted to) since the tabs aren't visible.

It would be extremely helpful if in cases like this there was a command to reuse the existing terminal window and re-start that session from scratch. Disconnect the dead process from the terminal, run the terminal's command again, and attach the new process to the existing terminal instead of spawning a new one. PuTTY has a "restart session" command that does exactly this, and it makes it much easier to work with remote devices that reboot or otherwise drop connection. Being able to restart the process and reconnect to the device with a keystroke or context menu option would make my workflow a lot smoother. Retaining the existing scrollback buffer would be a nice bonus, but that's certainly not a requirement.

Originally created by @sparkchaser on GitHub (May 23, 2023). It would be helpful if a terminal session could be re-started in situ after it closes. Background: I build firmware for embedded devices that I control via SSH. I set up a terminal profile that runs the command `ssh.exe <IP> <args>`, so now I can open a shell and connect to the device's console with just a keystroke. Everything works great, at least until I flash a new firmware image and the device reboots. The underlying ssh process terminates and I get the "process exited" message. That terminal tab is effectively dead and I have to open a new tab to reconnect. If I try to connect before the device is ready, the ssh command in the new tab will time out and I'll have *another* dead terminal window to close and re-open. Re-connecting to the device and cleaning up all the old terminal windows is a multi-step process, and I often have to do this every 10-15 minutes. It's even more annoying when using quake mode (which I am now addicted to) since the tabs aren't visible. It would be extremely helpful if in cases like this there was a command to reuse the existing terminal window and re-start that session from scratch. Disconnect the dead process from the terminal, run the terminal's command again, and attach the new process to the *existing* terminal instead of spawning a new one. PuTTY has a "restart session" command that does exactly this, and it makes it much easier to work with remote devices that reboot or otherwise drop connection. Being able to restart the process and reconnect to the device with a keystroke or context menu option would make my workflow a lot smoother. Retaining the existing scrollback buffer would be a nice bonus, but that's certainly not a requirement.
claunia added the Needs-TriageNeeds-Tag-FixNeeds-Attention labels 2026-01-31 06:57:38 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#19926