[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: emacsclient --create-frame not creating a window frame
From: |
Michel Verdier |
Subject: |
Re: emacsclient --create-frame not creating a window frame |
Date: |
Thu, 24 Oct 2024 10:10:19 +0200 |
User-agent: |
Gnus |
On 2024-10-24, Luca Ferrari wrote:
>> [Service]
>> Type=forking
>> ExecStart=/opt/emacs/emacs29.2/bin/emacs --daemon
>
> Even if the daemon is running fine when I login, and in fact I can
> connect only in text mode, I find that restarting the service with
>
> % systemctl --user restart emacs-daemon
>
> makes the client able to create a visual frame.
> Please note that
> % systemctl --user status emacs-daemon
> reports no problem at all. It seems the daemon is started "too soon"
> to understand there is a graphical environment.
I use --fg-daemon instead of --daemon
So I put in my .config/systemd/user/emacs.service
[Unit]
Description=Emacs text editor
Documentation=info:emacs man:emacs(1) https://gnu.org/software/emacs/
[Service]
Type=notify
ExecStart=/usr/bin/emacs --fg-daemon --no-splash
# Emacs will exit with status 15 after having received SIGTERM, which
# is the default "KillSignal" value systemd uses to stop services.
SuccessExitStatus=15
# The location of the SSH auth socket varies by distribution, and some
# set it from PAM, so don't override by default.
# Environment=SSH_AUTH_SOCK=%t/keyring/ssh
Restart=on-failure
[Install]
WantedBy=default.target