So I have a screen session running on one terminal/machine I would like to write a script that would attach to that screen session on another machine, but to a new window in that screen.
Does anyone know how I can do this? I feel like it might have somethig to do with screen -x (session name) -p (window number)
...if i put "-" as the window number, it goes to a blank screen, but I want a fresh window.
EDIT: Not really looking for a solution anymore myself, a neat tool called "tmux" replaces screen and makes this all trivial.
screen(1)
on one machine, you can log out and retake the conection elsewhere. It even offers the possibility of opening seevral tty's and switch among them. Or do you mean something else?