Questions tagged [emacs-daemon]

Starting Emacs in daemon mode

Emacs can start in daemon mode: it starts without any user interface, only with a , and you can open files and windows by contacting the server with the utility.

Do not use this tag for questions about other kinds of daemons! Use a tag that is related to what the daemon is for.

83 questions
13
votes
5 answers

Emacs client can't find server in terminal

So, I'm trying to set up emacs as a server but I'm having trouble getting it to work from the terminal. If I run emacs --daemon on some terminal I can connect to it if I run the emacsclient from that same terminal, but if I open a new terminal the…
10
votes
1 answer

how to make emacs prompt me before closing the last emacs gui frame when running emacs as a daemon?

I know that if I set: (setq confirm-kill-emacs 'y-or-n-p) Emacs prompts me before I kill it. But I want emacs to prompt me before I close my last gui frame (prompting me before killing any frame would be very helpful already). When you run emacs…
ninrod
  • 1,436
  • 2
  • 13
  • 28
10
votes
2 answers

How to make emacs running in daemon mode read my bashrc before start?

I run Emacs in the daemon mode as a user's systemd unit. However it won't read my environment variables. How to make it import my .bashrc first? I have multiple paths added in there and want to be able to use them in Emacs (but I don't want to…
catemperor
  • 233
  • 2
  • 10
9
votes
1 answer

Emacs (as daemon) doesn't load theme

Related: Emacs: GUI with emacs --daemon not loading fonts correctly My init.el contains the following lines: (require 'darktooth-theme) (load-theme 'darktooth t) If I start Emacs with $ emacs ... the theme loads properly. [Scroll…
digitalis_
  • 427
  • 4
  • 10
8
votes
0 answers

Restart emacs daemon from within emacs

Very much like Restart emacs from within emacs, except I'd like to do this for an emacs daemon and client. Specifically, I'm interested in the terminal client, but of course being able to restart from the graphical client would be cool. EDIT: A…
PythonNut
  • 10,243
  • 2
  • 29
  • 75
7
votes
2 answers

How can I run Emacs 24.x app on Mac OS X in daemon mode

I want to run the Emacs.app in daemon mode on Mac OS X. I can run emacs in daemon mode via the terminal, but instructions for running the app in a client-server pattern do not work (e.g.: http://overtone.github.io/emacs-live/doc-starting.html, yet…
pwalsh
  • 245
  • 2
  • 6
7
votes
2 answers

Unable to connect using emacsclient

I am starting the emacs server using systemctl --now --user enable emacs That server is running, if I run systemctl --user status emacs I got $ systemctl --user status emacs ● emacs.service - Emacs text editor Loaded: loaded…
7
votes
3 answers

Emacs 24.5.1 on Windows: How to use server mode?

I used to have Emacs 25.xx on my windows pc and was very happy with the daemon/server mode of emacs. Emacs started via batch-script on startup and everything worked fine -- on every subsequent call Emacs just started instantly. Just as it should.…
itmuckel
  • 267
  • 2
  • 12
5
votes
1 answer

emacsclient directly start eshell command command line

Both of the following work to call a graphical/terminal eshell: emacs -f eshell emacs -nw -f eshell Furthermore, this 2-step process also works: `emacsclient -t -a '' /some/real/file/name Metax eshell BUT, this does not: emacsclient -t -a '' -f…
5
votes
1 answer

How to start in daemon mode and suppress interactive dialogs?

I love to start emacs in daemon mode with my first login and then have the same emacs process for all subsequent logins, be it graphical, on physical console or from the network via ssh. But there is a problem with this, when using a session to save…
Uwe Koloska
  • 968
  • 9
  • 13
4
votes
1 answer

How are a daemon and a server different in Emacs?

After running (server-start) in Emacs, I evaluated (daemonp) and (server-running-p) The first one returns nil, whereas the second one returns t. So, how are a daemon and a server different in Emacs? The official website…
zell
  • 173
  • 6
4
votes
1 answer

Restoring Emacs desktops with daemon + clients

How to use Emacs desktop functionality with emacs daemon + emacsclient instances? I've enabled (desktop-save-mode 1) in my init file, and when I start the daemon I see messages like this: Desktop: 1 frame, 2 buffers restored. However, it does not…
Galder Zamarreño
  • 1,527
  • 2
  • 12
  • 21
4
votes
2 answers

how to start daemon with `--debug-init` or equivalent debugger?

summary problem I'm trying to debug a problem that involves an Emacs config and daemon startup. But when I run emacs --daemon --debug-init from a console, the spew ends with Loading desktop from /home/me/.emacs.d/personal/ ... Entering…
TomRoche
  • 592
  • 3
  • 20
4
votes
1 answer

server-edit vs kill-buffer to kill an emacsclient buffer

I use emacsclient to open files from my webrowser (pdfs, text files etc). When I'm done with the file, I know I need to close it with C-x # (server-edit); if I use C-x k (kill-buffer) I get a warning that the buffer still has a client. This happens…
Tyler
  • 21,719
  • 1
  • 52
  • 92
4
votes
0 answers

Starting emacs in daemon mode freezes, emacsclient is not able find a socket

I cannot launch the emacs daemon anymore. I do not know what triggered this. When entering emacs -Q --daemon -v I get only the following and nothing happen. Warning: due to a long standing Gtk+…
M. Toya
  • 157
  • 13
1
2 3 4 5 6