Re: Start multiple screen-sessions per script

Frank Röhm <[email protected]>
Newsgroups gmane.comp.gnu.screen.user
Message-ID <[email protected]>
> Am 02.03.2015 um 15:30 schrieb Axel Beckert <[email protected]>:
> … I'm tempted to call it a "screen window”

Yes, I mean a screen window, not a screen session.
I need a way to create new screen windows in a script and in these new windows there should run a script.

> What I did to solve this for myself was to write a script which
> generates a temporary .screenrc (named differently) which basically
> contains the line "source ~/.screenrc" and then one "screen …" line
> per command I want to run in its own screen window inside that
> session.

I tried this but get not the result.

To test it I created a screenrc file “myscreenrc”:

screen /path/to/myscript1.sh
screen /path/to/myscript2.sh

and I start this with:

screen -c myscreenrc

But I don’t get a screen with two windows in it, where one running myscript1.sh and the other running myscript2.sh
I get  just another window, without any command started.

And after a long search in the internet I still don’t know if there is a solution at all for this problem.

Maybe I misunderstood your solution?
Maybe my question was unclear? Again: I need a script doing just this (in a already created screen):

C+a, c, myscript_1.sh, C+a, c, myscript_2.sh, … C+a, c, myscript_n.sh

Can it be this difficult or impossible?


frank



_______________________________________________
screen-users mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/screen-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.