home

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 509552dd9bd5d2f60dc0e2cdbe1dbb9a88108ac7
parent d75e19f56500851329907558d32b399251b5ebab
Author: Vincent Demeester <vincent@sbr.pm>
Date:   Mon, 26 Oct 2020 09:55:27 +0100

tools/emacs: try to fix environment for emacs-server

Signed-off-by: Vincent Demeester <vincent@sbr.pm>

Diffstat:
Musers/modules/services/emacs-server.nix | 3++-
Musers/vincent/dev/emacs.nix | 5+++++
2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/users/modules/services/emacs-server.nix b/users/modules/services/emacs-server.nix @@ -31,7 +31,7 @@ in }; config = mkIf cfg.enable { - systemd.user.services.emacs = { + systemd.user.services.emacs-server = { Unit = { Description = "Emacs: the extensible, self-documenting text editor"; Documentation = @@ -47,6 +47,7 @@ in "${cfg.shell} 'exec emacs --fg-daemon=${cfg.name} ${cfg.extraOptions}'"; ExecStop = "${cfg.shell} 'emacsclient --eval '(kill-emacs)''"; Restart = "on-failure"; + Environment = "DISPLAY=:0"; }; Install = { WantedBy = [ "default.target" ]; }; diff --git a/users/vincent/dev/emacs.nix b/users/vincent/dev/emacs.nix @@ -145,6 +145,11 @@ in package = pkgs.my.emacs; extraPackages = myExtraPackages; }; + services.emacs = { + enable = true; + client.enable = true; + # socketActivation.enable = true; + }; services.emacs-server = { enable = true; package = pkgs.my.emacs;