From: Tassilo Horn <thorn+news@fastmail.fm>
To: help-gnu-emacs@gnu.org
Subject: Re: emacsserver unstable?
Date: Tue, 24 Jul 2007 09:48:16 +0200 [thread overview]
Message-ID: <878x96jl8f.fsf@baldur.tsdh.de> (raw)
In-Reply-To: mailman.3828.1185234040.32220.help-gnu-emacs@gnu.org
Sven Bretfeld <sven.bretfeld@gmx.ch> writes:
Hi Sven,
> I never close Emacs, but I'm working heavily with AucTeX and shell
> buffers. Is it possible that I unconsciously close the server by some
> operation? Or is it generally unstable?
No, at least here it runs fine. Maybe you start another emacs instance
sometimes? This will make the former server unavailable and if you close
the server you have none at all. To prevent that I use this code in my
~/.emacs which uses a lock file so that only the first instance acts as
server.
,----[ ~/.emacs ]
| (defparameter th-server-lock-file "~/.emacs.d/server.lock"
| "Emacs server lock file.")
|
| (defun th-server-start ()
| (interactive)
| (shell-command (concat "touch " th-server-lock-file))
| (server-start)
| (message "Emacs Server started...")
| ;; Titel
| (setq frame-title-format
| '("Emacs (Server): %b")))
|
| ;; Emacs-server nur dann starten, wenn noch kein anderer gestartet wurde.
| (if (and (not (file-exists-p th-server-lock-file))
| (not noninteractive))
| (th-server-start)
| (message "Emacs Server NOT started, because lockfile exists.")
| (setq frame-title-format
| '("Emacs: %b")))
|
| (defun th-server-remove-lock-file ()
| (interactive)
| (when (boundp 'server-process)
| (shell-command (concat "rm " th-server-lock-file))))
|
| ;; Beim Beenden der Server-Instanz das Lockfile löschen.
| (add-hook 'kill-emacs-hook
| 'th-server-remove-lock-file)
`----
Bye,
Tassilo
--
No person, no idea, and no religion deserves to be illegal to insult,
not even the Church of Emacs. (Richard M. Stallman)
next parent reply other threads:[~2007-07-24 7:48 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.3828.1185234040.32220.help-gnu-emacs@gnu.org>
2007-07-24 7:48 ` Tassilo Horn [this message]
2007-07-24 9:09 ` emacsserver unstable? Sven Bretfeld
[not found] ` <mailman.3845.1185268221.32220.help-gnu-emacs@gnu.org>
2007-07-25 5:59 ` Stefan Monnier
2007-07-26 13:26 ` Sven Bretfeld
2007-07-26 15:10 ` [SOLVED] " Sven Bretfeld
2007-07-26 18:27 ` Peter Dyballa
2007-07-23 23:40 Sven Bretfeld
2007-07-24 13:44 ` Sven Bretfeld
[not found] ` <mailman.3864.1185284692.32220.help-gnu-emacs@gnu.org>
2007-07-24 15:05 ` Tassilo Horn
2007-07-24 16:08 ` Sven Bretfeld
2007-07-24 17:44 ` Peter Dyballa
2007-07-24 19:08 ` Sven Bretfeld
2007-07-24 20:22 ` Peter Dyballa
2007-07-24 21:46 ` Lennart Borgman (gmail)
2007-07-24 21:50 ` Peter Dyballa
2007-07-24 22:01 ` Sven Bretfeld
2007-07-24 22:47 ` Peter Dyballa
2007-07-25 13:43 ` Sven Bretfeld
2007-07-25 15:13 ` Sven Bretfeld
2007-07-25 23:43 ` Sven Bretfeld
[not found] ` <mailman.3990.1185406991.32220.help-gnu-emacs@gnu.org>
2007-07-26 8:22 ` Tassilo Horn
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=878x96jl8f.fsf@baldur.tsdh.de \
--to=thorn+news@fastmail.fm \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.