all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* attaching to a running emacs process under linux?
@ 2008-01-16  2:18 ivowel
  2008-01-16  5:16 ` Dmitry Dzhus
  2008-01-16 19:24 ` Eli Zaretskii
  0 siblings, 2 replies; 4+ messages in thread
From: ivowel @ 2008-01-16  2:18 UTC (permalink / raw)
  To: help-gnu-emacs


is there a way to send a shell signal to ask emacs nicely to save all
its open buffers?  I sometimes forget to save my buffers, then go
somewhere else and ssh into the original machine, just to find that
emacs still has my unsaved changes.

/iaw

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: attaching to a running emacs process under linux?
  2008-01-16  2:18 attaching to a running emacs process under linux? ivowel
@ 2008-01-16  5:16 ` Dmitry Dzhus
  2008-01-16 13:57   ` Matthias Pfeifer
  2008-01-16 19:24 ` Eli Zaretskii
  1 sibling, 1 reply; 4+ messages in thread
From: Dmitry Dzhus @ 2008-01-16  5:16 UTC (permalink / raw)
  To: help-gnu-emacs

ivowel <ivowel@gmail.com> writes:

> is there a way to send a shell signal to ask emacs nicely to save all
> its open buffers?

Make sure Emacs server is running and use the following command:

    $ emacsclient -e '(save-some-buffers t)'

-- 
Happy Hacking.

http://sphinx.net.ru^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: attaching to a running emacs process under linux?
  2008-01-16  5:16 ` Dmitry Dzhus
@ 2008-01-16 13:57   ` Matthias Pfeifer
  0 siblings, 0 replies; 4+ messages in thread
From: Matthias Pfeifer @ 2008-01-16 13:57 UTC (permalink / raw)
  To: help-gnu-emacs

Dmitry Dzhus wrote:

> Make sure Emacs server is running and use the following command:
> 
>     $ emacsclient -e '(save-some-buffers t)'
> 

I guess that is not what the OP had in mind. I guess he is experiencing
some autosave feature.


matt

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: attaching to a running emacs process under linux?
  2008-01-16  2:18 attaching to a running emacs process under linux? ivowel
  2008-01-16  5:16 ` Dmitry Dzhus
@ 2008-01-16 19:24 ` Eli Zaretskii
  1 sibling, 0 replies; 4+ messages in thread
From: Eli Zaretskii @ 2008-01-16 19:24 UTC (permalink / raw)
  To: help-gnu-emacs

> From: ivowel <ivowel@gmail.com>
> Date: Tue, 15 Jan 2008 18:18:18 -0800 (PST)
> 
> 
> is there a way to send a shell signal to ask emacs nicely to save all
> its open buffers?  I sometimes forget to save my buffers, then go
> somewhere else and ssh into the original machine, just to find that
> emacs still has my unsaved changes.

Read about sigusr1 and sigusr2 events in the "Misc Events" node of the
ELisp manual.  You will need to write some Lisp in your ~/.emacs to
bind these events to some function that calls save-some-buffers or
some such.

If worse comes to worst, you can always send SIGTERM to Emacs: Emacs
always auto-saves before it terminates in an abnormal fashion.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2008-01-16 19:24 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-16  2:18 attaching to a running emacs process under linux? ivowel
2008-01-16  5:16 ` Dmitry Dzhus
2008-01-16 13:57   ` Matthias Pfeifer
2008-01-16 19:24 ` Eli Zaretskii

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.