Last call to make your voice heard! Our 2022 Developer Survey closes in less than a week. Take survey.

Questions tagged [emacsclient]

emacsclient is a program which allows the user to connect to the Emacs Server. This is useful when using Emacs as the default editor on Unix-like systems, as it allows Emacs to be invoked without creating a new process, allowing the reuse of shared buffers and command history.

Filter by
Sorted by
Tagged with
0 votes
0 answers
20 views

Z-Order of Emacs Client Not Layered Top-Most

System & related settings: Fedora 35 (using Cinnamon Desktop) Emacs 27.2 focus mode: "sloppy" with "raise-on-click" disabled Contrary to all other applications, including the ...
user avatar
  • 295
1 vote
0 answers
49 views

Custom org-capture find headerline function error, wrong number of arguments

So, I managed to get my headline retrieval function fixed, so now the function searches and finds my header lines, but when I select the one I want to use.. it oddly throws back this apply: Wrong ...
user avatar
1 vote
1 answer
46 views

How do I make org capture prompt for specific header target?

I need help writing a function that makes Org Capture prompt me of what it should place the capture to a specified header in my tasks org file (basically I need it to search through the specified org ...
user avatar
1 vote
1 answer
91 views

Running a program from elisp that runs `emacsclient` set on `$EDITOR`

I'm automating some work tasks, and many of them consist of calling kubectl edit on different objects. kubectl edit basically opens your $EDITOR which I have configured to be emacsclient. My question ...
user avatar
  • 207
3 votes
0 answers
58 views

What are the differences between multiple ways to "close" an emacsclient?

As a standalone instance (without daemon mode) I close my emacs via C-x C-c (save-buffers-kill-terminal). This works also with emacsclient and I see no problem about that. But the manpage of ...
user avatar
  • 499
1 vote
0 answers
16 views

How to trigger debugger on emacsclient error

I asked in a prior question about what might be causing my emacsclient widows to shutdown immediately with the following output on stderr: "ERROR: Beginning of buffer". I have tried to use ...
user avatar
0 votes
0 answers
59 views

emacsclient closes immediately on "*ERROR*: Beginning of buffer"

I have an app where I call emacsclient to do some editing on an org file. When it calls it, the frame flashes for an instant, then closes immediately. On stderr, I get the following message: *ERROR*:...
user avatar
0 votes
0 answers
21 views

How to use emacs client/server on sysVinit?

I'm on sysVinit init system on devuan. Anybody please help me on how can i enable client server on booting as like in systemd .
user avatar
1 vote
1 answer
46 views

Let emacsclient try to reconnect after running alternate_editor

If I set alternate_editor to an empty string, emacsclient runs "emacs --daemon" and then tries to reconnect. However, I want to run it a specific emacs executable that is not in my path. If ...
user avatar
  • 113
0 votes
1 answer
60 views

How to open emacsclient with working directory set to $PWD?

In my XTerm, I want to open new Emacs frame as well as buffer, with working directory set to $PWD in XTerm env. I tried emacsclient -t -c --eval "(cd $PWD)", but it doesn't seem to work. Is ...
user avatar
1 vote
0 answers
221 views

how to update emacs packages from the command line

I want to be able to update Emacs packages from the command line and then quit. I have written this function (defun updateandquit () (configuration-layer/update-packages t) (spacemacs/...
user avatar
0 votes
2 answers
219 views

What is emacs : daemon, emacsclient, tcp-server?

I want to know about why they are used? , what are they? what is daemon in emacs, Why Should/shouldnot i use "emacs" instead of "emacsclient --create-frame" ? what is client and ...
user avatar
0 votes
1 answer
39 views

org-link-open fails with Wrong number of arguments: (1 . 1), 0

I recently added a config entry to my ./doom.d/config.el to enable Firefox as a default browser for opening links. Below is the entry I added based on this post. ;; Set specific browser to open links ...
user avatar
0 votes
2 answers
76 views

Org Tangle if file does not exist

I've been trying to work out if it's possible to tangle a file if it's not existent on the system. I came across Can Org Babel conditionally tangle code blocks based on system-type? which gave me a ...
user avatar
1 vote
0 answers
31 views

Open new file in new frame without raising existing frames (Windows)

I run Emacs in a MSWindows environment (via server launched with runemacs), and open new files with emacsclientw.exe -n [filename]. It works very well, except for a detail in the second case below: ...
user avatar
  • 183
0 votes
1 answer
43 views

org-protocol URLs with UTF-8 (URL-encoded) characters aren't properly captured

When using org-protocol capture URLs on Windows, pages with non-ASCII titles or captured text results in a capture with incorrect values applied in the template. Despite such characters being properly ...
user avatar
1 vote
0 answers
74 views

emacs unable to create frame in tty mode on linux `No applicable method: frame-creation-function`

Recently I'm unable to open emacsclient in tty mode, it always fails with the below error (environment redacted, and added newlines) *ERROR*: No applicable method: frame-creation-function, ( (menu-bar-...
user avatar
1 vote
0 answers
1k views

Doom emacs org-agenda does not show to do items

I am new to doom emacs, I am trying to give a shot to using org mode todos and agenda files. I created a sample org file with a list of to-do items as below. #+TITLE: Sample list * Check ** TODO Item ...
user avatar
1 vote
0 answers
66 views

`org-ellipsis` respected by `emacsclient` but not by `emacs`

In my emacs.d/init.el I have: (use-package org ;; ... :custom (org-ellipsis " ▼") :custom-face (org-ellipsis ((t (:foreground "#665" :underline nil)))) ;; ....
user avatar
  • 375
0 votes
1 answer
116 views

Emacs daemon. First emacslient frame loads reasonably fast. Subsequent emacsclient frames load almost instantaneously. Why?

Emacs daemon greatly reduces time to load the first frame with emacsclient. However, when visiting a file with emacsclient, subsequent emacsclient frames load much faster than the first. Command Load ...
user avatar
1 vote
1 answer
30 views

org files are not refreshed in emacsclient

My org files are stored on the cloud so I can edit them from multiple machines. Whenever I make a change to an org file (from a different machine), emacsclient does not reflect these changes, but a ...
user avatar
  • 123
1 vote
1 answer
119 views

mwheel-scroll bindings between GUI and terminal?

Using an Emacs daemon (28, pgtk branch) switching between GUI and terminal, I can't get mouse scrolling to work on both. They work on each individually, but the issue is with the mouse-wheel-{up,down}-...
user avatar
  • 11
1 vote
1 answer
103 views

Emacs client doesn't recognize non-ascii input

The problem: When I type a non-ascii character, the character is not wrote and instead a weird key combination is performed, depending on which character I have typed, as if it didn't support utf-8. ...
user avatar
0 votes
1 answer
37 views

How to suppress emacsclient --eval output

I am opening a file as follows: $ emacsclient -qt -e '(progn (find-file "'filename.py'"))' #<buffer filename.py> which outputs #<buffer filename.py> in the terminal. Is it ...
user avatar
  • 1,112
6 votes
1 answer
1k views

How to get the PATH from the SHELL

When launched at system start-up, the Emacs daemon doesn't pick up modifications to the PATH introduced by shell initialization scripts. Emacswiki suggests to use this function to update Emacs' PATH, (...
user avatar
  • 1,392
0 votes
0 answers
101 views

How do I type … in the TUI?

When I call describe-key and enter … (Alt Gr + .), it says M-b runs the command backward-word […] and async-shell-command (bound to M-&) is called. I'm on Linux with Xorg, the terminal emulator is ...
user avatar
  • 105
1 vote
1 answer
29 views

When emacsclient open with eval using use-package it opens waiting M-x

I am trying to create a bash alias to open emacs with a calendar from terminal. To do so I am using calfw with use-package like so: (use-package calfw :ensure ;TODO: :config (require 'calfw) (...
user avatar
1 vote
1 answer
197 views

How to suppress `When done with a buffer, type C-x #` warning message?

When I open a buffer I keep seeing following message: When done with a buffer, type C-x # in the minibuffer. => Is it possible completely to suppress this message? I am using emacsclient -t -q to ...
user avatar
  • 1,112
0 votes
1 answer
137 views

What' s going on with this program?

I have been using emacs for many years, but from version 26 ... there is a mess with server as I have to type emacsclient in place of simply emacs. Going worse with 27. From 26 I haven't found a way ...
user avatar
  • 141
2 votes
0 answers
39 views

How can I get Emacs to release a locking folder handle?

After using Emacs to open a file in a folder on MS Windows using emacsclientw -n, killing the buffer does not release a handle Emacs has to the folder, so the folder can't be deleted. GNU Emacs 27.1 (...
user avatar
  • 121
0 votes
0 answers
53 views

emacsclient single executions are expensive?

I have server-mode enabled so that I can use emacsclient to execute functions from other parts of my system. My main example is that I have a polybar module that calls emacsclient for some details ...
user avatar
2 votes
1 answer
215 views

How does emacsclient determine what XDG_RUNTIME_DIRS is supposed to be?

When I run emacsclient I get this error: $ emacsclient . emacsclient: Should XDG_RUNTIME_DIR='/run/user/10030' be in the environment? emacsclient: (Be careful: XDG_RUNTIME_DIR is security-related.) ...
user avatar
2 votes
1 answer
520 views

Emacs daemon does not load my init.el completely but plain emacs does

When I run emacs, everything is ok, my init.el is read. However, after starting a daemon (emacs --daemon), an emacsclient GUI frame (emacsclient -c) is not configured for the following setting: font ...
user avatar
  • 63
0 votes
2 answers
78 views

Face setting doesn't work for client sessions

I wanted to change the colours of Anzu's counter, taking the foreground from the Isearch match background and the background from the fringes, like this So I evaluated (face-spec-set 'anzu-mode-line `...
user avatar
  • 1,392
0 votes
0 answers
61 views

How do I make Emacs not complain about not being able to start a new server?

I use the mac port version of emacs for handling org-protocol URLs, because I need a graphical instance when I use org-protocol from Chrome. The problem is that emacs will try to start an emacs server ...
user avatar
  • 620
0 votes
0 answers
155 views

emacsclient crashes on start

I use doom emacs. Starting emacs normally works just fine. Having an emacs daemon and trying to use emacsclient -c causes the following error: *ERROR*: Symbol’s function definition is void: persp-mode-...
user avatar
0 votes
0 answers
165 views

org capture: Store new file name or use an existing file name as a variable

I'm looking for a way to use a fuzzy finder menu to store a new file name or select an existing file name as ${title} or %ˆ{Name} string variable. I use the zettelkasten system and my workflow ...
user avatar
0 votes
0 answers
49 views

Server-edit Automatically When Buffer is Killed

I'm considering using emacs as a server (using (server-start)) but I do not want to use C-x # to kill buffers. I've heard of the -n option for emacsclient, but I'm concerned that it may cause unwanted ...
user avatar
3 votes
1 answer
139 views

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? ...
user avatar
  • 163
0 votes
0 answers
36 views

emacs org capture mode not creating link with "%a"?

my org capture template is (setq org-capture-templates '( ("i" "Idea" entry (file+datetree "~/Dropbox/org_mode/ideas.org") "* %?\n Idea: %U\n ...
user avatar
  • 111
2 votes
1 answer
52 views

Using `emacsclient` for `$VISUAL` raises `End of file during parsing`

I want to use emacs as VISUAL with server-mode. As a test, I write the following in a terminal: emacsclient -F "((left . 0) (top . 0))" -c -n file This behaves exactly as expected; it ...
user avatar
  • 145
0 votes
0 answers
331 views

emacsclient: connect: Connection refused

I am trying to run emacs-daemon on a remote machine (connected via ssh), which was working fine. After I try to setup ports for mosh between 60000:61000 emacs-daemon started not to open :-( The way I ...
user avatar
  • 1,112
2 votes
0 answers
296 views

How can I set WM_CLASS for Emacs 27?

I use scratchpads in XMonad (my WM) extensively for quickly capturing (notes, TODOs etc) from anyhwere. I have an instance of Emacs running permanently in a workspace, and launch emacsclient as my ...
user avatar
  • 121
1 vote
1 answer
579 views

Emacsclient not loading init file changes

Context: I just updated Emacs via homebrew; I don't remember the steps I followed to get Emacs to run via daemon originally, but since the update it doesn't seem to be using it anymore (i.e. quitting ...
user avatar
  • 13
0 votes
2 answers
737 views

Font and frame configuration in daemon mode

In my .emacs I have (set-frame-font "Source Code Pro") (set-face-attribute 'default nil :font "Source Code Pro" :height 140) (set-face-font 'default "Source Code Pro") ...
user avatar
3 votes
1 answer
587 views

Can't get rid of scratch buffer at startup for Emacs 26.3

I am using GNU Emacs 26.3 (build 1, x86_64-w64-mingw32) of 2019-08-29. In my .emacs I specifically asked not to show the startup screen or buffer *scratch*: (custom-set-variables '(inhibit-startup-...
user avatar
  • 61
2 votes
1 answer
209 views

How emacsclient automatically startup with the most recent file?

With the help of recentf I am able to open recently open files from its buffer list. As an example when I execute icicle-buffer, I can see the buffer list. I was wondering can I do this operation ...
user avatar
  • 1,112
1 vote
1 answer
637 views

emacsclient unable to connect to daemon under snap installation of Emacs

I am facing with a well know problem, when I try to start emacs --daemon on a remote machine, I am getting following error emacsclient: connect: Connection refused: $ ps aux | grep -E "[e]macs&...
user avatar
  • 1,112
1 vote
1 answer
256 views

How to exit emacs with `q` when man inside emacs is opened

Default behavior of man <command> (opens inside less) when q is pressed it is closed. I am using following to open MANPAGER with emacs: emacsclient -nw -e "(let ((Man-notify-method 'bully))...
user avatar
  • 1,112
0 votes
1 answer
107 views

Prevent dired-find-alternate-file from killing emacsclient

When visiting a folder with emacsclient, for example through emacsclient ., using dired, opening a folder using a will cause emacsclient to terminate. I believe this is because a, bound to dired-find-...
user avatar
  • 883

1
2 3 4 5 6