emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: screen & emacs


From: Sam Steingold
Subject: Re: screen & emacs
Date: Thu, 03 Feb 2011 12:28:10 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

> * Justin Lilly <address@hidden> [2011-02-02 23:58:18 -0500]:
>
> It seems as if you should be able to run a daemonized emacs. Multiple
> clients can then connect to it without stealing each other's
> connection.

thanks for the suggestion, I tried "emacs -daemon".

1. For many years I have been running emacs under gdb at all times.
It appears no longer to be an option with -daemon.

2. Unless used with "-c", emacsclient connecting to the daemon under
screen seems to default to "-nw" (or maybe it depends on DISPLAY? - I am
still somewhat confused about the interplay between DISPLAY & ssh/ForwardX11).
I tried that for a while and discovered that M-<left> et al do not work
(I need to do Esc-<left> &c).

3. When Emacs is started as a daemon, it loads .emacs with window-system
set to nil. This means that when the client opens an X window (emacs
frame), it has the settings in .emacs which are "appropriate" for a
terminal, not a GUI. I am not sure how to handle this properly, except
for remove all (when window-system ...) from .emacs.

just for the reference, my original request:

> On Wed, Feb 2, 2011 at 11:44 PM, Sam Steingold <address@hidden> wrote:
>> I use gnu screen on a server S to which I connect using ssh from various
>> client boxes (e.g., a windows desktop D and a linux laptop L).
>> This is great: I always see the same shell sessions on S regardless
>> where I connect from.
>> There is only one problem: I run ssh with ForwardX11=yes, so when I
>> start emacs on S, I see the usual GUI window on D or L (I still have to
>> figure out the right setting for DISPLAY for some reason) which is
>> precisely what I want.
>> Alas, when I open an emacs on S while connected from D and then go over
>> to L and ssh to S, then the screen session gets stolen from D and
>> appears on L, __BUT__ the emacs window (again, emacs is running on S,
>> but the window is shown on D) stays on D and does not go over to L
>> automagically.
>> Is there a way around this (except for "emacs -nw")?
>>
>> PS. One thing I hate about screen is that it does not terminate
>> "gracefully" on reboot: it is killed so the bash histories of various
>> widows are not saved...

-- 
Sam Steingold (http://sds.podval.org/) on gnu/linux terminal
http://iris.org.il http://www.PetitionOnline.com/tap12009/
http://dhimmi.com http://ffii.org http://thereligionofpeace.com
If you think big enough, you'll never have to do it.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]