[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: sending an arbitary command to a detached session
From: |
Sadrul Habib Chowdhury |
Subject: |
Re: sending an arbitary command to a detached session |
Date: |
Fri, 12 Feb 2010 14:04:48 -0500 |
User-agent: |
Mutt/1.5.18 (2008-05-17) |
* Faheem Mitha had this to say on [12 Feb 2010, 08:22:25 -0500]:
>
> Hi,
>
>> From the screen documentation, it looks like something similar to the
> following should work, but it doesn't. If it is not already clear from
> the commands below, I want to send an arbitrary command to run in a
> detached screen instance. Any recipe that works would be appreciated.
> Please CC me on any reply.
>
> Regards, Faheem
>
> *********************************************************************
>
> # create detached foo screen instance
> address@hidden:~$ screen -dmS foo
> address@hidden:~$ screen -ls
> There is a screen on:
> 30938.foo (02/12/2010 06:39:33 PM) (Detached)
> 1 Socket in /var/run/screen/S-faheem.
>
> address@hidden:~$ screen -S foo -X emacs -nw somefile
> address@hidden:~$ screen -r foo
> # attaching to the foo screen session but nothing there
You can run screen-commands with 'X', and 'emacs' is not a screen
command! You would want something like the following instead:
screen -S foo -X screen emacs -nw somefile
Cheers,
Sadrul